From 0d8c4682b1c6415fe5b59e77a56c3291eb3b815a Mon Sep 17 00:00:00 2001 From: Matas Ubarevicius Date: Thu, 8 Jan 2026 14:51:15 +0200 Subject: [PATCH 01/31] OCCT bottle demos added to playcanvas/threejs/babylonjs runner examples with dimensions --- .../hello-world-occt-bottle-demo.mdx | 675 +++++++++++++++++ .../hello-world-occt-bottle-demo.mdx | 646 ++++++++++++++++ .../threejs/hello-world-occt-bottle-demo.mdx | 696 ++++++++++++++++++ 3 files changed, 2017 insertions(+) create mode 100644 docs/learn/runners/engines/babylonjs/hello-world-occt-bottle-demo.mdx create mode 100644 docs/learn/runners/engines/playcanvas/hello-world-occt-bottle-demo.mdx create mode 100644 docs/learn/runners/engines/threejs/hello-world-occt-bottle-demo.mdx diff --git a/docs/learn/runners/engines/babylonjs/hello-world-occt-bottle-demo.mdx b/docs/learn/runners/engines/babylonjs/hello-world-occt-bottle-demo.mdx new file mode 100644 index 00000000..3bcca5b8 --- /dev/null +++ b/docs/learn/runners/engines/babylonjs/hello-world-occt-bottle-demo.mdx @@ -0,0 +1,675 @@ +--- +sidebar_position: 3 +title: OCCT Bottle Example +description: Learn how to use the full version of the Bitbybit BabylonJS runner for CAD operations +--- + +import BitByBitRenderCanvas from '@site/src/components/BitByBitRenderCanvas'; + +# BabylonJS Full Runner - Bottle Example + +The **full runner** bundles Babylon.js together with Bitbybit, so you don't need to load Babylon.js separately. This makes setup simpler but results in a larger bundle size. + +## Live Example + + + +## Complete Example - Parametric Bottle + +Below is a complete example that creates a parametric bottle with threading using OCCT, with lil-gui controls for adjusting parameters: + +```html + + + + Bitbybit Runner BabylonJS - Parametric Bottle + + + + + + + + + + + +
+ + +
+
+ +
+ + +``` + +## Key Points + +### Runner Script +```html + +``` + +The full runner includes BabylonJS, so you don't need to load it separately. + +### Using setTimeout +```javascript +setTimeout(async () => { + // Your code here +}, 0); +``` + +Unlike PlayCanvas and ThreeJS runners, the BabylonJS runner uses `setTimeout` to ensure the canvas element is fully rendered before initialization. + +### lil-gui Integration +```html + +``` + +Use lil-gui to create interactive parameter controls. The `onFinishChange` callback regenerates the model when parameters are adjusted. + +### Initialization +```javascript +const runner = window.bitbybitRunner.getRunnerInstance(); +const { bitbybit, Bit, BABYLON, scene } = await runner.run(runnerOptions); +``` + +The `run()` method returns: +- `bitbybit` - The main Bitbybit API object +- `Bit` - Helper classes including input DTOs +- `BABYLON` - The BabylonJS library itself +- `scene` - The BabylonJS Scene + +### BabylonJS Lights + +In BabylonJS, point lights are created directly: +```javascript +const light = new BABYLON.PointLight( + 'pointLight', + new BABYLON.Vector3(x, y, z), + scene +); +light.intensity = 200; +light.diffuse = new BABYLON.Color3(1, 1, 1); +``` + +### Model Cleanup + +In BabylonJS, use `.dispose()` to clean up meshes: +```javascript +if (currentGroup) { + currentGroup.dispose(); + currentGroup = null; +} +``` + +### Runner Options + +| Option | Type | Description | +|--------|------|-------------| +| `canvasId` | string | The ID of your canvas element | +| `canvasZoneClass` | string | CSS class for the canvas container | +| `enableOCCT` | boolean | Enable OpenCASCADE kernel | +| `enableJSCAD` | boolean | Enable JSCAD kernel | +| `enableManifold` | boolean | Enable Manifold kernel | +| `cameraPosition` | number[] | Initial camera position [x, y, z] | +| `cameraTarget` | number[] | Camera look-at target [x, y, z] | +| `backgroundColor` | string | Scene background color (hex) | +| `loadFonts` | string[] | Fonts to load for text operations | + +### Downloading STEP & STL Files + +Use `bitbybit.occt.io` to export shapes in various formats: + +```javascript +// Download STEP file +await bitbybit.occt.io.saveShapeSTEP({ + shape: myShape, + fileName: 'model.step', + adjustYtoZ: true, + tryDownload: true, +}); + +// Download STL file +await bitbybit.occt.io.saveShapeStl({ + shape: myShape, + fileName: 'model.stl', + precision: 0.01, + adjustYtoZ: true, + tryDownload: true, + binary: true, +}); +``` + +### Adding Dimensions + +Use `bitbybit.occt.dimensions` to create linear dimensions: + +```javascript +// Create dimension options DTO with default values +const dimOpt = new Bit.Inputs.OCCT.SimpleLinearLengthDimensionDto(); +dimOpt.start = [5, 0, 0]; +dimOpt.end = [0, 0, 0]; +dimOpt.direction = [0, 0, -1]; // Note: BabylonJS uses right-handed coordinates +dimOpt.offsetFromPoints = 0; +dimOpt.labelSize = 0.3; +dimOpt.labelSuffix = 'cm'; +dimOpt.labelRotation = 180; +dimOpt.endType = 'arrow'; +dimOpt.arrowSize = 0.3; +dimOpt.crossingSize = 0.2; +dimOpt.decimalPlaces = 1; + +const dimension = await bitbybit.occt.dimensions.simpleLinearLengthDimension(dimOpt); + +// Draw dimensions as wire geometry +const dimOptions = new Bit.Inputs.Draw.DrawOcctShapeOptions(); +dimOptions.edgeColour = '#ffffff'; +dimOptions.edgeWidth = 2; +dimOptions.drawEdges = true; +dimOptions.drawFaces = false; + +await bitbybit.draw.drawAnyAsync({ + entity: dimension, + options: dimOptions, +}); +``` + +## GitHub Source + +View the full source code on GitHub: [BabylonJS Full Runner Examples](https://github.com/bitbybit-dev/bitbybit/tree/master/examples/runner/babylonjs/full) diff --git a/docs/learn/runners/engines/playcanvas/hello-world-occt-bottle-demo.mdx b/docs/learn/runners/engines/playcanvas/hello-world-occt-bottle-demo.mdx new file mode 100644 index 00000000..6f56cfa4 --- /dev/null +++ b/docs/learn/runners/engines/playcanvas/hello-world-occt-bottle-demo.mdx @@ -0,0 +1,646 @@ +--- +sidebar_position: 3 +title: OCCT Bottle Example +description: Learn how to use the full version of the Bitbybit PlayCanvas runner for CAD operations +--- + +import BitByBitRenderCanvas from '@site/src/components/BitByBitRenderCanvas'; + +# PlayCanvas Full Runner + +The **full runner** bundles PlayCanvas together with Bitbybit, so you don't need to load PlayCanvas separately. This makes setup simpler but results in a larger bundle size. + +## Live Example + + + +## Complete Example - Parametric Bottle + +Below is a complete example that creates a parametric bottle with threading using OCCT, with lil-gui controls for adjusting parameters: + +```html + + + + Bitbybit Runner PlayCanvas - Parametric Bottle + + + + + + + + + + + +
+ + +
+
+ +
+ + +``` + +## Key Points + +### Runner Script +```html + +``` + +The full runner includes PlayCanvas, so you don't need to load it separately. + +### lil-gui Integration +```html + +``` + +Use lil-gui to create interactive parameter controls. The `onFinishChange` callback regenerates the model when parameters are adjusted. + +### Initialization +```javascript +const runner = window.bitbybitRunner.getRunnerInstance(); +const { bitbybit, Bit, camera, scene, app, pc } = await runner.run(runnerOptions); +``` + +The `run()` method returns: +- `bitbybit` - The main Bitbybit API object +- `Bit` - Helper classes including input DTOs +- `camera` - The PlayCanvas camera entity +- `scene` - The PlayCanvas scene (root entity) +- `app` - The PlayCanvas Application instance +- `pc` - The PlayCanvas library itself + +### PlayCanvas Lights vs Babylon.js + +In PlayCanvas, point lights are created as entities: +```javascript +const light = new pc.Entity('pointLight'); +light.addComponent('light', { + type: 'point', + color: new pc.Color(1, 1, 1), + intensity: 2, + range: 50, + castShadows: true, + shadowBias: 0.2, + normalOffsetBias: 0.05, + shadowResolution: 2048, +}); +light.setPosition(x, y, z); +scene.addChild(light); +``` + +### Runner Options + +| Option | Type | Description | +|--------|------|-------------| +| `canvasId` | string | The ID of your canvas element | +| `canvasZoneClass` | string | CSS class for the canvas container | +| `enableOCCT` | boolean | Enable OpenCASCADE kernel | +| `enableJSCAD` | boolean | Enable JSCAD kernel | +| `enableManifold` | boolean | Enable Manifold kernel | +| `cameraPosition` | number[] | Initial camera position [x, y, z] | +| `cameraTarget` | number[] | Camera look-at target [x, y, z] | +| `backgroundColor` | string | Scene background color (hex) | +| `loadFonts` | string[] | Fonts to load for text operations | + +### Downloading STEP & STL Files + +Use `bitbybit.occt.io` to export shapes in various formats: + +```javascript +// Download STEP file +await bitbybit.occt.io.saveShapeSTEP({ + shape: myShape, + fileName: 'model.step', + adjustYtoZ: true, // Convert Y-up to Z-up coordinate system + tryDownload: true, +}); + +// Download STL file +await bitbybit.occt.io.saveShapeStl({ + shape: myShape, + fileName: 'model.stl', + precision: 0.01, // Mesh precision (lower = higher resolution) + adjustYtoZ: true, + tryDownload: true, + binary: true, // Binary format for smaller file size +}); +``` + +### Adding Dimensions + +Use `bitbybit.occt.dimensions` to create linear dimensions: + +```javascript +// Create dimension options DTO with default values +const dimOpt = new Bit.Inputs.OCCT.SimpleLinearLengthDimensionDto(); +dimOpt.start = [0, 0, 0]; // Start point +dimOpt.end = [5, 0, 0]; // End point +dimOpt.direction = [0, 0, 1]; // Direction to offset the dimension line +dimOpt.offsetFromPoints = 0; // Distance from measurement points +dimOpt.labelSize = 0.3; // Size of the label text +dimOpt.labelSuffix = 'cm'; // Unit suffix (no space) +dimOpt.labelRotation = 180; // Rotate label for readability +dimOpt.endType = 'arrow'; // Arrow style endpoints +dimOpt.arrowSize = 0.3; // Arrow size +dimOpt.crossingSize = 0.2; // Size of endpoint markers +dimOpt.decimalPlaces = 1; // Number of decimal places + +const dimension = await bitbybit.occt.dimensions.simpleLinearLengthDimension(dimOpt); + +// Draw dimensions as wire geometry +const dimOptions = new Bit.Inputs.Draw.DrawOcctShapeOptions(); +dimOptions.edgeColour = '#ffffff'; +dimOptions.edgeWidth = 2; +dimOptions.drawEdges = true; +dimOptions.drawFaces = false; + +await bitbybit.draw.drawAnyAsync({ + entity: dimension, + options: dimOptions, +}); +``` + +## GitHub Source + +View the full source code on GitHub: [PlayCanvas Full Runner Examples](https://github.com/bitbybit-dev/bitbybit/tree/master/examples/runner/playcanvas/full) diff --git a/docs/learn/runners/engines/threejs/hello-world-occt-bottle-demo.mdx b/docs/learn/runners/engines/threejs/hello-world-occt-bottle-demo.mdx new file mode 100644 index 00000000..7a07ec1a --- /dev/null +++ b/docs/learn/runners/engines/threejs/hello-world-occt-bottle-demo.mdx @@ -0,0 +1,696 @@ +--- +sidebar_position: 3 +title: OCCT Bottle Example +description: Learn how to use the full version of the Bitbybit ThreeJS runner for CAD operations +--- + +import BitByBitRenderCanvas from '@site/src/components/BitByBitRenderCanvas'; + +# ThreeJS Full Runner - Bottle Example + +The **full runner** bundles Three.js together with Bitbybit, so you don't need to load Three.js separately. This makes setup simpler but results in a larger bundle size. + +## Live Example + + + +## Complete Example - Parametric Bottle + +Below is a complete example that creates a parametric bottle with threading using OCCT, with lil-gui controls for adjusting parameters: + +```html + + + + Bitbybit Runner ThreeJS - Parametric Bottle + + + + + + + + + + + +
+ + +
+
+ +
+ + +``` + +## Key Points + +### Runner Script +```html + +``` + +The full runner includes ThreeJS, so you don't need to load it separately. + +### lil-gui Integration +```html + +``` + +Use lil-gui to create interactive parameter controls. The `onFinishChange` callback regenerates the model when parameters are adjusted. + +### Initialization +```javascript +const runner = window.bitbybitRunner.getRunnerInstance(); +const { bitbybit, Bit, camera, scene, renderer, THREEJS } = await runner.run(runnerOptions); +``` + +The `run()` method returns: +- `bitbybit` - The main Bitbybit API object +- `Bit` - Helper classes including input DTOs +- `camera` - The ThreeJS PerspectiveCamera +- `scene` - The ThreeJS Scene +- `renderer` - The ThreeJS WebGLRenderer +- `THREEJS` - The ThreeJS library itself + +### ThreeJS Lights + +In ThreeJS, point lights are created directly: +```javascript +const light = new THREEJS.PointLight(0xffffff, 500); +light.position.set(x, y, z); +light.castShadow = true; +scene.add(light); +``` + +### Custom Materials + +ThreeJS allows you to create custom materials for your CAD geometry: + +```javascript +const mat = new THREEJS.MeshPhongMaterial({ + color: new THREEJS.Color(color) +}); +mat.polygonOffset = true; +mat.polygonOffsetFactor = 1; +options.faceMaterial = mat; +``` + +### Model Cleanup + +In ThreeJS, use `scene.remove()` to clean up meshes: +```javascript +if (currentGroup) { + scene.remove(currentGroup); + currentGroup = null; +} +``` + +### Runner Options + +| Option | Type | Description | +|--------|------|-------------| +| `canvasId` | string | The ID of your canvas element | +| `canvasZoneClass` | string | CSS class for the canvas container | +| `enableOCCT` | boolean | Enable OpenCASCADE kernel | +| `enableJSCAD` | boolean | Enable JSCAD kernel | +| `enableManifold` | boolean | Enable Manifold kernel | +| `cameraPosition` | number[] | Initial camera position [x, y, z] | +| `cameraTarget` | number[] | Camera look-at target [x, y, z] | +| `backgroundColor` | string | Scene background color (hex) | +| `loadFonts` | string[] | Fonts to load for text operations | + +### Downloading STEP & STL Files + +Use `bitbybit.occt.io` to export shapes in various formats: + +```javascript +// Download STEP file +await bitbybit.occt.io.saveShapeSTEP({ + shape: myShape, + fileName: 'model.step', + adjustYtoZ: true, + tryDownload: true, +}); + +// Download STL file +await bitbybit.occt.io.saveShapeStl({ + shape: myShape, + fileName: 'model.stl', + precision: 0.01, + adjustYtoZ: true, + tryDownload: true, + binary: true, +}); +``` + +### Adding Dimensions + +Use `bitbybit.occt.dimensions` to create linear dimensions: + +```javascript +// Create dimension options DTO with default values +const dimOpt = new Bit.Inputs.OCCT.SimpleLinearLengthDimensionDto(); +dimOpt.start = [0, 0, 0]; +dimOpt.end = [5, 0, 0]; +dimOpt.direction = [0, 0, 1]; +dimOpt.offsetFromPoints = 0; +dimOpt.labelSize = 0.3; +dimOpt.labelSuffix = 'cm'; +dimOpt.labelRotation = 180; +dimOpt.endType = 'arrow'; +dimOpt.arrowSize = 0.3; +dimOpt.crossingSize = 0.2; +dimOpt.decimalPlaces = 1; + +const dimension = await bitbybit.occt.dimensions.simpleLinearLengthDimension(dimOpt); + +// Draw dimensions as wire geometry +const dimOptions = new Bit.Inputs.Draw.DrawOcctShapeOptions(); +dimOptions.edgeColour = '#ffffff'; +dimOptions.edgeWidth = 2; +dimOptions.drawEdges = true; +dimOptions.drawFaces = false; + +await bitbybit.draw.drawAnyAsync({ + entity: dimension, + options: dimOptions, +}); +``` + +## GitHub Source + +View the full source code on GitHub: [ThreeJS Full Runner Examples](https://github.com/bitbybit-dev/bitbybit/tree/master/examples/runner/threejs/full) From f748481a5c661f29a832a9940c36489a897ae7f1 Mon Sep 17 00:00:00 2001 From: Matas Ubarevicius Date: Thu, 8 Jan 2026 14:54:43 +0200 Subject: [PATCH 02/31] update texts --- .../engines/babylonjs/hello-world-occt-bottle-demo.mdx | 8 ++------ .../engines/playcanvas/hello-world-occt-bottle-demo.mdx | 8 ++------ .../engines/threejs/hello-world-occt-bottle-demo.mdx | 8 ++------ 3 files changed, 6 insertions(+), 18 deletions(-) diff --git a/docs/learn/runners/engines/babylonjs/hello-world-occt-bottle-demo.mdx b/docs/learn/runners/engines/babylonjs/hello-world-occt-bottle-demo.mdx index 3bcca5b8..6ba681a2 100644 --- a/docs/learn/runners/engines/babylonjs/hello-world-occt-bottle-demo.mdx +++ b/docs/learn/runners/engines/babylonjs/hello-world-occt-bottle-demo.mdx @@ -6,9 +6,9 @@ description: Learn how to use the full version of the Bitbybit BabylonJS runner import BitByBitRenderCanvas from '@site/src/components/BitByBitRenderCanvas'; -# BabylonJS Full Runner - Bottle Example +## Complete Example - Parametric Bottle -The **full runner** bundles Babylon.js together with Bitbybit, so you don't need to load Babylon.js separately. This makes setup simpler but results in a larger bundle size. +Below is a complete example that creates a parametric bottle with threading using OCCT, with lil-gui controls for adjusting parameters: ## Live Example @@ -18,10 +18,6 @@ The **full runner** bundles Babylon.js together with Bitbybit, so you don't need title="StackBlitz - Babylon.js Full Runner Example" /> -## Complete Example - Parametric Bottle - -Below is a complete example that creates a parametric bottle with threading using OCCT, with lil-gui controls for adjusting parameters: - ```html diff --git a/docs/learn/runners/engines/playcanvas/hello-world-occt-bottle-demo.mdx b/docs/learn/runners/engines/playcanvas/hello-world-occt-bottle-demo.mdx index 6f56cfa4..4e82c27b 100644 --- a/docs/learn/runners/engines/playcanvas/hello-world-occt-bottle-demo.mdx +++ b/docs/learn/runners/engines/playcanvas/hello-world-occt-bottle-demo.mdx @@ -6,9 +6,9 @@ description: Learn how to use the full version of the Bitbybit PlayCanvas runner import BitByBitRenderCanvas from '@site/src/components/BitByBitRenderCanvas'; -# PlayCanvas Full Runner +## Complete Example - Parametric OCCT Bottle -The **full runner** bundles PlayCanvas together with Bitbybit, so you don't need to load PlayCanvas separately. This makes setup simpler but results in a larger bundle size. +Below is a complete example that creates a parametric bottle with threading using OCCT, with lil-gui controls for adjusting parameters: ## Live Example @@ -18,10 +18,6 @@ The **full runner** bundles PlayCanvas together with Bitbybit, so you don't need title="StackBlitz - PlayCanvas Full Runner Example" /> -## Complete Example - Parametric Bottle - -Below is a complete example that creates a parametric bottle with threading using OCCT, with lil-gui controls for adjusting parameters: - ```html diff --git a/docs/learn/runners/engines/threejs/hello-world-occt-bottle-demo.mdx b/docs/learn/runners/engines/threejs/hello-world-occt-bottle-demo.mdx index 7a07ec1a..95501f0c 100644 --- a/docs/learn/runners/engines/threejs/hello-world-occt-bottle-demo.mdx +++ b/docs/learn/runners/engines/threejs/hello-world-occt-bottle-demo.mdx @@ -6,9 +6,9 @@ description: Learn how to use the full version of the Bitbybit ThreeJS runner fo import BitByBitRenderCanvas from '@site/src/components/BitByBitRenderCanvas'; -# ThreeJS Full Runner - Bottle Example +## Complete Example - Parametric OCCT Bottle -The **full runner** bundles Three.js together with Bitbybit, so you don't need to load Three.js separately. This makes setup simpler but results in a larger bundle size. +Below is a complete example that creates a parametric bottle with threading using OCCT, with lil-gui controls for adjusting parameters: ## Live Example @@ -18,10 +18,6 @@ The **full runner** bundles Three.js together with Bitbybit, so you don't need t title="StackBlitz - Three.js Full Runner Example" /> -## Complete Example - Parametric Bottle - -Below is a complete example that creates a parametric bottle with threading using OCCT, with lil-gui controls for adjusting parameters: - ```html From 47ae5abbda772c65870fcb2c62b315772533dd13 Mon Sep 17 00:00:00 2001 From: Matas Ubarevicius Date: Fri, 9 Jan 2026 17:44:24 +0200 Subject: [PATCH 03/31] new example of runner setup in typescript project for simple fast vibe-coding workflows that contain all type defs and full intellisense. --- .../threejs/runner-occt-bottle/.gitignore | 24 + .../threejs/runner-occt-bottle/index.html | 24 + .../runner-occt-bottle/package-lock.json | 1582 + .../threejs/runner-occt-bottle/package.json | 20 + .../runner-occt-bottle/public/vite.svg | 1 + .../src/helpers/init-threejs.ts | 108 + .../threejs/runner-occt-bottle/src/main.ts | 423 + .../src/runner/bitbybit-0.21.0.d.ts | 49262 ++++++++++++++++ .../src/runner/load-runner-script.ts | 9 + .../src/runner/runner-types.ts | 113 + .../threejs/runner-occt-bottle/src/style.css | 37 + .../runner-occt-bottle/src/vite-env.d.ts | 1 + .../threejs/runner-occt-bottle/tsconfig.json | 25 + .../babylonjs/lib/api/inputs/draw-inputs.ts | 4 +- 14 files changed, 51631 insertions(+), 2 deletions(-) create mode 100644 examples/vite/threejs/runner-occt-bottle/.gitignore create mode 100644 examples/vite/threejs/runner-occt-bottle/index.html create mode 100644 examples/vite/threejs/runner-occt-bottle/package-lock.json create mode 100644 examples/vite/threejs/runner-occt-bottle/package.json create mode 100644 examples/vite/threejs/runner-occt-bottle/public/vite.svg create mode 100644 examples/vite/threejs/runner-occt-bottle/src/helpers/init-threejs.ts create mode 100644 examples/vite/threejs/runner-occt-bottle/src/main.ts create mode 100644 examples/vite/threejs/runner-occt-bottle/src/runner/bitbybit-0.21.0.d.ts create mode 100644 examples/vite/threejs/runner-occt-bottle/src/runner/load-runner-script.ts create mode 100644 examples/vite/threejs/runner-occt-bottle/src/runner/runner-types.ts create mode 100644 examples/vite/threejs/runner-occt-bottle/src/style.css create mode 100644 examples/vite/threejs/runner-occt-bottle/src/vite-env.d.ts create mode 100644 examples/vite/threejs/runner-occt-bottle/tsconfig.json diff --git a/examples/vite/threejs/runner-occt-bottle/.gitignore b/examples/vite/threejs/runner-occt-bottle/.gitignore new file mode 100644 index 00000000..a547bf36 --- /dev/null +++ b/examples/vite/threejs/runner-occt-bottle/.gitignore @@ -0,0 +1,24 @@ +# Logs +logs +*.log +npm-debug.log* +yarn-debug.log* +yarn-error.log* +pnpm-debug.log* +lerna-debug.log* + +node_modules +dist +dist-ssr +*.local + +# Editor directories and files +.vscode/* +!.vscode/extensions.json +.idea +.DS_Store +*.suo +*.ntvs* +*.njsproj +*.sln +*.sw? diff --git a/examples/vite/threejs/runner-occt-bottle/index.html b/examples/vite/threejs/runner-occt-bottle/index.html new file mode 100644 index 00000000..27351d60 --- /dev/null +++ b/examples/vite/threejs/runner-occt-bottle/index.html @@ -0,0 +1,24 @@ + + + + + + + + Bitbybit & PlayCanvas Hex House Concept Demo + + + + +
+ +
+ + + + \ No newline at end of file diff --git a/examples/vite/threejs/runner-occt-bottle/package-lock.json b/examples/vite/threejs/runner-occt-bottle/package-lock.json new file mode 100644 index 00000000..0086a549 --- /dev/null +++ b/examples/vite/threejs/runner-occt-bottle/package-lock.json @@ -0,0 +1,1582 @@ +{ + "name": "vite-typescript-starter", + "version": "0.0.0", + "lockfileVersion": 2, + "requires": true, + "packages": { + "": { + "name": "vite-typescript-starter", + "version": "0.0.0", + "dependencies": { + "lil-gui": "0.20.0", + "three": "0.182.0" + }, + "devDependencies": { + "@types/three": "0.182.0", + "typescript": "~5.8.3", + "vite": "^6.3.2" + } + }, + "node_modules/@dimforge/rapier3d-compat": { + "version": "0.12.0", + "resolved": "https://registry.npmjs.org/@dimforge/rapier3d-compat/-/rapier3d-compat-0.12.0.tgz", + "integrity": "sha512-uekIGetywIgopfD97oDL5PfeezkFpNhwlzlaEYNOA0N6ghdsOvh/HYjSMek5Q2O1PYvRSDFcqFVJl4r4ZBwOow==", + "dev": true, + "license": "Apache-2.0" + }, + "node_modules/@esbuild/aix-ppc64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/aix-ppc64/-/aix-ppc64-0.25.3.tgz", + "integrity": "sha512-W8bFfPA8DowP8l//sxjJLSLkD8iEjMc7cBVyP+u4cEv9sM7mdUCkgsj+t0n/BWPFtv7WWCN5Yzj0N6FJNUUqBQ==", + "cpu": [ + "ppc64" + ], + "dev": true, + "optional": true, + "os": [ + "aix" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/android-arm": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/android-arm/-/android-arm-0.25.3.tgz", + "integrity": "sha512-PuwVXbnP87Tcff5I9ngV0lmiSu40xw1At6i3GsU77U7cjDDB4s0X2cyFuBiDa1SBk9DnvWwnGvVaGBqoFWPb7A==", + "cpu": [ + "arm" + ], + "dev": true, + "optional": true, + "os": [ + "android" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/android-arm64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/android-arm64/-/android-arm64-0.25.3.tgz", + "integrity": "sha512-XelR6MzjlZuBM4f5z2IQHK6LkK34Cvv6Rj2EntER3lwCBFdg6h2lKbtRjpTTsdEjD/WSe1q8UyPBXP1x3i/wYQ==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "android" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/android-x64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/android-x64/-/android-x64-0.25.3.tgz", + "integrity": "sha512-ogtTpYHT/g1GWS/zKM0cc/tIebFjm1F9Aw1boQ2Y0eUQ+J89d0jFY//s9ei9jVIlkYi8AfOjiixcLJSGNSOAdQ==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "android" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/darwin-arm64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/darwin-arm64/-/darwin-arm64-0.25.3.tgz", + "integrity": "sha512-eESK5yfPNTqpAmDfFWNsOhmIOaQA59tAcF/EfYvo5/QWQCzXn5iUSOnqt3ra3UdzBv073ykTtmeLJZGt3HhA+w==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/darwin-x64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/darwin-x64/-/darwin-x64-0.25.3.tgz", + "integrity": "sha512-Kd8glo7sIZtwOLcPbW0yLpKmBNWMANZhrC1r6K++uDR2zyzb6AeOYtI6udbtabmQpFaxJ8uduXMAo1gs5ozz8A==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/freebsd-arm64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/freebsd-arm64/-/freebsd-arm64-0.25.3.tgz", + "integrity": "sha512-EJiyS70BYybOBpJth3M0KLOus0n+RRMKTYzhYhFeMwp7e/RaajXvP+BWlmEXNk6uk+KAu46j/kaQzr6au+JcIw==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "freebsd" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/freebsd-x64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/freebsd-x64/-/freebsd-x64-0.25.3.tgz", + "integrity": "sha512-Q+wSjaLpGxYf7zC0kL0nDlhsfuFkoN+EXrx2KSB33RhinWzejOd6AvgmP5JbkgXKmjhmpfgKZq24pneodYqE8Q==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "freebsd" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-arm": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/linux-arm/-/linux-arm-0.25.3.tgz", + "integrity": "sha512-dUOVmAUzuHy2ZOKIHIKHCm58HKzFqd+puLaS424h6I85GlSDRZIA5ycBixb3mFgM0Jdh+ZOSB6KptX30DD8YOQ==", + "cpu": [ + "arm" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-arm64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/linux-arm64/-/linux-arm64-0.25.3.tgz", + "integrity": "sha512-xCUgnNYhRD5bb1C1nqrDV1PfkwgbswTTBRbAd8aH5PhYzikdf/ddtsYyMXFfGSsb/6t6QaPSzxtbfAZr9uox4A==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-ia32": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/linux-ia32/-/linux-ia32-0.25.3.tgz", + "integrity": "sha512-yplPOpczHOO4jTYKmuYuANI3WhvIPSVANGcNUeMlxH4twz/TeXuzEP41tGKNGWJjuMhotpGabeFYGAOU2ummBw==", + "cpu": [ + "ia32" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-loong64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/linux-loong64/-/linux-loong64-0.25.3.tgz", + "integrity": "sha512-P4BLP5/fjyihmXCELRGrLd793q/lBtKMQl8ARGpDxgzgIKJDRJ/u4r1A/HgpBpKpKZelGct2PGI4T+axcedf6g==", + "cpu": [ + "loong64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-mips64el": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/linux-mips64el/-/linux-mips64el-0.25.3.tgz", + "integrity": "sha512-eRAOV2ODpu6P5divMEMa26RRqb2yUoYsuQQOuFUexUoQndm4MdpXXDBbUoKIc0iPa4aCO7gIhtnYomkn2x+bag==", + "cpu": [ + "mips64el" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-ppc64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/linux-ppc64/-/linux-ppc64-0.25.3.tgz", + "integrity": "sha512-ZC4jV2p7VbzTlnl8nZKLcBkfzIf4Yad1SJM4ZMKYnJqZFD4rTI+pBG65u8ev4jk3/MPwY9DvGn50wi3uhdaghg==", + "cpu": [ + "ppc64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-riscv64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/linux-riscv64/-/linux-riscv64-0.25.3.tgz", + "integrity": "sha512-LDDODcFzNtECTrUUbVCs6j9/bDVqy7DDRsuIXJg6so+mFksgwG7ZVnTruYi5V+z3eE5y+BJZw7VvUadkbfg7QA==", + "cpu": [ + "riscv64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-s390x": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/linux-s390x/-/linux-s390x-0.25.3.tgz", + "integrity": "sha512-s+w/NOY2k0yC2p9SLen+ymflgcpRkvwwa02fqmAwhBRI3SC12uiS10edHHXlVWwfAagYSY5UpmT/zISXPMW3tQ==", + "cpu": [ + "s390x" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-x64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/linux-x64/-/linux-x64-0.25.3.tgz", + "integrity": "sha512-nQHDz4pXjSDC6UfOE1Fw9Q8d6GCAd9KdvMZpfVGWSJztYCarRgSDfOVBY5xwhQXseiyxapkiSJi/5/ja8mRFFA==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/netbsd-arm64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/netbsd-arm64/-/netbsd-arm64-0.25.3.tgz", + "integrity": "sha512-1QaLtOWq0mzK6tzzp0jRN3eccmN3hezey7mhLnzC6oNlJoUJz4nym5ZD7mDnS/LZQgkrhEbEiTn515lPeLpgWA==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "netbsd" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/netbsd-x64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/netbsd-x64/-/netbsd-x64-0.25.3.tgz", + "integrity": "sha512-i5Hm68HXHdgv8wkrt+10Bc50zM0/eonPb/a/OFVfB6Qvpiirco5gBA5bz7S2SHuU+Y4LWn/zehzNX14Sp4r27g==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "netbsd" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/openbsd-arm64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/openbsd-arm64/-/openbsd-arm64-0.25.3.tgz", + "integrity": "sha512-zGAVApJEYTbOC6H/3QBr2mq3upG/LBEXr85/pTtKiv2IXcgKV0RT0QA/hSXZqSvLEpXeIxah7LczB4lkiYhTAQ==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "openbsd" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/openbsd-x64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/openbsd-x64/-/openbsd-x64-0.25.3.tgz", + "integrity": "sha512-fpqctI45NnCIDKBH5AXQBsD0NDPbEFczK98hk/aa6HJxbl+UtLkJV2+Bvy5hLSLk3LHmqt0NTkKNso1A9y1a4w==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "openbsd" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/sunos-x64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/sunos-x64/-/sunos-x64-0.25.3.tgz", + "integrity": "sha512-ROJhm7d8bk9dMCUZjkS8fgzsPAZEjtRJqCAmVgB0gMrvG7hfmPmz9k1rwO4jSiblFjYmNvbECL9uhaPzONMfgA==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "sunos" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/win32-arm64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/win32-arm64/-/win32-arm64-0.25.3.tgz", + "integrity": "sha512-YWcow8peiHpNBiIXHwaswPnAXLsLVygFwCB3A7Bh5jRkIBFWHGmNQ48AlX4xDvQNoMZlPYzjVOQDYEzWCqufMQ==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/win32-ia32": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/win32-ia32/-/win32-ia32-0.25.3.tgz", + "integrity": "sha512-qspTZOIGoXVS4DpNqUYUs9UxVb04khS1Degaw/MnfMe7goQ3lTfQ13Vw4qY/Nj0979BGvMRpAYbs/BAxEvU8ew==", + "cpu": [ + "ia32" + ], + "dev": true, + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/win32-x64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/win32-x64/-/win32-x64-0.25.3.tgz", + "integrity": "sha512-ICgUR+kPimx0vvRzf+N/7L7tVSQeE3BYY+NhHRHXS1kBuPO7z2+7ea2HbhDyZdTephgvNvKrlDDKUexuCVBVvg==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@rollup/rollup-android-arm-eabi": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-android-arm-eabi/-/rollup-android-arm-eabi-4.40.1.tgz", + "integrity": "sha512-kxz0YeeCrRUHz3zyqvd7n+TVRlNyTifBsmnmNPtk3hQURUyG9eAB+usz6DAwagMusjx/zb3AjvDUvhFGDAexGw==", + "cpu": [ + "arm" + ], + "dev": true, + "optional": true, + "os": [ + "android" + ] + }, + "node_modules/@rollup/rollup-android-arm64": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-android-arm64/-/rollup-android-arm64-4.40.1.tgz", + "integrity": "sha512-PPkxTOisoNC6TpnDKatjKkjRMsdaWIhyuMkA4UsBXT9WEZY4uHezBTjs6Vl4PbqQQeu6oION1w2voYZv9yquCw==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "android" + ] + }, + "node_modules/@rollup/rollup-darwin-arm64": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-darwin-arm64/-/rollup-darwin-arm64-4.40.1.tgz", + "integrity": "sha512-VWXGISWFY18v/0JyNUy4A46KCFCb9NVsH+1100XP31lud+TzlezBbz24CYzbnA4x6w4hx+NYCXDfnvDVO6lcAA==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "darwin" + ] + }, + "node_modules/@rollup/rollup-darwin-x64": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-darwin-x64/-/rollup-darwin-x64-4.40.1.tgz", + "integrity": "sha512-nIwkXafAI1/QCS7pxSpv/ZtFW6TXcNUEHAIA9EIyw5OzxJZQ1YDrX+CL6JAIQgZ33CInl1R6mHet9Y/UZTg2Bw==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "darwin" + ] + }, + "node_modules/@rollup/rollup-freebsd-arm64": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-freebsd-arm64/-/rollup-freebsd-arm64-4.40.1.tgz", + "integrity": "sha512-BdrLJ2mHTrIYdaS2I99mriyJfGGenSaP+UwGi1kB9BLOCu9SR8ZpbkmmalKIALnRw24kM7qCN0IOm6L0S44iWw==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "freebsd" + ] + }, + "node_modules/@rollup/rollup-freebsd-x64": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-freebsd-x64/-/rollup-freebsd-x64-4.40.1.tgz", + "integrity": "sha512-VXeo/puqvCG8JBPNZXZf5Dqq7BzElNJzHRRw3vjBE27WujdzuOPecDPc/+1DcdcTptNBep3861jNq0mYkT8Z6Q==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "freebsd" + ] + }, + "node_modules/@rollup/rollup-linux-arm-gnueabihf": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm-gnueabihf/-/rollup-linux-arm-gnueabihf-4.40.1.tgz", + "integrity": "sha512-ehSKrewwsESPt1TgSE/na9nIhWCosfGSFqv7vwEtjyAqZcvbGIg4JAcV7ZEh2tfj/IlfBeZjgOXm35iOOjadcg==", + "cpu": [ + "arm" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/rollup-linux-arm-musleabihf": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm-musleabihf/-/rollup-linux-arm-musleabihf-4.40.1.tgz", + "integrity": "sha512-m39iO/aaurh5FVIu/F4/Zsl8xppd76S4qoID8E+dSRQvTyZTOI2gVk3T4oqzfq1PtcvOfAVlwLMK3KRQMaR8lg==", + "cpu": [ + "arm" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/rollup-linux-arm64-gnu": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm64-gnu/-/rollup-linux-arm64-gnu-4.40.1.tgz", + "integrity": "sha512-Y+GHnGaku4aVLSgrT0uWe2o2Rq8te9hi+MwqGF9r9ORgXhmHK5Q71N757u0F8yU1OIwUIFy6YiJtKjtyktk5hg==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/rollup-linux-arm64-musl": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm64-musl/-/rollup-linux-arm64-musl-4.40.1.tgz", + "integrity": "sha512-jEwjn3jCA+tQGswK3aEWcD09/7M5wGwc6+flhva7dsQNRZZTe30vkalgIzV4tjkopsTS9Jd7Y1Bsj6a4lzz8gQ==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/rollup-linux-loongarch64-gnu": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-loongarch64-gnu/-/rollup-linux-loongarch64-gnu-4.40.1.tgz", + "integrity": "sha512-ySyWikVhNzv+BV/IDCsrraOAZ3UaC8SZB67FZlqVwXwnFhPihOso9rPOxzZbjp81suB1O2Topw+6Ug3JNegejQ==", + "cpu": [ + "loong64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/rollup-linux-powerpc64le-gnu": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-powerpc64le-gnu/-/rollup-linux-powerpc64le-gnu-4.40.1.tgz", + "integrity": "sha512-BvvA64QxZlh7WZWqDPPdt0GH4bznuL6uOO1pmgPnnv86rpUpc8ZxgZwcEgXvo02GRIZX1hQ0j0pAnhwkhwPqWg==", + "cpu": [ + "ppc64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/rollup-linux-riscv64-gnu": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-riscv64-gnu/-/rollup-linux-riscv64-gnu-4.40.1.tgz", + "integrity": "sha512-EQSP+8+1VuSulm9RKSMKitTav89fKbHymTf25n5+Yr6gAPZxYWpj3DzAsQqoaHAk9YX2lwEyAf9S4W8F4l3VBQ==", + "cpu": [ + "riscv64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/rollup-linux-riscv64-musl": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-riscv64-musl/-/rollup-linux-riscv64-musl-4.40.1.tgz", + "integrity": "sha512-n/vQ4xRZXKuIpqukkMXZt9RWdl+2zgGNx7Uda8NtmLJ06NL8jiHxUawbwC+hdSq1rrw/9CghCpEONor+l1e2gA==", + "cpu": [ + "riscv64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/rollup-linux-s390x-gnu": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-s390x-gnu/-/rollup-linux-s390x-gnu-4.40.1.tgz", + "integrity": "sha512-h8d28xzYb98fMQKUz0w2fMc1XuGzLLjdyxVIbhbil4ELfk5/orZlSTpF/xdI9C8K0I8lCkq+1En2RJsawZekkg==", + "cpu": [ + "s390x" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/rollup-linux-x64-gnu": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-x64-gnu/-/rollup-linux-x64-gnu-4.40.1.tgz", + "integrity": "sha512-XiK5z70PEFEFqcNj3/zRSz/qX4bp4QIraTy9QjwJAb/Z8GM7kVUsD0Uk8maIPeTyPCP03ChdI+VVmJriKYbRHQ==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/rollup-linux-x64-musl": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-x64-musl/-/rollup-linux-x64-musl-4.40.1.tgz", + "integrity": "sha512-2BRORitq5rQ4Da9blVovzNCMaUlyKrzMSvkVR0D4qPuOy/+pMCrh1d7o01RATwVy+6Fa1WBw+da7QPeLWU/1mQ==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/rollup-win32-arm64-msvc": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-arm64-msvc/-/rollup-win32-arm64-msvc-4.40.1.tgz", + "integrity": "sha512-b2bcNm9Kbde03H+q+Jjw9tSfhYkzrDUf2d5MAd1bOJuVplXvFhWz7tRtWvD8/ORZi7qSCy0idW6tf2HgxSXQSg==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "win32" + ] + }, + "node_modules/@rollup/rollup-win32-ia32-msvc": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-ia32-msvc/-/rollup-win32-ia32-msvc-4.40.1.tgz", + "integrity": "sha512-DfcogW8N7Zg7llVEfpqWMZcaErKfsj9VvmfSyRjCyo4BI3wPEfrzTtJkZG6gKP/Z92wFm6rz2aDO7/JfiR/whA==", + "cpu": [ + "ia32" + ], + "dev": true, + "optional": true, + "os": [ + "win32" + ] + }, + "node_modules/@rollup/rollup-win32-x64-msvc": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-x64-msvc/-/rollup-win32-x64-msvc-4.40.1.tgz", + "integrity": "sha512-ECyOuDeH3C1I8jH2MK1RtBJW+YPMvSfT0a5NN0nHfQYnDSJ6tUiZH3gzwVP5/Kfh/+Tt7tpWVF9LXNTnhTJ3kA==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "win32" + ] + }, + "node_modules/@tweenjs/tween.js": { + "version": "23.1.3", + "resolved": "https://registry.npmjs.org/@tweenjs/tween.js/-/tween.js-23.1.3.tgz", + "integrity": "sha512-vJmvvwFxYuGnF2axRtPYocag6Clbb5YS7kLL+SO/TeVFzHqDIWrNKYtcsPMibjDx9O+bu+psAy9NKfWklassUA==", + "dev": true, + "license": "MIT" + }, + "node_modules/@types/estree": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/@types/estree/-/estree-1.0.7.tgz", + "integrity": "sha512-w28IoSUCJpidD/TGviZwwMJckNESJZXFu7NBZ5YJ4mEUnNraUn9Pm8HSZm/jDF1pDWYKspWE7oVphigUPRakIQ==", + "dev": true + }, + "node_modules/@types/stats.js": { + "version": "0.17.4", + "resolved": "https://registry.npmjs.org/@types/stats.js/-/stats.js-0.17.4.tgz", + "integrity": "sha512-jIBvWWShCvlBqBNIZt0KAshWpvSjhkwkEu4ZUcASoAvhmrgAUI2t1dXrjSL4xXVLB4FznPrIsX3nKXFl/Dt4vA==", + "dev": true, + "license": "MIT" + }, + "node_modules/@types/three": { + "version": "0.182.0", + "resolved": "https://registry.npmjs.org/@types/three/-/three-0.182.0.tgz", + "integrity": "sha512-WByN9V3Sbwbe2OkWuSGyoqQO8Du6yhYaXtXLoA5FkKTUJorZ+yOHBZ35zUUPQXlAKABZmbYp5oAqpA4RBjtJ/Q==", + "dev": true, + "license": "MIT", + "dependencies": { + "@dimforge/rapier3d-compat": "~0.12.0", + "@tweenjs/tween.js": "~23.1.3", + "@types/stats.js": "*", + "@types/webxr": ">=0.5.17", + "@webgpu/types": "*", + "fflate": "~0.8.2", + "meshoptimizer": "~0.22.0" + } + }, + "node_modules/@types/three/node_modules/fflate": { + "version": "0.8.2", + "resolved": "https://registry.npmjs.org/fflate/-/fflate-0.8.2.tgz", + "integrity": "sha512-cPJU47OaAoCbg0pBvzsgpTPhmhqI5eJjh/JIu8tPj5q+T7iLvW/JAYUqmE7KOB4R1ZyEhzBaIQpQpardBF5z8A==", + "dev": true, + "license": "MIT" + }, + "node_modules/@types/webxr": { + "version": "0.5.24", + "resolved": "https://registry.npmjs.org/@types/webxr/-/webxr-0.5.24.tgz", + "integrity": "sha512-h8fgEd/DpoS9CBrjEQXR+dIDraopAEfu4wYVNY2tEPwk60stPWhvZMf4Foo5FakuQ7HFZoa8WceaWFervK2Ovg==", + "dev": true, + "license": "MIT" + }, + "node_modules/@webgpu/types": { + "version": "0.1.68", + "resolved": "https://registry.npmjs.org/@webgpu/types/-/types-0.1.68.tgz", + "integrity": "sha512-3ab1B59Ojb6RwjOspYLsTpCzbNB3ZaamIAxBMmvnNkiDoLTZUOBXZ9p5nAYVEkQlDdf6qAZWi1pqj9+ypiqznA==", + "dev": true, + "license": "BSD-3-Clause" + }, + "node_modules/esbuild": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/esbuild/-/esbuild-0.25.3.tgz", + "integrity": "sha512-qKA6Pvai73+M2FtftpNKRxJ78GIjmFXFxd/1DVBqGo/qNhLSfv+G12n9pNoWdytJC8U00TrViOwpjT0zgqQS8Q==", + "dev": true, + "hasInstallScript": true, + "bin": { + "esbuild": "bin/esbuild" + }, + "engines": { + "node": ">=18" + }, + "optionalDependencies": { + "@esbuild/aix-ppc64": "0.25.3", + "@esbuild/android-arm": "0.25.3", + "@esbuild/android-arm64": "0.25.3", + "@esbuild/android-x64": "0.25.3", + "@esbuild/darwin-arm64": "0.25.3", + "@esbuild/darwin-x64": "0.25.3", + "@esbuild/freebsd-arm64": "0.25.3", + "@esbuild/freebsd-x64": "0.25.3", + "@esbuild/linux-arm": "0.25.3", + "@esbuild/linux-arm64": "0.25.3", + "@esbuild/linux-ia32": "0.25.3", + "@esbuild/linux-loong64": "0.25.3", + "@esbuild/linux-mips64el": "0.25.3", + "@esbuild/linux-ppc64": "0.25.3", + "@esbuild/linux-riscv64": "0.25.3", + "@esbuild/linux-s390x": "0.25.3", + "@esbuild/linux-x64": "0.25.3", + "@esbuild/netbsd-arm64": "0.25.3", + "@esbuild/netbsd-x64": "0.25.3", + "@esbuild/openbsd-arm64": "0.25.3", + "@esbuild/openbsd-x64": "0.25.3", + "@esbuild/sunos-x64": "0.25.3", + "@esbuild/win32-arm64": "0.25.3", + "@esbuild/win32-ia32": "0.25.3", + "@esbuild/win32-x64": "0.25.3" + } + }, + "node_modules/fdir": { + "version": "6.4.4", + "resolved": "https://registry.npmjs.org/fdir/-/fdir-6.4.4.tgz", + "integrity": "sha512-1NZP+GK4GfuAv3PqKvxQRDMjdSRZjnkq7KfhlNrCNNlZ0ygQFpebfrnfnq/W7fpUnAv9aGWmY1zKx7FYL3gwhg==", + "dev": true, + "peerDependencies": { + "picomatch": "^3 || ^4" + }, + "peerDependenciesMeta": { + "picomatch": { + "optional": true + } + } + }, + "node_modules/fsevents": { + "version": "2.3.3", + "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.3.tgz", + "integrity": "sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw==", + "dev": true, + "hasInstallScript": true, + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": "^8.16.0 || ^10.6.0 || >=11.0.0" + } + }, + "node_modules/lil-gui": { + "version": "0.20.0", + "resolved": "https://registry.npmjs.org/lil-gui/-/lil-gui-0.20.0.tgz", + "integrity": "sha512-k7Ipr0ztqslMA2XvM5z5ZaWhxQtnEOwJBfI/hmSuRh6q4iMG9L0boqqrnZSzBR1jzyJ28OMl47l65ILzRe1TdA==", + "license": "MIT" + }, + "node_modules/meshoptimizer": { + "version": "0.22.0", + "resolved": "https://registry.npmjs.org/meshoptimizer/-/meshoptimizer-0.22.0.tgz", + "integrity": "sha512-IebiK79sqIy+E4EgOr+CAw+Ke8hAspXKzBd0JdgEmPHiAwmvEj2S4h1rfvo+o/BnfEYd/jAOg5IeeIjzlzSnDg==", + "dev": true, + "license": "MIT" + }, + "node_modules/nanoid": { + "version": "3.3.11", + "resolved": "https://registry.npmjs.org/nanoid/-/nanoid-3.3.11.tgz", + "integrity": "sha512-N8SpfPUnUp1bK+PMYW8qSWdl9U+wwNWI4QKxOYDy9JAro3WMX7p2OeVRF9v+347pnakNevPmiHhNmZ2HbFA76w==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/ai" + } + ], + "bin": { + "nanoid": "bin/nanoid.cjs" + }, + "engines": { + "node": "^10 || ^12 || ^13.7 || ^14 || >=15.0.1" + } + }, + "node_modules/picocolors": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.1.1.tgz", + "integrity": "sha512-xceH2snhtb5M9liqDsmEw56le376mTZkEX/jEb/RxNFyegNul7eNslCXP9FDj/Lcu0X8KEyMceP2ntpaHrDEVA==", + "dev": true + }, + "node_modules/picomatch": { + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.2.tgz", + "integrity": "sha512-M7BAV6Rlcy5u+m6oPhAPFgJTzAioX/6B0DxyvDlo9l8+T3nLKbrczg2WLUyzd45L8RqfUMyGPzekbMvX2Ldkwg==", + "dev": true, + "engines": { + "node": ">=12" + }, + "funding": { + "url": "https://github.com/sponsors/jonschlinkert" + } + }, + "node_modules/postcss": { + "version": "8.5.3", + "resolved": "https://registry.npmjs.org/postcss/-/postcss-8.5.3.tgz", + "integrity": "sha512-dle9A3yYxlBSrt8Fu+IpjGT8SY8hN0mlaA6GY8t0P5PjIOZemULz/E2Bnm/2dcUOena75OTNkHI76uZBNUUq3A==", + "dev": true, + "funding": [ + { + "type": "opencollective", + "url": "https://opencollective.com/postcss/" + }, + { + "type": "tidelift", + "url": "https://tidelift.com/funding/github/npm/postcss" + }, + { + "type": "github", + "url": "https://github.com/sponsors/ai" + } + ], + "dependencies": { + "nanoid": "^3.3.8", + "picocolors": "^1.1.1", + "source-map-js": "^1.2.1" + }, + "engines": { + "node": "^10 || ^12 || >=14" + } + }, + "node_modules/rollup": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/rollup/-/rollup-4.40.1.tgz", + "integrity": "sha512-C5VvvgCCyfyotVITIAv+4efVytl5F7wt+/I2i9q9GZcEXW9BP52YYOXC58igUi+LFZVHukErIIqQSWwv/M3WRw==", + "dev": true, + "dependencies": { + "@types/estree": "1.0.7" + }, + "bin": { + "rollup": "dist/bin/rollup" + }, + "engines": { + "node": ">=18.0.0", + "npm": ">=8.0.0" + }, + "optionalDependencies": { + "@rollup/rollup-android-arm-eabi": "4.40.1", + "@rollup/rollup-android-arm64": "4.40.1", + "@rollup/rollup-darwin-arm64": "4.40.1", + "@rollup/rollup-darwin-x64": "4.40.1", + "@rollup/rollup-freebsd-arm64": "4.40.1", + "@rollup/rollup-freebsd-x64": "4.40.1", + "@rollup/rollup-linux-arm-gnueabihf": "4.40.1", + "@rollup/rollup-linux-arm-musleabihf": "4.40.1", + "@rollup/rollup-linux-arm64-gnu": "4.40.1", + "@rollup/rollup-linux-arm64-musl": "4.40.1", + "@rollup/rollup-linux-loongarch64-gnu": "4.40.1", + "@rollup/rollup-linux-powerpc64le-gnu": "4.40.1", + "@rollup/rollup-linux-riscv64-gnu": "4.40.1", + "@rollup/rollup-linux-riscv64-musl": "4.40.1", + "@rollup/rollup-linux-s390x-gnu": "4.40.1", + "@rollup/rollup-linux-x64-gnu": "4.40.1", + "@rollup/rollup-linux-x64-musl": "4.40.1", + "@rollup/rollup-win32-arm64-msvc": "4.40.1", + "@rollup/rollup-win32-ia32-msvc": "4.40.1", + "@rollup/rollup-win32-x64-msvc": "4.40.1", + "fsevents": "~2.3.2" + } + }, + "node_modules/source-map-js": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/source-map-js/-/source-map-js-1.2.1.tgz", + "integrity": "sha512-UXWMKhLOwVKb728IUtQPXxfYU+usdybtUrK/8uGE8CQMvrhOpwvzDBwj0QhSL7MQc7vIsISBG8VQ8+IDQxpfQA==", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/three": { + "version": "0.182.0", + "resolved": "https://registry.npmjs.org/three/-/three-0.182.0.tgz", + "integrity": "sha512-GbHabT+Irv+ihI1/f5kIIsZ+Ef9Sl5A1Y7imvS5RQjWgtTPfPnZ43JmlYI7NtCRDK9zir20lQpfg8/9Yd02OvQ==", + "license": "MIT" + }, + "node_modules/tinyglobby": { + "version": "0.2.13", + "resolved": "https://registry.npmjs.org/tinyglobby/-/tinyglobby-0.2.13.tgz", + "integrity": "sha512-mEwzpUgrLySlveBwEVDMKk5B57bhLPYovRfPAXD5gA/98Opn0rCDj3GtLwFvCvH5RK9uPCExUROW5NjDwvqkxw==", + "dev": true, + "dependencies": { + "fdir": "^6.4.4", + "picomatch": "^4.0.2" + }, + "engines": { + "node": ">=12.0.0" + }, + "funding": { + "url": "https://github.com/sponsors/SuperchupuDev" + } + }, + "node_modules/typescript": { + "version": "5.8.3", + "resolved": "https://registry.npmjs.org/typescript/-/typescript-5.8.3.tgz", + "integrity": "sha512-p1diW6TqL9L07nNxvRMM7hMMw4c5XOo/1ibL4aAIGmSAt9slTE1Xgw5KWuof2uTOvCg9BY7ZRi+GaF+7sfgPeQ==", + "dev": true, + "bin": { + "tsc": "bin/tsc", + "tsserver": "bin/tsserver" + }, + "engines": { + "node": ">=14.17" + } + }, + "node_modules/vite": { + "version": "6.3.4", + "resolved": "https://registry.npmjs.org/vite/-/vite-6.3.4.tgz", + "integrity": "sha512-BiReIiMS2fyFqbqNT/Qqt4CVITDU9M9vE+DKcVAsB+ZV0wvTKd+3hMbkpxz1b+NmEDMegpVbisKiAZOnvO92Sw==", + "dev": true, + "dependencies": { + "esbuild": "^0.25.0", + "fdir": "^6.4.4", + "picomatch": "^4.0.2", + "postcss": "^8.5.3", + "rollup": "^4.34.9", + "tinyglobby": "^0.2.13" + }, + "bin": { + "vite": "bin/vite.js" + }, + "engines": { + "node": "^18.0.0 || ^20.0.0 || >=22.0.0" + }, + "funding": { + "url": "https://github.com/vitejs/vite?sponsor=1" + }, + "optionalDependencies": { + "fsevents": "~2.3.3" + }, + "peerDependencies": { + "@types/node": "^18.0.0 || ^20.0.0 || >=22.0.0", + "jiti": ">=1.21.0", + "less": "*", + "lightningcss": "^1.21.0", + "sass": "*", + "sass-embedded": "*", + "stylus": "*", + "sugarss": "*", + "terser": "^5.16.0", + "tsx": "^4.8.1", + "yaml": "^2.4.2" + }, + "peerDependenciesMeta": { + "@types/node": { + "optional": true + }, + "jiti": { + "optional": true + }, + "less": { + "optional": true + }, + "lightningcss": { + "optional": true + }, + "sass": { + "optional": true + }, + "sass-embedded": { + "optional": true + }, + "stylus": { + "optional": true + }, + "sugarss": { + "optional": true + }, + "terser": { + "optional": true + }, + "tsx": { + "optional": true + }, + "yaml": { + "optional": true + } + } + } + }, + "dependencies": { + "@dimforge/rapier3d-compat": { + "version": "0.12.0", + "resolved": "https://registry.npmjs.org/@dimforge/rapier3d-compat/-/rapier3d-compat-0.12.0.tgz", + "integrity": "sha512-uekIGetywIgopfD97oDL5PfeezkFpNhwlzlaEYNOA0N6ghdsOvh/HYjSMek5Q2O1PYvRSDFcqFVJl4r4ZBwOow==", + "dev": true + }, + "@esbuild/aix-ppc64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/aix-ppc64/-/aix-ppc64-0.25.3.tgz", + "integrity": "sha512-W8bFfPA8DowP8l//sxjJLSLkD8iEjMc7cBVyP+u4cEv9sM7mdUCkgsj+t0n/BWPFtv7WWCN5Yzj0N6FJNUUqBQ==", + "dev": true, + "optional": true + }, + "@esbuild/android-arm": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/android-arm/-/android-arm-0.25.3.tgz", + "integrity": "sha512-PuwVXbnP87Tcff5I9ngV0lmiSu40xw1At6i3GsU77U7cjDDB4s0X2cyFuBiDa1SBk9DnvWwnGvVaGBqoFWPb7A==", + "dev": true, + "optional": true + }, + "@esbuild/android-arm64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/android-arm64/-/android-arm64-0.25.3.tgz", + "integrity": "sha512-XelR6MzjlZuBM4f5z2IQHK6LkK34Cvv6Rj2EntER3lwCBFdg6h2lKbtRjpTTsdEjD/WSe1q8UyPBXP1x3i/wYQ==", + "dev": true, + "optional": true + }, + "@esbuild/android-x64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/android-x64/-/android-x64-0.25.3.tgz", + "integrity": "sha512-ogtTpYHT/g1GWS/zKM0cc/tIebFjm1F9Aw1boQ2Y0eUQ+J89d0jFY//s9ei9jVIlkYi8AfOjiixcLJSGNSOAdQ==", + "dev": true, + "optional": true + }, + "@esbuild/darwin-arm64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/darwin-arm64/-/darwin-arm64-0.25.3.tgz", + "integrity": "sha512-eESK5yfPNTqpAmDfFWNsOhmIOaQA59tAcF/EfYvo5/QWQCzXn5iUSOnqt3ra3UdzBv073ykTtmeLJZGt3HhA+w==", + "dev": true, + "optional": true + }, + "@esbuild/darwin-x64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/darwin-x64/-/darwin-x64-0.25.3.tgz", + "integrity": "sha512-Kd8glo7sIZtwOLcPbW0yLpKmBNWMANZhrC1r6K++uDR2zyzb6AeOYtI6udbtabmQpFaxJ8uduXMAo1gs5ozz8A==", + "dev": true, + "optional": true + }, + "@esbuild/freebsd-arm64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/freebsd-arm64/-/freebsd-arm64-0.25.3.tgz", + "integrity": "sha512-EJiyS70BYybOBpJth3M0KLOus0n+RRMKTYzhYhFeMwp7e/RaajXvP+BWlmEXNk6uk+KAu46j/kaQzr6au+JcIw==", + "dev": true, + "optional": true + }, + "@esbuild/freebsd-x64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/freebsd-x64/-/freebsd-x64-0.25.3.tgz", + "integrity": "sha512-Q+wSjaLpGxYf7zC0kL0nDlhsfuFkoN+EXrx2KSB33RhinWzejOd6AvgmP5JbkgXKmjhmpfgKZq24pneodYqE8Q==", + "dev": true, + "optional": true + }, + "@esbuild/linux-arm": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/linux-arm/-/linux-arm-0.25.3.tgz", + "integrity": "sha512-dUOVmAUzuHy2ZOKIHIKHCm58HKzFqd+puLaS424h6I85GlSDRZIA5ycBixb3mFgM0Jdh+ZOSB6KptX30DD8YOQ==", + "dev": true, + "optional": true + }, + "@esbuild/linux-arm64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/linux-arm64/-/linux-arm64-0.25.3.tgz", + "integrity": "sha512-xCUgnNYhRD5bb1C1nqrDV1PfkwgbswTTBRbAd8aH5PhYzikdf/ddtsYyMXFfGSsb/6t6QaPSzxtbfAZr9uox4A==", + "dev": true, + "optional": true + }, + "@esbuild/linux-ia32": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/linux-ia32/-/linux-ia32-0.25.3.tgz", + "integrity": "sha512-yplPOpczHOO4jTYKmuYuANI3WhvIPSVANGcNUeMlxH4twz/TeXuzEP41tGKNGWJjuMhotpGabeFYGAOU2ummBw==", + "dev": true, + "optional": true + }, + "@esbuild/linux-loong64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/linux-loong64/-/linux-loong64-0.25.3.tgz", + "integrity": "sha512-P4BLP5/fjyihmXCELRGrLd793q/lBtKMQl8ARGpDxgzgIKJDRJ/u4r1A/HgpBpKpKZelGct2PGI4T+axcedf6g==", + "dev": true, + "optional": true + }, + "@esbuild/linux-mips64el": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/linux-mips64el/-/linux-mips64el-0.25.3.tgz", + "integrity": "sha512-eRAOV2ODpu6P5divMEMa26RRqb2yUoYsuQQOuFUexUoQndm4MdpXXDBbUoKIc0iPa4aCO7gIhtnYomkn2x+bag==", + "dev": true, + "optional": true + }, + "@esbuild/linux-ppc64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/linux-ppc64/-/linux-ppc64-0.25.3.tgz", + "integrity": "sha512-ZC4jV2p7VbzTlnl8nZKLcBkfzIf4Yad1SJM4ZMKYnJqZFD4rTI+pBG65u8ev4jk3/MPwY9DvGn50wi3uhdaghg==", + "dev": true, + "optional": true + }, + "@esbuild/linux-riscv64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/linux-riscv64/-/linux-riscv64-0.25.3.tgz", + "integrity": "sha512-LDDODcFzNtECTrUUbVCs6j9/bDVqy7DDRsuIXJg6so+mFksgwG7ZVnTruYi5V+z3eE5y+BJZw7VvUadkbfg7QA==", + "dev": true, + "optional": true + }, + "@esbuild/linux-s390x": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/linux-s390x/-/linux-s390x-0.25.3.tgz", + "integrity": "sha512-s+w/NOY2k0yC2p9SLen+ymflgcpRkvwwa02fqmAwhBRI3SC12uiS10edHHXlVWwfAagYSY5UpmT/zISXPMW3tQ==", + "dev": true, + "optional": true + }, + "@esbuild/linux-x64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/linux-x64/-/linux-x64-0.25.3.tgz", + "integrity": "sha512-nQHDz4pXjSDC6UfOE1Fw9Q8d6GCAd9KdvMZpfVGWSJztYCarRgSDfOVBY5xwhQXseiyxapkiSJi/5/ja8mRFFA==", + "dev": true, + "optional": true + }, + "@esbuild/netbsd-arm64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/netbsd-arm64/-/netbsd-arm64-0.25.3.tgz", + "integrity": "sha512-1QaLtOWq0mzK6tzzp0jRN3eccmN3hezey7mhLnzC6oNlJoUJz4nym5ZD7mDnS/LZQgkrhEbEiTn515lPeLpgWA==", + "dev": true, + "optional": true + }, + "@esbuild/netbsd-x64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/netbsd-x64/-/netbsd-x64-0.25.3.tgz", + "integrity": "sha512-i5Hm68HXHdgv8wkrt+10Bc50zM0/eonPb/a/OFVfB6Qvpiirco5gBA5bz7S2SHuU+Y4LWn/zehzNX14Sp4r27g==", + "dev": true, + "optional": true + }, + "@esbuild/openbsd-arm64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/openbsd-arm64/-/openbsd-arm64-0.25.3.tgz", + "integrity": "sha512-zGAVApJEYTbOC6H/3QBr2mq3upG/LBEXr85/pTtKiv2IXcgKV0RT0QA/hSXZqSvLEpXeIxah7LczB4lkiYhTAQ==", + "dev": true, + "optional": true + }, + "@esbuild/openbsd-x64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/openbsd-x64/-/openbsd-x64-0.25.3.tgz", + "integrity": "sha512-fpqctI45NnCIDKBH5AXQBsD0NDPbEFczK98hk/aa6HJxbl+UtLkJV2+Bvy5hLSLk3LHmqt0NTkKNso1A9y1a4w==", + "dev": true, + "optional": true + }, + "@esbuild/sunos-x64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/sunos-x64/-/sunos-x64-0.25.3.tgz", + "integrity": "sha512-ROJhm7d8bk9dMCUZjkS8fgzsPAZEjtRJqCAmVgB0gMrvG7hfmPmz9k1rwO4jSiblFjYmNvbECL9uhaPzONMfgA==", + "dev": true, + "optional": true + }, + "@esbuild/win32-arm64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/win32-arm64/-/win32-arm64-0.25.3.tgz", + "integrity": "sha512-YWcow8peiHpNBiIXHwaswPnAXLsLVygFwCB3A7Bh5jRkIBFWHGmNQ48AlX4xDvQNoMZlPYzjVOQDYEzWCqufMQ==", + "dev": true, + "optional": true + }, + "@esbuild/win32-ia32": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/win32-ia32/-/win32-ia32-0.25.3.tgz", + "integrity": "sha512-qspTZOIGoXVS4DpNqUYUs9UxVb04khS1Degaw/MnfMe7goQ3lTfQ13Vw4qY/Nj0979BGvMRpAYbs/BAxEvU8ew==", + "dev": true, + "optional": true + }, + "@esbuild/win32-x64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/win32-x64/-/win32-x64-0.25.3.tgz", + "integrity": "sha512-ICgUR+kPimx0vvRzf+N/7L7tVSQeE3BYY+NhHRHXS1kBuPO7z2+7ea2HbhDyZdTephgvNvKrlDDKUexuCVBVvg==", + "dev": true, + "optional": true + }, + "@rollup/rollup-android-arm-eabi": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-android-arm-eabi/-/rollup-android-arm-eabi-4.40.1.tgz", + "integrity": "sha512-kxz0YeeCrRUHz3zyqvd7n+TVRlNyTifBsmnmNPtk3hQURUyG9eAB+usz6DAwagMusjx/zb3AjvDUvhFGDAexGw==", + "dev": true, + "optional": true + }, + "@rollup/rollup-android-arm64": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-android-arm64/-/rollup-android-arm64-4.40.1.tgz", + "integrity": "sha512-PPkxTOisoNC6TpnDKatjKkjRMsdaWIhyuMkA4UsBXT9WEZY4uHezBTjs6Vl4PbqQQeu6oION1w2voYZv9yquCw==", + "dev": true, + "optional": true + }, + "@rollup/rollup-darwin-arm64": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-darwin-arm64/-/rollup-darwin-arm64-4.40.1.tgz", + "integrity": "sha512-VWXGISWFY18v/0JyNUy4A46KCFCb9NVsH+1100XP31lud+TzlezBbz24CYzbnA4x6w4hx+NYCXDfnvDVO6lcAA==", + "dev": true, + "optional": true + }, + "@rollup/rollup-darwin-x64": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-darwin-x64/-/rollup-darwin-x64-4.40.1.tgz", + "integrity": "sha512-nIwkXafAI1/QCS7pxSpv/ZtFW6TXcNUEHAIA9EIyw5OzxJZQ1YDrX+CL6JAIQgZ33CInl1R6mHet9Y/UZTg2Bw==", + "dev": true, + "optional": true + }, + "@rollup/rollup-freebsd-arm64": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-freebsd-arm64/-/rollup-freebsd-arm64-4.40.1.tgz", + "integrity": "sha512-BdrLJ2mHTrIYdaS2I99mriyJfGGenSaP+UwGi1kB9BLOCu9SR8ZpbkmmalKIALnRw24kM7qCN0IOm6L0S44iWw==", + "dev": true, + "optional": true + }, + "@rollup/rollup-freebsd-x64": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-freebsd-x64/-/rollup-freebsd-x64-4.40.1.tgz", + "integrity": "sha512-VXeo/puqvCG8JBPNZXZf5Dqq7BzElNJzHRRw3vjBE27WujdzuOPecDPc/+1DcdcTptNBep3861jNq0mYkT8Z6Q==", + "dev": true, + "optional": true + }, + "@rollup/rollup-linux-arm-gnueabihf": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm-gnueabihf/-/rollup-linux-arm-gnueabihf-4.40.1.tgz", + "integrity": "sha512-ehSKrewwsESPt1TgSE/na9nIhWCosfGSFqv7vwEtjyAqZcvbGIg4JAcV7ZEh2tfj/IlfBeZjgOXm35iOOjadcg==", + "dev": true, + "optional": true + }, + "@rollup/rollup-linux-arm-musleabihf": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm-musleabihf/-/rollup-linux-arm-musleabihf-4.40.1.tgz", + "integrity": "sha512-m39iO/aaurh5FVIu/F4/Zsl8xppd76S4qoID8E+dSRQvTyZTOI2gVk3T4oqzfq1PtcvOfAVlwLMK3KRQMaR8lg==", + "dev": true, + "optional": true + }, + "@rollup/rollup-linux-arm64-gnu": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm64-gnu/-/rollup-linux-arm64-gnu-4.40.1.tgz", + "integrity": "sha512-Y+GHnGaku4aVLSgrT0uWe2o2Rq8te9hi+MwqGF9r9ORgXhmHK5Q71N757u0F8yU1OIwUIFy6YiJtKjtyktk5hg==", + "dev": true, + "optional": true + }, + "@rollup/rollup-linux-arm64-musl": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm64-musl/-/rollup-linux-arm64-musl-4.40.1.tgz", + "integrity": "sha512-jEwjn3jCA+tQGswK3aEWcD09/7M5wGwc6+flhva7dsQNRZZTe30vkalgIzV4tjkopsTS9Jd7Y1Bsj6a4lzz8gQ==", + "dev": true, + "optional": true + }, + "@rollup/rollup-linux-loongarch64-gnu": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-loongarch64-gnu/-/rollup-linux-loongarch64-gnu-4.40.1.tgz", + "integrity": "sha512-ySyWikVhNzv+BV/IDCsrraOAZ3UaC8SZB67FZlqVwXwnFhPihOso9rPOxzZbjp81suB1O2Topw+6Ug3JNegejQ==", + "dev": true, + "optional": true + }, + "@rollup/rollup-linux-powerpc64le-gnu": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-powerpc64le-gnu/-/rollup-linux-powerpc64le-gnu-4.40.1.tgz", + "integrity": "sha512-BvvA64QxZlh7WZWqDPPdt0GH4bznuL6uOO1pmgPnnv86rpUpc8ZxgZwcEgXvo02GRIZX1hQ0j0pAnhwkhwPqWg==", + "dev": true, + "optional": true + }, + "@rollup/rollup-linux-riscv64-gnu": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-riscv64-gnu/-/rollup-linux-riscv64-gnu-4.40.1.tgz", + "integrity": "sha512-EQSP+8+1VuSulm9RKSMKitTav89fKbHymTf25n5+Yr6gAPZxYWpj3DzAsQqoaHAk9YX2lwEyAf9S4W8F4l3VBQ==", + "dev": true, + "optional": true + }, + "@rollup/rollup-linux-riscv64-musl": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-riscv64-musl/-/rollup-linux-riscv64-musl-4.40.1.tgz", + "integrity": "sha512-n/vQ4xRZXKuIpqukkMXZt9RWdl+2zgGNx7Uda8NtmLJ06NL8jiHxUawbwC+hdSq1rrw/9CghCpEONor+l1e2gA==", + "dev": true, + "optional": true + }, + "@rollup/rollup-linux-s390x-gnu": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-s390x-gnu/-/rollup-linux-s390x-gnu-4.40.1.tgz", + "integrity": "sha512-h8d28xzYb98fMQKUz0w2fMc1XuGzLLjdyxVIbhbil4ELfk5/orZlSTpF/xdI9C8K0I8lCkq+1En2RJsawZekkg==", + "dev": true, + "optional": true + }, + "@rollup/rollup-linux-x64-gnu": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-x64-gnu/-/rollup-linux-x64-gnu-4.40.1.tgz", + "integrity": "sha512-XiK5z70PEFEFqcNj3/zRSz/qX4bp4QIraTy9QjwJAb/Z8GM7kVUsD0Uk8maIPeTyPCP03ChdI+VVmJriKYbRHQ==", + "dev": true, + "optional": true + }, + "@rollup/rollup-linux-x64-musl": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-x64-musl/-/rollup-linux-x64-musl-4.40.1.tgz", + "integrity": "sha512-2BRORitq5rQ4Da9blVovzNCMaUlyKrzMSvkVR0D4qPuOy/+pMCrh1d7o01RATwVy+6Fa1WBw+da7QPeLWU/1mQ==", + "dev": true, + "optional": true + }, + "@rollup/rollup-win32-arm64-msvc": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-arm64-msvc/-/rollup-win32-arm64-msvc-4.40.1.tgz", + "integrity": "sha512-b2bcNm9Kbde03H+q+Jjw9tSfhYkzrDUf2d5MAd1bOJuVplXvFhWz7tRtWvD8/ORZi7qSCy0idW6tf2HgxSXQSg==", + "dev": true, + "optional": true + }, + "@rollup/rollup-win32-ia32-msvc": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-ia32-msvc/-/rollup-win32-ia32-msvc-4.40.1.tgz", + "integrity": "sha512-DfcogW8N7Zg7llVEfpqWMZcaErKfsj9VvmfSyRjCyo4BI3wPEfrzTtJkZG6gKP/Z92wFm6rz2aDO7/JfiR/whA==", + "dev": true, + "optional": true + }, + "@rollup/rollup-win32-x64-msvc": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-x64-msvc/-/rollup-win32-x64-msvc-4.40.1.tgz", + "integrity": "sha512-ECyOuDeH3C1I8jH2MK1RtBJW+YPMvSfT0a5NN0nHfQYnDSJ6tUiZH3gzwVP5/Kfh/+Tt7tpWVF9LXNTnhTJ3kA==", + "dev": true, + "optional": true + }, + "@tweenjs/tween.js": { + "version": "23.1.3", + "resolved": "https://registry.npmjs.org/@tweenjs/tween.js/-/tween.js-23.1.3.tgz", + "integrity": "sha512-vJmvvwFxYuGnF2axRtPYocag6Clbb5YS7kLL+SO/TeVFzHqDIWrNKYtcsPMibjDx9O+bu+psAy9NKfWklassUA==", + "dev": true + }, + "@types/estree": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/@types/estree/-/estree-1.0.7.tgz", + "integrity": "sha512-w28IoSUCJpidD/TGviZwwMJckNESJZXFu7NBZ5YJ4mEUnNraUn9Pm8HSZm/jDF1pDWYKspWE7oVphigUPRakIQ==", + "dev": true + }, + "@types/stats.js": { + "version": "0.17.4", + "resolved": "https://registry.npmjs.org/@types/stats.js/-/stats.js-0.17.4.tgz", + "integrity": "sha512-jIBvWWShCvlBqBNIZt0KAshWpvSjhkwkEu4ZUcASoAvhmrgAUI2t1dXrjSL4xXVLB4FznPrIsX3nKXFl/Dt4vA==", + "dev": true + }, + "@types/three": { + "version": "0.182.0", + "resolved": "https://registry.npmjs.org/@types/three/-/three-0.182.0.tgz", + "integrity": "sha512-WByN9V3Sbwbe2OkWuSGyoqQO8Du6yhYaXtXLoA5FkKTUJorZ+yOHBZ35zUUPQXlAKABZmbYp5oAqpA4RBjtJ/Q==", + "dev": true, + "requires": { + "@dimforge/rapier3d-compat": "~0.12.0", + "@tweenjs/tween.js": "~23.1.3", + "@types/stats.js": "*", + "@types/webxr": ">=0.5.17", + "@webgpu/types": "*", + "fflate": "~0.8.2", + "meshoptimizer": "~0.22.0" + }, + "dependencies": { + "fflate": { + "version": "0.8.2", + "resolved": "https://registry.npmjs.org/fflate/-/fflate-0.8.2.tgz", + "integrity": "sha512-cPJU47OaAoCbg0pBvzsgpTPhmhqI5eJjh/JIu8tPj5q+T7iLvW/JAYUqmE7KOB4R1ZyEhzBaIQpQpardBF5z8A==", + "dev": true + } + } + }, + "@types/webxr": { + "version": "0.5.24", + "resolved": "https://registry.npmjs.org/@types/webxr/-/webxr-0.5.24.tgz", + "integrity": "sha512-h8fgEd/DpoS9CBrjEQXR+dIDraopAEfu4wYVNY2tEPwk60stPWhvZMf4Foo5FakuQ7HFZoa8WceaWFervK2Ovg==", + "dev": true + }, + "@webgpu/types": { + "version": "0.1.68", + "resolved": "https://registry.npmjs.org/@webgpu/types/-/types-0.1.68.tgz", + "integrity": "sha512-3ab1B59Ojb6RwjOspYLsTpCzbNB3ZaamIAxBMmvnNkiDoLTZUOBXZ9p5nAYVEkQlDdf6qAZWi1pqj9+ypiqznA==", + "dev": true + }, + "esbuild": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/esbuild/-/esbuild-0.25.3.tgz", + "integrity": "sha512-qKA6Pvai73+M2FtftpNKRxJ78GIjmFXFxd/1DVBqGo/qNhLSfv+G12n9pNoWdytJC8U00TrViOwpjT0zgqQS8Q==", + "dev": true, + "requires": { + "@esbuild/aix-ppc64": "0.25.3", + "@esbuild/android-arm": "0.25.3", + "@esbuild/android-arm64": "0.25.3", + "@esbuild/android-x64": "0.25.3", + "@esbuild/darwin-arm64": "0.25.3", + "@esbuild/darwin-x64": "0.25.3", + "@esbuild/freebsd-arm64": "0.25.3", + "@esbuild/freebsd-x64": "0.25.3", + "@esbuild/linux-arm": "0.25.3", + "@esbuild/linux-arm64": "0.25.3", + "@esbuild/linux-ia32": "0.25.3", + "@esbuild/linux-loong64": "0.25.3", + "@esbuild/linux-mips64el": "0.25.3", + "@esbuild/linux-ppc64": "0.25.3", + "@esbuild/linux-riscv64": "0.25.3", + "@esbuild/linux-s390x": "0.25.3", + "@esbuild/linux-x64": "0.25.3", + "@esbuild/netbsd-arm64": "0.25.3", + "@esbuild/netbsd-x64": "0.25.3", + "@esbuild/openbsd-arm64": "0.25.3", + "@esbuild/openbsd-x64": "0.25.3", + "@esbuild/sunos-x64": "0.25.3", + "@esbuild/win32-arm64": "0.25.3", + "@esbuild/win32-ia32": "0.25.3", + "@esbuild/win32-x64": "0.25.3" + } + }, + "fdir": { + "version": "6.4.4", + "resolved": "https://registry.npmjs.org/fdir/-/fdir-6.4.4.tgz", + "integrity": "sha512-1NZP+GK4GfuAv3PqKvxQRDMjdSRZjnkq7KfhlNrCNNlZ0ygQFpebfrnfnq/W7fpUnAv9aGWmY1zKx7FYL3gwhg==", + "dev": true, + "requires": {} + }, + "fsevents": { + "version": "2.3.3", + "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.3.tgz", + "integrity": "sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw==", + "dev": true, + "optional": true + }, + "lil-gui": { + "version": "0.20.0", + "resolved": "https://registry.npmjs.org/lil-gui/-/lil-gui-0.20.0.tgz", + "integrity": "sha512-k7Ipr0ztqslMA2XvM5z5ZaWhxQtnEOwJBfI/hmSuRh6q4iMG9L0boqqrnZSzBR1jzyJ28OMl47l65ILzRe1TdA==" + }, + "meshoptimizer": { + "version": "0.22.0", + "resolved": "https://registry.npmjs.org/meshoptimizer/-/meshoptimizer-0.22.0.tgz", + "integrity": "sha512-IebiK79sqIy+E4EgOr+CAw+Ke8hAspXKzBd0JdgEmPHiAwmvEj2S4h1rfvo+o/BnfEYd/jAOg5IeeIjzlzSnDg==", + "dev": true + }, + "nanoid": { + "version": "3.3.11", + "resolved": "https://registry.npmjs.org/nanoid/-/nanoid-3.3.11.tgz", + "integrity": "sha512-N8SpfPUnUp1bK+PMYW8qSWdl9U+wwNWI4QKxOYDy9JAro3WMX7p2OeVRF9v+347pnakNevPmiHhNmZ2HbFA76w==", + "dev": true + }, + "picocolors": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.1.1.tgz", + "integrity": "sha512-xceH2snhtb5M9liqDsmEw56le376mTZkEX/jEb/RxNFyegNul7eNslCXP9FDj/Lcu0X8KEyMceP2ntpaHrDEVA==", + "dev": true + }, + "picomatch": { + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.2.tgz", + "integrity": "sha512-M7BAV6Rlcy5u+m6oPhAPFgJTzAioX/6B0DxyvDlo9l8+T3nLKbrczg2WLUyzd45L8RqfUMyGPzekbMvX2Ldkwg==", + "dev": true + }, + "postcss": { + "version": "8.5.3", + "resolved": "https://registry.npmjs.org/postcss/-/postcss-8.5.3.tgz", + "integrity": "sha512-dle9A3yYxlBSrt8Fu+IpjGT8SY8hN0mlaA6GY8t0P5PjIOZemULz/E2Bnm/2dcUOena75OTNkHI76uZBNUUq3A==", + "dev": true, + "requires": { + "nanoid": "^3.3.8", + "picocolors": "^1.1.1", + "source-map-js": "^1.2.1" + } + }, + "rollup": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/rollup/-/rollup-4.40.1.tgz", + "integrity": "sha512-C5VvvgCCyfyotVITIAv+4efVytl5F7wt+/I2i9q9GZcEXW9BP52YYOXC58igUi+LFZVHukErIIqQSWwv/M3WRw==", + "dev": true, + "requires": { + "@rollup/rollup-android-arm-eabi": "4.40.1", + "@rollup/rollup-android-arm64": "4.40.1", + "@rollup/rollup-darwin-arm64": "4.40.1", + "@rollup/rollup-darwin-x64": "4.40.1", + "@rollup/rollup-freebsd-arm64": "4.40.1", + "@rollup/rollup-freebsd-x64": "4.40.1", + "@rollup/rollup-linux-arm-gnueabihf": "4.40.1", + "@rollup/rollup-linux-arm-musleabihf": "4.40.1", + "@rollup/rollup-linux-arm64-gnu": "4.40.1", + "@rollup/rollup-linux-arm64-musl": "4.40.1", + "@rollup/rollup-linux-loongarch64-gnu": "4.40.1", + "@rollup/rollup-linux-powerpc64le-gnu": "4.40.1", + "@rollup/rollup-linux-riscv64-gnu": "4.40.1", + "@rollup/rollup-linux-riscv64-musl": "4.40.1", + "@rollup/rollup-linux-s390x-gnu": "4.40.1", + "@rollup/rollup-linux-x64-gnu": "4.40.1", + "@rollup/rollup-linux-x64-musl": "4.40.1", + "@rollup/rollup-win32-arm64-msvc": "4.40.1", + "@rollup/rollup-win32-ia32-msvc": "4.40.1", + "@rollup/rollup-win32-x64-msvc": "4.40.1", + "@types/estree": "1.0.7", + "fsevents": "~2.3.2" + } + }, + "source-map-js": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/source-map-js/-/source-map-js-1.2.1.tgz", + "integrity": "sha512-UXWMKhLOwVKb728IUtQPXxfYU+usdybtUrK/8uGE8CQMvrhOpwvzDBwj0QhSL7MQc7vIsISBG8VQ8+IDQxpfQA==", + "dev": true + }, + "three": { + "version": "0.182.0", + "resolved": "https://registry.npmjs.org/three/-/three-0.182.0.tgz", + "integrity": "sha512-GbHabT+Irv+ihI1/f5kIIsZ+Ef9Sl5A1Y7imvS5RQjWgtTPfPnZ43JmlYI7NtCRDK9zir20lQpfg8/9Yd02OvQ==" + }, + "tinyglobby": { + "version": "0.2.13", + "resolved": "https://registry.npmjs.org/tinyglobby/-/tinyglobby-0.2.13.tgz", + "integrity": "sha512-mEwzpUgrLySlveBwEVDMKk5B57bhLPYovRfPAXD5gA/98Opn0rCDj3GtLwFvCvH5RK9uPCExUROW5NjDwvqkxw==", + "dev": true, + "requires": { + "fdir": "^6.4.4", + "picomatch": "^4.0.2" + } + }, + "typescript": { + "version": "5.8.3", + "resolved": "https://registry.npmjs.org/typescript/-/typescript-5.8.3.tgz", + "integrity": "sha512-p1diW6TqL9L07nNxvRMM7hMMw4c5XOo/1ibL4aAIGmSAt9slTE1Xgw5KWuof2uTOvCg9BY7ZRi+GaF+7sfgPeQ==", + "dev": true + }, + "vite": { + "version": "6.3.4", + "resolved": "https://registry.npmjs.org/vite/-/vite-6.3.4.tgz", + "integrity": "sha512-BiReIiMS2fyFqbqNT/Qqt4CVITDU9M9vE+DKcVAsB+ZV0wvTKd+3hMbkpxz1b+NmEDMegpVbisKiAZOnvO92Sw==", + "dev": true, + "requires": { + "esbuild": "^0.25.0", + "fdir": "^6.4.4", + "fsevents": "~2.3.3", + "picomatch": "^4.0.2", + "postcss": "^8.5.3", + "rollup": "^4.34.9", + "tinyglobby": "^0.2.13" + } + } + } +} diff --git a/examples/vite/threejs/runner-occt-bottle/package.json b/examples/vite/threejs/runner-occt-bottle/package.json new file mode 100644 index 00000000..6484c51e --- /dev/null +++ b/examples/vite/threejs/runner-occt-bottle/package.json @@ -0,0 +1,20 @@ +{ + "name": "vite-typescript-starter", + "private": true, + "version": "0.0.0", + "type": "module", + "scripts": { + "dev": "vite", + "build": "tsc && vite build", + "preview": "vite preview" + }, + "dependencies": { + "three": "0.182.0", + "lil-gui": "0.20.0" + }, + "devDependencies": { + "typescript": "~5.8.3", + "vite": "^6.3.2", + "@types/three": "0.182.0" + } +} diff --git a/examples/vite/threejs/runner-occt-bottle/public/vite.svg b/examples/vite/threejs/runner-occt-bottle/public/vite.svg new file mode 100644 index 00000000..e7b8dfb1 --- /dev/null +++ b/examples/vite/threejs/runner-occt-bottle/public/vite.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/examples/vite/threejs/runner-occt-bottle/src/helpers/init-threejs.ts b/examples/vite/threejs/runner-occt-bottle/src/helpers/init-threejs.ts new file mode 100644 index 00000000..6e0b9497 --- /dev/null +++ b/examples/vite/threejs/runner-occt-bottle/src/helpers/init-threejs.ts @@ -0,0 +1,108 @@ +import { + Color, + DirectionalLight, + Fog, + HemisphereLight, + Mesh, + MeshPhongMaterial, + PerspectiveCamera, + PlaneGeometry, + Scene, + VSMShadowMap, + WebGLRenderer, +} from "three"; +import { OrbitControls } from "three/examples/jsm/controls/OrbitControls.js"; + +export function initThreeJS(canvasId = "myCanvas") { + const domNode = document.getElementById(canvasId) as HTMLCanvasElement; + + const camera = new PerspectiveCamera( + 45, + window.innerWidth / window.innerHeight, + 0.1, + 200 + ); + const scene = new Scene(); + scene.background = new Color(0x1a1c1f); // Set background color + + scene.fog = new Fog(0x1a1c1f, 30, 80); + const light = new HemisphereLight(0xffffff, 0x444444, 2); // Adjusted intensity + scene.add(light); + + const renderer = new WebGLRenderer({ antialias: true, canvas: domNode }); + renderer.setSize(window.innerWidth, window.innerHeight); + renderer.setPixelRatio(window.devicePixelRatio); // Consider devicePixelRatio for sharpness + renderer.shadowMap.enabled = true; + renderer.shadowMap.type = VSMShadowMap; + + camera.position.set(15, 12, 15); + camera.aspect = window.innerWidth / window.innerHeight; + camera.near = 0.1; + camera.far = 200; + camera.updateProjectionMatrix(); + + const controls = new OrbitControls(camera, renderer.domElement); + controls.enableDamping = true; + controls.dampingFactor = 0.05; + controls.zoomSpeed = 0.5; + controls.target.set(0, 4, 0); + controls.update(); + + const onWindowResize = () => { + camera.aspect = window.innerWidth / window.innerHeight; + camera.updateProjectionMatrix(); + renderer.setSize(window.innerWidth, window.innerHeight); + }; + window.addEventListener("resize", onWindowResize, false); + + const animate = () => { + controls.update(); // Important for damping + renderer.render(scene, camera); + }; + renderer.setAnimationLoop(animate); + + createDirLightsAndGround(scene); + + return { scene, camera, renderer }; // Return renderer and camera if needed elsewhere +} + +function createDirLightsAndGround(scene: Scene) { + const dirLight = new DirectionalLight(0xffffff, 3); + dirLight.position.set(10, 15, 10); + dirLight.castShadow = true; + dirLight.shadow.camera.near = 0.5; + dirLight.shadow.camera.far = 50; + const dist = 15; + dirLight.shadow.camera.right = dist; + dirLight.shadow.camera.left = -dist; + dirLight.shadow.camera.top = dist; + dirLight.shadow.camera.bottom = -dist; + dirLight.shadow.mapSize.width = 1024; + dirLight.shadow.mapSize.height = 1024; + dirLight.shadow.blurSamples = 3; + dirLight.shadow.radius = 2; + dirLight.shadow.bias = -0.0005; + + scene?.add(dirLight); + + const dirLight2 = new DirectionalLight(0xffffff, 2); + dirLight2.position.set(-5, 10, -5); + dirLight2.shadow.camera.near = 0.5; + dirLight2.shadow.camera.far = 50; + dirLight2.shadow.camera.right = dist; + dirLight2.shadow.camera.left = -dist; + dirLight2.shadow.camera.top = dist; + dirLight2.shadow.camera.bottom = -dist; + + scene?.add(dirLight2); + + const material = new MeshPhongMaterial({ color: 0x444444 }); + material.shininess = 0; + material.specular = new Color(0x222222); + material.polygonOffset = true; + material.polygonOffsetFactor = 10; + const ground = new Mesh(new PlaneGeometry(50, 50, 1, 1), material); + ground.rotateX(-Math.PI / 2); + ground.receiveShadow = true; + scene?.add(ground); +} diff --git a/examples/vite/threejs/runner-occt-bottle/src/main.ts b/examples/vite/threejs/runner-occt-bottle/src/main.ts new file mode 100644 index 00000000..752b0708 --- /dev/null +++ b/examples/vite/threejs/runner-occt-bottle/src/main.ts @@ -0,0 +1,423 @@ +import "./style.css"; +import * as THREEJS from "three"; +import type { + BitByBitRunner, + RunOptionsInterface, +} from "./runner/runner-types"; +import { initThreeJS } from "./helpers/init-threejs"; +import * as lil from "lil-gui"; +import { loadRunnerScript } from "./runner/load-runner-script"; + +(window as any).THREEJS = THREEJS; + +// Dynamically load the runner script after THREE is available on window +loadRunnerScript().then(() => { + start(); +}); + +async function start() { + const { scene, camera, renderer } = initThreeJS(); + + const runnerOptions: RunOptionsInterface = { + canvasZoneClass: "myCanvasZone", + enableOCCT: true, + enableJSCAD: false, + enableManifold: false, + cameraPosition: [10, 10, 10], + cameraTarget: [0, 4, 0], + externalThreeJSSettings: { + scene, + camera, + renderer, + }, + backgroundColor: "#1a1c1f", + loadFonts: [], + }; + + const runner: BitByBitRunner = window.bitbybitRunner.getRunnerInstance(); + const { bitbybit, Bit } = await runner.run( + runnerOptions + ); + + // type short names + type Point3 = Bit.Inputs.Base.Point3; + type Point2 = Bit.Inputs.Base.Point2; + const dimensionEndTypeEnum = Bit.Inputs.OCCT.dimensionEndTypeEnum; + + // Model parameters + const model = { + width: 5, + height: 8, + thickness: 3, + color: "#ff00ff", + }; + + // Store current shape for downloading + let currentShape: Bit.Inputs.OCCT.TopoDSShapePointer | null = null; + + + // Track current model group for cleanup + let currentGroup: THREEJS.Group | null = null; + let currentDimensionsGroup: THREEJS.Group | null = null; + + // Download STEP file + async function downloadSTEP() { + if (!currentShape) return; + await bitbybit.occt.io.saveShapeSTEP({ + shape: currentShape, + fileName: "bottle.step", + adjustYtoZ: true, + tryDownload: true, + }); + } + + // Download STL file + async function downloadSTL() { + if (!currentShape) return; + await bitbybit.occt.io.saveShapeStl({ + shape: currentShape, + fileName: "bottle.stl", + precision: 0.001, + adjustYtoZ: true, + tryDownload: true, + binary: true, + }); + } + + async function createBottle( + width: number, + height: number, + thickness: number, + color: string + ) { + // Clean up previous model + if (currentGroup) { + scene.remove(currentGroup); + currentGroup = null; + } + if (currentDimensionsGroup) { + scene.remove(currentDimensionsGroup); + currentDimensionsGroup = null; + } + + const aPnt1 = [-width / 2, 0, 0] as Point3; + const aPnt2 = [-width / 2, 0, -thickness / 4] as Point3; + const aPnt3 = [0, 0, -thickness / 2] as Point3; + const aPnt4 = [width / 2, 0, -thickness / 4] as Point3; + const aPnt5 = [width / 2, 0, 0] as Point3; + + const anArc = await bitbybit.occt.shapes.edge.arcThroughThreePoints({ + start: aPnt2, + middle: aPnt3, + end: aPnt4, + }); + const edge1 = await bitbybit.occt.shapes.edge.line({ + start: aPnt1, + end: aPnt2, + }); + const edge2 = await bitbybit.occt.shapes.edge.line({ + start: aPnt4, + end: aPnt5, + }); + + const firstHalfWire = + await bitbybit.occt.shapes.wire.combineEdgesAndWiresIntoAWire({ + shapes: [edge1, anArc, edge2], + }); + + const direction = [1, 0, 0] as Point3; + const origin = [0, 0, 0] as Point3; + const secondHalfWire = await bitbybit.occt.transforms.mirror({ + direction, + origin, + shape: firstHalfWire, + }); + + const wire = await bitbybit.occt.shapes.wire.combineEdgesAndWiresIntoAWire({ + shapes: [firstHalfWire, secondHalfWire], + }); + + const aPrismVec = [0, height, 0] as Point3; + const face = await bitbybit.occt.shapes.face.createFaceFromWire({ + shape: wire, + planar: true, + }); + const extruded = await bitbybit.occt.operations.extrude({ + shape: face, + direction: aPrismVec, + }); + const appliedFillets = await bitbybit.occt.fillets.filletEdges({ + shape: extruded, + radius: thickness / 12, + }); + + const neckLocation = [0, height, 0] as Point3; + const neckRadius = thickness / 4; + const neckHeight = height / 10; + const neckAxis = [0, 1, 0] as Point3; + + const neck = await bitbybit.occt.shapes.solid.createCylinder({ + radius: neckRadius, + height: neckHeight, + center: neckLocation, + direction: neckAxis, + }); + + const unioned = await bitbybit.occt.booleans.union({ + shapes: [appliedFillets, neck], + keepEdges: false, + }); + + const faceToRemove = await bitbybit.occt.shapes.face.getFace({ + shape: unioned, + index: 27, + }); + + const thickOptions = new Bit.Inputs.OCCT.ThickSolidByJoinDto( + unioned, + [faceToRemove], + -thickness / 50 + ); + const thick = await bitbybit.occt.operations.makeThickSolidByJoin( + thickOptions + ); + + const geom = bitbybit.occt.geom; + + // Threading: Create Surfaces + const aCyl1 = await geom.surfaces.cylindricalSurface({ + direction: neckAxis, + radius: neckRadius * 0.99, + center: neckLocation, + }); + const aCyl2 = await geom.surfaces.cylindricalSurface({ + direction: neckAxis, + radius: neckRadius * 1.05, + center: neckLocation, + }); + + const aPnt = [2 * Math.PI, neckHeight / 2] as Point2; + const aDir = [2 * Math.PI, neckHeight / 4] as Point2; + const aMajor = 2 * Math.PI; + const aMinor = neckHeight / 10; + + const anEllipse1 = await geom.curves.geom2dEllipse({ + center: aPnt, + direction: aDir, + radiusMinor: aMinor, + radiusMajor: aMajor, + sense: true, + }); + const anEllipse2 = await geom.curves.geom2dEllipse({ + center: aPnt, + direction: aDir, + radiusMinor: aMinor / 4, + radiusMajor: aMajor, + sense: true, + }); + + const anArc1 = await geom.curves.geom2dTrimmedCurve({ + shape: anEllipse1, + u1: 0, + u2: Math.PI, + sense: true, + adjustPeriodic: true, + }); + const anArc2 = await geom.curves.geom2dTrimmedCurve({ + shape: anEllipse2, + u1: 0, + u2: Math.PI, + sense: true, + adjustPeriodic: true, + }); + + const anEllipsePnt1 = await geom.curves.get2dPointFrom2dCurveOnParam({ + shape: anEllipse1, + param: 0, + }); + const anEllipsePnt2 = await geom.curves.get2dPointFrom2dCurveOnParam({ + shape: anEllipse1, + param: Math.PI, + }); + + const aSegment = await geom.curves.geom2dSegment({ + start: anEllipsePnt1, + end: anEllipsePnt2, + }); + + const anEdge1OnSurf1 = + await bitbybit.occt.shapes.edge.makeEdgeFromGeom2dCurveAndSurface({ + curve: anArc1, + surface: aCyl1, + }); + const anEdge2OnSurf1 = + await bitbybit.occt.shapes.edge.makeEdgeFromGeom2dCurveAndSurface({ + curve: aSegment, + surface: aCyl1, + }); + const anEdge1OnSurf2 = + await bitbybit.occt.shapes.edge.makeEdgeFromGeom2dCurveAndSurface({ + curve: anArc2, + surface: aCyl2, + }); + const anEdge2OnSurf2 = + await bitbybit.occt.shapes.edge.makeEdgeFromGeom2dCurveAndSurface({ + curve: aSegment, + surface: aCyl2, + }); + + const threadingWire1 = + await bitbybit.occt.shapes.wire.combineEdgesAndWiresIntoAWire({ + shapes: [anEdge1OnSurf1, anEdge2OnSurf1], + }); + const threadingWire2 = + await bitbybit.occt.shapes.wire.combineEdgesAndWiresIntoAWire({ + shapes: [anEdge1OnSurf2, anEdge2OnSurf2], + }); + + const loft = await bitbybit.occt.operations.loft({ + shapes: [threadingWire1, threadingWire2], + makeSolid: true, + }); + + const union = await bitbybit.occt.booleans.union({ + shapes: [loft, thick], + keepEdges: false, + }); + + // Store shape for downloading + currentShape = union; + + // Create dimensions + // Width dimension (bottom of bottle) + const widthDimOpt = new Bit.Inputs.OCCT.SimpleLinearLengthDimensionDto(); + widthDimOpt.end = [-width / 2, 0, thickness / 2]; + widthDimOpt.start = [width / 2, 0, thickness / 2]; + widthDimOpt.direction = [0, 0, 1]; + widthDimOpt.offsetFromPoints = 0; + widthDimOpt.labelSize = 0.3; + widthDimOpt.labelSuffix = "cm"; + widthDimOpt.labelRotation = 180; + widthDimOpt.endType = dimensionEndTypeEnum.arrow; + widthDimOpt.arrowSize = 0.3; + widthDimOpt.crossingSize = 0.2; + widthDimOpt.decimalPlaces = 1; + const widthDimension = + await bitbybit.occt.dimensions.simpleLinearLengthDimension(widthDimOpt); + + // Height dimension (side of bottle) + const totalHeight = height + neckHeight; + const heightDimOpt = new Bit.Inputs.OCCT.SimpleLinearLengthDimensionDto(); + heightDimOpt.start = [-width / 2, 0, 0]; + heightDimOpt.end = [-width / 2, totalHeight, 0]; + heightDimOpt.direction = [-1, 0, 0]; + heightDimOpt.offsetFromPoints = 0; + heightDimOpt.labelSize = 0.3; + heightDimOpt.endType = dimensionEndTypeEnum.arrow; + heightDimOpt.labelSuffix = "cm"; + heightDimOpt.labelRotation = 0; + heightDimOpt.arrowSize = 0.3; + heightDimOpt.crossingSize = 0.2; + heightDimOpt.decimalPlaces = 1; + const heightDimension = + await bitbybit.occt.dimensions.simpleLinearLengthDimension(heightDimOpt); + + // Thickness dimension (depth of bottle) + const thicknessDimOpt = + new Bit.Inputs.OCCT.SimpleLinearLengthDimensionDto(); + thicknessDimOpt.start = [width / 2, 0, -thickness / 2]; + thicknessDimOpt.end = [width / 2, 0, thickness / 2]; + thicknessDimOpt.direction = [1, 0, 0]; + thicknessDimOpt.offsetFromPoints = 0; + thicknessDimOpt.labelSize = 0.3; + thicknessDimOpt.endType = dimensionEndTypeEnum.arrow; + thicknessDimOpt.labelSuffix = "cm"; + thicknessDimOpt.arrowSize = 0.3; + thicknessDimOpt.labelRotation = 180; + thicknessDimOpt.crossingSize = 0.2; + thicknessDimOpt.decimalPlaces = 1; + const thicknessDimension = + await bitbybit.occt.dimensions.simpleLinearLengthDimension( + thicknessDimOpt + ); + + // Draw options for model with custom material + const di = new Bit.Inputs.Draw.DrawOcctShapeOptions(); + di.edgeColour = "#000000"; + di.edgeOpacity = 0.5; + di.precision = 0.001; + di.faceOpacity = 1; + di.edgeWidth = 1; + + // Create custom ThreeJS material + const mat = new THREEJS.MeshPhongMaterial({ + color: new THREEJS.Color(color), + }); + mat.polygonOffset = true; + mat.polygonOffsetFactor = 1; + di.faceMaterial = mat; + + currentGroup = await bitbybit.draw.drawAnyAsync({ + entity: union, + options: di, + }); + + //Enable shadows on mesh children + currentGroup?.children[0].children.forEach((child) => { + child.castShadow = true; + child.receiveShadow = true; + }); + + // Draw options for dimensions + const dimOptions = new Bit.Inputs.Draw.DrawOcctShapeOptions(); + dimOptions.edgeColour = "#ffffff"; + dimOptions.edgeWidth = 2; + dimOptions.drawEdges = true; + dimOptions.drawFaces = false; + + currentDimensionsGroup = await bitbybit.draw.drawAnyAsync({ + entity: [widthDimension, heightDimension, thicknessDimension], + options: dimOptions, + }); + } + + // Initial render + await createBottle(model.width, model.height, model.thickness, model.color); + + // Setup lil-gui + const gui = new lil.GUI(); + gui.title("Bottle Parameters"); + + gui + .add(model, "width", 2, 10, 0.5) + .name("Width") + .onFinishChange(() => { + createBottle(model.width, model.height, model.thickness, model.color); + }); + + gui + .add(model, "height", 4, 15, 0.5) + .name("Base Height") + .onFinishChange(() => { + createBottle(model.width, model.height, model.thickness, model.color); + }); + + gui + .add(model, "thickness", 1, 6, 0.25) + .name("Thickness") + .onFinishChange(() => { + createBottle(model.width, model.height, model.thickness, model.color); + }); + + gui + .addColor(model, "color") + .name("Color") + .onFinishChange(() => { + createBottle(model.width, model.height, model.thickness, model.color); + }); + + // Download folder + const downloadFolder = gui.addFolder("Download"); + downloadFolder.add({ downloadSTEP }, "downloadSTEP").name("⬇ Download STEP"); + downloadFolder.add({ downloadSTL }, "downloadSTL").name("⬇ Download STL"); +} diff --git a/examples/vite/threejs/runner-occt-bottle/src/runner/bitbybit-0.21.0.d.ts b/examples/vite/threejs/runner-occt-bottle/src/runner/bitbybit-0.21.0.d.ts new file mode 100644 index 00000000..63ee8baa --- /dev/null +++ b/examples/vite/threejs/runner-occt-bottle/src/runner/bitbybit-0.21.0.d.ts @@ -0,0 +1,49262 @@ +declare namespace Bit { + declare namespace Inputs { + declare namespace Base { + type Color = string; + type ColorRGB = { + r: number; + g: number; + b: number; + }; + type Point2 = [number, number]; + type Vector2 = [number, number]; + type Point3 = [number, number, number]; + type Vector3 = [number, number, number]; + type Axis3 = { + origin: Base.Point3; + direction: Base.Vector3; + }; + type Axis2 = { + origin: Base.Point2; + direction: Base.Vector2; + }; + type Segment2 = [Point2, Point2]; + type Segment3 = [Point3, Point3]; + type TrianglePlane3 = { + normal: Vector3; + d: number; + }; + type Triangle3 = [Base.Point3, Base.Point3, Base.Point3]; + type Mesh3 = Triangle3[]; + type Plane3 = { + origin: Base.Point3; + normal: Base.Vector3; + direction: Base.Vector3; + }; + type BoundingBox = { + min: Base.Point3; + max: Base.Point3; + center?: Base.Point3; + width?: number; + height?: number; + length?: number; + }; + type Line2 = { + start: Base.Point2; + end: Base.Point2; + }; + type Line3 = { + start: Base.Point3; + end: Base.Point3; + }; + type Polyline3 = { + points: Base.Point3[]; + isClosed?: boolean; + }; + type Polyline2 = { + points: Base.Point2[]; + isClosed?: boolean; + }; + type VerbCurve = { + tessellate: (options: any) => any; + }; + type VerbSurface = { + tessellate: (options: any) => any; + }; + type TransformMatrix3x3 = [ + number, + number, + number, + number, + number, + number, + number, + number, + number + ]; + type TransformMatrixes3x3 = TransformMatrix3x3[]; + type TransformMatrix = [ + number, + number, + number, + number, + number, + number, + number, + number, + number, + number, + number, + number, + number, + number, + number, + number + ]; + type TransformMatrixes = TransformMatrix[]; + } + declare namespace JSCAD { + type JSCADEntity = any; + class PolylinePropertiesDto { + /** + * Provide options without default values + */ + constructor(points?: Base.Point3[], isClosed?: boolean); + /** + * Points of the polyline + */ + points: Base.Point3[]; + /** + * Can contain is closed information + */ + isClosed?: boolean; + /** + * Can contain color information + */ + color?: string | number[]; + } + enum solidCornerTypeEnum { + /** + * Edges will meet at a corner + */ + edge = "edge", + /** + * Edges will be rounded on the corner + */ + round = "round", + /** + * Edges will be chamfered on the corner + */ + chamfer = "chamfer", + } + enum jscadTextAlignEnum { + /** + * Aligns text to the left + */ + left = "left", + /** + * Aligns text to the center + */ + center = "center", + /** + * Aligns text to the right + */ + right = "right", + } + class MeshDto { + constructor(mesh?: JSCADEntity); + /** + * Solid Jscad mesh + */ + mesh: JSCADEntity; + } + class MeshesDto { + constructor(meshes?: JSCADEntity[]); + /** + * Solid Jscad mesh + */ + meshes: JSCADEntity[]; + } + class DrawSolidMeshDto { + /** + * Provide options without default values + */ + constructor( + mesh?: JSCADEntity, + opacity?: number, + colours?: string | string[], + updatable?: boolean, + hidden?: boolean, + jscadMesh?: T, + drawTwoSided?: boolean, + backFaceColour?: string, + backFaceOpacity?: number + ); + /** + * Solid Jscad mesh + */ + mesh: JSCADEntity; + /** + * Value between 0 and 1 + * @default 1 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + opacity: number; + /** + * Hex colour string + * @default #444444 + */ + colours: string | string[]; + /** + * Indicates wether this solid will be transformed in time + * @default false + */ + updatable: boolean; + /** + * Hidden + * @default false + */ + hidden: boolean; + /** + * Solid mesh variable in case it already exists and needs updating + * @default undefined + * @optional true + * @ignore true + */ + jscadMesh?: T; + /** + * Draw two-sided faces with different colors for front and back. This helps visualize face orientation. + * @default true + */ + drawTwoSided: boolean; + /** + * Hex colour string for back face colour (negative side of the face). Only used when drawTwoSided is true. + * @default #0000ff + */ + backFaceColour: string; + /** + * Back face opacity value between 0 and 1. Only used when drawTwoSided is true. + * @default 1 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + backFaceOpacity: number; + } + class DrawSolidMeshesDto { + /** + * Provide options without default values + */ + constructor( + meshes?: JSCADEntity[], + opacity?: number, + colours?: string | string[], + updatable?: boolean, + hidden?: boolean, + jscadMesh?: T, + drawTwoSided?: boolean, + backFaceColour?: string, + backFaceOpacity?: number + ); + /** + * Solid Jscad meshes + * @default undefined + * @optional true + */ + meshes: JSCADEntity[]; + /** + * Value between 0 and 1 + * @default 1 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + opacity: number; + /** + * Hex colour string + * @default #444444 + */ + colours: string | string[]; + /** + * Indicates wether this solid will be transformed in time + * @default false + */ + updatable: boolean; + /** + * Should be hidden + * @default false + */ + hidden: boolean; + /** + * Solid mesh variable in case it already exists and needs updating + * @default undefined + * @optional true + * @ignore true + */ + jscadMesh?: T; + /** + * Draw two-sided faces with different colors for front and back. This helps visualize face orientation. + * @default true + */ + drawTwoSided: boolean; + /** + * Hex colour string for back face colour (negative side of the face). Only used when drawTwoSided is true. + * @default #0000ff + */ + backFaceColour: string; + /** + * Back face opacity value between 0 and 1. Only used when drawTwoSided is true. + * @default 1 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + backFaceOpacity: number; + } + class DrawPathDto { + /** + * Provide options without default values + */ + constructor( + path?: JSCADEntity, + colour?: string, + opacity?: number, + width?: number, + updatable?: boolean, + pathMesh?: T + ); + /** + * 2D Path to draw + * @default undefined + */ + path: JSCADEntity; + /** + * Colour of the path + * @default #444444 + */ + colour: string; + /** + * Opacity of the path + * @default 1 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + opacity: number; + /** + * Width of the path + * @default 10 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + width: number; + /** + * Indicates wether the path will change in time + * @default false + */ + updatable: boolean; + /** + * Path mesh variable that will be updated if updatable property is set to true + * @default undefined + * @optional true + * @ignore true + */ + pathMesh?: T; + } + class TransformSolidsDto { + constructor( + meshes?: JSCADEntity[], + transformation?: Base.TransformMatrixes + ); + /** + * Solids to be transformed + * @default undefined + */ + meshes: JSCADEntity[]; + /** + * Transformation matrix or a list of transformation matrixes + * @default undefined + */ + transformation: Base.TransformMatrixes; + } + class TransformSolidDto { + constructor( + mesh?: JSCADEntity, + transformation?: Base.TransformMatrixes + ); + /** + * Solid to be transformed + * @default undefined + */ + mesh: JSCADEntity; + /** + * Transformation matrix or a list of transformation matrixes + * @default undefined + */ + transformation: Base.TransformMatrixes; + } + class DownloadSolidDto { + constructor(mesh?: JSCADEntity, fileName?: string); + /** + * Solid to be downloaded + * @default undefined + */ + mesh: JSCADEntity; + /** + * File name + * @default undefined + */ + fileName: string; + } + class DownloadGeometryDto { + constructor( + geometry?: JSCADEntity | JSCADEntity[], + fileName?: string, + options?: any + ); + /** + * Solid or path to be downloaded, also supports multiple geometries in array + * @default undefined + */ + geometry: JSCADEntity | JSCADEntity[]; + /** + * File name + * @default jscad-geometry + */ + fileName: string; + /** + * Options + * @default undefined + * @optional true + */ + options: any; + } + class DownloadSolidsDto { + constructor(meshes?: JSCADEntity[], fileName?: string); + /** + * Solids to be downloaded + * @default undefined + */ + meshes: JSCADEntity[]; + /** + * File name + * @default undefined + */ + fileName: string; + } + class ColorizeDto { + constructor(geometry?: JSCADEntity, color?: string); + /** + * Solid to be colorized + * @default undefined + */ + geometry: JSCADEntity | JSCADEntity[]; + /** + * Hex color string + * @default #0000ff + */ + color: string; + } + class BooleanObjectsDto { + constructor(meshes?: JSCADEntity[]); + /** + * Contains solid Jscad mesh objects that will be used to perform boolean operation + * @default undefined + */ + meshes: JSCADEntity[]; + } + class BooleanTwoObjectsDto { + constructor(first?: JSCADEntity, second?: JSCADEntity); + /** + * Contains Jscad Solid + * @default undefined + */ + first: JSCADEntity; + /** + * Contains Jscad Solid + * @default undefined + */ + second: JSCADEntity; + } + class BooleanObjectsFromDto { + constructor(from?: JSCADEntity, meshes?: JSCADEntity[]); + /** + * Contains Jscad Solid + * @default undefined + */ + from: JSCADEntity; + /** + * Contains Jscad Solid + * @default undefined + */ + meshes: JSCADEntity[]; + } + class ExpansionDto { + constructor( + geometry?: JSCADEntity, + delta?: number, + corners?: solidCornerTypeEnum, + segments?: number + ); + /** + * Can contain various Jscad entities from Solid category + * @default undefined + */ + geometry: JSCADEntity; + /** + * Delta (+/-) of expansion + * @default 0.1 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + delta: number; + /** + * Type of corner to create during of expansion; edge, chamfer, round + * @default edge + */ + corners: solidCornerTypeEnum; + /** + * Integer number of segments when creating round corners + * @default 24 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + segments: number; + } + class OffsetDto { + constructor( + geometry?: JSCADEntity, + delta?: number, + corners?: solidCornerTypeEnum, + segments?: number + ); + /** + * Can contain various Jscad entities from Solid category + * @default undefined + */ + geometry: JSCADEntity; + /** + * Delta (+/-) of offset + * @default 0.1 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + delta: number; + /** + * Type of corner to create during the offset; edge, chamfer, round. + * @default edge + */ + corners: solidCornerTypeEnum; + /** + * Integer number of segments when creating round corners + * @default 24 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + segments: number; + } + class ExtrudeLinearDto { + constructor( + geometry?: JSCADEntity, + height?: number, + twistAngle?: number, + twistSteps?: number + ); + /** + * Geometry to extrude + * @default undefined + */ + geometry: JSCADEntity; + /** + * Height of linear extrude + * @default 1 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + height: number; + /** + * Twist angle in degrees + * @default 90 + * @minimum -Infinity + * @maximum Infinity + * @step 1 + */ + twistAngle: number; + /** + * Number of twist steps + * @default 15 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + twistSteps: number; + } + class HullDto { + constructor(meshes?: JSCADEntity[]); + /** + * Geometries to use in hull + * @default undefined + */ + meshes: JSCADEntity[]; + } + class ExtrudeRectangularDto { + constructor(geometry?: JSCADEntity, height?: number, size?: number); + /** + * Geometry to extrude + * @default undefined + */ + geometry: JSCADEntity; + /** + * Height of linear extrude + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + height: number; + /** + * Size of the rectangle + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + size: number; + } + class ExtrudeRectangularPointsDto { + constructor(points?: Base.Point3[], height?: number, size?: number); + /** + * Points for a path + * @default undefined + */ + points: Base.Point3[]; + /** + * Height of linear extrude + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + height: number; + /** + * Size of the rectangle + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + size: number; + } + class ExtrudeRotateDto { + constructor( + polygon?: JSCADEntity, + angle?: number, + startAngle?: number, + segments?: number + ); + /** + * Polygon to extrude + * @default undefined + */ + polygon: JSCADEntity; + /** + * Angle in degrees + * @default 90 + * @minimum -Infinity + * @maximum Infinity + * @step 1 + */ + angle: number; + /** + * Start angle in degrees + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 1 + */ + startAngle: number; + /** + * Number of segments + * @default 24 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + segments: number; + } + class PolylineDto { + constructor(polyline?: PolylinePropertiesDto); + /** + * Polyline with points + */ + polyline: PolylinePropertiesDto; + } + class CurveDto { + constructor(curve?: any); + /** + * Nurbs curve + */ + curve: any; + } + class PointsDto { + constructor(points?: Base.Point3[]); + /** + * Points + */ + points: Base.Point3[]; + } + class PathDto { + constructor(path?: JSCADEntity); + /** + * 2D path + * @default undefined + */ + path: JSCADEntity; + } + class PathFromPointsDto { + constructor(points?: Base.Point2[], closed?: boolean); + /** + * Points through which to create a path + * @default undefined + */ + points: Base.Point2[]; + /** + * Indicates wether we want to create a closed path + * @default false + */ + closed: boolean; + } + class PathsFromPointsDto { + constructor(pointsLists?: Base.Point3[][] | Base.Point2[][]); + /** + * Points + * @default undefined + */ + pointsLists: Base.Point3[][] | Base.Point2[][]; + } + class PathFromPolylineDto { + constructor(polyline?: PolylinePropertiesDto, closed?: boolean); + /** + * Polyline + * @default undefined + */ + polyline: PolylinePropertiesDto; + /** + * Indicates wether we want to create a closed path + * @default false + */ + closed: boolean; + } + class PathAppendCurveDto { + constructor(curve?: JSCADEntity, path?: JSCADEntity); + /** + * Verb Nurbs curve + * @default undefined + */ + curve: JSCADEntity; + /** + * Path to append the curve to + * @default undefined + */ + path: JSCADEntity; + } + class PathAppendPointsDto { + constructor(points?: Base.Point2[], path?: JSCADEntity); + /** + * Points to append + * @default undefined + */ + points: Base.Point2[]; + /** + * Path to append the points to + * @default undefined + */ + path: JSCADEntity; + } + class PathAppendPolylineDto { + constructor(polyline?: PolylinePropertiesDto, path?: JSCADEntity); + /** + * Polyline to append + * @default undefined + */ + polyline: PolylinePropertiesDto; + /** + * Path to append the polyline to + * @default undefined + */ + path: JSCADEntity; + } + class PathAppendArcDto { + constructor( + path?: JSCADEntity, + endPoint?: Base.Point2, + xAxisRotation?: number, + clockwise?: boolean, + large?: boolean, + segments?: number, + radiusX?: number, + radiusY?: number + ); + /** + * Path to append the arc to + * @default undefined + */ + path: JSCADEntity; + /** + * End point of an arc + * @default [1, 1] + */ + endPoint: Base.Point2; + /** + * Rotation (degrees) of the X axis of the arc with respect to the X axis of the coordinate system + * @default 90 + * @minimum -Infinity + * @maximum Infinity + * @step 1 + */ + xAxisRotation: number; + /** + * Draw an arc clockwise with respect to the center point + * @default true + */ + clockwise: boolean; + /** + * Draw an arc longer than PI radians + * @default false + */ + large: boolean; + /** + * Number of segments for the arc + * @default 24 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + segments: number; + /** + * X radius of an arc + * @default 1 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + radiusX: number; + /** + * Y radius of an arc + * @default 1 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + radiusY: number; + } + class CircleDto { + constructor(center?: Base.Point2, radius?: number, segments?: number); + /** + * Center of the circle + * @default [0, 0] + */ + center: Base.Point2; + /** + * Radius of the circle + * @default 1 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + radius: number; + /** + * Segment number + * @default 24 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + segments: number; + } + class EllipseDto { + constructor( + center?: Base.Point2, + radius?: Base.Point2, + segments?: number + ); + /** + * Center of the circle + * @default [0, 0] + */ + center: Base.Point2; + /** + * Radius of the circle in [x, y] form + * @default [1, 2] + */ + radius: Base.Point2; + /** + * Segment number + * @default 24 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + segments: number; + } + class SquareDto { + constructor(center?: Base.Point2, size?: number); + /** + * Center of the 2D square + * @default [0, 0] + */ + center: Base.Point2; + /** + * Size of the square + * @default 1 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + size: number; + } + class RectangleDto { + constructor(center?: Base.Point2, width?: number, length?: number); + /** + * Center of the 2D rectangle + * @default [0, 0] + */ + center: Base.Point2; + /** + * Width of the rectangle + * @default 1 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + width: number; + /** + * Length of the rectangle + * @default 1 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + length: number; + } + class RoundedRectangleDto { + constructor( + center?: Base.Point2, + roundRadius?: number, + segments?: number, + width?: number, + length?: number + ); + /** + * Center of the 2D rectangle + * @default [0, 0] + */ + center: Base.Point2; + /** + * The radius to round the rectangle edge + * @default 0.2 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + roundRadius: number; + /** + * Number of segments for corners + * @default 24 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + segments: number; + /** + * Width of the rectangle + * @default 1 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + width: number; + /** + * Length of the rectangle + * @default 1 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + length: number; + } + class StarDto { + constructor( + center?: Base.Point2, + vertices?: number, + density?: number, + outerRadius?: number, + innerRadius?: number, + startAngle?: number + ); + /** + * Center of the 2D star + * @default [0, 0] + */ + center: Base.Point2; + /** + * Number of vertices on the star + * @default 10 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + vertices: number; + /** + * Density of the star + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + density: number; + /** + * Outer radius of the star + * @default 2 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + outerRadius: number; + /** + * Inner radius of the star + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + innerRadius: number; + /** + * Starting angle for first vertice, in degrees + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 1 + */ + startAngle: number; + } + class CubeDto { + constructor(center?: Base.Point3, size?: number); + /** + * Center coordinates of the cube + * @default [0, 0, 0] + */ + center: Base.Point3; + /** + * Size of the cube + * @default 1 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + size: number; + } + class CubeCentersDto { + constructor(centers?: Base.Point3[], size?: number); + /** + * Center coordinates of the cubes + * @default undefined + */ + centers: Base.Point3[]; + /** + * Size of the cube + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + size: number; + } + class CuboidDto { + constructor( + center?: Base.Point3, + width?: number, + length?: number, + height?: number + ); + /** + * Center coordinates of the cubod + * @default [0, 0, 0] + */ + center: Base.Point3; + /** + * Width of the cuboid + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + width: number; + /** + * Length of the cuboid + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + length: number; + /** + * Height of the cuboid + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + height: number; + } + class CuboidCentersDto { + constructor( + centers?: Base.Point3[], + width?: number, + length?: number, + height?: number + ); + /** + * Center coordinates of the cuboids + * @default undefined + */ + centers: Base.Point3[]; + /** + * Width of the cuboids + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + width: number; + /** + * Length of the cuboids + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + length: number; + /** + * Height of the cuboids + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + height: number; + } + class RoundedCuboidDto { + constructor( + center?: Base.Point3, + roundRadius?: number, + width?: number, + length?: number, + height?: number, + segments?: number + ); + /** + * Center coordinates of the cubod + * @default [0, 0, 0] + */ + center: Base.Point3; + /** + * Radius for rounding edges + * @default 0.1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + roundRadius: number; + /** + * Width of the cuboid + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + width: number; + /** + * Length of the cuboid + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + length: number; + /** + * Height of the cuboid + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + height: number; + /** + * Segments of rounded edges + * @default 24 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + segments: number; + } + class RoundedCuboidCentersDto { + constructor( + centers?: Base.Point3[], + roundRadius?: number, + width?: number, + length?: number, + height?: number, + segments?: number + ); + /** + * Center coordinates of the cuboids + * @default undefined + */ + centers: Base.Point3[]; + /** + * Radius for rounding edges + * @default 0.1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + roundRadius: number; + /** + * Width of the cuboids + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + width: number; + /** + * Length of the cuboids + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + length: number; + /** + * Height of the cuboids + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + height: number; + /** + * Segments of rounded edges + * @default 24 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + segments: number; + } + class CylidnerEllipticDto { + constructor( + center?: Base.Point3, + height?: number, + startRadius?: Base.Point2, + endRadius?: Base.Point2, + segments?: number + ); + /** + * Center of the cylinder + * @default [0, 0, 0] + */ + center: Base.Point3; + /** + * Height of the cylinder + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + height: number; + /** + * Start radius on X and Y directions + * @default [1, 2] + */ + startRadius: Base.Vector2; + /** + * End radius on X and Y directions + * @default [2, 3] + */ + endRadius: Base.Vector2; + /** + * Subdivision segments + * @default 24 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + segments: number; + } + class CylidnerCentersEllipticDto { + constructor( + centers?: Base.Point3[], + height?: number, + startRadius?: Base.Point2, + endRadius?: Base.Point2, + segments?: number + ); + /** + * Centers of the cylinders + * @default undefined + */ + centers: Base.Point3[]; + /** + * Height of the cylinders + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + height: number; + /** + * Start radius on X and Y directions + * @default [1, 2] + */ + startRadius: Base.Point2; + /** + * End radius on X and Y directions + * @default [2, 3] + */ + endRadius: Base.Point2; + /** + * Subdivision segments + * @default 24 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + segments: number; + } + class CylidnerDto { + constructor( + center?: Base.Point3, + height?: number, + radius?: number, + segments?: number + ); + /** + * Center of the cylinder + * @default [0, 0, 0] + */ + center: Base.Point3; + /** + * Height of the cylinder + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + height: number; + /** + * Radius of the cylinder + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + radius: number; + /** + * Subdivision segments + * @default 24 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + segments: number; + } + class RoundedCylidnerDto { + constructor( + center?: Base.Point3, + roundRadius?: number, + height?: number, + radius?: number, + segments?: number + ); + /** + * Center of the cylinder + * @default [0, 0, 0] + */ + center: Base.Point3; + /** + * Rounding radius + * @default 0.1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + roundRadius: number; + /** + * Height of the cylinder + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + height: number; + /** + * Radius of the cylinder + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + radius: number; + /** + * Segment number + * @default 24 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + segments: number; + } + class EllipsoidDto { + constructor( + center?: Base.Point3, + radius?: Base.Point3, + segments?: number + ); + /** + * Center coordinates + * @default [0, 0, 0] + */ + center: Base.Point3; + /** + * Radius of the ellipsoid in [x, y, z] form + * @default [1, 2, 3] + */ + radius: Base.Point3; + /** + * Segment count for ellipsoid + * @default 24 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + segments: number; + } + class EllipsoidCentersDto { + constructor( + centers?: Base.Point3[], + radius?: Base.Point3, + segments?: number + ); + /** + * Center coordinates + * @default undefined + */ + centers: Base.Point3[]; + /** + * Radius of the ellipsoid in [x, y, z] form + * @default [1, 2, 3] + */ + radius: Base.Point3; + /** + * Segment count for ellipsoid + * @default 24 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + segments: number; + } + class GeodesicSphereDto { + constructor(center?: Base.Point3, radius?: number, frequency?: number); + /** + * Center coordinate of the geodesic sphere + * @default [0, 0, 0] + */ + center: Base.Point3; + /** + * Radius of the sphere + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + radius: number; + /** + * Subdivision count + * @default 12 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + frequency: number; + } + class GeodesicSphereCentersDto { + constructor( + centers?: Base.Point3[], + radius?: number, + frequency?: number + ); + /** + * Center coordinates of the geodesic spheres + * @default undefined + */ + centers: Base.Point3[]; + /** + * Radius of the sphere + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + radius: number; + /** + * Subdivision count + * @default 12 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + frequency: number; + } + class CylidnerCentersDto { + constructor( + centers?: Base.Point3[], + height?: number, + radius?: number, + segments?: number + ); + /** + * Centers of the cylinders + * @default undefined + */ + centers: Base.Point3[]; + /** + * Height of the cylinders + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + height: number; + /** + * Radius of the cylinders + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + radius: number; + /** + * Subdivision segments + * @default 24 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + segments: number; + } + class RoundedCylidnerCentersDto { + constructor( + centers?: Base.Point3[], + roundRadius?: number, + height?: number, + radius?: number, + segments?: number + ); + /** + * Centers of the cylinders + * @default undefined + */ + centers: Base.Point3[]; + /** + * Rounding radius + * @default 0.1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + roundRadius: number; + /** + * Height of the cylinders + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + height: number; + /** + * Radius of the cylinders + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + radius: number; + /** + * Segment number + * @default 24 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + segments: number; + } + class SphereDto { + constructor(center?: Base.Point3, radius?: number, segments?: number); + /** + * Center point of the sphere + * @default [0, 0, 0] + */ + center: Base.Point3; + /** + * Radius of the sphere + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + radius: number; + /** + * Segment count + * @default 24 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + segments: number; + } + class SphereCentersDto { + constructor( + centers?: Base.Point3[], + radius?: number, + segments?: number + ); + /** + * Center points of the spheres + * @default undefined + */ + centers: Base.Point3[]; + /** + * Radius of the spheres + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + radius: number; + /** + * Segment count + * @default 24 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + segments: number; + } + class TorusDto { + constructor( + center?: Base.Point3, + innerRadius?: number, + outerRadius?: number, + innerSegments?: number, + outerSegments?: number, + innerRotation?: number, + outerRotation?: number, + startAngle?: number + ); + /** + * Center coordinate + * @default [0, 0, 0] + */ + center: Base.Point3; + /** + * Inner radius + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + innerRadius: number; + /** + * Outer radius + * @default 2 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + outerRadius: number; + /** + * Number of inner segments + * @default 24 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + innerSegments: number; + /** + * Number of outer segments + * @default 24 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + outerSegments: number; + /** + * Inner rotation in degrees + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 1 + */ + innerRotation: number; + /** + * Outer rotation in degrees + * @default 360 + * @minimum -Infinity + * @maximum Infinity + * @step 1 + */ + outerRotation: number; + /** + * Start angle in degrees + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 1 + */ + startAngle: number; + } + class TextDto { + constructor( + text?: string, + segments?: number, + xOffset?: number, + yOffset?: number, + height?: number, + lineSpacing?: number, + letterSpacing?: number, + align?: jscadTextAlignEnum, + extrudeOffset?: number + ); + /** + * Text to write + * @default Hello World + */ + text: string; + /** + * Number of segments + * @default 24 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + segments: number; + /** + * X offset of the text + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + xOffset: number; + /** + * Y offset of the text + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + yOffset: number; + /** + * Height of the text + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + height: number; + /** + * Space between lines + * @default 1.4 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + lineSpacing: number; + /** + * Space between letters + * @default 1 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + letterSpacing: number; + /** + * Align between left, center, right + * @default center + */ + align: jscadTextAlignEnum; + /** + * Offset the extrusion + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + extrudeOffset: number; + } + class CylinderTextDto { + constructor( + text?: string, + extrusionHeight?: number, + extrusionSize?: number, + segments?: number, + xOffset?: number, + yOffset?: number, + height?: number, + lineSpacing?: number, + letterSpacing?: number, + align?: jscadTextAlignEnum, + extrudeOffset?: number + ); + /** + * Text to write + * @default Hello World + */ + text: string; + /** + * Height of the cylinder + * @default 0.5 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + extrusionHeight: number; + /** + * Radius of the cylinder + * @default 0.1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + extrusionSize: number; + /** + * Segment subdivision for cylinder + * @default 24 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + segments: number; + /** + * X offset of the text + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + xOffset: number; + /** + * Y offset of the text + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + yOffset: number; + /** + * Height of the text + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + height: number; + /** + * Space between lines + * @default 1.4 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + lineSpacing: number; + /** + * Space between letters + * @default 1 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + letterSpacing: number; + /** + * Align between left, center, right + * @default center + */ + align: jscadTextAlignEnum; + /** + * Offset the extrusion + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + extrudeOffset: number; + } + class SphereTextDto { + constructor( + text?: string, + radius?: number, + segments?: number, + xOffset?: number, + yOffset?: number, + height?: number, + lineSpacing?: number, + letterSpacing?: number, + align?: jscadTextAlignEnum, + extrudeOffset?: number + ); + /** + * Text to write + * @default Hello World + */ + text: string; + /** + * Radius of the spheres + * @default 0.1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + radius: number; + /** + * Segment subdivision for sphere + * @default 24 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + segments: number; + /** + * X offset of the text + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + xOffset: number; + /** + * Y offset of the text + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + yOffset: number; + /** + * Height of the text + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + height: number; + /** + * Space between lines + * @default 1.4 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + lineSpacing: number; + /** + * Space between letters + * @default 1 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + letterSpacing: number; + /** + * Align between left, center, right + * @default center + */ + align: jscadTextAlignEnum; + /** + * Offset the extrusion + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + extrudeOffset: number; + } + class FromPolygonPoints { + constructor(polygonPoints?: Base.Point3[][]); + /** + * Points describing polygons + */ + polygonPoints?: Base.Point3[][]; + } + } + declare namespace Base { + type Color = string; + type ColorRGB = { + r: number; + g: number; + b: number; + }; + type Point2 = [number, number]; + type Vector2 = [number, number]; + type Point3 = [number, number, number]; + type Vector3 = [number, number, number]; + type Axis3 = { + origin: Base.Point3; + direction: Base.Vector3; + }; + type Axis2 = { + origin: Base.Point2; + direction: Base.Vector2; + }; + type Segment2 = [Point2, Point2]; + type Segment3 = [Point3, Point3]; + type TrianglePlane3 = { + normal: Vector3; + d: number; + }; + type Triangle3 = [Base.Point3, Base.Point3, Base.Point3]; + type Mesh3 = Triangle3[]; + type Plane3 = { + origin: Base.Point3; + normal: Base.Vector3; + direction: Base.Vector3; + }; + type BoundingBox = { + min: Base.Point3; + max: Base.Point3; + center?: Base.Point3; + width?: number; + height?: number; + length?: number; + }; + type Line2 = { + start: Base.Point2; + end: Base.Point2; + }; + type Line3 = { + start: Base.Point3; + end: Base.Point3; + }; + type Polyline3 = { + points: Base.Point3[]; + isClosed?: boolean; + }; + type Polyline2 = { + points: Base.Point2[]; + isClosed?: boolean; + }; + type VerbCurve = { + tessellate: (options: any) => any; + }; + type VerbSurface = { + tessellate: (options: any) => any; + }; + type TransformMatrix3x3 = [ + number, + number, + number, + number, + number, + number, + number, + number, + number + ]; + type TransformMatrixes3x3 = TransformMatrix3x3[]; + type TransformMatrix = [ + number, + number, + number, + number, + number, + number, + number, + number, + number, + number, + number, + number, + number, + number, + number, + number + ]; + type TransformMatrixes = TransformMatrix[]; + } + declare namespace Manifold { + type ManifoldPointer = { + hash: number; + type: string; + }; + type CrossSectionPointer = { + hash: number; + type: string; + }; + type MeshPointer = { + hash: number; + type: string; + }; + enum fillRuleEnum { + evenOdd = "EvenOdd", + nonZero = "NonZero", + positive = "Positive", + negative = "Negative", + } + enum manifoldJoinTypeEnum { + square = "Square", + round = "Round", + miter = "Miter", + bevel = "Bevel", + } + class DecomposedManifoldMeshDto { + numProp: number; + vertProperties: Float32Array; + triVerts: Uint32Array; + mergeFromVert?: Uint32Array; + mergeToVert?: Uint32Array; + runIndex?: Uint32Array; + runOriginalID?: Uint32Array; + runTransform?: Float32Array; + faceID?: Uint32Array; + halfedgeTangent?: Float32Array; + } + class DrawManifoldOrCrossSectionDto { + /** + * Provide options without default values + */ + constructor( + manifoldOrCrossSection?: T, + faceOpacity?: number, + faceMaterial?: M, + faceColour?: Base.Color, + crossSectionColour?: Base.Color, + crossSectionWidth?: number, + crossSectionOpacity?: number, + computeNormals?: boolean, + drawTwoSided?: boolean, + backFaceColour?: Base.Color, + backFaceOpacity?: number + ); + /** + * Manifold geometry + * @default undefined + */ + manifoldOrCrossSection?: T; + /** + * Face opacity value between 0 and 1 + * @default 1 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + faceOpacity: number; + /** + * Face material + * @default undefined + * @optional true + */ + faceMaterial?: M; + /** + * Hex colour string for face colour + * @default #ff0000 + */ + faceColour: Base.Color; + /** + * Hex colour string for cross section drawing + * @default #ff00ff + */ + crossSectionColour: Base.Color; + /** + * Width of cross section lines + * @default 2 + */ + crossSectionWidth: number; + /** + * Cross section opacity value between 0 and 1 + * @default 1 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + crossSectionOpacity: number; + /** + * Compute normals for the shape + * @default false + */ + computeNormals: boolean; + /** + * Draw two-sided faces with different colors for front and back. This helps visualize face orientation. + * @default true + */ + drawTwoSided: boolean; + /** + * Hex colour string for back face colour (negative side of the face). Only used when drawTwoSided is true. + * @default #0000ff + */ + backFaceColour: Base.Color; + /** + * Back face opacity value between 0 and 1. Only used when drawTwoSided is true. + * @default 1 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + backFaceOpacity: number; + } + class DrawManifoldsOrCrossSectionsDto { + /** + * Provide options without default values + */ + constructor( + manifoldsOrCrossSections?: T[], + faceOpacity?: number, + faceMaterial?: M, + faceColour?: Base.Color, + crossSectionColour?: Base.Color, + crossSectionWidth?: number, + crossSectionOpacity?: number, + computeNormals?: boolean, + drawTwoSided?: boolean, + backFaceColour?: Base.Color, + backFaceOpacity?: number + ); + /** + * Manifold geometry + * @default undefined + */ + manifoldsOrCrossSections?: T[]; + /** + * Face material + * @default undefined + * @optional true + */ + faceMaterial?: M; + /** + * Hex colour string for face colour + * @default #ff0000 + */ + faceColour: Base.Color; + /** + * Face opacity value between 0 and 1 + * @default 1 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + faceOpacity: number; + /** + * Hex colour string for cross section drawing + * @default #ff00ff + */ + crossSectionColour: Base.Color; + /** + * Width of cross section lines + * @default 2 + */ + crossSectionWidth: number; + /** + * Cross section opacity value between 0 and 1 + * @default 1 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + crossSectionOpacity: number; + /** + * Compute normals for the shape + * @default false + */ + computeNormals: boolean; + /** + * Draw two-sided faces with different colors for front and back. This helps visualize face orientation. + * @default true + */ + drawTwoSided: boolean; + /** + * Hex colour string for back face colour (negative side of the face). Only used when drawTwoSided is true. + * @default #0000ff + */ + backFaceColour: Base.Color; + /** + * Back face opacity value between 0 and 1. Only used when drawTwoSided is true. + * @default 1 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + backFaceOpacity: number; + } + class CreateFromMeshDto { + constructor(mesh?: DecomposedManifoldMeshDto); + /** + * Mesh definition + */ + mesh: DecomposedManifoldMeshDto; + } + class FromPolygonPointsDto { + constructor(polygonPoints?: Base.Point3[][]); + /** + * Points describing polygons + */ + polygonPoints?: Base.Point3[][]; + } + class CrossSectionFromPolygonPointsDto { + constructor( + points?: Base.Point3[], + fillRule?: fillRuleEnum, + removeDuplicates?: boolean, + tolerance?: number + ); + /** + * Points describing a single polygon + */ + points: Base.Point3[]; + /** + * Fill rule for polygon interpretation + * @default positive + */ + fillRule?: fillRuleEnum; + /** + * Remove consecutive duplicate points before creating polygon + * @default false + */ + removeDuplicates?: boolean; + /** + * Tolerance for duplicate removal + * @default 1e-7 + */ + tolerance?: number; + } + class CrossSectionFromPolygonsPointsDto { + constructor( + polygonPoints?: Base.Point3[][], + fillRule?: fillRuleEnum, + removeDuplicates?: boolean, + tolerance?: number + ); + /** + * Points describing multiple polygons + */ + polygonPoints: Base.Point3[][]; + /** + * Fill rule for polygon interpretation + * @default positive + */ + fillRule?: fillRuleEnum; + /** + * Remove consecutive duplicate points before creating polygons + * @default false + */ + removeDuplicates?: boolean; + /** + * Tolerance for duplicate removal + * @default 1e-7 + */ + tolerance?: number; + } + class CubeDto { + constructor(center?: boolean, size?: number); + /** + * Place cube on the center + * @default true + */ + center: boolean; + /** + * Size of the cube + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + size: number; + } + class CreateContourSectionDto { + constructor(polygons?: Base.Vector2[][], fillRule?: fillRuleEnum); + /** + * Polygons to use for the contour section + * @default undefined + */ + polygons: Base.Vector2[][]; + /** + * Fill rule for the contour section + * @default EvenOdd + */ + fillRule: fillRuleEnum; + } + class SquareDto { + constructor(center?: boolean, size?: number); + /** + * Place cube on the center + * @default false + */ + center: boolean; + /** + * Size of the cube + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + size: number; + } + class SphereDto { + constructor(radius?: number, circularSegments?: number); + /** + * Radius of the sphere + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + radius: number; + /** + * Circular segments of the sphere + * @default 32 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + circularSegments: number; + } + class CylinderDto { + constructor( + height?: number, + radiusLow?: number, + radiusHigh?: number, + circularSegments?: number, + center?: boolean + ); + /** + * Height of the cylinder + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + height: number; + /** + * Radius of the cylinder + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + radiusLow: number; + /** + * Radius of the cylinder + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + radiusHigh: number; + /** + * Circular segments of the cylinder + * @default 32 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + circularSegments: number; + /** + * Place cylinder on the center + * @default true + */ + center: boolean; + } + class CircleDto { + constructor(radius?: number, circularSegments?: number); + /** + * Radius of the cylinder + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + radius: number; + /** + * Circular segments of the cylinder + * @default 32 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + circularSegments: number; + } + class RectangleDto { + constructor(length?: number, height?: number, center?: boolean); + /** + * Length of the rectangle + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + length: number; + /** + * Height of the rectangle + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + height: number; + /** + * Place rectangle on the center + * @default false + */ + center: boolean; + } + class ManifoldDto { + constructor(manifold?: T); + /** + * Manifold shape + */ + manifold: T; + } + class CalculateNormalsDto { + constructor(manifold?: T, normalIdx?: number, minSharpAngle?: number); + /** + * Manifold shape + */ + manifold: T; + /** + * The property channel in which to store the X + * values of the normals. The X, Y, and Z channels will be sequential. The + * property set will be automatically expanded to include up through normalIdx + * + 2. + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + normalIdx: number; + /** + * Any edges with angles greater than this value will + * remain sharp, getting different normal vector properties on each side of + * the edge. By default, no edges are sharp and all normals are shared. With a + * value of zero, the model is faceted and all normals match their triangle + * normals, but in this case it would be better not to calculate normals at + * all. The value is in degrees. + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + minSharpAngle: number; + } + class CalculateCurvatureDto { + constructor(manifold?: T); + /** + * Manifold shape + */ + manifold: T; + /** + * The property channel index in which to store the + * Gaussian curvature. An index < 0 will be ignored (stores nothing). The + * property set will be automatically expanded to include the channel + * index specified. + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + gaussianIdx: number; + /** + * The property channel index in which to store the mean + * curvature. An index < 0 will be ignored (stores nothing). The property + * set will be automatically expanded to include the channel index + * specified. The mean curvature is a scalar value that describes the + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + meanIdx: number; + } + class CountDto { + constructor(count?: number); + /** + * Nr to count + */ + count: number; + } + class ManifoldsMinGapDto { + constructor(manifold1?: T, manifold2?: T, searchLength?: number); + /** + * Manifold shape + */ + manifold1: T; + /** + * Manifold shape + */ + manifold2: T; + /** + * Length of the search gap + * @default 100 + * @minimum 0 + * @maximum Infinity + * @step 10 + */ + searchLength: number; + } + class ManifoldRefineToleranceDto { + constructor(manifold?: T, tolerance?: number); + /** + * Manifold shape + */ + manifold: T; + /** + * The desired maximum distance between the faceted mesh + * produced and the exact smoothly curving surface. All vertices are exactly + * on the surface, within rounding error. + * @default 1e-6 + * @minimum 0 + * @maximum Infinity + * @step 1e-7 + */ + tolerance: number; + } + class ManifoldRefineLengthDto { + constructor(manifold?: T, length?: number); + /** + * Manifold shape + */ + manifold: T; + /** + * Length of the manifold + * @default 0.1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + length: number; + } + class ManifoldRefineDto { + constructor(manifold?: T, number?: number); + /** + * Manifold shape + */ + manifold: T; + /** + * The number of pieces to split every edge into. Must be > 1. + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + number: number; + } + class ManifoldSmoothByNormalsDto { + constructor(manifold?: T, normalIdx?: number); + /** + * Manifold shape + */ + manifold: T; + /** + * The first property channel of the normals. NumProp must be + * at least normalIdx + 3. Any vertex where multiple normals exist and don't + * agree will result in a sharp edge. + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + normalIdx: number; + } + class ManifoldSimplifyDto { + constructor(manifold?: T, tolerance?: number); + /** + * Manifold shape + */ + manifold: T; + /** + * The maximum distance between the original and simplified meshes. + * If not given or is less than the current tolerance, the current tolerance is used. + * The result will contain a subset of the original verts and all surfaces will have moved by less than tolerance. + * @default undefined + * @minimum 0 + * @maximum Infinity + * @step 0.001 + */ + tolerance?: number; + } + class ManifoldSetPropertiesDto { + constructor( + manifold?: T, + numProp?: number, + propFunc?: ( + newProp: number[], + position: Base.Vector3, + oldProp: number[] + ) => void + ); + /** + * Manifold shape + */ + manifold: T; + /** + * The new number of properties per vertex + * @default 3 + * @minimum 3 + * @maximum Infinity + * @step 1 + */ + numProp: number; + /** + * A function that modifies the properties of a given vertex. + * Note: undefined behavior will result if you read past the number of input properties or write past the number of output properties. + * @default undefined + */ + propFunc: ( + newProp: number[], + position: Base.Vector3, + oldProp: number[] + ) => void; + } + class ManifoldSmoothOutDto { + constructor( + manifold?: T, + minSharpAngle?: number, + minSmoothness?: number + ); + /** + * Manifold shape + */ + manifold: T; + /** + * Any edges with angles greater + * than this value will remain sharp. The rest will be smoothed to G1 + * continuity, with the caveat that flat faces of three or more triangles will + * always remain flat. With a value of zero, the model is faceted, but in this + * case there is no point in smoothing. + * @default 60 + * @minimum -Infinity + * @maximum Infinity + * @step 1 + */ + minSharpAngle: number; + /** + * The smoothness applied to + * sharp angles. The default gives a hard edge, while values > 0 will give a + * small fillet on these sharp edges. A value of 1 is equivalent to a + * minSharpAngle of 180 - all edges will be smooth. + * @default 0 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + minSmoothness: number; + } + class HullPointsDto { + constructor(points?: T); + /** + * Points to hull + */ + points: T; + } + class SliceDto { + constructor(manifold?: T); + /** + * Manifold shape + */ + manifold: T; + /** + * Height of the slice + * @default 0.5 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + height: number; + } + class MeshDto { + constructor(mesh?: T); + /** + * Mesh + */ + mesh: T; + } + class MeshVertexIndexDto { + constructor(mesh?: T, vertexIndex?: number); + /** + * Mesh + */ + mesh: T; + /** + * Vertex index + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + vertexIndex: number; + } + class MeshTriangleRunIndexDto { + constructor(mesh?: T, triangleRunIndex?: number); + /** + * Mesh + */ + mesh: T; + /** + * Triangle run index + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + triangleRunIndex: number; + } + class MeshHalfEdgeIndexDto { + constructor(mesh?: T, halfEdgeIndex?: number); + /** + * Mesh + */ + mesh: T; + /** + * Half edge index + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + halfEdgeIndex: number; + } + class MeshTriangleIndexDto { + constructor(mesh?: T, triangleIndex?: number); + /** + * Mesh + */ + mesh: T; + /** + * Triangle index + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + triangleIndex: number; + } + class CrossSectionDto { + constructor(crossSection?: T); + /** + * Cross section + */ + crossSection: T; + } + class CrossSectionsDto { + constructor(crossSections?: T[]); + /** + * Cross sections + */ + crossSections: T[]; + } + class ExtrudeDto { + constructor(crossSection?: T); + /** + * Extrude cross section shape + */ + crossSection: T; + /** + * Height of the extrusion + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + height: number; + /** + * Number of divisions + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + nDivisions: number; + /** + * Twist degrees + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 1 + */ + twistDegrees: number; + /** + * Scale top + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + scaleTopX: number; + /** + * Scale top + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + scaleTopY: number; + /** + * Center the extrusion + * @default true + */ + center: boolean; + } + class RevolveDto { + constructor( + crossSection?: T, + revolveDegrees?: number, + matchProfile?: boolean, + circularSegments?: number + ); + /** + * Revolve cross section shape + */ + crossSection: T; + /** + * Extrude cross section shape + * @default 360 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + revolveDegrees: number; + /** + * Default manifold library will adjust profile when generating revolved shape. We prefer it to be matching the profile by default. Set to false to use default manifold library behavior. + * @default true + */ + matchProfile: boolean; + /** + * Circular segments + * @default 32 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + circularSegments: number; + } + class OffsetDto { + constructor( + crossSection?: T, + delta?: number, + joinType?: manifoldJoinTypeEnum, + miterLimit?: number, + circularSegments?: number + ); + /** + * Revolve cross section shape + */ + crossSection: T; + /** + * Positive deltas will cause the expansion of outlining contours + * to expand, and retraction of inner (hole) contours. Negative deltas will + * have the opposite effect. + * @default 1 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + delta: number; + /** + * The join type specifying the treatment of contour joins + * (corners). + * @default round + */ + joinType: manifoldJoinTypeEnum; + /** + * The maximum distance in multiples of delta that vertices + * can be offset from their original positions with before squaring is + * applied, **when the join type is Miter** (default is 2, which is the + * minimum allowed). See the [Clipper2 + * MiterLimit](http://www.angusj.com/clipper2/Docs/Units/Clipper.Offset/Classes/ClipperOffset/Properties/MiterLimit.htm) + * page for a visual example. + * @default 2 + * @minimum 2 + * @maximum Infinity + * @step 0.1 + */ + miterLimit: number; + /** + * Number of segments per 360 degrees of + * JoinType::Round corners (roughly, the number of vertices that + * will be added to each contour). Default is calculated by the static Quality + * defaults according to the radius. + * @default 32 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + circularSegments: number; + } + class SimplifyDto { + constructor(crossSection?: T, epsilon?: number); + /** + * Revolve cross section shape + */ + crossSection: T; + /** + * Extrude cross section shape + * @default 1e-6 + * @minimum 0 + * @maximum Infinity + * @step 1e-7 + */ + epsilon: number; + } + class ComposeDto { + constructor(polygons?: T); + /** + * Polygons to compose + */ + polygons: T; + } + class MirrorCrossSectionDto { + constructor(crossSection?: T, normal?: Base.Vector2); + /** + * Manifold shape + */ + crossSection: T; + /** + * The normal vector of the plane to be mirrored over + * @default [1,0] + */ + normal: Base.Vector2; + } + class Scale2DCrossSectionDto { + constructor(crossSection?: T, vector?: Base.Vector2); + /** + * Manifold shape + */ + crossSection: T; + /** + * The normal vector of the plane to be mirrored over + * @default [2,2] + */ + vector: Base.Vector2; + } + class TranslateCrossSectionDto { + constructor(crossSection?: T, vector?: Base.Vector2); + /** + * Manifold shape + */ + crossSection: T; + /** + * The translation vector + * @default undefined + */ + vector: Base.Vector2; + } + class RotateCrossSectionDto { + constructor(crossSection?: T, degrees?: number); + /** + * Manifold shape + */ + crossSection: T; + /** + * The rotation vector in eulers + * @default 45 + * @minimum -Infinity + * @maximum Infinity + * @step 1 + */ + degrees: number; + } + class ScaleCrossSectionDto { + constructor(crossSection?: T, factor?: number); + /** + * Manifold shape + */ + crossSection: T; + /** + * The normal vector of the plane to be mirrored over + * @default 2 + */ + factor: number; + } + class TranslateXYCrossSectionDto { + constructor(crossSection?: T, x?: number, y?: number); + /** + * Manifold shape + */ + crossSection: T; + /** + * The translation X axis + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 1 + */ + x: number; + /** + * The translation Y axis + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 1 + */ + y: number; + } + class TransformCrossSectionDto { + constructor(crossSection?: T, transform?: Base.TransformMatrix3x3); + /** + * Cross section + */ + crossSection: T; + /** + * The transform matrix to apply + * @default undefined + */ + transform: Base.TransformMatrix3x3; + } + class CrossSectionWarpDto { + constructor(crossSection?: T, warpFunc?: (vert: Base.Vector2) => void); + /** + * Cross section + */ + crossSection: T; + /** + * A function that modifies a given vertex position + * @default undefined + */ + warpFunc: (vert: Base.Vector2) => void; + } + class MirrorDto { + constructor(manifold?: T, normal?: Base.Vector3); + /** + * Manifold shape + */ + manifold: T; + /** + * The normal vector of the plane to be mirrored over + * @default [1,0,0] + */ + normal: Base.Vector3; + } + class Scale3DDto { + constructor(manifold?: T, vector?: Base.Vector3); + /** + * Manifold shape + */ + manifold: T; + /** + * The normal vector of the plane to be mirrored over + * @default [2,2,2] + */ + vector: Base.Vector3; + } + class TranslateDto { + constructor(manifold?: T, vector?: Base.Vector3); + /** + * Manifold shape + */ + manifold: T; + /** + * The translation vector + * @default undefined + */ + vector: Base.Vector3; + } + class TranslateByVectorsDto { + constructor(manifold?: T, vectors?: Base.Vector3[]); + /** + * Manifold shape + */ + manifold: T; + /** + * The translation vector + * @default undefined + */ + vectors: Base.Vector3[]; + } + class RotateDto { + constructor(manifold?: T, vector?: Base.Vector3); + /** + * Manifold shape + */ + manifold: T; + /** + * The rotation vector in eulers + * @default undefined + */ + vector: Base.Vector3; + } + class RotateXYZDto { + constructor(manifold?: T, x?: number, y?: number, z?: number); + /** + * Manifold shape + */ + manifold: T; + /** + * The rotation vector in eulers on X axis + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 1 + */ + x: number; + /** + * The rotation vector in eulers on Y axis + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 1 + */ + y: number; + /** + * The rotation vector in eulers on Z axis + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 1 + */ + z: number; + } + class ScaleDto { + constructor(manifold?: T, factor?: number); + /** + * Manifold shape + */ + manifold: T; + /** + * The normal vector of the plane to be mirrored over + * @default 2 + */ + factor: number; + } + class TranslateXYZDto { + constructor(manifold?: T, x?: number, y?: number, z?: number); + /** + * Manifold shape + */ + manifold: T; + /** + * The translation X axis + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 1 + */ + x: number; + /** + * The translation Y axis + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 1 + */ + y: number; + /** + * The translation Z axis + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 1 + */ + z: number; + } + class TransformDto { + constructor(manifold?: T, transform?: Base.TransformMatrix); + /** + * Manifold shape + */ + manifold: T; + /** + * The transform matrix to apply + * @default undefined + */ + transform: Base.TransformMatrix; + } + class TransformsDto { + constructor(manifold?: T, transforms?: Base.TransformMatrixes); + /** + * Manifold shape + */ + manifold: T; + /** + * The transform matrixes to apply + * @default undefined + */ + transforms: Base.TransformMatrixes; + } + class ManifoldWarpDto { + constructor(manifold?: T, warpFunc?: (vert: Base.Vector3) => void); + /** + * Manifold shape + */ + manifold: T; + /** + * A function that modifies a given vertex position + * @default undefined + */ + warpFunc: (vert: Base.Vector3) => void; + } + class TwoCrossSectionsDto { + constructor(crossSection1?: T, crossSection2?: T); + /** + * Manifold shape + */ + crossSection1: T; + /** + * Manifold shape + */ + crossSection2: T; + } + class TwoManifoldsDto { + constructor(manifold1?: T, manifold2?: T); + /** + * Manifold shape + */ + manifold1: T; + /** + * Manifold shape + */ + manifold2: T; + } + class SplitManifoldsDto { + constructor(manifoldToSplit?: T, manifoldCutter?: T); + /** + * Manifold that will be split + */ + manifoldToSplit: T; + /** + * Manifold cutter + */ + manifoldCutter: T; + } + class TrimByPlaneDto { + constructor(manifold?: T, normal?: Base.Vector3, originOffset?: number); + /** + * Manifold that will be trimmed + */ + manifold: T; + /** + * The normal vector of the plane to be mirrored over + * @default [1,0,0] + */ + normal: Base.Vector3; + /** + * The offset from the origin + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + originOffset: number; + } + class SplitByPlaneDto { + constructor(manifold?: T, normal?: Base.Vector3, originOffset?: number); + /** + * Manifold that will be split + */ + manifold: T; + /** + * The normal vector of the plane to be mirrored over + * @default [1,0,0] + */ + normal: Base.Vector3; + /** + * The offset from the origin + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + originOffset: number; + } + class SplitByPlaneOnOffsetsDto { + constructor( + manifold?: T, + normal?: Base.Vector3, + originOffsets?: number[] + ); + /** + * Manifold that will be split + */ + manifold: T; + /** + * The normal vector of the plane to be mirrored over + * @default [1,0,0] + */ + normal: Base.Vector3; + /** + * The offsets from the origin + * @default [0] + */ + originOffsets: number[]; + } + class ManifoldsDto { + constructor(manifolds?: T[]); + /** + * Manifolds + */ + manifolds: T[]; + } + class ManifoldToMeshDto { + constructor(manifold?: T, normalIdx?: number); + /** + * Manifold shape + */ + manifold: T; + /** + * Optional normal index + */ + normalIdx?: number; + } + class ManifoldsToMeshesDto { + constructor(manifolds?: T[], normalIdx?: number[]); + /** + * Manifold shape + */ + manifolds: T[]; + /** + * Optional normal indexes + */ + normalIdx?: number[]; + } + class DecomposeManifoldOrCrossSectionDto { + constructor(manifoldOrCrossSection?: T, normalIdx?: number); + /** + * Manifold shape + */ + manifoldOrCrossSection: T; + /** + * Optional normal index + */ + normalIdx?: number; + } + class ManifoldOrCrossSectionDto { + constructor(manifoldOrCrossSection?: T); + /** + * Manifold or cross section + */ + manifoldOrCrossSection: T; + } + class ManifoldsOrCrossSectionsDto { + constructor(manifoldsOrCrossSections?: T[]); + /** + * Manifolds or cross sections + */ + manifoldsOrCrossSections: T[]; + } + class DecomposeManifoldsOrCrossSectionsDto { + constructor(manifoldsOrCrossSections?: T[], normalIdx?: number[]); + /** + * Manifold shape + */ + manifoldsOrCrossSections: T[]; + /** + * Optional normal indexes + */ + normalIdx?: number[]; + } + } + declare namespace OCCT { + type GeomCurvePointer = { + hash: number; + type: string; + }; + type Geom2dCurvePointer = { + hash: number; + type: string; + }; + type GeomSurfacePointer = { + hash: number; + type: string; + }; + type TopoDSVertexPointer = { + hash: number; + type: string; + }; + type TopoDSEdgePointer = { + hash: number; + type: string; + }; + type TopoDSWirePointer = { + hash: number; + type: string; + }; + type TopoDSFacePointer = { + hash: number; + type: string; + }; + type TopoDSShellPointer = { + hash: number; + type: string; + }; + type TopoDSSolidPointer = { + hash: number; + type: string; + }; + type TopoDSCompSolidPointer = { + hash: number; + type: string; + }; + type TopoDSCompoundPointer = { + hash: number; + type: string; + }; + type TopoDSShapePointer = + | TopoDSVertexPointer + | TopoDSEdgePointer + | TopoDSWirePointer + | TopoDSFacePointer + | TopoDSShellPointer + | TopoDSSolidPointer + | TopoDSCompoundPointer; + enum joinTypeEnum { + arc = "arc", + intersection = "intersection", + tangent = "tangent", + } + enum bRepOffsetModeEnum { + skin = "skin", + pipe = "pipe", + rectoVerso = "rectoVerso", + } + enum approxParametrizationTypeEnum { + approxChordLength = "approxChordLength", + approxCentripetal = "approxCentripetal", + approxIsoParametric = "approxIsoParametric", + } + enum directionEnum { + outside = "outside", + inside = "inside", + middle = "middle", + } + enum fileTypeEnum { + iges = "iges", + step = "step", + } + enum topAbsOrientationEnum { + forward = "forward", + reversed = "reversed", + internal = "internal", + external = "external", + } + enum topAbsStateEnum { + in = "in", + out = "out", + on = "on", + unknown = "unknown", + } + enum shapeTypeEnum { + unknown = "unknown", + vertex = "vertex", + edge = "edge", + wire = "wire", + face = "face", + shell = "shell", + solid = "solid", + compSolid = "compSolid", + compound = "compound", + shape = "shape", + } + enum gccEntPositionEnum { + unqualified = "unqualified", + enclosing = "enclosing", + enclosed = "enclosed", + outside = "outside", + noqualifier = "noqualifier", + } + enum positionResultEnum { + keepSide1 = "keepSide1", + keepSide2 = "keepSide2", + all = "all", + } + enum circleInclusionEnum { + none = "none", + keepSide1 = "keepSide1", + keepSide2 = "keepSide2", + } + enum twoCircleInclusionEnum { + none = "none", + outside = "outside", + inside = "inside", + outsideInside = "outsideInside", + insideOutside = "insideOutside", + } + enum fourSidesStrictEnum { + outside = "outside", + inside = "inside", + outsideInside = "outsideInside", + insideOutside = "insideOutside", + } + enum twoSidesStrictEnum { + outside = "outside", + inside = "inside", + } + enum combinationCirclesForFaceEnum { + allWithAll = "allWithAll", + inOrder = "inOrder", + inOrderClosed = "inOrderClosed", + } + enum typeSpecificityEnum { + curve = 0, + edge = 1, + wire = 2, + face = 3, + } + enum pointProjectionTypeEnum { + all = "all", + closest = "closest", + furthest = "furthest", + closestAndFurthest = "closestAndFurthest", + } + enum geomFillTrihedronEnum { + isCorrectedFrenet = "isCorrectedFrenet", + isFixed = "isFixed", + isFrenet = "isFrenet", + isConstantNormal = "isConstantNormal", + isDarboux = "isDarboux", + isGuideAC = "isGuideAC", + isGuidePlan = "isGuidePlan", + isGuideACWithContact = "isGuideACWithContact", + isGuidePlanWithContact = "isGuidePlanWithContact", + isDiscreteTrihedron = "isDiscreteTrihedron", + } + enum dxfColorFormatEnum { + aci = "aci", + truecolor = "truecolor", + } + enum dxfAcadVersionEnum { + AC1009 = "AC1009", + AC1015 = "AC1015", + } + enum dimensionEndTypeEnum { + none = "none", + arrow = "arrow", + } + class DecomposedMeshDto { + constructor( + faceList?: DecomposedFaceDto[], + edgeList?: DecomposedEdgeDto[] + ); + /** + * Face list for decomposed faces + */ + faceList: DecomposedFaceDto[]; + /** + * Edge list for decomposed edges + */ + edgeList: DecomposedEdgeDto[]; + /** + * The points list in a shape that includes vertex shapes + */ + pointsList: Base.Point3[]; + } + class DecomposedFaceDto { + face_index: number; + normal_coord: number[]; + number_of_triangles: number; + tri_indexes: number[]; + vertex_coord: number[]; + vertex_coord_vec: Base.Vector3[]; + center_point: Base.Point3; + center_normal: Base.Vector3; + uvs: number[]; + } + class DecomposedEdgeDto { + edge_index: number; + middle_point: Base.Point3; + vertex_coord: Base.Vector3[]; + } + class ShapesDto { + constructor(shapes?: T[]); + /** + * The OCCT shapes + * @default undefined + */ + shapes: T[]; + } + class PointDto { + constructor(point?: Base.Point3); + /** + * The point + * @default [0, 0, 0] + */ + point: Base.Point3; + } + class XYZDto { + constructor(x?: number, y?: number, z?: number); + /** + * X coord + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + x: number; + /** + * Y coord + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + y: number; + /** + * Z coord + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + z: number; + } + class PointsDto { + constructor(points?: Base.Point3[]); + /** + * The point + * @default undefined + */ + points: Base.Point3[]; + } + class ConstraintTanLinesFromPtToCircleDto { + constructor( + circle?: T, + point?: Base.Point3, + tolerance?: number, + positionResult?: positionResultEnum, + circleRemainder?: circleInclusionEnum + ); + /** + * The circle for tangent points + * @default undefined + */ + circle: T; + /** + * The point from which to find the lines + * @default undefined + */ + point: Base.Point3; + /** + * tolerance + * @default 1e-7 + * @minimum 0 + * @maximum Infinity + * @step 0.00001 + */ + tolerance: number; + /** + * Filters resulting lines by position + * @default all + */ + positionResult: positionResultEnum; + /** + * Splits provided circle on tangent points and adds it to the solutions + * This only works when number of solutions contains 2 lines, when solution involves more than 4 lines, this option will be ignored. + * @default none + */ + circleRemainder: circleInclusionEnum; + } + class ConstraintTanLinesFromTwoPtsToCircleDto { + constructor( + circle?: T, + point1?: Base.Point3, + point2?: Base.Point3, + tolerance?: number, + positionResult?: positionResultEnum, + circleRemainder?: circleInclusionEnum + ); + /** + * The circle for tangent points + * @default undefined + */ + circle: T; + /** + * The point from which to find the lines + * @default undefined + */ + point1: Base.Point3; + /** + * The point from which to find the lines + * @default undefined + */ + point2: Base.Point3; + /** + * tolerance + * @default 1e-7 + * @minimum 0 + * @maximum Infinity + * @step 0.00001 + */ + tolerance: number; + /** + * Filters resulting lines by position + * @default all + */ + positionResult: positionResultEnum; + /** + * Splits provided circle on tangent points and adds it to the solutions + * This only works when number of solutions contains 2 lines, when solution involves more than 4 lines, this option will be ignored. + * @default none + */ + circleRemainder: circleInclusionEnum; + } + class ConstraintTanLinesOnTwoCirclesDto { + constructor( + circle1?: T, + circle2?: T, + tolerance?: number, + positionResult?: positionResultEnum, + circleRemainders?: twoCircleInclusionEnum + ); + /** + * The first circle for tangential lines + * @default undefined + */ + circle1: T; + /** + * The second circle for tangential lines + * @default undefined + */ + circle2: T; + /** + * tolerance + * @default 1e-7 + * @minimum 0 + * @maximum Infinity + * @step 0.00001 + */ + tolerance: number; + /** + * Filters resulting lines by position relative to circles + * @default all + */ + positionResult: positionResultEnum; + /** + * Splits provided circles on tangent points and returns those as part of the solutions + * This only works when number of solutions is limited to 2 lines, when solution involves more than 4 lines, this option will be ignored. + * @default none + */ + circleRemainders: twoCircleInclusionEnum; + } + class ConstraintTanCirclesOnTwoCirclesDto { + constructor( + circle1?: T, + circle2?: T, + tolerance?: number, + radius?: number + ); + /** + * The first circle for tangential lines + * @default undefined + */ + circle1: T; + /** + * The second circle for tangential lines + * @default undefined + */ + circle2: T; + /** + * tolerance + * @default 1e-7 + * @minimum 0 + * @maximum Infinity + * @step 0.00001 + */ + tolerance: number; + /** + * Radius of the circles being constructed + * @default 0.3 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + radius: number; + } + class ConstraintTanCirclesOnCircleAndPntDto { + constructor( + circle?: T, + point?: Base.Point3, + tolerance?: number, + radius?: number + ); + /** + * The first circle for tangential lines + * @default undefined + */ + circle: T; + /** + * The second circle for tangential lines + * @default undefined + */ + point: Base.Point3; + /** + * tolerance + * @default 1e-7 + * @minimum 0 + * @maximum Infinity + * @step 0.00001 + */ + tolerance: number; + /** + * Radius of the circles being constructed + * @default 0.3 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + radius: number; + } + class CurveAndSurfaceDto { + constructor(curve?: T, surface?: U); + /** + * Curve + * @default undefined + */ + curve: T; + /** + * Surface + * @default undefined + */ + surface: U; + } + class FilletTwoEdgesInPlaneDto { + constructor( + edge1?: T, + edge2?: T, + planeOrigin?: Base.Point3, + planeDirection?: Base.Vector3, + radius?: number, + solution?: number + ); + /** + * First OCCT edge to fillet + * @default undefined + */ + edge1: T; + /** + * Second OCCT edge to fillet + * @default undefined + */ + edge2: T; + /** + * Plane origin that is also used to find the closest solution if two solutions exist. + * @default [0, 0, 0] + */ + planeOrigin: Base.Point3; + /** + * Plane direction for fillet + * @default [0, 1, 0] + */ + planeDirection: Base.Vector3; + /** + * Radius of the fillet + * @default 0.3 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + radius: number; + /** + * if solution is -1 planeOrigin chooses a particular fillet in case of several fillets may be constructed (for example, a circle intersecting a segment in 2 points). Put the intersecting (or common) point of the edges + * @default -1 + * @optional true + */ + solution?: number; + } + class ClosestPointsOnShapeFromPointsDto { + constructor(shape?: T, points?: Base.Point3[]); + /** + * The OCCT shape + * @default undefined + */ + shape: T; + /** + * The list of points + * @default undefined + */ + points: Base.Point3[]; + } + class BoundingBoxDto { + constructor(bbox?: BoundingBoxPropsDto); + /** + * Bounding box + * @default undefined + */ + bbox?: BoundingBoxPropsDto; + } + class BoundingBoxPropsDto { + constructor( + min?: Base.Point3, + max?: Base.Point3, + center?: Base.Point3, + size?: Base.Vector3 + ); + /** + * Minimum point of the bounding box + * @default [0, 0, 0] + */ + min: Base.Point3; + /** + * Maximum point of the bounding box + * @default [0, 0, 0] + */ + max: Base.Point3; + /** + * Center point of the bounding box + * @default [0, 0, 0] + */ + center: Base.Point3; + /** + * Size of the bounding box + * @default [0, 0, 0] + */ + size: Base.Vector3; + } + class BoundingSpherePropsDto { + constructor(center?: Base.Point3, radius?: number); + /** + * Center point of the bounding box + * @default [0, 0, 0] + */ + center: Base.Point3; + /** + * Radius of the bounding sphere + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + radius: number; + } + class SplitWireOnPointsDto { + constructor(shape?: T, points?: Base.Point3[]); + /** + * The OCCT wire shape + * @default undefined + */ + shape: T; + /** + * The list of points + * @default undefined + */ + points: Base.Point3[]; + } + class ClosestPointsOnShapesFromPointsDto { + constructor(shapes?: T[], points?: Base.Point3[]); + /** + * The OCCT shapes + * @default undefined + */ + shapes: T[]; + /** + * The list of points + * @default undefined + */ + points: Base.Point3[]; + } + class ClosestPointsBetweenTwoShapesDto { + constructor(shape1?: T, shape2?: T); + /** + * First OCCT shape + * @default undefined + */ + shape1: T; + /** + * Second OCCT shape + * @default undefined + */ + shape2: T; + } + class FaceFromSurfaceAndWireDto { + constructor(surface?: T, wire?: U, inside?: boolean); + /** + * Surface from which to create a face + * @default undefined + */ + surface: T; + /** + * Wire that represents a boundary on the surface to delimit the face + * @default undefined + */ + wire: U; + /** + * Indicates wether face should be created inside or outside the wire + * @default true + */ + inside: boolean; + } + class WireOnFaceDto { + constructor(wire?: T, face?: U); + /** + * Wire to place on face + * @default undefined + */ + wire: T; + /** + * Face on which the wire will be placed + * @default undefined + */ + face: U; + } + class DrawShapeDto { + /** + * Provide options without default values + */ + constructor( + shape?: T, + faceOpacity?: number, + edgeOpacity?: number, + edgeColour?: Base.Color, + faceMaterial?: Base.Material, + faceColour?: Base.Color, + edgeWidth?: number, + drawEdges?: boolean, + drawFaces?: boolean, + drawVertices?: boolean, + vertexColour?: Base.Color, + vertexSize?: number, + precision?: number, + drawEdgeIndexes?: boolean, + edgeIndexHeight?: number, + edgeIndexColour?: Base.Color, + drawFaceIndexes?: boolean, + faceIndexHeight?: number, + faceIndexColour?: Base.Color, + drawTwoSided?: boolean, + backFaceColour?: Base.Color, + backFaceOpacity?: number + ); + /** + * Brep OpenCascade geometry + * @default undefined + */ + shape?: T; + /** + * Face opacity value between 0 and 1 + * @default 1 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + faceOpacity: number; + /** + * Edge opacity value between 0 and 1 + * @default 1 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + edgeOpacity: number; + /** + * Hex colour string for the edges + * @default #ffffff + */ + edgeColour: Base.Color; + /** + * Face material + * @default undefined + * @optional true + */ + faceMaterial?: Base.Material; + /** + * Hex colour string for face colour + * @default #ff0000 + */ + faceColour: Base.Color; + /** + * Edge width + * @default 2 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + edgeWidth: number; + /** + * You can turn off drawing of edges via this property + * @default true + */ + drawEdges: boolean; + /** + * You can turn off drawing of faces via this property + * @default true + */ + drawFaces: boolean; + /** + * You can turn off drawing of vertexes via this property + * @default false + */ + drawVertices: boolean; + /** + * Color of the vertices that will be drawn + * @default #ff00ff + */ + vertexColour: string; + /** + * The size of a vertices that will be drawn + * @default 0.03 + * @minimum 0 + * @maximum Infinity + * @step 0.01 + */ + vertexSize: number; + /** + * Precision of the mesh that will be generated for the shape, lower number will mean more triangles + * @default 0.01 + * @minimum 0 + * @maximum Infinity + * @step 0.01 + */ + precision: number; + /** + * Draw index of edges in space + * @default false + */ + drawEdgeIndexes: boolean; + /** + * Indicates the edge index height if they are drawn + * @default 0.06 + * @minimum 0 + * @maximum Infinity + * @step 0.01 + */ + edgeIndexHeight: number; + /** + * Edge index colour if the edges are drawn + * @default #ff00ff + */ + edgeIndexColour: Base.Color; + /** + * Draw indexes of faces in space + * @default false + */ + drawFaceIndexes: boolean; + /** + * Indicates the edge index height if they are drawn + * @default 0.06 + * @minimum 0 + * @maximum Infinity + * @step 0.01 + */ + faceIndexHeight: number; + /** + * Edge index colour if the edges are drawn + * @default #0000ff + */ + faceIndexColour: Base.Color; + /** + * Draw two-sided faces with different colors for front and back. This helps visualize face orientation. + * @default true + */ + drawTwoSided: boolean; + /** + * Hex colour string for back face colour (negative side of the face). Only used when drawTwoSided is true. + * @default #0000ff + */ + backFaceColour: Base.Color; + /** + * Back face opacity value between 0 and 1. Only used when drawTwoSided is true. + * @default 1 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + backFaceOpacity: number; + } + class DrawShapesDto { + /** + * Provide options without default values + */ + constructor( + shapes?: T[], + faceOpacity?: number, + edgeOpacity?: number, + edgeColour?: Base.Color, + faceMaterial?: Base.Material, + faceColour?: Base.Color, + edgeWidth?: number, + drawEdges?: boolean, + drawFaces?: boolean, + drawVertices?: boolean, + vertexColour?: Base.Color, + vertexSize?: number, + precision?: number, + drawEdgeIndexes?: boolean, + edgeIndexHeight?: number, + edgeIndexColour?: Base.Color, + drawFaceIndexes?: boolean, + faceIndexHeight?: number, + faceIndexColour?: Base.Color, + drawTwoSided?: boolean, + backFaceColour?: Base.Color, + backFaceOpacity?: number + ); + /** + * Brep OpenCascade geometry + * @default undefined + */ + shapes: T[]; + /** + * Face opacity value between 0 and 1 + * @default 1 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + faceOpacity: number; + /** + * Edge opacity value between 0 and 1 + * @default 1 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + edgeOpacity: number; + /** + * Hex colour string for the edges + * @default #ffffff + */ + edgeColour: Base.Color; + /** + * Face material + * @default undefined + * @optional true + */ + faceMaterial?: Base.Material; + /** + * Hex colour string for face colour + * @default #ff0000 + */ + faceColour: Base.Color; + /** + * Edge width + * @default 2 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + edgeWidth: number; + /** + * You can turn off drawing of edges via this property + * @default true + */ + drawEdges: boolean; + /** + * You can turn off drawing of faces via this property + * @default true + */ + drawFaces: boolean; + /** + * You can turn off drawing of vertexes via this property + * @default false + */ + drawVertices: boolean; + /** + * Color of the vertices that will be drawn + * @default #ff00ff + */ + vertexColour: string; + /** + * The size of a vertices that will be drawn + * @default 0.03 + * @minimum 0 + * @maximum Infinity + * @step 0.01 + */ + vertexSize: number; + /** + * Precision of the mesh that will be generated for the shape, lower number will mean more triangles + * @default 0.01 + * @minimum 0 + * @maximum Infinity + * @step 0.01 + */ + precision: number; + /** + * Draw index of edges in space + * @default false + */ + drawEdgeIndexes: boolean; + /** + * Indicates the edge index height if they are drawn + * @default 0.06 + * @minimum 0 + * @maximum Infinity + * @step 0.01 + */ + edgeIndexHeight: number; + /** + * Edge index colour if the edges are drawn + * @default #ff00ff + */ + edgeIndexColour: Base.Color; + /** + * Draw indexes of faces in space + * @default false + */ + drawFaceIndexes: boolean; + /** + * Indicates the edge index height if they are drawn + * @default 0.06 + * @minimum 0 + * @maximum Infinity + * @step 0.01 + */ + faceIndexHeight: number; + /** + * Edge index colour if the edges are drawn + * @default #0000ff + */ + faceIndexColour: Base.Color; + /** + * Draw two-sided faces with different colors for front and back. This helps visualize face orientation. + * @default true + */ + drawTwoSided: boolean; + /** + * Hex colour string for back face colour (negative side of the face). Only used when drawTwoSided is true. + * @default #0000ff + */ + backFaceColour: Base.Color; + /** + * Back face opacity value between 0 and 1. Only used when drawTwoSided is true. + * @default 1 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + backFaceOpacity: number; + } + class FaceSubdivisionDto { + /** + * Provide options without default values + */ + constructor( + shape?: T, + nrDivisionsU?: number, + nrDivisionsV?: number, + shiftHalfStepU?: boolean, + removeStartEdgeU?: boolean, + removeEndEdgeU?: boolean, + shiftHalfStepV?: boolean, + removeStartEdgeV?: boolean, + removeEndEdgeV?: boolean + ); + /** + * Brep OpenCascade geometry + * @default undefined + */ + shape: T; + /** + * Number of points that will be added on U direction + * @default 10 + * @minimum 1 + * @maximum Infinity + * @step 1 + */ + nrDivisionsU: number; + /** + * Number of points that will be added on V direction + * @default 10 + * @minimum 1 + * @maximum Infinity + * @step 1 + */ + nrDivisionsV: number; + /** + * Sometimes you want to shift your points half way the step distance, especially on periodic surfaces + * @default false + */ + shiftHalfStepU: boolean; + /** + * Removes start edge points on U + * @default false + */ + removeStartEdgeU: boolean; + /** + * Removes end edge points on U + * @default false + */ + removeEndEdgeU: boolean; + /** + * Sometimes you want to shift your points half way the step distance, especially on periodic surfaces + * @default false + */ + shiftHalfStepV: boolean; + /** + * Removes start edge points on V + * @default false + */ + removeStartEdgeV: boolean; + /** + * Removes end edge points on V + * @default false + */ + removeEndEdgeV: boolean; + } + class FaceSubdivisionToWiresDto { + /** + * Provide options without default values + */ + constructor( + shape?: T, + nrDivisions?: number, + isU?: boolean, + shiftHalfStep?: boolean, + removeStart?: boolean, + removeEnd?: boolean + ); + /** + * Openascade Face + * @default undefined + */ + shape: T; + /** + * Number of points that will be added on U direction + * @default 10 + * @minimum 1 + * @maximum Infinity + * @step 1 + */ + nrDivisions: number; + /** + * Linear subdivision direction true - U, false - V + * @default true + */ + isU: boolean; + /** + * Sometimes you want to shift your wires half way the step distance, especially on periodic surfaces + * @default false + */ + shiftHalfStep: boolean; + /** + * Removes start wire + * @default false + */ + removeStart: boolean; + /** + * Removes end wire + * @default false + */ + removeEnd: boolean; + } + class FaceSubdivideToRectangleWiresDto { + /** + * Provide options without default values + */ + constructor( + shape?: T, + nrRectanglesU?: number, + nrRectanglesV?: number, + scalePatternU?: number[], + scalePatternV?: number[], + filletPattern?: number[], + inclusionPattern?: boolean[], + offsetFromBorderU?: number, + offsetFromBorderV?: number + ); + /** + * Openascade Face + * @default undefined + */ + shape: T; + /** + * Number of rectangles on U direction + * @default 10 + * @minimum 1 + * @maximum Infinity + * @step 1 + */ + nrRectanglesU: number; + /** + * Number of rectangles on V direction + * @default 10 + * @minimum 1 + * @maximum Infinity + * @step 1 + */ + nrRectanglesV: number; + /** + * Rectangle scale pattern on u direction - numbers between 0 and 1, if 1 or undefined is used, no scaling is applied + * @default undefined + * @optional true + */ + scalePatternU: number[]; + /** + * Rectangle scale pattern on v direction - numbers between 0 and 1, if 1 or undefined is used, no scaling is applied + * @default undefined + * @optional true + */ + scalePatternV: number[]; + /** + * Rectangle fillet scale pattern - numbers between 0 and 1, if 0 is used, no fillet is applied, + * if 1 is used, the fillet will be exactly half of the length of the shorter side of the rectangle + * @default undefined + * @optional true + */ + filletPattern: number[]; + /** + * Rectangle inclusion pattern - true means that the rectangle will be included, + * false means that the rectangle will be removed from the face + * @default undefined + * @optional true + */ + inclusionPattern: boolean[]; + /** + * If offset on U is bigger then 0 we will use a smaller space for rectangles to be placed. This means that even rectangle of U param 1 will be offset from the face border + * That is often required to create a pattern that is not too close to the face border + * It should not be bigger then half of the total width of the face as that will create problems + * @default 0 + * @minimum 0 + * @maximum 0.5 + * @step 0.01 + */ + offsetFromBorderU: number; + /** + * If offset on V is bigger then 0 we will use a smaller space for rectangles to be placed. This means that even rectangle of V param 1 will be offset from the face border + * That is often required to create a pattern that is not too close to the face border + * It should not be bigger then half of the total width of the face as that will create problems + * @default 0 + * @minimum 0 + * @maximum 0.5 + * @step 0.01 + */ + offsetFromBorderV: number; + } + class FaceSubdivideToHexagonWiresDto { + /** + * Provide options without default values + */ + constructor( + shape?: T, + nrHexagonsU?: number, + nrHexagonsV?: number, + flatU?: boolean, + scalePatternU?: number[], + scalePatternV?: number[], + filletPattern?: number[], + inclusionPattern?: boolean[], + offsetFromBorderU?: number, + offsetFromBorderV?: number, + extendUUp?: boolean, + extendUBottom?: boolean, + extendVUp?: boolean, + extendVBottom?: boolean + ); + /** + * Openascade Face + * @default undefined + */ + shape?: T; + /** + * Number of hexagons on U direction + * @default 10 + * @minimum 1 + * @maximum Infinity + * @step 1 + */ + nrHexagonsU?: number; + /** + * Number of hexagons on V direction + * @default 10 + * @minimum 1 + * @maximum Infinity + * @step 1 + */ + nrHexagonsV?: number; + flatU: boolean; + /** + * Hexagon scale pattern on u direction - numbers between 0 and 1, if 1 or undefined is used, no scaling is applied + * @default undefined + * @optional true + */ + scalePatternU?: number[]; + /** + * Hexagon scale pattern on v direction - numbers between 0 and 1, if 1 or undefined is used, no scaling is applied + * @default undefined + * @optional true + */ + scalePatternV?: number[]; + /** + * Hexagon fillet scale pattern - numbers between 0 and 1, if 0 is used, no fillet is applied, + * if 1 is used, the fillet will be exactly half of the length of the shortest segment of the hexagon + * @default undefined + * @optional true + */ + filletPattern?: number[]; + /** + * Hexagon inclusion pattern - true means that the hexagon will be included, + * false means that the hexagon will be removed from the face + * @default undefined + * @optional true + */ + inclusionPattern?: boolean[]; + /** + * If offset on U is bigger then 0 we will use a smaller space for hexagons to be placed. This means that even hexagon of U param 1 will be offset from the face border + * That is often required to create a pattern that is not too close to the face border + * It should not be bigger then half of the total width of the face as that will create problems + * @default 0 + * @minimum 0 + * @maximum 0.5 + * @step 0.01 + */ + offsetFromBorderU?: number; + /** + * If offset on V is bigger then 0 we will use a smaller space for hexagons to be placed. This means that even hexagon of V param 1 will be offset from the face border + * That is often required to create a pattern that is not too close to the face border + * It should not be bigger then half of the total width of the face as that will create problems + * @default 0 + * @minimum 0 + * @maximum 0.5 + * @step 0.01 + */ + offsetFromBorderV?: number; + /** + * If true, we will extend the hexagons beyond the face u up border by their pointy tops + * @default false + */ + extendUUp?: boolean; + /** + * If true, we will extend the hexagons beyond the face u bottom border by their pointy tops + * @default false + */ + extendUBottom?: boolean; + /** + * If true, we will extend the hexagons beyond the face v upper border by their half width + * @default false + */ + extendVUp?: boolean; + /** + * If true, we will extend the hexagons beyond the face v bottom border by their half width + * @default false + */ + extendVBottom?: boolean; + } + class FaceSubdivideToHexagonHolesDto { + /** + * Provide options without default values + */ + constructor( + shape?: T, + nrHexagonsU?: number, + nrHexagonsV?: number, + flatU?: boolean, + holesToFaces?: boolean, + scalePatternU?: number[], + scalePatternV?: number[], + filletPattern?: number[], + inclusionPattern?: boolean[], + offsetFromBorderU?: number, + offsetFromBorderV?: number + ); + /** + * Openascade Face + * @default undefined + */ + shape?: T; + /** + * Number of hexagons on U direction + * @default 10 + * @minimum 1 + * @maximum Infinity + * @step 1 + */ + nrHexagonsU?: number; + /** + * Number of hexagons on V direction + * @default 10 + * @minimum 1 + * @maximum Infinity + * @step 1 + */ + nrHexagonsV?: number; + flatU: boolean; + /** + * If true, we will also create holes as faces + * @default false + */ + holesToFaces?: boolean; + /** + * Hexagon scale pattern on u direction - numbers between 0 and 1, if 1 or undefined is used, no scaling is applied + * @default undefined + * @optional true + */ + scalePatternU?: number[]; + /** + * Hexagon scale pattern on v direction - numbers between 0 and 1, if 1 or undefined is used, no scaling is applied + * @default undefined + * @optional true + */ + scalePatternV?: number[]; + /** + * Hexagon fillet scale pattern - numbers between 0 and 1, if 0 is used, no fillet is applied, + * if 1 is used, the fillet will be exactly half of the length of the shortest segment of the hexagon + * @default undefined + * @optional true + */ + filletPattern?: number[]; + /** + * Hexagon inclusion pattern - true means that the hexagon will be included, + * false means that the hexagon will be removed from the face + * @default undefined + * @optional true + */ + inclusionPattern?: boolean[]; + /** + * If offset on U is bigger then 0 we will use a smaller space for hexagons to be placed. This means that even hexagon of U param 1 will be offset from the face border + * That is often required to create a pattern that is not too close to the face border + * It should not be bigger then half of the total width of the face as that will create problems + * @default 0 + * @minimum 0 + * @maximum 0.5 + * @step 0.01 + */ + offsetFromBorderU?: number; + /** + * If offset on V is bigger then 0 we will use a smaller space for hexagons to be placed. This means that even hexagon of V param 1 will be offset from the face border + * That is often required to create a pattern that is not too close to the face border + * It should not be bigger then half of the total width of the face as that will create problems + * @default 0 + * @minimum 0 + * @maximum 0.5 + * @step 0.01 + */ + offsetFromBorderV?: number; + } + class FaceSubdivideToRectangleHolesDto { + /** + * Provide options without default values + */ + constructor( + shape?: T, + nrRectanglesU?: number, + nrRectanglesV?: number, + scalePatternU?: number[], + scalePatternV?: number[], + filletPattern?: number[], + inclusionPattern?: boolean[], + holesToFaces?: boolean, + offsetFromBorderU?: number, + offsetFromBorderV?: number + ); + /** + * Openascade Face + * @default undefined + */ + shape: T; + /** + * Number of rectangles on U direction + * @default 10 + * @minimum 1 + * @maximum Infinity + * @step 1 + */ + nrRectanglesU: number; + /** + * Number of rectangles on V direction + * @default 10 + * @minimum 1 + * @maximum Infinity + * @step 1 + */ + nrRectanglesV: number; + /** + * Rectangle scale pattern on u direction - numbers between 0 and 1, if 1 or undefined is used, no scaling is applied + * @default undefined + * @optional true + */ + scalePatternU: number[]; + /** + * Rectangle scale pattern on v direction - numbers between 0 and 1, if 1 or undefined is used, no scaling is applied + * @default undefined + * @optional true + */ + scalePatternV: number[]; + /** + * Rectangle fillet scale pattern - numbers between 0 and 1, if 0 is used, no fillet is applied, + * if 1 is used, the fillet will be exactly half of the length of the shorter side of the rectangle + * @default undefined + * @optional true + */ + filletPattern: number[]; + /** + * Rectangle inclusion pattern - true means that the rectangle will be included, + * false means that the rectangle will be removed from the face + * @default undefined + * @optional true + */ + inclusionPattern: boolean[]; + /** + * If true, we will also output the faces for all the rectangles. The first face in the result will be the original face with holes punched, while the rest will be the rectangles + * @default false + */ + holesToFaces: boolean; + /** + * If offset on U is bigger then 0 we will use a smaller space for rectangles to be placed. This means that even rectangle of U param 1 will be offset from the face border + * That is often required to create a pattern that is not too close to the face border + * It should not be bigger then half of the total width of the face as that will create problems + * @default 0 + * @minimum 0 + * @maximum 0.5 + * @step 0.01 + */ + offsetFromBorderU: number; + /** + * If offset on V is bigger then 0 we will use a smaller space for rectangles to be placed. This means that even rectangle of V param 1 will be offset from the face border + * That is often required to create a pattern that is not too close to the face border + * It should not be bigger then half of the total width of the face as that will create problems + * @default 0 + * @minimum 0 + * @maximum 0.5 + * @step 0.01 + */ + offsetFromBorderV: number; + } + class FaceSubdivisionControlledDto { + /** + * Provide options without default values + */ + constructor( + shape?: T, + nrDivisionsU?: number, + nrDivisionsV?: number, + shiftHalfStepNthU?: number, + shiftHalfStepUOffsetN?: number, + removeStartEdgeNthU?: number, + removeStartEdgeUOffsetN?: number, + removeEndEdgeNthU?: number, + removeEndEdgeUOffsetN?: number, + shiftHalfStepNthV?: number, + shiftHalfStepVOffsetN?: number, + removeStartEdgeNthV?: number, + removeStartEdgeVOffsetN?: number, + removeEndEdgeNthV?: number, + removeEndEdgeVOffsetN?: number + ); + /** + * Brep OpenCascade geometry + * @default undefined + */ + shape: T; + /** + * Number of subdivisions on U direction + * @default 10 + * @minimum 1 + * @maximum Infinity + * @step 1 + */ + nrDivisionsU: number; + /** + * Number of subdivisions on V direction + * @default 10 + * @minimum 1 + * @maximum Infinity + * @step 1 + */ + nrDivisionsV: number; + /** + * Shift half step every nth U row + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + shiftHalfStepNthU: number; + /** + * Offset for shift half step every nth U row + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + shiftHalfStepUOffsetN: number; + /** + * Removes start edge points on U + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + removeStartEdgeNthU: number; + /** + * Offset for remove start edge points on U + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + removeStartEdgeUOffsetN: number; + /** + * Removes end edge points on U + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + removeEndEdgeNthU: number; + /** + * Offset for remove end edge points on U + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + removeEndEdgeUOffsetN: number; + /** + * Shift half step every nth V row + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + shiftHalfStepNthV: number; + /** + * Offset for shift half step every nth V row + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + shiftHalfStepVOffsetN: number; + /** + * Removes start edge points on V + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + removeStartEdgeNthV: number; + /** + * Offset for remove start edge points on V + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + removeStartEdgeVOffsetN: number; + /** + * Removes end edge points on V + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + removeEndEdgeNthV: number; + /** + * Offset for remove end edge points on V + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + removeEndEdgeVOffsetN: number; + } + class FaceLinearSubdivisionDto { + /** + * Provide options without default values + */ + constructor( + shape?: T, + isU?: boolean, + param?: number, + nrPoints?: number, + shiftHalfStep?: boolean, + removeStartPoint?: boolean, + removeEndPoint?: boolean + ); + /** + * Brep OpenCascade geometry + * @default undefined + */ + shape: T; + /** + * Linear subdivision direction true - U, false - V + * @default true + */ + isU: boolean; + /** + * Param on direction 0 - 1 + * @default 0.5 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + param: number; + /** + * Number of subdivisions on opposite direction + * @default 10 + * @minimum 1 + * @maximum Infinity + * @step 1 + */ + nrPoints: number; + /** + * Sometimes you want to shift your points half way the step distance, especially on periodic surfaces + * @default false + */ + shiftHalfStep: boolean; + /** + * Removes first point + * @default false + */ + removeStartPoint: boolean; + /** + * Removes last point + * @default false + */ + removeEndPoint: boolean; + } + class WireAlongParamDto { + /** + * Provide options without default values + */ + constructor(shape?: T, isU?: boolean, param?: number); + /** + * Brep OpenCascade geometry + * @default undefined + */ + shape: T; + /** + * Linear subdivision direction true - U, false - V + * @default true + */ + isU: boolean; + /** + * Param on direction 0 - 1 + * @default 0.5 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + param: number; + } + class WiresAlongParamsDto { + /** + * Provide options without default values + */ + constructor(shape?: T, isU?: boolean, params?: number[]); + /** + * Brep OpenCascade geometry + * @default undefined + */ + shape: T; + /** + * Linear subdivision direction true - U, false - V + * @default true + */ + isU: boolean; + /** + * Params on direction 0 - 1 + * @default undefined + */ + params: number[]; + } + class DataOnUVDto { + /** + * Provide options without default values + */ + constructor(shape?: T, paramU?: number, paramV?: number); + /** + * Brep OpenCascade geometry + * @default undefined + */ + shape: T; + /** + * Param on U direction 0 to 1 + * @default 0.5 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + paramU: number; + /** + * Param on V direction 0 to 1 + * @default 0.5 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + paramV: number; + } + class DataOnUVsDto { + /** + * Provide options without default values + */ + constructor(shape?: T, paramsUV?: [number, number][]); + /** + * Brep OpenCascade geometry + * @default undefined + */ + shape: T; + /** + * Params uv + * @default [[0.5, 0.5]] + */ + paramsUV: [number, number][]; + } + class PolygonDto { + constructor(points?: Base.Point3[]); + /** + * Points points + * @default undefined + */ + points: Base.Point3[]; + } + class PolygonsDto { + constructor(polygons?: PolygonDto[], returnCompound?: boolean); + /** + * Polygons + * @default undefined + */ + polygons: PolygonDto[]; + /** + * Indicates whether the shapes should be returned as a compound + */ + returnCompound: boolean; + } + class PolylineDto { + constructor(points?: Base.Point3[]); + /** + * Points points + * @default undefined + */ + points: Base.Point3[]; + } + class PolylineBaseDto { + constructor(polyline?: Base.Polyline3); + /** + * Polyline + * @default undefined + */ + polyline: Base.Polyline3; + } + class PolylinesBaseDto { + constructor(polylines?: Base.Polyline3[]); + /** + * Polylines + * @default undefined + */ + polylines: Base.Polyline3[]; + } + class LineBaseDto { + constructor(line?: Base.Line3); + /** + * Line + * @default undefined + */ + line: Base.Line3; + } + class LinesBaseDto { + constructor(lines?: Base.Line3[]); + /** + * Lines + * @default undefined + */ + lines: Base.Line3[]; + } + class SegmentBaseDto { + constructor(segment?: Base.Segment3); + /** + * Segment + * @default undefined + */ + segment: Base.Segment3; + } + class SegmentsBaseDto { + constructor(segments?: Base.Segment3[]); + /** + * Segments + * @default undefined + */ + segments: Base.Segment3[]; + } + class TriangleBaseDto { + constructor(triangle?: Base.Triangle3); + /** + * Triangle + * @default undefined + */ + triangle: Base.Triangle3; + } + class MeshBaseDto { + constructor(mesh?: Base.Mesh3); + /** + * Mesh + * @default undefined + */ + mesh: Base.Mesh3; + } + class PolylinesDto { + constructor(polylines?: PolylineDto[], returnCompound?: boolean); + /** + * Polylines + * @default undefined + */ + polylines: PolylineDto[]; + /** + * Indicates whether the shapes should be returned as a compound + */ + returnCompound: boolean; + } + class SquareDto { + constructor( + size?: number, + center?: Base.Point3, + direction?: Base.Vector3 + ); + /** + * size of square + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + size: number; + /** + * Center of the square + * @default [0, 0, 0] + */ + center: Base.Point3; + /** + * Direction of the square + * @default [0, 1, 0] + */ + direction: Base.Vector3; + } + class RectangleDto { + constructor( + width?: number, + length?: number, + center?: Base.Point3, + direction?: Base.Vector3 + ); + /** + * width of the rectangle + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + width: number; + /** + * Height of the rectangle + * @default 2 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + length: number; + /** + * Center of the rectangle + * @default [0, 0, 0] + */ + center: Base.Point3; + /** + * Direction of the rectangle + * @default [0, 1, 0] + */ + direction: Base.Vector3; + } + class LPolygonDto { + constructor( + widthFirst?: number, + lengthFirst?: number, + widthSecond?: number, + lengthSecond?: number, + align?: directionEnum, + rotation?: number, + center?: Base.Point3, + direction?: Base.Vector3 + ); + /** + * Width of the first side of L polygon + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + widthFirst: number; + /** + * Length of the first side of L polygon + * @default 2 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + lengthFirst: number; + /** + * Width of the second side of L polygon + * @default 0.5 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + widthSecond: number; + /** + * Length of the second side of L polygon + * @default 2 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + lengthSecond: number; + /** + * Indicates if the L polygon should be aligned inside/outside or middle + * @default outside + */ + align: directionEnum; + /** + * Rotation of the L polygon + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 15 + */ + rotation: number; + /** + * Center of the L polygon + * @default [0, 0, 0] + */ + center: Base.Point3; + /** + * Direction of the L polygon + * @default [0, 1, 0] + */ + direction: Base.Vector3; + } + class IBeamProfileDto { + constructor( + width?: number, + height?: number, + webThickness?: number, + flangeThickness?: number, + alignment?: Base.basicAlignmentEnum, + rotation?: number, + center?: Base.Point3, + direction?: Base.Vector3 + ); + /** + * Width of the I-beam (flange width) + * @default 2 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + width: number; + /** + * Height of the I-beam + * @default 3 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + height: number; + /** + * Thickness of the web (vertical part) + * @default 0.2 + * @minimum 0 + * @maximum Infinity + * @step 0.01 + */ + webThickness: number; + /** + * Thickness of the flanges (horizontal parts) + * @default 0.3 + * @minimum 0 + * @maximum Infinity + * @step 0.01 + */ + flangeThickness: number; + /** + * Alignment of the profile origin + * @default midMid + */ + alignment: Base.basicAlignmentEnum; + /** + * Rotation of the I-beam profile in degrees + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 15 + */ + rotation: number; + /** + * Center of the I-beam profile + * @default [0, 0, 0] + */ + center: Base.Point3; + /** + * Direction of the I-beam profile + * @default [0, 1, 0] + */ + direction: Base.Vector3; + } + class HBeamProfileDto { + constructor( + width?: number, + height?: number, + webThickness?: number, + flangeThickness?: number, + alignment?: Base.basicAlignmentEnum, + rotation?: number, + center?: Base.Point3, + direction?: Base.Vector3 + ); + /** + * Width of the H-beam (flange width) + * @default 2 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + width: number; + /** + * Height of the H-beam + * @default 3 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + height: number; + /** + * Thickness of the web (vertical part) + * @default 0.2 + * @minimum 0 + * @maximum Infinity + * @step 0.01 + */ + webThickness: number; + /** + * Thickness of the flanges (horizontal parts) + * @default 0.3 + * @minimum 0 + * @maximum Infinity + * @step 0.01 + */ + flangeThickness: number; + /** + * Alignment of the profile origin + * @default midMid + */ + alignment: Base.basicAlignmentEnum; + /** + * Rotation of the H-beam profile in degrees + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 15 + */ + rotation: number; + /** + * Center of the H-beam profile + * @default [0, 0, 0] + */ + center: Base.Point3; + /** + * Direction of the H-beam profile + * @default [0, 1, 0] + */ + direction: Base.Vector3; + } + class TBeamProfileDto { + constructor( + width?: number, + height?: number, + webThickness?: number, + flangeThickness?: number, + alignment?: Base.basicAlignmentEnum, + rotation?: number, + center?: Base.Point3, + direction?: Base.Vector3 + ); + /** + * Width of the T-beam (flange width) + * @default 2 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + width: number; + /** + * Height of the T-beam + * @default 2 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + height: number; + /** + * Thickness of the web (vertical part) + * @default 0.2 + * @minimum 0 + * @maximum Infinity + * @step 0.01 + */ + webThickness: number; + /** + * Thickness of the flange (horizontal part) + * @default 0.3 + * @minimum 0 + * @maximum Infinity + * @step 0.01 + */ + flangeThickness: number; + /** + * Alignment of the profile origin + * @default midMid + */ + alignment: Base.basicAlignmentEnum; + /** + * Rotation of the T-beam profile in degrees + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 15 + */ + rotation: number; + /** + * Center of the T-beam profile + * @default [0, 0, 0] + */ + center: Base.Point3; + /** + * Direction of the T-beam profile + * @default [0, 1, 0] + */ + direction: Base.Vector3; + } + class UBeamProfileDto { + constructor( + width?: number, + height?: number, + webThickness?: number, + flangeThickness?: number, + flangeWidth?: number, + alignment?: Base.basicAlignmentEnum, + rotation?: number, + center?: Base.Point3, + direction?: Base.Vector3 + ); + /** + * Overall width of the U-beam + * @default 2 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + width: number; + /** + * Height of the U-beam + * @default 3 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + height: number; + /** + * Thickness of the web (back part) + * @default 0.2 + * @minimum 0 + * @maximum Infinity + * @step 0.01 + */ + webThickness: number; + /** + * Thickness of the flanges (side parts) + * @default 0.3 + * @minimum 0 + * @maximum Infinity + * @step 0.01 + */ + flangeThickness: number; + /** + * Width of the flanges (how far they extend inward) + * @default 0.5 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + flangeWidth: number; + /** + * Alignment of the profile origin + * @default midMid + */ + alignment: Base.basicAlignmentEnum; + /** + * Rotation of the U-beam profile in degrees + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 15 + */ + rotation: number; + /** + * Center of the U-beam profile + * @default [0, 0, 0] + */ + center: Base.Point3; + /** + * Direction of the U-beam profile + * @default [0, 1, 0] + */ + direction: Base.Vector3; + } + class ExtrudedSolidDto { + constructor( + extrusionLengthFront?: number, + extrusionLengthBack?: number, + center?: Base.Point3, + direction?: Base.Vector3 + ); + /** + * Extrusion length in the forward direction + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + extrusionLengthFront: number; + /** + * Extrusion length in the backward direction + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + extrusionLengthBack: number; + /** + * Center of the solid + * @default [0, 0, 0] + */ + center: Base.Point3; + /** + * Direction of extrusion + * @default [0, 1, 0] + */ + direction: Base.Vector3; + } + class IBeamProfileSolidDto extends IBeamProfileDto { + constructor( + width?: number, + height?: number, + webThickness?: number, + flangeThickness?: number, + alignment?: Base.basicAlignmentEnum, + rotation?: number, + center?: Base.Point3, + direction?: Base.Vector3, + extrusionLengthFront?: number, + extrusionLengthBack?: number + ); + /** + * Extrusion length in the forward direction + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + extrusionLengthFront: number; + /** + * Extrusion length in the backward direction + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + extrusionLengthBack: number; + } + class HBeamProfileSolidDto extends HBeamProfileDto { + constructor( + width?: number, + height?: number, + webThickness?: number, + flangeThickness?: number, + alignment?: Base.basicAlignmentEnum, + rotation?: number, + center?: Base.Point3, + direction?: Base.Vector3, + extrusionLengthFront?: number, + extrusionLengthBack?: number + ); + /** + * Extrusion length in the forward direction + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + extrusionLengthFront: number; + /** + * Extrusion length in the backward direction + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + extrusionLengthBack: number; + } + class TBeamProfileSolidDto extends TBeamProfileDto { + constructor( + width?: number, + height?: number, + webThickness?: number, + flangeThickness?: number, + alignment?: Base.basicAlignmentEnum, + rotation?: number, + center?: Base.Point3, + direction?: Base.Vector3, + extrusionLengthFront?: number, + extrusionLengthBack?: number + ); + /** + * Extrusion length in the forward direction + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + extrusionLengthFront: number; + /** + * Extrusion length in the backward direction + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + extrusionLengthBack: number; + } + class UBeamProfileSolidDto extends UBeamProfileDto { + constructor( + width?: number, + height?: number, + webThickness?: number, + flangeThickness?: number, + flangeWidth?: number, + alignment?: Base.basicAlignmentEnum, + rotation?: number, + center?: Base.Point3, + direction?: Base.Vector3, + extrusionLengthFront?: number, + extrusionLengthBack?: number + ); + /** + * Extrusion length in the forward direction + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + extrusionLengthFront: number; + /** + * Extrusion length in the backward direction + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + extrusionLengthBack: number; + } + class BoxDto { + constructor( + width?: number, + length?: number, + height?: number, + center?: Base.Point3, + originOnCenter?: boolean + ); + /** + * Width of the box + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + width: number; + /** + * Length of the box + * @default 2 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + length: number; + /** + * Height of the box + * @default 3 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + height: number; + /** + * Center of the box + * @default [0, 0, 0] + */ + center: Base.Point3; + /** + * Force origin to be on the center of the cube + * @default true + */ + originOnCenter?: boolean; + } + class CubeDto { + constructor( + size?: number, + center?: Base.Point3, + originOnCenter?: boolean + ); + /** + * Size of the cube + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + size: number; + /** + * Center of the box + * @default [0, 0, 0] + */ + center: Base.Point3; + /** + * Force origin to be on the center of the cube + * @default true + */ + originOnCenter?: boolean; + } + class BoxFromCornerDto { + constructor( + width?: number, + length?: number, + height?: number, + corner?: Base.Point3 + ); + /** + * Width of the box + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + width: number; + /** + * Length of the box + * @default 2 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + length: number; + /** + * Height of the box + * @default 3 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + height: number; + /** + * Corner of the box + * @default [0, 0, 0] + */ + corner: Base.Point3; + } + class SphereDto { + constructor(radius?: number, center?: Base.Point3); + /** + * Radius of the sphere + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + radius: number; + /** + * Center of the sphere + * @default [0, 0, 0] + */ + center: Base.Point3; + } + class ConeDto { + constructor( + radius1?: number, + radius2?: number, + height?: number, + angle?: number, + center?: Base.Point3, + direction?: Base.Vector3 + ); + /** + * First radius of the cone + * @default 2 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + radius1: number; + /** + * Second radius of the cone + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + radius2: number; + /** + * Height of the cone + * @default 2 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + height: number; + /** + * Angle of the cone + * @default 360 + * @minimum 0 + * @maximum 360 + * @step 1 + */ + angle: number; + /** + * Center of the cone + * @default [0, 0, 0] + */ + center: Base.Point3; + /** + * Direction of the cone + * @default [0, 1, 0] + */ + direction: Base.Point3; + } + class LineDto { + constructor(start?: Base.Point3, end?: Base.Point3); + /** + * Start of the line + * @default [0, 0, 0] + */ + start: Base.Point3; + /** + * End of the line + * @default [0, 1, 0] + */ + end: Base.Point3; + } + class LineWithExtensionsDto { + constructor( + start?: Base.Point3, + end?: Base.Point3, + extensionStart?: number, + extensionEnd?: number + ); + /** + * Start of the line + * @default [0, 0, 0] + */ + start: Base.Point3; + /** + * End of the line + * @default [0, 1, 0] + */ + end: Base.Point3; + /** + * Extension of the line on the start + * @default 0.1 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + extensionStart: number; + /** + * Extension of the line on the end + * @default 0.1 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + extensionEnd: number; + } + class LinesDto { + constructor(lines?: LineDto[], returnCompound?: boolean); + /** + * Lines + * @default undefined + */ + lines: LineDto[]; + /** + * Indicates whether the shapes should be returned as a compound + */ + returnCompound: boolean; + } + class ArcEdgeTwoPointsTangentDto { + constructor( + start?: Base.Point3, + tangentVec?: Base.Vector3, + end?: Base.Point3 + ); + /** + * Start of the arc + * @default [0, 0, 0] + */ + start: Base.Point3; + /** + * Tangent vector on first point of the edge + * @default [0, 1, 0] + */ + tangentVec: Base.Vector3; + /** + * End of the arc + * @default [0, 0, 1] + */ + end: Base.Point3; + } + class ArcEdgeCircleTwoPointsDto { + constructor( + circle?: T, + start?: Base.Point3, + end?: Base.Point3, + sense?: boolean + ); + /** + * Circular edge + * @default undefined + */ + circle: T; + /** + * Start of the arc on the circle + * @default [0, 0, 0] + */ + start: Base.Point3; + /** + * End of the arc on the circle + * @default [0, 0, 1] + */ + end: Base.Point3; + /** + * If true will sense the direction + * @default true + */ + sense: boolean; + } + class ArcEdgeCircleTwoAnglesDto { + constructor( + circle?: T, + alphaAngle1?: number, + alphaAngle2?: number, + sense?: boolean + ); + /** + * Circular edge + * @default undefined + */ + circle: T; + /** + * First angle + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 1 + */ + alphaAngle1: number; + /** + * End angle + * @default 90 + * @minimum -Infinity + * @maximum Infinity + * @step 1 + */ + alphaAngle2: number; + /** + * If true will sense the direction + * @default true + */ + sense: boolean; + } + class ArcEdgeCirclePointAngleDto { + constructor( + circle?: T, + alphaAngle?: number, + alphaAngle2?: number, + sense?: boolean + ); + /** + * Circular edge + * @default undefined + */ + circle: T; + /** + * Point on the circle from where to start the arc + * @default undefined + */ + point: Base.Point3; + /** + * Angle from point + * @default 90 + * @minimum -Infinity + * @maximum Infinity + * @step 1 + */ + alphaAngle: number; + /** + * If true will sense the direction + * @default true + */ + sense: boolean; + } + class ArcEdgeThreePointsDto { + constructor( + start?: Base.Point3, + middle?: Base.Point3, + end?: Base.Point3 + ); + /** + * Start of the arc + * @default [0, 0, 0] + */ + start: Base.Point3; + /** + * Middle of the arc + * @default [0, 1, 0] + */ + middle: Base.Point3; + /** + * End of the arc + * @default [0, 0, 1] + */ + end: Base.Point3; + } + class CylinderDto { + constructor( + radius?: number, + height?: number, + center?: Base.Point3, + direction?: Base.Vector3, + angle?: number, + originOnCenter?: boolean + ); + /** + * Radius of the cylinder + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + radius: number; + /** + * Height of the cylinder + * @default 2 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + height: number; + /** + * Center of the cylinder + * @default [0, 0, 0] + */ + center: Base.Point3; + /** + * Direction for the cylinder + * @default [0, 1, 0] + */ + direction?: Base.Vector3; + /** + * Angle of the cylinder pie + * @default 360 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + angle?: number; + /** + * Force origin to be on the center of cylinder + * @default false + */ + originOnCenter?: boolean; + } + class CylindersOnLinesDto { + constructor(radius?: number, lines?: Base.Line3[]); + /** + * Radius of the cylinder + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + radius: number; + /** + * Lines between which to span cylinders + * @default undefined + */ + lines: Base.Line3[]; + } + class FilletDto { + constructor( + shape?: T, + radius?: number, + radiusList?: number[], + indexes?: number[] + ); + /** + * Shape to apply the fillets + * @default undefined + */ + shape: T; + /** + * Radius of the fillets + * @default 0.1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + * @optional true + */ + radius?: number; + /** + * Radius list + * @default undefined + * @optional true + */ + radiusList?: number[]; + /** + * List of edge indexes to which apply the fillet, if left empty all edges will be rounded + * @default undefined + * @optional true + */ + indexes?: number[]; + } + class FilletShapesDto { + constructor( + shapes?: T[], + radius?: number, + radiusList?: number[], + indexes?: number[] + ); + /** + * Shapes to apply the fillets + * @default undefined + */ + shapes: T[]; + /** + * Radius of the fillets + * @default 0.1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + * @optional true + */ + radius?: number; + /** + * Radius list + * @default undefined + * @optional true + */ + radiusList?: number[]; + /** + * List of edge indexes to which apply the fillet, if left empty all edges will be rounded + * @default undefined + * @optional true + */ + indexes?: number[]; + } + class FilletEdgesListDto { + constructor(shape?: T, edges?: U[], radiusList?: number[]); + /** + * Shape to apply the fillet + * @default undefined + */ + shape: T; + /** + * Edges to use for the fillet + * @default undefined + */ + edges: U[]; + /** + * Radius list for the fillets. The length of this array must match the length of the edges array. Each index corresponds to fillet on the edge at the same index. + * @default undefined + */ + radiusList: number[]; + } + class FilletEdgesListOneRadiusDto { + constructor(shape?: T, edges?: U[], radius?: number); + /** + * Shape to apply the fillet + * @default undefined + */ + shape: T; + /** + * Edges to use for the fillet + * @default undefined + */ + edges: U[]; + /** + * Radius of the fillets + * @default 0.1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + * @optional true + */ + radius: number; + } + class FilletEdgeVariableRadiusDto { + constructor( + shape?: T, + edge?: U, + radiusList?: number[], + paramsU?: number[] + ); + /** + * Shape to apply the fillet + * @default undefined + */ + shape: T; + /** + * Edge to use for the fillet + * @default undefined + */ + edge: U; + /** + * Radius list for the fillets that has to match the paramsU list + * @default undefined + */ + radiusList: number[]; + /** + * List of parameters on the edge to which apply the fillet. Each param must be between 0 and 1. + * @default undefined + */ + paramsU: number[]; + } + class FilletEdgesVariableRadiusDto { + constructor( + shape?: T, + edges?: U[], + radiusLists?: number[][], + paramsULists?: number[][] + ); + /** + * Shape to apply the fillet + * @default undefined + */ + shape: T; + /** + * Edges to use for the fillet + * @default undefined + */ + edges: U[]; + /** + * Lists of radius lists for the fillets. Top level array length needs to match the nr of edges used and each second level array needs to match paramsU length array at the same index. + * @default undefined + */ + radiusLists: number[][]; + /** + * Lists of parameter lists on the edges to which apply the fillet. Each param must be between 0 and 1. Top level array length needs to match the nr of edges used and each second level array needs to match radius length array at the same index. + * @default undefined + */ + paramsULists: number[][]; + } + class FilletEdgesSameVariableRadiusDto { + constructor( + shape?: T, + edges?: U[], + radiusList?: number[], + paramsU?: number[] + ); + /** + * Shape to apply the fillet + * @default undefined + */ + shape: T; + /** + * Edges to use for the fillet + * @default undefined + */ + edges: U[]; + /** + * Radius list for the fillets that has to match the paramsU list + * @default undefined + */ + radiusList: number[]; + /** + * List of parameters on the edges to which apply the fillet. Each param must be between 0 and 1. + * @default undefined + */ + paramsU: number[]; + } + class Fillet3DWiresDto { + constructor( + shapes?: T[], + radius?: number, + direction?: Base.Vector3, + radiusList?: number[], + indexes?: number[] + ); + /** + * Shapes to apply the fillets on + * @default undefined + */ + shapes: T[]; + /** + * Radius of the fillets + * @default 0.1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + * @optional true + */ + radius?: number; + /** + * Radius list + * @default undefined + * @optional true + */ + radiusList?: number[]; + /** + * List of edge indexes to which apply the fillet, if left empty all edges will be rounded + * @default undefined + * @optional true + */ + indexes?: number[]; + /** + * Orientation direction for the fillet + * @default [0, 1, 0] + */ + direction: Base.Vector3; + } + class Fillet3DWireDto { + constructor( + shape?: T, + radius?: number, + direction?: Base.Vector3, + radiusList?: number[], + indexes?: number[] + ); + /** + * Shape to apply the fillets + * @default undefined + */ + shape: T; + /** + * Radius of the fillets + * @default 0.1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + * @optional true + */ + radius?: number; + /** + * Radius list + * @default undefined + * @optional true + */ + radiusList?: number[]; + /** + * List of edge indexes to which apply the fillet, if left empty all edges will be rounded + * @default undefined + * @optional true + */ + indexes?: number[]; + /** + * Orientation direction for the fillet + * @default [0, 1, 0] + */ + direction: Base.Vector3; + } + class ChamferDto { + constructor( + shape?: T, + distance?: number, + distanceList?: number[], + indexes?: number[] + ); + /** + * Shape to apply the chamfer + * @default undefined + */ + shape: T; + /** + * Distance for the chamfer + * @default 0.1 + * @minimum 0 + * @maximum Infinity + * @optional true + * @step 0.1 + */ + distance?: number; + /** + * Distance for the chamfer + * @default undefined + * @optional true + */ + distanceList?: number[]; + /** + * List of edge indexes to which apply the chamfer, if left empty all edges will be chamfered + * @default undefined + * @optional true + */ + indexes?: number[]; + } + class ChamferEdgesListDto { + constructor(shape?: T, edges?: U[], distanceList?: number[]); + /** + * Shape to apply the chamfer + * @default undefined + */ + shape: T; + /** + * Edges to apply the chamfer to + * @default undefined + */ + edges: U[]; + /** + * Distance for the chamfer + * @default undefined + */ + distanceList: number[]; + } + class ChamferEdgeDistAngleDto { + constructor( + shape?: T, + edge?: U, + face?: F, + distance?: number, + angle?: number + ); + /** + * Shape to apply the chamfer + * @default undefined + */ + shape: T; + /** + * Edge to apply the chamfer to + * @default undefined + */ + edge: U; + /** + * Face from which to apply the angle + * @default undefined + */ + face: F; + /** + * Distance for the chamfer + * @default 0.1 + * @minimum 0 + * @maximum Infinity + * @step 0.01 + */ + distance: number; + /** + * Angle for the chamfer + * @default 45 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + angle: number; + } + class ChamferEdgeTwoDistancesDto { + constructor( + shape?: T, + edge?: U, + face?: F, + distance1?: number, + distance2?: number + ); + /** + * Shape to apply the chamfer + * @default undefined + */ + shape: T; + /** + * Edge to apply the chamfer to + * @default undefined + */ + edge: U; + /** + * Face from which to apply the first distance + * @default undefined + */ + face: F; + /** + * First distance from the face for the chamfer + * @default 0.1 + * @minimum 0 + * @maximum Infinity + * @step 0.01 + */ + distance1: number; + /** + * Second distance for the chamfer + * @default 0.2 + * @minimum 0 + * @maximum Infinity + * @step 0.01 + */ + distance2: number; + } + class ChamferEdgesTwoDistancesListsDto { + constructor( + shape?: T, + edges?: U[], + faces?: F[], + distances1?: number[], + distances2?: number[] + ); + /** + * Shape to apply the chamfer + * @default undefined + */ + shape: T; + /** + * Edges to apply the chamfers to + * @default undefined + */ + edges: U[]; + /** + * Faces from which to apply the angle of the chamfers + * @default undefined + */ + faces: F[]; + /** + * Distance 1 list for the chamfers + * @default undefined + */ + distances1: number[]; + /** + * Distance 2 list for the chamfers + * @default undefined + */ + distances2: number[]; + } + class ChamferEdgesTwoDistancesDto { + constructor( + shape?: T, + edges?: U[], + faces?: F[], + distance1?: number, + distance2?: number + ); + /** + * Shape to apply the chamfer + * @default undefined + */ + shape: T; + /** + * Edges to apply the chamfers to + * @default undefined + */ + edges: U[]; + /** + * Faces from which to apply the angle of the chamfers + * @default undefined + */ + faces: F[]; + /** + * First distance from the face for the chamfer + * @default 0.1 + * @minimum 0 + * @maximum Infinity + * @step 0.01 + */ + distance1: number; + /** + * Second distance for the chamfer + * @default 0.2 + * @minimum 0 + * @maximum Infinity + * @step 0.01 + */ + distance2: number; + } + class ChamferEdgesDistsAnglesDto { + constructor( + shape?: T, + edges?: U[], + faces?: F[], + distances?: number[], + angles?: number[] + ); + /** + * Shape to apply the chamfer + * @default undefined + */ + shape: T; + /** + * Edges to apply the chamfers to + * @default undefined + */ + edges: U[]; + /** + * Faces from which to apply the angle of the chamfers + * @default undefined + */ + faces: F[]; + /** + * Distance list for the chamfers + * @default undefined + */ + distances: number[]; + /** + * Angles for the chamfers + * @default undefined + */ + angles: number[]; + } + class ChamferEdgesDistAngleDto { + constructor( + shape?: T, + edges?: U[], + faces?: F[], + distance?: number, + angle?: number + ); + /** + * Shape to apply the chamfer + * @default undefined + */ + shape: T; + /** + * Edges to apply the chamfers to + * @default undefined + */ + edges: U[]; + /** + * Faces from which to apply the angle of the chamfers + * @default undefined + */ + faces: F[]; + /** + * Distance from the face + * @default 0.1 + * @minimum 0 + * @maximum Infinity + * @step 0.01 + */ + distance: number; + /** + * Angle for the chamfers + * @default 45 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + angle: number; + } + class BSplineDto { + constructor(points?: Base.Point3[], closed?: boolean); + /** + * Points through which the BSpline will be created + * @default undefined + */ + points: Base.Point3[]; + /** + * Indicates wether BSpline will be cloed + * @default false + */ + closed: boolean; + } + class BSplinesDto { + constructor(bSplines?: BSplineDto[], returnCompound?: boolean); + /** + * BSpline definitions + * @default undefined + */ + bSplines: BSplineDto[]; + /** + * Indicates whether the shapes should be returned as a compound + */ + returnCompound: boolean; + } + class WireFromTwoCirclesTanDto { + constructor( + circle1?: T, + circle2?: T, + keepLines?: twoSidesStrictEnum, + circleRemainders?: fourSidesStrictEnum, + tolerance?: number + ); + /** + * The first circle to be encloed with tangential lines + * @default undefined + */ + circle1: T; + /** + * The second circle to be encloed with tangential lines + * @default undefined + */ + circle2: T; + /** + * Choose which side to keep for the wire. Outside gives non-intersecting solution. + * @default outside + */ + keepLines: twoSidesStrictEnum; + /** + * Choose which side to keep for the wire. Outside gives non-intersecting solution. + * @default outside + */ + circleRemainders: fourSidesStrictEnum; + /** + * tolerance + * @default 1e-7 + * @minimum 0 + * @maximum Infinity + * @step 0.00001 + */ + tolerance: number; + } + class FaceFromMultipleCircleTanWiresDto { + constructor( + circles?: T[], + combination?: combinationCirclesForFaceEnum, + unify?: boolean, + tolerance?: number + ); + /** + * The circles that will all be joined into a single face through tangential lines + * @default undefined + */ + circles: T[]; + /** + * Indicates how circles should be joined together. Users can choose to join all circles with each other. Alternatively it is possible to respect the order of circles and only join consecutive circles. It is also possible to respect order and close the shape with first circle in the list. + * @default allWithAll + */ + combination: combinationCirclesForFaceEnum; + /** + * Choose whether you want faces to be unifided into a single face or not. Sometimes if you want to get faster result you can set this to false, but in this case faces will be returned as compound. + * @default true + */ + unify: boolean; + /** + * tolerance + * @default 1e-7 + * @minimum 0 + * @maximum Infinity + * @step 0.00001 + */ + tolerance: number; + } + class FaceFromMultipleCircleTanWireCollectionsDto { + constructor( + listsOfCircles?: T[][], + combination?: combinationCirclesForFaceEnum, + unify?: boolean, + tolerance?: number + ); + /** + * The two dimensional circle array that can host multiple circle collections. + * @default undefined + */ + listsOfCircles: T[][]; + /** + * Indicates how circles should be joined together. Users can choose to join all circles with each other. Alternatively it is possible to respect the order of circles and only join consecutive circles. It is also possible to respect order and close the shape with first circle in the list. + * @default allWithAll + */ + combination: combinationCirclesForFaceEnum; + /** + * Choose whether you want faces to be unifided into a single face or not. Sometimes if you want to get faster result you can set this to false, but in this case faces will be returned as compound. + * @default true + */ + unify: boolean; + /** + * tolerance + * @default 1e-7 + * @minimum 0 + * @maximum Infinity + * @step 0.00001 + */ + tolerance: number; + } + class ZigZagBetweenTwoWiresDto { + constructor( + wire1?: T, + wire2?: T, + nrZigZags?: number, + inverse?: boolean, + divideByEqualDistance?: boolean, + zigZagsPerEdge?: boolean + ); + /** + * The first wire for zig zag + * @default undefined + */ + wire1: T; + /** + * The second wire for zig zag + * @default undefined + */ + wire2: T; + /** + * How many zig zags to create between the two wires on each edge. The number of edges should match. Edges will be joined by zigzags in order. One zig zag means two edges forming a corner. + * @default 20 + * @minimum 1 + * @maximum Infinity + * @step 1 + */ + nrZigZags: number; + /** + * Inverse the the zig zag to go from wire2 to wire1 + * @default false + */ + inverse: boolean; + /** + * If true, the zig zags will be spaced equally on each edge. By default we follow parametric subdivision of the edges, which is not always equal to distance based subdivisions. + * @default false + */ + divideByEqualDistance: boolean; + /** + * By default the number of zig zags is applied to each edge. If this is set to false, the number of zig zags will be applied to the whole wire. This could then skip some corners where edges meet. + * @default true + */ + zigZagsPerEdge: boolean; + } + class InterpolationDto { + constructor( + points?: Base.Point3[], + periodic?: boolean, + tolerance?: number + ); + /** + * Points through which the BSpline will be created + * @default undefined + */ + points: Base.Point3[]; + /** + * Indicates wether BSpline will be periodic + * @default false + */ + periodic: boolean; + /** + * tolerance + * @default 1e-7 + * @minimum 0 + * @maximum Infinity + * @step 0.00001 + */ + tolerance: number; + } + class InterpolateWiresDto { + constructor( + interpolations?: InterpolationDto[], + returnCompound?: boolean + ); + /** + * Interpolation definitions + * @default undefined + */ + interpolations: InterpolationDto[]; + /** + * Indicates whether the shapes should be returned as a compound + */ + returnCompound: boolean; + } + class BezierDto { + constructor(points?: Base.Point3[], closed?: boolean); + /** + * Points through which the Bezier curve will be created + * @default undefined + */ + points: Base.Point3[]; + /** + * Indicates wether Bezier will be cloed + * @default false + */ + closed: boolean; + } + class BezierWeightsDto { + constructor( + points?: Base.Point3[], + weights?: number[], + closed?: boolean + ); + /** + * Points through which the Bezier curve will be created + * @default undefined + */ + points: Base.Point3[]; + /** + * Weights for beziers that will be used, values should be between 0 and 1 + * @default undefined + */ + weights: number[]; + /** + * Indicates wether Bezier will be cloed + * @default false + */ + closed: boolean; + } + class BezierWiresDto { + constructor(bezierWires?: BezierDto[], returnCompound?: boolean); + /** + * Bezier wires + * @default undefined + */ + bezierWires: BezierDto[]; + /** + * Indicates whether the shapes should be returned as a compound + */ + returnCompound: boolean; + } + class DivideDto { + constructor( + shape?: T, + nrOfDivisions?: number, + removeStartPoint?: boolean, + removeEndPoint?: boolean + ); + /** + * Shape representing a wire + * @default undefined + */ + shape?: T; + /** + * The number of divisions that will be performed on the curve + * @default 10 + * @minimum 1 + * @maximum Infinity + * @step 1 + */ + nrOfDivisions?: number; + /** + * Indicates if algorithm should remove start point + * @default false + */ + removeStartPoint?: boolean; + /** + * Indicates if algorithm should remove end point + * @default false + */ + removeEndPoint?: boolean; + } + class ProjectWireDto { + constructor(wire?: T, shape?: U, direction?: Base.Vector3); + /** + * Wire to project + * @default undefined + */ + wire: T; + /** + * Shape to use for projection + * @default undefined + */ + shape: U; + /** + * Direction vector for projection + * @default [0, 1, 0] + */ + direction: Base.Vector3; + } + class ProjectPointsOnShapeDto { + constructor( + points?: Base.Point3[], + shape?: T, + direction?: Base.Vector3, + projectionType?: pointProjectionTypeEnum + ); + /** + * Points to project + * @default undefined + */ + points: Base.Point3[]; + /** + * Shape to use for projection + * @default undefined + */ + shape: T; + /** + * Direction vector for projection - this must take the length into account as well, because algorithm looks for intresections with the shape in this direction. It will not find solutions outside the given length of this vector. + * @default [0, 10, 0] + */ + direction: Base.Vector3; + /** + * Allows user to choose what solutions are being returned by this operation. + * @default all + */ + projectionType: pointProjectionTypeEnum; + } + class WiresToPointsDto { + constructor( + shape?: T, + angularDeflection?: number, + curvatureDeflection?: number, + minimumOfPoints?: number, + uTolerance?: number, + minimumLength?: number + ); + /** + * Shape to use for parsing edges + * @default undefined + */ + shape: T; + /** + * The angular deflection + * @default 0.1 + * @minimum 0 + * @maximum Infinity + * @step 0.01 + */ + angularDeflection: number; + /** + * The curvature deflection + * @default 0.1 + * @minimum 0 + * @maximum Infinity + * @step 0.001 + */ + curvatureDeflection: number; + /** + * Minimum of points + * @default 2 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + minimumOfPoints: number; + /** + * U tolerance + * @default 1.0e-9 + * @minimum 0 + * @maximum Infinity + * @step 1.0e-9 + */ + uTolerance: number; + /** + * Minimum length + * @default 1.0e-7 + * @minimum 0 + * @maximum Infinity + * @step 1.0e-7 + */ + minimumLength: number; + } + class EdgesToPointsDto { + constructor( + shape?: T, + angularDeflection?: number, + curvatureDeflection?: number, + minimumOfPoints?: number, + uTolerance?: number, + minimumLength?: number + ); + /** + * Shape to use for parsing edges + * @default undefined + */ + shape: T; + /** + * The angular deflection + * @default 0.1 + * @minimum 0 + * @maximum Infinity + * @step 0.01 + */ + angularDeflection: number; + /** + * The curvature deflection + * @default 0.1 + * @minimum 0 + * @maximum Infinity + * @step 0.001 + */ + curvatureDeflection: number; + /** + * Minimum of points + * @default 2 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + minimumOfPoints: number; + /** + * U tolerance + * @default 1.0e-9 + * @minimum 0 + * @maximum Infinity + * @step 1.0e-9 + */ + uTolerance: number; + /** + * Minimum length + * @default 1.0e-7 + * @minimum 0 + * @maximum Infinity + * @step 1.0e-7 + */ + minimumLength: number; + } + class ProjectWiresDto { + constructor(wires?: T[], shape?: U, direction?: Base.Vector3); + /** + * Wire to project + * @default undefined + */ + wires: T[]; + /** + * Shape to use for projection + * @default undefined + */ + shape: U; + /** + * Direction vector for projection + * @default [0, 1, 0] + */ + direction: Base.Vector3; + } + class DivideShapesDto { + constructor( + shapes: T[], + nrOfDivisions?: number, + removeStartPoint?: boolean, + removeEndPoint?: boolean + ); + /** + * Shapes + * @default undefined + */ + shapes: T[]; + /** + * The number of divisions that will be performed on the curve + * @default 10 + * @minimum 1 + * @maximum Infinity + * @step 1 + */ + nrOfDivisions: number; + /** + * Indicates if algorithm should remove start point + * @default false + */ + removeStartPoint: boolean; + /** + * Indicates if algorithm should remove end point + * @default false + */ + removeEndPoint: boolean; + } + class DataOnGeometryAtParamDto { + constructor(shape: T, param?: number); + /** + * Shape representing a geometry + * @default undefined + */ + shape: T; + /** + * 0 - 1 value + * @default 0.5 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + param: number; + } + class DataOnGeometryesAtParamDto { + constructor(shapes: T[], param?: number); + /** + * Shapes representing a geometry + * @default undefined + */ + shapes: T[]; + /** + * 0 - 1 value + * @default 0.5 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + param: number; + } + class PointInFaceDto { + constructor( + face: T, + edge: T, + tEdgeParam?: number, + distance2DParam?: number + ); + /** + * OCCT face to be used for calculation + * @default undefined + */ + face: T; + /** + * OCCT edge to be used for calculation + * @default undefined + */ + edge: T; + /** + * 0 - 1 value + * @default 0.5 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + tEdgeParam: number; + /** + * The point will be distanced on from the 2d curve. + * @default 0.5 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + distance2DParam: number; + } + class PointsOnWireAtEqualLengthDto { + constructor( + shape: T, + length?: number, + tryNext?: boolean, + includeFirst?: boolean, + includeLast?: boolean + ); + /** + * Shape representing a wire + * @default undefined + */ + shape: T; + /** + * length at which to evaluate the point + * @default 0.5 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + length: number; + /** + * Try next point if the point is not found + * @default false + */ + tryNext: boolean; + /** + * Include first point + * @default false + */ + includeFirst: boolean; + /** + * Include last point + * @default false + */ + includeLast: boolean; + } + class PointsOnWireAtPatternOfLengthsDto { + constructor( + shape: T, + lengths?: number[], + tryNext?: boolean, + includeFirst?: boolean, + includeLast?: boolean + ); + /** + * Shape representing a wire + * @default undefined + */ + shape: T; + /** + * length at which to evaluate the point + * @default undefined + */ + lengths: number[]; + /** + * Try next point if the point is not found + * @default false + */ + tryNext: boolean; + /** + * Include first point + * @default false + */ + includeFirst: boolean; + /** + * Include last point + * @default false + */ + includeLast: boolean; + } + class DataOnGeometryAtLengthDto { + constructor(shape: T, length?: number); + /** + * Shape + * @default undefined + */ + shape: T; + /** + * length at which to evaluate the point + * @default 0.5 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + length: number; + } + class DataOnGeometryesAtLengthDto { + constructor(shapes: T[], length?: number); + /** + * Shapes + * @default undefined + */ + shapes: T[]; + /** + * length at which to evaluate the point + * @default 0.5 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + length: number; + } + class DataOnGeometryAtLengthsDto { + constructor(shape: T, lengths?: number[]); + /** + * Shape representing a wire + * @default undefined + */ + shape: T; + /** + * lengths at which to evaluate the points + * @default undefined + */ + lengths: number[]; + } + class CircleDto { + constructor( + radius?: number, + center?: Base.Point3, + direction?: Base.Vector3 + ); + /** + * Radius of the circle + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + radius: number; + /** + * Center of the circle + * @default [0, 0, 0] + */ + center: Base.Point3; + /** + * Direction vector for circle + * @default [0, 1, 0] + */ + direction: Base.Vector3; + } + class HexagonsInGridDto { + constructor( + wdith?: number, + height?: number, + nrHexagonsInHeight?: number, + nrHexagonsInWidth?: number, + flatTop?: boolean, + extendTop?: boolean, + extendBottom?: boolean, + extendLeft?: boolean, + extendRight?: boolean, + scalePatternWidth?: number[], + scalePatternHeight?: number[], + filletPattern?: number[], + inclusionPattern?: boolean[] + ); + /** Total desired width for the grid area. The hexagon size will be derived from this and nrHexagonsU. + * @default 10 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + width?: number; + /** Total desired height for the grid area. Note: due to hexagon geometry, the actual grid height might differ slightly if maintaining regular hexagons based on width. + * @default 10 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + height?: number; + /** Number of hexagons desired in width. + * @default 10 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + nrHexagonsInWidth?: number; + /** Number of hexagons desired in height. + * @default 10 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + nrHexagonsInHeight?: number; + /** If true, the hexagons will be oriented with their flat sides facing up and down. + * @default false + */ + flatTop?: boolean; + /** If true, shift the entire grid up by half hex height. + * @default false + */ + extendTop?: boolean; + /** If true, shift the entire grid down by half hex height. + * @default false + */ + extendBottom?: boolean; + /** If true, shift the entire grid left by half hex width. + * @default false + */ + extendLeft?: boolean; + /** If true, shift the entire grid right by half hex width. + * @default false + */ + extendRight?: boolean; + /** + * Hex scale pattern on width direction - numbers between 0 and 1, if 1 or undefined is used, no scaling is applied + * @default undefined + * @optional true + */ + scalePatternWidth?: number[]; + /** + * Hex scale pattern on height direction - numbers between 0 and 1, if 1 or undefined is used, no scaling is applied + * @default undefined + * @optional true + */ + scalePatternHeight?: number[]; + /** + * Hex fillet scale pattern - numbers between 0 and 1, if 0 is used, no fillet is applied, + * if 1 is used, the fillet will be exactly half of the length of the shorter side of the hex + * @default undefined + * @optional true + */ + filletPattern?: number[]; + /** + * Inclusion pattern - true means that the hex will be included, + * false means that the hex will be removed + * @default undefined + * @optional true + */ + inclusionPattern?: boolean[]; + } + class LoftDto { + constructor(shapes?: T[], makeSolid?: boolean); + /** + * Wires through which the loft passes + * @default undefined + */ + shapes: T[]; + /** + * Tries to make a solid when lofting + * @default false + */ + makeSolid: boolean; + } + class LoftAdvancedDto { + constructor( + shapes?: T[], + makeSolid?: boolean, + closed?: boolean, + periodic?: boolean, + straight?: boolean, + nrPeriodicSections?: number, + useSmoothing?: boolean, + maxUDegree?: number, + tolerance?: number, + parType?: approxParametrizationTypeEnum, + startVertex?: Base.Point3, + endVertex?: Base.Point3 + ); + /** + * Wires through which the loft passes + * @default undefined + */ + shapes: T[]; + /** + * Tries to make a solid when lofting + * @default false + */ + makeSolid: boolean; + /** + * Will make a closed loft. + * @default false + */ + closed: boolean; + /** + * Will make a periodic loft. + * @default false + */ + periodic: boolean; + /** + * Indicates whether straight sections should be made out of the loft + * @default false + */ + straight: boolean; + /** + * This number only is used when closed non straight lofting is used + * @default 10 + * @minimum 1 + * @maximum Infinity + * @step 1 + */ + nrPeriodicSections: number; + /** + * Tell algorithm to use smoothing + * @default false + */ + useSmoothing: boolean; + /** + * Maximum u degree + * @default 3 + */ + maxUDegree: number; + /** + * Tolerance + * @default 1.0e-7 + * @minimum 0 + * @maximum Infinity + * @step 0.000001 + */ + tolerance: number; + /** + * Approximation parametrization type + * @default approxCentripetal + */ + parType: approxParametrizationTypeEnum; + /** + * Optional if loft should start with a vertex + * @default undefined + * @optional true + */ + startVertex?: Base.Point3; + /** + * Optional if loft should end with a vertex + * @default undefined + * @optional true + */ + endVertex?: Base.Point3; + } + class OffsetDto { + constructor(shape?: T, face?: U, distance?: number, tolerance?: number); + /** + * Shape to offset + * @default undefined + */ + shape: T; + /** + * Optionally provide face for the offset + * @default undefined + * @optional true + */ + face?: U; + /** + * Distance of offset + * @default 0.2 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + distance: number; + /** + * Offset tolerance + * @default 0.1 + * @minimum 0 + * @maximum Infinity + * @step 0.01 + */ + tolerance: number; + } + class OffsetAdvancedDto { + constructor( + shape?: T, + face?: U, + distance?: number, + tolerance?: number, + joinType?: joinTypeEnum, + removeIntEdges?: boolean + ); + /** + * Shape to offset + * @default undefined + */ + shape: T; + /** + * Optionally provide face for the offset + * @default undefined + * @optional true + */ + face?: U; + /** + * Distance of offset + * @default 0.2 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + distance: number; + /** + * Offset tolerance + * @default 0.1 + * @minimum 0 + * @maximum Infinity + * @step 0.01 + */ + tolerance: number; + /** + * Join defines how to fill the holes that may appear between parallels to the two adjacent faces. It may take values GeomAbs_Arc or GeomAbs_Intersection: + * if Join is equal to GeomAbs_Arc, then pipes are generated between two free edges of two adjacent parallels, and spheres are generated on "images" of vertices; it is the default value + * @default arc + */ + joinType: joinTypeEnum; + /** + * Removes internal edges + * @default false + */ + removeIntEdges: boolean; + } + class RevolveDto { + constructor( + shape?: T, + angle?: number, + direction?: Base.Vector3, + copy?: boolean + ); + /** + * Shape to revolve + * @default undefined + */ + shape: T; + /** + * Angle degrees + * @default 360 + * @minimum 0 + * @maximum 360 + * @step 1 + */ + angle: number; + /** + * Direction vector + * @default [0, 1, 0] + */ + direction: Base.Vector3; + /** + * Copy original shape + * @default false + */ + copy: boolean; + } + class ShapeShapesDto { + constructor(shape?: T, shapes?: U[]); + /** + * The wire path + * @default undefined + */ + shape: T; + /** + * Shapes along the path to be piped + * @default undefined + */ + shapes: U[]; + } + class WiresOnFaceDto { + constructor(wires?: T[], face?: U); + /** + * The wires + * @default undefined + */ + wires: T[]; + /** + * Face shape + * @default undefined + */ + face: U; + } + class PipeWiresCylindricalDto { + constructor( + shapes?: T[], + radius?: number, + makeSolid?: boolean, + trihedronEnum?: geomFillTrihedronEnum, + forceApproxC1?: boolean + ); + /** + * Wire paths to pipe + * @default undefined + */ + shapes: T[]; + /** + * Radius of the cylindrical pipe + * @default 0.1 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + radius: number; + /** + * Make solid result by closing start and end parts + * @default true + */ + makeSolid: boolean; + /** + * Goemetry Fill Trihedron Options + * @default isConstantNormal + */ + trihedronEnum: geomFillTrihedronEnum; + /** + * Attempt to approximate a C1-continuous surface if a swept surface proved to be C0 + * @default false + */ + forceApproxC1: boolean; + } + class PipeWireCylindricalDto { + constructor( + shape?: T, + radius?: number, + makeSolid?: boolean, + trihedronEnum?: geomFillTrihedronEnum, + forceApproxC1?: boolean + ); + /** + * Wire path to pipe + * @default undefined + */ + shape: T; + /** + * Radius of the cylindrical pipe + * @default 0.1 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + radius: number; + /** + * Make solid result by closing start and end parts + * @default true + */ + makeSolid: boolean; + /** + * Goemetry Fill Trihedron Options + * @default isConstantNormal + */ + trihedronEnum: geomFillTrihedronEnum; + /** + * Attempt to approximate a C1-continuous surface if a swept surface proved to be C0 + * @default false + */ + forceApproxC1: boolean; + } + class PipePolygonWireNGonDto { + constructor( + shapes?: T, + radius?: number, + nrCorners?: number, + makeSolid?: boolean, + trihedronEnum?: geomFillTrihedronEnum, + forceApproxC1?: boolean + ); + /** + * Wire path to pipe + * @default undefined + */ + shape: T; + /** + * Radius of the cylindrical pipe + * @default 0.1 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + radius: number; + /** + * Nr of ngon corners to be used + * @default 6 + * @minimum 3 + * @maximum Infinity + * @step 1 + */ + nrCorners: number; + /** + * Make solid result by closing start and end parts + * @default true + */ + makeSolid: boolean; + /** + * Goemetry Fill Trihedron Options + * @default isConstantNormal + */ + trihedronEnum: geomFillTrihedronEnum; + /** + * Attempt to approximate a C1-continuous surface if a swept surface proved to be C0 + * @default false + */ + forceApproxC1: boolean; + } + class ExtrudeDto { + constructor(shape?: T, direction?: Base.Vector3); + /** + * Face to extrude + * @default undefined + */ + shape: T; + /** + * Direction vector for extrusion + * @default [0, 1, 0] + */ + direction: Base.Vector3; + } + class ExtrudeShapesDto { + constructor(shapes?: T[], direction?: Base.Vector3); + /** + * Shapes to extrude + * @default undefined + */ + shapes: T[]; + /** + * Direction vector for extrusion + * @default [0, 1, 0] + */ + direction: Base.Vector3; + } + class SplitDto { + constructor(shape?: T, shapes?: T[]); + /** + * Shape to split + * @default undefined + */ + shape: T; + /** + * Shapes to split from main shape + * @default undefined + */ + shapes: T[]; + /** + * Local fuzzy tolerance used for splitting + * @default 1.0e-4 + * @minimum 0 + * @maximum Infinity + * @step 0.000001 + */ + localFuzzyTolerance: number; + /** + * Set to true if you want to split the shape non-destructively + * @default true + */ + nonDestructive: boolean; + } + class UnionDto { + constructor(shapes?: T[], keepEdges?: boolean); + /** + * Objects to be joined together + * @default undefined + */ + shapes: T[]; + /** + * Keeps edges + * @default false + */ + keepEdges: boolean; + } + class DifferenceDto { + constructor(shape?: T, shapes?: T[], keepEdges?: boolean); + /** + * Object to subtract from + * @default undefined + */ + shape: T; + /** + * Objects to subtract + * @default undefined + */ + shapes: T[]; + /** + * Keeps edges unaffected + * @default false + */ + keepEdges: boolean; + } + class IntersectionDto { + constructor(shapes?: T[], keepEdges?: boolean); + /** + * Shapes to intersect + * @default undefined + */ + shapes: T[]; + /** + * Keep the edges + * @default false + */ + keepEdges: boolean; + } + class ShapeDto { + constructor(shape?: T); + /** + * Shape on which action should be performed + * @default undefined + */ + shape: T; + } + class MeshMeshIntersectionTwoShapesDto { + constructor( + shape1?: T, + shape2?: T, + precision1?: number, + precision2?: number + ); + /** + * First shape to be used for intersection + * @default undefined + */ + shape1: T; + /** + * Precision of first shape to be used for meshing and computing intersection. + * Keep in mind that the lower this value is, the more triangles will be produced and thus the slower the computation. + * @default 0.01 + * @minimum 0 + * @maximum Infinity + * @step 0.01 + */ + precision1?: number; + /** + * Second shape to be used for intersection + * @default undefined + */ + shape2: T; + /** + * Precision of second shape to be used for meshing and computing intersection. + * Keep in mind that the lower this value is, the more triangles will be produced and thus the slower the computation. + * @default 0.01 + * @minimum 0 + * @maximum Infinity + * @step 0.01 + */ + precision2?: number; + } + class MeshMeshesIntersectionOfShapesDto { + constructor( + shape?: T, + shapes?: T[], + precision?: number, + precisionShapes?: number[] + ); + /** + * Shape to use for the base of computations + * @default undefined + */ + shape?: T; + /** + * Precision of first shape to be used for meshing and computing intersection. + * Keep in mind that the lower this value is, the more triangles will be produced and thus the slower the computation. + * @default 0.01 + * @minimum 0 + * @maximum Infinity + * @step 0.01 + */ + precision?: number; + /** + * Second shape to be used for intersection + * @default undefined + */ + shapes?: T[]; + /** + * Precision of shapes to be used, if undefined, a universal precision will be used of the first shape + * @default undefined + * @optional true + */ + precisionShapes?: number[]; + } + class CompareShapesDto { + constructor(shape?: T, otherShape?: T); + /** + * Shape to be compared + * @default undefined + */ + shape: T; + /** + * Shape to be compared against + * @default undefined + */ + otherShape: T; + } + class FixSmallEdgesInWireDto { + constructor(shape?: T, lockvtx?: boolean, precsmall?: number); + /** + * Shape on which action should be performed + * @default undefined + */ + shape: T; + /** + * Lock vertex. If true, the edge must be kept. + * @default false + */ + lockvtx: boolean; + /** + * Definition of the small distance edge + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 0.0000000001 + */ + precsmall: number; + } + class BasicShapeRepairDto { + constructor( + shape?: T, + precision?: number, + maxTolerance?: number, + minTolerance?: number + ); + /** + * Shape to repair + * @default undefined + */ + shape: T; + /** + * Basic precision + * @default 0.001 + * @minimum 0 + * @maximum Infinity + * @step 0.0000000001 + */ + precision: number; + /** + * maximum allowed tolerance. All problems will be detected for cases when a dimension of invalidity is larger than + * the basic precision or a tolerance of sub-shape on that problem is detected. The maximum tolerance value limits + * the increasing tolerance for fixing a problem such as fix of not connected and self-intersected wires. If a value + * larger than the maximum allowed tolerance is necessary for correcting a detected problem the problem can not be fixed. + * The maximal tolerance is not taking into account during computation of tolerance of edges + * @default 0.01 + * @minimum 0 + * @maximum Infinity + * @step 0.0000000001 + */ + maxTolerance: number; + /** + * minimal allowed tolerance. It defines the minimal allowed length of edges. + * Detected edges having length less than the specified minimal tolerance will be removed. + * @default 0.0001 + * @minimum 0 + * @maximum Infinity + * @step 0.0000000001 + */ + minTolerance: number; + } + class FixClosedDto { + constructor(shape?: T, precision?: number); + /** + * Shape on which action should be performed + * @default undefined + */ + shape: T; + /** + * Precision for closed wire + * @default -0.1 + * @minimum -Infinity + * @maximum Infinity + * @step 0.0000000001 + */ + precision: number; + } + class ShapesWithToleranceDto { + constructor(shapes?: T[], tolerance?: number); + /** + * The shapes + * @default undefined + */ + shapes: T[]; + /** + * Tolerance used for intersections + * @default 1.0e-7 + * @minimum 0 + * @maximum Infinity + * @step 0.000001 + */ + tolerance: number; + } + class ShapeWithToleranceDto { + constructor(shape?: T, tolerance?: number); + /** + * The shape + * @default undefined + */ + shape: T; + /** + * Tolerance used for intersections + * @default 1.0e-7 + * @minimum 0 + * @maximum Infinity + * @step 0.000001 + */ + tolerance: number; + } + class ShapeIndexDto { + constructor(shape?: T, index?: number); + /** + * Shape + * @default undefined + */ + shape: T; + /** + * Index of the entity + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + index: number; + } + class EdgeIndexDto { + constructor(shape?: T, index?: number); + /** + * Shape + * @default undefined + */ + shape: T; + /** + * Index of the entity + * @default 1 + * @minimum 1 + * @maximum Infinity + * @step 1 + */ + index: number; + } + class RotationExtrudeDto { + constructor( + shape?: T, + height?: number, + angle?: number, + makeSolid?: boolean + ); + /** + * Wire to extrude by rotating + * @default undefined + */ + shape: T; + /** + * Height of rotation + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + height: number; + /** + * Rotation in degrees + * @default 360 + * @minimum 0 + * @maximum 360 + * @step 1 + */ + angle: number; + /** + * Make solid of the result + * @default true + */ + makeSolid: boolean; + } + class ThickSolidByJoinDto { + constructor( + shape?: T, + shapes?: T[], + offset?: number, + tolerance?: number, + intersection?: boolean, + selfIntersection?: boolean, + joinType?: joinTypeEnum, + removeIntEdges?: boolean + ); + /** + * Shape to make thick + * @default undefined + */ + shape: T; + /** + * closing faces + * @default undefined + */ + shapes: T[]; + /** + * Offset to apply + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + offset: number; + /** + * Tolerance defines the tolerance criterion for coincidence in generated shapes + * @default 1.0e-3 + * @minimum 0 + * @maximum Infinity + * @step 0.000001 + */ + tolerance: number; + /** + * if Intersection is false (default value), the intersection is calculated with the parallels to the two adjacent shapes + * @default false + */ + intersection: boolean; + /** + * SelfInter tells the algorithm whether a computation to eliminate self-intersections needs to be applied to the resulting shape. However, as this functionality is not yet implemented, you should use the default value (false) + * @default false + */ + selfIntersection: boolean; + /** + * Join defines how to fill the holes that may appear between parallels to the two adjacent faces. It may take values GeomAbs_Arc or GeomAbs_Intersection: + * if Join is equal to GeomAbs_Arc, then pipes are generated between two free edges of two adjacent parallels, and spheres are generated on "images" of vertices; it is the default value + * @default arc + */ + joinType: joinTypeEnum; + /** + * if Join is equal to GeomAbs_Intersection, then the parallels to the two adjacent faces are enlarged and intersected, so that there are no free edges on parallels to faces. RemoveIntEdges flag defines whether to remove the INTERNAL edges from the result or not. Warnings Since the algorithm of MakeThickSolid is based on MakeOffsetShape algorithm, the warnings are the same as for MakeOffsetShape. + * @default false + */ + removeIntEdges: boolean; + } + class TransformDto { + constructor( + shape?: T, + translation?: Base.Vector3, + rotationAxis?: Base.Vector3, + rotationAngle?: number, + scaleFactor?: number + ); + /** + * Shape to transform + * @default undefined + */ + shape: T; + /** + * Translation to apply + * @default [0,0,0] + */ + translation: Base.Vector3; + /** + * Rotation to apply + * @default [0,1,0] + */ + rotationAxis: Base.Vector3; + /** + * Rotation degrees + * @default 0 + * @minimum 0 + * @maximum 360 + * @step 1 + */ + rotationAngle: number; + /** + * Scale factor to apply + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + scaleFactor: number; + } + class TransformShapesDto { + constructor( + shapes?: T[], + translation?: Base.Vector3[], + rotationAxes?: Base.Vector3[], + rotationDegrees?: number[], + scaleFactors?: number[] + ); + /** + * Shape to transform + * @default undefined + */ + shapes: T[]; + /** + * Translation to apply + * @default [[0,0,0]] + */ + translations: Base.Vector3[]; + /** + * Rotation to apply + * @default [[0,1,0]] + */ + rotationAxes: Base.Vector3[]; + /** + * Rotation degrees + * @default [0] + */ + rotationAngles: number[]; + /** + * Scale factor to apply + * @default [1] + */ + scaleFactors: number[]; + } + class TranslateDto { + constructor(shape?: T, translation?: Base.Vector3); + /** + * Shape for translation + * @default undefined + */ + shape: T; + /** + * Translation vector + * @default [0, 0, 0] + */ + translation: Base.Vector3; + } + class TranslateShapesDto { + constructor(shapes?: T[], translations?: Base.Vector3[]); + /** + * Shape for translation + * @default undefined + */ + shapes: T[]; + /** + * Translation vector + * @default [[0, 0, 0]] + */ + translations: Base.Vector3[]; + } + class AlignNormAndAxisDto { + constructor( + shape?: T, + fromOrigin?: Base.Point3, + fromNorm?: Base.Vector3, + fromAx?: Base.Vector3, + toOrigin?: Base.Point3, + toNorm?: Base.Vector3, + toAx?: Base.Vector3 + ); + /** + * Shape for translation + * @default undefined + */ + shape: T; + /** + * @default [0, 0, 0] + */ + fromOrigin: Base.Point3; + /** + * From direction 1 + * @default [0, 0, 1] + */ + fromNorm: Base.Vector3; + /** + * From direction 2 + * @default [0, 0, 1] + */ + fromAx: Base.Vector3; + /** + * To origin + * @default [0, 1, 0] + */ + toOrigin: Base.Point3; + /** + * To direction 1 + * @default [0, 1, 0] + */ + toNorm: Base.Vector3; + /** + * To direction 2 + * @default [0, 0, 1] + */ + toAx: Base.Vector3; + } + class AlignDto { + constructor( + shape?: T, + fromOrigin?: Base.Point3, + fromDirection?: Base.Vector3, + toOrigin?: Base.Point3, + toDirection?: Base.Vector3 + ); + /** + * Shape for translation + * @default undefined + */ + shape: T; + /** + * @default [0, 0, 0] + */ + fromOrigin: Base.Point3; + /** + * From direction + * @default [0, 0, 1] + */ + fromDirection: Base.Vector3; + /** + * To origin + * @default [0, 1, 0] + */ + toOrigin: Base.Point3; + /** + * To direction + * @default [0, 1, 0] + */ + toDirection: Base.Vector3; + } + class AlignShapesDto { + constructor( + shapes?: T[], + fromOrigins?: Base.Vector3[], + fromDirections?: Base.Vector3[], + toOrigins?: Base.Vector3[], + toDirections?: Base.Vector3[] + ); + /** + * Shape for translation + * @default undefined + */ + shapes: T[]; + /** + * @default [[0, 0, 0]] + */ + fromOrigins: Base.Point3[]; + /** + * From direction + * @default [[0, 0, 1]] + */ + fromDirections: Base.Vector3[]; + /** + * To origin + * @default [[0, 1, 0]] + */ + toOrigins: Base.Point3[]; + /** + * To direction + * @default [[0, 1, 0]] + */ + toDirections: Base.Vector3[]; + } + class MirrorDto { + constructor(shape?: T, origin?: Base.Point3, direction?: Base.Vector3); + /** + * Shape to mirror + * @default undefined + */ + shape: T; + /** + * Axis origin point + * @default [0, 0, 0] + */ + origin: Base.Point3; + /** + * Axis direction vector + * @default [0, 0, 1] + */ + direction: Base.Vector3; + } + class MirrorShapesDto { + constructor( + shapes?: T[], + origins?: Base.Point3[], + directions?: Base.Vector3[] + ); + /** + * Shape to mirror + * @default undefined + */ + shapes: T[]; + /** + * Axis origin point + * @default [[0, 0, 0]] + */ + origins: Base.Point3[]; + /** + * Axis direction vector + * @default [[0, 0, 1]] + */ + directions: Base.Vector3[]; + } + class MirrorAlongNormalDto { + constructor(shape?: T, origin?: Base.Point3, normal?: Base.Vector3); + /** + * Shape to mirror + * @default undefined + */ + shape: T; + /** + * Axis origin point + * @default [0, 0, 0] + */ + origin: Base.Point3; + /** + * First normal axis direction vector + * @default [0, 0, 1] + */ + normal: Base.Vector3; + } + class MirrorAlongNormalShapesDto { + constructor( + shapes?: T[], + origins?: Base.Point3[], + normals?: Base.Vector3[] + ); + /** + * Shape to mirror + * @default undefined + */ + shapes: T[]; + /** + * Axis origin point + * @default [[0, 0, 0]] + */ + origins: Base.Point3[]; + /** + * First normal axis direction vector + * @default [[0, 0, 1]] + */ + normals: Base.Vector3[]; + } + class AlignAndTranslateDto { + constructor(shape?: T, direction?: Base.Vector3, center?: Base.Vector3); + /** + * Shape to align and translate + * @default undefined + */ + shape: T; + /** + * Direction on which to align + * @default [0, 0, 1] + */ + direction: Base.Vector3; + /** + * Position to translate + */ + center: Base.Vector3; + } + class UnifySameDomainDto { + constructor( + shape?: T, + unifyEdges?: boolean, + unifyFaces?: boolean, + concatBSplines?: boolean + ); + /** + * Shape on which action should be performed + * @default undefined + */ + shape: T; + /** + * If true, unifies the edges + * @default true + */ + unifyEdges: boolean; + /** + * If true, unifies the edges + * @default true + */ + unifyFaces: boolean; + /** + * If true, unifies the edges + * @default true + */ + concatBSplines: boolean; + } + class FilterFacesPointsDto { + constructor( + shapes?: T[], + points?: Base.Point3[], + tolerance?: number, + useBndBox?: boolean, + gapTolerance?: number, + keepIn?: boolean, + keepOn?: boolean, + keepOut?: boolean, + keepUnknown?: boolean, + flatPointsArray?: boolean + ); + /** + * Face that will be used to filter points + * @default undefined + */ + shapes: T[]; + /** + * Points to filter + * @default undefined + */ + points: Base.Point3[]; + /** + * Tolerance used for filter + * @default 1.0e-4 + * @minimum 0 + * @maximum Infinity + * @step 0.000001 + */ + tolerance: number; + /** + * If true, the bounding box will be used to prefilter the points so that there are less points to check on actual face. + * Recommended to enable if face has more than 10 edges and geometry is mostly spline. + * This might be faster, but if it is known that points are withing bounding box, this may not be faster. + * @default false + */ + useBndBox: boolean; + /** + * Gap tolerance + * @default 0.1 + * @minimum 0 + * @maximum Infinity + * @step 0.01 + */ + gapTolerance: number; + /** + * Return points that are inside the face + * @default true + */ + keepIn: boolean; + /** + * Return points that are on the border of the face + * @default true + */ + keepOn: boolean; + /** + * Return points that are outside the borders of the face + * @default false + */ + keepOut: boolean; + /** + * Return points that are classified as unknown + * @default false + */ + keepUnknown: boolean; + /** + * Returns flat points array by default, otherwise returns points for each face in order provided + * @default true + */ + flatPointsArray: boolean; + } + class FilterFacePointsDto { + constructor( + shape?: T, + points?: Base.Point3[], + tolerance?: number, + useBndBox?: boolean, + gapTolerance?: number, + keepIn?: boolean, + keepOn?: boolean, + keepOut?: boolean, + keepUnknown?: boolean + ); + /** + * Face that will be used to filter points + * @default undefined + */ + shape: T; + /** + * Points to filter + * @default undefined + */ + points: Base.Point3[]; + /** + * Tolerance used for filter + * @default 1.0e-4 + * @minimum 0 + * @maximum Infinity + * @step 0.000001 + */ + tolerance: number; + /** + * If true, the bounding box will be used to prefilter the points so that there are less points to check on actual face. + * Recommended to enable if face has more than 10 edges and geometry is mostly spline. + * This might be faster, but if it is known that points are withing bounding box, this may not be faster. + * @default false + */ + useBndBox: boolean; + /** + * Gap tolerance + * @default 0.1 + * @minimum 0 + * @maximum Infinity + * @step 0.01 + */ + gapTolerance: number; + /** + * Return points that are inside the face + * @default true + */ + keepIn: boolean; + /** + * Return points that are on the border of the face + * @default true + */ + keepOn: boolean; + /** + * Return points that are outside the borders of the face + * @default false + */ + keepOut: boolean; + /** + * Return points that are classified as unknown + * @default false + */ + keepUnknown: boolean; + } + class FilterSolidPointsDto { + constructor( + shape?: T, + points?: Base.Point3[], + tolerance?: number, + keepIn?: boolean, + keepOn?: boolean, + keepOut?: boolean, + keepUnknown?: boolean + ); + /** + * Face that will be used to filter points + * @default undefined + */ + shape: T; + /** + * Points to filter + * @default undefined + */ + points: Base.Point3[]; + /** + * Tolerance used for filter + * @default 1.0e-4 + * @minimum 0 + * @maximum Infinity + * @step 0.000001 + */ + tolerance: number; + /** + * Return points that are inside the face + * @default true + */ + keepIn: boolean; + /** + * Return points that are on the border of the face + * @default true + */ + keepOn: boolean; + /** + * Return points that are outside the borders of the face + * @default false + */ + keepOut: boolean; + /** + * Return points that are classified as unknown + * @default false + */ + keepUnknown: boolean; + } + class AlignAndTranslateShapesDto { + constructor( + shapes?: T[], + directions?: Base.Vector3[], + centers?: Base.Vector3[] + ); + /** + * Shapes to align and translate + * @default undefined + */ + shapes: T[]; + /** + * Directions on which to align + * @default [0, 0, 1] + */ + directions: Base.Vector3[]; + /** + * Positions to translate + */ + centers: Base.Vector3[]; + } + class RotateDto { + constructor(shape?: T, axis?: Base.Vector3, angle?: number); + /** + * Shape to rotate + * @default undefined + */ + shape: T; + /** + * Axis on which to rotate + * @default [0, 0, 1] + */ + axis: Base.Vector3; + /** + * Rotation degrees + * @default 0 + * @minimum 0 + * @maximum 360 + * @step 1 + */ + angle: number; + } + class RotateAroundCenterDto { + constructor( + shape?: T, + angle?: number, + center?: Base.Point3, + axis?: Base.Vector3 + ); + /** + * Shape to rotate + * @default undefined + */ + shape: T; + /** + * Angle of rotation to apply + * @default 0 + */ + angle: number; + /** + * Center of the rotation + * @default [0, 0, 0] + */ + center: Base.Point3; + /** + * Axis around which to rotate + * @default [0, 0, 1] + */ + axis: Base.Vector3; + } + class RotateShapesDto { + constructor(shapes?: T[], axes?: Base.Vector3[], angles?: number[]); + /** + * Shape to rotate + * @default undefined + */ + shapes: T[]; + /** + * Axis on which to rotate + * @default [[0, 0, 1]] + */ + axes: Base.Vector3[]; + /** + * Rotation degrees + * @default [0] + */ + angles: number[]; + } + class RotateAroundCenterShapesDto { + constructor( + shapes?: T[], + angles?: number[], + centers?: Base.Point3[], + axes?: Base.Vector3[] + ); + /** + * Shape to scale + * @default undefined + */ + shapes: T[]; + /** + * Angles of rotation to apply + * @default [0] + */ + angles: number[]; + /** + * Centers around which to rotate + * @default [[0, 0, 0]] + */ + centers: Base.Point3[]; + /** + * Axes around which to rotate + * @default [[0, 0, 1]] + */ + axes: Base.Vector3[]; + } + class ScaleDto { + constructor(shape?: T, factor?: number); + /** + * Shape to scale + * @default undefined + */ + shape: T; + /** + * Scale factor to apply + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + factor: number; + } + class ScaleShapesDto { + constructor(shapes?: T[], factors?: number[]); + /** + * Shape to scale + * @default undefined + */ + shapes: T[]; + /** + * Scale factor to apply + * @default [1] + */ + factors: number[]; + } + class Scale3DDto { + constructor(shape?: T, scale?: Base.Vector3, center?: Base.Point3); + /** + * Shape to scale + * @default undefined + */ + shape: T; + /** + * Scale factor to apply + * @default [1, 1, 1] + */ + scale: Base.Vector3; + /** + * Scale from the center + * @default [0, 0, 0] + */ + center: Base.Point3; + } + class Scale3DShapesDto { + constructor( + shapes?: T[], + scales?: Base.Vector3[], + centers?: Base.Point3[] + ); + /** + * Shape to scale + * @default undefined + */ + shapes: T[]; + /** + * Scale factor to apply + * @default [[1, 1, 1]] + */ + scales: Base.Vector3[]; + /** + * Scale from the center + * @default [[0, 0, 0]] + */ + centers: Base.Point3[]; + } + class ShapeToMeshDto { + constructor(shape?: T, precision?: number, adjustYtoZ?: boolean); + /** + * Shape to save + * @default undefined + */ + shape: T; + /** + * Precision of the mesh + * @default 0.01 + * @minimum 0 + * @maximum Infinity + * @step 0.001 + */ + precision: number; + /** + * Adjust Y (up) coordinate system to Z (up) coordinate system + * @default false + */ + adjustYtoZ: boolean; + } + class ShapeFacesToPolygonPointsDto { + constructor( + shape?: T, + precision?: number, + adjustYtoZ?: boolean, + reversedPoints?: boolean + ); + /** + * Shape to save + * @default undefined + */ + shape: T; + /** + * Precision of the mesh + * @default 0.01 + * @minimum 0 + * @maximum Infinity + * @step 0.001 + */ + precision: number; + /** + * Adjust Y (up) coordinate system to Z (up) coordinate system + * @default false + */ + adjustYtoZ: boolean; + /** + * Reverse the order of the points describing the polygon because some CAD kernels use the opposite order + * @default false + */ + reversedPoints: boolean; + } + class ShapesToMeshesDto { + constructor(shapes?: T[], precision?: number, adjustYtoZ?: boolean); + /** + * Shapes to transform + * @default undefined + */ + shapes: T[]; + /** + * Precision of the mesh + * @default 0.01 + * @minimum 0 + * @maximum Infinity + * @step 0.001 + */ + precision: number; + /** + * Adjust Y (up) coordinate system to Z (up) coordinate system + * @default false + */ + adjustYtoZ: boolean; + } + class SaveStepDto { + constructor( + shape?: T, + fileName?: string, + adjustYtoZ?: boolean, + tryDownload?: boolean + ); + /** + * Shape to save + * @default undefined + */ + shape: T; + /** + * File name + * @default shape.step + */ + fileName: string; + /** + * Adjust Y (up) coordinate system to Z (up) coordinate system + * @default false + */ + adjustYtoZ: boolean; + /** + * Will assume that the shape is created in right handed coordinate system environment + * and will compensate by not mirroring the shape along z axis + * @default false + */ + fromRightHanded?: boolean; + /** + * Will attempt to download the file if that is possible, keep in mind that you might need to implement this yourself. In bitbybit this is handled by worker layers which only run in browsers. + * @default true + */ + tryDownload?: boolean; + } + class SaveStlDto { + constructor( + shape?: T, + fileName?: string, + precision?: number, + adjustYtoZ?: boolean, + tryDownload?: boolean, + binary?: boolean + ); + /** + * Shape to save + * @default undefined + */ + shape: T; + /** + * File name + * @default shape.stl + */ + fileName: string; + /** + * Precision of the mesh - lower means higher res + * @default 0.01 + */ + precision: number; + /** + * Adjust Y (up) coordinate system to Z (up) coordinate system + * @default false + */ + adjustYtoZ: boolean; + /** + * Will attempt to download the file if that is possible, keep in mind that you might need to implement this yourself. In bitbybit this is handled by worker layers which only run in browsers. + * @default true + */ + tryDownload?: boolean; + /** + * Generate binary STL file + * @default true + */ + binary?: boolean; + } + class ShapeToDxfPathsDto { + constructor( + shape?: T, + angularDeflection?: number, + curvatureDeflection?: number, + minimumOfPoints?: number, + uTolerance?: number, + minimumLength?: number + ); + /** + * Shape to convert to DXF paths + * @default undefined + */ + shape: T; + /** + * The angular deflection for curve tessellation + * @default 0.1 + * @minimum 0 + * @maximum Infinity + * @step 0.01 + */ + angularDeflection: number; + /** + * The curvature deflection for curve tessellation + * @default 0.1 + * @minimum 0 + * @maximum Infinity + * @step 0.001 + */ + curvatureDeflection: number; + /** + * Minimum of points for curve tessellation + * @default 2 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + minimumOfPoints: number; + /** + * U tolerance for curve tessellation + * @default 1.0e-9 + * @minimum 0 + * @maximum Infinity + * @step 1.0e-9 + */ + uTolerance: number; + /** + * Minimum length for curve tessellation + * @default 1.0e-7 + * @minimum 0 + * @maximum Infinity + * @step 1.0e-7 + */ + minimumLength: number; + } + class DxfPathsWithLayerDto { + constructor( + paths?: IO.DxfPathDto[], + layer?: string, + color?: Base.Color + ); + /** + * Array of DXF paths (output from shapeToDxfPaths) + * @default undefined + */ + paths: IO.DxfPathDto[]; + /** + * Layer name for these paths + * @default Default + */ + layer: string; + /** + * Color for these paths + * @default #000000 + */ + color: Base.Color; + } + class DxfPathsPartsListDto { + constructor( + pathsParts?: IO.DxfPathsPartDto[], + colorFormat?: dxfColorFormatEnum, + acadVersion?: dxfAcadVersionEnum, + tryDownload?: boolean + ); + /** + * Array of DXF paths parts (output from dxfPathsWithLayer) + * @default undefined + */ + pathsParts: IO.DxfPathsPartDto[]; + /** + * Color format to use in the DXF file + * @default aci + */ + colorFormat: dxfColorFormatEnum; + /** + * AutoCAD version format for DXF file + * @default AC1009 + */ + acadVersion: dxfAcadVersionEnum; + /** + * File name + * @default bitbybit-dev.dxf + */ + fileName?: string; + /** + * Will attempt to download the file if that is possible, keep in mind that you might need to implement this yourself. In bitbybit this is handled by worker layers which only run in browsers. + * @default true + */ + tryDownload?: boolean; + } + class SaveDxfDto { + constructor( + shape?: T, + fileName?: string, + tryDownload?: boolean, + angularDeflection?: number, + curvatureDeflection?: number, + minimumOfPoints?: number, + uTolerance?: number, + minimumLength?: number + ); + /** + * Shape to save + * @default undefined + */ + shape: T; + /** + * File name + * @default shape.dxf + */ + fileName: string; + /** + * Will attempt to download the file if that is possible, keep in mind that you might need to implement this yourself. In bitbybit this is handled by worker layers which only run in browsers. + * @default true + */ + tryDownload?: boolean; + /** + * The angular deflection + * @default 0.1 + * @minimum 0 + * @maximum Infinity + * @step 0.01 + */ + angularDeflection: number; + /** + * The curvature deflection + * @default 0.1 + * @minimum 0 + * @maximum Infinity + * @step 0.001 + */ + curvatureDeflection: number; + /** + * Minimum of points + * @default 2 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + minimumOfPoints: number; + /** + * U tolerance + * @default 1.0e-9 + * @minimum 0 + * @maximum Infinity + * @step 1.0e-9 + */ + uTolerance: number; + /** + * Minimum length + * @default 1.0e-7 + * @minimum 0 + * @maximum Infinity + * @step 1.0e-7 + */ + minimumLength: number; + } + class ImportStepIgesFromTextDto { + constructor( + text?: string, + fileType?: fileTypeEnum, + adjustZtoY?: boolean + ); + /** + * The text that represents step or iges contents + * @default undefined + */ + text: string; + /** + */ + fileType: fileTypeEnum; + /** + * Adjusts models that use Z coordinate as up to Y up system. + * @default true + */ + adjustZtoY: boolean; + } + class ImportStepIgesDto { + constructor(assetFile?: File, adjustZtoY?: boolean); + /** + * The name of the asset to store in the cache. + * @default undefined + */ + assetFile: File; + /** + * Adjusts models that use Z coordinate as up to Y up system. + * @default true + */ + adjustZtoY: boolean; + } + class LoadStepOrIgesDto { + constructor( + filetext?: string | ArrayBuffer, + fileName?: string, + adjustZtoY?: boolean + ); + /** + * File text + * @default undefined + */ + filetext: string | ArrayBuffer; + /** + * File name + * @default shape.igs + */ + fileName: string; + /** + * Adjusts models that use Z coordinate as up to Y up system. + * @default true + */ + adjustZtoY: boolean; + } + class CompoundShapesDto { + constructor(shapes?: T[]); + /** + * Shapes to add to compound + * @default undefined + */ + shapes: T[]; + } + class ThisckSolidSimpleDto { + constructor(shape?: T, offset?: number); + /** + * Shape to make thick + * @default undefined + */ + shape: T; + /** + * Offset distance + * @default 1 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + offset: number; + } + class Offset3DWireDto { + constructor(shape?: T, offset?: number, direction?: Base.Vector3); + /** + * Shape to make thick + * @default undefined + */ + shape: T; + /** + * Offset distance + * @default 1 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + offset: number; + /** + * Direction normal of the plane for the offset + * @default [0, 1, 0] + */ + direction: Base.Vector3; + } + class FaceFromWireDto { + constructor(shape?: T, planar?: boolean); + /** + * Wire shape to convert into a face + * @default undefined + */ + shape: T; + /** + * Should plane be planar + * @default false + */ + planar: boolean; + } + class FaceFromWireOnFaceDto { + constructor(wire?: T, face?: U, inside?: boolean); + /** + * Wire shape to convert into a face + * @default undefined + */ + wire: T; + /** + * Face to attach the wire to + * @default undefined + */ + face: U; + /** + * Indication if wire is inside the surface or outside + * @default true + */ + inside: boolean; + } + class FacesFromWiresOnFaceDto { + constructor(wires?: T[], face?: U, inside?: boolean); + /** + * Wire shape to convert into a face + * @default undefined + */ + wires: T[]; + /** + * Face to attach the wires to + * @default undefined + */ + face: U; + /** + * Indication if wire is inside the surface or outside + * @default true + */ + inside: boolean; + } + class FaceFromWiresDto { + constructor(shapes?: T[], planar?: boolean); + /** + * Wire shapes to convert into a faces + * @default undefined + */ + shapes: T[]; + /** + * Should plane be planar + * @default false + */ + planar: boolean; + } + class FacesFromWiresDto { + constructor(shapes?: T[], planar?: boolean); + /** + * Wire shapes to convert into a faces + * @default undefined + */ + shapes: T[]; + /** + * Should plane be planar + * @default false + */ + planar: boolean; + } + class FaceFromWiresOnFaceDto { + constructor(wires?: T[], face?: U, inside?: boolean); + /** + * Wire shapes to convert into a faces + * @default undefined + */ + wires: T[]; + /** + * Guide face to use as a base + * @default undefined + */ + face: U; + /** + * Indication if wire is inside the surface or outside + * @default true + */ + inside: boolean; + } + class SewDto { + constructor(shapes?: T[], tolerance?: number); + /** + * Faces to construct a shell from + * @default undefined + */ + shapes: T[]; + /** + * Tolerance of sewing + * @default 1.0e-7 + * @minimum 0 + * @maximum Infinity + * @step 0.00001 + */ + tolerance: number; + } + class FaceIsoCurveAtParamDto { + constructor(shape?: T, param?: number, dir?: "u" | "v"); + /** + * Face shape + * @default undefined + */ + shape: T; + /** + * Param at which to find isocurve + * @default 0.5 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + param: number; + /** + * Direction to find the isocurve + * @default u + */ + dir: "u" | "v"; + } + class DivideFaceToUVPointsDto { + constructor( + shape?: T, + nrOfPointsU?: number, + nrOfPointsV?: number, + flat?: boolean + ); + /** + * Face shape + * @default undefined + */ + shape: T; + /** + * Number of points on U direction + * @default 10 + * @minimum 1 + * @maximum Infinity + * @step 1 + */ + nrOfPointsU: number; + /** + * Number of points on V direction + * @default 10 + * @minimum 1 + * @maximum Infinity + * @step 1 + */ + nrOfPointsV: number; + /** + * Flatten the output + * @default false + */ + flat: boolean; + } + class Geom2dEllipseDto { + constructor( + center?: Base.Point2, + direction?: Base.Vector2, + radiusMinor?: number, + radiusMajor?: number, + sense?: boolean + ); + /** + * Center of the ellipse + * @default [0,0] + */ + center: Base.Point2; + /** + * Direction of the vector + * @default [1,0] + */ + direction: Base.Vector2; + /** + * Minor radius of an ellipse + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + radiusMinor: number; + /** + * Major radius of an ellipse + * @default 2 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + radiusMajor: number; + /** + * If true will sense the direction + * @default false + */ + sense: boolean; + } + class Geom2dCircleDto { + constructor( + center?: Base.Point2, + direction?: Base.Vector2, + radius?: number, + sense?: boolean + ); + /** + * Center of the circle + * @default [0,0] + */ + center: Base.Point2; + /** + * Direction of the vector + * @default [1,0] + */ + direction: Base.Vector2; + /** + * Radius of the circle + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + radius: number; + /** + * If true will sense the direction + * @default false + */ + sense: boolean; + } + class ChristmasTreeDto { + constructor( + height?: number, + innerDist?: number, + outerDist?: number, + nrSkirts?: number, + trunkHeight?: number, + trunkWidth?: number, + half?: boolean, + rotation?: number, + origin?: Base.Point3, + direction?: Base.Vector3 + ); + /** + * Height of the tree + * @default 6 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + height: number; + /** + * Inner distance of the branches on the bottom of the tree + * @default 1.5 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + innerDist: number; + /** + * Outer distance of the branches on the bottom of the tree + * @default 3 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + outerDist: number; + /** + * Number of skirts on the tree (triangle like shapes) + * @default 5 + * @minimum 1 + * @maximum Infinity + * @step 1 + */ + nrSkirts: number; + /** + * Trunk height + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + trunkHeight: number; + /** + * Trunk width only applies if trunk height is more than 0 + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + trunkWidth: number; + /** + * Indicates wether only a half of the tree should be created + * @default false + */ + half: boolean; + /** + * Rotation of the tree + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 15 + */ + rotation: number; + /** + * Origin of the tree + * @default [0, 0, 0] + */ + origin: Base.Point3; + /** + * Direction of the tree + * @default [0, 1, 0] + */ + direction: Base.Vector3; + } + class StarDto { + constructor( + outerRadius?: number, + innerRadius?: number, + numRays?: number, + center?: Base.Point3, + direction?: Base.Vector3, + offsetOuterEdges?: number, + half?: boolean + ); + /** + * Center of the circle + * @default [0,0,0] + */ + center: Base.Point3; + /** + * Direction + * @default [0, 1, 0] + */ + direction: Base.Vector3; + /** + * Direction of the vector + * @default 7 + * @minimum 3 + * @maximum Infinity + * @step 1 + */ + numRays: number; + /** + * Angle of the rays + * @default 2 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + outerRadius: number; + /** + * Angle of the rays + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + innerRadius: number; + /** + * Offsets outer edge cornerners along the direction vector + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + offsetOuterEdges?: number; + /** + * Construct half of the star + * @default false + */ + half: boolean; + } + class ParallelogramDto { + constructor( + center?: Base.Point3, + direction?: Base.Vector3, + aroundCenter?: boolean, + width?: number, + height?: number, + angle?: number + ); + /** + * Center of the circle + * @default [0, 0, 0] + */ + center: Base.Point3; + /** + * Direction + * @default [0, 1, 0] + */ + direction: Base.Vector3; + /** + * Indicates whether to draw the parallelogram around the center point or start from corner. + * @default true + */ + aroundCenter: boolean; + /** + * Width of bounding rectangle + * @default 2 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + width: number; + /** + * Height of bounding rectangle + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + height: number; + /** + * Sharp angle of the parallelogram + * @default 15 + * @minimum -Infinity + * @maximum Infinity + * @step 1 + */ + angle: number; + } + class Heart2DDto { + constructor( + center?: Base.Point3, + direction?: Base.Vector3, + rotation?: number, + sizeApprox?: number + ); + /** + * Center of the circle + * @default [0, 0, 0] + */ + center: Base.Point3; + /** + * Direction + * @default [0, 1, 0] + */ + direction: Base.Vector3; + /** + * Rotation of the hear + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 15 + */ + rotation: number; + /** + * Size of the bounding box within which the heart gets drawn + * @default 2 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + sizeApprox: number; + } + class NGonWireDto { + constructor( + center?: Base.Point3, + direction?: Base.Vector3, + nrCorners?: number, + radius?: number + ); + /** + * Center of the circle + * @default [0, 0, 0] + */ + center: Base.Point3; + /** + * Direction + * @default [0, 1, 0] + */ + direction: Base.Vector3; + /** + * How many corners to create. + * @default 6 + * @minimum 3 + * @maximum Infinity + * @step 1 + */ + nrCorners: number; + /** + * Radius of nGon + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + radius: number; + } + class EllipseDto { + constructor( + center?: Base.Point3, + direction?: Base.Vector3, + radiusMinor?: number, + radiusMajor?: number + ); + /** + * Center of the ellipse + * @default [0, 0, 0] + */ + center: Base.Point3; + /** + * Direction of the vector + * @default [0, 1, 0] + */ + direction: Base.Vector3; + /** + * Minor radius of an ellipse + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + radiusMinor: number; + /** + * Major radius of an ellipse + * @default 2 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + radiusMajor: number; + } + class TextWiresDto { + constructor( + text?: string, + xOffset?: number, + yOffset?: number, + height?: number, + lineSpacing?: number, + letterSpacing?: number, + align?: Base.horizontalAlignEnum, + extrudeOffset?: number, + origin?: Base.Point3, + rotation?: number, + direction?: Base.Vector3, + centerOnOrigin?: boolean + ); + /** + * The text + * @default Hello World + */ + text?: string; + /** + * The x offset + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + xOffset?: number; + /** + * The y offset + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + yOffset?: number; + /** + * The height of the text + * @default 1 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + height?: number; + /** + * The line spacing + * @default 2 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + lineSpacing?: number; + /** + * The letter spacing offset + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + letterSpacing?: number; + /** + * The extrude offset + * @default left + */ + align?: Base.horizontalAlignEnum; + /** + * The extrude offset + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + extrudeOffset?: number; + /** + * Indicates whether to center text on origin + * @default false + */ + centerOnOrigin: boolean; + } + class GeomCylindricalSurfaceDto { + constructor( + radius?: number, + center?: Base.Point3, + direction?: Base.Vector3 + ); + /** + * Radius of the cylindrical surface + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + radius: number; + /** + * Center of the cylindrical surface + * @default [0, 0, 0] + */ + center: Base.Point3; + /** + * Axis of direction for cylindrical surface + * @default [0, 1, 0] + */ + direction: Base.Vector3; + } + class Geom2dTrimmedCurveDto { + constructor( + shape?: T, + u1?: number, + u2?: number, + sense?: boolean, + adjustPeriodic?: boolean + ); + /** + * 2D Curve to trim + * @default undefined + */ + shape: T; + /** + * First param on the curve for trimming. U1 can be greater or lower than U2. The returned curve is oriented from U1 to U2. + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + u1: number; + /** + * Second parameter on the curve for trimming + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + u2: number; + /** + * If the basis curve C is periodic there is an ambiguity because two parts are available. + * In this case by default the trimmed curve has the same orientation as the basis curve (Sense = True). + * If Sense = False then the orientation of the trimmed curve is opposite to the orientation of the basis curve C. + * @default true + */ + sense: boolean; + /** + * If the curve is closed but not periodic it is not possible to keep the part of the curve including the + * junction point (except if the junction point is at the beginning or at the end of the trimmed curve) + * because you could lose the fundamental characteristics of the basis curve which are used for example + * to compute the derivatives of the trimmed curve. So for a closed curve the rules are the same as for a open curve. + * @default true + */ + adjustPeriodic: boolean; + } + class Geom2dSegmentDto { + constructor(start?: Base.Point2, end?: Base.Point2); + /** + * Start 2d point for segment + * @default [0, 0] + */ + start: Base.Point2; + /** + * End 2d point for segment + * @default [1, 0] + */ + end: Base.Point2; + } + class SliceDto { + constructor(shape?: T, step?: number, direction?: Base.Vector3); + /** + * The shape to slice + * @default undefined + */ + shape: T; + /** + * Step at which to divide the shape + * @default 0.1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + step: number; + /** + * Direction vector + * @default [0, 1, 0] + */ + direction: Base.Vector3; + } + class SliceInStepPatternDto { + constructor(shape?: T, steps?: number[], direction?: Base.Vector3); + /** + * The shape to slice + * @default undefined + */ + shape: T; + /** + * Steps that should be used for slicing. This array is going to be treated as a pattern - + * this menas that if the actual number of steps is lower than the number of steps in the pattern, the pattern will be repeated. + * @default [0.1, 0.2] + */ + steps: number[]; + /** + * Direction vector + * @default [0, 1, 0] + */ + direction: Base.Vector3; + } + class SimpleLinearLengthDimensionDto { + constructor( + start?: Base.Point3, + end?: Base.Point3, + direction?: Base.Vector3, + offsetFromPoints?: number, + crossingSize?: number, + labelSuffix?: string, + labelSize?: number, + labelOffset?: number, + labelRotation?: number, + arrowType?: dimensionEndTypeEnum, + arrowSize?: number, + arrowAngle?: number, + arrowsFlipped?: boolean, + labelFlipHorizontal?: boolean, + labelFlipVertical?: boolean, + labelOverwrite?: string, + removeTrailingZeros?: boolean + ); + /** + * The start point for dimension + * @default undefined + */ + start: Base.Point3; + /** + * The end point for dimension + * @default undefined + */ + end?: Base.Point3; + /** + * The dimension direction (must include length) + * @default undefined + */ + direction?: Base.Vector3; + /** + * The dimension label + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + offsetFromPoints?: number; + /** + * The dimension crossing size + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + crossingSize?: number; + /** + * The dimension label decimal places + * @default 2 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + decimalPlaces?: number; + /** + * The dimension label suffix + * @default (cm) + */ + labelSuffix?: string; + /** + * The dimension label size + * @default 0.1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + labelSize?: number; + /** + * The dimension label offset + * @default 0.3 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + labelOffset?: number; + /** + * The dimension label rotation + * @default 0 + * @minimum -360 + * @maximum 360 + * @step 1 + */ + labelRotation?: number; + /** + * End type for dimension + * @default none + */ + endType?: dimensionEndTypeEnum; + /** + * The size/length of dimension arrows + * @default 0.3 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + arrowSize?: number; + /** + * The total angle between arrow lines (max 90 degrees) + * @default 30 + * @minimum 0 + * @maximum 90 + * @step 1 + */ + arrowAngle?: number; + /** + * Flip arrows to point outward instead of inward + * @default false + */ + arrowsFlipped?: boolean; + /** + * Flip label horizontally + * @default false + */ + labelFlipHorizontal?: boolean; + /** + * Flip label vertically + * @default false + */ + labelFlipVertical?: boolean; + /** + * Override label text with custom expression (supports 'val' for computed value, e.g., '100*val', 'Length: val mm') + * @default 1*val + * @optional true + */ + labelOverwrite?: string; + /** + * Remove trailing zeros from decimal places + * @default false + */ + removeTrailingZeros?: boolean; + } + class SimpleAngularDimensionDto { + constructor( + direction1?: Base.Point3, + direction2?: Base.Point3, + center?: Base.Point3, + radius?: number, + offsetFromCenter?: number, + crossingSize?: number, + radians?: boolean, + labelSuffix?: string, + labelSize?: number, + labelOffset?: number, + endType?: dimensionEndTypeEnum, + arrowSize?: number, + arrowAngle?: number, + arrowsFlipped?: boolean, + labelRotation?: number, + labelFlipHorizontal?: boolean, + labelFlipVertical?: boolean, + labelOverwrite?: string, + removeTrailingZeros?: boolean + ); + /** + * The first direction for dimension + * @default [1, 0, 0] + */ + direction1: Base.Point3; + /** + * The second direction for dimension + * @default [0, 0, 1] + */ + direction2: Base.Point3; + /** + * The center point for dimension + * @default [0, 0, 0] + */ + center: Base.Point3; + /** + * The dimension radius + * @default 4 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + radius: number; + /** + * Offset from center + * @default 0.5 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + offsetFromCenter: number; + /** + * The dimension crossing size + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + extraSize: number; + /** + * The dimension label decimal places + * @default 2 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + decimalPlaces: number; + /** + * The dimension label suffix + * @default (deg) + */ + labelSuffix: string; + /** + * The dimension label size + * @default 0.1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + labelSize: number; + /** + * The dimension label offset + * @default 0.3 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + labelOffset: number; + /** + * If true the angle is in radians + * @default false + */ + radians: boolean; + /** + * End type for dimension + * @default none + */ + endType?: dimensionEndTypeEnum; + /** + * The size/length of dimension arrows + * @default 0.3 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + arrowSize?: number; + /** + * The total angle between arrow lines (max 90 degrees) + * @default 30 + * @minimum 0 + * @maximum 90 + * @step 1 + */ + arrowAngle?: number; + /** + * Flip arrows to point outward instead of inward + * @default false + */ + arrowsFlipped?: boolean; + /** + * Additional rotation angle for the label in degrees + * @default 0 + * @minimum -360 + * @maximum 360 + * @step 1 + */ + labelRotation?: number; + /** + * Flip label horizontally + * @default false + */ + labelFlipHorizontal?: boolean; + /** + * Flip label vertically + * @default false + */ + labelFlipVertical?: boolean; + /** + * Override label text with custom expression (supports 'val' for computed value, e.g., '100*val', 'Angle: val deg') + * @default 1*val + * @optional true + */ + labelOverwrite?: string; + /** + * Remove trailing zeros from decimal places + * @default false + */ + removeTrailingZeros?: boolean; + } + class PinWithLabelDto { + constructor( + startPoint?: Base.Point3, + endPoint?: Base.Point3, + direction?: Base.Vector3, + offsetFromStart?: number, + label?: string, + labelOffset?: number, + labelSize?: number, + endType?: dimensionEndTypeEnum, + arrowSize?: number, + arrowAngle?: number, + arrowsFlipped?: boolean, + labelRotation?: number, + labelFlipHorizontal?: boolean, + labelFlipVertical?: boolean + ); + /** + * The start point for dimension + * @default [0, 0, 0] + */ + startPoint: Base.Point3; + /** + * The end point for dimension + * @default [0, 5, 2] + */ + endPoint?: Base.Point3; + /** + * The dimension direction (must include length) + * @default [0, 0, 1] + */ + direction?: Base.Vector3; + /** + * Offset from the start point + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + offsetFromStart?: number; + /** + * The dimension label + * @default Pin + */ + label?: string; + /** + * The dimension label offset + * @default 0.3 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + labelOffset?: number; + /** + * The dimension label size + * @default 0.1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + labelSize?: number; + /** + * End type for dimension + * @default none + */ + endType?: dimensionEndTypeEnum; + /** + * The size/length of dimension arrows + * @default 0.3 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + arrowSize?: number; + /** + * The total angle between arrow lines (max 90 degrees) + * @default 30 + * @minimum 0 + * @maximum 90 + * @step 1 + */ + arrowAngle?: number; + /** + * Flip arrows to point outward instead of inward + * @default false + */ + arrowsFlipped?: boolean; + /** + * Additional rotation angle for the label in degrees + * @default 0 + * @minimum -360 + * @maximum 360 + * @step 1 + */ + labelRotation?: number; + /** + * Flip label horizontally + * @default false + */ + labelFlipHorizontal?: boolean; + /** + * Flip label vertically + * @default false + */ + labelFlipVertical?: boolean; + } + class StarSolidDto extends StarDto { + constructor( + outerRadius?: number, + innerRadius?: number, + numRays?: number, + center?: Base.Point3, + direction?: Base.Vector3, + offsetOuterEdges?: number, + half?: boolean, + extrusionLengthFront?: number, + extrusionLengthBack?: number + ); + /** + * Extrusion length in the forward direction + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + extrusionLengthFront: number; + /** + * Extrusion length in the backward direction + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + extrusionLengthBack: number; + } + class NGonSolidDto extends NGonWireDto { + constructor( + center?: Base.Point3, + direction?: Base.Vector3, + nrCorners?: number, + radius?: number, + extrusionLengthFront?: number, + extrusionLengthBack?: number + ); + /** + * Extrusion length in the forward direction + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + extrusionLengthFront: number; + /** + * Extrusion length in the backward direction + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + extrusionLengthBack: number; + } + class ParallelogramSolidDto extends ParallelogramDto { + constructor( + center?: Base.Point3, + direction?: Base.Vector3, + aroundCenter?: boolean, + width?: number, + height?: number, + angle?: number, + extrusionLengthFront?: number, + extrusionLengthBack?: number + ); + /** + * Extrusion length in the forward direction + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + extrusionLengthFront: number; + /** + * Extrusion length in the backward direction + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + extrusionLengthBack: number; + } + class HeartSolidDto extends Heart2DDto { + constructor( + center?: Base.Point3, + direction?: Base.Vector3, + rotation?: number, + sizeApprox?: number, + extrusionLengthFront?: number, + extrusionLengthBack?: number + ); + /** + * Extrusion length in the forward direction + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + extrusionLengthFront: number; + /** + * Extrusion length in the backward direction + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + extrusionLengthBack: number; + } + class ChristmasTreeSolidDto extends ChristmasTreeDto { + constructor( + height?: number, + innerDist?: number, + outerDist?: number, + nrSkirts?: number, + trunkHeight?: number, + trunkWidth?: number, + half?: boolean, + rotation?: number, + origin?: Base.Point3, + direction?: Base.Vector3, + extrusionLengthFront?: number, + extrusionLengthBack?: number + ); + /** + * Extrusion length in the forward direction + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + extrusionLengthFront: number; + /** + * Extrusion length in the backward direction + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + extrusionLengthBack: number; + } + class LPolygonSolidDto extends LPolygonDto { + constructor( + widthFirst?: number, + lengthFirst?: number, + widthSecond?: number, + lengthSecond?: number, + align?: directionEnum, + rotation?: number, + center?: Base.Point3, + direction?: Base.Vector3, + extrusionLengthFront?: number, + extrusionLengthBack?: number + ); + /** + * Extrusion length in the forward direction + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + extrusionLengthFront: number; + /** + * Extrusion length in the backward direction + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + extrusionLengthBack: number; + } + } + declare namespace BabylonCamera { + class ArcRotateCameraDto { + constructor( + radius?: number, + alpha?: number, + beta?: number, + lowerRadiusLimit?: number, + upperRadiusLimit?: number, + lowerAlphaLimit?: number, + upperAlphaLimit?: number, + lowerBetaLimit?: number, + upperBetaLimit?: number, + angularSensibilityX?: number, + angularSensibilityY?: number, + panningSensibility?: number, + wheelPrecision?: number, + maxZ?: number + ); + /** + * Defines the camera distance from its target. This radius will be used to rotate the camera around the target as default. + * @default 20 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + radius: number; + /** + * Target of the arc rotate camera. Camera will look at and rotate around this point by default. + * @default [0, 0, 0] + */ + target: Base.Point3; + /** + * Defines the camera rotation along the longitudinal (horizontal) axis in degrees + * @default 45 + * @minimum -360 + * @maximum 360 + * @step 1 + */ + alpha: number; + /** + * Defines the camera rotation along the latitudinal (vertical) axis in degrees. This is counted from top down, where 0 is looking from top straight down. + * @default 70 + * @minimum -360 + * @maximum 360 + * @step 1 + */ + beta: number; + /** + * Lower radius limit - how close can the camera be to the target + * @default undefined + * @minimum -Infinity + * @maximum Infinity + * @step 1 + * @optional true + */ + lowerRadiusLimit: any; + /** + * Upper radius limit - how far can the camera be from the target + * @default undefined + * @minimum -Infinity + * @maximum Infinity + * @step 1 + * @optional true + */ + upperRadiusLimit: any; + /** + * Lower alpha limit - camera rotation along the longitudinal (horizontal) axis in degrees. + * @default undefined + * @minimum -360 + * @maximum 360 + * @step 1 + * @optional true + */ + lowerAlphaLimit: any; + /** + * Upper alpha limit - camera rotation along the longitudinal (horizontal) axis in degrees. + * @default undefined + * @minimum -360 + * @maximum 360 + * @step 1 + * @optional true + */ + upperAlphaLimit: any; + /** + * Lower beta limit - camera rotation along the latitudinal (vertical) axis in degrees. This is counted from the top down, where 0 is looking from top straight down. + * @default 1 + * @minimum -360 + * @maximum 360 + * @step 1 + */ + lowerBetaLimit: number; + /** + * Upper beta limit - camera rotation along the longitudinal (vertical) axis in degrees. This is counted from the top down, where 180 is looking from bottom straight up. + * @default 179 + * @minimum -360 + * @maximum 360 + * @step 1 + */ + upperBetaLimit: number; + /** + * Angular sensibility along x (horizontal) axis of the camera + * @default 1000 + * @minimum 0 + * @maximum Infinity + * @step 10 + */ + angularSensibilityX: number; + /** + * Angular sensibility along y (vertical) axis of the camera + * @default 1000 + * @minimum 0 + * @maximum Infinity + * @step 10 + */ + angularSensibilityY: number; + /** + * Panning sensibility. The lower this number gets the faster camera will move when panning. + * @default 1000 + * @minimum 0 + * @maximum Infinity + * @step 100 + */ + panningSensibility: number; + /** + * Wheel precision. The lower this number gets the faster camera will move when zooming. + * @default 3 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + wheelPrecision: number; + /** + * Maximum distance the camera can see. Objects that are further away from the camera than this value will not be rendered. + * @default 1000 + * @minimum 0 + * @maximum Infinity + * @step 10 + */ + maxZ: number; + } + class FreeCameraDto { + constructor(position?: Base.Point3, target?: Base.Point3); + /** + * Position of the free camera + * @default [20, 20, 20] + */ + position: Base.Point3; + /** + * Target of the free camera + * @default [0, 0, 0] + */ + target: Base.Point3; + } + class TargetCameraDto { + constructor(position?: Base.Point3, target?: Base.Point3); + /** + * Position of the free camera + * @default [20, 20, 20] + */ + position: Base.Point3; + /** + * Target of the free camera + * @default [0, 0, 0] + */ + target: Base.Point3; + } + class PositionDto { + constructor(camera?: BABYLON.TargetCamera, position?: Base.Point3); + /** + * Target camera + */ + camera: BABYLON.TargetCamera; + /** + * Position of the free camera + * @default [20, 20, 20] + */ + position: Base.Point3; + } + class SpeedDto { + constructor(camera?: BABYLON.TargetCamera, speed?: number); + /** + * Target camera + */ + camera: BABYLON.TargetCamera; + /** + * speed of the camera + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + speed: number; + } + class TargetDto { + constructor(camera?: BABYLON.TargetCamera, target?: Base.Point3); + /** + * Target camera + */ + camera: BABYLON.TargetCamera; + /** + * target of the camera + * @default [0, 0, 0] + */ + target: Base.Point3; + } + class MinZDto { + constructor(camera?: BABYLON.Camera, minZ?: number); + /** + * Free camera + */ + camera: BABYLON.Camera; + /** + * minZ of the camera + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 0.01 + */ + minZ: number; + } + class MaxZDto { + constructor(camera?: BABYLON.Camera, maxZ?: number); + /** + * Free camera + */ + camera: BABYLON.Camera; + /** + * maxZ of the camera + * @default 1000 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + maxZ: number; + } + class OrthographicDto { + constructor( + camera?: BABYLON.Camera, + orthoLeft?: number, + orthoRight?: number, + orthoTop?: number, + orthoBottom?: number + ); + /** + * Camera to adjust + */ + camera: BABYLON.Camera; + /** + * Left side limit of the orthographic camera + * @default -1 + * @minimum -Infinity + * @maximum Infinity + * @step 1 + */ + orthoLeft: number; + /** + * Right side limit of the orthographic camera + * @default 1 + * @minimum -Infinity + * @maximum Infinity + * @step 1 + */ + orthoRight: number; + /** + * Bottom side limit of the orthographic camera + * @default -1 + * @minimum -Infinity + * @maximum Infinity + * @step 1 + */ + orthoBottom: number; + /** + * Top side limit of the orthographic camera + * @default 1 + * @minimum -Infinity + * @maximum Infinity + * @step 1 + */ + orthoTop: number; + } + class CameraDto { + constructor(camera?: BABYLON.Camera); + /** + * Camera + */ + camera: BABYLON.Camera; + } + } + declare namespace BabylonGaussianSplatting { + class CreateGaussianSplattingMeshDto { + constructor(url?: string); + /** + * Babylon Mesh that needs to be updated + * @default undefined + */ + url: string; + } + class GaussianSplattingMeshDto { + constructor(babylonMesh?: BABYLON.GaussianSplattingMesh); + /** + * Gaussian Splatting Mesh that needs to be updated + */ + babylonMesh: BABYLON.GaussianSplattingMesh; + } + } + declare namespace BabylonGizmo { + enum positionGizmoObservableSelectorEnum { + /** Fires an event when any of it's sub gizmos are dragged */ + onDragStartObservable = "onDragStartObservable", + /** Fires an event when any of it's sub gizmos are being dragged */ + onDragObservable = "onDragObservable", + /** Fires an event when any of it's sub gizmos are released from dragging */ + onDragEndObservable = "onDragEndObservable", + } + enum rotationGizmoObservableSelectorEnum { + /** Fires an event when any of it's sub gizmos are dragged */ + onDragStartObservable = "onDragStartObservable", + /** Fires an event when any of it's sub gizmos are being dragged */ + onDragObservable = "onDragObservable", + /** Fires an event when any of it's sub gizmos are released from dragging */ + onDragEndObservable = "onDragEndObservable", + } + enum scaleGizmoObservableSelectorEnum { + /** Fires an event when any of it's sub gizmos are dragged */ + onDragStartObservable = "onDragStartObservable", + /** Fires an event when any of it's sub gizmos are being dragged */ + onDragObservable = "onDragObservable", + /** Fires an event when any of it's sub gizmos are released from dragging */ + onDragEndObservable = "onDragEndObservable", + } + enum boundingBoxGizmoObservableSelectorEnum { + /** + * Fired when a rotation anchor or scale box is dragged + */ + onDragStartObservable = "onDragStartObservable", + /** + * Fired when a scale box is dragged + */ + onScaleBoxDragObservable = "onScaleBoxDragObservable", + /** + * Fired when a scale box drag is ended + */ + onScaleBoxDragEndObservable = "onScaleBoxDragEndObservable", + /** + * Fired when a rotation anchor is dragged + */ + onRotationSphereDragObservable = "onRotationSphereDragObservable", + /** + * Fired when a rotation anchor drag is ended + */ + onRotationSphereDragEndObservable = "onRotationSphereDragEndObservable", + } + class CreateGizmoDto { + constructor( + positionGizmoEnabled?: boolean, + rotationGizmoEnabled?: boolean, + scaleGizmoEnabled?: boolean, + boundingBoxGizmoEnabled?: boolean, + attachableMeshes?: BABYLON.AbstractMesh[], + clearGizmoOnEmptyPointerEvent?: boolean, + scaleRatio?: number, + usePointerToAttachGizmos?: boolean + ); + /** + * Enable position gizmo + * @default true + */ + positionGizmoEnabled: boolean; + /** + * Enable rotation gizmo + * @default false + */ + rotationGizmoEnabled: boolean; + /** + * Enable scale gizmo + * @default false + */ + scaleGizmoEnabled: boolean; + /** + * Enable bounding box gizmo + * @default false + */ + boundingBoxGizmoEnabled: boolean; + /** + * Use pointer to attach gizmos + * @default true + */ + usePointerToAttachGizmos: boolean; + /** + * Clear gizmo on empty pointer event + * @default false + */ + clearGizmoOnEmptyPointerEvent: boolean; + /** + * Scale ratio + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + scaleRatio: number; + /** + * Attachable meshes + * @default undefined + */ + attachableMeshes: BABYLON.AbstractMesh[]; + } + class GizmoDto { + constructor(gizmo?: BABYLON.IGizmo); + /** + * Gizmo to use + * @default undefined + */ + gizmo: BABYLON.IGizmo; + } + class SetGizmoScaleRatioDto { + constructor(gizmo?: BABYLON.IGizmo, scaleRatio?: number); + /** + * gizmo + * @default undefined + */ + gizmo: BABYLON.IGizmo; + /** + * Scale ratio + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + scaleRatio: number; + } + class GizmoManagerDto { + constructor(gizmoManager?: BABYLON.GizmoManager); + /** + * Gizmo manager to use + * @default undefined + */ + gizmoManager: BABYLON.GizmoManager; + } + class PositionGizmoDto { + constructor(gizmoManager?: BABYLON.IPositionGizmo); + /** + * Gizmo manager to use + * @default undefined + */ + positionGizmo: BABYLON.IPositionGizmo; + } + class SetPlanarGizmoEnabled { + constructor( + positionGizmo?: BABYLON.IPositionGizmo, + planarGizmoEnabled?: boolean + ); + /** + * Position gizmo + * @default undefined + */ + positionGizmo: BABYLON.IPositionGizmo; + /** + * Planar gizmo enabled + * @default true + */ + planarGizmoEnabled: boolean; + } + class SetScaleGizmoSnapDistanceDto { + constructor(scaleGizmo?: BABYLON.IScaleGizmo, snapDistance?: number); + /** + * Scale gizmo + * @default undefined + */ + scaleGizmo: BABYLON.IScaleGizmo; + /** + * Snap distance + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + snapDistance: number; + } + class SetScaleGizmoIncrementalSnapDto { + constructor( + scaleGizmo?: BABYLON.IScaleGizmo, + incrementalSnap?: boolean + ); + /** + * Scale gizmo + * @default undefined + */ + scaleGizmo: BABYLON.IScaleGizmo; + /** + * Incremental snap + * @default false + */ + incrementalSnap: boolean; + } + class SetScaleGizmoSensitivityDto { + constructor(scaleGizmo?: BABYLON.IScaleGizmo, sensitivity?: number); + /** + * Scale gizmo + * @default undefined + */ + scaleGizmo: BABYLON.IScaleGizmo; + /** + * Sensitivity + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + sensitivity: number; + } + class ScaleGizmoDto { + constructor(scaleGizmo?: BABYLON.IScaleGizmo); + /** + * Scale gizmo + * @default undefined + */ + scaleGizmo: BABYLON.IScaleGizmo; + } + class BoundingBoxGizmoDto { + constructor(boundingBoxGizmo?: BABYLON.BoundingBoxGizmo); + /** + * Bounding box gizmo + * @default undefined + */ + boundingBoxGizmo: BABYLON.BoundingBoxGizmo; + } + class SetBoundingBoxGizmoRotationSphereSizeDto { + constructor( + boundingBoxGizmo?: BABYLON.BoundingBoxGizmo, + rotationSphereSize?: number + ); + /** + * Bounding box gizmo + * @default undefined + */ + boundingBoxGizmo: BABYLON.BoundingBoxGizmo; + /** + * The size of the rotation anchors attached to the bounding box (Default: 0.1) + * @default 0.1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + rotationSphereSize: number; + } + class SetBoundingBoxGizmoFixedDragMeshScreenSizeDto { + constructor( + boundingBoxGizmo?: BABYLON.BoundingBoxGizmo, + fixedDragMeshScreenSize?: boolean + ); + /** + * Bounding box gizmo + * @default undefined + */ + boundingBoxGizmo: BABYLON.BoundingBoxGizmo; + /** + * fiex drag mesh screen size + * @default false + */ + fixedDragMeshScreenSize: boolean; + } + class SetBoundingBoxGizmoFixedDragMeshBoundsSizeDto { + constructor( + boundingBoxGizmo?: BABYLON.BoundingBoxGizmo, + fixedDragMeshBoundsSize?: boolean + ); + /** + * Bounding box gizmo + * @default undefined + */ + boundingBoxGizmo: BABYLON.BoundingBoxGizmo; + /** + * fixed drag mesh bounds size + * @default false + */ + fixedDragMeshBoundsSize: boolean; + } + class SetBoundingBoxGizmoFixedDragMeshScreenSizeDistanceFactorDto { + constructor( + boundingBoxGizmo?: BABYLON.BoundingBoxGizmo, + fixedDragMeshScreenSizeDistanceFactor?: number + ); + /** + * Bounding box gizmo + * @default undefined + */ + boundingBoxGizmo: BABYLON.BoundingBoxGizmo; + /** + * fixed drag mesh screen size distance factor + * @default 10 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + fixedDragMeshScreenSizeDistanceFactor: number; + } + class SetBoundingBoxGizmoScalingSnapDistanceDto { + constructor( + boundingBoxGizmo?: BABYLON.BoundingBoxGizmo, + scalingSnapDistance?: number + ); + /** + * Bounding box gizmo + * @default undefined + */ + boundingBoxGizmo: BABYLON.BoundingBoxGizmo; + /** + * Scaling snap distance + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + scalingSnapDistance: number; + } + class SetBoundingBoxGizmoRotationSnapDistanceDto { + constructor( + boundingBoxGizmo?: BABYLON.BoundingBoxGizmo, + rotationSnapDistance?: number + ); + /** + * Bounding box gizmo + * @default undefined + */ + boundingBoxGizmo: BABYLON.BoundingBoxGizmo; + /** + * Rotation snap distance + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + rotationSnapDistance: number; + } + class SetBoundingBoxGizmoScaleBoxSizeDto { + constructor( + boundingBoxGizmo?: BABYLON.BoundingBoxGizmo, + scaleBoxSize?: number + ); + /** + * Bounding box gizmo + * @default undefined + */ + boundingBoxGizmo: BABYLON.BoundingBoxGizmo; + /** + * The size of the scale boxes attached to the bounding box (Default: 0.1) + * @default 0.1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + scaleBoxSize: number; + } + class SetBoundingBoxGizmoIncrementalSnapDto { + constructor( + boundingBoxGizmo?: BABYLON.BoundingBoxGizmo, + incrementalSnap?: boolean + ); + /** + * Bounding box gizmo + * @default undefined + */ + boundingBoxGizmo: BABYLON.BoundingBoxGizmo; + /** + * Incremental snap + * @default false + */ + incrementalSnap: boolean; + } + class SetBoundingBoxGizmoScalePivotDto { + constructor( + boundingBoxGizmo?: BABYLON.BoundingBoxGizmo, + scalePivot?: Base.Vector3 + ); + /** + * Bounding box gizmo + * @default undefined + */ + boundingBoxGizmo: BABYLON.BoundingBoxGizmo; + /** + * Scale pivot + * @default undefined + */ + scalePivot: Base.Vector3; + } + class SetBoundingBoxGizmoAxisFactorDto { + constructor( + boundingBoxGizmo?: BABYLON.BoundingBoxGizmo, + axisFactor?: Base.Vector3 + ); + /** + * Bounding box gizmo + * @default undefined + */ + boundingBoxGizmo: BABYLON.BoundingBoxGizmo; + /** + * Axis factor + * @default undefined + */ + axisFactor: Base.Vector3; + } + class SetBoundingBoxGizmoScaleDragSpeedDto { + constructor( + boundingBoxGizmo?: BABYLON.BoundingBoxGizmo, + scaleDragSpeed?: number + ); + /** + * Bounding box gizmo + * @default undefined + */ + boundingBoxGizmo: BABYLON.BoundingBoxGizmo; + /** + * Scale drag speed + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + scaleDragSpeed: number; + } + class SetPositionGizmoSnapDistanceDto { + constructor( + positionGizmo?: BABYLON.IPositionGizmo, + snapDistance?: number + ); + /** + * Position gizmo + * @default undefined + */ + positionGizmo: BABYLON.IPositionGizmo; + /** + * Snap distance + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + snapDistance: number; + } + class SetRotationGizmoSnapDistanceDto { + constructor( + rotationGizmo?: BABYLON.IRotationGizmo, + snapDistance?: number + ); + /** + * Position gizmo + * @default undefined + */ + rotationGizmo: BABYLON.IRotationGizmo; + /** + * Snap distance + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + snapDistance: number; + } + class SetRotationGizmoSensitivityDto { + constructor( + rotationGizmo?: BABYLON.IRotationGizmo, + sensitivity?: number + ); + /** + * Position gizmo + * @default undefined + */ + rotationGizmo: BABYLON.IRotationGizmo; + /** + * Sensitivity + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + sensitivity: number; + } + class RotationGizmoDto { + constructor(rotationGizmo?: BABYLON.IRotationGizmo); + /** + * Rotation gizmo + * @default undefined + */ + rotationGizmo: BABYLON.IRotationGizmo; + } + class AxisScaleGizmoDto { + constructor(axisScaleGizmo?: BABYLON.IAxisScaleGizmo); + /** + * axis scale gizmo + * @default undefined + */ + axisScaleGizmo: BABYLON.IAxisScaleGizmo; + } + class SetIsEnabledAxisScaleGizmoDto { + constructor( + gizmoManager?: BABYLON.IAxisScaleGizmo, + isEnabled?: boolean + ); + /** + * axis scale gizmo + * @default undefined + */ + axisScaleGizmo: BABYLON.IAxisScaleGizmo; + /** + * Is enabled + * @default true + */ + isEnabled: boolean; + } + class AxisDragGizmoDto { + constructor(axisDragGizmo?: BABYLON.IAxisDragGizmo); + /** + * axis drag gizmo + * @default undefined + */ + axisDragGizmo: BABYLON.IAxisDragGizmo; + } + class SetIsEnabledAxisDragGizmoDto { + constructor(gizmoManager?: BABYLON.IAxisDragGizmo, isEnabled?: boolean); + /** + * axis drag gizmo + * @default undefined + */ + axisDragGizmo: BABYLON.IAxisDragGizmo; + /** + * Is enabled + * @default true + */ + isEnabled: boolean; + } + class SetIsEnabledPlaneRotationGizmoDto { + constructor( + planeRotationGizmo?: BABYLON.IPlaneRotationGizmo, + isEnabled?: boolean + ); + /** + * plane drag gizmo + * @default undefined + */ + planeRotationGizmo: BABYLON.IPlaneRotationGizmo; + /** + * Is enabled + * @default true + */ + isEnabled: boolean; + } + class SetIsEnabledPlaneDragGizmoDto { + constructor( + planeDragGizmo?: BABYLON.IPlaneDragGizmo, + isEnabled?: boolean + ); + /** + * plane drag gizmo + * @default undefined + */ + planeDragGizmo: BABYLON.IPlaneDragGizmo; + /** + * Is enabled + * @default true + */ + isEnabled: boolean; + } + class PlaneDragGizmoDto { + constructor(planeDragGizmo?: BABYLON.IPlaneDragGizmo); + /** + * plane drag gizmo + * @default undefined + */ + planeDragGizmo: BABYLON.IPlaneDragGizmo; + } + class PlaneRotationGizmoDto { + constructor(planeRotationGizmo?: BABYLON.IPlaneRotationGizmo); + /** + * plane drag gizmo + * @default undefined + */ + planeRotationGizmo: BABYLON.IPlaneRotationGizmo; + } + class AttachToMeshDto { + constructor( + mesh: BABYLON.AbstractMesh, + gizmoManager: BABYLON.GizmoManager + ); + /** + * Mesh to attach gizmo manager to + */ + mesh: BABYLON.AbstractMesh; + /** + * Gizmo manager to attach + */ + gizmoManager: BABYLON.GizmoManager; + } + class PositionGizmoObservableSelectorDto { + constructor(selector: positionGizmoObservableSelectorEnum); + /** + * Selector + */ + selector: positionGizmoObservableSelectorEnum; + } + class BoundingBoxGizmoObservableSelectorDto { + constructor(selector: boundingBoxGizmoObservableSelectorEnum); + /** + * Selector + */ + selector: boundingBoxGizmoObservableSelectorEnum; + } + class RotationGizmoObservableSelectorDto { + constructor(selector: rotationGizmoObservableSelectorEnum); + /** + * Selector + */ + selector: rotationGizmoObservableSelectorEnum; + } + class ScaleGizmoObservableSelectorDto { + constructor(selector: scaleGizmoObservableSelectorEnum); + /** + * Selector + */ + selector: scaleGizmoObservableSelectorEnum; + } + } + declare namespace BabylonGui { + enum horizontalAlignmentEnum { + left = "left", + center = "center", + right = "right", + } + enum verticalAlignmentEnum { + top = "top", + center = "center", + bottom = "bottom", + } + enum inputTextObservableSelectorEnum { + /** Observable raised when the text changes */ + onTextChangedObservable = "onTextChangedObservable", + /** Observable raised just before an entered character is to be added */ + onBeforeKeyAddObservable = "onBeforeKeyAddObservable", + /** Observable raised when the text is highlighted */ + onTextHighlightObservable = "onTextHighlightObservable", + /** Observable raised when copy event is triggered */ + onTextCopyObservable = "onTextCopyObservable", + /** Observable raised when cut event is triggered */ + onTextCutObservable = "onTextCutObservable", + /** Observable raised when paste event is triggered */ + onTextPasteObservable = "onTextPasteObservable", + } + enum sliderObservableSelectorEnum { + /** + * Raised when the value has changed + */ + onValueChangedObservable = "onValueChangedObservable", + } + enum colorPickerObservableSelectorEnum { + /** + * Raised when the value has changed + */ + onValueChangedObservable = "onValueChangedObservable", + } + enum textBlockObservableSelectorEnum { + /** + * Raised when the text has changed + */ + onTextChangedObservable = "onTextChangedObservable", + } + enum checkboxObservableSelectorEnum { + /** + * Raised when the checkbox is checked or unchecked + */ + onIsCheckedChangedObservable = "onIsCheckedChangedObservable", + } + enum radioButtonObservableSelectorEnum { + /** + * Raised when the radio button is checked or unchecked + */ + onIsCheckedChangedObservable = "onIsCheckedChangedObservable", + } + enum controlObservableSelectorEnum { + onFocusObservable = "onFocusObservable", + onBlurObservable = "onBlurObservable", + /** + * Observable that fires whenever the accessibility event of the control has changed + */ + onAccessibilityTagChangedObservable = "onAccessibilityTagChangedObservable", + /** + * An event triggered when pointer wheel is scrolled + */ + onWheelObservable = "onWheelObservable", + /** + * An event triggered when the pointer moves over the control. + */ + onPointerMoveObservable = "onPointerMoveObservable", + /** + * An event triggered when the pointer moves out of the control. + */ + onPointerOutObservable = "onPointerOutObservable", + /** + * An event triggered when the pointer taps the control + */ + onPointerDownObservable = "onPointerDownObservable", + /** + * An event triggered when pointer up + */ + onPointerUpObservable = "onPointerUpObservable", + /** + * An event triggered when a control is clicked on + */ + onPointerClickObservable = "onPointerClickObservable", + /** + * An event triggered when a control receives an ENTER key down event + */ + onEnterPressedObservable = "onEnterPressedObservable", + /** + * An event triggered when pointer enters the control + */ + onPointerEnterObservable = "onPointerEnterObservable", + /** + * An event triggered when the control is marked as dirty + */ + onDirtyObservable = "onDirtyObservable", + /** + * An event triggered before drawing the control + */ + onBeforeDrawObservable = "onBeforeDrawObservable", + /** + * An event triggered after the control was drawn + */ + onAfterDrawObservable = "onAfterDrawObservable", + /** + * An event triggered when the control has been disposed + */ + onDisposeObservable = "onDisposeObservable", + /** + * An event triggered when the control isVisible is changed + */ + onIsVisibleChangedObservable = "onIsVisibleChangedObservable", + } + class CreateFullScreenUIDto { + constructor( + name?: string, + foreground?: boolean, + adaptiveScaling?: boolean + ); + /** + * Name of advanced texture + * @default fullscreen + */ + name: string; + /** + * Foreground + * @default true + */ + foreground?: boolean; + /** + * Adaptive scaling + * @default false + */ + adaptiveScaling?: boolean; + } + class CreateForMeshDto { + constructor( + mesh?: BABYLON.AbstractMesh, + width?: number, + height?: number, + supportPointerMove?: boolean, + onlyAlphaTesting?: boolean, + invertY?: boolean, + sampling?: BabylonTexture.samplingModeEnum + ); + /** + * Mesh + * @default undefined + */ + mesh: BABYLON.AbstractMesh; + /** + * Width + * @default undefined + * @optional true + */ + width?: number; + /** + * Height + * @default undefined + * @optional true + */ + height?: number; + /** + * Support pointer move + * @default true + */ + supportPointerMove: boolean; + /** + * Only alpha testing + * @default false + */ + onlyAlphaTesting: boolean; + /** + * Invert Y + * @default true + */ + invertY: boolean; + /** + * Sampling + * @default trilinear + */ + sampling: BabylonTexture.samplingModeEnum; + } + class CreateStackPanelDto { + constructor( + name?: string, + isVertical?: boolean, + spacing?: number, + width?: number | string, + height?: number | string, + color?: string, + background?: string + ); + /** + * Name of stack panel + * @default stackPanel + */ + name: string; + /** + * Horizontal or vertical + * @default true + */ + isVertical: boolean; + /** + * Spacing between each child in pixels + * @default 0 + */ + spacing: number; + /** + * Width of the stack panel. This value should not be set when in horizontal mode as it will be computed automatically. + * @default undefined + * @optional true + */ + width: number | string; + /** + * Height of the stack panel. This value should not be set when in vertical mode as it will be computed automatically. + * @default undefined + * @optional true + */ + height: number | string; + /** + * Color of the stack panel + * @default #00000000 + */ + color: string; + /** + * Background of the stack panel. We give transparency to the background by default so that it would be visible + * @default #00000055 + */ + background: string; + } + class SetStackPanelIsVerticalDto { + constructor(stackPanel?: BABYLON.GUI.StackPanel, isVertical?: boolean); + /** + * Stack panel to update + * @default undefined + */ + stackPanel: BABYLON.GUI.StackPanel; + /** + * Is vertical + * @default true + */ + isVertical: boolean; + } + class SetStackPanelSpacingDto { + constructor(stackPanel?: BABYLON.GUI.StackPanel, spacing?: number); + /** + * Stack panel to update + * @default undefined + */ + stackPanel: BABYLON.GUI.StackPanel; + /** + * Spacing between each child in pixels + * @default 0 + */ + spacing: number; + } + class SetStackPanelWidthDto { + constructor( + stackPanel?: BABYLON.GUI.StackPanel, + width?: number | string + ); + /** + * Stack panel to update + * @default undefined + */ + stackPanel: BABYLON.GUI.StackPanel; + /** + * Width of the stack panel + * @default undefined + * @optional true + */ + width: number | string; + } + class SetStackPanelHeightDto { + constructor( + stackPanel?: BABYLON.GUI.StackPanel, + height?: number | string + ); + /** + * Stack panel to update + * @default undefined + */ + stackPanel: BABYLON.GUI.StackPanel; + /** + * Height of the stack panel. + * @default undefined + * @optional true + */ + height: number | string; + } + class StackPanelDto { + constructor(stackPanel?: BABYLON.GUI.StackPanel); + /** + * Stack panel to update + * @default undefined + */ + stackPanel: BABYLON.GUI.StackPanel; + } + class SliderObservableSelectorDto { + constructor(selector: sliderObservableSelectorEnum); + /** + * Selector for the observable + * @default onValueChangedObservable + */ + selector: sliderObservableSelectorEnum; + } + class ColorPickerObservableSelectorDto { + constructor(selector: colorPickerObservableSelectorEnum); + /** + * Selector for the observable + * @default onValueChangedObservable + */ + selector: colorPickerObservableSelectorEnum; + } + class InputTextObservableSelectorDto { + constructor(selector: inputTextObservableSelectorEnum); + /** + * Selector for the observable + * @default onTextChangedObservable + */ + selector: inputTextObservableSelectorEnum; + } + class RadioButtonObservableSelectorDto { + constructor(selector: radioButtonObservableSelectorEnum); + /** + * Selector for the observable + * @default onIsCheckedChangedObservable + */ + selector: radioButtonObservableSelectorEnum; + } + class CheckboxObservableSelectorDto { + constructor(selector: checkboxObservableSelectorEnum); + /** + * Selector for the observable + * @default onIsCheckedChangedObservable + */ + selector: checkboxObservableSelectorEnum; + } + class ControlObservableSelectorDto { + constructor(selector: controlObservableSelectorEnum); + /** + * Selector for the observable + * @default onPointerClickObservable + */ + selector: controlObservableSelectorEnum; + } + class TextBlockObservableSelectorDto { + constructor(selector: textBlockObservableSelectorEnum); + /** + * Selector for the observable + * @default onTextChangedObservable + */ + selector: textBlockObservableSelectorEnum; + } + class ContainerDto { + constructor(container?: BABYLON.GUI.Container); + /** + * Container to update + * @default undefined + */ + container: BABYLON.GUI.Container; + } + class AddControlsToContainerDto { + constructor( + container?: BABYLON.GUI.StackPanel, + controls?: BABYLON.GUI.Control[], + clearControlsFirst?: boolean + ); + /** + * Container to add control to + * @default undefined + */ + container: BABYLON.GUI.Container; + /** + * Controls to add + * @default undefined + */ + controls: BABYLON.GUI.Control[]; + /** + * Clear controls first. That will preserve the order of the controls. + * @default true + */ + clearControlsFirst: boolean; + } + class GetControlByNameDto { + constructor(container?: BABYLON.GUI.Container, name?: string); + /** + * Container to get control from + * @default undefined + */ + container: BABYLON.GUI.Container; + /** + * Name of the control + * @default controlName + */ + name: string; + } + class SetControlIsVisibleDto { + constructor(control?: BABYLON.GUI.Control, isVisible?: boolean); + /** + * Control to update + * @default undefined + */ + control: BABYLON.GUI.Control; + /** + * Is visible + * @default true + */ + isVisible: boolean; + } + class SetControlIsReadonlyDto { + constructor(control?: BABYLON.GUI.Control, isReadOnly?: boolean); + /** + * Control to update + * @default undefined + */ + control: BABYLON.GUI.Control; + /** + * Is readonly + * @default false + */ + isReadOnly: boolean; + } + class SetControlIsEnabledDto { + constructor(control?: BABYLON.GUI.Control, isEnabled?: boolean); + /** + * Control to update + * @default undefined + */ + control: BABYLON.GUI.Control; + /** + * Is enabled + * @default true + */ + isEnabled: boolean; + } + class CreateImageDto { + constructor( + name?: string, + url?: string, + color?: string, + width?: number | string, + height?: number | string + ); + /** + * Name of the image + * @default imageName + */ + name: string; + /** + * Link to the image + * @default undefined + */ + url: string; + /** + * Color of the image + * @default black + */ + color: string; + /** + * Width of the image + * @default undefined + * @optional true + */ + width?: number | string; + /** + * Height of the image + * @default undefined + * @optional true + */ + height?: number | string; + } + class SetImageUrlDto { + constructor(image?: BABYLON.GUI.Image, url?: string); + /** + * Image to update + * @default undefined + */ + image: BABYLON.GUI.Image; + /** + * Link to the image + * @default undefined + */ + url: string; + } + class ImageDto { + constructor(image?: BABYLON.GUI.Image); + /** + * Image to update + * @default undefined + */ + image: BABYLON.GUI.Image; + } + class CreateButtonDto { + constructor( + name?: string, + label?: string, + color?: string, + background?: string, + width?: number | string, + height?: number | string, + fontSize?: number + ); + /** + * Name of the button + * @default buttonName + */ + name: string; + /** + * Text of the button + * @default Click me! + */ + label: string; + /** + * Color of the button + * @default black + */ + color: string; + /** + * Background of the button + * @default #f0cebb + */ + background: string; + /** + * Width of the button + * @default undefined + * @optional true + */ + width?: number | string; + /** + * Height of the button + * @default undefined + * @optional true + */ + height?: number | string; + /** + * Font size of the button + * @default 24 + */ + fontSize: number; + } + class SetButtonTextDto { + constructor(button?: BABYLON.GUI.Button, text?: string); + /** + * Button to update + * @default undefined + */ + button: BABYLON.GUI.Button; + /** + * Text of the button + * @default Click me! + */ + text: string; + } + class ButtonDto { + constructor(button?: BABYLON.GUI.Button); + /** + * Button to update + * @default undefined + */ + button: BABYLON.GUI.Button; + } + class CreateColorPickerDto { + constructor( + name?: string, + defaultColor?: string, + color?: string, + width?: number | string, + height?: number | string, + size?: number | string + ); + /** + * Name of the color picker + * @default colorPickerName + */ + name: string; + /** + * Default color of the color picker + * @default #f0cebb + */ + defaultColor: string; + /** + * Color of the color picker + * @default #f0cebb + */ + color: string; + /** + * Width of the color picker + * @default undefined + * @optional true + */ + width?: number | string; + /** + * Height of the color picker + * @default undefined + * @optional true + */ + height?: number | string; + /** + * Size of the color picker + * @default 300px + * @optional true + */ + size?: number | string; + } + class SetColorPickerValueDto { + constructor(colorPicker?: BABYLON.GUI.ColorPicker, color?: string); + /** + * Color picker to update + * @default undefined + */ + colorPicker: BABYLON.GUI.ColorPicker; + /** + * Value of the color picker + * @default undefined + */ + color: string; + } + class SetColorPickerSizeDto { + constructor( + colorPicker?: BABYLON.GUI.ColorPicker, + size?: number | string + ); + /** + * Color picker to update + * @default undefined + */ + colorPicker: BABYLON.GUI.ColorPicker; + /** + * Size of the color picker + * @default 300px + * @optional true + */ + size?: number | string; + } + class ColorPickerDto { + constructor(colorPicker?: BABYLON.GUI.ColorPicker); + /** + * Color picker to update + * @default undefined + */ + colorPicker: BABYLON.GUI.ColorPicker; + } + class CreateCheckboxDto { + constructor( + name?: string, + isChecked?: boolean, + checkSizeRatio?: number, + color?: string, + background?: string, + width?: number | string, + height?: number | string + ); + /** + * Name of the checkbox + * @default checkboxName + */ + name: string; + /** + * Is checked + * @default false + */ + isChecked: boolean; + /** + * Check size ratio + * @default 0.8 + * @minimum 0 + * @maximum 1 + * @step 0.05 + */ + checkSizeRatio: number; + /** + * Color of the checkbox + * @default #f0cebb + */ + color: string; + /** + * Background of the checkbox + * @default black + */ + background: string; + /** + * Width of the checkbox + * @default undefined + * @optional true + */ + width?: number | string; + /** + * Height of the checkbox + * @default undefined + * @optional true + */ + height?: number | string; + } + class SetControlFontSizeDto { + constructor(control?: BABYLON.GUI.Control, fontSize?: number); + /** + * Control to update + * @default undefined + */ + control: BABYLON.GUI.Control; + /** + * Font size of the button + * @default 24 + */ + fontSize: number; + } + class SetControlHeightDto { + constructor(control?: BABYLON.GUI.Control, height?: number | string); + /** + * Control to update + * @default undefined + */ + control: BABYLON.GUI.Control; + /** + * Height of the checkbox + * @default undefined + */ + height: number | string; + } + class SetControlWidthDto { + constructor(control?: BABYLON.GUI.Control, width?: number | string); + /** + * Control to update + * @default undefined + */ + control: BABYLON.GUI.Control; + /** + * Width of the checkbox + * @default undefined + */ + width: number | string; + } + class SetControlColorDto { + constructor(control?: BABYLON.GUI.Control, color?: string); + /** + * Control to update + * @default undefined + */ + control: BABYLON.GUI.Control; + /** + * Color of the checkbox + * @default #f0cebb + */ + color: string; + } + class SetContainerBackgroundDto { + constructor(container?: BABYLON.GUI.Container, background?: string); + /** + * Container to update + * @default undefined + */ + container: BABYLON.GUI.Container; + /** + * Background of the checkbox + * @default black + */ + background: string; + } + class SetContainerIsReadonlyDto { + constructor(container?: BABYLON.GUI.Container, isReadOnly?: boolean); + /** + * Container to update + * @default undefined + */ + container: BABYLON.GUI.Container; + /** + * Is readonly + * @default false + */ + isReadOnly: boolean; + } + class SetCheckboxBackgroundDto { + constructor(checkbox?: BABYLON.GUI.Checkbox, background?: string); + /** + * Checkbox to update + * @default undefined + */ + checkbox: BABYLON.GUI.Checkbox; + /** + * Background of the checkbox + * @default black + */ + background: string; + } + class SetCheckboxCheckSizeRatioDto { + constructor(checkbox?: BABYLON.GUI.Checkbox, checkSizeRatio?: number); + /** + * Checkbox to update + * @default undefined + */ + checkbox: BABYLON.GUI.Checkbox; + /** + * Check size ratio + * @default 0.8 + * @minimum 0 + * @maximum 1 + * @step 0.05 + */ + checkSizeRatio: number; + } + class CheckboxDto { + constructor(checkbox?: BABYLON.GUI.Checkbox); + /** + * Checkbox to update + * @default undefined + */ + checkbox: BABYLON.GUI.Checkbox; + } + class ControlDto { + constructor(control?: BABYLON.GUI.Control); + /** + * Control to update + * @default undefined + */ + control: BABYLON.GUI.Control; + } + class SetCheckboxIsCheckedDto { + constructor(checkbox?: BABYLON.GUI.Checkbox, isChecked?: boolean); + /** + * Checkbox to update + * @default undefined + */ + checkbox: BABYLON.GUI.Checkbox; + /** + * Is checked + * @default false + */ + isChecked: boolean; + } + class CreateInputTextDto { + constructor( + name?: string, + color?: string, + background?: string, + width?: number | string, + height?: number | string + ); + /** + * Name of the button + * @default inputName + */ + name: string; + /** + * Text of the input + * @default + */ + text: string; + /** + * Placeholder of the input + * @default + */ + placeholder: string; + /** + * Color of the button + * @default #f0cebb + */ + color: string; + /** + * Background of the button + * @default black + */ + background: string; + /** + * Width of the button + * @default undefined + * @optional true + */ + width?: number | string; + /** + * Height of the button + * @default undefined + * @optional true + */ + height?: number | string; + } + class SetInputTextBackgroundDto { + constructor(inputText?: BABYLON.GUI.InputText, background?: string); + /** + * Input text to update + * @default undefined + */ + inputText: BABYLON.GUI.InputText; + /** + * Background of the input text + * @default black + */ + background: string; + } + class SetInputTextTextDto { + constructor(inputText?: BABYLON.GUI.InputText, text?: string); + /** + * Input text to update + * @default undefined + */ + inputText: BABYLON.GUI.InputText; + /** + * Text of the input text + * @default + */ + text: string; + } + class SetInputTextPlaceholderDto { + constructor(inputText?: BABYLON.GUI.InputText, placeholder?: string); + /** + * Input text to update + * @default undefined + */ + inputText: BABYLON.GUI.InputText; + /** + * Placeholder of the input text + * @default + */ + placeholder: string; + } + class InputTextDto { + constructor(inputText?: BABYLON.GUI.InputText); + /** + * Input text to update + * @default undefined + */ + inputText: BABYLON.GUI.InputText; + } + class CreateRadioButtonDto { + constructor( + name?: string, + group?: string, + isChecked?: boolean, + checkSizeRatio?: number, + color?: string, + background?: string, + width?: number | string, + height?: number | string + ); + /** + * Name of the button + * @default radioBtnName + */ + name: string; + /** + * Group of the radio button which is used when multiple radio buttons needs to be split into separate groups + * @default + * @optional true + */ + group: string; + /** + * Is checked + * @default false + */ + isChecked: boolean; + /** + * Check size ratio + * @default 0.8 + * @minimum 0 + * @maximum 1 + * @step 0.05 + */ + checkSizeRatio: number; + /** + * Color of the button + * @default #f0cebb + */ + color: string; + /** + * Background of the button + * @default black + */ + background: string; + /** + * Width of the button + * @default undefined + * @optional true + */ + width?: number | string; + /** + * Height of the button + * @default undefined + * @optional true + */ + height?: number | string; + } + class SetRadioButtonCheckSizeRatioDto { + constructor( + radioButton?: BABYLON.GUI.RadioButton, + checkSizeRatio?: number + ); + /** + * Radio button to update + * @default undefined + */ + radioButton: BABYLON.GUI.RadioButton; + /** + * Check size ratio + * @default 0.8 + * @minimum 0 + * @maximum 1 + * @step 0.05 + */ + checkSizeRatio: number; + } + class SetRadioButtonGroupDto { + constructor(radioButton?: BABYLON.GUI.RadioButton, group?: string); + /** + * Radio button to update + * @default undefined + */ + radioButton: BABYLON.GUI.RadioButton; + /** + * Group of the radio button + * @default + */ + group: string; + } + class SetRadioButtonBackgroundDto { + constructor(radioButton?: BABYLON.GUI.RadioButton, background?: string); + /** + * Radio button to update + * @default undefined + */ + radioButton: BABYLON.GUI.RadioButton; + /** + * Background of the radio button + * @default black + */ + background: string; + } + class RadioButtonDto { + constructor(radioButton?: BABYLON.GUI.RadioButton); + /** + * Radio button to update + * @default undefined + */ + radioButton: BABYLON.GUI.RadioButton; + } + class CreateSliderDto { + constructor( + name?: string, + minimum?: number, + maximum?: number, + value?: number, + step?: number, + isVertical?: boolean, + color?: string, + background?: string, + width?: number | string, + height?: number | string, + displayThumb?: boolean + ); + /** + * Name of the button + * @default sliderName + */ + name: string; + /** + * Minimum value of the slider + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + minimum: number; + /** + * Maximum value of the slider + * @default 10 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + maximum: number; + /** + * Value of the slider + * @default 5 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + value: number; + /** + * Step of the slider + * @default 0.01 + * @minimum -Infinity + * @maximum Infinity + * @step 0.01 + */ + step: number; + /** + * Is slider vertical + * @default false + */ + isVertical: boolean; + /** + * Color of the button + * @default #f0cebb + */ + color: string; + /** + * Background of the button + * @default black + */ + background: string; + /** + * Width of the button + * @default undefined + * @optional true + */ + width?: number | string; + /** + * Height of the button + * @default undefined + * @optional true + */ + height?: number | string; + /** + * Should display thumb + * @default true + */ + displayThumb: boolean; + } + class CreateTextBlockDto { + constructor( + name?: string, + text?: string, + color?: string, + width?: number | string, + height?: number | string + ); + /** + * Name of the text block + * @default textBlockName + */ + name: string; + /** + * Text of the block + * @default Hello World! + */ + text: string; + /** + * Color of the text block + * @default #f0cebb + */ + color: string; + /** + * Width of the text block + * @default undefined + * @optional true + */ + width?: number | string; + /** + * Height of the text block + * @default undefined + * @optional true + */ + height?: number | string; + /** + * Font size of the text block + * @default 24 + */ + fontSize: number; + } + class SetTextBlockTextDto { + constructor(textBlock?: BABYLON.GUI.TextBlock, text?: string); + /** + * Text block to update + * @default undefined + */ + textBlock: BABYLON.GUI.TextBlock; + /** + * Text of the block + * @default undefined + */ + text: string; + } + class SetTextBlockResizeToFitDto { + constructor(textBlock?: BABYLON.GUI.TextBlock, resizeToFit?: boolean); + /** + * Text block to update + * @default undefined + */ + textBlock: BABYLON.GUI.TextBlock; + /** + * Resize to fit + * @default false + */ + resizeToFit: boolean; + } + class SetTextBlockTextWrappingDto { + constructor(textBlock?: BABYLON.GUI.TextBlock, textWrapping?: boolean); + /** + * Text block to update + * @default undefined + */ + textBlock: BABYLON.GUI.TextBlock; + /** + * Text wrapping + * @default undefined + */ + textWrapping: boolean | BABYLON.GUI.TextWrapping; + } + class SetTextBlockLineSpacingDto { + constructor( + textBlock?: BABYLON.GUI.TextBlock, + lineSpacing?: string | number + ); + /** + * Text block to update + * @default undefined + */ + textBlock: BABYLON.GUI.TextBlock; + /** + * Line spacing of the text + * @default undefined + */ + lineSpacing: string | number; + } + class TextBlockDto { + constructor(textBlock?: BABYLON.GUI.TextBlock); + /** + * Text block to update + * @default undefined + */ + textBlock: BABYLON.GUI.TextBlock; + } + class SliderThumbDto { + constructor( + slider?: BABYLON.GUI.Slider, + isThumbCircle?: boolean, + thumbColor?: string, + thumbWidth?: string | number, + isThumbClamped?: boolean, + displayThumb?: boolean + ); + /** + * Slider for which the thumb needs to be updated + * @default undefined + */ + slider: BABYLON.GUI.Slider; + /** + * Is thumb circle + * @default false + */ + isThumbCircle: boolean; + /** + * Color of the thumb + * @default white + */ + thumbColor: string; + /** + * Thumb width + * @default undefined + * @optional true + */ + thumbWidth?: string | number; + /** + * Is thumb clamped + * @default false + */ + isThumbClamped: boolean; + /** + * Should display thumb + * @default true + */ + displayThumb: boolean; + } + class SliderDto { + constructor(slider?: BABYLON.GUI.Slider); + /** + * Slider for which the thumb needs to be updated + * @default undefined + */ + slider: BABYLON.GUI.Slider; + } + class SliderBorderColorDto { + constructor(slider?: BABYLON.GUI.Slider, borderColor?: string); + /** + * Slider for which the thumb needs to be updated + * @default undefined + */ + slider: BABYLON.GUI.Slider; + /** + * Border color of the slider + * @default white + */ + borderColor: string; + } + class SliderBackgroundColorDto { + constructor(slider?: BABYLON.GUI.Slider, backgroundColor?: string); + /** + * Slider for which the thumb needs to be updated + * @default undefined + */ + slider: BABYLON.GUI.Slider; + /** + * Background color of the slider + * @default black + */ + backgroundColor: string; + } + class SetSliderValueDto { + constructor(slider?: BABYLON.GUI.Slider, value?: number); + /** + * Slider for which the thumb needs to be updated + * @default undefined + */ + slider: BABYLON.GUI.Slider; + /** + * Value of the slider + * @default 5 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + value: number; + } + class PaddingLeftRightTopBottomDto { + constructor( + control?: BABYLON.GUI.Control, + paddingLeft?: number | string, + paddingRight?: number | string, + paddingTop?: number | string, + paddingBottom?: number | string + ); + /** + * Control to change the padding + * @default undefined + */ + control: BABYLON.GUI.Control; + /** + * Padding left of the stack panel + * @default undefined + * @optional true + */ + paddingLeft: number | string; + /** + * Padding right of the stack panel + * @default undefined + * @optional true + */ + paddingRight: number | string; + /** + * Padding top of the stack panel + * @default undefined + * @optional true + */ + paddingTop: number | string; + /** + * Padding bottom of the stack panel + * @default undefined + * @optional true + */ + paddingBottom: number | string; + } + class CloneControlDto { + constructor( + control?: BABYLON.GUI.Control, + container?: BABYLON.GUI.Container, + name?: string, + host?: BABYLON.GUI.AdvancedDynamicTexture + ); + /** + * Control to clone + * @default undefined + */ + control: BABYLON.GUI.Control; + /** + * Use container to which the cloned control will be added + * @default undefined + * @optional true + */ + container?: BABYLON.GUI.Container; + /** + * Name of the cloned control + * @default clonedControl + */ + name: string; + /** + * Host of the cloned control + * @default undefined + * @optional true + */ + host?: BABYLON.GUI.AdvancedDynamicTexture; + } + class AlignmentDto { + constructor( + control?: T, + horizontalAlignment?: horizontalAlignmentEnum, + verticalAlignment?: verticalAlignmentEnum + ); + /** + * Control to change the padding + * @default undefined + */ + control: T; + /** + * Alignment horizontal + * @default center + */ + horizontalAlignment: horizontalAlignmentEnum; + /** + * Alignment horizontal + * @default center + */ + verticalAlignment: verticalAlignmentEnum; + } + class SetTextBlockTextOutlineDto { + constructor( + textBlock?: BABYLON.GUI.TextBlock, + outlineWidth?: number, + outlineColor?: string + ); + /** + * Control to change the padding + * @default undefined + */ + textBlock: BABYLON.GUI.TextBlock; + /** + * Alignment horizontal + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + outlineWidth: number; + /** + * Outline color + * @default white + */ + outlineColor: string; + } + } + declare namespace BabylonIO { + class ExportSceneGlbDto { + constructor(fileName?: string, discardSkyboxAndGrid?: boolean); + /** + * File name that should be used for the scene. + * @default bitbybit-scene + */ + fileName: string; + /** + * Discard skybox and grid + * @default false + * @optional true + */ + discardSkyboxAndGrid?: boolean; + } + class ExportSceneDto { + constructor(fileName?: string); + /** + * File name that should be used for the scene. + * @default bitbybit-scene + */ + fileName: string; + } + class ExportMeshToStlDto { + constructor(mesh?: BABYLON.Mesh, fileName?: string); + /** + * Mesh to export + */ + mesh: BABYLON.Mesh; + /** + * File name that should be used for the scene. + * @default bitbybit-mesh + */ + fileName: string; + } + class ExportMeshesToStlDto { + constructor(meshes?: BABYLON.Mesh[], fileName?: string); + /** + * Meshes to export + */ + meshes: BABYLON.Mesh[]; + /** + * File name that should be used for the scene. + * @default bitbybit-mesh + */ + fileName: string; + } + } + declare namespace BabylonLight { + class ShadowLightDirectionToTargetDto { + constructor(shadowLight?: BABYLON.ShadowLight, target?: Base.Vector3); + /** + * Shadow light to update + * @default undefined + */ + shadowLight: BABYLON.ShadowLight; + /** + * The direction target + * @default undefined + */ + target?: Base.Vector3; + } + class ShadowLightPositionDto { + constructor(shadowLight?: BABYLON.ShadowLight, position?: Base.Vector3); + /** + * Shadow light to update + * @default undefined + */ + shadowLight: BABYLON.ShadowLight; + /** + * The position + * @default undefined + */ + position?: Base.Vector3; + } + } + declare namespace BabylonMaterial { + class PBRMetallicRoughnessDto { + constructor( + name?: string, + baseColor?: Base.Color, + emissiveColor?: Base.Color, + metallic?: number, + roughness?: number, + alpha?: number, + backFaceCulling?: boolean, + zOffset?: number + ); + /** + * Name of the material + * @default Custom Material + */ + name: string; + /** + * Base color of the material + * @default #0000ff + */ + baseColor: Base.Color; + /** + * Emissive color of the material + * @default #000000 + */ + emissiveColor?: Base.Color; + /** + * Metallic value of the material + * @default 0.6 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + metallic: number; + /** + * Roughness value of the material + * @default 0.5 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + roughness: number; + /** + * Defines the transparency of the material + * @default 1 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + alpha: number; + /** + * Identifies if both sides of the surface should have material applied + * @default false + */ + backFaceCulling: boolean; + /** + * Defines the z offset of the material + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + zOffset: number; + } + class BaseColorDto { + constructor( + material?: BABYLON.PBRMetallicRoughnessMaterial, + baseColor?: Base.Color + ); + /** + * Material to update + * @default undefined + */ + material: BABYLON.PBRMetallicRoughnessMaterial; + /** + * Base color of the material + * @default #0000ff + */ + baseColor?: Base.Color; + } + class MaterialPropDto { + constructor(material?: BABYLON.PBRMetallicRoughnessMaterial); + /** + * Material to investigate + * @default undefined + */ + material: BABYLON.PBRMetallicRoughnessMaterial; + } + class SkyMaterialPropDto { + constructor(skyMaterial?: MATERIALS.SkyMaterial); + /** + * Material to investigate + * @default undefined + */ + skyMaterial: MATERIALS.SkyMaterial; + } + class MetallicDto { + constructor( + material?: BABYLON.PBRMetallicRoughnessMaterial, + metallic?: number + ); + /** + * Material to update + * @default undefined + */ + material: BABYLON.PBRMetallicRoughnessMaterial; + /** + * Metallic value of the material + * @default 0.5 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + metallic?: number; + } + class RoughnessDto { + constructor( + material?: BABYLON.PBRMetallicRoughnessMaterial, + roughness?: number + ); + /** + * Material to update + * @default undefined + */ + material: BABYLON.PBRMetallicRoughnessMaterial; + /** + * Roughness value of the material + * @default 0.5 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + roughness?: number; + } + class AlphaDto { + constructor( + material?: BABYLON.PBRMetallicRoughnessMaterial, + alpha?: number + ); + /** + * Material to update + * @default undefined + */ + material: BABYLON.PBRMetallicRoughnessMaterial; + /** + * Alpha value of the material + * @default 0.5 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + alpha?: number; + } + class BackFaceCullingDto { + constructor( + material?: BABYLON.PBRMetallicRoughnessMaterial, + backFaceCulling?: boolean + ); + /** + * Material to update + * @default undefined + */ + material: BABYLON.PBRMetallicRoughnessMaterial; + /** + * back face culling + * @default true + */ + backFaceCulling?: boolean; + } + class BaseTextureDto { + constructor( + material?: BABYLON.PBRMetallicRoughnessMaterial, + baseTexture?: BABYLON.Texture + ); + /** + * Material to update + * @default undefined + */ + material: BABYLON.PBRMetallicRoughnessMaterial; + /** + * Base texture of the material + * @default undefined + */ + baseTexture: BABYLON.Texture; + } + class SkyMaterialDto { + constructor( + luminance?: number, + turbidity?: number, + rayleigh?: number, + mieCoefficient?: number, + mieDirectionalG?: number, + distance?: number, + inclination?: number, + azimuth?: number, + sunPosition?: Base.Vector3, + useSunPosition?: boolean, + cameraOffset?: Base.Vector3, + up?: Base.Vector3, + dithering?: boolean + ); + /** + * Defines the overall luminance of sky in interval ]0, 1[. + * @default 1 + * @minimum 0 + * @maximum 1 + * @step 0.01 + * + */ + luminance: number; + /** + * Defines the amount (scattering) of haze as opposed to molecules in atmosphere. + * @default 10 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + turbidity: number; + /** + * Defines the sky appearance (light intensity). + * @default 2 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + rayleigh: number; + /** + * Defines the mieCoefficient in interval [0, 0.1] which affects the property .mieDirectionalG. + * @default 0.005 + * @minimum 0 + * @maximum Infinity + * @step 0.001 + */ + mieCoefficient: number; + /** + * Defines the amount of haze particles following the Mie scattering theory. + * @default 0.8 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + mieDirectionalG: number; + /** + * Defines the distance of the sun according to the active scene camera. + * @default 500 + * @minimum 0 + * @maximum Infinity + * @step 10 + */ + distance: number; + /** + * Defines the sun inclination, in interval [-0.5, 0.5]. When the inclination is not 0, the sun is said + * "inclined". + * @default 0.49 + * @minimum -0.5 + * @maximum 0.5 + * @step 0.01 + */ + inclination: number; + /** + * Defines the solar azimuth in interval [0, 1]. The azimuth is the angle in the horizontal plan between + * an object direction and a reference direction. + * @default 0.25 + * @minimum 0 + * @maximum 1 + * @step 0.01 + */ + azimuth: number; + /** + * Defines the sun position in the sky on (x,y,z). If the property .useSunPosition is set to false, then + * the property is overridden by the inclination and the azimuth and can be read at any moment. + * @default undefined + * @optional true + */ + sunPosition: Base.Vector3; + /** + * Defines if the sun position should be computed (inclination and azimuth) according to the given + * .sunPosition property. + * @default false + */ + useSunPosition: boolean; + /** + * Defines an offset vector used to get a horizon offset. + * @example skyMaterial.cameraOffset.y = camera.globalPosition.y // Set horizon relative to 0 on the Y axis + * @default undefined + * @optional true + */ + cameraOffset: Base.Vector3; + /** + * Defines the vector the skyMaterial should consider as up. (default is Vector3(0, 1, 0) as returned by Vector3.Up()) + * @default [0, 1, 0] + */ + up: number[]; + /** + * Defines if sky should be dithered. + * @default false + */ + dithering: boolean; + } + class LuminanceDto { + constructor(material?: MATERIALS.SkyMaterial, luminance?: number); + /** + * Material to update + * @default undefined + */ + material: MATERIALS.SkyMaterial; + /** + * Defines the overall luminance of sky in interval ]0, 1[. + * @default 1 + * @minimum 0 + * @maximum 1 + * @step 0.01 + */ + luminance?: number; + } + class TurbidityDto { + constructor(material?: MATERIALS.SkyMaterial, turbidity?: number); + /** + * Material to update + * @default undefined + */ + material: MATERIALS.SkyMaterial; + /** + * Defines the amount (scattering) of haze as opposed to molecules in atmosphere. + * @default 10 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + turbidity?: number; + } + class RayleighDto { + constructor(material?: MATERIALS.SkyMaterial, rayleigh?: number); + /** + * Material to update + * @default undefined + */ + material: MATERIALS.SkyMaterial; + /** + * Defines the sky appearance (light intensity). + * @default 2 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + rayleigh?: number; + } + class MieCoefficientDto { + constructor(material?: MATERIALS.SkyMaterial, mieCoefficient?: number); + /** + * Material to update + * @default undefined + */ + material: MATERIALS.SkyMaterial; + /** + * Defines the mieCoefficient in interval [0, 0.1] which affects the property .mieDirectionalG. + * @default 0.005 + * @minimum 0 + * @maximum Infinity + * @step 0.001 + */ + mieCoefficient?: number; + } + class MieDirectionalGDto { + constructor(material?: MATERIALS.SkyMaterial, mieDirectionalG?: number); + /** + * Material to update + * @default undefined + */ + material: MATERIALS.SkyMaterial; + /** + * Defines the amount of haze particles following the Mie scattering theory. + * @default 0.8 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + mieDirectionalG?: number; + } + class DistanceDto { + constructor(material?: MATERIALS.SkyMaterial, distance?: number); + /** + * Material to update + * @default undefined + */ + material: MATERIALS.SkyMaterial; + /** + * Defines the distance of the sun according to the active scene camera. + * @default 500 + * @minimum 0 + * @maximum Infinity + * @step 10 + */ + distance?: number; + } + class InclinationDto { + constructor(material?: MATERIALS.SkyMaterial, inclination?: number); + /** + * Material to update + * @default undefined + */ + material: MATERIALS.SkyMaterial; + /** + * Defines the sun inclination, in interval [-0.5, 0.5]. When the inclination is not 0, the sun is said + * "inclined". + * @default 0.49 + * @minimum -0.5 + * @maximum 0.5 + * @step 0.01 + */ + inclination?: number; + } + class AzimuthDto { + constructor(material?: MATERIALS.SkyMaterial, azimuth?: number); + /** + * Material to update + * @default undefined + */ + material: MATERIALS.SkyMaterial; + /** + * Defines the solar azimuth in interval [0, 1]. The azimuth is the angle in the horizontal plan between + * an object direction and a reference direction. + * @default 0.25 + * @minimum 0 + * @maximum 1 + * @step 0.01 + */ + azimuth?: number; + } + class SunPositionDto { + constructor( + material?: MATERIALS.SkyMaterial, + sunPosition?: Base.Vector3 + ); + /** + * Material to update + * @default undefined + */ + material: MATERIALS.SkyMaterial; + /** + * Defines the sun position in the sky on (x,y,z). If the property .useSunPosition is set to false, then + * the property is overridden by the inclination and the azimuth and can be read at any moment. + * @default undefined + */ + sunPosition?: Base.Vector3; + } + class UseSunPositionDto { + constructor(material?: MATERIALS.SkyMaterial, useSunPosition?: boolean); + /** + * Material to update + * @default undefined + */ + material: MATERIALS.SkyMaterial; + /** + * Defines if the sun position should be computed (inclination and azimuth) according to the given + * .sunPosition property. + * @default false + */ + useSunPosition?: boolean; + } + class CameraOffsetDto { + constructor( + material?: MATERIALS.SkyMaterial, + cameraOffset?: Base.Vector3 + ); + /** + * Material to update + * @default undefined + */ + material: MATERIALS.SkyMaterial; + /** + * Defines an offset vector used to get a horizon offset. + * @example skyMaterial.cameraOffset.y = camera.globalPosition.y // Set horizon relative to 0 on the Y axis + * @default undefined + */ + cameraOffset?: Base.Vector3; + } + class UpDto { + constructor(material?: MATERIALS.SkyMaterial, up?: Base.Vector3); + /** + * Material to update + * @default undefined + */ + material: MATERIALS.SkyMaterial; + /** + * Defines the vector the skyMaterial should consider as up. (default is Vector3(0, 1, 0) as returned by Vector3.Up()) + * @default undefined + */ + up?: Base.Vector3; + } + class DitheringDto { + constructor(material?: MATERIALS.SkyMaterial, dithering?: boolean); + /** + * Material to update + * @default undefined + */ + material: MATERIALS.SkyMaterial; + /** + * Defines if sky should be dithered. + * @default false + */ + dithering?: boolean; + } + } + declare namespace BabylonMeshBuilder { + class CreateBoxDto { + constructor( + width?: number, + depth?: number, + height?: number, + sideOrientation?: BabylonMesh.sideOrientationEnum, + enableShadows?: boolean + ); + /** + * Width of the box + * @default 1 + */ + width: number; + /** + * Depth of the box + * @default 1 + */ + depth: number; + /** + * Height of the box + * @default 1 + */ + height: number; + /** + * Side orientation of the mesh + * @default frontside + */ + sideOrientation: BabylonMesh.sideOrientationEnum; + /** + * Enables shadows for the mesh + * @default true + */ + enableShadows: boolean; + } + class CreateCubeDto { + constructor( + size?: number, + sideOrientation?: BabylonMesh.sideOrientationEnum, + enableShadows?: boolean + ); + /** + * Size of the cube + * @default 1 + */ + size: number; + /** + * Side orientation of the mesh + * @default frontside + */ + sideOrientation: BabylonMesh.sideOrientationEnum; + /** + * Enables shadows for the mesh + * @default true + */ + enableShadows: boolean; + } + class CreateSquarePlaneDto { + constructor( + size?: number, + sideOrientation?: BabylonMesh.sideOrientationEnum, + enableShadows?: boolean + ); + /** + * Size of the square plane + * @default 1 + */ + size: number; + /** + * Side orientation of the mesh + * @default frontside + */ + sideOrientation: BabylonMesh.sideOrientationEnum; + /** + * Enables shadows for the mesh + * @default true + */ + enableShadows: boolean; + } + class CreateSphereDto { + constructor( + diameter?: number, + segments?: number, + sideOrientation?: BabylonMesh.sideOrientationEnum, + enableShadows?: boolean + ); + /** + * Diameter of the sphere + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + diameter: number; + /** + * Segments of the sphere + * @default 32 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + segments: number; + /** + * Side orientation of the mesh + * @default frontside + */ + sideOrientation: BabylonMesh.sideOrientationEnum; + /** + * Enables shadows for the mesh + * @default true + */ + enableShadows: boolean; + } + class CreateIcoSphereDto { + constructor( + radius?: number, + radiusX?: number, + radiusY?: number, + radiusZ?: number, + flat?: boolean, + subdivisions?: number, + sideOrientation?: BabylonMesh.sideOrientationEnum, + enableShadows?: boolean + ); + /** + * Radius of the ico sphere + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + radius: number; + /** + * Radius X of the ico sphere + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + radiusX: number; + /** + * Radius Y of the ico sphere + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + radiusY: number; + /** + * Radius Z of the ico sphere + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + radiusZ: number; + /** + * Flat of the ico sphere + * @default false + */ + flat: boolean; + /** + * Subdivisions of the ico sphere + * @default 4 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + subdivisions: number; + /** + * Side orientation of the mesh + * @default frontside + */ + sideOrientation: BabylonMesh.sideOrientationEnum; + /** + * Enables shadows for the mesh + * @default true + */ + enableShadows: boolean; + } + class CreateDiscDto { + constructor( + radius?: number, + tessellation?: number, + sideOrientation?: BabylonMesh.sideOrientationEnum, + enableShadows?: boolean + ); + /** + * Radius of the disc + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + radius: number; + /** + * Tessellation of the disc + * @default 32 + * @minimum 3 + * @maximum Infinity + * @step 1 + */ + tessellation: number; + /** + * Arc between 0 and 1 + * @default 1 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + arc: number; + /** + * Side orientation of the mesh + * @default frontside + */ + sideOrientation: BabylonMesh.sideOrientationEnum; + /** + * Enables shadows for the mesh + * @default true + */ + enableShadows: boolean; + } + class CreateRibbonDto { + constructor( + pathArray?: Base.Vector3[][], + closeArray?: boolean, + closePath?: boolean, + offset?: number, + updatable?: boolean, + sideOrientation?: BabylonMesh.sideOrientationEnum, + enableShadows?: boolean + ); + /** + * Path array of the ribbon + */ + pathArray: Base.Vector3[][]; + /** + * Close array of the ribbon + * @default false + */ + closeArray: boolean; + /** + * Close path of the ribbon + * @default false + */ + closePath: boolean; + /** + * Offset of the ribbon + * @default 0 + */ + offset: number; + /** + * Updateable + * @default false + */ + updatable: boolean; + /** + * Side orientation of the mesh + * @default frontside + */ + sideOrientation: BabylonMesh.sideOrientationEnum; + /** + * Enables shadows for the mesh + * @default true + */ + enableShadows: boolean; + } + class CreateTorusDto { + constructor( + diameter?: number, + thickness?: number, + tessellation?: number, + sideOrientation?: BabylonMesh.sideOrientationEnum, + enableShadows?: boolean + ); + /** + * Diameter of the torus + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + diameter: number; + /** + * Thickness of the torus + * @default 0.5 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + thickness: number; + /** + * Tessellation of the torus + * @default 32 + * @minimum 3 + * @maximum Infinity + * @step 1 + */ + tessellation: number; + /** + * Side orientation of the mesh + * @default frontside + */ + sideOrientation: BabylonMesh.sideOrientationEnum; + /** + * Enables shadows for the mesh + * @default true + */ + enableShadows: boolean; + } + class CreateTorusKnotDto { + constructor( + radius?: number, + tube?: number, + radialSegments?: number, + tubularSegments?: number, + p?: number, + q?: number, + sideOrientation?: BabylonMesh.sideOrientationEnum, + enableShadows?: boolean + ); + /** + * Radius of the torus knot + * @default 2 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + radius: number; + /** + * Tube of the torus knot + * @default 0.5 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + tube: number; + /** + * Radial segments of the torus knot + * @default 128 + * @minimum 3 + * @maximum Infinity + * @step 1 + */ + radialSegments: number; + /** + * Tubular segments of the torus knot + * @default 32 + * @minimum 3 + * @maximum Infinity + * @step 1 + */ + tubularSegments: number; + /** + * P of the torus knot + * @default 2 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + p: number; + /** + * Q of the torus knot + * @default 3 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + q: number; + /** + * Side orientation of the mesh + * @default frontside + */ + sideOrientation: BabylonMesh.sideOrientationEnum; + /** + * Enables shadows for the mesh + * @default true + */ + enableShadows: boolean; + } + class CreatePolygonDto { + constructor( + shape?: Base.Vector3[], + holes?: Base.Vector3[][], + depth?: number, + smoothingThreshold?: number, + sideOrientation?: BabylonMesh.sideOrientationEnum, + wrap?: boolean, + enableShadows?: boolean + ); + /** + * Shape of the polygon + */ + shape: Base.Vector3[]; + /** + * Holes of the polygon + * @optional true + */ + holes?: Base.Vector3[][]; + /** + * Depth of the polygon + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + depth: number; + /** + * Smoothing threshold of the polygon + * @default 0.01 + * @minimum 0 + * @maximum 1 + * @step 0.01 + */ + smoothingThreshold: number; + /** + * Side orientation of the mesh + * @default frontside + */ + sideOrientation: BabylonMesh.sideOrientationEnum; + /** + * Wrap of the polygon + * @default false + */ + wrap: boolean; + /** + * Enables shadows for the mesh + * @default true + */ + enableShadows: boolean; + } + class ExtrudePolygonDto { + constructor( + shape?: Base.Vector3[], + holes?: Base.Vector3[][], + depth?: number, + sideOrientation?: BabylonMesh.sideOrientationEnum, + wrap?: boolean, + enableShadows?: boolean + ); + /** + * Shape of the extrude + */ + shape: Base.Vector3[]; + /** + * Holes of the extrude + * @optional true + */ + holes?: Base.Vector3[][]; + /** + * Depth of the extrude + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + depth: number; + /** + * Side orientation of the mesh + * @default frontside + */ + sideOrientation: BabylonMesh.sideOrientationEnum; + /** + * Wrap of the extrude + * @default false + */ + wrap: boolean; + /** + * Enables shadows for the mesh + * @default true + */ + enableShadows: boolean; + } + class CreatePolyhedronDto { + constructor( + size?: number, + type?: number, + sizeX?: number, + sizeY?: number, + sizeZ?: number, + custom?: number[], + flat?: boolean, + sideOrientation?: BabylonMesh.sideOrientationEnum, + enableShadows?: boolean + ); + /** + * Size of the polyhedron + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + size: number; + /** + * Type of the polyhedron + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + type: number; + /** + * Size X of the polyhedron + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + sizeX: number; + /** + * Size Y of the polyhedron + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + sizeY: number; + /** + * Size Z of the polyhedron + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + sizeZ: number; + /** + * Custom polyhedron + * @optional true + */ + custom?: number[]; + /** + * Flat polyhedron + * @default false + */ + flat: boolean; + /** + * Side orientation of the mesh + * @default frontside + */ + sideOrientation: BabylonMesh.sideOrientationEnum; + /** + * Enables shadows for the mesh + * @default true + */ + enableShadows: boolean; + } + class CreateGeodesicDto { + constructor( + m?: number, + n?: number, + size?: number, + sizeX?: number, + sizeY?: number, + sizeZ?: number, + flat?: boolean, + subdivisions?: number, + sideOrientation?: BabylonMesh.sideOrientationEnum, + enableShadows?: boolean + ); + /** + * M of the geodesic + * @default 4 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + m: number; + /** + * N of the geodesic + * @default 4 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + n: number; + /** + * Size of the geodesic + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + size: number; + /** + * Size X of the geodesic + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + sizeX: number; + /** + * Size Y of the geodesic + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + sizeY: number; + /** + * Size Z of the geodesic + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + sizeZ: number; + /** + * Flat + * @default false + */ + flat: boolean; + /** + * Subdivisions of the geodesic + * @default 4 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + subdivisions: number; + /** + * Side orientation of the mesh + * @default frontside + */ + sideOrientation: BabylonMesh.sideOrientationEnum; + /** + * Enables shadows for the mesh + * @default true + */ + enableShadows: boolean; + } + class CreateCapsuleDto { + constructor( + orientation?: Base.Vector3, + subdivisions?: number, + tessellation?: number, + height?: number, + radius?: number, + capSubdivisions?: number, + radiusTop?: number, + radiusBottom?: number, + topCapSubdivisions?: number, + bottomCapSubdivisions?: number, + sideOrientation?: BabylonMesh.sideOrientationEnum, + enableShadows?: boolean + ); + /** + * Orientation of the capsule + */ + orientation: Base.Vector3; + /** + * Subdivisions of the capsule + * @default 2 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + subdivisions: number; + /** + * Tessellation of the capsule + * @default 16 + * @minimum 3 + * @maximum Infinity + * @step 1 + */ + tessellation: number; + /** + * Height of the capsule + * @default 2 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + height: number; + /** + * Radius of the capsule + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + radius: number; + /** + * Cap subdivisions of the capsule + * @default 6 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + capSubdivisions: number; + /** + * Radius top of the capsule + * @default 0.5 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + radiusTop: number; + /** + * Radius bottom of the capsule + * @default 0.5 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + radiusBottom: number; + /** + * Top cap subdivisions of the capsule + * @default 6 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + topCapSubdivisions: number; + /** + * Bottom cap subdivisions of the capsule + * @default 6 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + bottomCapSubdivisions: number; + /** + * Side orientation of the mesh + * @default doubleside + */ + sideOrientation: BabylonMesh.sideOrientationEnum; + /** + * Enables shadows for the mesh + * @default true + */ + enableShadows: boolean; + } + class CreateGoldbergDto { + constructor( + m?: number, + n?: number, + size?: number, + sizeX?: number, + sizeY?: number, + sizeZ?: number, + sideOrientation?: BabylonMesh.sideOrientationEnum, + enableShadows?: boolean + ); + /** + * M of the goldberg + * @default 4 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + m: number; + /** + * N of the goldberg + * @default 4 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + n: number; + /** + * Size of the goldberg + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + size: number; + /** + * Size X of the goldberg + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + sizeX: number; + /** + * Size Y of the goldberg + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + sizeY: number; + /** + * Size Z of the goldberg + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + sizeZ: number; + /** + * Side orientation of the mesh + * @default doubleside + */ + sideOrientation: BabylonMesh.sideOrientationEnum; + /** + * Enables shadows for the mesh + * @default true + */ + enableShadows: boolean; + } + class CreateTubeDto { + constructor( + path?: Base.Vector3[], + radius?: number, + tessellation?: number, + cap?: number, + arc?: number, + sideOrientation?: BabylonMesh.sideOrientationEnum, + enableShadows?: boolean + ); + /** + * Path of the tube + * @default undefined + */ + path: Base.Vector3[]; + /** + * Radius of the tube + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + radius: number; + /** + * Tessellation of the tube + * @default 32 + * @minimum 3 + * @maximum Infinity + * @step 1 + */ + tessellation: number; + /** + * Cap of the tube + * @default 0 + * @minimum 0 + * @maximum 3 + * @step 1 + */ + cap: number; + /** + * Arc of the tube + * @default 1 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + arc: number; + /** + * Side orientation of the mesh + * @default doubleside + */ + sideOrientation: BabylonMesh.sideOrientationEnum; + /** + * Enables shadows for the mesh + * @default true + */ + enableShadows: boolean; + } + class CreateExtrudedShapeDto { + constructor( + shape?: Base.Vector3[], + path?: Base.Vector3[], + scale?: number, + rotation?: number, + cap?: number, + sideOrientation?: BabylonMesh.sideOrientationEnum, + enableShadows?: boolean + ); + /** + * Shape of the extrude + */ + shape: Base.Vector3[]; + /** + * Path of the extrude + */ + path: Base.Vector3[]; + /** + * Scale of the extrude + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + scale: number; + /** + * Rotation of the extrude + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + rotation: number; + /** + * Close shape of the extrude + * @default false + */ + closeShape: boolean; + /** + * Close path of the extrude + * @default false + */ + closePath: boolean; + /** + * Cap of the extrude + * @default 0 + * @minimum 0 + * @maximum 3 + * @step 1 + */ + cap: number; + /** + * Side orientation of the mesh + * @default doubleside + */ + sideOrientation: BabylonMesh.sideOrientationEnum; + /** + * Enables shadows for the mesh + * @default true + */ + enableShadows: boolean; + } + class CreateCylinderDto { + constructor( + height?: number, + diameterTop?: number, + diameterBottom?: number, + tessellation?: number, + subdivisions?: number, + sideOrientation?: BabylonMesh.sideOrientationEnum, + enableShadows?: boolean + ); + /** + * Height of the cylinder + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + height: number; + /** + * Diameter top of the cylinder + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + diameterTop: number; + /** + * Diameter bottom of the cylinder + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + diameterBottom: number; + /** + * Tessellation of the cylinder + * @default 64 + * @minimum 3 + * @maximum Infinity + * @step 1 + */ + tessellation: number; + /** + * Subdivisions of the cylinder + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + subdivisions: number; + /** + * Side orientation of the mesh + * @default doubleside + */ + sideOrientation: BabylonMesh.sideOrientationEnum; + /** + * Enables shadows for the mesh + * @default true + */ + enableShadows: boolean; + } + class CreateLatheDto { + constructor( + shape?: Base.Vector3[], + radius?: number, + tessellation?: number, + arc?: number, + closed?: boolean, + sideOrientation?: BabylonMesh.sideOrientationEnum, + enableShadows?: boolean + ); + /** + * Shape of the lathe + */ + shape: Base.Vector3[]; + /** + * Radius of the lathe + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + radius: number; + /** + * Tessellation of the lathe + * @default 64 + * @minimum 3 + * @maximum Infinity + * @step 1 + */ + tessellation: number; + /** + * Arc of the lathe + * @default 1 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + arc: number; + /** + * Should lathe be closed + * @default true + */ + closed: boolean; + /** + * Side orientation of the mesh + * @default doubleside + */ + sideOrientation: BabylonMesh.sideOrientationEnum; + /** + * Enables shadows for the mesh + * @default true + */ + enableShadows: boolean; + } + class CreateGroundDto { + constructor( + width?: number, + height?: number, + subdivisionsX?: number, + subdivisionsY?: number, + sideOrientation?: BabylonMesh.sideOrientationEnum, + enableShadows?: boolean + ); + /** + * Width of the ground + * @default 10 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + width: number; + /** + * Height of the ground + * @default 10 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + height: number; + /** + * Subdivisions X of the ground + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + subdivisionsX: number; + /** + * Subdivisions Y of the ground + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + subdivisionsY: number; + /** + * Side orientation of the mesh + * @default doubleside + */ + sideOrientation: BabylonMesh.sideOrientationEnum; + /** + * Enables shadows for the mesh + * @default true + */ + enableShadows: boolean; + } + class CreateRectanglePlaneDto { + constructor( + width?: number, + height?: number, + sideOrientation?: BabylonMesh.sideOrientationEnum, + enableShadows?: boolean + ); + /** + * Width of the rectangle plane + * @default 1 + */ + width: number; + /** + * Height of the rectangle plane + * @default 1 + */ + height: number; + /** + * Side orientation of the mesh + * @default doubleside + */ + sideOrientation: BabylonMesh.sideOrientationEnum; + /** + * Enables shadows for the mesh + * @default true + */ + enableShadows: boolean; + } + } + declare namespace BabylonMesh { + enum sideOrientationEnum { + frontside = "frontside", + backside = "backside", + doubleside = "doubleside", + } + class UpdateDrawnBabylonMesh { + constructor( + babylonMesh?: BABYLON.Mesh, + position?: Base.Point3, + rotation?: Base.Vector3, + scaling?: Base.Vector3, + colours?: string | string[] + ); + /** + * Babylon Mesh that needs to be updated + * @default undefined + */ + babylonMesh: BABYLON.Mesh; + /** + * Position to place the mesh into + * @default undefined + */ + position: Base.Point3; + /** + * Rotation for the mesh + * @default undefined + */ + rotation: Base.Vector3; + /** + * Scale mesh to certain value + * @default undefined + */ + scaling: Base.Vector3; + /** + * Colours or a single colour to change + * @default undefined + */ + colours: string | string[]; + } + class SetParentDto { + constructor( + babylonMesh?: + | BABYLON.Mesh + | BABYLON.InstancedMesh + | BABYLON.AbstractMesh, + parentMesh?: + | BABYLON.Mesh + | BABYLON.InstancedMesh + | BABYLON.AbstractMesh + ); + /** + * BabylonJS Mesh that needs to change it's parent + * @default undefined + */ + babylonMesh: + | BABYLON.Mesh + | BABYLON.InstancedMesh + | BABYLON.AbstractMesh; + /** + * BabylonJS Mesh to use as a parent + * @default undefined + */ + parentMesh: BABYLON.Mesh | BABYLON.InstancedMesh | BABYLON.AbstractMesh; + } + class UpdateDrawnBabylonMeshPositionDto { + constructor( + babylonMesh?: BABYLON.Mesh | BABYLON.InstancedMesh, + position?: Base.Point3 + ); + /** + * Babylon Mesh that needs to be updated + * @default undefined + */ + babylonMesh: BABYLON.Mesh | BABYLON.InstancedMesh; + /** + * Position to place the mesh into + * @default undefined + */ + position: Base.Point3; + } + class UpdateDrawnBabylonMeshRotationDto { + constructor( + babylonMesh?: BABYLON.Mesh | BABYLON.InstancedMesh, + rotation?: Base.Vector3 + ); + /** + * Babylon Mesh that needs to be updated + * @default undefined + */ + babylonMesh: BABYLON.Mesh | BABYLON.InstancedMesh; + /** + * Rotation for the mesh + * @default undefined + */ + rotation: Base.Vector3; + } + class UpdateDrawnBabylonMeshScaleDto { + constructor( + babylonMesh?: BABYLON.Mesh | BABYLON.InstancedMesh, + scale?: Base.Vector3 + ); + /** + * Babylon Mesh that needs to be updated + * @default undefined + */ + babylonMesh: BABYLON.Mesh | BABYLON.InstancedMesh; + /** + * Scale for the mesh + * @default undefined + */ + scale: Base.Vector3; + } + class ScaleInPlaceDto { + constructor( + babylonMesh?: BABYLON.Mesh | BABYLON.InstancedMesh, + scale?: number + ); + /** + * Babylon Mesh that needs to be updated + * @default undefined + */ + babylonMesh: BABYLON.Mesh | BABYLON.InstancedMesh; + /** + * factor for the scale + * @default 1 + */ + scale: number; + } + class IntersectsMeshDto { + constructor( + babylonMesh?: BABYLON.Mesh | BABYLON.InstancedMesh, + babylonMesh2?: BABYLON.Mesh | BABYLON.InstancedMesh, + precise?: boolean, + includeDescendants?: boolean + ); + /** + * Babylon Mesh that needs to be updated + * @default undefined + */ + babylonMesh: BABYLON.Mesh | BABYLON.InstancedMesh; + /** + * Babylon Mesh that needs to be updated + * @default undefined + */ + babylonMesh2: BABYLON.Mesh | BABYLON.InstancedMesh; + /** + * Should check precisely + * @default false + */ + precise: boolean; + /** + * Check descendant intersections as well + * @default false + */ + includeDescendants: boolean; + } + class IntersectsPointDto { + constructor( + babylonMesh?: BABYLON.Mesh | BABYLON.InstancedMesh, + point?: Base.Point3 + ); + /** + * Babylon Mesh that needs to be updated + * @default undefined + */ + babylonMesh: BABYLON.Mesh | BABYLON.InstancedMesh; + /** + * point + * @default undefined + */ + point: Base.Point3; + } + class BabylonMeshDto { + constructor(babylonMesh?: BABYLON.Mesh); + /** + * BabylonJS mesh + * @default undefined + */ + babylonMesh: BABYLON.Mesh; + } + class CloneToPositionsDto { + constructor(babylonMesh?: BABYLON.Mesh, positions?: Base.Point3[]); + /** + * BabylonJS mesh + * @default undefined + */ + babylonMesh: BABYLON.Mesh; + /** + * positions to clone to + * @default [] + */ + positions: Base.Point3[]; + } + class MergeMeshesDto { + constructor( + arrayOfMeshes?: BABYLON.Mesh[], + disposeSource?: boolean, + allow32BitsIndices?: boolean, + meshSubclass?: BABYLON.Mesh, + subdivideWithSubMeshes?: boolean, + multiMultiMaterials?: boolean + ); + /** + * meshes array of meshes with the vertices to merge. Entries cannot be empty meshes. + * @default undefined + */ + arrayOfMeshes: BABYLON.Mesh[]; + /** + * disposeSource when true (default), dispose of the vertices from the source meshes. + * @default true + */ + disposeSource: boolean; + /** + * allow32BitsIndices when the sum of the vertices > 64k, this must be set to true. + * @default false + */ + allow32BitsIndices: boolean; + /** + * meshSubclass (optional) can be set to a Mesh where the merged vertices will be inserted. + * @default undefined + * @optional true + */ + meshSubclass?: BABYLON.Mesh; + /** + * subdivideWithSubMeshes when true (false default), subdivide mesh into subMeshes. + * @default false + */ + subdivideWithSubMeshes: boolean; + /** + * multiMultiMaterials when true (false default), subdivide mesh into subMeshes with multiple materials, ignores subdivideWithSubMeshes. + * @default false + */ + multiMultiMaterials: boolean; + } + class BabylonMeshWithChildrenDto { + constructor(babylonMesh?: BABYLON.Mesh); + /** + * BabylonJS mesh + * @default undefined + */ + babylonMesh: BABYLON.Mesh; + /** + * Include children when performing action + * @default true + */ + includeChildren: boolean; + } + class ShowHideMeshDto { + constructor(babylonMesh?: BABYLON.Mesh, includeChildren?: boolean); + /** + * BabylonJS mesh + * @default undefined + */ + babylonMesh: BABYLON.Mesh; + /** + * Include children when showing hiding + * @default true + */ + includeChildren: boolean; + } + class CloneBabylonMeshDto { + constructor(babylonMesh?: BABYLON.Mesh); + /** + * BabylonJS mesh + * @default undefined + */ + babylonMesh: BABYLON.Mesh; + } + class ChildMeshesBabylonMeshDto { + constructor( + babylonMesh?: BABYLON.Mesh, + directDescendantsOnly?: boolean + ); + /** + * BabylonJS mesh + * @default undefined + */ + babylonMesh: BABYLON.Mesh; + /** + * Include only direct descendants + * @default false + */ + directDescendantsOnly: boolean; + } + class TranslateBabylonMeshDto { + constructor(babylonMesh?: BABYLON.Mesh, distance?: number); + /** + * BabylonJS mesh + * @default undefined + */ + babylonMesh: BABYLON.Mesh; + /** + * distance to translate + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 1 + */ + distance: number; + } + class NameBabylonMeshDto { + constructor( + babylonMesh?: BABYLON.Mesh, + name?: string, + includeChildren?: boolean + ); + /** + * BabylonJS mesh + * @default undefined + * + */ + babylonMesh?: BABYLON.Mesh; + /** + * name of the mesh + * @default undefined + */ + name: string; + /** + * Set name also on children + * @default false + */ + includeChildren?: boolean; + } + class ByNameBabylonMeshDto { + constructor(name?: string); + /** + * name of the mesh + * @default undefined + */ + name: string; + } + class MaterialBabylonMeshDto { + constructor( + babylonMesh?: BABYLON.Mesh, + material?: BABYLON.Material, + includeChildren?: boolean + ); + /** + * BabylonJS mesh + * @default undefined + */ + babylonMesh?: BABYLON.Mesh; + /** + * material of the mesh + * @default undefined + */ + material: BABYLON.Material; + /** + * Set material on children also + * @default false + */ + includeChildren: boolean; + } + class IdBabylonMeshDto { + constructor(babylonMesh?: BABYLON.Mesh, id?: string); + /** + * BabylonJS mesh + * @default undefined + */ + babylonMesh?: BABYLON.Mesh; + /** + * id of the mesh + * @default undefined + */ + id: string; + } + class ByIdBabylonMeshDto { + constructor(id?: string); + /** + * id of the mesh + * @default undefined + */ + id: string; + } + class UniqueIdBabylonMeshDto { + constructor(uniqueId?: number); + /** + * Unique id of the mesh + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 1 + */ + uniqueId: number; + } + class PickableBabylonMeshDto { + constructor( + babylonMesh?: BABYLON.Mesh, + pickable?: boolean, + includeChildren?: boolean + ); + /** + * BabylonJS mesh + * @default undefined + */ + babylonMesh: BABYLON.Mesh; + /** + * Pickable + * @default false + */ + pickable: boolean; + /** + * Apply set to children also + * @default false + */ + includeChildren: boolean; + } + class CheckCollisionsBabylonMeshDto { + constructor( + babylonMesh?: BABYLON.Mesh, + checkCollisions?: boolean, + includeChildren?: boolean + ); + /** + * BabylonJS mesh + * @default undefined + */ + babylonMesh: BABYLON.Mesh; + /** + * Check collisions + * @default false + */ + checkCollisions: boolean; + /** + * Apply set to children also + * @default false + */ + includeChildren: boolean; + } + class RotateBabylonMeshDto { + constructor(babylonMesh?: BABYLON.Mesh, rotate?: number); + /** + * BabylonJS mesh + * @default undefined + */ + babylonMesh: BABYLON.Mesh; + /** + * rotate to translate + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 1 + */ + rotate: number; + } + class SetMeshVisibilityDto { + constructor( + babylonMesh?: BABYLON.Mesh, + visibility?: number, + includeChildren?: boolean + ); + /** + * BabylonJS mesh + * @default undefined + */ + babylonMesh: BABYLON.Mesh; + /** + * Shows mesh if 0 and shows if 1 + * @default 0 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + visibility: number; + /** + * Include children + * @default false + */ + includeChildren: boolean; + } + class MeshInstanceAndTransformDto { + constructor( + mesh?: BABYLON.Mesh, + position?: Base.Point3, + rotation?: Base.Vector3, + scaling?: Base.Vector3 + ); + /** + * BabylonJS mesh + * @default undefined + */ + mesh: BABYLON.Mesh; + /** + * Position + * @default undefined + */ + position: Base.Point3; + /** + * Rotation + * @default undefined + */ + rotation: Base.Vector3; + /** + * Scaling + * @default undefined + */ + scaling: Base.Vector3; + } + class MeshInstanceDto { + constructor(mesh?: BABYLON.Mesh); + /** + * BabylonJS mesh + * @default undefined + */ + mesh: BABYLON.Mesh; + } + class RotateAroundAxisNodeDto { + constructor( + mesh?: BABYLON.Mesh, + position?: Base.Point3, + axis?: Base.Vector3, + angle?: number + ); + /** + * BabylonJS mesh + * @default undefined + */ + mesh: BABYLON.Mesh; + /** + * Position vector expressed in [x, y, z] vector array + */ + position: Base.Point3; + /** + * Rotate around the axis expressed in [x, y, z] vector array + */ + axis: Base.Vector3; + /** + * The rotation angle expressed in degrees + */ + angle: number; + } + } + declare namespace BabylonPick { + class RayDto { + constructor(ray?: BABYLON.Ray); + /** + * Ray + */ + ray: BABYLON.Ray; + } + class PickInfo { + constructor(pickInfo?: BABYLON.PickingInfo); + /** + * Information about picking result + */ + pickInfo: BABYLON.PickingInfo; + } + } + declare namespace BabylonRay { + class BaseRayDto { + constructor( + origin?: Base.Point3, + direction?: Base.Vector3, + length?: number + ); + /** + * Origin of the ray + */ + origin: Base.Point3; + /** + * Direction of the ray + */ + direction: Base.Vector3; + /** + * Length of the ray + */ + length?: number; + } + class RayDto { + constructor(ray?: BABYLON.Ray); + /** + * ray to analyze + */ + ray: BABYLON.Ray; + } + class FromToDto { + constructor(from?: Base.Point3, to?: Base.Point3); + /** + * From point + */ + from: Base.Point3; + /** + * To point + */ + to: Base.Point3; + } + } + declare namespace BabylonTexture { + enum samplingModeEnum { + nearest = "nearest", + bilinear = "bilinear", + trilinear = "trilinear", + } + class TextureSimpleDto { + constructor( + name?: string, + url?: string, + invertY?: boolean, + invertZ?: boolean, + wAng?: number, + uScale?: number, + vScale?: number, + uOffset?: number, + vOffset?: number, + samplingMode?: samplingModeEnum + ); + /** + * Name of the material + * @default Custom Texture + */ + name: string; + /** + * Url of the texture + * @default undefined + */ + url: string; + /** + * Invert texture on Y direction + * @default false + */ + invertY: boolean; + /** + * Invert texture on Z direction + * @default false + */ + invertZ: boolean; + /** + * W angle of the texture + * @default 0 + */ + wAng: number; + /** + * U scale of the texture + * @default 1 + */ + uScale: number; + /** + * V scale of the texture + * @default 1 + */ + vScale: number; + /** + * U offset of the texture + * @default 0 + */ + uOffset: number; + /** + * V offset of the texture + * @default 0 + */ + vOffset: number; + /** + * The sampling mode of the texture + * @default nearest + */ + samplingMode: samplingModeEnum; + } + } + declare namespace BabylonTools { + class ScreenshotDto { + constructor( + camera?: BABYLON.Camera, + width?: number, + height?: number, + mimeType?: string, + quality?: number + ); + /** + * Camera to be used. If not set, active camera will be used + * @default undefined + */ + camera: BABYLON.Camera; + /** + * width of the screenshot + * @default 1920 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + width: number; + /** + * height of the screenshot + * @default 1080 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + height: number; + /** + * The mime type + * @default image/png + */ + mimeType: string; + /** + * quality of the screenshot + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + quality: number; + } + } + declare namespace BabylonTransforms { + class RotationCenterAxisDto { + constructor(angle?: number, axis?: Base.Vector3, center?: Base.Point3); + /** + * Angle of rotation in degrees + * @default 90 + * @minimum -Infinity + * @maximum Infinity + * @step 1 + */ + angle: number; + /** + * Axis vector for rotation + * @default [0, 1, 0] + */ + axis: Base.Vector3; + /** + * The center from which the axis is pointing + * @default [0, 0, 0] + */ + center: Base.Point3; + } + class TransformBabylonMeshDto { + constructor( + mesh?: BABYLON.Mesh, + transformation?: Base.TransformMatrixes + ); + /** + * Mesh to transform + * @default undefined + */ + mesh: BABYLON.Mesh; + /** + * Transformation(s) to apply + * @default undefined + */ + transformation: Base.TransformMatrixes; + } + class RotationCenterDto { + constructor(angle?: number, center?: Base.Point3); + /** + * Angle of rotation in degrees + * @default 90 + * @minimum -Infinity + * @maximum Infinity + * @step 1 + */ + angle: number; + /** + * The center from which the axis is pointing + * @default [0, 0, 0] + */ + center: Base.Point3; + } + class RotationCenterYawPitchRollDto { + constructor( + yaw?: number, + pitch?: number, + roll?: number, + center?: Base.Point3 + ); + /** + * Yaw angle (Rotation around X) in degrees + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 1 + */ + yaw: number; + /** + * Pitch angle (Rotation around Y) in degrees + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 1 + */ + pitch: number; + /** + * Roll angle (Rotation around Z) in degrees + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 1 + */ + roll: number; + /** + * The center from which the rotations are applied + * @default [0, 0, 0] + */ + center: Base.Point3; + } + class ScaleXYZDto { + constructor(scaleXyz?: Base.Vector3); + /** + * Scaling factors for each axis [1, 2, 1] means that Y axis will be scaled 200% and both x and z axis will remain on 100% + * @default [1, 1, 1] + */ + scaleXyz: Base.Vector3; + } + class ScaleCenterXYZDto { + constructor(center?: Base.Point3, scaleXyz?: Base.Vector3); + /** + * The center from which the scaling is applied + * @default [0, 0, 0] + */ + center: Base.Point3; + /** + * Scaling factors for each axis [1, 2, 1] means that Y axis will be scaled 200% and both x and z axis will remain on 100% + * @default [1, 1, 1] + */ + scaleXyz: Base.Vector3; + } + class UniformScaleDto { + constructor(scale?: number); + /** + * Uniform scale factor for all x, y, z directions. 1 will keep everything on original size, 2 will scale 200%; + * @default 1 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + scale: number; + } + class UniformScaleFromCenterDto { + constructor(scale?: number, center?: Base.Point3); + /** + * Scale factor for all x, y, z directions. 1 will keep everything on original size, 2 will scale 200%; + * @default 1 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + scale: number; + /** + * Center position of the scaling + * @default [0, 0, 0] + */ + center: Base.Point3; + } + class TranslationXYZDto { + constructor(translation?: Base.Vector3); + /** + * Translation vector with [x, y, z] distances + * @default [0, 0, 0] + */ + translation: Base.Vector3; + } + class TranslationsXYZDto { + constructor(translations?: Base.Vector3[]); + /** + * Translation vectors with [x, y, z] distances + * @default undefined + */ + translations: Base.Vector3[]; + } + } + declare namespace BabylonWebXR { + class WebXRDefaultExperienceOptions { + constructor(disableDefaultUI?: boolean); + /** + * Enable or disable default UI to enter XR + * @optional true + */ + disableDefaultUI?: boolean; + /** + * Should pointer selection not initialize. + * Note that disabling pointer selection also disables teleportation. + * Defaults to false. + * @optional true + */ + disablePointerSelection?: boolean; + /** + * Should teleportation not initialize. Defaults to false. + * @optional true + */ + disableTeleportation?: boolean; + /** + * Should nearInteraction not initialize. Defaults to false. + * @optional true + */ + disableNearInteraction?: boolean; + /** + * Should hand tracking be disabled. Defaults to false. + * @optional true + */ + disableHandTracking?: boolean; + /** + * Floor meshes that will be used for teleport + * @optional true + */ + floorMeshes?: BABYLON.AbstractMesh[]; + /** + * If set to true, the first frame will not be used to reset position + * The first frame is mainly used when copying transformation from the old camera + * Mainly used in AR + * @optional true + */ + ignoreNativeCameraTransformation?: boolean; + /** + * Optional configuration for the XR input object + * @optional true + */ + inputOptions?: Partial; + /** + * optional configuration for pointer selection + * @optional true + */ + pointerSelectionOptions?: Partial; + /** + * optional configuration for near interaction + * @optional true + */ + nearInteractionOptions?: Partial; + /** + * optional configuration for hand tracking + * @optional true + */ + handSupportOptions?: Partial; + /** + * optional configuration for teleportation + * @optional true + */ + teleportationOptions?: Partial; + /** + * optional configuration for the output canvas + * @optional true + */ + outputCanvasOptions?: BABYLON.WebXRManagedOutputCanvasOptions; + /** + * optional UI options. This can be used among other to change session mode and reference space type + * @optional true + */ + uiOptions?: Partial; + /** + * When loading teleportation and pointer select, use stable versions instead of latest. + * @optional true + */ + useStablePlugins?: boolean; + /** + * An optional rendering group id that will be set globally for teleportation, pointer selection and default controller meshes + * @optional true + */ + renderingGroupId?: number; + /** + * A list of optional features to init the session with + * If set to true, all features we support will be added + * @optional true + */ + optionalFeatures?: boolean | string[]; + } + class DefaultWebXRWithTeleportationDto { + constructor(groundMeshes?: BABYLON.Mesh[]); + /** + * Create XR experience with ground meshes + */ + groundMeshes: BABYLON.Mesh[]; + } + class WebXRDefaultExperienceDto { + constructor(webXRDefaultExperience?: BABYLON.WebXRDefaultExperience); + /** + * Web XR default experience + */ + webXRDefaultExperience: BABYLON.WebXRDefaultExperience; + } + class WebXRExperienceHelperDto { + constructor(baseExperience?: BABYLON.WebXRExperienceHelper); + /** + * Base experience + */ + baseExperience: BABYLON.WebXRExperienceHelper; + } + } + declare namespace Base { + /** + * Defines how colors are mapped to entities when there are more entities than colors. + * - firstColorForAll: Uses the first color for all entities (legacy behavior) + * - lastColorRemainder: Maps colors 1:1, then uses last color for remaining entities + * - repeatColors: Cycles through colors in a repeating pattern + * - reversedColors: After exhausting colors, reverses direction (ping-pong pattern) + */ + enum colorMapStrategyEnum { + /** Uses the first color for all entities (legacy behavior) */ + firstColorForAll = "firstColorForAll", + /** Maps colors 1:1, then uses last color for remaining entities */ + lastColorRemainder = "lastColorRemainder", + /** Cycles through colors in a repeating pattern */ + repeatColors = "repeatColors", + /** After exhausting colors, reverses direction (ping-pong pattern) */ + reversedColors = "reversedColors", + } + enum skyboxEnum { + default = "default", + clearSky = "clearSky", + city = "city", + greyGradient = "greyGradient", + } + enum fogModeEnum { + none = "none", + exponential = "exponential", + exponentialSquared = "exponentialSquared", + linear = "linear", + } + enum gradientDirectionEnum { + toTop = "to top", + toTopRight = "to top right", + toRight = "to right", + toBottomRight = "to bottom right", + toBottom = "to bottom", + toBottomLeft = "to bottom left", + toLeft = "to left", + toTopLeft = "to top left", + deg0 = "0deg", + deg45 = "45deg", + deg90 = "90deg", + deg135 = "135deg", + deg180 = "180deg", + deg225 = "225deg", + deg270 = "270deg", + deg315 = "315deg", + } + enum gradientPositionEnum { + center = "center", + top = "top", + topLeft = "top left", + topRight = "top right", + bottom = "bottom", + bottomLeft = "bottom left", + bottomRight = "bottom right", + left = "left", + right = "right", + centerTop = "50% 0%", + centerBottom = "50% 100%", + leftCenter = "0% 50%", + rightCenter = "100% 50%", + } + enum gradientShapeEnum { + circle = "circle", + ellipse = "ellipse", + } + enum backgroundRepeatEnum { + repeat = "repeat", + repeatX = "repeat-x", + repeatY = "repeat-y", + noRepeat = "no-repeat", + space = "space", + round = "round", + } + enum backgroundSizeEnum { + auto = "auto", + cover = "cover", + contain = "contain", + } + enum backgroundAttachmentEnum { + scroll = "scroll", + fixed = "fixed", + local = "local", + } + enum backgroundOriginClipEnum { + paddingBox = "padding-box", + borderBox = "border-box", + contentBox = "content-box", + } + enum verticalAlignmentEnum { + top = "top", + middle = "middle", + bottom = "bottom", + } + enum topBottomEnum { + top = "top", + bottom = "bottom", + } + type Color = string; + type ColorRGB = { + r: number; + g: number; + b: number; + }; + type Material = any; + type Texture = any; + type Point2 = [number, number]; + type Vector2 = [number, number]; + type Point3 = [number, number, number]; + type Vector3 = [number, number, number]; + type Axis3 = { + origin: Base.Point3; + direction: Base.Vector3; + }; + type Axis2 = { + origin: Base.Point2; + direction: Base.Vector2; + }; + type Segment2 = [Point2, Point2]; + type Segment3 = [Point3, Point3]; + type TrianglePlane3 = { + normal: Vector3; + d: number; + }; + type Triangle3 = [Base.Point3, Base.Point3, Base.Point3]; + type Mesh3 = Triangle3[]; + type Plane3 = { + origin: Base.Point3; + normal: Base.Vector3; + direction: Base.Vector3; + }; + type BoundingBox = { + min: Base.Point3; + max: Base.Point3; + center?: Base.Point3; + width?: number; + height?: number; + length?: number; + }; + type Line2 = { + start: Base.Point2; + end: Base.Point2; + }; + type Line3 = { + start: Base.Point3; + end: Base.Point3; + }; + type Polyline3 = { + points: Base.Point3[]; + isClosed?: boolean; + }; + type Polyline2 = { + points: Base.Point2[]; + isClosed?: boolean; + }; + type VerbCurve = { + tessellate: (options: any) => any; + }; + type VerbSurface = { + tessellate: (options: any) => any; + }; + type TransformMatrix3x3 = [ + number, + number, + number, + number, + number, + number, + number, + number, + number + ]; + type TransformMatrixes3x3 = TransformMatrix3x3[]; + type TransformMatrix = [ + number, + number, + number, + number, + number, + number, + number, + number, + number, + number, + number, + number, + number, + number, + number, + number + ]; + type TransformMatrixes = TransformMatrix[]; + } + declare namespace Draw { + type DrawOptions = + | DrawBasicGeometryOptions + | DrawManifoldOrCrossSectionOptions + | DrawOcctShapeOptions + | DrawOcctShapeSimpleOptions + | DrawOcctShapeMaterialOptions + | DrawNodeOptions; + type Entity = + | Base.Point3 + | Base.Vector3 + | Base.Line3 + | Base.Polyline3 + | Base.VerbCurve + | Base.VerbSurface + | Inputs.OCCT.TopoDSShapePointer + | Inputs.Tag.TagDto + | { + type: string; + name?: string; + entityName?: string; + } + | Base.Point3[] + | Base.Vector3[] + | Base.Line3[] + | Base.Polyline3[] + | Base.VerbCurve[] + | Base.VerbSurface[] + | Inputs.OCCT.TopoDSShapePointer[] + | Inputs.Tag.TagDto[] + | { + type: string[]; + name?: string; + entityName?: string; + }; + class DrawAny { + constructor( + entity?: Entity, + options?: DrawOptions, + babylonMesh?: BABYLON.Mesh | BABYLON.LinesMesh + ); + /** + * Entity to be drawn - can be a single or multiple points, lines, polylines, verb curves, verb surfaces, jscad meshes, jscad polygons, jscad paths, occt shapes, tags, nodes + * @default undefined + */ + entity: Entity; + /** + * Options that help you control how your drawn objects look like. This property is optional. In order to pick the right option you need to know which entity you are going to draw. For example if you draw points, lines, polylines or jscad meshes you can use basic geometry options, but if you want to draw OCCT shapes, use OCCT options. + * @default undefined + * @optional true + */ + options?: DrawOptions; + /** + * Entity to be used when updating already drawn mesh in the render loop + * @default undefined + * @optional true + */ + babylonMesh?: BABYLON.Mesh | BABYLON.LinesMesh; + } + class SceneDrawGridMeshDto { + constructor( + width?: number, + height?: number, + subdivisions?: number, + majorUnitFrequency?: number, + minorUnitVisibility?: number, + gridRatio?: number, + opacity?: number, + backFaceCulling?: boolean, + mainColor?: Base.Color, + secondaryColor?: Base.Color + ); + /** + * Width of the grid + * @default 400 + * @minimum 0 + * @maximum Infinity + * @step 10 + */ + width: number; + /** + * Height of the ground + * @default 400 + * @minimum 0 + * @maximum Infinity + * @step 10 + */ + height: number; + /** + * Ground subdivisions + * @default 10 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + subdivisions: number; + /** + * The frequency of thicker lines. + * @default 10 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + majorUnitFrequency: number; + /** + * The visibility of minor units in the grid. + * @default 0.45 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + minorUnitVisibility: number; + /** + * The scale of the grid compared to unit. + * @default 0.5 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + gridRatio: number; + /** + * The grid opacity outside of the lines. + * @default 0.5 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + opacity: number; + /** + * Cull the back faces + * @default false + */ + backFaceCulling: boolean; + /** + * Main color of the grid (e.g. between lines) + * @default #ffffff + */ + mainColor: Base.Color; + /** + * Color of the grid lines. + * @default #ffffff + */ + secondaryColor: Base.Color; + } + /** + * Draw options for basic geometry types like points, lines, polylines, surfaces and jscad meshes + */ + class DrawBasicGeometryOptions { + constructor( + colours?: string | string[], + size?: number, + opacity?: number, + updatable?: boolean, + hidden?: boolean, + drawTwoSided?: boolean, + backFaceColour?: Base.Color, + backFaceOpacity?: number, + colorMapStrategy?: Base.colorMapStrategyEnum, + arrowSize?: number, + arrowAngle?: number + ); + /** + * Basic geometry colours to use for lines, points, polylines, surfaces, jscad meshes. + * @default #ff0000 + */ + colours: string | string[]; + /** + * Strategy for mapping colors to entities when there are more entities than colors. + * - firstColorForAll: Uses the first color for all entities (legacy behavior) + * - lastColorRemainder: Maps colors 1:1, then uses last color for remaining entities + * - repeatColors: Cycles through colors in a repeating pattern + * - reversedColors: After exhausting colors, reverses direction (ping-pong pattern) + * @default lastColorRemainder + */ + colorMapStrategy: Base.colorMapStrategyEnum; + /** + * Size affect how big the drawn points are and how wide lines are. + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + size: number; + /** + * Opacity of the point 0 to 1 + * @default 1 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + opacity: number; + /** + * If geometry needs to be updated later + * @default false + */ + updatable: boolean; + /** + * Hidden + * @default false + */ + hidden: boolean; + /** + * Draw two-sided faces with different colors for front and back. This helps visualize face orientation. Only applies to surfaces. + * @default true + */ + drawTwoSided: boolean; + /** + * Hex colour string for back face colour (negative side of the face). Only used when drawTwoSided is true and drawing surfaces. + * @default #0000ff + */ + backFaceColour: Base.Color; + /** + * Back face opacity value between 0 and 1. Only used when drawTwoSided is true and drawing surfaces. + * @default 1 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + backFaceOpacity: number; + /** + * Size of the arrow head at the end of lines and polylines. Set to 0 to disable arrows. + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 0.01 + */ + arrowSize: number; + /** + * Angle of the arrow head in degrees. Controls how wide the arrow head spreads. + * @default 15 + * @minimum 0 + * @maximum 90 + * @step 1 + */ + arrowAngle: number; + } + /** + * Draw options for Nodes + */ + class DrawNodeOptions { + constructor( + colourX?: Base.Color, + colourY?: Base.Color, + colourZ?: Base.Color, + size?: number + ); + /** + * X Axis colour + * @default #ff0000 + */ + colorX: Base.Color; + /** + * Y Axis colour + * @default #00ff00 + */ + colorY: Base.Color; + /** + * Z Axis colour + * @default #0000ff + */ + colorZ: Base.Color; + /** + * Length of the node axis + * @default 2 + * @minimum 0 + * @maximum Infinity + */ + size: number; + } + class DrawManifoldOrCrossSectionOptions { + /** + * Provide options without default values + */ + constructor( + faceOpacity?: number, + faceMaterial?: Base.Material, + faceColour?: Base.Color, + crossSectionColour?: Base.Color, + crossSectionWidth?: number, + crossSectionOpacity?: number, + computeNormals?: boolean, + drawTwoSided?: boolean, + backFaceColour?: Base.Color, + backFaceOpacity?: number + ); + /** + * Face opacity value between 0 and 1 + * @default 1 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + faceOpacity: number; + /** + * Hex colour string for face colour + * @default #ff0000 + */ + faceColour: Base.Color; + /** + * Face material + * @default undefined + * @optional true + */ + faceMaterial?: Base.Material; + /** + * Hex colour string for cross section drawing + * @default #ff00ff + */ + crossSectionColour: Base.Color; + /** + * Width of cross section lines + * @default 2 + */ + crossSectionWidth: number; + /** + * Cross section opacity value between 0 and 1 + * @default 1 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + crossSectionOpacity: number; + /** + * Compute normals for the shape + * @default false + */ + computeNormals: boolean; + /** + * Whether to draw two-sided geometry with back face rendering + * @default true + */ + drawTwoSided: boolean; + /** + * Hex colour string for the back face when drawing two-sided geometry + * @default #0000ff + */ + backFaceColour: Base.Color; + /** + * Opacity of the back face when drawing two-sided geometry + * @default 1 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + backFaceOpacity: number; + } + /** + * Draw options for OCCT shapes + */ + class DrawOcctShapeOptions { + /** + * Provide options without default values + */ + constructor( + faceOpacity?: number, + edgeOpacity?: number, + edgeColour?: Base.Color, + faceMaterial?: Base.Material, + faceColour?: Base.Color, + edgeWidth?: number, + drawEdges?: boolean, + drawFaces?: boolean, + drawVertices?: boolean, + vertexColour?: Base.Color, + vertexSize?: number, + precision?: number, + drawEdgeIndexes?: boolean, + edgeIndexHeight?: number, + edgeIndexColour?: Base.Color, + drawFaceIndexes?: boolean, + faceIndexHeight?: number, + faceIndexColour?: Base.Color, + drawTwoSided?: boolean, + backFaceColour?: Base.Color, + backFaceOpacity?: number, + edgeArrowSize?: number, + edgeArrowAngle?: number + ); + /** + * Face opacity value between 0 and 1 + * @default 1 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + faceOpacity: number; + /** + * Edge opacity value between 0 and 1 + * @default 1 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + edgeOpacity: number; + /** + * Hex colour string for the edges + * @default #ffffff + */ + edgeColour: Base.Color; + /** + * Hex colour string for face colour + * @default #ff0000 + */ + faceColour: Base.Color; + /** + * Color of the vertices that will be drawn + * @default #ff00ff + */ + vertexColour: Base.Color; + /** + * Face material + * @default undefined + * @optional true + */ + faceMaterial?: Base.Material; + /** + * Edge width + * @default 2 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + edgeWidth: number; + /** + * The size of a vertices that will be drawn + * @default 0.03 + * @minimum 0 + * @maximum Infinity + * @step 0.01 + */ + vertexSize: number; + /** + * You can turn off drawing of edges via this property + * @default true + */ + drawEdges: boolean; + /** + * You can turn off drawing of faces via this property + * @default true + */ + drawFaces: boolean; + /** + * You can turn off drawing of vertexes via this property + * @default false + */ + drawVertices: boolean; + /** + * Precision of the mesh that will be generated for the shape, lower number will mean more triangles + * @default 0.01 + * @minimum 0 + * @maximum Infinity + * @step 0.01 + */ + precision: number; + /** + * Draw index of edges in space + * @default false + */ + drawEdgeIndexes: boolean; + /** + * Indicates the edge index height if they are drawn + * @default 0.06 + * @minimum 0 + * @maximum Infinity + * @step 0.01 + */ + edgeIndexHeight: number; + /** + * Edge index colour if the edges are drawn + * @default #ff00ff + */ + edgeIndexColour: Base.Color; + /** + * Draw indexes of faces in space + * @default false + */ + drawFaceIndexes: boolean; + /** + * Indicates the edge index height if they are drawn + * @default 0.06 + * @minimum 0 + * @maximum Infinity + * @step 0.01 + */ + faceIndexHeight: number; + /** + * Edge index colour if the edges are drawn + * @default #0000ff + */ + faceIndexColour: Base.Color; + /** + * Draw two-sided faces with different colors for front and back. This helps visualize face orientation. + * @default true + */ + drawTwoSided: boolean; + /** + * Hex colour string for back face colour (negative side of the face). Only used when drawTwoSided is true. + * @default #0000ff + */ + backFaceColour: Base.Color; + /** + * Back face opacity value between 0 and 1. Only used when drawTwoSided is true. + * @default 1 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + backFaceOpacity: number; + /** + * Size of arrow heads at the end of edges to indicate edge/wire orientation. Set to 0 to disable arrows. + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 0.01 + */ + edgeArrowSize: number; + /** + * Angle of the arrow head in degrees. Controls how wide the arrow head spreads. + * @default 15 + * @minimum 0 + * @maximum 90 + * @step 1 + */ + edgeArrowAngle: number; + } + class DrawOcctShapeSimpleOptions { + constructor( + precision?: number, + drawFaces?: boolean, + faceColour?: Base.Color, + drawEdges?: boolean, + edgeColour?: Base.Color, + edgeWidth?: number, + drawTwoSided?: boolean, + backFaceColour?: Base.Color, + backFaceOpacity?: number + ); + /** + * Precision + * @default 0.01 + * @minimum 0 + * @maximum Infinity + */ + precision: number; + /** + * You can turn off drawing of faces via this property + * @default true + */ + drawFaces: boolean; + /** + * Hex colour string for face colour + * @default #ff0000 + */ + faceColour?: Base.Color; + /** + * You can turn off drawing of edges via this property + * @default true + */ + drawEdges: boolean; + /** + * Hex colour string for the edges + * @default #ffffff + */ + edgeColour: Base.Color; + /** + * Edge width + * @default 2 + * @minimum 0 + * @maximum Infinity + */ + edgeWidth: number; + /** + * Whether to draw two-sided geometry with back face rendering + * @default true + */ + drawTwoSided: boolean; + /** + * Hex colour string for the back face when drawing two-sided geometry + * @default #0000ff + */ + backFaceColour: Base.Color; + /** + * Opacity of the back face when drawing two-sided geometry + * @default 1 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + backFaceOpacity: number; + } + class DrawOcctShapeMaterialOptions { + constructor( + precision?: number, + faceMaterial?: any, + drawEdges?: boolean, + edgeColour?: Base.Color, + edgeWidth?: number + ); + /** + * Precision + * @default 0.01 + * @minimum 0 + * @maximum Infinity + */ + precision: number; + /** + * Face material + * @default undefined + */ + faceMaterial: any; + /** + * You can turn off drawing of edges via this property + * @default true + */ + drawEdges: boolean; + /** + * Hex colour string for the edges + * @default #ffffff + */ + edgeColour: Base.Color; + /** + * Edge width + * @default 2 + * @minimum 0 + * @maximum Infinity + */ + edgeWidth: number; + } + /** + * Texture filtering mode - how the texture is sampled when scaled + */ + enum samplingModeEnum { + nearest = "nearest", + bilinear = "bilinear", + trilinear = "trilinear", + } + /** + * Generic texture creation options that work across all supported game engines. + * These options are mapped to engine-specific texture properties. + */ + class GenericTextureDto { + constructor( + url?: string, + name?: string, + uScale?: number, + vScale?: number, + uOffset?: number, + vOffset?: number, + wAng?: number, + invertY?: boolean, + invertZ?: boolean, + samplingMode?: samplingModeEnum + ); + /** + * URL of the texture image. Can be a local path or remote URL. + * @default undefined + */ + url: string; + /** + * Name identifier for the texture + * @default Texture + */ + name: string; + /** + * Horizontal (U) scale/tiling of the texture + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + uScale: number; + /** + * Vertical (V) scale/tiling of the texture + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + vScale: number; + /** + * Horizontal (U) offset of the texture + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + uOffset: number; + /** + * Vertical (V) offset of the texture + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + vOffset: number; + /** + * Rotation angle of the texture in radians around the W axis + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + wAng: number; + /** + * Invert the texture on the Y axis + * @default false + */ + invertY: boolean; + /** + * Invert the texture on the Z axis + * @default false + */ + invertZ: boolean; + /** + * Texture sampling/filtering mode + * @default nearest + */ + samplingMode: samplingModeEnum; + } + /** + * Alpha/blend modes that determine how transparent materials are rendered + */ + enum alphaModeEnum { + opaque = "opaque", + mask = "mask", + blend = "blend", + } + /** + * Generic PBR (Physically Based Rendering) material creation options. + * These properties represent the common subset available across BabylonJS, ThreeJS, and PlayCanvas. + * Property names follow BabylonJS conventions and are mapped to equivalent properties in other engines. + */ + class GenericPBRMaterialDto { + constructor( + name?: string, + baseColor?: Base.Color, + metallic?: number, + roughness?: number, + alpha?: number, + emissiveColor?: Base.Color, + emissiveIntensity?: number, + zOffset?: number, + zOffsetUnits?: number, + baseColorTexture?: Base.Texture, + metallicRoughnessTexture?: Base.Texture, + normalTexture?: Base.Texture, + emissiveTexture?: Base.Texture, + occlusionTexture?: Base.Texture, + alphaMode?: alphaModeEnum, + alphaCutoff?: number, + doubleSided?: boolean, + wireframe?: boolean, + unlit?: boolean + ); + /** + * Name identifier for the material + * @default PBRMaterial + */ + name: string; + /** + * Base/albedo color of the material in hex format + * @default #0000ff + */ + baseColor: Base.Color; + /** + * Metallic factor (0 = dielectric, 1 = metallic) + * @default 0.5 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + metallic: number; + /** + * Roughness factor (0 = smooth/mirror, 1 = rough/diffuse) + * @default 0.5 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + roughness: number; + /** + * Overall opacity/transparency of the material (0 = fully transparent, 1 = fully opaque) + * @default 1 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + alpha: number; + /** + * Emissive color - the color the material appears to emit (glow) + * @default #000000 + */ + emissiveColor?: Base.Color; + /** + * Intensity multiplier for the emissive color + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + emissiveIntensity: number; + /** + * Z-buffer depth offset factor to help with z-fighting on coplanar surfaces + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + zOffset: number; + /** + * Z-buffer depth offset units for fine-tuned z-fighting control + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 1 + */ + zOffsetUnits: number; + /** + * Texture to use for base/albedo color + * @default undefined + * @optional true + */ + baseColorTexture?: Base.Texture; + /** + * Combined metallic-roughness texture (metallic in B channel, roughness in G channel) + * @default undefined + * @optional true + */ + metallicRoughnessTexture?: Base.Texture; + /** + * Normal/bump map texture for surface detail + * @default undefined + * @optional true + */ + normalTexture?: Base.Texture; + /** + * Texture for emissive/glow areas + * @default undefined + * @optional true + */ + emissiveTexture?: Base.Texture; + /** + * Ambient occlusion texture for soft shadows in crevices + * @default undefined + * @optional true + */ + occlusionTexture?: Base.Texture; + /** + * Alpha/transparency mode: opaque, mask (cutout), or blend (translucent) + * @default opaque + */ + alphaMode: alphaModeEnum; + /** + * Alpha threshold for mask mode (pixels below this are fully transparent) + * @default 0.5 + * @minimum 0 + * @maximum 1 + * @step 0.05 + */ + alphaCutoff: number; + /** + * Render both sides of faces (equivalent to disabling backFaceCulling) + * @default false + */ + doubleSided: boolean; + /** + * Render material as wireframe + * @default false + */ + wireframe: boolean; + /** + * Disable lighting calculations and render flat/unlit + * @default false + */ + unlit: boolean; + } + enum drawingTypes { + point = 0, + points = 1, + line = 2, + lines = 3, + node = 4, + nodes = 5, + polyline = 6, + polylines = 7, + verbCurve = 8, + verbCurves = 9, + verbSurface = 10, + verbSurfaces = 11, + jscadMesh = 12, + jscadMeshes = 13, + occt = 14, + manifold = 15, + tag = 16, + tags = 17, + } + } + declare namespace BabylonNode { + class NodeDto { + constructor(node?: BABYLON.TransformNode); + /** + * Transformation node + */ + node: BABYLON.TransformNode; + } + class NodeTranslationDto { + constructor( + node?: BABYLON.TransformNode, + direction?: Base.Vector3, + distance?: number + ); + /** + * Transformation node + */ + node: BABYLON.TransformNode; + /** + * Direction vector expressed in [x, y, z] vector array + */ + direction: Base.Vector3; + /** + * Distance to translate + */ + distance: number; + } + class NodeParentDto { + constructor( + node?: BABYLON.TransformNode, + parentNode?: BABYLON.TransformNode + ); + /** + * Transformation node + */ + node: BABYLON.TransformNode; + /** + * Parent node + */ + parentNode: BABYLON.TransformNode; + } + class NodeDirectionDto { + constructor(node?: BABYLON.TransformNode, direction?: Base.Vector3); + /** + * Transformation node + */ + node: BABYLON.TransformNode; + /** + * Direction vector expressed in [x, y, z] vector array + */ + direction: number[]; + } + class NodePositionDto { + constructor(node?: BABYLON.TransformNode, position?: Base.Point3); + /** + * Transformation node + */ + node: BABYLON.TransformNode; + /** + * Position vector expressed in [x, y, z] vector array + */ + position: Base.Point3; + } + class RotateNodeDto { + constructor( + node?: BABYLON.TransformNode, + axis?: Base.Vector3, + angle?: number + ); + /** + * Transformation node + */ + node: BABYLON.TransformNode; + /** + * Rotate around the axis expressed in [x, y, z] vector array + */ + axis: Base.Vector3; + /** + * The rotation angle expressed in degrees + */ + angle: number; + } + class RotateAroundAxisNodeDto { + constructor( + node?: BABYLON.TransformNode, + position?: Base.Point3, + axis?: Base.Vector3, + angle?: number + ); + /** + * Transformation node + */ + node: BABYLON.TransformNode; + /** + * Position vector expressed in [x, y, z] vector array + */ + position: Base.Point3; + /** + * Rotate around the axis expressed in [x, y, z] vector array + */ + axis: Base.Vector3; + /** + * The rotation angle expressed in degrees + */ + angle: number; + } + class CreateNodeFromRotationDto { + constructor( + parent?: BABYLON.TransformNode, + origin?: Base.Point3, + rotation?: Base.Vector3 + ); + /** + * Optional parent node + */ + parent: BABYLON.TransformNode | null; + /** + * Oirigin of the node + */ + origin: Base.Point3; + /** + * Rotations of the node around x y z axis + */ + rotation: Base.Vector3; + } + class DrawNodeDto { + constructor( + node?: BABYLON.TransformNode, + colorX?: string, + colorY?: string, + colorZ?: string, + size?: number + ); + /** + * Transformation node + */ + node: BABYLON.TransformNode; + /** + * Hex encoded color string for X axis + */ + colorX: string; + /** + * Hex encoded color string for Y axis + */ + colorY: string; + /** + * Hex encoded color string for Z axis + */ + colorZ: string; + /** + * Length of the node axis + */ + size: number; + } + class DrawNodesDto { + constructor( + nodes?: BABYLON.TransformNode[], + colorX?: string, + colorY?: string, + colorZ?: string, + size?: number + ); + /** + * Nodes that will be drawn + */ + nodes: BABYLON.TransformNode[]; + /** + * Hex encoded color string for X axis + */ + colorX: string; + /** + * Hex encoded color string for Y axis + */ + colorY: string; + /** + * Hex encoded color string for Z axis + */ + colorZ: string; + /** + * Length of the node axis + */ + size: number; + } + } + declare namespace BabylonScene { + class SceneBackgroundColourDto { + /** + * Provide options without default values + */ + constructor(colour?: string); + /** + * Hex colour string for the scene background colour + * @default #ffffff + */ + colour: Base.Color; + } + class SceneDto { + /** + * Provide scene + */ + constructor(scene?: BABYLON.Scene); + /** + * The babylonjs scene + * @default undefined + */ + scene: BABYLON.Scene; + } + class EnablePhysicsDto { + constructor(vector?: Base.Vector3); + /** + * The gravity vector + * @default [0, -9.81, 0] + */ + vector: Base.Vector3; + } + class PointLightDto { + constructor( + position?: Base.Point3, + intensity?: number, + diffuse?: Base.Color, + specular?: Base.Color, + radius?: number, + shadowGeneratorMapSize?: number, + enableShadows?: boolean, + shadowDarkness?: number, + transparencyShadow?: boolean, + shadowUsePercentageCloserFiltering?: boolean, + shadowContactHardeningLightSizeUVRatio?: number, + shadowBias?: number, + shadowNormalBias?: number, + shadowMaxZ?: number, + shadowMinZ?: number, + shadowRefreshRate?: number + ); + /** + * Position of the point light + * @default [0, 0, 0] + */ + position: Base.Point3; + /** + * Intensity of the point light, value between 0 and 1 + * @default 2000 + * @minimum 0 + * @maximum Infinity + * @step 500 + */ + intensity: number; + /** + * Diffuse colour of the point light + * @default #ffffff + */ + diffuse: Base.Color; + /** + * Specular colour of the point light + * @default #ffffff + */ + specular: Base.Color; + /** + * Radius of the sphere mesh representing the light bulb. If 0 light gets created without the mesh + * @default 0.1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + radius: number; + /** + * The map size for shadow generator texture if shadows are enabled + * @default 1024 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + shadowGeneratorMapSize?: number; + /** + * Enables shadows + * @default true + */ + enableShadows?: boolean; + /** + * Shadow darkness + * @default 0 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + shadowDarkness?: number; + /** + * Sets the ability to have transparent shadow (useful for Gaussian Splatting Meshes) + * @default false + */ + transparencyShadow: boolean; + /** + * Use percentage closer filtering + * @default true + */ + shadowUsePercentageCloserFiltering: boolean; + /** + * Shadow contact hardening light size UV ratio - only applies if usePercentageCloserFiltering is true + * @default 0.2 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + shadowContactHardeningLightSizeUVRatio: number; + /** + * Shadow bias + * @default 0.0001 + * @minimum 0 + * @maximum Infinity + * @step 0.00001 + */ + shadowBias: number; + /** + * Shadow normal bias + * @default 0.002 + * @minimum 0 + * @maximum Infinity + * @step 0.0001 + */ + shadowNormalBias: number; + /** + * Shadow max Z + * @default 1000 + * @minimum 0 + * @maximum Infinity + * @step 50 + */ + shadowMaxZ: number; + /** + * Shadow min Z + * @default 0.1 + * @minimum 0 + * @maximum Infinity + * @step 50 + */ + shadowMinZ: number; + /** + * Shadow refresh rate + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + shadowRefreshRate: number; + } + class ActiveCameraDto { + constructor(camera?: BABYLON.Camera); + /** + * Camera to activate + * @default undefined + */ + camera: BABYLON.Camera; + } + class UseRightHandedSystemDto { + constructor(use?: boolean); + /** Indicates to use right handed system + * @default true + */ + use: boolean; + } + class DirectionalLightDto { + constructor( + direction?: Base.Vector3, + intensity?: number, + diffuse?: Base.Color, + specular?: Base.Color, + shadowGeneratorMapSize?: number, + enableShadows?: boolean, + shadowDarkness?: number, + shadowUsePercentageCloserFiltering?: boolean, + shadowContactHardeningLightSizeUVRatio?: number, + shadowBias?: number, + shadowNormalBias?: number, + shadowMaxZ?: number, + shadowMinZ?: number, + shadowRefreshRate?: number + ); + /** + * Direction of the directional light + * @default [-100, -100, -100] + */ + direction: Base.Vector3; + /** + * Intensity of the point light, value between 0 and 1 + * @default 0.5 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + intensity: number; + /** + * Diffuse colour of the point light + * @default #ffffff + */ + diffuse: Base.Color; + /** + * Specular colour of the point light + * @default #ffffff + */ + specular: Base.Color; + /** + * The map size for shadow generator texture if shadows are enabled + * @default 1024 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + shadowGeneratorMapSize?: number; + /** + * Enables shadows + * @default true + */ + enableShadows?: boolean; + /** + * Shadow darkness + * @default 0 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + shadowDarkness?: number; + /** + * Use percentage closer filtering + * @default true + */ + shadowUsePercentageCloserFiltering: boolean; + /** + * Sets the ability to have transparent shadow (useful for Gaussian Splatting Meshes) + * @default false + */ + transparencyShadow: boolean; + /** + * Shadow contact hardening light size UV ratio - only applies if usePercentageCloserFiltering is true + * @default 0.2 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + shadowContactHardeningLightSizeUVRatio: number; + /** + * Shadow bias + * @default 0.0001 + * @minimum 0 + * @maximum Infinity + * @step 0.00001 + */ + shadowBias: number; + /** + * Shadow normal bias + * @default 0.002 + * @minimum 0 + * @maximum Infinity + * @step 0.0001 + */ + shadowNormalBias: number; + /** + * Shadow max Z + * @default 1000 + * @minimum 0 + * @maximum Infinity + * @step 50 + */ + shadowMaxZ: number; + /** + * Shadow min Z + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 50 + */ + shadowMinZ: number; + /** + * Shadow refresh rate + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + shadowRefreshRate: number; + } + class CameraConfigurationDto { + constructor( + position?: Base.Point3, + lookAt?: Base.Point3, + lowerRadiusLimit?: number, + upperRadiusLimit?: number, + lowerAlphaLimit?: number, + upperAlphaLimit?: number, + lowerBetaLimit?: number, + upperBetaLimit?: number, + angularSensibilityX?: number, + angularSensibilityY?: number, + maxZ?: number, + panningSensibility?: number, + wheelPrecision?: number + ); + /** + * Position of the point light + * @default [10, 10, 10] + * + */ + position: Base.Point3; + /** + * Look at + */ + lookAt: Base.Point3; + /** + * Lower radius limit - how close can the camera be to the target + * @default undefined + * @minimum -Infinity + * @maximum Infinity + * @step 1 + * @optional true + */ + lowerRadiusLimit: any; + /** + * Upper radius limit - how far can the camera be from the target + * @default undefined + * @minimum -Infinity + * @maximum Infinity + * @step 1 + * @optional true + */ + upperRadiusLimit: any; + /** + * Lower alpha limit - camera rotation along the longitudinal (horizontal) axis in degrees. + * @default undefined + * @minimum -360 + * @maximum 360 + * @step 1 + * @optional true + */ + lowerAlphaLimit: any; + /** + * Upper alpha limit - camera rotation along the longitudinal (horizontal) axis in degrees. + * @default undefined + * @minimum -360 + * @maximum 360 + * @step 1 + * @optional true + */ + upperAlphaLimit: any; + /** + * Lower beta limit - camera rotation along the latitudinal (vertical) axis in degrees. This is counted from the top down, where 0 is looking from top straight down. + * @default 1 + * @minimum -360 + * @maximum 360 + * @step 1 + */ + lowerBetaLimit: number; + /** + * Upper beta limit - camera rotation along the longitudinal (vertical) axis in degrees. This is counted from the top down, where 180 is looking from bottom straight up. + * @default 179 + * @minimum -360 + * @maximum 360 + * @step 1 + */ + upperBetaLimit: number; + /** + * Angular sensibility along x (horizontal) axis of the camera. The lower this number, the faster the camera will move. + * @default 1000 + * @minimum 0 + * @maximum Infinity + * @step 10 + */ + angularSensibilityX: number; + /** + * Angular sensibility along y (vertical) axis of the camera. The lower this number, the faster the camera will move. + * @default 1000 + * @minimum 0 + * @maximum Infinity + * @step 10 + */ + angularSensibilityY: number; + /** + * Change how far the camera can see + * @default 1000 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + maxZ: number; + /** + * Panning sensibility. If large units are used for the model, this number needs to get smaller + * @default 1000 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + panningSensibility: number; + /** + * Zoom precision of the wheel. If large units are used, this number needs to get smaller + * @default 3 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + wheelPrecision: number; + } + class SkyboxDto { + constructor( + skybox?: Base.skyboxEnum, + size?: number, + blur?: number, + environmentIntensity?: number, + hideSkybox?: boolean + ); + /** + * Skybox type + * @default clearSky + */ + skybox: Base.skyboxEnum; + /** + * Skybox size + * @default 1000 + * @minimum 0 + * @maximum Infinity + * @step 10 + */ + size: number; + /** + * Identifies if skybox texture should affect scene environment + * @default 0.1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + blur: number; + /** + * Identifies if skybox texture should affect scene environment + * @default 0.7 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + environmentIntensity: number; + /** + * Hides the skybox mesh but keeps the environment texture + * @default false + */ + hideSkybox?: boolean; + } + class SkyboxCustomTextureDto { + constructor( + textureUrl?: string, + textureSize?: number, + size?: number, + blur?: number, + environmentIntensity?: number, + hideSkybox?: boolean + ); + /** + * Skybox texture URL pointing to .hdr, .env or root of the cubemap images + * @default undefined + * @optional true + */ + textureUrl?: string; + /** + * Skybox texture size (only applies to custom URL texture) + * @default 512 + * @optional true + */ + textureSize?: number; + /** + * Skybox size + * @default 1000 + * @minimum 0 + * @maximum Infinity + * @step 10 + */ + size: number; + /** + * Identifies if skybox texture should affect scene environment + * @default 0.1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + blur: number; + /** + * Identifies if skybox texture should affect scene environment + * @default 0.7 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + environmentIntensity: number; + /** + * Hides the skybox mesh but keeps the environment texture + * @default false + */ + hideSkybox?: boolean; + } + class PointerDto { + statement_update: () => void; + } + class FogDto { + constructor( + mode?: Base.fogModeEnum, + color?: Base.Color, + density?: number, + start?: number, + end?: number + ); + /** + * Fog mode + * @default none + */ + mode: Base.fogModeEnum; + /** + * Fog color + * @default #ffffff + */ + color: Base.Color; + /** + * Fog density + * @default 0.1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + density: number; + /** + * Fog start + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + start: number; + /** + * Fog end + * @default 1000 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + end: number; + } + class SceneCanvasCSSBackgroundImageDto { + /** + * Provide options without default values + */ + constructor(cssBackgroundImage?: string); + /** + * CSS background image string + * @default linear-gradient(to top, #1a1c1f 0%, #93aacd 100%) + */ + cssBackgroundImage: string; + } + class SceneTwoColorLinearGradientDto { + constructor( + colorFrom?: Base.Color, + colorTo?: Base.Color, + direction?: Base.gradientDirectionEnum, + stopFrom?: number, + stopTo?: number + ); + /** + * Starting color in hex format + * @default #1a1c1f + */ + colorFrom: Base.Color; + /** + * Ending color in hex format + * @default #93aacd + */ + colorTo: Base.Color; + /** + * Gradient direction + * @default toBottom + */ + direction: Base.gradientDirectionEnum; + /** + * Starting color stop percentage + * @default 0 + * @minimum 0 + * @maximum 100 + * @step 1 + */ + stopFrom: number; + /** + * Ending color stop percentage + * @default 100 + * @minimum 0 + * @maximum 100 + * @step 1 + */ + stopTo: number; + } + class SceneTwoColorRadialGradientDto { + constructor( + colorFrom?: Base.Color, + colorTo?: Base.Color, + position?: Base.gradientPositionEnum, + stopFrom?: number, + stopTo?: number, + shape?: Base.gradientShapeEnum + ); + /** + * Starting color in hex format + * @default #1a1c1f + */ + colorFrom: Base.Color; + /** + * Ending color in hex format + * @default #93aacd + */ + colorTo: Base.Color; + /** + * Gradient position + * @default center + */ + position: Base.gradientPositionEnum; + /** + * Starting color stop percentage + * @default 0 + * @minimum 0 + * @maximum 100 + * @step 1 + */ + stopFrom: number; + /** + * Ending color stop percentage + * @default 100 + * @minimum 0 + * @maximum 100 + * @step 1 + */ + stopTo: number; + /** + * Gradient shape + * @default circle + */ + shape: Base.gradientShapeEnum; + } + class SceneMultiColorLinearGradientDto { + constructor( + colors?: Base.Color[], + stops?: number[], + direction?: Base.gradientDirectionEnum + ); + /** + * Array of colors in hex format + * @default ["#1a1c1f", "#93aacd"] + */ + colors: Base.Color[]; + /** + * Array of stop percentages for each color + * @default [0, 100] + */ + stops: number[]; + /** + * Gradient direction + * @default toTop + */ + direction: Base.gradientDirectionEnum; + } + class SceneMultiColorRadialGradientDto { + constructor( + colors?: Base.Color[], + stops?: number[], + position?: Base.gradientPositionEnum, + shape?: Base.gradientShapeEnum + ); + /** + * Array of colors in hex format + * @default ["#1a1c1f", "#93aacd"] + */ + colors: Base.Color[]; + /** + * Array of stop percentages for each color + * @default [0, 100] + */ + stops: number[]; + /** + * Gradient position + * @default center + */ + position: Base.gradientPositionEnum; + /** + * Gradient shape + * @default circle + */ + shape: Base.gradientShapeEnum; + } + class SceneCanvasBackgroundImageDto { + constructor( + imageUrl?: string, + repeat?: Base.backgroundRepeatEnum, + size?: Base.backgroundSizeEnum, + position?: Base.gradientPositionEnum, + attachment?: Base.backgroundAttachmentEnum, + origin?: Base.backgroundOriginClipEnum, + clip?: Base.backgroundOriginClipEnum + ); + /** + * URL of the background image + * @default undefined + */ + imageUrl?: string; + /** + * How the background image should repeat + * @default noRepeat + */ + repeat: Base.backgroundRepeatEnum; + /** + * Size of the background image (enum values or specific values like '100px 50px') + * @default cover + */ + size: Base.backgroundSizeEnum; + /** + * Position of the background image (enum values or specific values like '50% 50%') + * @default center + */ + position: Base.gradientPositionEnum; + /** + * Background attachment + * @default scroll + */ + attachment: Base.backgroundAttachmentEnum; + /** + * Background origin + * @default paddingBox + */ + origin: Base.backgroundOriginClipEnum; + /** + * Background clip + * @default borderBox + */ + clip: Base.backgroundOriginClipEnum; + } + } + declare namespace Base { + type Color = string; + type ColorRGB = { + r: number; + g: number; + b: number; + }; + type Material = any; + type Point2 = [number, number]; + type Vector2 = [number, number]; + type Point3 = [number, number, number]; + type Vector3 = [number, number, number]; + type Axis3 = { + origin: Base.Point3; + direction: Base.Vector3; + }; + type Axis2 = { + origin: Base.Point2; + direction: Base.Vector2; + }; + type Segment2 = [Point2, Point2]; + type Segment3 = [Point3, Point3]; + type TrianglePlane3 = { + normal: Vector3; + d: number; + }; + type Triangle3 = [Base.Point3, Base.Point3, Base.Point3]; + type Mesh3 = Triangle3[]; + type Plane3 = { + origin: Base.Point3; + normal: Base.Vector3; + direction: Base.Vector3; + }; + type BoundingBox = { + min: Base.Point3; + max: Base.Point3; + center?: Base.Point3; + width?: number; + height?: number; + length?: number; + }; + type Line2 = { + start: Base.Point2; + end: Base.Point2; + }; + type Line3 = { + start: Base.Point3; + end: Base.Point3; + }; + type Polyline3 = { + points: Base.Point3[]; + isClosed?: boolean; + color?: number[]; + }; + type Polyline2 = { + points: Base.Point2[]; + isClosed?: boolean; + color?: number[]; + }; + type TransformMatrix3x3 = [ + number, + number, + number, + number, + number, + number, + number, + number, + number + ]; + type TransformMatrixes3x3 = TransformMatrix3x3[]; + type TransformMatrix = [ + number, + number, + number, + number, + number, + number, + number, + number, + number, + number, + number, + number, + number, + number, + number, + number + ]; + type TransformMatrixes = TransformMatrix[]; + enum horizontalAlignEnum { + left = "left", + center = "center", + right = "right", + } + enum verticalAlignmentEnum { + top = "top", + middle = "middle", + bottom = "bottom", + } + enum topBottomEnum { + top = "top", + bottom = "bottom", + } + enum basicAlignmentEnum { + topLeft = "topLeft", + topMid = "topMid", + topRight = "topRight", + midLeft = "midLeft", + midMid = "midMid", + midRight = "midRight", + bottomLeft = "bottomLeft", + bottomMid = "bottomMid", + bottomRight = "bottomRight", + } + } + declare namespace Color { + class HexDto { + constructor(color?: Base.Color); + /** + * Color hex + * @default #0000ff + */ + color: Base.Color; + } + class InvertHexDto { + constructor(color?: Base.Color); + /** + * Color hex + * @default #0000ff + */ + color: Base.Color; + /** + * Choose to invert the color to black and white (useful for text color) + */ + blackAndWhite: boolean; + } + class HexDtoMapped { + constructor(color?: Base.Color, from?: number, to?: number); + /** + * Color hex + * @default #0000ff + */ + color: Base.Color; + /** + * From min bound + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 1 + */ + from: number; + /** + * To max bound + * @default 255 + * @minimum -Infinity + * @maximum Infinity + * @step 1 + */ + to: number; + } + class RGBObjectMaxDto { + constructor(rgb?: Base.ColorRGB, max?: number); + /** + * Red value component + * @default undefined + */ + rgb: Base.ColorRGB; + /** + * Min value of the range + * @default 0 + * @minimum 0 + * @maximum 255 + * @step 0.1 + */ + min: number; + /** + * Max value, it would automatically be remapped to whatever is needed if lower comes in + * @default 255 + * @minimum 0 + * @maximum 255 + * @step 0.1 + */ + max: number; + } + class RGBMinMaxDto { + constructor( + r?: number, + g?: number, + b?: number, + min?: number, + max?: number + ); + /** + * Red value component + * @default 255 + * @minimum 0 + * @maximum 255 + * @step 1 + */ + r: number; + /** + * Green value component + * @default 255 + * @minimum 0 + * @maximum 255 + * @step 1 + */ + g: number; + /** + * Blue value component + * @default 255 + * @minimum 0 + * @maximum 255 + * @step 1 + */ + b: number; + /** + * Min value of the range + * @default 0 + * @minimum 0 + * @maximum 255 + * @step 0.1 + */ + min: number; + /** + * Max value of the range + * @default 255 + * @minimum 0 + * @maximum 255 + * @step 0.1 + */ + max: number; + } + class RGBObjectDto { + constructor(rgb?: Base.ColorRGB); + /** + * Red value component + * @default undefined + */ + rgb: Base.ColorRGB; + } + } + declare namespace Dates { + class DateDto { + constructor(date?: Date); + /** + * The date + * @default undefined + */ + date: Date; + } + class DateStringDto { + constructor(dateString?: string); + /** + * The date string + * @default undefined + */ + dateString: string; + } + class DateSecondsDto { + constructor(date?: Date, seconds?: number); + /** + * The date to update the seconds for + * @default undefined + */ + date: Date; + /** + * The seconds of the date + * @default 30 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + seconds: number; + } + class DateDayDto { + constructor(date?: Date, day?: number); + /** + * The date + * @default undefined + */ + date: Date; + /** + * The day of the date + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + day: number; + } + class DateYearDto { + constructor(date?: Date, year?: number); + /** + * The date + * @default undefined + */ + date: Date; + /** + * The year of the date + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + year: number; + } + class DateMonthDto { + constructor(date?: Date, month?: number); + /** + * The date + * @default undefined + */ + date: Date; + /** + * The month of the date + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + month: number; + } + class DateHoursDto { + constructor(date?: Date, hours?: number); + /** + * The date + * @default undefined + */ + date: Date; + /** + * The hours of the date + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + hours: number; + } + class DateMinutesDto { + constructor(date?: Date, minutes?: number); + /** + * The date + * @default undefined + */ + date: Date; + /** + * The minutes of the date + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + minutes: number; + } + class DateMillisecondsDto { + constructor(date?: Date, milliseconds?: number); + /** + * The date + * @default undefined + */ + date: Date; + /** + * The milliseconds of the date + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + milliseconds: number; + } + class DateTimeDto { + constructor(date?: Date, time?: number); + /** + * The date + * @default undefined + */ + date: Date; + /** + * The time of the date + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + time: number; + } + class CreateFromUnixTimeStampDto { + constructor(unixTimeStamp?: number); + /** + * The unix time stamp + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + unixTimeStamp: number; + } + class CreateDateDto { + constructor( + year?: number, + month?: number, + day?: number, + hours?: number, + minutes?: number, + seconds?: number, + milliseconds?: number + ); + /** + * The year of the date + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + year: number; + /** + * The month of the date + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + month: number; + /** + * The day of the month + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + day: number; + /** + * The hours of the date + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + hours: number; + /** + * The minutes of the date + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + minutes: number; + /** + * The seconds of the date + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + seconds: number; + /** + * The milliseconds of the date + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + milliseconds: number; + } + } + declare namespace IO { + /** + * Line segment defined by start and end points + */ + class DxfLineSegmentDto { + constructor(start?: Base.Point2, end?: Base.Point2); + /** + * Start point of the line + * @default undefined + */ + start: Base.Point2; + /** + * End point of the line + * @default undefined + */ + end: Base.Point2; + } + /** + * Arc segment defined by center, radius, and start/end angles in degrees + */ + class DxfArcSegmentDto { + constructor( + center?: Base.Point2, + radius?: number, + startAngle?: number, + endAngle?: number + ); + /** + * Center point of the arc + * @default undefined + */ + center: Base.Point2; + /** + * Radius of the arc + * @default undefined + */ + radius: number; + /** + * Start angle in degrees + * @default undefined + */ + startAngle: number; + /** + * End angle in degrees (counter-clockwise from start angle) + * @default undefined + */ + endAngle: number; + } + /** + * Circle defined by center and radius + */ + class DxfCircleSegmentDto { + constructor(center?: Base.Point2, radius?: number); + /** + * Center point of the circle + * @default undefined + */ + center: Base.Point2; + /** + * Radius of the circle + * @default undefined + */ + radius: number; + } + /** + * Polyline segment defined by multiple points + * Can include bulge values to create arc segments between vertices + */ + class DxfPolylineSegmentDto { + constructor( + points?: Base.Point2[], + closed?: boolean, + bulges?: number[] + ); + /** + * Points defining the polyline vertices + * @default undefined + */ + points: Base.Point2[]; + /** + * Whether the polyline is closed + * @default false + */ + closed?: boolean; + /** + * Bulge values for each vertex (optional) + * Bulge = tan(angle/4) where angle is the arc angle in radians + * Positive = counterclockwise, Negative = clockwise + * 0 = straight line segment + * Array length should match points length (or be undefined for all straight segments) + * @default undefined + */ + bulges?: number[]; + } + /** + * Spline/B-spline segment defined by control points and degree + */ + class DxfSplineSegmentDto { + constructor( + controlPoints?: Base.Point2[], + degree?: number, + closed?: boolean + ); + /** + * Control points defining the spline + * @default undefined + */ + controlPoints: Base.Point2[]; + /** + * Degree of the spline (typically 2 or 3) + * @default 3 + */ + degree?: number; + /** + * Whether the spline is closed + * @default false + */ + closed?: boolean; + } + /** + * A path can contain multiple segments of different types (lines, arcs, polylines, circles, splines) + * Similar to OCCT wires that can combine different edge types + */ + class DxfPathDto { + constructor( + segments?: ( + | DxfLineSegmentDto + | DxfArcSegmentDto + | DxfCircleSegmentDto + | DxfPolylineSegmentDto + | DxfSplineSegmentDto + )[] + ); + /** + * Array of segments that make up this path + * Can include lines, arcs, circles, polylines, and splines + * @default undefined + */ + segments: ( + | DxfLineSegmentDto + | DxfArcSegmentDto + | DxfCircleSegmentDto + | DxfPolylineSegmentDto + | DxfSplineSegmentDto + )[]; + } + /** + * A part containing multiple paths on the same layer with the same color + */ + class DxfPathsPartDto { + constructor(layer?: string, color?: Base.Color, paths?: DxfPathDto[]); + /** + * Layer name for all paths in this part + * @default Default + */ + layer: string; + /** + * Color for all paths in this part + * @default #000000 + */ + color: Base.Color; + /** + * Array of paths, each containing multiple segments + * @default undefined + */ + paths: DxfPathDto[]; + } + /** + * Main DXF model containing all path parts + */ + class DxfModelDto { + constructor( + dxfPathsParts?: DxfPathsPartDto[], + colorFormat?: "aci" | "truecolor", + acadVersion?: "AC1009" | "AC1015" + ); + /** + * Array of path parts, each containing paths with segments + * @default undefined + */ + dxfPathsParts: DxfPathsPartDto[]; + /** + * Color format to use in the DXF file + * - "aci": AutoCAD Color Index (1-255) - Better compatibility with older CAD software like Design CAD 3D Max + * - "truecolor": 24-bit RGB true color - Full color spectrum, requires newer CAD software + * @default aci + */ + colorFormat?: "aci" | "truecolor"; + /** + * AutoCAD version format for DXF file + * - "AC1009": AutoCAD R12/R11 - Maximum compatibility with older CAD software (e.g., Design CAD 3D Max) + * - "AC1015": AutoCAD 2000 - Modern format with extended features + * @default AC1009 + */ + acadVersion?: "AC1009" | "AC1015"; + } + } + declare namespace Line { + class LinePointsDto { + /** + * Provide options without default values + */ + constructor(start?: Base.Point3, end?: Base.Point3); + /** + * Start point + * @default undefined + */ + start?: Base.Point3; + /** + * End point + * @default undefined + */ + end?: Base.Point3; + } + class LineStartEndPointsDto { + /** + * Provide options without default values + */ + constructor(startPoints?: Base.Point3[], endPoints?: Base.Point3[]); + /** + * Start points + * @default undefined + */ + startPoints: Base.Point3[]; + /** + * End points + * @default undefined + */ + endPoints: Base.Point3[]; + } + class DrawLineDto { + /** + * Provide options without default values + */ + constructor( + line?: LinePointsDto, + opacity?: number, + colours?: string | string[], + size?: number, + updatable?: boolean, + lineMesh?: T + ); + /** + * Line + * @default undefined + */ + line?: LinePointsDto; + /** + * Value between 0 and 1 + * @default 1 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + opacity?: number; + /** + * Hex colour string + * @default #444444 + */ + colours?: string | string[]; + /** + * Width of the line + * @default 3 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + size?: number; + /** + * Indicates wether the position of this line will change in time + * @default false + */ + updatable?: boolean; + /** + * Line mesh variable in case it already exists and needs updating + * @default undefined + */ + lineMesh?: T; + } + class DrawLinesDto { + /** + * Provide options without default values + */ + constructor( + lines?: LinePointsDto[], + opacity?: number, + colours?: string | string[], + size?: number, + updatable?: boolean, + linesMesh?: T + ); + /** + * Lines + * @default undefined + */ + lines?: LinePointsDto[]; + /** + * Value between 0 and 1 + * @default 1 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + opacity?: number; + /** + * Hex colour string + * @default #444444 + */ + colours?: string | string[]; + /** + * Width of the line + * @default 3 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + size?: number; + /** + * Indicates wether the position of these lines will change in time + * @default false + */ + updatable?: boolean; + /** + * Line mesh variable in case it already exists and needs updating + * @default undefined + */ + linesMesh?: T; + } + class PointsLinesDto { + constructor(points?: Base.Point3[]); + /** + * Points + * @default undefined + */ + points?: Base.Point3[]; + } + class LineDto { + constructor(line?: LinePointsDto); + /** + * Line to convert + * @default undefined + */ + line?: LinePointsDto; + } + class SegmentDto { + constructor(segment?: Base.Segment3); + /** + * Segment + * @default undefined + */ + segment?: Base.Segment3; + } + class SegmentsDto { + constructor(segments?: Base.Segment3[]); + /** + * Segments + * @default undefined + */ + segments?: Base.Segment3[]; + } + class LinesDto { + constructor(lines?: LinePointsDto[]); + /** + * Lines to convert + * @default undefined + */ + lines?: LinePointsDto[]; + } + class LineLineIntersectionDto { + constructor( + line1?: LinePointsDto, + line2?: LinePointsDto, + tolerance?: number + ); + /** + * First line + * @default undefined + */ + line1?: LinePointsDto; + /** + * Second line + * @default undefined + */ + line2?: LinePointsDto; + /** + * Set to false if you want to check for infinite lines + * @default true + */ + checkSegmentsOnly?: boolean; + /** + * Tolerance for intersection + * @default 0.01 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + tolerance?: number; + } + class PointOnLineDto { + constructor(line?: LinePointsDto, param?: number); + /** + * Line to get point on + * @default undefined + */ + line?: LinePointsDto; + /** + * Param to use for point on line + * @default 0.5 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + param?: number; + } + class TransformLineDto { + constructor( + line?: LinePointsDto, + transformation?: Base.TransformMatrixes + ); + /** + * Line to transform + * @default undefined + */ + line?: LinePointsDto; + /** + * Transformation matrix or a list of transformation matrixes + * @default undefined + */ + transformation?: Base.TransformMatrixes; + } + class TransformsLinesDto { + constructor( + lines?: LinePointsDto[], + transformation?: Base.TransformMatrixes[] + ); + /** + * Lines to transform + * @default undefined + */ + lines?: LinePointsDto[]; + /** + * Transformations matrix or a list of transformations matrixes + * @default undefined + */ + transformation?: Base.TransformMatrixes[]; + } + class TransformLinesDto { + constructor( + lines?: LinePointsDto[], + transformation?: Base.TransformMatrixes + ); + /** + * Lines to transform + * @default undefined + */ + lines?: LinePointsDto[]; + /** + * Transformation matrix or a list of transformation matrixes + * @default undefined + */ + transformation?: Base.TransformMatrixes; + } + } + declare namespace Lists { + enum firstLastEnum { + first = "first", + last = "last", + } + class ListItemDto { + constructor(list?: T[], index?: number, clone?: boolean); + /** + * The list to interrogate + * @default undefined + */ + list: T[]; + /** + * Index of the item in the list - 0 means first. + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + index: number; + /** + * Tries to make structured clone of the incoming list data in the component, sometimes it may not be possible due to circular structures or other types of error + * @default true + */ + clone?: boolean; + } + class SubListDto { + constructor( + list?: T[], + indexStart?: number, + indexEnd?: number, + clone?: boolean + ); + /** + * The list to split into a sublist + * @default undefined + */ + list: T[]; + /** + * Index from which to start the sublist - 0 means first. + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + indexStart: number; + /** + * Index to which to end the sublist - 0 means first. + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + indexEnd: number; + /** + * Tries to clone the data in the component, sometimes it may not be possible if structure is circular + * @default true + */ + clone?: boolean; + } + class ListCloneDto { + constructor(list?: T[], clone?: boolean); + /** + * The list to interrogate + * @default undefined + */ + list: T[]; + /** + * Tries to make structured clone of the incoming list data in the component, sometimes it may not be possible due to circular structures or other types of error + * @default true + */ + clone?: boolean; + } + class RepeatInPatternDto { + constructor(list?: T[]); + /** + * The list to interrogate + * @default undefined + */ + list: T[]; + /** + * Tries to make structured clone of the incoming list data in the component, sometimes it may not be possible due to circular structures or other types of error + * @default true + */ + clone?: boolean; + /** + * The limit of the length of the list + * @default 100 + * @minimum 1 + * @maximum Infinity + * @step 1 + */ + lengthLimit: number; + } + class SortDto { + constructor(list?: T[], clone?: boolean, orderAsc?: boolean); + /** + * The list to interrogate + * @default undefined + */ + list: T[]; + /** + * Tries to make structured clone of the incoming list data in the component, sometimes it may not be possible due to circular structures or other types of error + * @default true + */ + clone?: boolean; + /** + * If true, the list will be sorted in ascending order, otherwise in descending order + * @default true + */ + orderAsc: boolean; + } + class SortJsonDto { + constructor(list?: T[], clone?: boolean, orderAsc?: boolean); + /** + * The list to interrogate + * @default undefined + */ + list: T[]; + /** + * Tries to make structured clone of the incoming list data in the component, sometimes it may not be possible due to circular structures or other types of error + * @default true + */ + clone?: boolean; + /** + * If true, the list will be sorted in ascending order, otherwise in descending order + * @default true + */ + orderAsc: boolean; + /** + * The property to sort by + * @default propName + */ + property: string; + } + class ListDto { + constructor(list?: T[]); + /** + * The list + * @default undefined + */ + list: T[]; + } + class GroupListDto { + constructor(list?: T[], nrElements?: number, keepRemainder?: boolean); + /** + * The list of elements to group together + * @default undefined + */ + list: T[]; + /** + * The number of elements in each group + * @default 2 + * @minimum 1 + * @maximum Infinity + * @step 1 + */ + nrElements: number; + /** + * If true, the remainder of the list will be added as a separate group + * @default false + */ + keepRemainder: boolean; + } + class MultiplyItemDto { + constructor(item?: T, times?: number); + /** + * The item to multiply + * @default undefined + */ + item: T; + /** + * Times to multiply + * @default 10 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + times: number; + } + class AddItemAtIndexDto { + constructor(list?: T[], item?: T, index?: number, clone?: boolean); + /** + * The list to which item needs to be added + * @default undefined + */ + list: T[]; + /** + * The item to add + * @default undefined + */ + item: T; + /** + * The index to add the item at + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + index: number; + /** + * Tries to make structured clone of the incoming list data in the component, sometimes it may not be possible due to circular structures or other types of error + * @default true + */ + clone?: boolean; + } + class AddItemAtIndexesDto { + constructor(list?: T[], item?: T, indexes?: number[], clone?: boolean); + /** + * The list to which item needs to be added + * @default undefined + */ + list: T[]; + /** + * The item to add + * @default undefined + */ + item: T; + /** + * The index to add the item at + * @default [0] + */ + indexes: number[]; + /** + * Tries to make structured clone of the incoming list data in the component, sometimes it may not be possible due to circular structures or other types of error + * @default true + */ + clone?: boolean; + } + class AddItemsAtIndexesDto { + constructor( + list?: T[], + items?: T[], + indexes?: number[], + clone?: boolean + ); + /** + * The list to which item needs to be added + * @default undefined + */ + list: T[]; + /** + * The item to add + * @default undefined + */ + items: T[]; + /** + * The index to add the item at + * @default [0] + */ + indexes: number[]; + /** + * Tries to make structured clone of the incoming list data in the component, sometimes it may not be possible due to circular structures or other types of error + * @default true + */ + clone?: boolean; + } + class RemoveItemAtIndexDto { + constructor(list?: T[], index?: number, clone?: boolean); + /** + * The list from which item needs to be removed + * @default undefined + */ + list: T[]; + /** + * The index to on which remove item + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + index: number; + /** + * Tries to make structured clone of the incoming list data in the component, sometimes it may not be possible due to circular structures or other types of error + * @default true + */ + clone?: boolean; + } + class RemoveItemsAtIndexesDto { + constructor(list?: T[], indexes?: number[], clone?: boolean); + /** + * The list from which item needs to be removed + * @default undefined + */ + list: T[]; + /** + * The indexes that should be removed + * @default undefined + */ + indexes: number[]; + /** + * Tries to make structured clone of the incoming list data in the component, sometimes it may not be possible due to circular structures or other types of error + * @default true + */ + clone?: boolean; + } + class RemoveNthItemDto { + constructor(list?: T[], nth?: number, offset?: number, clone?: boolean); + /** + * The list from which item needs to be removed + * @default undefined + */ + list: T[]; + /** + * The nth item to remove + * @default 2 + * @minimum 1 + * @maximum Infinity + * @step 1 + */ + nth: number; + /** + * The offset from which to start counting + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + offset: number; + /** + * Tries to make structured clone of the incoming list data in the component, sometimes it may not be possible due to circular structures or other types of error + * @default true + */ + clone?: boolean; + } + class RandomThresholdDto { + constructor(list?: T[], threshold?: number, clone?: boolean); + /** + * The list from which item needs to be updated + * @default undefined + */ + list: T[]; + /** + * Threshold for items + * @default 0.5 + * @minimum 0 + * @maximum 1 + * @step 1 + */ + threshold: number; + /** + * Tries to make structured clone of the incoming list data in the component, sometimes it may not be possible due to circular structures or other types of error + * @default true + */ + clone?: boolean; + } + class RemoveDuplicatesDto { + constructor(list?: T[], clone?: boolean); + /** + * The list from which item needs to be removed + * @default undefined + */ + list: T[]; + /** + * Tries to make structured clone of the incoming list data in the component, sometimes it may not be possible due to circular structures or other types of error + * @default true + */ + clone?: boolean; + } + class RemoveDuplicatesToleranceDto { + constructor(list?: T[], clone?: boolean, tolerance?: number); + /** + * The list from which item needs to be removed + * @default undefined + */ + list: T[]; + /** + * The tolerance to apply + * @default 1e-7 + * @minimum 0 + * @maximum Infinity + * @step 1e-7 + */ + tolerance: number; + /** + * Tries to make structured clone of the incoming list data in the component, sometimes it may not be possible due to circular structures or other types of error + * @default true + */ + clone?: boolean; + } + class GetByPatternDto { + constructor(list?: T[], pattern?: boolean[]); + /** + * The list from which we need to get an item + * @default undefined + */ + list: T[]; + /** + * The list of booleans to be used as a pattern (true means get, false means skip) + * @default [true, true, false] + */ + pattern: boolean[]; + } + class GetNthItemDto { + constructor(list?: T[], nth?: number, offset?: number, clone?: boolean); + /** + * The list from which we need to get an item + * @default undefined + */ + list: T[]; + /** + * The nth item to get + * @default 2 + * @minimum 1 + * @maximum Infinity + * @step 1 + */ + nth: number; + /** + * The offset from which to start counting + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + offset: number; + /** + * Tries to make structured clone of the incoming list data in the component, sometimes it may not be possible due to circular structures or other types of error + * @default true + */ + clone?: boolean; + } + class GetLongestListLength { + constructor(lists?: T[]); + /** + * The list from which we need to get an item + * @default undefined + */ + lists: T[]; + } + class MergeElementsOfLists { + constructor(lists?: T[], level?: number); + /** + * The list from which we need to get an item + * @default undefined + */ + lists: T[]; + /** + * The level on which to merge the elements. 0 means first level + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + level: number; + } + class AddItemDto { + constructor(list?: T[], item?: T, clone?: boolean); + /** + * The list to which item needs to be added + * @default undefined + */ + list: T[]; + /** + * The item to add + * @default undefined + */ + item: T; + /** + * Tries to make structured clone of the incoming list data in the component, sometimes it may not be possible due to circular structures or other types of error + * @default true + */ + clone?: boolean; + } + class AddItemFirstLastDto { + constructor( + list?: T[], + item?: T, + position?: firstLastEnum, + clone?: boolean + ); + /** + * The list to which item needs to be added + * @default undefined + */ + list: T[]; + /** + * The item to add + * @default undefined + */ + item: T; + /** + * The option if the item needs to be added at the beginning or the end of the list + * @default last + */ + position: firstLastEnum; + /** + * Tries to make structured clone of the incoming list data in the component, sometimes it may not be possible due to circular structures or other types of error + * @default true + */ + clone?: boolean; + } + class ConcatenateDto { + constructor(lists?: T[][], clone?: boolean); + /** + * The lists to concatenate + * @default undefined + */ + lists: T[][]; + /** + * Tries to make structured clone of the incoming list data in the component, sometimes it may not be possible due to circular structures or other types of error + * @default true + */ + clone?: boolean; + } + class IncludesDto { + constructor(list?: T[], item?: T); + /** + * The list to check + * @default undefined + */ + list: T[]; + /** + * The item to look for + * @default undefined + */ + item: T; + } + class InterleaveDto { + constructor(lists?: T[][], clone?: boolean); + /** + * The lists to interleave + * @default undefined + */ + lists: T[][]; + /** + * Tries to make structured clone of the incoming list data in the component, sometimes it may not be possible due to circular structures or other types of error + * @default true + */ + clone?: boolean; + } + } + declare namespace Logic { + enum BooleanOperatorsEnum { + less = "<", + lessOrEqual = "<=", + greater = ">", + greaterOrEqual = ">=", + tripleEqual = "===", + tripleNotEqual = "!==", + equal = "==", + notEqual = "!=", + } + class ComparisonDto { + constructor(first?: T, second?: T, operator?: BooleanOperatorsEnum); + /** + * First item + * @default undefined + */ + first: T; + /** + * Second item + * @default undefined + */ + second: T; + /** + * Operator + * @default less + */ + operator: BooleanOperatorsEnum; + } + class BooleanDto { + constructor(boolean?: boolean); + /** + * Boolean value + * @default false + */ + boolean: boolean; + } + class BooleanListDto { + constructor(booleans?: boolean); + /** + * Boolean value + * @default undefined + */ + booleans: any; + } + class ValueGateDto { + constructor(value?: T, boolean?: boolean); + /** + * Value to transmit when gate will be released. When value is not released we will transmit undefined value + * @default undefined + */ + value: T; + /** + * Boolean value to release the gate + * @default false + */ + boolean: boolean; + } + class TwoValueGateDto { + constructor(value1?: T, value2?: U); + /** + * First value to check + * @default undefined + * @optional true + */ + value1?: T; + /** + * Second value to check + * @default undefined + * @optional true + */ + value2?: U; + } + class RandomBooleansDto { + constructor(length?: number); + /** + * Length of the list + * @default 10 + * @minimum 1 + * @maximum Infinity + * @step 1 + */ + length: number; + /** + * Threshold for true value between 0 and 1. The closer the value is to 1 the more true values there will be in the list. + * @default 0.5 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + trueThreshold: number; + } + class TwoThresholdRandomGradientDto { + /** + * Numbers to remap to bools + * @default undefined + */ + numbers: number[]; + /** + * Threshold for the numeric value until which the output will be true + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + thresholdTotalTrue: number; + /** + * Threshold for the numeric value until which the output will be true + * @default 2 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + thresholdTotalFalse: number; + /** + * Number of levels to go through in between thresholds for gradient + * @default 10 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + nrLevels: number; + } + class ThresholdBooleanListDto { + /** + * Numbers to remap to bools based on threshold + * @default undefined + */ + numbers: number[]; + /** + * Threshold for the numeric value until which the output will be true. + * If number in the list is larger than this threshold it will become false if inverse stays false. + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + threshold: number; + /** + * True values become false and false values become true + * @default false + */ + inverse: boolean; + } + class ThresholdGapsBooleanListDto { + /** + * Numbers to remap to bools based on threshold + * @default undefined + */ + numbers: number[]; + /** + * 2D arrays representing gaps of the thresholds on which numbers should be flipped from false to true if inverse is false. + * @default undefined + */ + gapThresholds: Base.Vector2[]; + /** + * True values become false and false values become true + * @default false + */ + inverse: boolean; + } + } + declare namespace Math { + enum mathTwoNrOperatorEnum { + add = "add", + subtract = "subtract", + multiply = "multiply", + divide = "divide", + power = "power", + modulus = "modulus", + } + enum mathOneNrOperatorEnum { + absolute = "absolute", + negate = "negate", + ln = "ln", + log10 = "log10", + tenPow = "tenPow", + round = "round", + floor = "floor", + ceil = "ceil", + sqrt = "sqrt", + sin = "sin", + cos = "cos", + tan = "tan", + asin = "asin", + acos = "acos", + atan = "atan", + log = "log", + exp = "exp", + radToDeg = "radToDeg", + degToRad = "degToRad", + } + enum easeEnum { + easeInSine = "easeInSine", + easeOutSine = "easeOutSine", + easeInOutSine = "easeInOutSine", + easeInQuad = "easeInQuad", + easeOutQuad = "easeOutQuad", + easeInOutQuad = "easeInOutQuad", + easeInCubic = "easeInCubic", + easeOutCubic = "easeOutCubic", + easeInOutCubic = "easeInOutCubic", + easeInQuart = "easeInQuart", + easeOutQuart = "easeOutQuart", + easeInOutQuart = "easeInOutQuart", + easeInQuint = "easeInQuint", + easeOutQuint = "easeOutQuint", + easeInOutQuint = "easeInOutQuint", + easeInExpo = "easeInExpo", + easeOutExpo = "easeOutExpo", + easeInOutExpo = "easeInOutExpo", + easeInCirc = "easeInCirc", + easeOutCirc = "easeOutCirc", + easeInOutCirc = "easeInOutCirc", + easeInElastic = "easeInElastic", + easeOutElastic = "easeOutElastic", + easeInOutElastic = "easeInOutElastic", + easeInBack = "easeInBack", + easeOutBack = "easeOutBack", + easeInOutBack = "easeInOutBack", + easeInBounce = "easeInBounce", + easeOutBounce = "easeOutBounce", + easeInOutBounce = "easeInOutBounce", + } + class ModulusDto { + constructor(number?: number, modulus?: number); + /** + * Number + * @default 1 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + number: number; + /** + * Modulus + * @default 1 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + modulus: number; + } + class NumberDto { + constructor(number?: number); + /** + * Number + * @default 1 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + number: number; + } + class EaseDto { + constructor(x?: number); + /** + * X value param between 0-1 + * @default 0.5 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + x: number; + /** + * Minimum value + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + min: number; + /** + * Maximum value + * @default 1 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + max: number; + /** + * Ease function + * @default easeInSine + */ + ease: easeEnum; + } + class RoundToDecimalsDto { + constructor(number?: number, decimalPlaces?: number); + /** + * Number to round + * @default 1.123456 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + number: number; + /** + * Number of decimal places + * @default 2 + * @minimum -Infinity + * @maximum Infinity + * @step 1 + */ + decimalPlaces: number; + } + class ActionOnTwoNumbersDto { + constructor( + first?: number, + second?: number, + operation?: mathTwoNrOperatorEnum + ); + /** + * First number + * @default 1 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + first: number; + /** + * Second number + * @default 1 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + second: number; + /** + * Point + * @default add + */ + operation: mathTwoNrOperatorEnum; + } + class TwoNumbersDto { + constructor(first?: number, second?: number); + /** + * First number + * @default 1 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + first: number; + /** + * Second number + * @default 2 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + second: number; + } + class ActionOnOneNumberDto { + constructor(number?: number, operation?: mathOneNrOperatorEnum); + /** + * First number + * @default 1 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + number: number; + /** + * Point + * @default absolute + */ + operation: mathOneNrOperatorEnum; + } + class RemapNumberDto { + constructor( + number?: number, + fromLow?: number, + fromHigh?: number, + toLow?: number, + toHigh?: number + ); + /** + * Number to remap + * @default 0.5 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + number: number; + /** + * First number range min + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + fromLow: number; + /** + * Map to range min + * @default 1 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + fromHigh: number; + /** + * First number range max + * @default 1 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + toLow: number; + /** + * Map to range max + * @default 2 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + toHigh: number; + } + class RandomNumberDto { + constructor(low?: number, high?: number); + /** + * Low range of random value + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + low: number; + /** + * High range of random value + * @default 1 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + high: number; + } + class RandomNumbersDto { + constructor(low?: number, high?: number, count?: number); + /** + * Low range of random value + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + low: number; + /** + * High range of random value + * @default 1 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + high: number; + /** + * Number of produced random values + * @default 10 + * @minimum -Infinity + * @maximum Infinity + * @step 1 + */ + count: number; + } + class ToFixedDto { + constructor(number?: number, decimalPlaces?: number); + /** + * Number to round + * @default undefined + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + number: number; + /** + * Number of decimal places + * @default 2 + * @minimum -Infinity + * @maximum Infinity + * @step 1 + */ + decimalPlaces: number; + } + class ClampDto { + constructor(number?: number, min?: number, max?: number); + /** + * Number to clamp + * @default 0.5 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + number: number; + /** + * Minimum value + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + min: number; + /** + * Maximum value + * @default 1 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + max: number; + } + class LerpDto { + constructor(start?: number, end?: number, t?: number); + /** + * Start value + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + start: number; + /** + * End value + * @default 1 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + end: number; + /** + * Interpolation value (0-1) + * @default 0.5 + * @minimum -Infinity + * @maximum Infinity + * @step 0.01 + */ + t: number; + } + class InverseLerpDto { + constructor(start?: number, end?: number, value?: number); + /** + * Start value + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + start: number; + /** + * End value + * @default 1 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + end: number; + /** + * Value to find t for + * @default 0.5 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + value: number; + } + class WrapDto { + constructor(number?: number, min?: number, max?: number); + /** + * Number to wrap + * @default 1.5 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + number: number; + /** + * Minimum value + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + min: number; + /** + * Maximum value + * @default 1 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + max: number; + } + class PingPongDto { + constructor(t?: number, length?: number); + /** + * Time value + * @default 0.5 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + t: number; + /** + * Length of ping pong + * @default 1 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + length: number; + } + class MoveTowardsDto { + constructor(current?: number, target?: number, maxDelta?: number); + /** + * Current value + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + current: number; + /** + * Target value + * @default 1 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + target: number; + /** + * Maximum change amount + * @default 0.1 + * @minimum -Infinity + * @maximum Infinity + * @step 0.01 + */ + maxDelta: number; + } + } + declare namespace Mesh { + class SignedDistanceFromPlaneToPointDto { + constructor(point?: Base.Point3, plane?: Base.TrianglePlane3); + /** + * Point from which to find the distance + * @default undefined + */ + point?: Base.Point3; + /** + * Triangle plane to which the distance is calculated + * @default undefined + */ + plane?: Base.TrianglePlane3; + } + class TriangleDto { + constructor(triangle?: Base.Triangle3); + /** + * Triangle to be used + * @default undefined + */ + triangle?: Base.Triangle3; + } + class TriangleToleranceDto { + constructor(triangle?: Base.Triangle3); + /** + * Triangle to be used + * @default undefined + */ + triangle?: Base.Triangle3; + /** + * Tolerance for the calculation + * @default 1e-7 + * @minimum -Infinity + * @maximum Infinity + * @step 1e-7 + */ + tolerance?: number; + } + class TriangleTriangleToleranceDto { + constructor( + triangle1?: Base.Triangle3, + triangle2?: Base.Triangle3, + tolerance?: number + ); + /** + * First triangle + * @default undefined + */ + triangle1?: Base.Triangle3; + /** + * Second triangle + * @default undefined + */ + triangle2?: Base.Triangle3; + /** + * Tolerance for the calculation + * @default 1e-7 + * @minimum -Infinity + * @maximum Infinity + * @step 1e-7 + */ + tolerance?: number; + } + class MeshMeshToleranceDto { + constructor(mesh1?: Base.Mesh3, mesh2?: Base.Mesh3, tolerance?: number); + /** + * First mesh + * @default undefined + */ + mesh1?: Base.Mesh3; + /** + * Second mesh + * @default undefined + */ + mesh2?: Base.Mesh3; + /** + * Tolerance for the calculation + * @default 1e-7 + * @minimum -Infinity + * @maximum Infinity + * @step 1e-7 + */ + tolerance?: number; + } + } + declare namespace Point { + class PointDto { + constructor(point?: Base.Point3); + /** + * Point + * @default undefined + */ + point: Base.Point3; + } + class PointXYZDto { + constructor(x?: number, y?: number, z?: number); + /** + * Point + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + x: number; + /** + * Point + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + y: number; + /** + * Point + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + z: number; + } + class PointXYDto { + constructor(x?: number, y?: number); + /** + * Point + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + x: number; + /** + * Point + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + y: number; + } + class PointsDto { + constructor(points?: Base.Point3[]); + /** + * Points + * @default undefined + */ + points: Base.Point3[]; + } + class TwoPointsDto { + constructor(point1?: Base.Point3, point2?: Base.Point3); + /** + * Point 1 + * @default undefined + */ + point1: Base.Point3; + /** + * Point 2 + * @default undefined + */ + point2: Base.Point3; + } + class DrawPointDto { + /** + * Provide options without default values + */ + constructor( + point?: Base.Point3, + opacity?: number, + size?: number, + colours?: string | string[], + updatable?: boolean, + pointMesh?: T + ); + /** + * Point + * @default undefined + */ + point: Base.Point3; + /** + * Value between 0 and 1 + * @default 1 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + opacity: number; + /** + * Size of the point + * @default 3 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + size: number; + /** + * Hex colour string + * @default #444444 + */ + colours: string | string[]; + /** + * Indicates wether the position of this point will change in time + * @default false + */ + updatable: boolean; + /** + * Point mesh variable in case it already exists and needs updating + * @default undefined + */ + pointMesh?: T; + } + class DrawPointsDto { + /** + * Provide options without default values + */ + constructor( + points?: Base.Point3[], + opacity?: number, + size?: number, + colours?: string | string[], + updatable?: boolean, + pointsMesh?: T + ); + /** + * Point + * @default undefined + */ + points: Base.Point3[]; + /** + * Value between 0 and 1 + * @default 1 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + opacity: number; + /** + * Size of the points + * @default 0.1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + size: number; + /** + * Hex colour string or collection of strings + * @default #444444 + */ + colours: string | string[]; + /** + * Indicates wether the position of this point will change in time + * @default false + */ + updatable: boolean; + /** + * Points mesh variable in case it already exists and needs updating + * @default undefined + */ + pointsMesh?: T; + } + class TransformPointDto { + constructor( + point?: Base.Point3, + transformation?: Base.TransformMatrixes + ); + /** + * Point to transform + * @default undefined + */ + point: Base.Point3; + /** + * Transformation matrix or a list of transformation matrixes + * @default undefined + */ + transformation: Base.TransformMatrixes; + } + class TransformPointsDto { + constructor( + points?: Base.Point3[], + transformation?: Base.TransformMatrixes + ); + /** + * Points to transform + * @default undefined + */ + points: Base.Point3[]; + /** + * Transformation matrix or a list of transformation matrixes + * @default undefined + */ + transformation: Base.TransformMatrixes; + } + class TranslatePointsWithVectorsDto { + constructor(points?: Base.Point3[], translations?: Base.Vector3[]); + /** + * Points to transform + * @default undefined + */ + points: Base.Point3[]; + /** + * Translation vectors for each point + * @default undefined + */ + translations: Base.Vector3[]; + } + class TranslatePointsDto { + constructor(points?: Base.Point3[], translation?: Base.Vector3); + /** + * Points to transform + * @default undefined + */ + points: Base.Point3[]; + /** + * Translation vector with x, y and z values + * @default undefined + */ + translation: Base.Vector3; + } + class TranslateXYZPointsDto { + constructor(points?: Base.Point3[], x?: number, y?: number, z?: number); + /** + * Points to transform + * @default undefined + */ + points: Base.Point3[]; + /** + * X vector value + * @default 0 + */ + x: number; + /** + * Y vector value + * @default 1 + */ + y: number; + /** + * Z vector value + * @default 0 + */ + z: number; + } + class ScalePointsCenterXYZDto { + constructor( + points?: Base.Point3[], + center?: Base.Point3, + scaleXyz?: Base.Vector3 + ); + /** + * Points to transform + * @default undefined + */ + points: Base.Point3[]; + /** + * The center from which the scaling is applied + * @default [0, 0, 0] + */ + center: Base.Point3; + /** + * Scaling factors for each axis [1, 2, 1] means that Y axis will be scaled 200% and both x and z axis will remain on 100% + * @default [1, 1, 1] + */ + scaleXyz: Base.Vector3; + } + class StretchPointsDirFromCenterDto { + constructor( + points?: Base.Point3[], + center?: Base.Point3, + direction?: Base.Vector3, + scale?: number + ); + /** + * Points to transform + * @default undefined + */ + points?: Base.Point3[]; + /** + * The center from which the scaling is applied + * @default [0, 0, 0] + */ + center?: Base.Point3; + /** + * Stretch direction vector + * @default [0, 0, 1] + */ + direction?: Base.Vector3; + /** + * The scale factor to apply along the direction vector. 1.0 means no change. + * @default 2 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + scale?: number; + } + class RotatePointsCenterAxisDto { + constructor( + points?: Base.Point3[], + angle?: number, + axis?: Base.Vector3, + center?: Base.Point3 + ); + /** + * Points to transform + * @default undefined + */ + points: Base.Point3[]; + /** + * Angle of rotation in degrees + * @default 90 + * @minimum -Infinity + * @maximum Infinity + * @step 1 + */ + angle: number; + /** + * Axis vector for rotation + * @default [0, 1, 0] + */ + axis: Base.Vector3; + /** + * The center from which the axis is pointing + * @default [0, 0, 0] + */ + center: Base.Point3; + } + class TransformsForPointsDto { + constructor( + points?: Base.Point3[], + transformation?: Base.TransformMatrixes[] + ); + /** + * Points to transform + * @default undefined + */ + points: Base.Point3[]; + /** + * Transformations that have to match nr of points + * @default undefined + */ + transformation: Base.TransformMatrixes[]; + } + class ThreePointsNormalDto { + constructor( + point1?: Base.Point3, + point2?: Base.Point3, + point3?: Base.Point3, + reverseNormal?: boolean + ); + /** + * Point 1 + * @default undefined + */ + point1: Base.Point3; + /** + * Point 2 + * @default undefined + */ + point2: Base.Point3; + /** + * Point 3 + * @default undefined + */ + point3: Base.Point3; + /** + * Reverse normal direction + * @default false + */ + reverseNormal: boolean; + } + class ThreePointsToleranceDto { + constructor( + start?: Base.Point3, + center?: Base.Point3, + end?: Base.Point3, + tolerance?: number + ); + /** + * Start point + * @default undefined + */ + start?: Base.Point3; + /** + * Center point + * @default undefined + */ + center?: Base.Point3; + /** + * End point + * @default undefined + */ + end?: Base.Point3; + /** + * Tolerance for the calculation + * @default 1e-7 + * @minimum -Infinity + * @maximum Infinity + * @step 1e-7 + */ + tolerance: number; + } + class PointsMaxFilletsHalfLineDto { + constructor( + points?: Base.Point3[], + checkLastWithFirst?: boolean, + tolerance?: number + ); + /** + * Points to transform + * @default undefined + */ + points?: Base.Point3[]; + /** + * Check first and last point for duplicates + * @default false + */ + checkLastWithFirst?: boolean; + /** + * Tolerance for the calculation + * @default 1e-7 + * @minimum -Infinity + * @maximum Infinity + * @step 1e-7 + */ + tolerance?: number; + } + class RemoveConsecutiveDuplicatesDto { + constructor( + points?: Base.Point3[], + tolerance?: number, + checkFirstAndLast?: boolean + ); + /** + * Points to transform + * @default undefined + */ + points: Base.Point3[]; + /** + * Tolerance for removing duplicates + * @default 1e-7 + * @minimum 0 + * @maximum Infinity + * @step 1e-7 + */ + tolerance: number; + /** + * Check first and last point for duplicates + */ + checkFirstAndLast: boolean; + } + class ClosestPointFromPointsDto { + constructor(points?: Base.Point3[], point?: Base.Point3); + /** + * Points to transform + * @default undefined + */ + points: Base.Point3[]; + /** + * Transformation matrix or a list of transformation matrixes + * @default undefined + */ + point: Base.Point3; + } + class TwoPointsToleranceDto { + constructor( + point1?: Base.Point3, + point2?: Base.Point3, + tolerance?: number + ); + /** + * First point to compare + * @default undefined + */ + point1?: Base.Point3; + /** + * Second point to compare + * @default undefined + */ + point2?: Base.Point3; + /** + * Tolerance for the calculation + * @default 1e-7 + * @minimum -Infinity + * @maximum Infinity + * @step 1e-7 + */ + tolerance?: number; + } + class StartEndPointsDto { + constructor(startPoint?: Base.Point3, endPoint?: Base.Point3); + /** + * Start point + * @default undefined + */ + startPoint: Base.Point3; + /** + * End point + * @default undefined + */ + endPoint: Base.Point3; + } + class StartEndPointsListDto { + constructor(startPoint?: Base.Point3, endPoints?: Base.Point3[]); + /** + * Start point + * @default undefined + */ + startPoint: Base.Point3; + /** + * End point + * @default undefined + */ + endPoints: Base.Point3[]; + } + class MultiplyPointDto { + constructor(point?: Base.Point3, amountOfPoints?: number); + /** + * Point for multiplication + * @default undefined + */ + point: Base.Point3; + /** + * Number of points to create in the list + * @default undefined + */ + amountOfPoints: number; + } + class SpiralDto { + constructor( + radius?: number, + numberPoints?: number, + widening?: number, + factor?: number, + phi?: number + ); + /** + * Identifies phi angle + * @default 0.9 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + phi: number; + /** + * Identifies how many points will be created + * @default 200 + * @minimum 0 + * @maximum Infinity + * @step 10 + */ + numberPoints: number; + /** + * Widening factor of the spiral + * @default 3 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + widening: number; + /** + * Radius of the spiral + * @default 6 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + radius: number; + /** + * Factor of the spiral + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + factor: number; + } + class HexGridScaledToFitDto { + constructor( + wdith?: number, + height?: number, + nrHexagonsU?: number, + nrHexagonsV?: number, + centerGrid?: boolean, + pointsOnGround?: boolean + ); + /** Total desired width for the grid area. The hexagon size will be derived from this and nrHexagonsU. + * @default 10 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + width?: number; + /** Total desired height for the grid area. Note: due to hexagon geometry, the actual grid height might differ slightly if maintaining regular hexagons based on width. + * @default 10 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + height?: number; + /** Number of hexagons desired in width. + * @default 10 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + nrHexagonsInWidth?: number; + /** Number of hexagons desired in height. + * @default 10 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + nrHexagonsInHeight?: number; + /** If true, the hexagons will be oriented with their flat sides facing up and down. + * @default false + */ + flatTop?: boolean; + /** If true, shift the entire grid up by half hex height. + * @default false + */ + extendTop?: boolean; + /** If true, shift the entire grid down by half hex height. + * @default false + */ + extendBottom?: boolean; + /** If true, shift the entire grid left by half hex width. + * @default false + */ + extendLeft?: boolean; + /** If true, shift the entire grid right by half hex width. + * @default false + */ + extendRight?: boolean; + /** If true, the grid center (based on totalWidth/totalHeight) will be at [0,0,0]. + * @default false + */ + centerGrid?: boolean; + /** If true, swaps Y and Z coordinates and sets Y to 0, placing points on the XZ ground plane. + * @default false + */ + pointsOnGround?: boolean; + } + class HexGridCentersDto { + constructor( + nrHexagonsX?: number, + nrHexagonsY?: number, + radiusHexagon?: number, + orientOnCenter?: boolean, + pointsOnGround?: boolean + ); + /** + * Number of hexagons on Y direction + * @default 21 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + nrHexagonsY: number; + /** + * Number of Hexagons on Z direction + * @default 21 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + nrHexagonsX: number; + /** + * radius of a single hexagon + * @default 0.2 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + radiusHexagon: number; + /** + * Orient hexagon points grid on center + * @default false + */ + orientOnCenter: boolean; + /** + * Orient points on the ground + * @default false + */ + pointsOnGround: boolean; + } + } + declare namespace Polyline { + class PolylineCreateDto { + /** + * Provide options without default values + */ + constructor(points?: Base.Point3[], isClosed?: boolean); + /** + * Points of the polyline + * @default undefined + */ + points?: Base.Point3[]; + /** + * Can contain is closed information + * @default false + */ + isClosed?: boolean; + } + class PolylinePropertiesDto { + /** + * Provide options without default values + */ + constructor(points?: Base.Point3[], isClosed?: boolean); + /** + * Points of the polyline + * @default undefined + */ + points?: Base.Point3[]; + /** + * Can contain is closed information + * @default false + */ + isClosed?: boolean; + /** + * Optional polyline color + * @default #444444 + */ + color?: string | number[]; + } + class PolylineDto { + constructor(polyline?: PolylinePropertiesDto); + /** + * Polyline with points + * @default undefined + */ + polyline?: PolylinePropertiesDto; + } + class PolylinesDto { + constructor(polylines?: PolylinePropertiesDto[]); + /** + * Polylines array + * @default undefined + */ + polylines?: PolylinePropertiesDto[]; + } + class TransformPolylineDto { + constructor( + polyline?: PolylinePropertiesDto, + transformation?: Base.TransformMatrixes + ); + /** + * Polyline to transform + * @default undefined + */ + polyline?: PolylinePropertiesDto; + /** + * Transformation matrix or a list of transformation matrixes + * @default undefined + */ + transformation?: Base.TransformMatrixes; + } + class DrawPolylineDto { + /** + * Provide options without default values + */ + constructor( + polyline?: PolylinePropertiesDto, + opacity?: number, + colours?: string | string[], + size?: number, + updatable?: boolean, + polylineMesh?: T + ); + /** + * Polyline + * @default undefined + */ + polyline?: PolylinePropertiesDto; + /** + * Value between 0 and 1 + * @default 1 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + opacity?: number; + /** + * Hex colour string + * @default #444444 + */ + colours?: string | string[]; + /** + * Width of the polyline + * @default 3 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + size?: number; + /** + * Indicates wether the position of this polyline will change in time + * @default false + */ + updatable?: boolean; + /** + * Line mesh variable in case it already exists and needs updating + * @default undefined + */ + polylineMesh?: T; + } + class DrawPolylinesDto { + /** + * Provide options without default values + */ + constructor( + polylines?: PolylinePropertiesDto[], + opacity?: number, + colours?: string | string[], + size?: number, + updatable?: boolean, + polylinesMesh?: T + ); + /** + * Polylines + * @default undefined + */ + polylines?: PolylinePropertiesDto[]; + /** + * Value between 0 and 1 + * @default 1 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + opacity?: number; + /** + * Hex colour string + * @default #444444 + */ + colours?: string | string[]; + /** + * Width of the polyline + * @default 3 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + size?: number; + /** + * Indicates wether the position of this polyline will change in time + * @default false + */ + updatable?: boolean; + /** + * Polyline mesh variable in case it already exists and needs updating + * @default undefined + */ + polylinesMesh?: T; + } + class SegmentsToleranceDto { + constructor(segments?: Base.Segment3[]); + /** + * Segments array + * @default undefined + */ + segments?: Base.Segment3[]; + /** + * Tolerance for the calculation + * @default 1e-5 + * @minimum -Infinity + * @maximum Infinity + * @step 1e-5 + */ + tolerance?: number; + } + class PolylineToleranceDto { + constructor(polyline?: PolylinePropertiesDto, tolerance?: number); + /** + * Polyline to check + * @default undefined + */ + polyline?: PolylinePropertiesDto; + /** + * Tolerance for the calculation + * @default 1e-5 + * @minimum -Infinity + * @maximum Infinity + * @step 1e-5 + */ + tolerance?: number; + } + class TwoPolylinesToleranceDto { + constructor( + polyline1?: PolylinePropertiesDto, + polyline2?: PolylinePropertiesDto, + tolerance?: number + ); + /** + * First polyline to check + * @default undefined + */ + polyline1?: PolylinePropertiesDto; + /** + * Second polyline to check + * @default undefined + */ + polyline2?: PolylinePropertiesDto; + /** + * Tolerance for the calculation + * @default 1e-5 + * @minimum -Infinity + * @maximum Infinity + * @step 1e-5 + */ + tolerance?: number; + } + } + declare namespace Text { + class TextDto { + constructor(text?: string); + /** + * The text + * @default Hello World + */ + text: string; + } + class TextSplitDto { + constructor(text?: string, separator?: string); + /** + * Text to split + * @default a,b,c + */ + text: string; + /** + * Text to split by + * @default , + */ + separator: string; + } + class TextReplaceDto { + constructor(text?: string, search?: string, replaceWith?: string); + /** + * Text to replace + * @default a-c + */ + text: string; + /** + * Text to search for + * @default - + */ + search: string; + /** + * Text to replace found occurences + * @default b + */ + replaceWith: string; + } + class TextJoinDto { + constructor(list?: string[], separator?: string); + /** + * Text to join + * @default undefined + */ + list: string[]; + /** + * Text to join by + * @default , + */ + separator: string; + } + class ToStringDto { + constructor(item?: T); + /** + * Item to stringify + * @default undefined + */ + item: T; + } + class ToStringEachDto { + constructor(list?: T[]); + /** + * Item to stringify + * @default undefined + */ + list: T[]; + } + class TextFormatDto { + constructor(text?: string, values?: string[]); + /** + * Text to format + * @default Hello {0} + */ + text: string; + /** + * Values to format + * @default ["World"] + */ + values: string[]; + } + class TextSearchDto { + constructor(text?: string, search?: string); + /** + * Text to search in + * @default hello world + */ + text: string; + /** + * Text to search for + * @default world + */ + search: string; + } + class TextSubstringDto { + constructor(text?: string, start?: number, end?: number); + /** + * Text to extract from + * @default hello world + */ + text: string; + /** + * Start index + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + start: number; + /** + * End index + * @default 5 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + end?: number; + } + class TextIndexDto { + constructor(text?: string, index?: number); + /** + * Text to get character from + * @default hello + */ + text: string; + /** + * Index of character + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + index: number; + } + class TextPadDto { + constructor(text?: string, length?: number, padString?: string); + /** + * Text to pad + * @default x + */ + text: string; + /** + * Target length + * @default 3 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + length: number; + /** + * String to pad with + * @default a + */ + padString: string; + } + class TextRepeatDto { + constructor(text?: string, count?: number); + /** + * Text to repeat + * @default ha + */ + text: string; + /** + * Number of repetitions + * @default 3 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + count: number; + } + class TextConcatDto { + constructor(texts?: string[]); + /** + * Texts to concatenate + * @default ["hello", " ", "world"] + */ + texts: string[]; + } + class TextRegexDto { + constructor(text?: string, pattern?: string, flags?: string); + /** + * Text to search in + * @default hello123world + */ + text: string; + /** + * Regular expression pattern + * @default [0-9]+ + */ + pattern: string; + /** + * Regular expression flags (g, i, m, s, u, y) + * @default g + */ + flags: string; + } + class TextRegexReplaceDto { + constructor( + text?: string, + pattern?: string, + flags?: string, + replaceWith?: string + ); + /** + * Text to search in + * @default hello123world456 + */ + text: string; + /** + * Regular expression pattern + * @default [0-9]+ + */ + pattern: string; + /** + * Regular expression flags (g, i, m, s, u, y) + * @default g + */ + flags: string; + /** + * Text to replace matches with + * @default X + */ + replaceWith: string; + } + class VectorCharDto { + constructor( + char?: string, + xOffset?: number, + yOffset?: number, + height?: number, + extrudeOffset?: number + ); + /** + * The text + * @default A + */ + char: string; + /** + * The x offset + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + xOffset?: number; + /** + * The y offset + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + yOffset?: number; + /** + * The height of the text + * @default 1 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + height?: number; + /** + * The extrude offset + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + extrudeOffset?: number; + } + class VectorTextDto { + constructor( + text?: string, + xOffset?: number, + yOffset?: number, + height?: number, + lineSpacing?: number, + letterSpacing?: number, + align?: Base.horizontalAlignEnum, + extrudeOffset?: number, + centerOnOrigin?: boolean + ); + /** + * The text + * @default Hello World + */ + text?: string; + /** + * The x offset + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + xOffset?: number; + /** + * The y offset + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + yOffset?: number; + /** + * The height of the text + * @default 1 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + height?: number; + /** + * The line spacing + * @default 1.4 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + lineSpacing?: number; + /** + * The letter spacing offset + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + letterSpacing?: number; + /** + * The extrude offset + * @default left + */ + align?: Base.horizontalAlignEnum; + /** + * The extrude offset + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + extrudeOffset?: number; + /** + * Will center text on 0, 0, 0 + * @default false + */ + centerOnOrigin?: boolean; + } + } + declare namespace Transforms { + class RotationCenterAxisDto { + constructor(angle?: number, axis?: Base.Vector3, center?: Base.Point3); + /** + * Angle of rotation in degrees + * @default 90 + * @minimum -Infinity + * @maximum Infinity + * @step 1 + */ + angle: number; + /** + * Axis vector for rotation + * @default [0, 1, 0] + */ + axis: Base.Vector3; + /** + * The center from which the axis is pointing + * @default [0, 0, 0] + */ + center: Base.Point3; + } + class RotationCenterDto { + constructor(angle?: number, center?: Base.Point3); + /** + * Angle of rotation in degrees + * @default 90 + * @minimum -Infinity + * @maximum Infinity + * @step 1 + */ + angle: number; + /** + * The center from which the axis is pointing + * @default [0, 0, 0] + */ + center: Base.Point3; + } + class RotationCenterYawPitchRollDto { + constructor( + yaw?: number, + pitch?: number, + roll?: number, + center?: Base.Point3 + ); + /** + * Yaw angle (Rotation around X) in degrees + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 1 + */ + yaw: number; + /** + * Pitch angle (Rotation around Y) in degrees + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 1 + */ + pitch: number; + /** + * Roll angle (Rotation around Z) in degrees + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 1 + */ + roll: number; + /** + * The center from which the rotations are applied + * @default [0, 0, 0] + */ + center: Base.Point3; + } + class ScaleXYZDto { + constructor(scaleXyz?: Base.Vector3); + /** + * Scaling factors for each axis [1, 2, 1] means that Y axis will be scaled 200% and both x and z axis will remain on 100% + * @default [1, 1, 1] + */ + scaleXyz: Base.Vector3; + } + class StretchDirCenterDto { + constructor( + scale?: number, + center?: Base.Point3, + direction?: Base.Vector3 + ); + /** The center point around which to stretch. + * @default [0, 0, 0] + */ + center?: Base.Point3; + /** The direction vector along which to stretch. Does not need to be normalized initially. + * @default [0, 0, 1] + */ + direction?: Base.Vector3; + /** The scale factor to apply along the direction vector. 1.0 means no change. + * @default 2 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + scale?: number; + } + class ScaleCenterXYZDto { + constructor(center?: Base.Point3, scaleXyz?: Base.Vector3); + /** + * The center from which the scaling is applied + * @default [0, 0, 0] + */ + center: Base.Point3; + /** + * Scaling factors for each axis [1, 2, 1] means that Y axis will be scaled 200% and both x and z axis will remain on 100% + * @default [1, 1, 1] + */ + scaleXyz: Base.Vector3; + } + class UniformScaleDto { + constructor(scale?: number); + /** + * Uniform scale factor for all x, y, z directions. 1 will keep everything on original size, 2 will scale 200%; + * @default 1 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + scale: number; + } + class UniformScaleFromCenterDto { + constructor(scale?: number, center?: Base.Point3); + /** + * Scale factor for all x, y, z directions. 1 will keep everything on original size, 2 will scale 200%; + * @default 1 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + scale: number; + /** + * Center position of the scaling + * @default [0, 0, 0] + */ + center: Base.Point3; + } + class TranslationXYZDto { + constructor(translation?: Base.Vector3); + /** + * Translation vector with [x, y, z] distances + * @default [0, 0, 0] + */ + translation: Base.Vector3; + } + class TranslationsXYZDto { + constructor(translations?: Base.Vector3[]); + /** + * Translation vectors with [x, y, z] distances + * @default undefined + */ + translations: Base.Vector3[]; + } + } + declare namespace Vector { + class TwoVectorsDto { + constructor(first?: number[], second?: number[]); + /** + * First vector + * @default undefined + */ + first: number[]; + /** + * Second vector + * @default undefined + */ + second: number[]; + } + class VectorBoolDto { + constructor(vector?: boolean[]); + /** + * Vector of booleans + * @default undefined + */ + vector: boolean[]; + } + class RemoveAllDuplicateVectorsDto { + constructor(vectors?: number[][], tolerance?: number); + /** + * Vectors array + * @default undefined + */ + vectors: number[][]; + /** + * Tolerance value + * @default 1e-7 + * @minimum 0 + * @maximum Infinity + */ + tolerance: number; + } + class RemoveConsecutiveDuplicateVectorsDto { + constructor( + vectors?: number[][], + checkFirstAndLast?: boolean, + tolerance?: number + ); + /** + * Vectors array + * @default undefined + */ + vectors: number[][]; + /** + * Check first and last vectors + * @default false + */ + checkFirstAndLast: boolean; + /** + * Tolerance value + * @default 1e-7 + * @minimum 0 + * @maximum Infinity + */ + tolerance: number; + } + class VectorsTheSameDto { + constructor(vec1?: number[], vec2?: number[], tolerance?: number); + /** + * First vector + * @default undefined + */ + vec1: number[]; + /** + * Second vector + * @default undefined + */ + vec2: number[]; + /** + * Tolerance value + * @default 1e-7 + * @minimum 0 + * @maximum Infinity + */ + tolerance: number; + } + class VectorDto { + constructor(vector?: number[]); + /** + * Vector array of numbers + * @default undefined + */ + vector: number[]; + } + class VectorStringDto { + constructor(vector?: string[]); + /** + * Vector array of stringified numbers + * @default undefined + */ + vector: string[]; + } + class Vector3Dto { + constructor(vector?: Base.Vector3); + /** + * Vector array of 3 numbers + * @default undefined + */ + vector: Base.Vector3; + } + class RangeMaxDto { + constructor(max?: number); + /** + * Maximum range boundary + * @default 10 + * @minimum -Infinity + * @maximum Infinity + * @step 1 + */ + max: number; + } + class VectorXYZDto { + constructor(x?: number, y?: number, z?: number); + /** + * X value of vector + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 0.5 + */ + x: number; + /** + * Y value of vector + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 0.5 + */ + y: number; + /** + * Z value of vector + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 0.5 + */ + z: number; + } + class VectorXYDto { + constructor(x?: number, y?: number); + /** + * X value of vector + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 0.5 + */ + x: number; + /** + * Y value of vector + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 0.5 + */ + y: number; + } + class SpanDto { + constructor(step?: number, min?: number, max?: number); + /** + * Step of the span + * @default 0.1 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + step: number; + /** + * Min value of the span + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 1 + */ + min: number; + /** + * Max value of the span + * @default 1 + * @minimum -Infinity + * @maximum Infinity + * @step 1 + */ + max: number; + } + class SpanEaseItemsDto { + constructor( + nrItems?: number, + min?: number, + max?: number, + ease?: Math.easeEnum + ); + /** + * Nr of items in the span + * @default 100 + * @minimum 2 + * @maximum Infinity + * @step 1 + */ + nrItems: number; + /** + * Min value of the span + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 1 + */ + min: number; + /** + * Max value of the span + * @default 1 + * @minimum -Infinity + * @maximum Infinity + * @step 1 + */ + max: number; + /** + * Ease type + * @default easeInSine + */ + ease: Math.easeEnum; + /** + * Indicates wether only intervals should be outputed. This will output step lengths between the values. + * @default false + */ + intervals: boolean; + } + class SpanLinearItemsDto { + constructor(nrItems?: number, min?: number, max?: number); + /** + * Nr of items in the span + * @default 100 + * @minimum 2 + * @maximum Infinity + * @step 1 + */ + nrItems: number; + /** + * Min value of the span + * @default 0 + * @minimum -Infinity + * @maximum Infinity + * @step 1 + */ + min: number; + /** + * Max value of the span + * @default 1 + * @minimum -Infinity + * @maximum Infinity + * @step 1 + */ + max: number; + } + class RayPointDto { + constructor(point?: Base.Point3, distance?: number, vector?: number[]); + /** + * Origin location of the ray + * @default undefined + */ + point: Base.Point3; + /** + * Distance to the point on the ray + * @default 1 + * @minimum -Infinity + * @maximum Infinity + * @step 1 + */ + distance: number; + /** + * Vector array of numbers + * @default undefined + */ + vector: number[]; + } + class VectorsDto { + constructor(vectors?: number[][]); + /** + * Vectors array + * @default undefined + */ + vectors: number[][]; + } + class FractionTwoVectorsDto { + constructor( + fraction?: number, + first?: Base.Vector3, + second?: Base.Vector3 + ); + /** + * Fraction number + * @default 0.5 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + fraction: number; + /** + * First vector + * @default undefined + */ + first: Base.Vector3; + /** + * Second vector + * @default undefined + */ + second: Base.Vector3; + } + class VectorScalarDto { + constructor(scalar?: number, vector?: number[]); + /** + * Scalar number + * @default 1 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + scalar: number; + /** + * Vector array of numbers + * @default undefined + */ + vector: number[]; + } + class TwoVectorsReferenceDto { + constructor( + reference?: number[], + first?: Base.Vector3, + second?: Base.Vector3 + ); + /** + * Reference vector + * @default undefined + */ + reference: number[]; + /** + * First vector + * @default undefined + */ + first: Base.Vector3; + /** + * Second vector + * @default undefined + */ + second: Base.Vector3; + } + } + declare namespace Asset { + class GetAssetDto { + constructor(fileName?: string); + /** + * The fileName associated with the projects asset + * @default undefined + */ + fileName: string; + } + class FetchDto { + constructor(url?: string); + /** + * The url to fetch from + * @default undefined + */ + url: string; + } + class FileDto { + constructor(file?: File | Blob); + /** + * Asset file that was loaded + * @default undefined + */ + file: File | Blob; + } + class FilesDto { + constructor(files?: (File | Blob)[]); + /** + * Asset file that was loaded + * @default undefined + */ + files: (File | Blob)[]; + } + class AssetFileDto { + constructor(assetFile?: File, hidden?: boolean); + /** + * Asset file that was loaded + * @default undefined + */ + assetFile: File; + /** + * Import the asset hidden + * @default false + */ + hidden: boolean; + } + class AssetFileByUrlDto { + constructor(assetFile?: string, rootUrl?: string, hidden?: boolean); + /** + * Asset file name + * @default undefined + */ + assetFile: string; + /** + * Root url + * @default undefined + */ + rootUrl: string; + /** + * Import the asset hidden + * @default false + */ + hidden: boolean; + } + class DownloadDto { + constructor( + fileName?: string, + content?: string | Blob, + extension?: string, + contentType?: string + ); + /** + * The file name for the downloaded file + * @default undefined + */ + fileName: string; + /** + * The content to download (string or Blob) + * @default undefined + */ + content: string | Blob; + /** + * The file extension (without dot) + * @default txt + */ + extension: string; + /** + * The content type for the file + * @default text/plain + */ + contentType: string; + } + } + declare namespace Base { + /** + * Defines how colors are mapped to entities when there are more entities than colors. + * - firstColorForAll: Uses the first color for all entities (legacy behavior) + * - lastColorRemainder: Maps colors 1:1, then uses last color for remaining entities + * - repeatColors: Cycles through colors in a repeating pattern + * - reversedColors: After exhausting colors, reverses direction (ping-pong pattern) + */ + enum colorMapStrategyEnum { + /** Uses the first color for all entities (legacy behavior) */ + firstColorForAll = "firstColorForAll", + /** Maps colors 1:1, then uses last color for remaining entities */ + lastColorRemainder = "lastColorRemainder", + /** Cycles through colors in a repeating pattern */ + repeatColors = "repeatColors", + /** After exhausting colors, reverses direction (ping-pong pattern) */ + reversedColors = "reversedColors", + } + enum skyboxEnum { + default = "default", + clearSky = "clearSky", + city = "city", + greyGradient = "greyGradient", + } + enum fogModeEnum { + none = "none", + exponential = "exponential", + exponentialSquared = "exponentialSquared", + linear = "linear", + } + enum horizontalAlignEnum { + left = "left", + center = "center", + right = "right", + } + enum verticalAlignmentEnum { + top = "top", + middle = "middle", + bottom = "bottom", + } + enum topBottomEnum { + top = "top", + bottom = "bottom", + } + enum basicAlignmentEnum { + topLeft = "topLeft", + topMid = "topMid", + topRight = "topRight", + midLeft = "midLeft", + midMid = "midMid", + midRight = "midRight", + bottomLeft = "bottomLeft", + bottomMid = "bottomMid", + bottomRight = "bottomRight", + } + type Color = string; + type ColorRGB = { + r: number; + g: number; + b: number; + }; + type Point2 = [number, number]; + type Vector2 = [number, number]; + type Point3 = [number, number, number]; + type Vector3 = [number, number, number]; + type Axis3 = { + origin: Base.Point3; + direction: Base.Vector3; + }; + type Axis2 = { + origin: Base.Point2; + direction: Base.Vector2; + }; + type Segment2 = [Point2, Point2]; + type Segment3 = [Point3, Point3]; + type TrianglePlane3 = { + normal: Vector3; + d: number; + }; + type Triangle3 = [Base.Point3, Base.Point3, Base.Point3]; + type Mesh3 = Triangle3[]; + type Plane3 = { + origin: Base.Point3; + normal: Base.Vector3; + direction: Base.Vector3; + }; + type BoundingBox = { + min: Base.Point3; + max: Base.Point3; + center?: Base.Point3; + width?: number; + height?: number; + length?: number; + }; + type Line2 = { + start: Base.Point2; + end: Base.Point2; + }; + type Line3 = { + start: Base.Point3; + end: Base.Point3; + }; + type Polyline3 = { + points: Base.Point3[]; + isClosed?: boolean; + }; + type Polyline2 = { + points: Base.Point2[]; + isClosed?: boolean; + }; + type VerbCurve = { + tessellate: (options: any) => any; + }; + type VerbSurface = { + tessellate: (options: any) => any; + }; + type TransformMatrix3x3 = [ + number, + number, + number, + number, + number, + number, + number, + number, + number + ]; + type TransformMatrixes3x3 = TransformMatrix3x3[]; + type TransformMatrix = [ + number, + number, + number, + number, + number, + number, + number, + number, + number, + number, + number, + number, + number, + number, + number, + number + ]; + type TransformMatrixes = TransformMatrix[]; + } + declare namespace CSV { + class ParseToArrayDto { + constructor( + csv?: string, + rowSeparator?: string, + columnSeparator?: string + ); + /** + * CSV text to parse + * @default name,age + John,30 + */ + csv: string; + /** + * Row separator (newline character) + * @default + + */ + rowSeparator?: string; + /** + * Column separator (delimiter) + * @default , + */ + columnSeparator?: string; + } + class ParseToJsonDto { + constructor( + csv?: string, + headerRow?: number, + dataStartRow?: number, + rowSeparator?: string, + columnSeparator?: string, + numberColumns?: string[] + ); + /** + * CSV text to parse + * @default name,age + John,30 + Jane,25 + */ + csv: string; + /** + * Row index where headers are located + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + headerRow?: number; + /** + * Row index where data starts + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + dataStartRow?: number; + /** + * Row separator (newline character) + * @default + + */ + rowSeparator?: string; + /** + * Column separator (delimiter) + * @default , + */ + columnSeparator?: string; + /** + * Column names that should be converted to numbers + * @default undefined + * @optional true + */ + numberColumns?: string[]; + } + class ParseToJsonWithHeadersDto { + constructor( + csv?: string, + headers?: string[], + dataStartRow?: number, + rowSeparator?: string, + columnSeparator?: string, + numberColumns?: string[] + ); + /** + * CSV text to parse + * @default John,30 + Jane,25 + */ + csv: string; + /** + * Custom header names to use + * @default ["name", "age"] + */ + headers: string[]; + /** + * Row index where data starts + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + dataStartRow?: number; + /** + * Row separator (newline character) + * @default + + */ + rowSeparator?: string; + /** + * Column separator (delimiter) + * @default , + */ + columnSeparator?: string; + /** + * Column names that should be converted to numbers + * @default undefined + * @optional true + */ + numberColumns?: string[]; + } + class QueryColumnDto { + constructor( + csv?: string, + column?: string, + headerRow?: number, + dataStartRow?: number, + rowSeparator?: string, + columnSeparator?: string, + asNumber?: boolean + ); + /** + * CSV text to query + * @default name,age + John,30 + Jane,25 + */ + csv: string; + /** + * Column name to query + * @default name + */ + column: string; + /** + * Row index where headers are located + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + headerRow?: number; + /** + * Row index where data starts + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + dataStartRow?: number; + /** + * Row separator (newline character) + * @default + + */ + rowSeparator?: string; + /** + * Column separator (delimiter) + * @default , + */ + columnSeparator?: string; + /** + * Convert column values to numbers + * @default false + */ + asNumber?: boolean; + } + class QueryRowsByValueDto { + constructor( + csv?: string, + column?: string, + value?: string, + headerRow?: number, + dataStartRow?: number, + rowSeparator?: string, + columnSeparator?: string, + numberColumns?: string[] + ); + /** + * CSV text to query + * @default name,age + John,30 + Jane,25 + */ + csv: string; + /** + * Column name to filter by + * @default age + */ + column: string; + /** + * Value to match + * @default 30 + */ + value: string; + /** + * Row index where headers are located + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + headerRow?: number; + /** + * Row index where data starts + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + dataStartRow?: number; + /** + * Row separator (newline character) + * @default + + */ + rowSeparator?: string; + /** + * Column separator (delimiter) + * @default , + */ + columnSeparator?: string; + /** + * Column names that should be converted to numbers + * @default undefined + * @optional true + */ + numberColumns?: string[]; + } + class ArrayToCsvDto { + constructor( + array?: (string | number | boolean | null | undefined)[][], + rowSeparator?: string, + columnSeparator?: string + ); + /** + * 2D array to convert + * @default [["name", "age"], ["John", "30"]] + */ + array: (string | number | boolean | null | undefined)[][]; + /** + * Row separator (newline character) + * @default + + */ + rowSeparator?: string; + /** + * Column separator (delimiter) + * @default , + */ + columnSeparator?: string; + } + class JsonToCsvDto> { + constructor( + json?: T[], + headers?: string[], + includeHeaders?: boolean, + rowSeparator?: string, + columnSeparator?: string + ); + /** + * Array of JSON objects to convert + * @default [{"name": "John", "age": "30"}] + */ + json: T[]; + /** + * Headers to use (in order) + * @default ["name", "age"] + */ + headers: string[]; + /** + * Whether to include headers in output + * @default true + */ + includeHeaders?: boolean; + /** + * Row separator (newline character) + * @default + + */ + rowSeparator?: string; + /** + * Column separator (delimiter) + * @default , + */ + columnSeparator?: string; + } + class JsonToCsvAutoDto> { + constructor( + json?: T[], + includeHeaders?: boolean, + rowSeparator?: string, + columnSeparator?: string + ); + /** + * Array of JSON objects to convert + * @default [{"name": "John", "age": "30"}] + */ + json: T[]; + /** + * Whether to include headers in output + * @default true + */ + includeHeaders?: boolean; + /** + * Row separator (newline character) + * @default + + */ + rowSeparator?: string; + /** + * Column separator (delimiter) + * @default , + */ + columnSeparator?: string; + } + class GetHeadersDto { + constructor( + csv?: string, + headerRow?: number, + rowSeparator?: string, + columnSeparator?: string + ); + /** + * CSV text to get headers from + * @default name,age + John,30 + */ + csv: string; + /** + * Row index where headers are located + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + headerRow?: number; + /** + * Row separator (newline character) + * @default + + */ + rowSeparator?: string; + /** + * Column separator (delimiter) + * @default , + */ + columnSeparator?: string; + } + class GetRowCountDto { + constructor( + csv?: string, + hasHeaders?: boolean, + dataStartRow?: number, + rowSeparator?: string, + columnSeparator?: string + ); + /** + * CSV text to count rows + * @default name,age + John,30 + Jane,25 + */ + csv: string; + /** + * Whether CSV has headers + * @default true + */ + hasHeaders?: boolean; + /** + * Row index where data starts (overrides hasHeaders if set) + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + dataStartRow?: number; + /** + * Row separator (newline character) + * @default + + */ + rowSeparator?: string; + /** + * Column separator (delimiter) + * @default , + */ + columnSeparator?: string; + } + } + declare namespace JSON { + class StringifyDto { + constructor(json?: any); + /** + * Stringify value + * @default undefined + */ + json: any; + } + class ParseDto { + constructor(text?: string); + /** + * Stringify value + * @default "[0, 0, 0]" + */ + text: string; + } + class QueryDto { + constructor(json?: any, query?: string); + /** + * query json structure + * @default undefined + */ + json: any; + /** + * query path + * @default undefined + */ + query: string; + } + class SetValueOnPropDto { + constructor(json?: any, value?: any, property?: string); + /** + * query json structure + * @default undefined + */ + json: any; + /** + * value to be set + * @default undefined + */ + value: any; + /** + * query json structure + * @default propName + */ + property: string; + } + class GetJsonFromArrayByFirstPropMatchDto { + constructor(jsonArray?: any[], property?: string, match?: any); + /** + * Array + * @default undefined + */ + jsonArray: any[]; + /** + * property to check + * @default propName + */ + property: string; + /** + * Value to match for the property + * @default undefined + */ + match: any; + } + class GetValueOnPropDto { + constructor(json?: any, property?: string); + /** + * query json structure + * @default undefined + */ + json: any; + /** + * query json structure + * @default propName + */ + property: string; + } + class SetValueDto { + constructor(json?: any, value?: any, path?: string, prop?: string); + /** + * query json structure + * @default undefined + */ + json: any; + /** + * value to be set + * @default undefined + */ + value: any; + /** + * query to json structure elements on which given prop has to be updated + * @default $.pathToParent + */ + path: string; + /** + * property to update + * @default propertyName + */ + prop: string; + } + class SetValuesOnPathsDto { + constructor(json?: any, values?: any[], paths?: string[], props?: []); + /** + * query json structure + * @default undefined + */ + json: any; + /** + * values to be set + * @default undefined + */ + values: any[]; + /** + * query json structures + * @default undefined + */ + paths: string[]; + /** + * properties to update + * @default undefined + */ + props: string[]; + } + class PathsDto { + constructor(json?: any, query?: string); + /** + * query json structure + * @default undefined + */ + json: any; + /** + * query path + * @default undefined + */ + query: string; + } + class JsonDto { + constructor(json?: any); + /** + * json value + * @default undefined + */ + json: any; + } + } + declare namespace Tag { + class DrawTagDto { + constructor(tag?: TagDto, updatable?: boolean, tagVariable?: TagDto); + /** + * Text tag to draw + */ + tag: TagDto; + /** + * Indicates that it is updatable tag + */ + updatable: boolean; + /** + * Optional existing tag in case it needs updating + */ + tagVariable?: TagDto; + } + class DrawTagsDto { + constructor( + tags?: TagDto[], + updatable?: boolean, + tagsVariable?: TagDto[] + ); + /** + * Text tag to draw + */ + tags: TagDto[]; + /** + * Indicates that it is updatable tag + */ + updatable: boolean; + /** + * Optional existing tag in case it needs updating + */ + tagsVariable?: TagDto[]; + } + /** + * Class representing a tag + */ + class TagDto { + constructor( + text?: string, + position?: Base.Point3, + colour?: string, + size?: number, + adaptDepth?: boolean, + needsUpdate?: boolean, + id?: string + ); + /** + * Text of the tag + */ + text: string; + /** + * Position of the tag + */ + position: Base.Point3; + /** + * Colour of the tag + */ + colour: string; + /** + * Text size + */ + size: number; + /** + * Make tags that are further away smaller + */ + adaptDepth: boolean; + /** + * Indicates if tag needs updating + */ + needsUpdate?: boolean; + /** + * Unique id of the tag + */ + id?: string; + } + } + declare namespace Time { + class PostFromIframe { + constructor(data?: any, targetOrigin?: string); + /** + * The data object to post + */ + data: any; + /** + * Thir party iframe origin url to which data should be posted + */ + targetOrigin: string; + } + } + declare namespace Verb { + class CurveDto { + constructor(curve?: any); + /** + * Nurbs curve + */ + curve: any; + } + class LineDto { + constructor(line?: Base.Line3); + /** + * Basic line + */ + line: Base.Line3; + } + class LinesDto { + constructor(lines?: Base.Line3[]); + /** + * Basic lines + */ + lines: Base.Line3[]; + } + class PolylineDto { + constructor(polyline?: Base.Polyline3); + /** + * Basic polyline + */ + polyline: Base.Polyline3; + } + class PolylinesDto { + constructor(polylines?: Base.Polyline3[]); + /** + * Basic polyline + */ + polylines: Base.Polyline3[]; + } + class CurvesDto { + constructor(curves?: any[]); + /** + * Nurbs curves + */ + curves: any[]; + } + class ClosestPointDto { + constructor(curve?: any, point?: Base.Point3); + /** + * Nurbs curve + */ + curve: any; + /** + * Point + */ + point: Base.Point3; + } + class ClosestPointsDto { + constructor(curve?: any, points?: Base.Point3[]); + /** + * Nurbs curve + */ + curve: any; + /** + * Points + */ + points: Base.Point3[]; + } + class BezierCurveDto { + constructor(points?: Base.Point3[], weights?: number[]); + /** + * Control points + */ + points: Base.Point3[]; + /** + * Weights + */ + weights: number[]; + } + class DrawCurveDto { + /** + * Provide options without default values + */ + constructor( + curve?: any, + opacity?: number, + colours?: string | string[], + size?: number, + updatable?: boolean, + curveMesh?: T + ); + /** + * Nurbs curve + */ + curve: any; + /** + * Value between 0 and 1 + */ + opacity: number; + /** + * Hex colour string + */ + colours: string | string[]; + /** + * Width of the polyline + */ + size: number; + /** + * Indicates wether the position of this curve will change in time + */ + updatable: boolean; + /** + * Curve mesh variable in case it already exists and needs updating + */ + curveMesh?: T; + } + class CurveParameterDto { + constructor(curve?: any, parameter?: number); + /** + * Nurbs curve + */ + curve: any; + /** + * Parameter on the curve + */ + parameter: number; + } + class CurvesParameterDto { + constructor(curves?: any[], parameter?: number); + /** + * Nurbs curve + */ + curves: any; + /** + * Parameter on the curve + */ + parameter: number; + } + class CurveTransformDto { + constructor(curve?: any, transformation?: Base.TransformMatrixes); + /** + * Nurbs curve + */ + curve: any; + /** + * Transformation matrixes + */ + transformation: Base.TransformMatrixes; + } + class CurvesTransformDto { + constructor(curves?: any[], transformation?: Base.TransformMatrixes); + /** + * Nurbs curve + */ + curves: any[]; + /** + * Transformation matrixes + */ + transformation: Base.TransformMatrixes; + } + class CurveToleranceDto { + constructor(curve?: any, tolerance?: number); + /** + * Nurbs curve + */ + curve: any; + /** + * Optional tolerance + */ + tolerance: number; + } + class CurveLengthToleranceDto { + constructor(curve?: any, length?: number, tolerance?: number); + /** + * Nurbs curve + */ + curve: any; + /** + * Length on the curve + */ + length: number; + /** + * Tolerance + */ + tolerance: number; + } + class CurveDerivativesDto { + constructor(curve?: any, parameter?: number, numDerivatives?: number); + /** + * Nurbs curve + */ + curve: any; + /** + * Number of derivatives + */ + numDerivatives: number; + /** + * Parameter on the curve + */ + parameter: number; + } + class CurveSubdivisionsDto { + constructor(curve?: any, subdivision?: number); + /** + * Nurbs curve + */ + curve: any; + /** + * Number of subdivisions + */ + subdivision: number; + } + class CurvesSubdivisionsDto { + constructor(curves?: any[], subdivision?: number); + /** + * Nurbs curves + */ + curves: any[]; + /** + * Number of subdivisions + */ + subdivision: number; + } + class CurvesDivideLengthDto { + constructor(curves?: any[], length?: number); + /** + * Nurbs curves + */ + curves: any[]; + /** + * Length of subdivisions + */ + length: number; + } + class CurveDivideLengthDto { + constructor(curve?: any, length?: number); + /** + * Nurbs curve + */ + curve: any; + /** + * Length of subdivisions + */ + length: number; + } + class DrawCurvesDto { + /** + * Provide options without default values + */ + constructor( + curves?: any[], + opacity?: number, + colours?: string | string[], + size?: number, + updatable?: boolean, + curvesMesh?: T + ); + /** + * Nurbs curves + */ + curves: any[]; + /** + * Value between 0 and 1 + */ + opacity: number; + /** + * Hex colour string + */ + colours: string | string[]; + /** + * Width of the polyline + */ + size: number; + /** + * Indicates wether the position of this polyline will change in time + */ + updatable: boolean; + /** + * Curve mesh variable in case it already exists and needs updating + */ + curvesMesh?: T; + } + class CurveNurbsDataDto { + constructor( + degree?: number, + weights?: number[], + knots?: number[], + points?: Base.Point3[] + ); + /** + * Nurbs curve degree + */ + degree: number; + /** + * Weights that identify strength that attracts curve to control points + */ + weights: number[]; + /** + * Knots of the Nurbs curve + */ + knots: number[]; + /** + * Control points of the nurbs curve + */ + points: Base.Point3[]; + } + class CurvePathDataDto { + constructor(degree?: number, points?: Base.Point3[]); + /** + * Nurbs curve degree + */ + degree: number; + /** + * Control points of the nurbs curve + */ + points: Base.Point3[]; + } + class EllipseDto { + constructor(ellipse?: any); + /** + * Nurbs ellipse + */ + ellipse: any; + } + class CircleDto { + constructor(circle?: any); + /** + * Nurbs circle + */ + circle: any; + } + class ArcDto { + constructor(arc?: any); + /** + * Nurbs arc + */ + arc: any; + } + class EllipseParametersDto { + constructor( + xAxis?: Base.Vector3, + yAxis?: Base.Vector3, + center?: Base.Point3 + ); + /** + * X axis of the circle + */ + xAxis: Base.Vector3; + /** + * Y axis of the circle + */ + yAxis: Base.Vector3; + /** + * Center of the circle + */ + center: Base.Point3; + } + class CircleParametersDto { + constructor( + xAxis?: Base.Vector3, + yAxis?: Base.Vector3, + radius?: number, + center?: Base.Point3 + ); + /** + * X axis of the circle + */ + xAxis: Base.Vector3; + /** + * Y axis of the circle + */ + yAxis: Base.Vector3; + /** + * Radius of the circle + */ + radius: number; + /** + * Center of the circle + */ + center: Base.Point3; + } + class ArcParametersDto { + constructor( + minAngle?: number, + maxAngle?: number, + xAxis?: Base.Vector3, + yAxis?: Base.Vector3, + radius?: number, + center?: Base.Point3 + ); + /** + * Minimum angle in degrees + */ + minAngle: number; + /** + * Maximum angle in degrees + */ + maxAngle: number; + /** + * X axis of the circle + */ + xAxis: Base.Vector3; + /** + * Y axis of the circle + */ + yAxis: Base.Vector3; + /** + * Radius of the circle + */ + radius: number; + /** + * Center of the circle + */ + center: Base.Point3; + } + class EllipseArcParametersDto { + constructor( + minAngle?: number, + maxAngle?: number, + xAxis?: Base.Vector3, + yAxis?: Base.Vector3, + center?: Base.Point3 + ); + /** + * Minimum angle in degrees + */ + minAngle: number; + /** + * Maximum angle in degrees + */ + maxAngle: number; + /** + * X axis of the circle + */ + xAxis: Base.Vector3; + /** + * Y axis of the circle + */ + yAxis: Base.Vector3; + /** + * Center of the circle + */ + center: Base.Point3; + } + class SurfaceDto { + constructor(surface?: any); + /** + * Nurbs surface + */ + surface: any; + } + class SurfaceTransformDto { + constructor(surface?: any, transformation?: Base.TransformMatrixes); + /** + * Nurbs surface + */ + surface: any; + /** + * Transformations + */ + transformation: Base.TransformMatrixes; + } + class SurfaceParameterDto { + constructor(surface?: any, parameter?: number, useV?: boolean); + /** + * Nurbs surface + */ + surface: any; + /** + * Parameter on the surface + */ + parameter: number; + /** + * Default parameter is on U direction, use V to switch + */ + useV: boolean; + } + class IsocurvesParametersDto { + constructor(surface?: any, parameters?: number[], useV?: boolean); + /** + * Nurbs surface + */ + surface: any; + /** + * Parameter on the surface + */ + parameters: number[]; + /** + * Default parameter is on U direction, use V to switch + */ + useV: boolean; + } + class IsocurveSubdivisionDto { + /** + * Provide undefined options + */ + constructor( + surface?: any, + useV?: boolean, + includeLast?: boolean, + includeFirst?: boolean, + isocurveSegments?: number + ); + /** + * Nurbs surface + */ + surface: any; + /** + * Default parameter is on U direction, use V to switch + */ + useV: boolean; + /** + * Check to include the last isocurve + */ + includeLast: boolean; + /** + * Check to include the first isocurve + */ + includeFirst: boolean; + /** + * Number of segments including surface start and end + */ + isocurveSegments: number; + } + class DerivativesDto { + constructor( + surface?: any, + u?: number, + v?: number, + numDerivatives?: number + ); + /** + * Nurbs surface + */ + surface: any; + /** + * U coordinate + */ + u: number; + /** + * V coordinate + */ + v: number; + /** + * Number of derivatives + */ + numDerivatives: number; + } + class SurfaceLocationDto { + constructor(surface?: any, u?: number, v?: number); + /** + * Nurbs surface + */ + surface: any; + /** + * U coordinate + */ + u: number; + /** + * V coordinate + */ + v: number; + } + class CornersDto { + constructor( + point1?: Base.Point3, + point2?: Base.Point3, + point3?: Base.Point3, + point4?: Base.Point3 + ); + /** + * Corner 1 + */ + point1: Base.Point3; + /** + * Corner 2 + */ + point2: Base.Point3; + /** + * Corner 3 + */ + point3: Base.Point3; + /** + * Corner 4 + */ + point4: Base.Point3; + } + class SurfaceParamDto { + constructor(surface?: any, point?: Base.Point3); + /** + * Nurbs surface + */ + surface: any; + /** + * Point + */ + point: Base.Point3; + } + class KnotsControlPointsWeightsDto { + constructor( + degreeU?: number, + degreeV?: number, + knotsU?: number[], + knotsV?: number[], + points?: Base.Point3[], + weights?: number[] + ); + /** + * U direction degree + */ + degreeU: number; + /** + * V direction degree + */ + degreeV: number; + /** + * U direction knots + */ + knotsU: number[]; + /** + * V direction knots + */ + knotsV: number[]; + /** + * Points + */ + points: Base.Point3[]; + /** + * Weights + */ + weights: number[]; + } + class LoftCurvesDto { + constructor(degreeV?: number, curves?: any[]); + /** + * V direction degree + */ + degreeV: number; + /** + * Nurbs curves + */ + curves: any[]; + } + class DrawSurfaceDto { + /** + * Provide options without default values + */ + constructor( + surface?: any, + opacity?: number, + colours?: string | string[], + updatable?: boolean, + hidden?: boolean, + surfaceMesh?: T, + drawTwoSided?: boolean, + backFaceColour?: string, + backFaceOpacity?: number + ); + /** + * Nurbs surface + */ + surface: any; + /** + * Value between 0 and 1 + */ + opacity: number; + /** + * Hex colour string + */ + colours: string | string[]; + /** + * Indicates wether the position of this surface will change in time + */ + updatable: boolean; + /** + * Should be hidden + */ + hidden: boolean; + /** + * Surface mesh variable in case it already exists and needs updating + */ + surfaceMesh?: T; + /** + * Draw two-sided faces with different colors for front and back. This helps visualize face orientation. + * @default true + */ + drawTwoSided: boolean; + /** + * Hex colour string for back face colour (negative side of the face). Only used when drawTwoSided is true. + * @default #0000ff + */ + backFaceColour: string; + /** + * Back face opacity value between 0 and 1. Only used when drawTwoSided is true. + * @default 1 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + backFaceOpacity: number; + } + class DrawSurfacesDto { + /** + * Provide options without default values + */ + constructor( + surfaces?: any[], + opacity?: number, + colours?: string | string[], + updatable?: boolean, + hidden?: boolean, + surfacesMesh?: T, + drawTwoSided?: boolean, + backFaceColour?: string, + backFaceOpacity?: number + ); + /** + * Nurbs surfaces + */ + surfaces: any[]; + /** + * Value between 0 and 1 + */ + opacity: number; + /** + * Hex colour string + */ + colours: string | string[]; + /** + * Indicates wether the position of these surfaces will change in time + */ + updatable: boolean; + /** + * Should be hidden + */ + hidden: boolean; + /** + * Surfaces mesh variable in case it already exists and needs updating + */ + surfacesMesh?: T; + /** + * Draw two-sided faces with different colors for front and back. This helps visualize face orientation. + * @default true + */ + drawTwoSided: boolean; + /** + * Hex colour string for back face colour (negative side of the face). Only used when drawTwoSided is true. + * @default #0000ff + */ + backFaceColour: string; + /** + * Back face opacity value between 0 and 1. Only used when drawTwoSided is true. + * @default 1 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + backFaceOpacity: number; + } + class DrawSurfacesColoursDto { + /** + * Provide options without default values + */ + constructor( + surfaces?: any[], + colours?: string[], + opacity?: number, + updatable?: boolean, + hidden?: boolean, + surfacesMesh?: T, + drawTwoSided?: boolean, + backFaceColour?: string, + backFaceOpacity?: number + ); + /** + * Nurbs surfaces + */ + surfaces: any[]; + /** + * Value between 0 and 1 + */ + opacity: number; + /** + * Hex colour strings, there has to be a colour for every single surface and lengths of arrays need to match + */ + colours: string | string[]; + /** + * Indicates wether the position of these surfaces will change in time + */ + updatable: boolean; + /** + * Indicates if surface should be hidden + */ + hidden: boolean; + /** + * Surfaces mesh variable in case it already exists and needs updating + */ + surfacesMesh?: T; + /** + * Draw two-sided faces with different colors for front and back. This helps visualize face orientation. + * @default true + */ + drawTwoSided: boolean; + /** + * Hex colour string for back face colour (negative side of the face). Only used when drawTwoSided is true. + * @default #0000ff + */ + backFaceColour: string; + /** + * Back face opacity value between 0 and 1. Only used when drawTwoSided is true. + * @default 1 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + backFaceOpacity: number; + } + class ConeAndCylinderParametersDto { + constructor( + axis?: Base.Vector3, + xAxis?: Base.Vector3, + base?: Base.Point3, + height?: number, + radius?: number + ); + /** + * Defines main axis of the cone + */ + axis: Base.Vector3; + /** + * X axis of the cone + */ + xAxis: Base.Vector3; + /** + * Base point for the cone + */ + base: Base.Point3; + /** + * Height of the cone + */ + height: number; + /** + * Radius of the cone + */ + radius: number; + } + class ConeDto { + constructor(cone?: any); + /** + * Conical Nurbs surface + */ + cone: any; + } + class CylinderDto { + constructor(cylinder?: any); + /** + * Cylindrical Nurbs surface + */ + cylinder: any; + } + class ExtrusionParametersDto { + constructor(profile?: any, direction?: Base.Vector3); + /** + * Profile Nurbs curve + */ + profile: any; + /** + * Direction vector + */ + direction: Base.Vector3; + } + class ExtrusionDto { + constructor(extrusion?: any); + /** + * Nurbs surface created through extrusion + */ + extrusion: any; + } + class SphericalParametersDto { + constructor(radius?: number, center?: number[]); + /** + * Radius of the sphere + */ + radius: number; + /** + * Center point + */ + center: number[]; + } + class SphereDto { + constructor(sphere?: any); + /** + * Spherical Nurbs surface + */ + sphere: any; + } + class RevolutionParametersDto { + constructor( + profile?: any, + center?: number[], + axis?: number[], + angle?: number + ); + /** + * Profile Nurbs curve + */ + profile: any; + /** + * Center point + */ + center: number[]; + /** + * Axis around which rotation will happen + */ + axis: number[]; + /** + * Angle at which to rotate in degrees + */ + angle: number; + } + class RevolutionDto { + constructor(revolution?: any); + /** + * Revolved Nurbs surface + */ + revolution: any; + } + class SweepParametersDto { + constructor(profile?: any, rail?: any); + /** + * Profile Nurbs curve + */ + profile: any; + /** + * Rail Nurbs curve + */ + rail: any; + } + class SweepDto { + constructor(sweep?: any); + /** + * Revolved Nurbs surface + */ + sweep: any; + } + class CurveCurveDto { + constructor(firstCurve?: any, secondCurve?: any, tolerance?: number); + /** + * First Nurbs curve + */ + firstCurve: any; + /** + * Second Nurbs curve + */ + secondCurve: number[]; + /** + * Optional tolerance parameter + */ + tolerance?: number; + } + class CurveSurfaceDto { + constructor(curve?: any, surface?: any, tolerance?: number); + /** + * Nurbs curve + */ + curve: any; + /** + * Nurbs surface + */ + surface: any; + /** + * Optional tolerance parameter + */ + tolerance?: number; + } + class SurfaceSurfaceDto { + constructor( + firstSurface?: any, + secondSurface?: any, + tolerance?: number + ); + /** + * Nurbs curve + */ + firstSurface: any; + /** + * Nurbs surface + */ + secondSurface: any; + /** + * Optional tolerance parameter + */ + tolerance?: number; + } + class CurveCurveIntersectionsDto { + constructor(intersections?: BaseTypes.CurveCurveIntersection[]); + /** + * Curve curve intersections + */ + intersections: BaseTypes.CurveCurveIntersection[]; + } + class CurveSurfaceIntersectionsDto { + constructor(intersections?: BaseTypes.CurveSurfaceIntersection[]); + /** + * Curve curve intersections + */ + intersections: BaseTypes.CurveSurfaceIntersection[]; + } + } + } + + declare namespace Models { + declare namespace Point { + declare class HexGridData { + centers: Base.Point3[]; + hexagons: Base.Point3[][]; + shortestDistEdge: number; + longestDistEdge: number; + maxFilletRadius: number; + } + } + declare namespace Text { + declare class VectorCharData { + constructor(width?: number, height?: number, paths?: Base.Point3[][]); + /** + * The width of the char + * @default undefined + */ + width?: number; + /** + * The height of the char + * @default undefined + */ + height?: number; + /** + * The segments of the char + * @default undefined + */ + paths?: Base.Point3[][]; + } + declare class VectorTextData { + constructor(width?: number, height?: number, chars?: VectorCharData[]); + /** + * The width of the char + * @default undefined + */ + width?: number; + /** + * The height of the char + * @default undefined + */ + height?: number; + /** + * The segments of the char + * @default undefined + */ + chars?: VectorCharData[]; + } + } + declare namespace OCCT { + declare class ShapeWithId { + id: string; + shape: U; + } + declare class ObjectDefinition { + compound?: U; + shapes?: ShapeWithId[]; + data?: M; + } + declare class TextWiresCharShapePart { + id?: string; + shapes?: { + compound?: T; + }; + } + declare class TextWiresDataDto { + type: string; + name: string; + compound?: T; + characters?: TextWiresCharShapePart[]; + width: number; + height: number; + center: Base.Point3; + } + } + } + + declare namespace Things { + declare namespace Enums { + declare class LodDto { + /** + * Level of detail + * @default low + */ + lod: lodEnum; + } + declare enum lodEnum { + low = "low", + middle = "middle", + high = "high", + } + } + declare namespace Architecture { + declare namespace Houses { + declare namespace ZenHideout { + declare class ZenHideoutData { + /** + * Type of the object being configured + */ + type: string; + /** + * Default name of the object + */ + name: string; + /** + * Original inputs + */ + originalInputs?: ZenHideoutDto; + /** + * Compounded shape representation of all of the geometric objects of the building + */ + compound?: T; + /** + * All the shapes of the building + */ + shapes?: Models.OCCT.ShapeWithId[]; + /** + * Representation of zen hideout parts that are useful for drawing the object efficiently + */ + drawingPart?: ZenHideoutDrawingPart; + /** + * Sandwitch parts that have inner and outer panels, can have windows and doors + */ + sandwitchPartsBetweenColumns?: Things.Architecture.SandwitchPart[]; + /** + * Corner part panels forming 90 degree angle + */ + cornerParts?: Things.Architecture.CornerPart[]; + /** + * Column parts of the building + */ + columnParts?: Things.Architecture.ColumnPart[]; + /** + * Roof parts of the building. Contain all the upper geometry, together with beams and columns. + */ + roofParts?: Things.Architecture.RoofPart[]; + /** + * Entrance corner part of the building, containing interior and exterior panels, staircase, and a corner window part + */ + entranceCorner?: Things.Architecture.CornerEntrancePart; + /** + * Terrace corner of the building, containing interior and exterior panels, staircase, and a corner window part + */ + entranceTerrace?: Things.Architecture.CornerEntrancePart; + /** + * Floor parts of the building + */ + floors?: Things.Architecture.FloorPart[]; + /** + * Ceiling parts of the building + */ + ceilings?: Things.Architecture.CeilingPart[]; + } + /** + * This defines useful compounded objects for representing zen hideout in optimal and fast way. + */ + declare class ZenHideoutDrawingPartShapes { + /** + * The representation of all window glass objects in the building + */ + windowGlassCompound?: T; + /** + * The representation of all glass frame objects in the building + */ + glassFramesCompound?: T; + /** + * The representation of all window frame objects in the building + */ + windowFrameCompound?: T; + /** + * The representation of all beam objects in the building + */ + beamsCompound?: T; + /** + * The representation of all column objects in the building + */ + columnsCompound?: T; + /** + * The representation of all exterior panels on the first floor + * of the building + */ + firstFloorExteriorPanelsCompound?: T; + /** + * The representation of all interior panels on the first floor + * of the building + */ + firstFloorInteriorPanelsCompound?: T; + /** + * The representation of all exterior panels on the roof + * of the building + */ + roofExteriorPanelsCompound?: T; + /** + * The representation of all interior panels on the roof + * of the building + */ + roofInteriorPanelsCompound?: T; + /** + * The representation of the first roof cover + * of the building + */ + roofCoverFirstCompound?: T; + /** + * The representation of the second roof cover + * of the building + */ + roofCoverSecondCompound?: T; + /** + * The representation of the floor + * of the building + */ + floorCompound?: T; + /** + * The representation of the ceiling + * of the building + */ + ceilingCompound?: T; + /** + * The representation of stairs + */ + stairsCompound?: T; + } + /** + * Information needed to draw the part in an optimal way + */ + declare class ZenHideoutDrawingPart { + /** + * Shapes that exist in the drawing part, T can represent opancascade geometry, + * babylonjs mesh, materials or other things that map to these drawing categories. + */ + shapes?: ZenHideoutDrawingPartShapes; + } + declare class ZenHideoutDtoBase { + widthFirstWing: T; + lengthFirstWing: T; + terraceWidth: T; + widthSecondWing: T; + lengthSecondWing: T; + heightWalls: T; + roofAngleFirstWing: T; + roofAngleSecondWing: T; + roofOffset: T; + roofInsideOverhang: T; + roofMaxDistAttachmentBeams: T; + roofAttachmentBeamWidth: T; + roofAttachmentBeamHeight: T; + roofOutsideOverhang: T; + columnSize: T; + ceilingBeamHeight: T; + ceilingBeamWidth: T; + nrCeilingBeamsBetweenColumns: T; + distBetweenColumns: T; + floorHeight: T; + groundLevel: T; + facadePanelThickness: T; + windowWidthOffset: T; + windowHeightOffset: T; + windowFrameThickness: T; + windowGlassFrameThickness: T; + lod: U; + rotation?: T; + origin?: V; + } + declare class ZenHideoutDto + implements + ZenHideoutDtoBase< + number, + Things.Enums.lodEnum, + Inputs.Base.Point3 + > + { + constructor( + widthFirstWing?: number, + lengthFirstWing?: number, + terraceWidth?: number, + widthSecondWing?: number, + lengthSecondWing?: number, + heightWalls?: number, + roofAngleFirstWing?: number, + roofAngleSecondWing?: number, + roofOffset?: number, + roofInsideOverhang?: number, + roofMaxDistAttachmentBeams?: number, + roofAttachmentBeamWidth?: number, + roofAttachmentBeamHeight?: number, + roofOutsideOverhang?: number, + columnSize?: number, + ceilingBeamHeight?: number, + ceilingBeamWidth?: number, + nrCeilingBeamsBetweenColumns?: number, + distBetweenColumns?: number, + floorHeight?: number, + groundLevel?: number, + facadePanelThickness?: number, + windowWidthOffset?: number, + windowHeightOffset?: number, + windowFrameThickness?: number, + windowGlassFrameThickness?: number, + lod?: Things.Enums.lodEnum, + skinOpacity?: number, + rotation?: number, + origin?: Inputs.Base.Point3 + ); + /** + * Width of the first wing of L shaped building + * @default 4 + * @minimum 3 + * @maximum Infinity + * @step 0.5 + */ + widthFirstWing: number; + /** + * Length of the first wing of L shaped building + * @default 10 + * @minimum 3 + * @maximum Infinity + * @step 0.5 + */ + lengthFirstWing: number; + /** + * Width of the terrace + * @default 3 + * @minimum 1 + * @maximum Infinity + * @step 0.25 + */ + terraceWidth: number; + /** + * Width of the second wing of L shaped building + * @default 5 + * @minimum 3 + * @maximum Infinity + * @step 0.5 + */ + widthSecondWing: number; + /** + * Length of the second wing of L shaped building + * @default 10 + * @minimum 3 + * @maximum Infinity + * @step 0.5 + */ + lengthSecondWing: number; + /** + * Height of the walls + * @default 3 + * @minimum 3 + * @maximum Infinity + * @step 0.1 + */ + heightWalls: number; + /** + * Height of the first wing end + * @default 15 + * @minimum 5 + * @maximum Infinity + * @step 5 + */ + roofAngleFirstWing: number; + /** + * Height of the first wing end + * @default 25 + * @minimum 5 + * @maximum Infinity + * @step 5 + */ + roofAngleSecondWing: number; + /** + * The offset to be applied to where the roof starts + * @default 0.5 + * @minimum 0.2 + * @maximum Infinity + * @step 0.25 + */ + roofOffset: number; + /** + * Roof overhang on the inside of the building (where the terrace is) + * @default 0.5 + * @minimum 0 + * @maximum Infinity + * @step 0.25 + */ + roofInsideOverhang: number; + /** + * Roof max distance between top attachment beams + * @default 0.8 + * @minimum 0.1 + * @maximum Infinity + * @step 0.25 + */ + roofMaxDistAttachmentBeams: number; + /** + * Roof attachment beam width + * @default 0.2 + * @minimum 0.01 + * @maximum Infinity + * @step 0.05 + */ + roofAttachmentBeamWidth: number; + /** + * Roof attachment beam height + * @default 0.05 + * @minimum 0.01 + * @maximum Infinity + * @step 0.05 + */ + roofAttachmentBeamHeight: number; + /** + * Roof overhang on the inside of the building + * @default 0.5 + * @minimum 0 + * @maximum Infinity + * @step 0.25 + */ + roofOutsideOverhang: number; + /** + * Column size + * @default 0.3 + * @minimum 0.01 + * @maximum Infinity + * @step 0.1 + */ + columnSize: number; + /** Ceiling beam height + * @default 0.25 + * @minimum 0.01 + * @maximum Infinity + * @step 0.05 + */ + ceilingBeamHeight: number; + /** Ceiling beam width + * @default 0.1 + * @minimum 0.01 + * @maximum Infinity + * @step 0.05 + */ + ceilingBeamWidth: number; + /** Nr ceiling beams between columns + * @default 3 + * @minimum 1 + * @maximum Infinity + * @step 1 + */ + nrCeilingBeamsBetweenColumns: number; + /** Distance between columns + * @default 2 + * @minimum 0.5 + * @maximum Infinity + * @step 0.25 + */ + distBetweenColumns: number; + /** The height of the floor + * @default 0.1 + * @minimum 0.1 + * @maximum Infinity + * @step 0.1 + */ + floorHeight: number; + /** ground level from the floor + * @default 0.6 + * @minimum 0.1 + * @maximum Infinity + * @step 0.1 + */ + groundLevel: number; + /** Facade panel thickness + * @default 0.05 + * @minimum 0.01 + * @maximum Infinity + * @step 0.01 + */ + facadePanelThickness: number; + /** Window width parameter + * @default 0.1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + windowWidthOffset: number; + /** Window bottom offset + * @default 0.2 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + windowHeightOffset: number; + /** Window frame thickness + * @default 0.1 + * @minimum 0.01 + * @maximum Infinity + * @step 0.01 + */ + windowFrameThickness: number; + /** Window glass frame thickness + * @default 0.05 + * @minimum 0.01 + * @maximum Infinity + * @step 0.01 + */ + windowGlassFrameThickness: number; + /** + * Level of detail to compute + * @default high + */ + lod: Things.Enums.lodEnum; + /** + * The opacity of the skin - only applied if lod is set to high + * @default 1 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + skinOpacity: number; + /** + * Rotation of the zen hideout + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 10 + */ + rotation: number; + /** + * Origin of the zen hideout + * @default [0, 0, 0] + */ + origin: Inputs.Base.Point3; + } + } + } + declare class BeamPart { + id?: string; + name?: string; + width?: number; + length?: number; + height?: number; + shapes?: { + beam?: T; + }; + } + declare class CeilingPart { + id?: string; + name?: string; + area?: number; + thickness?: number; + polygonPoints?: Inputs.Base.Point3[]; + shapes?: { + compound?: T; + }; + } + declare class ColumnPart { + id?: string; + name?: string; + width?: number; + length?: number; + height?: number; + shapes?: { + column?: T; + }; + } + declare class CornerEntranceDto { + /** + * Width first wing + * @default 1 + * @minimum 0.1 + * @maximum Infinity + * @step 0.1 + */ + widthFirstWing: number; + /** + * Width second wing + * @default 1 + * @minimum 0.1 + * @maximum Infinity + * @step 0.1 + */ + widthSecondWing: number; + /** + * Length stair first wing + * @default 1 + * @minimum 0.1 + * @maximum Infinity + * @step 0.1 + */ + lengthStairFirstWing: number; + /** + * Length stair second wing + * @default 1 + * @minimum 0.1 + * @maximum Infinity + * @step 0.1 + */ + lengthStairSecondWing: number; + /** + * Length wall first wing + * @default 1 + * @minimum 0.1 + * @maximum Infinity + * @step 0.1 + */ + lengthWallFirstWing: number; + /** + * Length wall second wing + * @default 1 + * @minimum 0.1 + * @maximum Infinity + * @step 0.1 + */ + lengthWallSecondWing: number; + /** Facade panel thickness + * @default 0.05 + * @minimum 0.01 + * @maximum Infinity + * @step 0.01 + */ + facadePanelThickness: number; + /** Wall thickness + * @default 0.3 + * @minimum 0.01 + * @maximum Infinity + * @step 0.05 + */ + wallThickness: number; + /** Height of the walls on the exterior side + * @default 3 + * @minimum 0.1 + * @maximum Infinity + * @step 0.1 + */ + wallHeightExterior: number; + /** Height of the walls on the interior side + * @default 3 + * @minimum 0.1 + * @maximum Infinity + * @step 0.1 + */ + wallHeightInterior: number; + /** Window offset top + * @default 0.3 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + windowFrameOffsetTop: number; + /** Window frame thickness + * @default 0.1 + * @minimum 0.01 + * @maximum Infinity + * @step 0.1 + */ + windowFrameThickness: number; + /** Glass frame thickness + * @default 0.1 + * @minimum 0.01 + * @maximum Infinity + * @step 0.1 + */ + glassFrameThickness: number; + /** Door width + * @default 1 + * @minimum 0.7 + * @maximum Infinity + * @step 0.1 + */ + doorWidth: number; + /** Corner Window Width Offset + * @default 0.3 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + windowWidthOffset: number; + /** Stair total height + * @default 1 + * @minimum 0.7 + * @maximum Infinity + * @step 0.1 + */ + stairTotalHeight: number; + /** Create stairs + * @default false + */ + createStair: boolean; + /** + * Flips the direction - outside things become inside and vice versa + * @default false + */ + flipDirection: boolean; + /** + * Rotation of the entrance + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 15 + */ + rotation: number; + /** + * Origin of the stairs + * @default [0, 0, 0] + */ + origin: Inputs.Base.Point3; + } + declare class CornerEntrancePart { + id?: string; + name?: string; + panelThickness?: number; + widthPanelExteriorOne?: number; + heightPanelsExterior?: number; + stair?: CornerStairPart; + window?: WindowCornerPart; + shapes?: { + compound?: T; + panelExterior?: T; + panelInterior?: T; + }; + } + declare class CornerPart { + /** + * Unique id of the corner part + */ + id?: string; + /** + * Name of the corner part + */ + name?: string; + /** + * Width of the panel + */ + widthPanel?: number; + /** + * Height of the panel + */ + heightPanel?: number; + /** + * Thickness of the panel + */ + thicknessPanel?: number; + /** + * Corner shapes + */ + shapes?: { + corner?: T; + }; + } + declare class CornerStairDto { + /** + * Inverts the side of the stair from going out to going inside of the L shape. This kind of stair can produce self intersecting result. + * @default false + */ + invert: boolean; + /** + * Width first wing + * @default 1 + * @minimum 0.1 + * @maximum Infinity + * @step 0.1 + */ + widthFirstLanding: number; + /** + * Width second wing + * @default 1 + * @minimum 0.1 + * @maximum Infinity + * @step 0.1 + */ + widthSecondLanding: number; + /** + * Length first wing + * @default 2 + * @minimum 0.1 + * @maximum Infinity + * @step 0.1 + */ + lengthFirstWing: number; + /** + * Length second wing + * @default 1 + * @minimum 0.1 + * @maximum Infinity + * @step 0.1 + */ + lengthSecondWing: number; + /** + * Max wished step height + * @default 0.25 + * @minimum 0.01 + * @maximum Infinity + * @step 0.05 + */ + maxWishedStepHeight: number; + /** + * Max wished step height + * @default 0.25 + * @minimum 0.01 + * @maximum Infinity + * @step 0.05 + */ + stepHeightWidthProportion: number; + /** + * Total height of the corner stairs + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + totalHeight: number; + /** + * Rotation of the stairs + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 15 + */ + rotation: number; + /** + * Origin of the stairs + * @default [0, 0, 0] + */ + origin: Inputs.Base.Point3; + } + declare class CornerStairPart extends CornerStairDto { + id?: string; + name?: string; + steps?: number; + stepWidth?: number; + stepHeight?: number; + shapes?: { + stair?: T; + }; + } + declare class FloorPart { + id?: string; + name?: string; + area?: number; + thickness?: number; + polygonPoints?: Inputs.Base.Point3[]; + shapes?: { + compound?: T; + }; + } + declare class ZenHideoutData { + /** + * Type of the object being configured + */ + type: string; + /** + * Default name of the object + */ + name: string; + /** + * Original inputs + */ + originalInputs?: ZenHideoutDto; + /** + * Compounded shape representation of all of the geometric objects of the building + */ + compound?: T; + /** + * All the shapes of the building + */ + shapes?: Models.OCCT.ShapeWithId[]; + /** + * Representation of zen hideout parts that are useful for drawing the object efficiently + */ + drawingPart?: ZenHideoutDrawingPart; + /** + * Sandwitch parts that have inner and outer panels, can have windows and doors + */ + sandwitchPartsBetweenColumns?: Things.Architecture.SandwitchPart[]; + /** + * Corner part panels forming 90 degree angle + */ + cornerParts?: Things.Architecture.CornerPart[]; + /** + * Column parts of the building + */ + columnParts?: Things.Architecture.ColumnPart[]; + /** + * Roof parts of the building. Contain all the upper geometry, together with beams and columns. + */ + roofParts?: Things.Architecture.RoofPart[]; + /** + * Entrance corner part of the building, containing interior and exterior panels, staircase, and a corner window part + */ + entranceCorner?: Things.Architecture.CornerEntrancePart; + /** + * Terrace corner of the building, containing interior and exterior panels, staircase, and a corner window part + */ + entranceTerrace?: Things.Architecture.CornerEntrancePart; + /** + * Floor parts of the building + */ + floors?: Things.Architecture.FloorPart[]; + /** + * Ceiling parts of the building + */ + ceilings?: Things.Architecture.CeilingPart[]; + } + /** + * This defines useful compounded objects for representing zen hideout in optimal and fast way. + */ + declare class ZenHideoutDrawingPartShapes { + /** + * The representation of all window glass objects in the building + */ + windowGlassCompound?: T; + /** + * The representation of all glass frame objects in the building + */ + glassFramesCompound?: T; + /** + * The representation of all window frame objects in the building + */ + windowFrameCompound?: T; + /** + * The representation of all beam objects in the building + */ + beamsCompound?: T; + /** + * The representation of all column objects in the building + */ + columnsCompound?: T; + /** + * The representation of all exterior panels on the first floor + * of the building + */ + firstFloorExteriorPanelsCompound?: T; + /** + * The representation of all interior panels on the first floor + * of the building + */ + firstFloorInteriorPanelsCompound?: T; + /** + * The representation of all exterior panels on the roof + * of the building + */ + roofExteriorPanelsCompound?: T; + /** + * The representation of all interior panels on the roof + * of the building + */ + roofInteriorPanelsCompound?: T; + /** + * The representation of the first roof cover + * of the building + */ + roofCoverFirstCompound?: T; + /** + * The representation of the second roof cover + * of the building + */ + roofCoverSecondCompound?: T; + /** + * The representation of the floor + * of the building + */ + floorCompound?: T; + /** + * The representation of the ceiling + * of the building + */ + ceilingCompound?: T; + /** + * The representation of stairs + */ + stairsCompound?: T; + } + /** + * Information needed to draw the part in an optimal way + */ + declare class ZenHideoutDrawingPart { + /** + * Shapes that exist in the drawing part, T can represent opancascade geometry, + * babylonjs mesh, materials or other things that map to these drawing categories. + */ + shapes?: ZenHideoutDrawingPartShapes; + } + declare class ZenHideoutDtoBase { + widthFirstWing: T; + lengthFirstWing: T; + terraceWidth: T; + widthSecondWing: T; + lengthSecondWing: T; + heightWalls: T; + roofAngleFirstWing: T; + roofAngleSecondWing: T; + roofOffset: T; + roofInsideOverhang: T; + roofMaxDistAttachmentBeams: T; + roofAttachmentBeamWidth: T; + roofAttachmentBeamHeight: T; + roofOutsideOverhang: T; + columnSize: T; + ceilingBeamHeight: T; + ceilingBeamWidth: T; + nrCeilingBeamsBetweenColumns: T; + distBetweenColumns: T; + floorHeight: T; + groundLevel: T; + facadePanelThickness: T; + windowWidthOffset: T; + windowHeightOffset: T; + windowFrameThickness: T; + windowGlassFrameThickness: T; + lod: U; + rotation?: T; + origin?: V; + } + declare class ZenHideoutDto + implements + ZenHideoutDtoBase + { + constructor( + widthFirstWing?: number, + lengthFirstWing?: number, + terraceWidth?: number, + widthSecondWing?: number, + lengthSecondWing?: number, + heightWalls?: number, + roofAngleFirstWing?: number, + roofAngleSecondWing?: number, + roofOffset?: number, + roofInsideOverhang?: number, + roofMaxDistAttachmentBeams?: number, + roofAttachmentBeamWidth?: number, + roofAttachmentBeamHeight?: number, + roofOutsideOverhang?: number, + columnSize?: number, + ceilingBeamHeight?: number, + ceilingBeamWidth?: number, + nrCeilingBeamsBetweenColumns?: number, + distBetweenColumns?: number, + floorHeight?: number, + groundLevel?: number, + facadePanelThickness?: number, + windowWidthOffset?: number, + windowHeightOffset?: number, + windowFrameThickness?: number, + windowGlassFrameThickness?: number, + lod?: Things.Enums.lodEnum, + skinOpacity?: number, + rotation?: number, + origin?: Inputs.Base.Point3 + ); + /** + * Width of the first wing of L shaped building + * @default 4 + * @minimum 3 + * @maximum Infinity + * @step 0.5 + */ + widthFirstWing: number; + /** + * Length of the first wing of L shaped building + * @default 10 + * @minimum 3 + * @maximum Infinity + * @step 0.5 + */ + lengthFirstWing: number; + /** + * Width of the terrace + * @default 3 + * @minimum 1 + * @maximum Infinity + * @step 0.25 + */ + terraceWidth: number; + /** + * Width of the second wing of L shaped building + * @default 5 + * @minimum 3 + * @maximum Infinity + * @step 0.5 + */ + widthSecondWing: number; + /** + * Length of the second wing of L shaped building + * @default 10 + * @minimum 3 + * @maximum Infinity + * @step 0.5 + */ + lengthSecondWing: number; + /** + * Height of the walls + * @default 3 + * @minimum 3 + * @maximum Infinity + * @step 0.1 + */ + heightWalls: number; + /** + * Height of the first wing end + * @default 15 + * @minimum 5 + * @maximum Infinity + * @step 5 + */ + roofAngleFirstWing: number; + /** + * Height of the first wing end + * @default 25 + * @minimum 5 + * @maximum Infinity + * @step 5 + */ + roofAngleSecondWing: number; + /** + * The offset to be applied to where the roof starts + * @default 0.5 + * @minimum 0.2 + * @maximum Infinity + * @step 0.25 + */ + roofOffset: number; + /** + * Roof overhang on the inside of the building (where the terrace is) + * @default 0.5 + * @minimum 0 + * @maximum Infinity + * @step 0.25 + */ + roofInsideOverhang: number; + /** + * Roof max distance between top attachment beams + * @default 0.8 + * @minimum 0.1 + * @maximum Infinity + * @step 0.25 + */ + roofMaxDistAttachmentBeams: number; + /** + * Roof attachment beam width + * @default 0.2 + * @minimum 0.01 + * @maximum Infinity + * @step 0.05 + */ + roofAttachmentBeamWidth: number; + /** + * Roof attachment beam height + * @default 0.05 + * @minimum 0.01 + * @maximum Infinity + * @step 0.05 + */ + roofAttachmentBeamHeight: number; + /** + * Roof overhang on the inside of the building + * @default 0.5 + * @minimum 0 + * @maximum Infinity + * @step 0.25 + */ + roofOutsideOverhang: number; + /** + * Column size + * @default 0.3 + * @minimum 0.01 + * @maximum Infinity + * @step 0.1 + */ + columnSize: number; + /** Ceiling beam height + * @default 0.25 + * @minimum 0.01 + * @maximum Infinity + * @step 0.05 + */ + ceilingBeamHeight: number; + /** Ceiling beam width + * @default 0.1 + * @minimum 0.01 + * @maximum Infinity + * @step 0.05 + */ + ceilingBeamWidth: number; + /** Nr ceiling beams between columns + * @default 3 + * @minimum 1 + * @maximum Infinity + * @step 1 + */ + nrCeilingBeamsBetweenColumns: number; + /** Distance between columns + * @default 2 + * @minimum 0.5 + * @maximum Infinity + * @step 0.25 + */ + distBetweenColumns: number; + /** The height of the floor + * @default 0.1 + * @minimum 0.1 + * @maximum Infinity + * @step 0.1 + */ + floorHeight: number; + /** ground level from the floor + * @default 0.6 + * @minimum 0.1 + * @maximum Infinity + * @step 0.1 + */ + groundLevel: number; + /** Facade panel thickness + * @default 0.05 + * @minimum 0.01 + * @maximum Infinity + * @step 0.01 + */ + facadePanelThickness: number; + /** Window width parameter + * @default 0.1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + windowWidthOffset: number; + /** Window bottom offset + * @default 0.2 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + windowHeightOffset: number; + /** Window frame thickness + * @default 0.1 + * @minimum 0.01 + * @maximum Infinity + * @step 0.01 + */ + windowFrameThickness: number; + /** Window glass frame thickness + * @default 0.05 + * @minimum 0.01 + * @maximum Infinity + * @step 0.01 + */ + windowGlassFrameThickness: number; + /** + * Level of detail to compute + * @default high + */ + lod: Things.Enums.lodEnum; + /** + * The opacity of the skin - only applied if lod is set to high + * @default 1 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + skinOpacity: number; + /** + * Rotation of the zen hideout + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 10 + */ + rotation: number; + /** + * Origin of the zen hideout + * @default [0, 0, 0] + */ + origin: Inputs.Base.Point3; + } + declare class RoofBeamsPart { + beamsCeiling?: BeamPart[]; + beamsVerticalHigh?: BeamPart[]; + beamsVerticalLow?: BeamPart[]; + beamsTop?: BeamPart[]; + beamsAttachment: BeamPart[]; + shapes?: { + compound?: T; + }; + } + declare class RoofCoverOneSidedDto { + /** + * Roof cover name + * @default roof-cover + */ + name: string; + /** + * Roof angle + * @default 15 + * @minimum 0 + * @maximum Infinity + * @step 5 + */ + roofAngle: number; + /** + * Roof length + * @default 3 + * @minimum 0.1 + * @maximum Infinity + * @step 0.1 + */ + roofLength: number; + /** + * Roof width along the angle part, total width contains roof inside and outside overhangs + * @default 3 + * @minimum 0.01 + * @maximum Infinity + * @step 0.1 + */ + roofWidth: number; + /** + * Roof outside overhang + * @default 0.5 + * @minimum 0.1 + * @maximum Infinity + * @step 0.1 + */ + roofOutsideOverhang: number; + /** + * Roof inside overhang + * @default 1 + * @minimum 0.1 + * @maximum Infinity + * @step 0.1 + */ + roofInsideOverhang: number; + /** + * Roof overhang facade + * @default 0.1 + * @minimum 0.01 + * @maximum Infinity + * @step 0.1 + */ + roofOverhangFacade: number; + /** + * Roof thickness + * @default 0.05 + * @minimum 0.001 + * @maximum Infinity + * @step 0.01 + */ + roofThickness: number; + /** + * Roof cover height + * @default 0.3 + * @minimum 0.01 + * @maximum Infinity + * @step 0.1 + */ + roofCoverHeight: number; + /** + * Rotation of the window + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 15 + */ + rotation: number; + /** + * Level of detail + * @default high + */ + lod: Things.Enums.lodEnum; + /** + * Origin of the stairs + * @default [0, 0, 0] + */ + center: Inputs.Base.Point3; + /** + * Direction of the window + * @default [0, 1, 0] + */ + direction: Inputs.Base.Vector3; + } + declare class RoofCoverPart extends RoofCoverOneSidedDto { + id?: string; + shapes?: { + compound?: T; + }; + } + declare class RoofPanelPart { + id?: string; + name?: string; + innerPanels?: SandwitchPart[]; + innerFillPanels?: SandwitchPart[]; + outerPanels?: SandwitchPart[]; + outerFillPanels?: SandwitchPart[]; + ends?: SandwitchPartFlex[]; + shapes?: { + compoundInnerExteriorPanels?: T; + compoundInnerInteriorPanels?: T; + compoundInnerFillExteriorPanels?: T; + compoundInnerFillInteriorPanels?: T; + compoundOuterExteriorPanels?: T; + compoundOuterInteriorPanels?: T; + compoundOuterFillExteriorPanels?: T; + compoundOuterFillInteriorPanels?: T; + compoundEndsInteriorPanels?: T; + compoundEndsExteriorPanels?: T; + compound?: T; + }; + } + declare class RoofPart { + id?: string; + name?: string; + beams: RoofBeamsPart; + panels?: RoofPanelPart; + covers?: RoofCoverPart[]; + shapes?: { + compound?: T; + }; + } + declare class SandwitchPanelDto { + /** Name of the sandwitch panel + * @default sandwitch-panel + */ + name: string; + /** Indicates wether a window should be created + * @default true + */ + createWindow: boolean; + /** Indicates wether the inner panel should be created + * @default true + */ + createInnerPanel: boolean; + /** Indicates wether the exterior panel should be created + * @default true + */ + createExteriorPanel: boolean; + /** Wall thickness + * @default 0.3 + * @minimum 0.01 + * @maximum Infinity + * @step 0.05 + */ + wallWidth: number; + /** Exterior panel width + * @default 0.4 + * @minimum 0.01 + * @maximum Infinity + * @step 0.05 + */ + exteriorPanelWidth: number; + /** Exterior panel height + * @default 3 + * @minimum 0.01 + * @maximum Infinity + * @step 0.1 + */ + exteriorPanelHeight: number; + /** Exterior panel thickness + * @default 0.05 + * @minimum 0.01 + * @maximum Infinity + * @step 0.1 + */ + exteriorPanelThickness: number; + /** Exterior panel bottom offset + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + exteriorPanelBottomOffset: number; + /** Interior panel width + * @default 0.4 + * @minimum 0.01 + * @maximum Infinity + * @step 0.05 + */ + interiorPanelWidth: number; + /** Interior panel height + * @default 3 + * @minimum 0.01 + * @maximum Infinity + * @step 0.1 + */ + interiorPanelHeight: number; + /** Interior panel thickness + * @default 0.05 + * @minimum 0.01 + * @maximum Infinity + * @step 0.1 + */ + interiorPanelThickness: number; + /** Interior panel bottom offset + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + interiorPanelBottomOffset: number; + /** Window width parameter + * @default 0.1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + windowWidthOffset: number; + /** Window bottom offset + * @default 0.2 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + windowHeightOffset: number; + /** Window frame thickness + * @default 0.1 + * @minimum 0.01 + * @maximum Infinity + * @step 0.01 + */ + windowFrameThickness: number; + /** Window glass frame thickness + * @default 0.05 + * @minimum 0.01 + * @maximum Infinity + * @step 0.01 + */ + windowGlassFrameThickness: number; + } + declare class SandwitchPanelFlexDto { + /** Name of the sandwitch panel + * @default sandwitch-panel + */ + name: string; + /** Indicates wether a window should be created + * @default true + */ + createInteriorPanel: boolean; + /** Indicates wether the exterior panel should be created + * @default true + */ + createExteriorPanel: boolean; + /** Wall thickness + * @default 0.3 + * @minimum 0.01 + * @maximum Infinity + * @step 0.05 + */ + wallWidth: number; + /** Exterior panel thickness + * @default 0.05 + * @minimum 0.01 + * @maximum Infinity + * @step 0.1 + */ + exteriorPanelThickness: number; + /** Interior panel thickness + * @default 0.05 + * @minimum 0.01 + * @maximum Infinity + * @step 0.1 + */ + interiorPanelThickness: number; + /** + * Interior wall panel polygon points + * @default [] + */ + interiorPanelPolygonPoints: Inputs.Base.Point2[]; + /** + * Exterior wall panel polygon points + * @default [] + */ + exteriorPanelPolygonPoints: Inputs.Base.Point2[]; + } + declare class SandwitchPart extends SandwitchPanelDto { + id?: string; + rotation?: number; + center?: Inputs.Base.Point3; + direction?: Inputs.Base.Vector3; + windows?: WindowRectangularPart[]; + shapes?: { + panelExterior?: T; + panelInterior?: T; + compound?: T; + }; + } + declare class SandwitchPartFlex extends SandwitchPanelFlexDto { + id?: string; + rotation?: number; + center?: Inputs.Base.Point3; + direction?: Inputs.Base.Vector3; + windows?: WindowRectangularPart[]; + shapes?: { + panelExterior?: T; + panelInterior?: T; + compound?: T; + }; + } + declare class WindowCornerDto { + /** Wall thickness + * @default 0.4 + * @minimum 0.01 + * @maximum Infinity + * @step 0.05 + */ + wallThickness: number; + /** Facade panel thickness + * @default 0.05 + * @minimum 0.01 + * @maximum Infinity + * @step 0.05 + */ + facadePanelThickness: number; + /** Glass frame thickness + * @default 0.02 + * @minimum 0.01 + * @maximum Infinity + * @step 0.01 + */ + glassFrameThickness: number; + /** Glass thickness + * @default 0.005 + * @minimum 0.001 + * @maximum Infinity + * @step 0.001 + */ + glassThickness: number; + /** Frame thickness + * @default 0.05 + * @minimum 0.01 + * @maximum Infinity + * @step 0.01 + */ + frameThckness: number; + /** Window height + * @default 0.05 + * @minimum 0.01 + * @maximum Infinity + * @step 0.01 + */ + height: number; + /** Length first window + * @default 1 + * @minimum 0.01 + * @maximum Infinity + * @step 0.1 + */ + lengthFirst: number; + /** Length second window + * @default 1 + * @minimum 0.01 + * @maximum Infinity + * @step 0.1 + */ + lengthSecond: number; + /** + * Rotation of the window + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 15 + */ + rotation: number; + /** + * Origin of the stairs + * @default [0, 0, 0] + */ + origin: Inputs.Base.Point3; + } + declare class WindowPartShapes { + /** + * Cutout of the window - this can be used to make the hole in the wall and usually should not be visualised + */ + cutout?: T; + /** + * Shape of the glass of the window + */ + glass?: T; + /** + * Glass frame of the window + */ + glassFrame?: T; + /** + * Frame of the window that usually is as thick as the wall and that touches glass frame + */ + frame?: T; + /** + * Compounded shape of the window with all other shapes joined together + */ + compound?: T; + } + declare class WindowRectangularPart extends WindowRectangularDto { + /** + * The name of the window part + */ + name: string; + /** + * The unique id of the window part + */ + id?: string; + /** + * Generic shapes that represent the window part + */ + shapes?: WindowPartShapes; + } + declare class WindowCornerPart extends WindowCornerDto { + /** + * The name of the window part + */ + name: string; + /** + * The unique id of the window part + */ + id?: string; + /** + * Generic shapes that represent the window part + */ + shapes?: WindowPartShapes; + } + declare class WindowRectangularDto { + /** Window thickness + * @default 0.3 + * @minimum 0.01 + * @maximum Infinity + * @step 0.05 + */ + thickness: number; + /** Glass frame thickness + * @default 0.02 + * @minimum 0.01 + * @maximum Infinity + * @step 0.01 + */ + glassFrameThickness: number; + /** Glass thickness + * @default 0.005 + * @minimum 0.001 + * @maximum Infinity + * @step 0.001 + */ + glassThickness: number; + /** Frame thickness + * @default 0.05 + * @minimum 0.01 + * @maximum Infinity + * @step 0.01 + */ + frameThickness: number; + /** Window height + * @default 0.05 + * @minimum 0.01 + * @maximum Infinity + * @step 0.01 + */ + height: number; + /** Width first window + * @default 1 + * @minimum 0.01 + * @maximum Infinity + * @step 0.1 + */ + width: number; + /** + * Rotation of the window + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 15 + */ + rotation: number; + /** + * Origin of the stairs + * @default [0, 0, 0] + */ + center: Inputs.Base.Point3; + /** + * Direction of the window + * @default [0, 1, 0] + */ + direction: Inputs.Base.Vector3; + } + } + declare namespace KidsCorner { + declare namespace BirdHouses { + declare namespace WingtipVilla { + declare class WingtipVillaData { + type: string; + name: string; + compound?: T; + roof: { + compound: T; + shapes: T[]; + }; + walls: { + compound: T; + shapes: T[]; + }; + stick: { + shape: T; + }; + floor: { + shape: T; + }; + chimney: { + shape: T; + }; + basicPoints: { + kind: string; + point: Inputs.Base.Point3; + }[]; + } + declare class WingtipVillaDto { + constructor( + interiorWidth?: number, + interiorLength?: number, + interiorHeight?: number, + thickness?: number, + holeDiameter?: number, + holeDistToBottom?: number, + stickLength?: number, + stickDiameter?: number, + baseAttachmentHeight?: number, + roofOverhang?: number, + rotation?: number, + chimneyHeight?: number, + origin?: Inputs.Base.Point3 + ); + /** + * Width of the house + * @default 3 + * @minimum 0 + * @maximum Infinity + * @step 0.5 + */ + interiorWidth: number; + /** + * Interior length of the house + * @default 3 + * @minimum 0 + * @maximum Infinity + * @step 0.5 + */ + interiorLength: number; + /** + * Interior height that goes from the floor to where the roof starts + * @default 5 + * @minimum 0 + * @maximum Infinity + * @step 0.5 + */ + interiorHeight: number; + /** + * thickness of the house + * @default 0.5 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + thickness: number; + /** + * hole diameter of the house + * @default 1.5 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + holeDiameter: number; + /** + * hole distance to the bottom of the house + * @default 2.5 + * @minimum 0 + * @maximum Infinity + * @step 0.5 + */ + holeDistToBottom: number; + /** + * stick length + * @default 1.2 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + stickLength: number; + /** + * stick diameter + * @default 0.5 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + stickDiameter: number; + /** + * base attachment height + * @default 2 + * @minimum 0 + * @maximum Infinity + * @step 0.5 + */ + baseAttachmentHeight: number; + /** + * roof overhang + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.5 + */ + roofOverhang: number; + /** + * Rotation of the bird house around the origin. + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 10 + */ + rotation: number; + /** + * Chimney height + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.5 + */ + chimneyHeight: number; + /** + * Origin of the bird house (where the bird house would be attached to the tree or the wall) + * @default [0, 0, 0] + */ + origin: Inputs.Base.Point3; + } + } + declare namespace ChirpyChalet { + declare class ChirpyChaletData { + type: string; + name: string; + compound?: T; + roof: { + compound: T; + shapes: T[]; + }; + walls: { + compound: T; + shapes: T[]; + }; + stick: { + shape: T; + }; + floor: { + shape: T; + }; + basicPoints: { + kind: string; + point: Inputs.Base.Point3; + }[]; + } + declare class ChirpyChaletDto { + constructor( + interiorWidth?: number, + interiorLength?: number, + interiorHeight?: number, + thickness?: number, + holeDiameter?: number, + holeDistToBottom?: number, + stickLength?: number, + stickDiameter?: number, + baseAttachmentHeight?: number, + roofOverhang?: number, + roofAngle?: number, + rotation?: number, + origin?: Inputs.Base.Point3 + ); + /** + * Width of the house + * @default 3 + * @minimum 0 + * @maximum Infinity + * @step 0.5 + */ + interiorWidth: number; + /** + * Interior length of the house + * @default 3 + * @minimum 0 + * @maximum Infinity + * @step 0.5 + */ + interiorLength: number; + /** + * Interior height that goes from the floor to where the roof starts + * @default 5 + * @minimum 0 + * @maximum Infinity + * @step 0.5 + */ + interiorHeight: number; + /** + * thickness of the house + * @default 0.3 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + thickness: number; + /** + * hole diameter of the house + * @default 1.2 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + holeDiameter: number; + /** + * hole distance to the bottom of the house + * @default 2.5 + * @minimum 0 + * @maximum Infinity + * @step 0.5 + */ + holeDistToBottom: number; + /** + * stick length + * @default 0.9 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + stickLength: number; + /** + * stick diameter + * @default 0.3 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + stickDiameter: number; + /** + * base attachment height + * @default 2 + * @minimum 0 + * @maximum Infinity + * @step 0.5 + */ + baseAttachmentHeight: number; + /** + * roof overhang + * @default 0.5 + * @minimum 0 + * @maximum Infinity + * @step 0.5 + */ + roofOverhang: number; + /** + * roof overhang + * @default 20 + * @minimum 0 + * @maximum 80 + * @step 5 + */ + roofAngle: number; + /** + * Rotation of the bird house around the origin. + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 10 + */ + rotation: number; + /** + * Origin of the bird house (where the bird house would be attached to the tree or the wall) + * @default [0, 0, 0] + */ + origin: Inputs.Base.Point3; + } + } + } + } + + declare namespace ThreeDPrinting { + declare namespace Vases { + declare namespace SerenitySwirl { + declare class SerenitySwirlData { + type: string; + name: string; + compound?: T; + } + declare class SerenitySwirlDto { + constructor( + swirl?: number, + nrOfDivisions?: number, + addRadiusNarrow?: number, + addRadiusWide?: number, + addMiddleHeight?: number, + addTopHeight?: number, + thickness?: number, + rotation?: number, + origin?: Inputs.Base.Point3 + ); + /** + * Swirl 0 - no swirl 1 max swirl + * @default 0.6 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + swirl: number; + /** + * Nr of divisions + * @default 10 + * @minimum 1 + * @maximum Infinity + * @step 1 + */ + nrOfDivisions: number; + /** + * Add to narrow radius + * @default 0.4 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + addRadiusNarrow: number; + /** + * Add to radius wide + * @default 0.2 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + addRadiusWide: number; + /** + * Add to middle height + * @default 1.6 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + addMiddleHeight: number; + /** + * Add to top height + * @default 1.5 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + addTopHeight: number; + /** + * Thickness of the vase on the widest part + * @default 1 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + thickness: number; + /** + * Rotation of the serenity swirl + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 10 + */ + rotation: number; + /** + * Origin of the vase + * @default [0, 0, 0] + */ + origin: Inputs.Base.Point3; + } + } + declare namespace ArabicArchway { + declare class ArabicArchwayData { + /** + * Type of the object being configured + */ + type: string; + /** + * Default name of the object + */ + name: string; + /** + * Compound shape of all the parts + */ + compound?: T; + /** + * Original inputs + */ + originalInputs: ArabicArchwayDto; + /** + * All the shapes of the vase + */ + shapes?: Models.OCCT.ShapeWithId[]; + /** + * Representation of arabic archway parts that are useful for drawing the object efficiently + */ + drawingPart?: ArabicArchwayDrawingPart; + } + declare class ArabicArchwayDrawingPartShapes { + /** + * The representation of all objects in the vase + */ + compound?: T; + /** + * The representation of all vase part objects in the vase + */ + vasePartsCompound?: T; + /** + * The representation of all glass objects in the vase + */ + glassPartsCompound?: T; + /** + * The representation of the base of the vase + */ + vaseBaseCompound?: T; + } + /** + * Information needed to draw the part in an optimal way + */ + declare class ArabicArchwayDrawingPart { + /** + * Shapes that exist in the drawing part, T can represent opancascade geometry, + * babylonjs mesh, materials or other things that map to these drawing categories. + */ + shapes?: + | ArabicArchwayDrawingPartShapes + | { + [x: string]: T; + }; + } + declare class ArabicArchwayDtoBase { + profilePoints?: P; + nrOfSides: T; + nrOfVerticalArches: T; + thickness: T; + edgesThickness: T; + archCenterThickness: T; + baseHeight: T; + patchHoles: B; + lod?: U; + rotation?: T; + direction?: V; + scale?: V; + origin?: V; + } + declare class ArabicArchwayDto + implements + ArabicArchwayDtoBase< + number, + Inputs.Base.Point3, + Inputs.Base.Point3[], + Things.Enums.lodEnum, + boolean + > + { + constructor( + nrOfSides?: number, + nrOfVerticalArches?: number, + archCenterThickness?: number, + edgesThickness?: number, + thickness?: number, + baseHeight?: number, + patchHoles?: boolean, + lod?: Things.Enums.lodEnum, + rotation?: number, + origin?: Inputs.Base.Point3, + direction?: Inputs.Base.Point3, + scale?: Inputs.Base.Vector3 + ); + /** + * nr of sides for arabic archway vase + * @default [[2, 0, 0],[4, 5, 0],[1.5, 10, 0],[2, 14, 0]] + */ + profilePoints: Inputs.Base.Point3[]; + /** + * nr of sides for arabic archway vase + * @default 3 + * @minimum 3 + * @maximum 30 + * @step 1 + */ + nrOfSides: number; + /** + * nr of vertical arches + * @default 6 + * @minimum 2 + * @maximum 30 + * @step 1 + */ + nrOfVerticalArches: number; + /** + * Arch center thickness + * @default 0.8 + * @minimum 0 + * @maximum 10 + * @step 0.1 + */ + archCenterThickness: number; + /** + * Edges thickness + * @default 0.2 + * @minimum 0 + * @maximum 10 + * @step 0.1 + */ + edgesThickness: number; + /** + * Thickness of the vase on the widest part + * @default 1 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + thickness: number; + /** + * Indicates how high the base should be, if 0 then no base will be made + * @default 0.4 + * @minimum 0 + * @maximum 10 + * @step 0.1 + */ + baseHeight: number; + /** + * Indicates whether holes of the vase should be patched + * @default true + */ + patchHoles: boolean; + /** + * Level of details for the model + * @default high + */ + lod: Things.Enums.lodEnum; + /** + * Rotation of the serenity swirl + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 10 + */ + rotation: number; + /** + * Origin of the vase + * @default [0, 0, 0] + */ + origin: Inputs.Base.Point3; + /** + * Direction of the vase + * @default [0, 1, 0] + */ + direction: Inputs.Base.Point3; + /** + * Scale of the vase + * @default [1, 1, 1] + */ + scale: Inputs.Base.Vector3; + } + } + } + declare namespace Cups { + declare namespace CalmCup { + declare class CalmCupData { + type: string; + name: string; + originalInputs: CalmCupDto; + compound?: T; + } + declare class CalmCupDtoBase { + height: T; + radiusBottom: T; + radiusTopOffset: T; + thickness: T; + fillet: T; + nrOfHandles: T; + handleDist: T; + precision: T; + rotation?: T; + scale?: T; + origin?: U; + direction?: U; + } + declare class CalmCupDto + implements CalmCupDtoBase + { + constructor( + height?: number, + radiusBottom?: number, + radiusTopOffset?: number, + thickness?: number, + fillet?: number, + nrOfHandles?: number, + handleDist?: number, + precision?: number, + rotation?: number, + scale?: number, + origin?: Inputs.Base.Point3, + direction?: Inputs.Base.Vector3 + ); + /** + * Height of the cup + * @default 6 + * @minimum 0.1 + * @maximum Infinity + * @step 0.1 + */ + height: number; + /** + * Radius top offset + * @default 4 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + radiusBottom: number; + /** + * Radius top offset + * @default 2 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + radiusTopOffset: number; + /** + * Thickness of the cup + * @default 0.6 + * @minimum 0.05 + * @maximum 3 + * @step 0.01 + */ + thickness: number; + /** + * Fillet of the cup + * @default 0.2 + * @minimum 0.01 + * @maximum Infinity + * @step 0.01 + */ + fillet: number; + /** + * Nr of handles, 0 will create a cup without handles + * @default 1 + * @minimum 0 + * @maximum 2 + * @step 1 + */ + nrOfHandles: number; + /** + * Handle distance from the cup + * @default 2 + * @minimum 0.1 + * @maximum Infinity + * @step 0.1 + */ + handleDist: number; + /** + * Meshing precision of the drawn model. Scale scales precision as well. The lower the number the more precise the drawn model is. Keep in mind that output of this algorithm also contains pure occt shape that can be meshed separately in draw any async commands + * @default 0.01 + * @minimum 0.000001 + * @maximum 5 + * @step 0.001 + */ + precision: number; + /** + * Rotation of the cup + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 10 + */ + rotation: number; + /** + * Scale of the cup - affects edge width and precision + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 10 + */ + scale: number; + /** + * Origin of the medal + * @default [0, 0, 0] + */ + origin: Inputs.Base.Point3; + /** + * Direction of the model + * @default [0, 1, 0] + */ + direction: Inputs.Base.Vector3; + } + } + declare namespace DragonCup { + declare class DragonCupData { + type: string; + name: string; + originalInputs: DragonCupDto; + compound?: T; + } + declare class DragonCupDtoBase { + height: T; + radiusBottom: T; + radiusTopOffset: T; + radiusMidOffset: T; + rotationMidAngle: T; + rotationTopAngle: T; + thickness: T; + bottomThickness: T; + nrSkinCellsHorizontal: T; + nrSkinCellsVertical: T; + nrSkinCellDivisionsTop: T; + nrSkinCellDivisionsBottom: T; + skinCellOuterHeight: T; + skinCellInnerHeight: T; + skinCellBottomHeight: T; + skinCellTopHeight: T; + precision: T; + rotation?: T; + scale?: T; + origin?: U; + direction?: U; + } + declare class DragonCupDto + implements DragonCupDtoBase + { + constructor( + height?: number, + radiusBottom?: number, + radiusTopOffset?: number, + radiusMidOffset?: number, + rotationTopAngle?: number, + rotationMidAngle?: number, + nrSkinCellsVertical?: number, + nrSkinCellsHorizontal?: number, + nrSkinCellDivisionsTop?: number, + nrSkinCellDivisionsBottom?: number, + skinCellOuterHeight?: number, + skinCellInnerHeight?: number, + skinCellBottomHeight?: number, + skinCellTopHeight?: number, + thickness?: number, + bottomThickness?: number, + precision?: number, + rotation?: number, + scale?: number, + origin?: Inputs.Base.Point3, + direction?: Inputs.Base.Vector3 + ); + /** + * Height of the cup + * @default 6 + * @minimum 0.1 + * @maximum Infinity + * @step 0.1 + */ + height: number; + /** + * Radius top offset + * @default 4 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + radiusBottom: number; + /** + * Radius top offset + * @default 2 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + radiusTopOffset: number; + /** + * Radius middle offset + * @default 2 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + radiusMidOffset: number; + /** + * Rotation of the top from the middle (angle in degrees) + * @default 20 + * @minimum -90 + * @maximum 90 + * @step 1 + */ + rotationTopAngle: number; + /** + * Rotation of the middle from the bottom (angle in degrees) + * @default 20 + * @minimum -90 + * @maximum 90 + * @step 1 + */ + rotationMidAngle: number; + /** + * Nr of skin cells along vertical direction + * @default 5 + * @minimum 1 + * @maximum Infinity + * @step 1 + */ + nrSkinCellsVertical: number; + /** + * Nr of skin cells along horizontal direction + * @default 10 + * @minimum 3 + * @maximum Infinity + * @step 1 + */ + nrSkinCellsHorizontal: number; + /** + * Nr of skin cell divisions on the top of the cup + * @default 1 + * @minimum 1 + * @maximum Infinity + * @step 1 + */ + nrSkinCellDivisionsTop: number; + /** + * Nr of skin cell divisions on the bottom of the cup + * @default 3 + * @minimum 1 + * @maximum Infinity + * @step 1 + */ + nrSkinCellDivisionsBottom: number; + /** + * skin cell outer height + * @default 0.4 + * @minimum -Infinity + * @maximum Infinity + * @step 0.01 + */ + skinCellOuterHeight: number; + /** + * skin cell inner height + * @default 0.3 + * @minimum -Infinity + * @maximum Infinity + * @step 0.01 + */ + skinCellInnerHeight: number; + /** + * skin cell bottom height + * @default 0.4 + * @minimum -Infinity + * @maximum Infinity + * @step 0.01 + */ + skinCellBottomHeight: number; + /** + * skin cell top height + * @default 0.4 + * @minimum -Infinity + * @maximum Infinity + * @step 0.01 + */ + skinCellTopHeight: number; + /** + * Thickness of the cup + * @default 0.6 + * @minimum 0.05 + * @maximum Infinity + * @step 0.01 + */ + thickness: number; + /** + * Bottom thickness of the cup + * @default 1 + * @minimum 0.05 + * @maximum Infinity + * @step 0.01 + */ + bottomThickness: number; + /** + * Meshing precision of the drawn model. Scale scales precision as well. The lower the number the more precise the drawn model is. Keep in mind that output of this algorithm also contains pure occt shape that can be meshed separately in draw any async commands + * @default 0.01 + * @minimum 0.000001 + * @maximum 5 + * @step 0.001 + */ + precision: number; + /** + * Rotation of the cup + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 10 + */ + rotation: number; + /** + * Scale of the cup - affects edge width and precision + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 10 + */ + scale: number; + /** + * Origin of the medal + * @default [0, 0, 0] + */ + origin: Inputs.Base.Point3; + /** + * Direction of the model + * @default [0, 1, 0] + */ + direction: Inputs.Base.Vector3; + } + declare class DragonCupModelDto { + /** + * The model that represents result of the dragon cup + * @default undefined + */ + model: DragonCupData; + } + } + } + declare namespace Boxes { + declare namespace SpicyBox { + declare class SpicyBoxData { + type: string; + name: string; + originalInputs: SpicyBoxDto; + compound?: T; + } + declare class SpicyBoxDtoBase { + textTop: V; + textFront: V; + height: T; + coverHeight: T; + baseHeight: T; + radiusBase: T; + radiusOffset: T; + thickness: T; + ornamentalThickness: T; + nrOrnamnetsPerSide: T; + invertOrnaments: Z; + fillet: T; + nrSides: T; + nrOffsets: T; + precision: T; + rotation?: T; + scale?: T; + origin?: U; + direction?: U; + } + declare class SpicyBoxDto + implements + SpicyBoxDtoBase + { + constructor( + textTop?: string, + textFront?: string, + nrSides?: number, + nrOffsets?: number, + height?: number, + coverHeight?: number, + baseHeight?: number, + radiusBottom?: number, + radiusTopOffset?: number, + thickness?: number, + ornamentalThickness?: number, + nrOrnamnetsPerSide?: number, + invertOrnaments?: boolean, + fillet?: number, + precision?: number, + rotation?: number, + scale?: number, + origin?: Inputs.Base.Point3, + direction?: Inputs.Base.Vector3 + ); + /** + * Text on the top of the box + * @default Pepper + */ + textTop: string; + /** + * Text on the front of the box + * @default For Your Spicy Needs + */ + textFront: string; + /** + * Nr of sides of the box + * @default 4 + * @minimum 3 + * @maximum 16 + * @step 1 + */ + nrSides: number; + /** + * Nr vertical offsets + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + nrOffsets: number; + /** + * Height of the cup + * @default 6 + * @minimum 0.1 + * @maximum Infinity + * @step 0.1 + */ + height: number; + /** + * Radius top offset + * @default 4 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + radiusBase: number; + /** + * Radius top offset + * @default 2 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + radiusOffset: number; + /** + * Cover height + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + coverHeight: number; + /** + * Base height + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + baseHeight: number; + /** + * Thickness of the cup + * @default 0.6 + * @minimum 0.05 + * @maximum Infinity + * @step 0.01 + */ + thickness: number; + /** + * Ornamental thickness + * @default 0.1 + * @minimum 0.05 + * @maximum Infinity + * @step 0.01 + */ + ornamentalThickness: number; + /** + * Ornamental thickness + * @default 10 + * @minimum 1 + * @maximum Infinity + * @step 1 + */ + nrOrnamnetsPerSide: number; + /** + * Inverst the ornaments + * @default false + */ + invertOrnaments: boolean; + /** + * Fillet of the cup + * @default 0.2 + * @minimum 0.01 + * @maximum Infinity + * @step 0.01 + */ + fillet: number; + /** + * Meshing precision of the drawn model. Scale scales precision as well. The lower the number the more precise the drawn model is. Keep in mind that output of this algorithm also contains pure occt shape that can be meshed separately in draw any async commands + * @default 0.01 + * @minimum 0.000001 + * @maximum 5 + * @step 0.001 + */ + precision: number; + /** + * Rotation of the cup + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 10 + */ + rotation: number; + /** + * Scale of the cup - affects edge width and precision + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 10 + */ + scale: number; + /** + * Origin of the medal + * @default [0, 0, 0] + */ + origin: Inputs.Base.Point3; + /** + * Direction of the model + * @default [0, 1, 0] + */ + direction: Inputs.Base.Vector3; + } + declare class SpicyBoxModelDto { + /** + * The model that represents result of the spicy box + * @default undefined + */ + model: SpicyBoxData; + } + } + } + declare namespace Medals { + declare namespace EternalLove { + declare class EternalLoveData { + type: string; + name: string; + originalInputs: EternalLoveDto; + compound?: T; + } + declare class EternalLoveDtoBase { + textHeading: T; + textName: T; + fullModel: B; + thickness: U; + decorationThickness: U; + rotation?: U; + origin?: V; + direction?: V; + } + declare class EternalLoveDto + implements + EternalLoveDtoBase + { + constructor( + textHeading?: string, + textName?: string, + fullModel?: boolean, + thickness?: number, + decorationThickness?: number, + rotation?: number, + origin?: Inputs.Base.Point3, + direction?: Inputs.Base.Vector3 + ); + /** + * The head text + * @default LOVE YOU + */ + textHeading: string; + /** + * Name of the person + * @default NORA + */ + textName: string; + /** + * Choose whether to produce half of the model (better for 3d printing) or full model with two sides + * @default true + */ + fullModel: boolean; + /** + * Thickness of the model + * @default 6 + * @minimum 0.5 + * @maximum 20 + * @step 0.1 + */ + thickness: number; + /** + * Additional thickness of the decorations + * @default 1 + * @minimum 0.1 + * @maximum 3 + * @step 0.1 + */ + decorationThickness: number; + /** + * Rotation of the erenal love medal + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 10 + */ + rotation: number; + /** + * Origin of the medal + * @default [0, 0, 0] + */ + origin: Inputs.Base.Point3; + /** + * Direction of the model + * @default [0, 1, 0] + */ + direction: Inputs.Base.Vector3; + } + } + } + declare namespace Desktop { + declare namespace PhoneNest { + declare class PhoneNestData { + type: string; + /** + * The name of the model + */ + name: string; + /** + * Original inputs that were used to create the model + */ + originalInputs: PhoneNestDto; + /** + * Compound shape of the table geometry + */ + compound?: T; + /** + * Representation of table parts that are useful for drawing the object efficiently + */ + drawingPart?: PhoneNestDrawingPart; + /** + * Data that contains information and shapes of the top part of the table + */ + mainPart?: PhoneNestMainPart; + /** + * All the shapes of the vase + */ + shapes?: Models.OCCT.ShapeWithId[]; + } + declare class PhoneNestDrawDto { + /** + * Main material + * @defaul undefined + * @optional true + */ + mainMaterial?: T; + /** + * Phone material + * @defaul undefined + * @optional true + */ + phoneMaterial?: T; + /** + * You can turn off drawing of faces via this property + * @default true + */ + drawFaces: boolean; + /** + * Meshing precision of the drawn model. The lower the number the more precise the drawn model is. Keep in mind that output of this algorithm also contains pure occt shape that can be meshed separately in draw any async commands + * @default 0.001 + * @minimum 0.000001 + * @maximum 5 + * @step 0.001 + */ + precision: number; + /** + * Defines if the edges of the model should be drawn + * @default true + */ + drawEdges: boolean; + /** + * Hex colour string for the edges + * @default #ffffff + */ + edgeColour: Inputs.Base.Color; + /** + * Edge width + * @default 0.06 + * @minimum 0 + * @maximum Infinity + */ + edgeWidth: number; + } + /** + * This defines useful compounded objects for representing model in optimal and fast way. + */ + declare class PhoneNestDrawingPartShapes { + /** + * The representation of main part of the table + */ + main?: T; + /** + * The representation of the glass of the table + */ + phone?: T; + } + /** + * Information needed to draw the part in an optimal way + */ + declare class PhoneNestDrawingPart extends Part { + /** + * Shapes that exist in the drawing part, T can represent opancascade geometry, + * babylonjs mesh, materials or other things that map to these drawing categories. + */ + shapes?: PhoneNestDrawingPartShapes; + } + declare class PhoneNestDtoBase { + heightBottom: T; + heightTop: T; + widthBack: T; + widthFront: T; + length: T; + backOffset: T; + thickness: T; + filletRadius: T; + applyOrnaments: B; + phoneHeight: T; + phoneWidth: T; + phoneThickness: T; + precision: T; + rotation?: T; + scale?: T; + origin?: U; + direction?: U; + } + declare class PhoneNestDto + implements PhoneNestDtoBase + { + constructor( + heightBottom?: number, + heightTop?: number, + widthBack?: number, + widthFront?: number, + length?: number, + backOffset?: number, + thickness?: number, + applyOrnaments?: boolean, + filletRadius?: number, + phoneHeight?: number, + phoneWidth?: number, + phoneThickness?: number, + precision?: number, + drawEdges?: boolean, + rotation?: number, + scale?: number, + origin?: Inputs.Base.Point3, + direction?: Inputs.Base.Vector3 + ); + /** + * Height of the phone holder at the bottom + * @default 5 + * @minimum 0 + * @maximum Infinity + * @step 0.01 + */ + heightBottom: number; + /** + * Height of the phone holder at the top + * @default 16 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + heightTop: number; + /** + * Width of the phone holder on the back + * @default 25 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + widthBack: number; + /** + * Width of the phone holder on the front and holder + * @default 10 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + widthFront: number; + /** + * Length of the holder base + * @default 16 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + length: number; + /** + * The back offset + * @default 6 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + backOffset: number; + /** + * The thickness of the table + * @default 0.4 + * @minimum 0.01 + * @maximum Infinity + * @step 0.01 + */ + thickness: number; + /** + * Apply final ornaments + * @default false + */ + applyOrnaments: boolean; + /** + * The radius of the fillet + * @default 2 + * @minimum 0.001 + * @maximum Infinity + * @step 0.1 + */ + filletRadius: number; + /** + * The height of the phone + * @default 16.8 + * @minimum 0 + * @maximum Infinitypho + * @step 0.01 + */ + phoneHeight: number; + /** + * The width of the phone + * @default 7.8 + * @minimum 0 + * @maximum Infinity + * @step 0.01 + */ + phoneWidth: number; + /** + * The thickness of the phone + * @default 0.7 + * @minimum 0 + * @maximum Infinity + * @step 0.01 + */ + phoneThickness: number; + /** + * Meshing precision of the drawn model. The lower the number the more precise the drawn model is. Keep in mind that output of this algorithm also contains pure occt shape that can be meshed separately in draw any async commands + * @default 0.01 + * @minimum 0.000001 + * @maximum 5 + * @step 0.001 + */ + precision: number; + /** + * Defines if the edges of the model should be drawn + * @default true + */ + drawEdges: boolean; + /** + * Rotation of the table in degrees + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 10 + */ + rotation: number; + /** + * Scale of the table + * @default 1 + * @minimum 0 + * @maximum Infinity + */ + scale: number; + /** + * Origin of the medal + * @default [0, 0, 0] + */ + origin: Inputs.Base.Point3; + /** + * Direction of the model + * @default [0, 1, 0] + */ + direction: Inputs.Base.Vector3; + } + declare class PhoneNestModelDto { + /** + * The model that represents result of the good coffee table create operation + * @default undefined + */ + model: PhoneNestData; + } + declare class PhoneNestMainPart extends Part { + shapes?: { + phone?: T; + main?: T; + compound?: T; + }; + } + } + } + } + + declare namespace LaserCutting { + declare namespace Gadgets { + declare namespace DropletsPhoneHolder { + declare class DropletsPhoneHolderData { + /** + * Type of the object being configured + */ + type: string; + /** + * Default name of the object + */ + name: string; + /** + * Compound shape of all the parts + */ + compound?: T; + /** + * Original inputs + */ + originalInputs: DropletsPhoneHolderDto; + /** + * All the shapes of the vase + */ + shapes?: Models.OCCT.ShapeWithId[]; + /** + * Representation of arabic archway parts that are useful for drawing the object efficiently + */ + drawingPart?: DropletsPhoneHolderDrawingPart; + } + declare class DropletsPhoneHolderDrawingPartShapes { + /** + * The representation of all the objects in the phone holder, including all wires + */ + compound?: T; + /** + * The representation of 3D model of the phone holder + */ + phoneHolderCompound?: T; + /** + * The representation of all cut wires + */ + cutWiresCompound?: T; + /** + * The representation of the engraving wires + */ + engravingWiresCompound?: T; + } + /** + * Information needed to draw the part in an optimal way + */ + declare class DropletsPhoneHolderDrawingPart { + /** + * Shapes that exist in the drawing part, T can represent opancascade geometry, + * babylonjs mesh, materials or other things that map to these drawing categories. + */ + shapes?: + | DropletsPhoneHolderDrawingPartShapes + | { + [x: string]: T; + }; + } + declare class DropletsPhoneHolderDtoBase { + title?: S; + subtitle: S; + includeLogo: B; + thickness: T; + kerf: T; + phoneWidth: T; + phoneHeight: T; + phoneThickness: T; + backLength: T; + angle: T; + offsetAroundPhone: T; + penShelf: T; + phoneLockHeight: T; + filletRadius: T; + includePattern: B; + densityPattern: T; + holesForWire: B; + wireInputThickness: T; + includeModel: B; + includeDrawings: B; + spacingDrawings: T; + rotation?: T; + direction?: V; + scale?: V; + origin?: V; + } + declare class DropletsPhoneHolderDto + implements + DropletsPhoneHolderDtoBase< + string, + boolean, + number, + Inputs.Base.Vector3 + > + { + constructor( + title?: string, + subtitle?: string, + includeLogo?: boolean, + thickness?: number, + kerf?: number, + phoneWidth?: number, + phoneHeight?: number, + phoneThickness?: number, + backLength?: number, + angle?: number, + offsetAroundPhone?: number, + penShelf?: number, + phoneLockHeight?: number, + filletRadius?: number, + includePattern?: boolean, + densityPattern?: number, + holesForWire?: boolean, + wireInputThickness?: number, + includeModel?: boolean, + includeDrawings?: boolean, + spacingDrawings?: number, + rotation?: number, + origin?: Inputs.Base.Point3, + direction?: Inputs.Base.Point3, + scale?: Inputs.Base.Vector3 + ); + /** + * Title of the phone holder + * @default Your Name + */ + title: string; + /** + * Subtitle of the phone holder + * @default And Message + */ + subtitle: string; + /** + * Include the logo + * @default true + */ + includeLogo: boolean; + /** + * Thickness of the phone holder + * @default 0.4 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + thickness: number; + /** + * Kerf value for the laser cutting of joints + * @default 0.01 + * @minimum 0 + * @maximum Infinity + * @step 0.001 + */ + kerf: number; + /** + * Width of the phone + * @default 8 + * @minimum 4 + * @maximum Infinity + * @step 0.1 + */ + phoneWidth: number; + /** + * Height of the phone + * @default 16 + * @minimum 4 + * @maximum Infinity + * @step 0.1 + */ + phoneHeight: number; + /** + * Thickness of the phone + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + phoneThickness: number; + /** + * Length of the back + * @default 10 + * @minimum 5 + * @maximum Infinity + * @step 0.1 + */ + backLength: number; + /** + * Angle of the back + * @default 20 + * @minimum 0 + * @maximum 60 + * @step 1 + */ + angle: number; + /** + * Offset around the phone + * @default 0.5 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + offsetAroundPhone: number; + /** + * Pen shelf + * @default 1 + * @minimum 0.5 + * @maximum Infinity + * @step 0.1 + */ + penShelf: number; + /** + * Phone lock height + * @default 2 + * @minimum 0.5 + * @maximum Infinity + * @step 0.1 + */ + phoneLockHeight: number; + /** + * Fillet radius + * @default 0.3 + * @minimum 0.1 + * @maximum 0.4 + * @step 0.1 + */ + filletRadius: number; + /** + * Include pattern + * @default false + */ + includePattern: boolean; + /** + * Density of the pattern + * @default 0.4 + * @minimum 0 + * @maximum 2 + * @step 0.1 + */ + densityPattern: number; + /** + * Include pattern + * @default true + */ + holesForWire: boolean; + /** + * Wire input thickness + * @default 1.5 + * @minimum 0.7 + * @maximum Infinity + * @step 0.1 + */ + wireInputThickness: number; + /** + * Include 3D model + * @default true + */ + includeModel: boolean; + /** + * Include drawings + * @default true + */ + includeDrawings: boolean; + /** + * Spacing of the drawings + * @default 0.5 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + spacingDrawings: number; + /** + * Rotation of the model + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 10 + */ + rotation: number; + /** + * Origin of the model + * @default [0, 0, 0] + */ + origin: Inputs.Base.Point3; + /** + * Direction of the model + * @default [0, 1, 0] + */ + direction: Inputs.Base.Point3; + /** + * Scale of the model + * @default [1, 1, 1] + */ + scale: Inputs.Base.Vector3; + } + declare class DropletsPhoneHolderModelDto { + /** + * The model that represents result of the model + * @default undefined + */ + model: DropletsPhoneHolderData; + } + declare class DropletsPhoneHolderModelDxfDto { + /** + * The model that represents result of the model + * @default undefined + */ + model: DropletsPhoneHolderData; + /** + * The laser cut wires color + * @default #000000 + */ + cutWiresColor: Inputs.Base.Color; + /** + * The laser engraving wires color + * @default #0000ff + */ + engravingWiresColor: Inputs.Base.Color; + /** + * The file name + * @default bitbybit-droplets-phone-holder + */ + fileName: string; + /** + * The angular deflection + * @default 0.1 + * @minimum 0 + * @maximum Infinity + * @step 0.01 + */ + angularDeflection: number; + /** + * The curvature deflection + * @default 0.1 + * @minimum 0 + * @maximum Infinity + * @step 0.001 + */ + curvatureDeflection: number; + /** + * Minimum of points + * @default 2 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + minimumOfPoints: number; + /** + * U tolerance + * @default 1.0e-9 + * @minimum 0 + * @maximum Infinity + * @step 1.0e-9 + */ + uTolerance: number; + /** + * Minimum length + * @default 1.0e-7 + * @minimum 0 + * @maximum Infinity + * @step 1.0e-7 + */ + minimumLength: number; + } + declare class DropletsPhoneHolderModelStepDto { + /** + * The model that represents result of the model + * @default undefined + */ + model: DropletsPhoneHolderData; + /** + * The file name + * @default bitbybit-droplets-phone-holder + */ + fileName: string; + /** + * Adjust Y to Z axis + * @default true + */ + adjustYZ: boolean; + } + } + } + } + + declare namespace Furniture { + declare namespace Chairs { + declare namespace SnakeChair { + declare class SnakeChairData { + type: string; + /** + * The name of the model + */ + name: string; + /** + * Original inputs that were used to create the model + */ + originalInputs: SnakeChairDto; + /** + * Compound shape of the table geometry + */ + compound?: T; + /** + * Representation of table parts that are useful for drawing the object efficiently + */ + drawingPart?: SnakeChairDrawingPart; + /** + * Data that contains information and shapes of the top part of the table + */ + mainPart?: SnakeChairMainPart; + /** + * All the shapes of the vase + */ + shapes?: Models.OCCT.ShapeWithId[]; + } + declare class SnakeChairDrawDto { + /** + * Main material + * @defaul undefined + * @optional true + */ + mainMaterial?: T; + /** + * You can turn off drawing of faces via this property + * @default true + */ + drawFaces: boolean; + /** + * Meshing precision of the drawn model. The lower the number the more precise the drawn model is. Keep in mind that output of this algorithm also contains pure occt shape that can be meshed separately in draw any async commands + * @default 0.001 + * @minimum 0.000001 + * @maximum 5 + * @step 0.001 + */ + precision: number; + /** + * Defines if the edges of the model should be drawn + * @default true + */ + drawEdges: boolean; + /** + * Hex colour string for the edges + * @default #ffffff + */ + edgeColour: Inputs.Base.Color; + /** + * Edge width + * @default 0.06 + * @minimum 0 + * @maximum Infinity + */ + edgeWidth: number; + } + /** + * This defines useful compounded objects for representing model in optimal and fast way. + */ + declare class SnakeChairDrawingPartShapes { + /** + * The representation of main part of the chair + */ + main?: T; + } + /** + * Information needed to draw the part in an optimal way + */ + declare class SnakeChairDrawingPart extends Part { + /** + * Shapes that exist in the drawing part, T can represent opancascade geometry, + * babylonjs mesh, materials or other things that map to these drawing categories. + */ + shapes?: SnakeChairDrawingPartShapes; + } + declare class SnakeChairDtoBase { + sittingHeight: T; + backRestOffset: T; + backRestHeight: T; + width: T; + length: T; + thickness: T; + ornamentDepth: T; + nrOrnamentPlanks: T; + filletRadius: T; + precision: T; + rotation?: T; + scale?: T; + origin?: U; + direction?: U; + } + declare class SnakeChairDto + implements SnakeChairDtoBase + { + constructor( + sittingHeight?: number, + backRestOffset?: number, + backRestHeight?: number, + width?: number, + length?: number, + thickness?: number, + nrOrnamentPlanks?: number, + ornamentDepth?: number, + filletRadius?: number, + precision?: number, + drawEdges?: boolean, + rotation?: number, + scale?: number, + origin?: Inputs.Base.Point3, + direction?: Inputs.Base.Vector3 + ); + /** + * Height of the sitting area + * @default 0.45 + * @minimum 0.1 + * @maximum Infinity + * @step 0.01 + */ + sittingHeight: number; + /** + * Sitting top offset from perpendicular ending of the chair + * @default 0.1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + backRestOffset: number; + /** + * Height of the back rest + * @default 0.7 + * @minimum 0.1 + * @maximum Infinity + * @step 0.01 + */ + backRestHeight: number; + /** + * Width of the table + * @default 0.45 + * @minimum 0 + * @maximum Infinity + * @step 0.01 + */ + width: number; + /** + * Length of the table + * @default 0.45 + * @minimum 0 + * @maximum Infinity + * @step 0.01 + */ + length: number; + /** + * The thickness of the chair + * @default 0.05 + * @minimum 0.01 + * @maximum Infinity + * @step 0.01 + */ + thickness: number; + /** + * The number of ornament planks + * @default 7 + * @minimum 1 + * @maximum Infinity + * @step 1 + */ + nrOrnamentPlanks: number; + /** + * The ornament depth of the chair + * @default 0.01 + * @minimum 0.001 + * @maximum Infinity + * @step 0.001 + */ + ornamentDepth: number; + /** + * The radius of the fillet + * @default 0.05 + * @minimum 0.001 + * @maximum Infinity + * @step 0.01 + */ + filletRadius: number; + /** + * Meshing precision of the drawn model. The lower the number the more precise the drawn model is. Keep in mind that output of this algorithm also contains pure occt shape that can be meshed separately in draw any async commands + * @default 0.01 + * @minimum 0.000001 + * @maximum 5 + * @step 0.001 + */ + precision: number; + /** + * Defines if the edges of the model should be drawn + * @default true + */ + drawEdges: boolean; + /** + * Rotation of the table in degrees + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 10 + */ + rotation: number; + /** + * Scale of the table + * @default 1 + * @minimum 0 + * @maximum Infinity + */ + scale: number; + /** + * Origin of the medal + * @default [0, 0, 0] + */ + origin: Inputs.Base.Point3; + /** + * Direction of the model + * @default [0, 1, 0] + */ + direction: Inputs.Base.Vector3; + } + declare class SnakeChairModelDto { + /** + * The model that represents result of the good coffee table create operation + * @default undefined + */ + model: SnakeChairData; + } + declare class SnakeChairMainPart extends Part { + sittingCenter?: Inputs.Base.Point3; + shapes?: { + sittingWire?: T; + compound?: T; + }; + } + } + } + declare namespace Tables { + declare namespace ElegantTable { + declare class ElegantTableData { + type: string; + /** + * The name of the model + */ + name: string; + /** + * Original inputs that were used to create the model + */ + originalInputs: ElegantTableDto; + /** + * Compound shape of the table geometry + */ + compound?: T; + /** + * Representation of table parts that are useful for drawing the object efficiently + */ + drawingPart?: ElegantTableDrawingPart; + /** + * Data that contains information and shapes of the top part of the table + */ + topPart?: ElegantTableTopPart; + /** + * Data that contains information and shapes repreesenting the legs of the table + */ + legParts?: ElegantTableLegPart[]; + /** + * All the shapes of the vase + */ + shapes?: Models.OCCT.ShapeWithId[]; + } + declare class ElegantTableDrawDto { + /** + * Material of the top of the table + * @defaul undefined + * @optional true + */ + topMaterial?: T; + /** + * Material of the top base of the table + * @defaul undefined + * @optional true + */ + topBaseMaterial?: T; + /** + * Material of the legs of the table + * @defaul undefined + * @optional true + */ + legsMaterial?: T; + /** + * You can turn off drawing of faces via this property + * @default true + */ + drawFaces: boolean; + /** + * Meshing precision of the drawn model. The lower the number the more precise the drawn model is. Keep in mind that output of this algorithm also contains pure occt shape that can be meshed separately in draw any async commands + * @default 0.001 + * @minimum 0.000001 + * @maximum 5 + * @step 0.001 + */ + precision: number; + /** + * Defines if the edges of the model should be drawn + * @default true + */ + drawEdges: boolean; + /** + * Hex colour string for the edges + * @default #ffffff + */ + edgeColour: Inputs.Base.Color; + /** + * Edge width + * @default 0.06 + * @minimum 0 + * @maximum Infinity + */ + edgeWidth: number; + } + /** + * This defines useful compounded objects for representing elegant table in optimal and fast way. + */ + declare class ElegantTableDrawingPartShapes { + /** + * The representation of top of the table + */ + top?: T; + /** + * The representation of base of the table top + */ + topBase?: T; + /** + * The representation of all legs as compound of the table + */ + legs?: T; + } + /** + * Information needed to draw the part in an optimal way + */ + declare class ElegantTableDrawingPart extends Part { + /** + * Shapes that exist in the drawing part, T can represent opancascade geometry, + * babylonjs mesh, materials or other things that map to these drawing categories. + */ + shapes?: ElegantTableDrawingPartShapes; + } + declare class ElegantTableDtoBase { + height: T; + width: T; + length: T; + topThickness: T; + topOffset: T; + bottomThickness: T; + minFillet: T; + radiusLegTop: T; + radiusLegBottom: T; + nrLegPairs: T; + precision: T; + rotation?: T; + scale?: T; + origin?: U; + direction?: U; + } + declare class ElegantTableDto + implements ElegantTableDtoBase + { + constructor( + height?: number, + width?: number, + length?: number, + topThickness?: number, + topOffset?: number, + bottomThickness?: number, + minFillet?: number, + radiusLegTop?: number, + radiusLegBottom?: number, + nrLegPairs?: number, + precision?: number, + drawEdges?: boolean, + rotation?: number, + scale?: number, + origin?: Inputs.Base.Point3, + direction?: Inputs.Base.Vector3 + ); + /** + * Height of the table + * @default 0.74 + * @minimum 0.1 + * @maximum Infinity + * @step 0.01 + */ + height: number; + /** + * Width of the table + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + width: number; + /** + * Length of the table + * @default 2 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + length: number; + /** + * Top thickness of the table + * @default 0.02 + * @minimum 0.001 + * @maximum Infinity + * @step 0.001 + */ + topThickness: number; + /** + * Top offset from the base of the table + * @default 0.03 + * @minimum 0 + * @maximum Infinity + * @step 0.01 + */ + topOffset: number; + /** + * Bottom thickness of the table + * @default 0.05 + * @minimum 0.01 + * @maximum Infinity + * @step 0.01 + */ + bottomThickness: number; + /** + * Fillet table corners + * @default 0.2 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + minFillet: number; + /** + * Radius leg top + * @default 0.03 + * @minimum 0.01 + * @maximum Infinity + * @step 0.01 + */ + radiusLegTop: number; + /** + * Radius leg top + * @default 0.01 + * @minimum 0.01 + * @maximum Infinity + * @step 0.01 + */ + radiusLegBottom: number; + /** + * The number of leg pairs of the table + * @default 2 + * @minimum 2 + * @maximum Infinity + * @step 1 + */ + nrLegPairs: number; + /** + * Meshing precision of the drawn model. The lower the number the more precise the drawn model is. Keep in mind that output of this algorithm also contains pure occt shape that can be meshed separately in draw any async commands + * @default 0.001 + * @minimum 0.000001 + * @maximum 5 + * @step 0.001 + */ + precision: number; + /** + * Defines if the edges of the model should be drawn + * @default true + */ + drawEdges: boolean; + /** + * Rotation of the table in degrees + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 10 + */ + rotation: number; + /** + * Scale of the table + * @default 1 + * @minimum 0 + * @maximum Infinity + */ + scale: number; + /** + * Origin of the medal + * @default [0, 0, 0] + */ + origin: Inputs.Base.Point3; + /** + * Direction of the model + * @default [0, 1, 0] + */ + direction: Inputs.Base.Vector3; + } + declare class ElegantTableLegByIndexDto { + /** + * The model that represents result of the elegant table create operation + * @default undefined + */ + model: ElegantTableData; + /** + * The index of the leg to be returned + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + index: number; + } + declare class ElegantTableLegPart extends Part { + topCenter?: Inputs.Base.Point3; + bottomCenter?: Inputs.Base.Point3; + topRadius?: number; + bottomRadius?: number; + shapes?: { + topCircleWire?: T; + bottomCircleWire?: T; + leg?: T; + }; + } + declare class ElegantTableModelDto { + /** + * The model that represents result of the elegant table create operation + * @default undefined + */ + model: ElegantTableData; + } + declare class ElegantTableTopPart extends Part { + topCenter?: Inputs.Base.Point3; + bottomCenter?: Inputs.Base.Point3; + shapes?: { + topPanel?: T; + topWire?: T; + bottomWire?: T; + bottomPanel?: T; + compound?: T; + }; + } + } + declare namespace GoodCoffeeTable { + declare class GoodCoffeeTableData { + type: string; + /** + * The name of the model + */ + name: string; + /** + * Original inputs that were used to create the model + */ + originalInputs: GoodCoffeeTableDto; + /** + * Compound shape of the table geometry + */ + compound?: T; + /** + * Representation of table parts that are useful for drawing the object efficiently + */ + drawingPart?: GoodCoffeeTableDrawingPart; + /** + * Data that contains information and shapes of the top part of the table + */ + topPart?: GoodCoffeeTableTopPart; + /** + * Data that contains information and shapes of the shelf part of the table + */ + shelfPart?: GoodCoffeeTableShelfPart; + /** + * Data that contains information and shapes repreesenting the legs of the table + */ + legParts?: GoodCoffeeTableLegPart[]; + /** + * All the shapes of the vase + */ + shapes?: Models.OCCT.ShapeWithId[]; + } + declare class GoodCoffeeTableDrawDto { + /** + * Material of the glass + * @defaul undefined + * @optional true + */ + topGlassMaterial?: T; + /** + * Material of the top frame of the table + * @defaul undefined + * @optional true + */ + topMaterial?: T; + /** + * Material of the shelf of the table + * @defaul undefined + * @optional true + */ + shelfMaterial?: T; + /** + * Material of the legs of the table + * @defaul undefined + * @optional true + */ + legsMaterial?: T; + /** + * You can turn off drawing of faces via this property + * @default true + */ + drawFaces: boolean; + /** + * Meshing precision of the drawn model. The lower the number the more precise the drawn model is. Keep in mind that output of this algorithm also contains pure occt shape that can be meshed separately in draw any async commands + * @default 0.001 + * @minimum 0.000001 + * @maximum 5 + * @step 0.001 + */ + precision: number; + /** + * Defines if the edges of the model should be drawn + * @default true + */ + drawEdges: boolean; + /** + * Hex colour string for the edges + * @default #ffffff + */ + edgeColour: Inputs.Base.Color; + /** + * Edge width + * @default 0.06 + * @minimum 0 + * @maximum Infinity + */ + edgeWidth: number; + } + /** + * This defines useful compounded objects for representing elegant table in optimal and fast way. + */ + declare class GoodCoffeeTableDrawingPartShapes { + /** + * The representation of top of the table + */ + top?: T; + /** + * The representation of glass of the table top + */ + topGlass?: T; + /** + * The shelf of the table + */ + shelf?: T; + /** + * The representation of all legs as compound of the table + */ + legs?: T; + } + /** + * Information needed to draw the part in an optimal way + */ + declare class GoodCoffeeTableDrawingPart extends Part { + /** + * Shapes that exist in the drawing part, T can represent opancascade geometry, + * babylonjs mesh, materials or other things that map to these drawing categories. + */ + shapes?: GoodCoffeeTableDrawingPartShapes; + } + declare class GoodCoffeeTableDtoBase { + height: T; + width: T; + length: T; + topThickness: T; + topGlassOffset: T; + glassThickness: T; + glassHolderLength: T; + chamfer: T; + shelfTopOffset: T; + shelfThickness: T; + legWidth: T; + legDepth: T; + precision: T; + rotation?: T; + scale?: T; + origin?: U; + direction?: U; + } + declare class GoodCoffeeTableDto + implements GoodCoffeeTableDtoBase + { + constructor( + height?: number, + width?: number, + length?: number, + chamfer?: number, + topThickness?: number, + topGlassOffset?: number, + glassThickness?: number, + glassHolderLength?: number, + shelfTopOffset?: number, + shelfThickness?: number, + legWidth?: number, + legDepth?: number, + precision?: number, + drawEdges?: boolean, + rotation?: number, + scale?: number, + origin?: Inputs.Base.Point3, + direction?: Inputs.Base.Vector3 + ); + /** + * Height of the table + * @default 0.4 + * @minimum 0.1 + * @maximum Infinity + * @step 0.01 + */ + height: number; + /** + * Width of the table + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + width: number; + /** + * Length of the table + * @default 1.2 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + length: number; + /** + * Chamfer the corners + * @default 0.01 + * @minimum 0 + * @maximum Infinity + * @step 0.001 + */ + chamfer: number; + /** + * Top thickness of the table + * @default 0.05 + * @minimum 0.001 + * @maximum Infinity + * @step 0.001 + */ + topThickness: number; + /** + * Top offset from the edge of the table till the glass + * @default 0.2 + * @minimum 0 + * @maximum Infinity + * @step 0.01 + */ + topGlassOffset: number; + /** + * Glass thickness of the table + * @default 0.005 + * @minimum 0.001 + * @maximum Infinity + * @step 0.001 + */ + glassThickness: number; + /** + * Glass holder length of the table + * @default 0.02 + * @minimum 0.001 + * @maximum Infinity + * @step 0.001 + */ + glassHolderLength: number; + /** + * The offset of the shelf from the bottom of the top - 0 means that no shelf is made as such shelf would be non-functional. + * @default 0.15 + * @minimum 0 + * @maximum Infinity + * @step 0.01 + */ + shelfTopOffset: number; + /** + * Shelf thickness + * @default 0.03 + * @minimum 0.001 + * @maximum Infinity + * @step 0.001 + */ + shelfThickness: number; + /** + * Width of the leg + * @default 0.1 + * @minimum 0.01 + * @maximum Infinity + * @step 0.01 + */ + legWidth: number; + /** + * The depth of the leg + * @default 0.05 + * @minimum 0.01 + * @maximum Infinity + * @step 0.01 + */ + legDepth: number; + /** + * Meshing precision of the drawn model. The lower the number the more precise the drawn model is. Keep in mind that output of this algorithm also contains pure occt shape that can be meshed separately in draw any async commands + * @default 0.001 + * @minimum 0.000001 + * @maximum 5 + * @step 0.001 + */ + precision: number; + /** + * Defines if the edges of the model should be drawn + * @default true + */ + drawEdges: boolean; + /** + * Rotation of the table in degrees + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 10 + */ + rotation: number; + /** + * Scale of the table + * @default 1 + * @minimum 0 + * @maximum Infinity + */ + scale: number; + /** + * Origin of the medal + * @default [0, 0, 0] + */ + origin: Inputs.Base.Point3; + /** + * Direction of the model + * @default [0, 1, 0] + */ + direction: Inputs.Base.Vector3; + } + declare class GoodCoffeeTableLegByIndexDto { + /** + * The model that represents result of the elegant table create operation + * @default undefined + */ + model: GoodCoffeeTableData; + /** + * The index of the leg to be returned + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + index: number; + } + declare class GoodCoffeeTableLegPart extends Part { + topCenter?: Inputs.Base.Point3; + bottomCenter?: Inputs.Base.Point3; + width: number; + depth: number; + height: number; + shapes?: { + topWire?: T; + bottomWire?: T; + leg?: T; + }; + } + declare class GoodCoffeeTableModelDto { + /** + * The model that represents result of the good coffee table create operation + * @default undefined + */ + model: GoodCoffeeTableData; + } + declare class GoodCoffeeTableShelfPart extends Part { + topCenter?: Inputs.Base.Point3; + bottomCenter?: Inputs.Base.Point3; + shapes?: { + topWire?: T; + bottomWire?: T; + compound?: T; + }; + } + declare class GoodCoffeeTableTopPart extends Part { + topCenter?: Inputs.Base.Point3; + shapes?: { + topFrame?: T; + topWire?: T; + glassWire?: T; + glassPanel?: T; + compound?: T; + }; + } + } + declare namespace SnakeTable { + declare class SnakeTableData { + type: string; + /** + * The name of the model + */ + name: string; + /** + * Original inputs that were used to create the model + */ + originalInputs: SnakeTableDto; + /** + * Compound shape of the table geometry + */ + compound?: T; + /** + * Representation of table parts that are useful for drawing the object efficiently + */ + drawingPart?: SnakeTableDrawingPart; + /** + * Data that contains information and shapes of the top part of the table + */ + mainPart?: SnakeTableMainPart; + /** + * All the shapes of the vase + */ + shapes?: Models.OCCT.ShapeWithId[]; + } + declare class SnakeTableDrawDto { + /** + * Main material + * @defaul undefined + * @optional true + */ + mainMaterial?: T; + /** + * Glass material + * @defaul undefined + * @optional true + */ + glassMaterial?: T; + /** + * You can turn off drawing of faces via this property + * @default true + */ + drawFaces: boolean; + /** + * Meshing precision of the drawn model. The lower the number the more precise the drawn model is. Keep in mind that output of this algorithm also contains pure occt shape that can be meshed separately in draw any async commands + * @default 0.001 + * @minimum 0.000001 + * @maximum 5 + * @step 0.001 + */ + precision: number; + /** + * Defines if the edges of the model should be drawn + * @default true + */ + drawEdges: boolean; + /** + * Hex colour string for the edges + * @default #ffffff + */ + edgeColour: Inputs.Base.Color; + /** + * Edge width + * @default 0.06 + * @minimum 0 + * @maximum Infinity + */ + edgeWidth: number; + } + /** + * This defines useful compounded objects for representing model in optimal and fast way. + */ + declare class SnakeTableDrawingPartShapes { + /** + * The representation of main part of the table + */ + main?: T; + /** + * The representation of the glass of the table + */ + glass?: T; + } + /** + * Information needed to draw the part in an optimal way + */ + declare class SnakeTableDrawingPart extends Part { + /** + * Shapes that exist in the drawing part, T can represent opancascade geometry, + * babylonjs mesh, materials or other things that map to these drawing categories. + */ + shapes?: SnakeTableDrawingPartShapes; + } + declare class SnakeTableDtoBase { + height: T; + width: T; + length: T; + supportLength: T; + shelfHeight: T; + glassThickness: T; + glassOffset: T; + thickness: T; + ornamentDepth: T; + nrOrnamentPlanks: T; + filletRadius: T; + precision: T; + rotation?: T; + scale?: T; + origin?: U; + direction?: U; + } + declare class SnakeTableDto + implements SnakeTableDtoBase + { + constructor( + height?: number, + width?: number, + length?: number, + supportLength?: number, + shelfHeight?: number, + thickness?: number, + glassThickness?: number, + glassOffset?: number, + nrOrnamentPlanks?: number, + ornamentDepth?: number, + filletRadius?: number, + precision?: number, + drawEdges?: boolean, + rotation?: number, + scale?: number, + origin?: Inputs.Base.Point3, + direction?: Inputs.Base.Vector3 + ); + /** + * Height of the table + * @default 0.74 + * @minimum 0 + * @maximum Infinity + * @step 0.01 + */ + height: number; + /** + * Width of the table + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.01 + */ + width: number; + /** + * Length of the table + * @default 2 + * @minimum 0 + * @maximum Infinity + * @step 0.01 + */ + length: number; + /** + * The length of the support + * @default 0.5 + * @minimum 0 + * @maximum Infinity + * @step 0.01 + */ + supportLength: number; + /** + * The height of the shelf + * @default 0.2 + * @minimum 0 + * @maximum Infinity + * @step 0.01 + */ + shelfHeight: number; + /** + * The thickness of the table + * @default 0.05 + * @minimum 0.01 + * @maximum Infinity + * @step 0.01 + */ + thickness: number; + /** + * The thickness of the glass + * @default 0.005 + * @minimum 0.001 + * @maximum Infinity + * @step 0.001 + */ + glassThickness: number; + /** + * The glass offset - goes beyond width and length limitations + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 0.01 + */ + glassOffset: number; + /** + * The number of ornament planks + * @default 7 + * @minimum 1 + * @maximum Infinity + * @step 1 + */ + nrOrnamentPlanks: number; + /** + * The ornament depth of the table + * @default 0.01 + * @minimum 0.001 + * @maximum Infinity + * @step 0.001 + */ + ornamentDepth: number; + /** + * The radius of the fillet + * @default 0.05 + * @minimum 0.001 + * @maximum Infinity + * @step 0.01 + */ + filletRadius: number; + /** + * Meshing precision of the drawn model. The lower the number the more precise the drawn model is. Keep in mind that output of this algorithm also contains pure occt shape that can be meshed separately in draw any async commands + * @default 0.01 + * @minimum 0.000001 + * @maximum 5 + * @step 0.001 + */ + precision: number; + /** + * Defines if the edges of the model should be drawn + * @default true + */ + drawEdges: boolean; + /** + * Rotation of the table in degrees + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 10 + */ + rotation: number; + /** + * Scale of the table + * @default 1 + * @minimum 0 + * @maximum Infinity + */ + scale: number; + /** + * Origin of the medal + * @default [0, 0, 0] + */ + origin: Inputs.Base.Point3; + /** + * Direction of the model + * @default [0, 1, 0] + */ + direction: Inputs.Base.Vector3; + } + declare class SnakeTableModelDto { + /** + * The model that represents result of the good coffee table create operation + * @default undefined + */ + model: SnakeTableData; + } + declare class SnakeTableMainPart extends Part { + topCenter?: Inputs.Base.Point3; + shapes?: { + topWire?: T; + glass?: T; + main?: T; + compound?: T; + }; + } + } + } + } + + declare namespace Shared { + declare class Part { + id?: string; + rotation?: number; + center?: Inputs.Base.Point3; + scale?: Inputs.Base.Vector3; + direction?: Inputs.Base.Vector3; + } + } + } + declare namespace Advanced { + declare namespace Enums { + declare enum outputShapeEnum { + wire = "wire", + face = "face", + solid = "solid", + } + } + declare namespace Text3D { + declare class CharacterPart { + id: string; + shapes?: { + compound?: T; + }; + } + declare class FacePart { + id: string; + type: faceTypeEnum; + shapes?: { + face?: T; + }; + } + declare enum faceTextVarEnum { + separatedExtrusion = "separatedExtrusion", + integratedExtrusion = "integratedExtrusion", + cutout = "cutout", + } + declare enum faceTypeEnum { + compound = "compound", + cutout = "originalCutout", + cutoutInsideCharacter = "cutoutInsideCharacter", + } + declare class FontDefinition { + name: string; + type?: fontsEnum; + variant?: fontVariantsEnum; + font: Font; + } + declare const fontsModel: { + key: string; + variants: string[]; + }[]; + declare enum fontVariantsEnum { + Regular = "Regular", + Black = "Black", + Bold = "Bold", + ExtraBold = "ExtraBold", + Medium = "Medium", + SemiBold = "SemiBold", + BlackItalic = "BlackItalic", + BoldItalic = "BoldItalic", + Italic = "Italic", + Light = "Light", + LightItalic = "LightItalic", + MediumItalic = "MediumItalic", + Thin = "Thin", + ThinItalic = "ThinItalic", + ExtraLight = "ExtraLight", + } + declare enum fontsEnum { + Aboreto = "Aboreto", + Bungee = "Bungee", + IndieFlower = "IndieFlower", + Lugrasimo = "Lugrasimo", + Orbitron = "Orbitron", + Roboto = "Roboto", + RobotoSlab = "RobotoSlab", + Silkscreen = "Silkscreen", + Tektur = "Tektur", + Workbench = "Workbench", + } + declare enum recAlignmentEnum { + leftTop = "leftTop", + leftMiddle = "leftMiddle", + leftBottom = "leftBottom", + centerTop = "centerTop", + centerMiddle = "centerMiddle", + centerBottom = "centerBottom", + rightTop = "rightTop", + rightMiddle = "rightMiddle", + rightBottom = "rightBottom", + } + declare class Text3DData { + /** + * Type of the object being configured + */ + type: string; + /** + * Default name of the object + */ + name: string; + /** + * The advance width of the text + */ + advanceWidth: number; + /** + * The bounding box of the text + */ + boundingBox: { + x1: number; + y1: number; + x2: number; + y2: number; + }; + /** + * Original inputs + */ + originalInputs?: Text3DDto | Texts3DFaceDto; + /** + * Compounded shape of the 3d text + */ + compound?: T; + /** + * The parts of letters + */ + characterParts?: CharacterPart[]; + /** + * This only applies if we use 3d text on face algorithms + */ + faceParts?: FacePart[]; + /** + * All the shapes of the 3d text + */ + shapes?: Models.OCCT.ShapeWithId[]; + /** + * All the letter coordinates of the 3d text + */ + characterCenterCoordinates: Inputs.Base.Point3[]; + } + declare class Text3DDto { + constructor( + text?: string, + fontType?: fontsEnum, + fontVariant?: fontVariantsEnum, + fontSize?: number, + height?: number, + rotation?: number, + origin?: Inputs.Base.Vector3, + direction?: Inputs.Base.Vector3, + originAlignment?: recAlignmentEnum + ); + /** + * The type of font to use + * @default bitbybit.dev + */ + text: string; + /** + * The type of font to use + * @default Roboto + */ + fontType: fontsEnum; + /** + * The type of font to use + * @default Regular + */ + fontVariant: fontVariantsEnum; + /** + * The size of the font + * @default 1.5 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + fontSize: number; + /** + * The height of the font extrusion, if 0 then face will be returned and not a solid + * @default 0.2 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + height: number; + /** + * The rotation of the generated text + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 15 + */ + rotation: number; + /** + * Origin of the text + * @default [0, 0, 0] + */ + origin: Inputs.Base.Vector3; + /** + * Direction of the text + * @default [0, 1, 0] + */ + direction: Inputs.Base.Vector3; + /** + * Origin alignment + * @default centerMiddle + */ + originAlignment: recAlignmentEnum; + } + declare class Text3DFaceDefinitionDto { + constructor( + faceTextVar?: faceTextVarEnum, + text?: string, + fontType?: fontsEnum, + fontVariant?: fontVariantsEnum, + fontSize?: number, + height?: number, + rotation?: number, + originParamU?: number, + originParamV?: number, + originAlignment?: recAlignmentEnum + ); + /** + * You can choose how your face text will be constructed. + * Separated extrusion will only return text letters + * Integrated extrusion will create a shell from the extruded text and original face + * Integrated pull in will create a shell from the negative extrusion and original face + * Cutout will return compound with faces that are left after cutting the original face with text + * @default separatedExtrusion + */ + faceTextVar: faceTextVarEnum; + /** + * The type of font to use + * @default bitbybit.dev + */ + text: string; + /** + * The type of font to use + * @default Roboto + */ + fontType: fontsEnum; + /** + * The type of font to use + * @default Regular + */ + fontVariant: fontVariantsEnum; + /** + * The size of the font + * @default 1.5 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + fontSize: number; + /** + * The height of the font extrusion, if 0 then face will be returned and not a solid + * @default 0.2 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + height: number; + /** + * The rotation of the generated text + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 15 + */ + rotation: number; + /** + * Origin u param for the text 0 - 1 + * @default 0.5 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + originParamU: number; + /** + * Origin v param for the text 0 - 1 + * @default 0.5 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + originParamV: number; + /** + * Origin alignment + * @default centerMiddle + */ + originAlignment: recAlignmentEnum; + } + declare class Text3DFaceDefinitionUrlDto { + constructor( + faceTextVar?: faceTextVarEnum, + text?: string, + fontUrl?: string, + fontSize?: number, + height?: number, + rotation?: number, + originParamU?: number, + originParamV?: number, + originAlignment?: recAlignmentEnum + ); + /** + * You can choose how your face text will be constructed. + * Separated extrusion will only return text letters + * Integrated extrusion will create a shell from the extruded text and original face + * Integrated pull in will create a shell from the negative extrusion and original face + * Cutout will return compound with faces that are left after cutting the original face with text + * @default separatedExtrusion + */ + faceTextVar: faceTextVarEnum; + /** + * The type of font to use + * @default bitbybit.dev + */ + text: string; + /** + * The font URL to load and use. If Url is provided then font will be loaded using opentype.js. + * Supported formats are: ttf, otf, woff. + * Please note that Woff2 is not supported by opentype.js as it is a compressed format. + * @default https://cdn.jsdelivr.net/gh/bitbybit-dev/bitbybit-assets@latest/fonts/Tektur/Tektur-Bold.ttf + */ + fontUrl: string; + /** + * The size of the font + * @default 1.5 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + fontSize: number; + /** + * The height of the font extrusion, if 0 then face will be returned and not a solid + * @default 0.2 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + height: number; + /** + * The rotation of the generated text + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 15 + */ + rotation: number; + /** + * Origin u param for the text 0 - 1 + * @default 0.5 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + originParamU: number; + /** + * Origin v param for the text 0 - 1 + * @default 0.5 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + originParamV: number; + /** + * Origin alignment + * @default centerMiddle + */ + originAlignment: recAlignmentEnum; + } + declare class Text3DFaceDefinitionUrlParsedDto { + constructor( + faceTextVar?: faceTextVarEnum, + text?: string, + letterPaths?: any, + fontSize?: number, + height?: number, + rotation?: number, + originParamU?: number, + originParamV?: number, + originAlignment?: recAlignmentEnum + ); + /** + * You can choose how your face text will be constructed. + * Separated extrusion will only return text letters + * Integrated extrusion will create a shell from the extruded text and original face + * Integrated pull in will create a shell from the negative extrusion and original face + * Cutout will return compound with faces that are left after cutting the original face with text + * @default separatedExtrusion + */ + faceTextVar: faceTextVarEnum; + /** + * The type of font to use + * @default bitbybit.dev + */ + text: string; + /** + * The parsed letter paths that were generated by opentype.js + * @default undefined + */ + letterPaths: any; + /** + * The size of the font + * @default 1.5 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + fontSize: number; + /** + * The height of the font extrusion, if 0 then face will be returned and not a solid + * @default 0.2 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + height: number; + /** + * The rotation of the generated text + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 15 + */ + rotation: number; + /** + * Origin u param for the text 0 - 1 + * @default 0.5 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + originParamU: number; + /** + * Origin v param for the text 0 - 1 + * @default 0.5 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + originParamV: number; + /** + * Origin alignment + * @default centerMiddle + */ + originAlignment: recAlignmentEnum; + } + declare class Text3DFaceDto { + constructor( + face?: T, + facePlanar?: boolean, + faceTextVar?: faceTextVarEnum, + text?: string, + fontType?: fontsEnum, + fontVariant?: fontVariantsEnum, + fontSize?: number, + height?: number, + rotation?: number, + originParamU?: number, + originParamV?: number, + originAlignment?: recAlignmentEnum + ); + /** + * The face of the text + * @default undefined + */ + face: T; + /** + * If the face is planar it should be true + * @default false + */ + facePlanar: boolean; + /** + * You can choose how your face text will be constructed. + * Separated extrusion will only return text letters + * Integrated extrusion will create a shell from the extruded text and original face + * Integrated pull in will create a shell from the negative extrusion and original face + * Cutout will return compound with faces that are left after cutting the original face with text + */ + faceTextVar: faceTextVarEnum; + /** + * The type of font to use + * @default bitbybit.dev + */ + text: string; + /** + * The type of font to use + * @default Roboto + */ + fontType: fontsEnum; + /** + * The type of font to use + * @default Regular + */ + fontVariant: fontVariantsEnum; + /** + * The size of the font + * @default 1.5 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + fontSize: number; + /** + * The height of the font extrusion, if 0 then face will be returned and not a solid + * @default 0.2 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + height: number; + /** + * The rotation of the generated text + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 15 + */ + rotation: number; + /** + * Origin u param for the text 0 - 1 + * @default 0.5 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + originParamU: number; + /** + * Origin v param for the text 0 - 1 + * @default 0.5 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + originParamV: number; + /** + * Origin alignment + * @default centerMiddle + */ + originAlignment: recAlignmentEnum; + } + declare class Text3DFaceUrlDto { + constructor( + face?: T, + facePlanar?: boolean, + faceTextVar?: faceTextVarEnum, + text?: string, + fontUrl?: string, + fontSize?: number, + height?: number, + rotation?: number, + originParamU?: number, + originParamV?: number, + originAlignment?: recAlignmentEnum + ); + /** + * The face of the text + * @default undefined + */ + face: T; + /** + * If the face is planar it should be true + * @default false + */ + facePlanar: boolean; + /** + * You can choose how your face text will be constructed. + * Separated extrusion will only return text letters + * Integrated extrusion will create a shell from the extruded text and original face + * Integrated pull in will create a shell from the negative extrusion and original face + * Cutout will return compound with faces that are left after cutting the original face with text + */ + faceTextVar: faceTextVarEnum; + /** + * The type of font to use + * @default bitbybit.dev + */ + text: string; + /** + * The font URL to load and use. If Url is provided then font will be loaded using opentype.js. + * Supported formats are: ttf, otf, woff. + * Please note that Woff2 is not supported by opentype.js as it is a compressed format. + * @default https://cdn.jsdelivr.net/gh/bitbybit-dev/bitbybit-assets@latest/fonts/Tektur/Tektur-Bold.ttf + */ + fontUrl: string; + /** + * The size of the font + * @default 1.5 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + fontSize: number; + /** + * The height of the font extrusion, if 0 then face will be returned and not a solid + * @default 0.2 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + height: number; + /** + * The rotation of the generated text + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 15 + */ + rotation: number; + /** + * Origin u param for the text 0 - 1 + * @default 0.5 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + originParamU: number; + /** + * Origin v param for the text 0 - 1 + * @default 0.5 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + originParamV: number; + /** + * Origin alignment + * @default centerMiddle + */ + originAlignment: recAlignmentEnum; + } + declare class Text3DFaceUrlParsedDto { + constructor( + face?: T, + facePlanar?: boolean, + faceTextVar?: faceTextVarEnum, + text?: string, + letterPaths?: any, + fontSize?: number, + height?: number, + rotation?: number, + originParamU?: number, + originParamV?: number, + originAlignment?: recAlignmentEnum + ); + /** + * The face of the text + * @default undefined + */ + face: T; + /** + * If the face is planar it should be true + * @default false + */ + facePlanar: boolean; + /** + * You can choose how your face text will be constructed. + * Separated extrusion will only return text letters + * Integrated extrusion will create a shell from the extruded text and original face + * Integrated pull in will create a shell from the negative extrusion and original face + * Cutout will return compound with faces that are left after cutting the original face with text + */ + faceTextVar: faceTextVarEnum; + /** + * The type of font to use + * @default bitbybit.dev + */ + text: string; + /** + * The parsed letter paths that were generated by opentype.js + * @default undefined + */ + letterPaths: any; + /** + * The size of the font + * @default 1.5 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + fontSize: number; + /** + * The height of the font extrusion, if 0 then face will be returned and not a solid + * @default 0.2 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + height: number; + /** + * The rotation of the generated text + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 15 + */ + rotation: number; + /** + * Origin u param for the text 0 - 1 + * @default 0.5 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + originParamU: number; + /** + * Origin v param for the text 0 - 1 + * @default 0.5 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + originParamV: number; + /** + * Origin alignment + * @default centerMiddle + */ + originAlignment: recAlignmentEnum; + } + declare class Text3DLetterByIndexDto { + /** + * The model that represents result of the text3d create operation + * @default undefined + */ + model: Text3DData; + /** + * The index of the letter to be returned + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + index: number; + } + declare class Text3DModelDto { + /** + * The model that represents result of the text3d create operation + * @default undefined + */ + model: Text3DData; + } + declare class Text3DUrlDto { + constructor( + text?: string, + fontUrl?: string, + fontSize?: number, + height?: number, + rotation?: number, + origin?: Inputs.Base.Vector3, + direction?: Inputs.Base.Vector3, + originAlignment?: recAlignmentEnum + ); + /** + * The type of font to use + * @default bitbybit.dev + */ + text: string; + /** + * The font URL to load and use. If Url is provided then font will be loaded using opentype.js. + * Supported formats are: ttf, otf, woff. + * Please note that Woff2 is not supported by opentype.js as it is a compressed format. + * @default https://cdn.jsdelivr.net/gh/bitbybit-dev/bitbybit-assets@latest/fonts/Tektur/Tektur-Bold.ttf + */ + fontUrl: string; + /** + * The size of the font + * @default 1.5 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + fontSize: number; + /** + * The height of the font extrusion, if 0 then face will be returned and not a solid + * @default 0.2 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + height: number; + /** + * The rotation of the generated text + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 15 + */ + rotation: number; + /** + * Origin of the text + * @default [0, 0, 0] + */ + origin: Inputs.Base.Vector3; + /** + * Direction of the text + * @default [0, 1, 0] + */ + direction: Inputs.Base.Vector3; + /** + * Origin alignment + * @default centerMiddle + */ + originAlignment: recAlignmentEnum; + } + declare class Text3DUrlParsedDto { + constructor( + text?: string, + letterPaths?: any, + fontSize?: number, + height?: number, + rotation?: number, + origin?: Inputs.Base.Vector3, + direction?: Inputs.Base.Vector3, + originAlignment?: recAlignmentEnum + ); + /** + * The type of font to use + * @default bitbybit.dev + */ + text: string; + /** + * The parsed letter paths that were generated by opentype.js + * @default undefined + */ + letterPaths: any; + /** + * The size of the font + * @default 1.5 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + fontSize: number; + /** + * The height of the font extrusion, if 0 then face will be returned and not a solid + * @default 0.2 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + height: number; + /** + * The rotation of the generated text + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 15 + */ + rotation: number; + /** + * Origin of the text + * @default [0, 0, 0] + */ + origin: Inputs.Base.Vector3; + /** + * Direction of the text + * @default [0, 1, 0] + */ + direction: Inputs.Base.Vector3; + /** + * Origin alignment + * @default centerMiddle + */ + originAlignment: recAlignmentEnum; + } + declare class Texts3DFaceDto { + constructor( + face: T, + facePlanar?: boolean, + definitions?: Text3DFaceDefinitionDto[] + ); + /** + * The face of the text + * @default undefined + */ + face: T; + /** + * If the face is planar it should be true + * @default false + */ + facePlanar: boolean; + /** + * The definitions of texts to create on the face + * @default undefined + */ + definitions: Text3DFaceDefinitionDto[]; + } + declare class Texts3DFaceUrlDto { + constructor( + face: T, + facePlanar?: boolean, + definitions?: Text3DFaceDefinitionUrlDto[] + ); + /** + * The face of the text + * @default undefined + */ + face: T; + /** + * If the face is planar it should be true + * @default false + */ + facePlanar: boolean; + /** + * The definitions of texts to create on the face + * @default undefined + */ + definitions: Text3DFaceDefinitionUrlDto[]; + } + declare class Texts3DFaceUrlParsedDto { + constructor( + face: T, + facePlanar?: boolean, + definitions?: Text3DFaceDefinitionUrlParsedDto[] + ); + /** + * The face of the text + * @default undefined + */ + face: T; + /** + * If the face is planar it should be true + * @default false + */ + facePlanar: boolean; + /** + * The definitions of texts to create on the face + * @default undefined + */ + definitions: Text3DFaceDefinitionUrlParsedDto[]; + } + } + declare namespace Patterns { + declare namespace FacePatterns { + declare namespace PyramidSimple { + declare class PyramidSimpleAffectorsDto { + constructor( + faces?: T[], + affectorPoints?: Inputs.Base.Point3[], + uNumber?: number, + vNumber?: number, + minHeight?: number, + maxHeight?: number, + precision?: number + ); + /** + * The faces on which to apply the pattern + * @default undefined + */ + faces: T[]; + /** + * The affector points affect the height of the pyramid elements. The distance is measured between a center point of the corner points and the attractor point. Then it is remapped to certain values. + * @default undefined + */ + affectorPoints: Inputs.Base.Point3[]; + /** + * The affector radius indicates the limit of affection. Cells heights that are further away from the affector than this radius will not be adjusted. If value is not provided, all affector points will use the radius of 10. + * @default undefined + * @optional true + */ + affectorRadiusList?: number[]; + /** + * The affector factors determine if a given affector attracts (value 0 to 1) or repulses (values -1 to 0) the default height of the pyramid elements. + * If value is not provided, all affector points will use the factor of 1 and will thus attract the heights. + * @default undefined + * @optional true + */ + affectorFactors?: number[]; + /** + * The nr of pyramids along u direction of the face + * @default 10 + * @minimum 1 + * @maximum Infinity + * @step 1 + */ + uNumber: number; + /** + * The nr of pyramids along v direction of the face + * @default 5 + * @minimum 1 + * @maximum Infinity + * @step 1 + */ + vNumber: number; + /** + * The default height for the pyramid if it is not affected by any of the affectors. + * @default 0.2 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + defaultHeight: number; + /** + * Min value to add to the height if affector factor is 1 or subtract from the height if affector factor is -1. + * This adds to the height if the affector factor > 0 and subtracts from the height if the affector factor is < 0. + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + affectMinHeight: number; + /** + * Max value to add to the height if affector factor is 1 or subtract from the height if affector factor is -1. + * This adds to the height if the affector factor > 0 and subtracts from the height if the affector factor is < 0. + * @default 1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + affectMaxHeight: number; + /** + * Meshing precision of the drawn model. The lower the number the more precise the drawn model is. Keep in mind that output of this algorithm also contains pure occt shape that can be meshed separately in draw any async commands + * @default 0.01 + * @minimum 0.000001 + * @maximum 5 + * @step 0.001 + */ + precision: number; + } + declare class PyramidSimpeByIndexDto { + /** + * The model that represents result of the pyramid + * @default undefined + */ + model: PyramidSimpleData; + /** + * The index of pyramid element to be returned + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + index: number; + } + declare class PyramidSimpleCellPart { + id: string; + uIndex: number; + vIndex: number; + cornerPoint1: Inputs.Base.Point3; + cornerPoint2: Inputs.Base.Point3; + cornerPoint3: Inputs.Base.Point3; + cornerPoint4: Inputs.Base.Point3; + cornerNormal1?: Inputs.Base.Vector3; + cornerNormal2?: Inputs.Base.Vector3; + cornerNormal3?: Inputs.Base.Vector3; + cornerNormal4?: Inputs.Base.Vector3; + centerPoint?: Inputs.Base.Point3; + centerNormal?: Inputs.Base.Point3; + topPoint?: Inputs.Base.Point3; + shapes?: { + wire1?: T; + wire2?: T; + wire3?: T; + wire4?: T; + face1?: T; + face2?: T; + face3?: T; + face4?: T; + compound?: T; + }; + } + declare class PyramidSimpleData { + /** + * Type of the object being configured + */ + type: string; + /** + * Default name of the object + */ + name: string; + /** + * Original inputs + */ + originalInputs?: PyramidSimpleDto | PyramidSimpleAffectorsDto; + /** + * Compounded shape of the pyramids + */ + compound?: T; + /** + * All the shapes of the pyramid + */ + shapes?: Models.OCCT.ShapeWithId[]; + /** + * Data that contains information and shapes about each face on which pyramids were computed + */ + faceParts?: PyramidSimpleFacePart[]; + /** + * All the pyramid top coordinates + */ + topCoordinates: Inputs.Base.Point3[]; + } + declare class PyramidSimpleDto { + constructor( + faces?: T[], + uNumber?: number, + vNumber?: number, + height?: number + ); + /** + * The faces on which to apply the pattern + * @default undefined + */ + faces: T[]; + /** + * The nr of pyramids along u direction of the face + * @default 10 + * @minimum 1 + * @maximum Infinity + * @step 1 + */ + uNumber: number; + /** + * The nr of pyramids along v direction of the face + * @default 10 + * @minimum 1 + * @maximum Infinity + * @step 1 + */ + vNumber: number; + /** + * The height of the pyramid + * @default 0.2 + * @minimum -Infinity + * @maximum Infinity + * @step 0.1 + */ + height: number; + /** + * Meshing precision of the drawn model. The lower the number the more precise the drawn model is. Keep in mind that output of this algorithm also contains pure occt shape that can be meshed separately in draw any async commands + * @default 0.01 + * @minimum 0.000001 + * @maximum 5 + * @step 0.001 + */ + precision: number; + } + declare class PyramidSimpleFacePart { + id: string; + /** + * Data that contains information and shapes of the top part of the table + */ + cells?: PyramidSimpleCellPart[]; + shapes?: { + compound?: T; + startPolylineWireU?: T; + startPolylineWireV?: T; + endPolylineWireU?: T; + endPolylineWireV?: T; + compoundPolylineWiresU?: T; + compoundPolylineWiresV?: T; + compoundPolylineWiresUV?: T; + }; + } + declare class PyramidSimpleModelCellDto { + /** + * The part that represents the cell of the pyramid + * @default undefined + */ + cells: PyramidSimpleCellPart; + } + declare class PyramidSimpleModelCellsDto { + /** + * The part that represents the cells of the pyramid + * @default undefined + */ + cells: PyramidSimpleCellPart[]; + } + declare class PyramidSimpleModelCellsIndexDto { + /** + * The part that represents the cells of the pyramid + * @default undefined + */ + cells: PyramidSimpleCellPart[]; + /** + * The index that can represent a corner, face or a wire in the pyramid + * @default 0 + * @minimum 0 + * @maximum 3 + * @step 1 + */ + index: number; + } + declare class PyramidSimpleModelDto { + /** + * The model that represents result of the pyramid create operation + * @default undefined + */ + model: PyramidSimpleData; + } + declare class PyramidSimpleModelFaceCellIndexDto { + /** + * The model that represents result of the pyramid create operation + * @default undefined + */ + model: PyramidSimpleData; + /** + * Face index for the pyramid queries + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + faceIndex: number; + /** + * Cell u index for the pyramid + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + uIndex: number; + /** + * Cell v index for the pyramid + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + vIndex: number; + } + declare class PyramidSimpleModelFaceCellsUIndexDto { + /** + * The model that represents result of the pyramid create operation + * @default undefined + */ + model: PyramidSimpleData; + /** + * Face index for the pyramid queries + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + faceIndex: number; + /** + * U index of the pyramid cells + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + uIndex: number; + } + declare class PyramidSimpleModelFaceCellsVIndexDto { + /** + * The model that represents result of the pyramid create operation + * @default undefined + */ + model: PyramidSimpleData; + /** + * Face index for the pyramid queries + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + faceIndex: number; + /** + * V index of the pyramid cells + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + vIndex: number; + } + declare class PyramidSimpleModelFaceIndexDto { + /** + * The model that represents result of the pyramid create operation + * @default undefined + */ + model: PyramidSimpleData; + /** + * Face index for the pyramid queries + * @default 0 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + faceIndex: number; + } + } + } + } + declare namespace Navigation { + declare class FocusFromAngleDto { + constructor( + meshes?: BABYLON.Mesh[], + includeChildren?: boolean, + orientation?: number[], + distance?: number, + padding?: number, + animationSpeed?: number + ); + /** + * List of meshes to focus on + * @default [] + */ + meshes: BABYLON.Mesh[]; + /** + * Whether to include children when computing bounding boxes + * @default true + */ + includeChildren: boolean; + /** + * Orientation vector indicating the direction from which to view the object + * The camera will be positioned in this direction from the center of the bounding box + * @default [1, 1, 1] + */ + orientation: number[]; + /** + * Distance from the center of the bounding box to position the camera + * If not specified, distance will be automatically calculated based on object size + * @default undefined + * @minimum 0.01 + * @maximum Infinity + * @step 0.1 + * @optional true + */ + distance?: number; + /** + * Padding multiplier to control spacing around objects when distance is auto-calculated + * Higher values = more space around object (camera further away) + * Lower values = tighter framing (camera closer) + * Only applies when distance is not manually specified + * @default 1.5 + * @minimum 0.1 + * @maximum Infinity + * @step 0.1 + */ + padding: number; + /** + * Speed of camera animation in seconds + * @default 1.0 + * @minimum 0.01 + * @maximum Infinity + * @step 0.01 + */ + animationSpeed: number; + } + declare class PointOfInterestDto { + constructor( + name?: string, + position?: Inputs.Base.Point3, + cameraTarget?: Inputs.Base.Point3, + cameraPosition?: Inputs.Base.Point3, + style?: PointOfInterestStyleDto + ); + /** Point of Interest name + * @default Point of Interest + */ + name: string; + /** + * Camera look at point + * @default [0, 1, 0] + */ + position: Inputs.Base.Point3; + /** + * Camera look at point + * @default [0, 0, 0] + */ + cameraTarget: Inputs.Base.Point3; + /** + * Camera position + * @default [10, 10, 10] + */ + cameraPosition: Inputs.Base.Point3; + /** + * Point of Interest style + * @default undefined + * @optional true + */ + style?: PointOfInterestStyleDto; + } + declare class PointOfInterestEntity extends PointOfInterestDto { + type: string; + entityName: string; + } + declare class PointOfInterestStyleDto { + constructor( + pointSize?: number, + pointColor?: string, + hoverPointColor?: string, + pulseColor?: string, + pulseMinSize?: number, + pulseMaxSize?: number, + pulseThickness?: number, + pulseSpeed?: number, + textColor?: string, + hoverTextColor?: string, + textSize?: number, + textFontWeight?: number, + textBackgroundColor?: string, + textBackgroundOpacity?: number, + textBackgroundStroke?: boolean, + textBackgroundStrokeThickness?: number, + textBackgroundRadius?: number, + textPosition?: Inputs.Base.topBottomEnum, + stableSize?: boolean, + alwaysOnTop?: boolean + ); + /** + * Diameter of the central point in pixels + * @default 20 + */ + pointSize?: number; + /** Color of the central point + * @default #ffffff + */ + pointColor?: Inputs.Base.Color; + /** Color of the central point on hover + * @default #0000ff + */ + hoverPointColor?: Inputs.Base.Color; + /** Color of the animated pulse + * @default #ffffff + */ + pulseColor?: Inputs.Base.Color; + /** Hover color of the animated pulse + * @default #0000ff + */ + hoverPulseColor?: Inputs.Base.Color; + /** Smallest diameter of the pulse in pixels + * @default 20 + */ + pulseMinSize?: number; + /** Largest diameter of the pulse in pixels + * @default 50 + */ + pulseMaxSize?: number; + /** Thickness of the pulse ring in pixels + * @default 2 + */ + pulseThickness?: number; + /** Speed multiplier for the pulse animation + * @default 3 + */ + pulseSpeed?: number; + /** Color of the text label + * @default #ffffff + */ + textColor?: Inputs.Base.Color; + /** Color of the text label on hover + * @default #0000ff + */ + hoverTextColor?: Inputs.Base.Color; + /** Font size of the text label in pixels + * @default 14 + */ + textSize?: number; + /** Font weight of the text label + * @default 400 + * @minimum 100 + * @maximum 900 + * @step 100 + */ + textFontWeight?: number; + /** Background color of text label + * @default #000000 + */ + textBackgroundColor?: Inputs.Base.Color; + /** Opacity of text background + * @default 0.0 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + textBackgroundOpacity: number; + /** Whether to show stroke around text background + * @default false + */ + textBackgroundStroke: boolean; + /** Thickness of the stroke around text background + * @default 8 + * @minimum 1 + * @maximum 20 + * @step 1 + */ + textBackgroundStrokeThickness: number; + /** Corner radius for text background rounding + * @default 40 + * @minimum 0 + * @maximum 100 + * @step 5 + */ + textBackgroundRadius: number; + /** Position of the text label relative to the point in screen space (top or bottom) + * @default bottom + */ + textPosition: Inputs.Base.topBottomEnum; + /** Whether the entire point of interest should maintain stable size regardless of camera distance + * @default true + */ + stableSize: boolean; + /** Whether the point of interest should always render on top of other objects + * @default false + */ + alwaysOnTop: boolean; + } + declare class ZoomOnDto { + constructor( + meshes?: BABYLON.Mesh[], + includeChildren?: boolean, + animationSpeed?: number, + offset?: number, + doNotUpdateMaxZ?: boolean + ); + /** + * List of meshes to zoom on + * @default [] + */ + meshes: BABYLON.Mesh[]; + /** + * Whether to include children when analyzing bounding boxes + * @default true + */ + includeChildren: boolean; + /** + * Speed of camera animation in seconds + * @default 0.8 + * @minimum 0.01 + * @maximum Infinity + * @step 0.01 + */ + animationSpeed: number; + /** + * Offset multiplier to control spacing around objects + * Negative values = tighter framing (closer to object) + * 0 = default BabylonJS framing (has built-in padding) + * Positive values = more space around object + * @default 0 + * @minimum -0.9 + * @maximum Infinity + * @step 0.1 + */ + offset: number; + /** + * Whether to prevent updating camera's maxZ (far clipping plane) during zoom + * @default true + */ + doNotUpdateMaxZ: boolean; + } + } + declare namespace Dimensions { + declare class AngularDimensionDto { + constructor( + centerPoint?: Inputs.Base.Point3, + direction1?: Inputs.Base.Vector3, + direction2?: Inputs.Base.Vector3, + radius?: number, + labelOffset?: number, + decimalPlaces?: number, + labelSuffix?: string, + labelOverwrite?: string, + radians?: boolean, + removeTrailingZeros?: boolean, + style?: DimensionStyleDto + ); + /** + * Center point of the angle + * @default [0, 0, 0] + */ + centerPoint: Inputs.Base.Point3; + /** + * First direction vector + * @default [1, 0, 0] + */ + direction1: Inputs.Base.Vector3; + /** + * Second direction vector + * @default [0, 1, 0] + */ + direction2: Inputs.Base.Vector3; + /** + * Radius of the dimension arc + * @default 1 + * @minimum 0.1 + * @maximum Infinity + * @step 0.1 + */ + radius: number; + /** + * Label offset from arc + * @default 0.1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + labelOffset: number; + /** + * Decimal places for angle display + * @default 1 + * @minimum 0 + * @maximum 10 + * @step 1 + */ + decimalPlaces: number; + /** + * Suffix to add to the angle label + * @default ° + */ + labelSuffix: string; + /** + * Override label text with custom expression (supports 'val' for computed value, e.g., '100*val', 'Angle: val°') + * @default 1*val + */ + labelOverwrite: string; + /** + * Whether to display angle in radians + * @default false + */ + radians: boolean; + /** + * Remove trailing zeros from decimal places + * @default false + */ + removeTrailingZeros: boolean; + /** + * Dimension style + * @default undefined + * @optional true + */ + style?: DimensionStyleDto; + } + declare class AngularDimensionEntity extends AngularDimensionDto { + type: string; + entityName: string; + /** Identifier for this dimension entity + * @ignore true + */ + id?: string; + } + declare class DiametralDimensionDto { + constructor( + centerPoint?: Inputs.Base.Point3, + direction?: Inputs.Base.Vector3, + diameter?: number, + labelOffset?: number, + decimalPlaces?: number, + labelSuffix?: string, + labelOverwrite?: string, + showCenterMark?: boolean, + removeTrailingZeros?: boolean, + style?: DimensionStyleDto + ); + /** + * Center point of the circle/arc + * @default [0, 0, 0] + */ + centerPoint: Inputs.Base.Point3; + /** + * Direction vector for diameter line + * @default [1, 0, 0] + */ + direction: Inputs.Base.Vector3; + /** + * Diameter value + * @default 2 + * @minimum 0.01 + * @maximum Infinity + * @step 0.1 + */ + diameter: number; + /** + * Label offset from diameter line + * @default 0.1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + labelOffset: number; + /** + * Decimal places for measurement display + * @default 2 + * @minimum 0 + * @maximum 10 + * @step 1 + */ + decimalPlaces: number; + /** + * Label suffix text + * @default mm + */ + labelSuffix: string; + /** + * Override label text with custom expression (supports 'val' for computed value, e.g., '100*val', '⌀ val mm') + * @default 1*val + */ + labelOverwrite: string; + /** + * Whether to show center mark at center point + * @default true + */ + showCenterMark: boolean; + /** + * Remove trailing zeros from decimal places + * @default false + */ + removeTrailingZeros: boolean; + /** + * Dimension style + * @default undefined + * @optional true + */ + style?: DimensionStyleDto; + } + declare class DiametralDimensionEntity extends DiametralDimensionDto { + type: string; + entityName: string; + /** Identifier for this dimension entity + * @ignore true + */ + id?: string; + } + declare class DimensionStyleDto { + constructor( + lineColor?: string, + lineThickness?: number, + extensionLineLength?: number, + arrowTailLength?: number, + textColor?: string, + textSize?: number, + textFontWeight?: number, + textBackgroundColor?: string, + textBackgroundOpacity?: number, + textBackgroundStroke?: boolean, + textBackgroundStrokeThickness?: number, + textBackgroundRadius?: number, + textStableSize?: boolean, + arrowSize?: number, + arrowColor?: string, + showArrows?: boolean, + textBillboard?: boolean, + occlusionCheckInterval?: number, + alwaysOnTop?: boolean + ); + /** + * Color of dimension lines + * @default #ffffff + */ + lineColor: Inputs.Base.Color; + /** + * Thickness of dimension lines + * @default 0.01 + * @minimum 0.01 + * @maximum 0.5 + * @step 0.01 + */ + lineThickness: number; + /** + * Length of extension lines beyond dimension line + * @default 0.2 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + extensionLineLength: number; + /** + * Length of arrow tail extensions beyond arrow tips + * @default 0.2 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + arrowTailLength: number; + /** + * Color of dimension text + * @default #ffffff + */ + textColor: Inputs.Base.Color; + /** + * Size of dimension text + * @default 16 + * @minimum 0 + * @maximum Infinity + * @step 2 + */ + textSize: number; + /** + * Font weight of dimension text + * @default 400 + * @minimum 100 + * @maximum 900 + * @step 100 + */ + textFontWeight: number; + /** + * Background color of text (if needed) + * @default #000000 + */ + textBackgroundColor: Inputs.Base.Color; + /** + * Opacity of text background + * @default 0.0 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + textBackgroundOpacity: number; + /** + * Whether to show stroke around text background + * @default false + */ + textBackgroundStroke: boolean; + /** + * Thickness of the stroke around text background + * @default 8 + * @minimum 1 + * @maximum 20 + * @step 1 + */ + textBackgroundStrokeThickness: number; + /** + * Corner radius for text background rounding + * @default 40 + * @minimum 0 + * @maximum 100 + * @step 5 + */ + textBackgroundRadius: number; + /** + * Whether text should maintain stable size regardless of camera distance + * @default false + */ + textStableSize: boolean; + /** + * Size of arrow heads + * @default 0.05 + * @minimum 0 + * @maximum Infinity + * @step 0.01 + */ + arrowSize: number; + /** + * Color of arrow heads + * @default #ffffff + */ + arrowColor: Inputs.Base.Color; + /** + * Whether to show arrow heads/cones + * @default true + */ + showArrows: boolean; + /** + * Whether text should billboard (always face camera) + * @default true + */ + textBillboard: boolean; + /** + * How often to check for occlusion in milliseconds (only for GUI modes) + * @default 100 + * @minimum 50 + * @maximum 1000 + * @step 50 + */ + occlusionCheckInterval: number; + /** + * Whether dimensions should always render on top of other objects + * @default false + */ + alwaysOnTop: boolean; + } + declare class LinearDimensionDto { + constructor( + startPoint?: Inputs.Base.Point3, + endPoint?: Inputs.Base.Point3, + direction?: Inputs.Base.Vector3, + labelOffset?: number, + decimalPlaces?: number, + labelSuffix?: string, + labelOverwrite?: string, + removeTrailingZeros?: boolean, + style?: DimensionStyleDto + ); + /** + * Start point of the dimension + * @default [0, 0, 0] + */ + startPoint: Inputs.Base.Point3; + /** + * End point of the dimension + * @default [1, 0, 0] + */ + endPoint: Inputs.Base.Point3; + /** + * Direction vector for dimension line offset + * @default [0, 1, 0] + */ + direction: Inputs.Base.Vector3; + /** + * Label offset from dimension line + * @default 0.1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + labelOffset: number; + /** + * Decimal places for measurement display + * @default 2 + * @minimum 0 + * @maximum 10 + * @step 1 + */ + decimalPlaces: number; + /** + * Label suffix text + * @default mm + */ + labelSuffix: string; + /** + * Override label text with custom expression (supports 'val' for computed value, e.g., '100*val', 'Length: val mm') + * @default 1*val + */ + labelOverwrite: string; + /** + * Remove trailing zeros from decimal places + * @default false + */ + removeTrailingZeros: boolean; + /** + * Dimension style + * @default undefined + * @optional true + */ + style?: DimensionStyleDto; + } + declare class LinearDimensionEntity extends LinearDimensionDto { + type: string; + entityName: string; + /** Identifier for this dimension entity + * @ignore true + */ + id?: string; + } + declare enum ordinateAxisEnum { + x = "x", + y = "y", + z = "z", + } + declare class OrdinateDimensionDto { + constructor( + measurementPoint?: Inputs.Base.Point3, + referencePoint?: Inputs.Base.Point3, + axis?: ordinateAxisEnum, + labelOffset?: number, + decimalPlaces?: number, + labelSuffix?: string, + labelOverwrite?: string, + showLeaderLine?: boolean, + removeTrailingZeros?: boolean, + style?: DimensionStyleDto + ); + /** + * Point to measure coordinate from + * @default [1, 1, 1] + */ + measurementPoint: Inputs.Base.Point3; + /** + * Reference origin point for coordinate system + * @default [0, 0, 0] + */ + referencePoint: Inputs.Base.Point3; + /** + * Which axis coordinate to display (X, Y, or Z) + * @default x + */ + axis: ordinateAxisEnum; + /** + * Label offset from measurement point + * @default 0.5 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + labelOffset: number; + /** + * Decimal places for measurement display + * @default 2 + * @minimum 0 + * @maximum 10 + * @step 1 + */ + decimalPlaces: number; + /** + * Label suffix text + * @default mm + */ + labelSuffix: string; + /** + * Override label text with custom expression (supports 'val' for computed value, e.g., '100*val', 'X: val mm') + * @default 1*val + */ + labelOverwrite: string; + /** + * Whether to show leader line from measurement point to label + * @default true + */ + showLeaderLine: boolean; + /** + * Remove trailing zeros from decimal places + * @default false + */ + removeTrailingZeros: boolean; + /** + * Dimension style + * @default undefined + * @optional true + */ + style?: DimensionStyleDto; + } + declare class OrdinateDimensionEntity extends OrdinateDimensionDto { + type: string; + entityName: string; + /** Identifier for this dimension entity + * @ignore true + */ + id?: string; + } + declare class RadialDimensionDto { + constructor( + centerPoint?: Inputs.Base.Point3, + radiusPoint?: Inputs.Base.Point3, + labelOffset?: number, + decimalPlaces?: number, + labelSuffix?: string, + labelOverwrite?: string, + showDiameter?: boolean, + showCenterMark?: boolean, + removeTrailingZeros?: boolean, + style?: DimensionStyleDto + ); + /** + * Center point of the circle/arc + * @default [0, 0, 0] + */ + centerPoint: Inputs.Base.Point3; + /** + * Point on the radius/perimeter of the circle/arc + * @default [1, 0, 0] + */ + radiusPoint: Inputs.Base.Point3; + /** + * Label offset from radius line + * @default 0.1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + labelOffset: number; + /** + * Decimal places for measurement display + * @default 2 + * @minimum 0 + * @maximum 10 + * @step 1 + */ + decimalPlaces: number; + /** + * Label suffix text + * @default mm + */ + labelSuffix: string; + /** + * Override label text with custom expression (supports 'val' for computed value, e.g., '100*val', 'R val mm') + * @default 1*val + */ + labelOverwrite: string; + /** + * Whether to show diameter instead of radius + * @default false + */ + showDiameter: boolean; + /** + * Whether to show center mark at center point + * @default true + */ + showCenterMark: boolean; + /** + * Remove trailing zeros from decimal places + * @default false + */ + removeTrailingZeros: boolean; + /** + * Dimension style + * @default undefined + * @optional true + */ + style?: DimensionStyleDto; + } + declare class RadialDimensionEntity extends RadialDimensionDto { + type: string; + entityName: string; + /** Identifier for this dimension entity + * @ignore true + */ + id?: string; + } + } + } + + /** + * This should be used only if you want to use only JSCAD worker without other of the bitbybit packages + */ + declare class BitByBitJSCAD { + jscadWorkerManager: JSCADWorkerManager; + jscad: JSCAD; + constructor(); + init(jscad: Worker): void; + } + /** + * Contains various functions for Solid booleans from JSCAD library https://github.com/jscad/OpenJSCAD.org + * Thanks JSCAD community for developing this kernel + */ + declare class JSCADBooleans { + private readonly jscadWorkerManager; + constructor(jscadWorkerManager: JSCADWorkerManager); + /** + * Intersect multiple solid mesh objects + * @param inputs Contains multiple solids for intersection + * @returns Solid mesh + * @group boolean + * @shortname intersect + * @drawable true + */ + intersect( + inputs: Inputs.JSCAD.BooleanObjectsDto + ): Promise; + /** + * Subtract multiple solid mesh objects + * @param inputs Contains multiple solids for subtraction + * @returns Solid mesh + * @group boolean + * @shortname subtract + * @drawable true + */ + subtract( + inputs: Inputs.JSCAD.BooleanObjectsDto + ): Promise; + /** + * Union multiple solid mesh objects + * @param inputs Contains multiple solids for union + * @returns Solid mesh + * @group boolean + * @shortname union + * @drawable true + */ + union( + inputs: Inputs.JSCAD.BooleanObjectsDto + ): Promise; + /** + * Intersect two solid mesh objects + * @param inputs Contains multiple solids for intersection + * @returns Solid mesh + * @group boolean + * @shortname intersect two + * @drawable true + */ + intersectTwo( + inputs: Inputs.JSCAD.BooleanTwoObjectsDto + ): Promise; + /** + * Subtract two solid mesh objects + * @param inputs Contains multiple solids for subtraction + * @returns Solid mesh + * @group boolean + * @shortname subtract two + * @drawable true + */ + subtractTwo( + inputs: Inputs.JSCAD.BooleanTwoObjectsDto + ): Promise; + /** + * Union two solid mesh objects + * @param inputs Contains multiple solids for union + * @returns Solid mesh + * @group boolean + * @shortname union two + * @drawable true + */ + unionTwo( + inputs: Inputs.JSCAD.BooleanTwoObjectsDto + ): Promise; + /** + * Subtract multiple meshes from one mesh object + * @param inputs Contains mesh from which to subtract and multiple meshes for subtraction + * @returns mesh + * @group boolean + * @shortname subtract from + * @drawable true + */ + subtractFrom( + inputs: Inputs.JSCAD.BooleanObjectsFromDto + ): Promise; + } + /** + * Contains functions for colorizing objects + */ + declare class JSCADColors { + private readonly jscadWorkerManager; + constructor(jscadWorkerManager: JSCADWorkerManager); + /** + * Colorizes geometry of jscad. If geometry is in the array it will colorize all items and return them. If geometry is a single item it will return a single item. + * Keep in mind that colorized geometry in jscad will always be drawn in that color even if you try to change it via draw options. + * @param inputs contain geometry and hex color + * @returns Colorized geometry of jsacd + * @group colorize + * @shortname colorize geometry + * @drawable true + */ + colorize( + inputs: Inputs.JSCAD.ColorizeDto + ): Promise; + } + /** + * Contains various functions for Solid expansions from JSCAD library https://github.com/jscad/OpenJSCAD.org + * Thanks JSCAD community for developing this kernel + */ + declare class JSCADExpansions { + private readonly jscadWorkerManager; + constructor(jscadWorkerManager: JSCADWorkerManager); + /** + * Expand geometries of solid category + * @param inputs Contains options and geometries for expansion + * @returns Expanded geometry + * @group expansion + * @shortname expand + * @drawable true + */ + expand( + inputs: Inputs.JSCAD.ExpansionDto + ): Promise; + /** + * Offset 2d geometries of solid category + * @param inputs Contains options and geometries for offset + * @returns Expanded geometry + * @group expansion + * @shortname offset + * @drawable true + */ + offset( + inputs: Inputs.JSCAD.ExpansionDto + ): Promise; + } + /** + * Contains various functions for Solid extrusions from JSCAD library https://github.com/jscad/OpenJSCAD.org + * Thanks JSCAD community for developing this kernel + */ + declare class JSCADExtrusions { + private readonly jscadWorkerManager; + constructor(jscadWorkerManager: JSCADWorkerManager); + /** + * Linear extrude 2D geometries of solid category + * @param inputs Contains options and geometries for linear extrude + * @returns Extruded geometry + * @group extrude + * @shortname linear + * @drawable true + */ + extrudeLinear( + inputs: Inputs.JSCAD.ExtrudeLinearDto + ): Promise; + /** + * Rectangular extrude 2D geometries of solid category. Creates a wall-type extrusion of certain height and size. + * @param inputs Contains options and geometries for rectangular extrude + * @returns Extruded geometry + * @group extrude + * @shortname rectangular + * @drawable true + */ + extrudeRectangular( + inputs: Inputs.JSCAD.ExtrudeRectangularDto + ): Promise; + /** + * Rectangular extrude a list of 2D points. Creates a wall-type extrusion of certain height and size. + * @param inputs Contains options and points for extrusion + * @returns Extruded geometry + * @group extrude + * @shortname rectangular points + * @drawable true + */ + extrudeRectangularPoints( + inputs: Inputs.JSCAD.ExtrudeRectangularPointsDto + ): Promise; + /** + * Rectangular extrude a list of 2D points. Creates a wall-type extrusion of certain height and size. + * @param inputs Contains options and points for extrusion + * @returns Extruded geometry + * @group extrude + * @shortname rotational + * @drawable true + */ + extrudeRotate( + inputs: Inputs.JSCAD.ExtrudeRotateDto + ): Promise; + } + /** + * Contains various functions for Solid hulls from JSCAD library https://github.com/jscad/OpenJSCAD.org + * Thanks JSCAD community for developing this kernel + */ + declare class JSCADHulls { + private readonly jscadWorkerManager; + constructor(jscadWorkerManager: JSCADWorkerManager); + /** + * Hull chain connects solids or 2d geometries by filling an empty space in between objects in order. + * Geometries need to be of the same type. + * @param inputs Geometries + * @returns Chain hulled geometry + * @group hulls + * @shortname hull chain + * @drawable true + */ + hullChain(inputs: Inputs.JSCAD.HullDto): Promise; + /** + * Convex hull connects solids or 2d geometries by filling an empty space in between without following order. + * Geometries need to be of the same type. + * @param inputs Geometries + * @returns Hulled geometry + * @group hulls + * @shortname hull + * @drawable true + */ + hull(inputs: Inputs.JSCAD.HullDto): Promise; + } + /** + * Contains various functions for Solid meshes from JSCAD library https://github.com/jscad/OpenJSCAD.org + * Thanks JSCAD community for developing this kernel + */ + declare class JSCAD { + private readonly jscadWorkerManager; + readonly booleans: JSCADBooleans; + readonly expansions: JSCADExpansions; + readonly extrusions: JSCADExtrusions; + readonly hulls: JSCADHulls; + readonly path: JSCADPath; + readonly polygon: JSCADPolygon; + readonly shapes: JSCADShapes; + readonly text: JSCADText; + readonly colors: JSCADColors; + constructor(jscadWorkerManager: JSCADWorkerManager); + /** + * Converts the Jscad mesh to polygon points representing triangles of the mesh. + * @param inputs Jscad mesh + * @returns polygon points + * @group conversions + * @shortname to polygon points + * @drawable false + */ + toPolygonPoints(inputs: Inputs.JSCAD.MeshDto): Promise; + /** + * Transforms the Jscad solid meshes with a given list of transformations. + * @param inputs Solids with the transformation matrixes + * @returns Solids with a transformation + * @group transforms + * @shortname transform solids + * @drawable true + */ + transformSolids( + inputs: Inputs.JSCAD.TransformSolidsDto + ): Promise; + /** + * Transforms the Jscad solid mesh with a given list of transformations. + * @param inputs Solid with the transformation matrixes + * @returns Solid with a transformation + * @group transforms + * @shortname transform solid + * @drawable true + */ + transformSolid( + inputs: Inputs.JSCAD.TransformSolidDto + ): Promise; + /** + * Downloads the binary STL file from a 3D solid + * @param inputs 3D Solid + * @group io + * @shortname solid to stl + */ + downloadSolidSTL(inputs: Inputs.JSCAD.DownloadSolidDto): Promise; + /** + * Downloads the binary STL file from a 3D solids + * @param inputs 3D Solid + * @group io + * @shortname solids to stl + */ + downloadSolidsSTL(inputs: Inputs.JSCAD.DownloadSolidsDto): Promise; + /** + * Downloads the dxf file from jscad geometry. Supports paths and meshes in array. + * @param inputs 3D geometry + * @group io + * @shortname geometry to dxf + */ + downloadGeometryDxf( + inputs: Inputs.JSCAD.DownloadGeometryDto + ): Promise; + /** + * Downloads the 3MF file from jscad geometry. + * @param inputs 3D geometry + * @group io + * @shortname geometry to 3mf + */ + downloadGeometry3MF( + inputs: Inputs.JSCAD.DownloadGeometryDto + ): Promise; + private downloadFile; + } + /** + * Contains various functions for Path from JSCAD library https://github.com/jscad/OpenJSCAD.org + * Thanks JSCAD community for developing this kernel + */ + declare class JSCADPath { + private readonly jscadWorkerManager; + constructor(jscadWorkerManager: JSCADWorkerManager); + /** + * Create a 2D path from a list of points + * @param inputs Points and indication if we want a closed path or not + * @returns Path + * @group from + * @shortname points + * @drawable true + */ + createFromPoints( + inputs: Inputs.JSCAD.PathFromPointsDto + ): Promise; + /** + * Create 2D paths from a lists of points + * @param inputs Points lists + * @returns Paths + * @group from + * @shortname paths from points + * @drawable true + */ + createPathsFromPoints( + inputs: Inputs.JSCAD.PathsFromPointsDto + ): Promise; + /** + * Create a 2D path from a polyline + * @param inputs Polyline and indication if we want a closed path or not + * @returns Path + * @group from + * @shortname polyline + * @drawable true + */ + createFromPolyline( + inputs: Inputs.JSCAD.PathFromPolylineDto + ): Promise; + /** + * Create empty 2D path + * @returns Empty path + * @group create + * @shortname empty + * @drawable false + */ + createEmpty(): Promise; + /** + * Closes an open 2D path + * @param inputs Path + * @returns Closed path + * @group edit + * @shortname close + * @drawable true + */ + close(inputs: Inputs.JSCAD.PathDto): Promise; + /** + * Append the path with 2D points + * @param inputs Path to append and points + * @returns Appended path + * @group append + * @shortname points + * @drawable true + */ + appendPoints( + inputs: Inputs.JSCAD.PathAppendPointsDto + ): Promise; + /** + * Append the path with polyline + * @param inputs Path to append and polyline + * @returns Appended path + * @group append + * @shortname polyline + * @drawable true + */ + appendPolyline( + inputs: Inputs.JSCAD.PathAppendPolylineDto + ): Promise; + /** + * Append the arc to the path + * @param inputs Path and arc parameters + * @returns Appended path + * @group append + * @shortname arc + * @drawable true + */ + appendArc( + inputs: Inputs.JSCAD.PathAppendArcDto + ): Promise; + } + /** + * Contains various functions for Polygon from JSCAD library https://github.com/jscad/OpenJSCAD.org + * Thanks JSCAD community for developing this kernel + */ + declare class JSCADPolygon { + private readonly jscadWorkerManager; + constructor(jscadWorkerManager: JSCADWorkerManager); + /** + * Create a 2D polygon from a list of points + * @param inputs Points + * @returns Polygons + * @group from + * @shortname polygon from points + * @drawable true + */ + createFromPoints( + inputs: Inputs.JSCAD.PointsDto + ): Promise; + /** + * Create a 2D polygon from a polyline + * @param inputs Polyline + * @returns Polygon + * @group from + * @shortname polyline + * @drawable true + */ + createFromPolyline( + inputs: Inputs.JSCAD.PolylineDto + ): Promise; + /** + * Create a 2D polygon from a curve + * @param inputs Nurbs curve + * @returns Polygon + * @group from + * @shortname curve + * @drawable true + */ + createFromCurve( + inputs: Inputs.JSCAD.CurveDto + ): Promise; + /** + * Create a 2D polygon from a path + * @param inputs Path + * @returns Polygon + * @group from + * @shortname path + * @drawable true + */ + createFromPath( + inputs: Inputs.JSCAD.PathDto + ): Promise; + /** + * Create a 2D polygon circle + * @param inputs Circle parameters + * @returns Circle polygon + * @group primitives + * @shortname circle + * @drawable true + */ + circle(inputs: Inputs.JSCAD.CircleDto): Promise; + /** + * Create a 2D polygon ellipse + * @param inputs Ellipse parameters + * @returns Ellipse polygon + * @group primitives + * @shortname ellipse + * @drawable true + */ + ellipse(inputs: Inputs.JSCAD.EllipseDto): Promise; + /** + * Create a 2D polygon rectangle + * @param inputs Rectangle parameters + * @returns Rectangle polygon + * @group primitives + * @shortname rectangle + * @drawable true + */ + rectangle( + inputs: Inputs.JSCAD.RectangleDto + ): Promise; + /** + * Create a 2D rounded rectangle + * @param inputs Rounded rectangle parameters + * @returns Rounded rectangle polygon + * @group primitives + * @shortname rounded rectangle + * @drawable true + */ + roundedRectangle( + inputs: Inputs.JSCAD.RoundedRectangleDto + ): Promise; + /** + * Create a 2D polygon square + * @param inputs Square parameters + * @returns Square polygon + * @group primitives + * @shortname square + * @drawable true + */ + square(inputs: Inputs.JSCAD.SquareDto): Promise; + /** + * Create a 2D polygon star + * @param inputs Star parameters + * @returns Star polygon + * @group primitives + * @shortname star + * @drawable true + */ + star(inputs: Inputs.JSCAD.StarDto): Promise; + } + /** + * Contains various functions for solid 3D shapes from JSCAD library https://github.com/jscad/OpenJSCAD.org + * Thanks JSCAD community for developing this kernel + */ + declare class JSCADShapes { + private readonly jscadWorkerManager; + constructor(jscadWorkerManager: JSCADWorkerManager); + /** + * Create a 3D cube shape + * @param inputs Cube parameters + * @returns Cube solid + * @group primitives + * @shortname cube + * @drawable true + */ + cube(inputs: Inputs.JSCAD.CubeDto): Promise; + /** + * Create a 3D cubes on multiple center points + * @param inputs Cube with multiple center points parameters + * @returns List of cube solids + * @group primitives on centers + * @shortname cubes + * @drawable true + */ + cubesOnCenterPoints( + inputs: Inputs.JSCAD.CubeCentersDto + ): Promise; + /** + * Create a 3D cuboid shape + * @param inputs Cuboid parameters + * @returns Cuboid solid + * @group primitives + * @shortname cuboid + * @drawable true + */ + cuboid(inputs: Inputs.JSCAD.CuboidDto): Promise; + /** + * Create a 3D cuboids on multiple center points + * @param inputs Cuboids with multiple center point parameters + * @returns List of cuboid solids + * @group primitives on centers + * @shortname cuboids + * @drawable true + */ + cuboidsOnCenterPoints( + inputs: Inputs.JSCAD.CuboidCentersDto + ): Promise; + /** + * Create a 3D elliptic cylinder solid + * @param inputs Elliptic cylinder parameters + * @returns Elliptic cylinder solid + * @group primitives + * @shortname cylinder elliptic + * @drawable true + */ + cylinderElliptic( + inputs: Inputs.JSCAD.CylidnerEllipticDto + ): Promise; + /** + * Create a 3D elliptic cylinders on multiple center points + * @param inputs Elliptic cylinders with multiple center point parameters + * @returns List of elliptic cylinders solids + * @group primitives on centers + * @shortname cylinder elliptic + * @drawable true + */ + cylinderEllipticOnCenterPoints( + inputs: Inputs.JSCAD.CylidnerCentersEllipticDto + ): Promise; + /** + * Create a 3D cylinder solid + * @param inputs Cylinder parameters + * @returns Cylinder solid + * @group primitives + * @shortname cylinder + * @drawable true + */ + cylinder( + inputs: Inputs.JSCAD.CylidnerDto + ): Promise; + /** + * Create a 3D cylinders on multiple center points + * @param inputs Cylinders with multiple center point parameters + * @returns List of cylinder solids + * @group primitives on centers + * @shortname cylinder + * @drawable true + */ + cylindersOnCenterPoints( + inputs: Inputs.JSCAD.CylidnerCentersDto + ): Promise; + /** + * Create a 3D ellipsoid solid + * @param inputs Ellipsoid parameters + * @returns Ellipsoid solid + * @group primitives + * @shortname ellipsoid + * @drawable true + */ + ellipsoid( + inputs: Inputs.JSCAD.EllipsoidDto + ): Promise; + /** + * Create a 3D ellipsoids on multiple center points + * @param inputs Ellipsoid parameters with multiple center points + * @returns List of ellipsoid solids + * @group primitives on centers + * @shortname ellipsoid + * @drawable true + */ + ellipsoidsOnCenterPoints( + inputs: Inputs.JSCAD.EllipsoidCentersDto + ): Promise; + /** + * Create a 3D geodesic sphere solid + * @param inputs Geodesic sphere parameters + * @returns Geodesic sphere solid + * @group primitives + * @shortname geodesic sphere + * @drawable true + */ + geodesicSphere( + inputs: Inputs.JSCAD.GeodesicSphereDto + ): Promise; + /** + * Create a 3D geodesic spheres on multiple center points + * @param inputs Geodesic sphere parameters with multiple center points + * @returns List of geodesic spheres + * @group primitives on centers + * @shortname geodesic sphere + * @drawable true + */ + geodesicSpheresOnCenterPoints( + inputs: Inputs.JSCAD.GeodesicSphereCentersDto + ): Promise; + /** + * Create a 3D rounded cuboid solid + * @param inputs Rounded cuboid parameters + * @returns Rounded cuboid solid + * @group primitives + * @shortname rounded cuboid + * @drawable true + */ + roundedCuboid( + inputs: Inputs.JSCAD.RoundedCuboidDto + ): Promise; + /** + * Create a 3D rounded cuboids on multiple center points + * @param inputs Rounded cuboids parameters with multiple center points + * @returns List of rounded cuboids + * @group primitives on centers + * @shortname rounded cuboid + * @drawable true + */ + roundedCuboidsOnCenterPoints( + inputs: Inputs.JSCAD.RoundedCuboidCentersDto + ): Promise; + /** + * Create a 3D rounded cylinder solid + * @param inputs Rounded cylinder parameters + * @returns Rounded cylinder solid + * @group primitives + * @shortname rounded cylinder + * @drawable true + */ + roundedCylinder( + inputs: Inputs.JSCAD.RoundedCylidnerDto + ): Promise; + /** + * Create a 3D rounded cylinders on multiple center points + * @param inputs Rounded cylinders parameters with multiple center points + * @returns List of rounded cylinders + * @group primitives on centers + * @shortname rounded cylinder + * @drawable true + */ + roundedCylindersOnCenterPoints( + inputs: Inputs.JSCAD.RoundedCylidnerCentersDto + ): Promise; + /** + * Create a 3D sphere solid + * @param inputs Sphere parameters + * @returns Sphere solid + * @group primitives + * @shortname sphere + * @drawable true + */ + sphere(inputs: Inputs.JSCAD.SphereDto): Promise; + /** + * Create a 3D sphere on multiple center points + * @param inputs Sphere parameters with multiple center points + * @returns List of spheres + * @group primitives on centers + * @shortname sphere + * @drawable true + */ + spheresOnCenterPoints( + inputs: Inputs.JSCAD.SphereCentersDto + ): Promise; + /** + * Create a 3D torus solid + * @param inputs Torus parameters + * @returns Torus solid + * @group primitives + * @shortname torus + * @drawable true + */ + torus(inputs: Inputs.JSCAD.TorusDto): Promise; + /** + * Create a 3D shape from poylgon points that have to be nested arrays of points + * @param inputs points + * @returns shape + * @group shapes + * @shortname from polygon points + * @drawable true + */ + fromPolygonPoints( + inputs: Inputs.JSCAD.FromPolygonPoints + ): Promise; + } + /** + * Contains various functions for solid 3D texts from JSCAD library https://github.com/jscad/OpenJSCAD.org + * Thanks JSCAD community for developing this kernel + */ + declare class JSCADText { + private readonly jscadWorkerManager; + constructor(jscadWorkerManager: JSCADWorkerManager); + /** + * Creates a text that is based on chain hulling cylinders + * @param inputs Cylindrical text parameters + * @returns List of solids for text + * @group text + * @shortname cylindrical + * @drawable true + */ + cylindricalText( + inputs: Inputs.JSCAD.CylinderTextDto + ): Promise; + /** + * Creates a text that is based on chain hulling spheres + * @param inputs Spherical text parameters + * @returns List of solids for text + * @group text + * @shortname spherical + * @drawable true + */ + sphericalText( + inputs: Inputs.JSCAD.SphereTextDto + ): Promise; + /** + * Creates a vector text + * @param inputs Vector text parameters + * @returns List of polygons + * @group text + * @shortname vector + * @drawable false + */ + createVectorText( + inputs: Inputs.JSCAD.TextDto + ): Promise; + } + /** + * This should be used only if you want to use only Manifold worker without other of the bitbybit packages + */ + declare class BitByBitManifold { + manifoldWorkerManager: ManifoldWorkerManager; + manifold: ManifoldBitByBit; + constructor(); + init(manifold: Worker): void; + } + /** + * Contains various functions for Solid meshes from Manifold library https://github.com/elalish/manifold + * Thanks Manifold community for developing this kernel + */ + declare class CrossSectionBooleans { + private readonly manifoldWorkerManager; + constructor(manifoldWorkerManager: ManifoldWorkerManager); + /** + * Subtract two cross sections + * @param inputs two cross sections + * @returns subtracted cross section + * @group a to b + * @shortname subtract + * @drawable true + */ + subtract( + inputs: Inputs.Manifold.TwoCrossSectionsDto + ): Promise; + /** + * Add two cross sections + * @param inputs two cross sections + * @returns unioned cross section + * @group a to b + * @shortname add + * @drawable true + */ + add( + inputs: Inputs.Manifold.TwoCrossSectionsDto + ): Promise; + /** + * Intersect two cross sections + * @param inputs two cross sections + * @returns intersected cross section + * @group a to b + * @shortname intersect + * @drawable true + */ + intersect( + inputs: Inputs.Manifold.TwoCrossSectionsDto + ): Promise; + /** + * Difference of two cross sections + * @param inputs two cross sections + * @returns difference of two cross sections + * @group 2 cross sections + * @shortname difference 2 cs + * @drawable true + */ + differenceTwo( + inputs: Inputs.Manifold.TwoCrossSectionsDto + ): Promise; + /** + * Union of two cross sections + * @param inputs two cross sections + * @returns union of two cross sections + * @group 2 cross sections + * @shortname union 2 cs + * @drawable true + */ + unionTwo( + inputs: Inputs.Manifold.TwoCrossSectionsDto + ): Promise; + /** + * Intersection of two cross sections + * @param inputs two shapes + * @returns intersection of two cross sections + * @group 2 cross sections + * @shortname intersect 2 cs + * @drawable true + */ + intersectionTwo( + inputs: Inputs.Manifold.TwoCrossSectionsDto + ): Promise; + /** + * Difference of multiple cross sections + * @param inputs multiple cross sections + * @returns difference of cross sections + * @group multiple + * @shortname diff cross sections + * @drawable true + */ + difference( + inputs: Inputs.Manifold.CrossSectionsDto + ): Promise; + /** + * Union of multiple cross sections + * @param inputs multiple cross sections + * @returns union of two cross sections + * @group multiple + * @shortname union cross sections + * @drawable true + */ + union( + inputs: Inputs.Manifold.CrossSectionsDto + ): Promise; + /** + * Intersection of multiple cross sections + * @param inputs two cross sections + * @returns intersection of multiple cross sections + * @group multiple + * @shortname intersection cross sections + * @drawable true + */ + intersection( + inputs: Inputs.Manifold.CrossSectionsDto + ): Promise; + } + /** + * Contains various functions for Solid meshes from Manifold library https://github.com/elalish/manifold + * Thanks Manifold community for developing this kernel + */ + declare class ManifoldCrossSection { + private readonly manifoldWorkerManager; + shapes: CrossSectionShapes; + operations: CrossSectionOperations; + booleans: CrossSectionBooleans; + transforms: CrossSectionTransforms; + evaluate: CrossSectionEvaluate; + constructor(manifoldWorkerManager: ManifoldWorkerManager); + /** + * Creates a cross section from a single polygon points + * @param inputs polygon points + * @returns cross section + * @group create + * @shortname cross section from points + * @drawable true + */ + crossSectionFromPoints( + inputs: Inputs.Manifold.CrossSectionFromPolygonPointsDto + ): Promise; + /** + * Creates a cross section from multiple polygons points + * @param inputs polygons points + * @returns cross section + * @group create + * @shortname cross section from polygons + * @drawable true + */ + crossSectionFromPolygons( + inputs: Inputs.Manifold.CrossSectionFromPolygonsPointsDto + ): Promise; + /** + * Turns cross section into polygons + * @param inputs cross section + * @returns polygons + * @group decompose + * @shortname cross section to polygons + * @drawable false + */ + crossSectionToPolygons( + inputs: Inputs.Manifold.CrossSectionDto + ): Promise; + /** + * Extracts points from a cross section + * @param inputs cross section + * @returns points + * @group decompose + * @shortname cross section to points + * @drawable false + */ + crossSectionToPoints( + inputs: Inputs.Manifold.CrossSectionDto + ): Promise; + /** + * Turns cross sections into polygons + * @param inputs cross sections + * @returns polygons + * @group decompose + * @shortname cross sections to polygons + * @drawable false + */ + crossSectionsToPolygons( + inputs: Inputs.Manifold.CrossSectionsDto + ): Promise; + /** + * Extracts points from cross sections + * @param inputs cross sections + * @returns points + * @group decompose + * @shortname cross sections to points + * @drawable false + */ + crossSectionsToPoints( + inputs: Inputs.Manifold.CrossSectionsDto + ): Promise; + } + /** + * Contains various functions for Solid meshes from Manifold library https://github.com/elalish/manifold + * Thanks Manifold community for developing this kernel + */ + declare class CrossSectionEvaluate { + private readonly manifoldWorkerManager; + constructor(manifoldWorkerManager: ManifoldWorkerManager); + /** + * Get area of cross section + * @param inputs cross section + * @returns area of cross section + * @group basic + * @shortname area + * @drawable false + */ + area( + inputs: Inputs.Manifold.CrossSectionDto + ): Promise; + /** + * Check if cross section is empty + * @param inputs cross section + * @returns boolean indicating emptyness + * @group basic + * @shortname is empty + * @drawable false + */ + isEmpty( + inputs: Inputs.Manifold.CrossSectionDto + ): Promise; + /** + * Get number of vertices in cross section + * @param inputs cross section + * @returns number of vertices of cross section + * @group basic + * @shortname num vert + * @drawable false + */ + numVert( + inputs: Inputs.Manifold.CrossSectionDto + ): Promise; + /** + * Get number of contours in cross section + * @param inputs cross section + * @returns number of contour of cross section + * @group basic + * @shortname num contour + * @drawable false + */ + numContour( + inputs: Inputs.Manifold.CrossSectionDto + ): Promise; + /** + * Get the bounds of the contour as a rectangle. Output is given in two vec2 points in the array. First array is the min point and second array is the max point. + * @param inputs cross section + * @returns bounds of cross section + * @group basic + * @shortname bounds + * @drawable false + */ + bounds( + inputs: Inputs.Manifold.CrossSectionDto + ): Promise; + } + /** + * Contains various functions for Solid meshes from Manifold library https://github.com/elalish/manifold + * Thanks Manifold community for developing this kernel + */ + declare class CrossSectionOperations { + private readonly manifoldWorkerManager; + constructor(manifoldWorkerManager: ManifoldWorkerManager); + /** + * Compute convex hull for the cross section + * @param inputs cross section + * @returns hulled cross section + * @group basic + * @shortname hull + * @drawable true + */ + hull( + inputs: Inputs.Manifold.CrossSectionDto + ): Promise; + /** + * Extrude the cross section to create a 3D shape + * @param inputs cross section and extrusion parameters + * @returns extruded manifold shape + * @group basic + * @shortname extrude + * @drawable true + */ + extrude( + inputs: Inputs.Manifold.ExtrudeDto + ): Promise; + /** + * Revolve the cross section to create a 3D shape + * @param inputs cross section and extrusion parameters + * @returns extruded manifold shape + * @group basic + * @shortname revolve + * @drawable true + */ + revolve( + inputs: Inputs.Manifold.RevolveDto + ): Promise; + /** + * Offsets the cross section to create a new cross section with a given delta (uses Clipper2 algorithm behind). + * @param inputs cross section and offset parameters + * @returns offset cross section + * @group basic + * @shortname offset + * @drawable true + */ + offset( + inputs: Inputs.Manifold.OffsetDto + ): Promise; + /** + * Remove vertices from the contours in this CrossSection that are less than + * the specified distance epsilon from an imaginary line that passes through + * its two adjacent vertices. Near duplicate vertices and collinear points + * will be removed at lower epsilons, with elimination of line segments + * becoming increasingly aggressive with larger epsilons. + * + * It is recommended to apply this function following Offset, in order to + * clean up any spurious tiny line segments introduced that do not improve + * offseting operations are to be performed, which would compound the issue. + * @param inputs cross section and epsilon parameters + * @returns simplified cross section + * @group basic + * @shortname simplify + * @drawable true + */ + simplify( + inputs: Inputs.Manifold.SimplifyDto + ): Promise; + /** + * Composes multiple cross sections or polygons into a single cross section + * @param inputs cross sections or polygons + * @returns composed cross section + * @group composition + * @shortname compose + * @drawable true + */ + compose( + inputs: Inputs.Manifold.ComposeDto< + (Inputs.Manifold.CrossSectionPointer | Inputs.Base.Vector2[])[] + > + ): Promise; + /** + * Decompose cross sections that are topologically + * disconnected, each containing one outline contour with zero or more + * holes. + * @param inputs cross section + * @returns decomposed cross sections + * @group composition + * @shortname decompose + * @drawable true + */ + decompose( + inputs: Inputs.Manifold.CrossSectionDto + ): Promise; + } + /** + * Contains various functions for making shapes Manifold library https://github.com/elalish/manifold + * Thanks Manifold community for developing this kernel + */ + declare class CrossSectionShapes { + private readonly manifoldWorkerManager; + constructor(manifoldWorkerManager: ManifoldWorkerManager); + /** + * Create a 2d cross-section from a set of contours (complex polygons). A + * boolean union operation (with Positive filling rule by default) is + * performed to combine overlapping polygons and ensure the resulting + * CrossSection is free of intersections. + * @param inputs polygons and fill rule + * @returns cross section + * @group base + * @shortname create + * @drawable true + */ + create( + inputs: Inputs.Manifold.CreateContourSectionDto + ): Promise; + /** + * Create a 2D square cross section + * @param inputs Square parameters + * @returns square cross section + * @group primitives + * @shortname square + * @drawable true + */ + square( + inputs: Inputs.Manifold.SquareDto + ): Promise; + /** + * Create a 2D circle cross section + * @param inputs Circle parameters + * @returns circle cross section + * @group primitives + * @shortname circle + * @drawable true + */ + circle( + inputs: Inputs.Manifold.CircleDto + ): Promise; + /** + * Create a 2D rectangle cross section + * @param inputs Rectangle parameters + * @returns rectangle cross section + * @group primitives + * @shortname rectangle + * @drawable true + */ + rectangle( + inputs: Inputs.Manifold.RectangleDto + ): Promise; + } + /** + * Contains various functions for transforming cross section from Manifold library https://github.com/elalish/manifold + * Thanks Manifold community for developing this kernel + */ + declare class CrossSectionTransforms { + private readonly manifoldWorkerManager; + constructor(manifoldWorkerManager: ManifoldWorkerManager); + /** + * Scales a cross section shape with 2D vector + * @param inputs cross section and scale vector + * @returns Scaled cross section shape + * @group transforms + * @shortname scale 2d + * @drawable true + */ + scale2D( + inputs: Inputs.Manifold.Scale2DCrossSectionDto + ): Promise; + /** + * Scales a cross section shape with single factor + * @param inputs cross section and scale factor + * @returns Scaled cross section shape + * @group transforms + * @shortname scale uniform + * @drawable true + */ + scale( + inputs: Inputs.Manifold.ScaleCrossSectionDto + ): Promise; + /** + * Mirrors a cross section shape over a plane defined by a normal vector + * @param inputs cross section and normal vector + * @returns Mirrored cross section shape + * @group transforms + * @shortname mirror + * @drawable true + */ + mirror( + inputs: Inputs.Manifold.MirrorCrossSectionDto + ): Promise; + /** + * Translates a cross section shape along the vector + * @param inputs cross section and trnaslation vector + * @returns Translated cross section shape + * @group transforms + * @shortname translate + * @drawable true + */ + translate( + inputs: Inputs.Manifold.TranslateCrossSectionDto + ): Promise; + /** + * Translates a cross section shape along x, y + * @param inputs cross section and trnaslation coordinates + * @returns Translated cross section shape + * @group transforms + * @shortname translate xy + * @drawable true + */ + translateXY( + inputs: Inputs.Manifold.TranslateXYCrossSectionDto + ): Promise; + /** + * Rotates a cross section shape along the containing degrees + * @param inputs cross section and rotation degrees + * @returns Rotated cross section shape + * @group transforms + * @shortname rotate + * @drawable true + */ + rotate( + inputs: Inputs.Manifold.RotateCrossSectionDto + ): Promise; + /** + * Transforms a cross section shape by using the 3x3 transformation matrix + * @param inputs cross section and transformation matrix + * @returns Transformed cross section shape + * @group matrix + * @shortname transform + * @drawable true + */ + transform( + inputs: Inputs.Manifold.TransformCrossSectionDto + ): Promise; + /** + * Move the vertices of this CrossSection (creating a new one) according to + * any arbitrary input function, followed by a union operation (with a + * Positive fill rule) that ensures any introduced intersections are not + * included in the result. + * @param inputs cross section and warp function + * @returns Warped cross section shape + * @group transforms + * @shortname warp + * @drawable true + */ + warp( + inputs: Inputs.Manifold.CrossSectionWarpDto + ): Promise; + } + /** + * Contains various functions for Solid meshes from Manifold library https://github.com/elalish/manifold + * Thanks Manifold community for developing this kernel + */ + declare class ManifoldBooleans { + private readonly manifoldWorkerManager; + constructor(manifoldWorkerManager: ManifoldWorkerManager); + /** + * Subtract two manifold shapes + * @param inputs two shapes + * @returns subtracted manifold shape + * @group a to b + * @shortname subtract + * @drawable true + */ + subtract( + inputs: Inputs.Manifold.TwoManifoldsDto + ): Promise; + /** + * Add two manifold shapes + * @param inputs two shapes + * @returns unioned manifold shape + * @group a to b + * @shortname add + * @drawable true + */ + add( + inputs: Inputs.Manifold.TwoManifoldsDto + ): Promise; + /** + * Intersect two manifold shapes + * @param inputs two shapes + * @returns intersected manifold shape + * @group a to b + * @shortname intersect + * @drawable true + */ + intersect( + inputs: Inputs.Manifold.TwoManifoldsDto + ): Promise; + /** + * Difference of two manifold shapes + * @param inputs two shapes + * @returns difference of two manifold shapes + * @group 2 manifolds + * @shortname difference 2 manifolds + * @drawable true + */ + differenceTwo( + inputs: Inputs.Manifold.TwoManifoldsDto + ): Promise; + /** + * Union of two manifold shapes + * @param inputs two shapes + * @returns union of two manifold shapes + * @group 2 manifolds + * @shortname union 2 manifolds + * @drawable true + */ + unionTwo( + inputs: Inputs.Manifold.TwoManifoldsDto + ): Promise; + /** + * Intersection of two manifold shapes + * @param inputs two shapes + * @returns intersection of two manifold shapes + * @group 2 manifolds + * @shortname intersection 2 manifolds + * @drawable true + */ + intersectionTwo( + inputs: Inputs.Manifold.TwoManifoldsDto + ): Promise; + /** + * Difference of multiple manifold shapes + * @param inputs multiple shapes + * @returns difference of two manifold shapes + * @group multiple + * @shortname difference manifolds + * @drawable true + */ + difference( + inputs: Inputs.Manifold.ManifoldsDto + ): Promise; + /** + * Union of multiple manifold shapes + * @param inputs multiple shapes + * @returns union of two manifold shapes + * @group multiple + * @shortname union manifolds + * @drawable true + */ + union( + inputs: Inputs.Manifold.ManifoldsDto + ): Promise; + /** + * Intersection of multiple manifold shapes + * @param inputs two shapes + * @returns intersection of multiple manifold shapes + * @group multiple + * @shortname intersection manifolds + * @drawable true + */ + intersection( + inputs: Inputs.Manifold.ManifoldsDto + ): Promise; + /** + * Split manifold by another manifold + * @param inputs manifold to split and manifold cutter + * @returns split manifold + * @group split + * @shortname split + * @drawable true + */ + split( + inputs: Inputs.Manifold.SplitManifoldsDto + ): Promise; + /** + * Split manifold by plane + * @param inputs manifold and plane + * @returns split manifold + * @group split + * @shortname split by plane + * @drawable true + */ + splitByPlane( + inputs: Inputs.Manifold.SplitByPlaneDto + ): Promise; + /** + * Split manifold by plane on various offsets + * @param inputs manifold, plane and the list of offsets + * @returns splitted manifolds + * @group split + * @shortname split by plane on offsets + * @drawable true + */ + splitByPlaneOnOffsets( + inputs: Inputs.Manifold.SplitByPlaneOnOffsetsDto + ): Promise; + /** + * Trim manifold by plane + * @param inputs manifold and plane + * @returns trimmed manifold + * @group trim + * @shortname trim by plane + * @drawable true + */ + trimByPlane( + inputs: Inputs.Manifold.TrimByPlaneDto + ): Promise; + } + /** + * Contains various functions for Solid meshes from Manifold library https://github.com/elalish/manifold + * Thanks Manifold community for developing this kernel + */ + declare class ManifoldEvaluate { + private readonly manifoldWorkerManager; + constructor(manifoldWorkerManager: ManifoldWorkerManager); + /** + * Get surface area of manifold + * @param inputs manifold + * @returns surface area of manifold + * @group basic + * @shortname surface area + * @drawable false + */ + surfaceArea( + inputs: Inputs.Manifold.ManifoldDto + ): Promise; + /** + * Get volume of manifold + * @param inputs manifold + * @returns volume of manifold + * @group basic + * @shortname volume + * @drawable false + */ + volume( + inputs: Inputs.Manifold.ManifoldDto + ): Promise; + /** + * Check if manifold contains triangles + * @param inputs manifold + * @returns boolean indicating emptyness + * @group basic + * @shortname is empty + * @drawable false + */ + isEmpty( + inputs: Inputs.Manifold.ManifoldDto + ): Promise; + /** + * Get number of vertices in manifold + * @param inputs manifold + * @returns number of vertices of manifold + * @group basic + * @shortname num vert + * @drawable false + */ + numVert( + inputs: Inputs.Manifold.ManifoldDto + ): Promise; + /** + * Get number of triangles in manifold + * @param inputs manifold + * @returns number of triangles of manifold + * @group basic + * @shortname num triangles + * @drawable false + */ + numTri( + inputs: Inputs.Manifold.ManifoldDto + ): Promise; + /** + * Get number of edges in manifold + * @param inputs manifold + * @returns number of edges of manifold + * @group basic + * @shortname num edges + * @drawable false + */ + numEdge( + inputs: Inputs.Manifold.ManifoldDto + ): Promise; + /** + * Get number of properties in manifold + * @param inputs manifold + * @returns number of properties of manifold + * @group basic + * @shortname num prop + * @drawable false + */ + numProp( + inputs: Inputs.Manifold.ManifoldDto + ): Promise; + /** + * The number of property vertices in the Manifold. This will always be >= + * numVert, as some physical vertices may be duplicated to account for + * different properties on different neighboring triangles. + * @param inputs manifold + * @returns number of properties of manifold + * @group basic + * @shortname num prop vert + * @drawable false + */ + numPropVert( + inputs: Inputs.Manifold.ManifoldDto + ): Promise; + /** + * Returns the axis-aligned bounding box of all the Manifold's vertices. + * @param inputs manifold + * @returns bounding box corner vectors of manifold + * @group basic + * @shortname bounding box + * @drawable false + */ + boundingBox( + inputs: Inputs.Manifold.ManifoldDto + ): Promise; + /** + * Returns the tolerance of this Manifold's vertices, which tracks the + * approximate rounding error over all the transforms and operations that have + * led to this state. Any triangles that are colinear within this tolerance + * are considered degenerate and removed. This is the value of ε + * defining + * [ε-valid](https://github.com/elalish/manifold/wiki/Manifold-Library#definition-of-%CE%B5-valid). + * @param inputs manifold + * @returns tolerance of manifold + * @group basic + * @shortname tolerance + * @drawable false + */ + tolerance( + inputs: Inputs.Manifold.ManifoldDto + ): Promise; + /** + * The genus is a topological property of the manifold, representing the + * number of handles. A sphere is 0, torus 1, etc. It is only meaningful for + * a single mesh, so it is best to call Decompose() first. + * @param inputs manifold + * @returns genus of manifold + * @group basic + * @shortname genus + * @drawable false + */ + genus( + inputs: Inputs.Manifold.ManifoldDto + ): Promise; + /** + * Returns the minimum gap between two manifolds. Returns a float between + * 0 and searchLength. + * @param inputs two manifolds and search length + * @returns minimum + * @group basic + * @shortname min gap + * @drawable false + */ + minGap( + inputs: Inputs.Manifold.ManifoldsMinGapDto + ): Promise; + /** + * If this mesh is an original, this returns its ID that can be referenced + * by product manifolds. If this manifold is a product, this + * returns -1. + * @param inputs manifold + * @returns original id of manifold + * @group basic + * @shortname original id + * @drawable false + */ + originalID( + inputs: Inputs.Manifold.ManifoldDto + ): Promise; + /** + * Returns the reason for an input Mesh producing an empty Manifold. This + * Status will carry on through operations like NaN propogation, ensuring an + * errored mesh doesn't get mysteriously lost. Empty meshes may still show + * NoError, for instance the intersection of non-overlapping meshes. + * @param inputs manifold + * @returns error status string (NoError, NotManifold, InvalidConstruction, etc.) + * @group basic + * @shortname status + * @drawable false + */ + status( + inputs: Inputs.Manifold.ManifoldDto + ): Promise; + } + /** + * Contains various functions for Solid meshes from Manifold library https://github.com/elalish/manifold + * Thanks Manifold community for developing this kernel + */ + declare class Manifold { + private readonly manifoldWorkerManager; + readonly shapes: ManifoldShapes; + readonly booleans: ManifoldBooleans; + readonly operations: ManifoldOperations; + readonly transforms: ManifoldTransforms; + readonly evaluate: ManifoldEvaluate; + constructor(manifoldWorkerManager: ManifoldWorkerManager); + /** + * Turns manifold shape into a mesh + * @param inputs Manifold shape + * @returns Decomposed mesh definition + * @group meshing + * @shortname manifold to mesh + * @drawable false + */ + manifoldToMesh( + inputs: Inputs.Manifold.ManifoldToMeshDto + ): Promise; + /** + * Turns manifold shapes into meshes + * @param inputs Manifold shapes + * @returns Decomposed mesh definitions + * @group meshing + * @shortname manifolds to meshes + * @drawable false + */ + manifoldsToMeshes( + inputs: Inputs.Manifold.ManifoldsToMeshesDto + ): Promise; + } + /** + * Contains various functions for Solid meshes from Manifold library https://github.com/elalish/manifold + * Thanks Manifold community for developing this kernel + */ + declare class ManifoldOperations { + private readonly manifoldWorkerManager; + constructor(manifoldWorkerManager: ManifoldWorkerManager); + /** + * Computes convex hull of the manifold shape provided + * @param inputs two shapes + * @returns hulled manifold shape + * @group hulls + * @shortname convex hull + * @drawable true + */ + hull( + inputs: Inputs.Manifold.ManifoldDto + ): Promise; + /** + * Hull points or manifolds + * @param inputs manifold + * @returns manifold + * @group hulls + * @shortname hull points + * @drawable true + */ + hullPoints( + inputs: Inputs.Manifold.HullPointsDto< + (Inputs.Base.Point3 | Inputs.Manifold.ManifoldPointer)[] + > + ): Promise; + /** + * Returns the cross section of this object parallel to the X-Y plane at the + * specified height. Using a height equal to the bottom + * of the bounding box will return the bottom faces, while using a height + * equal to the top of the bounding box will return empty. + * @param inputs manifold and height + * @returns sliced cross section + * @group cross sections + * @shortname slice + * @drawable true + */ + slice( + inputs: Inputs.Manifold.SliceDto + ): Promise; + /** + * Creates a projection on xy plane from the shape outline + * @param inputs manifold + * @returns projected cross section + * @group cross sections + * @shortname project + * @drawable true + */ + project( + inputs: Inputs.Manifold.ManifoldDto + ): Promise; + /** + * Return a copy of the manifold with the set tolerance value. + * This performs mesh simplification when the tolerance value is increased. + * @param inputs manifold and tolerance + * @returns manifold with new tolerance + * @group basic + * @shortname set tolerance + * @drawable false + */ + setTolerance( + inputs: Inputs.Manifold.ManifoldRefineToleranceDto + ): Promise; + /** + * Returns the first of n sequential new unique mesh IDs for marking sets of triangles that can be looked up after further operations. Assign to Mesh.runOriginalID vector. + * @param inputs count + * @returns void + * @group basic + * @shortname reserve id + * @drawable false + */ + reserveIds(inputs: Inputs.Manifold.CountDto): Promise; + /** + * If you copy a manifold, but you want this new copy to have new properties + * (e.g. a different UV mapping), you can reset its IDs to a new original, + * meaning it will now be referenced by its descendants instead of the meshes + * it was built from, allowing you to differentiate the copies when applying + * your properties to the final result. + * + * This function also condenses all coplanar faces in the relation, and + * collapses those edges. If you want to have inconsistent properties across + * these faces, meaning you want to preserve some of these edges, you should + * instead call GetMesh(), calculate your properties and use these to + * construct a new manifold. + * @param inputs manifold + * @returns original manifold + * @group basic + * @shortname as original + * @drawable true + */ + asOriginal( + inputs: Inputs.Manifold.ManifoldDto + ): Promise; + /** + * Constructs a new manifold from a list of other manifolds. This is a purely + * topological operation, so care should be taken to avoid creating + * overlapping results. It is the inverse operation of Decompose(). + * @param inputs manifold shapes + * @returns composed manifold + * @group composition + * @shortname compose + * @drawable true + */ + compose( + inputs: Inputs.Manifold.ManifoldsDto + ): Promise; + /** + * This operation returns a vector of Manifolds that are topologically + * disconnected. If everything is connected, the vector is length one, + * containing a copy of the original. It is the inverse operation of + * Compose(). + * @param inputs manifold + * @returns decomposed manifold shapes + * @group composition + * @shortname decompose + * @drawable true + */ + decompose( + inputs: Inputs.Manifold.ManifoldDto + ): Promise; + /** + * Fills in vertex properties for normal vectors, calculated from the mesh + * geometry. Flat faces composed of three or more triangles will remain flat. + * @param inputs manifold and normal index with minimum sharp angle + * @returns manifold with calculated normals + * @group adjustments + * @shortname calculate normals + * @drawable true + */ + calculateNormals( + inputs: Inputs.Manifold.CalculateNormalsDto + ): Promise; + /** + * Curvature is the inverse of the radius of curvature, and signed such that + * positive is convex and negative is concave. There are two orthogonal + * principal curvatures at any point on a manifold, with one maximum and the + * other minimum. Gaussian curvature is their product, while mean + * curvature is their sum. This approximates them for every vertex and assigns + * them as vertex properties on the given channels. + * @param inputs manifold and gaussian and mean index + * @returns manifold with calculated curvature + * @group adjustments + * @shortname calculate curvature + * @drawable true + */ + calculateCurvature( + inputs: Inputs.Manifold.CalculateCurvatureDto + ): Promise; + /** + * Increase the density of the mesh by splitting each edge into pieces such + * that any point on the resulting triangles is roughly within tolerance of + * the smoothly curved surface defined by the tangent vectors. This means + * tightly curving regions will be divided more finely than smoother regions. + * If halfedgeTangents are not present, the result will simply be a copy of + * the original. Quads will ignore their interior triangle bisector. + * @param inputs manifold and tolerance + * @returns refined manifold + * @group adjustments + * @shortname refine to tolerance + * @drawable true + */ + refineToTolerance( + inputs: Inputs.Manifold.ManifoldRefineToleranceDto + ): Promise; + /** + * Increase the density of the mesh by splitting each edge into pieces of + * roughly the input length. Interior verts are added to keep the rest of the + * triangulation edges also of roughly the same length. If halfedgeTangents + * are present (e.g. from the Smooth() constructor), the new vertices will be + * moved to the interpolated surface according to their barycentric + * coordinates. + * @param inputs manifold and length + * @returns refined manifold + * @group adjustments + * @shortname refine to length + * @drawable true + */ + refineToLength( + inputs: Inputs.Manifold.ManifoldRefineLengthDto + ): Promise; + /** + * Increase the density of the mesh by splitting every edge into n pieces. For + * instance, with n = 2, each triangle will be split into 4 triangles. These + * will all be coplanar (and will not be immediately collapsed) unless the + * Mesh/Manifold has halfedgeTangents specified (e.g. from the Smooth() + * constructor), in which case the new vertices will be moved to the + * interpolated surface according to their barycentric coordinates. + * @param inputs manifold and count + * @returns refined manifold + * @group adjustments + * @shortname refine + * @drawable true + */ + refine( + inputs: Inputs.Manifold.ManifoldRefineDto + ): Promise; + /** + * Smooths out the Manifold by filling in the halfedgeTangent vectors. The + * geometry will remain unchanged until Refine or RefineToLength is called to + * interpolate the surface. This version uses the geometry of the triangles + * and pseudo-normals to define the tangent vectors. + * @param inputs manifold and minimum sharp angle and minimum smoothness + * @returns smoothed manifold + * @group adjustments + * @shortname smooth out + * @drawable true + */ + smoothOut( + inputs: Inputs.Manifold.ManifoldSmoothOutDto + ): Promise; + /** + * Smooths out the Manifold by filling in the halfedgeTangent vectors. The + * geometry will remain unchanged until Refine or RefineToLength is called to + * interpolate the surface. This version uses the supplied vertex normal + * properties to define the tangent vectors. + * @param inputs manifold and normal index + * @returns smoothed manifold + * @group adjustments + * @shortname smooth by normals + * @drawable true + */ + smoothByNormals( + inputs: Inputs.Manifold.ManifoldSmoothByNormalsDto + ): Promise; + /** + * Return a copy of the manifold simplified to the given tolerance, but with + * its actual tolerance value unchanged. The result will contain a subset of + * the original verts and all surfaces will have moved by less than tolerance. + * @param inputs manifold and tolerance + * @returns simplified manifold + * @group adjustments + * @shortname simplify + * @drawable true + */ + simplify( + inputs: Inputs.Manifold.ManifoldSimplifyDto + ): Promise; + /** + * Create a new copy of this manifold with updated vertex properties by + * supplying a function that takes the existing position and properties as + * input. You may specify any number of output properties, allowing creation + * and removal of channels. Note: undefined behavior will result if you read + * past the number of input properties or write past the number of output + * properties. + * @param inputs manifold, numProp and property function + * @returns manifold with updated properties + * @group adjustments + * @shortname set properties + * @drawable true + */ + setProperties( + inputs: Inputs.Manifold.ManifoldSetPropertiesDto + ): Promise; + } + /** + * Contains various functions for Solid meshes from Manifold library https://github.com/elalish/manifold + * Thanks Manifold community for developing this kernel + */ + declare class ManifoldShapes { + private readonly manifoldWorkerManager; + constructor(manifoldWorkerManager: ManifoldWorkerManager); + /** + * Convert a Mesh into a Manifold, retaining its properties and merging only + * the positions according to the merge vectors. Will throw an error if the + * result is not an oriented 2-manifold. Will collapse degenerate triangles + * and unnecessary vertices. + * + * All fields are read, making this structure suitable for a lossless + * round-trip of data from manifoldToMesh(). For multi-material input, use + * reserveIDs() to set a unique originalID for each material, and sort the + * materials into triangle runs. + * @param inputs mesh definition + * @returns manifold + * @group create + * @shortname manifold from mesh + * @drawable true + */ + manifoldFromMesh( + inputs: Inputs.Manifold.CreateFromMeshDto + ): Promise; + /** + * Create a Manifold from a set of polygon points describing triangles. + * @param inputs Polygon points + * @returns Manifold + * @group create + * @shortname from polygon points + * @drawable true + */ + fromPolygonPoints( + inputs: Inputs.Manifold.FromPolygonPointsDto + ): Promise; + /** + * Create a 3D cube shape + * @param inputs Cube parameters + * @returns Cube solid + * @group primitives + * @shortname cube + * @drawable true + */ + cube( + inputs: Inputs.Manifold.CubeDto + ): Promise; + /** + * Create a 3D sphere shape + * @param inputs Sphere parameters + * @returns Sphere solid + * @group primitives + * @shortname sphere + * @drawable true + */ + sphere( + inputs: Inputs.Manifold.SphereDto + ): Promise; + /** + * Create a 3D tetrahedron shape + * @returns Tetrahedron solid + * @group primitives + * @shortname tetrahedron + * @drawable true + */ + tetrahedron(): Promise; + /** + * Create a 3D cylinder shape + * @param inputs Cylinder parameters + * @returns Cylinder solid + * @group primitives + * @shortname cylinder + * @drawable true + */ + cylinder( + inputs: Inputs.Manifold.CylinderDto + ): Promise; + } + /** + * Contains various functions for Solid meshes from Manifold library https://github.com/elalish/manifold + * Thanks Manifold community for developing this kernel + */ + declare class ManifoldTransforms { + private readonly manifoldWorkerManager; + constructor(manifoldWorkerManager: ManifoldWorkerManager); + /** + * Scales a manifold shape with 3D vector + * @param inputs manifold and scale vector + * @returns Scaled manifold shape + * @group transforms + * @shortname scale 3d + * @drawable true + */ + scale3D( + inputs: Inputs.Manifold.Scale3DDto + ): Promise; + /** + * Scales a manifold shape with single factor + * @param inputs manifold and scale factor + * @returns Scaled manifold shape + * @group transforms + * @shortname scale uniform + * @drawable true + */ + scale( + inputs: Inputs.Manifold.ScaleDto + ): Promise; + /** + * Mirrors a manifold shape over a plane defined by a normal vector + * @param inputs manifold and normal vector + * @returns Mirrored manifold shape + * @group transforms + * @shortname mirror + * @drawable true + */ + mirror( + inputs: Inputs.Manifold.MirrorDto + ): Promise; + /** + * Translates a manifold shape along the vector + * @param inputs manifold and trnaslation vector + * @returns Translated manifold shape + * @group transforms + * @shortname translate + * @drawable true + */ + translate( + inputs: Inputs.Manifold.TranslateDto + ): Promise; + /** + * Translates a manifold shape along by multiple vectors + * @param inputs manifold and trnaslation vectors + * @returns Translated manifold shapes + * @group multiple + * @shortname translate by vectors + * @drawable true + */ + translateByVectors( + inputs: Inputs.Manifold.TranslateByVectorsDto + ): Promise; + /** + * Translates a manifold shape along x, y, z + * @param inputs manifold and trnaslation coordinates + * @returns Translated manifold shape + * @group transforms + * @shortname translate xyz + * @drawable true + */ + translateXYZ( + inputs: Inputs.Manifold.TranslateXYZDto + ): Promise; + /** + * Rotates a manifold shape along the vector containing euler angles + * @param inputs manifold and rotation vector + * @returns Rotated manifold shape + * @group transforms + * @shortname rotate + * @drawable true + */ + rotate( + inputs: Inputs.Manifold.RotateDto + ): Promise; + /** + * Rotates a manifold shape along the x y z euler angles + * @param inputs manifold and rotation eulers + * @returns Rotated manifold shape + * @group transforms + * @shortname rotate xyz + * @drawable true + */ + rotateXYZ( + inputs: Inputs.Manifold.RotateXYZDto + ): Promise; + /** + * Transforms a manifold shape by using the 4x4 transformation matrix + * @param inputs manifold and transformation matrix + * @returns Transformed manifold shape + * @group matrix + * @shortname transform + * @drawable true + */ + transform( + inputs: Inputs.Manifold.TransformDto + ): Promise; + /** + * Transforms a manifold shape by using the 4x4 transformation matrixes + * @param inputs manifold and transformation matrixes + * @returns Transformed manifold shape + * @group matrix + * @shortname transforms + * @drawable true + */ + transforms( + inputs: Inputs.Manifold.TransformsDto + ): Promise; + /** + * Move the vertices of this Manifold (creating a new one) according to any + * arbitrary input function. It is easy to create a function that warps a + * geometrically valid object into one which overlaps, but that is not checked + * here, so it is up to the user to choose their function with discretion. + * @param inputs manifold and warp function + * @returns Warped manifold shape + * @group transforms + * @shortname warp + * @drawable true + */ + warp( + inputs: Inputs.Manifold.ManifoldWarpDto + ): Promise; + } + /** + * Contains various functions for Solid meshes from Manifold library https://github.com/elalish/manifold + * Thanks Manifold community for developing this kernel + */ + declare class ManifoldBitByBit { + private readonly manifoldWorkerManager; + readonly manifold: Manifold; + readonly crossSection: ManifoldCrossSection; + readonly mesh: Mesh; + constructor(manifoldWorkerManager: ManifoldWorkerManager); + /** + * Turns manifold shape into a mesh pointer that lives in worker's memory. This pointer can be used with bitbybit.manifold.mesh functions + * @param inputs Manifold shape + * @returns Pointer to manifold mesh definition + * @group meshing + * @shortname manifold to mesh pointer + * @drawable false + */ + manifoldToMeshPointer( + inputs: Inputs.Manifold.ManifoldToMeshDto + ): Promise; + /** + * Decomposes manifold or cross section shape into a mesh or simple polygons + * @param inputs Manifold shape or cross section + * @returns Decomposed mesh definition or simple polygons + * @group decompose + * @shortname decompose m or cs + * @drawable false + */ + decomposeManifoldOrCrossSection( + inputs: Inputs.Manifold.DecomposeManifoldOrCrossSectionDto< + Inputs.Manifold.ManifoldPointer | Inputs.Manifold.CrossSectionPointer + > + ): Promise< + Inputs.Manifold.DecomposedManifoldMeshDto | Inputs.Base.Vector2[][] + >; + /** + * Turns manifold shape into a collection of polygon points representing the mesh. + * @param inputs Manifold shape + * @returns polygon points + * @group decompose + * @shortname to polygon points + * @drawable false + */ + toPolygonPoints( + inputs: Inputs.Manifold.ManifoldDto + ): Promise; + /** + * Decomposes manifold or cross section shape into a mesh or simple polygons + * @param inputs Manifold shapes or cross sections + * @returns Decomposed mesh definitions or a list of simple polygons + * @group decompose + * @shortname decompose m's or cs's + * @drawable false + */ + decomposeManifoldsOrCrossSections( + inputs: Inputs.Manifold.DecomposeManifoldsOrCrossSectionsDto< + Inputs.Manifold.ManifoldPointer | Inputs.Manifold.CrossSectionPointer + > + ): Promise< + (Inputs.Manifold.DecomposedManifoldMeshDto | Inputs.Base.Vector2[][])[] + >; + /** + * Delete manifold or cross section from memory + * @param inputs manifold or cross section + * @group cleanup + * @shortname delete m or cs + * @drawable false + */ + deleteManifoldOrCrossSection( + inputs: Inputs.Manifold.ManifoldOrCrossSectionDto + ): Promise; + /** + * Delete manifolds or cross sections from memory + * @param inputs manifolds or cross sections + * @group cleanup + * @shortname delete m's or cs's + * @drawable false + */ + deleteManifoldsOrCrossSections( + inputs: Inputs.Manifold.ManifoldsOrCrossSectionsDto + ): Promise; + } + /** + * Contains various functions for Solid meshes from Manifold library https://github.com/elalish/manifold + * Thanks Manifold community for developing this kernel + */ + declare class MeshEvaluate { + private readonly manifoldWorkerManager; + constructor(manifoldWorkerManager: ManifoldWorkerManager); + /** + * Get position on mesh vertex index + * @param inputs mesh + * @returns point + * @group basic + * @shortname position + * @drawable true + */ + position( + inputs: Inputs.Manifold.MeshVertexIndexDto + ): Promise; + /** + * Gets the three vertex indices of this triangle in CCW order. + * @param inputs mesh + * @returns verts + * @group basic + * @shortname verts + * @drawable false + */ + verts( + inputs: Inputs.Manifold.MeshTriangleIndexDto + ): Promise; + /** + * Gets the tangent vector starting at verts(tri)[j] pointing to the next + * Bezier point along the CCW edge. The fourth value is its weight. + * @param inputs mesh + * @returns tangent + * @group basic + * @shortname tangent + * @drawable true + */ + tangent( + inputs: Inputs.Manifold.MeshHalfEdgeIndexDto + ): Promise; + /** + * Gets any other properties associated with this vertex. + * @param inputs mesh + * @returns extras + * @group basic + * @shortname extras + * @drawable false + */ + extras( + inputs: Inputs.Manifold.MeshVertexIndexDto + ): Promise; + /** + * Gets the column-major 4x4 matrix transform from the original mesh to these + * related triangles. + * @param inputs mesh + * @returns transform matrix + * @group basic + * @shortname transform 4x4 matrix + * @drawable false + */ + transform( + inputs: Inputs.Manifold.MeshVertexIndexDto + ): Promise; + /** + * Number of properties per vertex, always >= 3. + * @param inputs mesh + * @returns number of properties + * @group basic + * @shortname number props + * @drawable false + */ + numProp( + inputs: Inputs.Manifold.MeshDto + ): Promise; + /** + * Number of property vertices + * @param inputs mesh + * @returns number of vertices + * @group basic + * @shortname number vertices + * @drawable false + */ + numVert( + inputs: Inputs.Manifold.MeshDto + ): Promise; + /** + * Get number of triangles on mesh + * @param inputs mesh + * @returns number of triangles + * @group basic + * @shortname number triangles + * @drawable false + */ + numTri( + inputs: Inputs.Manifold.MeshDto + ): Promise; + /** + * Number of triangle runs. Each triangle run is a set of consecutive + * triangles that all come from the same instance of the same input mesh. + * @param inputs mesh + * @returns number of runs + * @group basic + * @shortname number runs + * @drawable false + */ + numRun( + inputs: Inputs.Manifold.MeshDto + ): Promise; + } + /** + * Contains various functions for Solid meshes from Manifold library https://github.com/elalish/manifold + * Thanks Manifold community for developing this kernel + */ + declare class Mesh { + private readonly manifoldWorkerManager; + readonly operations: MeshOperations; + readonly evaluate: MeshEvaluate; + constructor(manifoldWorkerManager: ManifoldWorkerManager); + } + /** + * Contains various functions for Solid meshes from Manifold library https://github.com/elalish/manifold + * Thanks Manifold community for developing this kernel + */ + declare class MeshOperations { + private readonly manifoldWorkerManager; + constructor(manifoldWorkerManager: ManifoldWorkerManager); + /** + * Updates the mergeFromVert and mergeToVert vectors in order to create a + * manifold solid. If the MeshGL is already manifold, no change will occur and + * the function will return false. Otherwise, this will merge verts along open + * edges within tolerance (the maximum of the MeshGL tolerance and the + * baseline bounding-box tolerance), keeping any from the existing merge + * vectors. + * + * There is no guarantee the result will be manifold - this is a best-effort + * helper function designed primarily to aid in the case where a manifold + * multi-material MeshGL was produced, but its merge vectors were lost due to + * a round-trip through a file format. Constructing a Manifold from the result + * will report a Status if it is not manifold. + * @param inputs mesh + * @returns merged mesh + * @group base + * @shortname merge + * @drawable true + */ + merge( + inputs: Inputs.Manifold.MeshDto + ): Promise; + } + declare class BitByBitOCCT { + occtWorkerManager: OCCTWorkerManager; + occt: OCCT; + constructor(); + init(occt: Worker): void; + } + declare class OCCTBooleans { + private readonly occWorkerManager; + constructor(occWorkerManager: OCCTWorkerManager); + /** + * Joins separate objects + * @param inputs Objects to join + * @returns OpenCascade joined shape + * @group booleans + * @shortname union + * @drawable true + */ + union( + inputs: Inputs.OCCT.UnionDto + ): Promise; + /** + * Does boolean difference operation between a main shape and given shapes + * @param inputs Main shape and shapes to differ + * @returns OpenCascade difference shape + * @group booleans + * @shortname difference + * @drawable true + */ + difference( + inputs: Inputs.OCCT.DifferenceDto + ): Promise; + /** + * Does boolean intersection operation between a main shape and given shapes + * @param inputs Main shape and shapes to differ + * @returns OpenCascade intersection of shapes + * @group booleans + * @shortname intersection + * @drawable true + */ + intersection( + inputs: Inputs.OCCT.IntersectionDto + ): Promise; + /** + * Does mesh mesh intersection operation between two shapes - both shapes can have their own meshing precision. + * This algorithm intersects the meshes and returns the wires of the intersection, which are polylines or polygons. + * @param inputs Two shapes to intersect + * @returns Wires where shapes intersect + * @group mesh based + * @shortname mesh mesh intersection as wires + * @drawable true + */ + meshMeshIntersectionWires( + inputs: Inputs.OCCT.MeshMeshIntersectionTwoShapesDto + ): Promise; + /** + * Does mesh mesh intersection operation between two shapes - both shapes can have their own meshing precision. + * This algorithm intersects the meshes and returns the points of the intersection, which are polylines or polygons. + * @param inputs Two shapes to intersect + * @returns Points where shapes intersect + * @group mesh based + * @shortname mesh mesh intersection as points + * @drawable true + */ + meshMeshIntersectionPoints( + inputs: Inputs.OCCT.MeshMeshIntersectionTwoShapesDto + ): Promise; + /** + * Does mesh mesh intersection operation between the shape and multiple other shapes - all shapes can have their own meshing precision. + * This algorithm intersects the meshes and returns the wires of the intersection, which are polylines or polygons. + * @param inputs Two shapes to intersect + * @returns Wires where shapes intersect + * @group mesh based + * @shortname mesh mesh intersection of shapes as wires + * @drawable true + */ + meshMeshIntersectionOfShapesWires( + inputs: Inputs.OCCT.MeshMeshesIntersectionOfShapesDto + ): Promise; + /** + * Does mesh mesh intersection operation between the shape and multiple other shapes - all shapes can have their own meshing precision. + * This algorithm intersects the meshes and returns the points of the intersection. + * @param inputs Two shapes to intersect + * @returns Wires where shapes intersect + * @group mesh based + * @shortname mesh mesh intersection of shapes as points + * @drawable true + */ + meshMeshIntersectionOfShapesPoints( + inputs: Inputs.OCCT.MeshMeshesIntersectionOfShapesDto + ): Promise; + } + declare class OCCTDimensions { + private readonly occWorkerManager; + constructor(occWorkerManager: OCCTWorkerManager); + /** + * Creates simple linear length dimension between two points - measuring units. You decide what kind of units you re using by providing a suffix. + * @param inputs two points, direction, label size, label normal direction, offset, and unit suffix, decimal rounding place + * @returns compound wires representing dimensions + * @group simple + * @shortname linear dimension + * @drawable true + */ + simpleLinearLengthDimension( + inputs: Inputs.OCCT.SimpleLinearLengthDimensionDto + ): Promise; + /** + * Creates simple angular dimension. By default we output degrees, but you can opt to use radians. + * @param inputs a center, two directions, radius and various label parameters + * @returns compound wires representing dimension + * @group simple + * @shortname angular dimension + * @drawable true + */ + simpleAngularDimension( + inputs: Inputs.OCCT.SimpleAngularDimensionDto + ): Promise; + /** + * @param inputs a start and end point, direction and parameters for the label + * @returns compound wires representing dimension + * @group simple + * @shortname pin with label + * @drawable true + */ + pinWithLabel( + inputs: Inputs.OCCT.PinWithLabelDto + ): Promise; + } + declare class OCCTFillets { + private readonly occWorkerManager; + constructor(occWorkerManager: OCCTWorkerManager); + /** + * Fillets OpenCascade Shapes + * @param inputs Shape, radius and edge indexes to fillet + * @returns OpenCascade shape with filleted edges + * @group 3d fillets + * @shortname fillet edges + * @drawable true + */ + filletEdges( + inputs: Inputs.OCCT.FilletDto + ): Promise; + /** + * Fillets edges list with different radius on each edge. + * @param inputs Shape, edges and radius list + * @returns OpenCascade shape with filleted edges + * @group 3d fillets + * @shortname fillet edges list + * @drawable true + */ + filletEdgesList( + inputs: Inputs.OCCT.FilletEdgesListDto< + Inputs.OCCT.TopoDSShapePointer, + Inputs.OCCT.TopoDSEdgePointer + > + ): Promise; + /** + * Fillets edges list with the single radius on all edges. + * @param inputs Shape, edges and radius + * @returns OpenCascade shape with filleted edges + * @group 3d fillets + * @shortname fillet edges list one r + * @drawable true + */ + filletEdgesListOneRadius( + inputs: Inputs.OCCT.FilletEdgesListOneRadiusDto< + Inputs.OCCT.TopoDSShapePointer, + Inputs.OCCT.TopoDSEdgePointer + > + ): Promise; + /** + * Fillets a single edge with variable radius list on given u params. You need to provide a list of params to identify on which U param to apply the radius on. + * @param inputs Shape, edge, radius list and param list + * @returns OpenCascade shape with filleted edges + * @group 3d fillets + * @shortname fillet edge variable r + * @drawable true + */ + filletEdgeVariableRadius( + inputs: Inputs.OCCT.FilletEdgeVariableRadiusDto< + Inputs.OCCT.TopoDSShapePointer, + Inputs.OCCT.TopoDSEdgePointer + > + ): Promise; + /** + * Fillets multiple provided edges with the same variable radiuses on u params for each edge. + * @param inputs Shape, edge, radius list and param list + * @returns OpenCascade shape with filleted edges + * @group 3d fillets + * @shortname fillet edges same variable r + * @drawable true + */ + filletEdgesSameVariableRadius( + inputs: Inputs.OCCT.FilletEdgesSameVariableRadiusDto< + Inputs.OCCT.TopoDSShapePointer, + Inputs.OCCT.TopoDSEdgePointer + > + ): Promise; + /** + * Fillets multiple provided edges with variable radius lists on given params lists. You need to provide a list of params to identify on which U param to apply the radius on. + * @param inputs Shape, edge, radius list and param list + * @returns OpenCascade shape with filleted edges + * @group 3d fillets + * @shortname fillet edges variable r + * @drawable true + */ + filletEdgesVariableRadius( + inputs: Inputs.OCCT.FilletEdgesVariableRadiusDto< + Inputs.OCCT.TopoDSShapePointer, + Inputs.OCCT.TopoDSEdgePointer + > + ): Promise; + /** + * Fillets OpenCascade 3d wire, this algorithm takes one guiding direction for fillets to be formed. + * It does not respect tangent directions on each filleted corner. This algorithm is based on extruding wire along the given direction + * to form a shell, then filleting the shell and finally extracting the filleted wire from the shell itself. + * Make sure you provide a direction that is not parallel to the wire and that forms high enough extrusion for the fillet to succeed. + * @param inputs Shape, radius and edge indexes to fillet + * @returns OpenCascade shape with filleted edges + * @group 3d fillets + * @shortname fillet 3d wire + * @drawable true + */ + fillet3DWire( + inputs: Inputs.OCCT.Fillet3DWireDto + ): Promise; + /** + * Fillets OpenCascade 3d wires, this algorithm takes one guiding direction for fillets to be formed. + * It does not respect tangent directions on each filleted corner. This algorithm is based on extruding wires along the given direction + * to form a shell, then filleting the shell and finally extracting the filleted wire from the shell itself. + * Make sure you provide a direction that is not parallel to the wire and that forms high enough extrusion for the fillet to succeed. + * @param inputs Shapes, radius and edge indexes to fillet + * @returns OpenCascade shape with filleted edges + * @group 3d fillets + * @shortname fillet 3d wires + * @drawable true + */ + fillet3DWires( + inputs: Inputs.OCCT.Fillet3DWiresDto + ): Promise; + /** + * Chamfer OpenCascade Shape edges + * @param inputs Shape, distance and edge indexes to chamfer + * @returns OpenCascade shape with chamfered edges + * @group 3d chamfers + * @shortname chamfer edges + * @drawable true + */ + chamferEdges( + inputs: Inputs.OCCT.ChamferDto + ): Promise; + /** + * Chamfers edges list with different distance on each edge. + * @param inputs Shape, edges and distance list + * @returns OpenCascade shape with chamfered edges + * @group 3d chamfers + * @shortname chamfer edges list + * @drawable true + */ + chamferEdgesList( + inputs: Inputs.OCCT.ChamferEdgesListDto< + Inputs.OCCT.TopoDSShapePointer, + Inputs.OCCT.TopoDSEdgePointer + > + ): Promise; + /** + * Chamfers edge by a by two distances. Face indicates the first distance to be applied + * @param inputs Shape, edge, face, distance1 and distance2 + * @returns OpenCascade shape with chamfered edges + * @group 3d chamfers + * @shortname chamfer edge 2 dist + * @drawable true + */ + chamferEdgeTwoDistances( + inputs: Inputs.OCCT.ChamferEdgeTwoDistancesDto< + Inputs.OCCT.TopoDSShapePointer, + Inputs.OCCT.TopoDSEdgePointer, + Inputs.OCCT.TopoDSFacePointer + > + ): Promise; + /** + * Chamfers edges by a by two distances. Face indicates the first distance to be applied + * @param inputs Shape, edges, faces, distance1 and distance2 + * @returns OpenCascade shape with chamfered edges + * @group 3d chamfers + * @shortname chamfer edges 2 dist + * @drawable true + */ + chamferEdgesTwoDistances( + inputs: Inputs.OCCT.ChamferEdgesTwoDistancesDto< + Inputs.OCCT.TopoDSShapePointer, + Inputs.OCCT.TopoDSEdgePointer, + Inputs.OCCT.TopoDSFacePointer + > + ): Promise; + /** + * Chamfers edges by two distances. Face indicates the first distance to be applied + * @param inputs Shape, edges, faces, distance1 list and distance2 list + * @returns OpenCascade shape with chamfered edges + * @group 3d chamfers + * @shortname chamfer edges 2 dist lists + * @drawable true + */ + chamferEdgesTwoDistancesLists( + inputs: Inputs.OCCT.ChamferEdgesTwoDistancesListsDto< + Inputs.OCCT.TopoDSShapePointer, + Inputs.OCCT.TopoDSEdgePointer, + Inputs.OCCT.TopoDSFacePointer + > + ): Promise; + /** + * Chamfers edge by a given distance and angle from the face + * @param inputs Shape, edge, face, distance and angle + * @returns OpenCascade shape with chamfered edges + * @group 3d chamfers + * @shortname chamfer edge angle + * @drawable true + */ + chamferEdgeDistAngle( + inputs: Inputs.OCCT.ChamferEdgeDistAngleDto< + Inputs.OCCT.TopoDSShapePointer, + Inputs.OCCT.TopoDSEdgePointer, + Inputs.OCCT.TopoDSFacePointer + > + ): Promise; + /** + * Chamfers multiple edges by a given distance and angle from the faces + * @param inputs Shape, edge, face, distance and angle + * @returns OpenCascade shape with chamfered edges + * @group 3d chamfers + * @shortname chamfer edges angle + * @drawable true + */ + chamferEdgesDistAngle( + inputs: Inputs.OCCT.ChamferEdgesDistAngleDto< + Inputs.OCCT.TopoDSShapePointer, + Inputs.OCCT.TopoDSEdgePointer, + Inputs.OCCT.TopoDSFacePointer + > + ): Promise; + /** + * Chamfers edges by a given distances and angles from the faces + * @param inputs Shape, edges, faces, distances and angles + * @returns OpenCascade shape with chamfered edges + * @group 3d chamfers + * @shortname chamfer edges angles + * @drawable true + */ + chamferEdgesDistsAngles( + inputs: Inputs.OCCT.ChamferEdgesDistsAnglesDto< + Inputs.OCCT.TopoDSShapePointer, + Inputs.OCCT.TopoDSEdgePointer, + Inputs.OCCT.TopoDSFacePointer + > + ): Promise; + /** + * Fillets 2d wire or face + * @param inputs Shape + * @returns OpenCascade filleted shape result + * @group 2d fillets + * @shortname fillet 2d wire or face + * @drawable true + */ + fillet2d( + inputs: Inputs.OCCT.FilletDto< + Inputs.OCCT.TopoDSWirePointer | Inputs.OCCT.TopoDSFacePointer + > + ): Promise; + /** + * Fillets 2d wires or faces + * @param inputs Shapes + * @returns OpenCascade filleted shapes result + * @group 2d fillets + * @shortname fillet 2d wires or faces + * @drawable true + */ + fillet2dShapes( + inputs: Inputs.OCCT.FilletShapesDto< + Inputs.OCCT.TopoDSWirePointer | Inputs.OCCT.TopoDSFacePointer + > + ): Promise; + /** + * Fillets two planar edges into a wire by providing a radius, plane, edges and possible solution index if more than one result exists + * @param inputs Definition for fillets + * @returns OpenCascade wire shape if solution is found + * @group 2d fillets + * @shortname fillet 2 edges + * @drawable true + */ + filletTwoEdgesInPlaneIntoAWire( + inputs: Inputs.OCCT.FilletTwoEdgesInPlaneDto + ): Promise; + } + declare class OCCTCurves { + private readonly occWorkerManager; + constructor(occWorkerManager: OCCTWorkerManager); + /** + * Creates a 2d ellipse. Be sure to use this geometry only for constructive purposes of modeling, but not for representation. You need to transform these curves to edges in order to draw them. + * @param inputs 2D Ellipse parameters + * @returns OpenCascade Geom2d_ellipse + * @group primitives + * @shortname ellipse 2d + */ + geom2dEllipse( + inputs: Inputs.OCCT.Geom2dEllipseDto + ): Promise; + /** + * Creates a trimmed curve from the basis curve limited between U1 and U2. This curve can't be drawn. + * @param inputs Bounds and strategy for trimming the curve + * @returns OpenCascade Geom2d_TrimmedCurve + * @group create + * @shortname trimmed 2d + */ + geom2dTrimmedCurve( + inputs: Inputs.OCCT.Geom2dTrimmedCurveDto + ): Promise; + /** + * Creates a trimmed 2d curve segment between two 2d points. This curve can't be drawn. + * @param inputs Two 2d points for start and end + * @returns OpenCascade Geom2d_Segment + * @group primitives + * @shortname segment 2d + */ + geom2dSegment( + inputs: Inputs.OCCT.Geom2dSegmentDto + ): Promise; + /** + * Gets 2d point represented by [number, number] on a curve at parameter. + * @param inputs 2D Curve shape and parameter + * @returns Point as array of 2 numbers + * @group get + * @shortname 2d point on curve + */ + get2dPointFrom2dCurveOnParam( + inputs: Inputs.OCCT.DataOnGeometryAtParamDto + ): Promise; + /** + * Creates a circle geom curve + * @param inputs Axis information and radius + * @returns Opencascade Geom_Circle curve + * @group primitives + * @shortname circle + * @drawable false + */ + geomCircleCurve( + inputs: Inputs.OCCT.CircleDto + ): Promise; + /** + * Creates an ellipse geom curve + * @param inputs Axis information and radius + * @returns Opencascade Geom_Ellipse curve + * @group primitives + * @shortname ellipse + * @drawable false + */ + geomEllipseCurve( + inputs: Inputs.OCCT.EllipseDto + ): Promise; + } + declare class OCCTGeom { + readonly curves: OCCTCurves; + readonly surfaces: OCCTSurfaces; + constructor(occWorkerManager: OCCTWorkerManager); + } + declare class OCCTSurfaces { + private readonly occWorkerManager; + constructor(occWorkerManager: OCCTWorkerManager); + /** + * Creates an infinite cylindrical surface that can not be drawn. Be sure to use this geometry only for constructive purposes of modeling, but not for representation. + * @param inputs Cylinder parameters + * @returns OpenCascade cylindrical surface + * @group surfaces + * @shortname cylindrical + * @drawable false + */ + cylindricalSurface( + inputs: Inputs.OCCT.GeomCylindricalSurfaceDto + ): Promise; + /** + * Creates a surface from the face + * @param inputs Face shape + * @returns OpenCascade geom surface + * @group surfaces + * @shortname from face + * @drawable false + */ + surfaceFromFace( + inputs: Inputs.OCCT.ShapeDto + ): Promise; + } + declare class OCCTIO { + readonly occWorkerManager: OCCTWorkerManager; + constructor(occWorkerManager: OCCTWorkerManager); + /** + * Saves the step file + * @param inputs STEP filename and shape to be saved + * @group io + * @shortname save step + * @drawable false + */ + saveShapeSTEP( + inputs: Inputs.OCCT.SaveStepDto + ): Promise; + /** + * Saves the step file and returns the text value + * @param inputs STEP filename and shape to be saved + * @group io + * @shortname save step and return + * @drawable false + */ + saveShapeSTEPAndReturn( + inputs: Inputs.OCCT.SaveStepDto + ): Promise; + /** + * Saves the stl file + * @param inputs STL filename and shape to be saved + * @group io + * @shortname save stl + * @drawable false + */ + saveShapeStl( + inputs: Inputs.OCCT.SaveStlDto + ): Promise; + /** + * Saves the stl file and returns + * @param inputs STL filename and shape to be saved + * @group io + * @shortname save stl return + * @drawable false + */ + saveShapeStlAndReturn( + inputs: Inputs.OCCT.SaveStlDto + ): Promise; + private saveSTEP; + private saveStl; + /** + * Creates DXF paths from an OCCT shape + * Important - shapes containing wires must lie on XZ plane (Y=0) for correct 2D DXF export. + * @param inputs Shape to convert to DXF paths + * @group dxf + * @shortname shape to dxf paths + * @drawable false + */ + shapeToDxfPaths( + inputs: Inputs.OCCT.ShapeToDxfPathsDto + ): Promise; + /** + * Adds layer and color information to DXF paths + * Important - shapes containing wires must lie on XZ plane (Y=0) for correct 2D DXF export. + * @param inputs DXF paths, layer name, and color + * @group dxf + * @shortname dxf paths with layer + * @drawable false + */ + dxfPathsWithLayer( + inputs: Inputs.OCCT.DxfPathsWithLayerDto + ): Promise; + /** + * Assembles multiple path parts into a complete DXF file. + * Important - shapes containing wires must lie on XZ plane (Y=0) for correct 2D DXF export. + * @param inputs Multiple DXF paths parts + * @group dxf + * @shortname dxf create + * @drawable false + */ + dxfCreate(inputs: Inputs.OCCT.DxfPathsPartsListDto): Promise; + } + /** + * Contains various methods for OpenCascade implementation + */ + declare class OCCT { + readonly occWorkerManager: OCCTWorkerManager; + readonly shapes: OCCTShapes; + readonly geom: OCCTGeom; + readonly fillets: OCCTFillets; + readonly transforms: OCCTTransforms; + readonly operations: OCCTOperations; + readonly booleans: OCCTBooleans; + readonly dimensions: OCCTDimensions; + readonly shapeFix: OCCTShapeFix; + io: OCCTIO; + constructor(occWorkerManager: OCCTWorkerManager); + /** + * Creates polygon points from the shape faces + * @param inputs shape + * @group convert + * @shortname faces to polygon points + * @drawable false + */ + shapeFacesToPolygonPoints( + inputs: Inputs.OCCT.ShapeFacesToPolygonPointsDto + ): Promise; + /** + * Creates mesh from the shape + * @param inputs shape + * @group convert + * @shortname shape to mesh + * @drawable false + */ + shapeToMesh( + inputs: Inputs.OCCT.ShapeToMeshDto + ): Promise; + /** + * Creates mesh from the shape + * @param inputs shape + * @group convert + * @shortname shape to mesh + * @drawable false + */ + shapesToMeshes( + inputs: Inputs.OCCT.ShapesToMeshesDto + ): Promise; + /** + * Deletes shape from the cache to keep memory usage low + * @param inputs shape + * @group memory + * @shortname delete shape + */ + deleteShape( + inputs: Inputs.OCCT.ShapeDto + ): Promise; + /** + * Deletes shapes from the cache to keep memory usage low + * @param inputs shape + * @group memory + * @shortname delete shapes + */ + deleteShapes( + inputs: Inputs.OCCT.ShapesDto + ): Promise; + /** + * Cleans all cache and all shapes from the memory + * @param inputs shape + * @group memory + * @shortname clean all cache + */ + cleanAllCache(): Promise; + } + declare class OCCTOperations { + private readonly occWorkerManager; + constructor(occWorkerManager: OCCTWorkerManager); + /** + * Lofts wires into a shell + * @param inputs Loft wires + * @returns Resulting loft shape + * @group lofts + * @shortname loft + * @drawable true + */ + loft( + inputs: Inputs.OCCT.LoftDto + ): Promise; + /** + * Lofts wires into a shell by using many advanced options + * @param inputs Advanced loft parameters + * @returns Resulting loft shell + * @group lofts + * @shortname loft adv. + * @drawable true + */ + loftAdvanced( + inputs: Inputs.OCCT.LoftAdvancedDto + ): Promise; + /** + * Computes two closest points between two shapes + * @param inputs two shapes + * @returns Resulting points + * @group closest pts + * @shortname two shapes + * @drawable true + */ + closestPointsBetweenTwoShapes( + inputs: Inputs.OCCT.ClosestPointsBetweenTwoShapesDto + ): Promise; + /** + * Computes closest points between a list of points and a given shape + * @param inputs a list of points and a shape + * @returns Resulting points + * @group closest pts + * @shortname on shape + * @drawable true + */ + closestPointsOnShapeFromPoints( + inputs: Inputs.OCCT.ClosestPointsOnShapeFromPointsDto + ): Promise; + /** + * Computes closest points between a list of points and shapes + * @param inputs a list of points and a list of shapes + * @returns Resulting points + * @group closest pts + * @shortname on shapes + * @drawable true + */ + closestPointsOnShapesFromPoints( + inputs: Inputs.OCCT.ClosestPointsOnShapesFromPointsDto + ): Promise; + /** + * Computes distances between a list of points and a corresponding closest points on shapes. + * @param inputs a list of points and a shapes + * @returns Resulting distances + * @group measure + * @shortname distances points to shape + * @drawable false + */ + distancesToShapeFromPoints( + inputs: Inputs.OCCT.ClosestPointsOnShapeFromPointsDto + ): Promise; + /** + * Computes bounding box parameters of the shape + * @param inputs a shape + * @returns Min, max center and size of the bounding box + * @group measure + * @shortname bbox of shape + * @drawable false + */ + boundingBoxOfShape( + inputs: Inputs.OCCT.ShapeDto + ): Promise; + /** + * Get min point of the bounding box of the shape + * @param inputs a shape + * @returns Min point of the bounding box + * @group measure + * @shortname bbox min of shape + * @drawable true + */ + boundingBoxMinOfShape( + inputs: Inputs.OCCT.ShapeDto + ): Promise; + /** + * Get max point of the bounding box of the shape + * @param inputs a shape + * @returns Max point of the bounding box + * @group measure + * @shortname bbox max of shape + * @drawable true + */ + boundingBoxMaxOfShape( + inputs: Inputs.OCCT.ShapeDto + ): Promise; + /** + * Get center point of the bounding box of the shape + * @param inputs a shape + * @returns Center point of the bounding box + * @group measure + * @shortname bbox center of shape + * @drawable true + */ + boundingBoxCenterOfShape( + inputs: Inputs.OCCT.ShapeDto + ): Promise; + /** + * Get size point of the bounding box of the shape + * @param inputs a shape + * @returns Center point of the bounding box + * @group measure + * @shortname bbox size of shape + * @drawable false + */ + boundingBoxSizeOfShape( + inputs: Inputs.OCCT.ShapeDto + ): Promise; + /** + * Get bounding box shape of the shape + * @param inputs a shape + * @returns shape of the bounding box + * @group measure + * @shortname bbox shape of shape + * @drawable true + */ + boundingBoxShapeOfShape( + inputs: Inputs.OCCT.ShapeDto + ): Promise; + /** + * Computes bounding sphere parameters of the shape + * @param inputs a shape + * @returns Center and radius of the bounding sphere + * @group measure + * @shortname bsphere of shape + * @drawable false + */ + boundingSphereOfShape( + inputs: Inputs.OCCT.ShapeDto + ): Promise; + /** + * Get center point of the bounding sphere of the shape + * @param inputs a shape + * @returns Center point of the bounding sphere + * @group measure + * @shortname bsphere center of shape + * @drawable false + */ + boundingSphereCenterOfShape( + inputs: Inputs.OCCT.ShapeDto + ): Promise; + /** + * Get radius of the bounding sphere of the shape + * @param inputs a shape + * @returns Radius of the bounding sphere + * @group measure + * @shortname bsphere radius of shape + * @drawable false + */ + boundingSphereRadiusOfShape( + inputs: Inputs.OCCT.ShapeDto + ): Promise; + /** + * Get bounding sphere shape of the shape + * @param inputs a shape + * @returns shape of the bounding sphere + * @group measure + * @shortname bsphere shape of shape + * @drawable true + */ + boundingSphereShapeOfShape( + inputs: Inputs.OCCT.ShapeDto + ): Promise; + /** + * Extrudes the shape along direction - wire will produce shell, face will produce solid + * @param inputs Shape to extrude and direction parameter with tolerance + * @returns Resulting extruded shape + * @group extrusions + * @shortname extrude + * @drawable true + */ + extrude( + inputs: Inputs.OCCT.ExtrudeDto + ): Promise; + /** + * Extrudes the shapes along direction + * @param inputs Shapes to extrude and direction parameter with tolerance + * @returns Resulting extruded shapes + * @group extrusions + * @shortname extrude shapes + * @drawable true + */ + extrudeShapes( + inputs: Inputs.OCCT.ExtrudeShapesDto + ): Promise; + /** + * Splits the shape with shapes + * @param inputs Shape to split and shapes to split with + * @returns Resulting shapes + * @group divisions + * @shortname split + * @drawable true + */ + splitShapeWithShapes( + inputs: Inputs.OCCT.SplitDto + ): Promise; + /** + * Revolves the shape around the given direction + * @param inputs Revolve parameters + * @returns Resulting revolved shape + * @group revolutions + * @shortname revolve + * @drawable true + */ + revolve( + inputs: Inputs.OCCT.RevolveDto + ): Promise; + /** + * Rotated extrude that is perofrmed on the shape + * @param inputs Rotated extrusion inputs + * @returns OpenCascade shape + * @group extrusions + * @shortname rotated extrude + * @drawable true + */ + rotatedExtrude( + inputs: Inputs.OCCT.RotationExtrudeDto + ): Promise; + /** + * Pipe shapes along the wire + * @param inputs Path wire and shapes along the path + * @returns OpenCascade shape + * @group pipeing + * @shortname pipe + * @drawable true + */ + pipe( + inputs: Inputs.OCCT.ShapeShapesDto< + Inputs.OCCT.TopoDSWirePointer, + Inputs.OCCT.TopoDSShapePointer + > + ): Promise; + /** + * Pipes polyline wire with ngon profile. + * @param inputs Path polyline wire + * @returns OpenCascade piped shapes + * @group pipeing + * @shortname pipe polyline ngon + * @drawable true + */ + pipePolylineWireNGon( + inputs: Inputs.OCCT.PipePolygonWireNGonDto + ): Promise; + /** + * Pipe wires with cylindrical shape + * @param inputs Path wires and radius + * @returns OpenCascade piped shapes + * @group pipeing + * @shortname pipe wires cylindrical + * @drawable true + */ + pipeWiresCylindrical( + inputs: Inputs.OCCT.PipeWiresCylindricalDto + ): Promise; + /** + * Pipe wire with cylindrical shape + * @param inputs Path wire and radius + * @returns OpenCascade piped shapes + * @group pipeing + * @shortname pipe wire cylindrical + * @drawable true + */ + pipeWireCylindrical( + inputs: Inputs.OCCT.PipeWireCylindricalDto + ): Promise; + /** + * Offset for various shapes + * @param inputs Shape to offset and distance with tolerance + * @returns Resulting offset shape + * @group offsets + * @shortname offset + * @drawable true + */ + offset( + inputs: Inputs.OCCT.OffsetDto< + Inputs.OCCT.TopoDSShapePointer, + Inputs.OCCT.TopoDSFacePointer + > + ): Promise; + /** + * Offset advanced that give more options for offset, such as joinType for edges and corners + * @param inputs Shape to offset and advanced parameters + * @returns Resulting offset shape + * @group offsets + * @shortname offset adv. + * @drawable true + */ + offsetAdv( + inputs: Inputs.OCCT.OffsetAdvancedDto< + Inputs.OCCT.TopoDSShapePointer, + Inputs.OCCT.TopoDSFacePointer + > + ): Promise; + /** + * Thickens the shape into a solid by an offset distance + * @param inputs OpenCascade shape + * @returns OpenCascade solid shape + * @group offsets + * @shortname thicken + * @drawable true + */ + makeThickSolidSimple( + inputs: Inputs.OCCT.ThisckSolidSimpleDto + ): Promise; + /** + * Thickens the shape into a solid by joining + * @param inputs OpenCascade shape and options for thickening + * @returns OpenCascade solid shape + * @group offsets + * @shortname joined thicken + * @drawable true + */ + makeThickSolidByJoin( + inputs: Inputs.OCCT.ThickSolidByJoinDto + ): Promise; + /** + * Slices the shape + * @param inputs OpenCascade shape and options for slicing + * @returns OpenCascade shape + * @group divisions + * @shortname slice + * @drawable true + */ + slice( + inputs: Inputs.OCCT.SliceDto + ): Promise; + /** + * Slices the shape in step pattern + * @param inputs OpenCascade shape and options for slicing + * @returns OpenCascade shape + * @group divisions + * @shortname slice in step pattern + * @drawable true + */ + sliceInStepPattern( + inputs: Inputs.OCCT.SliceInStepPatternDto + ): Promise; + /** + * Offset the 3D wire. When using this method consider using it on filleted wires that do not contain sharp corners. + * You can use fillet 3D on it. + * @param inputs wire and shape + * @returns OpenCascade compound + * @group offsets + * @shortname offset 3d wire + * @drawable true + */ + offset3DWire( + inputs: Inputs.OCCT.Offset3DWireDto + ): Promise; + } + declare class OCCTShapeFix { + private readonly occWorkerManager; + constructor(occWorkerManager: OCCTWorkerManager); + /** + * Performs the basic shape repair + * @param inputs the shape to be fixed and some options + * @returns OpenCascade fixed shape + * @group shape + * @shortname basic shape repair + * @drawable true + */ + basicShapeRepair( + inputs: Inputs.OCCT.BasicShapeRepairDto + ): Promise; + /** + * Fix small edge on wire + * @param inputs the wire to be fixed and some options + * @returns OpenCascade fixed wire + * @group wire + * @shortname fix small edge + * @drawable true + */ + fixSmallEdgeOnWire( + inputs: Inputs.OCCT.FixSmallEdgesInWireDto + ): Promise; + /** + * Fix edge orientations along wire + * @param inputs the wire to be fixed and some options + * @returns OpenCascade fixed wire + * @group wire + * @shortname fix edge orientations + * @drawable true + */ + fixEdgeOrientationsAlongWire( + inputs: Inputs.OCCT.ShapeDto + ): Promise; + } + declare class OCCTCompound { + private readonly occWorkerManager; + constructor(occWorkerManager: OCCTWorkerManager); + /** + * Makes the compound shape, which can include any kind of shapes + * @param inputs OpenCascade shapes + * @returns OpenCascade compounded shape + * @group create + * @shortname make + * @drawable true + */ + makeCompound( + inputs: Inputs.OCCT.CompoundShapesDto + ): Promise; + /** + * Gets the shapes that compound is made of + * @param inputs OpenCascade shapes + * @returns OpenCascade compounded shape + * @group get + * @shortname get shapes of compound + * @drawable true + */ + getShapesOfCompound( + inputs: Inputs.OCCT.ShapeDto + ): Promise; + } + declare class OCCTEdge { + private readonly occWorkerManager; + constructor(occWorkerManager: OCCTWorkerManager); + /** + * Creates linear edge from base line format {start: Point3, end: Point3} + * @param inputs base line + * @returns OpenCascade edge + * @group from base + * @shortname edge from base line + * @drawable true + */ + fromBaseLine( + inputs: Inputs.OCCT.LineBaseDto + ): Promise; + /** + * Creates linear edges from base lines format {start: Point3, end: Point3}[] + * @param inputs base lines + * @returns OpenCascade edges + * @group from base + * @shortname edges from base lines + * @drawable true + */ + fromBaseLines( + inputs: Inputs.OCCT.LineBaseDto + ): Promise; + /** + * Creates linear edge from base segment format [Point3, Point3] + * @param inputs base segment + * @returns OpenCascade edge + * @group from base + * @shortname edge from base segment + * @drawable true + */ + fromBaseSegment( + inputs: Inputs.OCCT.SegmentBaseDto + ): Promise; + /** + * Creates linear edge from base segments format [Point3, Point3][] + * @param inputs base segments + * @returns OpenCascade edges + * @group from base + * @shortname edges from base segments + * @drawable true + */ + fromBaseSegments( + inputs: Inputs.OCCT.SegmentsBaseDto + ): Promise; + /** + * Creates linear edges from collection of points + * @param inputs Points + * @returns OpenCascade edges + * @group from base + * @shortname edges from points + * @drawable true + */ + fromPoints( + inputs: Inputs.OCCT.PointsDto + ): Promise; + /** + * Creates linear edges from polyline definition + * @param inputs Polyline + * @returns OpenCascade edges + * @group from base + * @shortname edges from polyline + * @drawable true + */ + fromBasePolyline( + inputs: Inputs.OCCT.PolylineBaseDto + ): Promise; + /** + * Creates linear edges from triangle definition + * @param inputs Triangle + * @returns OpenCascade edges + * @group from base + * @shortname edges from triangle + * @drawable true + */ + fromBaseTriangle( + inputs: Inputs.OCCT.TriangleBaseDto + ): Promise; + /** + * Creates linear edges from mesh definition + * @param inputs Mesh + * @returns OpenCascade edges + * @group from base + * @shortname edges from mesh + * @drawable true + */ + fromBaseMesh( + inputs: Inputs.OCCT.MeshBaseDto + ): Promise; + /** + * Creates linear edge between two points + * @param inputs Two points between which edge should be created + * @returns OpenCascade edge + * @group primitives + * @shortname line + * @drawable true + */ + line(inputs: Inputs.OCCT.LineDto): Promise; + /** + * Creates arc edge between three points + * @param inputs three points + * @returns OpenCascade edge + * @group primitives + * @shortname arc 3 points + * @drawable true + */ + arcThroughThreePoints( + inputs: Inputs.OCCT.ArcEdgeThreePointsDto + ): Promise; + /** + * Creates arc edge between two points given the tangent direction vector on first point. + * @param inputs two points and tangent vector + * @returns OpenCascade edge + * @group primitives + * @shortname arc 2 points tangent + * @drawable true + */ + arcThroughTwoPointsAndTangent( + inputs: Inputs.OCCT.ArcEdgeTwoPointsTangentDto + ): Promise; + /** + * Creates an arc edge between two points on a circle + * @param inputs two points and circle edge + * @returns OpenCascade edge + * @group primitives + * @shortname arc from circle and points + * @drawable true + */ + arcFromCircleAndTwoPoints( + inputs: Inputs.OCCT.ArcEdgeCircleTwoPointsDto + ): Promise; + /** + * Creates an arc edge between two alpha angles on a circle + * @param inputs two angles and circle edge + * @returns OpenCascade edge + * @group primitives + * @shortname arc from circle and angles + * @drawable true + */ + arcFromCircleAndTwoAngles( + inputs: Inputs.OCCT.ArcEdgeCircleTwoAnglesDto + ): Promise; + /** + * Creates an arc edge between the point on a circle and a given alpha angle + * @param inputs point, circle edge and alpha angle + * @returns OpenCascade edge + * @group primitives + * @shortname arc from circle point and angle + * @drawable true + */ + arcFromCirclePointAndAngle( + inputs: Inputs.OCCT.ArcEdgeCirclePointAngleDto + ): Promise; + /** + * Creates OpenCascade circle edge + * @param inputs Circle parameters + * @returns OpenCascade circle edge + * @group primitives + * @shortname circle + * @drawable true + */ + createCircleEdge( + inputs: Inputs.OCCT.CircleDto + ): Promise; + /** + * Creates OpenCascade ellipse edge + * @param inputs Ellipse parameters + * @returns OpenCascade ellipse edge + * @group primitives + * @shortname ellipse + * @drawable true + */ + createEllipseEdge( + inputs: Inputs.OCCT.EllipseDto + ): Promise; + /** + * Removes internal faces for the shape + * @param inputs Shape + * @returns OpenCascade shape with no internal edges + * @group shapes + * @shortname remove internal + * @drawable true + */ + removeInternalEdges( + inputs: Inputs.OCCT.ShapeDto + ): Promise; + /** + * Creates an edge from geom curve and geom surface + * @param inputs shapes are expected to contain 2 array elements - first is geom curve, second geom surface + * @returns OpenCascade TopoDS_Edge + * @group from + * @shortname 2d curve and surface + * @drawable true + */ + makeEdgeFromGeom2dCurveAndSurface( + inputs: Inputs.OCCT.CurveAndSurfaceDto< + Inputs.OCCT.Geom2dCurvePointer, + Inputs.OCCT.GeomSurfacePointer + > + ): Promise; + /** + * Gets the edge by providing an index from the shape + * @param inputs Shape + * @returns OpenCascade edge + * @group get + * @shortname get edge + * @drawable true + */ + getEdge( + inputs: Inputs.OCCT.EdgeIndexDto + ): Promise; + /** + * Gets the edges of a shape in a list + * @param inputs Shape + * @returns OpenCascade edge list + * @group get + * @shortname get edges + * @drawable true + */ + getEdges( + inputs: Inputs.OCCT.ShapeDto + ): Promise; + /** + * Gets the edges of a wire ordered along the direction of the wire + * @param inputs wire shape + * @returns OpenCascade edge list + * @group get + * @shortname get edges along wire + * @drawable true + */ + getEdgesAlongWire( + inputs: Inputs.OCCT.ShapeDto + ): Promise; + /** + * Gets circular edges of a wire ordered along the direction of the wire + * @param inputs wire shape + * @returns OpenCascade edge list + * @group get + * @shortname get circular edges along wire + * @drawable true + */ + getCircularEdgesAlongWire( + inputs: Inputs.OCCT.ShapeDto + ): Promise; + /** + * Gets linear edges of a wire ordered along the direction of the wire + * @param inputs wire shape + * @returns OpenCascade edge list + * @group get + * @shortname get linear edges along wire + * @drawable true + */ + getLinearEdgesAlongWire( + inputs: Inputs.OCCT.ShapeDto + ): Promise; + /** + * Gets corner points of edges for a shape. There's no order guarantee here. All duplicates are removed, so when three edges form one corner, that will be represented by a single point in the list. + * @param inputs Shape that contains edges - wire, face, shell, solid + * @returns List of points + * @group get + * @shortname corners + * @drawable true + */ + getCornerPointsOfEdgesForShape( + inputs: Inputs.OCCT.ShapeDto + ): Promise; + /** + * Gets the edge length + * @param inputs edge + * @returns Length + * @group get + * @shortname edge length + * @drawable false + */ + getEdgeLength( + inputs: Inputs.OCCT.ShapeDto + ): Promise; + /** + * Gets the edge lengths of the shape + * @param inputs shape + * @returns Lengths + * @group get + * @shortname edge lengths of shape + * @drawable false + */ + getEdgeLengthsOfShape( + inputs: Inputs.OCCT.ShapeDto + ): Promise; + /** + * Gets the lengths of the edges + * @param inputs edges + * @returns Lengths + * @group get + * @shortname lengths + * @drawable false + */ + getEdgesLengths( + inputs: Inputs.OCCT.ShapesDto + ): Promise; + /** + * Gets the center of mass for the edge + * @param inputs edge + * @returns Point representing center of mass + * @group get + * @shortname center of mass + * @drawable true + */ + getEdgeCenterOfMass( + inputs: Inputs.OCCT.ShapeDto + ): Promise; + /** + * Gets the centers of mass for the edges + * @param inputs edges + * @returns Points representing centers of mass + * @group get + * @shortname centers of mass + * @drawable true + */ + getEdgesCentersOfMass( + inputs: Inputs.OCCT.ShapesDto + ): Promise; + /** + * Gets the center point of the circular edge. If edge is not circular, point will not be returned. + * @param inputs edge + * @returns Point representing center of the circular edge + * @group get circular edge + * @shortname get center of circular edge + * @drawable true + */ + getCircularEdgeCenterPoint( + inputs: Inputs.OCCT.ShapeDto + ): Promise; + /** + * Gets the radius of the circular edge. If edge is not circular, radius will not be returned. + * @param inputs edge + * @returns Radius of the circular edge + * @group get circular edge + * @shortname get radius of circular edge + * @drawable false + */ + getCircularEdgeRadius( + inputs: Inputs.OCCT.ShapeDto + ): Promise; + /** + * Gets the direction vector of the plane of the circular edge. If edge is not circular, direction vector will not be returned. + * @param inputs edge + * @returns Direction vector of the circular edge + * @group get circular edge + * @shortname get plane direction of circular edge + * @drawable true + */ + getCircularEdgePlaneDirection( + inputs: Inputs.OCCT.ShapeDto + ): Promise; + /** + * Gets the point on edge at param + * @param input edge + * @returns Point on param + * @group extract + * @shortname point at param + * @drawable true + */ + pointOnEdgeAtParam( + inputs: Inputs.OCCT.DataOnGeometryAtParamDto + ): Promise; + /** + * Gets the points on edges at param + * @param input edges + * @returns Points on param + * @group extract + * @shortname points on edges at param + * @drawable true + */ + pointsOnEdgesAtParam( + inputs: Inputs.OCCT.DataOnGeometryesAtParamDto + ): Promise; + /** + * Gets the points of all edges from a shape in separate lists for each edge + * @param inputs Shape + * @returns OpenCascade points lists + * @group extract + * @shortname edges to points + * @drawable false + */ + edgesToPoints( + inputs: Inputs.OCCT.EdgesToPointsDto + ): Promise; + /** + * Computes reversed edge from input edge + * @param inputs Shape + * @returns OpenCascade edge + * @group get + * @shortname reversed edge + * @drawable true + */ + reversedEdge( + inputs: Inputs.OCCT.ShapeDto + ): Promise; + /** + * Gets the tangent vector on edge at param + * @param input edge + * @returns Tangent vector on param + * @group extract + * @shortname tangent at param + * @drawable true + */ + tangentOnEdgeAtParam( + inputs: Inputs.OCCT.DataOnGeometryAtParamDto + ): Promise; + /** + * Gets the tangent vectors on edges at param + * @param input edges + * @returns Tangent vectors on param + * @group extract + * @shortname tangents on edges at param + * @drawable true + */ + tangentsOnEdgesAtParam( + inputs: Inputs.OCCT.DataOnGeometryesAtParamDto + ): Promise; + /** + * Gets the point on edge at length + * @param input edge and length + * @returns Point on edge + * @group extract + * @shortname point at length + * @drawable true + */ + pointOnEdgeAtLength( + inputs: Inputs.OCCT.DataOnGeometryAtLengthDto + ): Promise; + /** + * Gets the points on edges at length + * @param input edges and length + * @returns Points on edges + * @group extract + * @shortname points at length + * @drawable true + */ + pointsOnEdgesAtLength( + inputs: Inputs.OCCT.DataOnGeometryesAtLengthDto + ): Promise; + /** + * Gets the tangent vector on edge at length + * @param input edge and length + * @returns Tangent vector on edge + * @group extract + * @shortname tangent at length + * @drawable true + */ + tangentOnEdgeAtLength( + inputs: Inputs.OCCT.DataOnGeometryAtLengthDto + ): Promise; + /** + * Gets the tangent vectors on edges at length + * @param input edges and length + * @returns Tangent vectors on edges + * @group extract + * @shortname tangents at length + * @drawable true + */ + tangentsOnEdgesAtLength( + inputs: Inputs.OCCT.DataOnGeometryesAtLengthDto + ): Promise; + /** + * Gets the start point on edge + * @param input edge + * @returns Start point + * @group extract + * @shortname start point + * @drawable true + */ + startPointOnEdge( + inputs: Inputs.OCCT.ShapeDto + ): Promise; + /** + * Gets the start points on edges + * @param input edges + * @returns Start points + * @group extract + * @shortname start points + * @drawable true + */ + startPointsOnEdges( + inputs: Inputs.OCCT.ShapesDto + ): Promise; + /** + * Gets the end point on edge + * @param input edge + * @returns End point + * @group extract + * @shortname end point + * @drawable true + */ + endPointOnEdge( + inputs: Inputs.OCCT.ShapeDto + ): Promise; + /** + * Gets the end points on edges + * @param input edges + * @returns End points + * @group extract + * @shortname end points + * @drawable true + */ + endPointsOnEdges( + inputs: Inputs.OCCT.ShapesDto + ): Promise; + /** + * Divides edge by params to points + * @param input edge and division params + * @returns Points + * @group extract + * @shortname points by params + * @drawable true + */ + divideEdgeByParamsToPoints( + inputs: Inputs.OCCT.DivideDto + ): Promise; + /** + * Divides edges by params to points + * @param input edges and division params + * @returns Points + * @group extract + * @shortname points by params on edges + * @drawable false + */ + divideEdgesByParamsToPoints( + inputs: Inputs.OCCT.DivideShapesDto + ): Promise; + /** + * Divides edge by length to points + * @param input edge and division params + * @returns Points + * @group extract + * @shortname points by distance + * @drawable true + */ + divideEdgeByEqualDistanceToPoints( + inputs: Inputs.OCCT.DivideDto + ): Promise; + /** + * Divides edges by length to points + * @param input edges and division params + * @returns Points + * @group extract + * @shortname points by distance on edges + * @drawable false + */ + divideEdgesByEqualDistanceToPoints( + inputs: Inputs.OCCT.DivideShapesDto + ): Promise; + /** + * Creates lines from two given points till circle tangent locations + * @param input resulting lines + * @returns lines + * @group constraint + * @shortname tan lines from 2 pts to circle + * @drawable true + */ + constraintTanLinesFromTwoPtsToCircle( + inputs: Inputs.OCCT.ConstraintTanLinesFromTwoPtsToCircleDto + ): Promise; + /** + * Creates lines from a given point till circle tangent locations + * @param input resulting lines + * @returns lines + * @group constraint + * @shortname tan lines from pt to circle + * @drawable true + */ + constraintTanLinesFromPtToCircle( + inputs: Inputs.OCCT.ConstraintTanLinesFromPtToCircleDto + ): Promise; + /** + * Creates tangent lines between two circles. + * @param input resulting lines + * @returns lines + * @group constraint + * @shortname tan lines on two circles + * @drawable true + */ + constraintTanLinesOnTwoCircles( + inputs: Inputs.OCCT.ConstraintTanLinesOnTwoCirclesDto + ): Promise; + /** + * Creates tangent circles between two circles. + * @param input resulting circles + * @returns circles + * @group constraint + * @shortname tan circles on two circles + * @drawable true + */ + constraintTanCirclesOnTwoCircles( + inputs: Inputs.OCCT.ConstraintTanCirclesOnTwoCirclesDto + ): Promise; + /** + * Creates tangent circles between a point and a circle. + * @param input resulting circles + * @returns circles + * @group constraint + * @shortname tan circles on circle and pnt + * @drawable true + */ + constraintTanCirclesOnCircleAndPnt( + inputs: Inputs.OCCT.ConstraintTanCirclesOnCircleAndPntDto + ): Promise; + /** + * Checks whether an edge is linear + * @param input edge + * @returns boolean if is linear + * @group is + * @shortname is edge linear + * @drawable false + */ + isEdgeLinear( + inputs: Inputs.OCCT.ShapeDto + ): Promise; + /** + * Checks whether an edge is circular + * @param input edge + * @returns boolean if is circular + * @group is + * @shortname is edge circular + * @drawable false + */ + isEdgeCircular( + inputs: Inputs.OCCT.ShapeDto + ): Promise; + } + declare class OCCTFace { + private readonly occWorkerManager; + constructor(occWorkerManager: OCCTWorkerManager); + /** + * Creates face from triangle definition + * @param inputs Triangle + * @returns OpenCascade face + * @group from base + * @shortname face from triangle + * @drawable true + */ + fromBaseTriangle( + inputs: Inputs.OCCT.TriangleBaseDto + ): Promise; + /** + * Creates faces from mesh definition + * @param inputs Mesh + * @returns OpenCascade faces + * @group from base + * @shortname faces from mesh + * @drawable true + */ + fromBaseMesh( + inputs: Inputs.OCCT.MeshBaseDto + ): Promise; + /** + * Creates a faces from wires on face + * @param inputs OpenCascade wires and guiding face + * @returns OpenCascade faces + * @group from + * @shortname faces from wires on face + * @drawable true + */ + createFacesFromWiresOnFace( + inputs: Inputs.OCCT.FacesFromWiresOnFaceDto< + Inputs.OCCT.TopoDSWirePointer, + Inputs.OCCT.TopoDSFacePointer + > + ): Promise; + /** + * Creates a face from wire on face + * @param inputs OpenCascade wire shape and guiding face + * @returns OpenCascade face shape + * @group from + * @shortname face from wire on face + * @drawable true + */ + createFaceFromWireOnFace( + inputs: Inputs.OCCT.FaceFromWireOnFaceDto< + Inputs.OCCT.TopoDSWirePointer, + Inputs.OCCT.TopoDSFacePointer + > + ): Promise; + /** + * Creates a face from wire + * @param inputs OpenCascade wire shape and indication if face should be planar + * @returns OpenCascade face shape + * @group from + * @shortname face from wire + * @drawable true + */ + createFaceFromWire( + inputs: Inputs.OCCT.FaceFromWireDto + ): Promise; + /** + * Creates a face from wires. This can produce hollow faces. + * @param inputs OpenCascade wire shapes and indication if face should be planar + * @returns OpenCascade face shape + * @group from + * @shortname face from wires + * @drawable true + */ + createFaceFromWires( + inputs: Inputs.OCCT.FaceFromWiresDto + ): Promise; + /** + * Creates a face from wires on the guiding face. This can produce hollow faces. + * @param inputs OpenCascade wire shapes and indication if wire is inside the face + * @returns OpenCascade face shape + * @group from + * @shortname face from wires on face + * @drawable true + */ + createFaceFromWiresOnFace( + inputs: Inputs.OCCT.FaceFromWiresOnFaceDto< + Inputs.OCCT.TopoDSWirePointer, + Inputs.OCCT.TopoDSFacePointer + > + ): Promise; + /** + * Creates faces from wires + * @param inputs OpenCascade wire shape and indication if face should be planar + * @returns OpenCascade face shape + * @group from + * @shortname faces from wires + * @drawable true + */ + createFacesFromWires( + inputs: Inputs.OCCT.FacesFromWiresDto + ): Promise; + /** + * Creates face from multiple circle tangent wires + * @param inputs OpenCascade circle wire shapes + * @returns OpenCascade face shape + * @group from + * @shortname face from circles tan + * @drawable true + */ + createFaceFromMultipleCircleTanWires( + inputs: Inputs.OCCT.FaceFromMultipleCircleTanWiresDto + ): Promise; + /** + * Creates face from multiple circle tangent wire collections + * @param inputs OpenCascade circle wire shapes + * @returns OpenCascade face shape + * @group from + * @shortname face from multiple circle tan collections + * @drawable true + */ + createFaceFromMultipleCircleTanWireCollections( + inputs: Inputs.OCCT.FaceFromMultipleCircleTanWireCollectionsDto + ): Promise; + /** + * Creates a face from the surface + * @param inputs Face shape + * @returns OpenCascade surface + * @group from + * @shortname surface + * @drawable true + */ + faceFromSurface( + inputs: Inputs.OCCT.ShapeDto + ): Promise; + /** + * Creates a face from the surface and a wire + * @param inputs OpenCascade surface, a wire and indication wether face should be created inside or not + * @returns Face shape + * @group from + * @shortname surface and wire + * @drawable true + */ + faceFromSurfaceAndWire( + inputs: Inputs.OCCT.FaceFromSurfaceAndWireDto< + Inputs.OCCT.GeomSurfacePointer, + Inputs.OCCT.TopoDSWirePointer + > + ): Promise; + /** + * Creates OpenCascade Polygon face + * @param inputs Polygon points + * @returns OpenCascade polygon face + * @group primitives + * @shortname polygon + * @drawable true + */ + createPolygonFace( + inputs: Inputs.OCCT.PolygonDto + ): Promise; + /** + * Creates OpenCascade circle face + * @param inputs Circle parameters + * @returns OpenCascade circle face + * @group primitives + * @shortname circle + * @drawable true + */ + createCircleFace( + inputs: Inputs.OCCT.CircleDto + ): Promise; + /** + * Creates OpenCascade hexagons in grid + * @param inputs Hexagon parameters + * @returns OpenCascade hexagons in grid + * @group primitives + * @shortname hexagons in grid + * @drawable true + */ + hexagonsInGrid( + inputs: Inputs.OCCT.HexagonsInGridDto + ): Promise; + /** + * Creates OpenCascade ellipse face + * @param inputs Ellipse parameters + * @returns OpenCascade ellipse face + * @group primitives + * @shortname ellipse + * @drawable true + */ + createEllipseFace( + inputs: Inputs.OCCT.EllipseDto + ): Promise; + /** + * Creates OpenCascade square face + * @param inputs Square parameters + * @returns OpenCascade square face + * @group primitives + * @shortname square + * @drawable true + */ + createSquareFace( + inputs: Inputs.OCCT.SquareDto + ): Promise; + /** + * Creates OpenCascade rectangle face + * @param inputs rectangle parameters + * @returns OpenCascade rectangle + * @group primitives + * @shortname rectangle + * @drawable true + */ + createRectangleFace( + inputs: Inputs.OCCT.RectangleDto + ): Promise; + /** + * Creates OpenCascade L-polygon face + * @param inputs L-polygon parameters + * @returns OpenCascade L-polygon face + * @group primitives + * @shortname L-polygon + * @drawable true + */ + createLPolygonFace( + inputs: Inputs.OCCT.LPolygonDto + ): Promise; + /** + * Creates OpenCascade star face + * @param inputs Star parameters + * @returns OpenCascade star face + * @group primitives + * @shortname star + * @drawable true + */ + createStarFace( + inputs: Inputs.OCCT.StarDto + ): Promise; + /** + * Creates OpenCascade christmas tree face + * @param inputs Christmas tree parameters + * @returns OpenCascade christmas tree face + * @group primitives + * @shortname christmas tree + * @drawable true + */ + createChristmasTreeFace( + inputs: Inputs.OCCT.ChristmasTreeDto + ): Promise; + /** + * Creates OpenCascade parallelogram face + * @param inputs Parallelogram parameters + * @returns OpenCascade parallelogram face + * @group primitives + * @shortname parallelogram + * @drawable true + */ + createParallelogramFace( + inputs: Inputs.OCCT.ParallelogramDto + ): Promise; + /** + * Creates OpenCascade heart face + * @param inputs Heart parameters + * @returns OpenCascade heart face + * @group primitives + * @shortname heart + * @drawable true + */ + createHeartFace( + inputs: Inputs.OCCT.Heart2DDto + ): Promise; + /** + * Creates OpenCascade n-gon face + * @param inputs N-gon parameters + * @returns OpenCascade n-gon face + * @group primitives + * @shortname n-gon + * @drawable true + */ + createNGonFace( + inputs: Inputs.OCCT.NGonWireDto + ): Promise; + /** + * Creates OpenCascade I-beam profile face + * @param inputs I-beam profile parameters + * @returns OpenCascade I-beam profile face + * @group beam profiles + * @shortname I-beam profile + * @drawable true + */ + createIBeamProfileFace( + inputs: Inputs.OCCT.IBeamProfileDto + ): Promise; + /** + * Creates OpenCascade H-beam profile face + * @param inputs H-beam profile parameters + * @returns OpenCascade H-beam profile face + * @group beam profiles + * @shortname H-beam profile + * @drawable true + */ + createHBeamProfileFace( + inputs: Inputs.OCCT.HBeamProfileDto + ): Promise; + /** + * Creates OpenCascade T-beam profile face + * @param inputs T-beam profile parameters + * @returns OpenCascade T-beam profile face + * @group beam profiles + * @shortname T-beam profile + * @drawable true + */ + createTBeamProfileFace( + inputs: Inputs.OCCT.TBeamProfileDto + ): Promise; + /** + * Creates OpenCascade U-beam profile face + * @param inputs U-beam profile parameters + * @returns OpenCascade U-beam profile face + * @group beam profiles + * @shortname U-beam profile + * @drawable true + */ + createUBeamProfileFace( + inputs: Inputs.OCCT.UBeamProfileDto + ): Promise; + /** + * Gets the face by providing an index from the shape + * @param inputs Shape + * @returns OpenCascade face + * @group get + * @shortname face + * @drawable true + */ + getFace( + inputs: Inputs.OCCT.ShapeIndexDto + ): Promise; + /** + * Gets the faces of the shape in a list + * @param inputs Shape + * @returns OpenCascade faces array + * @group get + * @shortname faces + * @drawable true + */ + getFaces( + inputs: Inputs.OCCT.ShapeDto + ): Promise; + /** + * Computes reversed face from input face + * @param inputs Face + * @returns OpenCascade face + * @group get + * @shortname reversed + * @drawable true + */ + reversedFace( + inputs: Inputs.OCCT.ShapeDto + ): Promise; + /** + * Subdivides a face to point grid + * @param inputs Face and options for subdivision + * @returns points + * @group extract + * @shortname points + * @drawable true + */ + subdivideToPoints( + inputs: Inputs.OCCT.FaceSubdivisionDto + ): Promise; + /** + * Subdivides a face to wires + * @param inputs Face and options for subdivision + * @returns wires + * @group extract + * @shortname wires + * @drawable true + */ + subdivideToWires( + inputs: Inputs.OCCT.FaceSubdivisionToWiresDto + ): Promise; + /** + * Subdivides a face to rectangle wires + * @param inputs Face and options for subdivision + * @returns wires + * @group patterns + * @shortname rectangle wires on face + * @drawable true + */ + subdivideToRectangleWires( + inputs: Inputs.OCCT.FaceSubdivideToRectangleWiresDto + ): Promise; + /** + * Subdivides a face to rectangle wires + * @param inputs Face and options for subdivision + * @returns wires + * @group patterns + * @shortname rectangle holes on face + * @drawable true + */ + subdivideToRectangleHoles( + inputs: Inputs.OCCT.FaceSubdivideToRectangleHolesDto + ): Promise; + /** + * Subdivides a face to hexagon wires + * @param inputs Face and options for subdivision + * @returns wires + * @group patterns + * @shortname hexagon wires on face + * @drawable true + */ + subdivideToHexagonWires( + inputs: Inputs.OCCT.FaceSubdivideToHexagonWiresDto + ): Promise; + /** + * Subdivides a face to hexagon holes + * @param inputs Face and options for subdivision + * @returns faces + * @group patterns + * @shortname hexagon holes on face + * @drawable true + */ + subdivideToHexagonHoles( + inputs: Inputs.OCCT.FaceSubdivideToHexagonHolesDto + ): Promise; + /** + * Subdivides a face to point grid with shifts and removals on nth uv rows or columns + * @param inputs Face and params for subdivision + * @returns points + * @group extract + * @shortname points nth + * @drawable true + */ + subdivideToPointsControlled( + inputs: Inputs.OCCT.FaceSubdivisionControlledDto + ): Promise; + /** + * Subdivides a face to normals grid + * @param inputs Face and params for subdivision + * @returns normal vectors + * @group extract + * @shortname normals + * @drawable true + */ + subdivideToNormals( + inputs: Inputs.OCCT.FaceSubdivisionDto + ): Promise; + /** + * Subdivides a face to uv grid + * @param inputs Face and params for subdivision + * @returns uv params in array + * @group extract + * @shortname uvs + * @drawable true + */ + subdivideToUV( + inputs: Inputs.OCCT.FaceSubdivisionDto + ): Promise; + /** + * Get point on UV where U and V are described between 0 and 1. These will be mapped to real bounds. + * @param inputs Face and params for subdivision + * @returns point + * @group extract + * @shortname point on uv + * @drawable true + */ + pointOnUV( + inputs: Inputs.OCCT.DataOnUVDto + ): Promise; + /** + * Get normal on UV where U and V are described between 0 and 1. These will be mapped to real bounds. + * @param inputs Face and params for subdivision + * @returns normal vector + * @group extract + * @shortname normal on uv + * @drawable true + */ + normalOnUV( + inputs: Inputs.OCCT.DataOnUVDto + ): Promise; + /** + * Get points on UVs where U and V are described between 0 and 1 in two dimensional arrays. These will be mapped to real bounds. + * @param inputs Face and params for subdivision + * @returns points + * @group extract + * @shortname points on uvs + * @drawable true + */ + pointsOnUVs( + inputs: Inputs.OCCT.DataOnUVsDto + ): Promise; + /** + * Get normals on UVs where U and V are described between 0 and 1 in two dimensional arrays. These will be mapped to real bounds. + * @param inputs Face and params for subdivision + * @returns normals + * @group extract + * @shortname normals on uvs + * @drawable true + */ + normalsOnUVs( + inputs: Inputs.OCCT.DataOnUVsDto + ): Promise; + /** + * Subdivides a face to points along a line on parameter + * @param inputs Face and params for subdivision + * @returns points + * @group extract + * @shortname points on param + * @drawable true + */ + subdivideToPointsOnParam( + inputs: Inputs.OCCT.FaceLinearSubdivisionDto + ): Promise; + /** + * Gets the wire along the parameter on the face + * @param inputs Face and param + * @returns wire + * @group extract + * @shortname wire along param + * @drawable true + */ + wireAlongParam( + inputs: Inputs.OCCT.WireAlongParamDto + ): Promise; + /** + * Gets the wires along the parameters on the face + * @param inputs Face and params + * @returns wires + * @group extract + * @shortname wires along params + * @drawable true + */ + wiresAlongParams( + inputs: Inputs.OCCT.WiresAlongParamsDto + ): Promise; + /** + * Gets the U min bound of the face + * @param inputs OCCT Face + * @returns u min bound + * @group get + * @shortname u min + * @drawable false + */ + getUMinBound( + inputs: Inputs.OCCT.ShapeDto + ): Promise; + /** + * Gets the U max bound of the face + * @param inputs OCCT Face + * @returns u max bound + * @group get + * @shortname u max + * @drawable false + */ + getUMaxBound( + inputs: Inputs.OCCT.ShapeDto + ): Promise; + /** + * Gets the V min bound of the face + * @param inputs OCCT Face + * @returns v min bound + * @group get + * @shortname v min + * @drawable false + */ + getVMinBound( + inputs: Inputs.OCCT.ShapeDto + ): Promise; + /** + * Gets the V max bound of the face + * @param inputs OCCT Face + * @returns v max bound + * @group get + * @shortname v max + * @drawable false + */ + getVMaxBound( + inputs: Inputs.OCCT.ShapeDto + ): Promise; + /** + * Get the area of the face + * @param inputs OCCT Face + * @returns area + * @group get + * @shortname face area + * @drawable false + */ + getFaceArea( + inputs: Inputs.OCCT.ShapeDto + ): Promise; + /** + * Get the areas of the faces + * @param inputs OCCT Faces + * @returns areas + * @group get + * @shortname areas of faces + * @drawable false + */ + getFacesAreas( + inputs: Inputs.OCCT.ShapesDto + ): Promise; + /** + * Get the face center of mass point + * @param inputs OCCT Face + * @returns point + * @group get + * @shortname center of mass + * @drawable true + */ + getFaceCenterOfMass( + inputs: Inputs.OCCT.ShapeDto + ): Promise; + /** + * Get the center of mass points for faces + * @param inputs OCCT Faces + * @returns points + * @group get + * @shortname centers of mass + * @drawable true + */ + getFacesCentersOfMass( + inputs: Inputs.OCCT.ShapesDto + ): Promise; + /** + * Filters points on face + * @param inputs face and collection of points with options + * @returns filtered points + * @group filter + * @shortname filter face points + * @drawable true + */ + filterFacePoints( + inputs: Inputs.OCCT.FilterFacePointsDto + ): Promise; + /** + * Filters points on faces + * @param inputs faces and collection of points with options + * @returns filtered points + * @group filter + * @shortname filter points on faces + * @drawable true + */ + filterFacesPoints( + inputs: Inputs.OCCT.FilterFacesPointsDto + ): Promise; + } + declare class OCCTShape { + private readonly occWorkerManager; + constructor(occWorkerManager: OCCTWorkerManager); + /** + * Remove internal edges that are not connected to any face in the shape + * @param inputs shape + * @returns purged shape + * @group edit + * @shortname purge internal edges + * @drawable true + */ + purgeInternalEdges( + inputs: Inputs.OCCT.ShapeDto + ): Promise; + /** + * Unifies faces, edges in the same domain and has possibility to concatinate bsplines + * @param inputs shape + * @returns unified shape + * @group edit + * @shortname unify same domain + * @drawable true + */ + unifySameDomain( + inputs: Inputs.OCCT.UnifySameDomainDto + ): Promise; + /** + * Check if the shape is closed + * @param inputs shape + * @returns boolean answer + * @group analysis + * @shortname is closed + * @drawable false + */ + isClosed( + inputs: Inputs.OCCT.ShapeDto + ): Promise; + /** + * Check if the shape is convex + * @param inputs shape + * @returns boolean answer + * @group analysis + * @shortname is convex + * @drawable false + */ + isConvex( + inputs: Inputs.OCCT.ShapeDto + ): Promise; + /** + * Check if the shape is checked + * @param inputs shape + * @returns boolean answer + * @group analysis + * @shortname is checked + * @drawable false + */ + isChecked( + inputs: Inputs.OCCT.ShapeDto + ): Promise; + /** + * Check if the shape is free + * @param inputs shape + * @returns boolean answer + * @group analysis + * @shortname is free + * @drawable false + */ + isFree( + inputs: Inputs.OCCT.ShapeDto + ): Promise; + /** + * Check if the shape is infinite + * @param inputs shape + * @returns boolean answer + * @group analysis + * @shortname is infinite + * @drawable false + */ + isInfinite( + inputs: Inputs.OCCT.ShapeDto + ): Promise; + /** + * Check if the shape is modified + * @param inputs shape + * @returns boolean answer + * @group analysis + * @shortname is modified + * @drawable false + */ + isModified( + inputs: Inputs.OCCT.ShapeDto + ): Promise; + /** + * Check if the shape is locked + * @param inputs shape + * @returns boolean answer + * @group analysis + * @shortname is locked + * @drawable false + */ + isLocked( + inputs: Inputs.OCCT.ShapeDto + ): Promise; + /** + * Check if the shape is null + * @param inputs shape + * @returns boolean answer + * @group analysis + * @shortname is null + * @drawable false + */ + isNull( + inputs: Inputs.OCCT.ShapeDto + ): Promise; + /** + * Check if the shape is equal to other shape + * @param inputs shapes + * @returns boolean answer + * @group analysis + * @shortname is equal + * @drawable false + */ + isEqual( + inputs: Inputs.OCCT.CompareShapesDto + ): Promise; + /** + * Check if the shape is not equal to other shape + * @param inputs shapes + * @returns boolean answer + * @group analysis + * @shortname is not equal + * @drawable false + */ + isNotEqual( + inputs: Inputs.OCCT.CompareShapesDto + ): Promise; + /** + * Check if the shape is partner to other shape + * @param inputs shapes + * @returns boolean answer + * @group analysis + * @shortname is partner + * @drawable false + */ + isPartner( + inputs: Inputs.OCCT.CompareShapesDto + ): Promise; + /** + * Check if the shape is the same as the other shape + * @param inputs shapes + * @returns boolean answer + * @group analysis + * @shortname is same + * @drawable false + */ + isSame( + inputs: Inputs.OCCT.CompareShapesDto + ): Promise; + /** + * Get the shape orientation + * @param inputs shape + * @returns shape orientation + * @group analysis + * @shortname get orientation + * @drawable false + */ + getOrientation( + inputs: Inputs.OCCT.ShapeDto + ): Promise; + /** + * Get the shape type + * @param inputs shape + * @returns shape type + * @group analysis + * @shortname get shape type + * @drawable false + */ + getShapeType( + inputs: Inputs.OCCT.ShapeDto + ): Promise; + } + declare class OCCTShapes { + readonly vertex: OCCTVertex; + readonly edge: OCCTEdge; + readonly wire: OCCTWire; + readonly face: OCCTFace; + readonly shell: OCCTShell; + readonly solid: OCCTSolid; + readonly compound: OCCTCompound; + readonly shape: OCCTShape; + constructor(occWorkerManager: OCCTWorkerManager); + } + declare class OCCTShell { + private readonly occWorkerManager; + constructor(occWorkerManager: OCCTWorkerManager); + /** + * Creates a shell from faces + * @param inputs OpenCascade shell and faces + * @returns OpenCascade shell + * @group create + * @shortname sew + * @drawable true + */ + sewFaces( + inputs: Inputs.OCCT.SewDto + ): Promise; + /** + * Get shell surface area + * @param inputs shell shape + * @returns Surface area + * @group get + * @shortname area + * @drawable false + */ + getShellSurfaceArea( + inputs: Inputs.OCCT.ShapeDto + ): Promise; + } + declare class OCCTSolid { + private readonly occWorkerManager; + constructor(occWorkerManager: OCCTWorkerManager); + /** + * Creates Solid From shell that must be closed + * @param inputs Closed shell to make into solid + * @returns OpenCascade Solid + * @group from + * @shortname solid from closed shell + * @drawable true + */ + fromClosedShell( + inputs: Inputs.OCCT.ShapeDto + ): Promise; + /** + * Creates OpenCascade Box + * @param inputs Box size and center + * @returns OpenCascade Box + * @group primitives + * @shortname box + * @drawable true + */ + createBox( + inputs: Inputs.OCCT.BoxDto + ): Promise; + /** + * Creates OpenCascade Cube + * @param inputs Cube size and center + * @returns OpenCascade Cube + * @group primitives + * @shortname cube + * @drawable true + */ + createCube( + inputs: Inputs.OCCT.CubeDto + ): Promise; + /** + * Creates OpenCascade Box from corner + * @param inputs Box size and corner coordinates + * @returns OpenCascade Box + * @group primitives + * @shortname box corner + * @drawable true + */ + createBoxFromCorner( + inputs: Inputs.OCCT.BoxFromCornerDto + ): Promise; + /** + * Creates OpenCascade Cylinder + * @param inputs Cylinder parameters + * @returns OpenCascade Cylinder + * @group primitives + * @shortname cylinder + * @drawable true + */ + createCylinder( + inputs: Inputs.OCCT.CylinderDto + ): Promise; + /** + * Creates OpenCascade Cylinders on simple bit by bit lines represented by two points + * @param inputs Cylinder parameters + * @returns OpenCascade Cylinder + * @group primitives + * @shortname cylinders on lines + * @drawable true + */ + createCylindersOnLines( + inputs: Inputs.OCCT.CylindersOnLinesDto + ): Promise; + /** + * Creates OpenCascade Sphere + * @param inputs Sphere radius and center + * @returns OpenCascade Sphere + * @group primitives + * @shortname sphere + * @drawable true + */ + createSphere( + inputs: Inputs.OCCT.SphereDto + ): Promise; + /** + * Creates OpenCascade Cone + * @param inputs Cone parameters + * @returns OpenCascade cone shape + * @group primitives + * @shortname cone + * @drawable true + */ + createCone( + inputs: Inputs.OCCT.ConeDto + ): Promise; + /** + * Creates OpenCascade star solid + * @param inputs Star solid parameters + * @returns OpenCascade star solid + * @group primitives + * @shortname star + * @drawable true + */ + createStarSolid( + inputs: Inputs.OCCT.StarSolidDto + ): Promise; + /** + * Creates OpenCascade n-gon solid + * @param inputs N-gon solid parameters + * @returns OpenCascade n-gon solid + * @group primitives + * @shortname n-gon + * @drawable true + */ + createNGonSolid( + inputs: Inputs.OCCT.NGonSolidDto + ): Promise; + /** + * Creates OpenCascade parallelogram solid + * @param inputs Parallelogram solid parameters + * @returns OpenCascade parallelogram solid + * @group primitives + * @shortname parallelogram + * @drawable true + */ + createParallelogramSolid( + inputs: Inputs.OCCT.ParallelogramSolidDto + ): Promise; + /** + * Creates OpenCascade heart solid + * @param inputs Heart solid parameters + * @returns OpenCascade heart solid + * @group primitives + * @shortname heart + * @drawable true + */ + createHeartSolid( + inputs: Inputs.OCCT.HeartSolidDto + ): Promise; + /** + * Creates OpenCascade christmas tree solid + * @param inputs Christmas tree solid parameters + * @returns OpenCascade christmas tree solid + * @group primitives + * @shortname christmas tree + * @drawable true + */ + createChristmasTreeSolid( + inputs: Inputs.OCCT.ChristmasTreeSolidDto + ): Promise; + /** + * Creates OpenCascade L-polygon solid + * @param inputs L-polygon solid parameters + * @returns OpenCascade L-polygon solid + * @group primitives + * @shortname L-polygon + * @drawable true + */ + createLPolygonSolid( + inputs: Inputs.OCCT.LPolygonSolidDto + ): Promise; + /** + * Creates OpenCascade I-beam profile solid + * @param inputs I-beam profile solid parameters + * @returns OpenCascade I-beam profile solid + * @group beam + * @shortname I-beam profile + * @drawable true + */ + createIBeamProfileSolid( + inputs: Inputs.OCCT.IBeamProfileSolidDto + ): Promise; + /** + * Creates OpenCascade H-beam profile solid + * @param inputs H-beam profile solid parameters + * @returns OpenCascade H-beam profile solid + * @group beam + * @shortname H-beam profile + * @drawable true + */ + createHBeamProfileSolid( + inputs: Inputs.OCCT.HBeamProfileSolidDto + ): Promise; + /** + * Creates OpenCascade T-beam profile solid + * @param inputs T-beam profile solid parameters + * @returns OpenCascade T-beam profile solid + * @group beam + * @shortname T-beam profile + * @drawable true + */ + createTBeamProfileSolid( + inputs: Inputs.OCCT.TBeamProfileSolidDto + ): Promise; + /** + * Creates OpenCascade U-beam profile solid + * @param inputs U-beam profile solid parameters + * @returns OpenCascade U-beam profile solid + * @group beam + * @shortname U-beam profile + * @drawable true + */ + createUBeamProfileSolid( + inputs: Inputs.OCCT.UBeamProfileSolidDto + ): Promise; + /** + * Get solid surface area + * @param inputs Closed solid shape + * @returns Surface area + * @group get + * @shortname area + * @drawable false + */ + getSolidSurfaceArea( + inputs: Inputs.OCCT.ShapeDto + ): Promise; + /** + * Get solid volume + * @param inputs Closed solid shape + * @returns volume + * @group get + * @shortname volume + * @drawable false + */ + getSolidVolume( + inputs: Inputs.OCCT.ShapeDto + ): Promise; + /** + * Get solids volumes + * @param inputs Closed solid shapes + * @returns volumes + * @group get + * @shortname volumes + * @drawable false + */ + getSolidsVolumes( + inputs: Inputs.OCCT.ShapesDto + ): Promise; + /** + * Get solid center of mass + * @param inputs Closed solid shape + * @returns center of mass point + * @group get + * @shortname center of mass + * @drawable true + */ + getSolidCenterOfMass( + inputs: Inputs.OCCT.ShapeDto + ): Promise; + /** + * Get centers of mass of solids + * @param inputs Closed solid shapes + * @returns Points indicating centers of mass + * @group get + * @shortname centers of mass + * @drawable true + */ + getSolidsCentersOfMass( + inputs: Inputs.OCCT.ShapesDto + ): Promise; + /** + * Gets the solids of the shape in a list + * @param inputs Shape + * @returns OpenCascade solids array + * @group get + * @shortname solids + * @drawable true + */ + getSolids( + inputs: Inputs.OCCT.ShapeDto + ): Promise; + /** + * Filters collection of points based on relationship with the solid. You can choose whether to output in, on or out points. + * @param inputs OpenCascade solid and collection of points with options + * @returns filtered points + * @group filter + * @shortname filter solid points + * @drawable true + */ + filterSolidPoints( + inputs: Inputs.OCCT.FilterSolidPointsDto + ): Promise; + } + declare class OCCTVertex { + private readonly occWorkerManager; + constructor(occWorkerManager: OCCTWorkerManager); + /** + * Creates vertex shape from x y z coordinates + * @param inputs x y z coordinates + * @returns OpenCascade vertex + * @group from + * @shortname vertex from xyz + * @drawable true + */ + vertexFromXYZ( + inputs: Inputs.OCCT.XYZDto + ): Promise; + /** + * Creates vertex shape from point + * @param inputs a point + * @returns OpenCascade vertex + * @group from + * @shortname vertex from point + * @drawable true + */ + vertexFromPoint( + inputs: Inputs.OCCT.PointDto + ): Promise; + /** + * Creates vertices from points + * @param inputs a point + * @returns OpenCascade vertices + * @group from + * @shortname vertices from points + * @drawable true + */ + verticesFromPoints( + inputs: Inputs.OCCT.PointsDto + ): Promise; + /** + * Creates compound shape containing multiple vertices. This simply speeds up rendering and allows to apply occt transformations easily on vertex groups. + * @param inputs points + * @returns OpenCascade vertices as compound shape + * @group from + * @shortname compound vertices from points + * @drawable true + */ + verticesCompoundFromPoints( + inputs: Inputs.OCCT.PointsDto + ): Promise; + /** + * Get all vertices in the list of a shape + * @param inputs a shape + * @returns OpenCascade vertices + * @group get + * @shortname get vertices from shape + * @drawable true + */ + getVertices( + inputs: Inputs.OCCT.ShapeDto + ): Promise; + /** + * Get all vertices in the list of a shape as points + * @param inputs a shape + * @returns Points + * @group get + * @shortname get vertices as points + * @drawable true + */ + getVerticesAsPoints( + inputs: Inputs.OCCT.ShapeDto + ): Promise; + /** + * Transforms vertices to points + * @param inputs a vertex shapes + * @returns Points + * @group transform + * @shortname vertices to points + * @drawable true + */ + verticesToPoints( + inputs: Inputs.OCCT.ShapesDto + ): Promise; + /** + * Transform vertex to point + * @param inputs a vertex shape + * @returns Point + * @group transform + * @shortname vertex to point + * @drawable true + */ + vertexToPoint( + inputs: Inputs.OCCT.ShapesDto + ): Promise; + /** + * @param inputs points, shape and direction that includes the length + * @returns Points + * @group place + * @shortname project points + * @drawable true + */ + projectPoints( + inputs: Inputs.OCCT.ProjectPointsOnShapeDto + ): Promise; + } + declare class OCCTWire { + private readonly occWorkerManager; + constructor(occWorkerManager: OCCTWorkerManager); + /** + * Creates linear wire from base line format {start: Point3, end: Point3} + * @param inputs base line + * @returns OpenCascade wire + * @group from base + * @shortname wire from base line + * @drawable true + */ + fromBaseLine( + inputs: Inputs.OCCT.LineBaseDto + ): Promise; + /** + * Creates linear wires from base lines format {start: Point3, end: Point3}[] + * @param inputs base lines + * @returns OpenCascade wires + * @group from base + * @shortname wires from base lines + * @drawable true + */ + fromBaseLines( + inputs: Inputs.OCCT.LineBaseDto + ): Promise; + /** + * Creates linear wire from base segment format [Point3, Point3] + * @param inputs base segment + * @returns OpenCascade wire + * @group from base + * @shortname wire from base segment + * @drawable true + */ + fromBaseSegment( + inputs: Inputs.OCCT.SegmentBaseDto + ): Promise; + /** + * Creates linear wires from base segments format [Point3, Point3][] + * @param inputs base segments + * @returns OpenCascade wires + * @group from base + * @shortname wires from base segments + * @drawable true + */ + fromBaseSegments( + inputs: Inputs.OCCT.SegmentsBaseDto + ): Promise; + /** + * Creates wire from collection of points + * @param inputs Points + * @returns OpenCascade wire + * @group from base + * @shortname wire from points + * @drawable true + */ + fromPoints( + inputs: Inputs.OCCT.PointsDto + ): Promise; + /** + * Creates wire from polyline definition + * @param inputs Polyline + * @returns OpenCascade wire + * @group from base + * @shortname wire from polyline + * @drawable true + */ + fromBasePolyline( + inputs: Inputs.OCCT.PolylineBaseDto + ): Promise; + /** + * Creates wire from triangle definition + * @param inputs Triangle + * @returns OpenCascade wire + * @group from base + * @shortname wire from triangle + * @drawable true + */ + fromBaseTriangle( + inputs: Inputs.OCCT.TriangleBaseDto + ): Promise; + /** + * Creates wires from mesh definition + * @param inputs Mesh + * @returns OpenCascade wires + * @group from base + * @shortname wires from mesh + * @drawable true + */ + fromBaseMesh( + inputs: Inputs.OCCT.MeshBaseDto + ): Promise; + /** + * Creates OpenCascade Polygon wire + * @param inputs Polygon points + * @returns OpenCascade polygon wire shape + * @group via points + * @shortname polygon + * @drawable true + */ + createPolygonWire( + inputs: Inputs.OCCT.PolygonDto + ): Promise; + /** + * Creates OpenCascade Polygons + * @param inputs Polygon points + * @returns OpenCascade polygon wires shapes + * @group multiple + * @shortname polygons + * @drawable true + */ + createPolygons( + inputs: Inputs.OCCT.PolygonsDto + ): Promise< + Inputs.OCCT.TopoDSWirePointer[] | Inputs.OCCT.TopoDSCompoundPointer + >; + /** + * Creates OpenCascade line wire + * @param inputs line start and end point + * @returns OpenCascade line wire shape + * @group via points + * @shortname line + * @drawable true + */ + createLineWire( + inputs: Inputs.OCCT.LineDto + ): Promise; + /** + * Creates OpenCascade line wire with extensions + * @param inputs line start and end point and extension lengths for both start and end + * @returns OpenCascade line wire shape + * @group via points + * @shortname line with extensions + * @drawable true + */ + createLineWireWithExtensions( + inputs: Inputs.OCCT.LineWithExtensionsDto + ): Promise; + /** + * Creates OpenCascade lines + * @param inputs lines with start and end points + * @returns OpenCascade line wire shapes + * @group multiple + * @shortname lines + * @drawable true + */ + createLines( + inputs: Inputs.OCCT.LinesDto + ): Promise< + Inputs.OCCT.TopoDSWirePointer[] | Inputs.OCCT.TopoDSCompoundPointer + >; + /** + * Splits a wire on a set of given points + * @param inputs wire and a list of points + * @returns OpenCascade line wire shapes + * @group extract + * @shortname split on points + * @drawable true + */ + splitOnPoints( + inputs: Inputs.OCCT.SplitWireOnPointsDto + ): Promise; + /** + * Transform shape wires to points ordered in lists. + * This also removes duplicated points between start end end points of + * consecutive edges on the wire + * @param inputs OCCT shape + * @returns point lists for wires + * @group extract + * @shortname wires to points + * @drawable false + */ + wiresToPoints( + inputs: Inputs.OCCT.WiresToPointsDto + ): Promise; + /** + * Creates OpenCascade polyline wire + * @param inputs polyline points + * @returns OpenCascade polyline wire shape + * @group via points + * @shortname polyline + * @drawable true + */ + createPolylineWire( + inputs: Inputs.OCCT.PolylineDto + ): Promise; + /** + * Creates zig zag between two wires + * @param inputs two wires and zig zag parameters + * @returns OpenCascade polyline wire shape + * @group via wires + * @shortname zig zag between two wires + * @drawable true + */ + createZigZagBetweenTwoWires( + inputs: Inputs.OCCT.ZigZagBetweenTwoWiresDto + ): Promise; + /** + * Creates a tangent wire enclosing two planar circles + * @param inputs two circle wires and tolerance + * @returns OpenCascade wire shape + * @group via wires + * @shortname tangent wire from two circles + * @drawable true + */ + createWireFromTwoCirclesTan( + inputs: Inputs.OCCT.WireFromTwoCirclesTanDto + ): Promise; + /** + * Creates OpenCascade polyline wires + * @param inputs polylines + * @returns OpenCascade polyline wire shapes + * @group multiple + * @shortname polylines + * @drawable true + */ + createPolylines( + inputs: Inputs.OCCT.PolylinesDto + ): Promise< + Inputs.OCCT.TopoDSWirePointer[] | Inputs.OCCT.TopoDSCompoundPointer + >; + /** + * Creates OpenCascade Bezier wire + * @param inputs Points through which to make bezier curve + * @returns OpenCascade Bezier wire + * @group via points + * @shortname bezier + * @drawable true + */ + createBezier( + inputs: Inputs.OCCT.BezierDto + ): Promise; + /** + * Creates OpenCascade Bezier wire with weights + * @param inputs Points through which to make bezier curve and weights on those points which are used to control the curve + * @returns OpenCascade Bezier wire + * @group via points + * @shortname bezier weights + * @drawable true + */ + createBezierWeights( + inputs: Inputs.OCCT.BezierWeightsDto + ): Promise; + /** + * Creates OpenCascade Bezier wires + * @param inputs Multiple bezier wire definitions + * @returns OpenCascade Bezier wires + * @group multiple + * @shortname bezier wires + * @drawable true + */ + createBezierWires( + inputs: Inputs.OCCT.BezierWiresDto + ): Promise< + Inputs.OCCT.TopoDSWirePointer[] | Inputs.OCCT.TopoDSCompoundPointer + >; + /** + * Creates OpenCascade BSpline wire from points. This method can be used to create nicely shaped (periodic) loops. + * @param inputs Points through which to make the curve, periodic bool and tolerance + * @returns OpenCascade BSpline wire + * @group via points + * @shortname interpolate + * @drawable true + */ + interpolatePoints( + inputs: Inputs.OCCT.InterpolationDto + ): Promise; + /** + * Creates OpenCascade multiple interpolated wires + * @param inputs Interpolated wire definitions + * @returns OpenCascade BSpline wires + * @group multiple + * @shortname interpolate wires + * @drawable true + */ + interpolateWires( + inputs: Inputs.OCCT.InterpolateWiresDto + ): Promise< + Inputs.OCCT.TopoDSWirePointer[] | Inputs.OCCT.TopoDSCompoundPointer + >; + /** + * Creates OpenCascade BSPline wire + * @param inputs Points through which to make BSpline + * @returns OpenCascade BSpline wire + * @group via points + * @shortname bspline + * @drawable true + */ + createBSpline( + inputs: Inputs.OCCT.BSplineDto + ): Promise; + /** + * Creates OpenCascade BSPline wires + * @param inputs Points through which to make BSpline + * @returns OpenCascade BSpline wires + * @group multiple + * @shortname bsplines + * @drawable true + */ + createBSplines( + inputs: Inputs.OCCT.BSplinesDto + ): Promise< + Inputs.OCCT.TopoDSWirePointer[] | Inputs.OCCT.TopoDSCompoundPointer + >; + /** + * Combines OpenCascade edges and wires into a single wire + * @param inputs List of shapes of edges and wires + * @returns OpenCascade wire + * @group build + * @shortname combine + * @drawable true + */ + combineEdgesAndWiresIntoAWire( + inputs: Inputs.OCCT.ShapesDto< + Inputs.OCCT.TopoDSWirePointer | Inputs.OCCT.TopoDSEdgePointer + > + ): Promise; + /** + * Creates wire from edge + * @param inputs An edge to transform into a wire + * @returns OpenCascade wire + * @group build + * @shortname wire from edge + * @drawable true + */ + createWireFromEdge( + inputs: Inputs.OCCT.ShapeDto + ): Promise; + /** + * Adds OpenCascade edges and wires into another wire + * @param inputs List of shapes of edges and wires and a single shape wire to which edges need to be added + * @returns OpenCascade wire + * @group build + * @shortname extend + * @drawable true + */ + addEdgesAndWiresToWire( + inputs: Inputs.OCCT.ShapeShapesDto< + Inputs.OCCT.TopoDSWirePointer, + Inputs.OCCT.TopoDSWirePointer | Inputs.OCCT.TopoDSEdgePointer + > + ): Promise; + /** + * Divides OpenCascade wire to points blindly following its parametric space + * @param inputs Describes into how many points should the wire be divided + * @returns Points on wire + * @group extract + * @shortname points by params + * @drawable true + */ + divideWireByParamsToPoints( + inputs: Inputs.OCCT.DivideDto + ): Promise; + /** + * Divides OpenCascade wires to points blindly following its parametric space + * @param inputs Describes into how many points should the wires be divided + * @returns Points on wire + * @group extract from wires + * @shortname points by params + * @drawable true + */ + divideWiresByParamsToPoints( + inputs: Inputs.OCCT.DivideShapesDto + ): Promise; + /** + * Divides OpenCascade wire to equal distance points + * @param inputs Describes into how many points should the wire be divided + * @returns Points on wire + * @group extract + * @shortname points by distance + * @drawable true + */ + divideWireByEqualDistanceToPoints( + inputs: Inputs.OCCT.DivideDto + ): Promise; + /** + * Divides OpenCascade wires to equal distance points + * @param inputs Describes into how many points should the wires be divided + * @returns Points on wire + * @group extract from wires + * @shortname points by distance + * @drawable true + */ + divideWiresByEqualDistanceToPoints( + inputs: Inputs.OCCT.DivideShapesDto + ): Promise; + /** + * Evaluates point on a wire at parameter value between 0 and 1, being start and end points + * @param inputs Wire shape and parameter + * @returns Point as array of 3 numbers + * @group extract + * @shortname point at param + * @drawable true + */ + pointOnWireAtParam( + inputs: Inputs.OCCT.DataOnGeometryAtParamDto + ): Promise; + /** + * Evaluates point on a wire at certain length + * @param inputs Wire shape and length value + * @returns Point as array of 3 numbers + * @group extract + * @shortname point at length + * @drawable true + */ + pointOnWireAtLength( + inputs: Inputs.OCCT.DataOnGeometryAtLengthDto + ): Promise; + /** + * Evaluates points on a wire at certain lengths + * @param inputs Wire shape and lengths array + * @returns Points as arrays of 3 numbers + * @group extract + * @shortname points at lengths + * @drawable true + */ + pointsOnWireAtLengths( + inputs: Inputs.OCCT.DataOnGeometryAtLengthsDto + ): Promise; + /** + * Evaluates points on a wire at equal length + * @param inputs Wire shape and length + * @returns Points as arrays of 3 numbers + * @group extract + * @shortname points at equal length + * @drawable true + */ + pointsOnWireAtEqualLength( + inputs: Inputs.OCCT.PointsOnWireAtEqualLengthDto + ): Promise; + /** + * Evaluates points on a wire at pattern of lengths + * @param inputs Wire shape and lengths pattern + * @returns Points as arrays of 3 numbers + * @group extract + * @shortname points at pattern of lengths + * @drawable true + */ + pointsOnWireAtPatternOfLengths( + inputs: Inputs.OCCT.PointsOnWireAtPatternOfLengthsDto + ): Promise; + /** + * Evaluates tangent vector on a wire at parameter value between 0 and 1, being start and end points + * @param inputs Wire shape and parameter + * @returns Tangent vector as array of 3 numbers + * @group extract + * @shortname tangent at param + * @drawable true + */ + tangentOnWireAtParam( + inputs: Inputs.OCCT.DataOnGeometryAtParamDto + ): Promise; + /** + * Evaluates tangent vector on a wire at certain length + * @param inputs Wire shape and length value + * @returns Tangent vector as array of 3 numbers + * @group extract + * @shortname tangent at length + * @drawable true + */ + tangentOnWireAtLength( + inputs: Inputs.OCCT.DataOnGeometryAtLengthDto + ): Promise; + /** + * Computes 3 derivative vectors of a curve at a given length + * @param inputs Wire shape and length value + * @returns Three arrays of vectors. Each vector represents derivatives in order - first, second, third + * @group extract + * @shortname derivatives at length + * @drawable false + */ + derivativesOnWireAtLength( + inputs: Inputs.OCCT.DataOnGeometryAtLengthDto + ): Promise<[Inputs.Base.Vector3, Inputs.Base.Vector3, Inputs.Base.Vector3]>; + /** + * Computes 3 derivative vectors of a curve on parameter between 0 and 1. + * @param inputs Wire shape and parameter value + * @returns Three arrays of vectors. Each vector represents derivatives in order - first, second, third + * @group extract + * @shortname derivatives at param + * @drawable false + */ + derivativesOnWireAtParam( + inputs: Inputs.OCCT.DataOnGeometryAtParamDto + ): Promise<[Inputs.Base.Vector3, Inputs.Base.Vector3, Inputs.Base.Vector3]>; + /** + * Computes the start point on the wire at param 0 + * @param inputs Wire shape + * @returns The start point on wire + * @group extract + * @shortname start point + * @drawable true + */ + startPointOnWire( + inputs: Inputs.OCCT.ShapeDto + ): Promise; + /** + * Computes the middle point on the wire at param 0.5 + * @param inputs Wire shape + * @returns The middle point on wire + * @group extract + * @shortname mid point + * @drawable true + */ + midPointOnWire( + inputs: Inputs.OCCT.ShapeDto + ): Promise; + /** + * Computes the end point on the wire at param 1 + * @param inputs Wire shape + * @returns The length of the wire + * @group extract + * @shortname end point + * @drawable true + */ + endPointOnWire( + inputs: Inputs.OCCT.ShapeDto + ): Promise; + /** + * Creates OpenCascade circle wire + * @param inputs Circle parameters + * @returns OpenCascade circle wire + * @group primitives + * @shortname circle + * @drawable true + */ + createCircleWire( + inputs: Inputs.OCCT.CircleDto + ): Promise; + /** + * Creates OpenCascade hexagon wires in grid + * @param inputs grid parameters + * @returns OpenCascade hexagon wires + * @group primitives + * @shortname hegagons in grid + * @drawable true + */ + hexagonsInGrid( + inputs: Inputs.OCCT.HexagonsInGridDto + ): Promise; + /** + * Creates OpenCascade square wire + * @param inputs Square parameters + * @returns OpenCascade square wire + * @group primitives + * @shortname square + * @drawable true + */ + createSquareWire( + inputs: Inputs.OCCT.SquareDto + ): Promise; + /** + * Creates OpenCascade star wire + * @param inputs star parameters + * @returns OpenCascade star wire + * @group primitives + * @shortname star + * @drawable true + */ + createStarWire( + inputs: Inputs.OCCT.StarDto + ): Promise; + /** + * Creates Christmas tree wire + * @param inputs christmas tree parameters + * @returns OpenCascade christmas tree wire + * @group primitives + * @shortname christmas tree + * @drawable true + */ + createChristmasTreeWire( + inputs: Inputs.OCCT.ChristmasTreeDto + ): Promise; + /** + * Creates OpenCascade n-gon wire + * @param inputs ngon parameters + * @returns OpenCascade ngon wire + * @group primitives + * @shortname n-gon + * @drawable true + */ + createNGonWire( + inputs: Inputs.OCCT.NGonWireDto + ): Promise; + /** + * Creates n parallelogram wire + * @param inputs parallelogram parameters + * @returns OpenCascade parallelogram wire + * @group primitives + * @shortname parallelogram + * @drawable true + */ + createParallelogramWire( + inputs: Inputs.OCCT.ParallelogramDto + ): Promise; + /** + * Creates a heart wire + * @param inputs heart parameters + * @returns OpenCascade heart shaped wire + * @group primitives + * @shortname heart + * @drawable true + */ + createHeartWire( + inputs: Inputs.OCCT.Heart2DDto + ): Promise; + /** + * Creates OpenCascade rectangle wire + * @param inputs rectangle parameters + * @returns OpenCascade rectangle + * @group primitives + * @shortname rectangle + * @drawable true + */ + createRectangleWire( + inputs: Inputs.OCCT.RectangleDto + ): Promise; + /** + * Creates OpenCascade L polygon wire + * @param inputs L polygon parameters + * @returns OpenCascade polygon + * @group primitives + * @shortname L polygon + * @drawable true + */ + createLPolygonWire( + inputs: Inputs.OCCT.LPolygonDto + ): Promise; + /** + * Creates OpenCascade I-beam profile wire + * @param inputs I-beam profile parameters + * @returns OpenCascade I-beam profile wire + * @group beam profiles + * @shortname I-beam profile + * @drawable true + */ + createIBeamProfileWire( + inputs: Inputs.OCCT.IBeamProfileDto + ): Promise; + /** + * Creates OpenCascade H-beam profile wire + * @param inputs H-beam profile parameters + * @returns OpenCascade H-beam profile wire + * @group beam profiles + * @shortname H-beam profile + * @drawable true + */ + createHBeamProfileWire( + inputs: Inputs.OCCT.HBeamProfileDto + ): Promise; + /** + * Creates OpenCascade T-beam profile wire + * @param inputs T-beam profile parameters + * @returns OpenCascade T-beam profile wire + * @group beam profiles + * @shortname T-beam profile + * @drawable true + */ + createTBeamProfileWire( + inputs: Inputs.OCCT.TBeamProfileDto + ): Promise; + /** + * Creates OpenCascade U-beam profile wire + * @param inputs U-beam profile parameters + * @returns OpenCascade U-beam profile wire + * @group beam profiles + * @shortname U-beam profile + * @drawable true + */ + createUBeamProfileWire( + inputs: Inputs.OCCT.UBeamProfileDto + ): Promise; + /** + * Creates OpenCascade ellipse wire + * @param inputs Ellipse parameters + * @returns OpenCascade ellipse wire + * @group primitives + * @shortname ellipse + * @drawable true + */ + createEllipseWire( + inputs: Inputs.OCCT.EllipseDto + ): Promise; + /** + * Creates OpenCascade text wires based on simplex font created by Dr. A. V. Hershey + * @param inputs Text parameters + * @returns OpenCascade text wires + * @group primitives + * @shortname text wires + * @drawable true + */ + textWires( + inputs: Inputs.OCCT.TextWiresDto + ): Promise; + /** + * Creates OpenCascade compound out of text wires and returns additional information based on simplex font created by Dr. A. V. Hershey + * @param inputs Text parameters + * @returns OpenCascade text compound derivative data + * @group primitives + * @shortname text wires deriv + * @drawable true + */ + textWiresWithData( + inputs: Inputs.OCCT.TextWiresDto + ): Promise>; + /** + * Gets the wire by providing an index from the shape + * @param inputs Shape + * @returns OpenCascade wire + * @group get + * @shortname wire + * @drawable true + */ + getWire( + inputs: Inputs.OCCT.ShapeIndexDto + ): Promise; + /** + * Gets all the wires from the shape + * @param inputs Shape + * @returns OpenCascade wires + * @group get + * @shortname wires + * @drawable true + */ + getWires( + inputs: Inputs.OCCT.ShapeDto + ): Promise; + /** + * Get the wire center of mass point + * @param inputs OCCT Wire + * @returns point + * @group get + * @shortname center of mass + * @drawable true + */ + getWireCenterOfMass( + inputs: Inputs.OCCT.ShapeDto + ): Promise; + /** + * Get the wires centers of mass point + * @param inputs OCCT Wires + * @returns points + * @group get + * @shortname centers of mass + * @drawable true + */ + getWiresCentersOfMass( + inputs: Inputs.OCCT.ShapesDto + ): Promise; + /** + * Computes reversed wire from input wire + * @param inputs Shape + * @returns OpenCascade wire + * @group get + * @shortname reversed + * @drawable true + */ + reversedWire( + inputs: Inputs.OCCT.ShapeDto + ): Promise; + /** + * Computes reversed wire by reversing all edges and combining them into a new wire + * @param inputs Shape + * @returns OpenCascade wire + * @group get + * @shortname reversed wire by rev edges + * @drawable true + */ + reversedWireFromReversedEdges( + inputs: Inputs.OCCT.ShapeDto + ): Promise; + /** + * Checks whether wire is closed + * @param inputs wire + * @returns boolean + * @group get + * @shortname is wire closed + * @drawable false + */ + isWireClosed( + inputs: Inputs.OCCT.ShapeDto + ): Promise; + /** + * Gets the wire length + * @param inputs wire + * @returns Length + * @group get + * @shortname length + * @drawable false + */ + getWireLength( + inputs: Inputs.OCCT.ShapeDto + ): Promise; + /** + * Gets the lengths of wires + * @param inputs wires + * @returns Lengths + * @group get + * @shortname lengths + * @drawable false + */ + getWiresLengths( + inputs: Inputs.OCCT.ShapesDto + ): Promise; + /** + * Places a wire on the face by mapping it's 2d coordinates to UV space. Wire must be positioned on the ground XZ plane for this to work. + * @param inputs two shapes - first a wire and second a face + * @returns OpenCascade wire + * @group place + * @shortname wire on face + * @drawable true + */ + placeWireOnFace( + inputs: Inputs.OCCT.WireOnFaceDto< + Inputs.OCCT.TopoDSWirePointer, + Inputs.OCCT.TopoDSFacePointer + > + ): Promise; + /** + * Places multiple wires on the face by mapping it's 2d coordinates to UV space. Wires must be positioned on the ground XZ plane for this to work. + * @param inputs a face and a list of wires + * @returns OpenCascade wires + * @group place + * @shortname wires on face + * @drawable true + */ + placeWiresOnFace( + inputs: Inputs.OCCT.WiresOnFaceDto< + Inputs.OCCT.TopoDSWirePointer, + Inputs.OCCT.TopoDSFacePointer + > + ): Promise; + /** + * Closes the open wire with additional straight edge joining start and end points + * @param inputs Shape + * @returns OpenCascade wire + * @group edit + * @shortname close open wire + * @drawable true + */ + closeOpenWire( + inputs: Inputs.OCCT.ShapeDto + ): Promise; + /** + * Project wire on the shape + * @param inputs wire and shape + * @returns OpenCascade compound + * @group place + * @shortname project + * @drawable true + */ + project( + inputs: Inputs.OCCT.ProjectWireDto< + Inputs.OCCT.TopoDSWirePointer, + Inputs.OCCT.TopoDSShapePointer + > + ): Promise; + /** + * Project multiple wires on the shape + * @param inputs wire and shape + * @returns OpenCascade compound + * @group place + * @shortname project wires + * @drawable true + */ + projectWires( + inputs: Inputs.OCCT.ProjectWiresDto< + Inputs.OCCT.TopoDSWirePointer, + Inputs.OCCT.TopoDSShapePointer + > + ): Promise; + } + declare class OCCTTransforms { + private readonly occWorkerManager; + constructor(occWorkerManager: OCCTWorkerManager); + /** + * Transforms the shape + * @param inputs Transformation description + * @returns OpenCascade shape + * @group on single shape + * @shortname transform + * @drawable true + */ + transform( + inputs: Inputs.OCCT.TransformDto + ): Promise; + /** + * Rotate the shape + * @param inputs Rotation description + * @returns OpenCascade shape + * @group on single shape + * @shortname rotate + * @drawable true + */ + rotate( + inputs: Inputs.OCCT.RotateDto + ): Promise; + /** + * Rotate the shape around the provided center + * @param inputs Rotation description + * @returns OpenCascade shape + * @group on single shape + * @shortname rotate around center + * @drawable true + */ + rotateAroundCenter( + inputs: Inputs.OCCT.RotateAroundCenterDto + ): Promise; + /** + * Align the shape + * @param inputs Align description + * @returns OpenCascade shape + * @group on single shape + * @shortname align + * @drawable true + */ + align( + inputs: Inputs.OCCT.AlignDto + ): Promise; + /** + * Align the shape with normal and axis + * @param inputs Align description + * @returns OpenCascade shape + * @group on single shape + * @shortname align normal and axis + * @drawable true + */ + alignNormAndAxis( + inputs: Inputs.OCCT.AlignNormAndAxisDto + ): Promise; + /** + * Align and translates the shape + * @param inputs Align description + * @returns OpenCascade shape + * @group on single shape + * @shortname align and translate + * @drawable true + */ + alignAndTranslate( + inputs: Inputs.OCCT.AlignAndTranslateDto + ): Promise; + /** + * Translates the shape + * @param inputs Translation description + * @returns OpenCascade shape + * @group on single shape + * @shortname translate + * @drawable true + */ + translate( + inputs: Inputs.OCCT.TranslateDto + ): Promise; + /** + * Scales the shape + * @param inputs Scale description + * @returns OpenCascade shape + * @group on single shape + * @shortname scale + * @drawable true + */ + scale( + inputs: Inputs.OCCT.ScaleDto + ): Promise; + /** + * Scales the shape in 3D + * @param inputs Scale 3D description + * @returns OpenCascade scaled shape + * @group on single shape + * @shortname scale 3d + * @drawable true + */ + scale3d( + inputs: Inputs.OCCT.Scale3DDto + ): Promise; + /** + * Mirrors the shape + * @param inputs Mirror axis origin, axis direction and shape + * @returns OpenCascade shape + * @group on single shape + * @shortname mirror + * @drawable true + */ + mirror( + inputs: Inputs.OCCT.MirrorDto + ): Promise; + /** + * Mirrors the shape along the normal and origin + * @param inputs Normal for mirroring with origin + * @returns OpenCascade shape + * @group on single shape + * @shortname mirror normal + * @drawable true + */ + mirrorAlongNormal( + inputs: Inputs.OCCT.MirrorAlongNormalDto + ): Promise; + /** + * Transforms the array of shapes with transformations + * @param inputs Transformation descriptions + * @returns OpenCascade shapes + * @group on shapes + * @shortname transforms + * @drawable true + */ + transformShapes( + inputs: Inputs.OCCT.TransformShapesDto + ): Promise; + /** + * Rotate the shapes with rotations + * @param inputs Rotation descriptions + * @returns OpenCascade shapes + * @group on shapes + * @shortname rotations + * @drawable true + */ + rotateShapes( + inputs: Inputs.OCCT.RotateShapesDto + ): Promise; + /** + * Rotate the shapes around the center and an axis + * @param inputs Rotation descriptions + * @returns OpenCascade shapes + * @group on shapes + * @shortname rotations around center + * @drawable true + */ + rotateAroundCenterShapes( + inputs: Inputs.OCCT.RotateAroundCenterShapesDto + ): Promise; + /** + * Align the shapes with alignments + * @param inputs Align descriptions + * @returns OpenCascade shapes + * @group on shapes + * @shortname alignments + * @drawable true + */ + alignShapes( + inputs: Inputs.OCCT.AlignShapesDto + ): Promise; + /** + * Align and translate the shapes + * @param inputs Align descriptions + * @returns OpenCascade shapes + * @group on shapes + * @shortname align and translate + * @drawable true + */ + alignAndTranslateShapes( + inputs: Inputs.OCCT.AlignAndTranslateShapesDto + ): Promise; + /** + * Translates the shapes with translations + * @param inputs Translation descriptions + * @returns OpenCascade shapes + * @group on shapes + * @shortname translations + * @drawable true + */ + translateShapes( + inputs: Inputs.OCCT.TranslateShapesDto + ): Promise; + /** + * Scales the shapes with scale factors + * @param inputs Scale descriptions + * @returns OpenCascade shapes + * @group on shapes + * @shortname scales + * @drawable true + */ + scaleShapes( + inputs: Inputs.OCCT.ScaleShapesDto + ): Promise; + /** + * Scales the shape in 3D + * @param inputs Scale 3D descriptions + * @returns OpenCascade scaled shapes + * @group on shapes + * @shortname scales 3d + * @drawable true + */ + scale3dShapes( + inputs: Inputs.OCCT.Scale3DShapesDto + ): Promise; + /** + * Mirrors the shapes with multiple mirrors + * @param inputs Mirror axis origins, axis directions and shapes + * @returns OpenCascade shapes + * @group on shapes + * @shortname mirrors + * @drawable true + */ + mirrorShapes( + inputs: Inputs.OCCT.MirrorShapesDto + ): Promise; + /** + * Mirrors the shapes along the normal and origin + * @param inputs Normals for mirroring with origins + * @returns OpenCascade shapes + * @group on shapes + * @shortname mirrors normal + * @drawable true + */ + mirrorAlongNormalShapes( + inputs: Inputs.OCCT.MirrorAlongNormalShapesDto + ): Promise; + } + /** + * Contains various functions that expose BABYLONJS objects + */ + declare class Babylon { + mesh: BabylonMesh; + gaussianSplatting: BabylonGaussianSplatting; + camera: BabylonCamera; + webXr: BabylonWebXR; + node: BabylonNode; + engine: BabylonEngine; + scene: BabylonScene; + transforms: BabylonTransforms; + io: BabylonIO; + ray: BabylonRay; + pick: BabylonPick; + material: BabylonMaterial; + lights: BabylonLights; + meshBuilder: BabylonMeshBuilder; + texture: BabylonTexture; + tools: BabylonTools; + gui: BabylonGui; + gizmo: BabylonGizmo; + constructor(context: Context, drawHelper: DrawHelper, color: Color); + } + declare class BabylonArcRotateCamera { + private readonly context; + constructor(context: Context); + /** + * Creates a camera that rotates around a given target while traveling the arc path. This camera is suitable for simple 3D navigation and is a default camera used by bitbybit. + * @param inputs Describes the arc rotate camera + * @returns BabylonJS arc rotate camera + * @group create + * @shortname new arc rotate camera + */ + create( + inputs: Inputs.BabylonCamera.ArcRotateCameraDto + ): BABYLON.ArcRotateCamera; + private getRadians; + } + declare class BabylonCamera { + private readonly context; + free: BabylonFreeCamera; + arcRotate: BabylonArcRotateCamera; + target: BabylonTargetCamera; + constructor(context: Context); + /** + * Freeze projection matrix of the camera + * @param inputs camera to freeze + * @group adjust + * @shortname freeze projection matrix + */ + freezeProjectionMatrix(inputs: Inputs.BabylonCamera.CameraDto): void; + /** + * Unfreeze projection matrix of the camera + * @param inputs camera to unfreeze + * @group adjust + * @shortname unfreeze projection matrix + */ + unfreezeProjectionMatrix(inputs: Inputs.BabylonCamera.CameraDto): void; + /** + * Changes the position of a camera + * @param inputs camera and position + * @group set + * @shortname set camera position + */ + setPosition(inputs: Inputs.BabylonCamera.PositionDto): void; + /** + * Gets the position of a camera + * @param inputs camera + * @group get + * @shortname get camera position + */ + getPosition(inputs: Inputs.BabylonCamera.PositionDto): Base.Point3; + /** + * Changes the target of a camera + * @param inputs camera and target + * @group set + * @shortname set camera target + */ + setTarget(inputs: Inputs.BabylonCamera.TargetDto): void; + /** + * Gets the target of a camera + * @param inputs camera + * @group get + * @shortname get camera target + */ + getTarget(inputs: Inputs.BabylonCamera.PositionDto): Base.Point3; + /** + * Changes the speed of a camera + * @param inputs camera and speed + * @group set + * @shortname set camera speed + */ + setSpeed(inputs: Inputs.BabylonCamera.SpeedDto): void; + /** + * Gets the speed of a camera + * @param inputs camera + * @group get + * @shortname get camera speed + */ + getSpeed(inputs: Inputs.BabylonCamera.PositionDto): Base.Point3; + /** + * Changes the minZ of a camera + * @param inputs camera + * @group set + * @shortname set camera min z + */ + setMinZ(inputs: Inputs.BabylonCamera.MinZDto): void; + /** + * Changes the maxZ of a camera + * @param inputs camera and maxz value + * @group set + * @shortname camera max z + */ + setMaxZ(inputs: Inputs.BabylonCamera.MaxZDto): void; + /** + * Changes the the mode of the camera to orthographic + * @param inputs the camera and orthographic properties + * @group adjust + * @shortname enable orthographic mode + */ + makeCameraOrthographic(inputs: Inputs.BabylonCamera.OrthographicDto): void; + /** + * Changes the mode of a camera to perspective + * @param inputs Changes the camera maxZ + * @group adjust + * @shortname enable perspective mode + */ + makeCameraPerspective(inputs: Inputs.BabylonCamera.CameraDto): void; + } + declare class BabylonFreeCamera { + private readonly context; + constructor(context: Context); + /** + * Creates a free camera + * @param inputs Describes the free camera + * @returns BabylonJS free camera + * @group create + * @shortname new free camera + */ + create(inputs: Inputs.BabylonCamera.FreeCameraDto): BABYLON.FreeCamera; + } + declare class BabylonTargetCamera { + private readonly context; + constructor(context: Context); + /** + * Creates a target camera + * @param inputs Describes the target camera + * @returns BabylonJS target camera + * @group create + * @shortname new target camera + */ + create(inputs: Inputs.BabylonCamera.TargetCameraDto): BABYLON.TargetCamera; + } + declare class BabylonEngine { + private readonly context; + constructor(context: Context); + /** + * Gets the engine for the current context + * @ignore true + * @group engine + * @shortname get engine + */ + getEngine(): BABYLON.Engine | BABYLON.WebGPUEngine; + /** + * Gets the rendering canvas on which scene cameras can be attached + * @ignore true + * @group engine + * @shortname get rendering canvas + */ + getRenderingCanvas(): HTMLCanvasElement; + } + declare class BabylonGaussianSplatting { + private readonly context; + constructor(context: Context); + /** Creates gaussian splatting mesh + * @param inputs Contains url of Gaussian splatting mesh + * @group create + * @shortname gaussian splatting mesh + * @disposableOutput true + */ + create( + inputs: Inputs.BabylonGaussianSplatting.CreateGaussianSplattingMeshDto + ): Promise; + /** Clones gaussian splatting mesh + * @param inputs Contains BabylonJS mesh that should be cloned + * @group multiply + * @shortname clone splat + * @disposableOutput true + */ + clone( + inputs: Inputs.BabylonGaussianSplatting.GaussianSplattingMeshDto + ): BABYLON.GaussianSplattingMesh; + /** + * Gets splat positions of the gaussian splat mesh + * @param inputs Contains BabylonJS mesh + * @group get + * @shortname get splat positions + * @drawable true + */ + getSplatPositions( + inputs: Inputs.BabylonGaussianSplatting.GaussianSplattingMeshDto + ): Inputs.Base.Point3[]; + private enableShadows; + } + declare class BabylonGizmoAxisDragGizmo { + private readonly context; + constructor(context: Context); + /** + * Sets if axis is enabled or not + * @param inputs axis drag gizmo + * @returns axis drag gizmo + * @group set + * @shortname set is axis enabled + */ + setIsEnabled( + inputs: Inputs.BabylonGizmo.SetIsEnabledAxisDragGizmoDto + ): BABYLON.IAxisDragGizmo; + /** + * Checks if axis is enabled + * @param inputs axis drag gizmo + * @returns is enabled + * @group get + * @shortname is axis enabled + */ + getIsEnabled(inputs: Inputs.BabylonGizmo.AxisDragGizmoDto): boolean; + } + declare class BabylonGizmoAxisScaleGizmo { + private readonly context; + constructor(context: Context); + /** + * Sets if axis is enabled or not + * @param inputs axis scale gizmo + * @returns axis scale gizmo + * @group set + * @shortname set is axis enabled + */ + setIsEnabled( + inputs: Inputs.BabylonGizmo.SetIsEnabledAxisScaleGizmoDto + ): BABYLON.IAxisScaleGizmo; + /** + * Checks if axis is enabled + * @param inputs axis scale gizmo + * @returns is enabled + * @group get + * @shortname is axis enabled + */ + getIsEnabled(inputs: Inputs.BabylonGizmo.AxisScaleGizmoDto): boolean; + } + declare class BabylonGizmoBoundingBoxGizmo { + private readonly context; + constructor(context: Context); + /** + * Set bounding box gizmo rotation sphere size + * @param inputs bounding box gizmo + * @returns bounding box gizmo + * @group set + * @shortname set rotation sphere size + */ + setRotationSphereSize( + inputs: Inputs.BabylonGizmo.SetBoundingBoxGizmoRotationSphereSizeDto + ): BABYLON.BoundingBoxGizmo; + /** + * If set, the rotation anchors and scale boxes will increase in size based on the distance away from the camera to have a consistent screen size (Default: false) Note : fixedDragMeshScreenSize takes precedence over fixedDragMeshBoundsSize if both are true + * @param inputs bounding box gizmo + * @returns bounding box gizmo + * @group set + * @shortname set fixed drag mesh screen size + */ + setFixedDragMeshScreenSize( + inputs: Inputs.BabylonGizmo.SetBoundingBoxGizmoFixedDragMeshScreenSizeDto + ): BABYLON.BoundingBoxGizmo; + /** + * Set bounding box gizmo fixed drag mesh bounds size + * @param inputs bounding box gizmo + * @returns bounding box gizmo + * @group set + * @shortname set fixed drag mesh bounds size + */ + setFixedDragMeshBoundsSize( + inputs: Inputs.BabylonGizmo.SetBoundingBoxGizmoFixedDragMeshBoundsSizeDto + ): BABYLON.BoundingBoxGizmo; + /** + * The distance away from the object which the draggable meshes should appear world sized when fixedDragMeshScreenSize is set to true (default: 10) + * @param inputs bounding box gizmo + * @returns bounding box gizmo + * @group set + * @shortname set fixed drag mesh screen size dist factor + */ + setFixedDragMeshScreenSizeDistanceFactor( + inputs: Inputs.BabylonGizmo.SetBoundingBoxGizmoFixedDragMeshScreenSizeDistanceFactorDto + ): BABYLON.BoundingBoxGizmo; + /** + * Set bounding box gizmo scaling snap distance. Drag distance in babylon units that the gizmo will snap scaling to when dragged. + * @param inputs bounding box gizmo + * @returns bounding box gizmo + * @group set + * @shortname set scaling snap dist. + */ + setScalingSnapDistance( + inputs: Inputs.BabylonGizmo.SetBoundingBoxGizmoScalingSnapDistanceDto + ): BABYLON.BoundingBoxGizmo; + /** + * Set bounding box gizmo rotation snap distance. Drag distance in babylon units that the gizmo will snap rotation to when dragged. + * @param inputs bounding box gizmo + * @returns bounding box gizmo + * @group set + * @shortname set rotation snap dist. + */ + setRotationSnapDistance( + inputs: Inputs.BabylonGizmo.SetBoundingBoxGizmoRotationSnapDistanceDto + ): BABYLON.BoundingBoxGizmo; + /** + * Set bounding box gizmo scale box size + * @param inputs bounding box gizmo + * @returns bounding box gizmo + * @group set + * @shortname set scale box size + */ + setScaleBoxSize( + inputs: Inputs.BabylonGizmo.SetBoundingBoxGizmoScaleBoxSizeDto + ): BABYLON.BoundingBoxGizmo; + /** + * Set bounding box gizmo incremental snap. Incremental snap scaling (default is false). When true, with a snapDistance of 0.1, scaling will be 1.1,1.2,1.3 instead of, when false: 1.1,1.21,1.33,... + * @param inputs bounding box gizmo + * @returns bounding box gizmo + * @group set + * @shortname set incremental snap + */ + setIncrementalSnap( + inputs: Inputs.BabylonGizmo.SetBoundingBoxGizmoIncrementalSnapDto + ): BABYLON.BoundingBoxGizmo; + /** + * Set bounding box gizmo scale pivot. Relative bounding box pivot used when scaling the attached node. When null object with scale from the opposite corner. 0.5,0.5,0.5 for center and 0.5,0,0.5 for bottom (Default: null) + * @param inputs bounding box gizmo and scale pivot + * @returns bounding box gizmo + * @group set + * @shortname set scale pivot + */ + setScalePivot( + inputs: Inputs.BabylonGizmo.SetBoundingBoxGizmoScalePivotDto + ): BABYLON.BoundingBoxGizmo; + /** + * Set bounding box gizmo axis factor. Set custom sensitivity value for each axis + * @param inputs bounding box gizmo and axis factor + * @returns bounding box gizmo + * @group set + * @shortname set axis factor + */ + setAxisFactor( + inputs: Inputs.BabylonGizmo.SetBoundingBoxGizmoAxisFactorDto + ): BABYLON.BoundingBoxGizmo; + /** + * Set bounding box gizmo scale drag speed + * @param inputs bounding box gizmo and scale drag speed + * @returns bounding box gizmo + * @group set + * @shortname set scale drag speed + */ + setScaleDragSpeed( + inputs: Inputs.BabylonGizmo.SetBoundingBoxGizmoScaleDragSpeedDto + ): BABYLON.BoundingBoxGizmo; + /** + * Get rotation sphere size + * @param inputs bounding box gizmo + * @returns rotation sphere size + * @group get + * @shortname get rotation sphere size + */ + getRotationSphereSize( + inputs: Inputs.BabylonGizmo.BoundingBoxGizmoDto + ): number; + /** + * Get scale box size + * @param inputs bounding box gizmo + * @returns scale box size + * @group get + * @shortname get scale box size + */ + getScaleBoxSize(inputs: Inputs.BabylonGizmo.BoundingBoxGizmoDto): number; + /** + * Get fixed drag mesh screen size + * @param inputs bounding box gizmo + * @returns fixed drag mesh screen size + * @group get + * @shortname get fixed drag mesh screen size + */ + getFixedDragMeshScreenSize( + inputs: Inputs.BabylonGizmo.BoundingBoxGizmoDto + ): boolean; + /** + * Get fixed drag mesh bounds size + * @param inputs bounding box gizmo + * @returns fixed drag mesh bounds size + * @group get + * @shortname get fixed drag mesh bounds size + */ + getFixedDragMeshBoundsSize( + inputs: Inputs.BabylonGizmo.BoundingBoxGizmoDto + ): boolean; + /** + * Get fixed drag mesh screen size distance factor + * @param inputs bounding box gizmo + * @returns fixed drag mesh screen size distance factor + * @group get + * @shortname get fixed drag mesh screen size distance factor + */ + getFixedDragMeshScreenSizeDistanceFactor( + inputs: Inputs.BabylonGizmo.BoundingBoxGizmoDto + ): number; + /** + * Get scaling snap distance + * @param inputs bounding box gizmo + * @returns scaling snap distance + * @group get + * @shortname get scaling snap distance + */ + getScalingSnapDistance( + inputs: Inputs.BabylonGizmo.BoundingBoxGizmoDto + ): number; + /** + * Get rotation snap distance + * @param inputs bounding box gizmo + * @returns rotation snap distance + * @group get + * @shortname get rotation snap distance + */ + getRotationSnapDistance( + inputs: Inputs.BabylonGizmo.BoundingBoxGizmoDto + ): number; + /** + * Get incremental snap + * @param inputs bounding box gizmo + * @returns incremental snap + * @group get + * @shortname get incremental snap + */ + getIncrementalSnap( + inputs: Inputs.BabylonGizmo.BoundingBoxGizmoDto + ): boolean; + /** + * Get scale pivot + * @param inputs bounding box gizmo + * @returns scale pivot + * @group get + * @shortname get scale pivot + */ + getScalePivot( + inputs: Inputs.BabylonGizmo.BoundingBoxGizmoDto + ): Inputs.Base.Vector3; + /** + * Get axis factor + * @param inputs bounding box gizmo + * @returns axis factor + * @group get + * @shortname get axis factor + */ + getAxisFactor( + inputs: Inputs.BabylonGizmo.BoundingBoxGizmoDto + ): Inputs.Base.Vector3; + /** + * Get scale drag speed + * @param inputs bounding box gizmo + * @returns scale drag speed + * @group get + * @shortname get scale drag speed + */ + getScaleDragSpeed(inputs: Inputs.BabylonGizmo.BoundingBoxGizmoDto): number; + /** + * Creates the selector of an observable for a bounding box gizmo + * @param inputs observable name + * @returns bounding box gizmo observable selector + * @group create + * @shortname bounding box gizmo observable selector + */ + createBoundingBoxGizmoObservableSelector( + inputs: Inputs.BabylonGizmo.BoundingBoxGizmoObservableSelectorDto + ): Inputs.BabylonGizmo.boundingBoxGizmoObservableSelectorEnum; + } + declare class BabylonGizmoBase { + private readonly context; + constructor(context: Context); + /** + * Set gizmo scale ratio + * @param inputs gizmo + * @group set + * @shortname set scale ratio + */ + scaleRatio( + inputs: Inputs.BabylonGizmo.SetGizmoScaleRatioDto + ): BABYLON.IGizmo; + /** + * Gets scale ratio + * @param inputs gizmo + * @returns scale ratio + * @group get + * @shortname get scale ratio + */ + getScaleRatio(inputs: Inputs.BabylonGizmo.GizmoDto): number; + } + declare class BabylonGizmo { + private readonly context; + manager: BabylonGizmoManager; + base: BabylonGizmoBase; + positionGizmo: BabylonGizmoPositionGizmo; + rotationGizmo: BabylonGizmoRotationGizmo; + scaleGizmo: BabylonGizmoScaleGizmo; + boundingBoxGizmo: BabylonGizmoBoundingBoxGizmo; + axisDragGizmo: BabylonGizmoAxisDragGizmo; + axisScaleGizmo: BabylonGizmoAxisScaleGizmo; + planeDragGizmo: BabylonGizmoPlaneDragGizmo; + planeRotationGizmo: BabylonGizmoPlaneRotationGizmo; + constructor(context: Context); + } + declare class BabylonGizmoManager { + private readonly context; + constructor(context: Context); + /** + * Create gizmo manager + * @param inputs gizmo manager options + * @group create + * @shortname create gizmo manager + * @disposableOutput true + */ + createGizmoManager( + inputs: Inputs.BabylonGizmo.CreateGizmoDto + ): BABYLON.GizmoManager; + /** + * Get position gizmo + * @param inputs gizmo manager + * @returns position gizmo + * @group get + * @shortname get position gizmo + */ + getPositionGizmo( + inputs: Inputs.BabylonGizmo.GizmoManagerDto + ): BABYLON.IPositionGizmo; + /** + * Get rotation gizmo + * @param inputs gizmo manager + * @returns rotation gizmo + * @group get + * @shortname get rotation gizmo + */ + getRotationGizmo( + inputs: Inputs.BabylonGizmo.GizmoManagerDto + ): BABYLON.IRotationGizmo; + /** + * Get scale gizmo + * @param inputs gizmo manager + * @returns scale gizmo + * @group get + * @shortname get scale gizmo + */ + getScaleGizmo( + inputs: Inputs.BabylonGizmo.GizmoManagerDto + ): BABYLON.IScaleGizmo; + /** + * Get bounding box gizmo + * @param inputs gizmo manager + * @returns bounding box gizmo + * @group get + * @shortname get bounding box gizmo + */ + getBoundingBoxGizmo( + inputs: Inputs.BabylonGizmo.GizmoManagerDto + ): BABYLON.IBoundingBoxGizmo; + /** + * Attach gizmo manager to mesh + * @param inputs gizmo manager, mesh + * @returns gizmo manager + * @group update + * @shortname attach to mesh + */ + attachToMesh( + inputs: Inputs.BabylonGizmo.AttachToMeshDto + ): BABYLON.GizmoManager; + /** + * Detach gizmo manager from mesh + * @param inputs gizmo manager, mesh + * @returns gizmo manager + * @group update + * @shortname detach mesh + */ + detachMesh( + inputs: Inputs.BabylonGizmo.GizmoManagerDto + ): BABYLON.GizmoManager; + } + declare class BabylonGizmoPlaneDragGizmo { + private readonly context; + constructor(context: Context); + /** + * Sets if plane is enabled or not + * @param inputs plane drag gizmo + * @returns plane drag gizmo + * @group set + * @shortname set is plane enabled + */ + setIsEnabled( + inputs: Inputs.BabylonGizmo.SetIsEnabledPlaneDragGizmoDto + ): BABYLON.IPlaneDragGizmo; + /** + * Checks if plane is enabled + * @param inputs plane drag gizmo + * @returns is enabled + * @group get + * @shortname is plane enabled + */ + getIsEnabled(inputs: Inputs.BabylonGizmo.PlaneDragGizmoDto): boolean; + } + declare class BabylonGizmoPlaneRotationGizmo { + private readonly context; + constructor(context: Context); + /** + * Sets if plane is enabled or not + * @param inputs plane rotation gizmo + * @returns plane rotation gizmo + * @group set + * @shortname set is plane enabled + */ + setIsEnabled( + inputs: Inputs.BabylonGizmo.SetIsEnabledPlaneRotationGizmoDto + ): BABYLON.IPlaneRotationGizmo; + /** + * Checks if plane is enabled + * @param inputs plane rotation gizmo + * @returns is enabled + * @group get + * @shortname is plane enabled + */ + getIsEnabled(inputs: Inputs.BabylonGizmo.PlaneRotationGizmoDto): boolean; + } + declare class BabylonGizmoPositionGizmo { + private readonly context; + constructor(context: Context); + /** + * Set planar gizmo enabled + * @param inputs position gizmo + * @group set + * @shortname set planar gizmo enabled + */ + planarGizmoEnabled( + inputs: Inputs.BabylonGizmo.SetPlanarGizmoEnabled + ): BABYLON.IPositionGizmo; + /** + * Set position gizmo snap distance + * @param inputs position gizmo + * @group set + * @shortname set snap distance + */ + snapDistance( + inputs: Inputs.BabylonGizmo.SetPositionGizmoSnapDistanceDto + ): BABYLON.IPositionGizmo; + /** + * Get attached mesh + * @param inputs position gizmo + * @returns attached mesh + * @group get + * @shortname get attached mesh + */ + getAttachedMesh( + inputs: Inputs.BabylonGizmo.PositionGizmoDto + ): BABYLON.AbstractMesh; + /** + * Get attached node + * @param inputs position gizmo + * @returns attached node + * @group get + * @shortname get attached node + */ + getAttachedNode(inputs: Inputs.BabylonGizmo.PositionGizmoDto): BABYLON.Node; + /** + * Get x gizmo + * @param inputs position gizmo + * @returns x drag gizmo + * @group get + * @shortname get x gizmo + */ + getXGizmo( + inputs: Inputs.BabylonGizmo.PositionGizmoDto + ): BABYLON.IAxisDragGizmo; + /** + * Get y gizmo + * @param inputs position gizmo + * @returns y drag gizmo + * @group get + * @shortname get y gizmo + */ + getYGizmo( + inputs: Inputs.BabylonGizmo.PositionGizmoDto + ): BABYLON.IAxisDragGizmo; + /** + * Get z gizmo + * @param inputs position gizmo + * @returns z drag gizmo + * @group get + * @shortname get z gizmo + */ + getZGizmo( + inputs: Inputs.BabylonGizmo.PositionGizmoDto + ): BABYLON.IAxisDragGizmo; + /** + * Get x plane gizmo + * @param inputs position gizmo + * @group get + * @shortname get x plane gizmo + */ + getXPlaneGizmo( + inputs: Inputs.BabylonGizmo.PositionGizmoDto + ): BABYLON.IPlaneDragGizmo; + /** + * Get y plane gizmo + * @param inputs position gizmo + * @group get + * @shortname get y plane gizmo + */ + getYPlaneGizmo( + inputs: Inputs.BabylonGizmo.PositionGizmoDto + ): BABYLON.IPlaneDragGizmo; + /** + * Get z plane gizmo + * @param inputs position gizmo + * @group get + * @shortname get z plane gizmo + */ + getZPlaneGizmo( + inputs: Inputs.BabylonGizmo.PositionGizmoDto + ): BABYLON.IPlaneDragGizmo; + /** + * Get if planar gizmo enabled + * @param inputs position gizmo + * @returns is enabled + * @group get + * @shortname get planar gizmo enabled + */ + getPlanarGizmoEnabled( + inputs: Inputs.BabylonGizmo.PositionGizmoDto + ): boolean; + /** + * Get snap distance + * @param inputs position gizmo + * @returns snap distance + * @group get + * @shortname get snap distance + */ + getSnapDistance(inputs: Inputs.BabylonGizmo.PositionGizmoDto): number; + /** + * Get if is dragging + * @param inputs position gizmo + * @returns is dragging + * @group get + * @shortname get is dragging + */ + getIsDragging(inputs: Inputs.BabylonGizmo.PositionGizmoDto): boolean; + /** + * Creates the selector of an observable for a position gizmo + * @param inputs observable name + * @returns position gizmo observable selector + * @group create + * @shortname position gizmo observable selector + */ + createPositionGizmoObservableSelector( + inputs: Inputs.BabylonGizmo.PositionGizmoObservableSelectorDto + ): Inputs.BabylonGizmo.positionGizmoObservableSelectorEnum; + } + declare class BabylonGizmoRotationGizmo { + private readonly context; + constructor(context: Context); + /** + * Set rotation gizmo snap distance + * @param inputs rotation gizmo + * @returns rotation gizmo + * @group set + * @shortname set snap distance + */ + snapDistance( + inputs: Inputs.BabylonGizmo.SetRotationGizmoSnapDistanceDto + ): BABYLON.IRotationGizmo; + /** + * Set rotation gizmo sensitivity + * @param inputs rotation gizmo + * @returns rotation gizmo + * @group set + * @shortname set sensitivity + */ + sensitivity( + inputs: Inputs.BabylonGizmo.SetRotationGizmoSensitivityDto + ): BABYLON.IRotationGizmo; + /** + * Get attached mesh + * @param inputs rotation gizmo + * @returns attached mesh + * @group get + * @shortname get attached mesh + */ + getAttachedMesh( + inputs: Inputs.BabylonGizmo.RotationGizmoDto + ): BABYLON.Nullable; + /** + * Get attached node + * @param inputs rotation gizmo + * @returns attached node + * @group get + * @shortname get attached node + */ + getAttachedNode(inputs: Inputs.BabylonGizmo.RotationGizmoDto): BABYLON.Node; + /** + * Get x gizmo + * @param inputs rotation gizmo + * @returns x drag gizmo + * @group get + * @shortname get x gizmo + */ + getXGizmo( + inputs: Inputs.BabylonGizmo.RotationGizmoDto + ): BABYLON.IPlaneRotationGizmo; + /** + * Get y gizmo + * @param inputs rotation gizmo + * @returns y drag gizmo + * @group get + * @shortname get y gizmo + */ + getYGizmo( + inputs: Inputs.BabylonGizmo.RotationGizmoDto + ): BABYLON.IPlaneRotationGizmo; + /** + * Get z gizmo + * @param inputs rotation gizmo + * @returns z drag gizmo + * @group get + * @shortname get z gizmo + */ + getZGizmo( + inputs: Inputs.BabylonGizmo.RotationGizmoDto + ): BABYLON.IPlaneRotationGizmo; + /** + * Get snap distance + * @param inputs rotation gizmo + * @returns snap distance + * @group get + * @shortname get snap distance + */ + getSnapDistance(inputs: Inputs.BabylonGizmo.RotationGizmoDto): number; + /** + * Get sensitivity + * @param inputs rotation gizmo + * @returns sensitivity + * @group get + * @shortname get sensitivity + */ + getSensitivity(inputs: Inputs.BabylonGizmo.RotationGizmoDto): number; + /** + * Creates the selector of an observable for a rotation gizmo + * @param inputs observable name + * @returns rotation gizmo observable selector + * @group create + * @shortname rotation gizmo observable selector + */ + createRotationGizmoObservableSelector( + inputs: Inputs.BabylonGizmo.RotationGizmoObservableSelectorDto + ): Inputs.BabylonGizmo.rotationGizmoObservableSelectorEnum; + } + declare class BabylonGizmoScaleGizmo { + private readonly context; + constructor(context: Context); + /** + * Get x gizmo + * @param inputs scale gizmo + * @returns x scale gizmo + * @group get + * @shortname get x gizmo + */ + getXGizmo( + inputs: Inputs.BabylonGizmo.ScaleGizmoDto + ): BABYLON.IAxisScaleGizmo; + /** + * Get y gizmo + * @param inputs position gizmo + * @returns y scale gizmo + * @group get + * @shortname get y gizmo + */ + getYGizmo( + inputs: Inputs.BabylonGizmo.ScaleGizmoDto + ): BABYLON.IAxisScaleGizmo; + /** + * Get z gizmo + * @param inputs scale gizmo + * @returns z scale gizmo + * @group get + * @shortname get z gizmo + */ + getZGizmo( + inputs: Inputs.BabylonGizmo.ScaleGizmoDto + ): BABYLON.IAxisScaleGizmo; + /** + * Set scale gizmo snap distance + * @param inputs scale gizmo + * @returns scale gizmo + * @group set + * @shortname set snap distance + */ + snapDistance( + inputs: Inputs.BabylonGizmo.SetScaleGizmoSnapDistanceDto + ): BABYLON.IScaleGizmo; + /** + * Set scale gizmo incremental snap + * @param inputs scale gizmo + * @returns scale gizmo + * @group set + * @shortname set incremental snap + */ + setIncrementalSnap( + inputs: Inputs.BabylonGizmo.SetScaleGizmoIncrementalSnapDto + ): BABYLON.IScaleGizmo; + /** + * Set scale gizmo sensitivity + * @param inputs scale gizmo + * @returns scale gizmo + * @group set + * @shortname set sensitivity + */ + sensitivity( + inputs: Inputs.BabylonGizmo.SetScaleGizmoSensitivityDto + ): BABYLON.IScaleGizmo; + /** + * Get incremental snap + * @param inputs scale gizmo + * @returns incremental snap + * @group get + * @shortname get incremental snap + */ + getIncrementalSnap(inputs: Inputs.BabylonGizmo.ScaleGizmoDto): boolean; + /** + * Get snap distance + * @param inputs scale gizmo + * @returns snap distance + * @group get + * @shortname get snap distance + */ + getSnapDistance(inputs: Inputs.BabylonGizmo.ScaleGizmoDto): number; + /** + * Get sensitivity + * @param inputs scale gizmo + * @returns sensitivity + * @group get + * @shortname get sensitivity + */ + getSensitivity(inputs: Inputs.BabylonGizmo.ScaleGizmoDto): number; + /** + * Creates the selector of an observable for a scale gizmo + * @param inputs observable name + * @returns scale gizmo observable selector + * @group create + * @shortname scale gizmo observable selector + */ + createScaleGizmoObservableSelector( + inputs: Inputs.BabylonGizmo.ScaleGizmoObservableSelectorDto + ): Inputs.BabylonGizmo.scaleGizmoObservableSelectorEnum; + } + declare class BabylonGuiAdvancedDynamicTexture { + private readonly context; + constructor(context: Context); + /** + * Creates full screen UI + * @param inputs with name of advanced texture, foreground, sampling and adaptive scaling + * @returns advanced dynamic texture + * @group spaces + * @shortname create full screen ui + * @disposableOutput true + */ + createFullScreenUI( + inputs: Inputs.BabylonGui.CreateFullScreenUIDto + ): BABYLON.GUI.AdvancedDynamicTexture; + /** + * Creates advanced dynamic texture for a mesh + * @param inputs with mesh, width, height, support pointer move, only alpha testing, invert y and sampling + * @returns advanced dynamic texture + * @group spaces + * @shortname create for mesh + * @disposableOutput true + */ + createForMesh( + inputs: Inputs.BabylonGui.CreateForMeshDto + ): BABYLON.GUI.AdvancedDynamicTexture; + } + declare class BabylonGuiButton { + private readonly context; + constructor(context: Context); + /** + * Creates simple button + * @param inputs button properties + * @returns button + * @group create + * @shortname create simple button + * @disposableOutput true + */ + createSimpleButton( + inputs: Inputs.BabylonGui.CreateButtonDto + ): BABYLON.GUI.Button; + /** + * Set button text + * @param inputs button and text + * @returns button with changed text + * @group set + * @shortname set button text + */ + setButtonText( + inputs: Inputs.BabylonGui.SetButtonTextDto + ): BABYLON.GUI.Button; + /** + * Get button text + * @param inputs button + * @returns button text + * @group get + * @shortname get button text + */ + getButtonText(inputs: Inputs.BabylonGui.ButtonDto): string; + } + declare class BabylonGuiCheckbox { + private readonly context; + constructor(context: Context); + /** + * Creates checkbox + * @param inputs checkbox properties + * @returns checkbox + * @group create + * @shortname create checkbox + * @disposableOutput true + */ + createCheckbox( + inputs: Inputs.BabylonGui.CreateCheckboxDto + ): BABYLON.GUI.Checkbox; + /** + * Sets the checkbox background + * @param inputs checkbox and background + * @group set + * @shortname set checkbox background + */ + setBackground( + inputs: Inputs.BabylonGui.SetCheckboxBackgroundDto + ): BABYLON.GUI.Checkbox; + /** + * Sets the checkbox check size ratio + * @param inputs checkbox and check size ratio + * @group set + * @shortname set checkbox check size ratio + */ + setCheckSizeRatio( + inputs: Inputs.BabylonGui.SetCheckboxCheckSizeRatioDto + ): BABYLON.GUI.Checkbox; + /** + * Sets the checkbox is checked + * @param inputs checkbox and is checked + * @group set + * @shortname set checkbox is checked + */ + setIsChecked( + inputs: Inputs.BabylonGui.SetCheckboxIsCheckedDto + ): BABYLON.GUI.Checkbox; + /** + * Gets the check size ratio + * @param inputs checkbox + * @group get + * @shortname get check size ratio + */ + getCheckSizeRatio(inputs: Inputs.BabylonGui.CheckboxDto): number; + /** + * Gets the is checked + * @param inputs checkbox + * @group get + * @shortname get is checked + */ + getIsChecked(inputs: Inputs.BabylonGui.CheckboxDto): boolean; + /** + * Gets the background + * @param inputs checkbox + * @group get + * @shortname get checkbox background + */ + getBackground(inputs: Inputs.BabylonGui.CheckboxDto): string; + /** + * Creates the selector of an observable for the checkbox + * @param inputs observable name + * @group create + * @shortname checkbox observable selector + */ + createCheckboxObservableSelector( + inputs: Inputs.BabylonGui.CheckboxObservableSelectorDto + ): Inputs.BabylonGui.checkboxObservableSelectorEnum; + } + declare class BabylonGuiColorPicker { + private readonly context; + constructor(context: Context); + /** + * Creates color picker + * @param inputs color picker properties + * @returns color picker + * @group create + * @shortname color picker + * @disposableOutput true + */ + createColorPicker( + inputs: Inputs.BabylonGui.CreateColorPickerDto + ): BABYLON.GUI.ColorPicker; + /** + * Sets color picker value color + * @param inputs color picker and color + * @returns color picker + * @group set + * @shortname set colo picker value + */ + setColorPickerValue( + inputs: Inputs.BabylonGui.SetColorPickerValueDto + ): BABYLON.GUI.ColorPicker; + /** + * Sets color picker size (width and height) + * @param inputs color picker and size + * @returns color picker + * @group set + * @shortname set color picker size + */ + setColorPickerSize( + inputs: Inputs.BabylonGui.SetColorPickerSizeDto + ): BABYLON.GUI.ColorPicker; + /** + * Gets color picker value color + * @param inputs color picker + * @returns color + * @group get + * @shortname get color picker value + */ + getColorPickerValue(inputs: Inputs.BabylonGui.ColorPickerDto): string; + /** + * Gets color picker size + * @param inputs color picker + * @returns size + * @group get + * @shortname get color picker size + */ + getColorPickerSize( + inputs: Inputs.BabylonGui.ColorPickerDto + ): string | number; + /** + * Creates the selector of an observable for color picker + * @param inputs observable name + * @returns color picker observable selector + * @group create + * @shortname color picker observable selector + */ + createColorPickerObservableSelector( + inputs: Inputs.BabylonGui.ColorPickerObservableSelectorDto + ): Inputs.BabylonGui.colorPickerObservableSelectorEnum; + } + declare class BabylonGuiContainer { + private readonly context; + constructor(context: Context); + /** + * Adds controls to container and keeps the order + * @param inputs with container and controls + * @returns container + * @group controls + * @shortname add controls to container + */ + addControls( + inputs: Inputs.BabylonGui.AddControlsToContainerDto + ): BABYLON.GUI.Container; + /** + * Sets the container background + * @param inputs container and background + * @group set + * @shortname set container background + */ + setBackground( + inputs: Inputs.BabylonGui.SetContainerBackgroundDto + ): BABYLON.GUI.Container; + /** + * Sets the container is readonly + * @param inputs container and is readonly + * @group set + * @shortname set container is readonly + */ + setIsReadonly( + inputs: Inputs.BabylonGui.SetContainerIsReadonlyDto + ): BABYLON.GUI.Container; + /** + * Gets the container background + * @param inputs container + * @group get + * @shortname get container background + */ + getBackground(inputs: Inputs.BabylonGui.ContainerDto): string; + /** + * Gets the container is readonly + * @param inputs container + * @group get + * @shortname get container is readonly + */ + getIsReadonly(inputs: Inputs.BabylonGui.ContainerDto): boolean; + } + declare class BabylonGuiControl { + private readonly context; + constructor(context: Context); + /** + * Change the padding for the control + * @param inputs the control and the padding values + * @returns control that has changed padding + * @group positioning + * @shortname change padding + */ + changeControlPadding( + inputs: Inputs.BabylonGui.PaddingLeftRightTopBottomDto + ): BABYLON.GUI.Control; + /** + * Change the alignment for the control + * @param inputs the control and the alignment values + * @returns control that has changed alignment + * @group positioning + * @shortname change alignment + */ + changeControlAlignment( + inputs: Inputs.BabylonGui.AlignmentDto + ): BABYLON.GUI.Control; + /** + * Clone control + * @param inputs control to clone + * @returns cloned control + * @group create + * @shortname clone control + * @disposableOutput true + */ + cloneControl( + inputs: Inputs.BabylonGui.CloneControlDto + ): BABYLON.GUI.Control; + /** + * Creates the selector of an observable for a control + * @param inputs observable name + * @group create + * @shortname control observable selector + */ + createControlObservableSelector( + inputs: Inputs.BabylonGui.ControlObservableSelectorDto + ): Inputs.BabylonGui.controlObservableSelectorEnum; + /** + * Get control by name + * @param inputs container and control name + * @returns control with the name + * @group get + * @shortname get control by name + */ + getControlByName( + inputs: Inputs.BabylonGui.GetControlByNameDto + ): BABYLON.GUI.Control; + /** + * Set if control is visible + * @param inputs control and is visible + * @returns control with changed visibility + * @group set + * @shortname set control is visible + */ + setIsVisible( + inputs: Inputs.BabylonGui.SetControlIsVisibleDto + ): BABYLON.GUI.Control; + /** + * Set if control is readonly + * @param inputs control and is readonly + * @returns control with changed readonly + * @group set + * @shortname set control is readonly + */ + setIsReadonly( + inputs: Inputs.BabylonGui.SetControlIsReadonlyDto + ): BABYLON.GUI.Control; + /** + * Set if control is enabled + * @param inputs control and is enabled + * @returns control with changed enabled + * @group set + * @shortname set control is enabled + */ + setIsEnabled( + inputs: Inputs.BabylonGui.SetControlIsEnabledDto + ): BABYLON.GUI.Control; + /** + * Sets the control height + * @param inputs control and height + * @group set + * @shortname set control height + */ + setHeight( + inputs: Inputs.BabylonGui.SetControlHeightDto + ): BABYLON.GUI.Control; + /** + * Sets the control width + * @param inputs control and width + * @group set + * @shortname set control width + */ + setWidth(inputs: Inputs.BabylonGui.SetControlWidthDto): BABYLON.GUI.Control; + /** + * Sets the control color + * @param inputs control and color + * @group set + * @shortname set control color + */ + setColor(inputs: Inputs.BabylonGui.SetControlColorDto): BABYLON.GUI.Control; + /** + * Set font size + * @param inputs control and font size + * @returns control with changed font size + * @group set + * @shortname set control font size + */ + setFontSize( + inputs: Inputs.BabylonGui.SetControlFontSizeDto + ): BABYLON.GUI.Control; + /** + * Gets the height + * @param inputs control + * @group get + * @shortname get control height + */ + getHeight(inputs: Inputs.BabylonGui.ControlDto): string | number; + /** + * Gets the width + * @param inputs control + * @group get + * @shortname get control width + */ + getWidth(inputs: Inputs.BabylonGui.ControlDto): string | number; + /** + * Gets the color + * @param inputs control + * @group get + * @shortname get control color + */ + getColor(inputs: Inputs.BabylonGui.ControlDto): string; + /** + * Get control font size + * @param inputs control + * @returns control font size. Can be in the form of a string "24px" or a number + * @group get + * @shortname get control font size + */ + getFontSize(inputs: Inputs.BabylonGui.ControlDto): string | number; + /** + * Get control is visible + * @param inputs control + * @returns control visibility + * @group get + * @shortname get control is visible + */ + getIsVisible(inputs: Inputs.BabylonGui.ControlDto): boolean; + /** + * Get control is readonly + * @param inputs control + * @returns control readonly + * @group get + * @shortname get control is readonly + */ + getIsReadonly(inputs: Inputs.BabylonGui.ControlDto): boolean; + /** + * Get control is enabled + * @param inputs control + * @returns control enabled + * @group get + * @shortname get control is enabled + */ + getIsEnabled(inputs: Inputs.BabylonGui.ControlDto): boolean; + } + declare class BabylonGui { + private readonly context; + advancedDynamicTexture: BabylonGuiAdvancedDynamicTexture; + control: BabylonGuiControl; + container: BabylonGuiContainer; + stackPanel: BabylonGuiStackPanel; + button: BabylonGuiButton; + slider: BabylonGuiSlider; + textBlock: BabylonGuiTextBlock; + radioButton: BabylonGuiRadioButton; + checkbox: BabylonGuiCheckbox; + inputText: BabylonGuiInputText; + colorPicker: BabylonGuiColorPicker; + image: BabylonGuiImage; + constructor(context: Context); + } + declare class BabylonGuiImage { + private readonly context; + constructor(context: Context); + /** + * Creates image + * @param inputs image properties + * @returns image + * @group create + * @shortname create image + * @disposableOutput true + */ + createImage(inputs: Inputs.BabylonGui.CreateImageDto): BABYLON.GUI.Image; + /** + * Sets image source url + * @param inputs image and url + * @returns image + * @group set + * @shortname set image source url + */ + setSourceUrl(inputs: Inputs.BabylonGui.SetImageUrlDto): BABYLON.GUI.Image; + /** + * Gets image source url + * @param inputs image + * @returns image source url + * @group get + * @shortname get image source url + */ + getSourceUrl(inputs: Inputs.BabylonGui.ImageDto): string; + } + declare class BabylonGuiInputText { + private readonly context; + constructor(context: Context); + /** + * Creates input text + * @param inputs input text properties + * @returns input text + * @group create + * @shortname create input text + * @disposableOutput true + */ + createInputText( + inputs: Inputs.BabylonGui.CreateInputTextDto + ): BABYLON.GUI.InputText; + /** + * Sets the input text background + * @param inputs input text and background + * @returns input text + * @group set + * @shortname set input text background + */ + setBackground( + inputs: Inputs.BabylonGui.SetInputTextBackgroundDto + ): BABYLON.GUI.InputText; + /** + * Sets the input text text + * @param inputs input text and text + * @returns input text + * @group set + * @shortname set input text text + */ + setText( + inputs: Inputs.BabylonGui.SetInputTextTextDto + ): BABYLON.GUI.InputText; + /** + * Sets the input text placeholder + * @param inputs input text and placeholder + * @returns input text + * @group set + * @shortname set input text placeholder + */ + setPlaceholder( + inputs: Inputs.BabylonGui.SetInputTextPlaceholderDto + ): BABYLON.GUI.InputText; + /** + * Gets the input text background + * @param inputs input text + * @returns input text background + * @group get + * @shortname get input text background + */ + getBackground(inputs: Inputs.BabylonGui.InputTextDto): string; + /** + * Gets the input text text + * @param inputs input text + * @returns input text text + * @group get + * @shortname get input text text + */ + getText(inputs: Inputs.BabylonGui.InputTextDto): string; + /** + * Gets the input text placeholder + * @param inputs input text + * @returns input text placeholder + * @group get + * @shortname get input text placeholder + */ + getPlaceholder(inputs: Inputs.BabylonGui.InputTextDto): string; + /** + * Creates the selector of an observable for the input text + * @param inputs observable name + * @group create + * @shortname input text observable selector + */ + createInputTextObservableSelector( + inputs: Inputs.BabylonGui.InputTextObservableSelectorDto + ): Inputs.BabylonGui.inputTextObservableSelectorEnum; + } + declare class BabylonGuiRadioButton { + private readonly context; + constructor(context: Context); + /** + * Creates radio button + * @param inputs radio button properties + * @returns radio button + * @group create + * @shortname create radio button + * @disposableOutput true + */ + createRadioButton( + inputs: Inputs.BabylonGui.CreateRadioButtonDto + ): BABYLON.GUI.RadioButton; + /** + * Sets the radio button check size ratio + * @param inputs radio button and check size ratio + * @group set + * @shortname set radio button check size ratio + */ + setCheckSizeRatio( + inputs: Inputs.BabylonGui.SetRadioButtonCheckSizeRatioDto + ): BABYLON.GUI.RadioButton; + /** + * Sets the radio button group + * @param inputs radio button and group + * @group set + * @shortname set radio button group + */ + setGroup( + inputs: Inputs.BabylonGui.SetRadioButtonGroupDto + ): BABYLON.GUI.RadioButton; + /** + * Sets the radio button background + * @param inputs radio button and background + * @group set + * @shortname set radio button background + */ + setBackground( + inputs: Inputs.BabylonGui.SetRadioButtonBackgroundDto + ): BABYLON.GUI.RadioButton; + /** + * Gets the radio button check size ratio + * @param inputs radio button + * @group get + * @shortname get radio button check size ratio + */ + getCheckSizeRatio(inputs: Inputs.BabylonGui.RadioButtonDto): number; + /** + * Gets the radio button group + * @param inputs radio button + * @group get + * @shortname get radio button group + */ + getGroup(inputs: Inputs.BabylonGui.RadioButtonDto): string; + /** + * Gets the radio button background + * @param inputs radio button + * @group get + * @shortname get radio button background + */ + getBackground(inputs: Inputs.BabylonGui.RadioButtonDto): string; + /** + * Creates the selector of an observable for the radio button + * @param inputs observable name + * @group create + * @shortname radio button observable selector + */ + createRadioButtonObservableSelector( + inputs: Inputs.BabylonGui.RadioButtonObservableSelectorDto + ): Inputs.BabylonGui.radioButtonObservableSelectorEnum; + } + declare class BabylonGuiSlider { + private readonly context; + constructor(context: Context); + /** + * Creates slider + * @param inputs slider properties + * @returns slider + * @group create + * @shortname create slider + * @disposableOutput true + */ + createSlider(inputs: Inputs.BabylonGui.CreateSliderDto): BABYLON.GUI.Slider; + /** + * Changes slider thumb properties + * @param inputs slider properties* + * @returns slider + * @group set + * @shortname set slider thumb + */ + changeSliderThumb( + inputs: Inputs.BabylonGui.SliderThumbDto + ): BABYLON.GUI.Slider; + /** + * Changes slider border color + * @param inputs slider border color + * @returns slider + * @group set + * @shortname set slider border color + */ + setBorderColor( + inputs: Inputs.BabylonGui.SliderBorderColorDto + ): BABYLON.GUI.Slider; + /** + * Changes slider background color + * @param inputs slider background color + * @returns slider + * @group set + * @shortname set slider background color + */ + setBackgroundColor( + inputs: Inputs.BabylonGui.SliderBackgroundColorDto + ): BABYLON.GUI.Slider; + /** + * Changes slider maximum value + * @param inputs slider maximum value + * @returns slider + * @group set + * @shortname set slider maximum + */ + setMaximum(inputs: Inputs.BabylonGui.SetSliderValueDto): BABYLON.GUI.Slider; + /** + * Changes slider minimum value + * @param inputs slider minimum value + * @returns slider + * @group set + * @shortname set slider minimum + */ + setMinimum(inputs: Inputs.BabylonGui.SetSliderValueDto): BABYLON.GUI.Slider; + /** + * Changes slider step value + * @param inputs slider step value + * @returns slider + * @group set + * @shortname set slider step + */ + setStep(inputs: Inputs.BabylonGui.SetSliderValueDto): BABYLON.GUI.Slider; + /** + * Changes slider value + * @param inputs slider value + * @returns slider + * @group set + * @shortname set slider value + */ + setValue(inputs: Inputs.BabylonGui.SetSliderValueDto): BABYLON.GUI.Slider; + /** + * Creates the selector of an observable for a slider + * @param inputs observable name + * @returns slider observable selector + * @group create + * @shortname slider observable selector + */ + createSliderObservableSelector( + inputs: Inputs.BabylonGui.SliderObservableSelectorDto + ): Inputs.BabylonGui.sliderObservableSelectorEnum; + /** + * Gets the slider border color + * @param slider slider + * @returns slider border color + * @group get + * @shortname get slider border color + */ + getBorderColor(inputs: Inputs.BabylonGui.SliderDto): string; + /** + * Gets the slider background color + * @param slider slider + * @returns slider background color + * @group get + * @shortname get slider background color + */ + getBackgroundColor(inputs: Inputs.BabylonGui.SliderDto): string; + /** + * Gets the slider maximum value + * @param slider slider + * @returns slider maximum value + * @group get + * @shortname get slider maximum + */ + getMaximum(inputs: Inputs.BabylonGui.SliderDto): number; + /** + * Gets the slider minimum value + * @param slider slider + * @returns slider minimum value + * @group get + * @shortname get slider minimum + */ + getMinimum(inputs: Inputs.BabylonGui.SliderDto): number; + /** + * Gets the slider step value + * @param slider slider + * @returns slider step value + * @group get + * @shortname get slider step + */ + getStep(inputs: Inputs.BabylonGui.SliderDto): number; + /** + * Gets the slider value + * @param slider slider + * @returns slider value + * @group get + * @shortname get slider value + */ + getValue(inputs: Inputs.BabylonGui.SliderDto): number; + /** + * Gets the slider thumb color + * @param slider slider + * @returns slider thumb color + * @group get + * @shortname get slider thumb color + */ + getThumbColor(inputs: Inputs.BabylonGui.SliderDto): string; + /** + * Gets the slider thumb width + * @param slider slider + * @returns slider thumb width + * @group get + * @shortname get slider thumb width + */ + getThumbWidth(inputs: Inputs.BabylonGui.SliderDto): string | number; + /** + * Gets the slider is vertical + * @param slider slider + * @returns slider is vertical + * @group get + * @shortname get slider is vertical + */ + getIsVertical(inputs: Inputs.BabylonGui.SliderDto): boolean; + /** + * Gets the slider display thumb + * @param slider slider + * @returns slider display thumb + * @group get + * @shortname get slider display thumb + */ + getDisplayThumb(inputs: Inputs.BabylonGui.SliderDto): boolean; + /** + * Gets the slider is thumb circle + * @param slider slider + * @returns slider is thumb circle + * @group get + * @shortname get slider is thumb circle + */ + getIsThumbCircle(inputs: Inputs.BabylonGui.SliderDto): boolean; + /** + * Gets the slider is thumb clamped + * @param slider slider + * @returns slider is thumb clamped + * @group get + * @shortname get slider is thumb clamped + */ + getIsThumbClamped(inputs: Inputs.BabylonGui.SliderDto): boolean; + } + declare class BabylonGuiStackPanel { + private readonly context; + constructor(context: Context); + /** + * Creates stack panel + * @param inputs stack panel props + * @group create + * @shortname create stack panel + * @disposableOutput true + */ + createStackPanel( + inputs: Inputs.BabylonGui.CreateStackPanelDto + ): BABYLON.GUI.StackPanel; + /** + * Set stack panel is vertical + * @param inputs with stack panel and is vertical + * @returns stack panel with changed is vertical + * @group set + * @shortname set stack panel is vertical + */ + setIsVertical( + inputs: Inputs.BabylonGui.SetStackPanelIsVerticalDto + ): BABYLON.GUI.StackPanel; + /** + * Set stack panel spacing + * @param inputs with stack panel and spacing + * @returns stack panel with changed spacing + * @group set + * @shortname set stack panel spacing + */ + setSpacing( + inputs: Inputs.BabylonGui.SetStackPanelSpacingDto + ): BABYLON.GUI.StackPanel; + /** + * Set stack panel width + * @param inputs with stack panel and width + * @returns stack panel with changed width + * @group set + * @shortname set stack panel width + */ + setWidth( + inputs: Inputs.BabylonGui.SetStackPanelWidthDto + ): BABYLON.GUI.StackPanel; + /** + * Set stack panel height + * @param inputs with stack panel and height + * @returns stack panel with changed height + * @group set + * @shortname set stack panel height + */ + setHeight( + inputs: Inputs.BabylonGui.SetStackPanelHeightDto + ): BABYLON.GUI.StackPanel; + /** + * Get stack panel is vertical + * @param inputs with stack panel + * @returns stack panel is vertical + * @group get + * @shortname get stack panel is vertical + */ + getIsVertical(inputs: Inputs.BabylonGui.StackPanelDto): boolean; + /** + * Get stack panel spacing + * @param inputs with stack panel + * @returns stack panel spacing + * @group get + * @shortname get stack panel spacing + */ + getSpacing(inputs: Inputs.BabylonGui.StackPanelDto): number; + /** + * Get stack panel width + * @param inputs with stack panel + * @returns stack panel width + * @group get + * @shortname get stack panel width + */ + getWidth(inputs: Inputs.BabylonGui.StackPanelDto): string | number; + /** + * Get stack panel height + * @param inputs with stack panel + * @returns stack panel height + * @group get + * @shortname get stack panel height + */ + getHeight(inputs: Inputs.BabylonGui.StackPanelDto): string | number; + } + declare class BabylonGuiTextBlock { + private readonly context; + constructor(context: Context); + /** + * Creates text block + * @param inputs text block properties + * @group create + * @shortname create text block + * @disposableOutput true + */ + createTextBlock( + inputs: Inputs.BabylonGui.CreateTextBlockDto + ): BABYLON.GUI.TextBlock; + /** + * Change the alignment for the text + * @param inputs the text block and the alignment values + * @returns control that has changed text alignment + * @group positioning + * @shortname align text block text + */ + alignText( + inputs: Inputs.BabylonGui.AlignmentDto + ): BABYLON.GUI.TextBlock; + /** + * Change the text outline for the text + * @param inputs the text block and the outline values + * @returns control that has changed text outline + * @group set + * @shortname text outline + */ + setTextOutline( + inputs: Inputs.BabylonGui.SetTextBlockTextOutlineDto + ): BABYLON.GUI.TextBlock; + /** + * Sets the new text to the text block + * @param inputs text block and text + * @returns control that has changed text + * @group set + * @shortname set text block text + */ + setText( + inputs: Inputs.BabylonGui.SetTextBlockTextDto + ): BABYLON.GUI.TextBlock; + /** + * Enable or disable resize to fit + * @param inputs text block and boolean value + * @returns control that has enabled or disabled resize to fit + * @group set + * @shortname set resize to fit + */ + setRsizeToFit( + inputs: Inputs.BabylonGui.SetTextBlockResizeToFitDto + ): BABYLON.GUI.TextBlock; + /** + * Sets the new text wrapping to the text block + * @param inputs text block and text wrapping + * @returns control that has changed text wrapping + * @group set + * @shortname set text wrapping + */ + setTextWrapping( + inputs: Inputs.BabylonGui.SetTextBlockTextWrappingDto + ): BABYLON.GUI.TextBlock; + /** + * Sets the line spacing of the text + * @param inputs text block and line spacing + * @returns control that has changed line spacing + * @group set + * @shortname set line spacing + */ + setLineSpacing( + inputs: Inputs.BabylonGui.SetTextBlockLineSpacingDto + ): BABYLON.GUI.TextBlock; + /** + * Gets the text of the text block + * @param inputs text block + * @returns text of the text block + * @group get + * @shortname get text block text + */ + getText(inputs: Inputs.BabylonGui.TextBlockDto): string; + /** + * Gets the text wrapping of the text block + * @param inputs text block + * @returns text wrapping of the text block + * @group get + * @shortname get text wrapping + */ + getTextWrapping( + inputs: Inputs.BabylonGui.TextBlockDto + ): boolean | BABYLON.GUI.TextWrapping; + /** + * Gets the line spacing of the text block + * @param inputs text block + * @returns line spacing of the text block + * @group get + * @shortname get line spacing + */ + getLineSpacing(inputs: Inputs.BabylonGui.TextBlockDto): string | number; + /** + * Gets the outline width of the text block + * @param inputs text block + * @returns outline width of the text block + * @group get + * @shortname get outline width + */ + getOutlineWidth(inputs: Inputs.BabylonGui.TextBlockDto): number; + /** + * Gets the resize to fit of the text block + * @param inputs text block + * @returns resize to fit of the text block + * @group get + * @shortname get resize to fit + */ + getResizeToFit(inputs: Inputs.BabylonGui.TextBlockDto): boolean; + /** + * Gets the text horizontal alignment of the text block + * @param inputs text block + * @returns text horizontal alignment of the text block + * @group get + * @shortname get text horizontal alignment + */ + getTextHorizontalAlignment(inputs: Inputs.BabylonGui.TextBlockDto): number; + /** + * Gets the text vertical alignment of the text block + * @param inputs text block + * @returns text vertical alignment of the text block + * @group get + * @shortname get text vertical alignment + */ + getTextVerticalAlignment(inputs: Inputs.BabylonGui.TextBlockDto): number; + /** + * Creates the selector of an observable for a text block + * @param inputs observable name + * @group create + * @shortname text block observable selector + */ + createTextBlockObservableSelector( + inputs: Inputs.BabylonGui.TextBlockObservableSelectorDto + ): Inputs.BabylonGui.textBlockObservableSelectorEnum; + } + declare class BabylonIO { + private readonly context; + private supportedFileFormats; + private objectUrl; + constructor(context: Context); + /** + * Imports mesh from the asset that you have uploaded for the project. + * You must upload your assets to your project via project management page. + * @returns scene loaded mesh + * @group load + * @shortname asset + */ + loadAssetIntoScene( + inputs: Inputs.Asset.AssetFileDto + ): Promise; + /** + * Imports mesh from the asset that you have uploaded for the project. + * You must upload your assets to your project via project management page. + * @returns scene loaded mesh + * @group load + * @shortname asset + */ + loadAssetIntoSceneNoReturn( + inputs: Inputs.Asset.AssetFileDto + ): Promise; + /** + * Imports mesh from the asset url that you have uploaded to an accessible web storage. + * Keep in mind that files need to be publically accessible for this to work, be sure that CORS access is enabled for the assets. + * @returns scene loaded mesh + * @group load + * @shortname asset from url + */ + loadAssetIntoSceneFromRootUrl( + inputs: Inputs.Asset.AssetFileByUrlDto + ): Promise; + /** + * Imports mesh from the asset url that you have uploaded to an accessible web storage. + * Keep in mind that files need to be publically accessible for this to work, be sure that CORS access is enabled for the assets. + * @returns scene loaded mesh + * @group load + * @shortname asset from url + */ + loadAssetIntoSceneFromRootUrlNoReturn( + inputs: Inputs.Asset.AssetFileByUrlDto + ): Promise; + /** + * Exports the whole scene to .babylon scene format. You can then edit it further in babylonjs editors. + * @param inputs filename + * @group export + * @shortname babylon scene + */ + exportBabylon(inputs: Inputs.BabylonIO.ExportSceneDto): void; + /** + * Exports the whole scene to .glb format. This file format has become industry standard for web models. + * @param inputs filename + * @group export + * @shortname gltf scene + */ + exportGLB(inputs: Inputs.BabylonIO.ExportSceneGlbDto): void; + /** + * Exports the mesh with its children to stl + * @param inputs filename and the mesh + * @group export + * @shortname babylon mesh to stl + */ + exportMeshToStl(inputs: Inputs.BabylonIO.ExportMeshToStlDto): Promise; + /** + * Exports the meshes to stl + * @param inputs filename and the mesh + * @group export + * @shortname babylon meshes to stl + */ + exportMeshesToStl( + inputs: Inputs.BabylonIO.ExportMeshesToStlDto + ): Promise; + private loadAsset; + } + declare class BabylonLights { + private readonly context; + shadowLight: BabylonShadowLight; + constructor(context: Context); + } + declare class BabylonShadowLight { + private readonly context; + constructor(context: Context); + /** + * Sets the direction of the shadow light + * @param inputs shadow light and direction + * @group set + * @shortname set target + */ + setDirectionToTarget( + inputs: Inputs.BabylonLight.ShadowLightDirectionToTargetDto + ): void; + /** + * Sets the position of the shadow light + * @param inputs shadow light and position + * @group set + * @shortname set position + */ + setPosition(inputs: Inputs.BabylonLight.ShadowLightPositionDto): void; + } + declare class BabylonMaterial { + private readonly context; + private readonly color; + pbrMetallicRoughness: BabylonMaterialPbrMetallicRoughness; + skyMaterial: BabylonMaterialSky; + constructor(context: Context, color: Color); + } + declare class BabylonMaterialPbrMetallicRoughness { + private readonly context; + private readonly color; + constructor(context: Context, color: Color); + /** + * Create PBR metallic roughnes material. + * @param inputs required to set up metallic roughness material + * @returns PBR metallic roughness material + * @group create + * @shortname pbr material + * @disposableOutput true + */ + create( + inputs: Inputs.BabylonMaterial.PBRMetallicRoughnessDto + ): BABYLON.PBRMetallicRoughnessMaterial; + /** + * Sets the base color of material + * @param inputs base color and material + * @group set + * @shortname set base color + */ + setBaseColor(inputs: Inputs.BabylonMaterial.BaseColorDto): void; + /** + * Sets the metallic property of material + * @param inputs metallic value + * @group set + * @shortname set metallic + */ + setMetallic(inputs: Inputs.BabylonMaterial.MetallicDto): void; + /** + * Sets the roughness of material + * @param inputs roughness value + * @group set + * @shortname set roughness + */ + setRoughness(inputs: Inputs.BabylonMaterial.RoughnessDto): void; + /** + * Sets the alpha of material + * @param inputs alpha value + * @group set + * @shortname set alpha + */ + setAlpha(inputs: Inputs.BabylonMaterial.AlphaDto): void; + /** + * Sets the back face culling of material + * @param inputs back face culling boolean + * @group set + * @shortname set back face culling + */ + setBackFaceCulling(inputs: Inputs.BabylonMaterial.BackFaceCullingDto): void; + /** + * Sets the texture of material + * @param inputs texture and material + * @group set + * @shortname set base texture + */ + setBaseTexture(inputs: Inputs.BabylonMaterial.BaseTextureDto): void; + /** + * Gets the base color of material + * @param inputs material + * @return base color + * @group get + * @shortname get base color + */ + getBaseColor(inputs: Inputs.BabylonMaterial.MaterialPropDto): string; + /** + * Gets the metallic property of material + * @param inputs material + * @return metallic value + * @group get + * @shortname get metallic + */ + getMetallic(inputs: Inputs.BabylonMaterial.MaterialPropDto): number; + /** + * Gets the roughness of material + * @param inputs material + * @return roughness value + * @group get + * @shortname get roughness + */ + getRoughness(inputs: Inputs.BabylonMaterial.MaterialPropDto): number; + /** + * Gets the alpha of material + * @param inputs material + * @return alpha value + * @group get + * @shortname get alpha + */ + getAlpha(inputs: Inputs.BabylonMaterial.MaterialPropDto): number; + /** + * Gets the back face culling of material + * @param inputs material + * @return backfaceculling boolean + * @group get + * @shortname get back face culling + */ + getBackFaceCulling(inputs: Inputs.BabylonMaterial.MaterialPropDto): boolean; + /** + * Get the base texture of material + * @param inputs material + * @group get + * @shortname get base texture + */ + getBaseTexture( + inputs: Inputs.BabylonMaterial.MaterialPropDto + ): BABYLON.BaseTexture; + } + declare class BabylonMaterialSky { + private readonly context; + constructor(context: Context); + /** + * Create Sky Material + * @param inputs required to set up the sky material + * @returns Sky material + * @group create + * @shortname sky material + */ + create(inputs: Inputs.BabylonMaterial.SkyMaterialDto): SkyMaterial; + /** + * Sets the luminance of the sky material + * @param inputs luminance value and material + * @group set + * @shortname set luminance + */ + setLuminance(inputs: Inputs.BabylonMaterial.LuminanceDto): void; + /** + * Sets the turbidity of the sky material + * @param inputs turbidity value and material + * @group set + * @shortname set turbidity + */ + setTurbidity(inputs: Inputs.BabylonMaterial.TurbidityDto): void; + /** + * Sets the rayleigh of the sky material + * @param inputs rayleigh value and material + * @group set + * @shortname set rayleigh + */ + setRayleigh(inputs: Inputs.BabylonMaterial.RayleighDto): void; + /** + * Sets the mieCoefficient of the sky material + * @param inputs mieCoefficient value and material + * @group set + * @shortname set mieCoefficient + */ + setMieCoefficient(inputs: Inputs.BabylonMaterial.MieCoefficientDto): void; + /** + * Sets the mieDirectionalG of the sky material + * @param inputs mieDirectionalG value and material + * @group set + * @shortname set mieDirectionalG + */ + setMieDirectionalG(inputs: Inputs.BabylonMaterial.MieDirectionalGDto): void; + /** + * Sets the distance of the sky material + * @param inputs distance value and material + * @group set + * @shortname set distance + */ + setDistance(inputs: Inputs.BabylonMaterial.DistanceDto): void; + /** + * Sets the inclination of the sky material + * @param inputs inclination value and material + * @group set + * @shortname set inclination + */ + setInclination(inputs: Inputs.BabylonMaterial.InclinationDto): void; + /** + * Sets the azimuth of the sky material + * @param inputs azimuth value and material + * @group set + * @shortname set azimuth + */ + setAzimuth(inputs: Inputs.BabylonMaterial.AzimuthDto): void; + /** + * Sets the sun position of the sky material + * @param inputs sun position value and material + * @group set + * @shortname set sun position + */ + setSunPosition(inputs: Inputs.BabylonMaterial.SunPositionDto): void; + /** + * Sets the use sun position of the sky material + * @param inputs use sun position value and material + * @group set + * @shortname set use sun position + */ + setUseSunPosition(inputs: Inputs.BabylonMaterial.UseSunPositionDto): void; + /** + * Sets the camera offset of the sky material + * @param inputs camera offset value and material + * @group set + * @shortname set camera offset + */ + setCameraOffset(inputs: Inputs.BabylonMaterial.CameraOffsetDto): void; + /** + * Sets the up of the sky material + * @param inputs up value and material + * @group set + * @shortname set up + */ + setUp(inputs: Inputs.BabylonMaterial.UpDto): void; + /** + * Sets the dithering of the sky material + * @param inputs dithering value and material + * @group set + * @shortname set dithering + */ + setDithering(inputs: Inputs.BabylonMaterial.DitheringDto): void; + /** + * Gets the luminance of the sky material + * @param inputs material + * @group get + * @shortname get luminance + */ + getLuminance(inputs: Inputs.BabylonMaterial.SkyMaterialPropDto): number; + /** + * Gets the turbidity of the sky material + * @param inputs material + * @group get + * @shortname get turbidity + */ + getTurbidity(inputs: Inputs.BabylonMaterial.SkyMaterialPropDto): number; + /** + * Gets the rayleigh of the sky material + * @param inputs material + * @group get + * @shortname get rayleigh + */ + getRayleigh(inputs: Inputs.BabylonMaterial.SkyMaterialPropDto): number; + /** + * Gets the mieCoefficient of the sky material + * @param inputs material + * @group get + * @shortname get mieCoefficient + */ + getMieCoefficient( + inputs: Inputs.BabylonMaterial.SkyMaterialPropDto + ): number; + /** + * Gets the mieDirectionalG of the sky material + * @param inputs material + * @group get + * @shortname get mieDirectionalG + */ + getMieDirectionalG( + inputs: Inputs.BabylonMaterial.SkyMaterialPropDto + ): number; + /** + * Gets the distance of the sky material + * @param inputs material + * @group get + * @shortname get distance + */ + getDistance(inputs: Inputs.BabylonMaterial.SkyMaterialPropDto): number; + /** + * Gets the inclination of the sky material + * @param inputs material + * @group get + * @shortname get inclination + */ + getInclination(inputs: Inputs.BabylonMaterial.SkyMaterialPropDto): number; + /** + * Gets the azimuth of the sky material + * @param inputs material + * @group get + * @shortname get azimuth + */ + getAzimuth(inputs: Inputs.BabylonMaterial.SkyMaterialPropDto): number; + /** + * Gets the sun position of the sky material + * @param inputs material + * @group get + * @shortname get sun position + */ + getSunPosition( + inputs: Inputs.BabylonMaterial.SkyMaterialPropDto + ): Inputs.Base.Vector3; + /** + * Gets the use sun position of the sky material + * @param inputs material + * @group get + * @shortname get use sun position + */ + getUseSunPosition( + inputs: Inputs.BabylonMaterial.SkyMaterialPropDto + ): boolean; + /** + * Gets the camera offset of the sky material + * @param inputs material + * @group get + * @shortname get camera offset + */ + getCameraOffset( + inputs: Inputs.BabylonMaterial.SkyMaterialPropDto + ): Inputs.Base.Vector3; + /** + * Gets the up of the sky material + * @param inputs material + * @group get + * @shortname get up + */ + getUp( + inputs: Inputs.BabylonMaterial.SkyMaterialPropDto + ): Inputs.Base.Vector3; + /** + * Gets the dithering of the sky material + * @param inputs material + * @group get + * @shortname get dithering + */ + getDithering(inputs: Inputs.BabylonMaterial.SkyMaterialPropDto): boolean; + } + declare class BabylonMeshBuilder { + private readonly context; + private readonly mesh; + constructor(context: Context, mesh: BabylonMesh); + /** + * Creates a box mesh + * @param inputs required to set up basic box + * @returns Babylon mesh + * @group create simple + * @shortname create box + * @disposableOutput true + * @drawable true + */ + createBox(inputs: Inputs.BabylonMeshBuilder.CreateBoxDto): BABYLON.Mesh; + /** + * Creates a cube mesh + * @param inputs required to set up basic cube + * @returns Babylon mesh + * @group create simple + * @shortname create cube + * @disposableOutput true + * @drawable true + */ + createCube(inputs: Inputs.BabylonMeshBuilder.CreateCubeDto): BABYLON.Mesh; + /** + * Creates a square plane mesh + * @param inputs required to set up basic cube + * @returns Babylon mesh + * @group create simple + * @shortname square plane + * @disposableOutput true + * @drawable true + */ + createSquarePlane( + inputs: Inputs.BabylonMeshBuilder.CreateSquarePlaneDto + ): BABYLON.Mesh; + /** + * Creates a sphere mesh + * @param inputs required to set up basic sphere + * @returns Babylon mesh + * @group create simple + * @shortname create sphere + * @disposableOutput true + * @drawable true + */ + createSphere( + inputs: Inputs.BabylonMeshBuilder.CreateSphereDto + ): BABYLON.Mesh; + /** + * Create ico sphere + * @param inputs required to set up a ico sphere + * @returns Babylon mesh + * @group create simple + * @shortname create ico sphere + * @disposableOutput true + * @drawable true + */ + createIcoSphere( + inputs: Inputs.BabylonMeshBuilder.CreateIcoSphereDto + ): BABYLON.Mesh; + /** + * Creates a disc + * @param inputs required to set up a disc + * @returns Babylon mesh + * @group create simple + * @shortname create disc + * @disposableOutput true + * @drawable true + */ + createDisc(inputs: Inputs.BabylonMeshBuilder.CreateDiscDto): BABYLON.Mesh; + /** + * Create a torus mesh + * @param inputs required to set up a torus + * @returns Babylon mesh + * @group create simple + * @shortname create torus + * @disposableOutput true + * @drawable true + */ + createTorus(inputs: Inputs.BabylonMeshBuilder.CreateTorusDto): BABYLON.Mesh; + /** + * Create a torus knot mesh + * @param inputs required to set up a torus knot + * @returns Babylon mesh + * @group create simple + * @shortname create torus knot + * @disposableOutput true + * @drawable true + */ + createTorusKnot( + inputs: Inputs.BabylonMeshBuilder.CreateTorusKnotDto + ): BABYLON.Mesh; + /** + * Create a polygon mesh + * @param inputs required to set up a polygon + * @returns Babylon mesh + * @group create simple + * @shortname create polygon + * @disposableOutput true + * @drawable true + */ + createPolygon( + inputs: Inputs.BabylonMeshBuilder.CreatePolygonDto + ): BABYLON.Mesh; + /** + * Create extruded polygon mesh + * @param inputs required to set up a extrude polygon + * @returns Babylon mesh + * @group create simple + * @shortname create extrude polygon + * @disposableOutput true + * @drawable true + */ + extrudePolygon( + inputs: Inputs.BabylonMeshBuilder.ExtrudePolygonDto + ): BABYLON.Mesh; + /** + * Create a tube mesh + * @param inputs required to set up a tube + * @returns Babylon mesh + * @group create simple + * @shortname create tube + * @disposableOutput true + * @drawable true + */ + createTube(inputs: Inputs.BabylonMeshBuilder.CreateTubeDto): BABYLON.Mesh; + /** + * Create a polyhedron mesh + * @param inputs required to set up a polyhedron + * @returns Babylon mesh + * @group create simple + * @shortname create polyhedron + * @disposableOutput true + * @drawable true + */ + createPolyhedron( + inputs: Inputs.BabylonMeshBuilder.CreatePolyhedronDto + ): BABYLON.Mesh; + /** + * Create geodesic mesh + * @param inputs required to set up a geodesic + * @returns Babylon mesh + * @group create simple + * @shortname create geodesic + * @disposableOutput true + * @drawable true + */ + createGeodesic( + inputs: Inputs.BabylonMeshBuilder.CreateGeodesicDto + ): BABYLON.Mesh; + /** + * Create goldberg mesh + * @param inputs required to set up a goldberg mesh + * @returns Babylon mesh + * @group create simple + * @shortname create goldberg + * @disposableOutput true + * @drawable true + */ + createGoldberg( + inputs: Inputs.BabylonMeshBuilder.CreateGoldbergDto + ): BABYLON.Mesh; + /** + * Create capsule mesh + * @param inputs required to set up a capsule + * @returns Babylon mesh + * @group create simple + * @shortname create capsule + * @disposableOutput true + * @drawable true + */ + createCapsule( + inputs: Inputs.BabylonMeshBuilder.CreateCapsuleDto + ): BABYLON.Mesh; + /** + * Create a cylinder mesh + * @param inputs required to set up a cylinder + * @returns Babylon mesh + * @group create simple + * @shortname create cylinder + * @disposableOutput true + * @drawable true + */ + createCylinder( + inputs: Inputs.BabylonMeshBuilder.CreateCylinderDto + ): BABYLON.Mesh; + /** + * Create extruded shape + * @param inputs required to set up a extrude shape + * @returns Babylon mesh + * @group create simple + * @shortname create extruded shape + * @disposableOutput true + * @drawable true + */ + createExtrudedSahpe( + inputs: Inputs.BabylonMeshBuilder.CreateExtrudedShapeDto + ): BABYLON.Mesh; + /** + * Create a ribbon mesh + * @param inputs required to set up a ribbon + * @returns Babylon mesh + * @group create simple + * @shortname create ribbon + * @disposableOutput true + * @drawable true + */ + createRibbon( + inputs: Inputs.BabylonMeshBuilder.CreateRibbonDto + ): BABYLON.Mesh; + /** + * Create lathe mesh + * @param inputs required to set up a lathe + * @returns Babylon mesh + * @group create simple + * @shortname create lathe + * @disposableOutput true + * @drawable true + */ + createLathe(inputs: Inputs.BabylonMeshBuilder.CreateLatheDto): BABYLON.Mesh; + /** + * Create the ground mesh + * @param inputs required to set up a ground + * @returns Babylon mesh + * @group create simple + * @shortname create ground + * @disposableOutput true + * @drawable true + */ + createGround( + inputs: Inputs.BabylonMeshBuilder.CreateGroundDto + ): BABYLON.Mesh; + /** + * Creates a rectangle plane mesh + * @param inputs required to set up basic cube + * @returns Babylon mesh + * @group create simple + * @shortname rectangle plane + * @disposableOutput true + * @drawable true + */ + createRectanglePlane( + inputs: Inputs.BabylonMeshBuilder.CreateRectanglePlaneDto + ): BABYLON.Mesh; + private enableShadows; + } + declare class BabylonMesh { + private readonly context; + constructor(context: Context); + /** Disposes drawn mesh object from the scene + * @param inputs Contains BabylonJS mesh that should be disposed + * @group memory + * @shortname dispose + */ + dispose(inputs: Inputs.BabylonMesh.BabylonMeshDto): void; + /** Udates drawn BabylonJS mesh object without disposing it + * @param inputs Contains BabylonJS mesh that should be updated, together with position, rotation, scaling and colour info + * @returns BabylonJS Mesh + * @group updates + * @shortname update drawn + */ + updateDrawn(inputs: Inputs.BabylonMesh.UpdateDrawnBabylonMesh): void; + /** + * Change the visibility of a drawn BabylonJS mesh + * @param inputs BabylonJS mesh and parent mesh + * @group visibility + * @shortname set visibility + */ + setVisibility(inputs: Inputs.BabylonMesh.SetMeshVisibilityDto): void; + /** + * Hides the mesh + * @param inputs BabylonJS mesh to hide + * @group visibility + * @shortname hide + */ + hide(inputs: Inputs.BabylonMesh.ShowHideMeshDto): void; + /** + * Show the mesh + * @param inputs BabylonJS mesh to hide + * @group visibility + * @shortname show + */ + show(inputs: Inputs.BabylonMesh.ShowHideMeshDto): void; + /** + * Change the parent of the drawn mesh + * @param inputs BabylonJS mesh and parent mesh + * @group set + * @shortname parent + */ + setParent(inputs: Inputs.BabylonMesh.SetParentDto): void; + /** + * Get the parent of the drawn mesh + * @param inputs BabylonJS mesh + * @returns Parent mesh + * @group get + * @shortname parent + */ + getParent(inputs: Inputs.BabylonMesh.SetParentDto): BABYLON.Node; + /** + * Change the check collisions property of the drawn mesh + * @param inputs BabylonJS mesh and check collisions + * @group set + * @shortname check collisions + */ + setCheckCollisions( + inputs: Inputs.BabylonMesh.CheckCollisionsBabylonMeshDto + ): void; + /** + * Get the check collisions property of the drawn mesh + * @param inputs BabylonJS mesh and check collisions + * @group get + * @shortname check collisions + */ + getCheckCollisions( + inputs: Inputs.BabylonMesh.CheckCollisionsBabylonMeshDto + ): boolean; + /** + * Change the pickable property of the drawn mesh + * @param inputs BabylonJS mesh and pickable + * @group get + * @shortname check collisions + */ + setPickable(inputs: Inputs.BabylonMesh.PickableBabylonMeshDto): void; + /** + * Force mesh to be pickable by pointer move events, default is false as it is performance heavy + * @param inputs BabylonJS mesh + * @group set + * @shortname enable pointer move events + */ + enablePointerMoveEvents( + inputs: Inputs.BabylonMesh.BabylonMeshWithChildrenDto + ): void; + /** + * Make mesh ignore pointer move events, default is false + * @param inputs BabylonJS mesh and pickable + * @group set + * @shortname disable pointer move events + */ + disablePointerMoveEvents( + inputs: Inputs.BabylonMesh.BabylonMeshWithChildrenDto + ): void; + /** + * Change the pickable property of the drawn mesh + * @param inputs BabylonJS mesh and pickable + * @group get + * @shortname pickable + */ + getPickable(inputs: Inputs.BabylonMesh.BabylonMeshDto): boolean; + /** + * Gets meshes that have names which contain a given text + * @param inputs BabylonJS mesh and name + * @group get + * @shortname meshes where name contains + */ + getMeshesWhereNameContains( + inputs: Inputs.BabylonMesh.ByNameBabylonMeshDto + ): BABYLON.AbstractMesh[]; + /** + * Gets child meshes + * @param inputs BabylonJS mesh and whether to include only direct descendants + * @group get + * @shortname child meshes + */ + getChildMeshes( + inputs: Inputs.BabylonMesh.ChildMeshesBabylonMeshDto + ): BABYLON.AbstractMesh[]; + /** + * Gets meshes of id + * @param inputs BabylonJS mesh and name + * @group get + * @shortname meshes by id + */ + getMeshesOfId( + inputs: Inputs.BabylonMesh.ByIdBabylonMeshDto + ): BABYLON.AbstractMesh[]; + /** + * Gets mesh of id + * @param inputs BabylonJS mesh and name + * @group get + * @shortname mesh by id + */ + getMeshOfId( + inputs: Inputs.BabylonMesh.ByIdBabylonMeshDto + ): BABYLON.AbstractMesh; + /** + * Gets mesh of unique id + * @param inputs BabylonJS mesh and name + * @group get + * @shortname mesh by unique id + */ + getMeshOfUniqueId( + inputs: Inputs.BabylonMesh.UniqueIdBabylonMeshDto + ): BABYLON.AbstractMesh; + /** + * Merges multiple meshes into one + * @param inputs BabylonJS meshes and options + * @returns a new mesh + * @group edit + * @shortname merge + */ + mergeMeshes(inputs: Inputs.BabylonMesh.MergeMeshesDto): BABYLON.Mesh; + /** Convers mesh to flat shaded mesh + * @param inputs BabylonJS mesh + * @returns a new mesh + * @group edit + * @shortname convert to flat shaded + */ + convertToFlatShadedMesh( + inputs: Inputs.BabylonMesh.BabylonMeshDto + ): BABYLON.Mesh; + /** + * Clones the mesh + * @param inputs BabylonJS mesh to clone + * @returns a new mesh + * @group edit + * @shortname clone + * @disposableOutput true + */ + clone(inputs: Inputs.BabylonMesh.BabylonMeshDto): BABYLON.Mesh; + /** + * Clones the mesh to positions + * @param inputs BabylonJS mesh and positions + * @returns a new mesh + * @group edit + * @shortname clone to positions + * @disposableOutput true + * @drawable true + */ + cloneToPositions( + inputs: Inputs.BabylonMesh.CloneToPositionsDto + ): BABYLON.Mesh[]; + /** + * Change the id of the drawn mesh + * @param inputs BabylonJS mesh and name + * @group set + * @shortname id + */ + setId(inputs: Inputs.BabylonMesh.IdBabylonMeshDto): void; + /** + * Get the id of the drawn mesh + * @param inputs BabylonJS mesh and id + * @group get + * @shortname id + */ + getId(inputs: Inputs.BabylonMesh.IdBabylonMeshDto): string; + /** + * Get the unique id of the drawn mesh + * @param inputs BabylonJS mesh and id + * @returns unique id number + * @group get + * @shortname unique id + */ + getUniqueId(inputs: Inputs.BabylonMesh.BabylonMeshDto): number; + /** + * Change the name of the drawn mesh + * @param inputs BabylonJS mesh and name + * @group set + * @shortname name + */ + setName(inputs: Inputs.BabylonMesh.NameBabylonMeshDto): void; + /** + * Gets the vertices as polygon points. These can be used with other construction methods to create meshes. Mesh must be triangulated. + * @param inputs BabylonJS mesh and name + * @group get + * @shortname vertices as polygon points + */ + getVerticesAsPolygonPoints( + inputs: Inputs.BabylonMesh.BabylonMeshDto + ): Base.Point3[][]; + /** + * Gets the name of babylon mesh + * @param inputs BabylonJS mesh and name + * @group get + * @shortname name + */ + getName(inputs: Inputs.BabylonMesh.BabylonMeshDto): string; + /** + * Change the material of the drawn mesh + * @param inputs BabylonJS mesh and material + * @group set + * @shortname material + */ + setMaterial(inputs: Inputs.BabylonMesh.MaterialBabylonMeshDto): void; + /** + * Gets the material of babylon mesh + * @param inputs BabylonJS mesh + * @group get + * @shortname material + */ + getMaterial(inputs: Inputs.BabylonMesh.BabylonMeshDto): BABYLON.Material; + /** + * Gets the position as point of babylonjs mesh + * @param inputs BabylonJS mesh + * @returns point + * @group get + * @shortname position + */ + getPosition(inputs: Inputs.BabylonMesh.BabylonMeshDto): Base.Point3; + /** + * Gets the absolute position in the world as point of babylonjs mesh + * @param inputs BabylonJS mesh + * @returns point + * @group get + * @shortname absolute position + */ + getAbsolutePosition(inputs: Inputs.BabylonMesh.BabylonMeshDto): Base.Point3; + /** + * Gets the rotation vector of babylonjs mesh + * @param inputs BabylonJS mesh + * @group get + * @shortname rotation + */ + getRotation(inputs: Inputs.BabylonMesh.BabylonMeshDto): Base.Point3; + /** + * Gets the scale vector of babylonjs mesh + * @param inputs BabylonJS mesh + * @group get + * @shortname scale + */ + getScale(inputs: Inputs.BabylonMesh.BabylonMeshDto): Base.Point3; + /** + * Moves babylonjs mesh forward in local space + * @param inputs BabylonJS mesh and distance + * @group move + * @shortname forward + */ + moveForward(inputs: Inputs.BabylonMesh.TranslateBabylonMeshDto): void; + /** + * Moves babylonjs mesh backward in local space + * @param inputs BabylonJS mesh and distance + * @group move + * @shortname backward + */ + moveBackward(inputs: Inputs.BabylonMesh.TranslateBabylonMeshDto): void; + /** + * Moves babylonjs mesh up in local space + * @param inputs BabylonJS mesh and distance + * @group move + * @shortname up + */ + moveUp(inputs: Inputs.BabylonMesh.TranslateBabylonMeshDto): void; + /** + * Moves babylonjs mesh down in local space + * @param inputs BabylonJS mesh and distance + * @group move + * @shortname down + */ + moveDown(inputs: Inputs.BabylonMesh.TranslateBabylonMeshDto): void; + /** + * Moves babylonjs mesh right in local space + * @param inputs BabylonJS mesh and distance + * @group move + * @shortname right + */ + moveRight(inputs: Inputs.BabylonMesh.TranslateBabylonMeshDto): void; + /** + * Moves babylonjs mesh left in local space + * @param inputs BabylonJS mesh and distance + * @group move + * @shortname left + */ + moveLeft(inputs: Inputs.BabylonMesh.TranslateBabylonMeshDto): void; + /** + * Rotates babylonjs mesh around local y axis + * @param inputs BabylonJS mesh and rotation in degrees + * @group move + * @shortname yaw + */ + yaw(inputs: Inputs.BabylonMesh.RotateBabylonMeshDto): void; + /** + * Rotates babylonjs mesh around local x axis + * @param inputs BabylonJS mesh and rotation in degrees + * @group move + * @shortname pitch + */ + pitch(inputs: Inputs.BabylonMesh.RotateBabylonMeshDto): void; + /** + * Rotates babylonjs mesh around local z axis + * @param inputs BabylonJS mesh and rotation in degrees + * @group move + * @shortname roll + */ + roll(inputs: Inputs.BabylonMesh.RotateBabylonMeshDto): void; + /** + * Rotates the mesh around axis and given position by a given angle + * @param inputs Rotation around axis information + * @group move + * @shortname rotate around axis with position + */ + rotateAroundAxisWithPosition( + inputs: Inputs.BabylonMesh.RotateAroundAxisNodeDto + ): void; + /** + * Updates the position of the BabylonJS mesh or instanced mesh + * @param inputs BabylonJS mesh and position point + * @group set + * @shortname position + */ + setPosition( + inputs: Inputs.BabylonMesh.UpdateDrawnBabylonMeshPositionDto + ): void; + /** + * Updates the rotation of the BabylonJS mesh or instanced mesh + * @param inputs BabylonJS mesh and rotation along x, y and z axis in degrees + * @group set + * @shortname rotation + */ + setRotation( + inputs: Inputs.BabylonMesh.UpdateDrawnBabylonMeshRotationDto + ): void; + /** + * Updates the scale of the BabylonJS mesh or instanced mesh + * @param inputs BabylonJS mesh and scale vector + * @group set + * @shortname scale + */ + setScale(inputs: Inputs.BabylonMesh.UpdateDrawnBabylonMeshScaleDto): void; + /** + * Scales the BabylonJS mesh or instanced mesh in place by a given factor + * @param inputs BabylonJS mesh and scale factor + * @group set + * @shortname scale in place + */ + setLocalScale(inputs: Inputs.BabylonMesh.ScaleInPlaceDto): void; + /** + * Checks wether mesh intersects another mesh mesh + * @param inputs Two BabylonJS meshes + * @group intersects + * @shortname mesh + */ + intersectsMesh(inputs: Inputs.BabylonMesh.IntersectsMeshDto): boolean; + /** + * Checks wether mesh intersects point + * @param inputs BabylonJS mesh and point + * @group intersects + * @shortname point + */ + intersectsPoint(inputs: Inputs.BabylonMesh.IntersectsPointDto): boolean; + /** + * Creates mesh instance for optimised rendering. This method will check if mesh contains children and will create instances for each child. + * These are optimised for max performance when rendering many similar objects in the scene. This method returns instances as childrens in a new mesh. + * If the mesh has children, then every child goes a mesh instance. + * @group instance + * @shortname create and transform + * @disposableOutput true + */ + createMeshInstanceAndTransformNoReturn( + inputs: Inputs.BabylonMesh.MeshInstanceAndTransformDto + ): void; + /** + * Creates mesh instance for optimised rendering. This method will check if mesh contains children and will create instances for each child. + * These are optimised for max performance when rendering many similar objects in the scene. This method returns instances as childrens in a new mesh. + * If the mesh has children, then every child goes a mesh instance. + * @group instance + * @returns babylon mesh + * @shortname create and transform + * @disposableOutput true + */ + createMeshInstanceAndTransform( + inputs: Inputs.BabylonMesh.MeshInstanceAndTransformDto + ): BABYLON.Mesh; + /** + * Creates mesh instance. These are optimised for max performance + * when rendering many similar objects in the scene. If the mesh has children, then every child gets a mesh instance. + * @group instance + * @shortname create + * @disposableOutput true + */ + createMeshInstance( + inputs: Inputs.BabylonMesh.MeshInstanceDto + ): BABYLON.Mesh; + /** + * Gets side orientation + * @ignore true + */ + getSideOrientation( + sideOrientation: Inputs.BabylonMesh.sideOrientationEnum + ): number; + private assignColorToMesh; + } + /** + * Nodes help understand the space and construct more complicated space structures. Nodes can be nested together + * into child parent relationships to simplify the creation of 3D objects. + */ + declare class BabylonNode { + private readonly context; + private readonly drawHelper; + constructor(context: Context, drawHelper: DrawHelper); + /** + * Draws a node of given size with given colours for every axis + * @param inputs Contains node data that includes size and colour information + */ + drawNode(inputs: Inputs.BabylonNode.DrawNodeDto): void; + /** + * Draws a nodes of given size with given colours for every axis + * @param inputs Contains node data that includes size and colour information + */ + drawNodes(inputs: Inputs.BabylonNode.DrawNodesDto): void; + /** + * Creates a node on the origin with the given rotations in the parent coordinate system + * @param inputs Contains information for origin, rotation and parent node + * @returns A new node + */ + createNodeFromRotation( + inputs: Inputs.BabylonNode.CreateNodeFromRotationDto + ): BABYLON.TransformNode; + /** + * Creates a world node which has root node as his parent + * @returns A new node whos parent is the root node of the scene + */ + createWorldNode(): BABYLON.TransformNode; + /** + * Gets the absolute forward facing vector in world space + * @param inputs Node from which to get the forward vector + * @returns Vector as an array of numbers + */ + getAbsoluteForwardVector(inputs: Inputs.BabylonNode.NodeDto): number[]; + /** + * Gets the absolute right facing vector in world space + * @param inputs Node from which to get the right vector + * @returns Vector as an array of numbers + */ + getAbsoluteRightVector(inputs: Inputs.BabylonNode.NodeDto): number[]; + /** + * Gets the absolute up facing vector in world space + * @param inputs Node from which to get the up vector + * @returns Vector as an array of numbers + */ + getAbsoluteUpVector(inputs: Inputs.BabylonNode.NodeDto): number[]; + /** + * Gets the absolute position of the node as origin vector in world space + * @param inputs Node from which to get the absolute position + * @returns Vector as an array of numbers indicating location of origin in world space + */ + getAbsolutePosition(inputs: Inputs.BabylonNode.NodeDto): number[]; + /** + * Gets the absolute rotation of the node as a transformation matrix encoded in array of 16 numbers + * @param inputs Node from which to get the rotation transformation + * @returns Transformation as an array of 16 numbers + */ + getAbsoluteRotationTransformation( + inputs: Inputs.BabylonNode.NodeDto + ): number[]; + /** + * Gets the rotation of the node in local parent coordinate space as a transformation matrix encoded in array of 16 numbers + * @param inputs Node from which to get the rotation transformation + * @returns Transformation as an array of 16 numbers + */ + getRotationTransformation(inputs: Inputs.BabylonNode.NodeDto): number[]; + /** + * Gets children of the node + * @param inputs Node from which to get the children + * @returns List of children nodes in the array + */ + getChildren(inputs: Inputs.BabylonNode.NodeDto): BABYLON.Node[]; + /** + * Gets parent of the node + * @param inputs Node from which to get a parent + * @returns Parent node + */ + getParent(inputs: Inputs.BabylonNode.NodeDto): BABYLON.Node; + /** + * Gets the position of the node expressed in local space + * @param inputs Node from which to get the position in local space + * @returns Position vector + */ + getPositionExpressedInLocalSpace( + inputs: Inputs.BabylonNode.NodeDto + ): number[]; + /** + * Gets the root node + * @returns Root node + */ + getRootNode(): BABYLON.TransformNode; + /** + * Gets the euler rotations + * @param inputs Node from which to get rotation + * @returns Euler rotations of x, y and z angles in the number array + */ + getRotation(inputs: Inputs.BabylonNode.NodeDto): number[]; + /** + * Rotates the node around axis and given position by a given angle + * @param inputs Rotation around axis information + */ + rotateAroundAxisWithPosition( + inputs: Inputs.BabylonNode.RotateAroundAxisNodeDto + ): void; + /** + * Rotates the node around the origin and given axis + * @param inputs Rotation information + */ + rotate(inputs: Inputs.BabylonNode.RotateNodeDto): void; + /** + * Sets the absolute position of the node + * @param inputs Node absolute position information + */ + setAbsolutePosition(inputs: Inputs.BabylonNode.NodePositionDto): void; + /** + * Sets the direction of the node + * @param inputs Direction information + */ + setDirection(inputs: Inputs.BabylonNode.NodeDirectionDto): void; + /** + * Sets the new parent to the node + * @param inputs Node parent information + */ + setParent(inputs: Inputs.BabylonNode.NodeParentDto): void; + /** + * Translates the node by a given direction vector and a distance + * @param inputs Node translation information + */ + translate(inputs: Inputs.BabylonNode.NodeTranslationDto): void; + } + declare class BabylonPick { + private readonly context; + constructor(context: Context); + /** + * Get a hit result of picking with ray + * @param inputs ray to use for picking + * @group pick + * @shortname pick with custom ray + * @returns Picking info + */ + pickWithRay(inputs: Inputs.BabylonPick.RayDto): BABYLON.PickingInfo; + /** + * Pick with picking ray of the current mouse position in the active camera + * @group pick + * @shortname pick with picking ray + * @returns Picking info + */ + pickWithPickingRay(): BABYLON.PickingInfo; + /** + * Get the distance to the object if picking result exists + * @param inputs picking result + * @group get from pick info + * @shortname pick distance + * @returns Distance + */ + getDistance(inputs: Inputs.BabylonPick.PickInfo): number; + /** + * Get the picked mesh + * @param inputs picking result + * @group get from pick info + * @shortname picked mesh + * @returns Picked mesh + */ + getPickedMesh(inputs: Inputs.BabylonPick.PickInfo): BABYLON.AbstractMesh; + /** + * Get the picked point + * @param inputs picking result + * @group get from pick info + * @shortname picked point + * @returns Picked point + */ + getPickedPoint(inputs: Inputs.BabylonPick.PickInfo): Base.Point3; + /** + * Check if pick ray hit something in the scene or not + * @param inputs picking result + * @group get from pick info + * @shortname hit + * @returns Indication of a hit + */ + hit(inputs: Inputs.BabylonPick.PickInfo): boolean; + /** + * Gets the unique submesh id if it was picked + * @param inputs picking result + * @group get from pick info + * @shortname sub mesh id + * @returns Submesh id + */ + getSubMeshId(inputs: Inputs.BabylonPick.PickInfo): number; + /** + * Gets the unique submesh face id if it was picked + * @param inputs picking result + * @group get from pick info + * @shortname sub mesh face id + * @returns Submesh face id + */ + getSubMeshFaceId(inputs: Inputs.BabylonPick.PickInfo): number; + /** + * Gets the the barycentric U coordinate that is used when calculating the texture coordinates of the collision + * @param inputs picking result + * @group get from pick info + * @shortname picked bu + * @returns U coordinate + */ + getBU(inputs: Inputs.BabylonPick.PickInfo): number; + /** + * Gets the the barycentric V coordinate that is used when calculating the texture coordinates of the collision + * @param inputs picking result + * @group get from pick info + * @shortname picked bv + * @returns V coordinate + */ + getBV(inputs: Inputs.BabylonPick.PickInfo): number; + /** + * Get the picked sprite + * @param inputs picking result + * @group get from pick info + * @shortname picked sprite + * @returns Picked sprite + */ + getPickedSprite(inputs: Inputs.BabylonPick.PickInfo): BABYLON.Sprite; + } + declare class BabylonRay { + private readonly context; + constructor(context: Context); + /** + * Creates a picking ray of the current mouse position in the active camera + * @group create + * @shortname create picking ray + * @returns Ray + */ + createPickingRay(): BABYLON.Ray; + /** + * Create a ray that start at origin, has direction vector and optionally length + * @param inputs origin, direction and length + * @group create + * @shortname create custom ray + * @returns ray + */ + createRay(inputs: Inputs.BabylonRay.BaseRayDto): BABYLON.Ray; + /** + * Create a ray from one point to another + * @param inputs origin, direction and length + * @group create + * @shortname create ray from to + * @returns ray + */ + createRayFromTo(inputs: Inputs.BabylonRay.FromToDto): BABYLON.Ray; + /** + * Get the origin of the ray + * @param inputs ray + * @group get + * @shortname get ray origin + * @returns origin point + */ + getOrigin(inputs: Inputs.BabylonRay.RayDto): Base.Point3; + /** + * Get the direction of the ray + * @param inputs ray + * @group get + * @shortname get ray direction + * @returns direction vector + */ + getDirection(inputs: Inputs.BabylonRay.RayDto): Base.Vector3; + /** + * Get the length of the ray + * @param inputs ray + * @group get + * @shortname get ray length + * @returns length + */ + getLength(inputs: Inputs.BabylonRay.RayDto): number; + } + declare class BabylonScene { + private readonly context; + constructor(context: Context); + /** + * Gets the scene for the current context + * @ignore true + * @group scene + * @shortname get scene + */ + getScene(): BABYLON.Scene; + /** + * Gets the scene for the current context + * @ignore true + * @group scene + * @shortname get scene + */ + setAndAttachScene(inputs: Inputs.BabylonScene.SceneDto): BABYLON.Scene; + /** + * Activate camera by overwriting currently active camera + * @param inputs Activates the camera + * @group camera + * @shortname activate + */ + activateCamera(inputs: Inputs.BabylonScene.ActiveCameraDto): void; + /** + * Use right handed system + * @param inputs Activates the camera + * @group system + * @shortname hand right + */ + useRightHandedSystem( + inputs: Inputs.BabylonScene.UseRightHandedSystemDto + ): void; + /** + * Creates and draws a point light in the scene but does not output anything + * @param inputs Describes the light source + * @group lights + * @shortname point + * @disposableOutput true + */ + drawPointLightNoReturn(inputs: Inputs.BabylonScene.PointLightDto): void; + /** + * Get shadow generators added by light sources through bitbybit + * @param inputs Describes the light source + * @group lights + * @shortname point + * @disposableOutput true + */ + getShadowGenerators(): BABYLON.ShadowGenerator[]; + /** + * Creates and draws a point light in the scene + * @param inputs Describes the light source + * @returns BabylonJS point light + * @group lights + * @shortname point light + * @disposableOutput true + */ + drawPointLight( + inputs: Inputs.BabylonScene.PointLightDto + ): BABYLON.PointLight; + /** + * Creates and draws a directional light in the scene + * @param inputs Describes the light source + * @group lights + * @shortname directional + * @disposableOutput true + */ + drawDirectionalLightNoReturn( + inputs: Inputs.BabylonScene.DirectionalLightDto + ): void; + /** + * Creates and draws a directional light in the scene + * @param inputs Describes the light source + * @returns BabylonJS directional light + * @group lights + * @shortname directional light + * @disposableOutput true + */ + drawDirectionalLight( + inputs: Inputs.BabylonScene.DirectionalLightDto + ): BABYLON.DirectionalLight; + /** + * Gets the active camera of the scene + * @group camera + * @shortname get active camera + */ + getActiveCamera(): BABYLON.Camera; + /** + * Adjusts the active arc rotate camera with configuration parameters + * @group camera + * @shortname adjust active camera + */ + adjustActiveArcRotateCamera( + inputs: Inputs.BabylonScene.CameraConfigurationDto + ): void; + /** + * Clears all of the drawn objects in the 3D scene + * @group environment + * @shortname clear all drawn + */ + clearAllDrawn(): void; + /** + * Enables skybox + * @param inputs Skybox configuration + * @group environment + * @shortname skybox + */ + enableSkybox(inputs: Inputs.BabylonScene.SkyboxDto): void; + /** + * Enables skybox with custom texture + * @param inputs Skybox configuration + * @group environment + * @shortname skybox + */ + enableSkyboxCustomTexture( + inputs: Inputs.BabylonScene.SkyboxCustomTextureDto + ): void; + /** + * Registers code to run when pointer is down + * @param inputs pointer statement + * @ignore true + */ + onPointerDown(inputs: Inputs.BabylonScene.PointerDto): void; + /** + * Registers code to run when pointer is up + * @param inputs pointer statement + * @ignore true + */ + onPointerUp(inputs: Inputs.BabylonScene.PointerDto): void; + /** + * Registers code to run when pointer is moving + * @param inputs pointer statement + * @ignore true + */ + onPointerMove(inputs: Inputs.BabylonScene.PointerDto): void; + /** + * Enables fog mode + * @param inputs fog options + * @group environment + * @shortname fog + */ + fog(inputs: Inputs.BabylonScene.FogDto): void; + /** + * Enables the physics + * @param inputs the gravity vector + * @ignore true + * @group physics + * @shortname enable + */ + enablePhysics(inputs: Inputs.BabylonScene.EnablePhysicsDto): void; + /** + * Changes the scene background to a css background image for 3D space + * @param inputs Describes the css of the scene background or image + * @group background + * @shortname css background image + */ + canvasCSSBackgroundImage( + inputs: Inputs.BabylonScene.SceneCanvasCSSBackgroundImageDto + ): { + backgroundImage: string; + }; + /** + * Creates a two-color linear gradient background for 3D space + * @param inputs Describes the two-color linear gradient parameters + * @group background + * @shortname two color linear gradient + */ + twoColorLinearGradientBackground( + inputs: Inputs.BabylonScene.SceneTwoColorLinearGradientDto + ): { + backgroundImage: string; + }; + /** + * Creates a two-color radial gradient background for 3D space + * @param inputs Describes the two-color radial gradient parameters + * @group background + * @shortname two color radial gradient + */ + twoColorRadialGradientBackground( + inputs: Inputs.BabylonScene.SceneTwoColorRadialGradientDto + ): { + backgroundImage: string; + }; + /** + * Creates a multi-color linear gradient background for 3D space + * @param inputs Describes the multi-color linear gradient parameters + * @group background + * @shortname multi color linear gradient + */ + multiColorLinearGradientBackground( + inputs: Inputs.BabylonScene.SceneMultiColorLinearGradientDto + ): + | { + backgroundImage: string; + } + | { + error: string; + }; + /** + * Creates a multi-color radial gradient background for 3D space + * @param inputs Describes the multi-color radial gradient parameters + * @group background + * @shortname multi color radial gradient + */ + multiColorRadialGradientBackground( + inputs: Inputs.BabylonScene.SceneMultiColorRadialGradientDto + ): + | { + backgroundImage: string; + } + | { + error: string; + }; + /** + * Sets a background image with various customization options for 3D space + * @param inputs Describes the background image parameters + * @group background + * @shortname background image + */ + canvasBackgroundImage( + inputs: Inputs.BabylonScene.SceneCanvasBackgroundImageDto + ): { + backgroundImage: string; + backgroundRepeat: string; + backgroundSize: string; + backgroundPosition: string; + backgroundAttachment: string; + backgroundOrigin: string; + backgroundClip: string; + }; + /** + * Changes the scene background colour for 3D space + * @param inputs Describes the colour of the scene background + * @group background + * @shortname colour + */ + backgroundColour( + inputs: Inputs.BabylonScene.SceneBackgroundColourDto + ): void; + private getRadians; + private createSkyboxMesh; + } + declare class BabylonTexture { + private readonly context; + constructor(context: Context); + /** + * Creates texture from URL from a few basic options. If you loaded the asset via the file, create object url and pass it here. + * @param inputs required to set up basic texture + * @returns Babylon texture that can be used with materials + * @group create + * @shortname simple texture + * @disposableOutput true + */ + createSimple( + inputs: Inputs.BabylonTexture.TextureSimpleDto + ): BABYLON.Texture; + } + declare class BabylonTools { + private readonly context; + constructor(context: Context); + /** + * Creates a screenshot of the scene + * @group screenshots + * @shortname create screenshot + */ + createScreenshot( + inputs: Inputs.BabylonTools.ScreenshotDto + ): Promise; + /** + * Creates a screenshot of the scene and download file + * @group screenshots + * @shortname create screenshot and download + */ + createScreenshotAndDownload( + inputs: Inputs.BabylonTools.ScreenshotDto + ): Promise; + } + /** + * Transformations help to move, scale, rotate and mirror objects. You can combine multiple transformations + * for object to be placed exactly into position and orientation that you want. + * Contains various methods for transformations that represent 4x4 matrixes in flat 16 number arrays. + */ + declare class BabylonTransforms { + /** + * Creates a rotation transformations around the center and an axis + * @param inputs Rotation around center with an axis information + * @returns array of transformations + * @group rotation + * @shortname center axis + * @drawable false + */ + rotationCenterAxis( + inputs: Inputs.BabylonTransforms.RotationCenterAxisDto + ): Base.TransformMatrixes; + /** + * Creates a rotation transformations around the center and an X axis + * @param inputs Rotation around center with an X axis information + * @returns array of transformations + * @group rotation + * @shortname center x + * @drawable false + */ + rotationCenterX( + inputs: Inputs.BabylonTransforms.RotationCenterDto + ): Base.TransformMatrixes; + /** + * Creates a rotation transformations around the center and an Y axis + * @param inputs Rotation around center with an Y axis information + * @returns array of transformations + * @group rotation + * @shortname center y + * @drawable false + */ + rotationCenterY( + inputs: Inputs.BabylonTransforms.RotationCenterDto + ): Base.TransformMatrixes; + /** + * Creates a rotation transformations around the center and an Z axis + * @param inputs Rotation around center with an Z axis information + * @returns array of transformations + * @group rotation + * @shortname center z + * @drawable false + */ + rotationCenterZ( + inputs: Inputs.BabylonTransforms.RotationCenterDto + ): Base.TransformMatrixes; + /** + * Creates a rotation transformations with yaw pitch and roll + * @param inputs Yaw pitch roll rotation information + * @returns array of transformations + * @group rotation + * @shortname yaw pitch roll + * @drawable false + */ + rotationCenterYawPitchRoll( + inputs: Inputs.BabylonTransforms.RotationCenterYawPitchRollDto + ): Base.TransformMatrixes; + /** + * Scale transformation around center and xyz directions + * @param inputs Scale center xyz trnansformation + * @returns array of transformations + * @group rotation + * @shortname center xyz + * @drawable false + */ + scaleCenterXYZ( + inputs: Inputs.BabylonTransforms.ScaleCenterXYZDto + ): Base.TransformMatrixes; + /** + * Creates the scale transformation in x, y and z directions + * @param inputs Scale XYZ number array information + * @returns transformation + * @group scale + * @shortname xyz + * @drawable false + */ + scaleXYZ( + inputs: Inputs.BabylonTransforms.ScaleXYZDto + ): Base.TransformMatrixes; + /** + * Creates uniform scale transformation + * @param inputs Scale Dto + * @returns transformation + * @group scale + * @shortname uniform + * @drawable false + */ + uniformScale( + inputs: Inputs.BabylonTransforms.UniformScaleDto + ): Base.TransformMatrixes; + /** + * Creates uniform scale transformation from the center + * @param inputs Scale Dto with center point information + * @returns array of transformations + * @group scale + * @shortname uniform from center + * @drawable false + */ + uniformScaleFromCenter( + inputs: Inputs.BabylonTransforms.UniformScaleFromCenterDto + ): Base.TransformMatrixes; + /** + * Creates the translation transformation + * @param inputs Translation information + * @returns transformation + * @group translation + * @shortname xyz + * @drawable false + */ + translationXYZ( + inputs: Inputs.BabylonTransforms.TranslationXYZDto + ): Base.TransformMatrixes; + /** + * Creates the translation transformation + * @param inputs Translation information + * @returns transformation + * @group translations + * @shortname xyz + * @drawable false + */ + translationsXYZ( + inputs: Inputs.BabylonTransforms.TranslationsXYZDto + ): Base.TransformMatrixes[]; + } + declare class BabylonWebXRBase { + private readonly context; + constructor(context: Context); + /** + * Creates default XR experience + * @param inputs Options for basic configuration + * @group scene + * @shortname default xr experience async + * @disposableOutput true + */ + createDefaultXRExperienceAsync( + inputs: Inputs.BabylonWebXR.WebXRDefaultExperienceOptions + ): Promise; + /** + * Creates default XR experience + * @param inputs Options for basic configuration + * @group scene + * @shortname default xr experience no opt. async + * @disposableOutput true + */ + createDefaultXRExperienceNoOptionsAsync(): Promise; + /** + * Returns the base experience of the default XR experience + * @param inputs Inputs with the default XR experience + * @group get + * @shortname get base experience + */ + getBaseExperience( + inputs: Inputs.BabylonWebXR.WebXRDefaultExperienceDto + ): BABYLON.WebXRExperienceHelper; + /** + * Returns the feature manager of the default XR experience + * @param inputs Inputs with the default XR experience + * @group get + * @shortname get feature manager + */ + getFeatureManager( + inputs: Inputs.BabylonWebXR.WebXRExperienceHelperDto + ): BABYLON.WebXRFeaturesManager; + } + declare class BabylonWebXRSimple { + private readonly context; + constructor(context: Context); + /** + * Creates default XR experience in immersive-ar mode + * @param inputs Creates default XR experience with teleportation + * @returns Default XR experience + * @group scene + * @shortname simple immersive ar experience + * @disposableOutput true + */ + createImmersiveARExperience(): Promise; + /** + * Creates default XR experience with teleportation that is very basic and works for simple scenarios + * @param inputs Creates default XR experience with teleportation + * @group scene + * @shortname simple xr with teleportation + */ + createDefaultXRExperienceWithTeleportation( + inputs: Inputs.BabylonWebXR.DefaultWebXRWithTeleportationDto + ): Promise; + /** + * Creates default XR experience with teleportation that is very basic and works for simple scenarios + * @param inputs Creates default XR experience with teleportation + * @group scene + * @shortname simple xr with teleportation return + * @disposableOutput true + */ + createDefaultXRExperienceWithTeleportationReturn( + inputs: Inputs.BabylonWebXR.DefaultWebXRWithTeleportationDto + ): Promise<{ + xr: BABYLON.WebXRDefaultExperience; + torusMat: BABYLON.PBRMetallicRoughnessMaterial; + manager: GUI3DManager; + near: NearMenu; + button: TouchHolographicButton; + text: TextBlock; + dispose: () => void; + }>; + } + declare class BabylonWebXR { + private readonly context; + simple: BabylonWebXRSimple; + constructor(context: Context); + } + declare class Draw extends DrawCore { + /** + * @ignore true + */ + readonly drawHelper: DrawHelper; + /** + * @ignore true + */ + readonly node: BabylonNode; + /** + * @ignore true + */ + readonly tag: Tag; + /** + * @ignore true + */ + readonly context: Context; + private defaultBasicOptions; + private defaultPolylineOptions; + private defaultNodeOptions; + constructor( + /** + * @ignore true + */ + drawHelper: DrawHelper, + /** + * @ignore true + */ + node: BabylonNode, + /** + * @ignore true + */ + tag: Tag, + /** + * @ignore true + */ + context: Context + ); + /** + * Draws any kind of geometry and does not return anything + * @param inputs Contains options and entities to be drawn + * @group draw async + * @shortname draw async void + * @disposableOutput true + * @drawable true + */ + drawAnyAsyncNoReturn(inputs: Inputs.Draw.DrawAny): Promise; + /** + * Draws any kind of geometry and returns the babylon mesh + * @param inputs Contains options and entities to be drawn + * @returns BabylonJS Mesh Promise + * @group draw async + * @shortname draw async + * @drawable true + * @disposableOutput true + */ + drawAnyAsync(inputs: Inputs.Draw.DrawAny): Promise; + private updateAny; + /** + * Draws any kind of geometry that does not need asynchronous computing, thus it cant be used with shapes coming from occt or jscad + * @param inputs Contains options and entities to be drawn + * @returns BabylonJS Mesh + * @group draw sync + * @shortname draw sync void + */ + drawAnyNoReturn(inputs: Inputs.Draw.DrawAny): void; + /** + * Draws any kind of geometry that does not need asynchronous computing, thus it cant be used with shapes coming from occt or jscad + * @param inputs Contains options and entities to be drawn + * @returns BabylonJS Mesh + * @group draw sync + * @shortname draw sync + */ + drawAny(inputs: Inputs.Draw.DrawAny): BABYLON.Mesh; + /** + * Draws a grid mesh on the ground plane in 3D space. This helps to orient yourself in the world. + * @param inputs Describes various parameters of the grid mesh like size, colour, etc. + * @group grid + * @shortname draw grid no return + * @disposableOutput true + */ + drawGridMeshNoReturn(inputs: Inputs.Draw.SceneDrawGridMeshDto): void; + /** + * Draws a grid mesh on the ground plane in 3D space. This helps to orient yourself in the world. + * @param inputs Describes various parameters of the grid mesh like size, colour, etc. + * @returns grid mesh + * @group grid + * @shortname draw grid + * @disposableOutput true + */ + drawGridMesh(inputs: Inputs.Draw.SceneDrawGridMeshDto): BABYLON.Mesh; + /** + * Creates draw options for basic geometry types like points, lines, polylines, surfaces and jscad meshes + * @param inputs option definition + * @returns options + * @group options + * @shortname simple + */ + optionsSimple( + inputs: Inputs.Draw.DrawBasicGeometryOptions + ): Inputs.Draw.DrawBasicGeometryOptions; + /** + * Creates draw options for occt shape geometry like edges, wires, faces, shells, solids and compounds + * @param inputs option definition + * @returns options + * @group options + * @shortname occt shape + */ + optionsOcctShape( + inputs: Inputs.Draw.DrawOcctShapeOptions + ): Inputs.Draw.DrawOcctShapeOptions; + /** + * Creates simple draw options for occt shape geometry + * @param inputs option definition + * @returns options + * @group options + * @shortname occt shape simple + */ + optionsOcctShapeSimple( + inputs: Inputs.Draw.DrawOcctShapeSimpleOptions + ): Inputs.Draw.DrawOcctShapeSimpleOptions; + /** + * Creates simple draw options with custom face material for occt shape geometry + * @param inputs option definition + * @returns options + * @group options + * @shortname occt shape with material + */ + optionsOcctShapeMaterial( + inputs: Inputs.Draw.DrawOcctShapeMaterialOptions + ): Inputs.Draw.DrawOcctShapeMaterialOptions; + /** + * Creates draw options for manifold gemetry + * @param inputs option definition + * @returns options + * @group options + * @shortname manifold shape draw options + */ + optionsManifoldShapeMaterial( + inputs: Inputs.Draw.DrawManifoldOrCrossSectionOptions + ): Inputs.Draw.DrawManifoldOrCrossSectionOptions; + /** + * Creates draw options for babylon js nodes + * @param inputs option definition + * @returns options + * @group options + * @shortname babylon node + */ + optionsBabylonNode( + inputs: Inputs.Draw.DrawNodeOptions + ): Inputs.Draw.DrawNodeOptions; + /** + * Creates a generic texture that can be used with PBR materials. + * This method provides a cross-engine compatible way to create textures. + * @param inputs Texture configuration options + * @returns BabylonJS Texture + * @group material + * @shortname create texture + * @disposableOutput true + */ + createTexture(inputs: Inputs.Draw.GenericTextureDto): BABYLON.Texture; + /** + * Creates a generic PBR (Physically Based Rendering) material. + * This method provides a cross-engine compatible way to create materials + * that can be used with draw options for OCCT shapes and other geometry. + * @param inputs Material configuration options + * @returns BabylonJS PBRMetallicRoughnessMaterial + * @group material + * @shortname create pbr material + * @disposableOutput true + */ + createPBRMaterial( + inputs: Inputs.Draw.GenericPBRMaterialDto + ): BABYLON.PBRMetallicRoughnessMaterial; + private getSamplingMode; + private handleTags; + private handleTag; + private handleVerbSurfaces; + private handleVerbCurves; + private handleNodes; + private handlePoints; + private handleLines; + private handlePolylines; + private handleVerbSurface; + private handleVerbCurve; + private handleNode; + private handlePolyline; + private handlePoint; + private handleLine; + private handleJscadMeshes; + private handleManifoldShape; + private handleManifoldShapes; + private handleOcctShape; + private handleOcctShapes; + private handleJscadMesh; + private applyGlobalSettingsAndMetadataAndShadowCasting; + } + declare class Color { + private readonly math; + constructor(math: MathBitByBit); + /** + * Creates and returns a hex color string (pass-through for color input). + * Example: '#FF5733' → '#FF5733' + * @param inputs Color hex + * @returns color string + * @group create + * @shortname color + * @drawable false + */ + hexColor(inputs: Inputs.Color.HexDto): Inputs.Base.Color; + /** + * Converts hex color to RGB object with r, g, b values (0-255 range). + * Example: '#FF5733' → {r: 255, g: 87, b: 51} + * @param inputs Color hex + * @returns rgb color + * @group convert + * @shortname hex to rgb + * @drawable false + */ + hexToRgb(inputs: Inputs.Color.HexDto): Inputs.Base.ColorRGB; + /** + * Converts RGB values to hex color string (supports custom min/max ranges, auto-remaps to 0-255). + * Example: r=255, g=87, b=51 with range [0,255] → '#ff5733' + * Example: r=1, g=0.5, b=0.2 with range [0,1] → '#ff7f33' + * @param inputs Color hext + * @returns hex color + * @group convert + * @shortname rgb to hex + * @drawable false + */ + rgbToHex(inputs: Inputs.Color.RGBMinMaxDto): Inputs.Base.Color; + /** + * Converts RGB object to hex color string (supports custom min/max ranges). + * Example: {r: 1, g: 0.5, b: 0.2} with range [0,1] → '#ff7f33' + * @param inputs Color hext + * @returns hex color string + * @group convert + * @shortname rgb obj to hex + * @drawable false + */ + rgbObjToHex(inputs: Inputs.Color.RGBObjectMaxDto): Inputs.Base.Color; + /** + * Converts hex color to RGB and remaps values to a custom range. + * Example: '#FF5733' mapped to [0,1] → {r: 1, g: 0.341, b: 0.2} + * Example: '#FF5733' mapped to [0,100] → {r: 100, g: 34.1, b: 20} + * @param inputs Color hext + * @returns rgb color + * @group convert + * @shortname hex to rgb mapped + * @drawable false + */ + hexToRgbMapped(inputs: Inputs.Color.HexDtoMapped): Inputs.Base.ColorRGB; + /** + * Extracts the red channel value from hex color (can be mapped to custom range). + * Example: '#FF5733' with range [0,1] → 1 + * @param inputs Color hext + * @returns rgb color + * @group hex to + * @shortname red + * @drawable false + */ + getRedParam(inputs: Inputs.Color.HexDtoMapped): number; + /** + * Extracts the green channel value from hex color (can be mapped to custom range). + * Example: '#FF5733' with range [0,1] → 0.341 + * @param inputs Color hext + * @returns rgb color + * @group hex to + * @shortname green + * @drawable false + */ + getGreenParam(inputs: Inputs.Color.HexDtoMapped): number; + /** + * Extracts the blue channel value from hex color (can be mapped to custom range). + * Example: '#FF5733' with range [0,1] → 0.2 + * @param inputs Color hext + * @returns blue param + * @group hex to + * @shortname blue + * @drawable false + */ + getBlueParam(inputs: Inputs.Color.HexDtoMapped): number; + /** + * Extracts the red channel value from RGB object. + * Example: {r: 255, g: 87, b: 51} → 255 + * @param inputs Color rgb + * @returns red param + * @group rgb to + * @shortname red + * @drawable false + */ + rgbToRed(inputs: Inputs.Color.RGBObjectDto): number; + /** + * Extracts the green channel value from RGB object. + * Example: {r: 255, g: 87, b: 51} → 87 + * @param inputs Color rgb + * @returns green param + * @group rgb to + * @shortname green + * @drawable false + */ + rgbToGreen(inputs: Inputs.Color.RGBObjectDto): number; + /** + * Extracts the blue channel value from RGB object. + * Example: {r: 255, g: 87, b: 51} → 51 + * @param inputs Color rgb + * @returns blue param + * @group rgb to + * @shortname blue + * @drawable false + */ + rgbToBlue(inputs: Inputs.Color.RGBObjectDto): number; + /** + * Inverts a hex color (flips RGB channels: 255-r, 255-g, 255-b). + * With blackAndWhite=true → returns '#000000' or '#ffffff' based on brightness. + * Example: '#FF5733' → '#00a8cc', '#FF5733' with blackAndWhite=true → '#ffffff' + * @param inputs hex color and black and white option + * @returns inverted color + * @group hex to + * @shortname invert color + * @drawable false + */ + invert(inputs: Inputs.Color.InvertHexDto): Inputs.Base.Color; + } + /** + * Contains various date methods. + */ + declare class Dates { + /** + * Converts date to human-readable date string (excludes time). + * Example: Date(2024,0,15,14,30) → 'Mon Jan 15 2024' + * @param inputs a date + * @returns date as string + * @group convert + * @shortname date to string + * @drawable false + */ + toDateString(inputs: Inputs.Dates.DateDto): string; + /** + * Converts date to ISO 8601 format string (standard format for APIs and data interchange). + * Example: Date(2024,0,15,14,30,45) → '2024-01-15T14:30:45.000Z' + * @param inputs a date + * @returns date as string + * @group convert + * @shortname date to iso string + * @drawable false + */ + toISOString(inputs: Inputs.Dates.DateDto): string; + /** + * Converts date to JSON-compatible string (same as ISO format, used in JSON.stringify). + * Example: Date(2024,0,15,14,30) → '2024-01-15T14:30:00.000Z' + * @param inputs a date + * @returns date as string + * @group convert + * @shortname date to json + * @drawable false + */ + toJSON(inputs: Inputs.Dates.DateDto): string; + /** + * Converts date to full locale-specific string (includes date, time, and timezone). + * Example: Date(2024,0,15,14,30) → 'Mon Jan 15 2024 14:30:00 GMT+0000' + * @param inputs a date + * @returns date as string + * @group convert + * @shortname date to locale string + * @drawable false + */ + toString(inputs: Inputs.Dates.DateDto): string; + /** + * Converts date to time string (excludes date, includes timezone). + * Example: Date(2024,0,15,14,30,45) → '14:30:45 GMT+0000' + * @param inputs a date + * @returns time as string + * @group convert + * @shortname date to time string + * @drawable false + */ + toTimeString(inputs: Inputs.Dates.DateDto): string; + /** + * Converts date to UTC string format (Universal Coordinated Time, no timezone offset). + * Example: Date(2024,0,15,14,30) → 'Mon, 15 Jan 2024 14:30:00 GMT' + * @param inputs a date + * @returns date as utc string + * @group convert + * @shortname date to utc string + * @drawable false + */ + toUTCString(inputs: Inputs.Dates.DateDto): string; + /** + * Returns the current date and time at the moment of execution. + * Example: calling now() → Date object representing current moment (e.g., '2024-01-15T14:30:45') + * @returns date + * @group create + * @shortname now + * @drawable false + */ + now(): Date; + /** + * Creates a new date from individual components using local time. + * Month is 0-indexed: 0=January, 11=December. + * Example: year=2024, month=0, day=15, hours=14, minutes=30 → Date(Jan 15, 2024 14:30) + * @param inputs a date + * @returns date + * @group create + * @shortname create date + * @drawable false + */ + createDate(inputs: Inputs.Dates.CreateDateDto): Date; + /** + * Creates a new date from individual components using UTC (ignores timezone). + * Returns milliseconds since Unix epoch (Jan 1, 1970 00:00:00 UTC). + * Example: year=2024, month=0, day=15 → Date representing Jan 15, 2024 00:00 UTC + * @param inputs a date + * @returns date + * @group create + * @shortname create utc date + * @drawable false + */ + createDateUTC(inputs: Inputs.Dates.CreateDateDto): Date; + /** + * Creates a date from Unix timestamp (milliseconds since Jan 1, 1970 UTC). + * Example: unixTimeStamp=1705329000000 → Date(Jan 15, 2024 14:30:00) + * @param inputs a unix time stamp + * @returns date + * @group create + * @shortname create from unix timestamp + * @drawable false + */ + createFromUnixTimeStamp( + inputs: Inputs.Dates.CreateFromUnixTimeStampDto + ): Date; + /** + * Parses a date string and returns Unix timestamp (milliseconds since Jan 1, 1970 UTC). + * Example: dateString='2024-01-15' → 1705276800000 + * @param inputs a date string + * @returns the number of milliseconds between that date and midnight, January 1, 1970. + * @group parse + * @shortname parse date string + * @drawable false + */ + parseDate(inputs: Inputs.Dates.DateStringDto): number; + /** + * Extracts day of the month from date (1-31) using local time. + * Example: Date(2024,0,15) → 15 + * @returns date + * @group get + * @shortname get date of month + * @drawable false + */ + getDayOfMonth(inputs: Inputs.Dates.DateDto): number; + /** + * Extracts day of the week from date (0=Sunday, 6=Saturday) using local time. + * Example: Date(2024,0,15) → 1 (Monday) + * @returns day + * @group get + * @shortname get weekday + * @drawable false + */ + getWeekday(inputs: Inputs.Dates.DateDto): number; + /** + * Extracts full year from date using local time. + * Example: Date(2024,0,15) → 2024 + * @returns year + * @group get + * @shortname get year + * @drawable false + */ + getYear(inputs: Inputs.Dates.DateDto): number; + /** + * Extracts month from date (0=January, 11=December) using local time. + * Example: Date(2024,0,15) → 0 (January) + * @returns month + * @group get + * @shortname get month + * @drawable false + */ + getMonth(inputs: Inputs.Dates.DateDto): number; + /** + * Extracts hours from date (0-23) using local time. + * Example: Date(2024,0,15,14,30) → 14 + * @returns hours + * @group get + * @shortname get hours + * @drawable false + */ + getHours(inputs: Inputs.Dates.DateDto): number; + /** + * Extracts minutes from date (0-59) using local time. + * Example: Date(2024,0,15,14,30) → 30 + * @returns minutes + * @group get + * @shortname get minutes + * @drawable false + */ + getMinutes(inputs: Inputs.Dates.DateDto): number; + /** + * Extracts seconds from date (0-59) using local time. + * Example: Date(2024,0,15,14,30,45) → 45 + * @returns seconds + * @group get + * @shortname get seconds + * @drawable false + */ + getSeconds(inputs: Inputs.Dates.DateDto): number; + /** + * Extracts milliseconds from date (0-999) using local time. + * Example: Date(2024,0,15,14,30,45,123) → 123 + * @returns milliseconds + * @group get + * @shortname get milliseconds + * @drawable false + */ + getMilliseconds(inputs: Inputs.Dates.DateDto): number; + /** + * Converts date to Unix timestamp (milliseconds since Jan 1, 1970 UTC). + * Example: Date(2024,0,15,14,30) → 1705329000000 + * @returns time + * @group get + * @shortname get time + * @drawable false + */ + getTime(inputs: Inputs.Dates.DateDto): number; + /** + * Extracts full year from date using UTC (ignores timezone). + * Example: Date(2024,0,15) → 2024 + * @returns year + * @group get + * @shortname get utc year + * @drawable false + */ + getUTCYear(inputs: Inputs.Dates.DateDto): number; + /** + * Extracts month from date (0=January, 11=December) using UTC. + * Example: Date.UTC(2024,0,15) → 0 (January) + * @returns month + * @group get + * @shortname get utc month + * @drawable false + */ + getUTCMonth(inputs: Inputs.Dates.DateDto): number; + /** + * Extracts day of the month from date (1-31) using UTC. + * Example: Date.UTC(2024,0,15) → 15 + * @returns day + * @group get + * @shortname get utc day + * @drawable false + */ + getUTCDay(inputs: Inputs.Dates.DateDto): number; + /** + * Extracts hours from date (0-23) using UTC. + * Example: Date.UTC(2024,0,15,14) → 14 + * @returns hours + * @group get + * @shortname get utc hours + * @drawable false + */ + getUTCHours(inputs: Inputs.Dates.DateDto): number; + /** + * Extracts minutes from date (0-59) using UTC. + * Example: Date.UTC(2024,0,15,14,30) → 30 + * @returns minutes + * @group get + * @shortname get utc minutes + * @drawable false + */ + getUTCMinutes(inputs: Inputs.Dates.DateDto): number; + /** + * Extracts seconds from date (0-59) using UTC. + * Example: Date.UTC(2024,0,15,14,30,45) → 45 + * @returns seconds + * @group get + * @shortname get utc seconds + * @drawable false + */ + getUTCSeconds(inputs: Inputs.Dates.DateDto): number; + /** + * Extracts milliseconds from date (0-999) using UTC. + * Example: Date.UTC(2024,0,15,14,30,45,123) → 123 + * @returns milliseconds + * @group get + * @shortname get utc milliseconds + * @drawable false + */ + getUTCMilliseconds(inputs: Inputs.Dates.DateDto): number; + /** + * Creates new date with modified year (returns new date, original unchanged). + * Example: Date(2024,0,15) with year=2025 → Date(2025,0,15) + * @param inputs a date and the year + * @returns date + * @group set + * @shortname set year + * @drawable false + * */ + setYear(inputs: Inputs.Dates.DateYearDto): Date; + /** + * Creates new date with modified month (0=January, 11=December, returns new date). + * Example: Date(2024,0,15) with month=5 → Date(2024,5,15) (June 15) + * @param inputs a date and the month + * @returns date + * @group set + * @shortname set month + * @drawable false + * */ + setMonth(inputs: Inputs.Dates.DateMonthDto): Date; + /** + * Creates new date with modified day of month (1-31, returns new date). + * Example: Date(2024,0,15) with day=20 → Date(2024,0,20) + * @param inputs a date and the day + * @returns date + * @group set + * @shortname set day of month + * @drawable false + */ + setDayOfMonth(inputs: Inputs.Dates.DateDayDto): Date; + /** + * Sets the hour value in the Date object using local time. + * @param inputs a date and the hours + * @returns date + * @group set + * @shortname set hours + * @drawable false + * */ + setHours(inputs: Inputs.Dates.DateHoursDto): Date; + /** + * Sets the minutes value in the Date object using local time. + * @param inputs a date and the minutes + * @returns date + * @group set + * @shortname set minutes + * @drawable false + * */ + setMinutes(inputs: Inputs.Dates.DateMinutesDto): Date; + /** + * Sets the seconds value in the Date object using local time. + * @param inputs a date and the seconds + * @returns date + * @group set + * @shortname set seconds + * @drawable false + */ + setSeconds(inputs: Inputs.Dates.DateSecondsDto): Date; + /** + * Sets the milliseconds value in the Date object using local time. + * @param inputs a date and the milliseconds + * @returns date + * @group set + * @shortname set milliseconds + * @drawable false + */ + setMilliseconds(inputs: Inputs.Dates.DateMillisecondsDto): Date; + /** + * Sets the date and time value in the Date object. + * @param inputs a date and the time + * @returns date + * @group set + * @shortname set time + * @drawable false + */ + setTime(inputs: Inputs.Dates.DateTimeDto): Date; + /** + * Sets the year value in the Date object using Universal Coordinated Time (UTC). + * @param inputs a date and the year + * @returns date + * @group set + * @shortname set utc year + * @drawable false + * */ + setUTCYear(inputs: Inputs.Dates.DateYearDto): Date; + /** + * Sets the month value in the Date object using Universal Coordinated Time (UTC). + * @param inputs a date and the month + * @returns date + * @group set + * @shortname set utc month + * @drawable false + * */ + setUTCMonth(inputs: Inputs.Dates.DateMonthDto): Date; + /** + * Sets the numeric day of the month in the Date object using Universal Coordinated Time (UTC). + * @param inputs a date and the day + * @returns date + * @group set + * @shortname set utc day + * @drawable false + */ + setUTCDay(inputs: Inputs.Dates.DateDayDto): Date; + /** + * Sets the hours value in the Date object using Universal Coordinated Time (UTC). + * @param inputs a date and the hours + * @returns date + * @group set + * @shortname set utc hours + * @drawable false + * */ + setUTCHours(inputs: Inputs.Dates.DateHoursDto): Date; + /** + * Sets the minutes value in the Date object using Universal Coordinated Time (UTC). + * @param inputs a date and the minutes + * @returns date + * @group set + * @shortname set utc minutes + * @drawable false + * */ + setUTCMinutes(inputs: Inputs.Dates.DateMinutesDto): Date; + /** + * Sets the seconds value in the Date object using Universal Coordinated Time (UTC). + * @param inputs a date and the seconds + * @returns date + * @group set + * @shortname set utc seconds + * @drawable false + */ + setUTCSeconds(inputs: Inputs.Dates.DateSecondsDto): Date; + /** + * Sets the milliseconds value in the Date object using Universal Coordinated Time (UTC). + * @param inputs a date and the milliseconds + * @returns date + * @group set + * @shortname set utc milliseconds + * @drawable false + */ + setUTCMilliseconds(inputs: Inputs.Dates.DateMillisecondsDto): Date; + } + declare class GeometryHelper { + /** + * Applies one or more 4×4 transformation matrices to a list of points sequentially. + * Each transformation is applied in order (composition of transformations). + * Example: points=[[0,0,0], [1,0,0]] with translation [5,0,0] → [[5,0,0], [6,0,0]] + */ + transformControlPoints( + transformation: number[][] | number[][][], + transformedControlPoints: Inputs.Base.Point3[] + ): Inputs.Base.Point3[]; + /** + * Flattens nested transformation arrays into a single-level array of transformation matrices. + * Handles both 2D arrays (single transform list) and 3D arrays (nested transform lists). + * Example: [[[matrix1, matrix2]], [[matrix3]]] → [matrix1, matrix2, matrix3] + */ + getFlatTransformations( + transformation: number[][] | number[][][] + ): number[][]; + /** + * Calculates the nesting depth of an array recursively. + * Example: [1,2,3] → 1, [[1,2],[3,4]] → 2, [[[1]]] → 3 + */ + getArrayDepth: (value: any) => number; + /** + * Applies a single 4×4 transformation matrix (as flat 16-element array) to multiple points. + * Example: points=[[0,0,0], [1,0,0]] with translation matrix → transformed points + */ + transformPointsByMatrixArray( + points: Inputs.Base.Point3[], + transform: number[] + ): Inputs.Base.Point3[]; + /** + * Transforms multiple points using a transformation matrix (maps each point through the matrix). + * Example: points=[[1,0,0], [0,1,0]] with 90° rotation → [[0,1,0], [-1,0,0]] + */ + transformPointsCoordinates( + points: Inputs.Base.Point3[], + transform: number[] + ): Inputs.Base.Point3[]; + /** + * Removes all duplicate vectors from a list (works with arbitrary-length numeric vectors). + * Compares vectors using tolerance for floating-point equality. + * Example: [[1,2], [3,4], [1,2], [5,6]] with tolerance=1e-7 → [[1,2], [3,4], [5,6]] + */ + removeAllDuplicateVectors( + vectors: number[][], + tolerance?: number + ): number[][]; + /** + * Removes consecutive duplicate vectors from a list (keeps only first occurrence in each sequence). + * Optionally checks and removes duplicate if first and last vectors match. + * Example: [[1,2], [1,2], [3,4], [3,4], [5,6]] → [[1,2], [3,4], [5,6]] + */ + removeConsecutiveVectorDuplicates( + vectors: number[][], + checkFirstAndLast?: boolean, + tolerance?: number + ): number[][]; + /** + * Compares two vectors for approximate equality using tolerance (element-wise comparison). + * Returns false if vectors have different lengths. + * Example: [1.0000001, 2.0], [1.0, 2.0] with tolerance=1e-6 → true + */ + vectorsTheSame(vec1: number[], vec2: number[], tolerance: number): boolean; + /** + * Checks if two numbers are approximately equal within a tolerance. + * Example: 1.0000001, 1.0 with tolerance=1e-6 → true, 1.001, 1.0 with tolerance=1e-6 → false + */ + approxEq(num1: number, num2: number, tolerance: number): boolean; + /** + * Removes consecutive duplicate points from a list (specialized for 3D/2D points). + * Optionally checks and removes duplicate if first and last points match (for closed loops). + * Example: [[0,0,0], [0,0,0], [1,0,0], [1,0,0]] → [[0,0,0], [1,0,0]] + */ + removeConsecutivePointDuplicates( + points: Inputs.Base.Point3[], + checkFirstAndLast?: boolean, + tolerance?: number + ): Inputs.Base.Point3[]; + /** + * Checks if two points are approximately equal using tolerance (supports 2D and 3D points). + * Example: [1.0000001, 2.0, 3.0], [1.0, 2.0, 3.0] with tolerance=1e-6 → true + */ + arePointsTheSame( + pointA: Inputs.Base.Point3 | Inputs.Base.Point2, + pointB: Inputs.Base.Point3 | Inputs.Base.Point2, + tolerance: number + ): boolean; + private transformCoordinates; + } + declare class DxfGenerator { + private entityHandle; + private colorFormat; + private acadVersion; + /** + * Generate a complete DXF file content from path-based entities + */ + generateDxf(dxfInputs: Inputs.IO.DxfModelDto): string; + /** + * Generate DXF header section + */ + private generateHeader; + /** + * Generate DXF tables section (layers, line types, etc.) + */ + private generateTables; + /** + * Generate line type table + */ + private generateLineTypeTable; + /** + * Generate text style table + */ + private generateStyleTable; + /** + * Generate VPORT table (viewport configuration) + */ + private generateVportTable; + /** + * Generate VIEW table (empty but required for AC1009) + */ + private generateViewTable; + /** + * Generate UCS table (user coordinate system - empty but required for AC1009) + */ + private generateUcsTable; + /** + * Generate APPID table (application ID - required for AC1009) + */ + private generateAppidTable; + /** + * Generate DIMSTYLE table (dimension style - empty but required for AC1009) + */ + private generateDimstyleTable; + /** + * Generate blocks section (empty but required) + */ + private generateBlocks; + /** + * Generate layer table based on unique layers in all parts + */ + private generateLayerTable; + /** + * Generate DXF entities section with all path segments + */ + private generateEntities; + /** + * Generate entity for a single segment based on its type + */ + private generateSegmentEntity; + /** + * Type guard for line segments + */ + private isLineSegment; + /** + * Type guard for arc segments + */ + private isArcSegment; + /** + * Type guard for circle segments + */ + private isCircleSegment; + /** + * Type guard for polyline segments + */ + private isPolylineSegment; + /** + * Type guard for spline segments + */ + private isSplineSegment; + /** + * Generate a LINE entity + */ + private generateLineEntity; + /** + * Generate a CIRCLE entity + */ + private generateCircleEntity; + /** + * Generate an ARC entity + */ + private generateArcEntity; + /** + * Generate a LWPOLYLINE entity + */ + private generatePolylineEntity; + /** + * Generate a SPLINE entity + */ + private generateSplineEntity; + /** + * Check if polyline should be closed (first and last points are the same) + */ + private isClosedPolyline; + /** + * Get next entity handle as hex string + */ + private getNextHandle; + /** + * Convert color to DXF format + * Accepts hex color (#RRGGBB) or ACI color index (1-255) + * Returns appropriate DXF color codes based on colorFormat setting + */ + private convertColorToDxf; + /** + * Convert RGB values to nearest AutoCAD Color Index (ACI) + * Uses a simplified mapping to standard ACI colors + */ + private rgbToAciColorIndex; + } + declare class Dxf { + private dxfGenerator; + /** + * Creates a line segment definition for DXF (pass-through for validation). + * Example: start=[0,0], end=[10,5] → DXF line segment from origin to [10,5] + * @param inputs Line segment definition + * @returns Line segment DTO + * @group dxf + * @shortname line segment + * @drawable false + */ + lineSegment( + inputs: Inputs.IO.DxfLineSegmentDto + ): Inputs.IO.DxfLineSegmentDto; + /** + * Creates an arc segment definition for DXF (curved path between two points). + * Example: center=[5,5], radius=5, startAngle=0°, endAngle=90° → quarter circle arc + * @param inputs Arc segment definition + * @returns Arc segment DTO + * @group dxf + * @shortname arc segment + * @drawable false + */ + arcSegment(inputs: Inputs.IO.DxfArcSegmentDto): Inputs.IO.DxfArcSegmentDto; + /** + * Creates a circle segment definition for DXF (closed circular path). + * Example: center=[10,10], radius=5 → full circle with diameter 10 centered at [10,10] + * @param inputs Circle segment definition + * @returns Circle segment DTO + * @group dxf + * @shortname circle segment + * @drawable false + */ + circleSegment( + inputs: Inputs.IO.DxfCircleSegmentDto + ): Inputs.IO.DxfCircleSegmentDto; + /** + * Creates a polyline segment definition for DXF (connected line segments through points). + * Example: points=[[0,0], [5,0], [5,5], [0,5]] → rectangular polyline path + * @param inputs Polyline segment definition + * @returns Polyline segment DTO + * @group dxf + * @shortname polyline segment + * @drawable false + */ + polylineSegment( + inputs: Inputs.IO.DxfPolylineSegmentDto + ): Inputs.IO.DxfPolylineSegmentDto; + /** + * Creates a spline segment definition for DXF (smooth curve through control points). + * Example: controlPoints=[[0,0], [5,10], [10,0]] → smooth curved path through points + * @param inputs Spline segment definition + * @returns Spline segment DTO + * @group dxf + * @shortname spline segment + * @drawable false + */ + splineSegment( + inputs: Inputs.IO.DxfSplineSegmentDto + ): Inputs.IO.DxfSplineSegmentDto; + /** + * Creates a path from multiple segments (combines lines, arcs, circles, polylines, splines). + * Similar to OCCT wires - segments are connected to form a continuous or multi-part path. + * Example: segments=[lineSegment, arcSegment, polylineSegment] → combined path entity + * @param inputs Path definition with segments + * @returns Path DTO + * @group dxf + * @shortname path + * @drawable false + */ + path(inputs: Inputs.IO.DxfPathDto): Inputs.IO.DxfPathDto; + /** + * Creates a paths part with layer and color assignment for DXF organization. + * Groups multiple paths into a single layer with consistent styling. + * Example: paths=[path1, path2], layer="Outlines", color=red → grouped geometry + * @param inputs Paths part definition + * @returns Paths part DTO + * @group dxf + * @shortname paths part + * @drawable false + */ + pathsPart(inputs: Inputs.IO.DxfPathsPartDto): Inputs.IO.DxfPathsPartDto; + /** + * Generates a complete DXF file from paths parts (exports 2D CAD drawing format). + * Supports lines, arcs, circles, polylines, and splines organized in layered paths. + * Example: model with 3 parts on different layers → valid DXF file string for CAD software + * @param inputs DXF model definition + * @returns DXF file content as string + * @group dxf + * @shortname dxf create + * @drawable false + */ + dxfCreate(inputs: Inputs.IO.DxfModelDto): string; + } + declare class IoBitByBit { + dxf: Dxf; + constructor(); + } + /** + * Contains various methods for lines and segments. Line in bitbybit is a simple object that has start and end point properties. + * { start: [ x, y, z ], end: [ x, y, z ] } + */ + declare class Line { + private readonly vector; + private readonly point; + private readonly geometryHelper; + constructor(vector: Vector, point: Point, geometryHelper: GeometryHelper); + /** + * Extracts start point from a line. + * Example: line={start:[0,0,0], end:[10,5,0]} → [0,0,0] + * @param inputs a line + * @returns start point + * @group get + * @shortname line start point + * @drawable true + */ + getStartPoint(inputs: Inputs.Line.LineDto): Inputs.Base.Point3; + /** + * Extracts end point from a line. + * Example: line={start:[0,0,0], end:[10,5,0]} → [10,5,0] + * @param inputs a line + * @returns end point + * @group get + * @shortname line end point + * @drawable true + */ + getEndPoint(inputs: Inputs.Line.LineDto): Inputs.Base.Point3; + /** + * Calculates length (distance) of a line segment. + * Example: line={start:[0,0,0], end:[3,4,0]} → 5 (using Pythagorean theorem) + * @param inputs a line + * @returns line length + * @group get + * @shortname line length + * @drawable false + */ + length(inputs: Inputs.Line.LineDto): number; + /** + * Reverses line direction by swapping start and end points. + * Example: line={start:[0,0,0], end:[10,5,0]} → {start:[10,5,0], end:[0,0,0]} + * @param inputs a line + * @returns reversed line + * @group operations + * @shortname reversed line + * @drawable true + */ + reverse(inputs: Inputs.Line.LineDto): Inputs.Base.Line3; + /** + * Applies transformation matrix to line (rotates, scales, or translates both endpoints). + * Example: line={start:[0,0,0], end:[10,0,0]} with translation [5,5,0] → {start:[5,5,0], end:[15,5,0]} + * @param inputs a line + * @returns transformed line + * @group transforms + * @shortname transform line + * @drawable true + */ + transformLine(inputs: Inputs.Line.TransformLineDto): Inputs.Base.Line3; + /** + * Applies multiple transformations to multiple lines (one transform per line). + * Example: 3 lines with 3 different translation matrices → each line moved independently + * @param inputs lines + * @returns transformed lines + * @group transforms + * @shortname transform lines + * @drawable true + */ + transformsForLines( + inputs: Inputs.Line.TransformsLinesDto + ): Inputs.Base.Line3[]; + /** + * Creates a line from two points (line object with start and end properties). + * Example: start=[0,0,0], end=[10,5,0] → {start:[0,0,0], end:[10,5,0]} + * @param inputs start and end points of the line + * @returns line + * @group create + * @shortname line + * @drawable true + */ + create(inputs: Inputs.Line.LinePointsDto): Inputs.Base.Line3; + /** + * Creates a segment from two points (array format: [start, end]). + * Example: start=[0,0,0], end=[10,5,0] → [[0,0,0], [10,5,0]] + * @param inputs start and end points of the segment + * @returns segment + * @group create + * @shortname segment + * @drawable true + */ + createSegment(inputs: Inputs.Line.LinePointsDto): Inputs.Base.Segment3; + /** + * Calculates point at parameter t along line segment (0=start, 1=end, linear interpolation). + * Example: line={start:[0,0,0], end:[10,0,0]}, param=0.5 → [5,0,0] (midpoint) + * @param inputs line + * @returns point on line + * @group get + * @shortname point on line + * @drawable true + */ + getPointOnLine(inputs: Inputs.Line.PointOnLineDto): Inputs.Base.Point3; + /** + * Creates line segments connecting consecutive points in a list (forms a polyline path). + * Example: points=[[0,0,0], [5,0,0], [5,5,0]] → 2 lines: [0→5] and [5→5,5] + * @param inputs points + * @returns lines + * @group create + * @shortname lines between points + * @drawable true + */ + linesBetweenPoints(inputs: Inputs.Line.PointsLinesDto): Inputs.Base.Line3[]; + /** + * Creates lines by pairing corresponding start and end points from two arrays. + * Filters out zero-length lines. + * Example: starts=[[0,0,0], [5,0,0]], ends=[[0,5,0], [5,5,0]] → 2 lines connecting paired points + * @param inputs start points and end points + * @returns lines + * @group create + * @shortname start and end points to lines + * @drawable true + */ + linesBetweenStartAndEndPoints( + inputs: Inputs.Line.LineStartEndPointsDto + ): Inputs.Base.Line3[]; + /** + * Converts line object to segment array format. + * Example: {start:[0,0,0], end:[10,5,0]} → [[0,0,0], [10,5,0]] + * @param inputs line + * @returns segment + * @group convert + * @shortname line to segment + * @drawable false + */ + lineToSegment(inputs: Inputs.Line.LineDto): Inputs.Base.Segment3; + /** + * Converts multiple line objects to segment array format (batch conversion). + * Example: 3 line objects → 3 segment arrays [[start1, end1], [start2, end2], ...] + * @param inputs lines + * @returns segments + * @group convert + * @shortname lines to segments + * @drawable false + */ + linesToSegments(inputs: Inputs.Line.LinesDto): Inputs.Base.Segment3[]; + /** + * Converts segment array to line object format. + * Example: [[0,0,0], [10,5,0]] → {start:[0,0,0], end:[10,5,0]} + * @param inputs segment + * @returns line + * @group convert + * @shortname segment to line + * @drawable true + */ + segmentToLine(inputs: Inputs.Line.SegmentDto): Inputs.Base.Line3; + /** + * Converts multiple segment arrays to line object format (batch conversion). + * Example: 3 segment arrays → 3 line objects with start/end properties + * @param inputs segments + * @returns lines + * @group convert + * @shortname segments to lines + * @drawable true + */ + segmentsToLines(inputs: Inputs.Line.SegmentsDto): Inputs.Base.Line3[]; + /** + * Calculates intersection point of two lines (or segments if checkSegmentsOnly=true). + * Returns undefined if lines are parallel, skew, or segments don't overlap. + * Example: line1={start:[0,0,0], end:[10,0,0]}, line2={start:[5,-5,0], end:[5,5,0]} → [5,0,0] + * @param inputs line1 and line2 + * @returns intersection point or undefined if no intersection + * @group intersection + * @shortname line-line int + * @drawable true + */ + lineLineIntersection( + inputs: Inputs.Line.LineLineIntersectionDto + ): Inputs.Base.Point3 | undefined; + } + /** + * Contains various list methods. + */ + declare class Lists { + /** + * Gets an item from the list at a specific position using zero-based indexing. + * Example: From [10, 20, 30, 40], getting index 2 returns 30 + * @param inputs a list and an index + * @returns item + * @group get + * @shortname item by index + * @drawable false + */ + getItem(inputs: Inputs.Lists.ListItemDto): T; + /** + * Gets the first item from the list. + * Example: From [10, 20, 30, 40], returns 10 + * @param inputs a list + * @returns first item + * @group get + * @shortname first item + * @drawable false + */ + getFirstItem(inputs: Inputs.Lists.ListCloneDto): T; + /** + * Gets the last item from the list. + * Example: From [10, 20, 30, 40], returns 40 + * @param inputs a list + * @returns last item + * @group get + * @shortname last item + * @drawable false + */ + getLastItem(inputs: Inputs.Lists.ListCloneDto): T; + /** + * Randomly keeps items from the list based on a probability threshold (0 to 1). + * Example: From [1, 2, 3, 4, 5] with threshold 0.5, might return [1, 3, 5] (50% chance for each item) + * @param inputs a list and a threshold for randomization of items to remove + * @returns list with remaining items + * @group get + * @shortname random get threshold + * @drawable false + */ + randomGetThreshold(inputs: Inputs.Lists.RandomThresholdDto): T[]; + /** + * Extracts a portion of the list between start and end positions (end is exclusive). + * Example: From [10, 20, 30, 40, 50] with start=1 and end=4, returns [20, 30, 40] + * @param inputs a list and start and end indexes + * @returns sub list + * @group get + * @shortname sublist + * @drawable false + */ + getSubList(inputs: Inputs.Lists.SubListDto): T[]; + /** + * Gets every nth item from the list, starting from an optional offset position. + * Example: From [0, 1, 2, 3, 4, 5, 6, 7, 8] with nth=3 and offset=0, returns [0, 3, 6] + * Example: From [0, 1, 2, 3, 4, 5, 6, 7, 8] with nth=2 and offset=1, returns [1, 3, 5, 7] + * @param inputs a list and index + * @returns list with filtered items + * @group get + * @shortname every n-th + * @drawable false + */ + getNthItem(inputs: Inputs.Lists.GetNthItemDto): T[]; + /** + * Filters items from the list using a repeating true/false pattern. + * Example: From [0, 1, 2, 3, 4, 5] with pattern [true, true, false], returns [0, 1, 3, 4] (keeps items where pattern is true) + * @param inputs a list and index + * @returns list with filtered items + * @group get + * @shortname by pattern + * @drawable false + */ + getByPattern(inputs: Inputs.Lists.GetByPatternDto): T[]; + /** + * Merges elements from multiple lists at a specific nesting level, grouping elements by position. + * Example: From [[0, 1, 2], [3, 4, 5]] at level 0, returns [[0, 3], [1, 4], [2, 5]] + * @param inputs lists, level and flatten data + * @returns list with merged lists and flattened lists + * @group get + * @shortname merge levels + * @drawable false + */ + mergeElementsOfLists( + inputs: Inputs.Lists.MergeElementsOfLists + ): T[]; + /** + * Finds the length of the longest list among multiple lists. + * Example: From [[1, 2], [3, 4, 5, 6], [7]], returns 4 (length of [3, 4, 5, 6]) + * @param inputs a list of lists + * @returns number of max length + * @group get + * @shortname longest list length + * @drawable false + */ + getLongestListLength( + inputs: Inputs.Lists.GetLongestListLength + ): number; + /** + * Reverses the order of items in the list. + * Example: From [1, 2, 3, 4, 5], returns [5, 4, 3, 2, 1] + * @param inputs a list and an index + * @returns item + * @group edit + * @shortname reverse + * @drawable false + */ + reverse(inputs: Inputs.Lists.ListCloneDto): T[]; + /** + * Randomly rearranges all items in the list (using Fisher-Yates algorithm). + * Example: From [1, 2, 3, 4, 5], might return [3, 1, 5, 2, 4] (order varies each time) + * @param inputs a list + * @returns shuffled list + * @group edit + * @shortname shuffle + * @drawable false + */ + shuffle(inputs: Inputs.Lists.ListCloneDto): T[]; + /** + * Transposes a 2D list by swapping rows and columns (all sublists must be equal length). + * Example: From [[0, 1, 2], [3, 4, 5]], returns [[0, 3], [1, 4], [2, 5]] + * @param inputs a list of lists to flip + * @returns item + * @group edit + * @shortname flip lists + * @drawable false + */ + flipLists(inputs: Inputs.Lists.ListCloneDto): T[][]; + /** + * Splits the list into smaller lists of n elements each. + * Example: From [0, 1, 2, 3, 4, 5, 6, 7, 8] with n=3, returns [[0, 1, 2], [3, 4, 5], [6, 7, 8]] + * Example: From [0, 1, 2, 3, 4] with n=2 and keepRemainder=true, returns [[0, 1], [2, 3], [4]] + * @param inputs a list + * @returns items grouped in lists of n elements + * @group edit + * @shortname group elements + * @drawable false + */ + groupNth(inputs: Inputs.Lists.GroupListDto): T[][]; + /** + * Checks whether the list contains a specific item. + * Example: List [10, 20, 30, 40] with item 30 returns true, with item 50 returns false + * @param inputs a list and an item + * @returns true if item is in list + * @group get + * @shortname contains item + * @drawable false + */ + includes(inputs: Inputs.Lists.IncludesDto): boolean; + /** + * Finds the position (index) of the first occurrence of an item in the list. + * Example: In [10, 20, 30, 20, 40], finding 20 returns 1 (first occurrence), finding 50 returns -1 (not found) + * @param inputs a list and an item + * @returns index of the item or -1 if not found + * @group get + * @shortname find index + * @drawable false + */ + findIndex(inputs: Inputs.Lists.IncludesDto): number; + /** + * Determines the maximum nesting level (depth) of a list structure. + * Example: [1, 2, 3] has depth 1, [[1, 2], [3, 4]] has depth 2, [[[1]]] has depth 3 + * @param inputs a list + * @returns number of depth + * @group get + * @shortname max list depth + * @drawable false + */ + getListDepth(inputs: Inputs.Lists.ListCloneDto<[]>): number; + /** + * Returns the number of items in the list. + * Example: [10, 20, 30, 40, 50] returns 5, [] returns 0 + * @param inputs a length list + * @returns a number + * @group get + * @shortname list length + * @drawable false + */ + listLength(inputs: Inputs.Lists.ListCloneDto): number; + /** + * Inserts an item at a specific position in the list. + * Example: In [10, 20, 30, 40], adding 99 at index 2 gives [10, 20, 99, 30, 40] + * @param inputs a list, item and an index + * @returns list with added item + * @group add + * @shortname add item + * @drawable false + */ + addItemAtIndex(inputs: Inputs.Lists.AddItemAtIndexDto): T[]; + /** + * Inserts the same item at multiple specified positions in the list. + * Example: In [10, 20, 30], adding 99 at indexes [0, 2] gives [99, 10, 20, 99, 30] + * @param inputs a list, item and an indexes + * @returns list with added item + * @group add + * @shortname add item at indexes + * @drawable false + */ + addItemAtIndexes(inputs: Inputs.Lists.AddItemAtIndexesDto): T[]; + /** + * Inserts multiple items at corresponding positions (first item at first index, second item at second index, etc.). + * Example: In [10, 20, 30], adding items [88, 99] at indexes [1, 2] gives [10, 88, 20, 99, 30] + * @param inputs a list, items and an indexes + * @returns list with added items + * @group add + * @shortname add items + * @drawable false + */ + addItemsAtIndexes(inputs: Inputs.Lists.AddItemsAtIndexesDto): T[]; + /** + * Removes the item at a specific position in the list. + * Example: From [10, 20, 30, 40, 50], removing index 2 gives [10, 20, 40, 50] + * @param inputs a list and index + * @returns list with removed item + * @group remove + * @shortname remove item + * @drawable false + */ + removeItemAtIndex(inputs: Inputs.Lists.RemoveItemAtIndexDto): T[]; + /** + * Removes the first item from the list. + * Example: From [10, 20, 30, 40], returns [20, 30, 40] + * @param inputs a list + * @returns list with first item removed + * @group remove + * @shortname remove first item + * @drawable false + */ + removeFirstItem(inputs: Inputs.Lists.ListCloneDto): T[]; + /** + * Removes the last item from the list. + * Example: From [10, 20, 30, 40], returns [10, 20, 30] + * @param inputs a list + * @returns list with last item removed + * @group remove + * @shortname remove last item + * @drawable false + */ + removeLastItem(inputs: Inputs.Lists.ListCloneDto): T[]; + /** + * Removes an item counting from the end of the list (index 0 = last item, 1 = second-to-last, etc.). + * Example: From [10, 20, 30, 40, 50], removing index 1 from end gives [10, 20, 30, 50] (removes 40) + * @param inputs a list and index from end + * @returns list with removed item + * @group remove + * @shortname remove item from end + * @drawable false + */ + removeItemAtIndexFromEnd( + inputs: Inputs.Lists.RemoveItemAtIndexDto + ): T[]; + /** + * Removes items at multiple specified positions from the list. + * Example: From [10, 20, 30, 40, 50], removing indexes [1, 3] gives [10, 30, 50] + * @param inputs a list and indexes + * @returns list with removed items + * @group remove + * @shortname remove items + * @drawable false + */ + removeItemsAtIndexes( + inputs: Inputs.Lists.RemoveItemsAtIndexesDto + ): T[]; + /** + * Clears all items from the list, resulting in an empty list. + * Example: From [10, 20, 30, 40], returns [] + * @param inputs a list + * @returns The length is set to 0 and same array memory object is returned + * @group remove + * @shortname remove all items + * @drawable false + */ + removeAllItems(inputs: Inputs.Lists.ListDto): T[]; + /** + * Removes every nth item from the list, starting from an optional offset position. + * Example: From [0, 1, 2, 3, 4, 5, 6, 7, 8] with nth=3 and offset=0, returns [1, 2, 4, 5, 7, 8] (removes 0, 3, 6) + * @param inputs a list and index + * @returns list with removed item + * @group remove + * @shortname every n-th + * @drawable false + */ + removeNthItem(inputs: Inputs.Lists.RemoveNthItemDto): T[]; + /** + * Randomly removes items from the list based on a probability threshold (0 to 1). + * Example: From [1, 2, 3, 4, 5] with threshold 0.5, might return [2, 4] (50% chance to remove each item) + * @param inputs a list and a threshold for randomization of items to remove + * @returns list with removed items + * @group remove + * @shortname random remove threshold + * @drawable false + */ + randomRemoveThreshold(inputs: Inputs.Lists.RandomThresholdDto): T[]; + /** + * Removes duplicate numbers from the list, keeping only the first occurrence of each value. + * Example: From [1, 2, 3, 2, 4, 3, 5], returns [1, 2, 3, 4, 5] + * @param inputs a list of numbers + * @returns list with unique numbers + * @group remove + * @shortname remove duplicate numbers + * @drawable false + */ + removeDuplicateNumbers( + inputs: Inputs.Lists.RemoveDuplicatesDto + ): number[]; + /** + * Removes duplicate numbers that are within a specified tolerance range of each other. + * Example: From [1.0, 1.001, 2.0, 2.002, 3.0] with tolerance 0.01, returns [1.0, 2.0, 3.0] + * @param inputs a list of numbers and the tolerance + * @returns list with unique numbers + * @group remove + * @shortname remove duplicates tol + * @drawable false + */ + removeDuplicateNumbersTolerance( + inputs: Inputs.Lists.RemoveDuplicatesToleranceDto + ): number[]; + /** + * Removes duplicate items from the list using strict equality comparison (works with any type). + * Example: From ['a', 'b', 'c', 'a', 'd', 'b'], returns ['a', 'b', 'c', 'd'] + * @param inputs a list + * @returns list with unique items + * @group remove + * @shortname remove duplicates + * @drawable false + */ + removeDuplicates(inputs: Inputs.Lists.RemoveDuplicatesDto): T[]; + /** + * Appends an item to the end of the list. + * Example: To [10, 20, 30], adding 40 gives [10, 20, 30, 40] + * @param inputs a list and an item + * @returns list with added item + * @group add + * @shortname add item to list + * @drawable false + */ + addItem(inputs: Inputs.Lists.AddItemDto): T[]; + /** + * Adds an item to the beginning of the list. + * Example: To [10, 20, 30], prepending 5 gives [5, 10, 20, 30] + * @param inputs a list and an item + * @returns list with added item + * @group add + * @shortname prepend item to list + * @drawable false + */ + prependItem(inputs: Inputs.Lists.AddItemDto): T[]; + /** + * Adds an item either at the beginning or end of the list based on the position parameter. + * Example: To [10, 20, 30], adding 5 at 'first' gives [5, 10, 20, 30], at 'last' gives [10, 20, 30, 5] + * @param inputs a list, item and an option for first or last position + * @returns list with added item + * @group add + * @shortname item at first or last + * @drawable false + */ + addItemFirstLast(inputs: Inputs.Lists.AddItemFirstLastDto): T[]; + /** + * Combines multiple lists into a single list by joining them end-to-end. + * Example: From [[1, 2], [3, 4], [5, 6]], returns [1, 2, 3, 4, 5, 6] + * @param inputs lists to concatenate + * @returns concatenated list + * @group add + * @shortname concatenate lists + * @drawable false + */ + concatenate(inputs: Inputs.Lists.ConcatenateDto): T[]; + /** + * Creates a new empty list with no items. + * Example: Returns [] + * @returns an empty array list + * @group create + * @shortname empty list + * @drawable false + */ + createEmptyList(): []; + /** + * Creates a new list by repeating an item a specified number of times. + * Example: Repeating 5 three times returns [5, 5, 5] + * @param inputs an item to multiply + * @returns list + * @group create + * @shortname repeat + * @drawable false + */ + repeat(inputs: Inputs.Lists.MultiplyItemDto): T[]; + /** + * Repeats a pattern of items cyclically until reaching a target list length. + * Example: Pattern [1, 2, 3] with length 7 returns [1, 2, 3, 1, 2, 3, 1] + * @param inputs a list to multiply and a length limit + * @returns list + * @group create + * @shortname repeat in pattern + * @drawable false + */ + repeatInPattern(inputs: Inputs.Lists.RepeatInPatternDto): T[]; + /** + * Sorts numbers in ascending (lowest to highest) or descending (highest to lowest) order. + * Example: [5, 2, 8, 1, 9] ascending returns [1, 2, 5, 8, 9], descending returns [9, 8, 5, 2, 1] + * @param inputs a list of numbers to sort and an option for ascending or descending order + * @returns list + * @group sorting + * @shortname sort numbers + * @drawable false + */ + sortNumber(inputs: Inputs.Lists.SortDto): number[]; + /** + * Sorts text strings alphabetically in ascending (A to Z) or descending (Z to A) order. + * Example: ['dog', 'apple', 'cat', 'banana'] ascending returns ['apple', 'banana', 'cat', 'dog'] + * @param inputs a list of texts to sort and an option for ascending or descending order + * @returns list + * @group sorting + * @shortname sort texts + * @drawable false + */ + sortTexts(inputs: Inputs.Lists.SortDto): string[]; + /** + * Sorts objects by comparing numeric values of a specified property. + * Example: [{age: 30}, {age: 20}, {age: 25}] sorted by 'age' ascending returns [{age: 20}, {age: 25}, {age: 30}] + * @param inputs a list to sort, a property to sort by and an option for ascending or descending order + * @returns list + * @group sorting + * @shortname sort json objects + * @drawable false + */ + sortByPropValue(inputs: Inputs.Lists.SortJsonDto): any[]; + /** + * Combines multiple lists by alternating elements from each list (first from list1, first from list2, second from list1, etc.). + * Example: From [[0, 1, 2], [3, 4, 5]], returns [0, 3, 1, 4, 2, 5] + * @param inputs Lists to interleave + * @returns Flattened interleaved list + * @group transform + * @shortname interleave lists + * @drawable false + */ + interleave(inputs: Inputs.Lists.InterleaveDto): T[]; + } + /** + * Contains various logic methods. + */ + declare class Logic { + /** + * Creates and returns a boolean value (pass-through for boolean input). + * Example: true → true, false → false + * @param inputs a true or false boolean + * @returns boolean + * @group create + * @shortname boolean + * @drawable false + */ + boolean(inputs: Inputs.Logic.BooleanDto): boolean; + /** + * Generates a random boolean list where each value has a threshold chance of being true. + * Example: length=5, threshold=0.7 → might produce [true, true, false, true, true] + * @param inputs a length and a threshold for randomization of true values + * @returns booleans + * @group create + * @shortname random booleans + * @drawable false + */ + randomBooleans(inputs: Inputs.Logic.RandomBooleansDto): boolean[]; + /** + * Converts numbers to booleans using two thresholds with gradient randomization between them. + * Values below trueThreshold → always true, above falseThreshold → always false. + * Between thresholds → probability gradient (closer to false threshold = higher chance of false). + * Example: [0.1, 0.4, 0.6, 0.9] with thresholds [0.3, 0.7] → [true, gradient, gradient, false] + * @param inputs a length and a threshold for randomization of true values + * @returns booleans + * @group create + * @shortname 2 threshold random gradient + * @drawable false + */ + twoThresholdRandomGradient( + inputs: Inputs.Logic.TwoThresholdRandomGradientDto + ): boolean[]; + /** + * Converts numbers to booleans based on a threshold (below threshold → true, above → false). + * Can be inverted to flip the logic. + * Example: [0.3, 0.7, 0.5] with threshold=0.6 → [true, false, true] + * @param inputs a length and a threshold for randomization of true values + * @returns booleans + * @group create + * @shortname threshold boolean list + * @drawable false + */ + thresholdBooleanList( + inputs: Inputs.Logic.ThresholdBooleanListDto + ): boolean[]; + /** + * Converts numbers to booleans using multiple range thresholds (gaps define true ranges). + * Values within any gap range → true, outside all gaps → false. Can be inverted. + * Example: [0.2, 0.5, 0.8] with gaps [[0.3, 0.6], [0.7, 0.9]] → [false, true, true] + * @param inputs a length and a threshold for randomization of true values + * @returns booleans + * @group create + * @shortname threshold gaps boolean list + * @drawable false + */ + thresholdGapsBooleanList( + inputs: Inputs.Logic.ThresholdGapsBooleanListDto + ): boolean[]; + /** + * Applies NOT operator to flip a boolean value. + * Example: true → false, false → true + * @param inputs a true or false boolean + * @returns boolean + * @group edit + * @shortname not + * @drawable false + */ + not(inputs: Inputs.Logic.BooleanDto): boolean; + /** + * Applies NOT operator to flip all boolean values in a list. + * Example: [true, false, true] → [false, true, false] + * @param inputs a list of true or false booleans + * @returns booleans + * @group edit + * @shortname not list + * @drawable false + */ + notList(inputs: Inputs.Logic.BooleanListDto): boolean[]; + /** + * Compares two values using various operators (==, !=, ===, !==, <, <=, >, >=). + * Example: 5 > 3 → true, 'hello' === 'world' → false + * @param inputs two values to be compared + * @returns Result of the comparison + * @group operations + * @shortname compare + * @drawable false + */ + compare(inputs: Inputs.Logic.ComparisonDto): boolean; + /** + * Conditionally passes a value through if boolean is true, otherwise returns undefined. + * Example: value=42, boolean=true → 42, value=42, boolean=false → undefined + * @param inputs a value and a boolean value + * @returns value or undefined + * @group operations + * @shortname value gate + * @drawable false + */ + valueGate(inputs: Inputs.Logic.ValueGateDto): T | undefined; + /** + * Returns the first defined (non-undefined) value from two options (fallback pattern). + * Example: value1=42, value2=10 → 42, value1=undefined, value2=10 → 10 + * @param inputs two values + * @returns value or undefined + * @group operations + * @shortname first defined value gate + * @drawable false + */ + firstDefinedValueGate( + inputs: Inputs.Logic.TwoValueGateDto + ): T | U | undefined; + } + /** + * Contains various math methods. + */ + declare class MathBitByBit { + /** + * Creates and returns a number value (pass-through for number input). + * Example: Input 42 → 42, Input 3.14 → 3.14 + * @param inputs a number to be created + * @returns number + * @group create + * @shortname number + * @drawable false + */ + number(inputs: Inputs.Math.NumberDto): number; + /** + * Performs basic arithmetic operations on two numbers (add, subtract, multiply, divide, power, modulus). + * Example: 5 + 3 → 8, 10 % 3 → 1, 2 ^ 3 → 8 + * @param inputs two numbers and operator + * @returns Result of math operation action + * @group operations + * @shortname two numbers + * @drawable false + */ + twoNrOperation(inputs: Inputs.Math.ActionOnTwoNumbersDto): number; + /** + * Calculates the remainder after division (modulus operation). + * Example: 10 % 3 → 1, 17 % 5 → 2 + * @param inputs two numbers and operator + * @returns Result of modulus operation + * @group operations + * @shortname modulus + * @drawable false + */ + modulus(inputs: Inputs.Math.ModulusDto): number; + /** + * Rounds a number to specified decimal places. + * Example: 1.32156 with 3 decimals returns 1.322 + * @param inputs a number and decimal places + * @returns Result of rounding + * @group operations + * @shortname round to decimals + * @drawable false + */ + roundToDecimals(inputs: Inputs.Math.RoundToDecimalsDto): number; + /** + * Rounds a number to specified decimal places and removes trailing zeros. + * Example: 1.32156 with 3 decimals returns 1.322, but 1.320000001 returns 1.32, and 1.000 returns 1 + * @param inputs a number and decimal places + * @returns Result of rounding as a number without trailing zeros + * @group operations + * @shortname round trim zeros + * @drawable false + */ + roundAndRemoveTrailingZeros(inputs: Inputs.Math.RoundToDecimalsDto): number; + /** + * Performs mathematical operations on a single number (absolute, negate, sqrt, trig functions, logarithms, etc.). + * Example: sqrt(5) → 2.236, abs(-3) → 3, sin(π/2) → 1 + * @param inputs one number and operator action + * @returns Result of math operation + * @group operations + * @shortname one number + * @drawable false + */ + oneNrOperation(inputs: Inputs.Math.ActionOnOneNumberDto): number; + /** + * Maps a number from one range to another range proportionally. + * Example: 5 from [0,10] to [0,100] → 50, 0.5 from [0,1] to [-10,10] → 0 + * @param inputs one number and operator action + * @returns Result of mapping + * @group operations + * @shortname remap + * @drawable false + */ + remap(inputs: Inputs.Math.RemapNumberDto): number; + /** + * Generates a random decimal number between 0 (inclusive) and 1 (exclusive). + * Example: Outputs like 0.342, 0.891, or any value in [0, 1) + * @returns A random number between 0 and 1 + * @group generate + * @shortname random 0 - 1 + * @drawable false + */ + random(): number; + /** + * Generates a random number within a specified range (low to high). + * Example: Range [0, 10] → outputs like 3.7, 8.2, or any value between 0 and 10 + * @param inputs low and high numbers + * @returns A random number + * @group generate + * @shortname random number + * @drawable false + */ + randomNumber(inputs: Inputs.Math.RandomNumberDto): number; + /** + * Generates multiple random numbers within a specified range. + * Example: Range [0, 10] with 3 items → [2.5, 7.1, 4.8] + * @param inputs low and high numbers + * @returns A list of random numbers + * @group generate + * @shortname random numbers + * @drawable false + */ + randomNumbers(inputs: Inputs.Math.RandomNumbersDto): number[]; + /** + * Returns the mathematical constant π (pi) ≈ 3.14159. + * Example: Outputs 3.141592653589793 + * @returns A number PI + * @group generate + * @shortname π + * @drawable false + */ + pi(): number; + /** + * Formats a number as a string with a fixed number of decimal places (always shows trailing zeros). + * Example: 3.14159 with 2 decimals → '3.14', 5 with 3 decimals → '5.000' + * @param inputs a number to be rounded to decimal places + * @returns number + * @group operations + * @shortname to fixed + * @drawable false + */ + toFixed(inputs: Inputs.Math.ToFixedDto): string; + /** + * Adds two numbers together. + * Example: 5 + 3 → 8, -2 + 7 → 5 + * @param inputs two numbers + * @returns number + * @group basics + * @shortname add + * @drawable false + */ + add(inputs: Inputs.Math.TwoNumbersDto): number; + /** + * Subtracts the second number from the first. + * Example: 10 - 3 → 7, 5 - 8 → -3 + * @param inputs two numbers + * @returns number + * @group basics + * @shortname subtract + * @drawable false + */ + subtract(inputs: Inputs.Math.TwoNumbersDto): number; + /** + * Multiplies two numbers together. + * Example: 5 × 3 → 15, -2 × 4 → -8 + * @param inputs two numbers + * @returns number + * @group basics + * @shortname multiply + * @drawable false + */ + multiply(inputs: Inputs.Math.TwoNumbersDto): number; + /** + * Divides the first number by the second. + * Example: 10 ÷ 2 → 5, 7 ÷ 2 → 3.5 + * @param inputs two numbers + * @returns number + * @group basics + * @shortname divide + * @drawable false + */ + divide(inputs: Inputs.Math.TwoNumbersDto): number; + /** + * Raises the first number to the power of the second (exponentiation). + * Example: 2³ → 8, 5² → 25, 10⁻¹ → 0.1 + * @param inputs two numbers + * @returns number + * @group basics + * @shortname power + * @drawable false + */ + power(inputs: Inputs.Math.TwoNumbersDto): number; + /** + * Calculates the square root of a number. + * Example: √9 → 3, √2 → 1.414, √16 → 4 + * @param inputs a number + * @returns number + * @group basics + * @shortname sqrt + * @drawable false + */ + sqrt(inputs: Inputs.Math.NumberDto): number; + /** + * Returns the absolute value (removes negative sign, always positive or zero). + * Example: |-5| → 5, |3| → 3, |0| → 0 + * @param inputs a number + * @returns number + * @group basics + * @shortname abs + * @drawable false + */ + abs(inputs: Inputs.Math.NumberDto): number; + /** + * Rounds a number to the nearest integer. + * Example: 3.7 → 4, 2.3 → 2, 5.5 → 6 + * @param inputs a number + * @returns number + * @group basics + * @shortname round + * @drawable false + */ + round(inputs: Inputs.Math.NumberDto): number; + /** + * Rounds a number down to the nearest integer (toward negative infinity). + * Example: 3.7 → 3, -2.3 → -3, 5 → 5 + * @param inputs a number + * @returns number + * @group basics + * @shortname floor + * @drawable false + */ + floor(inputs: Inputs.Math.NumberDto): number; + /** + * Rounds a number up to the nearest integer (toward positive infinity). + * Example: 3.2 → 4, -2.8 → -2, 5 → 5 + * @param inputs a number + * @returns number + * @group basics + * @shortname ceil + * @drawable false + */ + ceil(inputs: Inputs.Math.NumberDto): number; + /** + * Negates a number (flips its sign: positive becomes negative, negative becomes positive). + * Example: 5 → -5, -3 → 3, 0 → 0 + * @param inputs a number + * @returns number + * @group basics + * @shortname negate + * @drawable false + */ + negate(inputs: Inputs.Math.NumberDto): number; + /** + * Calculates the natural logarithm (base e) of a number. + * Example: ln(2.718) → ~1, ln(7.389) → ~2, ln(1) → 0 + * @param inputs a number + * @returns number + * @group basics + * @shortname ln + * @drawable false + */ + ln(inputs: Inputs.Math.NumberDto): number; + /** + * Calculates the base 10 logarithm of a number. + * Example: log₁₀(100) → 2, log₁₀(1000) → 3, log₁₀(10) → 1 + * @param inputs a number + * @returns number + * @group basics + * @shortname log10 + * @drawable false + */ + log10(inputs: Inputs.Math.NumberDto): number; + /** + * Raises 10 to the power of the input number. + * Example: 10² → 100, 10³ → 1000, 10⁻¹ → 0.1 + * @param inputs a number + * @returns number + * @group basics + * @shortname ten pow + * @drawable false + */ + tenPow(inputs: Inputs.Math.NumberDto): number; + /** + * Calculates the sine of an angle in radians. + * Example: sin(0) → 0, sin(π/2) → 1, sin(π) → ~0 + * @param inputs a number + * @returns number + * @group basics + * @shortname sin + * @drawable false + */ + sin(inputs: Inputs.Math.NumberDto): number; + /** + * Calculates the cosine of an angle in radians. + * Example: cos(0) → 1, cos(π/2) → ~0, cos(π) → -1 + * @param inputs a number + * @returns number + * @group basics + * @shortname cos + * @drawable false + */ + cos(inputs: Inputs.Math.NumberDto): number; + /** + * Calculates the tangent of an angle in radians. + * Example: tan(0) → 0, tan(π/4) → ~1, tan(π/2) → infinity + * @param inputs a number + * @returns number + * @group basics + * @shortname tan + * @drawable false + */ + tan(inputs: Inputs.Math.NumberDto): number; + /** + * Calculates the arcsine (inverse sine) in radians, returns angle whose sine is the input. + * Example: asin(0) → 0, asin(1) → π/2 (~1.57), asin(0.5) → π/6 (~0.524) + * @param inputs a number + * @returns number + * @group basics + * @shortname asin + * @drawable false + */ + asin(inputs: Inputs.Math.NumberDto): number; + /** + * Calculates the arccosine (inverse cosine) in radians, returns angle whose cosine is the input. + * Example: acos(1) → 0, acos(0) → π/2 (~1.57), acos(-1) → π (~3.14) + * @param inputs a number + * @returns number + * @group basics + * @shortname acos + * @drawable false + */ + acos(inputs: Inputs.Math.NumberDto): number; + /** + * Calculates the arctangent (inverse tangent) in radians, returns angle whose tangent is the input. + * Example: atan(0) → 0, atan(1) → π/4 (~0.785), atan(-1) → -π/4 + * @param inputs a number + * @returns number + * @group basics + * @shortname atan + * @drawable false + */ + atan(inputs: Inputs.Math.NumberDto): number; + /** + * Calculates e raised to the power of the input (exponential function). + * Example: e⁰ → 1, e¹ → ~2.718, e² → ~7.389 + * @param inputs a number + * @returns number + * @group basics + * @shortname exp + * @drawable false + */ + exp(inputs: Inputs.Math.NumberDto): number; + /** + * Converts an angle from degrees to radians. + * Example: 180° → π (~3.14159), 90° → π/2 (~1.5708), 360° → 2π + * @param inputs a number in degrees + * @returns number + * @group basics + * @shortname deg to rad + * @drawable false + */ + degToRad(inputs: Inputs.Math.NumberDto): number; + /** + * Converts an angle from radians to degrees. + * Example: π → 180°, π/2 → 90°, 2π → 360° + * @param inputs a number in radians + * @returns number + * @group basics + * @shortname rad to deg + * @drawable false + */ + radToDeg(inputs: Inputs.Math.NumberDto): number; + /** + * Applies an easing function to interpolate smoothly between min and max values. + * Example: x=0.5 from [0,100] with easeInQuad → applies quadratic acceleration curve + * Useful for smooth animations with various acceleration/deceleration curves. + * @param inputs a number, min and max values, and ease type + * @returns number + * @group operations + * @shortname ease + * @drawable false + */ + ease(inputs: Inputs.Math.EaseDto): number; + /** + * Constrains a value between a minimum and maximum value. + * Example: clamp(5, 0, 3) returns 3, clamp(-1, 0, 3) returns 0, clamp(1.5, 0, 3) returns 1.5 + * @param inputs a number, min and max values + * @returns number clamped between min and max + * @group operations + * @shortname clamp + * @drawable false + */ + clamp(inputs: Inputs.Math.ClampDto): number; + /** + * Linear interpolation between two values using parameter t (0 to 1). + * Example: From 0 to 100 at t=0.5 → 50, From 10 to 20 at t=0.25 → 12.5 + * When t=0 returns start, when t=1 returns end. Useful for smooth transitions. + * @param inputs start value, end value, and interpolation parameter t + * @returns interpolated value + * @group operations + * @shortname lerp + * @drawable false + */ + lerp(inputs: Inputs.Math.LerpDto): number; + /** + * Calculates the interpolation parameter t for a value between start and end (reverse of lerp). + * Example: Value 5 in range [0,10] → t=0.5, Value 2.5 in range [0,10] → t=0.25 + * Returns what t value would produce the given value in a lerp. Useful for finding relative position. + * @param inputs start value, end value, and the value to find t for + * @returns interpolation parameter (typically 0-1) + * @group operations + * @shortname inverse lerp + * @drawable false + */ + inverseLerp(inputs: Inputs.Math.InverseLerpDto): number; + /** + * Hermite interpolation with smooth acceleration and deceleration (smoother than linear lerp). + * Example: x=0 → 0, x=0.5 → 0.5, x=1 → 1 (but with smooth S-curve in between) + * Input is automatically clamped to [0,1]. Output eases in and out smoothly. Great for animations. + * @param inputs a number between 0 and 1 + * @returns smoothly interpolated value + * @group operations + * @shortname smoothstep + * @drawable false + */ + smoothstep(inputs: Inputs.Math.NumberDto): number; + /** + * Returns the sign of a number: -1 for negative, 0 for zero, 1 for positive. + * Example: -5 → -1, 0 → 0, 3.14 → 1 + * Useful for determining direction or polarity. + * @param inputs a number + * @returns -1, 0, or 1 + * @group operations + * @shortname sign + * @drawable false + */ + sign(inputs: Inputs.Math.NumberDto): number; + /** + * Returns the fractional part of a number (removes integer part, keeps decimals). + * Example: 3.14 → 0.14, 5.9 → 0.9, -2.3 → 0.7 + * Useful for wrapping values and creating repeating patterns. + * @param inputs a number + * @returns fractional part (always positive) + * @group operations + * @shortname fract + * @drawable false + */ + fract(inputs: Inputs.Math.NumberDto): number; + /** + * Wraps a number within a specified range (creates repeating cycle). + * Example: 1.5 in range [0,1) → 0.5, -0.3 in range [0,1) → 0.7, 370° in range [0,360) → 10° + * Useful for angles, UVs, or any repeating domain. Like modulo but handles negatives properly. + * @param inputs a number, min and max values + * @returns wrapped value within range + * @group operations + * @shortname wrap + * @drawable false + */ + wrap(inputs: Inputs.Math.WrapDto): number; + /** + * Creates a ping-pong (back-and-forth) effect that bounces a value between 0 and length. + * The value goes from 0→length, then back length→0, repeating this cycle. + * Example: With length=1: t=0→0, t=0.5→0.5, t=1→1 (peak), t=1.5→0.5, t=2→0, t=2.5→0.5 (repeats) + * Useful for creating bouncing animations like a ball or oscillating motion. + * @param inputs time value t and length + * @returns value bouncing between 0 and length + * @group operations + * @shortname ping pong + * @drawable false + */ + pingPong(inputs: Inputs.Math.PingPongDto): number; + /** + * Moves a value toward a target by a maximum delta amount (never overshooting). + * Example: From 0 toward 10 by max 3 → 3, From 8 toward 10 by max 3 → 10 (reached) + * Useful for smooth movement with maximum speed limits. + * @param inputs current value, target value, and maximum delta + * @returns new value moved toward target + * @group operations + * @shortname move towards + * @drawable false + */ + moveTowards(inputs: Inputs.Math.MoveTowardsDto): number; + private easeInSine; + private easeOutSine; + private easeInOutSine; + private easeInQuad; + private easeOutQuad; + private easeInOutQuad; + private easeInCubic; + private easeOutCubic; + private easeInOutCubic; + private easeInQuart; + private easeOutQuart; + private easeInOutQuart; + private easeInQuint; + private easeOutQuint; + private easeInOutQuint; + private easeInExpo; + private easeOutExpo; + private easeInOutExpo; + private easeInCirc; + private easeOutCirc; + private easeInOutCirc; + private easeInBack; + private easeOutBack; + private easeInOutBack; + private easeInElastic; + private easeOutElastic; + private easeInOutElastic; + private easeInBounce; + private easeOutBounce; + private easeInOutBounce; + } + /** + * Contains various mesh helper methods that are not necessarily present in higher level CAD kernels that bitbybit is using. + */ + declare class MeshBitByBit { + private readonly vector; + private readonly polyline; + constructor(vector: Vector, polyline: Polyline); + /** + * Calculates signed distance from a point to a plane (positive=above plane, negative=below). + * Example: point=[0,5,0], plane={normal:[0,1,0], d:0} → 5 (point is 5 units above XZ plane) + * @param inputs a point and a plane + * @returns signed distance + * @group base + * @shortname signed dist to plane + * @drawable false + */ + signedDistanceToPlane( + inputs: Inputs.Mesh.SignedDistanceFromPlaneToPointDto + ): number; + /** + * Calculates plane equation from triangle vertices (normal vector and distance from origin). + * Returns undefined if triangle is degenerate (zero area, collinear points). + * Example: triangle=[[0,0,0], [1,0,0], [0,1,0]] → {normal:[0,0,1], d:0} (XY plane) + * @param inputs triangle and tolerance + * @returns triangle plane + * @group traingle + * @shortname triangle plane + * @drawable false + */ + calculateTrianglePlane( + inputs: Inputs.Mesh.TriangleToleranceDto + ): Inputs.Base.TrianglePlane3 | undefined; + /** + * Calculates intersection segment of two triangles (line segment where they cross). + * Returns undefined if triangles don't intersect, are parallel, or are coplanar. + * Example: triangle1=[[0,0,0], [2,0,0], [1,2,0]], triangle2=[[1,-1,1], [1,1,1], [1,1,-1]] → [[1,0,0], [1,1,0]] + * @param inputs first triangle, second triangle, and tolerance + * @returns intersection segment or undefined if no intersection + * @group traingle + * @shortname triangle-triangle int + * @drawable false + */ + triangleTriangleIntersection( + inputs: Inputs.Mesh.TriangleTriangleToleranceDto + ): Inputs.Base.Segment3 | undefined; + /** + * Calculates all intersection segments between two triangle meshes (pairwise triangle tests). + * Returns array of line segments where mesh surfaces intersect. + * Example: cube mesh intersecting with sphere mesh → multiple segments forming intersection curve + * @param inputs first mesh, second mesh, and tolerance + * @returns array of intersection segments + * @group mesh + * @shortname mesh-mesh int segments + * @drawable false + */ + meshMeshIntersectionSegments( + inputs: Inputs.Mesh.MeshMeshToleranceDto + ): Inputs.Base.Segment3[]; + /** + * Calculates intersection polylines between two meshes by sorting segments into connected paths. + * Segments are joined end-to-end to form continuous or closed curves. + * Example: cube-sphere intersection → closed polyline loops where surfaces meet + * @param inputs first mesh, second mesh, and tolerance + * @returns array of intersection polylines + * @group mesh + * @shortname mesh-mesh int polylines + * @drawable true + */ + meshMeshIntersectionPolylines( + inputs: Inputs.Mesh.MeshMeshToleranceDto + ): Inputs.Base.Polyline3[]; + /** + * Calculates intersection points between two meshes as point arrays (one array per polyline). + * Closed polylines have first point duplicated at end. + * Example: cube-sphere intersection → arrays of points defining intersection curves + * @param inputs first mesh, second mesh, and tolerance + * @returns array of intersection points + * @group mesh + * @shortname mesh-mesh int points + * @drawable false + */ + meshMeshIntersectionPoints( + inputs: Inputs.Mesh.MeshMeshToleranceDto + ): Inputs.Base.Point3[][]; + private computeIntersectionPoint; + } + /** + * Contains various methods for points. Point in bitbybit is simply an array containing 3 numbers for [x, y, z]. + * Because of this form Point can be interchanged with Vector, which also is an array in [x, y, z] form. + * When creating 2D points, z coordinate is simply set to 0 - [x, y, 0]. + */ + declare class Point { + private readonly geometryHelper; + private readonly transforms; + private readonly vector; + private readonly lists; + constructor( + geometryHelper: GeometryHelper, + transforms: Transforms, + vector: Vector, + lists: Lists + ); + /** + * Applies transformation matrix to a single point (rotates, scales, or translates). + * Example: point=[0,0,0] with translation [5,5,0] → [5,5,0] + * @param inputs Contains a point and the transformations to apply + * @returns Transformed point + * @group transforms + * @shortname transform point + * @drawable true + */ + transformPoint(inputs: Inputs.Point.TransformPointDto): Inputs.Base.Point3; + /** + * Applies same transformation matrix to multiple points (batch transform). + * Example: 5 points with rotation 90° → all 5 points rotated together + * @param inputs Contains points and the transformations to apply + * @returns Transformed points + * @group transforms + * @shortname transform points + * @drawable true + */ + transformPoints( + inputs: Inputs.Point.TransformPointsDto + ): Inputs.Base.Point3[]; + /** + * Applies different transformation matrices to corresponding points (one transform per point). + * Arrays must have equal length. + * Example: 3 points with 3 different translations → each point moved independently + * @param inputs Contains points and the transformations to apply + * @returns Transformed points + * @group transforms + * @shortname transforms for points + * @drawable true + */ + transformsForPoints( + inputs: Inputs.Point.TransformsForPointsDto + ): Inputs.Base.Point3[]; + /** + * Moves multiple points by a translation vector (same offset for all points). + * Example: points=[[0,0,0], [1,0,0]], translation=[5,5,0] → [[5,5,0], [6,5,0]] + * @param inputs Contains points and the translation vector + * @returns Translated points + * @group transforms + * @shortname translate points + * @drawable true + */ + translatePoints( + inputs: Inputs.Point.TranslatePointsDto + ): Inputs.Base.Point3[]; + /** + * Moves multiple points by corresponding translation vectors (one vector per point). + * Arrays must have equal length. + * Example: 3 points with 3 different vectors → each point moved by its corresponding vector + * @param inputs Contains points and the translation vector + * @returns Translated points + * @group transforms + * @shortname translate points with vectors + * @drawable true + */ + translatePointsWithVectors( + inputs: Inputs.Point.TranslatePointsWithVectorsDto + ): Inputs.Base.Point3[]; + /** + * Moves multiple points by separate X, Y, Z values (convenience method for translation). + * Example: points=[[0,0,0]], x=10, y=5, z=0 → [[10,5,0]] + * @param inputs Contains points and the translation in x y and z + * @returns Translated points + * @group transforms + * @shortname translate xyz points + * @drawable true + */ + translateXYZPoints( + inputs: Inputs.Point.TranslateXYZPointsDto + ): Inputs.Base.Point3[]; + /** + * Scales multiple points around a center point with different factors per axis. + * Example: points=[[10,0,0]], center=[5,0,0], scaleXyz=[2,1,1] → [[15,0,0]] (doubles X distance from center) + * @param inputs Contains points, center point and scale factors + * @returns Scaled points + * @group transforms + * @shortname scale points on center + * @drawable true + */ + scalePointsCenterXYZ( + inputs: Inputs.Point.ScalePointsCenterXYZDto + ): Inputs.Base.Point3[]; + /** + * Stretches multiple points along a direction from a center point (directional scaling). + * Example: points=[[10,0,0]], center=[0,0,0], direction=[1,0,0], scale=2 → [[20,0,0]] + * @param inputs Contains points, center point, direction and scale factor + * @returns Stretched points + * @group transforms + * @shortname stretch points dir from center + * @drawable true + */ + stretchPointsDirFromCenter( + inputs: Inputs.Point.StretchPointsDirFromCenterDto + ): Inputs.Base.Point3[]; + /** + * Rotates multiple points around a center point along a custom axis. + * Example: points=[[10,0,0]], center=[0,0,0], axis=[0,1,0], angle=90° → [[0,0,-10]] + * @param inputs Contains points, axis, center point and angle of rotation + * @returns Rotated points + * @group transforms + * @shortname rotate points center axis + * @drawable true + */ + rotatePointsCenterAxis( + inputs: Inputs.Point.RotatePointsCenterAxisDto + ): Inputs.Base.Point3[]; + /** + * Calculates axis-aligned bounding box containing all points (min, max, center, width, height, length). + * Example: points=[[0,0,0], [10,5,3]] → {min:[0,0,0], max:[10,5,3], center:[5,2.5,1.5], width:10, height:5, length:3} + * @param inputs Points + * @returns Bounding box of points + * @group extract + * @shortname bounding box pts + * @drawable true + */ + boundingBoxOfPoints( + inputs: Inputs.Point.PointsDto + ): Inputs.Base.BoundingBox; + /** + * Calculates distance to the nearest point in a collection. + * Example: point=[0,0,0], points=[[5,0,0], [10,0,0], [3,0,0]] → 3 (distance to [3,0,0]) + * @param inputs Point from which to measure and points to measure the distance against + * @returns Distance to closest point + * @group extract + * @shortname distance to closest pt + * @drawable false + */ + closestPointFromPointsDistance( + inputs: Inputs.Point.ClosestPointFromPointsDto + ): number; + /** + * Finds array index of the nearest point in a collection (1-based index, not 0-based). + * Example: point=[0,0,0], points=[[5,0,0], [10,0,0], [3,0,0]] → 3 (index of [3,0,0]) + * @param inputs Point from which to find the index in a collection of points + * @returns Closest point index + * @group extract + * @shortname index of closest pt + * @drawable false + */ + closestPointFromPointsIndex( + inputs: Inputs.Point.ClosestPointFromPointsDto + ): number; + /** + * Finds the nearest point in a collection to a reference point. + * Example: point=[0,0,0], points=[[5,0,0], [10,0,0], [3,0,0]] → [3,0,0] + * @param inputs Point and points collection to find the closest point in + * @returns Closest point + * @group extract + * @shortname closest pt + * @drawable true + */ + closestPointFromPoints( + inputs: Inputs.Point.ClosestPointFromPointsDto + ): Inputs.Base.Point3; + /** + * Calculates Euclidean distance between two points. + * Example: start=[0,0,0], end=[3,4,0] → 5 (using Pythagorean theorem: √(3²+4²)) + * @param inputs Coordinates of start and end points + * @returns Distance + * @group measure + * @shortname distance + * @drawable false + */ + distance(inputs: Inputs.Point.StartEndPointsDto): number; + /** + * Calculates distances from a start point to multiple end points. + * Example: start=[0,0,0], endPoints=[[3,0,0], [0,4,0], [5,0,0]] → [3, 4, 5] + * @param inputs Coordinates of start and end points + * @returns Distances + * @group measure + * @shortname distances to points + * @drawable false + */ + distancesToPoints(inputs: Inputs.Point.StartEndPointsListDto): number[]; + /** + * Duplicates a point N times (creates array with N copies of the same point). + * Example: point=[5,5,0], amountOfPoints=3 → [[5,5,0], [5,5,0], [5,5,0]] + * @param inputs The point to be multiplied and the amount of points to create + * @returns Distance + * @group transforms + * @shortname multiply point + * @drawable true + */ + multiplyPoint(inputs: Inputs.Point.MultiplyPointDto): Inputs.Base.Point3[]; + /** + * Extracts X coordinate from a point. + * Example: point=[5,10,3] → 5 + * @param inputs The point + * @returns X coordinate + * @group get + * @shortname x coord + * @drawable false + */ + getX(inputs: Inputs.Point.PointDto): number; + /** + * Extracts Y coordinate from a point. + * Example: point=[5,10,3] → 10 + * @param inputs The point + * @returns Y coordinate + * @group get + * @shortname y coord + * @drawable false + */ + getY(inputs: Inputs.Point.PointDto): number; + /** + * Extracts Z coordinate from a point. + * Example: point=[5,10,3] → 3 + * @param inputs The point + * @returns Z coordinate + * @group get + * @shortname z coord + * @drawable false + */ + getZ(inputs: Inputs.Point.PointDto): number; + /** + * Calculates centroid (average position) of multiple points. + * Example: points=[[0,0,0], [10,0,0], [10,10,0]] → [6.67,3.33,0] + * @param inputs The points + * @returns point + * @group extract + * @shortname average point + * @drawable true + */ + averagePoint(inputs: Inputs.Point.PointsDto): Inputs.Base.Point3; + /** + * Creates a 3D point from X, Y, Z coordinates. + * Example: x=10, y=5, z=3 → [10,5,3] + * @param inputs xyz information + * @returns point 3d + * @group create + * @shortname point xyz + * @drawable true + */ + pointXYZ(inputs: Inputs.Point.PointXYZDto): Inputs.Base.Point3; + /** + * Creates a 2D point from X, Y coordinates. + * Example: x=10, y=5 → [10,5] + * @param inputs xy information + * @returns point 3d + * @group create + * @shortname point xy + * @drawable false + */ + pointXY(inputs: Inputs.Point.PointXYDto): Inputs.Base.Point2; + /** + * Creates logarithmic spiral points using golden angle or custom widening factor. + * Generates natural spiral patterns common in nature (sunflower, nautilus shell). + * Example: numberPoints=100, radius=10, phi=1.618 → 100 points forming outward spiral + * @param inputs Spiral information + * @returns Specified number of points in the array along the spiral + * @group create + * @shortname spiral + * @drawable true + */ + spiral(inputs: Inputs.Point.SpiralDto): Inputs.Base.Point3[]; + /** + * Creates hexagonal grid center points on XY plane (honeycomb pattern). + * Grid size controlled by number of hexagons, not width/height. + * Example: radiusHexagon=1, nrHexagonsX=3, nrHexagonsY=3 → 9 hex centers in grid pattern + * @param inputs Information about hexagon and the grid + * @returns Points in the array on the grid + * @group create + * @shortname hex grid + * @drawable true + */ + hexGrid(inputs: Inputs.Point.HexGridCentersDto): Inputs.Base.Point3[]; + /** + * Creates hexagonal grid scaled to fit within specified width/height bounds (auto-calculates hex size). + * Returns center points and hex vertices. Supports pointy-top or flat-top orientation. + * Example: width=10, height=10, nrHexagonsInHeight=3 → hex grid filling 10×10 area with 3 rows + * @param inputs Information about the desired grid dimensions and hexagon counts. + * @returns An object containing the array of center points and an array of hexagon vertex arrays. + * @group create + * @shortname scaled hex grid to fit + * @drawable false + */ + hexGridScaledToFit( + inputs: Inputs.Point.HexGridScaledToFitDto + ): Models.Point.HexGridData; + /** + * Calculates the maximum possible fillet radius at a corner formed by two line segments + * sharing an endpoint (C), such that the fillet arc is tangent to both segments + * and lies entirely within them. + * @param inputs three points and the tolerance + * @returns the maximum fillet radius + * @group fillet + * @shortname max fillet radius + * @drawable false + */ + maxFilletRadius(inputs: Inputs.Point.ThreePointsToleranceDto): number; + /** + * Calculates the maximum possible fillet radius at a corner C, such that the fillet arc + * is tangent to both segments (P1-C, P2-C) and the tangent points lie within + * the first half of each segment (measured from C). + * @param inputs three points and the tolerance + * @returns the maximum fillet radius + * @group fillet + * @shortname max fillet radius half line + * @drawable false + */ + maxFilletRadiusHalfLine( + inputs: Inputs.Point.ThreePointsToleranceDto + ): number; + /** + * Calculates the maximum possible fillet radius at each corner of a polyline formed by + * formed by a series of points. The fillet radius is calculated for each internal + * corner and optionally for the closing corners if the polyline is closed. + * @param inputs Points, checkLastWithFirst flag, and tolerance + * @returns Array of maximum fillet radii for each corner + * @group fillet + * @shortname max fillets half line + * @drawable false + */ + maxFilletsHalfLine( + inputs: Inputs.Point.PointsMaxFilletsHalfLineDto + ): number[]; + /** + * Calculates the single safest maximum fillet radius that can be applied + * uniformly to all corners of collection of points, based on the 'half-line' constraint. + * This is determined by finding the minimum of the maximum possible fillet + * radii calculated for each individual corner. + * @param inputs Defines the points, whether it's closed, and an optional tolerance. + * @returns The smallest value from the results of pointsMaxFilletsHalfLine. + * Returns 0 if the polyline has fewer than 3 points or if any + * calculated maximum radius is 0. + * @group fillet + * @shortname safest fillet radii points + * @drawable false + */ + safestPointsMaxFilletHalfLine( + inputs: Inputs.Point.PointsMaxFilletsHalfLineDto + ): number; + /** + * Removes consecutive duplicate points from array within tolerance. + * Example: [[0,0,0], [0,0,0], [1,0,0], [1,0,0], [2,0,0]] → [[0,0,0], [1,0,0], [2,0,0]] + * @param inputs points, tolerance and check first and last + * @returns Points in the array without consecutive duplicates + * @group clean + * @shortname remove duplicates + * @drawable true + */ + removeConsecutiveDuplicates( + inputs: Inputs.Point.RemoveConsecutiveDuplicatesDto + ): Inputs.Base.Point3[]; + /** + * Calculates normal vector from three points using cross product (perpendicular to plane). + * Example: p1=[0,0,0], p2=[1,0,0], p3=[0,1,0] → [0,0,1] (pointing up from XY plane) + * @param inputs Three points and the reverse normal flag + * @returns Normal vector + * @group create + * @shortname normal from 3 points + * @drawable true + */ + normalFromThreePoints( + inputs: Inputs.Point.ThreePointsNormalDto + ): Inputs.Base.Vector3; + private closestPointFromPointData; + /** + * Checks if two points are approximately equal within tolerance (distance-based comparison). + * Example: point1=[1.0000001, 2.0, 3.0], point2=[1.0, 2.0, 3.0], tolerance=1e-6 → true + * @param inputs Two points and the tolerance + * @returns true if the points are almost equal + * @group measure + * @shortname two points almost equal + * @drawable false + */ + twoPointsAlmostEqual(inputs: Inputs.Point.TwoPointsToleranceDto): boolean; + /** + * Sorts points lexicographically (by X, then Y, then Z coordinates). + * Example: [[5,0,0], [1,0,0], [3,0,0]] → [[1,0,0], [3,0,0], [5,0,0]] + * @param inputs points + * @returns sorted points + * @group sort + * @shortname sort points + * @drawable true + */ + sortPoints(inputs: Inputs.Point.PointsDto): Inputs.Base.Point3[]; + /** + * Calculates the 6 vertices of a regular flat-top hexagon. + * @param center The center point [x, y, z]. + * @param radius The radius (distance from center to vertex). + * @returns An array of 6 Point3 vertices in counter-clockwise order. + */ + private getRegularHexagonVertices; + } + /** + * Contains various methods for polyline. Polyline in bitbybit is a simple object that has points property containing an array of points. + * { points: number[][] } + */ + declare class Polyline { + private readonly vector; + private readonly point; + private readonly line; + private readonly geometryHelper; + constructor( + vector: Vector, + point: Point, + line: Line, + geometryHelper: GeometryHelper + ); + /** + * Calculates total length of polyline by summing distances between consecutive points. + * Example: points=[[0,0,0], [3,0,0], [3,4,0]] → 3 + 4 = 7 + * @param inputs a polyline + * @returns length + * @group get + * @shortname polyline length + * @drawable false + */ + length(inputs: Inputs.Polyline.PolylineDto): number; + /** + * Counts number of points in polyline. + * Example: polyline with points=[[0,0,0], [1,0,0], [1,1,0]] → 3 + * @param inputs a polyline + * @returns nr of points + * @group get + * @shortname nr polyline points + * @drawable false + */ + countPoints(inputs: Inputs.Polyline.PolylineDto): number; + /** + * Extracts points array from polyline object. + * Example: polyline={points:[[0,0,0], [1,0,0]]} → [[0,0,0], [1,0,0]] + * @param inputs a polyline + * @returns points + * @group get + * @shortname points + * @drawable true + */ + getPoints(inputs: Inputs.Polyline.PolylineDto): Inputs.Base.Point3[]; + /** + * Reverses point order of polyline (flips direction). + * Example: points=[[0,0,0], [1,0,0], [2,0,0]] → [[2,0,0], [1,0,0], [0,0,0]] + * @param inputs a polyline + * @returns reversed polyline + * @group convert + * @shortname reverse polyline + * @drawable true + */ + reverse( + inputs: Inputs.Polyline.PolylineDto + ): Inputs.Polyline.PolylinePropertiesDto; + /** + * Applies transformation matrix to all points in polyline (rotates, scales, or translates). + * Example: polyline with 4 points, translation [5,0,0] → all points moved +5 in X direction + * @param inputs a polyline + * @returns transformed polyline + * @group transforms + * @shortname transform polyline + * @drawable true + */ + transformPolyline( + inputs: Inputs.Polyline.TransformPolylineDto + ): Inputs.Polyline.PolylinePropertiesDto; + /** + * Creates a polyline from points array with optional isClosed flag. + * Example: points=[[0,0,0], [1,0,0], [1,1,0]], isClosed=true → {points:..., isClosed:true} + * @param inputs points and info if its closed + * @returns polyline + * @group create + * @shortname polyline + * @drawable true + */ + create( + inputs: Inputs.Polyline.PolylineCreateDto + ): Inputs.Polyline.PolylinePropertiesDto; + /** + * Converts polyline to line segments (each segment as line object with start/end). + * Closed polylines include closing segment. + * Example: 3 points → 2 or 3 lines (depending on isClosed) + * @param inputs polyline + * @returns lines + * @group convert + * @shortname polyline to lines + * @drawable true + */ + polylineToLines(inputs: Inputs.Polyline.PolylineDto): Inputs.Base.Line3[]; + /** + * Converts polyline to segment arrays (each segment as [point1, point2]). + * Closed polylines include closing segment if endpoints differ. + * Example: 4 points, closed → 4 segments connecting all points in a loop + * @param inputs polyline + * @returns segments + * @group convert + * @shortname polyline to segments + * @drawable false + */ + polylineToSegments( + inputs: Inputs.Polyline.PolylineDto + ): Inputs.Base.Segment3[]; + /** + * Finds points where polyline crosses itself (self-intersection points). + * Skips adjacent segments and deduplicates close points. + * Example: figure-8 shaped polyline → returns center crossing point + * @param inputs points of self intersection + * @returns polyline + * @group intersections + * @shortname polyline self intersections + * @drawable true + */ + polylineSelfIntersection( + inputs: Inputs.Polyline.PolylineToleranceDto + ): Inputs.Base.Point3[]; + /** + * Finds intersection points between two polylines (all segment-segment crossings). + * Tests all segment pairs and deduplicates close points. + * Example: crossing polylines forming an X → returns center intersection point + * @param inputs two polylines and tolerance + * @returns points + * @group intersection + * @shortname two polyline intersection + * @drawable true + */ + twoPolylineIntersection( + inputs: Inputs.Polyline.TwoPolylinesToleranceDto + ): Inputs.Base.Point3[]; + /** + * Sorts scrambled segments into connected polylines by matching endpoints. + * Uses spatial hashing for efficient connection finding. + * Example: 10 random segments that form 2 connected paths → 2 polylines + * @param inputs segments + * @returns polylines + * @group sort + * @shortname segments to polylines + * @drawable true + */ + sortSegmentsIntoPolylines( + inputs: Inputs.Polyline.SegmentsToleranceDto + ): Inputs.Base.Polyline3[]; + /** + * Calculates the maximum possible half-line fillet radius for each corner + * of a given polyline. For a closed polyline, it includes the corners + * connecting the last segment back to the first. + * + * The calculation uses the 'half-line' constraint, meaning the fillet's + * tangent points must lie within the first half of each segment connected + * to the corner. + * + * @param inputs Defines the polyline points, whether it's closed, and an optional tolerance. + * @returns An array containing the maximum fillet radius calculated for each corner. + * The order corresponds to corners P[1]...P[n-2] for open polylines, + * and P[1]...P[n-2], P[0], P[n-1] for closed polylines. + * Returns an empty array if the polyline has fewer than 3 points. + * @group fillet + * @shortname polyline max fillet radii + * @drawable false + */ + maxFilletsHalfLine(inputs: Inputs.Polyline.PolylineToleranceDto): number[]; + /** + * Calculates the single safest maximum fillet radius that can be applied + * uniformly to all corners of a polyline, based on the 'half-line' constraint. + * This is determined by finding the minimum of the maximum possible fillet + * radii calculated for each individual corner. + * + * @param inputs Defines the polyline points, whether it's closed, and an optional tolerance. + * @returns The smallest value from the results of calculatePolylineMaxFillets. + * Returns 0 if the polyline has fewer than 3 points or if any + * calculated maximum radius is 0. + * @group fillet + * @shortname polyline safest fillet radius + * @drawable false + */ + safestFilletRadius(inputs: Inputs.Polyline.PolylineToleranceDto): number; + } + /** + * Contains various text methods. + */ + declare class TextBitByBit { + private readonly point; + constructor(point: Point); + /** + * Creates and returns a text string (pass-through for text input). + * Example: text='Hello World' → 'Hello World' + * @param inputs a text + * @returns text + * @group create + * @shortname text + * @drawable false + */ + create(inputs: Inputs.Text.TextDto): string; + /** + * Splits text into multiple pieces using a separator string. + * Example: text='apple,banana,cherry', separator=',' → ['apple', 'banana', 'cherry'] + * @param inputs a text + * @returns text + * @group transform + * @shortname split + * @drawable false + */ + split(inputs: Inputs.Text.TextSplitDto): string[]; + /** + * Replaces all occurrences of a search string with a replacement string. + * Example: text='hello hello', search='hello', replaceWith='hi' → 'hi hi' + * @param inputs a text + * @returns text + * @group transform + * @shortname replaceAll + * @drawable false + */ + replaceAll(inputs: Inputs.Text.TextReplaceDto): string; + /** + * Joins multiple items into a single text string using a separator. + * Example: list=['apple', 'banana', 'cherry'], separator=', ' → 'apple, banana, cherry' + * @param inputs a list of items + * @returns text + * @group transform + * @shortname join + * @drawable false + */ + join(inputs: Inputs.Text.TextJoinDto): string; + /** + * Transform any item to text + * @param inputs any item + * @returns text + * @group transform + * @shortname to string + * @drawable false + */ + toString(inputs: Inputs.Text.ToStringDto): string; + /** + * Transform each item in list to text + * @param inputs list of items + * @returns texts + * @group transform + * @shortname to strings + * @drawable false + */ + toStringEach(inputs: Inputs.Text.ToStringEachDto): string[]; + /** + * Formats text with placeholder values using {0}, {1}, etc. syntax. + * Example: text='Point: ({0}, {1})', values=[10, 5] → 'Point: (10, 5)' + * @param inputs a text and values + * @returns formatted text + * @group transform + * @shortname format + * @drawable false + */ + format(inputs: Inputs.Text.TextFormatDto): string; + /** + * Checks if text contains a search string. + * Example: text='hello world', search='world' → true + * @param inputs a text and search string + * @returns boolean + * @group query + * @shortname includes + * @drawable false + */ + includes(inputs: Inputs.Text.TextSearchDto): boolean; + /** + * Checks if text starts with a search string. + * Example: text='hello world', search='hello' → true + * @param inputs a text and search string + * @returns boolean + * @group query + * @shortname starts with + * @drawable false + */ + startsWith(inputs: Inputs.Text.TextSearchDto): boolean; + /** + * Checks if text ends with a search string. + * Example: text='hello world', search='world' → true + * @param inputs a text and search string + * @returns boolean + * @group query + * @shortname ends with + * @drawable false + */ + endsWith(inputs: Inputs.Text.TextSearchDto): boolean; + /** + * Returns the index of the first occurrence of a search string. + * Example: text='hello world', search='world' → 6 + * @param inputs a text and search string + * @returns index or -1 if not found + * @group query + * @shortname index of + * @drawable false + */ + indexOf(inputs: Inputs.Text.TextSearchDto): number; + /** + * Returns the index of the last occurrence of a search string. + * Example: text='hello world hello', search='hello' → 12 + * @param inputs a text and search string + * @returns index or -1 if not found + * @group query + * @shortname last index of + * @drawable false + */ + lastIndexOf(inputs: Inputs.Text.TextSearchDto): number; + /** + * Extracts a section of text between two indices. + * Example: text='hello world', start=0, end=5 → 'hello' + * @param inputs a text, start and end indices + * @returns extracted text + * @group transform + * @shortname substring + * @drawable false + */ + substring(inputs: Inputs.Text.TextSubstringDto): string; + /** + * Extracts a section of text and returns a new string. + * Example: text='hello world', start=0, end=5 → 'hello' + * @param inputs a text, start and end indices + * @returns extracted text + * @group transform + * @shortname slice + * @drawable false + */ + slice(inputs: Inputs.Text.TextSubstringDto): string; + /** + * Returns the character at the specified index. + * Example: text='hello', index=1 → 'e' + * @param inputs a text and index + * @returns character + * @group query + * @shortname char at + * @drawable false + */ + charAt(inputs: Inputs.Text.TextIndexDto): string; + /** + * Removes whitespace from both ends of text. + * Example: text=' hello ' → 'hello' + * @param inputs a text + * @returns trimmed text + * @group transform + * @shortname trim + * @drawable false + */ + trim(inputs: Inputs.Text.TextDto): string; + /** + * Removes whitespace from the start of text. + * Example: text=' hello ' → 'hello ' + * @param inputs a text + * @returns trimmed text + * @group transform + * @shortname trim start + * @drawable false + */ + trimStart(inputs: Inputs.Text.TextDto): string; + /** + * Removes whitespace from the end of text. + * Example: text=' hello ' → ' hello' + * @param inputs a text + * @returns trimmed text + * @group transform + * @shortname trim end + * @drawable false + */ + trimEnd(inputs: Inputs.Text.TextDto): string; + /** + * Pads text from the start to reach target length. + * Example: text='x', length=3, padString='a' → 'aax' + * @param inputs a text, target length and pad string + * @returns padded text + * @group transform + * @shortname pad start + * @drawable false + */ + padStart(inputs: Inputs.Text.TextPadDto): string; + /** + * Pads text from the end to reach target length. + * Example: text='x', length=3, padString='a' → 'xaa' + * @param inputs a text, target length and pad string + * @returns padded text + * @group transform + * @shortname pad end + * @drawable false + */ + padEnd(inputs: Inputs.Text.TextPadDto): string; + /** + * Converts text to uppercase. + * Example: text='hello' → 'HELLO' + * @param inputs a text + * @returns uppercase text + * @group transform + * @shortname to upper case + * @drawable false + */ + toUpperCase(inputs: Inputs.Text.TextDto): string; + /** + * Converts text to lowercase. + * Example: text='HELLO' → 'hello' + * @param inputs a text + * @returns lowercase text + * @group transform + * @shortname to lower case + * @drawable false + */ + toLowerCase(inputs: Inputs.Text.TextDto): string; + /** + * Capitalizes the first character of text. + * Example: text='hello world' → 'Hello world' + * @param inputs a text + * @returns text with first character uppercase + * @group transform + * @shortname capitalize first + * @drawable false + */ + toUpperCaseFirst(inputs: Inputs.Text.TextDto): string; + /** + * Lowercases the first character of text. + * Example: text='Hello World' → 'hello World' + * @param inputs a text + * @returns text with first character lowercase + * @group transform + * @shortname uncapitalize first + * @drawable false + */ + toLowerCaseFirst(inputs: Inputs.Text.TextDto): string; + /** + * Repeats text a specified number of times. + * Example: text='ha', count=3 → 'hahaha' + * @param inputs a text and count + * @returns repeated text + * @group transform + * @shortname repeat + * @drawable false + */ + repeat(inputs: Inputs.Text.TextRepeatDto): string; + /** + * Reverses the characters in text. + * Example: text='hello' → 'olleh' + * @param inputs a text + * @returns reversed text + * @group transform + * @shortname reverse + * @drawable false + */ + reverse(inputs: Inputs.Text.TextDto): string; + /** + * Returns the length of text. + * Example: text='hello' → 5 + * @param inputs a text + * @returns length + * @group query + * @shortname length + * @drawable false + */ + length(inputs: Inputs.Text.TextDto): number; + /** + * Checks if text is empty or only whitespace. + * Example: text=' ' → true + * @param inputs a text + * @returns boolean + * @group query + * @shortname is empty + * @drawable false + */ + isEmpty(inputs: Inputs.Text.TextDto): boolean; + /** + * Concatenates multiple text strings. + * Example: texts=['hello', ' ', 'world'] → 'hello world' + * @param inputs array of texts + * @returns concatenated text + * @group transform + * @shortname concat + * @drawable false + */ + concat(inputs: Inputs.Text.TextConcatDto): string; + /** + * Tests if text matches a regular expression pattern. + * Example: text='hello123', pattern='[0-9]+' → true + * @param inputs a text and regex pattern + * @returns boolean + * @group regex + * @shortname test regex + * @drawable false + */ + regexTest(inputs: Inputs.Text.TextRegexDto): boolean; + /** + * Matches text against a regular expression and returns matches. + * Example: text='hello123world456', pattern='[0-9]+', flags='g' → ['123', '456'] + * @param inputs a text and regex pattern + * @returns array of matches or null + * @group regex + * @shortname regex match + * @drawable false + */ + regexMatch(inputs: Inputs.Text.TextRegexDto): string[] | null; + /** + * Replaces text matching a regular expression pattern. + * Example: text='hello123world456', pattern='[0-9]+', flags='g', replaceWith='X' → 'helloXworldX' + * @param inputs a text, regex pattern, and replacement + * @returns text with replacements + * @group regex + * @shortname regex replace + * @drawable false + */ + regexReplace(inputs: Inputs.Text.TextRegexReplaceDto): string; + /** + * Searches text for a regular expression pattern and returns the index. + * Example: text='hello123', pattern='[0-9]+' → 5 + * @param inputs a text and regex pattern + * @returns index or -1 if not found + * @group regex + * @shortname regex search + * @drawable false + */ + regexSearch(inputs: Inputs.Text.TextRegexDto): number; + /** + * Splits text using a regular expression pattern. + * Example: text='a1b2c3', pattern='[0-9]+' → ['a', 'b', 'c'] + * @param inputs a text and regex pattern + * @returns array of split strings + * @group regex + * @shortname regex split + * @drawable false + */ + regexSplit(inputs: Inputs.Text.TextRegexDto): string[]; + /** + * Converts a character to vector paths (polylines) with width and height data for rendering. + * Uses simplex stroke font to generate 2D line segments representing the character shape. + * Example: char='A', height=10 → {width:8, height:10, paths:[[points forming A shape]]} + * @param inputs a text + * @returns width, height and segments as json + * @group vector + * @shortname vector char + * @drawable false + */ + vectorChar(inputs: Inputs.Text.VectorCharDto): Models.Text.VectorCharData; + /** + * Converts multi-line text to vector paths (polylines) with alignment and spacing controls. + * Supports line breaks, letter spacing, line spacing, horizontal alignment, and origin centering. + * Example: text='Hello + World', height=10, align=center → [{line1 chars}, {line2 chars}] + * @param inputs a text as string + * @returns segments + * @group vector + * @shortname vector text + * @drawable false + */ + vectorText(inputs: Inputs.Text.VectorTextDto): Models.Text.VectorTextData[]; + private vectorParamsChar; + private translateLine; + } + /** + * Transformations help to move, scale, rotate objects. You can combine multiple transformations + * for object to be placed exactly into position and orientation that you want. + * Contains various methods for transformations that represent 4x4 matrixes in flat 16 number arrays. + */ + declare class Transforms { + private readonly vector; + private readonly math; + constructor(vector: Vector, math: MathBitByBit); + /** + * Creates rotation transformations around a center point and custom axis. + * Combines translation to origin, axis rotation, then translation back. + * Example: center=[5,0,0], axis=[0,1,0], angle=90° → rotates around vertical axis through point [5,0,0] + * @param inputs Rotation around center with an axis information + * @returns array of transformations + * @group rotation + * @shortname center axis + * @drawable false + */ + rotationCenterAxis( + inputs: Inputs.Transforms.RotationCenterAxisDto + ): Base.TransformMatrixes; + /** + * Creates rotation transformations around a center point along the X axis. + * Example: center=[5,5,5], angle=90° → rotates 90° around X axis through point [5,5,5] + * @param inputs Rotation around center with an X axis information + * @returns array of transformations + * @group rotation + * @shortname center x + * @drawable false + */ + rotationCenterX( + inputs: Inputs.Transforms.RotationCenterDto + ): Base.TransformMatrixes; + /** + * Creates rotation transformations around a center point along the Y axis. + * Example: center=[0,0,0], angle=45° → rotates 45° around Y axis through origin + * @param inputs Rotation around center with an Y axis information + * @returns array of transformations + * @group rotation + * @shortname center y + * @drawable false + */ + rotationCenterY( + inputs: Inputs.Transforms.RotationCenterDto + ): Base.TransformMatrixes; + /** + * Creates rotation transformations around a center point along the Z axis. + * Example: center=[10,10,0], angle=180° → rotates 180° around Z axis through point [10,10,0] + * @param inputs Rotation around center with an Z axis information + * @returns array of transformations + * @group rotation + * @shortname center z + * @drawable false + */ + rotationCenterZ( + inputs: Inputs.Transforms.RotationCenterDto + ): Base.TransformMatrixes; + /** + * Creates rotation transformations using yaw-pitch-roll (Euler angles) around a center point. + * Yaw → Y axis rotation, Pitch → X axis rotation, Roll → Z axis rotation. + * Example: center=[0,0,0], yaw=90°, pitch=0°, roll=0° → rotates 90° around Y axis + * @param inputs Yaw pitch roll rotation information + * @returns array of transformations + * @group rotation + * @shortname yaw pitch roll + * @drawable false + */ + rotationCenterYawPitchRoll( + inputs: Inputs.Transforms.RotationCenterYawPitchRollDto + ): Base.TransformMatrixes; + /** + * Creates non-uniform scale transformation around a center point (different scale per axis). + * Example: center=[5,5,5], scaleXyz=[2,1,0.5] → doubles X, keeps Y, halves Z around point [5,5,5] + * @param inputs Scale center xyz trnansformation + * @returns array of transformations + * @group scale + * @shortname center xyz + * @drawable false + */ + scaleCenterXYZ( + inputs: Inputs.Transforms.ScaleCenterXYZDto + ): Base.TransformMatrixes; + /** + * Creates non-uniform scale transformation from origin (different scale per axis). + * Example: scaleXyz=[2,3,1] → doubles X, triples Y, keeps Z unchanged + * @param inputs Scale XYZ number array information + * @returns transformation + * @group scale + * @shortname xyz + * @drawable false + */ + scaleXYZ(inputs: Inputs.Transforms.ScaleXYZDto): Base.TransformMatrixes; + /** + * Creates directional stretch transformation that scales along a specific direction from a center point. + * Points move only along the direction vector; perpendicular plane remains unchanged. + * Example: center=[0,0,0], direction=[1,0,0], scale=2 → stretches 2× along X axis only + * @param inputs Defines the center, direction, and scale factor for the stretch. + * @returns Array of transformations: [Translate To Origin, Stretch, Translate Back]. + * @group scale + * @shortname stretch dir center + * @drawable false + */ + stretchDirFromCenter( + inputs: Inputs.Transforms.StretchDirCenterDto + ): Base.TransformMatrixes; + /** + * Creates uniform scale transformation from origin (same scale on all axes). + * Example: scale=2 → doubles size in all directions (X, Y, Z) + * @param inputs Scale Dto + * @returns transformation + * @group scale + * @shortname uniform + * @drawable false + */ + uniformScale( + inputs: Inputs.Transforms.UniformScaleDto + ): Base.TransformMatrixes; + /** + * Creates uniform scale transformation around a center point (same scale on all axes). + * Example: center=[5,5,5], scale=0.5 → halves size in all directions around point [5,5,5] + * @param inputs Scale Dto with center point information + * @returns array of transformations + * @group scale + * @shortname uniform from center + * @drawable false + */ + uniformScaleFromCenter( + inputs: Inputs.Transforms.UniformScaleFromCenterDto + ): Base.TransformMatrixes; + /** + * Creates translation transformation (moves objects in space). + * Example: translation=[10,5,0] → moves object 10 units in X, 5 in Y, 0 in Z + * @param inputs Translation information + * @returns transformation + * @group translation + * @shortname xyz + * @drawable false + */ + translationXYZ( + inputs: Inputs.Transforms.TranslationXYZDto + ): Base.TransformMatrixes; + /** + * Creates multiple translation transformations (batch move operations). + * Example: translations=[[1,0,0], [0,2,0]] → generates two transforms: move +X, move +Y + * @param inputs Translation information + * @returns transformation + * @group translations + * @shortname xyz + * @drawable false + */ + translationsXYZ( + inputs: Inputs.Transforms.TranslationsXYZDto + ): Base.TransformMatrixes[]; + /** + * Creates identity transformation matrix (no transformation - leaves objects unchanged). + * Returns 4×4 matrix: [1,0,0,0, 0,1,0,0, 0,0,1,0, 0,0,0,1] + * @returns transformation + * @group identity + * @shortname identity + * @drawable false + */ + identity(): Base.TransformMatrix; + private translation; + private scaling; + private rotationAxis; + private rotationX; + private rotationY; + private rotationZ; + private rotationYawPitchRoll; + private rotationMatrixFromQuat; + /** + * Creates a 4x4 matrix that scales along a given direction vector. + * @param direction The direction vector (will be normalized). + * @param scale The scale factor along the direction. + * @returns A 4x4 column-major transformation matrix. + */ + private stretchDirection; + } + /** + * Contains various methods for vector mathematics. Vector in bitbybit is simply an array, usually containing numbers. + * In 3D [x, y, z] form describes space, where y is the up vector. + * Because of this form Vector can be interchanged with Point, which also is an array in [x, y, z] form. + */ + declare class Vector { + private readonly math; + private readonly geometryHelper; + constructor(math: MathBitByBit, geometryHelper: GeometryHelper); + /** + * Removes all duplicate vectors from the input array (keeps only unique vectors). + * Example: [[1,2,3], [4,5,6], [1,2,3], [7,8,9]] → [[1,2,3], [4,5,6], [7,8,9]] + * @param inputs Contains vectors and a tolerance value + * @returns Array of vectors without duplicates + * @group remove + * @shortname remove all duplicates + * @drawable false + */ + removeAllDuplicateVectors( + inputs: Inputs.Vector.RemoveAllDuplicateVectorsDto + ): number[][]; + /** + * Removes consecutive duplicate vectors from the input array (only removes duplicates that appear next to each other). + * Example: [[1,2], [1,2], [3,4], [1,2]] → [[1,2], [3,4], [1,2]] (only removed consecutive duplicate) + * @param inputs Contains vectors and a tolerance value + * @returns Array of vectors without duplicates + * @group remove + * @shortname remove consecutive duplicates + * @drawable false + */ + removeConsecutiveDuplicateVectors( + inputs: Inputs.Vector.RemoveConsecutiveDuplicateVectorsDto + ): number[][]; + /** + * Checks if two vectors are the same within a given tolerance (accounts for floating point precision). + * Example: [1,2,3] vs [1.0001,2.0001,3.0001] with tolerance 0.001 → true + * @param inputs Contains two vectors and a tolerance value + * @returns Boolean indicating if vectors are the same + * @group validate + * @shortname vectors the same + * @drawable false + */ + vectorsTheSame(inputs: Inputs.Vector.VectorsTheSameDto): boolean; + /** + * Measures the angle between two vectors in degrees (always returns positive angle 0-180°). + * Example: [1,0,0] and [0,1,0] → 90° (perpendicular vectors) + * @param inputs Contains two vectors represented as number arrays + * @group angles + * @shortname angle + * @returns Number in degrees + * @drawable false + */ + angleBetween(inputs: Inputs.Vector.TwoVectorsDto): number; + /** + * Measures the normalized 2D angle between two vectors in degrees (considers direction, can be negative). + * Example: [1,0] to [0,1] → 90°, [0,1] to [1,0] → -90° + * @param inputs Contains two vectors represented as number arrays + * @returns Number in degrees + * @group angles + * @shortname angle normalized 2d + * @drawable false + */ + angleBetweenNormalized2d(inputs: Inputs.Vector.TwoVectorsDto): number; + /** + * Measures a positive angle between two vectors given the reference vector in degrees (always 0-360°). + * Example: converts negative signed angles to positive by adding 360° when needed + * @param inputs Contains information of two vectors and a reference vector + * @returns Number in degrees + * @group angles + * @shortname positive angle + * @drawable false + */ + positiveAngleBetween(inputs: Inputs.Vector.TwoVectorsReferenceDto): number; + /** + * Adds all vector xyz values together element-wise and creates a new vector. + * Example: [[1,2,3], [4,5,6], [7,8,9]] → [12,15,18] (sums each column) + * @param inputs Vectors to be added + * @returns New vector that has xyz values as sums of all the vectors + * @group sum + * @shortname add all + * @drawable false + */ + addAll(inputs: Inputs.Vector.VectorsDto): number[]; + /** + * Adds two vectors together element-wise. + * Example: [1,2,3] + [4,5,6] → [5,7,9] + * @param inputs Two vectors to be added + * @returns Number array representing vector + * @group sum + * @shortname add + * @drawable false + */ + add(inputs: Inputs.Vector.TwoVectorsDto): number[]; + /** + * Checks if the boolean array contains only true values, returns false if there's a single false. + * Example: [true, true, true] → true, [true, false, true] → false + * @param inputs Vectors to be checked + * @returns Boolean indicating if vector contains only true values + * @group sum + * @shortname all + * @drawable false + */ + all(inputs: Inputs.Vector.VectorBoolDto): boolean; + /** + * Computes the cross product of two 3D vectors (perpendicular vector to both inputs). + * Example: [1,0,0] × [0,1,0] → [0,0,1] (right-hand rule) + * @param inputs Two vectors to be crossed + * @group base + * @shortname cross + * @returns Crossed vector + * @drawable false + */ + cross(inputs: Inputs.Vector.TwoVectorsDto): number[]; + /** + * Calculates squared distance between two vectors (faster than distance, avoids sqrt). + * Example: [0,0,0] to [3,4,0] → 25 (distance 5 squared) + * @param inputs Two vectors + * @returns Number representing squared distance between two vectors + * @group distance + * @shortname dist squared + * @drawable false + */ + distSquared(inputs: Inputs.Vector.TwoVectorsDto): number; + /** + * Calculates the Euclidean distance between two vectors. + * Example: [0,0,0] to [3,4,0] → 5, [1,1] to [4,5] → 5 + * @param inputs Two vectors + * @returns Number representing distance between two vectors + * @group distance + * @shortname dist + * @drawable false + */ + dist(inputs: Inputs.Vector.TwoVectorsDto): number; + /** + * Divides each element of the vector by a scalar value. + * Example: [10,20,30] ÷ 2 → [5,10,15] + * @param inputs Contains vector and a scalar + * @returns Vector that is a result of division by a scalar + * @group base + * @shortname div + * @drawable false + */ + div(inputs: Inputs.Vector.VectorScalarDto): number[]; + /** + * Computes the domain (range) between minimum and maximum values of the vector. + * Example: [1,3,5,9] → 8 (difference between last and first: 9-1) + * @param inputs Vector information + * @returns Number representing distance between two vectors + * @group base + * @shortname domain + * @drawable false + */ + domain(inputs: Inputs.Vector.VectorDto): number; + /** + * Calculates the dot product between two vectors (measures similarity/projection). + * Example: [1,2,3] • [4,5,6] → 32 (1×4 + 2×5 + 3×6), perpendicular vectors → 0 + * @param inputs Two vectors + * @returns Number representing dot product of the vector + * @group base + * @shortname dot + * @drawable false + */ + dot(inputs: Inputs.Vector.TwoVectorsDto): number; + /** + * Checks if each element in the vector is finite and returns a boolean array. + * Example: [1, 2, Infinity, 3] → [true, true, false, true] + * @param inputs Vector with possibly infinite values + * @returns Vector array that contains boolean values for each number in the input + * vector that identifies if value is finite (true) or infinite (false) + * @group validate + * @shortname finite + * @drawable false + */ + finite(inputs: Inputs.Vector.VectorDto): boolean[]; + /** + * Checks if the vector has zero length (all elements are zero). + * Example: [0,0,0] → true, [0,0,0.001] → false + * @param inputs Vector to be checked + * @returns Boolean that identifies if vector is zero length + * @group validate + * @shortname isZero + * @drawable false + */ + isZero(inputs: Inputs.Vector.VectorDto): boolean; + /** + * Finds an interpolated vector between two vectors using a fraction (linear interpolation). + * Example: [0,0,0] to [10,10,10] at 0.5 → [5,5,5], fraction=0 → first, fraction=1 → second + * @param inputs Information for finding vector between two vectors using a fraction + * @returns Vector that is in between two vectors + * @group distance + * @shortname lerp + * @drawable false + */ + lerp(inputs: Inputs.Vector.FractionTwoVectorsDto): number[]; + /** + * Finds the maximum (largest) value in the vector. + * Example: [3, 7, 2, 9, 1] → 9 + * @param inputs Vector to be checked + * @returns Largest number in the vector + * @group extract + * @shortname max + * @drawable false + */ + max(inputs: Inputs.Vector.VectorDto): number; + /** + * Finds the minimum (smallest) value in the vector. + * Example: [3, 7, 2, 9, 1] → 1 + * @param inputs Vector to be checked + * @returns Lowest number in the vector + * @group extract + * @shortname min + * @drawable false + */ + min(inputs: Inputs.Vector.VectorDto): number; + /** + * Multiplies each element of the vector by a scalar value. + * Example: [2,3,4] × 5 → [10,15,20] + * @param inputs Vector with a scalar + * @returns Vector that results from multiplication + * @group base + * @shortname mul + * @drawable false + */ + mul(inputs: Inputs.Vector.VectorScalarDto): number[]; + /** + * Negates the vector (flips the sign of each element). + * Example: [5,-3,2] → [-5,3,-2] + * @param inputs Vector to negate + * @returns Negative vector + * @group base + * @shortname neg + * @drawable false + */ + neg(inputs: Inputs.Vector.VectorDto): number[]; + /** + * Computes the squared norm (squared magnitude/length) of the vector. + * Example: [3,4,0] → 25 (length 5 squared) + * @param inputs Vector for squared norm + * @returns Number that is squared norm + * @group base + * @shortname norm squared + * @drawable false + */ + normSquared(inputs: Inputs.Vector.VectorDto): number; + /** + * Calculates the norm (magnitude/length) of the vector. + * Example: [3,4,0] → 5, [1,0,0] → 1 + * @param inputs Vector to compute the norm + * @returns Number that is norm of the vector + * @group base + * @shortname norm + * @drawable false + */ + norm(inputs: Inputs.Vector.VectorDto): number; + /** + * Normalizes the vector into a unit vector that has a length of 1 (maintains direction, scales magnitude to 1). + * Example: [3,4,0] → [0.6,0.8,0], [10,0,0] → [1,0,0] + * @param inputs Vector to normalize + * @returns Unit vector that has length of 1 + * @group base + * @shortname normalized + * @drawable false + */ + normalized(inputs: Inputs.Vector.VectorDto): number[]; + /** + * Finds a point on a ray at a given distance from the origin along the direction vector. + * Example: Point [0,0,0] + direction [1,0,0] at distance 5 → [5,0,0] + * @param inputs Provide a point, vector and a distance for finding a point + * @returns Vector representing point on the ray + * @group base + * @shortname on ray + * @drawable false + */ + onRay(inputs: Inputs.Vector.RayPointDto): number[]; + /** + * Creates a 3D vector from x, y, z coordinates. + * Example: x=1, y=2, z=3 → [1,2,3] + * @param inputs Vector coordinates + * @returns Create a vector of xyz values + * @group create + * @shortname vector XYZ + * @drawable true + */ + vectorXYZ(inputs: Inputs.Vector.VectorXYZDto): Inputs.Base.Vector3; + /** + * Creates a 2D vector from x, y coordinates. + * Example: x=3, y=4 → [3,4] + * @param inputs Vector coordinates + * @returns Create a vector of xy values + * @group create + * @shortname vector XY + * @drawable true + */ + vectorXY(inputs: Inputs.Vector.VectorXYDto): Inputs.Base.Vector2; + /** + * Creates a vector of integers from 0 to max (exclusive). + * Example: max=5 → [0,1,2,3,4], max=3 → [0,1,2] + * @param inputs Max value for the range + * @returns Vector containing items from 0 to max + * @group create + * @shortname range + * @drawable false + */ + range(inputs: Inputs.Vector.RangeMaxDto): number[]; + /** + * Computes signed angle between two vectors using a reference vector (determines rotation direction). + * Example: Returns positive or negative angle depending on rotation direction relative to reference + * @param inputs Contains information of two vectors and a reference vector + * @returns Signed angle in degrees + * @group angles + * @shortname signed angle + * @drawable false + */ + signedAngleBetween(inputs: Inputs.Vector.TwoVectorsReferenceDto): number; + /** + * Creates a vector containing numbers from min to max at a given step increment. + * Example: min=0, max=10, step=2 → [0,2,4,6,8,10] + * @param inputs Span information containing min, max and step values + * @returns Vector containing number between min, max and increasing at a given step + * @group create + * @shortname span + * @drawable false + */ + span(inputs: Inputs.Vector.SpanDto): number[]; + /** + * Creates a vector with numbers from min to max using an easing function for non-linear distribution. + * Example: min=0, max=100, nrItems=5, ease='easeInQuad' → creates accelerating intervals + * @param inputs Span information containing min, max and ease function + * @returns Vector containing numbers between min, max and increasing in non-linear steps defined by nr of items in the vector and type + * @group create + * @shortname span ease items + * @drawable false + */ + spanEaseItems(inputs: Inputs.Vector.SpanEaseItemsDto): number[]; + /** + * Creates a vector with evenly spaced numbers from min to max with a specified number of items. + * Example: min=0, max=10, nrItems=5 → [0, 2.5, 5, 7.5, 10] + * @param inputs Span information containing min, max and step values + * @returns Vector containing number between min, max by giving nr of items + * @group create + * @shortname span linear items + * @drawable false + */ + spanLinearItems(inputs: Inputs.Vector.SpanLinearItemsDto): number[]; + /** + * Subtracts the second vector from the first element-wise. + * Example: [10,20,30] - [1,2,3] → [9,18,27] + * @param inputs Two vectors + * @returns Vector that result by subtraction two vectors + * @group base + * @shortname sub + * @drawable false + */ + sub(inputs: Inputs.Vector.TwoVectorsDto): number[]; + /** + * Sums all values in the vector and returns a single number. + * Example: [1,2,3,4] → 10, [5,10,15] → 30 + * @param inputs Vector to sum + * @returns Number that results by adding up all values in the vector + * @group base + * @shortname sum + * @drawable false + */ + sum(inputs: Inputs.Vector.VectorDto): number; + /** + * Computes the squared length (squared magnitude) of a 3D vector. + * Example: [3,4,0] → 25 (length 5 squared) + * @param inputs Vector to compute the length + * @returns Number that is squared length of the vector + * @group base + * @shortname length squared + * @drawable false + */ + lengthSq(inputs: Inputs.Vector.Vector3Dto): number; + /** + * Computes the length (magnitude) of a 3D vector. + * Example: [3,4,0] → 5, [1,0,0] → 1 + * @param inputs Vector to compute the length + * @returns Number that is length of the vector + * @group base + * @shortname length + * @drawable false + */ + length(inputs: Inputs.Vector.Vector3Dto): number; + /** + * Converts an array of stringified numbers to actual numbers. + * Example: ['1', '2.5', '3'] → [1, 2.5, 3], ['10', '-5', '0.1'] → [10, -5, 0.1] + * @param inputs Array of stringified numbers + * @returns Array of numbers + * @group create + * @shortname parse numbers + * @drawable false + */ + parseNumbers(inputs: Inputs.Vector.VectorStringDto): number[]; + } + declare class Asset { + assetManager: AssetManager; + constructor(); + /** + * Gets the asset file + * @param inputs file name to get from project assets + * @returns Blob of asset + * @group get + * @shortname cloud file + */ + getFile(inputs: Inputs.Asset.GetAssetDto): Promise; + /** + * Gets the text from asset file stored in your cloud account. + * @param inputs asset name to get from project assets + * @returns Text of asset + * @group get + * @shortname text file + */ + getTextFile(inputs: Inputs.Asset.GetAssetDto): Promise; + /** + * Gets the local asset file stored in your browser. + * @param inputs asset name to get from local assets + * @returns Blob of asset + * @group get + * @shortname local file + */ + getLocalFile(inputs: Inputs.Asset.GetAssetDto): Promise; + /** + * Gets the text from asset file stored in your browser. + * @param inputs asset name to get from local assets + * @returns Text of asset or array of texts + * @group get + * @shortname local text file + */ + getLocalTextFile( + inputs: Inputs.Asset.GetAssetDto + ): Promise; + /** + * Fetches the blob from the given url, must be CORS enabled accessible endpoint + * @param inputs url of the asset + * @returns Blob + * @group fetch + * @shortname fetch blob + */ + fetchBlob(inputs: Inputs.Asset.FetchDto): Promise; + /** + * Fetches the file from the given url, must be CORS enabled accessible endpoint + * @param inputs url of the asset + * @returns File + * @group fetch + * @shortname fetch file + */ + fetchFile(inputs: Inputs.Asset.FetchDto): Promise; + /** + * Fetches the json from the given url, must be CORS enabled accessible endpoint + * @param inputs url of the asset + * @returns JSON + * @group fetch + * @shortname fetch json + */ + fetchJSON(inputs: Inputs.Asset.FetchDto): Promise; + /** + * Fetches the json from the given url, must be CORS enabled accessible endpoint + * @param inputs url of the asset + * @returns Text + * @group fetch + * @shortname fetch text + */ + fetchText(inputs: Inputs.Asset.FetchDto): Promise; + /** + * Gets and creates the url string path to your file stored in your memory. + * @param File or a blob + * @returns URL string of a file + * @group create + * @shortname object url + */ + createObjectURL(inputs: Inputs.Asset.FileDto): string; + /** + * Gets and creates the url string paths to your files stored in your memory. + * @param Files or a blobs + * @returns URL strings for given files + * @group create + * @shortname object urls + */ + createObjectURLs(inputs: Inputs.Asset.FilesDto): string[]; + /** + * Downloads a file with the given content, extension, and content type. + * @param inputs file name, content, extension, and content type + * @group download + * @shortname download file + */ + download(inputs: Inputs.Asset.DownloadDto): void; + } + declare namespace BaseTypes { + /** + * Interval represents an object that has two properties - min and max. + */ + class IntervalDto { + /** + * Minimum value of the interval + */ + min: number; + /** + * Maximum value of the interval + */ + max: number; + } + /** + * UV usually represents 2D coordinates on 3D or 2D surfaces. It is similar to XY coordinates in planes. + */ + class UVDto { + /** + * U coordinate of the surface + */ + u: number; + /** + * V coordinate of the surface + */ + v: number; + } + /** + * Intersection result of curve curve + */ + class CurveCurveIntersection { + /** + * Point of intersection on the first curve + */ + point0: number[]; + /** + * Point of intersection on the second curve + */ + point1: number[]; + /** + * Parameter of intersection on the first curve + */ + u0: number; + /** + * Parameter of intersection on the second curve + */ + u1: number; + } + /** + * Intersection result of curve and surface + */ + class CurveSurfaceIntersection { + /** + * Parameter of intersection on the curve + */ + u: number; + /** + * UV Parameters of intersection on the surface + */ + uv: UVDto; + /** + * Point of intersection on the curve + */ + curvePoint: number[]; + /** + * Point of intersection on the surface + */ + surfacePoint: number[]; + } + /** + * Intersection point between two surfaces + */ + class SurfaceSurfaceIntersectionPoint { + /** + * UV parameters of intersection on first surface + */ + uv0: UVDto; + /** + * UV parameters of intersection on second surface + */ + uv1: UVDto; + /** + * Point of intersection + */ + point: number[]; + /** + * Distance + */ + dist: number; + } + } + /** + * Contains various CSV parsing and generation methods. + */ + declare class CSVBitByBit { + /** + * Parses CSV text to a 2D array of strings (rows and columns). + * Example: csv='a,b,c + 1,2,3' → [['a','b','c'], ['1','2','3']] + * @param inputs CSV text and parsing options + * @returns 2D array of strings + * @group parse + * @shortname parse to array + * @drawable false + */ + parseToArray(inputs: Inputs.CSV.ParseToArrayDto): string[][]; + /** + * Parses CSV text to an array of JSON objects using headers. + * Example: csv='name,age + John,30 + Jane,25', headerRow=0, dataStartRow=1 + * → [{'name':'John','age':'30'}, {'name':'Jane','age':'25'}] + * @param inputs CSV text and parsing options + * @returns Array of JSON objects + * @group parse + * @shortname parse to json + * @drawable false + */ + parseToJson>( + inputs: Inputs.CSV.ParseToJsonDto + ): T[]; + /** + * Parses CSV text to JSON using custom headers (ignores CSV headers if present). + * Example: csv='John,30 + Jane,25', headers=['name','age'] + * → [{'name':'John','age':'30'}, {'name':'Jane','age':'25'}] + * @param inputs CSV text, custom headers, and parsing options + * @returns Array of JSON objects + * @group parse + * @shortname parse to json with headers + * @drawable false + */ + parseToJsonWithHeaders>( + inputs: Inputs.CSV.ParseToJsonWithHeadersDto + ): T[]; + /** + * Queries CSV data by column/header name and returns all values in that column. + * Example: csv='name,age + John,30 + Jane,25', column='name' → ['John', 'Jane'] + * @param inputs CSV text, column name, and parsing options + * @returns Array of values from the specified column + * @group query + * @shortname query column + * @drawable false + */ + queryColumn>( + inputs: Inputs.CSV.QueryColumnDto + ): (string | number)[]; + /** + * Queries CSV data and filters rows where a column matches a value. + * Example: csv='name,age + John,30 + Jane,25', column='age', value='30' → [{'name':'John','age':'30'}] + * @param inputs CSV text, column name, value, and parsing options + * @returns Array of matching rows as JSON objects + * @group query + * @shortname query rows by value + * @drawable false + */ + queryRowsByValue>( + inputs: Inputs.CSV.QueryRowsByValueDto + ): T[]; + /** + * Converts a 2D array to CSV text. + * Example: array=[['name','age'], ['John','30']] → 'name,age + John,30' + * @param inputs 2D array and formatting options + * @returns CSV text + * @group generate + * @shortname array to csv + * @drawable false + */ + arrayToCsv(inputs: Inputs.CSV.ArrayToCsvDto): string; + /** + * Converts an array of JSON objects to CSV text. + * Example: json=[{'name':'John','age':'30'}], headers=['name','age'] → 'name,age + John,30' + * @param inputs JSON array, headers, and formatting options + * @returns CSV text + * @group generate + * @shortname json to csv + * @drawable false + */ + jsonToCsv>( + inputs: Inputs.CSV.JsonToCsvDto + ): string; + /** + * Converts an array of JSON objects to CSV text using object keys as headers. + * Example: json=[{'name':'John','age':'30'}] → 'name,age + John,30' + * @param inputs JSON array and formatting options + * @returns CSV text + * @group generate + * @shortname json to csv auto + * @drawable false + */ + jsonToCsvAuto>( + inputs: Inputs.CSV.JsonToCsvAutoDto + ): string; + /** + * Gets the headers from a CSV file. + * Example: csv='name,age + John,30', headerRow=0 → ['name', 'age'] + * @param inputs CSV text and options + * @returns Array of header names + * @group query + * @shortname get headers + * @drawable false + */ + getHeaders(inputs: Inputs.CSV.GetHeadersDto): string[]; + /** + * Gets the number of rows in a CSV file (excluding headers if specified). + * Example: csv='name,age + John,30 + Jane,25', headerRow=0 → 2 + * @param inputs CSV text and options + * @returns Number of data rows + * @group query + * @shortname row count + * @drawable false + */ + getRowCount(inputs: Inputs.CSV.GetRowCountDto): number; + /** + * Gets the number of columns in a CSV file. + * Example: csv='name,age,city + John,30,NYC' → 3 + * @param inputs CSV text and options + * @returns Number of columns + * @group query + * @shortname column count + * @drawable false + */ + getColumnCount(inputs: Inputs.CSV.ParseToArrayDto): number; + private parseCsvLine; + private escapeCsvCell; + /** + * Converts literal escape sequence strings to their actual characters. + * For example, converts "\n" (two characters) to " + " (newline character). + */ + private convertEscapeSequences; + } + /** + * Contains various json path methods. + */ + declare class JSONBitByBit { + private readonly context; + constructor(context: ContextBase); + /** + * Stringifies the input value + * @param inputs a value to be stringified + * @returns string + * @group transform + * @shortname stringify + * @drawable false + */ + stringify(inputs: Inputs.JSON.StringifyDto): string; + /** + * Parses the input value + * @param inputs a value to be parsed + * @returns any + * @group transform + * @shortname parse + * @drawable false + */ + parse(inputs: Inputs.JSON.ParseDto): any; + /** + * Queries the input value + * @param inputs a value to be queried + * @returns any + * @group jsonpath + * @shortname query + * @drawable false + */ + query(inputs: Inputs.JSON.QueryDto): any; + /** + * Sets value on given property of the given json + * @param inputs a value to be added, json and a property name + * @returns any + * @group props + * @shortname set value on property + * @drawable false + */ + setValueOnProp(inputs: Inputs.JSON.SetValueOnPropDto): any; + /** + * Gets json from array by first property match. This is very simplistic search and only returns the first match. + * If you need more complex search, you can use jsonpath query with filters. + * @param inputs an array of json objects, a property name and a value to match + * @returns any + * @group props + * @shortname get json from array by prop match + * @drawable false + */ + getJsonFromArrayByFirstPropMatch( + inputs: Inputs.JSON.GetJsonFromArrayByFirstPropMatchDto + ): any; + /** + * Gets value of the property in the given json + * @param inputs a value to be added, json and a property name + * @returns any + * @group props + * @shortname get value on property + * @drawable false + */ + getValueOnProp(inputs: Inputs.JSON.GetValueOnPropDto): any; + /** + * Sets value to the json by providing a path + * @param inputs a value to be added, json and a path + * @returns any + * @group jsonpath + * @shortname set value on path + * @drawable false + */ + setValue(inputs: Inputs.JSON.SetValueDto): any; + /** + * Sets multiple values to the json by providing paths + * @param inputs a value to be added, json and a path + * @returns any + * @group jsonpath + * @shortname set values on paths + * @drawable false + */ + setValuesOnPaths(inputs: Inputs.JSON.SetValuesOnPathsDto): any; + /** + * Find paths to elements in object matching path expression + * @param inputs a json value and a query + * @returns any + * @group jsonpath + * @shortname paths + * @drawable false + */ + paths(inputs: Inputs.JSON.PathsDto): any; + /** + * Creates an empty JavaScript object + * @returns any + * @group create + * @shortname empty + * @drawable false + */ + createEmpty(): any; + /** + * Previews json and gives option to save it + * @returns any + * @group preview + * @shortname json preview and save + * @drawable false + */ + previewAndSaveJson(inputs: Inputs.JSON.JsonDto): void; + /** + * Previews json + * @returns any + * @group preview + * @shortname json preview + * @drawable false + */ + previewJson(inputs: Inputs.JSON.JsonDto): void; + } + declare class OCCTWIO extends OCCTIO { + readonly occWorkerManager: OCCTWorkerManager; + private readonly context; + constructor(occWorkerManager: OCCTWorkerManager, context: ContextBase); + /** + * Imports the step or iges asset file + * @group io + * @shortname load step | iges + * @returns OCCT Shape + */ + loadSTEPorIGES( + inputs: Inputs.OCCT.ImportStepIgesDto + ): Promise; + /** + * Imports the step or iges asset file from text + * @group io + * @shortname load text step | iges + * @returns OCCT Shape + */ + loadSTEPorIGESFromText( + inputs: Inputs.OCCT.ImportStepIgesFromTextDto + ): Promise; + } + /** + * Contains various methods for OpenCascade implementation + */ + declare class OCCTW extends OCCT { + readonly context: ContextBase; + readonly occWorkerManager: OCCTWorkerManager; + readonly io: OCCTWIO; + constructor(context: ContextBase, occWorkerManager: OCCTWorkerManager); + } + /** + * Tags help you to put text on top of your 3D objects. Tags are heavily used in data visualization scenarios + * where you need to convery additional textual information. + */ + declare class Tag { + private readonly context; + constructor(context: ContextBase); + /** + * Creates a tag dto + * @param inputs Tag description + * @returns A tag + */ + create(inputs: Inputs.Tag.TagDto): Inputs.Tag.TagDto; + /** + * Draws a single tag + * @param inputs Information to draw the tag + * @returns A tag + * @ignore true + */ + drawTag(inputs: Inputs.Tag.DrawTagDto): Inputs.Tag.TagDto; + /** + * Draws multiple tags + * @param inputs Information to draw the tags + * @returns Tags + * @ignore true + */ + drawTags(inputs: Inputs.Tag.DrawTagsDto): Inputs.Tag.TagDto[]; + } + /** + * Time functions help to create various interactions which happen in time + */ + declare class Time { + private context; + constructor(context: ContextBase); + /** + * Registers a function to render loop + * @param update The function to call in render loop + */ + registerRenderFunction(update: (timePassedMs: number) => void): void; + } + /** + * Contains various methods for nurbs circle. + * These methods wrap around Verbnurbs library that you can find here http://verbnurbs.com/. + * Thanks Peter Boyer for his work. + */ + declare class VerbCurveCircle { + private readonly context; + private readonly math; + constructor(context: ContextBase, math: MathBitByBit); + /** + * Creates the circle Nurbs curve + * @param inputs Circle parameters + * @returns Circle Nurbs curve + */ + createCircle(inputs: Inputs.Verb.CircleParametersDto): any; + /** + * Creates the arc Nurbs curve + * @param inputs Arc parameters + * @returns Arc Nurbs curve + */ + createArc(inputs: Inputs.Verb.ArcParametersDto): any; + /** + * Gets the center point of the circle or an arc + * @param inputs An arc or a circle Nurbs curve + * @returns Point + */ + center(inputs: Inputs.Verb.CircleDto): number[]; + /** + * Gets the radius of the circle or an arc + * @param inputs An arc or a circle Nurbs curve + * @returns Radius + */ + radius(inputs: Inputs.Verb.CircleDto): number; + /** + * Gets the max angle of the arc in degrees + * @param inputs Arc + * @returns Max angle in degrees + */ + maxAngle(inputs: Inputs.Verb.CircleDto): number; + /** + * Gets the min angle of the arc in degrees + * @param inputs Arc + * @returns Min angle in degrees + */ + minAngle(inputs: Inputs.Verb.CircleDto): number; + /** + * Gets the x angle of the arc + * @param inputs Circle + * @returns X axis vector + */ + xAxis(inputs: Inputs.Verb.CircleDto): number[]; + /** + * Gets the y angle of the arc + * @param inputs Circle + * @returns Y axis vector + */ + yAxis(inputs: Inputs.Verb.CircleDto): number[]; + } + /** + * Contains various methods for nurbs ellipse. + * These methods wrap around Verbnurbs library that you can find here http://verbnurbs.com/. + * Thanks Peter Boyer for his work. + */ + declare class VerbCurveEllipse { + private readonly context; + private readonly math; + constructor(context: ContextBase, math: MathBitByBit); + /** + * Creates the ellipse Nurbs curve + * @param inputs Ellipse parameters + * @returns Ellipse Nurbs curve + */ + createEllipse(inputs: Inputs.Verb.EllipseParametersDto): any; + /** + * Creates the ellipse arc Nurbs curve + * @param inputs Ellipse arc parameters + * @returns Ellipse arc Nurbs curve + */ + createArc(inputs: Inputs.Verb.EllipseArcParametersDto): any; + /** + * Gets the center point of the ellipse or an arc + * @param inputs The arc or the ellipse Nurbs curve + * @returns Point + */ + center(inputs: Inputs.Verb.EllipseDto): number[]; + /** + * Gets the max angle of the arc in degrees + * @param inputs Arc + * @returns Max angle in degrees + */ + maxAngle(inputs: Inputs.Verb.EllipseDto): number; + /** + * Gets the min angle of the arc in degrees + * @param inputs Arc + * @returns Min angle in degrees + */ + minAngle(inputs: Inputs.Verb.EllipseDto): number; + /** + * Gets the x angle of the arc or an ellipse + * @param inputs Ellipse or an arc + * @returns X axis vector + */ + xAxis(inputs: Inputs.Verb.EllipseDto): number[]; + /** + * Gets the y angle of the arc or an ellipse + * @param inputs Ellipse or an arc + * @returns Y axis vector + */ + yAxis(inputs: Inputs.Verb.EllipseDto): number[]; + } + /** + * Contains various methods for nurbs curves. + * These methods wrap around Verbnurbs library that you can find here http://verbnurbs.com/. + * Thanks Peter Boyer for his work. + */ + declare class VerbCurve { + private readonly context; + private readonly geometryHelper; + private readonly math; + readonly circle: VerbCurveCircle; + readonly ellipse: VerbCurveEllipse; + constructor( + context: ContextBase, + geometryHelper: GeometryHelper, + math: MathBitByBit + ); + /** + * Creates a Nurbs curve by providing knots, control points & weights + * @param inputs Contains knots, control points and weights + * @returns Nurbs curve + */ + createCurveByKnotsControlPointsWeights( + inputs: Inputs.Verb.CurveNurbsDataDto + ): any; + /** + * Creates a Nurbs curve by providing control points + * @param inputs Control points + * @returns Nurbs curve + */ + createCurveByPoints(inputs: Inputs.Verb.CurvePathDataDto): any; + /** + * Converts lines to NURBS curves + * Returns array of the verbnurbs Line objects + * @param inputs Lines to be transformed to curves + * @returns Verb nurbs curves + */ + convertLinesToNurbsCurves(inputs: Inputs.Verb.LinesDto): any[]; + /** + * Converts line to NURBS curve + * Returns the verbnurbs Line object + * @param inputs Line to be transformed to curve + * @returns Verb nurbs curves + */ + convertLineToNurbsCurve(inputs: Inputs.Verb.LineDto): any; + /** + * Converts a polyline to a NURBS curve + * Returns the verbnurbs NurbsCurve object + * @param inputs Polyline to be transformed to curve + * @returns Verb nurbs curve + */ + convertPolylineToNurbsCurve(inputs: Inputs.Verb.PolylineDto): any; + /** + * Converts a polylines to a NURBS curves + * Returns the verbnurbs NurbsCurve objects + * @param inputs Polylines to be transformed to curves + * @returns Verb nurbs curves + */ + convertPolylinesToNurbsCurves(inputs: Inputs.Verb.PolylinesDto): any[]; + /** + * Creates a Bezier Nurbs curve by providing control points and weights + * @param inputs Control points + * @returns Bezier Nurbs curve + */ + createBezierCurve(inputs: Inputs.Verb.BezierCurveDto): any; + /** + * Clone the Nurbs curve + * @param inputs Nurbs curve + * @returns Nurbs curve + */ + clone(inputs: Inputs.Verb.CurveDto): any; + /** + * Finds the closest param on the Nurbs curve from the point + * @param inputs Nurbs curve with point + * @returns Param number + */ + closestParam(inputs: Inputs.Verb.ClosestPointDto): number; + /** + * Finds the closest params on the Nurbs curve from the points + * @param inputs Nurbs curve with points + * @returns Param numbers + */ + closestParams(inputs: Inputs.Verb.ClosestPointsDto): number[]; + /** + * Finds the closest point on the Nurbs curve from the point + * @param inputs Nurbs curve with point + * @returns Point + */ + closestPoint(inputs: Inputs.Verb.ClosestPointDto): Inputs.Base.Point3; + /** + * Finds the closest points on the Nurbs curve from the list of points + * @param inputs Nurbs curve with points + * @returns Points + */ + closestPoints(inputs: Inputs.Verb.ClosestPointsDto): Inputs.Base.Point3[]; + /** + * Finds the control points of the Nurbs curve + * @param inputs Nurbs curve + * @returns Points + */ + controlPoints(inputs: Inputs.Verb.CurveDto): Inputs.Base.Point3[]; + /** + * Finds the degree of the Nurbs curve + * @param inputs Nurbs curve + * @returns Degree number + */ + degree(inputs: Inputs.Verb.CurveDto): number; + /** + * Finds the derivatives of the Nurbs curve at parameter + * @param inputs Nurbs curve with specified derivative number and parameter + * @returns Derivatives + */ + derivatives(inputs: Inputs.Verb.CurveDerivativesDto): number[]; + /** + * Divides the curve by equal arc length to parameters + * @param inputs Nurbs curve + * @returns Parameters + */ + divideByEqualArcLengthToParams( + inputs: Inputs.Verb.CurveSubdivisionsDto + ): number[]; + /** + * Divides the curve by equal arc length to points + * @param inputs Nurbs curve + * @returns Points + */ + divideByEqualArcLengthToPoints( + inputs: Inputs.Verb.CurveSubdivisionsDto + ): Inputs.Base.Point3[]; + /** + * Divides the curve by arc length to parameters + * @param inputs Nurbs curve + * @returns Parameters + */ + divideByArcLengthToParams( + inputs: Inputs.Verb.CurveDivideLengthDto + ): number[]; + /** + * Divides the curve by arc length to points + * @param inputs Nurbs curve + * @returns Points + */ + divideByArcLengthToPoints( + inputs: Inputs.Verb.CurveDivideLengthDto + ): Inputs.Base.Point3[]; + /** + * Divides multiple curves by equal arc length to points + * @param inputs Nurbs curves + * @returns Points placed for each curve in separate arrays + */ + divideCurvesByEqualArcLengthToPoints( + inputs: Inputs.Verb.CurvesSubdivisionsDto + ): Inputs.Base.Point3[][]; + /** + * Divides multiple curves by arc length to points + * @param inputs Nurbs curves + * @returns Points placed for each curve in separate arrays + */ + divideCurvesByArcLengthToPoints( + inputs: Inputs.Verb.CurvesDivideLengthDto + ): Inputs.Base.Point3[][]; + /** + * Finds the domain interval of the curve parameters + * @param inputs Nurbs curve + * @returns Interval domain + */ + domain(inputs: Inputs.Verb.CurveDto): BaseTypes.IntervalDto; + /** + * Start point of the curve + * @param inputs Nurbs curve + * @returns Start point + */ + startPoint(inputs: Inputs.Verb.CurveDto): Inputs.Base.Point3; + /** + * End point of the curve + * @param inputs Nurbs curve + * @returns End point + */ + endPoint(inputs: Inputs.Verb.CurveDto): Inputs.Base.Point3; + /** + * Start points of the curves + * @param inputs Nurbs curves + * @returns Start points + */ + startPoints(inputs: Inputs.Verb.CurvesDto): Inputs.Base.Point3[]; + /** + * End points of the curves + * @param inputs Nurbs curves + * @returns End points + */ + endPoints(inputs: Inputs.Verb.CurvesDto): Inputs.Base.Point3[]; + /** + * Finds the knots of the Nurbs curve + * @param inputs Nurbs curve + * @returns Knots + */ + knots(inputs: Inputs.Verb.CurveDto): number[]; + /** + * Gets the length of the Nurbs curve at specific parameter + * @param inputs Nurbs curve and parameter + * @returns Length + */ + lengthAtParam(inputs: Inputs.Verb.CurveParameterDto): number; + /** + * Gets the length of the Nurbs curve + * @param inputs Nurbs curve + * @returns Length + */ + length(inputs: Inputs.Verb.CurveDto): number; + /** + * Gets the param at specified length on the Nurbs curve + * @param inputs Nurbs curve, length and tolerance + * @returns Parameter + */ + paramAtLength(inputs: Inputs.Verb.CurveLengthToleranceDto): number; + /** + * Gets the point at specified parameter on the Nurbs curve + * @param inputs Nurbs curve and a parameter + * @returns Point + */ + pointAtParam(inputs: Inputs.Verb.CurveParameterDto): Inputs.Base.Point3; + /** + * Gets the points at specified parameter on the Nurbs curves + * @param inputs Nurbs curves and a parameter + * @returns Points in arrays for each curve + */ + pointsAtParam(inputs: Inputs.Verb.CurvesParameterDto): Inputs.Base.Point3[]; + /** + * Reverses the Nurbs curve + * @param inputs Nurbs curve + * @returns Reversed Nurbs curve + */ + reverse(inputs: Inputs.Verb.CurveDto): any; + /** + * Splits the Nurbs curve in two at a given parameter + * @param inputs Nurbs curve with parameter + * @returns Nurbs curves + */ + split(inputs: Inputs.Verb.CurveParameterDto): any[]; + /** + * Tangent of the Nurbs curve at a given parameter + * @param inputs Nurbs curve with parameter + * @returns Tangent vector + */ + tangent(inputs: Inputs.Verb.CurveParameterDto): Inputs.Base.Vector3; + /** + * Tessellates the Nurbs curve into a list of points + * @param inputs Nurbs curve with tolerance + * @returns Points + */ + tessellate(inputs: Inputs.Verb.CurveToleranceDto): Inputs.Base.Point3[]; + /** + * Transforms the Nurbs curve + * @param inputs Nurbs curve with transformation matrixes + * @returns Transformed curve + */ + transform(inputs: Inputs.Verb.CurveTransformDto): any; + /** + * Transforms the Nurbs curves + * @param inputs Nurbs curves with transformation matrixes + * @returns Transformed curves + */ + transformCurves(inputs: Inputs.Verb.CurvesTransformDto): any[]; + /** + * Weights of the Nurbs curve + * @param inputs Nurbs curve + * @returns Weights + */ + weights(inputs: Inputs.Verb.CurveDto): number[]; + } + /** + * Functions that allow to intersect various geometric entities and get the results + */ + declare class VerbIntersect { + private readonly context; + private readonly geometryHelper; + constructor(context: ContextBase, geometryHelper: GeometryHelper); + /** + * Intersects two verb Nurbs curves together and returns intersection results + * @param inputs Two Nurbs curves + * @returns Intersection results + */ + curves( + inputs: Inputs.Verb.CurveCurveDto + ): BaseTypes.CurveCurveIntersection[]; + /** + * Intersects curve and surface + * @param inputs Nurbs curve and a Nurbs surface + * @returns Intersection results + */ + curveAndSurface( + inputs: Inputs.Verb.CurveSurfaceDto + ): BaseTypes.CurveSurfaceIntersection[]; + /** + * Intersects two surfaces + * @param inputs Nurbs curve and a Nurbs surface + * @returns Nurbs curves along the intersection + */ + surfaces(inputs: Inputs.Verb.SurfaceSurfaceDto): any[]; + /** + * Gets intersection parameters on the first curve from curve-curve intersection + * @param inputs Intersections data + * @returns Parameters on first curve + */ + curveCurveFirstParams( + inputs: Inputs.Verb.CurveCurveIntersectionsDto + ): number[]; + /** + * Gets intersection parameters on the second curve from curve-curve intersection + * @param inputs Intersections data + * @returns Parameters on second curve + */ + curveCurveSecondParams( + inputs: Inputs.Verb.CurveCurveIntersectionsDto + ): number[]; + /** + * Gets intersection points on the first curve from curve-curve intersection + * @param inputs Intersections data + * @returns Points on first curve + */ + curveCurveFirstPoints( + inputs: Inputs.Verb.CurveCurveIntersectionsDto + ): number[][]; + /** + * Gets intersection points on the second curve from curve-curve intersection + * @param inputs Intersections data + * @returns Points on second curve + */ + curveCurveSecondPoints( + inputs: Inputs.Verb.CurveCurveIntersectionsDto + ): number[][]; + /** + * Gets intersection parameters on the curve from curve-surface intersection + * @param inputs Intersections data + * @returns Parameters on the curve + */ + curveSurfaceCurveParams( + inputs: Inputs.Verb.CurveSurfaceIntersectionsDto + ): number[]; + /** + * Gets intersection parameters on the surface from curve-surface intersection + * @param inputs Intersections data + * @returns Parameters on the surface + */ + curveSurfaceSurfaceParams( + inputs: Inputs.Verb.CurveSurfaceIntersectionsDto + ): BaseTypes.UVDto[]; + /** + * Gets intersection points on the curve from curve-surface intersection + * @param inputs Intersections data + * @returns Points on the curve + */ + curveSurfaceCurvePoints( + inputs: Inputs.Verb.CurveSurfaceIntersectionsDto + ): number[][]; + /** + * Gets intersection points on the surface from curve-surface intersection + * @param inputs Intersections data + * @returns Points on the surface + */ + curveSurfaceSurfacePoints( + inputs: Inputs.Verb.CurveSurfaceIntersectionsDto + ): number[][]; + } + /** + * Conical surface functions. + * These functions wrap around Verbnurbs library that you can find here http://verbnurbs.com/. + * Thanks Peter Boyer for his work. + */ + declare class VerbSurfaceConical { + private readonly context; + constructor(context: ContextBase); + /** + * Creates the conical Nurbs surface + * @param inputs Parameters for Nurbs conical surface + * @returns Conical Nurbs surface + */ + create(inputs: Inputs.Verb.ConeAndCylinderParametersDto): any; + /** + * Get cone axis + * @param inputs Nurbs conical surface + * @returns Axis vector + */ + axis(inputs: Inputs.Verb.ConeDto): number[]; + /** + * Get cone base + * @param inputs Nurbs conical surface + * @returns Base point + */ + base(inputs: Inputs.Verb.ConeDto): number[]; + /** + * Get cone height + * @param inputs Nurbs conical surface + * @returns Height + */ + height(inputs: Inputs.Verb.ConeDto): number; + /** + * Get cone radius + * @param inputs Nurbs conical surface + * @returns Radius + */ + radius(inputs: Inputs.Verb.ConeDto): number; + /** + * Get cone x axis + * @param inputs Nurbs conical surface + * @returns X axis vector + */ + xAxis(inputs: Inputs.Verb.ConeDto): number[]; + } + /** + * Cylindrical surface functions. + * These functions wrap around Verbnurbs library that you can find here http://verbnurbs.com/. + * Thanks Peter Boyer for his work. + */ + declare class VerbSurfaceCylindrical { + private readonly context; + constructor(context: ContextBase); + /** + * Creates the cylindrical Nurbs surface + * @param inputs Parameters for cylindrical Nurbs surface + * @returns Cylindrical Nurbs surface + */ + create(inputs: Inputs.Verb.ConeAndCylinderParametersDto): any; + /** + * Get cylinder axis + * @param inputs Nurbs cylindrical surface + * @returns Axis vector + */ + axis(inputs: Inputs.Verb.CylinderDto): number[]; + /** + * Get cylinder base + * @param inputs Nurbs cylindrical surface + * @returns Base point + */ + base(inputs: Inputs.Verb.CylinderDto): number[]; + /** + * Get cylinder height + * @param inputs Nurbs cylindrical surface + * @returns Height + */ + height(inputs: Inputs.Verb.CylinderDto): number; + /** + * Get cylinder radius + * @param inputs Nurbs cylindrical surface + * @returns Radius + */ + radius(inputs: Inputs.Verb.CylinderDto): number; + /** + * Get cylinder x axis + * @param inputs Nurbs cylindrical surface + * @returns X axis vector + */ + xAxis(inputs: Inputs.Verb.CylinderDto): number[]; + } + /** + * Extrusion surface functions. + * These functions wrap around Verbnurbs library that you can find here http://verbnurbs.com/. + * Thanks Peter Boyer for his work. + */ + declare class VerbSurfaceExtrusion { + private readonly context; + constructor(context: ContextBase); + /** + * Creates the Nurbs surface extrusion from the curve + * @param inputs Nurbs profile curve and direction vector + * @returns Nurbs surface + */ + create(inputs: Inputs.Verb.ExtrusionParametersDto): any; + /** + * Gets the direction vector of the extrusion + * @param inputs Extruded Nurbs surface + * @returns Vector + */ + direction(inputs: Inputs.Verb.ExtrusionDto): number[]; + /** + * Gets the profile Nurbs curve of the extrusion + * @param inputs Extruded Nurbs surface + * @returns Profile Nurbs curve + */ + profile(inputs: Inputs.Verb.ExtrusionDto): number[]; + } + /** + * Revolved surface functions. + * These functions wrap around Verbnurbs library that you can find here http://verbnurbs.com/. + * Thanks Peter Boyer for his work. + */ + declare class VerbSurfaceRevolved { + private readonly context; + private readonly math; + constructor(context: ContextBase, math: MathBitByBit); + /** + * Creates the revolved Nurbs surface + * @param inputs Parameters for Nurbs revolved surface + * @returns Revolved Nurbs surface + */ + create(inputs: Inputs.Verb.RevolutionParametersDto): any; + /** + * Get the profile Nurbs curve of the revolved Nurbs surface + * @param inputs Revolved Nurbs surface + * @returns Nurbs curve + */ + profile(inputs: Inputs.Verb.RevolutionDto): any; + /** + * Get the center Nurbs curve of the revolved Nurbs surface + * @param inputs Revolved Nurbs surface + * @returns Center point + */ + center(inputs: Inputs.Verb.RevolutionDto): number[]; + /** + * Get the rotation axis of the revolved Nurbs surface + * @param inputs Revolved Nurbs surface + * @returns Axis vector of rotation + */ + axis(inputs: Inputs.Verb.RevolutionDto): number[]; + /** + * Get the angle of rotation from revolved Nurbs surface + * @param inputs Revolved Nurbs surface + * @returns Angle in degrees + */ + angle(inputs: Inputs.Verb.RevolutionDto): number; + } + /** + * Spherical surface functions. + * These functions wrap around Verbnurbs library that you can find here http://verbnurbs.com/. + * Thanks Peter Boyer for his work. + */ + declare class VerbSurfaceSpherical { + private readonly context; + constructor(context: ContextBase); + /** + * Creates the spherical Nurbs surface + * @param inputs Parameters for Nurbs spherical surface + * @returns Spherical Nurbs surface + */ + create(inputs: Inputs.Verb.SphericalParametersDto): any; + /** + * Get the radius of the spherical Nurbs surface + * @param inputs Spherical Nurbs surface + * @returns Radius + */ + radius(inputs: Inputs.Verb.SphereDto): number; + /** + * Get the center of the spherical Nurbs surface + * @param inputs Spherical Nurbs surface + * @returns Center point + */ + center(inputs: Inputs.Verb.SphereDto): number[]; + } + /** + * Sweep surface functions. + * These functions wrap around Verbnurbs library that you can find here http://verbnurbs.com/. + * Thanks Peter Boyer for his work. + */ + declare class VerbSurfaceSweep { + private readonly context; + constructor(context: ContextBase); + /** + * Creates the sweep Nurbs surface + * @param inputs Parameters for Nurbs sweep surface + * @returns Sweep Nurbs surface + */ + create(inputs: Inputs.Verb.SweepParametersDto): any; + /** + * Get the profile Nurbs curve of the swept Nurbs surface + * @param inputs Sweep Nurbs surface + * @returns Profile Nurbs curve + */ + profile(inputs: Inputs.Verb.SweepDto): any; + /** + * Get the rail Nurbs curve of the swept Nurbs surface + * @param inputs Sweep Nurbs surface + * @returns Rail Nurbs curve + */ + rail(inputs: Inputs.Verb.SweepDto): any; + } + /** + * Contains various functions for Nurbs surfaces. + * These functions wrap around Verbnurbs library that you can find here http://verbnurbs.com/. + * Thanks Peter Boyer for his work. + */ + declare class VerbSurface { + private readonly context; + private readonly geometryHelper; + private readonly math; + readonly cone: VerbSurfaceConical; + readonly cylinder: VerbSurfaceCylindrical; + readonly extrusion: VerbSurfaceExtrusion; + readonly sphere: VerbSurfaceSpherical; + readonly revolved: VerbSurfaceRevolved; + readonly sweep: VerbSurfaceSweep; + constructor( + context: ContextBase, + geometryHelper: GeometryHelper, + math: MathBitByBit + ); + /** + * Gets the boundary edge Nurbs curves of the surface in a list + * @param inputs Nurbs surface + * @returns Array of curves + */ + boundaries(inputs: Inputs.Verb.SurfaceDto): any[]; + /** + * Creates the surface by providing 4 points as corners + * @param inputs 4 points + * @returns Nurbs surface + */ + createSurfaceByCorners(inputs: Inputs.Verb.CornersDto): any; + /** + * Creates the Nurbs surface by providing uv knots, uv degrees, points and weights + * @param inputs Surface creation information + * @returns Nurbs surface + */ + createSurfaceByKnotsControlPointsWeights( + inputs: Inputs.Verb.KnotsControlPointsWeightsDto + ): any; + /** + * Creates the Nurbs surface by lofting curves + * @param inputs Curves to loft through + * @returns Nurbs surface + */ + createSurfaceByLoftingCurves(inputs: Inputs.Verb.LoftCurvesDto): any; + /** + * Clone the Nurbs surface + * @param inputs Nurbs surface + * @returns Nurbs surface + */ + clone(inputs: Inputs.Verb.SurfaceDto): any; + /** + * Finds the closest parameter on the surface from the point + * @param inputs Nurbs surface with a point + * @returns UV parameters + */ + closestParam(inputs: Inputs.Verb.SurfaceParamDto): BaseTypes.UVDto; + /** + * Finds the closest point on the surface from the point + * @param inputs Nurbs surface with a point + * @returns Point + */ + closestPoint(inputs: Inputs.Verb.SurfaceParamDto): number[]; + /** + * Gets the control points on the surface + * @param inputs Nurbs surface + * @returns Two dimensional array of points + */ + controlPoints(inputs: Inputs.Verb.SurfaceDto): number[][][]; + /** + * Gets the U degree of the surface + * @param inputs Nurbs surface + * @returns U degree + */ + degreeU(inputs: Inputs.Verb.SurfaceDto): number; + /** + * Gets the V degree of the surface + * @param inputs Nurbs surface + * @returns V degree + */ + degreeV(inputs: Inputs.Verb.SurfaceDto): number; + /** + * Gets the derivatives of the surface at specified uv coordinate + * @param inputs Nurbs surface + * @returns Two dimensional array of vectors + */ + derivatives(inputs: Inputs.Verb.DerivativesDto): number[][][]; + /** + * Gets the U domain of the surface + * @param inputs Nurbs surface + * @returns U domain as interval + */ + domainU(inputs: Inputs.Verb.SurfaceDto): BaseTypes.IntervalDto; + /** + * Gets the V domain of the surface + * @param inputs Nurbs surface + * @returns V domain as interval + */ + domainV(inputs: Inputs.Verb.SurfaceDto): BaseTypes.IntervalDto; + /** + * Gets the Nurbs isocurve on the surface + * @param inputs Nurbs surface + * @returns Nurbs curve + */ + isocurve(inputs: Inputs.Verb.SurfaceParameterDto): any; + /** + * Subdivides surface into preferred number of isocurves + * @param inputs Nurbs surface + * @returns Nurbs curves + */ + isocurvesSubdivision(inputs: Inputs.Verb.IsocurveSubdivisionDto): any[]; + /** + * Subdivides surface into isocurves on specified array of parameters + * @param inputs Nurbs surface + * @returns Nurbs curves + */ + isocurvesAtParams(inputs: Inputs.Verb.IsocurvesParametersDto): any[]; + /** + * Gets the U knots of the surface + * @param inputs Nurbs surface + * @returns Knots on u direction + */ + knotsU(inputs: Inputs.Verb.SurfaceDto): number[]; + /** + * Gets the V knots of the surface + * @param inputs Nurbs surface + * @returns Knots on v direction + */ + knotsV(inputs: Inputs.Verb.SurfaceDto): number[]; + /** + * Gets the normal on the surface at uv coordinate + * @param inputs Nurbs surface + * @returns Normal vector + */ + normal(inputs: Inputs.Verb.SurfaceLocationDto): number[]; + /** + * Gets the point on the surface at uv coordinate + * @param inputs Nurbs surface + * @returns Point + */ + point(inputs: Inputs.Verb.SurfaceLocationDto): number[]; + /** + * Reverse the Nurbs surface. This will reverse the UV origin and isocurve directions + * @param inputs Nurbs surface + * @returns Nurbs surface + */ + reverse(inputs: Inputs.Verb.SurfaceDto): any; + /** + * Splits the Nurbs surface in two halfs. + * @param inputs Nurbs surface + * @returns Two Nurbs surfaces + */ + split(inputs: Inputs.Verb.SurfaceParameterDto): any[]; + /** + * Transforms the Nurbs surface with a given list of transformations. + * @param inputs Nurbs surface with transforms + * @returns Nurbs surface + */ + transformSurface(inputs: Inputs.Verb.SurfaceTransformDto): any; + /** + * Gets the weights of the surface + * @param inputs Nurbs surface + * @returns Two dimensional array of weights + */ + weights(inputs: Inputs.Verb.SurfaceDto): number[][]; + } + /** + * Contains various functions for Nurbs curves and surfaces. + * These functions wrap around Verbnurbs library that you can find here http://verbnurbs.com/. + * Thanks Peter Boyer for his work. + */ + declare class Verb { + private readonly math; + readonly curve: VerbCurve; + readonly surface: VerbSurface; + readonly intersect: VerbIntersect; + constructor( + context: ContextBase, + geometryHelper: GeometryHelper, + math: MathBitByBit + ); + } + declare class AdvancedAdv { + private readonly occWorkerManager; + private readonly context; + private readonly draw; + text3d: Text3D; + patterns: Patterns; + navigation: Navigation; + dimensions: Dimensions; + constructor( + occWorkerManager: OCCTWorkerManager, + context: Context, + draw: Draw + ); + } + declare class Dimensions { + private readonly context; + constructor(context: ContextComplete); + /** + * Creates linear dimension - a measurement line between two points with extension lines and text label. + * The dimension shows the distance between the points and can be styled with DimensionStyleDto. + * @example Dimensions.linearDimension({ name: "Length", startPoint: [0, 0, 0], endPoint: [5, 0, 0], direction: [0, 1, 0] }); + * @param inputs + * @returns Create linear dimension + * @group dimensions + * @shortname linear dimension + * @drawable true + */ + linearDimension( + inputs: Advanced.Dimensions.LinearDimensionDto + ): Advanced.Dimensions.LinearDimensionEntity; + /** + * Creates angular dimension - a measurement arc between two direction vectors with extension lines and text label. + * The dimension shows the angle between the directions and can be styled with DimensionStyleDto. + * @example Dimensions.angularDimension({ name: "Angle", centerPoint: [0, 0, 0], direction1: [1, 0, 0], direction2: [0, 1, 0], radius: 2 }); + * @param inputs + * @returns Create angular dimension + * @group dimensions + * @shortname angular dimension + * @drawable true + */ + angularDimension( + inputs: Advanced.Dimensions.AngularDimensionDto + ): Advanced.Dimensions.AngularDimensionEntity; + /** + * Creates radial dimension - a measurement line from center to perimeter showing radius or diameter. + * Shows 'R' prefix for radius or '⌀' prefix for diameter with optional center mark. + * @example Dimensions.radialDimension({ centerPoint: [0, 0, 0], radiusPoint: [2, 0, 0], showDiameter: false }); + * @param inputs + * @returns Create radial dimension + * @group dimensions + * @shortname radial dimension + * @drawable true + */ + radialDimension( + inputs: Advanced.Dimensions.RadialDimensionDto + ): Advanced.Dimensions.RadialDimensionEntity; + /** + * Creates diametral dimension - a measurement line spanning full diameter of circular features. + * Shows '⌀' prefix with optional center mark and arrows at both ends. + * @example Dimensions.diametralDimension({ centerPoint: [0, 0, 0], direction: [1, 0, 0], diameter: 4 }); + * @param inputs + * @returns Create diametral dimension + * @group dimensions + * @shortname diametral dimension + * @drawable true + */ + diametralDimension( + inputs: Advanced.Dimensions.DiametralDimensionDto + ): Advanced.Dimensions.DiametralDimensionEntity; + /** + * Creates ordinate dimension - shows X, Y, or Z coordinate from a reference point with leader line. + * Useful for coordinate annotations and datum referencing in technical drawings. + * @example Dimensions.ordinateDimension({ measurementPoint: [5, 3, 2], referencePoint: [0, 0, 0], axis: "X" }); + * @param inputs + * @returns Create ordinate dimension + * @group dimensions + * @shortname ordinate dimension + * @drawable true + */ + ordinateDimension( + inputs: Advanced.Dimensions.OrdinateDimensionDto + ): Advanced.Dimensions.OrdinateDimensionEntity; + /** + * Create dimension style - used to style dimension lines, arrows, and text in 3D space. + * You can customize line colors, thickness, text size, arrow size, and background colors. + * @param inputs + * @returns Create dimension style + * @group style + * @shortname dimension style + * @drawable false + */ + dimensionStyle( + inputs: Advanced.Dimensions.DimensionStyleDto + ): Advanced.Dimensions.DimensionStyleDto; + /** + * Draw linear dimension in 3D space + * @param inputs + * @returns Draw linear dimension with dispose method + * @group linear dimension + * @shortname draw linear dimension + * @drawable false + * @ignore true + */ + drawLinearDimension(inputs: Advanced.Dimensions.LinearDimensionEntity): { + dispose: () => void; + }; + /** + * Draw angular dimension in 3D space + * @param inputs + * @returns Draw angular dimension with dispose method + * @group angular dimension + * @shortname draw angular dimension + * @drawable false + * @ignore true + */ + drawAngularDimension(inputs: Advanced.Dimensions.AngularDimensionEntity): { + dispose: () => void; + }; + /** + * Draw radial dimension in 3D space + * @param inputs + * @returns Draw radial dimension with dispose method + * @group radial dimension + * @shortname draw radial dimension + * @drawable false + * @ignore true + */ + drawRadialDimension(inputs: Advanced.Dimensions.RadialDimensionEntity): { + dispose: () => void; + }; + /** + * Draw diametral dimension in 3D space + * @param inputs + * @returns Draw diametral dimension with dispose method + * @group diametral dimension + * @shortname draw diametral dimension + * @drawable false + * @ignore true + */ + drawDiametralDimension( + inputs: Advanced.Dimensions.DiametralDimensionEntity + ): { + dispose: () => void; + }; + /** + * Draw ordinate dimension in 3D space + * @param inputs + * @returns Draw ordinate dimension with dispose method + * @group ordinate dimension + * @shortname draw ordinate dimension + * @drawable false + * @ignore true + */ + drawOrdinateDimension( + inputs: Advanced.Dimensions.OrdinateDimensionEntity + ): { + dispose: () => void; + }; + } + declare class AngularDimension { + private scene; + private data; + private style; + private arc; + private extensionLine1; + private extensionLine2; + private tangentExtension1; + private tangentExtension2; + private arrow1; + private arrow2; + private dimensionText3D; + private static readonly DEFAULT_STYLE; + constructor(options: AngularDimensionDto, scene: BABYLON.Scene); + private createDimension; + private createArc; + private createArrowTailExtensions; + private createLine; + private createArrow; + private createText; + dispose(): void; + } + declare class DiametralDimension { + private scene; + private data; + private style; + private diameterLine; + private centerMark; + private arrow1; + private arrow2; + private dimensionText3D; + constructor(options: DiametralDimensionDto, scene: BABYLON.Scene); + private create; + private createLine; + private createCenterMark; + private createArrow; + private createText; + dispose(): void; + } + /** + * Service for evaluating mathematical expressions in dimension labels. + * Supports basic arithmetic operations and template string replacement. + */ + declare class DimensionExpressionService { + /** + * Evaluates a mathematical expression or template string with a given value + * @param expression The expression to evaluate (can contain 'val' placeholder) + * @param value The numeric value to substitute for 'val' + * @param decimalPlaces Number of decimal places to format the result + * @param removeTrailingZeros Whether to remove trailing zeros from the result + * @returns The evaluated expression as a formatted string + */ + static evaluate( + expression: string, + value: number, + decimalPlaces: number, + removeTrailingZeros?: boolean + ): string; + /** + * Formats dimension text with prefix, suffix, and expression evaluation + * @param value The numeric value to display + * @param labelOverwrite Optional expression to evaluate instead of raw value + * @param decimalPlaces Number of decimal places for formatting + * @param labelSuffix Suffix to append to the text + * @param removeTrailingZeros Whether to remove trailing zeros from the result + * @param prefix Optional prefix to prepend to the text + * @returns Formatted dimension text + */ + static formatDimensionText( + value: number, + labelOverwrite: string | undefined, + decimalPlaces: number, + labelSuffix: string, + removeTrailingZeros?: boolean, + prefix?: string + ): string; + /** + * Formats linear dimension text + */ + static formatLinearText( + distance: number, + labelOverwrite: string | undefined, + decimalPlaces: number, + labelSuffix: string, + removeTrailingZeros?: boolean + ): string; + /** + * Formats angular dimension text + */ + static formatAngularText( + angle: number, + labelOverwrite: string | undefined, + decimalPlaces: number, + labelSuffix: string, + removeTrailingZeros?: boolean + ): string; + /** + * Formats radial dimension text + */ + static formatRadialText( + radius: number, + showDiameter: boolean, + labelOverwrite: string | undefined, + decimalPlaces: number, + labelSuffix: string, + removeTrailingZeros?: boolean + ): string; + /** + * Formats diametral dimension text + */ + static formatDiametralText( + diameter: number, + labelOverwrite: string | undefined, + decimalPlaces: number, + labelSuffix: string, + removeTrailingZeros?: boolean + ): string; + /** + * Formats ordinate dimension text + */ + static formatOrdinateText( + coordinate: number, + axisName: string, + labelOverwrite: string | undefined, + decimalPlaces: number, + labelSuffix: string, + removeTrailingZeros?: boolean + ): string; + } + declare class DimensionManager { + private linearDimensions; + private angularDimensions; + private radialDimensions; + private diametralDimensions; + private ordinateDimensions; + addLinearDimension(dimension: LinearDimension): void; + removeLinearDimension(dimension: LinearDimension): void; + addAngularDimension(dimension: AngularDimension): void; + removeAngularDimension(dimension: AngularDimension): void; + addRadialDimension(dimension: RadialDimension): void; + removeRadialDimension(dimension: RadialDimension): void; + addDiametralDimension(dimension: DiametralDimension): void; + removeDiametralDimension(dimension: DiametralDimension): void; + addOrdinateDimension(dimension: OrdinateDimension): void; + removeOrdinateDimension(dimension: OrdinateDimension): void; + clearAllDimensions(): void; + dispose(): void; + } + /** + * Interface for GUI text creation result + */ + interface GuiTextElements { + textAnchor: BABYLON.TransformNode; + textContainer: GUI.Rectangle; + textBlock: GUI.TextBlock; + } + /** + * Service for creating shared 3D and GUI rendering elements used across all dimension types. + * Eliminates code duplication by providing common mesh and text creation functionality. + */ + declare class DimensionRenderingService { + /** + * Creates a line mesh using tube geometry with consistent styling + * @param scene The Babylon scene + * @param points Array of Vector3 points defining the line path + * @param name Name for the mesh + * @param style Dimension style containing appearance settings + * @param dimensionType Type of dimension for metadata + * @returns The created line mesh + */ + static createLine( + scene: BABYLON.Scene, + points: BABYLON.Vector3[], + name: string, + style: DimensionStyleDto, + dimensionType: string + ): BABYLON.Mesh; + /** + * Creates an arrow mesh (cone) with consistent styling + * @param scene The Babylon scene + * @param position Position for the arrow + * @param direction Direction the arrow should point + * @param name Name for the mesh + * @param style Dimension style containing appearance settings + * @param dimensionType Type of dimension for metadata + * @returns The created arrow mesh + */ + static createArrow( + scene: BABYLON.Scene, + position: BABYLON.Vector3, + direction: BABYLON.Vector3, + name: string, + style: DimensionStyleDto, + dimensionType: string + ): BABYLON.Mesh; + /** + * Creates a 3D text mesh using DimensionText3D + * @param scene The Babylon scene + * @param text The text content + * @param position Position for the text + * @param style Dimension style containing appearance settings + * @returns The created DimensionText3D instance + */ + static create3DText( + scene: BABYLON.Scene, + text: string, + position: BABYLON.Vector3, + style: DimensionStyleDto + ): DimensionText3D; + /** + * Creates GUI text elements (anchor, container, text block) with consistent styling + * @param scene The Babylon scene + * @param adt Advanced Dynamic Texture for GUI + * @param text The text content + * @param position Position for the text anchor + * @param style Dimension style containing appearance settings + * @param dimensionType Type of dimension for unique IDs + * @returns Object containing the created GUI elements + */ + static createGuiText( + scene: BABYLON.Scene, + adt: GUI.AdvancedDynamicTexture, + text: string, + position: BABYLON.Vector3, + style: DimensionStyleDto + ): GuiTextElements; + /** + * Creates a center mark (crossing lines) for radial/diametral dimensions + * @param scene The Babylon scene + * @param center Center position for the mark + * @param style Dimension style containing appearance settings + * @param dimensionType Type of dimension for metadata + * @returns The merged center mark mesh + */ + static createCenterMark( + scene: BABYLON.Scene, + center: BABYLON.Vector3, + style: DimensionStyleDto, + dimensionType: string + ): BABYLON.Mesh; + } + /** + * Manages shared services and utilities for all dimension classes. + * Provides singleton pattern for occlusion services and shared utilities. + */ + declare class DimensionServiceManager { + private static idCounter; + /** + * Generates unique IDs for dimensions using a counter-based approach + */ + static generateId(type: string): string; + /** + * Creates Vector3 from array efficiently + */ + static createVector3FromArray( + arr: [number, number, number] + ): BABYLON.Vector3; + /** + * Creates a fresh material for dimension elements + * No caching to avoid issues with disposed materials and external scene cleanup + */ + static getDimensionMaterial( + scene: BABYLON.Scene, + color: string, + materialType?: "line" | "arrow" + ): BABYLON.StandardMaterial; + } + interface Text3DOptions { + text: string; + position: BABYLON.Vector3; + size?: number; + fontWeight?: number; + color?: string; + backgroundColor?: string; + backgroundOpacity?: number; + backgroundStroke?: boolean; + backgroundStrokeThickness?: number; + backgroundRadius?: number; + stableSize?: boolean; + billboardMode?: boolean; + alwaysOnTop?: boolean; + name?: string; + } + /** + * Helper class for creating 3D text labels that properly participate in depth testing + * and rendering within the 3D scene. + */ + declare class DimensionText3D { + private scene; + private textMesh; + private material; + private dynamicTexture; + private options; + constructor(scene: BABYLON.Scene, options: Text3DOptions); + private createTextMesh; + private setupDistanceScaling; + private measureText; + /** + * Update the text content + */ + updateText(newText: string): void; + /** + * Update the position of the text mesh + */ + updatePosition(position: BABYLON.Vector3): void; + /** + * Get the text mesh for further manipulation + */ + getMesh(): BABYLON.Mesh | null; + /** + * Dispose all resources + */ + dispose(): void; + } + declare class LinearDimension { + private scene; + private data; + private style; + private dimensionLine; + private extensionLine1; + private extensionLine2; + private arrow1; + private arrow2; + private arrowTail1; + private arrowTail2; + private dimensionText3D; + private static readonly DEFAULT_STYLE; + constructor(options: LinearDimensionDto, scene: BABYLON.Scene); + private createDimension; + private createLine; + private createArrow; + private createText; + dispose(): void; + } + declare class OrdinateDimension { + private scene; + private data; + private style; + private leaderLine; + private arrow; + private dimensionText3D; + constructor(options: OrdinateDimensionDto, scene: BABYLON.Scene); + private create; + private calculateOffsetDirection; + private createLine; + private createArrow; + private createText; + dispose(): void; + } + declare class RadialDimension { + private scene; + private data; + private style; + private radiusLine; + private centerMark; + private arrow; + private dimensionText3D; + constructor(options: RadialDimensionDto, scene: BABYLON.Scene); + private create; + private createLine; + private createCenterMark; + private createArrow; + private createText; + dispose(): void; + } + declare class CameraManager { + private scene; + private camera; + private readonly animationFrameRate; + private readonly animationDurationInFrames; + constructor(scene: BABYLON.Scene); + flyTo(newPosition: BABYLON.Vector3, newTarget: BABYLON.Vector3): void; + } + declare class PointOfInterest { + private scene; + private data; + private style; + private time; + private pointSphere; + private pulseRing; + private clickSphere; + private labelText; + private labelContainer; + private containerNode; + private pointMaterial; + private pulseMaterial; + private camera; + private static readonly DEFAULT_STYLE; + constructor( + options: PointOfInterestDto, + scene: BABYLON.Scene, + onClick: () => void + ); + private create3DVisual; + private setupDistanceScaling; + private updateLabelPosition; + private createMaterials; + private createLabelText; + private updateLabelText; + private setupInteractions; + /** Animates the pulse effect using torus scaling and visibility changes for a ring effect. */ + animatePulse(): void; + dispose(): void; + } + declare class Navigation { + private readonly context; + constructor(context: ContextComplete); + /** + * Creates point of interest - clickable indicator in 3D space that can be used to fly the camera to a specific location with predefined camera position and target. + * Point of interest can be styled with PointOfInterestStyleDto and animated with pulse effect. + * Point of interest can also have a text label. + * @example Navigation.pointOfInterest({ name: "Entrance", position: [0, 1, 0], cameraPosition: [10, 10, 10], cameraTarget: [0, 0, 0] }); + * @param inputs + * @returns Create point of interest + * @group point of interest + * @shortname point of interest + * @drawable true + */ + pointOfInterest( + inputs: Advanced.Navigation.PointOfInterestDto + ): Advanced.Navigation.PointOfInterestEntity; + /** + * Create point of interest style - used to style point of interest indicators in 3D space. + * You can customize point size, color, hover color, pulse effect, text label color and size. + * @param inputs + * @returns Create point of interest style + * @group point of interest + * @shortname point of interest style + * @drawable false + */ + pointOfInterestStyle( + inputs: Advanced.Navigation.PointOfInterestStyleDto + ): Advanced.Navigation.PointOfInterestStyleDto; + /** + * Zoom camera to fit specified meshes in the scene with smooth animation. + * Works only with ArcRotateCamera. Animation can be interrupted if called multiple times. + * @param inputs Configuration for zoom operation including meshes, children inclusion, and animation speed + * @returns void + * @group camera + * @shortname zoom on + * @drawable false + */ + zoomOn(inputs: Advanced.Navigation.ZoomOnDto): Promise; + /** + * Zoom camera to fit specified meshes in the scene with smooth animation, considering exact screen aspect ratio. + * Unlike zoomOn, this method precisely calculates camera distance based on viewport dimensions and mesh bounding box + * to ensure better fit at padding=0. Works only with ArcRotateCamera. Animation can be interrupted if called multiple times. + * @param inputs Configuration for zoom operation including meshes, children inclusion, and animation speed + * @returns void + * @group camera + * @shortname zoom on aspect + * @drawable false + */ + zoomOnAspect(inputs: Advanced.Navigation.ZoomOnDto): Promise; + /** + * Focus camera on specified meshes from a specific angle with smooth animation. + * Computes the center of the bounding box of all meshes and positions the camera + * at the specified orientation vector to look at the center. + * Works only with ArcRotateCamera. Animation can be interrupted if called multiple times. + * @param inputs Configuration for focus operation including meshes, orientation, distance, and animation speed + * @returns void + * @group camera + * @shortname focus from angle + * @drawable false + */ + focusFromAngle( + inputs: Advanced.Navigation.FocusFromAngleDto + ): Promise; + /** + * Create fly through node + * @param inputs + * @returns Create fly through node + * @group point of interest + * @shortname fly through node + * @drawable false + * @ignore true + */ + drawPointOfInterest(inputs: Advanced.Navigation.PointOfInterestEntity): { + dispose: () => void; + }; + } + declare class FacePatterns { + private readonly occWorkerManager; + private readonly context; + private readonly draw; + pyramidSimple: PyramidSimple; + constructor( + occWorkerManager: OCCTWorkerManager, + context: Context, + draw: Draw + ); + } + declare class PyramidSimple { + private readonly occWorkerManager; + private readonly context; + private readonly draw; + constructor( + occWorkerManager: OCCTWorkerManager, + context: Context, + draw: Draw + ); + /** + * Creates a simple pyramid pattern on faces + * @param inputs + * @returns pyramid shapes along the wire + * @group create + * @shortname create simple pyramid + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/advanced/patterns/pyramid-simple.jpeg + * @drawable true + */ + createPyramidSimple( + inputs: Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleDto + ): Promise< + Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleData + >; + /** + * Creates a simple pyramid pattern on faces with affectors that change the height + * @param inputs uv numbers, affector points and affector weights -1 to 1 + * @returns pyramid shapes along the wire + * @group create + * @shortname create simple pyramid affector + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/advanced/patterns/pyramid-simple.jpeg + * @drawable true + */ + createPyramidSimpleAffectors( + inputs: Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleAffectorsDto + ): Promise< + Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleData + >; + /** + * Draws pyramids on the screen + * @param inputs Contains a model shapes to be drawn and additional information + * @returns BabylonJS Mesh + * @group drawing + * @shortname draw shape + * @drawable false + * @ignore true + */ + drawModel( + inputs: Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleData + ): Promise; + /** + * Gets the compound shape of all the pyramids + * @param inputs pyramid model + * @returns Compound shape of the pyramid + * @group get shapes + * @shortname get compound + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/advanced/patterns/pyramid-simple.jpeg + * @drawable true + */ + getCompoundShape( + inputs: Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelDto + ): Inputs.OCCT.TopoDSShapePointer; + /** + * Gets the compound shape on the face + * @param inputs pyramid model and face index + * @returns Compound shape of the pyramids on the face + * @group get shapes + * @shortname get compound on face + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/advanced/patterns/pyramid-simple.jpeg + * @drawable true + */ + getCompoundShapeOnFace( + inputs: Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelFaceIndexDto + ): Inputs.OCCT.TopoDSShapePointer; + /** + * Gets the compound shape of the pyramid on the face at particular index + * @param inputs + * @returns Compound shape of the pyramid + * @group get shapes + * @shortname get compound cell on face + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/advanced/patterns/pyramid-simple.jpeg + * @drawable true + */ + getCompoundShapeCellOnFace( + inputs: Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelFaceCellIndexDto + ): Inputs.OCCT.TopoDSShapePointer; + /** + * Gets all of the pyramid cells. This is usually in between action to then read particular information of the cells themselves. + * @param inputs + * @returns Compound shape of the pyramid + * @group get cells + * @shortname get all cells + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/advanced/patterns/pyramid-simple.jpeg + * @drawable false + */ + getAllPyramidCells( + inputs: Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelDto + ): Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleCellPart[]; + /** + * Gets pyramid cells on the face. This is usually in between action to then read particular information of the cells themselves. + * @param inputs + * @returns Cells of the pyramid + * @group get cells + * @shortname get cells on face + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/advanced/patterns/pyramid-simple.jpeg + * @drawable false + */ + getAllPyramidCellsOnFace( + inputs: Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelFaceIndexDto + ): Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleCellPart[]; + /** + * Gets pyramid cells on the face. This is usually in between action to then read particular information of the cells themselves. + * @param inputs + * @returns Cells of the pyramid + * @group get cells + * @shortname get cells on face + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/advanced/patterns/pyramid-simple.jpeg + * @drawable false + */ + getAllPyramidUCellsOnFace( + inputs: Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelFaceIndexDto + ): Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleCellPart[]; + /** + * Gets pyramid cells on the face at u index along v direction. This is usually in between action to then read particular information of the cells themselves. + * @param inputs + * @returns Cells of the pyramid + * @group get cells + * @shortname get cells on face at u + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/advanced/patterns/pyramid-simple.jpeg + * @drawable false + */ + getAllPyramidUCellsOnFaceAtU( + inputs: Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelFaceCellsUIndexDto + ): Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleCellPart[]; + /** + * Gets pyramid cells on the face at v index along u direction. This is usually in between action to then read particular information of the cells themselves. + * @param inputs + * @returns Cells of the pyramid + * @group get cells + * @shortname get cells on face at v + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/advanced/patterns/pyramid-simple.jpeg + * @drawable false + */ + getAllPyramidUCellsOnFaceAtV( + inputs: Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelFaceCellsVIndexDto + ): Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleCellPart[]; + /** + * Gets pyramid cell on the face at u and v index. This is usually in between action to then read particular information of the cell itself. + * @param inputs + * @returns Cell of the pyramid + * @group get cell + * @shortname get cell + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/advanced/patterns/pyramid-simple.jpeg + * @drawable false + */ + getCellOnIndex( + inputs: Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelFaceCellIndexDto + ): Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleCellPart; + /** + * Gets the top points of cells + * @param inputs cells of the pyramid + * @returns Top points on the cells + * @group get from cells + * @shortname get top points + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/advanced/patterns/pyramid-simple.jpeg + * @drawable true + */ + getTopPointsOfCells( + inputs: Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelCellsDto + ): Inputs.Base.Point3[]; + /** + * Gets the center point between cell corners + * @param inputs cells of the pyramid + * @returns Center points on the cells + * @group get from cells + * @shortname get center points + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/advanced/patterns/pyramid-simple.jpeg + * @drawable true + */ + getCenterPointsOfCells( + inputs: Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelCellsDto + ): Inputs.Base.Point3[]; + /** + * Gets the corner points of cells + * @param inputs cells of the pyramid + * @returns Corner points on cells provided + * @group get from cells + * @shortname get corner points of cells + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/advanced/patterns/pyramid-simple.jpeg + * @drawable false + */ + getCornerPointsOfCells( + inputs: Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelCellsDto + ): Inputs.Base.Point3[][]; + /** + * Gets the corner points of cells + * @param inputs cells of the pyramid + * @returns Corner points on cells provided + * @group get from cells + * @shortname get corner point of cells + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/advanced/patterns/pyramid-simple.jpeg + * @drawable true + */ + getCornerPointOfCells( + inputs: Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelCellsIndexDto + ): Inputs.Base.Point3[]; + /** + * Gets the corner normal of cells + * @param inputs cells of the pyramid + * @returns Corner normals on cells provided + * @group get from cells + * @shortname get corner normal of cells + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/advanced/patterns/pyramid-simple.jpeg + * @drawable false + */ + getCornerNormalOfCells( + inputs: Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelCellsIndexDto + ): Inputs.Base.Point3[]; + /** + * Gets the corner normals of cells + * @param inputs cells of the pyramid + * @returns Corner normals on cells provided + * @group get from cells + * @shortname get corner normals of cells + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/advanced/patterns/pyramid-simple.jpeg + * @drawable false + */ + getCornerNormalsOfCells( + inputs: Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelCellsDto + ): Inputs.Base.Point3[][]; + /** + * Gets the compound shapes of the pyramid cells + * @param inputs cells of the pyramid + * @returns Compound shapes on cells provided + * @group get from cells + * @shortname get compound shapes + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/advanced/patterns/pyramid-simple.jpeg + * @drawable true + */ + getCompoundShapesOfCells( + inputs: Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelCellsDto + ): Inputs.OCCT.TopoDSShapePointer[]; + /** + * Gets the face shapes of the pyramid cells provided + * @param inputs cells of the pyramid + * @returns Face shapes on cells provided + * @group get from cells + * @shortname get face shapes + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/advanced/patterns/pyramid-simple.jpeg + * @drawable true + */ + getFaceShapesOfCells( + inputs: Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelCellsIndexDto + ): Inputs.OCCT.TopoDSShapePointer[]; + /** + * Gets the face shapes of the pyramid cells provided + * @param inputs cells of the pyramid + * @returns Wire shapes on cells provided + * @group get from cells + * @shortname get wire shapes + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/advanced/patterns/pyramid-simple.jpeg + * @drawable true + */ + getWireShapesOfCells( + inputs: Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelCellsIndexDto + ): Inputs.OCCT.TopoDSShapePointer[]; + /** + * Gets the polyline wire along the start edge of the face's U direction + * @param inputs pyramid model and face index + * @returns Wire shapes + * @group get from face + * @shortname get start polyline wire u + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/advanced/patterns/pyramid-simple.jpeg + * @drawable true + */ + getStartPolylineWireU( + inputs: Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelFaceIndexDto + ): Inputs.OCCT.TopoDSShapePointer; + /** + * Gets the polyline wire along the end edge of the face's U direction + * @param inputs pyramid model and face index + * @returns Wire shapes + * @group get from face + * @shortname get end polyline wire u + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/advanced/patterns/pyramid-simple.jpeg + * @drawable true + */ + getEndPolylineWireU( + inputs: Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelFaceIndexDto + ): Inputs.OCCT.TopoDSShapePointer; + /** + * Gets the polyline wire along the start edge of the face's V direction + * @param inputs pyramid model and face index + * @returns Wire shapes + * @group get from face + * @shortname get start polyline wire v + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/advanced/patterns/pyramid-simple.jpeg + * @drawable true + */ + getStartPolylineWireV( + inputs: Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelFaceIndexDto + ): Inputs.OCCT.TopoDSShapePointer; + /** + * Gets the polyline wire along the end edge of the face's V direction + * @param inputs pyramid model and face index + * @returns Wire shapes + * @group get from face + * @shortname get end polyline wire v + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/advanced/patterns/pyramid-simple.jpeg + * @drawable true + */ + getEndPolylineWireV( + inputs: Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelFaceIndexDto + ): Inputs.OCCT.TopoDSShapePointer; + /** + * Gets the polyline wires along U direction + * @param inputs pyramid model and face index + * @returns Wire shapes + * @group get from face + * @shortname get compound polyline wires u + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/advanced/patterns/pyramid-simple.jpeg + * @drawable true + */ + getPolylineWiresUCompound( + inputs: Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelFaceIndexDto + ): Inputs.OCCT.TopoDSShapePointer; + /** + * Gets the polyline wires along V direction + * @param inputs pyramid model and face index + * @returns Wire shapes + * @group get from face + * @shortname get compound polyline wires v + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/advanced/patterns/pyramid-simple.jpeg + * @drawable true + */ + getPolylineWiresVCompound( + inputs: Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelFaceIndexDto + ): Inputs.OCCT.TopoDSShapePointer; + } + declare class Patterns { + private readonly occWorkerManager; + private readonly context; + private readonly draw; + facePatterns: FacePatterns; + constructor( + occWorkerManager: OCCTWorkerManager, + context: Context, + draw: Draw + ); + } + declare class Text3D { + private readonly occWorkerManager; + private readonly context; + private readonly draw; + constructor( + occWorkerManager: OCCTWorkerManager, + context: Context, + draw: Draw + ); + /** + * Creates a 3d text + * @param inputs + * @returns 3d text + * @group create + * @shortname create 3d text + * @drawable true + */ + create( + inputs: Advanced.Text3D.Text3DDto + ): Promise>; + /** + * Creates a 3d text with a font URL + * This is useful when you want to use a custom font that is not included in the library. + * The font will be loaded from the provided URL and used to generate the 3d text. + * Make sure that fonts do not contain self intersection and other bad characters - that is common issue with custom fonts. + * Font formats supported are: ttf, otf, woff. + * Please note that Woff2 is not supported by opentype.js as it is a compressed format. + * @param inputs + * @returns 3d text + * @group create + * @shortname create 3d text with url + * @drawable true + */ + createWithUrl( + inputs: Advanced.Text3D.Text3DUrlDto + ): Promise>; + /** + * Creates a 3d text on the face + * @param inputs + * @returns 3d text + * @group create + * @shortname create 3d text on face + * @drawable true + */ + createTextOnFace( + inputs: Advanced.Text3D.Text3DFaceDto + ): Promise>; + /** + * Creates a 3d text on the face using a font URL. + * This is useful when you want to use a custom font that is not included in the library. + * The font will be loaded from the provided URL and used to generate the 3d text. + * Make sure that fonts do not contain self intersection and other bad characters - that is common issue with custom fonts. + * Font formats supported are: ttf, otf, woff. + * Please note that Woff2 is not supported by opentype.js as it is a compressed format. + * @param inputs + * @returns 3d text + * @group create + * @shortname create 3d text on face url + * @drawable true + */ + createTextOnFaceUrl( + inputs: Advanced.Text3D.Text3DFaceUrlDto + ): Promise>; + /** + * Creates 3d texts on the face from multiple definitions + * @param inputs + * @returns 3d text + * @group create + * @shortname create 3d texts on face + * @drawable true + */ + createTextsOnFace( + inputs: Advanced.Text3D.Texts3DFaceDto + ): Promise>; + /** + * Creates 3d texts on the face from multiple url definitions + * This is useful when you want to use a custom font that is not included in the library. + * The font will be loaded from the provided URL and used to generate the 3d text. + * Make sure that fonts do not contain self intersection and other bad characters - that is common issue with custom fonts. + * Font formats supported are: ttf, otf, woff. + * Please note that Woff2 is not supported by opentype.js as it is a compressed format. + * @param inputs + * @returns 3d text + * @group create + * @shortname create 3d texts on face url + * @drawable true + */ + createTextsOnFaceUrl( + inputs: Advanced.Text3D.Texts3DFaceUrlDto + ): Promise>; + /** + * Creates 3d text that will be used on the face defintion + * @param inputs + * @returns definition + * @group definitions + * @shortname 3d text face def + * @drawable false + */ + definition3dTextOnFace( + inputs: Advanced.Text3D.Text3DFaceDefinitionDto + ): Advanced.Text3D.Text3DFaceDefinitionDto; + /** + * Creates 3d text that will be used on the face url defintion + * This is useful when you want to use a custom font that is not included in the library. + * The font will be loaded from the provided URL and used to generate the 3d text. + * Make sure that fonts do not contain self intersection and other bad characters - that is common issue with custom fonts. + * Font formats supported are: ttf, otf, woff. + * Please note that Woff2 is not supported by opentype.js as it is a compressed format. + * @param inputs + * @returns definition + * @group definitions + * @shortname 3d text face url def + * @drawable false + */ + definition3dTextOnFaceUrl( + inputs: Advanced.Text3D.Text3DFaceDefinitionUrlDto + ): Advanced.Text3D.Text3DFaceDefinitionUrlDto; + /** + * Draws 3d text on the screen + * @param inputs Contains a model shapes to be drawn and additional information + * @returns BabylonJS Mesh + * @group drawing + * @shortname draw shape + * @drawable false + * @ignore true + */ + drawModel( + inputs: Advanced.Text3D.Text3DData, + precision?: number + ): Promise; + /** + * Gets compounded shape of the 3d text result + * @param inputs + * @returns compounded OCCT shape + * @group get + * @shortname compound shape + * @drawable true + */ + getCompoundShape( + inputs: Advanced.Text3D.Text3DModelDto + ): Inputs.OCCT.TopoDSShapePointer; + /** + * Gets the character shape at particular index + * @param inputs + * @returns character OCCT shape of the 3d text result at index + * @group get + * @shortname character shape + * @drawable true + */ + getCharacterShape( + inputs: Advanced.Text3D.Text3DLetterByIndexDto + ): Inputs.OCCT.TopoDSShapePointer; + /** + * Gets character shapes of the 3d text result + * @param inputs + * @returns character OCCT shapes of the 3d text result + * @group get + * @shortname character shapes + * @drawable true + */ + getCharacterShapes( + inputs: Advanced.Text3D.Text3DModelDto + ): Inputs.OCCT.TopoDSShapePointer[]; + /** + * Gets the center of mass coordinates of all characters + * @param inputs + * @returns character coordinates as points + * @group get + * @shortname character coordinates + * @drawable true + */ + getCharacterCenterCoordinates( + inputs: Advanced.Text3D.Text3DModelDto + ): Inputs.Base.Point3[]; + /** + * Gets the face cutout from text 3d that was created on the face + * @param inputs + * @returns character coordinates as points + * @group get from face + * @shortname face cutout + * @drawable true + */ + getFaceCutout( + inputs: Advanced.Text3D.Text3DModelDto + ): Inputs.OCCT.TopoDSShapePointer; + /** + * Gets all of the face cutouts from text 3d that was created on the original face + * @param inputs + * @returns character coordinates as points + * @group get from face + * @shortname get all coutout faces + * @drawable true + */ + getAllFacesOfCutout( + inputs: Advanced.Text3D.Text3DModelDto + ): Inputs.OCCT.TopoDSShapePointer[]; + /** + * Gets character face cutouts from text 3d that was created on the original face + * @param inputs + * @returns character coordinates as points + * @group get from face + * @shortname get faces in characters + * @drawable true + */ + getCutoutsInsideCharacters( + inputs: Advanced.Text3D.Text3DModelDto + ): Inputs.OCCT.TopoDSShapePointer[]; + /** + * Get advance width + * @param inputs + * @returns width dimension + * @group dimensions + * @shortname get advance width + * @drawable false + */ + getAdvanceWidth( + inputs: Advanced.Text3D.Text3DModelDto + ): number; + } + declare class ContextComplete extends Context { + advancedDynamicTextureForFullscreenUI: GUI.AdvancedDynamicTexture; + pointsOfInterestSystem: { + observer: BABYLON.Observer; + pois: BABYLON.Nullable[]; + cameraManager: CameraManager; + }; + dimensionsSystem: { + dimensionManager: DimensionManager; + }; + } + declare class DrawComplete extends Draw { + /** + * @ignore true + */ + readonly drawHelper: DrawHelper; + /** + * @ignore true + */ + readonly node: BabylonNode; + /** + * @ignore true + */ + readonly tag: Tag; + /** + * @ignore true + */ + private readonly things; + /** + * @ignore true + */ + private readonly advanced; + /** + * @ignore true + */ + readonly context: Context; + constructor( + /** + * @ignore true + */ + drawHelper: DrawHelper, + /** + * @ignore true + */ + node: BabylonNode, + /** + * @ignore true + */ + tag: Tag, + /** + * @ignore true + */ + things: ThingsAdv, + /** + * @ignore true + */ + advanced: AdvancedAdv, + /** + * @ignore true + */ + context: Context + ); + /** + * Draws any kind of geometry after all input promises are resolved. Inputs can also be non-promise like. + * @param inputs Contains options and entities to be drawn + * @returns BabylonJS Mesh Promise + * @group draw + * @shortname draw anything + * @disposableOutput true + */ + drawAnyAsync(inputs: Inputs.Draw.DrawAny): Promise; + /** + * Draws a grid mesh on the ground plane in 3D space. This helps to orient yourself in the world. + * @param inputs Describes various parameters of the grid mesh like size, colour, etc. + * @group draw + * @shortname draw grid + * @disposableOutput true + */ + drawGridMesh(inputs: Inputs.Draw.SceneDrawGridMeshDto): BABYLON.Mesh; + /** + * Creates draw options for basic geometry types like points, lines, polylines, surfaces and jscad meshes + * @param inputs option definition + * @returns options + * @group options + * @shortname simple + */ + optionsSimple( + inputs: Inputs.Draw.DrawBasicGeometryOptions + ): Inputs.Draw.DrawBasicGeometryOptions; + /** + * Creates draw options for occt shape geometry like edges, wires, faces, shells, solids and compounds + * @param inputs option definition + * @returns options + * @group options + * @shortname occt shape + */ + optionsOcctShape( + inputs: Inputs.Draw.DrawOcctShapeOptions + ): Inputs.Draw.DrawOcctShapeOptions; + /** + * Creates draw options for babylon js nodes + * @param inputs option definition + * @returns options + * @group options + * @shortname babylon node + */ + optionsBabylonNode( + inputs: Inputs.Draw.DrawNodeOptions + ): Inputs.Draw.DrawNodeOptions; + } + declare class CreateMaterialDto { + constructor(s: CreateMaterialDto); + name: string; + scene: BABYLON.Scene | undefined; + wAng?: number; + uScale?: number; + vScale?: number; + color?: string; + albedoTextureUrl?: string; + microSurfaceTextureUrl?: string; + bumpTextureUrl?: string; + metallic: number; + roughness: number; + zOffset: number; + } + declare class MaterialsService { + static textures: { + wood1: { + microSurfaceTexture: string; + light: { + albedo: string; + }; + dark: { + albedo: string; + }; + }; + wood2: { + microSurfaceTexture: string; + light: { + albedo: string; + }; + }; + metal1: { + microSurfaceTexture: string; + light: { + albedo: string; + normalGL: string; + roughness: string; + metalness: string; + }; + }; + brownPlanks: { + microSurfaceTexture: string; + light: { + albedo: string; + }; + }; + woodenPlanks: { + microSurfaceTexture: string; + light: { + albedo: string; + }; + }; + brushedConcrete: { + microSurfaceTexture: string; + sand: { + albedo: string; + }; + grey: { + albedo: string; + }; + }; + rock1: { + microSurfaceTexture: string; + default: { + albedo: string; + roughness: string; + }; + }; + }; + static simpleBlackMaterial(scene: any): BABYLON.PBRMaterial; + static rock1Material( + scene: BABYLON.Scene, + wAng: number, + scale: number + ): BABYLON.PBRMaterial; + static wood1Material( + scene: BABYLON.Scene, + wAng: number, + scale: number + ): BABYLON.PBRMaterial; + static wood2Material( + scene: BABYLON.Scene, + wAng: number, + scale: number + ): BABYLON.PBRMaterial; + static wood3Material( + scene: BABYLON.Scene, + wAng: number, + scale: number + ): BABYLON.PBRMaterial; + static brownPlanks( + scene: BABYLON.Scene, + wAng: number, + scale: number + ): BABYLON.PBRMaterial; + static woodenPlanks( + scene: BABYLON.Scene, + wAng: number, + scale: number + ): BABYLON.PBRMaterial; + static glass( + scene: BABYLON.Scene, + albedoColor: string + ): BABYLON.PBRMaterial; + static brushedConcrete( + scene: BABYLON.Scene, + wAng: number, + scale: number + ): BABYLON.PBRMaterial; + static metal1( + scene: BABYLON.Scene, + wAng: number, + scale: number + ): BABYLON.PBRMaterial; + static roughPlastic( + scene: BABYLON.Scene, + color: string + ): BABYLON.PBRMaterial; + private static createMaterial; + private static createTexture; + } + declare class ThreeDPrinting { + private readonly occWorkerManager; + private readonly context; + private readonly draw; + private readonly occt; + vases: Vases; + medals: Medals; + cups: Cups; + desktop: Desktop; + constructor( + occWorkerManager: OCCTWorkerManager, + context: Context, + draw: Draw, + occt: OCCTW + ); + } + declare class Boxes { + private readonly occWorkerManager; + private readonly context; + private readonly draw; + spicyBox: SpicyBox; + constructor( + occWorkerManager: OCCTWorkerManager, + context: Context, + draw: Draw + ); + } + declare class SpicyBox { + private readonly occWorkerManager; + private readonly context; + private readonly draw; + constructor( + occWorkerManager: OCCTWorkerManager, + context: Context, + draw: Draw + ); + /** + * Creates a spicy box model for your spices + * @param inputs + * @returns Spicy box model + * @group create + * @shortname spicy box + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/3dprinting/cups/dragon-cup.jpeg + * @drawable true + */ + create( + inputs: Things.ThreeDPrinting.Boxes.SpicyBox.SpicyBoxDto + ): Promise< + Things.ThreeDPrinting.Boxes.SpicyBox.SpicyBoxData + >; + /** + * Gets the compound shape of the spicy box + * @param inputs + * @returns Compound shape of the spicy box model + * @group get shapes + * @shortname compound + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/3dprinting/cups/dragon-cup.jpeg + * @drawable true + */ + getCompoundShape( + inputs: Things.ThreeDPrinting.Boxes.SpicyBox.SpicyBoxModelDto + ): Inputs.OCCT.TopoDSShapePointer; + /** + * Draws spicy box model in default settings + * @param inputs Contains a model shapes to be drawn and additional information + * @returns BabylonJS Mesh + * @group drawing + * @shortname draw shape + * @drawable false + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/3dprinting/cups/dragon-cup.jpeg + * @ignore true + */ + drawModel( + inputs: Things.ThreeDPrinting.Boxes.SpicyBox.SpicyBoxData + ): Promise; + } + declare class CalmCup { + private readonly occWorkerManager; + private readonly context; + private readonly draw; + private readonly occt; + constructor( + occWorkerManager: OCCTWorkerManager, + context: Context, + draw: Draw, + occt: OCCTW + ); + /** + * Creates a cup model for your calm moments + * @param inputs + * @returns Calm cup model + * @group create + * @shortname calm cup + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/3dprinting/cups/calm-cup.jpeg + * @drawable true + */ + create( + inputs: Things.ThreeDPrinting.Cups.CalmCup.CalmCupDto + ): Promise< + Things.ThreeDPrinting.Cups.CalmCup.CalmCupData + >; + /** + * Draws calm cup model in default settings + * @param inputs Contains a model shapes to be drawn and additional information + * @returns BabylonJS Mesh + * @group drawing + * @shortname draw shape + * @drawable false + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/3dprinting/cups/calm-cup.jpeg + * @ignore true + */ + drawModel( + inputs: Things.ThreeDPrinting.Cups.CalmCup.CalmCupData + ): Promise; + /** + * Disposes a cup model + * @param inputs Contains a model shapes to be disposed and additional information + * @group drawing + * @shortname dispose calm cup + * @drawable false + * @ignore true + */ + dispose( + inputs: Things.ThreeDPrinting.Vases.SerenitySwirl.SerenitySwirlData + ): Promise; + } + declare class Cups { + private readonly occWorkerManager; + private readonly context; + private readonly draw; + private readonly occt; + calmCup: CalmCup; + dragonCup: DragonCup; + constructor( + occWorkerManager: OCCTWorkerManager, + context: Context, + draw: Draw, + occt: OCCTW + ); + } + declare class DragonCup { + private readonly occWorkerManager; + private readonly context; + private readonly draw; + constructor( + occWorkerManager: OCCTWorkerManager, + context: Context, + draw: Draw + ); + /** + * Creates a cup model for your inner dragon + * @param inputs + * @returns Dragon cup model + * @group create + * @shortname dragon cup + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/3dprinting/cups/dragon-cup.jpeg + * @drawable true + */ + create( + inputs: Things.ThreeDPrinting.Cups.DragonCup.DragonCupDto + ): Promise< + Things.ThreeDPrinting.Cups.DragonCup.DragonCupData + >; + /** + * Gets the compound shape of the dragon cup + * @param inputs + * @returns Compound shape of the dragon cup model + * @group get shapes + * @shortname compound + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/3dprinting/cups/dragon-cup.jpeg + * @drawable true + */ + getCompoundShape( + inputs: Things.ThreeDPrinting.Cups.DragonCup.DragonCupModelDto + ): Inputs.OCCT.TopoDSShapePointer; + /** + * Draws dragon cup model in default settings + * @param inputs Contains a model shapes to be drawn and additional information + * @returns BabylonJS Mesh + * @group drawing + * @shortname draw shape + * @drawable false + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/3dprinting/cups/dragon-cup.jpeg + * @ignore true + */ + drawModel( + inputs: Things.ThreeDPrinting.Cups.DragonCup.DragonCupData + ): Promise; + } + declare class Desktop { + private readonly occWorkerManager; + private readonly context; + private readonly draw; + private readonly occt; + phoneNest: PhoneNest; + constructor( + occWorkerManager: OCCTWorkerManager, + context: Context, + draw: Draw, + occt: OCCTW + ); + } + declare class PhoneNest { + private readonly occWorkerManager; + private readonly context; + private readonly draw; + private readonly occt; + private materials; + constructor( + occWorkerManager: OCCTWorkerManager, + context: Context, + draw: Draw, + occt: OCCTW + ); + /** + * Creates a phone nest model + * @param inputs + * @returns phone nest model + * @group create + * @shortname phone nest + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/3dprinting/desktop/phone-nest.jpeg + * @drawable true + */ + create( + inputs: Things.ThreeDPrinting.Desktop.PhoneNest.PhoneNestDto + ): Promise< + Things.ThreeDPrinting.Desktop.PhoneNest.PhoneNestData + >; + /** + * Gets the compound shape of the phone nest + * @param inputs + * @returns Compound shape of the phone nest model + * @group get shapes + * @shortname compound + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/3dprinting/desktop/phone-nest.jpeg + * @drawable true + */ + getCompoundShape( + inputs: Things.ThreeDPrinting.Desktop.PhoneNest.PhoneNestModelDto + ): Inputs.OCCT.TopoDSShapePointer; + /** + * Creates draw options for model + * @param inputs + * @returns Draw options + * @group draw + * @shortname phone nest draw options + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/3dprinting/desktop/phone-nest.jpeg + * @drawable false + */ + drawOptions( + inputs: Things.ThreeDPrinting.Desktop.PhoneNest.PhoneNestDrawDto + ): Things.ThreeDPrinting.Desktop.PhoneNest.PhoneNestDrawDto; + /** + * Draws phone nest model in default settings + * @param model Contains a model shapes to be drawn and additional information + * @returns BabylonJS Mesh + * @group drawing + * @shortname draw shape + * @drawable false + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/3dprinting/desktop/phone-nest.jpeg + * @ignore true + */ + drawModel( + model: Things.ThreeDPrinting.Desktop.PhoneNest.PhoneNestData, + options: Things.ThreeDPrinting.Desktop.PhoneNest.PhoneNestDrawDto + ): Promise; + /** + * Disposes a model + * @param inputs Contains a model shapes to be disposed and additional information + * @group drawing + * @shortname dispose phone nest + * @drawable false + * @ignore true + */ + dispose( + inputs: Things.ThreeDPrinting.Desktop.PhoneNest.PhoneNestData + ): Promise; + /** + * Creates materials + * @param inputs Contains a model shapes to be disposed and additional information + * @group drawing + * @shortname creates default materials + * @drawable false + * @ignore true + */ + private createMaterials; + } + declare class EternalLove { + private readonly occWorkerManager; + private readonly context; + private readonly draw; + private readonly occt; + constructor( + occWorkerManager: OCCTWorkerManager, + context: Context, + draw: Draw, + occt: OCCTW + ); + /** + * Creates a eternal love medal model + * @param inputs + * @returns Eternal love model + * @group create + * @shortname eternal love + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/3dprinting/Medals/EternalLove.jpeg + * @drawable true + */ + create( + inputs: Things.ThreeDPrinting.Medals.EternalLove.EternalLoveDto + ): Promise< + Things.ThreeDPrinting.Medals.EternalLove.EternalLoveData + >; + /** + * Draws wingtip villa in default settings + * @param inputs Contains a model shapes to be drawn and additional information + * @returns BabylonJS Mesh + * @group drawing + * @shortname draw shape + * @drawable false + * @ignore true + */ + drawModel( + inputs: Things.ThreeDPrinting.Medals.EternalLove.EternalLoveData, + precision?: number + ): Promise; + /** + * Disposes a wingtip villa model objects + * @param inputs Contains a model shapes to be disposed and additional information + * @group drawing + * @shortname dispose wingtip villa + * @drawable false + * @ignore true + */ + dispose( + inputs: Things.ThreeDPrinting.Vases.SerenitySwirl.SerenitySwirlData + ): Promise; + } + declare class Medals { + private readonly occWorkerManager; + private readonly context; + private readonly draw; + private readonly occt; + eternalLove: EternalLove; + constructor( + occWorkerManager: OCCTWorkerManager, + context: Context, + draw: Draw, + occt: OCCTW + ); + } + declare class ArabicArchway { + private readonly occWorkerManager; + private readonly context; + private readonly draw; + private readonly occt; + private materials; + constructor( + occWorkerManager: OCCTWorkerManager, + context: Context, + draw: Draw, + occt: OCCTW + ); + /** + * Creates a arabic archway vase + * @param inputs + * @returns Arabic archway mesh + * @group create + * @shortname arabic archway + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/3dprinting/Vases/ArabicArchway.jpeg + * @drawable true + */ + create( + inputs: Things.ThreeDPrinting.Vases.ArabicArchway.ArabicArchwayDto + ): Promise< + Things.ThreeDPrinting.Vases.ArabicArchway.ArabicArchwayData + >; + /** + * Draws arabic archway in default settings + * @param inputs Contains a model shapes to be drawn and additional information + * @returns BabylonJS Mesh + * @group drawing + * @shortname draw shape + * @drawable false + * @ignore true + */ + drawModel( + model: Things.ThreeDPrinting.Vases.ArabicArchway.ArabicArchwayData, + precision?: number + ): Promise; + /** + * Disposes a arabic archway model objects + * @param inputs Contains a model shapes to be disposed and additional information + * @group drawing + * @shortname dispose arabic archway + * @drawable false + * @ignore true + */ + dispose( + inputs: Things.ThreeDPrinting.Vases.ArabicArchway.ArabicArchwayData + ): Promise; + private createMaterials; + private createOpaqueMaterial; + private createBaseMaterial; + private createGlassMaterial; + } + declare class SerenitySwirl { + private readonly occWorkerManager; + private readonly context; + private readonly draw; + private readonly occt; + constructor( + occWorkerManager: OCCTWorkerManager, + context: Context, + draw: Draw, + occt: OCCTW + ); + /** + * Creates a serenity swirl + * @param inputs + * @returns Serenity swirl mesh + * @group create + * @shortname serenity swirl + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/3dprinting/Vases/SerenitySwirl.webp + * @drawable true + */ + create( + inputs: Things.ThreeDPrinting.Vases.SerenitySwirl.SerenitySwirlDto + ): Promise< + Things.ThreeDPrinting.Vases.SerenitySwirl.SerenitySwirlData + >; + /** + * Draws wingtip villa in default settings + * @param inputs Contains a model shapes to be drawn and additional information + * @returns BabylonJS Mesh + * @group drawing + * @shortname draw shape + * @drawable false + * @ignore true + */ + drawModel( + inputs: Things.ThreeDPrinting.Vases.SerenitySwirl.SerenitySwirlData, + precision?: number + ): Promise; + /** + * Disposes a wingtip villa model objects + * @param inputs Contains a model shapes to be disposed and additional information + * @group drawing + * @shortname dispose wingtip villa + * @drawable false + * @ignore true + */ + dispose( + inputs: Things.ThreeDPrinting.Vases.SerenitySwirl.SerenitySwirlData + ): Promise; + } + declare class Vases { + private readonly occWorkerManager; + private readonly context; + private readonly draw; + private readonly occt; + serenitySwirl: SerenitySwirl; + arabicArchway: ArabicArchway; + constructor( + occWorkerManager: OCCTWorkerManager, + context: Context, + draw: Draw, + occt: OCCTW + ); + } + declare class Architecture { + private readonly occWorkerManager; + private readonly context; + private readonly draw; + private readonly occt; + houses: Houses; + constructor( + occWorkerManager: OCCTWorkerManager, + context: Context, + draw: Draw, + occt: OCCTW + ); + } + declare class Houses { + private readonly occWorkerManager; + private readonly context; + private readonly draw; + private readonly occt; + zenHideout: ZenHideout; + constructor( + occWorkerManager: OCCTWorkerManager, + context: Context, + draw: Draw, + occt: OCCTW + ); + } + declare class ZenHideout { + private readonly occWorkerManager; + private readonly context; + private readonly draw; + private readonly occt; + private materials; + skin: Things.Architecture.Houses.ZenHideout.ZenHideoutDrawingPartShapes; + constructor( + occWorkerManager: OCCTWorkerManager, + context: Context, + draw: Draw, + occt: OCCTW + ); + /** + * Creates a zen hideout + * @param inputs + * @returns Zen hideout mesh + * @group create + * @shortname zen hideout + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/architecture/Houses/ZenHideout.jpeg + * @drawable true + */ + create( + inputs: Things.Architecture.Houses.ZenHideout.ZenHideoutDto + ): Promise< + Things.Architecture.Houses.ZenHideout.ZenHideoutData + >; + /** + * Draws wingtip villa in default settings + * @param model Contains a model shapes to be drawn and additional information + * @returns BabylonJS Mesh + * @group drawing + * @shortname draw shape + * @drawable false + * @ignore true + */ + drawModel( + model: Things.Architecture.Houses.ZenHideout.ZenHideoutData, + precision?: number + ): Promise; + /** + * Disposes a zen hideout model objects + * @param inputs Contains a model shapes to be disposed and additional information + * @group drawing + * @shortname dispose zen hideout + * @drawable false + * @ignore true + */ + dispose( + inputs: Things.Architecture.Houses.ZenHideout.ZenHideoutData + ): Promise; + /** + * Creates materials + * @param inputs Contains a model shapes to be disposed and additional information + * @group drawing + * @shortname creates default materials for zen hideout + * @drawable false + * @ignore true + */ + private createMaterials; + private createSkin; + } + declare class Enums { + /** + * Creates a level of detail enumeration value + * @param inputs + * @returns level of detail + * @group enums + * @shortname lod + * @drawable false + */ + lodEnum(inputs: Things.Enums.LodDto): Things.Enums.lodEnum; + } + declare class Chairs { + private readonly occWorkerManager; + private readonly context; + private readonly draw; + private readonly occt; + snakeChair: SnakeChair; + constructor( + occWorkerManager: OCCTWorkerManager, + context: Context, + draw: Draw, + occt: OCCTW + ); + } + declare class SnakeChair { + private readonly occWorkerManager; + private readonly context; + private readonly draw; + private readonly occt; + private materials; + constructor( + occWorkerManager: OCCTWorkerManager, + context: Context, + draw: Draw, + occt: OCCTW + ); + /** + * Creates a snake chair model + * @param inputs + * @returns Snake chair model + * @group create + * @shortname snake chair + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/chairs/snake-chair.jpeg + * @drawable true + */ + create( + inputs: Things.Furniture.Chairs.SnakeChair.SnakeChairDto + ): Promise< + Things.Furniture.Chairs.SnakeChair.SnakeChairData + >; + /** + * Gets the compound shape of the chair + * @param inputs + * @returns Compound shape of the snake chair model + * @group get shapes + * @shortname compound + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/chairs/snake-chair.jpeg + * @drawable true + */ + getCompoundShape( + inputs: Things.Furniture.Chairs.SnakeChair.SnakeChairModelDto + ): Inputs.OCCT.TopoDSShapePointer; + /** + * Gets the wire shape of the chair sitting area + * @param inputs + * @returns Wire shape of the sitting area + * @group get shapes + * @shortname get sitting wire + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/chairs/snake-chair.jpeg + * @drawable true + */ + getSittingWireShape( + inputs: Things.Furniture.Chairs.SnakeChair.SnakeChairModelDto + ): Inputs.OCCT.TopoDSShapePointer; + /** + * Gets the center point of the chair sitting area + * @param inputs + * @returns The point on the center of the sitting area + * @group get points + * @shortname get sitting area center + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/chairs/snake-chair.jpeg + * @drawable true + */ + getSittingAreaCenterPoint( + inputs: Things.Furniture.Chairs.SnakeChair.SnakeChairModelDto + ): Inputs.Base.Point3; + /** + * Creates draw options for snake chair + * @param inputs + * @returns Draw options + * @group draw + * @shortname snake chair draw options + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/chairs/snake-chair.jpeg + * @drawable false + */ + drawOptions( + inputs: Things.Furniture.Chairs.SnakeChair.SnakeChairDrawDto + ): Things.Furniture.Chairs.SnakeChair.SnakeChairDrawDto; + /** + * Draws snake chair model in default settings + * @param model Contains a model shapes to be drawn and additional information + * @returns BabylonJS Mesh + * @group drawing + * @shortname draw shape + * @drawable false + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/chairs/snake-chair.jpeg + * @ignore true + */ + drawModel( + model: Things.Furniture.Chairs.SnakeChair.SnakeChairData, + options: Things.Furniture.Chairs.SnakeChair.SnakeChairDrawDto + ): Promise; + /** + * Disposes a cup model + * @param inputs Contains a model shapes to be disposed and additional information + * @group drawing + * @shortname dispose calm cup + * @drawable false + * @ignore true + */ + dispose( + inputs: Things.Furniture.Chairs.SnakeChair.SnakeChairData + ): Promise; + /** + * Creates materials + * @param inputs Contains a model shapes to be disposed and additional information + * @group drawing + * @shortname creates default materials for zen hideout + * @drawable false + * @ignore true + */ + private createMaterials; + } + declare class Furniture { + private readonly occWorkerManager; + private readonly context; + private readonly draw; + private readonly occt; + chairs: Chairs; + tables: Tables; + constructor( + occWorkerManager: OCCTWorkerManager, + context: Context, + draw: Draw, + occt: OCCTW + ); + } + declare class ElegantTable { + private readonly occWorkerManager; + private readonly context; + private readonly draw; + private readonly occt; + private materials; + constructor( + occWorkerManager: OCCTWorkerManager, + context: Context, + draw: Draw, + occt: OCCTW + ); + /** + * Creates an elegant table model + * @param inputs + * @returns Elegant table model + * @group create + * @shortname elegant table + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/elegant-table.jpeg + * @drawable true + */ + create( + inputs: Things.Furniture.Tables.ElegantTable.ElegantTableDto + ): Promise< + Things.Furniture.Tables.ElegantTable.ElegantTableData + >; + /** + * Gets the compound shape of the table + * @param inputs + * @returns Compound shape of the elegant table model + * @group get shapes + * @shortname compound + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/elegant-table.jpeg + * @drawable true + */ + getCompoundShape( + inputs: Things.Furniture.Tables.ElegantTable.ElegantTableModelDto + ): Inputs.OCCT.TopoDSShapePointer; + /** + * Gets the leg shapes as a list + * @param inputs + * @returns Leg shapes of the table + * @group get shapes + * @shortname legs + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/elegant-table.jpeg + * @drawable true + */ + getLegShapes( + inputs: Things.Furniture.Tables.ElegantTable.ElegantTableModelDto + ): Inputs.OCCT.TopoDSShapePointer[]; + /** + * Gets the leg shape by index + * @param inputs + * @returns Leg shapes of the table + * @group get shapes + * @shortname leg by index + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/elegant-table.jpeg + * @drawable true + */ + getLegShapeByIndex( + inputs: Things.Furniture.Tables.ElegantTable.ElegantTableLegByIndexDto + ): Inputs.OCCT.TopoDSShapePointer; + /** + * Gets the table top panel shape + * @param inputs + * @returns Top panel shape of the table + * @group get shapes + * @shortname top panel + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/elegant-table.jpeg + * @drawable true + */ + getTopPanelShape( + inputs: Things.Furniture.Tables.ElegantTable.ElegantTableModelDto + ): Inputs.OCCT.TopoDSShapePointer; + /** + * Gets the table top panel wire shape + * @param inputs + * @returns Top panel wire shape of the table + * @group get shapes + * @shortname top panel wire + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/elegant-table.jpeg + * @drawable true + */ + getTopPanelWireShape( + inputs: Things.Furniture.Tables.ElegantTable.ElegantTableModelDto + ): Inputs.OCCT.TopoDSShapePointer; + /** + * Gets the table bottom panel wire shape + * @param inputs + * @returns Bottom panel wire shape of the table + * @group get shapes + * @shortname bottom panel wire + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/elegant-table.jpeg + * @drawable true + */ + getBottomPanelWireShape( + inputs: Things.Furniture.Tables.ElegantTable.ElegantTableModelDto + ): Inputs.OCCT.TopoDSShapePointer; + /** + * Gets the table bottom panel shape + * @param inputs + * @returns Bottom panel shape of the table + * @group get shapes + * @shortname bottom panel + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/elegant-table.jpeg + * @drawable true + */ + getBottomPanelShape( + inputs: Things.Furniture.Tables.ElegantTable.ElegantTableModelDto + ): Inputs.OCCT.TopoDSShapePointer; + /** + * Gets the leg shapes as a compound shape + * @param inputs + * @returns Compound shape of the legs + * @group get shapes + * @shortname legs compound + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/elegant-table.jpeg + * @drawable true + */ + getLegsCompoundShape( + inputs: Things.Furniture.Tables.ElegantTable.ElegantTableModelDto + ): Inputs.OCCT.TopoDSShapePointer; + /** + * Gets the top center point + * @param inputs + * @returns Top center point + * @group get points + * @shortname top center point + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/elegant-table.jpeg + * @drawable true + */ + getTableTopCenterPoint( + inputs: Things.Furniture.Tables.ElegantTable.ElegantTableModelDto + ): Inputs.Base.Point3; + /** + * Gets the bottom center point + * @param inputs + * @returns Bottom center point + * @group get points + * @shortname bottom center point + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/elegant-table.jpeg + * @drawable true + */ + getTableBottomCenterPoint( + inputs: Things.Furniture.Tables.ElegantTable.ElegantTableModelDto + ): Inputs.Base.Point3; + /** + * Gets the leg bottom points + * @param inputs + * @returns Bottom points + * @group get points + * @shortname leg bottom points + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/elegant-table.jpeg + * @drawable true + */ + getLegBottomPoints( + inputs: Things.Furniture.Tables.ElegantTable.ElegantTableModelDto + ): Inputs.Base.Point3[]; + /** + * Gets the leg top points + * @param inputs + * @returns Top points + * @group get points + * @shortname leg top points + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/elegant-table.jpeg + * @drawable true + */ + getLegTopPoints( + inputs: Things.Furniture.Tables.ElegantTable.ElegantTableModelDto + ): Inputs.Base.Point3[]; + /** + * Creates draw options for elegant table + * @param inputs + * @returns Draw options + * @group draw + * @shortname elegant table draw options + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/elegant-table.jpeg + * @drawable false + */ + drawOptions( + inputs: Things.Furniture.Tables.ElegantTable.ElegantTableDrawDto + ): Things.Furniture.Tables.ElegantTable.ElegantTableDrawDto; + /** + * Draws elegant table model in default settings + * @param model Contains a model shapes to be drawn and additional information + * @returns BabylonJS Mesh + * @group drawing + * @shortname draw shape + * @drawable false + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/elegant-table.jpeg + * @ignore true + */ + drawModel( + model: Things.Furniture.Tables.ElegantTable.ElegantTableData, + options: Things.Furniture.Tables.ElegantTable.ElegantTableDrawDto + ): Promise; + /** + * Disposes a cup model + * @param inputs Contains a model shapes to be disposed and additional information + * @group drawing + * @shortname dispose calm cup + * @drawable false + * @ignore true + */ + dispose( + inputs: Things.Furniture.Tables.ElegantTable.ElegantTableData + ): Promise; + /** + * Creates materials + * @param inputs Contains a model shapes to be disposed and additional information + * @group drawing + * @shortname creates default materials for zen hideout + * @drawable false + * @ignore true + */ + private createMaterials; + } + declare class GoodCoffeeTable { + private readonly occWorkerManager; + private readonly context; + private readonly draw; + private readonly occt; + private materials; + constructor( + occWorkerManager: OCCTWorkerManager, + context: Context, + draw: Draw, + occt: OCCTW + ); + /** + * Creates an good coffee table model + * @param inputs + * @returns Good coffee table model + * @group create + * @shortname good coffee table + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/good-coffee-table.jpeg + * @drawable true + */ + create( + inputs: Things.Furniture.Tables.GoodCoffeeTable.GoodCoffeeTableDto + ): Promise< + Things.Furniture.Tables.GoodCoffeeTable.GoodCoffeeTableData + >; + /** + * Gets the compound shape of the table + * @param inputs + * @returns Compound shape of the elegant table model + * @group get shapes + * @shortname get compound + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/good-coffee-table.jpeg + * @drawable true + */ + getCompoundShape( + inputs: Things.Furniture.Tables.GoodCoffeeTable.GoodCoffeeTableModelDto + ): Inputs.OCCT.TopoDSShapePointer; + /** + * Gets the leg shapes as a list + * @param inputs + * @returns Leg shapes of the table + * @group get shapes + * @shortname get legs + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/good-coffee-table.jpeg + * @drawable true + */ + getLegShapes( + inputs: Things.Furniture.Tables.GoodCoffeeTable.GoodCoffeeTableModelDto + ): Inputs.OCCT.TopoDSShapePointer[]; + /** + * Gets the leg shape by index + * @param inputs + * @returns Leg shapes of the table + * @group get shapes + * @shortname get leg by index + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/good-coffee-table.jpeg + * @drawable true + */ + getLegShapeByIndex( + inputs: Things.Furniture.Tables.GoodCoffeeTable.GoodCoffeeTableLegByIndexDto + ): Inputs.OCCT.TopoDSShapePointer; + /** + * Gets the table top panel shape + * @param inputs + * @returns Top panel shape of the table + * @group get shapes + * @shortname get top panel + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/good-coffee-table.jpeg + * @drawable true + */ + getTopPanelShape( + inputs: Things.Furniture.Tables.GoodCoffeeTable.GoodCoffeeTableModelDto + ): Inputs.OCCT.TopoDSShapePointer; + /** + * Gets the table top panel wire shape + * @param inputs + * @returns Top panel wire shape of the table + * @group get shapes + * @shortname get top panel wire + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/good-coffee-table.jpeg + * @drawable true + */ + getTopPanelWireShape( + inputs: Things.Furniture.Tables.GoodCoffeeTable.GoodCoffeeTableModelDto + ): Inputs.OCCT.TopoDSShapePointer; + /** + * Gets the table glass panel shape + * @param inputs + * @returns Glass panel shape of the table + * @group get shapes + * @shortname get glass panel + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/good-coffee-table.jpeg + * @drawable true + */ + getGlassPanelShape( + inputs: Things.Furniture.Tables.GoodCoffeeTable.GoodCoffeeTableModelDto + ): Inputs.OCCT.TopoDSShapePointer; + /** + * Gets the table glass panel wire shape + * @param inputs + * @returns Glass panel wire shape of the table + * @group get shapes + * @shortname get glass panel wire + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/good-coffee-table.jpeg + * @drawable true + */ + getGlassPanelWireShape( + inputs: Things.Furniture.Tables.GoodCoffeeTable.GoodCoffeeTableModelDto + ): Inputs.OCCT.TopoDSShapePointer; + /** + * Gets the table shelf shape + * @param inputs + * @returns Shelf shape of the table + * @group get shapes + * @shortname get shelf shape + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/good-coffee-table.jpeg + * @drawable true + */ + getShelfShape( + inputs: Things.Furniture.Tables.GoodCoffeeTable.GoodCoffeeTableModelDto + ): Inputs.OCCT.TopoDSShapePointer; + /** + * Gets the table shelf top wire shape + * @param inputs + * @returns Shelf wire shape of the table + * @group get shapes + * @shortname get shelf top wire + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/good-coffee-table.jpeg + * @drawable true + */ + getShelfTopWireShape( + inputs: Things.Furniture.Tables.GoodCoffeeTable.GoodCoffeeTableModelDto + ): Inputs.OCCT.TopoDSShapePointer; + /** + * Gets the leg shapes as a compound shape + * @param inputs + * @returns Compound shape of the legs + * @group get shapes + * @shortname get legs compound + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/good-coffee-table.jpeg + * @drawable true + */ + getLegsCompoundShape( + inputs: Things.Furniture.Tables.GoodCoffeeTable.GoodCoffeeTableModelDto + ): Inputs.OCCT.TopoDSShapePointer; + /** + * Gets the top center point + * @param inputs + * @returns Top center point + * @group get points + * @shortname get top center point + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/good-coffee-table.jpeg + * @drawable true + */ + getTableTopCenterPoint( + inputs: Things.Furniture.Tables.GoodCoffeeTable.GoodCoffeeTableModelDto + ): Inputs.Base.Point3; + /** + * Gets the top center point of the shelf + * @param inputs + * @returns Top center point of the shelf + * @group get points + * @shortname get top shelf center point + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/good-coffee-table.jpeg + * @drawable true + */ + getTableShelfTopCenterPoint( + inputs: Things.Furniture.Tables.GoodCoffeeTable.GoodCoffeeTableModelDto + ): Inputs.Base.Point3; + /** + * Gets the leg bottom points + * @param inputs + * @returns Bottom points + * @group get points + * @shortname get leg bottom points + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/good-coffee-table.jpeg + * @drawable true + */ + getLegBottomPoints( + inputs: Things.Furniture.Tables.GoodCoffeeTable.GoodCoffeeTableModelDto + ): Inputs.Base.Point3[]; + /** + * Gets the leg top points + * @param inputs + * @returns Top points + * @group get points + * @shortname get leg top points + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/good-coffee-table.jpeg + * @drawable true + */ + getLegTopPoints( + inputs: Things.Furniture.Tables.GoodCoffeeTable.GoodCoffeeTableModelDto + ): Inputs.Base.Point3[]; + /** + * Creates draw options for good coffee table + * @param inputs + * @returns Draw options + * @group draw + * @shortname good coffee table draw options + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/good-coffee-table.jpeg + * @drawable false + */ + drawOptions( + inputs: Things.Furniture.Tables.GoodCoffeeTable.GoodCoffeeTableDrawDto + ): Things.Furniture.Tables.GoodCoffeeTable.GoodCoffeeTableDrawDto; + /** + * Draws good coffee table model in default settings + * @param model Contains a model shapes to be drawn and additional information + * @returns BabylonJS Mesh + * @group drawing + * @shortname get draw shape + * @drawable false + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/good-coffee-table.jpeg + * @ignore true + */ + drawModel( + model: Things.Furniture.Tables.GoodCoffeeTable.GoodCoffeeTableData, + options: Things.Furniture.Tables.GoodCoffeeTable.GoodCoffeeTableDrawDto + ): Promise; + /** + * Disposes a cup model + * @param inputs Contains a model shapes to be disposed and additional information + * @group drawing + * @shortname dispose calm cup + * @drawable false + * @ignore true + */ + dispose( + inputs: Things.Furniture.Tables.GoodCoffeeTable.GoodCoffeeTableData + ): Promise; + /** + * Creates materials + * @param inputs Contains a model shapes to be disposed and additional information + * @group drawing + * @shortname creates default materials for zen hideout + * @drawable false + * @ignore true + */ + private createMaterials; + } + declare class SnakeTable { + private readonly occWorkerManager; + private readonly context; + private readonly draw; + private readonly occt; + private materials; + constructor( + occWorkerManager: OCCTWorkerManager, + context: Context, + draw: Draw, + occt: OCCTW + ); + /** + * Creates a snake table model + * @param inputs + * @returns Snake table model + * @group create + * @shortname snake table + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/snake-table.jpeg + * @drawable true + */ + create( + inputs: Things.Furniture.Tables.SnakeTable.SnakeTableDto + ): Promise< + Things.Furniture.Tables.SnakeTable.SnakeTableData + >; + /** + * Gets the compound shape of the table + * @param inputs + * @returns Compound shape of the snake table model + * @group get shapes + * @shortname get compound + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/snake-table.jpeg + * @drawable true + */ + getCompoundShape( + inputs: Things.Furniture.Tables.SnakeTable.SnakeTableModelDto + ): Inputs.OCCT.TopoDSShapePointer; + /** + * Gets the glass shape of the table + * @param inputs + * @returns The glass shape solid of the table + * @group get shapes + * @shortname get glass + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/snake-table.jpeg + * @drawable true + */ + getGlassShape( + inputs: Things.Furniture.Tables.SnakeTable.SnakeTableModelDto + ): Inputs.OCCT.TopoDSShapePointer; + /** + * Gets the main solid shape of the table + * @param inputs + * @returns The main shape solid of the table + * @group get shapes + * @shortname get main + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/snake-table.jpeg + * @drawable true + */ + getMainShape( + inputs: Things.Furniture.Tables.SnakeTable.SnakeTableModelDto + ): Inputs.OCCT.TopoDSShapePointer; + /** + * Gets the center point of the table top + * @param inputs + * @returns The point on the center of the top area + * @group get points + * @shortname get top center + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/snake-table.jpeg + * @drawable true + */ + getTopCenterPoint( + inputs: Things.Furniture.Tables.SnakeTable.SnakeTableModelDto + ): Inputs.Base.Point3; + /** + * Creates draw options for snake table + * @param inputs + * @returns Draw options + * @group draw + * @shortname snake table draw options + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/snake-table.jpeg + * @drawable false + */ + drawOptions( + inputs: Things.Furniture.Tables.SnakeTable.SnakeTableDrawDto + ): Things.Furniture.Tables.SnakeTable.SnakeTableDrawDto; + /** + * Draws snake table model in default settings + * @param model Contains a model shapes to be drawn and additional information + * @returns BabylonJS Mesh + * @group drawing + * @shortname draw shape + * @drawable false + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/snake-table.jpeg + * @ignore true + */ + drawModel( + model: Things.Furniture.Tables.SnakeTable.SnakeTableData, + options: Things.Furniture.Tables.SnakeTable.SnakeTableDrawDto + ): Promise; + /** + * Disposes a cup model + * @param inputs Contains a model shapes to be disposed and additional information + * @group drawing + * @shortname dispose calm cup + * @drawable false + * @ignore true + */ + dispose( + inputs: Things.Furniture.Tables.SnakeTable.SnakeTableData + ): Promise; + /** + * Creates materials + * @param inputs Contains a model shapes to be disposed and additional information + * @group drawing + * @shortname creates default materials for zen hideout + * @drawable false + * @ignore true + */ + private createMaterials; + } + declare class Tables { + private readonly occWorkerManager; + private readonly context; + private readonly draw; + private readonly occt; + elegantTable: ElegantTable; + goodCoffeeTable: GoodCoffeeTable; + snakeTable: SnakeTable; + constructor( + occWorkerManager: OCCTWorkerManager, + context: Context, + draw: Draw, + occt: OCCTW + ); + } + declare class Birdhouses { + private readonly occWorkerManager; + private readonly context; + private readonly draw; + private readonly occt; + wingtipVilla: WingtipVilla; + chirpyChalet: ChirpyChalet; + constructor( + occWorkerManager: OCCTWorkerManager, + context: Context, + draw: Draw, + occt: OCCTW + ); + } + declare class ChirpyChalet { + private readonly occWorkerManager; + private readonly context; + private readonly draw; + private readonly occt; + constructor( + occWorkerManager: OCCTWorkerManager, + context: Context, + draw: Draw, + occt: OCCTW + ); + /** + * Disposes a chirpy chalet model objects + * @param inputs Contains a model shapes to be disposed and additional information + * @group drawing + * @shortname dispose chirpy chalet + * @drawable false + * @ignore true + */ + dispose( + inputs: Things.KidsCorner.BirdHouses.ChirpyChalet.ChirpyChaletData + ): Promise; + /** + * Creates a chirpy chalet birdhouse with a 45 degree roof + * @param inputs Contains points and the transformations to apply + * @returns Transformed points + * @group birdhouse + * @shortname chirpy chalet + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/kids/Birdhouses/ChirpyChaletIcon.webp + * @drawable true + */ + create( + inputs: Things.KidsCorner.BirdHouses.ChirpyChalet.ChirpyChaletDto + ): Promise< + Things.KidsCorner.BirdHouses.ChirpyChalet.ChirpyChaletData + >; + /** + * Draws wingtip villa in default settings + * @param inputs Contains a model shapes to be drawn and additional information + * @returns BabylonJS Mesh + * @group drawing + * @shortname draw shape + * @drawable false + * @ignore true + */ + drawModel( + inputs: Things.KidsCorner.BirdHouses.ChirpyChalet.ChirpyChaletData + ): Promise; + } + declare class WingtipVilla { + private readonly occWorkerManager; + private readonly context; + private readonly draw; + private readonly occt; + constructor( + occWorkerManager: OCCTWorkerManager, + context: Context, + draw: Draw, + occt: OCCTW + ); + /** + * Creates a wingtip villa birdhouse with a 45 degree roof + * @param inputs Contains points and the transformations to apply + * @returns Transformed points + * @group birdhouse + * @shortname wingtip villa + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/kids/Birdhouses/WingtipVillaIcon.webp + * @drawable true + */ + create( + inputs: Things.KidsCorner.BirdHouses.WingtipVilla.WingtipVillaDto + ): Promise< + Things.KidsCorner.BirdHouses.WingtipVilla.WingtipVillaData + >; + /** + * Draws wingtip villa in default settings + * @param inputs Contains a model shapes to be drawn and additional information + * @returns BabylonJS Mesh + * @group drawing + * @shortname draw shape + * @drawable false + * @ignore true + */ + drawModel( + inputs: Things.KidsCorner.BirdHouses.WingtipVilla.WingtipVillaData + ): Promise; + /** + * Disposes a wingtip villa model objects + * @param inputs Contains a model shapes to be disposed and additional information + * @group drawing + * @shortname dispose wingtip villa + * @drawable false + * @ignore true + */ + dispose( + inputs: Things.KidsCorner.BirdHouses.WingtipVilla.WingtipVillaData + ): Promise; + } + declare class KidsCorner { + private readonly occWorkerManager; + private readonly context; + private readonly draw; + private readonly occt; + birdhouses: Birdhouses; + constructor( + occWorkerManager: OCCTWorkerManager, + context: Context, + draw: Draw, + occt: OCCTW + ); + } + declare class DropletsPhoneHolder { + private readonly occWorkerManager; + private readonly context; + private readonly draw; + private readonly occt; + private readonly jscad; + private drawOptions; + constructor( + occWorkerManager: OCCTWorkerManager, + context: Context, + draw: Draw, + occt: OCCTW, + jscad: JSCAD + ); + /** + * Creates droplets phone holder + * @param inputs + * @returns Droplets phone holder data + * @group create + * @shortname droplets phone holder + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/laser-cutting/gadgets/DropletsPhoneHolder.jpeg + * @drawable true + */ + create( + inputs: Things.LaserCutting.Gadgets.DropletsPhoneHolder.DropletsPhoneHolderDto + ): Promise< + Things.LaserCutting.Gadgets.DropletsPhoneHolder.DropletsPhoneHolderData + >; + /** + * Gets the compound shape of the droplets phone holder + * @param inputs + * @returns Compound shape of the droplets phone holder model + * @group get shapes + * @shortname compound + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/laser-cutting/gadgets/DropletsPhoneHolder.jpeg + * @drawable true + */ + getCompoundShape( + inputs: Things.LaserCutting.Gadgets.DropletsPhoneHolder.DropletsPhoneHolderModelDto + ): Inputs.OCCT.TopoDSShapePointer; + /** + * Gets the cut wires compound + * @param inputs + * @returns Compound of the cut wires + * @group get shapes + * @shortname cut wires + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/laser-cutting/gadgets/DropletsPhoneHolder.jpeg + * @drawable true + */ + getCutWiresCompound( + inputs: Things.LaserCutting.Gadgets.DropletsPhoneHolder.DropletsPhoneHolderModelDto + ): Inputs.OCCT.TopoDSShapePointer; + /** + * Gets the engraving wires compound + * @param inputs + * @returns Compound of the engraving wires + * @group get shapes + * @shortname engraving wires + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/laser-cutting/gadgets/DropletsPhoneHolder.jpeg + * @drawable true + */ + getEngravingWiresCompound( + inputs: Things.LaserCutting.Gadgets.DropletsPhoneHolder.DropletsPhoneHolderModelDto + ): Inputs.OCCT.TopoDSShapePointer; + /** + * Downloads DXF drawing + * @param inputs + * @returns DXF File + * @group download + * @shortname dxf drawings + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/laser-cutting/gadgets/DropletsPhoneHolder.jpeg + * @drawable false + */ + downloadDXFDrawings( + inputs: Things.LaserCutting.Gadgets.DropletsPhoneHolder.DropletsPhoneHolderModelDxfDto + ): Promise; + /** + * Downloads STEP drawing + * @param inputs + * @returns STEP File + * @group download + * @shortname step drawings + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/laser-cutting/gadgets/DropletsPhoneHolder.jpeg + * @drawable false + */ + downloadSTEPDrawings( + inputs: Things.LaserCutting.Gadgets.DropletsPhoneHolder.DropletsPhoneHolderModelStepDto + ): Promise; + /** + * Downloads STEP 3D model + * @param inputs + * @returns STEP File + * @group download + * @shortname 3d step model + * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/laser-cutting/gadgets/DropletsPhoneHolder.jpeg + * @drawable false + */ + download3dSTEPModel( + inputs: Things.LaserCutting.Gadgets.DropletsPhoneHolder.DropletsPhoneHolderModelStepDto + ): Promise; + /** + * Draws droplets phone holder in default settings + * @param inputs Contains a model shapes to be drawn and additional information + * @returns BabylonJS Mesh + * @group drawing + * @shortname draw shape + * @drawable false + * @ignore true + */ + drawModel( + model: Things.LaserCutting.Gadgets.DropletsPhoneHolder.DropletsPhoneHolderData, + precision?: number + ): Promise; + /** + * Disposes a droplets phone holder model objects + * @param inputs Contains a model shapes to be disposed and additional information + * @group drawing + * @shortname dispose droplets phone holder + * @drawable false + * @ignore true + */ + dispose( + inputs: Things.LaserCutting.Gadgets.DropletsPhoneHolder.DropletsPhoneHolderData + ): Promise; + private createDrawOptions; + } + declare class Gadgets { + private readonly occWorkerManager; + private readonly context; + private readonly draw; + private readonly occt; + private readonly jscad; + dropletsPhoneHolder: DropletsPhoneHolder; + constructor( + occWorkerManager: OCCTWorkerManager, + context: Context, + draw: Draw, + occt: OCCTW, + jscad: JSCAD + ); + } + declare class LaserCutting { + private readonly occWorkerManager; + private readonly context; + private readonly draw; + private readonly occt; + private readonly jscad; + gadgets: Gadgets; + constructor( + occWorkerManager: OCCTWorkerManager, + context: Context, + draw: Draw, + occt: OCCTW, + jscad: JSCAD + ); + } + declare class ThingsAdv { + private readonly occWorkerManager; + private readonly context; + private readonly draw; + private readonly occt; + private readonly jscad; + kidsCorner: KidsCorner; + threeDPrinting: ThreeDPrinting; + laserCutting: LaserCutting; + architecture: Architecture; + furniture: Furniture; + enums: Enums; + constructor( + occWorkerManager: OCCTWorkerManager, + context: Context, + draw: Draw, + occt: OCCTW, + jscad: JSCAD + ); + } + + declare class BitByBitBase { + readonly draw: Draw; + readonly babylon: Babylon; + readonly vector: Vector; + readonly point: Point; + readonly line: Line; + readonly polyline: Polyline; + readonly mesh: MeshBitByBit; + readonly occt: OCCTW & OCCT; + readonly advanced: AdvancedAdv; + readonly things: ThingsAdv; + readonly jscad: JSCAD; + readonly manifold: ManifoldBitByBit; + readonly logic: Logic; + readonly math: MathBitByBit; + readonly lists: Lists; + readonly color: Color; + readonly text: TextBitByBit; + readonly dates: Dates; + readonly json: JSONBitByBit; + readonly csv: CSVBitByBit; + readonly verb: Verb; + readonly tag: Tag; + readonly time: Time; + readonly asset: Asset; + } + + declare var isRunnerContext: boolean; + declare function mockBitbybitRunnerInputs(inputs: T): T; + declare function getBitbybitRunnerInputs(): T; + declare function setBitbybitRunnerResult(result: T): void; +} diff --git a/examples/vite/threejs/runner-occt-bottle/src/runner/load-runner-script.ts b/examples/vite/threejs/runner-occt-bottle/src/runner/load-runner-script.ts new file mode 100644 index 00000000..be6b0837 --- /dev/null +++ b/examples/vite/threejs/runner-occt-bottle/src/runner/load-runner-script.ts @@ -0,0 +1,9 @@ +export function loadRunnerScript(): Promise { + return new Promise((resolve, reject) => { + const script = document.createElement("script"); + script.src = "https://cdn.jsdelivr.net/gh/bitbybit-dev/bitbybit-assets@latest/runner/bitbybit-runner-lite-threejs.js"; + script.onload = () => resolve(); + script.onerror = () => reject(new Error("Failed to load bitbybit-runner script")); + document.head.appendChild(script); + }); +} diff --git a/examples/vite/threejs/runner-occt-bottle/src/runner/runner-types.ts b/examples/vite/threejs/runner-occt-bottle/src/runner/runner-types.ts new file mode 100644 index 00000000..dd768458 --- /dev/null +++ b/examples/vite/threejs/runner-occt-bottle/src/runner/runner-types.ts @@ -0,0 +1,113 @@ +// eslint-disable-next-line @typescript-eslint/triple-slash-reference +/// +import type * as THREEJS from "three"; + +class ExternalThreeJS { + /** + * Potentially scene can be created outside the context of the runner. In this case, you can provide your scene here. + */ + scene?: THREEJS.Scene; + /** + * Potentially scene can be created outside the context of the runner. In this case, you must provide your camera here. + */ + camera?: THREEJS.Camera; + /** + * Potentially scene can be created outside the context of the runner. In this case, you must provide your renderer + */ + renderer?: THREEJS.WebGLRenderer; +} + +export interface RunOptionsInterface { + /** + * The id of the HTML canvas element where the scene will be rendered. + */ + canvasId?: string; + /** + * In order to draw bitbybit HTML tags correctly we need to know the class name of surrounding canvas div. Default is "canvasZone" if not provided. + */ + canvasZoneClass?: string; + /** + * JSCAD kernel is enabled by default if this property is emitted. If you will set it to false it will be disabled. + */ + enableJSCAD?: boolean; + /** + * Manifold kernel is enabled by default if this property is emitted. If you will set it to false it will be disabled. + */ + enableManifold?: boolean; + /** + * OCCT kernel is enabled by default if this property is emitted. If you will set it to false it will be disabled. + */ + enableOCCT?: boolean; + /** + * Currently only blockly supports handling key events. If you do not write games or simulations that react to key events you can disable that feature. + */ + enableKeyEventListeners?: boolean; + /** + * The camera position that will be set when the scene is created. + */ + cameraPosition?: [number, number, number]; + /** + * The camera target that will be set when the scene is created. + */ + cameraTarget?: [number, number, number]; + /** + * The background color of the scene. Default is white. + */ + backgroundColor?: string; + /** + * Load the fonts that are provided in the array. If you will not provide this property all the fonts will be loaded by default. + */ + loadFonts?: fontsEnum[]; + /** + * URL to use for CDN of the runner. By default when this is not provided we're using jsdelivr, but if you'd like to host these assets yourself or use our fallback CDN - that's totally fine. + */ + cdnUrl?: string; + /** + * If you have created the scene outside the runner, you can provide it here. + */ + externalThreeJSSettings?: ExternalThreeJS; +} + +// Runner result interface +export interface RunnerResult { + bitbybit: Bit.BitByBitBase; + Bit: typeof Bit; + camera: THREEJS.Camera; + scene: THREEJS.Scene; + renderer: THREEJS.WebGLRenderer; + THREEJS: typeof THREEJS; +} + +// BitByBit Runner interface +export interface BitByBitRunner { + run(options: RunOptionsInterface): Promise; + executeScript(script: string, inputs?: any): T; + resetRunnerContext(disposeScene?: boolean): void; +} + +// Global window interface extension +declare global { + interface Window { + bitbybitRunner: { + getRunnerInstance(): BitByBitRunner; + }; + } +} + +/** + * The fonts that are available for the runner to load. + */ +export const fontsEnum = { + Aboreto: "Aboreto", + Bungee: "Bungee", + IndieFlower: "IndieFlower", + Lugrasimo: "Lugrasimo", + Orbitron: "Orbitron", + Roboto: "Roboto", + RobotoSlab: "RobotoSlab", + Silkscreen: "Silkscreen", + Tektur: "Tektur", + Workbench: "Workbench", +} as const; + +export type fontsEnum = (typeof fontsEnum)[keyof typeof fontsEnum]; diff --git a/examples/vite/threejs/runner-occt-bottle/src/style.css b/examples/vite/threejs/runner-occt-bottle/src/style.css new file mode 100644 index 00000000..3fcf895c --- /dev/null +++ b/examples/vite/threejs/runner-occt-bottle/src/style.css @@ -0,0 +1,37 @@ +body { + margin: 0px; + overflow: hidden; +} +a.logo { + position: absolute; + color: white; + vertical-align: middle; + bottom: 10px; + left: 10px; + font-family: 'Courier New', Courier, monospace; + text-decoration: none; + width: 100%; +} + +.logo { + margin-bottom: 20px; + text-align: center; +} + +.logo img { + width: 50px; + height: 50px; +} +body { + margin: 0; + background-color: #1a1c1f; +} +#myCanvas { + display: block; + width: 100%; + height: 100vh; +} +.myCanvasZone { + width: 100%; + height: 100vh; +} \ No newline at end of file diff --git a/examples/vite/threejs/runner-occt-bottle/src/vite-env.d.ts b/examples/vite/threejs/runner-occt-bottle/src/vite-env.d.ts new file mode 100644 index 00000000..11f02fe2 --- /dev/null +++ b/examples/vite/threejs/runner-occt-bottle/src/vite-env.d.ts @@ -0,0 +1 @@ +/// diff --git a/examples/vite/threejs/runner-occt-bottle/tsconfig.json b/examples/vite/threejs/runner-occt-bottle/tsconfig.json new file mode 100644 index 00000000..a22caba9 --- /dev/null +++ b/examples/vite/threejs/runner-occt-bottle/tsconfig.json @@ -0,0 +1,25 @@ +{ + "compilerOptions": { + "target": "ES2020", + "useDefineForClassFields": true, + "module": "ESNext", + "lib": ["ES2020", "DOM", "DOM.Iterable"], + "skipLibCheck": true, + + /* Bundler mode */ + "moduleResolution": "bundler", + "allowImportingTsExtensions": true, + "verbatimModuleSyntax": true, + "moduleDetection": "force", + "noEmit": true, + + /* Linting */ + "strict": true, + "noUnusedLocals": true, + "noUnusedParameters": true, + "erasableSyntaxOnly": true, + "noFallthroughCasesInSwitch": true, + "noUncheckedSideEffectImports": true + }, + "include": ["src"] +} diff --git a/packages/dev/babylonjs/lib/api/inputs/draw-inputs.ts b/packages/dev/babylonjs/lib/api/inputs/draw-inputs.ts index cd85c066..a5b587f8 100644 --- a/packages/dev/babylonjs/lib/api/inputs/draw-inputs.ts +++ b/packages/dev/babylonjs/lib/api/inputs/draw-inputs.ts @@ -154,12 +154,12 @@ export namespace Draw { colorMapStrategy: Base.colorMapStrategyEnum = Base.colorMapStrategyEnum.lastColorRemainder; /** * Size affect how big the drawn points are and how wide lines are. - * @default 1 + * @default 0.1 * @minimum 0 * @maximum Infinity * @step 0.1 */ - size = 1; + size = 0.1; /** * Opacity of the point 0 to 1 * @default 1 From 49bc50a334ac9e2abd1eb51d4bedf09b42daa2c8 Mon Sep 17 00:00:00 2001 From: Matas Ubarevicius Date: Sat, 10 Jan 2026 14:37:29 +0200 Subject: [PATCH 04/31] threejs complete project setup and bitbybit-ai setup start --- .../threejs/runner-occt-bottle/index.html | 2 +- .../src/helpers/init-threejs.ts | 14 +- .../threejs/runner-occt-bottle/src/main.ts | 3 - .../src/runner/bitbybit-0.21.0.d.ts | 49263 +--------------- .../src/runner/load-runner-script.ts | 8 + .../src/runner/runner-types.ts | 1 - .../vite/threejs/starter-template/src/main.ts | 7 +- 7 files changed, 20 insertions(+), 49278 deletions(-) diff --git a/examples/vite/threejs/runner-occt-bottle/index.html b/examples/vite/threejs/runner-occt-bottle/index.html index 27351d60..317df4dc 100644 --- a/examples/vite/threejs/runner-occt-bottle/index.html +++ b/examples/vite/threejs/runner-occt-bottle/index.html @@ -5,7 +5,7 @@ - Bitbybit & PlayCanvas Hex House Concept Demo + Bitbybit & ThreeJS Hex House Concept Demo diff --git a/examples/vite/threejs/runner-occt-bottle/src/helpers/init-threejs.ts b/examples/vite/threejs/runner-occt-bottle/src/helpers/init-threejs.ts index 6e0b9497..c282ac3c 100644 --- a/examples/vite/threejs/runner-occt-bottle/src/helpers/init-threejs.ts +++ b/examples/vite/threejs/runner-occt-bottle/src/helpers/init-threejs.ts @@ -23,15 +23,15 @@ export function initThreeJS(canvasId = "myCanvas") { 200 ); const scene = new Scene(); - scene.background = new Color(0x1a1c1f); // Set background color + scene.background = new Color(0x1a1c1f); scene.fog = new Fog(0x1a1c1f, 30, 80); - const light = new HemisphereLight(0xffffff, 0x444444, 2); // Adjusted intensity + const light = new HemisphereLight(0xffffff, 0x444444, 2); scene.add(light); const renderer = new WebGLRenderer({ antialias: true, canvas: domNode }); renderer.setSize(window.innerWidth, window.innerHeight); - renderer.setPixelRatio(window.devicePixelRatio); // Consider devicePixelRatio for sharpness + renderer.setPixelRatio(window.devicePixelRatio); renderer.shadowMap.enabled = true; renderer.shadowMap.type = VSMShadowMap; @@ -63,7 +63,7 @@ export function initThreeJS(canvasId = "myCanvas") { createDirLightsAndGround(scene); - return { scene, camera, renderer }; // Return renderer and camera if needed elsewhere + return { scene, camera, renderer }; } function createDirLightsAndGround(scene: Scene) { @@ -83,7 +83,7 @@ function createDirLightsAndGround(scene: Scene) { dirLight.shadow.radius = 2; dirLight.shadow.bias = -0.0005; - scene?.add(dirLight); + scene.add(dirLight); const dirLight2 = new DirectionalLight(0xffffff, 2); dirLight2.position.set(-5, 10, -5); @@ -94,7 +94,7 @@ function createDirLightsAndGround(scene: Scene) { dirLight2.shadow.camera.top = dist; dirLight2.shadow.camera.bottom = -dist; - scene?.add(dirLight2); + scene.add(dirLight2); const material = new MeshPhongMaterial({ color: 0x444444 }); material.shininess = 0; @@ -104,5 +104,5 @@ function createDirLightsAndGround(scene: Scene) { const ground = new Mesh(new PlaneGeometry(50, 50, 1, 1), material); ground.rotateX(-Math.PI / 2); ground.receiveShadow = true; - scene?.add(ground); + scene.add(ground); } diff --git a/examples/vite/threejs/runner-occt-bottle/src/main.ts b/examples/vite/threejs/runner-occt-bottle/src/main.ts index 752b0708..b01c1f2e 100644 --- a/examples/vite/threejs/runner-occt-bottle/src/main.ts +++ b/examples/vite/threejs/runner-occt-bottle/src/main.ts @@ -8,9 +8,6 @@ import { initThreeJS } from "./helpers/init-threejs"; import * as lil from "lil-gui"; import { loadRunnerScript } from "./runner/load-runner-script"; -(window as any).THREEJS = THREEJS; - -// Dynamically load the runner script after THREE is available on window loadRunnerScript().then(() => { start(); }); diff --git a/examples/vite/threejs/runner-occt-bottle/src/runner/bitbybit-0.21.0.d.ts b/examples/vite/threejs/runner-occt-bottle/src/runner/bitbybit-0.21.0.d.ts index 63ee8baa..aa951f56 100644 --- a/examples/vite/threejs/runner-occt-bottle/src/runner/bitbybit-0.21.0.d.ts +++ b/examples/vite/threejs/runner-occt-bottle/src/runner/bitbybit-0.21.0.d.ts @@ -1,49262 +1 @@ -declare namespace Bit { - declare namespace Inputs { - declare namespace Base { - type Color = string; - type ColorRGB = { - r: number; - g: number; - b: number; - }; - type Point2 = [number, number]; - type Vector2 = [number, number]; - type Point3 = [number, number, number]; - type Vector3 = [number, number, number]; - type Axis3 = { - origin: Base.Point3; - direction: Base.Vector3; - }; - type Axis2 = { - origin: Base.Point2; - direction: Base.Vector2; - }; - type Segment2 = [Point2, Point2]; - type Segment3 = [Point3, Point3]; - type TrianglePlane3 = { - normal: Vector3; - d: number; - }; - type Triangle3 = [Base.Point3, Base.Point3, Base.Point3]; - type Mesh3 = Triangle3[]; - type Plane3 = { - origin: Base.Point3; - normal: Base.Vector3; - direction: Base.Vector3; - }; - type BoundingBox = { - min: Base.Point3; - max: Base.Point3; - center?: Base.Point3; - width?: number; - height?: number; - length?: number; - }; - type Line2 = { - start: Base.Point2; - end: Base.Point2; - }; - type Line3 = { - start: Base.Point3; - end: Base.Point3; - }; - type Polyline3 = { - points: Base.Point3[]; - isClosed?: boolean; - }; - type Polyline2 = { - points: Base.Point2[]; - isClosed?: boolean; - }; - type VerbCurve = { - tessellate: (options: any) => any; - }; - type VerbSurface = { - tessellate: (options: any) => any; - }; - type TransformMatrix3x3 = [ - number, - number, - number, - number, - number, - number, - number, - number, - number - ]; - type TransformMatrixes3x3 = TransformMatrix3x3[]; - type TransformMatrix = [ - number, - number, - number, - number, - number, - number, - number, - number, - number, - number, - number, - number, - number, - number, - number, - number - ]; - type TransformMatrixes = TransformMatrix[]; - } - declare namespace JSCAD { - type JSCADEntity = any; - class PolylinePropertiesDto { - /** - * Provide options without default values - */ - constructor(points?: Base.Point3[], isClosed?: boolean); - /** - * Points of the polyline - */ - points: Base.Point3[]; - /** - * Can contain is closed information - */ - isClosed?: boolean; - /** - * Can contain color information - */ - color?: string | number[]; - } - enum solidCornerTypeEnum { - /** - * Edges will meet at a corner - */ - edge = "edge", - /** - * Edges will be rounded on the corner - */ - round = "round", - /** - * Edges will be chamfered on the corner - */ - chamfer = "chamfer", - } - enum jscadTextAlignEnum { - /** - * Aligns text to the left - */ - left = "left", - /** - * Aligns text to the center - */ - center = "center", - /** - * Aligns text to the right - */ - right = "right", - } - class MeshDto { - constructor(mesh?: JSCADEntity); - /** - * Solid Jscad mesh - */ - mesh: JSCADEntity; - } - class MeshesDto { - constructor(meshes?: JSCADEntity[]); - /** - * Solid Jscad mesh - */ - meshes: JSCADEntity[]; - } - class DrawSolidMeshDto { - /** - * Provide options without default values - */ - constructor( - mesh?: JSCADEntity, - opacity?: number, - colours?: string | string[], - updatable?: boolean, - hidden?: boolean, - jscadMesh?: T, - drawTwoSided?: boolean, - backFaceColour?: string, - backFaceOpacity?: number - ); - /** - * Solid Jscad mesh - */ - mesh: JSCADEntity; - /** - * Value between 0 and 1 - * @default 1 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - opacity: number; - /** - * Hex colour string - * @default #444444 - */ - colours: string | string[]; - /** - * Indicates wether this solid will be transformed in time - * @default false - */ - updatable: boolean; - /** - * Hidden - * @default false - */ - hidden: boolean; - /** - * Solid mesh variable in case it already exists and needs updating - * @default undefined - * @optional true - * @ignore true - */ - jscadMesh?: T; - /** - * Draw two-sided faces with different colors for front and back. This helps visualize face orientation. - * @default true - */ - drawTwoSided: boolean; - /** - * Hex colour string for back face colour (negative side of the face). Only used when drawTwoSided is true. - * @default #0000ff - */ - backFaceColour: string; - /** - * Back face opacity value between 0 and 1. Only used when drawTwoSided is true. - * @default 1 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - backFaceOpacity: number; - } - class DrawSolidMeshesDto { - /** - * Provide options without default values - */ - constructor( - meshes?: JSCADEntity[], - opacity?: number, - colours?: string | string[], - updatable?: boolean, - hidden?: boolean, - jscadMesh?: T, - drawTwoSided?: boolean, - backFaceColour?: string, - backFaceOpacity?: number - ); - /** - * Solid Jscad meshes - * @default undefined - * @optional true - */ - meshes: JSCADEntity[]; - /** - * Value between 0 and 1 - * @default 1 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - opacity: number; - /** - * Hex colour string - * @default #444444 - */ - colours: string | string[]; - /** - * Indicates wether this solid will be transformed in time - * @default false - */ - updatable: boolean; - /** - * Should be hidden - * @default false - */ - hidden: boolean; - /** - * Solid mesh variable in case it already exists and needs updating - * @default undefined - * @optional true - * @ignore true - */ - jscadMesh?: T; - /** - * Draw two-sided faces with different colors for front and back. This helps visualize face orientation. - * @default true - */ - drawTwoSided: boolean; - /** - * Hex colour string for back face colour (negative side of the face). Only used when drawTwoSided is true. - * @default #0000ff - */ - backFaceColour: string; - /** - * Back face opacity value between 0 and 1. Only used when drawTwoSided is true. - * @default 1 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - backFaceOpacity: number; - } - class DrawPathDto { - /** - * Provide options without default values - */ - constructor( - path?: JSCADEntity, - colour?: string, - opacity?: number, - width?: number, - updatable?: boolean, - pathMesh?: T - ); - /** - * 2D Path to draw - * @default undefined - */ - path: JSCADEntity; - /** - * Colour of the path - * @default #444444 - */ - colour: string; - /** - * Opacity of the path - * @default 1 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - opacity: number; - /** - * Width of the path - * @default 10 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - width: number; - /** - * Indicates wether the path will change in time - * @default false - */ - updatable: boolean; - /** - * Path mesh variable that will be updated if updatable property is set to true - * @default undefined - * @optional true - * @ignore true - */ - pathMesh?: T; - } - class TransformSolidsDto { - constructor( - meshes?: JSCADEntity[], - transformation?: Base.TransformMatrixes - ); - /** - * Solids to be transformed - * @default undefined - */ - meshes: JSCADEntity[]; - /** - * Transformation matrix or a list of transformation matrixes - * @default undefined - */ - transformation: Base.TransformMatrixes; - } - class TransformSolidDto { - constructor( - mesh?: JSCADEntity, - transformation?: Base.TransformMatrixes - ); - /** - * Solid to be transformed - * @default undefined - */ - mesh: JSCADEntity; - /** - * Transformation matrix or a list of transformation matrixes - * @default undefined - */ - transformation: Base.TransformMatrixes; - } - class DownloadSolidDto { - constructor(mesh?: JSCADEntity, fileName?: string); - /** - * Solid to be downloaded - * @default undefined - */ - mesh: JSCADEntity; - /** - * File name - * @default undefined - */ - fileName: string; - } - class DownloadGeometryDto { - constructor( - geometry?: JSCADEntity | JSCADEntity[], - fileName?: string, - options?: any - ); - /** - * Solid or path to be downloaded, also supports multiple geometries in array - * @default undefined - */ - geometry: JSCADEntity | JSCADEntity[]; - /** - * File name - * @default jscad-geometry - */ - fileName: string; - /** - * Options - * @default undefined - * @optional true - */ - options: any; - } - class DownloadSolidsDto { - constructor(meshes?: JSCADEntity[], fileName?: string); - /** - * Solids to be downloaded - * @default undefined - */ - meshes: JSCADEntity[]; - /** - * File name - * @default undefined - */ - fileName: string; - } - class ColorizeDto { - constructor(geometry?: JSCADEntity, color?: string); - /** - * Solid to be colorized - * @default undefined - */ - geometry: JSCADEntity | JSCADEntity[]; - /** - * Hex color string - * @default #0000ff - */ - color: string; - } - class BooleanObjectsDto { - constructor(meshes?: JSCADEntity[]); - /** - * Contains solid Jscad mesh objects that will be used to perform boolean operation - * @default undefined - */ - meshes: JSCADEntity[]; - } - class BooleanTwoObjectsDto { - constructor(first?: JSCADEntity, second?: JSCADEntity); - /** - * Contains Jscad Solid - * @default undefined - */ - first: JSCADEntity; - /** - * Contains Jscad Solid - * @default undefined - */ - second: JSCADEntity; - } - class BooleanObjectsFromDto { - constructor(from?: JSCADEntity, meshes?: JSCADEntity[]); - /** - * Contains Jscad Solid - * @default undefined - */ - from: JSCADEntity; - /** - * Contains Jscad Solid - * @default undefined - */ - meshes: JSCADEntity[]; - } - class ExpansionDto { - constructor( - geometry?: JSCADEntity, - delta?: number, - corners?: solidCornerTypeEnum, - segments?: number - ); - /** - * Can contain various Jscad entities from Solid category - * @default undefined - */ - geometry: JSCADEntity; - /** - * Delta (+/-) of expansion - * @default 0.1 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - delta: number; - /** - * Type of corner to create during of expansion; edge, chamfer, round - * @default edge - */ - corners: solidCornerTypeEnum; - /** - * Integer number of segments when creating round corners - * @default 24 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - segments: number; - } - class OffsetDto { - constructor( - geometry?: JSCADEntity, - delta?: number, - corners?: solidCornerTypeEnum, - segments?: number - ); - /** - * Can contain various Jscad entities from Solid category - * @default undefined - */ - geometry: JSCADEntity; - /** - * Delta (+/-) of offset - * @default 0.1 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - delta: number; - /** - * Type of corner to create during the offset; edge, chamfer, round. - * @default edge - */ - corners: solidCornerTypeEnum; - /** - * Integer number of segments when creating round corners - * @default 24 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - segments: number; - } - class ExtrudeLinearDto { - constructor( - geometry?: JSCADEntity, - height?: number, - twistAngle?: number, - twistSteps?: number - ); - /** - * Geometry to extrude - * @default undefined - */ - geometry: JSCADEntity; - /** - * Height of linear extrude - * @default 1 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - height: number; - /** - * Twist angle in degrees - * @default 90 - * @minimum -Infinity - * @maximum Infinity - * @step 1 - */ - twistAngle: number; - /** - * Number of twist steps - * @default 15 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - twistSteps: number; - } - class HullDto { - constructor(meshes?: JSCADEntity[]); - /** - * Geometries to use in hull - * @default undefined - */ - meshes: JSCADEntity[]; - } - class ExtrudeRectangularDto { - constructor(geometry?: JSCADEntity, height?: number, size?: number); - /** - * Geometry to extrude - * @default undefined - */ - geometry: JSCADEntity; - /** - * Height of linear extrude - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - height: number; - /** - * Size of the rectangle - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - size: number; - } - class ExtrudeRectangularPointsDto { - constructor(points?: Base.Point3[], height?: number, size?: number); - /** - * Points for a path - * @default undefined - */ - points: Base.Point3[]; - /** - * Height of linear extrude - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - height: number; - /** - * Size of the rectangle - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - size: number; - } - class ExtrudeRotateDto { - constructor( - polygon?: JSCADEntity, - angle?: number, - startAngle?: number, - segments?: number - ); - /** - * Polygon to extrude - * @default undefined - */ - polygon: JSCADEntity; - /** - * Angle in degrees - * @default 90 - * @minimum -Infinity - * @maximum Infinity - * @step 1 - */ - angle: number; - /** - * Start angle in degrees - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 1 - */ - startAngle: number; - /** - * Number of segments - * @default 24 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - segments: number; - } - class PolylineDto { - constructor(polyline?: PolylinePropertiesDto); - /** - * Polyline with points - */ - polyline: PolylinePropertiesDto; - } - class CurveDto { - constructor(curve?: any); - /** - * Nurbs curve - */ - curve: any; - } - class PointsDto { - constructor(points?: Base.Point3[]); - /** - * Points - */ - points: Base.Point3[]; - } - class PathDto { - constructor(path?: JSCADEntity); - /** - * 2D path - * @default undefined - */ - path: JSCADEntity; - } - class PathFromPointsDto { - constructor(points?: Base.Point2[], closed?: boolean); - /** - * Points through which to create a path - * @default undefined - */ - points: Base.Point2[]; - /** - * Indicates wether we want to create a closed path - * @default false - */ - closed: boolean; - } - class PathsFromPointsDto { - constructor(pointsLists?: Base.Point3[][] | Base.Point2[][]); - /** - * Points - * @default undefined - */ - pointsLists: Base.Point3[][] | Base.Point2[][]; - } - class PathFromPolylineDto { - constructor(polyline?: PolylinePropertiesDto, closed?: boolean); - /** - * Polyline - * @default undefined - */ - polyline: PolylinePropertiesDto; - /** - * Indicates wether we want to create a closed path - * @default false - */ - closed: boolean; - } - class PathAppendCurveDto { - constructor(curve?: JSCADEntity, path?: JSCADEntity); - /** - * Verb Nurbs curve - * @default undefined - */ - curve: JSCADEntity; - /** - * Path to append the curve to - * @default undefined - */ - path: JSCADEntity; - } - class PathAppendPointsDto { - constructor(points?: Base.Point2[], path?: JSCADEntity); - /** - * Points to append - * @default undefined - */ - points: Base.Point2[]; - /** - * Path to append the points to - * @default undefined - */ - path: JSCADEntity; - } - class PathAppendPolylineDto { - constructor(polyline?: PolylinePropertiesDto, path?: JSCADEntity); - /** - * Polyline to append - * @default undefined - */ - polyline: PolylinePropertiesDto; - /** - * Path to append the polyline to - * @default undefined - */ - path: JSCADEntity; - } - class PathAppendArcDto { - constructor( - path?: JSCADEntity, - endPoint?: Base.Point2, - xAxisRotation?: number, - clockwise?: boolean, - large?: boolean, - segments?: number, - radiusX?: number, - radiusY?: number - ); - /** - * Path to append the arc to - * @default undefined - */ - path: JSCADEntity; - /** - * End point of an arc - * @default [1, 1] - */ - endPoint: Base.Point2; - /** - * Rotation (degrees) of the X axis of the arc with respect to the X axis of the coordinate system - * @default 90 - * @minimum -Infinity - * @maximum Infinity - * @step 1 - */ - xAxisRotation: number; - /** - * Draw an arc clockwise with respect to the center point - * @default true - */ - clockwise: boolean; - /** - * Draw an arc longer than PI radians - * @default false - */ - large: boolean; - /** - * Number of segments for the arc - * @default 24 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - segments: number; - /** - * X radius of an arc - * @default 1 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - radiusX: number; - /** - * Y radius of an arc - * @default 1 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - radiusY: number; - } - class CircleDto { - constructor(center?: Base.Point2, radius?: number, segments?: number); - /** - * Center of the circle - * @default [0, 0] - */ - center: Base.Point2; - /** - * Radius of the circle - * @default 1 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - radius: number; - /** - * Segment number - * @default 24 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - segments: number; - } - class EllipseDto { - constructor( - center?: Base.Point2, - radius?: Base.Point2, - segments?: number - ); - /** - * Center of the circle - * @default [0, 0] - */ - center: Base.Point2; - /** - * Radius of the circle in [x, y] form - * @default [1, 2] - */ - radius: Base.Point2; - /** - * Segment number - * @default 24 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - segments: number; - } - class SquareDto { - constructor(center?: Base.Point2, size?: number); - /** - * Center of the 2D square - * @default [0, 0] - */ - center: Base.Point2; - /** - * Size of the square - * @default 1 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - size: number; - } - class RectangleDto { - constructor(center?: Base.Point2, width?: number, length?: number); - /** - * Center of the 2D rectangle - * @default [0, 0] - */ - center: Base.Point2; - /** - * Width of the rectangle - * @default 1 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - width: number; - /** - * Length of the rectangle - * @default 1 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - length: number; - } - class RoundedRectangleDto { - constructor( - center?: Base.Point2, - roundRadius?: number, - segments?: number, - width?: number, - length?: number - ); - /** - * Center of the 2D rectangle - * @default [0, 0] - */ - center: Base.Point2; - /** - * The radius to round the rectangle edge - * @default 0.2 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - roundRadius: number; - /** - * Number of segments for corners - * @default 24 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - segments: number; - /** - * Width of the rectangle - * @default 1 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - width: number; - /** - * Length of the rectangle - * @default 1 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - length: number; - } - class StarDto { - constructor( - center?: Base.Point2, - vertices?: number, - density?: number, - outerRadius?: number, - innerRadius?: number, - startAngle?: number - ); - /** - * Center of the 2D star - * @default [0, 0] - */ - center: Base.Point2; - /** - * Number of vertices on the star - * @default 10 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - vertices: number; - /** - * Density of the star - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - density: number; - /** - * Outer radius of the star - * @default 2 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - outerRadius: number; - /** - * Inner radius of the star - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - innerRadius: number; - /** - * Starting angle for first vertice, in degrees - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 1 - */ - startAngle: number; - } - class CubeDto { - constructor(center?: Base.Point3, size?: number); - /** - * Center coordinates of the cube - * @default [0, 0, 0] - */ - center: Base.Point3; - /** - * Size of the cube - * @default 1 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - size: number; - } - class CubeCentersDto { - constructor(centers?: Base.Point3[], size?: number); - /** - * Center coordinates of the cubes - * @default undefined - */ - centers: Base.Point3[]; - /** - * Size of the cube - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - size: number; - } - class CuboidDto { - constructor( - center?: Base.Point3, - width?: number, - length?: number, - height?: number - ); - /** - * Center coordinates of the cubod - * @default [0, 0, 0] - */ - center: Base.Point3; - /** - * Width of the cuboid - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - width: number; - /** - * Length of the cuboid - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - length: number; - /** - * Height of the cuboid - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - height: number; - } - class CuboidCentersDto { - constructor( - centers?: Base.Point3[], - width?: number, - length?: number, - height?: number - ); - /** - * Center coordinates of the cuboids - * @default undefined - */ - centers: Base.Point3[]; - /** - * Width of the cuboids - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - width: number; - /** - * Length of the cuboids - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - length: number; - /** - * Height of the cuboids - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - height: number; - } - class RoundedCuboidDto { - constructor( - center?: Base.Point3, - roundRadius?: number, - width?: number, - length?: number, - height?: number, - segments?: number - ); - /** - * Center coordinates of the cubod - * @default [0, 0, 0] - */ - center: Base.Point3; - /** - * Radius for rounding edges - * @default 0.1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - roundRadius: number; - /** - * Width of the cuboid - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - width: number; - /** - * Length of the cuboid - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - length: number; - /** - * Height of the cuboid - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - height: number; - /** - * Segments of rounded edges - * @default 24 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - segments: number; - } - class RoundedCuboidCentersDto { - constructor( - centers?: Base.Point3[], - roundRadius?: number, - width?: number, - length?: number, - height?: number, - segments?: number - ); - /** - * Center coordinates of the cuboids - * @default undefined - */ - centers: Base.Point3[]; - /** - * Radius for rounding edges - * @default 0.1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - roundRadius: number; - /** - * Width of the cuboids - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - width: number; - /** - * Length of the cuboids - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - length: number; - /** - * Height of the cuboids - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - height: number; - /** - * Segments of rounded edges - * @default 24 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - segments: number; - } - class CylidnerEllipticDto { - constructor( - center?: Base.Point3, - height?: number, - startRadius?: Base.Point2, - endRadius?: Base.Point2, - segments?: number - ); - /** - * Center of the cylinder - * @default [0, 0, 0] - */ - center: Base.Point3; - /** - * Height of the cylinder - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - height: number; - /** - * Start radius on X and Y directions - * @default [1, 2] - */ - startRadius: Base.Vector2; - /** - * End radius on X and Y directions - * @default [2, 3] - */ - endRadius: Base.Vector2; - /** - * Subdivision segments - * @default 24 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - segments: number; - } - class CylidnerCentersEllipticDto { - constructor( - centers?: Base.Point3[], - height?: number, - startRadius?: Base.Point2, - endRadius?: Base.Point2, - segments?: number - ); - /** - * Centers of the cylinders - * @default undefined - */ - centers: Base.Point3[]; - /** - * Height of the cylinders - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - height: number; - /** - * Start radius on X and Y directions - * @default [1, 2] - */ - startRadius: Base.Point2; - /** - * End radius on X and Y directions - * @default [2, 3] - */ - endRadius: Base.Point2; - /** - * Subdivision segments - * @default 24 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - segments: number; - } - class CylidnerDto { - constructor( - center?: Base.Point3, - height?: number, - radius?: number, - segments?: number - ); - /** - * Center of the cylinder - * @default [0, 0, 0] - */ - center: Base.Point3; - /** - * Height of the cylinder - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - height: number; - /** - * Radius of the cylinder - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - radius: number; - /** - * Subdivision segments - * @default 24 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - segments: number; - } - class RoundedCylidnerDto { - constructor( - center?: Base.Point3, - roundRadius?: number, - height?: number, - radius?: number, - segments?: number - ); - /** - * Center of the cylinder - * @default [0, 0, 0] - */ - center: Base.Point3; - /** - * Rounding radius - * @default 0.1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - roundRadius: number; - /** - * Height of the cylinder - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - height: number; - /** - * Radius of the cylinder - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - radius: number; - /** - * Segment number - * @default 24 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - segments: number; - } - class EllipsoidDto { - constructor( - center?: Base.Point3, - radius?: Base.Point3, - segments?: number - ); - /** - * Center coordinates - * @default [0, 0, 0] - */ - center: Base.Point3; - /** - * Radius of the ellipsoid in [x, y, z] form - * @default [1, 2, 3] - */ - radius: Base.Point3; - /** - * Segment count for ellipsoid - * @default 24 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - segments: number; - } - class EllipsoidCentersDto { - constructor( - centers?: Base.Point3[], - radius?: Base.Point3, - segments?: number - ); - /** - * Center coordinates - * @default undefined - */ - centers: Base.Point3[]; - /** - * Radius of the ellipsoid in [x, y, z] form - * @default [1, 2, 3] - */ - radius: Base.Point3; - /** - * Segment count for ellipsoid - * @default 24 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - segments: number; - } - class GeodesicSphereDto { - constructor(center?: Base.Point3, radius?: number, frequency?: number); - /** - * Center coordinate of the geodesic sphere - * @default [0, 0, 0] - */ - center: Base.Point3; - /** - * Radius of the sphere - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - radius: number; - /** - * Subdivision count - * @default 12 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - frequency: number; - } - class GeodesicSphereCentersDto { - constructor( - centers?: Base.Point3[], - radius?: number, - frequency?: number - ); - /** - * Center coordinates of the geodesic spheres - * @default undefined - */ - centers: Base.Point3[]; - /** - * Radius of the sphere - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - radius: number; - /** - * Subdivision count - * @default 12 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - frequency: number; - } - class CylidnerCentersDto { - constructor( - centers?: Base.Point3[], - height?: number, - radius?: number, - segments?: number - ); - /** - * Centers of the cylinders - * @default undefined - */ - centers: Base.Point3[]; - /** - * Height of the cylinders - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - height: number; - /** - * Radius of the cylinders - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - radius: number; - /** - * Subdivision segments - * @default 24 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - segments: number; - } - class RoundedCylidnerCentersDto { - constructor( - centers?: Base.Point3[], - roundRadius?: number, - height?: number, - radius?: number, - segments?: number - ); - /** - * Centers of the cylinders - * @default undefined - */ - centers: Base.Point3[]; - /** - * Rounding radius - * @default 0.1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - roundRadius: number; - /** - * Height of the cylinders - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - height: number; - /** - * Radius of the cylinders - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - radius: number; - /** - * Segment number - * @default 24 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - segments: number; - } - class SphereDto { - constructor(center?: Base.Point3, radius?: number, segments?: number); - /** - * Center point of the sphere - * @default [0, 0, 0] - */ - center: Base.Point3; - /** - * Radius of the sphere - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - radius: number; - /** - * Segment count - * @default 24 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - segments: number; - } - class SphereCentersDto { - constructor( - centers?: Base.Point3[], - radius?: number, - segments?: number - ); - /** - * Center points of the spheres - * @default undefined - */ - centers: Base.Point3[]; - /** - * Radius of the spheres - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - radius: number; - /** - * Segment count - * @default 24 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - segments: number; - } - class TorusDto { - constructor( - center?: Base.Point3, - innerRadius?: number, - outerRadius?: number, - innerSegments?: number, - outerSegments?: number, - innerRotation?: number, - outerRotation?: number, - startAngle?: number - ); - /** - * Center coordinate - * @default [0, 0, 0] - */ - center: Base.Point3; - /** - * Inner radius - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - innerRadius: number; - /** - * Outer radius - * @default 2 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - outerRadius: number; - /** - * Number of inner segments - * @default 24 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - innerSegments: number; - /** - * Number of outer segments - * @default 24 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - outerSegments: number; - /** - * Inner rotation in degrees - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 1 - */ - innerRotation: number; - /** - * Outer rotation in degrees - * @default 360 - * @minimum -Infinity - * @maximum Infinity - * @step 1 - */ - outerRotation: number; - /** - * Start angle in degrees - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 1 - */ - startAngle: number; - } - class TextDto { - constructor( - text?: string, - segments?: number, - xOffset?: number, - yOffset?: number, - height?: number, - lineSpacing?: number, - letterSpacing?: number, - align?: jscadTextAlignEnum, - extrudeOffset?: number - ); - /** - * Text to write - * @default Hello World - */ - text: string; - /** - * Number of segments - * @default 24 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - segments: number; - /** - * X offset of the text - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - xOffset: number; - /** - * Y offset of the text - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - yOffset: number; - /** - * Height of the text - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - height: number; - /** - * Space between lines - * @default 1.4 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - lineSpacing: number; - /** - * Space between letters - * @default 1 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - letterSpacing: number; - /** - * Align between left, center, right - * @default center - */ - align: jscadTextAlignEnum; - /** - * Offset the extrusion - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - extrudeOffset: number; - } - class CylinderTextDto { - constructor( - text?: string, - extrusionHeight?: number, - extrusionSize?: number, - segments?: number, - xOffset?: number, - yOffset?: number, - height?: number, - lineSpacing?: number, - letterSpacing?: number, - align?: jscadTextAlignEnum, - extrudeOffset?: number - ); - /** - * Text to write - * @default Hello World - */ - text: string; - /** - * Height of the cylinder - * @default 0.5 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - extrusionHeight: number; - /** - * Radius of the cylinder - * @default 0.1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - extrusionSize: number; - /** - * Segment subdivision for cylinder - * @default 24 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - segments: number; - /** - * X offset of the text - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - xOffset: number; - /** - * Y offset of the text - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - yOffset: number; - /** - * Height of the text - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - height: number; - /** - * Space between lines - * @default 1.4 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - lineSpacing: number; - /** - * Space between letters - * @default 1 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - letterSpacing: number; - /** - * Align between left, center, right - * @default center - */ - align: jscadTextAlignEnum; - /** - * Offset the extrusion - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - extrudeOffset: number; - } - class SphereTextDto { - constructor( - text?: string, - radius?: number, - segments?: number, - xOffset?: number, - yOffset?: number, - height?: number, - lineSpacing?: number, - letterSpacing?: number, - align?: jscadTextAlignEnum, - extrudeOffset?: number - ); - /** - * Text to write - * @default Hello World - */ - text: string; - /** - * Radius of the spheres - * @default 0.1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - radius: number; - /** - * Segment subdivision for sphere - * @default 24 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - segments: number; - /** - * X offset of the text - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - xOffset: number; - /** - * Y offset of the text - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - yOffset: number; - /** - * Height of the text - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - height: number; - /** - * Space between lines - * @default 1.4 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - lineSpacing: number; - /** - * Space between letters - * @default 1 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - letterSpacing: number; - /** - * Align between left, center, right - * @default center - */ - align: jscadTextAlignEnum; - /** - * Offset the extrusion - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - extrudeOffset: number; - } - class FromPolygonPoints { - constructor(polygonPoints?: Base.Point3[][]); - /** - * Points describing polygons - */ - polygonPoints?: Base.Point3[][]; - } - } - declare namespace Base { - type Color = string; - type ColorRGB = { - r: number; - g: number; - b: number; - }; - type Point2 = [number, number]; - type Vector2 = [number, number]; - type Point3 = [number, number, number]; - type Vector3 = [number, number, number]; - type Axis3 = { - origin: Base.Point3; - direction: Base.Vector3; - }; - type Axis2 = { - origin: Base.Point2; - direction: Base.Vector2; - }; - type Segment2 = [Point2, Point2]; - type Segment3 = [Point3, Point3]; - type TrianglePlane3 = { - normal: Vector3; - d: number; - }; - type Triangle3 = [Base.Point3, Base.Point3, Base.Point3]; - type Mesh3 = Triangle3[]; - type Plane3 = { - origin: Base.Point3; - normal: Base.Vector3; - direction: Base.Vector3; - }; - type BoundingBox = { - min: Base.Point3; - max: Base.Point3; - center?: Base.Point3; - width?: number; - height?: number; - length?: number; - }; - type Line2 = { - start: Base.Point2; - end: Base.Point2; - }; - type Line3 = { - start: Base.Point3; - end: Base.Point3; - }; - type Polyline3 = { - points: Base.Point3[]; - isClosed?: boolean; - }; - type Polyline2 = { - points: Base.Point2[]; - isClosed?: boolean; - }; - type VerbCurve = { - tessellate: (options: any) => any; - }; - type VerbSurface = { - tessellate: (options: any) => any; - }; - type TransformMatrix3x3 = [ - number, - number, - number, - number, - number, - number, - number, - number, - number - ]; - type TransformMatrixes3x3 = TransformMatrix3x3[]; - type TransformMatrix = [ - number, - number, - number, - number, - number, - number, - number, - number, - number, - number, - number, - number, - number, - number, - number, - number - ]; - type TransformMatrixes = TransformMatrix[]; - } - declare namespace Manifold { - type ManifoldPointer = { - hash: number; - type: string; - }; - type CrossSectionPointer = { - hash: number; - type: string; - }; - type MeshPointer = { - hash: number; - type: string; - }; - enum fillRuleEnum { - evenOdd = "EvenOdd", - nonZero = "NonZero", - positive = "Positive", - negative = "Negative", - } - enum manifoldJoinTypeEnum { - square = "Square", - round = "Round", - miter = "Miter", - bevel = "Bevel", - } - class DecomposedManifoldMeshDto { - numProp: number; - vertProperties: Float32Array; - triVerts: Uint32Array; - mergeFromVert?: Uint32Array; - mergeToVert?: Uint32Array; - runIndex?: Uint32Array; - runOriginalID?: Uint32Array; - runTransform?: Float32Array; - faceID?: Uint32Array; - halfedgeTangent?: Float32Array; - } - class DrawManifoldOrCrossSectionDto { - /** - * Provide options without default values - */ - constructor( - manifoldOrCrossSection?: T, - faceOpacity?: number, - faceMaterial?: M, - faceColour?: Base.Color, - crossSectionColour?: Base.Color, - crossSectionWidth?: number, - crossSectionOpacity?: number, - computeNormals?: boolean, - drawTwoSided?: boolean, - backFaceColour?: Base.Color, - backFaceOpacity?: number - ); - /** - * Manifold geometry - * @default undefined - */ - manifoldOrCrossSection?: T; - /** - * Face opacity value between 0 and 1 - * @default 1 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - faceOpacity: number; - /** - * Face material - * @default undefined - * @optional true - */ - faceMaterial?: M; - /** - * Hex colour string for face colour - * @default #ff0000 - */ - faceColour: Base.Color; - /** - * Hex colour string for cross section drawing - * @default #ff00ff - */ - crossSectionColour: Base.Color; - /** - * Width of cross section lines - * @default 2 - */ - crossSectionWidth: number; - /** - * Cross section opacity value between 0 and 1 - * @default 1 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - crossSectionOpacity: number; - /** - * Compute normals for the shape - * @default false - */ - computeNormals: boolean; - /** - * Draw two-sided faces with different colors for front and back. This helps visualize face orientation. - * @default true - */ - drawTwoSided: boolean; - /** - * Hex colour string for back face colour (negative side of the face). Only used when drawTwoSided is true. - * @default #0000ff - */ - backFaceColour: Base.Color; - /** - * Back face opacity value between 0 and 1. Only used when drawTwoSided is true. - * @default 1 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - backFaceOpacity: number; - } - class DrawManifoldsOrCrossSectionsDto { - /** - * Provide options without default values - */ - constructor( - manifoldsOrCrossSections?: T[], - faceOpacity?: number, - faceMaterial?: M, - faceColour?: Base.Color, - crossSectionColour?: Base.Color, - crossSectionWidth?: number, - crossSectionOpacity?: number, - computeNormals?: boolean, - drawTwoSided?: boolean, - backFaceColour?: Base.Color, - backFaceOpacity?: number - ); - /** - * Manifold geometry - * @default undefined - */ - manifoldsOrCrossSections?: T[]; - /** - * Face material - * @default undefined - * @optional true - */ - faceMaterial?: M; - /** - * Hex colour string for face colour - * @default #ff0000 - */ - faceColour: Base.Color; - /** - * Face opacity value between 0 and 1 - * @default 1 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - faceOpacity: number; - /** - * Hex colour string for cross section drawing - * @default #ff00ff - */ - crossSectionColour: Base.Color; - /** - * Width of cross section lines - * @default 2 - */ - crossSectionWidth: number; - /** - * Cross section opacity value between 0 and 1 - * @default 1 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - crossSectionOpacity: number; - /** - * Compute normals for the shape - * @default false - */ - computeNormals: boolean; - /** - * Draw two-sided faces with different colors for front and back. This helps visualize face orientation. - * @default true - */ - drawTwoSided: boolean; - /** - * Hex colour string for back face colour (negative side of the face). Only used when drawTwoSided is true. - * @default #0000ff - */ - backFaceColour: Base.Color; - /** - * Back face opacity value between 0 and 1. Only used when drawTwoSided is true. - * @default 1 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - backFaceOpacity: number; - } - class CreateFromMeshDto { - constructor(mesh?: DecomposedManifoldMeshDto); - /** - * Mesh definition - */ - mesh: DecomposedManifoldMeshDto; - } - class FromPolygonPointsDto { - constructor(polygonPoints?: Base.Point3[][]); - /** - * Points describing polygons - */ - polygonPoints?: Base.Point3[][]; - } - class CrossSectionFromPolygonPointsDto { - constructor( - points?: Base.Point3[], - fillRule?: fillRuleEnum, - removeDuplicates?: boolean, - tolerance?: number - ); - /** - * Points describing a single polygon - */ - points: Base.Point3[]; - /** - * Fill rule for polygon interpretation - * @default positive - */ - fillRule?: fillRuleEnum; - /** - * Remove consecutive duplicate points before creating polygon - * @default false - */ - removeDuplicates?: boolean; - /** - * Tolerance for duplicate removal - * @default 1e-7 - */ - tolerance?: number; - } - class CrossSectionFromPolygonsPointsDto { - constructor( - polygonPoints?: Base.Point3[][], - fillRule?: fillRuleEnum, - removeDuplicates?: boolean, - tolerance?: number - ); - /** - * Points describing multiple polygons - */ - polygonPoints: Base.Point3[][]; - /** - * Fill rule for polygon interpretation - * @default positive - */ - fillRule?: fillRuleEnum; - /** - * Remove consecutive duplicate points before creating polygons - * @default false - */ - removeDuplicates?: boolean; - /** - * Tolerance for duplicate removal - * @default 1e-7 - */ - tolerance?: number; - } - class CubeDto { - constructor(center?: boolean, size?: number); - /** - * Place cube on the center - * @default true - */ - center: boolean; - /** - * Size of the cube - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - size: number; - } - class CreateContourSectionDto { - constructor(polygons?: Base.Vector2[][], fillRule?: fillRuleEnum); - /** - * Polygons to use for the contour section - * @default undefined - */ - polygons: Base.Vector2[][]; - /** - * Fill rule for the contour section - * @default EvenOdd - */ - fillRule: fillRuleEnum; - } - class SquareDto { - constructor(center?: boolean, size?: number); - /** - * Place cube on the center - * @default false - */ - center: boolean; - /** - * Size of the cube - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - size: number; - } - class SphereDto { - constructor(radius?: number, circularSegments?: number); - /** - * Radius of the sphere - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - radius: number; - /** - * Circular segments of the sphere - * @default 32 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - circularSegments: number; - } - class CylinderDto { - constructor( - height?: number, - radiusLow?: number, - radiusHigh?: number, - circularSegments?: number, - center?: boolean - ); - /** - * Height of the cylinder - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - height: number; - /** - * Radius of the cylinder - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - radiusLow: number; - /** - * Radius of the cylinder - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - radiusHigh: number; - /** - * Circular segments of the cylinder - * @default 32 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - circularSegments: number; - /** - * Place cylinder on the center - * @default true - */ - center: boolean; - } - class CircleDto { - constructor(radius?: number, circularSegments?: number); - /** - * Radius of the cylinder - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - radius: number; - /** - * Circular segments of the cylinder - * @default 32 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - circularSegments: number; - } - class RectangleDto { - constructor(length?: number, height?: number, center?: boolean); - /** - * Length of the rectangle - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - length: number; - /** - * Height of the rectangle - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - height: number; - /** - * Place rectangle on the center - * @default false - */ - center: boolean; - } - class ManifoldDto { - constructor(manifold?: T); - /** - * Manifold shape - */ - manifold: T; - } - class CalculateNormalsDto { - constructor(manifold?: T, normalIdx?: number, minSharpAngle?: number); - /** - * Manifold shape - */ - manifold: T; - /** - * The property channel in which to store the X - * values of the normals. The X, Y, and Z channels will be sequential. The - * property set will be automatically expanded to include up through normalIdx - * + 2. - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - normalIdx: number; - /** - * Any edges with angles greater than this value will - * remain sharp, getting different normal vector properties on each side of - * the edge. By default, no edges are sharp and all normals are shared. With a - * value of zero, the model is faceted and all normals match their triangle - * normals, but in this case it would be better not to calculate normals at - * all. The value is in degrees. - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - minSharpAngle: number; - } - class CalculateCurvatureDto { - constructor(manifold?: T); - /** - * Manifold shape - */ - manifold: T; - /** - * The property channel index in which to store the - * Gaussian curvature. An index < 0 will be ignored (stores nothing). The - * property set will be automatically expanded to include the channel - * index specified. - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - gaussianIdx: number; - /** - * The property channel index in which to store the mean - * curvature. An index < 0 will be ignored (stores nothing). The property - * set will be automatically expanded to include the channel index - * specified. The mean curvature is a scalar value that describes the - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - meanIdx: number; - } - class CountDto { - constructor(count?: number); - /** - * Nr to count - */ - count: number; - } - class ManifoldsMinGapDto { - constructor(manifold1?: T, manifold2?: T, searchLength?: number); - /** - * Manifold shape - */ - manifold1: T; - /** - * Manifold shape - */ - manifold2: T; - /** - * Length of the search gap - * @default 100 - * @minimum 0 - * @maximum Infinity - * @step 10 - */ - searchLength: number; - } - class ManifoldRefineToleranceDto { - constructor(manifold?: T, tolerance?: number); - /** - * Manifold shape - */ - manifold: T; - /** - * The desired maximum distance between the faceted mesh - * produced and the exact smoothly curving surface. All vertices are exactly - * on the surface, within rounding error. - * @default 1e-6 - * @minimum 0 - * @maximum Infinity - * @step 1e-7 - */ - tolerance: number; - } - class ManifoldRefineLengthDto { - constructor(manifold?: T, length?: number); - /** - * Manifold shape - */ - manifold: T; - /** - * Length of the manifold - * @default 0.1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - length: number; - } - class ManifoldRefineDto { - constructor(manifold?: T, number?: number); - /** - * Manifold shape - */ - manifold: T; - /** - * The number of pieces to split every edge into. Must be > 1. - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - number: number; - } - class ManifoldSmoothByNormalsDto { - constructor(manifold?: T, normalIdx?: number); - /** - * Manifold shape - */ - manifold: T; - /** - * The first property channel of the normals. NumProp must be - * at least normalIdx + 3. Any vertex where multiple normals exist and don't - * agree will result in a sharp edge. - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - normalIdx: number; - } - class ManifoldSimplifyDto { - constructor(manifold?: T, tolerance?: number); - /** - * Manifold shape - */ - manifold: T; - /** - * The maximum distance between the original and simplified meshes. - * If not given or is less than the current tolerance, the current tolerance is used. - * The result will contain a subset of the original verts and all surfaces will have moved by less than tolerance. - * @default undefined - * @minimum 0 - * @maximum Infinity - * @step 0.001 - */ - tolerance?: number; - } - class ManifoldSetPropertiesDto { - constructor( - manifold?: T, - numProp?: number, - propFunc?: ( - newProp: number[], - position: Base.Vector3, - oldProp: number[] - ) => void - ); - /** - * Manifold shape - */ - manifold: T; - /** - * The new number of properties per vertex - * @default 3 - * @minimum 3 - * @maximum Infinity - * @step 1 - */ - numProp: number; - /** - * A function that modifies the properties of a given vertex. - * Note: undefined behavior will result if you read past the number of input properties or write past the number of output properties. - * @default undefined - */ - propFunc: ( - newProp: number[], - position: Base.Vector3, - oldProp: number[] - ) => void; - } - class ManifoldSmoothOutDto { - constructor( - manifold?: T, - minSharpAngle?: number, - minSmoothness?: number - ); - /** - * Manifold shape - */ - manifold: T; - /** - * Any edges with angles greater - * than this value will remain sharp. The rest will be smoothed to G1 - * continuity, with the caveat that flat faces of three or more triangles will - * always remain flat. With a value of zero, the model is faceted, but in this - * case there is no point in smoothing. - * @default 60 - * @minimum -Infinity - * @maximum Infinity - * @step 1 - */ - minSharpAngle: number; - /** - * The smoothness applied to - * sharp angles. The default gives a hard edge, while values > 0 will give a - * small fillet on these sharp edges. A value of 1 is equivalent to a - * minSharpAngle of 180 - all edges will be smooth. - * @default 0 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - minSmoothness: number; - } - class HullPointsDto { - constructor(points?: T); - /** - * Points to hull - */ - points: T; - } - class SliceDto { - constructor(manifold?: T); - /** - * Manifold shape - */ - manifold: T; - /** - * Height of the slice - * @default 0.5 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - height: number; - } - class MeshDto { - constructor(mesh?: T); - /** - * Mesh - */ - mesh: T; - } - class MeshVertexIndexDto { - constructor(mesh?: T, vertexIndex?: number); - /** - * Mesh - */ - mesh: T; - /** - * Vertex index - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - vertexIndex: number; - } - class MeshTriangleRunIndexDto { - constructor(mesh?: T, triangleRunIndex?: number); - /** - * Mesh - */ - mesh: T; - /** - * Triangle run index - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - triangleRunIndex: number; - } - class MeshHalfEdgeIndexDto { - constructor(mesh?: T, halfEdgeIndex?: number); - /** - * Mesh - */ - mesh: T; - /** - * Half edge index - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - halfEdgeIndex: number; - } - class MeshTriangleIndexDto { - constructor(mesh?: T, triangleIndex?: number); - /** - * Mesh - */ - mesh: T; - /** - * Triangle index - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - triangleIndex: number; - } - class CrossSectionDto { - constructor(crossSection?: T); - /** - * Cross section - */ - crossSection: T; - } - class CrossSectionsDto { - constructor(crossSections?: T[]); - /** - * Cross sections - */ - crossSections: T[]; - } - class ExtrudeDto { - constructor(crossSection?: T); - /** - * Extrude cross section shape - */ - crossSection: T; - /** - * Height of the extrusion - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - height: number; - /** - * Number of divisions - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - nDivisions: number; - /** - * Twist degrees - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 1 - */ - twistDegrees: number; - /** - * Scale top - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - scaleTopX: number; - /** - * Scale top - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - scaleTopY: number; - /** - * Center the extrusion - * @default true - */ - center: boolean; - } - class RevolveDto { - constructor( - crossSection?: T, - revolveDegrees?: number, - matchProfile?: boolean, - circularSegments?: number - ); - /** - * Revolve cross section shape - */ - crossSection: T; - /** - * Extrude cross section shape - * @default 360 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - revolveDegrees: number; - /** - * Default manifold library will adjust profile when generating revolved shape. We prefer it to be matching the profile by default. Set to false to use default manifold library behavior. - * @default true - */ - matchProfile: boolean; - /** - * Circular segments - * @default 32 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - circularSegments: number; - } - class OffsetDto { - constructor( - crossSection?: T, - delta?: number, - joinType?: manifoldJoinTypeEnum, - miterLimit?: number, - circularSegments?: number - ); - /** - * Revolve cross section shape - */ - crossSection: T; - /** - * Positive deltas will cause the expansion of outlining contours - * to expand, and retraction of inner (hole) contours. Negative deltas will - * have the opposite effect. - * @default 1 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - delta: number; - /** - * The join type specifying the treatment of contour joins - * (corners). - * @default round - */ - joinType: manifoldJoinTypeEnum; - /** - * The maximum distance in multiples of delta that vertices - * can be offset from their original positions with before squaring is - * applied, **when the join type is Miter** (default is 2, which is the - * minimum allowed). See the [Clipper2 - * MiterLimit](http://www.angusj.com/clipper2/Docs/Units/Clipper.Offset/Classes/ClipperOffset/Properties/MiterLimit.htm) - * page for a visual example. - * @default 2 - * @minimum 2 - * @maximum Infinity - * @step 0.1 - */ - miterLimit: number; - /** - * Number of segments per 360 degrees of - * JoinType::Round corners (roughly, the number of vertices that - * will be added to each contour). Default is calculated by the static Quality - * defaults according to the radius. - * @default 32 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - circularSegments: number; - } - class SimplifyDto { - constructor(crossSection?: T, epsilon?: number); - /** - * Revolve cross section shape - */ - crossSection: T; - /** - * Extrude cross section shape - * @default 1e-6 - * @minimum 0 - * @maximum Infinity - * @step 1e-7 - */ - epsilon: number; - } - class ComposeDto { - constructor(polygons?: T); - /** - * Polygons to compose - */ - polygons: T; - } - class MirrorCrossSectionDto { - constructor(crossSection?: T, normal?: Base.Vector2); - /** - * Manifold shape - */ - crossSection: T; - /** - * The normal vector of the plane to be mirrored over - * @default [1,0] - */ - normal: Base.Vector2; - } - class Scale2DCrossSectionDto { - constructor(crossSection?: T, vector?: Base.Vector2); - /** - * Manifold shape - */ - crossSection: T; - /** - * The normal vector of the plane to be mirrored over - * @default [2,2] - */ - vector: Base.Vector2; - } - class TranslateCrossSectionDto { - constructor(crossSection?: T, vector?: Base.Vector2); - /** - * Manifold shape - */ - crossSection: T; - /** - * The translation vector - * @default undefined - */ - vector: Base.Vector2; - } - class RotateCrossSectionDto { - constructor(crossSection?: T, degrees?: number); - /** - * Manifold shape - */ - crossSection: T; - /** - * The rotation vector in eulers - * @default 45 - * @minimum -Infinity - * @maximum Infinity - * @step 1 - */ - degrees: number; - } - class ScaleCrossSectionDto { - constructor(crossSection?: T, factor?: number); - /** - * Manifold shape - */ - crossSection: T; - /** - * The normal vector of the plane to be mirrored over - * @default 2 - */ - factor: number; - } - class TranslateXYCrossSectionDto { - constructor(crossSection?: T, x?: number, y?: number); - /** - * Manifold shape - */ - crossSection: T; - /** - * The translation X axis - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 1 - */ - x: number; - /** - * The translation Y axis - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 1 - */ - y: number; - } - class TransformCrossSectionDto { - constructor(crossSection?: T, transform?: Base.TransformMatrix3x3); - /** - * Cross section - */ - crossSection: T; - /** - * The transform matrix to apply - * @default undefined - */ - transform: Base.TransformMatrix3x3; - } - class CrossSectionWarpDto { - constructor(crossSection?: T, warpFunc?: (vert: Base.Vector2) => void); - /** - * Cross section - */ - crossSection: T; - /** - * A function that modifies a given vertex position - * @default undefined - */ - warpFunc: (vert: Base.Vector2) => void; - } - class MirrorDto { - constructor(manifold?: T, normal?: Base.Vector3); - /** - * Manifold shape - */ - manifold: T; - /** - * The normal vector of the plane to be mirrored over - * @default [1,0,0] - */ - normal: Base.Vector3; - } - class Scale3DDto { - constructor(manifold?: T, vector?: Base.Vector3); - /** - * Manifold shape - */ - manifold: T; - /** - * The normal vector of the plane to be mirrored over - * @default [2,2,2] - */ - vector: Base.Vector3; - } - class TranslateDto { - constructor(manifold?: T, vector?: Base.Vector3); - /** - * Manifold shape - */ - manifold: T; - /** - * The translation vector - * @default undefined - */ - vector: Base.Vector3; - } - class TranslateByVectorsDto { - constructor(manifold?: T, vectors?: Base.Vector3[]); - /** - * Manifold shape - */ - manifold: T; - /** - * The translation vector - * @default undefined - */ - vectors: Base.Vector3[]; - } - class RotateDto { - constructor(manifold?: T, vector?: Base.Vector3); - /** - * Manifold shape - */ - manifold: T; - /** - * The rotation vector in eulers - * @default undefined - */ - vector: Base.Vector3; - } - class RotateXYZDto { - constructor(manifold?: T, x?: number, y?: number, z?: number); - /** - * Manifold shape - */ - manifold: T; - /** - * The rotation vector in eulers on X axis - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 1 - */ - x: number; - /** - * The rotation vector in eulers on Y axis - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 1 - */ - y: number; - /** - * The rotation vector in eulers on Z axis - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 1 - */ - z: number; - } - class ScaleDto { - constructor(manifold?: T, factor?: number); - /** - * Manifold shape - */ - manifold: T; - /** - * The normal vector of the plane to be mirrored over - * @default 2 - */ - factor: number; - } - class TranslateXYZDto { - constructor(manifold?: T, x?: number, y?: number, z?: number); - /** - * Manifold shape - */ - manifold: T; - /** - * The translation X axis - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 1 - */ - x: number; - /** - * The translation Y axis - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 1 - */ - y: number; - /** - * The translation Z axis - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 1 - */ - z: number; - } - class TransformDto { - constructor(manifold?: T, transform?: Base.TransformMatrix); - /** - * Manifold shape - */ - manifold: T; - /** - * The transform matrix to apply - * @default undefined - */ - transform: Base.TransformMatrix; - } - class TransformsDto { - constructor(manifold?: T, transforms?: Base.TransformMatrixes); - /** - * Manifold shape - */ - manifold: T; - /** - * The transform matrixes to apply - * @default undefined - */ - transforms: Base.TransformMatrixes; - } - class ManifoldWarpDto { - constructor(manifold?: T, warpFunc?: (vert: Base.Vector3) => void); - /** - * Manifold shape - */ - manifold: T; - /** - * A function that modifies a given vertex position - * @default undefined - */ - warpFunc: (vert: Base.Vector3) => void; - } - class TwoCrossSectionsDto { - constructor(crossSection1?: T, crossSection2?: T); - /** - * Manifold shape - */ - crossSection1: T; - /** - * Manifold shape - */ - crossSection2: T; - } - class TwoManifoldsDto { - constructor(manifold1?: T, manifold2?: T); - /** - * Manifold shape - */ - manifold1: T; - /** - * Manifold shape - */ - manifold2: T; - } - class SplitManifoldsDto { - constructor(manifoldToSplit?: T, manifoldCutter?: T); - /** - * Manifold that will be split - */ - manifoldToSplit: T; - /** - * Manifold cutter - */ - manifoldCutter: T; - } - class TrimByPlaneDto { - constructor(manifold?: T, normal?: Base.Vector3, originOffset?: number); - /** - * Manifold that will be trimmed - */ - manifold: T; - /** - * The normal vector of the plane to be mirrored over - * @default [1,0,0] - */ - normal: Base.Vector3; - /** - * The offset from the origin - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - originOffset: number; - } - class SplitByPlaneDto { - constructor(manifold?: T, normal?: Base.Vector3, originOffset?: number); - /** - * Manifold that will be split - */ - manifold: T; - /** - * The normal vector of the plane to be mirrored over - * @default [1,0,0] - */ - normal: Base.Vector3; - /** - * The offset from the origin - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - originOffset: number; - } - class SplitByPlaneOnOffsetsDto { - constructor( - manifold?: T, - normal?: Base.Vector3, - originOffsets?: number[] - ); - /** - * Manifold that will be split - */ - manifold: T; - /** - * The normal vector of the plane to be mirrored over - * @default [1,0,0] - */ - normal: Base.Vector3; - /** - * The offsets from the origin - * @default [0] - */ - originOffsets: number[]; - } - class ManifoldsDto { - constructor(manifolds?: T[]); - /** - * Manifolds - */ - manifolds: T[]; - } - class ManifoldToMeshDto { - constructor(manifold?: T, normalIdx?: number); - /** - * Manifold shape - */ - manifold: T; - /** - * Optional normal index - */ - normalIdx?: number; - } - class ManifoldsToMeshesDto { - constructor(manifolds?: T[], normalIdx?: number[]); - /** - * Manifold shape - */ - manifolds: T[]; - /** - * Optional normal indexes - */ - normalIdx?: number[]; - } - class DecomposeManifoldOrCrossSectionDto { - constructor(manifoldOrCrossSection?: T, normalIdx?: number); - /** - * Manifold shape - */ - manifoldOrCrossSection: T; - /** - * Optional normal index - */ - normalIdx?: number; - } - class ManifoldOrCrossSectionDto { - constructor(manifoldOrCrossSection?: T); - /** - * Manifold or cross section - */ - manifoldOrCrossSection: T; - } - class ManifoldsOrCrossSectionsDto { - constructor(manifoldsOrCrossSections?: T[]); - /** - * Manifolds or cross sections - */ - manifoldsOrCrossSections: T[]; - } - class DecomposeManifoldsOrCrossSectionsDto { - constructor(manifoldsOrCrossSections?: T[], normalIdx?: number[]); - /** - * Manifold shape - */ - manifoldsOrCrossSections: T[]; - /** - * Optional normal indexes - */ - normalIdx?: number[]; - } - } - declare namespace OCCT { - type GeomCurvePointer = { - hash: number; - type: string; - }; - type Geom2dCurvePointer = { - hash: number; - type: string; - }; - type GeomSurfacePointer = { - hash: number; - type: string; - }; - type TopoDSVertexPointer = { - hash: number; - type: string; - }; - type TopoDSEdgePointer = { - hash: number; - type: string; - }; - type TopoDSWirePointer = { - hash: number; - type: string; - }; - type TopoDSFacePointer = { - hash: number; - type: string; - }; - type TopoDSShellPointer = { - hash: number; - type: string; - }; - type TopoDSSolidPointer = { - hash: number; - type: string; - }; - type TopoDSCompSolidPointer = { - hash: number; - type: string; - }; - type TopoDSCompoundPointer = { - hash: number; - type: string; - }; - type TopoDSShapePointer = - | TopoDSVertexPointer - | TopoDSEdgePointer - | TopoDSWirePointer - | TopoDSFacePointer - | TopoDSShellPointer - | TopoDSSolidPointer - | TopoDSCompoundPointer; - enum joinTypeEnum { - arc = "arc", - intersection = "intersection", - tangent = "tangent", - } - enum bRepOffsetModeEnum { - skin = "skin", - pipe = "pipe", - rectoVerso = "rectoVerso", - } - enum approxParametrizationTypeEnum { - approxChordLength = "approxChordLength", - approxCentripetal = "approxCentripetal", - approxIsoParametric = "approxIsoParametric", - } - enum directionEnum { - outside = "outside", - inside = "inside", - middle = "middle", - } - enum fileTypeEnum { - iges = "iges", - step = "step", - } - enum topAbsOrientationEnum { - forward = "forward", - reversed = "reversed", - internal = "internal", - external = "external", - } - enum topAbsStateEnum { - in = "in", - out = "out", - on = "on", - unknown = "unknown", - } - enum shapeTypeEnum { - unknown = "unknown", - vertex = "vertex", - edge = "edge", - wire = "wire", - face = "face", - shell = "shell", - solid = "solid", - compSolid = "compSolid", - compound = "compound", - shape = "shape", - } - enum gccEntPositionEnum { - unqualified = "unqualified", - enclosing = "enclosing", - enclosed = "enclosed", - outside = "outside", - noqualifier = "noqualifier", - } - enum positionResultEnum { - keepSide1 = "keepSide1", - keepSide2 = "keepSide2", - all = "all", - } - enum circleInclusionEnum { - none = "none", - keepSide1 = "keepSide1", - keepSide2 = "keepSide2", - } - enum twoCircleInclusionEnum { - none = "none", - outside = "outside", - inside = "inside", - outsideInside = "outsideInside", - insideOutside = "insideOutside", - } - enum fourSidesStrictEnum { - outside = "outside", - inside = "inside", - outsideInside = "outsideInside", - insideOutside = "insideOutside", - } - enum twoSidesStrictEnum { - outside = "outside", - inside = "inside", - } - enum combinationCirclesForFaceEnum { - allWithAll = "allWithAll", - inOrder = "inOrder", - inOrderClosed = "inOrderClosed", - } - enum typeSpecificityEnum { - curve = 0, - edge = 1, - wire = 2, - face = 3, - } - enum pointProjectionTypeEnum { - all = "all", - closest = "closest", - furthest = "furthest", - closestAndFurthest = "closestAndFurthest", - } - enum geomFillTrihedronEnum { - isCorrectedFrenet = "isCorrectedFrenet", - isFixed = "isFixed", - isFrenet = "isFrenet", - isConstantNormal = "isConstantNormal", - isDarboux = "isDarboux", - isGuideAC = "isGuideAC", - isGuidePlan = "isGuidePlan", - isGuideACWithContact = "isGuideACWithContact", - isGuidePlanWithContact = "isGuidePlanWithContact", - isDiscreteTrihedron = "isDiscreteTrihedron", - } - enum dxfColorFormatEnum { - aci = "aci", - truecolor = "truecolor", - } - enum dxfAcadVersionEnum { - AC1009 = "AC1009", - AC1015 = "AC1015", - } - enum dimensionEndTypeEnum { - none = "none", - arrow = "arrow", - } - class DecomposedMeshDto { - constructor( - faceList?: DecomposedFaceDto[], - edgeList?: DecomposedEdgeDto[] - ); - /** - * Face list for decomposed faces - */ - faceList: DecomposedFaceDto[]; - /** - * Edge list for decomposed edges - */ - edgeList: DecomposedEdgeDto[]; - /** - * The points list in a shape that includes vertex shapes - */ - pointsList: Base.Point3[]; - } - class DecomposedFaceDto { - face_index: number; - normal_coord: number[]; - number_of_triangles: number; - tri_indexes: number[]; - vertex_coord: number[]; - vertex_coord_vec: Base.Vector3[]; - center_point: Base.Point3; - center_normal: Base.Vector3; - uvs: number[]; - } - class DecomposedEdgeDto { - edge_index: number; - middle_point: Base.Point3; - vertex_coord: Base.Vector3[]; - } - class ShapesDto { - constructor(shapes?: T[]); - /** - * The OCCT shapes - * @default undefined - */ - shapes: T[]; - } - class PointDto { - constructor(point?: Base.Point3); - /** - * The point - * @default [0, 0, 0] - */ - point: Base.Point3; - } - class XYZDto { - constructor(x?: number, y?: number, z?: number); - /** - * X coord - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - x: number; - /** - * Y coord - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - y: number; - /** - * Z coord - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - z: number; - } - class PointsDto { - constructor(points?: Base.Point3[]); - /** - * The point - * @default undefined - */ - points: Base.Point3[]; - } - class ConstraintTanLinesFromPtToCircleDto { - constructor( - circle?: T, - point?: Base.Point3, - tolerance?: number, - positionResult?: positionResultEnum, - circleRemainder?: circleInclusionEnum - ); - /** - * The circle for tangent points - * @default undefined - */ - circle: T; - /** - * The point from which to find the lines - * @default undefined - */ - point: Base.Point3; - /** - * tolerance - * @default 1e-7 - * @minimum 0 - * @maximum Infinity - * @step 0.00001 - */ - tolerance: number; - /** - * Filters resulting lines by position - * @default all - */ - positionResult: positionResultEnum; - /** - * Splits provided circle on tangent points and adds it to the solutions - * This only works when number of solutions contains 2 lines, when solution involves more than 4 lines, this option will be ignored. - * @default none - */ - circleRemainder: circleInclusionEnum; - } - class ConstraintTanLinesFromTwoPtsToCircleDto { - constructor( - circle?: T, - point1?: Base.Point3, - point2?: Base.Point3, - tolerance?: number, - positionResult?: positionResultEnum, - circleRemainder?: circleInclusionEnum - ); - /** - * The circle for tangent points - * @default undefined - */ - circle: T; - /** - * The point from which to find the lines - * @default undefined - */ - point1: Base.Point3; - /** - * The point from which to find the lines - * @default undefined - */ - point2: Base.Point3; - /** - * tolerance - * @default 1e-7 - * @minimum 0 - * @maximum Infinity - * @step 0.00001 - */ - tolerance: number; - /** - * Filters resulting lines by position - * @default all - */ - positionResult: positionResultEnum; - /** - * Splits provided circle on tangent points and adds it to the solutions - * This only works when number of solutions contains 2 lines, when solution involves more than 4 lines, this option will be ignored. - * @default none - */ - circleRemainder: circleInclusionEnum; - } - class ConstraintTanLinesOnTwoCirclesDto { - constructor( - circle1?: T, - circle2?: T, - tolerance?: number, - positionResult?: positionResultEnum, - circleRemainders?: twoCircleInclusionEnum - ); - /** - * The first circle for tangential lines - * @default undefined - */ - circle1: T; - /** - * The second circle for tangential lines - * @default undefined - */ - circle2: T; - /** - * tolerance - * @default 1e-7 - * @minimum 0 - * @maximum Infinity - * @step 0.00001 - */ - tolerance: number; - /** - * Filters resulting lines by position relative to circles - * @default all - */ - positionResult: positionResultEnum; - /** - * Splits provided circles on tangent points and returns those as part of the solutions - * This only works when number of solutions is limited to 2 lines, when solution involves more than 4 lines, this option will be ignored. - * @default none - */ - circleRemainders: twoCircleInclusionEnum; - } - class ConstraintTanCirclesOnTwoCirclesDto { - constructor( - circle1?: T, - circle2?: T, - tolerance?: number, - radius?: number - ); - /** - * The first circle for tangential lines - * @default undefined - */ - circle1: T; - /** - * The second circle for tangential lines - * @default undefined - */ - circle2: T; - /** - * tolerance - * @default 1e-7 - * @minimum 0 - * @maximum Infinity - * @step 0.00001 - */ - tolerance: number; - /** - * Radius of the circles being constructed - * @default 0.3 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - radius: number; - } - class ConstraintTanCirclesOnCircleAndPntDto { - constructor( - circle?: T, - point?: Base.Point3, - tolerance?: number, - radius?: number - ); - /** - * The first circle for tangential lines - * @default undefined - */ - circle: T; - /** - * The second circle for tangential lines - * @default undefined - */ - point: Base.Point3; - /** - * tolerance - * @default 1e-7 - * @minimum 0 - * @maximum Infinity - * @step 0.00001 - */ - tolerance: number; - /** - * Radius of the circles being constructed - * @default 0.3 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - radius: number; - } - class CurveAndSurfaceDto { - constructor(curve?: T, surface?: U); - /** - * Curve - * @default undefined - */ - curve: T; - /** - * Surface - * @default undefined - */ - surface: U; - } - class FilletTwoEdgesInPlaneDto { - constructor( - edge1?: T, - edge2?: T, - planeOrigin?: Base.Point3, - planeDirection?: Base.Vector3, - radius?: number, - solution?: number - ); - /** - * First OCCT edge to fillet - * @default undefined - */ - edge1: T; - /** - * Second OCCT edge to fillet - * @default undefined - */ - edge2: T; - /** - * Plane origin that is also used to find the closest solution if two solutions exist. - * @default [0, 0, 0] - */ - planeOrigin: Base.Point3; - /** - * Plane direction for fillet - * @default [0, 1, 0] - */ - planeDirection: Base.Vector3; - /** - * Radius of the fillet - * @default 0.3 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - radius: number; - /** - * if solution is -1 planeOrigin chooses a particular fillet in case of several fillets may be constructed (for example, a circle intersecting a segment in 2 points). Put the intersecting (or common) point of the edges - * @default -1 - * @optional true - */ - solution?: number; - } - class ClosestPointsOnShapeFromPointsDto { - constructor(shape?: T, points?: Base.Point3[]); - /** - * The OCCT shape - * @default undefined - */ - shape: T; - /** - * The list of points - * @default undefined - */ - points: Base.Point3[]; - } - class BoundingBoxDto { - constructor(bbox?: BoundingBoxPropsDto); - /** - * Bounding box - * @default undefined - */ - bbox?: BoundingBoxPropsDto; - } - class BoundingBoxPropsDto { - constructor( - min?: Base.Point3, - max?: Base.Point3, - center?: Base.Point3, - size?: Base.Vector3 - ); - /** - * Minimum point of the bounding box - * @default [0, 0, 0] - */ - min: Base.Point3; - /** - * Maximum point of the bounding box - * @default [0, 0, 0] - */ - max: Base.Point3; - /** - * Center point of the bounding box - * @default [0, 0, 0] - */ - center: Base.Point3; - /** - * Size of the bounding box - * @default [0, 0, 0] - */ - size: Base.Vector3; - } - class BoundingSpherePropsDto { - constructor(center?: Base.Point3, radius?: number); - /** - * Center point of the bounding box - * @default [0, 0, 0] - */ - center: Base.Point3; - /** - * Radius of the bounding sphere - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - radius: number; - } - class SplitWireOnPointsDto { - constructor(shape?: T, points?: Base.Point3[]); - /** - * The OCCT wire shape - * @default undefined - */ - shape: T; - /** - * The list of points - * @default undefined - */ - points: Base.Point3[]; - } - class ClosestPointsOnShapesFromPointsDto { - constructor(shapes?: T[], points?: Base.Point3[]); - /** - * The OCCT shapes - * @default undefined - */ - shapes: T[]; - /** - * The list of points - * @default undefined - */ - points: Base.Point3[]; - } - class ClosestPointsBetweenTwoShapesDto { - constructor(shape1?: T, shape2?: T); - /** - * First OCCT shape - * @default undefined - */ - shape1: T; - /** - * Second OCCT shape - * @default undefined - */ - shape2: T; - } - class FaceFromSurfaceAndWireDto { - constructor(surface?: T, wire?: U, inside?: boolean); - /** - * Surface from which to create a face - * @default undefined - */ - surface: T; - /** - * Wire that represents a boundary on the surface to delimit the face - * @default undefined - */ - wire: U; - /** - * Indicates wether face should be created inside or outside the wire - * @default true - */ - inside: boolean; - } - class WireOnFaceDto { - constructor(wire?: T, face?: U); - /** - * Wire to place on face - * @default undefined - */ - wire: T; - /** - * Face on which the wire will be placed - * @default undefined - */ - face: U; - } - class DrawShapeDto { - /** - * Provide options without default values - */ - constructor( - shape?: T, - faceOpacity?: number, - edgeOpacity?: number, - edgeColour?: Base.Color, - faceMaterial?: Base.Material, - faceColour?: Base.Color, - edgeWidth?: number, - drawEdges?: boolean, - drawFaces?: boolean, - drawVertices?: boolean, - vertexColour?: Base.Color, - vertexSize?: number, - precision?: number, - drawEdgeIndexes?: boolean, - edgeIndexHeight?: number, - edgeIndexColour?: Base.Color, - drawFaceIndexes?: boolean, - faceIndexHeight?: number, - faceIndexColour?: Base.Color, - drawTwoSided?: boolean, - backFaceColour?: Base.Color, - backFaceOpacity?: number - ); - /** - * Brep OpenCascade geometry - * @default undefined - */ - shape?: T; - /** - * Face opacity value between 0 and 1 - * @default 1 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - faceOpacity: number; - /** - * Edge opacity value between 0 and 1 - * @default 1 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - edgeOpacity: number; - /** - * Hex colour string for the edges - * @default #ffffff - */ - edgeColour: Base.Color; - /** - * Face material - * @default undefined - * @optional true - */ - faceMaterial?: Base.Material; - /** - * Hex colour string for face colour - * @default #ff0000 - */ - faceColour: Base.Color; - /** - * Edge width - * @default 2 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - edgeWidth: number; - /** - * You can turn off drawing of edges via this property - * @default true - */ - drawEdges: boolean; - /** - * You can turn off drawing of faces via this property - * @default true - */ - drawFaces: boolean; - /** - * You can turn off drawing of vertexes via this property - * @default false - */ - drawVertices: boolean; - /** - * Color of the vertices that will be drawn - * @default #ff00ff - */ - vertexColour: string; - /** - * The size of a vertices that will be drawn - * @default 0.03 - * @minimum 0 - * @maximum Infinity - * @step 0.01 - */ - vertexSize: number; - /** - * Precision of the mesh that will be generated for the shape, lower number will mean more triangles - * @default 0.01 - * @minimum 0 - * @maximum Infinity - * @step 0.01 - */ - precision: number; - /** - * Draw index of edges in space - * @default false - */ - drawEdgeIndexes: boolean; - /** - * Indicates the edge index height if they are drawn - * @default 0.06 - * @minimum 0 - * @maximum Infinity - * @step 0.01 - */ - edgeIndexHeight: number; - /** - * Edge index colour if the edges are drawn - * @default #ff00ff - */ - edgeIndexColour: Base.Color; - /** - * Draw indexes of faces in space - * @default false - */ - drawFaceIndexes: boolean; - /** - * Indicates the edge index height if they are drawn - * @default 0.06 - * @minimum 0 - * @maximum Infinity - * @step 0.01 - */ - faceIndexHeight: number; - /** - * Edge index colour if the edges are drawn - * @default #0000ff - */ - faceIndexColour: Base.Color; - /** - * Draw two-sided faces with different colors for front and back. This helps visualize face orientation. - * @default true - */ - drawTwoSided: boolean; - /** - * Hex colour string for back face colour (negative side of the face). Only used when drawTwoSided is true. - * @default #0000ff - */ - backFaceColour: Base.Color; - /** - * Back face opacity value between 0 and 1. Only used when drawTwoSided is true. - * @default 1 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - backFaceOpacity: number; - } - class DrawShapesDto { - /** - * Provide options without default values - */ - constructor( - shapes?: T[], - faceOpacity?: number, - edgeOpacity?: number, - edgeColour?: Base.Color, - faceMaterial?: Base.Material, - faceColour?: Base.Color, - edgeWidth?: number, - drawEdges?: boolean, - drawFaces?: boolean, - drawVertices?: boolean, - vertexColour?: Base.Color, - vertexSize?: number, - precision?: number, - drawEdgeIndexes?: boolean, - edgeIndexHeight?: number, - edgeIndexColour?: Base.Color, - drawFaceIndexes?: boolean, - faceIndexHeight?: number, - faceIndexColour?: Base.Color, - drawTwoSided?: boolean, - backFaceColour?: Base.Color, - backFaceOpacity?: number - ); - /** - * Brep OpenCascade geometry - * @default undefined - */ - shapes: T[]; - /** - * Face opacity value between 0 and 1 - * @default 1 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - faceOpacity: number; - /** - * Edge opacity value between 0 and 1 - * @default 1 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - edgeOpacity: number; - /** - * Hex colour string for the edges - * @default #ffffff - */ - edgeColour: Base.Color; - /** - * Face material - * @default undefined - * @optional true - */ - faceMaterial?: Base.Material; - /** - * Hex colour string for face colour - * @default #ff0000 - */ - faceColour: Base.Color; - /** - * Edge width - * @default 2 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - edgeWidth: number; - /** - * You can turn off drawing of edges via this property - * @default true - */ - drawEdges: boolean; - /** - * You can turn off drawing of faces via this property - * @default true - */ - drawFaces: boolean; - /** - * You can turn off drawing of vertexes via this property - * @default false - */ - drawVertices: boolean; - /** - * Color of the vertices that will be drawn - * @default #ff00ff - */ - vertexColour: string; - /** - * The size of a vertices that will be drawn - * @default 0.03 - * @minimum 0 - * @maximum Infinity - * @step 0.01 - */ - vertexSize: number; - /** - * Precision of the mesh that will be generated for the shape, lower number will mean more triangles - * @default 0.01 - * @minimum 0 - * @maximum Infinity - * @step 0.01 - */ - precision: number; - /** - * Draw index of edges in space - * @default false - */ - drawEdgeIndexes: boolean; - /** - * Indicates the edge index height if they are drawn - * @default 0.06 - * @minimum 0 - * @maximum Infinity - * @step 0.01 - */ - edgeIndexHeight: number; - /** - * Edge index colour if the edges are drawn - * @default #ff00ff - */ - edgeIndexColour: Base.Color; - /** - * Draw indexes of faces in space - * @default false - */ - drawFaceIndexes: boolean; - /** - * Indicates the edge index height if they are drawn - * @default 0.06 - * @minimum 0 - * @maximum Infinity - * @step 0.01 - */ - faceIndexHeight: number; - /** - * Edge index colour if the edges are drawn - * @default #0000ff - */ - faceIndexColour: Base.Color; - /** - * Draw two-sided faces with different colors for front and back. This helps visualize face orientation. - * @default true - */ - drawTwoSided: boolean; - /** - * Hex colour string for back face colour (negative side of the face). Only used when drawTwoSided is true. - * @default #0000ff - */ - backFaceColour: Base.Color; - /** - * Back face opacity value between 0 and 1. Only used when drawTwoSided is true. - * @default 1 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - backFaceOpacity: number; - } - class FaceSubdivisionDto { - /** - * Provide options without default values - */ - constructor( - shape?: T, - nrDivisionsU?: number, - nrDivisionsV?: number, - shiftHalfStepU?: boolean, - removeStartEdgeU?: boolean, - removeEndEdgeU?: boolean, - shiftHalfStepV?: boolean, - removeStartEdgeV?: boolean, - removeEndEdgeV?: boolean - ); - /** - * Brep OpenCascade geometry - * @default undefined - */ - shape: T; - /** - * Number of points that will be added on U direction - * @default 10 - * @minimum 1 - * @maximum Infinity - * @step 1 - */ - nrDivisionsU: number; - /** - * Number of points that will be added on V direction - * @default 10 - * @minimum 1 - * @maximum Infinity - * @step 1 - */ - nrDivisionsV: number; - /** - * Sometimes you want to shift your points half way the step distance, especially on periodic surfaces - * @default false - */ - shiftHalfStepU: boolean; - /** - * Removes start edge points on U - * @default false - */ - removeStartEdgeU: boolean; - /** - * Removes end edge points on U - * @default false - */ - removeEndEdgeU: boolean; - /** - * Sometimes you want to shift your points half way the step distance, especially on periodic surfaces - * @default false - */ - shiftHalfStepV: boolean; - /** - * Removes start edge points on V - * @default false - */ - removeStartEdgeV: boolean; - /** - * Removes end edge points on V - * @default false - */ - removeEndEdgeV: boolean; - } - class FaceSubdivisionToWiresDto { - /** - * Provide options without default values - */ - constructor( - shape?: T, - nrDivisions?: number, - isU?: boolean, - shiftHalfStep?: boolean, - removeStart?: boolean, - removeEnd?: boolean - ); - /** - * Openascade Face - * @default undefined - */ - shape: T; - /** - * Number of points that will be added on U direction - * @default 10 - * @minimum 1 - * @maximum Infinity - * @step 1 - */ - nrDivisions: number; - /** - * Linear subdivision direction true - U, false - V - * @default true - */ - isU: boolean; - /** - * Sometimes you want to shift your wires half way the step distance, especially on periodic surfaces - * @default false - */ - shiftHalfStep: boolean; - /** - * Removes start wire - * @default false - */ - removeStart: boolean; - /** - * Removes end wire - * @default false - */ - removeEnd: boolean; - } - class FaceSubdivideToRectangleWiresDto { - /** - * Provide options without default values - */ - constructor( - shape?: T, - nrRectanglesU?: number, - nrRectanglesV?: number, - scalePatternU?: number[], - scalePatternV?: number[], - filletPattern?: number[], - inclusionPattern?: boolean[], - offsetFromBorderU?: number, - offsetFromBorderV?: number - ); - /** - * Openascade Face - * @default undefined - */ - shape: T; - /** - * Number of rectangles on U direction - * @default 10 - * @minimum 1 - * @maximum Infinity - * @step 1 - */ - nrRectanglesU: number; - /** - * Number of rectangles on V direction - * @default 10 - * @minimum 1 - * @maximum Infinity - * @step 1 - */ - nrRectanglesV: number; - /** - * Rectangle scale pattern on u direction - numbers between 0 and 1, if 1 or undefined is used, no scaling is applied - * @default undefined - * @optional true - */ - scalePatternU: number[]; - /** - * Rectangle scale pattern on v direction - numbers between 0 and 1, if 1 or undefined is used, no scaling is applied - * @default undefined - * @optional true - */ - scalePatternV: number[]; - /** - * Rectangle fillet scale pattern - numbers between 0 and 1, if 0 is used, no fillet is applied, - * if 1 is used, the fillet will be exactly half of the length of the shorter side of the rectangle - * @default undefined - * @optional true - */ - filletPattern: number[]; - /** - * Rectangle inclusion pattern - true means that the rectangle will be included, - * false means that the rectangle will be removed from the face - * @default undefined - * @optional true - */ - inclusionPattern: boolean[]; - /** - * If offset on U is bigger then 0 we will use a smaller space for rectangles to be placed. This means that even rectangle of U param 1 will be offset from the face border - * That is often required to create a pattern that is not too close to the face border - * It should not be bigger then half of the total width of the face as that will create problems - * @default 0 - * @minimum 0 - * @maximum 0.5 - * @step 0.01 - */ - offsetFromBorderU: number; - /** - * If offset on V is bigger then 0 we will use a smaller space for rectangles to be placed. This means that even rectangle of V param 1 will be offset from the face border - * That is often required to create a pattern that is not too close to the face border - * It should not be bigger then half of the total width of the face as that will create problems - * @default 0 - * @minimum 0 - * @maximum 0.5 - * @step 0.01 - */ - offsetFromBorderV: number; - } - class FaceSubdivideToHexagonWiresDto { - /** - * Provide options without default values - */ - constructor( - shape?: T, - nrHexagonsU?: number, - nrHexagonsV?: number, - flatU?: boolean, - scalePatternU?: number[], - scalePatternV?: number[], - filletPattern?: number[], - inclusionPattern?: boolean[], - offsetFromBorderU?: number, - offsetFromBorderV?: number, - extendUUp?: boolean, - extendUBottom?: boolean, - extendVUp?: boolean, - extendVBottom?: boolean - ); - /** - * Openascade Face - * @default undefined - */ - shape?: T; - /** - * Number of hexagons on U direction - * @default 10 - * @minimum 1 - * @maximum Infinity - * @step 1 - */ - nrHexagonsU?: number; - /** - * Number of hexagons on V direction - * @default 10 - * @minimum 1 - * @maximum Infinity - * @step 1 - */ - nrHexagonsV?: number; - flatU: boolean; - /** - * Hexagon scale pattern on u direction - numbers between 0 and 1, if 1 or undefined is used, no scaling is applied - * @default undefined - * @optional true - */ - scalePatternU?: number[]; - /** - * Hexagon scale pattern on v direction - numbers between 0 and 1, if 1 or undefined is used, no scaling is applied - * @default undefined - * @optional true - */ - scalePatternV?: number[]; - /** - * Hexagon fillet scale pattern - numbers between 0 and 1, if 0 is used, no fillet is applied, - * if 1 is used, the fillet will be exactly half of the length of the shortest segment of the hexagon - * @default undefined - * @optional true - */ - filletPattern?: number[]; - /** - * Hexagon inclusion pattern - true means that the hexagon will be included, - * false means that the hexagon will be removed from the face - * @default undefined - * @optional true - */ - inclusionPattern?: boolean[]; - /** - * If offset on U is bigger then 0 we will use a smaller space for hexagons to be placed. This means that even hexagon of U param 1 will be offset from the face border - * That is often required to create a pattern that is not too close to the face border - * It should not be bigger then half of the total width of the face as that will create problems - * @default 0 - * @minimum 0 - * @maximum 0.5 - * @step 0.01 - */ - offsetFromBorderU?: number; - /** - * If offset on V is bigger then 0 we will use a smaller space for hexagons to be placed. This means that even hexagon of V param 1 will be offset from the face border - * That is often required to create a pattern that is not too close to the face border - * It should not be bigger then half of the total width of the face as that will create problems - * @default 0 - * @minimum 0 - * @maximum 0.5 - * @step 0.01 - */ - offsetFromBorderV?: number; - /** - * If true, we will extend the hexagons beyond the face u up border by their pointy tops - * @default false - */ - extendUUp?: boolean; - /** - * If true, we will extend the hexagons beyond the face u bottom border by their pointy tops - * @default false - */ - extendUBottom?: boolean; - /** - * If true, we will extend the hexagons beyond the face v upper border by their half width - * @default false - */ - extendVUp?: boolean; - /** - * If true, we will extend the hexagons beyond the face v bottom border by their half width - * @default false - */ - extendVBottom?: boolean; - } - class FaceSubdivideToHexagonHolesDto { - /** - * Provide options without default values - */ - constructor( - shape?: T, - nrHexagonsU?: number, - nrHexagonsV?: number, - flatU?: boolean, - holesToFaces?: boolean, - scalePatternU?: number[], - scalePatternV?: number[], - filletPattern?: number[], - inclusionPattern?: boolean[], - offsetFromBorderU?: number, - offsetFromBorderV?: number - ); - /** - * Openascade Face - * @default undefined - */ - shape?: T; - /** - * Number of hexagons on U direction - * @default 10 - * @minimum 1 - * @maximum Infinity - * @step 1 - */ - nrHexagonsU?: number; - /** - * Number of hexagons on V direction - * @default 10 - * @minimum 1 - * @maximum Infinity - * @step 1 - */ - nrHexagonsV?: number; - flatU: boolean; - /** - * If true, we will also create holes as faces - * @default false - */ - holesToFaces?: boolean; - /** - * Hexagon scale pattern on u direction - numbers between 0 and 1, if 1 or undefined is used, no scaling is applied - * @default undefined - * @optional true - */ - scalePatternU?: number[]; - /** - * Hexagon scale pattern on v direction - numbers between 0 and 1, if 1 or undefined is used, no scaling is applied - * @default undefined - * @optional true - */ - scalePatternV?: number[]; - /** - * Hexagon fillet scale pattern - numbers between 0 and 1, if 0 is used, no fillet is applied, - * if 1 is used, the fillet will be exactly half of the length of the shortest segment of the hexagon - * @default undefined - * @optional true - */ - filletPattern?: number[]; - /** - * Hexagon inclusion pattern - true means that the hexagon will be included, - * false means that the hexagon will be removed from the face - * @default undefined - * @optional true - */ - inclusionPattern?: boolean[]; - /** - * If offset on U is bigger then 0 we will use a smaller space for hexagons to be placed. This means that even hexagon of U param 1 will be offset from the face border - * That is often required to create a pattern that is not too close to the face border - * It should not be bigger then half of the total width of the face as that will create problems - * @default 0 - * @minimum 0 - * @maximum 0.5 - * @step 0.01 - */ - offsetFromBorderU?: number; - /** - * If offset on V is bigger then 0 we will use a smaller space for hexagons to be placed. This means that even hexagon of V param 1 will be offset from the face border - * That is often required to create a pattern that is not too close to the face border - * It should not be bigger then half of the total width of the face as that will create problems - * @default 0 - * @minimum 0 - * @maximum 0.5 - * @step 0.01 - */ - offsetFromBorderV?: number; - } - class FaceSubdivideToRectangleHolesDto { - /** - * Provide options without default values - */ - constructor( - shape?: T, - nrRectanglesU?: number, - nrRectanglesV?: number, - scalePatternU?: number[], - scalePatternV?: number[], - filletPattern?: number[], - inclusionPattern?: boolean[], - holesToFaces?: boolean, - offsetFromBorderU?: number, - offsetFromBorderV?: number - ); - /** - * Openascade Face - * @default undefined - */ - shape: T; - /** - * Number of rectangles on U direction - * @default 10 - * @minimum 1 - * @maximum Infinity - * @step 1 - */ - nrRectanglesU: number; - /** - * Number of rectangles on V direction - * @default 10 - * @minimum 1 - * @maximum Infinity - * @step 1 - */ - nrRectanglesV: number; - /** - * Rectangle scale pattern on u direction - numbers between 0 and 1, if 1 or undefined is used, no scaling is applied - * @default undefined - * @optional true - */ - scalePatternU: number[]; - /** - * Rectangle scale pattern on v direction - numbers between 0 and 1, if 1 or undefined is used, no scaling is applied - * @default undefined - * @optional true - */ - scalePatternV: number[]; - /** - * Rectangle fillet scale pattern - numbers between 0 and 1, if 0 is used, no fillet is applied, - * if 1 is used, the fillet will be exactly half of the length of the shorter side of the rectangle - * @default undefined - * @optional true - */ - filletPattern: number[]; - /** - * Rectangle inclusion pattern - true means that the rectangle will be included, - * false means that the rectangle will be removed from the face - * @default undefined - * @optional true - */ - inclusionPattern: boolean[]; - /** - * If true, we will also output the faces for all the rectangles. The first face in the result will be the original face with holes punched, while the rest will be the rectangles - * @default false - */ - holesToFaces: boolean; - /** - * If offset on U is bigger then 0 we will use a smaller space for rectangles to be placed. This means that even rectangle of U param 1 will be offset from the face border - * That is often required to create a pattern that is not too close to the face border - * It should not be bigger then half of the total width of the face as that will create problems - * @default 0 - * @minimum 0 - * @maximum 0.5 - * @step 0.01 - */ - offsetFromBorderU: number; - /** - * If offset on V is bigger then 0 we will use a smaller space for rectangles to be placed. This means that even rectangle of V param 1 will be offset from the face border - * That is often required to create a pattern that is not too close to the face border - * It should not be bigger then half of the total width of the face as that will create problems - * @default 0 - * @minimum 0 - * @maximum 0.5 - * @step 0.01 - */ - offsetFromBorderV: number; - } - class FaceSubdivisionControlledDto { - /** - * Provide options without default values - */ - constructor( - shape?: T, - nrDivisionsU?: number, - nrDivisionsV?: number, - shiftHalfStepNthU?: number, - shiftHalfStepUOffsetN?: number, - removeStartEdgeNthU?: number, - removeStartEdgeUOffsetN?: number, - removeEndEdgeNthU?: number, - removeEndEdgeUOffsetN?: number, - shiftHalfStepNthV?: number, - shiftHalfStepVOffsetN?: number, - removeStartEdgeNthV?: number, - removeStartEdgeVOffsetN?: number, - removeEndEdgeNthV?: number, - removeEndEdgeVOffsetN?: number - ); - /** - * Brep OpenCascade geometry - * @default undefined - */ - shape: T; - /** - * Number of subdivisions on U direction - * @default 10 - * @minimum 1 - * @maximum Infinity - * @step 1 - */ - nrDivisionsU: number; - /** - * Number of subdivisions on V direction - * @default 10 - * @minimum 1 - * @maximum Infinity - * @step 1 - */ - nrDivisionsV: number; - /** - * Shift half step every nth U row - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - shiftHalfStepNthU: number; - /** - * Offset for shift half step every nth U row - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - shiftHalfStepUOffsetN: number; - /** - * Removes start edge points on U - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - removeStartEdgeNthU: number; - /** - * Offset for remove start edge points on U - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - removeStartEdgeUOffsetN: number; - /** - * Removes end edge points on U - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - removeEndEdgeNthU: number; - /** - * Offset for remove end edge points on U - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - removeEndEdgeUOffsetN: number; - /** - * Shift half step every nth V row - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - shiftHalfStepNthV: number; - /** - * Offset for shift half step every nth V row - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - shiftHalfStepVOffsetN: number; - /** - * Removes start edge points on V - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - removeStartEdgeNthV: number; - /** - * Offset for remove start edge points on V - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - removeStartEdgeVOffsetN: number; - /** - * Removes end edge points on V - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - removeEndEdgeNthV: number; - /** - * Offset for remove end edge points on V - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - removeEndEdgeVOffsetN: number; - } - class FaceLinearSubdivisionDto { - /** - * Provide options without default values - */ - constructor( - shape?: T, - isU?: boolean, - param?: number, - nrPoints?: number, - shiftHalfStep?: boolean, - removeStartPoint?: boolean, - removeEndPoint?: boolean - ); - /** - * Brep OpenCascade geometry - * @default undefined - */ - shape: T; - /** - * Linear subdivision direction true - U, false - V - * @default true - */ - isU: boolean; - /** - * Param on direction 0 - 1 - * @default 0.5 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - param: number; - /** - * Number of subdivisions on opposite direction - * @default 10 - * @minimum 1 - * @maximum Infinity - * @step 1 - */ - nrPoints: number; - /** - * Sometimes you want to shift your points half way the step distance, especially on periodic surfaces - * @default false - */ - shiftHalfStep: boolean; - /** - * Removes first point - * @default false - */ - removeStartPoint: boolean; - /** - * Removes last point - * @default false - */ - removeEndPoint: boolean; - } - class WireAlongParamDto { - /** - * Provide options without default values - */ - constructor(shape?: T, isU?: boolean, param?: number); - /** - * Brep OpenCascade geometry - * @default undefined - */ - shape: T; - /** - * Linear subdivision direction true - U, false - V - * @default true - */ - isU: boolean; - /** - * Param on direction 0 - 1 - * @default 0.5 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - param: number; - } - class WiresAlongParamsDto { - /** - * Provide options without default values - */ - constructor(shape?: T, isU?: boolean, params?: number[]); - /** - * Brep OpenCascade geometry - * @default undefined - */ - shape: T; - /** - * Linear subdivision direction true - U, false - V - * @default true - */ - isU: boolean; - /** - * Params on direction 0 - 1 - * @default undefined - */ - params: number[]; - } - class DataOnUVDto { - /** - * Provide options without default values - */ - constructor(shape?: T, paramU?: number, paramV?: number); - /** - * Brep OpenCascade geometry - * @default undefined - */ - shape: T; - /** - * Param on U direction 0 to 1 - * @default 0.5 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - paramU: number; - /** - * Param on V direction 0 to 1 - * @default 0.5 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - paramV: number; - } - class DataOnUVsDto { - /** - * Provide options without default values - */ - constructor(shape?: T, paramsUV?: [number, number][]); - /** - * Brep OpenCascade geometry - * @default undefined - */ - shape: T; - /** - * Params uv - * @default [[0.5, 0.5]] - */ - paramsUV: [number, number][]; - } - class PolygonDto { - constructor(points?: Base.Point3[]); - /** - * Points points - * @default undefined - */ - points: Base.Point3[]; - } - class PolygonsDto { - constructor(polygons?: PolygonDto[], returnCompound?: boolean); - /** - * Polygons - * @default undefined - */ - polygons: PolygonDto[]; - /** - * Indicates whether the shapes should be returned as a compound - */ - returnCompound: boolean; - } - class PolylineDto { - constructor(points?: Base.Point3[]); - /** - * Points points - * @default undefined - */ - points: Base.Point3[]; - } - class PolylineBaseDto { - constructor(polyline?: Base.Polyline3); - /** - * Polyline - * @default undefined - */ - polyline: Base.Polyline3; - } - class PolylinesBaseDto { - constructor(polylines?: Base.Polyline3[]); - /** - * Polylines - * @default undefined - */ - polylines: Base.Polyline3[]; - } - class LineBaseDto { - constructor(line?: Base.Line3); - /** - * Line - * @default undefined - */ - line: Base.Line3; - } - class LinesBaseDto { - constructor(lines?: Base.Line3[]); - /** - * Lines - * @default undefined - */ - lines: Base.Line3[]; - } - class SegmentBaseDto { - constructor(segment?: Base.Segment3); - /** - * Segment - * @default undefined - */ - segment: Base.Segment3; - } - class SegmentsBaseDto { - constructor(segments?: Base.Segment3[]); - /** - * Segments - * @default undefined - */ - segments: Base.Segment3[]; - } - class TriangleBaseDto { - constructor(triangle?: Base.Triangle3); - /** - * Triangle - * @default undefined - */ - triangle: Base.Triangle3; - } - class MeshBaseDto { - constructor(mesh?: Base.Mesh3); - /** - * Mesh - * @default undefined - */ - mesh: Base.Mesh3; - } - class PolylinesDto { - constructor(polylines?: PolylineDto[], returnCompound?: boolean); - /** - * Polylines - * @default undefined - */ - polylines: PolylineDto[]; - /** - * Indicates whether the shapes should be returned as a compound - */ - returnCompound: boolean; - } - class SquareDto { - constructor( - size?: number, - center?: Base.Point3, - direction?: Base.Vector3 - ); - /** - * size of square - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - size: number; - /** - * Center of the square - * @default [0, 0, 0] - */ - center: Base.Point3; - /** - * Direction of the square - * @default [0, 1, 0] - */ - direction: Base.Vector3; - } - class RectangleDto { - constructor( - width?: number, - length?: number, - center?: Base.Point3, - direction?: Base.Vector3 - ); - /** - * width of the rectangle - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - width: number; - /** - * Height of the rectangle - * @default 2 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - length: number; - /** - * Center of the rectangle - * @default [0, 0, 0] - */ - center: Base.Point3; - /** - * Direction of the rectangle - * @default [0, 1, 0] - */ - direction: Base.Vector3; - } - class LPolygonDto { - constructor( - widthFirst?: number, - lengthFirst?: number, - widthSecond?: number, - lengthSecond?: number, - align?: directionEnum, - rotation?: number, - center?: Base.Point3, - direction?: Base.Vector3 - ); - /** - * Width of the first side of L polygon - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - widthFirst: number; - /** - * Length of the first side of L polygon - * @default 2 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - lengthFirst: number; - /** - * Width of the second side of L polygon - * @default 0.5 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - widthSecond: number; - /** - * Length of the second side of L polygon - * @default 2 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - lengthSecond: number; - /** - * Indicates if the L polygon should be aligned inside/outside or middle - * @default outside - */ - align: directionEnum; - /** - * Rotation of the L polygon - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 15 - */ - rotation: number; - /** - * Center of the L polygon - * @default [0, 0, 0] - */ - center: Base.Point3; - /** - * Direction of the L polygon - * @default [0, 1, 0] - */ - direction: Base.Vector3; - } - class IBeamProfileDto { - constructor( - width?: number, - height?: number, - webThickness?: number, - flangeThickness?: number, - alignment?: Base.basicAlignmentEnum, - rotation?: number, - center?: Base.Point3, - direction?: Base.Vector3 - ); - /** - * Width of the I-beam (flange width) - * @default 2 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - width: number; - /** - * Height of the I-beam - * @default 3 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - height: number; - /** - * Thickness of the web (vertical part) - * @default 0.2 - * @minimum 0 - * @maximum Infinity - * @step 0.01 - */ - webThickness: number; - /** - * Thickness of the flanges (horizontal parts) - * @default 0.3 - * @minimum 0 - * @maximum Infinity - * @step 0.01 - */ - flangeThickness: number; - /** - * Alignment of the profile origin - * @default midMid - */ - alignment: Base.basicAlignmentEnum; - /** - * Rotation of the I-beam profile in degrees - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 15 - */ - rotation: number; - /** - * Center of the I-beam profile - * @default [0, 0, 0] - */ - center: Base.Point3; - /** - * Direction of the I-beam profile - * @default [0, 1, 0] - */ - direction: Base.Vector3; - } - class HBeamProfileDto { - constructor( - width?: number, - height?: number, - webThickness?: number, - flangeThickness?: number, - alignment?: Base.basicAlignmentEnum, - rotation?: number, - center?: Base.Point3, - direction?: Base.Vector3 - ); - /** - * Width of the H-beam (flange width) - * @default 2 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - width: number; - /** - * Height of the H-beam - * @default 3 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - height: number; - /** - * Thickness of the web (vertical part) - * @default 0.2 - * @minimum 0 - * @maximum Infinity - * @step 0.01 - */ - webThickness: number; - /** - * Thickness of the flanges (horizontal parts) - * @default 0.3 - * @minimum 0 - * @maximum Infinity - * @step 0.01 - */ - flangeThickness: number; - /** - * Alignment of the profile origin - * @default midMid - */ - alignment: Base.basicAlignmentEnum; - /** - * Rotation of the H-beam profile in degrees - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 15 - */ - rotation: number; - /** - * Center of the H-beam profile - * @default [0, 0, 0] - */ - center: Base.Point3; - /** - * Direction of the H-beam profile - * @default [0, 1, 0] - */ - direction: Base.Vector3; - } - class TBeamProfileDto { - constructor( - width?: number, - height?: number, - webThickness?: number, - flangeThickness?: number, - alignment?: Base.basicAlignmentEnum, - rotation?: number, - center?: Base.Point3, - direction?: Base.Vector3 - ); - /** - * Width of the T-beam (flange width) - * @default 2 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - width: number; - /** - * Height of the T-beam - * @default 2 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - height: number; - /** - * Thickness of the web (vertical part) - * @default 0.2 - * @minimum 0 - * @maximum Infinity - * @step 0.01 - */ - webThickness: number; - /** - * Thickness of the flange (horizontal part) - * @default 0.3 - * @minimum 0 - * @maximum Infinity - * @step 0.01 - */ - flangeThickness: number; - /** - * Alignment of the profile origin - * @default midMid - */ - alignment: Base.basicAlignmentEnum; - /** - * Rotation of the T-beam profile in degrees - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 15 - */ - rotation: number; - /** - * Center of the T-beam profile - * @default [0, 0, 0] - */ - center: Base.Point3; - /** - * Direction of the T-beam profile - * @default [0, 1, 0] - */ - direction: Base.Vector3; - } - class UBeamProfileDto { - constructor( - width?: number, - height?: number, - webThickness?: number, - flangeThickness?: number, - flangeWidth?: number, - alignment?: Base.basicAlignmentEnum, - rotation?: number, - center?: Base.Point3, - direction?: Base.Vector3 - ); - /** - * Overall width of the U-beam - * @default 2 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - width: number; - /** - * Height of the U-beam - * @default 3 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - height: number; - /** - * Thickness of the web (back part) - * @default 0.2 - * @minimum 0 - * @maximum Infinity - * @step 0.01 - */ - webThickness: number; - /** - * Thickness of the flanges (side parts) - * @default 0.3 - * @minimum 0 - * @maximum Infinity - * @step 0.01 - */ - flangeThickness: number; - /** - * Width of the flanges (how far they extend inward) - * @default 0.5 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - flangeWidth: number; - /** - * Alignment of the profile origin - * @default midMid - */ - alignment: Base.basicAlignmentEnum; - /** - * Rotation of the U-beam profile in degrees - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 15 - */ - rotation: number; - /** - * Center of the U-beam profile - * @default [0, 0, 0] - */ - center: Base.Point3; - /** - * Direction of the U-beam profile - * @default [0, 1, 0] - */ - direction: Base.Vector3; - } - class ExtrudedSolidDto { - constructor( - extrusionLengthFront?: number, - extrusionLengthBack?: number, - center?: Base.Point3, - direction?: Base.Vector3 - ); - /** - * Extrusion length in the forward direction - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - extrusionLengthFront: number; - /** - * Extrusion length in the backward direction - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - extrusionLengthBack: number; - /** - * Center of the solid - * @default [0, 0, 0] - */ - center: Base.Point3; - /** - * Direction of extrusion - * @default [0, 1, 0] - */ - direction: Base.Vector3; - } - class IBeamProfileSolidDto extends IBeamProfileDto { - constructor( - width?: number, - height?: number, - webThickness?: number, - flangeThickness?: number, - alignment?: Base.basicAlignmentEnum, - rotation?: number, - center?: Base.Point3, - direction?: Base.Vector3, - extrusionLengthFront?: number, - extrusionLengthBack?: number - ); - /** - * Extrusion length in the forward direction - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - extrusionLengthFront: number; - /** - * Extrusion length in the backward direction - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - extrusionLengthBack: number; - } - class HBeamProfileSolidDto extends HBeamProfileDto { - constructor( - width?: number, - height?: number, - webThickness?: number, - flangeThickness?: number, - alignment?: Base.basicAlignmentEnum, - rotation?: number, - center?: Base.Point3, - direction?: Base.Vector3, - extrusionLengthFront?: number, - extrusionLengthBack?: number - ); - /** - * Extrusion length in the forward direction - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - extrusionLengthFront: number; - /** - * Extrusion length in the backward direction - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - extrusionLengthBack: number; - } - class TBeamProfileSolidDto extends TBeamProfileDto { - constructor( - width?: number, - height?: number, - webThickness?: number, - flangeThickness?: number, - alignment?: Base.basicAlignmentEnum, - rotation?: number, - center?: Base.Point3, - direction?: Base.Vector3, - extrusionLengthFront?: number, - extrusionLengthBack?: number - ); - /** - * Extrusion length in the forward direction - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - extrusionLengthFront: number; - /** - * Extrusion length in the backward direction - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - extrusionLengthBack: number; - } - class UBeamProfileSolidDto extends UBeamProfileDto { - constructor( - width?: number, - height?: number, - webThickness?: number, - flangeThickness?: number, - flangeWidth?: number, - alignment?: Base.basicAlignmentEnum, - rotation?: number, - center?: Base.Point3, - direction?: Base.Vector3, - extrusionLengthFront?: number, - extrusionLengthBack?: number - ); - /** - * Extrusion length in the forward direction - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - extrusionLengthFront: number; - /** - * Extrusion length in the backward direction - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - extrusionLengthBack: number; - } - class BoxDto { - constructor( - width?: number, - length?: number, - height?: number, - center?: Base.Point3, - originOnCenter?: boolean - ); - /** - * Width of the box - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - width: number; - /** - * Length of the box - * @default 2 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - length: number; - /** - * Height of the box - * @default 3 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - height: number; - /** - * Center of the box - * @default [0, 0, 0] - */ - center: Base.Point3; - /** - * Force origin to be on the center of the cube - * @default true - */ - originOnCenter?: boolean; - } - class CubeDto { - constructor( - size?: number, - center?: Base.Point3, - originOnCenter?: boolean - ); - /** - * Size of the cube - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - size: number; - /** - * Center of the box - * @default [0, 0, 0] - */ - center: Base.Point3; - /** - * Force origin to be on the center of the cube - * @default true - */ - originOnCenter?: boolean; - } - class BoxFromCornerDto { - constructor( - width?: number, - length?: number, - height?: number, - corner?: Base.Point3 - ); - /** - * Width of the box - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - width: number; - /** - * Length of the box - * @default 2 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - length: number; - /** - * Height of the box - * @default 3 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - height: number; - /** - * Corner of the box - * @default [0, 0, 0] - */ - corner: Base.Point3; - } - class SphereDto { - constructor(radius?: number, center?: Base.Point3); - /** - * Radius of the sphere - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - radius: number; - /** - * Center of the sphere - * @default [0, 0, 0] - */ - center: Base.Point3; - } - class ConeDto { - constructor( - radius1?: number, - radius2?: number, - height?: number, - angle?: number, - center?: Base.Point3, - direction?: Base.Vector3 - ); - /** - * First radius of the cone - * @default 2 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - radius1: number; - /** - * Second radius of the cone - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - radius2: number; - /** - * Height of the cone - * @default 2 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - height: number; - /** - * Angle of the cone - * @default 360 - * @minimum 0 - * @maximum 360 - * @step 1 - */ - angle: number; - /** - * Center of the cone - * @default [0, 0, 0] - */ - center: Base.Point3; - /** - * Direction of the cone - * @default [0, 1, 0] - */ - direction: Base.Point3; - } - class LineDto { - constructor(start?: Base.Point3, end?: Base.Point3); - /** - * Start of the line - * @default [0, 0, 0] - */ - start: Base.Point3; - /** - * End of the line - * @default [0, 1, 0] - */ - end: Base.Point3; - } - class LineWithExtensionsDto { - constructor( - start?: Base.Point3, - end?: Base.Point3, - extensionStart?: number, - extensionEnd?: number - ); - /** - * Start of the line - * @default [0, 0, 0] - */ - start: Base.Point3; - /** - * End of the line - * @default [0, 1, 0] - */ - end: Base.Point3; - /** - * Extension of the line on the start - * @default 0.1 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - extensionStart: number; - /** - * Extension of the line on the end - * @default 0.1 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - extensionEnd: number; - } - class LinesDto { - constructor(lines?: LineDto[], returnCompound?: boolean); - /** - * Lines - * @default undefined - */ - lines: LineDto[]; - /** - * Indicates whether the shapes should be returned as a compound - */ - returnCompound: boolean; - } - class ArcEdgeTwoPointsTangentDto { - constructor( - start?: Base.Point3, - tangentVec?: Base.Vector3, - end?: Base.Point3 - ); - /** - * Start of the arc - * @default [0, 0, 0] - */ - start: Base.Point3; - /** - * Tangent vector on first point of the edge - * @default [0, 1, 0] - */ - tangentVec: Base.Vector3; - /** - * End of the arc - * @default [0, 0, 1] - */ - end: Base.Point3; - } - class ArcEdgeCircleTwoPointsDto { - constructor( - circle?: T, - start?: Base.Point3, - end?: Base.Point3, - sense?: boolean - ); - /** - * Circular edge - * @default undefined - */ - circle: T; - /** - * Start of the arc on the circle - * @default [0, 0, 0] - */ - start: Base.Point3; - /** - * End of the arc on the circle - * @default [0, 0, 1] - */ - end: Base.Point3; - /** - * If true will sense the direction - * @default true - */ - sense: boolean; - } - class ArcEdgeCircleTwoAnglesDto { - constructor( - circle?: T, - alphaAngle1?: number, - alphaAngle2?: number, - sense?: boolean - ); - /** - * Circular edge - * @default undefined - */ - circle: T; - /** - * First angle - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 1 - */ - alphaAngle1: number; - /** - * End angle - * @default 90 - * @minimum -Infinity - * @maximum Infinity - * @step 1 - */ - alphaAngle2: number; - /** - * If true will sense the direction - * @default true - */ - sense: boolean; - } - class ArcEdgeCirclePointAngleDto { - constructor( - circle?: T, - alphaAngle?: number, - alphaAngle2?: number, - sense?: boolean - ); - /** - * Circular edge - * @default undefined - */ - circle: T; - /** - * Point on the circle from where to start the arc - * @default undefined - */ - point: Base.Point3; - /** - * Angle from point - * @default 90 - * @minimum -Infinity - * @maximum Infinity - * @step 1 - */ - alphaAngle: number; - /** - * If true will sense the direction - * @default true - */ - sense: boolean; - } - class ArcEdgeThreePointsDto { - constructor( - start?: Base.Point3, - middle?: Base.Point3, - end?: Base.Point3 - ); - /** - * Start of the arc - * @default [0, 0, 0] - */ - start: Base.Point3; - /** - * Middle of the arc - * @default [0, 1, 0] - */ - middle: Base.Point3; - /** - * End of the arc - * @default [0, 0, 1] - */ - end: Base.Point3; - } - class CylinderDto { - constructor( - radius?: number, - height?: number, - center?: Base.Point3, - direction?: Base.Vector3, - angle?: number, - originOnCenter?: boolean - ); - /** - * Radius of the cylinder - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - radius: number; - /** - * Height of the cylinder - * @default 2 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - height: number; - /** - * Center of the cylinder - * @default [0, 0, 0] - */ - center: Base.Point3; - /** - * Direction for the cylinder - * @default [0, 1, 0] - */ - direction?: Base.Vector3; - /** - * Angle of the cylinder pie - * @default 360 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - angle?: number; - /** - * Force origin to be on the center of cylinder - * @default false - */ - originOnCenter?: boolean; - } - class CylindersOnLinesDto { - constructor(radius?: number, lines?: Base.Line3[]); - /** - * Radius of the cylinder - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - radius: number; - /** - * Lines between which to span cylinders - * @default undefined - */ - lines: Base.Line3[]; - } - class FilletDto { - constructor( - shape?: T, - radius?: number, - radiusList?: number[], - indexes?: number[] - ); - /** - * Shape to apply the fillets - * @default undefined - */ - shape: T; - /** - * Radius of the fillets - * @default 0.1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - * @optional true - */ - radius?: number; - /** - * Radius list - * @default undefined - * @optional true - */ - radiusList?: number[]; - /** - * List of edge indexes to which apply the fillet, if left empty all edges will be rounded - * @default undefined - * @optional true - */ - indexes?: number[]; - } - class FilletShapesDto { - constructor( - shapes?: T[], - radius?: number, - radiusList?: number[], - indexes?: number[] - ); - /** - * Shapes to apply the fillets - * @default undefined - */ - shapes: T[]; - /** - * Radius of the fillets - * @default 0.1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - * @optional true - */ - radius?: number; - /** - * Radius list - * @default undefined - * @optional true - */ - radiusList?: number[]; - /** - * List of edge indexes to which apply the fillet, if left empty all edges will be rounded - * @default undefined - * @optional true - */ - indexes?: number[]; - } - class FilletEdgesListDto { - constructor(shape?: T, edges?: U[], radiusList?: number[]); - /** - * Shape to apply the fillet - * @default undefined - */ - shape: T; - /** - * Edges to use for the fillet - * @default undefined - */ - edges: U[]; - /** - * Radius list for the fillets. The length of this array must match the length of the edges array. Each index corresponds to fillet on the edge at the same index. - * @default undefined - */ - radiusList: number[]; - } - class FilletEdgesListOneRadiusDto { - constructor(shape?: T, edges?: U[], radius?: number); - /** - * Shape to apply the fillet - * @default undefined - */ - shape: T; - /** - * Edges to use for the fillet - * @default undefined - */ - edges: U[]; - /** - * Radius of the fillets - * @default 0.1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - * @optional true - */ - radius: number; - } - class FilletEdgeVariableRadiusDto { - constructor( - shape?: T, - edge?: U, - radiusList?: number[], - paramsU?: number[] - ); - /** - * Shape to apply the fillet - * @default undefined - */ - shape: T; - /** - * Edge to use for the fillet - * @default undefined - */ - edge: U; - /** - * Radius list for the fillets that has to match the paramsU list - * @default undefined - */ - radiusList: number[]; - /** - * List of parameters on the edge to which apply the fillet. Each param must be between 0 and 1. - * @default undefined - */ - paramsU: number[]; - } - class FilletEdgesVariableRadiusDto { - constructor( - shape?: T, - edges?: U[], - radiusLists?: number[][], - paramsULists?: number[][] - ); - /** - * Shape to apply the fillet - * @default undefined - */ - shape: T; - /** - * Edges to use for the fillet - * @default undefined - */ - edges: U[]; - /** - * Lists of radius lists for the fillets. Top level array length needs to match the nr of edges used and each second level array needs to match paramsU length array at the same index. - * @default undefined - */ - radiusLists: number[][]; - /** - * Lists of parameter lists on the edges to which apply the fillet. Each param must be between 0 and 1. Top level array length needs to match the nr of edges used and each second level array needs to match radius length array at the same index. - * @default undefined - */ - paramsULists: number[][]; - } - class FilletEdgesSameVariableRadiusDto { - constructor( - shape?: T, - edges?: U[], - radiusList?: number[], - paramsU?: number[] - ); - /** - * Shape to apply the fillet - * @default undefined - */ - shape: T; - /** - * Edges to use for the fillet - * @default undefined - */ - edges: U[]; - /** - * Radius list for the fillets that has to match the paramsU list - * @default undefined - */ - radiusList: number[]; - /** - * List of parameters on the edges to which apply the fillet. Each param must be between 0 and 1. - * @default undefined - */ - paramsU: number[]; - } - class Fillet3DWiresDto { - constructor( - shapes?: T[], - radius?: number, - direction?: Base.Vector3, - radiusList?: number[], - indexes?: number[] - ); - /** - * Shapes to apply the fillets on - * @default undefined - */ - shapes: T[]; - /** - * Radius of the fillets - * @default 0.1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - * @optional true - */ - radius?: number; - /** - * Radius list - * @default undefined - * @optional true - */ - radiusList?: number[]; - /** - * List of edge indexes to which apply the fillet, if left empty all edges will be rounded - * @default undefined - * @optional true - */ - indexes?: number[]; - /** - * Orientation direction for the fillet - * @default [0, 1, 0] - */ - direction: Base.Vector3; - } - class Fillet3DWireDto { - constructor( - shape?: T, - radius?: number, - direction?: Base.Vector3, - radiusList?: number[], - indexes?: number[] - ); - /** - * Shape to apply the fillets - * @default undefined - */ - shape: T; - /** - * Radius of the fillets - * @default 0.1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - * @optional true - */ - radius?: number; - /** - * Radius list - * @default undefined - * @optional true - */ - radiusList?: number[]; - /** - * List of edge indexes to which apply the fillet, if left empty all edges will be rounded - * @default undefined - * @optional true - */ - indexes?: number[]; - /** - * Orientation direction for the fillet - * @default [0, 1, 0] - */ - direction: Base.Vector3; - } - class ChamferDto { - constructor( - shape?: T, - distance?: number, - distanceList?: number[], - indexes?: number[] - ); - /** - * Shape to apply the chamfer - * @default undefined - */ - shape: T; - /** - * Distance for the chamfer - * @default 0.1 - * @minimum 0 - * @maximum Infinity - * @optional true - * @step 0.1 - */ - distance?: number; - /** - * Distance for the chamfer - * @default undefined - * @optional true - */ - distanceList?: number[]; - /** - * List of edge indexes to which apply the chamfer, if left empty all edges will be chamfered - * @default undefined - * @optional true - */ - indexes?: number[]; - } - class ChamferEdgesListDto { - constructor(shape?: T, edges?: U[], distanceList?: number[]); - /** - * Shape to apply the chamfer - * @default undefined - */ - shape: T; - /** - * Edges to apply the chamfer to - * @default undefined - */ - edges: U[]; - /** - * Distance for the chamfer - * @default undefined - */ - distanceList: number[]; - } - class ChamferEdgeDistAngleDto { - constructor( - shape?: T, - edge?: U, - face?: F, - distance?: number, - angle?: number - ); - /** - * Shape to apply the chamfer - * @default undefined - */ - shape: T; - /** - * Edge to apply the chamfer to - * @default undefined - */ - edge: U; - /** - * Face from which to apply the angle - * @default undefined - */ - face: F; - /** - * Distance for the chamfer - * @default 0.1 - * @minimum 0 - * @maximum Infinity - * @step 0.01 - */ - distance: number; - /** - * Angle for the chamfer - * @default 45 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - angle: number; - } - class ChamferEdgeTwoDistancesDto { - constructor( - shape?: T, - edge?: U, - face?: F, - distance1?: number, - distance2?: number - ); - /** - * Shape to apply the chamfer - * @default undefined - */ - shape: T; - /** - * Edge to apply the chamfer to - * @default undefined - */ - edge: U; - /** - * Face from which to apply the first distance - * @default undefined - */ - face: F; - /** - * First distance from the face for the chamfer - * @default 0.1 - * @minimum 0 - * @maximum Infinity - * @step 0.01 - */ - distance1: number; - /** - * Second distance for the chamfer - * @default 0.2 - * @minimum 0 - * @maximum Infinity - * @step 0.01 - */ - distance2: number; - } - class ChamferEdgesTwoDistancesListsDto { - constructor( - shape?: T, - edges?: U[], - faces?: F[], - distances1?: number[], - distances2?: number[] - ); - /** - * Shape to apply the chamfer - * @default undefined - */ - shape: T; - /** - * Edges to apply the chamfers to - * @default undefined - */ - edges: U[]; - /** - * Faces from which to apply the angle of the chamfers - * @default undefined - */ - faces: F[]; - /** - * Distance 1 list for the chamfers - * @default undefined - */ - distances1: number[]; - /** - * Distance 2 list for the chamfers - * @default undefined - */ - distances2: number[]; - } - class ChamferEdgesTwoDistancesDto { - constructor( - shape?: T, - edges?: U[], - faces?: F[], - distance1?: number, - distance2?: number - ); - /** - * Shape to apply the chamfer - * @default undefined - */ - shape: T; - /** - * Edges to apply the chamfers to - * @default undefined - */ - edges: U[]; - /** - * Faces from which to apply the angle of the chamfers - * @default undefined - */ - faces: F[]; - /** - * First distance from the face for the chamfer - * @default 0.1 - * @minimum 0 - * @maximum Infinity - * @step 0.01 - */ - distance1: number; - /** - * Second distance for the chamfer - * @default 0.2 - * @minimum 0 - * @maximum Infinity - * @step 0.01 - */ - distance2: number; - } - class ChamferEdgesDistsAnglesDto { - constructor( - shape?: T, - edges?: U[], - faces?: F[], - distances?: number[], - angles?: number[] - ); - /** - * Shape to apply the chamfer - * @default undefined - */ - shape: T; - /** - * Edges to apply the chamfers to - * @default undefined - */ - edges: U[]; - /** - * Faces from which to apply the angle of the chamfers - * @default undefined - */ - faces: F[]; - /** - * Distance list for the chamfers - * @default undefined - */ - distances: number[]; - /** - * Angles for the chamfers - * @default undefined - */ - angles: number[]; - } - class ChamferEdgesDistAngleDto { - constructor( - shape?: T, - edges?: U[], - faces?: F[], - distance?: number, - angle?: number - ); - /** - * Shape to apply the chamfer - * @default undefined - */ - shape: T; - /** - * Edges to apply the chamfers to - * @default undefined - */ - edges: U[]; - /** - * Faces from which to apply the angle of the chamfers - * @default undefined - */ - faces: F[]; - /** - * Distance from the face - * @default 0.1 - * @minimum 0 - * @maximum Infinity - * @step 0.01 - */ - distance: number; - /** - * Angle for the chamfers - * @default 45 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - angle: number; - } - class BSplineDto { - constructor(points?: Base.Point3[], closed?: boolean); - /** - * Points through which the BSpline will be created - * @default undefined - */ - points: Base.Point3[]; - /** - * Indicates wether BSpline will be cloed - * @default false - */ - closed: boolean; - } - class BSplinesDto { - constructor(bSplines?: BSplineDto[], returnCompound?: boolean); - /** - * BSpline definitions - * @default undefined - */ - bSplines: BSplineDto[]; - /** - * Indicates whether the shapes should be returned as a compound - */ - returnCompound: boolean; - } - class WireFromTwoCirclesTanDto { - constructor( - circle1?: T, - circle2?: T, - keepLines?: twoSidesStrictEnum, - circleRemainders?: fourSidesStrictEnum, - tolerance?: number - ); - /** - * The first circle to be encloed with tangential lines - * @default undefined - */ - circle1: T; - /** - * The second circle to be encloed with tangential lines - * @default undefined - */ - circle2: T; - /** - * Choose which side to keep for the wire. Outside gives non-intersecting solution. - * @default outside - */ - keepLines: twoSidesStrictEnum; - /** - * Choose which side to keep for the wire. Outside gives non-intersecting solution. - * @default outside - */ - circleRemainders: fourSidesStrictEnum; - /** - * tolerance - * @default 1e-7 - * @minimum 0 - * @maximum Infinity - * @step 0.00001 - */ - tolerance: number; - } - class FaceFromMultipleCircleTanWiresDto { - constructor( - circles?: T[], - combination?: combinationCirclesForFaceEnum, - unify?: boolean, - tolerance?: number - ); - /** - * The circles that will all be joined into a single face through tangential lines - * @default undefined - */ - circles: T[]; - /** - * Indicates how circles should be joined together. Users can choose to join all circles with each other. Alternatively it is possible to respect the order of circles and only join consecutive circles. It is also possible to respect order and close the shape with first circle in the list. - * @default allWithAll - */ - combination: combinationCirclesForFaceEnum; - /** - * Choose whether you want faces to be unifided into a single face or not. Sometimes if you want to get faster result you can set this to false, but in this case faces will be returned as compound. - * @default true - */ - unify: boolean; - /** - * tolerance - * @default 1e-7 - * @minimum 0 - * @maximum Infinity - * @step 0.00001 - */ - tolerance: number; - } - class FaceFromMultipleCircleTanWireCollectionsDto { - constructor( - listsOfCircles?: T[][], - combination?: combinationCirclesForFaceEnum, - unify?: boolean, - tolerance?: number - ); - /** - * The two dimensional circle array that can host multiple circle collections. - * @default undefined - */ - listsOfCircles: T[][]; - /** - * Indicates how circles should be joined together. Users can choose to join all circles with each other. Alternatively it is possible to respect the order of circles and only join consecutive circles. It is also possible to respect order and close the shape with first circle in the list. - * @default allWithAll - */ - combination: combinationCirclesForFaceEnum; - /** - * Choose whether you want faces to be unifided into a single face or not. Sometimes if you want to get faster result you can set this to false, but in this case faces will be returned as compound. - * @default true - */ - unify: boolean; - /** - * tolerance - * @default 1e-7 - * @minimum 0 - * @maximum Infinity - * @step 0.00001 - */ - tolerance: number; - } - class ZigZagBetweenTwoWiresDto { - constructor( - wire1?: T, - wire2?: T, - nrZigZags?: number, - inverse?: boolean, - divideByEqualDistance?: boolean, - zigZagsPerEdge?: boolean - ); - /** - * The first wire for zig zag - * @default undefined - */ - wire1: T; - /** - * The second wire for zig zag - * @default undefined - */ - wire2: T; - /** - * How many zig zags to create between the two wires on each edge. The number of edges should match. Edges will be joined by zigzags in order. One zig zag means two edges forming a corner. - * @default 20 - * @minimum 1 - * @maximum Infinity - * @step 1 - */ - nrZigZags: number; - /** - * Inverse the the zig zag to go from wire2 to wire1 - * @default false - */ - inverse: boolean; - /** - * If true, the zig zags will be spaced equally on each edge. By default we follow parametric subdivision of the edges, which is not always equal to distance based subdivisions. - * @default false - */ - divideByEqualDistance: boolean; - /** - * By default the number of zig zags is applied to each edge. If this is set to false, the number of zig zags will be applied to the whole wire. This could then skip some corners where edges meet. - * @default true - */ - zigZagsPerEdge: boolean; - } - class InterpolationDto { - constructor( - points?: Base.Point3[], - periodic?: boolean, - tolerance?: number - ); - /** - * Points through which the BSpline will be created - * @default undefined - */ - points: Base.Point3[]; - /** - * Indicates wether BSpline will be periodic - * @default false - */ - periodic: boolean; - /** - * tolerance - * @default 1e-7 - * @minimum 0 - * @maximum Infinity - * @step 0.00001 - */ - tolerance: number; - } - class InterpolateWiresDto { - constructor( - interpolations?: InterpolationDto[], - returnCompound?: boolean - ); - /** - * Interpolation definitions - * @default undefined - */ - interpolations: InterpolationDto[]; - /** - * Indicates whether the shapes should be returned as a compound - */ - returnCompound: boolean; - } - class BezierDto { - constructor(points?: Base.Point3[], closed?: boolean); - /** - * Points through which the Bezier curve will be created - * @default undefined - */ - points: Base.Point3[]; - /** - * Indicates wether Bezier will be cloed - * @default false - */ - closed: boolean; - } - class BezierWeightsDto { - constructor( - points?: Base.Point3[], - weights?: number[], - closed?: boolean - ); - /** - * Points through which the Bezier curve will be created - * @default undefined - */ - points: Base.Point3[]; - /** - * Weights for beziers that will be used, values should be between 0 and 1 - * @default undefined - */ - weights: number[]; - /** - * Indicates wether Bezier will be cloed - * @default false - */ - closed: boolean; - } - class BezierWiresDto { - constructor(bezierWires?: BezierDto[], returnCompound?: boolean); - /** - * Bezier wires - * @default undefined - */ - bezierWires: BezierDto[]; - /** - * Indicates whether the shapes should be returned as a compound - */ - returnCompound: boolean; - } - class DivideDto { - constructor( - shape?: T, - nrOfDivisions?: number, - removeStartPoint?: boolean, - removeEndPoint?: boolean - ); - /** - * Shape representing a wire - * @default undefined - */ - shape?: T; - /** - * The number of divisions that will be performed on the curve - * @default 10 - * @minimum 1 - * @maximum Infinity - * @step 1 - */ - nrOfDivisions?: number; - /** - * Indicates if algorithm should remove start point - * @default false - */ - removeStartPoint?: boolean; - /** - * Indicates if algorithm should remove end point - * @default false - */ - removeEndPoint?: boolean; - } - class ProjectWireDto { - constructor(wire?: T, shape?: U, direction?: Base.Vector3); - /** - * Wire to project - * @default undefined - */ - wire: T; - /** - * Shape to use for projection - * @default undefined - */ - shape: U; - /** - * Direction vector for projection - * @default [0, 1, 0] - */ - direction: Base.Vector3; - } - class ProjectPointsOnShapeDto { - constructor( - points?: Base.Point3[], - shape?: T, - direction?: Base.Vector3, - projectionType?: pointProjectionTypeEnum - ); - /** - * Points to project - * @default undefined - */ - points: Base.Point3[]; - /** - * Shape to use for projection - * @default undefined - */ - shape: T; - /** - * Direction vector for projection - this must take the length into account as well, because algorithm looks for intresections with the shape in this direction. It will not find solutions outside the given length of this vector. - * @default [0, 10, 0] - */ - direction: Base.Vector3; - /** - * Allows user to choose what solutions are being returned by this operation. - * @default all - */ - projectionType: pointProjectionTypeEnum; - } - class WiresToPointsDto { - constructor( - shape?: T, - angularDeflection?: number, - curvatureDeflection?: number, - minimumOfPoints?: number, - uTolerance?: number, - minimumLength?: number - ); - /** - * Shape to use for parsing edges - * @default undefined - */ - shape: T; - /** - * The angular deflection - * @default 0.1 - * @minimum 0 - * @maximum Infinity - * @step 0.01 - */ - angularDeflection: number; - /** - * The curvature deflection - * @default 0.1 - * @minimum 0 - * @maximum Infinity - * @step 0.001 - */ - curvatureDeflection: number; - /** - * Minimum of points - * @default 2 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - minimumOfPoints: number; - /** - * U tolerance - * @default 1.0e-9 - * @minimum 0 - * @maximum Infinity - * @step 1.0e-9 - */ - uTolerance: number; - /** - * Minimum length - * @default 1.0e-7 - * @minimum 0 - * @maximum Infinity - * @step 1.0e-7 - */ - minimumLength: number; - } - class EdgesToPointsDto { - constructor( - shape?: T, - angularDeflection?: number, - curvatureDeflection?: number, - minimumOfPoints?: number, - uTolerance?: number, - minimumLength?: number - ); - /** - * Shape to use for parsing edges - * @default undefined - */ - shape: T; - /** - * The angular deflection - * @default 0.1 - * @minimum 0 - * @maximum Infinity - * @step 0.01 - */ - angularDeflection: number; - /** - * The curvature deflection - * @default 0.1 - * @minimum 0 - * @maximum Infinity - * @step 0.001 - */ - curvatureDeflection: number; - /** - * Minimum of points - * @default 2 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - minimumOfPoints: number; - /** - * U tolerance - * @default 1.0e-9 - * @minimum 0 - * @maximum Infinity - * @step 1.0e-9 - */ - uTolerance: number; - /** - * Minimum length - * @default 1.0e-7 - * @minimum 0 - * @maximum Infinity - * @step 1.0e-7 - */ - minimumLength: number; - } - class ProjectWiresDto { - constructor(wires?: T[], shape?: U, direction?: Base.Vector3); - /** - * Wire to project - * @default undefined - */ - wires: T[]; - /** - * Shape to use for projection - * @default undefined - */ - shape: U; - /** - * Direction vector for projection - * @default [0, 1, 0] - */ - direction: Base.Vector3; - } - class DivideShapesDto { - constructor( - shapes: T[], - nrOfDivisions?: number, - removeStartPoint?: boolean, - removeEndPoint?: boolean - ); - /** - * Shapes - * @default undefined - */ - shapes: T[]; - /** - * The number of divisions that will be performed on the curve - * @default 10 - * @minimum 1 - * @maximum Infinity - * @step 1 - */ - nrOfDivisions: number; - /** - * Indicates if algorithm should remove start point - * @default false - */ - removeStartPoint: boolean; - /** - * Indicates if algorithm should remove end point - * @default false - */ - removeEndPoint: boolean; - } - class DataOnGeometryAtParamDto { - constructor(shape: T, param?: number); - /** - * Shape representing a geometry - * @default undefined - */ - shape: T; - /** - * 0 - 1 value - * @default 0.5 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - param: number; - } - class DataOnGeometryesAtParamDto { - constructor(shapes: T[], param?: number); - /** - * Shapes representing a geometry - * @default undefined - */ - shapes: T[]; - /** - * 0 - 1 value - * @default 0.5 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - param: number; - } - class PointInFaceDto { - constructor( - face: T, - edge: T, - tEdgeParam?: number, - distance2DParam?: number - ); - /** - * OCCT face to be used for calculation - * @default undefined - */ - face: T; - /** - * OCCT edge to be used for calculation - * @default undefined - */ - edge: T; - /** - * 0 - 1 value - * @default 0.5 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - tEdgeParam: number; - /** - * The point will be distanced on from the 2d curve. - * @default 0.5 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - distance2DParam: number; - } - class PointsOnWireAtEqualLengthDto { - constructor( - shape: T, - length?: number, - tryNext?: boolean, - includeFirst?: boolean, - includeLast?: boolean - ); - /** - * Shape representing a wire - * @default undefined - */ - shape: T; - /** - * length at which to evaluate the point - * @default 0.5 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - length: number; - /** - * Try next point if the point is not found - * @default false - */ - tryNext: boolean; - /** - * Include first point - * @default false - */ - includeFirst: boolean; - /** - * Include last point - * @default false - */ - includeLast: boolean; - } - class PointsOnWireAtPatternOfLengthsDto { - constructor( - shape: T, - lengths?: number[], - tryNext?: boolean, - includeFirst?: boolean, - includeLast?: boolean - ); - /** - * Shape representing a wire - * @default undefined - */ - shape: T; - /** - * length at which to evaluate the point - * @default undefined - */ - lengths: number[]; - /** - * Try next point if the point is not found - * @default false - */ - tryNext: boolean; - /** - * Include first point - * @default false - */ - includeFirst: boolean; - /** - * Include last point - * @default false - */ - includeLast: boolean; - } - class DataOnGeometryAtLengthDto { - constructor(shape: T, length?: number); - /** - * Shape - * @default undefined - */ - shape: T; - /** - * length at which to evaluate the point - * @default 0.5 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - length: number; - } - class DataOnGeometryesAtLengthDto { - constructor(shapes: T[], length?: number); - /** - * Shapes - * @default undefined - */ - shapes: T[]; - /** - * length at which to evaluate the point - * @default 0.5 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - length: number; - } - class DataOnGeometryAtLengthsDto { - constructor(shape: T, lengths?: number[]); - /** - * Shape representing a wire - * @default undefined - */ - shape: T; - /** - * lengths at which to evaluate the points - * @default undefined - */ - lengths: number[]; - } - class CircleDto { - constructor( - radius?: number, - center?: Base.Point3, - direction?: Base.Vector3 - ); - /** - * Radius of the circle - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - radius: number; - /** - * Center of the circle - * @default [0, 0, 0] - */ - center: Base.Point3; - /** - * Direction vector for circle - * @default [0, 1, 0] - */ - direction: Base.Vector3; - } - class HexagonsInGridDto { - constructor( - wdith?: number, - height?: number, - nrHexagonsInHeight?: number, - nrHexagonsInWidth?: number, - flatTop?: boolean, - extendTop?: boolean, - extendBottom?: boolean, - extendLeft?: boolean, - extendRight?: boolean, - scalePatternWidth?: number[], - scalePatternHeight?: number[], - filletPattern?: number[], - inclusionPattern?: boolean[] - ); - /** Total desired width for the grid area. The hexagon size will be derived from this and nrHexagonsU. - * @default 10 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - width?: number; - /** Total desired height for the grid area. Note: due to hexagon geometry, the actual grid height might differ slightly if maintaining regular hexagons based on width. - * @default 10 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - height?: number; - /** Number of hexagons desired in width. - * @default 10 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - nrHexagonsInWidth?: number; - /** Number of hexagons desired in height. - * @default 10 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - nrHexagonsInHeight?: number; - /** If true, the hexagons will be oriented with their flat sides facing up and down. - * @default false - */ - flatTop?: boolean; - /** If true, shift the entire grid up by half hex height. - * @default false - */ - extendTop?: boolean; - /** If true, shift the entire grid down by half hex height. - * @default false - */ - extendBottom?: boolean; - /** If true, shift the entire grid left by half hex width. - * @default false - */ - extendLeft?: boolean; - /** If true, shift the entire grid right by half hex width. - * @default false - */ - extendRight?: boolean; - /** - * Hex scale pattern on width direction - numbers between 0 and 1, if 1 or undefined is used, no scaling is applied - * @default undefined - * @optional true - */ - scalePatternWidth?: number[]; - /** - * Hex scale pattern on height direction - numbers between 0 and 1, if 1 or undefined is used, no scaling is applied - * @default undefined - * @optional true - */ - scalePatternHeight?: number[]; - /** - * Hex fillet scale pattern - numbers between 0 and 1, if 0 is used, no fillet is applied, - * if 1 is used, the fillet will be exactly half of the length of the shorter side of the hex - * @default undefined - * @optional true - */ - filletPattern?: number[]; - /** - * Inclusion pattern - true means that the hex will be included, - * false means that the hex will be removed - * @default undefined - * @optional true - */ - inclusionPattern?: boolean[]; - } - class LoftDto { - constructor(shapes?: T[], makeSolid?: boolean); - /** - * Wires through which the loft passes - * @default undefined - */ - shapes: T[]; - /** - * Tries to make a solid when lofting - * @default false - */ - makeSolid: boolean; - } - class LoftAdvancedDto { - constructor( - shapes?: T[], - makeSolid?: boolean, - closed?: boolean, - periodic?: boolean, - straight?: boolean, - nrPeriodicSections?: number, - useSmoothing?: boolean, - maxUDegree?: number, - tolerance?: number, - parType?: approxParametrizationTypeEnum, - startVertex?: Base.Point3, - endVertex?: Base.Point3 - ); - /** - * Wires through which the loft passes - * @default undefined - */ - shapes: T[]; - /** - * Tries to make a solid when lofting - * @default false - */ - makeSolid: boolean; - /** - * Will make a closed loft. - * @default false - */ - closed: boolean; - /** - * Will make a periodic loft. - * @default false - */ - periodic: boolean; - /** - * Indicates whether straight sections should be made out of the loft - * @default false - */ - straight: boolean; - /** - * This number only is used when closed non straight lofting is used - * @default 10 - * @minimum 1 - * @maximum Infinity - * @step 1 - */ - nrPeriodicSections: number; - /** - * Tell algorithm to use smoothing - * @default false - */ - useSmoothing: boolean; - /** - * Maximum u degree - * @default 3 - */ - maxUDegree: number; - /** - * Tolerance - * @default 1.0e-7 - * @minimum 0 - * @maximum Infinity - * @step 0.000001 - */ - tolerance: number; - /** - * Approximation parametrization type - * @default approxCentripetal - */ - parType: approxParametrizationTypeEnum; - /** - * Optional if loft should start with a vertex - * @default undefined - * @optional true - */ - startVertex?: Base.Point3; - /** - * Optional if loft should end with a vertex - * @default undefined - * @optional true - */ - endVertex?: Base.Point3; - } - class OffsetDto { - constructor(shape?: T, face?: U, distance?: number, tolerance?: number); - /** - * Shape to offset - * @default undefined - */ - shape: T; - /** - * Optionally provide face for the offset - * @default undefined - * @optional true - */ - face?: U; - /** - * Distance of offset - * @default 0.2 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - distance: number; - /** - * Offset tolerance - * @default 0.1 - * @minimum 0 - * @maximum Infinity - * @step 0.01 - */ - tolerance: number; - } - class OffsetAdvancedDto { - constructor( - shape?: T, - face?: U, - distance?: number, - tolerance?: number, - joinType?: joinTypeEnum, - removeIntEdges?: boolean - ); - /** - * Shape to offset - * @default undefined - */ - shape: T; - /** - * Optionally provide face for the offset - * @default undefined - * @optional true - */ - face?: U; - /** - * Distance of offset - * @default 0.2 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - distance: number; - /** - * Offset tolerance - * @default 0.1 - * @minimum 0 - * @maximum Infinity - * @step 0.01 - */ - tolerance: number; - /** - * Join defines how to fill the holes that may appear between parallels to the two adjacent faces. It may take values GeomAbs_Arc or GeomAbs_Intersection: - * if Join is equal to GeomAbs_Arc, then pipes are generated between two free edges of two adjacent parallels, and spheres are generated on "images" of vertices; it is the default value - * @default arc - */ - joinType: joinTypeEnum; - /** - * Removes internal edges - * @default false - */ - removeIntEdges: boolean; - } - class RevolveDto { - constructor( - shape?: T, - angle?: number, - direction?: Base.Vector3, - copy?: boolean - ); - /** - * Shape to revolve - * @default undefined - */ - shape: T; - /** - * Angle degrees - * @default 360 - * @minimum 0 - * @maximum 360 - * @step 1 - */ - angle: number; - /** - * Direction vector - * @default [0, 1, 0] - */ - direction: Base.Vector3; - /** - * Copy original shape - * @default false - */ - copy: boolean; - } - class ShapeShapesDto { - constructor(shape?: T, shapes?: U[]); - /** - * The wire path - * @default undefined - */ - shape: T; - /** - * Shapes along the path to be piped - * @default undefined - */ - shapes: U[]; - } - class WiresOnFaceDto { - constructor(wires?: T[], face?: U); - /** - * The wires - * @default undefined - */ - wires: T[]; - /** - * Face shape - * @default undefined - */ - face: U; - } - class PipeWiresCylindricalDto { - constructor( - shapes?: T[], - radius?: number, - makeSolid?: boolean, - trihedronEnum?: geomFillTrihedronEnum, - forceApproxC1?: boolean - ); - /** - * Wire paths to pipe - * @default undefined - */ - shapes: T[]; - /** - * Radius of the cylindrical pipe - * @default 0.1 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - radius: number; - /** - * Make solid result by closing start and end parts - * @default true - */ - makeSolid: boolean; - /** - * Goemetry Fill Trihedron Options - * @default isConstantNormal - */ - trihedronEnum: geomFillTrihedronEnum; - /** - * Attempt to approximate a C1-continuous surface if a swept surface proved to be C0 - * @default false - */ - forceApproxC1: boolean; - } - class PipeWireCylindricalDto { - constructor( - shape?: T, - radius?: number, - makeSolid?: boolean, - trihedronEnum?: geomFillTrihedronEnum, - forceApproxC1?: boolean - ); - /** - * Wire path to pipe - * @default undefined - */ - shape: T; - /** - * Radius of the cylindrical pipe - * @default 0.1 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - radius: number; - /** - * Make solid result by closing start and end parts - * @default true - */ - makeSolid: boolean; - /** - * Goemetry Fill Trihedron Options - * @default isConstantNormal - */ - trihedronEnum: geomFillTrihedronEnum; - /** - * Attempt to approximate a C1-continuous surface if a swept surface proved to be C0 - * @default false - */ - forceApproxC1: boolean; - } - class PipePolygonWireNGonDto { - constructor( - shapes?: T, - radius?: number, - nrCorners?: number, - makeSolid?: boolean, - trihedronEnum?: geomFillTrihedronEnum, - forceApproxC1?: boolean - ); - /** - * Wire path to pipe - * @default undefined - */ - shape: T; - /** - * Radius of the cylindrical pipe - * @default 0.1 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - radius: number; - /** - * Nr of ngon corners to be used - * @default 6 - * @minimum 3 - * @maximum Infinity - * @step 1 - */ - nrCorners: number; - /** - * Make solid result by closing start and end parts - * @default true - */ - makeSolid: boolean; - /** - * Goemetry Fill Trihedron Options - * @default isConstantNormal - */ - trihedronEnum: geomFillTrihedronEnum; - /** - * Attempt to approximate a C1-continuous surface if a swept surface proved to be C0 - * @default false - */ - forceApproxC1: boolean; - } - class ExtrudeDto { - constructor(shape?: T, direction?: Base.Vector3); - /** - * Face to extrude - * @default undefined - */ - shape: T; - /** - * Direction vector for extrusion - * @default [0, 1, 0] - */ - direction: Base.Vector3; - } - class ExtrudeShapesDto { - constructor(shapes?: T[], direction?: Base.Vector3); - /** - * Shapes to extrude - * @default undefined - */ - shapes: T[]; - /** - * Direction vector for extrusion - * @default [0, 1, 0] - */ - direction: Base.Vector3; - } - class SplitDto { - constructor(shape?: T, shapes?: T[]); - /** - * Shape to split - * @default undefined - */ - shape: T; - /** - * Shapes to split from main shape - * @default undefined - */ - shapes: T[]; - /** - * Local fuzzy tolerance used for splitting - * @default 1.0e-4 - * @minimum 0 - * @maximum Infinity - * @step 0.000001 - */ - localFuzzyTolerance: number; - /** - * Set to true if you want to split the shape non-destructively - * @default true - */ - nonDestructive: boolean; - } - class UnionDto { - constructor(shapes?: T[], keepEdges?: boolean); - /** - * Objects to be joined together - * @default undefined - */ - shapes: T[]; - /** - * Keeps edges - * @default false - */ - keepEdges: boolean; - } - class DifferenceDto { - constructor(shape?: T, shapes?: T[], keepEdges?: boolean); - /** - * Object to subtract from - * @default undefined - */ - shape: T; - /** - * Objects to subtract - * @default undefined - */ - shapes: T[]; - /** - * Keeps edges unaffected - * @default false - */ - keepEdges: boolean; - } - class IntersectionDto { - constructor(shapes?: T[], keepEdges?: boolean); - /** - * Shapes to intersect - * @default undefined - */ - shapes: T[]; - /** - * Keep the edges - * @default false - */ - keepEdges: boolean; - } - class ShapeDto { - constructor(shape?: T); - /** - * Shape on which action should be performed - * @default undefined - */ - shape: T; - } - class MeshMeshIntersectionTwoShapesDto { - constructor( - shape1?: T, - shape2?: T, - precision1?: number, - precision2?: number - ); - /** - * First shape to be used for intersection - * @default undefined - */ - shape1: T; - /** - * Precision of first shape to be used for meshing and computing intersection. - * Keep in mind that the lower this value is, the more triangles will be produced and thus the slower the computation. - * @default 0.01 - * @minimum 0 - * @maximum Infinity - * @step 0.01 - */ - precision1?: number; - /** - * Second shape to be used for intersection - * @default undefined - */ - shape2: T; - /** - * Precision of second shape to be used for meshing and computing intersection. - * Keep in mind that the lower this value is, the more triangles will be produced and thus the slower the computation. - * @default 0.01 - * @minimum 0 - * @maximum Infinity - * @step 0.01 - */ - precision2?: number; - } - class MeshMeshesIntersectionOfShapesDto { - constructor( - shape?: T, - shapes?: T[], - precision?: number, - precisionShapes?: number[] - ); - /** - * Shape to use for the base of computations - * @default undefined - */ - shape?: T; - /** - * Precision of first shape to be used for meshing and computing intersection. - * Keep in mind that the lower this value is, the more triangles will be produced and thus the slower the computation. - * @default 0.01 - * @minimum 0 - * @maximum Infinity - * @step 0.01 - */ - precision?: number; - /** - * Second shape to be used for intersection - * @default undefined - */ - shapes?: T[]; - /** - * Precision of shapes to be used, if undefined, a universal precision will be used of the first shape - * @default undefined - * @optional true - */ - precisionShapes?: number[]; - } - class CompareShapesDto { - constructor(shape?: T, otherShape?: T); - /** - * Shape to be compared - * @default undefined - */ - shape: T; - /** - * Shape to be compared against - * @default undefined - */ - otherShape: T; - } - class FixSmallEdgesInWireDto { - constructor(shape?: T, lockvtx?: boolean, precsmall?: number); - /** - * Shape on which action should be performed - * @default undefined - */ - shape: T; - /** - * Lock vertex. If true, the edge must be kept. - * @default false - */ - lockvtx: boolean; - /** - * Definition of the small distance edge - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 0.0000000001 - */ - precsmall: number; - } - class BasicShapeRepairDto { - constructor( - shape?: T, - precision?: number, - maxTolerance?: number, - minTolerance?: number - ); - /** - * Shape to repair - * @default undefined - */ - shape: T; - /** - * Basic precision - * @default 0.001 - * @minimum 0 - * @maximum Infinity - * @step 0.0000000001 - */ - precision: number; - /** - * maximum allowed tolerance. All problems will be detected for cases when a dimension of invalidity is larger than - * the basic precision or a tolerance of sub-shape on that problem is detected. The maximum tolerance value limits - * the increasing tolerance for fixing a problem such as fix of not connected and self-intersected wires. If a value - * larger than the maximum allowed tolerance is necessary for correcting a detected problem the problem can not be fixed. - * The maximal tolerance is not taking into account during computation of tolerance of edges - * @default 0.01 - * @minimum 0 - * @maximum Infinity - * @step 0.0000000001 - */ - maxTolerance: number; - /** - * minimal allowed tolerance. It defines the minimal allowed length of edges. - * Detected edges having length less than the specified minimal tolerance will be removed. - * @default 0.0001 - * @minimum 0 - * @maximum Infinity - * @step 0.0000000001 - */ - minTolerance: number; - } - class FixClosedDto { - constructor(shape?: T, precision?: number); - /** - * Shape on which action should be performed - * @default undefined - */ - shape: T; - /** - * Precision for closed wire - * @default -0.1 - * @minimum -Infinity - * @maximum Infinity - * @step 0.0000000001 - */ - precision: number; - } - class ShapesWithToleranceDto { - constructor(shapes?: T[], tolerance?: number); - /** - * The shapes - * @default undefined - */ - shapes: T[]; - /** - * Tolerance used for intersections - * @default 1.0e-7 - * @minimum 0 - * @maximum Infinity - * @step 0.000001 - */ - tolerance: number; - } - class ShapeWithToleranceDto { - constructor(shape?: T, tolerance?: number); - /** - * The shape - * @default undefined - */ - shape: T; - /** - * Tolerance used for intersections - * @default 1.0e-7 - * @minimum 0 - * @maximum Infinity - * @step 0.000001 - */ - tolerance: number; - } - class ShapeIndexDto { - constructor(shape?: T, index?: number); - /** - * Shape - * @default undefined - */ - shape: T; - /** - * Index of the entity - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - index: number; - } - class EdgeIndexDto { - constructor(shape?: T, index?: number); - /** - * Shape - * @default undefined - */ - shape: T; - /** - * Index of the entity - * @default 1 - * @minimum 1 - * @maximum Infinity - * @step 1 - */ - index: number; - } - class RotationExtrudeDto { - constructor( - shape?: T, - height?: number, - angle?: number, - makeSolid?: boolean - ); - /** - * Wire to extrude by rotating - * @default undefined - */ - shape: T; - /** - * Height of rotation - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - height: number; - /** - * Rotation in degrees - * @default 360 - * @minimum 0 - * @maximum 360 - * @step 1 - */ - angle: number; - /** - * Make solid of the result - * @default true - */ - makeSolid: boolean; - } - class ThickSolidByJoinDto { - constructor( - shape?: T, - shapes?: T[], - offset?: number, - tolerance?: number, - intersection?: boolean, - selfIntersection?: boolean, - joinType?: joinTypeEnum, - removeIntEdges?: boolean - ); - /** - * Shape to make thick - * @default undefined - */ - shape: T; - /** - * closing faces - * @default undefined - */ - shapes: T[]; - /** - * Offset to apply - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - offset: number; - /** - * Tolerance defines the tolerance criterion for coincidence in generated shapes - * @default 1.0e-3 - * @minimum 0 - * @maximum Infinity - * @step 0.000001 - */ - tolerance: number; - /** - * if Intersection is false (default value), the intersection is calculated with the parallels to the two adjacent shapes - * @default false - */ - intersection: boolean; - /** - * SelfInter tells the algorithm whether a computation to eliminate self-intersections needs to be applied to the resulting shape. However, as this functionality is not yet implemented, you should use the default value (false) - * @default false - */ - selfIntersection: boolean; - /** - * Join defines how to fill the holes that may appear between parallels to the two adjacent faces. It may take values GeomAbs_Arc or GeomAbs_Intersection: - * if Join is equal to GeomAbs_Arc, then pipes are generated between two free edges of two adjacent parallels, and spheres are generated on "images" of vertices; it is the default value - * @default arc - */ - joinType: joinTypeEnum; - /** - * if Join is equal to GeomAbs_Intersection, then the parallels to the two adjacent faces are enlarged and intersected, so that there are no free edges on parallels to faces. RemoveIntEdges flag defines whether to remove the INTERNAL edges from the result or not. Warnings Since the algorithm of MakeThickSolid is based on MakeOffsetShape algorithm, the warnings are the same as for MakeOffsetShape. - * @default false - */ - removeIntEdges: boolean; - } - class TransformDto { - constructor( - shape?: T, - translation?: Base.Vector3, - rotationAxis?: Base.Vector3, - rotationAngle?: number, - scaleFactor?: number - ); - /** - * Shape to transform - * @default undefined - */ - shape: T; - /** - * Translation to apply - * @default [0,0,0] - */ - translation: Base.Vector3; - /** - * Rotation to apply - * @default [0,1,0] - */ - rotationAxis: Base.Vector3; - /** - * Rotation degrees - * @default 0 - * @minimum 0 - * @maximum 360 - * @step 1 - */ - rotationAngle: number; - /** - * Scale factor to apply - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - scaleFactor: number; - } - class TransformShapesDto { - constructor( - shapes?: T[], - translation?: Base.Vector3[], - rotationAxes?: Base.Vector3[], - rotationDegrees?: number[], - scaleFactors?: number[] - ); - /** - * Shape to transform - * @default undefined - */ - shapes: T[]; - /** - * Translation to apply - * @default [[0,0,0]] - */ - translations: Base.Vector3[]; - /** - * Rotation to apply - * @default [[0,1,0]] - */ - rotationAxes: Base.Vector3[]; - /** - * Rotation degrees - * @default [0] - */ - rotationAngles: number[]; - /** - * Scale factor to apply - * @default [1] - */ - scaleFactors: number[]; - } - class TranslateDto { - constructor(shape?: T, translation?: Base.Vector3); - /** - * Shape for translation - * @default undefined - */ - shape: T; - /** - * Translation vector - * @default [0, 0, 0] - */ - translation: Base.Vector3; - } - class TranslateShapesDto { - constructor(shapes?: T[], translations?: Base.Vector3[]); - /** - * Shape for translation - * @default undefined - */ - shapes: T[]; - /** - * Translation vector - * @default [[0, 0, 0]] - */ - translations: Base.Vector3[]; - } - class AlignNormAndAxisDto { - constructor( - shape?: T, - fromOrigin?: Base.Point3, - fromNorm?: Base.Vector3, - fromAx?: Base.Vector3, - toOrigin?: Base.Point3, - toNorm?: Base.Vector3, - toAx?: Base.Vector3 - ); - /** - * Shape for translation - * @default undefined - */ - shape: T; - /** - * @default [0, 0, 0] - */ - fromOrigin: Base.Point3; - /** - * From direction 1 - * @default [0, 0, 1] - */ - fromNorm: Base.Vector3; - /** - * From direction 2 - * @default [0, 0, 1] - */ - fromAx: Base.Vector3; - /** - * To origin - * @default [0, 1, 0] - */ - toOrigin: Base.Point3; - /** - * To direction 1 - * @default [0, 1, 0] - */ - toNorm: Base.Vector3; - /** - * To direction 2 - * @default [0, 0, 1] - */ - toAx: Base.Vector3; - } - class AlignDto { - constructor( - shape?: T, - fromOrigin?: Base.Point3, - fromDirection?: Base.Vector3, - toOrigin?: Base.Point3, - toDirection?: Base.Vector3 - ); - /** - * Shape for translation - * @default undefined - */ - shape: T; - /** - * @default [0, 0, 0] - */ - fromOrigin: Base.Point3; - /** - * From direction - * @default [0, 0, 1] - */ - fromDirection: Base.Vector3; - /** - * To origin - * @default [0, 1, 0] - */ - toOrigin: Base.Point3; - /** - * To direction - * @default [0, 1, 0] - */ - toDirection: Base.Vector3; - } - class AlignShapesDto { - constructor( - shapes?: T[], - fromOrigins?: Base.Vector3[], - fromDirections?: Base.Vector3[], - toOrigins?: Base.Vector3[], - toDirections?: Base.Vector3[] - ); - /** - * Shape for translation - * @default undefined - */ - shapes: T[]; - /** - * @default [[0, 0, 0]] - */ - fromOrigins: Base.Point3[]; - /** - * From direction - * @default [[0, 0, 1]] - */ - fromDirections: Base.Vector3[]; - /** - * To origin - * @default [[0, 1, 0]] - */ - toOrigins: Base.Point3[]; - /** - * To direction - * @default [[0, 1, 0]] - */ - toDirections: Base.Vector3[]; - } - class MirrorDto { - constructor(shape?: T, origin?: Base.Point3, direction?: Base.Vector3); - /** - * Shape to mirror - * @default undefined - */ - shape: T; - /** - * Axis origin point - * @default [0, 0, 0] - */ - origin: Base.Point3; - /** - * Axis direction vector - * @default [0, 0, 1] - */ - direction: Base.Vector3; - } - class MirrorShapesDto { - constructor( - shapes?: T[], - origins?: Base.Point3[], - directions?: Base.Vector3[] - ); - /** - * Shape to mirror - * @default undefined - */ - shapes: T[]; - /** - * Axis origin point - * @default [[0, 0, 0]] - */ - origins: Base.Point3[]; - /** - * Axis direction vector - * @default [[0, 0, 1]] - */ - directions: Base.Vector3[]; - } - class MirrorAlongNormalDto { - constructor(shape?: T, origin?: Base.Point3, normal?: Base.Vector3); - /** - * Shape to mirror - * @default undefined - */ - shape: T; - /** - * Axis origin point - * @default [0, 0, 0] - */ - origin: Base.Point3; - /** - * First normal axis direction vector - * @default [0, 0, 1] - */ - normal: Base.Vector3; - } - class MirrorAlongNormalShapesDto { - constructor( - shapes?: T[], - origins?: Base.Point3[], - normals?: Base.Vector3[] - ); - /** - * Shape to mirror - * @default undefined - */ - shapes: T[]; - /** - * Axis origin point - * @default [[0, 0, 0]] - */ - origins: Base.Point3[]; - /** - * First normal axis direction vector - * @default [[0, 0, 1]] - */ - normals: Base.Vector3[]; - } - class AlignAndTranslateDto { - constructor(shape?: T, direction?: Base.Vector3, center?: Base.Vector3); - /** - * Shape to align and translate - * @default undefined - */ - shape: T; - /** - * Direction on which to align - * @default [0, 0, 1] - */ - direction: Base.Vector3; - /** - * Position to translate - */ - center: Base.Vector3; - } - class UnifySameDomainDto { - constructor( - shape?: T, - unifyEdges?: boolean, - unifyFaces?: boolean, - concatBSplines?: boolean - ); - /** - * Shape on which action should be performed - * @default undefined - */ - shape: T; - /** - * If true, unifies the edges - * @default true - */ - unifyEdges: boolean; - /** - * If true, unifies the edges - * @default true - */ - unifyFaces: boolean; - /** - * If true, unifies the edges - * @default true - */ - concatBSplines: boolean; - } - class FilterFacesPointsDto { - constructor( - shapes?: T[], - points?: Base.Point3[], - tolerance?: number, - useBndBox?: boolean, - gapTolerance?: number, - keepIn?: boolean, - keepOn?: boolean, - keepOut?: boolean, - keepUnknown?: boolean, - flatPointsArray?: boolean - ); - /** - * Face that will be used to filter points - * @default undefined - */ - shapes: T[]; - /** - * Points to filter - * @default undefined - */ - points: Base.Point3[]; - /** - * Tolerance used for filter - * @default 1.0e-4 - * @minimum 0 - * @maximum Infinity - * @step 0.000001 - */ - tolerance: number; - /** - * If true, the bounding box will be used to prefilter the points so that there are less points to check on actual face. - * Recommended to enable if face has more than 10 edges and geometry is mostly spline. - * This might be faster, but if it is known that points are withing bounding box, this may not be faster. - * @default false - */ - useBndBox: boolean; - /** - * Gap tolerance - * @default 0.1 - * @minimum 0 - * @maximum Infinity - * @step 0.01 - */ - gapTolerance: number; - /** - * Return points that are inside the face - * @default true - */ - keepIn: boolean; - /** - * Return points that are on the border of the face - * @default true - */ - keepOn: boolean; - /** - * Return points that are outside the borders of the face - * @default false - */ - keepOut: boolean; - /** - * Return points that are classified as unknown - * @default false - */ - keepUnknown: boolean; - /** - * Returns flat points array by default, otherwise returns points for each face in order provided - * @default true - */ - flatPointsArray: boolean; - } - class FilterFacePointsDto { - constructor( - shape?: T, - points?: Base.Point3[], - tolerance?: number, - useBndBox?: boolean, - gapTolerance?: number, - keepIn?: boolean, - keepOn?: boolean, - keepOut?: boolean, - keepUnknown?: boolean - ); - /** - * Face that will be used to filter points - * @default undefined - */ - shape: T; - /** - * Points to filter - * @default undefined - */ - points: Base.Point3[]; - /** - * Tolerance used for filter - * @default 1.0e-4 - * @minimum 0 - * @maximum Infinity - * @step 0.000001 - */ - tolerance: number; - /** - * If true, the bounding box will be used to prefilter the points so that there are less points to check on actual face. - * Recommended to enable if face has more than 10 edges and geometry is mostly spline. - * This might be faster, but if it is known that points are withing bounding box, this may not be faster. - * @default false - */ - useBndBox: boolean; - /** - * Gap tolerance - * @default 0.1 - * @minimum 0 - * @maximum Infinity - * @step 0.01 - */ - gapTolerance: number; - /** - * Return points that are inside the face - * @default true - */ - keepIn: boolean; - /** - * Return points that are on the border of the face - * @default true - */ - keepOn: boolean; - /** - * Return points that are outside the borders of the face - * @default false - */ - keepOut: boolean; - /** - * Return points that are classified as unknown - * @default false - */ - keepUnknown: boolean; - } - class FilterSolidPointsDto { - constructor( - shape?: T, - points?: Base.Point3[], - tolerance?: number, - keepIn?: boolean, - keepOn?: boolean, - keepOut?: boolean, - keepUnknown?: boolean - ); - /** - * Face that will be used to filter points - * @default undefined - */ - shape: T; - /** - * Points to filter - * @default undefined - */ - points: Base.Point3[]; - /** - * Tolerance used for filter - * @default 1.0e-4 - * @minimum 0 - * @maximum Infinity - * @step 0.000001 - */ - tolerance: number; - /** - * Return points that are inside the face - * @default true - */ - keepIn: boolean; - /** - * Return points that are on the border of the face - * @default true - */ - keepOn: boolean; - /** - * Return points that are outside the borders of the face - * @default false - */ - keepOut: boolean; - /** - * Return points that are classified as unknown - * @default false - */ - keepUnknown: boolean; - } - class AlignAndTranslateShapesDto { - constructor( - shapes?: T[], - directions?: Base.Vector3[], - centers?: Base.Vector3[] - ); - /** - * Shapes to align and translate - * @default undefined - */ - shapes: T[]; - /** - * Directions on which to align - * @default [0, 0, 1] - */ - directions: Base.Vector3[]; - /** - * Positions to translate - */ - centers: Base.Vector3[]; - } - class RotateDto { - constructor(shape?: T, axis?: Base.Vector3, angle?: number); - /** - * Shape to rotate - * @default undefined - */ - shape: T; - /** - * Axis on which to rotate - * @default [0, 0, 1] - */ - axis: Base.Vector3; - /** - * Rotation degrees - * @default 0 - * @minimum 0 - * @maximum 360 - * @step 1 - */ - angle: number; - } - class RotateAroundCenterDto { - constructor( - shape?: T, - angle?: number, - center?: Base.Point3, - axis?: Base.Vector3 - ); - /** - * Shape to rotate - * @default undefined - */ - shape: T; - /** - * Angle of rotation to apply - * @default 0 - */ - angle: number; - /** - * Center of the rotation - * @default [0, 0, 0] - */ - center: Base.Point3; - /** - * Axis around which to rotate - * @default [0, 0, 1] - */ - axis: Base.Vector3; - } - class RotateShapesDto { - constructor(shapes?: T[], axes?: Base.Vector3[], angles?: number[]); - /** - * Shape to rotate - * @default undefined - */ - shapes: T[]; - /** - * Axis on which to rotate - * @default [[0, 0, 1]] - */ - axes: Base.Vector3[]; - /** - * Rotation degrees - * @default [0] - */ - angles: number[]; - } - class RotateAroundCenterShapesDto { - constructor( - shapes?: T[], - angles?: number[], - centers?: Base.Point3[], - axes?: Base.Vector3[] - ); - /** - * Shape to scale - * @default undefined - */ - shapes: T[]; - /** - * Angles of rotation to apply - * @default [0] - */ - angles: number[]; - /** - * Centers around which to rotate - * @default [[0, 0, 0]] - */ - centers: Base.Point3[]; - /** - * Axes around which to rotate - * @default [[0, 0, 1]] - */ - axes: Base.Vector3[]; - } - class ScaleDto { - constructor(shape?: T, factor?: number); - /** - * Shape to scale - * @default undefined - */ - shape: T; - /** - * Scale factor to apply - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - factor: number; - } - class ScaleShapesDto { - constructor(shapes?: T[], factors?: number[]); - /** - * Shape to scale - * @default undefined - */ - shapes: T[]; - /** - * Scale factor to apply - * @default [1] - */ - factors: number[]; - } - class Scale3DDto { - constructor(shape?: T, scale?: Base.Vector3, center?: Base.Point3); - /** - * Shape to scale - * @default undefined - */ - shape: T; - /** - * Scale factor to apply - * @default [1, 1, 1] - */ - scale: Base.Vector3; - /** - * Scale from the center - * @default [0, 0, 0] - */ - center: Base.Point3; - } - class Scale3DShapesDto { - constructor( - shapes?: T[], - scales?: Base.Vector3[], - centers?: Base.Point3[] - ); - /** - * Shape to scale - * @default undefined - */ - shapes: T[]; - /** - * Scale factor to apply - * @default [[1, 1, 1]] - */ - scales: Base.Vector3[]; - /** - * Scale from the center - * @default [[0, 0, 0]] - */ - centers: Base.Point3[]; - } - class ShapeToMeshDto { - constructor(shape?: T, precision?: number, adjustYtoZ?: boolean); - /** - * Shape to save - * @default undefined - */ - shape: T; - /** - * Precision of the mesh - * @default 0.01 - * @minimum 0 - * @maximum Infinity - * @step 0.001 - */ - precision: number; - /** - * Adjust Y (up) coordinate system to Z (up) coordinate system - * @default false - */ - adjustYtoZ: boolean; - } - class ShapeFacesToPolygonPointsDto { - constructor( - shape?: T, - precision?: number, - adjustYtoZ?: boolean, - reversedPoints?: boolean - ); - /** - * Shape to save - * @default undefined - */ - shape: T; - /** - * Precision of the mesh - * @default 0.01 - * @minimum 0 - * @maximum Infinity - * @step 0.001 - */ - precision: number; - /** - * Adjust Y (up) coordinate system to Z (up) coordinate system - * @default false - */ - adjustYtoZ: boolean; - /** - * Reverse the order of the points describing the polygon because some CAD kernels use the opposite order - * @default false - */ - reversedPoints: boolean; - } - class ShapesToMeshesDto { - constructor(shapes?: T[], precision?: number, adjustYtoZ?: boolean); - /** - * Shapes to transform - * @default undefined - */ - shapes: T[]; - /** - * Precision of the mesh - * @default 0.01 - * @minimum 0 - * @maximum Infinity - * @step 0.001 - */ - precision: number; - /** - * Adjust Y (up) coordinate system to Z (up) coordinate system - * @default false - */ - adjustYtoZ: boolean; - } - class SaveStepDto { - constructor( - shape?: T, - fileName?: string, - adjustYtoZ?: boolean, - tryDownload?: boolean - ); - /** - * Shape to save - * @default undefined - */ - shape: T; - /** - * File name - * @default shape.step - */ - fileName: string; - /** - * Adjust Y (up) coordinate system to Z (up) coordinate system - * @default false - */ - adjustYtoZ: boolean; - /** - * Will assume that the shape is created in right handed coordinate system environment - * and will compensate by not mirroring the shape along z axis - * @default false - */ - fromRightHanded?: boolean; - /** - * Will attempt to download the file if that is possible, keep in mind that you might need to implement this yourself. In bitbybit this is handled by worker layers which only run in browsers. - * @default true - */ - tryDownload?: boolean; - } - class SaveStlDto { - constructor( - shape?: T, - fileName?: string, - precision?: number, - adjustYtoZ?: boolean, - tryDownload?: boolean, - binary?: boolean - ); - /** - * Shape to save - * @default undefined - */ - shape: T; - /** - * File name - * @default shape.stl - */ - fileName: string; - /** - * Precision of the mesh - lower means higher res - * @default 0.01 - */ - precision: number; - /** - * Adjust Y (up) coordinate system to Z (up) coordinate system - * @default false - */ - adjustYtoZ: boolean; - /** - * Will attempt to download the file if that is possible, keep in mind that you might need to implement this yourself. In bitbybit this is handled by worker layers which only run in browsers. - * @default true - */ - tryDownload?: boolean; - /** - * Generate binary STL file - * @default true - */ - binary?: boolean; - } - class ShapeToDxfPathsDto { - constructor( - shape?: T, - angularDeflection?: number, - curvatureDeflection?: number, - minimumOfPoints?: number, - uTolerance?: number, - minimumLength?: number - ); - /** - * Shape to convert to DXF paths - * @default undefined - */ - shape: T; - /** - * The angular deflection for curve tessellation - * @default 0.1 - * @minimum 0 - * @maximum Infinity - * @step 0.01 - */ - angularDeflection: number; - /** - * The curvature deflection for curve tessellation - * @default 0.1 - * @minimum 0 - * @maximum Infinity - * @step 0.001 - */ - curvatureDeflection: number; - /** - * Minimum of points for curve tessellation - * @default 2 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - minimumOfPoints: number; - /** - * U tolerance for curve tessellation - * @default 1.0e-9 - * @minimum 0 - * @maximum Infinity - * @step 1.0e-9 - */ - uTolerance: number; - /** - * Minimum length for curve tessellation - * @default 1.0e-7 - * @minimum 0 - * @maximum Infinity - * @step 1.0e-7 - */ - minimumLength: number; - } - class DxfPathsWithLayerDto { - constructor( - paths?: IO.DxfPathDto[], - layer?: string, - color?: Base.Color - ); - /** - * Array of DXF paths (output from shapeToDxfPaths) - * @default undefined - */ - paths: IO.DxfPathDto[]; - /** - * Layer name for these paths - * @default Default - */ - layer: string; - /** - * Color for these paths - * @default #000000 - */ - color: Base.Color; - } - class DxfPathsPartsListDto { - constructor( - pathsParts?: IO.DxfPathsPartDto[], - colorFormat?: dxfColorFormatEnum, - acadVersion?: dxfAcadVersionEnum, - tryDownload?: boolean - ); - /** - * Array of DXF paths parts (output from dxfPathsWithLayer) - * @default undefined - */ - pathsParts: IO.DxfPathsPartDto[]; - /** - * Color format to use in the DXF file - * @default aci - */ - colorFormat: dxfColorFormatEnum; - /** - * AutoCAD version format for DXF file - * @default AC1009 - */ - acadVersion: dxfAcadVersionEnum; - /** - * File name - * @default bitbybit-dev.dxf - */ - fileName?: string; - /** - * Will attempt to download the file if that is possible, keep in mind that you might need to implement this yourself. In bitbybit this is handled by worker layers which only run in browsers. - * @default true - */ - tryDownload?: boolean; - } - class SaveDxfDto { - constructor( - shape?: T, - fileName?: string, - tryDownload?: boolean, - angularDeflection?: number, - curvatureDeflection?: number, - minimumOfPoints?: number, - uTolerance?: number, - minimumLength?: number - ); - /** - * Shape to save - * @default undefined - */ - shape: T; - /** - * File name - * @default shape.dxf - */ - fileName: string; - /** - * Will attempt to download the file if that is possible, keep in mind that you might need to implement this yourself. In bitbybit this is handled by worker layers which only run in browsers. - * @default true - */ - tryDownload?: boolean; - /** - * The angular deflection - * @default 0.1 - * @minimum 0 - * @maximum Infinity - * @step 0.01 - */ - angularDeflection: number; - /** - * The curvature deflection - * @default 0.1 - * @minimum 0 - * @maximum Infinity - * @step 0.001 - */ - curvatureDeflection: number; - /** - * Minimum of points - * @default 2 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - minimumOfPoints: number; - /** - * U tolerance - * @default 1.0e-9 - * @minimum 0 - * @maximum Infinity - * @step 1.0e-9 - */ - uTolerance: number; - /** - * Minimum length - * @default 1.0e-7 - * @minimum 0 - * @maximum Infinity - * @step 1.0e-7 - */ - minimumLength: number; - } - class ImportStepIgesFromTextDto { - constructor( - text?: string, - fileType?: fileTypeEnum, - adjustZtoY?: boolean - ); - /** - * The text that represents step or iges contents - * @default undefined - */ - text: string; - /** - */ - fileType: fileTypeEnum; - /** - * Adjusts models that use Z coordinate as up to Y up system. - * @default true - */ - adjustZtoY: boolean; - } - class ImportStepIgesDto { - constructor(assetFile?: File, adjustZtoY?: boolean); - /** - * The name of the asset to store in the cache. - * @default undefined - */ - assetFile: File; - /** - * Adjusts models that use Z coordinate as up to Y up system. - * @default true - */ - adjustZtoY: boolean; - } - class LoadStepOrIgesDto { - constructor( - filetext?: string | ArrayBuffer, - fileName?: string, - adjustZtoY?: boolean - ); - /** - * File text - * @default undefined - */ - filetext: string | ArrayBuffer; - /** - * File name - * @default shape.igs - */ - fileName: string; - /** - * Adjusts models that use Z coordinate as up to Y up system. - * @default true - */ - adjustZtoY: boolean; - } - class CompoundShapesDto { - constructor(shapes?: T[]); - /** - * Shapes to add to compound - * @default undefined - */ - shapes: T[]; - } - class ThisckSolidSimpleDto { - constructor(shape?: T, offset?: number); - /** - * Shape to make thick - * @default undefined - */ - shape: T; - /** - * Offset distance - * @default 1 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - offset: number; - } - class Offset3DWireDto { - constructor(shape?: T, offset?: number, direction?: Base.Vector3); - /** - * Shape to make thick - * @default undefined - */ - shape: T; - /** - * Offset distance - * @default 1 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - offset: number; - /** - * Direction normal of the plane for the offset - * @default [0, 1, 0] - */ - direction: Base.Vector3; - } - class FaceFromWireDto { - constructor(shape?: T, planar?: boolean); - /** - * Wire shape to convert into a face - * @default undefined - */ - shape: T; - /** - * Should plane be planar - * @default false - */ - planar: boolean; - } - class FaceFromWireOnFaceDto { - constructor(wire?: T, face?: U, inside?: boolean); - /** - * Wire shape to convert into a face - * @default undefined - */ - wire: T; - /** - * Face to attach the wire to - * @default undefined - */ - face: U; - /** - * Indication if wire is inside the surface or outside - * @default true - */ - inside: boolean; - } - class FacesFromWiresOnFaceDto { - constructor(wires?: T[], face?: U, inside?: boolean); - /** - * Wire shape to convert into a face - * @default undefined - */ - wires: T[]; - /** - * Face to attach the wires to - * @default undefined - */ - face: U; - /** - * Indication if wire is inside the surface or outside - * @default true - */ - inside: boolean; - } - class FaceFromWiresDto { - constructor(shapes?: T[], planar?: boolean); - /** - * Wire shapes to convert into a faces - * @default undefined - */ - shapes: T[]; - /** - * Should plane be planar - * @default false - */ - planar: boolean; - } - class FacesFromWiresDto { - constructor(shapes?: T[], planar?: boolean); - /** - * Wire shapes to convert into a faces - * @default undefined - */ - shapes: T[]; - /** - * Should plane be planar - * @default false - */ - planar: boolean; - } - class FaceFromWiresOnFaceDto { - constructor(wires?: T[], face?: U, inside?: boolean); - /** - * Wire shapes to convert into a faces - * @default undefined - */ - wires: T[]; - /** - * Guide face to use as a base - * @default undefined - */ - face: U; - /** - * Indication if wire is inside the surface or outside - * @default true - */ - inside: boolean; - } - class SewDto { - constructor(shapes?: T[], tolerance?: number); - /** - * Faces to construct a shell from - * @default undefined - */ - shapes: T[]; - /** - * Tolerance of sewing - * @default 1.0e-7 - * @minimum 0 - * @maximum Infinity - * @step 0.00001 - */ - tolerance: number; - } - class FaceIsoCurveAtParamDto { - constructor(shape?: T, param?: number, dir?: "u" | "v"); - /** - * Face shape - * @default undefined - */ - shape: T; - /** - * Param at which to find isocurve - * @default 0.5 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - param: number; - /** - * Direction to find the isocurve - * @default u - */ - dir: "u" | "v"; - } - class DivideFaceToUVPointsDto { - constructor( - shape?: T, - nrOfPointsU?: number, - nrOfPointsV?: number, - flat?: boolean - ); - /** - * Face shape - * @default undefined - */ - shape: T; - /** - * Number of points on U direction - * @default 10 - * @minimum 1 - * @maximum Infinity - * @step 1 - */ - nrOfPointsU: number; - /** - * Number of points on V direction - * @default 10 - * @minimum 1 - * @maximum Infinity - * @step 1 - */ - nrOfPointsV: number; - /** - * Flatten the output - * @default false - */ - flat: boolean; - } - class Geom2dEllipseDto { - constructor( - center?: Base.Point2, - direction?: Base.Vector2, - radiusMinor?: number, - radiusMajor?: number, - sense?: boolean - ); - /** - * Center of the ellipse - * @default [0,0] - */ - center: Base.Point2; - /** - * Direction of the vector - * @default [1,0] - */ - direction: Base.Vector2; - /** - * Minor radius of an ellipse - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - radiusMinor: number; - /** - * Major radius of an ellipse - * @default 2 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - radiusMajor: number; - /** - * If true will sense the direction - * @default false - */ - sense: boolean; - } - class Geom2dCircleDto { - constructor( - center?: Base.Point2, - direction?: Base.Vector2, - radius?: number, - sense?: boolean - ); - /** - * Center of the circle - * @default [0,0] - */ - center: Base.Point2; - /** - * Direction of the vector - * @default [1,0] - */ - direction: Base.Vector2; - /** - * Radius of the circle - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - radius: number; - /** - * If true will sense the direction - * @default false - */ - sense: boolean; - } - class ChristmasTreeDto { - constructor( - height?: number, - innerDist?: number, - outerDist?: number, - nrSkirts?: number, - trunkHeight?: number, - trunkWidth?: number, - half?: boolean, - rotation?: number, - origin?: Base.Point3, - direction?: Base.Vector3 - ); - /** - * Height of the tree - * @default 6 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - height: number; - /** - * Inner distance of the branches on the bottom of the tree - * @default 1.5 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - innerDist: number; - /** - * Outer distance of the branches on the bottom of the tree - * @default 3 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - outerDist: number; - /** - * Number of skirts on the tree (triangle like shapes) - * @default 5 - * @minimum 1 - * @maximum Infinity - * @step 1 - */ - nrSkirts: number; - /** - * Trunk height - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - trunkHeight: number; - /** - * Trunk width only applies if trunk height is more than 0 - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - trunkWidth: number; - /** - * Indicates wether only a half of the tree should be created - * @default false - */ - half: boolean; - /** - * Rotation of the tree - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 15 - */ - rotation: number; - /** - * Origin of the tree - * @default [0, 0, 0] - */ - origin: Base.Point3; - /** - * Direction of the tree - * @default [0, 1, 0] - */ - direction: Base.Vector3; - } - class StarDto { - constructor( - outerRadius?: number, - innerRadius?: number, - numRays?: number, - center?: Base.Point3, - direction?: Base.Vector3, - offsetOuterEdges?: number, - half?: boolean - ); - /** - * Center of the circle - * @default [0,0,0] - */ - center: Base.Point3; - /** - * Direction - * @default [0, 1, 0] - */ - direction: Base.Vector3; - /** - * Direction of the vector - * @default 7 - * @minimum 3 - * @maximum Infinity - * @step 1 - */ - numRays: number; - /** - * Angle of the rays - * @default 2 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - outerRadius: number; - /** - * Angle of the rays - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - innerRadius: number; - /** - * Offsets outer edge cornerners along the direction vector - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - offsetOuterEdges?: number; - /** - * Construct half of the star - * @default false - */ - half: boolean; - } - class ParallelogramDto { - constructor( - center?: Base.Point3, - direction?: Base.Vector3, - aroundCenter?: boolean, - width?: number, - height?: number, - angle?: number - ); - /** - * Center of the circle - * @default [0, 0, 0] - */ - center: Base.Point3; - /** - * Direction - * @default [0, 1, 0] - */ - direction: Base.Vector3; - /** - * Indicates whether to draw the parallelogram around the center point or start from corner. - * @default true - */ - aroundCenter: boolean; - /** - * Width of bounding rectangle - * @default 2 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - width: number; - /** - * Height of bounding rectangle - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - height: number; - /** - * Sharp angle of the parallelogram - * @default 15 - * @minimum -Infinity - * @maximum Infinity - * @step 1 - */ - angle: number; - } - class Heart2DDto { - constructor( - center?: Base.Point3, - direction?: Base.Vector3, - rotation?: number, - sizeApprox?: number - ); - /** - * Center of the circle - * @default [0, 0, 0] - */ - center: Base.Point3; - /** - * Direction - * @default [0, 1, 0] - */ - direction: Base.Vector3; - /** - * Rotation of the hear - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 15 - */ - rotation: number; - /** - * Size of the bounding box within which the heart gets drawn - * @default 2 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - sizeApprox: number; - } - class NGonWireDto { - constructor( - center?: Base.Point3, - direction?: Base.Vector3, - nrCorners?: number, - radius?: number - ); - /** - * Center of the circle - * @default [0, 0, 0] - */ - center: Base.Point3; - /** - * Direction - * @default [0, 1, 0] - */ - direction: Base.Vector3; - /** - * How many corners to create. - * @default 6 - * @minimum 3 - * @maximum Infinity - * @step 1 - */ - nrCorners: number; - /** - * Radius of nGon - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - radius: number; - } - class EllipseDto { - constructor( - center?: Base.Point3, - direction?: Base.Vector3, - radiusMinor?: number, - radiusMajor?: number - ); - /** - * Center of the ellipse - * @default [0, 0, 0] - */ - center: Base.Point3; - /** - * Direction of the vector - * @default [0, 1, 0] - */ - direction: Base.Vector3; - /** - * Minor radius of an ellipse - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - radiusMinor: number; - /** - * Major radius of an ellipse - * @default 2 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - radiusMajor: number; - } - class TextWiresDto { - constructor( - text?: string, - xOffset?: number, - yOffset?: number, - height?: number, - lineSpacing?: number, - letterSpacing?: number, - align?: Base.horizontalAlignEnum, - extrudeOffset?: number, - origin?: Base.Point3, - rotation?: number, - direction?: Base.Vector3, - centerOnOrigin?: boolean - ); - /** - * The text - * @default Hello World - */ - text?: string; - /** - * The x offset - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - xOffset?: number; - /** - * The y offset - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - yOffset?: number; - /** - * The height of the text - * @default 1 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - height?: number; - /** - * The line spacing - * @default 2 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - lineSpacing?: number; - /** - * The letter spacing offset - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - letterSpacing?: number; - /** - * The extrude offset - * @default left - */ - align?: Base.horizontalAlignEnum; - /** - * The extrude offset - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - extrudeOffset?: number; - /** - * Indicates whether to center text on origin - * @default false - */ - centerOnOrigin: boolean; - } - class GeomCylindricalSurfaceDto { - constructor( - radius?: number, - center?: Base.Point3, - direction?: Base.Vector3 - ); - /** - * Radius of the cylindrical surface - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - radius: number; - /** - * Center of the cylindrical surface - * @default [0, 0, 0] - */ - center: Base.Point3; - /** - * Axis of direction for cylindrical surface - * @default [0, 1, 0] - */ - direction: Base.Vector3; - } - class Geom2dTrimmedCurveDto { - constructor( - shape?: T, - u1?: number, - u2?: number, - sense?: boolean, - adjustPeriodic?: boolean - ); - /** - * 2D Curve to trim - * @default undefined - */ - shape: T; - /** - * First param on the curve for trimming. U1 can be greater or lower than U2. The returned curve is oriented from U1 to U2. - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - u1: number; - /** - * Second parameter on the curve for trimming - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - u2: number; - /** - * If the basis curve C is periodic there is an ambiguity because two parts are available. - * In this case by default the trimmed curve has the same orientation as the basis curve (Sense = True). - * If Sense = False then the orientation of the trimmed curve is opposite to the orientation of the basis curve C. - * @default true - */ - sense: boolean; - /** - * If the curve is closed but not periodic it is not possible to keep the part of the curve including the - * junction point (except if the junction point is at the beginning or at the end of the trimmed curve) - * because you could lose the fundamental characteristics of the basis curve which are used for example - * to compute the derivatives of the trimmed curve. So for a closed curve the rules are the same as for a open curve. - * @default true - */ - adjustPeriodic: boolean; - } - class Geom2dSegmentDto { - constructor(start?: Base.Point2, end?: Base.Point2); - /** - * Start 2d point for segment - * @default [0, 0] - */ - start: Base.Point2; - /** - * End 2d point for segment - * @default [1, 0] - */ - end: Base.Point2; - } - class SliceDto { - constructor(shape?: T, step?: number, direction?: Base.Vector3); - /** - * The shape to slice - * @default undefined - */ - shape: T; - /** - * Step at which to divide the shape - * @default 0.1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - step: number; - /** - * Direction vector - * @default [0, 1, 0] - */ - direction: Base.Vector3; - } - class SliceInStepPatternDto { - constructor(shape?: T, steps?: number[], direction?: Base.Vector3); - /** - * The shape to slice - * @default undefined - */ - shape: T; - /** - * Steps that should be used for slicing. This array is going to be treated as a pattern - - * this menas that if the actual number of steps is lower than the number of steps in the pattern, the pattern will be repeated. - * @default [0.1, 0.2] - */ - steps: number[]; - /** - * Direction vector - * @default [0, 1, 0] - */ - direction: Base.Vector3; - } - class SimpleLinearLengthDimensionDto { - constructor( - start?: Base.Point3, - end?: Base.Point3, - direction?: Base.Vector3, - offsetFromPoints?: number, - crossingSize?: number, - labelSuffix?: string, - labelSize?: number, - labelOffset?: number, - labelRotation?: number, - arrowType?: dimensionEndTypeEnum, - arrowSize?: number, - arrowAngle?: number, - arrowsFlipped?: boolean, - labelFlipHorizontal?: boolean, - labelFlipVertical?: boolean, - labelOverwrite?: string, - removeTrailingZeros?: boolean - ); - /** - * The start point for dimension - * @default undefined - */ - start: Base.Point3; - /** - * The end point for dimension - * @default undefined - */ - end?: Base.Point3; - /** - * The dimension direction (must include length) - * @default undefined - */ - direction?: Base.Vector3; - /** - * The dimension label - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - offsetFromPoints?: number; - /** - * The dimension crossing size - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - crossingSize?: number; - /** - * The dimension label decimal places - * @default 2 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - decimalPlaces?: number; - /** - * The dimension label suffix - * @default (cm) - */ - labelSuffix?: string; - /** - * The dimension label size - * @default 0.1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - labelSize?: number; - /** - * The dimension label offset - * @default 0.3 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - labelOffset?: number; - /** - * The dimension label rotation - * @default 0 - * @minimum -360 - * @maximum 360 - * @step 1 - */ - labelRotation?: number; - /** - * End type for dimension - * @default none - */ - endType?: dimensionEndTypeEnum; - /** - * The size/length of dimension arrows - * @default 0.3 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - arrowSize?: number; - /** - * The total angle between arrow lines (max 90 degrees) - * @default 30 - * @minimum 0 - * @maximum 90 - * @step 1 - */ - arrowAngle?: number; - /** - * Flip arrows to point outward instead of inward - * @default false - */ - arrowsFlipped?: boolean; - /** - * Flip label horizontally - * @default false - */ - labelFlipHorizontal?: boolean; - /** - * Flip label vertically - * @default false - */ - labelFlipVertical?: boolean; - /** - * Override label text with custom expression (supports 'val' for computed value, e.g., '100*val', 'Length: val mm') - * @default 1*val - * @optional true - */ - labelOverwrite?: string; - /** - * Remove trailing zeros from decimal places - * @default false - */ - removeTrailingZeros?: boolean; - } - class SimpleAngularDimensionDto { - constructor( - direction1?: Base.Point3, - direction2?: Base.Point3, - center?: Base.Point3, - radius?: number, - offsetFromCenter?: number, - crossingSize?: number, - radians?: boolean, - labelSuffix?: string, - labelSize?: number, - labelOffset?: number, - endType?: dimensionEndTypeEnum, - arrowSize?: number, - arrowAngle?: number, - arrowsFlipped?: boolean, - labelRotation?: number, - labelFlipHorizontal?: boolean, - labelFlipVertical?: boolean, - labelOverwrite?: string, - removeTrailingZeros?: boolean - ); - /** - * The first direction for dimension - * @default [1, 0, 0] - */ - direction1: Base.Point3; - /** - * The second direction for dimension - * @default [0, 0, 1] - */ - direction2: Base.Point3; - /** - * The center point for dimension - * @default [0, 0, 0] - */ - center: Base.Point3; - /** - * The dimension radius - * @default 4 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - radius: number; - /** - * Offset from center - * @default 0.5 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - offsetFromCenter: number; - /** - * The dimension crossing size - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - extraSize: number; - /** - * The dimension label decimal places - * @default 2 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - decimalPlaces: number; - /** - * The dimension label suffix - * @default (deg) - */ - labelSuffix: string; - /** - * The dimension label size - * @default 0.1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - labelSize: number; - /** - * The dimension label offset - * @default 0.3 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - labelOffset: number; - /** - * If true the angle is in radians - * @default false - */ - radians: boolean; - /** - * End type for dimension - * @default none - */ - endType?: dimensionEndTypeEnum; - /** - * The size/length of dimension arrows - * @default 0.3 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - arrowSize?: number; - /** - * The total angle between arrow lines (max 90 degrees) - * @default 30 - * @minimum 0 - * @maximum 90 - * @step 1 - */ - arrowAngle?: number; - /** - * Flip arrows to point outward instead of inward - * @default false - */ - arrowsFlipped?: boolean; - /** - * Additional rotation angle for the label in degrees - * @default 0 - * @minimum -360 - * @maximum 360 - * @step 1 - */ - labelRotation?: number; - /** - * Flip label horizontally - * @default false - */ - labelFlipHorizontal?: boolean; - /** - * Flip label vertically - * @default false - */ - labelFlipVertical?: boolean; - /** - * Override label text with custom expression (supports 'val' for computed value, e.g., '100*val', 'Angle: val deg') - * @default 1*val - * @optional true - */ - labelOverwrite?: string; - /** - * Remove trailing zeros from decimal places - * @default false - */ - removeTrailingZeros?: boolean; - } - class PinWithLabelDto { - constructor( - startPoint?: Base.Point3, - endPoint?: Base.Point3, - direction?: Base.Vector3, - offsetFromStart?: number, - label?: string, - labelOffset?: number, - labelSize?: number, - endType?: dimensionEndTypeEnum, - arrowSize?: number, - arrowAngle?: number, - arrowsFlipped?: boolean, - labelRotation?: number, - labelFlipHorizontal?: boolean, - labelFlipVertical?: boolean - ); - /** - * The start point for dimension - * @default [0, 0, 0] - */ - startPoint: Base.Point3; - /** - * The end point for dimension - * @default [0, 5, 2] - */ - endPoint?: Base.Point3; - /** - * The dimension direction (must include length) - * @default [0, 0, 1] - */ - direction?: Base.Vector3; - /** - * Offset from the start point - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - offsetFromStart?: number; - /** - * The dimension label - * @default Pin - */ - label?: string; - /** - * The dimension label offset - * @default 0.3 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - labelOffset?: number; - /** - * The dimension label size - * @default 0.1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - labelSize?: number; - /** - * End type for dimension - * @default none - */ - endType?: dimensionEndTypeEnum; - /** - * The size/length of dimension arrows - * @default 0.3 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - arrowSize?: number; - /** - * The total angle between arrow lines (max 90 degrees) - * @default 30 - * @minimum 0 - * @maximum 90 - * @step 1 - */ - arrowAngle?: number; - /** - * Flip arrows to point outward instead of inward - * @default false - */ - arrowsFlipped?: boolean; - /** - * Additional rotation angle for the label in degrees - * @default 0 - * @minimum -360 - * @maximum 360 - * @step 1 - */ - labelRotation?: number; - /** - * Flip label horizontally - * @default false - */ - labelFlipHorizontal?: boolean; - /** - * Flip label vertically - * @default false - */ - labelFlipVertical?: boolean; - } - class StarSolidDto extends StarDto { - constructor( - outerRadius?: number, - innerRadius?: number, - numRays?: number, - center?: Base.Point3, - direction?: Base.Vector3, - offsetOuterEdges?: number, - half?: boolean, - extrusionLengthFront?: number, - extrusionLengthBack?: number - ); - /** - * Extrusion length in the forward direction - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - extrusionLengthFront: number; - /** - * Extrusion length in the backward direction - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - extrusionLengthBack: number; - } - class NGonSolidDto extends NGonWireDto { - constructor( - center?: Base.Point3, - direction?: Base.Vector3, - nrCorners?: number, - radius?: number, - extrusionLengthFront?: number, - extrusionLengthBack?: number - ); - /** - * Extrusion length in the forward direction - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - extrusionLengthFront: number; - /** - * Extrusion length in the backward direction - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - extrusionLengthBack: number; - } - class ParallelogramSolidDto extends ParallelogramDto { - constructor( - center?: Base.Point3, - direction?: Base.Vector3, - aroundCenter?: boolean, - width?: number, - height?: number, - angle?: number, - extrusionLengthFront?: number, - extrusionLengthBack?: number - ); - /** - * Extrusion length in the forward direction - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - extrusionLengthFront: number; - /** - * Extrusion length in the backward direction - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - extrusionLengthBack: number; - } - class HeartSolidDto extends Heart2DDto { - constructor( - center?: Base.Point3, - direction?: Base.Vector3, - rotation?: number, - sizeApprox?: number, - extrusionLengthFront?: number, - extrusionLengthBack?: number - ); - /** - * Extrusion length in the forward direction - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - extrusionLengthFront: number; - /** - * Extrusion length in the backward direction - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - extrusionLengthBack: number; - } - class ChristmasTreeSolidDto extends ChristmasTreeDto { - constructor( - height?: number, - innerDist?: number, - outerDist?: number, - nrSkirts?: number, - trunkHeight?: number, - trunkWidth?: number, - half?: boolean, - rotation?: number, - origin?: Base.Point3, - direction?: Base.Vector3, - extrusionLengthFront?: number, - extrusionLengthBack?: number - ); - /** - * Extrusion length in the forward direction - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - extrusionLengthFront: number; - /** - * Extrusion length in the backward direction - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - extrusionLengthBack: number; - } - class LPolygonSolidDto extends LPolygonDto { - constructor( - widthFirst?: number, - lengthFirst?: number, - widthSecond?: number, - lengthSecond?: number, - align?: directionEnum, - rotation?: number, - center?: Base.Point3, - direction?: Base.Vector3, - extrusionLengthFront?: number, - extrusionLengthBack?: number - ); - /** - * Extrusion length in the forward direction - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - extrusionLengthFront: number; - /** - * Extrusion length in the backward direction - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - extrusionLengthBack: number; - } - } - declare namespace BabylonCamera { - class ArcRotateCameraDto { - constructor( - radius?: number, - alpha?: number, - beta?: number, - lowerRadiusLimit?: number, - upperRadiusLimit?: number, - lowerAlphaLimit?: number, - upperAlphaLimit?: number, - lowerBetaLimit?: number, - upperBetaLimit?: number, - angularSensibilityX?: number, - angularSensibilityY?: number, - panningSensibility?: number, - wheelPrecision?: number, - maxZ?: number - ); - /** - * Defines the camera distance from its target. This radius will be used to rotate the camera around the target as default. - * @default 20 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - radius: number; - /** - * Target of the arc rotate camera. Camera will look at and rotate around this point by default. - * @default [0, 0, 0] - */ - target: Base.Point3; - /** - * Defines the camera rotation along the longitudinal (horizontal) axis in degrees - * @default 45 - * @minimum -360 - * @maximum 360 - * @step 1 - */ - alpha: number; - /** - * Defines the camera rotation along the latitudinal (vertical) axis in degrees. This is counted from top down, where 0 is looking from top straight down. - * @default 70 - * @minimum -360 - * @maximum 360 - * @step 1 - */ - beta: number; - /** - * Lower radius limit - how close can the camera be to the target - * @default undefined - * @minimum -Infinity - * @maximum Infinity - * @step 1 - * @optional true - */ - lowerRadiusLimit: any; - /** - * Upper radius limit - how far can the camera be from the target - * @default undefined - * @minimum -Infinity - * @maximum Infinity - * @step 1 - * @optional true - */ - upperRadiusLimit: any; - /** - * Lower alpha limit - camera rotation along the longitudinal (horizontal) axis in degrees. - * @default undefined - * @minimum -360 - * @maximum 360 - * @step 1 - * @optional true - */ - lowerAlphaLimit: any; - /** - * Upper alpha limit - camera rotation along the longitudinal (horizontal) axis in degrees. - * @default undefined - * @minimum -360 - * @maximum 360 - * @step 1 - * @optional true - */ - upperAlphaLimit: any; - /** - * Lower beta limit - camera rotation along the latitudinal (vertical) axis in degrees. This is counted from the top down, where 0 is looking from top straight down. - * @default 1 - * @minimum -360 - * @maximum 360 - * @step 1 - */ - lowerBetaLimit: number; - /** - * Upper beta limit - camera rotation along the longitudinal (vertical) axis in degrees. This is counted from the top down, where 180 is looking from bottom straight up. - * @default 179 - * @minimum -360 - * @maximum 360 - * @step 1 - */ - upperBetaLimit: number; - /** - * Angular sensibility along x (horizontal) axis of the camera - * @default 1000 - * @minimum 0 - * @maximum Infinity - * @step 10 - */ - angularSensibilityX: number; - /** - * Angular sensibility along y (vertical) axis of the camera - * @default 1000 - * @minimum 0 - * @maximum Infinity - * @step 10 - */ - angularSensibilityY: number; - /** - * Panning sensibility. The lower this number gets the faster camera will move when panning. - * @default 1000 - * @minimum 0 - * @maximum Infinity - * @step 100 - */ - panningSensibility: number; - /** - * Wheel precision. The lower this number gets the faster camera will move when zooming. - * @default 3 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - wheelPrecision: number; - /** - * Maximum distance the camera can see. Objects that are further away from the camera than this value will not be rendered. - * @default 1000 - * @minimum 0 - * @maximum Infinity - * @step 10 - */ - maxZ: number; - } - class FreeCameraDto { - constructor(position?: Base.Point3, target?: Base.Point3); - /** - * Position of the free camera - * @default [20, 20, 20] - */ - position: Base.Point3; - /** - * Target of the free camera - * @default [0, 0, 0] - */ - target: Base.Point3; - } - class TargetCameraDto { - constructor(position?: Base.Point3, target?: Base.Point3); - /** - * Position of the free camera - * @default [20, 20, 20] - */ - position: Base.Point3; - /** - * Target of the free camera - * @default [0, 0, 0] - */ - target: Base.Point3; - } - class PositionDto { - constructor(camera?: BABYLON.TargetCamera, position?: Base.Point3); - /** - * Target camera - */ - camera: BABYLON.TargetCamera; - /** - * Position of the free camera - * @default [20, 20, 20] - */ - position: Base.Point3; - } - class SpeedDto { - constructor(camera?: BABYLON.TargetCamera, speed?: number); - /** - * Target camera - */ - camera: BABYLON.TargetCamera; - /** - * speed of the camera - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - speed: number; - } - class TargetDto { - constructor(camera?: BABYLON.TargetCamera, target?: Base.Point3); - /** - * Target camera - */ - camera: BABYLON.TargetCamera; - /** - * target of the camera - * @default [0, 0, 0] - */ - target: Base.Point3; - } - class MinZDto { - constructor(camera?: BABYLON.Camera, minZ?: number); - /** - * Free camera - */ - camera: BABYLON.Camera; - /** - * minZ of the camera - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 0.01 - */ - minZ: number; - } - class MaxZDto { - constructor(camera?: BABYLON.Camera, maxZ?: number); - /** - * Free camera - */ - camera: BABYLON.Camera; - /** - * maxZ of the camera - * @default 1000 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - maxZ: number; - } - class OrthographicDto { - constructor( - camera?: BABYLON.Camera, - orthoLeft?: number, - orthoRight?: number, - orthoTop?: number, - orthoBottom?: number - ); - /** - * Camera to adjust - */ - camera: BABYLON.Camera; - /** - * Left side limit of the orthographic camera - * @default -1 - * @minimum -Infinity - * @maximum Infinity - * @step 1 - */ - orthoLeft: number; - /** - * Right side limit of the orthographic camera - * @default 1 - * @minimum -Infinity - * @maximum Infinity - * @step 1 - */ - orthoRight: number; - /** - * Bottom side limit of the orthographic camera - * @default -1 - * @minimum -Infinity - * @maximum Infinity - * @step 1 - */ - orthoBottom: number; - /** - * Top side limit of the orthographic camera - * @default 1 - * @minimum -Infinity - * @maximum Infinity - * @step 1 - */ - orthoTop: number; - } - class CameraDto { - constructor(camera?: BABYLON.Camera); - /** - * Camera - */ - camera: BABYLON.Camera; - } - } - declare namespace BabylonGaussianSplatting { - class CreateGaussianSplattingMeshDto { - constructor(url?: string); - /** - * Babylon Mesh that needs to be updated - * @default undefined - */ - url: string; - } - class GaussianSplattingMeshDto { - constructor(babylonMesh?: BABYLON.GaussianSplattingMesh); - /** - * Gaussian Splatting Mesh that needs to be updated - */ - babylonMesh: BABYLON.GaussianSplattingMesh; - } - } - declare namespace BabylonGizmo { - enum positionGizmoObservableSelectorEnum { - /** Fires an event when any of it's sub gizmos are dragged */ - onDragStartObservable = "onDragStartObservable", - /** Fires an event when any of it's sub gizmos are being dragged */ - onDragObservable = "onDragObservable", - /** Fires an event when any of it's sub gizmos are released from dragging */ - onDragEndObservable = "onDragEndObservable", - } - enum rotationGizmoObservableSelectorEnum { - /** Fires an event when any of it's sub gizmos are dragged */ - onDragStartObservable = "onDragStartObservable", - /** Fires an event when any of it's sub gizmos are being dragged */ - onDragObservable = "onDragObservable", - /** Fires an event when any of it's sub gizmos are released from dragging */ - onDragEndObservable = "onDragEndObservable", - } - enum scaleGizmoObservableSelectorEnum { - /** Fires an event when any of it's sub gizmos are dragged */ - onDragStartObservable = "onDragStartObservable", - /** Fires an event when any of it's sub gizmos are being dragged */ - onDragObservable = "onDragObservable", - /** Fires an event when any of it's sub gizmos are released from dragging */ - onDragEndObservable = "onDragEndObservable", - } - enum boundingBoxGizmoObservableSelectorEnum { - /** - * Fired when a rotation anchor or scale box is dragged - */ - onDragStartObservable = "onDragStartObservable", - /** - * Fired when a scale box is dragged - */ - onScaleBoxDragObservable = "onScaleBoxDragObservable", - /** - * Fired when a scale box drag is ended - */ - onScaleBoxDragEndObservable = "onScaleBoxDragEndObservable", - /** - * Fired when a rotation anchor is dragged - */ - onRotationSphereDragObservable = "onRotationSphereDragObservable", - /** - * Fired when a rotation anchor drag is ended - */ - onRotationSphereDragEndObservable = "onRotationSphereDragEndObservable", - } - class CreateGizmoDto { - constructor( - positionGizmoEnabled?: boolean, - rotationGizmoEnabled?: boolean, - scaleGizmoEnabled?: boolean, - boundingBoxGizmoEnabled?: boolean, - attachableMeshes?: BABYLON.AbstractMesh[], - clearGizmoOnEmptyPointerEvent?: boolean, - scaleRatio?: number, - usePointerToAttachGizmos?: boolean - ); - /** - * Enable position gizmo - * @default true - */ - positionGizmoEnabled: boolean; - /** - * Enable rotation gizmo - * @default false - */ - rotationGizmoEnabled: boolean; - /** - * Enable scale gizmo - * @default false - */ - scaleGizmoEnabled: boolean; - /** - * Enable bounding box gizmo - * @default false - */ - boundingBoxGizmoEnabled: boolean; - /** - * Use pointer to attach gizmos - * @default true - */ - usePointerToAttachGizmos: boolean; - /** - * Clear gizmo on empty pointer event - * @default false - */ - clearGizmoOnEmptyPointerEvent: boolean; - /** - * Scale ratio - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - scaleRatio: number; - /** - * Attachable meshes - * @default undefined - */ - attachableMeshes: BABYLON.AbstractMesh[]; - } - class GizmoDto { - constructor(gizmo?: BABYLON.IGizmo); - /** - * Gizmo to use - * @default undefined - */ - gizmo: BABYLON.IGizmo; - } - class SetGizmoScaleRatioDto { - constructor(gizmo?: BABYLON.IGizmo, scaleRatio?: number); - /** - * gizmo - * @default undefined - */ - gizmo: BABYLON.IGizmo; - /** - * Scale ratio - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - scaleRatio: number; - } - class GizmoManagerDto { - constructor(gizmoManager?: BABYLON.GizmoManager); - /** - * Gizmo manager to use - * @default undefined - */ - gizmoManager: BABYLON.GizmoManager; - } - class PositionGizmoDto { - constructor(gizmoManager?: BABYLON.IPositionGizmo); - /** - * Gizmo manager to use - * @default undefined - */ - positionGizmo: BABYLON.IPositionGizmo; - } - class SetPlanarGizmoEnabled { - constructor( - positionGizmo?: BABYLON.IPositionGizmo, - planarGizmoEnabled?: boolean - ); - /** - * Position gizmo - * @default undefined - */ - positionGizmo: BABYLON.IPositionGizmo; - /** - * Planar gizmo enabled - * @default true - */ - planarGizmoEnabled: boolean; - } - class SetScaleGizmoSnapDistanceDto { - constructor(scaleGizmo?: BABYLON.IScaleGizmo, snapDistance?: number); - /** - * Scale gizmo - * @default undefined - */ - scaleGizmo: BABYLON.IScaleGizmo; - /** - * Snap distance - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - snapDistance: number; - } - class SetScaleGizmoIncrementalSnapDto { - constructor( - scaleGizmo?: BABYLON.IScaleGizmo, - incrementalSnap?: boolean - ); - /** - * Scale gizmo - * @default undefined - */ - scaleGizmo: BABYLON.IScaleGizmo; - /** - * Incremental snap - * @default false - */ - incrementalSnap: boolean; - } - class SetScaleGizmoSensitivityDto { - constructor(scaleGizmo?: BABYLON.IScaleGizmo, sensitivity?: number); - /** - * Scale gizmo - * @default undefined - */ - scaleGizmo: BABYLON.IScaleGizmo; - /** - * Sensitivity - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - sensitivity: number; - } - class ScaleGizmoDto { - constructor(scaleGizmo?: BABYLON.IScaleGizmo); - /** - * Scale gizmo - * @default undefined - */ - scaleGizmo: BABYLON.IScaleGizmo; - } - class BoundingBoxGizmoDto { - constructor(boundingBoxGizmo?: BABYLON.BoundingBoxGizmo); - /** - * Bounding box gizmo - * @default undefined - */ - boundingBoxGizmo: BABYLON.BoundingBoxGizmo; - } - class SetBoundingBoxGizmoRotationSphereSizeDto { - constructor( - boundingBoxGizmo?: BABYLON.BoundingBoxGizmo, - rotationSphereSize?: number - ); - /** - * Bounding box gizmo - * @default undefined - */ - boundingBoxGizmo: BABYLON.BoundingBoxGizmo; - /** - * The size of the rotation anchors attached to the bounding box (Default: 0.1) - * @default 0.1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - rotationSphereSize: number; - } - class SetBoundingBoxGizmoFixedDragMeshScreenSizeDto { - constructor( - boundingBoxGizmo?: BABYLON.BoundingBoxGizmo, - fixedDragMeshScreenSize?: boolean - ); - /** - * Bounding box gizmo - * @default undefined - */ - boundingBoxGizmo: BABYLON.BoundingBoxGizmo; - /** - * fiex drag mesh screen size - * @default false - */ - fixedDragMeshScreenSize: boolean; - } - class SetBoundingBoxGizmoFixedDragMeshBoundsSizeDto { - constructor( - boundingBoxGizmo?: BABYLON.BoundingBoxGizmo, - fixedDragMeshBoundsSize?: boolean - ); - /** - * Bounding box gizmo - * @default undefined - */ - boundingBoxGizmo: BABYLON.BoundingBoxGizmo; - /** - * fixed drag mesh bounds size - * @default false - */ - fixedDragMeshBoundsSize: boolean; - } - class SetBoundingBoxGizmoFixedDragMeshScreenSizeDistanceFactorDto { - constructor( - boundingBoxGizmo?: BABYLON.BoundingBoxGizmo, - fixedDragMeshScreenSizeDistanceFactor?: number - ); - /** - * Bounding box gizmo - * @default undefined - */ - boundingBoxGizmo: BABYLON.BoundingBoxGizmo; - /** - * fixed drag mesh screen size distance factor - * @default 10 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - fixedDragMeshScreenSizeDistanceFactor: number; - } - class SetBoundingBoxGizmoScalingSnapDistanceDto { - constructor( - boundingBoxGizmo?: BABYLON.BoundingBoxGizmo, - scalingSnapDistance?: number - ); - /** - * Bounding box gizmo - * @default undefined - */ - boundingBoxGizmo: BABYLON.BoundingBoxGizmo; - /** - * Scaling snap distance - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - scalingSnapDistance: number; - } - class SetBoundingBoxGizmoRotationSnapDistanceDto { - constructor( - boundingBoxGizmo?: BABYLON.BoundingBoxGizmo, - rotationSnapDistance?: number - ); - /** - * Bounding box gizmo - * @default undefined - */ - boundingBoxGizmo: BABYLON.BoundingBoxGizmo; - /** - * Rotation snap distance - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - rotationSnapDistance: number; - } - class SetBoundingBoxGizmoScaleBoxSizeDto { - constructor( - boundingBoxGizmo?: BABYLON.BoundingBoxGizmo, - scaleBoxSize?: number - ); - /** - * Bounding box gizmo - * @default undefined - */ - boundingBoxGizmo: BABYLON.BoundingBoxGizmo; - /** - * The size of the scale boxes attached to the bounding box (Default: 0.1) - * @default 0.1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - scaleBoxSize: number; - } - class SetBoundingBoxGizmoIncrementalSnapDto { - constructor( - boundingBoxGizmo?: BABYLON.BoundingBoxGizmo, - incrementalSnap?: boolean - ); - /** - * Bounding box gizmo - * @default undefined - */ - boundingBoxGizmo: BABYLON.BoundingBoxGizmo; - /** - * Incremental snap - * @default false - */ - incrementalSnap: boolean; - } - class SetBoundingBoxGizmoScalePivotDto { - constructor( - boundingBoxGizmo?: BABYLON.BoundingBoxGizmo, - scalePivot?: Base.Vector3 - ); - /** - * Bounding box gizmo - * @default undefined - */ - boundingBoxGizmo: BABYLON.BoundingBoxGizmo; - /** - * Scale pivot - * @default undefined - */ - scalePivot: Base.Vector3; - } - class SetBoundingBoxGizmoAxisFactorDto { - constructor( - boundingBoxGizmo?: BABYLON.BoundingBoxGizmo, - axisFactor?: Base.Vector3 - ); - /** - * Bounding box gizmo - * @default undefined - */ - boundingBoxGizmo: BABYLON.BoundingBoxGizmo; - /** - * Axis factor - * @default undefined - */ - axisFactor: Base.Vector3; - } - class SetBoundingBoxGizmoScaleDragSpeedDto { - constructor( - boundingBoxGizmo?: BABYLON.BoundingBoxGizmo, - scaleDragSpeed?: number - ); - /** - * Bounding box gizmo - * @default undefined - */ - boundingBoxGizmo: BABYLON.BoundingBoxGizmo; - /** - * Scale drag speed - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - scaleDragSpeed: number; - } - class SetPositionGizmoSnapDistanceDto { - constructor( - positionGizmo?: BABYLON.IPositionGizmo, - snapDistance?: number - ); - /** - * Position gizmo - * @default undefined - */ - positionGizmo: BABYLON.IPositionGizmo; - /** - * Snap distance - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - snapDistance: number; - } - class SetRotationGizmoSnapDistanceDto { - constructor( - rotationGizmo?: BABYLON.IRotationGizmo, - snapDistance?: number - ); - /** - * Position gizmo - * @default undefined - */ - rotationGizmo: BABYLON.IRotationGizmo; - /** - * Snap distance - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - snapDistance: number; - } - class SetRotationGizmoSensitivityDto { - constructor( - rotationGizmo?: BABYLON.IRotationGizmo, - sensitivity?: number - ); - /** - * Position gizmo - * @default undefined - */ - rotationGizmo: BABYLON.IRotationGizmo; - /** - * Sensitivity - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - sensitivity: number; - } - class RotationGizmoDto { - constructor(rotationGizmo?: BABYLON.IRotationGizmo); - /** - * Rotation gizmo - * @default undefined - */ - rotationGizmo: BABYLON.IRotationGizmo; - } - class AxisScaleGizmoDto { - constructor(axisScaleGizmo?: BABYLON.IAxisScaleGizmo); - /** - * axis scale gizmo - * @default undefined - */ - axisScaleGizmo: BABYLON.IAxisScaleGizmo; - } - class SetIsEnabledAxisScaleGizmoDto { - constructor( - gizmoManager?: BABYLON.IAxisScaleGizmo, - isEnabled?: boolean - ); - /** - * axis scale gizmo - * @default undefined - */ - axisScaleGizmo: BABYLON.IAxisScaleGizmo; - /** - * Is enabled - * @default true - */ - isEnabled: boolean; - } - class AxisDragGizmoDto { - constructor(axisDragGizmo?: BABYLON.IAxisDragGizmo); - /** - * axis drag gizmo - * @default undefined - */ - axisDragGizmo: BABYLON.IAxisDragGizmo; - } - class SetIsEnabledAxisDragGizmoDto { - constructor(gizmoManager?: BABYLON.IAxisDragGizmo, isEnabled?: boolean); - /** - * axis drag gizmo - * @default undefined - */ - axisDragGizmo: BABYLON.IAxisDragGizmo; - /** - * Is enabled - * @default true - */ - isEnabled: boolean; - } - class SetIsEnabledPlaneRotationGizmoDto { - constructor( - planeRotationGizmo?: BABYLON.IPlaneRotationGizmo, - isEnabled?: boolean - ); - /** - * plane drag gizmo - * @default undefined - */ - planeRotationGizmo: BABYLON.IPlaneRotationGizmo; - /** - * Is enabled - * @default true - */ - isEnabled: boolean; - } - class SetIsEnabledPlaneDragGizmoDto { - constructor( - planeDragGizmo?: BABYLON.IPlaneDragGizmo, - isEnabled?: boolean - ); - /** - * plane drag gizmo - * @default undefined - */ - planeDragGizmo: BABYLON.IPlaneDragGizmo; - /** - * Is enabled - * @default true - */ - isEnabled: boolean; - } - class PlaneDragGizmoDto { - constructor(planeDragGizmo?: BABYLON.IPlaneDragGizmo); - /** - * plane drag gizmo - * @default undefined - */ - planeDragGizmo: BABYLON.IPlaneDragGizmo; - } - class PlaneRotationGizmoDto { - constructor(planeRotationGizmo?: BABYLON.IPlaneRotationGizmo); - /** - * plane drag gizmo - * @default undefined - */ - planeRotationGizmo: BABYLON.IPlaneRotationGizmo; - } - class AttachToMeshDto { - constructor( - mesh: BABYLON.AbstractMesh, - gizmoManager: BABYLON.GizmoManager - ); - /** - * Mesh to attach gizmo manager to - */ - mesh: BABYLON.AbstractMesh; - /** - * Gizmo manager to attach - */ - gizmoManager: BABYLON.GizmoManager; - } - class PositionGizmoObservableSelectorDto { - constructor(selector: positionGizmoObservableSelectorEnum); - /** - * Selector - */ - selector: positionGizmoObservableSelectorEnum; - } - class BoundingBoxGizmoObservableSelectorDto { - constructor(selector: boundingBoxGizmoObservableSelectorEnum); - /** - * Selector - */ - selector: boundingBoxGizmoObservableSelectorEnum; - } - class RotationGizmoObservableSelectorDto { - constructor(selector: rotationGizmoObservableSelectorEnum); - /** - * Selector - */ - selector: rotationGizmoObservableSelectorEnum; - } - class ScaleGizmoObservableSelectorDto { - constructor(selector: scaleGizmoObservableSelectorEnum); - /** - * Selector - */ - selector: scaleGizmoObservableSelectorEnum; - } - } - declare namespace BabylonGui { - enum horizontalAlignmentEnum { - left = "left", - center = "center", - right = "right", - } - enum verticalAlignmentEnum { - top = "top", - center = "center", - bottom = "bottom", - } - enum inputTextObservableSelectorEnum { - /** Observable raised when the text changes */ - onTextChangedObservable = "onTextChangedObservable", - /** Observable raised just before an entered character is to be added */ - onBeforeKeyAddObservable = "onBeforeKeyAddObservable", - /** Observable raised when the text is highlighted */ - onTextHighlightObservable = "onTextHighlightObservable", - /** Observable raised when copy event is triggered */ - onTextCopyObservable = "onTextCopyObservable", - /** Observable raised when cut event is triggered */ - onTextCutObservable = "onTextCutObservable", - /** Observable raised when paste event is triggered */ - onTextPasteObservable = "onTextPasteObservable", - } - enum sliderObservableSelectorEnum { - /** - * Raised when the value has changed - */ - onValueChangedObservable = "onValueChangedObservable", - } - enum colorPickerObservableSelectorEnum { - /** - * Raised when the value has changed - */ - onValueChangedObservable = "onValueChangedObservable", - } - enum textBlockObservableSelectorEnum { - /** - * Raised when the text has changed - */ - onTextChangedObservable = "onTextChangedObservable", - } - enum checkboxObservableSelectorEnum { - /** - * Raised when the checkbox is checked or unchecked - */ - onIsCheckedChangedObservable = "onIsCheckedChangedObservable", - } - enum radioButtonObservableSelectorEnum { - /** - * Raised when the radio button is checked or unchecked - */ - onIsCheckedChangedObservable = "onIsCheckedChangedObservable", - } - enum controlObservableSelectorEnum { - onFocusObservable = "onFocusObservable", - onBlurObservable = "onBlurObservable", - /** - * Observable that fires whenever the accessibility event of the control has changed - */ - onAccessibilityTagChangedObservable = "onAccessibilityTagChangedObservable", - /** - * An event triggered when pointer wheel is scrolled - */ - onWheelObservable = "onWheelObservable", - /** - * An event triggered when the pointer moves over the control. - */ - onPointerMoveObservable = "onPointerMoveObservable", - /** - * An event triggered when the pointer moves out of the control. - */ - onPointerOutObservable = "onPointerOutObservable", - /** - * An event triggered when the pointer taps the control - */ - onPointerDownObservable = "onPointerDownObservable", - /** - * An event triggered when pointer up - */ - onPointerUpObservable = "onPointerUpObservable", - /** - * An event triggered when a control is clicked on - */ - onPointerClickObservable = "onPointerClickObservable", - /** - * An event triggered when a control receives an ENTER key down event - */ - onEnterPressedObservable = "onEnterPressedObservable", - /** - * An event triggered when pointer enters the control - */ - onPointerEnterObservable = "onPointerEnterObservable", - /** - * An event triggered when the control is marked as dirty - */ - onDirtyObservable = "onDirtyObservable", - /** - * An event triggered before drawing the control - */ - onBeforeDrawObservable = "onBeforeDrawObservable", - /** - * An event triggered after the control was drawn - */ - onAfterDrawObservable = "onAfterDrawObservable", - /** - * An event triggered when the control has been disposed - */ - onDisposeObservable = "onDisposeObservable", - /** - * An event triggered when the control isVisible is changed - */ - onIsVisibleChangedObservable = "onIsVisibleChangedObservable", - } - class CreateFullScreenUIDto { - constructor( - name?: string, - foreground?: boolean, - adaptiveScaling?: boolean - ); - /** - * Name of advanced texture - * @default fullscreen - */ - name: string; - /** - * Foreground - * @default true - */ - foreground?: boolean; - /** - * Adaptive scaling - * @default false - */ - adaptiveScaling?: boolean; - } - class CreateForMeshDto { - constructor( - mesh?: BABYLON.AbstractMesh, - width?: number, - height?: number, - supportPointerMove?: boolean, - onlyAlphaTesting?: boolean, - invertY?: boolean, - sampling?: BabylonTexture.samplingModeEnum - ); - /** - * Mesh - * @default undefined - */ - mesh: BABYLON.AbstractMesh; - /** - * Width - * @default undefined - * @optional true - */ - width?: number; - /** - * Height - * @default undefined - * @optional true - */ - height?: number; - /** - * Support pointer move - * @default true - */ - supportPointerMove: boolean; - /** - * Only alpha testing - * @default false - */ - onlyAlphaTesting: boolean; - /** - * Invert Y - * @default true - */ - invertY: boolean; - /** - * Sampling - * @default trilinear - */ - sampling: BabylonTexture.samplingModeEnum; - } - class CreateStackPanelDto { - constructor( - name?: string, - isVertical?: boolean, - spacing?: number, - width?: number | string, - height?: number | string, - color?: string, - background?: string - ); - /** - * Name of stack panel - * @default stackPanel - */ - name: string; - /** - * Horizontal or vertical - * @default true - */ - isVertical: boolean; - /** - * Spacing between each child in pixels - * @default 0 - */ - spacing: number; - /** - * Width of the stack panel. This value should not be set when in horizontal mode as it will be computed automatically. - * @default undefined - * @optional true - */ - width: number | string; - /** - * Height of the stack panel. This value should not be set when in vertical mode as it will be computed automatically. - * @default undefined - * @optional true - */ - height: number | string; - /** - * Color of the stack panel - * @default #00000000 - */ - color: string; - /** - * Background of the stack panel. We give transparency to the background by default so that it would be visible - * @default #00000055 - */ - background: string; - } - class SetStackPanelIsVerticalDto { - constructor(stackPanel?: BABYLON.GUI.StackPanel, isVertical?: boolean); - /** - * Stack panel to update - * @default undefined - */ - stackPanel: BABYLON.GUI.StackPanel; - /** - * Is vertical - * @default true - */ - isVertical: boolean; - } - class SetStackPanelSpacingDto { - constructor(stackPanel?: BABYLON.GUI.StackPanel, spacing?: number); - /** - * Stack panel to update - * @default undefined - */ - stackPanel: BABYLON.GUI.StackPanel; - /** - * Spacing between each child in pixels - * @default 0 - */ - spacing: number; - } - class SetStackPanelWidthDto { - constructor( - stackPanel?: BABYLON.GUI.StackPanel, - width?: number | string - ); - /** - * Stack panel to update - * @default undefined - */ - stackPanel: BABYLON.GUI.StackPanel; - /** - * Width of the stack panel - * @default undefined - * @optional true - */ - width: number | string; - } - class SetStackPanelHeightDto { - constructor( - stackPanel?: BABYLON.GUI.StackPanel, - height?: number | string - ); - /** - * Stack panel to update - * @default undefined - */ - stackPanel: BABYLON.GUI.StackPanel; - /** - * Height of the stack panel. - * @default undefined - * @optional true - */ - height: number | string; - } - class StackPanelDto { - constructor(stackPanel?: BABYLON.GUI.StackPanel); - /** - * Stack panel to update - * @default undefined - */ - stackPanel: BABYLON.GUI.StackPanel; - } - class SliderObservableSelectorDto { - constructor(selector: sliderObservableSelectorEnum); - /** - * Selector for the observable - * @default onValueChangedObservable - */ - selector: sliderObservableSelectorEnum; - } - class ColorPickerObservableSelectorDto { - constructor(selector: colorPickerObservableSelectorEnum); - /** - * Selector for the observable - * @default onValueChangedObservable - */ - selector: colorPickerObservableSelectorEnum; - } - class InputTextObservableSelectorDto { - constructor(selector: inputTextObservableSelectorEnum); - /** - * Selector for the observable - * @default onTextChangedObservable - */ - selector: inputTextObservableSelectorEnum; - } - class RadioButtonObservableSelectorDto { - constructor(selector: radioButtonObservableSelectorEnum); - /** - * Selector for the observable - * @default onIsCheckedChangedObservable - */ - selector: radioButtonObservableSelectorEnum; - } - class CheckboxObservableSelectorDto { - constructor(selector: checkboxObservableSelectorEnum); - /** - * Selector for the observable - * @default onIsCheckedChangedObservable - */ - selector: checkboxObservableSelectorEnum; - } - class ControlObservableSelectorDto { - constructor(selector: controlObservableSelectorEnum); - /** - * Selector for the observable - * @default onPointerClickObservable - */ - selector: controlObservableSelectorEnum; - } - class TextBlockObservableSelectorDto { - constructor(selector: textBlockObservableSelectorEnum); - /** - * Selector for the observable - * @default onTextChangedObservable - */ - selector: textBlockObservableSelectorEnum; - } - class ContainerDto { - constructor(container?: BABYLON.GUI.Container); - /** - * Container to update - * @default undefined - */ - container: BABYLON.GUI.Container; - } - class AddControlsToContainerDto { - constructor( - container?: BABYLON.GUI.StackPanel, - controls?: BABYLON.GUI.Control[], - clearControlsFirst?: boolean - ); - /** - * Container to add control to - * @default undefined - */ - container: BABYLON.GUI.Container; - /** - * Controls to add - * @default undefined - */ - controls: BABYLON.GUI.Control[]; - /** - * Clear controls first. That will preserve the order of the controls. - * @default true - */ - clearControlsFirst: boolean; - } - class GetControlByNameDto { - constructor(container?: BABYLON.GUI.Container, name?: string); - /** - * Container to get control from - * @default undefined - */ - container: BABYLON.GUI.Container; - /** - * Name of the control - * @default controlName - */ - name: string; - } - class SetControlIsVisibleDto { - constructor(control?: BABYLON.GUI.Control, isVisible?: boolean); - /** - * Control to update - * @default undefined - */ - control: BABYLON.GUI.Control; - /** - * Is visible - * @default true - */ - isVisible: boolean; - } - class SetControlIsReadonlyDto { - constructor(control?: BABYLON.GUI.Control, isReadOnly?: boolean); - /** - * Control to update - * @default undefined - */ - control: BABYLON.GUI.Control; - /** - * Is readonly - * @default false - */ - isReadOnly: boolean; - } - class SetControlIsEnabledDto { - constructor(control?: BABYLON.GUI.Control, isEnabled?: boolean); - /** - * Control to update - * @default undefined - */ - control: BABYLON.GUI.Control; - /** - * Is enabled - * @default true - */ - isEnabled: boolean; - } - class CreateImageDto { - constructor( - name?: string, - url?: string, - color?: string, - width?: number | string, - height?: number | string - ); - /** - * Name of the image - * @default imageName - */ - name: string; - /** - * Link to the image - * @default undefined - */ - url: string; - /** - * Color of the image - * @default black - */ - color: string; - /** - * Width of the image - * @default undefined - * @optional true - */ - width?: number | string; - /** - * Height of the image - * @default undefined - * @optional true - */ - height?: number | string; - } - class SetImageUrlDto { - constructor(image?: BABYLON.GUI.Image, url?: string); - /** - * Image to update - * @default undefined - */ - image: BABYLON.GUI.Image; - /** - * Link to the image - * @default undefined - */ - url: string; - } - class ImageDto { - constructor(image?: BABYLON.GUI.Image); - /** - * Image to update - * @default undefined - */ - image: BABYLON.GUI.Image; - } - class CreateButtonDto { - constructor( - name?: string, - label?: string, - color?: string, - background?: string, - width?: number | string, - height?: number | string, - fontSize?: number - ); - /** - * Name of the button - * @default buttonName - */ - name: string; - /** - * Text of the button - * @default Click me! - */ - label: string; - /** - * Color of the button - * @default black - */ - color: string; - /** - * Background of the button - * @default #f0cebb - */ - background: string; - /** - * Width of the button - * @default undefined - * @optional true - */ - width?: number | string; - /** - * Height of the button - * @default undefined - * @optional true - */ - height?: number | string; - /** - * Font size of the button - * @default 24 - */ - fontSize: number; - } - class SetButtonTextDto { - constructor(button?: BABYLON.GUI.Button, text?: string); - /** - * Button to update - * @default undefined - */ - button: BABYLON.GUI.Button; - /** - * Text of the button - * @default Click me! - */ - text: string; - } - class ButtonDto { - constructor(button?: BABYLON.GUI.Button); - /** - * Button to update - * @default undefined - */ - button: BABYLON.GUI.Button; - } - class CreateColorPickerDto { - constructor( - name?: string, - defaultColor?: string, - color?: string, - width?: number | string, - height?: number | string, - size?: number | string - ); - /** - * Name of the color picker - * @default colorPickerName - */ - name: string; - /** - * Default color of the color picker - * @default #f0cebb - */ - defaultColor: string; - /** - * Color of the color picker - * @default #f0cebb - */ - color: string; - /** - * Width of the color picker - * @default undefined - * @optional true - */ - width?: number | string; - /** - * Height of the color picker - * @default undefined - * @optional true - */ - height?: number | string; - /** - * Size of the color picker - * @default 300px - * @optional true - */ - size?: number | string; - } - class SetColorPickerValueDto { - constructor(colorPicker?: BABYLON.GUI.ColorPicker, color?: string); - /** - * Color picker to update - * @default undefined - */ - colorPicker: BABYLON.GUI.ColorPicker; - /** - * Value of the color picker - * @default undefined - */ - color: string; - } - class SetColorPickerSizeDto { - constructor( - colorPicker?: BABYLON.GUI.ColorPicker, - size?: number | string - ); - /** - * Color picker to update - * @default undefined - */ - colorPicker: BABYLON.GUI.ColorPicker; - /** - * Size of the color picker - * @default 300px - * @optional true - */ - size?: number | string; - } - class ColorPickerDto { - constructor(colorPicker?: BABYLON.GUI.ColorPicker); - /** - * Color picker to update - * @default undefined - */ - colorPicker: BABYLON.GUI.ColorPicker; - } - class CreateCheckboxDto { - constructor( - name?: string, - isChecked?: boolean, - checkSizeRatio?: number, - color?: string, - background?: string, - width?: number | string, - height?: number | string - ); - /** - * Name of the checkbox - * @default checkboxName - */ - name: string; - /** - * Is checked - * @default false - */ - isChecked: boolean; - /** - * Check size ratio - * @default 0.8 - * @minimum 0 - * @maximum 1 - * @step 0.05 - */ - checkSizeRatio: number; - /** - * Color of the checkbox - * @default #f0cebb - */ - color: string; - /** - * Background of the checkbox - * @default black - */ - background: string; - /** - * Width of the checkbox - * @default undefined - * @optional true - */ - width?: number | string; - /** - * Height of the checkbox - * @default undefined - * @optional true - */ - height?: number | string; - } - class SetControlFontSizeDto { - constructor(control?: BABYLON.GUI.Control, fontSize?: number); - /** - * Control to update - * @default undefined - */ - control: BABYLON.GUI.Control; - /** - * Font size of the button - * @default 24 - */ - fontSize: number; - } - class SetControlHeightDto { - constructor(control?: BABYLON.GUI.Control, height?: number | string); - /** - * Control to update - * @default undefined - */ - control: BABYLON.GUI.Control; - /** - * Height of the checkbox - * @default undefined - */ - height: number | string; - } - class SetControlWidthDto { - constructor(control?: BABYLON.GUI.Control, width?: number | string); - /** - * Control to update - * @default undefined - */ - control: BABYLON.GUI.Control; - /** - * Width of the checkbox - * @default undefined - */ - width: number | string; - } - class SetControlColorDto { - constructor(control?: BABYLON.GUI.Control, color?: string); - /** - * Control to update - * @default undefined - */ - control: BABYLON.GUI.Control; - /** - * Color of the checkbox - * @default #f0cebb - */ - color: string; - } - class SetContainerBackgroundDto { - constructor(container?: BABYLON.GUI.Container, background?: string); - /** - * Container to update - * @default undefined - */ - container: BABYLON.GUI.Container; - /** - * Background of the checkbox - * @default black - */ - background: string; - } - class SetContainerIsReadonlyDto { - constructor(container?: BABYLON.GUI.Container, isReadOnly?: boolean); - /** - * Container to update - * @default undefined - */ - container: BABYLON.GUI.Container; - /** - * Is readonly - * @default false - */ - isReadOnly: boolean; - } - class SetCheckboxBackgroundDto { - constructor(checkbox?: BABYLON.GUI.Checkbox, background?: string); - /** - * Checkbox to update - * @default undefined - */ - checkbox: BABYLON.GUI.Checkbox; - /** - * Background of the checkbox - * @default black - */ - background: string; - } - class SetCheckboxCheckSizeRatioDto { - constructor(checkbox?: BABYLON.GUI.Checkbox, checkSizeRatio?: number); - /** - * Checkbox to update - * @default undefined - */ - checkbox: BABYLON.GUI.Checkbox; - /** - * Check size ratio - * @default 0.8 - * @minimum 0 - * @maximum 1 - * @step 0.05 - */ - checkSizeRatio: number; - } - class CheckboxDto { - constructor(checkbox?: BABYLON.GUI.Checkbox); - /** - * Checkbox to update - * @default undefined - */ - checkbox: BABYLON.GUI.Checkbox; - } - class ControlDto { - constructor(control?: BABYLON.GUI.Control); - /** - * Control to update - * @default undefined - */ - control: BABYLON.GUI.Control; - } - class SetCheckboxIsCheckedDto { - constructor(checkbox?: BABYLON.GUI.Checkbox, isChecked?: boolean); - /** - * Checkbox to update - * @default undefined - */ - checkbox: BABYLON.GUI.Checkbox; - /** - * Is checked - * @default false - */ - isChecked: boolean; - } - class CreateInputTextDto { - constructor( - name?: string, - color?: string, - background?: string, - width?: number | string, - height?: number | string - ); - /** - * Name of the button - * @default inputName - */ - name: string; - /** - * Text of the input - * @default - */ - text: string; - /** - * Placeholder of the input - * @default - */ - placeholder: string; - /** - * Color of the button - * @default #f0cebb - */ - color: string; - /** - * Background of the button - * @default black - */ - background: string; - /** - * Width of the button - * @default undefined - * @optional true - */ - width?: number | string; - /** - * Height of the button - * @default undefined - * @optional true - */ - height?: number | string; - } - class SetInputTextBackgroundDto { - constructor(inputText?: BABYLON.GUI.InputText, background?: string); - /** - * Input text to update - * @default undefined - */ - inputText: BABYLON.GUI.InputText; - /** - * Background of the input text - * @default black - */ - background: string; - } - class SetInputTextTextDto { - constructor(inputText?: BABYLON.GUI.InputText, text?: string); - /** - * Input text to update - * @default undefined - */ - inputText: BABYLON.GUI.InputText; - /** - * Text of the input text - * @default - */ - text: string; - } - class SetInputTextPlaceholderDto { - constructor(inputText?: BABYLON.GUI.InputText, placeholder?: string); - /** - * Input text to update - * @default undefined - */ - inputText: BABYLON.GUI.InputText; - /** - * Placeholder of the input text - * @default - */ - placeholder: string; - } - class InputTextDto { - constructor(inputText?: BABYLON.GUI.InputText); - /** - * Input text to update - * @default undefined - */ - inputText: BABYLON.GUI.InputText; - } - class CreateRadioButtonDto { - constructor( - name?: string, - group?: string, - isChecked?: boolean, - checkSizeRatio?: number, - color?: string, - background?: string, - width?: number | string, - height?: number | string - ); - /** - * Name of the button - * @default radioBtnName - */ - name: string; - /** - * Group of the radio button which is used when multiple radio buttons needs to be split into separate groups - * @default - * @optional true - */ - group: string; - /** - * Is checked - * @default false - */ - isChecked: boolean; - /** - * Check size ratio - * @default 0.8 - * @minimum 0 - * @maximum 1 - * @step 0.05 - */ - checkSizeRatio: number; - /** - * Color of the button - * @default #f0cebb - */ - color: string; - /** - * Background of the button - * @default black - */ - background: string; - /** - * Width of the button - * @default undefined - * @optional true - */ - width?: number | string; - /** - * Height of the button - * @default undefined - * @optional true - */ - height?: number | string; - } - class SetRadioButtonCheckSizeRatioDto { - constructor( - radioButton?: BABYLON.GUI.RadioButton, - checkSizeRatio?: number - ); - /** - * Radio button to update - * @default undefined - */ - radioButton: BABYLON.GUI.RadioButton; - /** - * Check size ratio - * @default 0.8 - * @minimum 0 - * @maximum 1 - * @step 0.05 - */ - checkSizeRatio: number; - } - class SetRadioButtonGroupDto { - constructor(radioButton?: BABYLON.GUI.RadioButton, group?: string); - /** - * Radio button to update - * @default undefined - */ - radioButton: BABYLON.GUI.RadioButton; - /** - * Group of the radio button - * @default - */ - group: string; - } - class SetRadioButtonBackgroundDto { - constructor(radioButton?: BABYLON.GUI.RadioButton, background?: string); - /** - * Radio button to update - * @default undefined - */ - radioButton: BABYLON.GUI.RadioButton; - /** - * Background of the radio button - * @default black - */ - background: string; - } - class RadioButtonDto { - constructor(radioButton?: BABYLON.GUI.RadioButton); - /** - * Radio button to update - * @default undefined - */ - radioButton: BABYLON.GUI.RadioButton; - } - class CreateSliderDto { - constructor( - name?: string, - minimum?: number, - maximum?: number, - value?: number, - step?: number, - isVertical?: boolean, - color?: string, - background?: string, - width?: number | string, - height?: number | string, - displayThumb?: boolean - ); - /** - * Name of the button - * @default sliderName - */ - name: string; - /** - * Minimum value of the slider - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - minimum: number; - /** - * Maximum value of the slider - * @default 10 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - maximum: number; - /** - * Value of the slider - * @default 5 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - value: number; - /** - * Step of the slider - * @default 0.01 - * @minimum -Infinity - * @maximum Infinity - * @step 0.01 - */ - step: number; - /** - * Is slider vertical - * @default false - */ - isVertical: boolean; - /** - * Color of the button - * @default #f0cebb - */ - color: string; - /** - * Background of the button - * @default black - */ - background: string; - /** - * Width of the button - * @default undefined - * @optional true - */ - width?: number | string; - /** - * Height of the button - * @default undefined - * @optional true - */ - height?: number | string; - /** - * Should display thumb - * @default true - */ - displayThumb: boolean; - } - class CreateTextBlockDto { - constructor( - name?: string, - text?: string, - color?: string, - width?: number | string, - height?: number | string - ); - /** - * Name of the text block - * @default textBlockName - */ - name: string; - /** - * Text of the block - * @default Hello World! - */ - text: string; - /** - * Color of the text block - * @default #f0cebb - */ - color: string; - /** - * Width of the text block - * @default undefined - * @optional true - */ - width?: number | string; - /** - * Height of the text block - * @default undefined - * @optional true - */ - height?: number | string; - /** - * Font size of the text block - * @default 24 - */ - fontSize: number; - } - class SetTextBlockTextDto { - constructor(textBlock?: BABYLON.GUI.TextBlock, text?: string); - /** - * Text block to update - * @default undefined - */ - textBlock: BABYLON.GUI.TextBlock; - /** - * Text of the block - * @default undefined - */ - text: string; - } - class SetTextBlockResizeToFitDto { - constructor(textBlock?: BABYLON.GUI.TextBlock, resizeToFit?: boolean); - /** - * Text block to update - * @default undefined - */ - textBlock: BABYLON.GUI.TextBlock; - /** - * Resize to fit - * @default false - */ - resizeToFit: boolean; - } - class SetTextBlockTextWrappingDto { - constructor(textBlock?: BABYLON.GUI.TextBlock, textWrapping?: boolean); - /** - * Text block to update - * @default undefined - */ - textBlock: BABYLON.GUI.TextBlock; - /** - * Text wrapping - * @default undefined - */ - textWrapping: boolean | BABYLON.GUI.TextWrapping; - } - class SetTextBlockLineSpacingDto { - constructor( - textBlock?: BABYLON.GUI.TextBlock, - lineSpacing?: string | number - ); - /** - * Text block to update - * @default undefined - */ - textBlock: BABYLON.GUI.TextBlock; - /** - * Line spacing of the text - * @default undefined - */ - lineSpacing: string | number; - } - class TextBlockDto { - constructor(textBlock?: BABYLON.GUI.TextBlock); - /** - * Text block to update - * @default undefined - */ - textBlock: BABYLON.GUI.TextBlock; - } - class SliderThumbDto { - constructor( - slider?: BABYLON.GUI.Slider, - isThumbCircle?: boolean, - thumbColor?: string, - thumbWidth?: string | number, - isThumbClamped?: boolean, - displayThumb?: boolean - ); - /** - * Slider for which the thumb needs to be updated - * @default undefined - */ - slider: BABYLON.GUI.Slider; - /** - * Is thumb circle - * @default false - */ - isThumbCircle: boolean; - /** - * Color of the thumb - * @default white - */ - thumbColor: string; - /** - * Thumb width - * @default undefined - * @optional true - */ - thumbWidth?: string | number; - /** - * Is thumb clamped - * @default false - */ - isThumbClamped: boolean; - /** - * Should display thumb - * @default true - */ - displayThumb: boolean; - } - class SliderDto { - constructor(slider?: BABYLON.GUI.Slider); - /** - * Slider for which the thumb needs to be updated - * @default undefined - */ - slider: BABYLON.GUI.Slider; - } - class SliderBorderColorDto { - constructor(slider?: BABYLON.GUI.Slider, borderColor?: string); - /** - * Slider for which the thumb needs to be updated - * @default undefined - */ - slider: BABYLON.GUI.Slider; - /** - * Border color of the slider - * @default white - */ - borderColor: string; - } - class SliderBackgroundColorDto { - constructor(slider?: BABYLON.GUI.Slider, backgroundColor?: string); - /** - * Slider for which the thumb needs to be updated - * @default undefined - */ - slider: BABYLON.GUI.Slider; - /** - * Background color of the slider - * @default black - */ - backgroundColor: string; - } - class SetSliderValueDto { - constructor(slider?: BABYLON.GUI.Slider, value?: number); - /** - * Slider for which the thumb needs to be updated - * @default undefined - */ - slider: BABYLON.GUI.Slider; - /** - * Value of the slider - * @default 5 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - value: number; - } - class PaddingLeftRightTopBottomDto { - constructor( - control?: BABYLON.GUI.Control, - paddingLeft?: number | string, - paddingRight?: number | string, - paddingTop?: number | string, - paddingBottom?: number | string - ); - /** - * Control to change the padding - * @default undefined - */ - control: BABYLON.GUI.Control; - /** - * Padding left of the stack panel - * @default undefined - * @optional true - */ - paddingLeft: number | string; - /** - * Padding right of the stack panel - * @default undefined - * @optional true - */ - paddingRight: number | string; - /** - * Padding top of the stack panel - * @default undefined - * @optional true - */ - paddingTop: number | string; - /** - * Padding bottom of the stack panel - * @default undefined - * @optional true - */ - paddingBottom: number | string; - } - class CloneControlDto { - constructor( - control?: BABYLON.GUI.Control, - container?: BABYLON.GUI.Container, - name?: string, - host?: BABYLON.GUI.AdvancedDynamicTexture - ); - /** - * Control to clone - * @default undefined - */ - control: BABYLON.GUI.Control; - /** - * Use container to which the cloned control will be added - * @default undefined - * @optional true - */ - container?: BABYLON.GUI.Container; - /** - * Name of the cloned control - * @default clonedControl - */ - name: string; - /** - * Host of the cloned control - * @default undefined - * @optional true - */ - host?: BABYLON.GUI.AdvancedDynamicTexture; - } - class AlignmentDto { - constructor( - control?: T, - horizontalAlignment?: horizontalAlignmentEnum, - verticalAlignment?: verticalAlignmentEnum - ); - /** - * Control to change the padding - * @default undefined - */ - control: T; - /** - * Alignment horizontal - * @default center - */ - horizontalAlignment: horizontalAlignmentEnum; - /** - * Alignment horizontal - * @default center - */ - verticalAlignment: verticalAlignmentEnum; - } - class SetTextBlockTextOutlineDto { - constructor( - textBlock?: BABYLON.GUI.TextBlock, - outlineWidth?: number, - outlineColor?: string - ); - /** - * Control to change the padding - * @default undefined - */ - textBlock: BABYLON.GUI.TextBlock; - /** - * Alignment horizontal - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - outlineWidth: number; - /** - * Outline color - * @default white - */ - outlineColor: string; - } - } - declare namespace BabylonIO { - class ExportSceneGlbDto { - constructor(fileName?: string, discardSkyboxAndGrid?: boolean); - /** - * File name that should be used for the scene. - * @default bitbybit-scene - */ - fileName: string; - /** - * Discard skybox and grid - * @default false - * @optional true - */ - discardSkyboxAndGrid?: boolean; - } - class ExportSceneDto { - constructor(fileName?: string); - /** - * File name that should be used for the scene. - * @default bitbybit-scene - */ - fileName: string; - } - class ExportMeshToStlDto { - constructor(mesh?: BABYLON.Mesh, fileName?: string); - /** - * Mesh to export - */ - mesh: BABYLON.Mesh; - /** - * File name that should be used for the scene. - * @default bitbybit-mesh - */ - fileName: string; - } - class ExportMeshesToStlDto { - constructor(meshes?: BABYLON.Mesh[], fileName?: string); - /** - * Meshes to export - */ - meshes: BABYLON.Mesh[]; - /** - * File name that should be used for the scene. - * @default bitbybit-mesh - */ - fileName: string; - } - } - declare namespace BabylonLight { - class ShadowLightDirectionToTargetDto { - constructor(shadowLight?: BABYLON.ShadowLight, target?: Base.Vector3); - /** - * Shadow light to update - * @default undefined - */ - shadowLight: BABYLON.ShadowLight; - /** - * The direction target - * @default undefined - */ - target?: Base.Vector3; - } - class ShadowLightPositionDto { - constructor(shadowLight?: BABYLON.ShadowLight, position?: Base.Vector3); - /** - * Shadow light to update - * @default undefined - */ - shadowLight: BABYLON.ShadowLight; - /** - * The position - * @default undefined - */ - position?: Base.Vector3; - } - } - declare namespace BabylonMaterial { - class PBRMetallicRoughnessDto { - constructor( - name?: string, - baseColor?: Base.Color, - emissiveColor?: Base.Color, - metallic?: number, - roughness?: number, - alpha?: number, - backFaceCulling?: boolean, - zOffset?: number - ); - /** - * Name of the material - * @default Custom Material - */ - name: string; - /** - * Base color of the material - * @default #0000ff - */ - baseColor: Base.Color; - /** - * Emissive color of the material - * @default #000000 - */ - emissiveColor?: Base.Color; - /** - * Metallic value of the material - * @default 0.6 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - metallic: number; - /** - * Roughness value of the material - * @default 0.5 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - roughness: number; - /** - * Defines the transparency of the material - * @default 1 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - alpha: number; - /** - * Identifies if both sides of the surface should have material applied - * @default false - */ - backFaceCulling: boolean; - /** - * Defines the z offset of the material - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - zOffset: number; - } - class BaseColorDto { - constructor( - material?: BABYLON.PBRMetallicRoughnessMaterial, - baseColor?: Base.Color - ); - /** - * Material to update - * @default undefined - */ - material: BABYLON.PBRMetallicRoughnessMaterial; - /** - * Base color of the material - * @default #0000ff - */ - baseColor?: Base.Color; - } - class MaterialPropDto { - constructor(material?: BABYLON.PBRMetallicRoughnessMaterial); - /** - * Material to investigate - * @default undefined - */ - material: BABYLON.PBRMetallicRoughnessMaterial; - } - class SkyMaterialPropDto { - constructor(skyMaterial?: MATERIALS.SkyMaterial); - /** - * Material to investigate - * @default undefined - */ - skyMaterial: MATERIALS.SkyMaterial; - } - class MetallicDto { - constructor( - material?: BABYLON.PBRMetallicRoughnessMaterial, - metallic?: number - ); - /** - * Material to update - * @default undefined - */ - material: BABYLON.PBRMetallicRoughnessMaterial; - /** - * Metallic value of the material - * @default 0.5 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - metallic?: number; - } - class RoughnessDto { - constructor( - material?: BABYLON.PBRMetallicRoughnessMaterial, - roughness?: number - ); - /** - * Material to update - * @default undefined - */ - material: BABYLON.PBRMetallicRoughnessMaterial; - /** - * Roughness value of the material - * @default 0.5 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - roughness?: number; - } - class AlphaDto { - constructor( - material?: BABYLON.PBRMetallicRoughnessMaterial, - alpha?: number - ); - /** - * Material to update - * @default undefined - */ - material: BABYLON.PBRMetallicRoughnessMaterial; - /** - * Alpha value of the material - * @default 0.5 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - alpha?: number; - } - class BackFaceCullingDto { - constructor( - material?: BABYLON.PBRMetallicRoughnessMaterial, - backFaceCulling?: boolean - ); - /** - * Material to update - * @default undefined - */ - material: BABYLON.PBRMetallicRoughnessMaterial; - /** - * back face culling - * @default true - */ - backFaceCulling?: boolean; - } - class BaseTextureDto { - constructor( - material?: BABYLON.PBRMetallicRoughnessMaterial, - baseTexture?: BABYLON.Texture - ); - /** - * Material to update - * @default undefined - */ - material: BABYLON.PBRMetallicRoughnessMaterial; - /** - * Base texture of the material - * @default undefined - */ - baseTexture: BABYLON.Texture; - } - class SkyMaterialDto { - constructor( - luminance?: number, - turbidity?: number, - rayleigh?: number, - mieCoefficient?: number, - mieDirectionalG?: number, - distance?: number, - inclination?: number, - azimuth?: number, - sunPosition?: Base.Vector3, - useSunPosition?: boolean, - cameraOffset?: Base.Vector3, - up?: Base.Vector3, - dithering?: boolean - ); - /** - * Defines the overall luminance of sky in interval ]0, 1[. - * @default 1 - * @minimum 0 - * @maximum 1 - * @step 0.01 - * - */ - luminance: number; - /** - * Defines the amount (scattering) of haze as opposed to molecules in atmosphere. - * @default 10 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - turbidity: number; - /** - * Defines the sky appearance (light intensity). - * @default 2 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - rayleigh: number; - /** - * Defines the mieCoefficient in interval [0, 0.1] which affects the property .mieDirectionalG. - * @default 0.005 - * @minimum 0 - * @maximum Infinity - * @step 0.001 - */ - mieCoefficient: number; - /** - * Defines the amount of haze particles following the Mie scattering theory. - * @default 0.8 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - mieDirectionalG: number; - /** - * Defines the distance of the sun according to the active scene camera. - * @default 500 - * @minimum 0 - * @maximum Infinity - * @step 10 - */ - distance: number; - /** - * Defines the sun inclination, in interval [-0.5, 0.5]. When the inclination is not 0, the sun is said - * "inclined". - * @default 0.49 - * @minimum -0.5 - * @maximum 0.5 - * @step 0.01 - */ - inclination: number; - /** - * Defines the solar azimuth in interval [0, 1]. The azimuth is the angle in the horizontal plan between - * an object direction and a reference direction. - * @default 0.25 - * @minimum 0 - * @maximum 1 - * @step 0.01 - */ - azimuth: number; - /** - * Defines the sun position in the sky on (x,y,z). If the property .useSunPosition is set to false, then - * the property is overridden by the inclination and the azimuth and can be read at any moment. - * @default undefined - * @optional true - */ - sunPosition: Base.Vector3; - /** - * Defines if the sun position should be computed (inclination and azimuth) according to the given - * .sunPosition property. - * @default false - */ - useSunPosition: boolean; - /** - * Defines an offset vector used to get a horizon offset. - * @example skyMaterial.cameraOffset.y = camera.globalPosition.y // Set horizon relative to 0 on the Y axis - * @default undefined - * @optional true - */ - cameraOffset: Base.Vector3; - /** - * Defines the vector the skyMaterial should consider as up. (default is Vector3(0, 1, 0) as returned by Vector3.Up()) - * @default [0, 1, 0] - */ - up: number[]; - /** - * Defines if sky should be dithered. - * @default false - */ - dithering: boolean; - } - class LuminanceDto { - constructor(material?: MATERIALS.SkyMaterial, luminance?: number); - /** - * Material to update - * @default undefined - */ - material: MATERIALS.SkyMaterial; - /** - * Defines the overall luminance of sky in interval ]0, 1[. - * @default 1 - * @minimum 0 - * @maximum 1 - * @step 0.01 - */ - luminance?: number; - } - class TurbidityDto { - constructor(material?: MATERIALS.SkyMaterial, turbidity?: number); - /** - * Material to update - * @default undefined - */ - material: MATERIALS.SkyMaterial; - /** - * Defines the amount (scattering) of haze as opposed to molecules in atmosphere. - * @default 10 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - turbidity?: number; - } - class RayleighDto { - constructor(material?: MATERIALS.SkyMaterial, rayleigh?: number); - /** - * Material to update - * @default undefined - */ - material: MATERIALS.SkyMaterial; - /** - * Defines the sky appearance (light intensity). - * @default 2 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - rayleigh?: number; - } - class MieCoefficientDto { - constructor(material?: MATERIALS.SkyMaterial, mieCoefficient?: number); - /** - * Material to update - * @default undefined - */ - material: MATERIALS.SkyMaterial; - /** - * Defines the mieCoefficient in interval [0, 0.1] which affects the property .mieDirectionalG. - * @default 0.005 - * @minimum 0 - * @maximum Infinity - * @step 0.001 - */ - mieCoefficient?: number; - } - class MieDirectionalGDto { - constructor(material?: MATERIALS.SkyMaterial, mieDirectionalG?: number); - /** - * Material to update - * @default undefined - */ - material: MATERIALS.SkyMaterial; - /** - * Defines the amount of haze particles following the Mie scattering theory. - * @default 0.8 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - mieDirectionalG?: number; - } - class DistanceDto { - constructor(material?: MATERIALS.SkyMaterial, distance?: number); - /** - * Material to update - * @default undefined - */ - material: MATERIALS.SkyMaterial; - /** - * Defines the distance of the sun according to the active scene camera. - * @default 500 - * @minimum 0 - * @maximum Infinity - * @step 10 - */ - distance?: number; - } - class InclinationDto { - constructor(material?: MATERIALS.SkyMaterial, inclination?: number); - /** - * Material to update - * @default undefined - */ - material: MATERIALS.SkyMaterial; - /** - * Defines the sun inclination, in interval [-0.5, 0.5]. When the inclination is not 0, the sun is said - * "inclined". - * @default 0.49 - * @minimum -0.5 - * @maximum 0.5 - * @step 0.01 - */ - inclination?: number; - } - class AzimuthDto { - constructor(material?: MATERIALS.SkyMaterial, azimuth?: number); - /** - * Material to update - * @default undefined - */ - material: MATERIALS.SkyMaterial; - /** - * Defines the solar azimuth in interval [0, 1]. The azimuth is the angle in the horizontal plan between - * an object direction and a reference direction. - * @default 0.25 - * @minimum 0 - * @maximum 1 - * @step 0.01 - */ - azimuth?: number; - } - class SunPositionDto { - constructor( - material?: MATERIALS.SkyMaterial, - sunPosition?: Base.Vector3 - ); - /** - * Material to update - * @default undefined - */ - material: MATERIALS.SkyMaterial; - /** - * Defines the sun position in the sky on (x,y,z). If the property .useSunPosition is set to false, then - * the property is overridden by the inclination and the azimuth and can be read at any moment. - * @default undefined - */ - sunPosition?: Base.Vector3; - } - class UseSunPositionDto { - constructor(material?: MATERIALS.SkyMaterial, useSunPosition?: boolean); - /** - * Material to update - * @default undefined - */ - material: MATERIALS.SkyMaterial; - /** - * Defines if the sun position should be computed (inclination and azimuth) according to the given - * .sunPosition property. - * @default false - */ - useSunPosition?: boolean; - } - class CameraOffsetDto { - constructor( - material?: MATERIALS.SkyMaterial, - cameraOffset?: Base.Vector3 - ); - /** - * Material to update - * @default undefined - */ - material: MATERIALS.SkyMaterial; - /** - * Defines an offset vector used to get a horizon offset. - * @example skyMaterial.cameraOffset.y = camera.globalPosition.y // Set horizon relative to 0 on the Y axis - * @default undefined - */ - cameraOffset?: Base.Vector3; - } - class UpDto { - constructor(material?: MATERIALS.SkyMaterial, up?: Base.Vector3); - /** - * Material to update - * @default undefined - */ - material: MATERIALS.SkyMaterial; - /** - * Defines the vector the skyMaterial should consider as up. (default is Vector3(0, 1, 0) as returned by Vector3.Up()) - * @default undefined - */ - up?: Base.Vector3; - } - class DitheringDto { - constructor(material?: MATERIALS.SkyMaterial, dithering?: boolean); - /** - * Material to update - * @default undefined - */ - material: MATERIALS.SkyMaterial; - /** - * Defines if sky should be dithered. - * @default false - */ - dithering?: boolean; - } - } - declare namespace BabylonMeshBuilder { - class CreateBoxDto { - constructor( - width?: number, - depth?: number, - height?: number, - sideOrientation?: BabylonMesh.sideOrientationEnum, - enableShadows?: boolean - ); - /** - * Width of the box - * @default 1 - */ - width: number; - /** - * Depth of the box - * @default 1 - */ - depth: number; - /** - * Height of the box - * @default 1 - */ - height: number; - /** - * Side orientation of the mesh - * @default frontside - */ - sideOrientation: BabylonMesh.sideOrientationEnum; - /** - * Enables shadows for the mesh - * @default true - */ - enableShadows: boolean; - } - class CreateCubeDto { - constructor( - size?: number, - sideOrientation?: BabylonMesh.sideOrientationEnum, - enableShadows?: boolean - ); - /** - * Size of the cube - * @default 1 - */ - size: number; - /** - * Side orientation of the mesh - * @default frontside - */ - sideOrientation: BabylonMesh.sideOrientationEnum; - /** - * Enables shadows for the mesh - * @default true - */ - enableShadows: boolean; - } - class CreateSquarePlaneDto { - constructor( - size?: number, - sideOrientation?: BabylonMesh.sideOrientationEnum, - enableShadows?: boolean - ); - /** - * Size of the square plane - * @default 1 - */ - size: number; - /** - * Side orientation of the mesh - * @default frontside - */ - sideOrientation: BabylonMesh.sideOrientationEnum; - /** - * Enables shadows for the mesh - * @default true - */ - enableShadows: boolean; - } - class CreateSphereDto { - constructor( - diameter?: number, - segments?: number, - sideOrientation?: BabylonMesh.sideOrientationEnum, - enableShadows?: boolean - ); - /** - * Diameter of the sphere - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - diameter: number; - /** - * Segments of the sphere - * @default 32 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - segments: number; - /** - * Side orientation of the mesh - * @default frontside - */ - sideOrientation: BabylonMesh.sideOrientationEnum; - /** - * Enables shadows for the mesh - * @default true - */ - enableShadows: boolean; - } - class CreateIcoSphereDto { - constructor( - radius?: number, - radiusX?: number, - radiusY?: number, - radiusZ?: number, - flat?: boolean, - subdivisions?: number, - sideOrientation?: BabylonMesh.sideOrientationEnum, - enableShadows?: boolean - ); - /** - * Radius of the ico sphere - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - radius: number; - /** - * Radius X of the ico sphere - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - radiusX: number; - /** - * Radius Y of the ico sphere - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - radiusY: number; - /** - * Radius Z of the ico sphere - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - radiusZ: number; - /** - * Flat of the ico sphere - * @default false - */ - flat: boolean; - /** - * Subdivisions of the ico sphere - * @default 4 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - subdivisions: number; - /** - * Side orientation of the mesh - * @default frontside - */ - sideOrientation: BabylonMesh.sideOrientationEnum; - /** - * Enables shadows for the mesh - * @default true - */ - enableShadows: boolean; - } - class CreateDiscDto { - constructor( - radius?: number, - tessellation?: number, - sideOrientation?: BabylonMesh.sideOrientationEnum, - enableShadows?: boolean - ); - /** - * Radius of the disc - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - radius: number; - /** - * Tessellation of the disc - * @default 32 - * @minimum 3 - * @maximum Infinity - * @step 1 - */ - tessellation: number; - /** - * Arc between 0 and 1 - * @default 1 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - arc: number; - /** - * Side orientation of the mesh - * @default frontside - */ - sideOrientation: BabylonMesh.sideOrientationEnum; - /** - * Enables shadows for the mesh - * @default true - */ - enableShadows: boolean; - } - class CreateRibbonDto { - constructor( - pathArray?: Base.Vector3[][], - closeArray?: boolean, - closePath?: boolean, - offset?: number, - updatable?: boolean, - sideOrientation?: BabylonMesh.sideOrientationEnum, - enableShadows?: boolean - ); - /** - * Path array of the ribbon - */ - pathArray: Base.Vector3[][]; - /** - * Close array of the ribbon - * @default false - */ - closeArray: boolean; - /** - * Close path of the ribbon - * @default false - */ - closePath: boolean; - /** - * Offset of the ribbon - * @default 0 - */ - offset: number; - /** - * Updateable - * @default false - */ - updatable: boolean; - /** - * Side orientation of the mesh - * @default frontside - */ - sideOrientation: BabylonMesh.sideOrientationEnum; - /** - * Enables shadows for the mesh - * @default true - */ - enableShadows: boolean; - } - class CreateTorusDto { - constructor( - diameter?: number, - thickness?: number, - tessellation?: number, - sideOrientation?: BabylonMesh.sideOrientationEnum, - enableShadows?: boolean - ); - /** - * Diameter of the torus - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - diameter: number; - /** - * Thickness of the torus - * @default 0.5 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - thickness: number; - /** - * Tessellation of the torus - * @default 32 - * @minimum 3 - * @maximum Infinity - * @step 1 - */ - tessellation: number; - /** - * Side orientation of the mesh - * @default frontside - */ - sideOrientation: BabylonMesh.sideOrientationEnum; - /** - * Enables shadows for the mesh - * @default true - */ - enableShadows: boolean; - } - class CreateTorusKnotDto { - constructor( - radius?: number, - tube?: number, - radialSegments?: number, - tubularSegments?: number, - p?: number, - q?: number, - sideOrientation?: BabylonMesh.sideOrientationEnum, - enableShadows?: boolean - ); - /** - * Radius of the torus knot - * @default 2 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - radius: number; - /** - * Tube of the torus knot - * @default 0.5 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - tube: number; - /** - * Radial segments of the torus knot - * @default 128 - * @minimum 3 - * @maximum Infinity - * @step 1 - */ - radialSegments: number; - /** - * Tubular segments of the torus knot - * @default 32 - * @minimum 3 - * @maximum Infinity - * @step 1 - */ - tubularSegments: number; - /** - * P of the torus knot - * @default 2 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - p: number; - /** - * Q of the torus knot - * @default 3 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - q: number; - /** - * Side orientation of the mesh - * @default frontside - */ - sideOrientation: BabylonMesh.sideOrientationEnum; - /** - * Enables shadows for the mesh - * @default true - */ - enableShadows: boolean; - } - class CreatePolygonDto { - constructor( - shape?: Base.Vector3[], - holes?: Base.Vector3[][], - depth?: number, - smoothingThreshold?: number, - sideOrientation?: BabylonMesh.sideOrientationEnum, - wrap?: boolean, - enableShadows?: boolean - ); - /** - * Shape of the polygon - */ - shape: Base.Vector3[]; - /** - * Holes of the polygon - * @optional true - */ - holes?: Base.Vector3[][]; - /** - * Depth of the polygon - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - depth: number; - /** - * Smoothing threshold of the polygon - * @default 0.01 - * @minimum 0 - * @maximum 1 - * @step 0.01 - */ - smoothingThreshold: number; - /** - * Side orientation of the mesh - * @default frontside - */ - sideOrientation: BabylonMesh.sideOrientationEnum; - /** - * Wrap of the polygon - * @default false - */ - wrap: boolean; - /** - * Enables shadows for the mesh - * @default true - */ - enableShadows: boolean; - } - class ExtrudePolygonDto { - constructor( - shape?: Base.Vector3[], - holes?: Base.Vector3[][], - depth?: number, - sideOrientation?: BabylonMesh.sideOrientationEnum, - wrap?: boolean, - enableShadows?: boolean - ); - /** - * Shape of the extrude - */ - shape: Base.Vector3[]; - /** - * Holes of the extrude - * @optional true - */ - holes?: Base.Vector3[][]; - /** - * Depth of the extrude - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - depth: number; - /** - * Side orientation of the mesh - * @default frontside - */ - sideOrientation: BabylonMesh.sideOrientationEnum; - /** - * Wrap of the extrude - * @default false - */ - wrap: boolean; - /** - * Enables shadows for the mesh - * @default true - */ - enableShadows: boolean; - } - class CreatePolyhedronDto { - constructor( - size?: number, - type?: number, - sizeX?: number, - sizeY?: number, - sizeZ?: number, - custom?: number[], - flat?: boolean, - sideOrientation?: BabylonMesh.sideOrientationEnum, - enableShadows?: boolean - ); - /** - * Size of the polyhedron - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - size: number; - /** - * Type of the polyhedron - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - type: number; - /** - * Size X of the polyhedron - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - sizeX: number; - /** - * Size Y of the polyhedron - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - sizeY: number; - /** - * Size Z of the polyhedron - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - sizeZ: number; - /** - * Custom polyhedron - * @optional true - */ - custom?: number[]; - /** - * Flat polyhedron - * @default false - */ - flat: boolean; - /** - * Side orientation of the mesh - * @default frontside - */ - sideOrientation: BabylonMesh.sideOrientationEnum; - /** - * Enables shadows for the mesh - * @default true - */ - enableShadows: boolean; - } - class CreateGeodesicDto { - constructor( - m?: number, - n?: number, - size?: number, - sizeX?: number, - sizeY?: number, - sizeZ?: number, - flat?: boolean, - subdivisions?: number, - sideOrientation?: BabylonMesh.sideOrientationEnum, - enableShadows?: boolean - ); - /** - * M of the geodesic - * @default 4 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - m: number; - /** - * N of the geodesic - * @default 4 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - n: number; - /** - * Size of the geodesic - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - size: number; - /** - * Size X of the geodesic - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - sizeX: number; - /** - * Size Y of the geodesic - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - sizeY: number; - /** - * Size Z of the geodesic - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - sizeZ: number; - /** - * Flat - * @default false - */ - flat: boolean; - /** - * Subdivisions of the geodesic - * @default 4 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - subdivisions: number; - /** - * Side orientation of the mesh - * @default frontside - */ - sideOrientation: BabylonMesh.sideOrientationEnum; - /** - * Enables shadows for the mesh - * @default true - */ - enableShadows: boolean; - } - class CreateCapsuleDto { - constructor( - orientation?: Base.Vector3, - subdivisions?: number, - tessellation?: number, - height?: number, - radius?: number, - capSubdivisions?: number, - radiusTop?: number, - radiusBottom?: number, - topCapSubdivisions?: number, - bottomCapSubdivisions?: number, - sideOrientation?: BabylonMesh.sideOrientationEnum, - enableShadows?: boolean - ); - /** - * Orientation of the capsule - */ - orientation: Base.Vector3; - /** - * Subdivisions of the capsule - * @default 2 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - subdivisions: number; - /** - * Tessellation of the capsule - * @default 16 - * @minimum 3 - * @maximum Infinity - * @step 1 - */ - tessellation: number; - /** - * Height of the capsule - * @default 2 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - height: number; - /** - * Radius of the capsule - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - radius: number; - /** - * Cap subdivisions of the capsule - * @default 6 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - capSubdivisions: number; - /** - * Radius top of the capsule - * @default 0.5 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - radiusTop: number; - /** - * Radius bottom of the capsule - * @default 0.5 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - radiusBottom: number; - /** - * Top cap subdivisions of the capsule - * @default 6 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - topCapSubdivisions: number; - /** - * Bottom cap subdivisions of the capsule - * @default 6 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - bottomCapSubdivisions: number; - /** - * Side orientation of the mesh - * @default doubleside - */ - sideOrientation: BabylonMesh.sideOrientationEnum; - /** - * Enables shadows for the mesh - * @default true - */ - enableShadows: boolean; - } - class CreateGoldbergDto { - constructor( - m?: number, - n?: number, - size?: number, - sizeX?: number, - sizeY?: number, - sizeZ?: number, - sideOrientation?: BabylonMesh.sideOrientationEnum, - enableShadows?: boolean - ); - /** - * M of the goldberg - * @default 4 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - m: number; - /** - * N of the goldberg - * @default 4 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - n: number; - /** - * Size of the goldberg - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - size: number; - /** - * Size X of the goldberg - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - sizeX: number; - /** - * Size Y of the goldberg - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - sizeY: number; - /** - * Size Z of the goldberg - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - sizeZ: number; - /** - * Side orientation of the mesh - * @default doubleside - */ - sideOrientation: BabylonMesh.sideOrientationEnum; - /** - * Enables shadows for the mesh - * @default true - */ - enableShadows: boolean; - } - class CreateTubeDto { - constructor( - path?: Base.Vector3[], - radius?: number, - tessellation?: number, - cap?: number, - arc?: number, - sideOrientation?: BabylonMesh.sideOrientationEnum, - enableShadows?: boolean - ); - /** - * Path of the tube - * @default undefined - */ - path: Base.Vector3[]; - /** - * Radius of the tube - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - radius: number; - /** - * Tessellation of the tube - * @default 32 - * @minimum 3 - * @maximum Infinity - * @step 1 - */ - tessellation: number; - /** - * Cap of the tube - * @default 0 - * @minimum 0 - * @maximum 3 - * @step 1 - */ - cap: number; - /** - * Arc of the tube - * @default 1 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - arc: number; - /** - * Side orientation of the mesh - * @default doubleside - */ - sideOrientation: BabylonMesh.sideOrientationEnum; - /** - * Enables shadows for the mesh - * @default true - */ - enableShadows: boolean; - } - class CreateExtrudedShapeDto { - constructor( - shape?: Base.Vector3[], - path?: Base.Vector3[], - scale?: number, - rotation?: number, - cap?: number, - sideOrientation?: BabylonMesh.sideOrientationEnum, - enableShadows?: boolean - ); - /** - * Shape of the extrude - */ - shape: Base.Vector3[]; - /** - * Path of the extrude - */ - path: Base.Vector3[]; - /** - * Scale of the extrude - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - scale: number; - /** - * Rotation of the extrude - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - rotation: number; - /** - * Close shape of the extrude - * @default false - */ - closeShape: boolean; - /** - * Close path of the extrude - * @default false - */ - closePath: boolean; - /** - * Cap of the extrude - * @default 0 - * @minimum 0 - * @maximum 3 - * @step 1 - */ - cap: number; - /** - * Side orientation of the mesh - * @default doubleside - */ - sideOrientation: BabylonMesh.sideOrientationEnum; - /** - * Enables shadows for the mesh - * @default true - */ - enableShadows: boolean; - } - class CreateCylinderDto { - constructor( - height?: number, - diameterTop?: number, - diameterBottom?: number, - tessellation?: number, - subdivisions?: number, - sideOrientation?: BabylonMesh.sideOrientationEnum, - enableShadows?: boolean - ); - /** - * Height of the cylinder - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - height: number; - /** - * Diameter top of the cylinder - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - diameterTop: number; - /** - * Diameter bottom of the cylinder - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - diameterBottom: number; - /** - * Tessellation of the cylinder - * @default 64 - * @minimum 3 - * @maximum Infinity - * @step 1 - */ - tessellation: number; - /** - * Subdivisions of the cylinder - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - subdivisions: number; - /** - * Side orientation of the mesh - * @default doubleside - */ - sideOrientation: BabylonMesh.sideOrientationEnum; - /** - * Enables shadows for the mesh - * @default true - */ - enableShadows: boolean; - } - class CreateLatheDto { - constructor( - shape?: Base.Vector3[], - radius?: number, - tessellation?: number, - arc?: number, - closed?: boolean, - sideOrientation?: BabylonMesh.sideOrientationEnum, - enableShadows?: boolean - ); - /** - * Shape of the lathe - */ - shape: Base.Vector3[]; - /** - * Radius of the lathe - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - radius: number; - /** - * Tessellation of the lathe - * @default 64 - * @minimum 3 - * @maximum Infinity - * @step 1 - */ - tessellation: number; - /** - * Arc of the lathe - * @default 1 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - arc: number; - /** - * Should lathe be closed - * @default true - */ - closed: boolean; - /** - * Side orientation of the mesh - * @default doubleside - */ - sideOrientation: BabylonMesh.sideOrientationEnum; - /** - * Enables shadows for the mesh - * @default true - */ - enableShadows: boolean; - } - class CreateGroundDto { - constructor( - width?: number, - height?: number, - subdivisionsX?: number, - subdivisionsY?: number, - sideOrientation?: BabylonMesh.sideOrientationEnum, - enableShadows?: boolean - ); - /** - * Width of the ground - * @default 10 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - width: number; - /** - * Height of the ground - * @default 10 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - height: number; - /** - * Subdivisions X of the ground - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - subdivisionsX: number; - /** - * Subdivisions Y of the ground - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - subdivisionsY: number; - /** - * Side orientation of the mesh - * @default doubleside - */ - sideOrientation: BabylonMesh.sideOrientationEnum; - /** - * Enables shadows for the mesh - * @default true - */ - enableShadows: boolean; - } - class CreateRectanglePlaneDto { - constructor( - width?: number, - height?: number, - sideOrientation?: BabylonMesh.sideOrientationEnum, - enableShadows?: boolean - ); - /** - * Width of the rectangle plane - * @default 1 - */ - width: number; - /** - * Height of the rectangle plane - * @default 1 - */ - height: number; - /** - * Side orientation of the mesh - * @default doubleside - */ - sideOrientation: BabylonMesh.sideOrientationEnum; - /** - * Enables shadows for the mesh - * @default true - */ - enableShadows: boolean; - } - } - declare namespace BabylonMesh { - enum sideOrientationEnum { - frontside = "frontside", - backside = "backside", - doubleside = "doubleside", - } - class UpdateDrawnBabylonMesh { - constructor( - babylonMesh?: BABYLON.Mesh, - position?: Base.Point3, - rotation?: Base.Vector3, - scaling?: Base.Vector3, - colours?: string | string[] - ); - /** - * Babylon Mesh that needs to be updated - * @default undefined - */ - babylonMesh: BABYLON.Mesh; - /** - * Position to place the mesh into - * @default undefined - */ - position: Base.Point3; - /** - * Rotation for the mesh - * @default undefined - */ - rotation: Base.Vector3; - /** - * Scale mesh to certain value - * @default undefined - */ - scaling: Base.Vector3; - /** - * Colours or a single colour to change - * @default undefined - */ - colours: string | string[]; - } - class SetParentDto { - constructor( - babylonMesh?: - | BABYLON.Mesh - | BABYLON.InstancedMesh - | BABYLON.AbstractMesh, - parentMesh?: - | BABYLON.Mesh - | BABYLON.InstancedMesh - | BABYLON.AbstractMesh - ); - /** - * BabylonJS Mesh that needs to change it's parent - * @default undefined - */ - babylonMesh: - | BABYLON.Mesh - | BABYLON.InstancedMesh - | BABYLON.AbstractMesh; - /** - * BabylonJS Mesh to use as a parent - * @default undefined - */ - parentMesh: BABYLON.Mesh | BABYLON.InstancedMesh | BABYLON.AbstractMesh; - } - class UpdateDrawnBabylonMeshPositionDto { - constructor( - babylonMesh?: BABYLON.Mesh | BABYLON.InstancedMesh, - position?: Base.Point3 - ); - /** - * Babylon Mesh that needs to be updated - * @default undefined - */ - babylonMesh: BABYLON.Mesh | BABYLON.InstancedMesh; - /** - * Position to place the mesh into - * @default undefined - */ - position: Base.Point3; - } - class UpdateDrawnBabylonMeshRotationDto { - constructor( - babylonMesh?: BABYLON.Mesh | BABYLON.InstancedMesh, - rotation?: Base.Vector3 - ); - /** - * Babylon Mesh that needs to be updated - * @default undefined - */ - babylonMesh: BABYLON.Mesh | BABYLON.InstancedMesh; - /** - * Rotation for the mesh - * @default undefined - */ - rotation: Base.Vector3; - } - class UpdateDrawnBabylonMeshScaleDto { - constructor( - babylonMesh?: BABYLON.Mesh | BABYLON.InstancedMesh, - scale?: Base.Vector3 - ); - /** - * Babylon Mesh that needs to be updated - * @default undefined - */ - babylonMesh: BABYLON.Mesh | BABYLON.InstancedMesh; - /** - * Scale for the mesh - * @default undefined - */ - scale: Base.Vector3; - } - class ScaleInPlaceDto { - constructor( - babylonMesh?: BABYLON.Mesh | BABYLON.InstancedMesh, - scale?: number - ); - /** - * Babylon Mesh that needs to be updated - * @default undefined - */ - babylonMesh: BABYLON.Mesh | BABYLON.InstancedMesh; - /** - * factor for the scale - * @default 1 - */ - scale: number; - } - class IntersectsMeshDto { - constructor( - babylonMesh?: BABYLON.Mesh | BABYLON.InstancedMesh, - babylonMesh2?: BABYLON.Mesh | BABYLON.InstancedMesh, - precise?: boolean, - includeDescendants?: boolean - ); - /** - * Babylon Mesh that needs to be updated - * @default undefined - */ - babylonMesh: BABYLON.Mesh | BABYLON.InstancedMesh; - /** - * Babylon Mesh that needs to be updated - * @default undefined - */ - babylonMesh2: BABYLON.Mesh | BABYLON.InstancedMesh; - /** - * Should check precisely - * @default false - */ - precise: boolean; - /** - * Check descendant intersections as well - * @default false - */ - includeDescendants: boolean; - } - class IntersectsPointDto { - constructor( - babylonMesh?: BABYLON.Mesh | BABYLON.InstancedMesh, - point?: Base.Point3 - ); - /** - * Babylon Mesh that needs to be updated - * @default undefined - */ - babylonMesh: BABYLON.Mesh | BABYLON.InstancedMesh; - /** - * point - * @default undefined - */ - point: Base.Point3; - } - class BabylonMeshDto { - constructor(babylonMesh?: BABYLON.Mesh); - /** - * BabylonJS mesh - * @default undefined - */ - babylonMesh: BABYLON.Mesh; - } - class CloneToPositionsDto { - constructor(babylonMesh?: BABYLON.Mesh, positions?: Base.Point3[]); - /** - * BabylonJS mesh - * @default undefined - */ - babylonMesh: BABYLON.Mesh; - /** - * positions to clone to - * @default [] - */ - positions: Base.Point3[]; - } - class MergeMeshesDto { - constructor( - arrayOfMeshes?: BABYLON.Mesh[], - disposeSource?: boolean, - allow32BitsIndices?: boolean, - meshSubclass?: BABYLON.Mesh, - subdivideWithSubMeshes?: boolean, - multiMultiMaterials?: boolean - ); - /** - * meshes array of meshes with the vertices to merge. Entries cannot be empty meshes. - * @default undefined - */ - arrayOfMeshes: BABYLON.Mesh[]; - /** - * disposeSource when true (default), dispose of the vertices from the source meshes. - * @default true - */ - disposeSource: boolean; - /** - * allow32BitsIndices when the sum of the vertices > 64k, this must be set to true. - * @default false - */ - allow32BitsIndices: boolean; - /** - * meshSubclass (optional) can be set to a Mesh where the merged vertices will be inserted. - * @default undefined - * @optional true - */ - meshSubclass?: BABYLON.Mesh; - /** - * subdivideWithSubMeshes when true (false default), subdivide mesh into subMeshes. - * @default false - */ - subdivideWithSubMeshes: boolean; - /** - * multiMultiMaterials when true (false default), subdivide mesh into subMeshes with multiple materials, ignores subdivideWithSubMeshes. - * @default false - */ - multiMultiMaterials: boolean; - } - class BabylonMeshWithChildrenDto { - constructor(babylonMesh?: BABYLON.Mesh); - /** - * BabylonJS mesh - * @default undefined - */ - babylonMesh: BABYLON.Mesh; - /** - * Include children when performing action - * @default true - */ - includeChildren: boolean; - } - class ShowHideMeshDto { - constructor(babylonMesh?: BABYLON.Mesh, includeChildren?: boolean); - /** - * BabylonJS mesh - * @default undefined - */ - babylonMesh: BABYLON.Mesh; - /** - * Include children when showing hiding - * @default true - */ - includeChildren: boolean; - } - class CloneBabylonMeshDto { - constructor(babylonMesh?: BABYLON.Mesh); - /** - * BabylonJS mesh - * @default undefined - */ - babylonMesh: BABYLON.Mesh; - } - class ChildMeshesBabylonMeshDto { - constructor( - babylonMesh?: BABYLON.Mesh, - directDescendantsOnly?: boolean - ); - /** - * BabylonJS mesh - * @default undefined - */ - babylonMesh: BABYLON.Mesh; - /** - * Include only direct descendants - * @default false - */ - directDescendantsOnly: boolean; - } - class TranslateBabylonMeshDto { - constructor(babylonMesh?: BABYLON.Mesh, distance?: number); - /** - * BabylonJS mesh - * @default undefined - */ - babylonMesh: BABYLON.Mesh; - /** - * distance to translate - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 1 - */ - distance: number; - } - class NameBabylonMeshDto { - constructor( - babylonMesh?: BABYLON.Mesh, - name?: string, - includeChildren?: boolean - ); - /** - * BabylonJS mesh - * @default undefined - * - */ - babylonMesh?: BABYLON.Mesh; - /** - * name of the mesh - * @default undefined - */ - name: string; - /** - * Set name also on children - * @default false - */ - includeChildren?: boolean; - } - class ByNameBabylonMeshDto { - constructor(name?: string); - /** - * name of the mesh - * @default undefined - */ - name: string; - } - class MaterialBabylonMeshDto { - constructor( - babylonMesh?: BABYLON.Mesh, - material?: BABYLON.Material, - includeChildren?: boolean - ); - /** - * BabylonJS mesh - * @default undefined - */ - babylonMesh?: BABYLON.Mesh; - /** - * material of the mesh - * @default undefined - */ - material: BABYLON.Material; - /** - * Set material on children also - * @default false - */ - includeChildren: boolean; - } - class IdBabylonMeshDto { - constructor(babylonMesh?: BABYLON.Mesh, id?: string); - /** - * BabylonJS mesh - * @default undefined - */ - babylonMesh?: BABYLON.Mesh; - /** - * id of the mesh - * @default undefined - */ - id: string; - } - class ByIdBabylonMeshDto { - constructor(id?: string); - /** - * id of the mesh - * @default undefined - */ - id: string; - } - class UniqueIdBabylonMeshDto { - constructor(uniqueId?: number); - /** - * Unique id of the mesh - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 1 - */ - uniqueId: number; - } - class PickableBabylonMeshDto { - constructor( - babylonMesh?: BABYLON.Mesh, - pickable?: boolean, - includeChildren?: boolean - ); - /** - * BabylonJS mesh - * @default undefined - */ - babylonMesh: BABYLON.Mesh; - /** - * Pickable - * @default false - */ - pickable: boolean; - /** - * Apply set to children also - * @default false - */ - includeChildren: boolean; - } - class CheckCollisionsBabylonMeshDto { - constructor( - babylonMesh?: BABYLON.Mesh, - checkCollisions?: boolean, - includeChildren?: boolean - ); - /** - * BabylonJS mesh - * @default undefined - */ - babylonMesh: BABYLON.Mesh; - /** - * Check collisions - * @default false - */ - checkCollisions: boolean; - /** - * Apply set to children also - * @default false - */ - includeChildren: boolean; - } - class RotateBabylonMeshDto { - constructor(babylonMesh?: BABYLON.Mesh, rotate?: number); - /** - * BabylonJS mesh - * @default undefined - */ - babylonMesh: BABYLON.Mesh; - /** - * rotate to translate - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 1 - */ - rotate: number; - } - class SetMeshVisibilityDto { - constructor( - babylonMesh?: BABYLON.Mesh, - visibility?: number, - includeChildren?: boolean - ); - /** - * BabylonJS mesh - * @default undefined - */ - babylonMesh: BABYLON.Mesh; - /** - * Shows mesh if 0 and shows if 1 - * @default 0 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - visibility: number; - /** - * Include children - * @default false - */ - includeChildren: boolean; - } - class MeshInstanceAndTransformDto { - constructor( - mesh?: BABYLON.Mesh, - position?: Base.Point3, - rotation?: Base.Vector3, - scaling?: Base.Vector3 - ); - /** - * BabylonJS mesh - * @default undefined - */ - mesh: BABYLON.Mesh; - /** - * Position - * @default undefined - */ - position: Base.Point3; - /** - * Rotation - * @default undefined - */ - rotation: Base.Vector3; - /** - * Scaling - * @default undefined - */ - scaling: Base.Vector3; - } - class MeshInstanceDto { - constructor(mesh?: BABYLON.Mesh); - /** - * BabylonJS mesh - * @default undefined - */ - mesh: BABYLON.Mesh; - } - class RotateAroundAxisNodeDto { - constructor( - mesh?: BABYLON.Mesh, - position?: Base.Point3, - axis?: Base.Vector3, - angle?: number - ); - /** - * BabylonJS mesh - * @default undefined - */ - mesh: BABYLON.Mesh; - /** - * Position vector expressed in [x, y, z] vector array - */ - position: Base.Point3; - /** - * Rotate around the axis expressed in [x, y, z] vector array - */ - axis: Base.Vector3; - /** - * The rotation angle expressed in degrees - */ - angle: number; - } - } - declare namespace BabylonPick { - class RayDto { - constructor(ray?: BABYLON.Ray); - /** - * Ray - */ - ray: BABYLON.Ray; - } - class PickInfo { - constructor(pickInfo?: BABYLON.PickingInfo); - /** - * Information about picking result - */ - pickInfo: BABYLON.PickingInfo; - } - } - declare namespace BabylonRay { - class BaseRayDto { - constructor( - origin?: Base.Point3, - direction?: Base.Vector3, - length?: number - ); - /** - * Origin of the ray - */ - origin: Base.Point3; - /** - * Direction of the ray - */ - direction: Base.Vector3; - /** - * Length of the ray - */ - length?: number; - } - class RayDto { - constructor(ray?: BABYLON.Ray); - /** - * ray to analyze - */ - ray: BABYLON.Ray; - } - class FromToDto { - constructor(from?: Base.Point3, to?: Base.Point3); - /** - * From point - */ - from: Base.Point3; - /** - * To point - */ - to: Base.Point3; - } - } - declare namespace BabylonTexture { - enum samplingModeEnum { - nearest = "nearest", - bilinear = "bilinear", - trilinear = "trilinear", - } - class TextureSimpleDto { - constructor( - name?: string, - url?: string, - invertY?: boolean, - invertZ?: boolean, - wAng?: number, - uScale?: number, - vScale?: number, - uOffset?: number, - vOffset?: number, - samplingMode?: samplingModeEnum - ); - /** - * Name of the material - * @default Custom Texture - */ - name: string; - /** - * Url of the texture - * @default undefined - */ - url: string; - /** - * Invert texture on Y direction - * @default false - */ - invertY: boolean; - /** - * Invert texture on Z direction - * @default false - */ - invertZ: boolean; - /** - * W angle of the texture - * @default 0 - */ - wAng: number; - /** - * U scale of the texture - * @default 1 - */ - uScale: number; - /** - * V scale of the texture - * @default 1 - */ - vScale: number; - /** - * U offset of the texture - * @default 0 - */ - uOffset: number; - /** - * V offset of the texture - * @default 0 - */ - vOffset: number; - /** - * The sampling mode of the texture - * @default nearest - */ - samplingMode: samplingModeEnum; - } - } - declare namespace BabylonTools { - class ScreenshotDto { - constructor( - camera?: BABYLON.Camera, - width?: number, - height?: number, - mimeType?: string, - quality?: number - ); - /** - * Camera to be used. If not set, active camera will be used - * @default undefined - */ - camera: BABYLON.Camera; - /** - * width of the screenshot - * @default 1920 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - width: number; - /** - * height of the screenshot - * @default 1080 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - height: number; - /** - * The mime type - * @default image/png - */ - mimeType: string; - /** - * quality of the screenshot - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - quality: number; - } - } - declare namespace BabylonTransforms { - class RotationCenterAxisDto { - constructor(angle?: number, axis?: Base.Vector3, center?: Base.Point3); - /** - * Angle of rotation in degrees - * @default 90 - * @minimum -Infinity - * @maximum Infinity - * @step 1 - */ - angle: number; - /** - * Axis vector for rotation - * @default [0, 1, 0] - */ - axis: Base.Vector3; - /** - * The center from which the axis is pointing - * @default [0, 0, 0] - */ - center: Base.Point3; - } - class TransformBabylonMeshDto { - constructor( - mesh?: BABYLON.Mesh, - transformation?: Base.TransformMatrixes - ); - /** - * Mesh to transform - * @default undefined - */ - mesh: BABYLON.Mesh; - /** - * Transformation(s) to apply - * @default undefined - */ - transformation: Base.TransformMatrixes; - } - class RotationCenterDto { - constructor(angle?: number, center?: Base.Point3); - /** - * Angle of rotation in degrees - * @default 90 - * @minimum -Infinity - * @maximum Infinity - * @step 1 - */ - angle: number; - /** - * The center from which the axis is pointing - * @default [0, 0, 0] - */ - center: Base.Point3; - } - class RotationCenterYawPitchRollDto { - constructor( - yaw?: number, - pitch?: number, - roll?: number, - center?: Base.Point3 - ); - /** - * Yaw angle (Rotation around X) in degrees - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 1 - */ - yaw: number; - /** - * Pitch angle (Rotation around Y) in degrees - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 1 - */ - pitch: number; - /** - * Roll angle (Rotation around Z) in degrees - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 1 - */ - roll: number; - /** - * The center from which the rotations are applied - * @default [0, 0, 0] - */ - center: Base.Point3; - } - class ScaleXYZDto { - constructor(scaleXyz?: Base.Vector3); - /** - * Scaling factors for each axis [1, 2, 1] means that Y axis will be scaled 200% and both x and z axis will remain on 100% - * @default [1, 1, 1] - */ - scaleXyz: Base.Vector3; - } - class ScaleCenterXYZDto { - constructor(center?: Base.Point3, scaleXyz?: Base.Vector3); - /** - * The center from which the scaling is applied - * @default [0, 0, 0] - */ - center: Base.Point3; - /** - * Scaling factors for each axis [1, 2, 1] means that Y axis will be scaled 200% and both x and z axis will remain on 100% - * @default [1, 1, 1] - */ - scaleXyz: Base.Vector3; - } - class UniformScaleDto { - constructor(scale?: number); - /** - * Uniform scale factor for all x, y, z directions. 1 will keep everything on original size, 2 will scale 200%; - * @default 1 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - scale: number; - } - class UniformScaleFromCenterDto { - constructor(scale?: number, center?: Base.Point3); - /** - * Scale factor for all x, y, z directions. 1 will keep everything on original size, 2 will scale 200%; - * @default 1 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - scale: number; - /** - * Center position of the scaling - * @default [0, 0, 0] - */ - center: Base.Point3; - } - class TranslationXYZDto { - constructor(translation?: Base.Vector3); - /** - * Translation vector with [x, y, z] distances - * @default [0, 0, 0] - */ - translation: Base.Vector3; - } - class TranslationsXYZDto { - constructor(translations?: Base.Vector3[]); - /** - * Translation vectors with [x, y, z] distances - * @default undefined - */ - translations: Base.Vector3[]; - } - } - declare namespace BabylonWebXR { - class WebXRDefaultExperienceOptions { - constructor(disableDefaultUI?: boolean); - /** - * Enable or disable default UI to enter XR - * @optional true - */ - disableDefaultUI?: boolean; - /** - * Should pointer selection not initialize. - * Note that disabling pointer selection also disables teleportation. - * Defaults to false. - * @optional true - */ - disablePointerSelection?: boolean; - /** - * Should teleportation not initialize. Defaults to false. - * @optional true - */ - disableTeleportation?: boolean; - /** - * Should nearInteraction not initialize. Defaults to false. - * @optional true - */ - disableNearInteraction?: boolean; - /** - * Should hand tracking be disabled. Defaults to false. - * @optional true - */ - disableHandTracking?: boolean; - /** - * Floor meshes that will be used for teleport - * @optional true - */ - floorMeshes?: BABYLON.AbstractMesh[]; - /** - * If set to true, the first frame will not be used to reset position - * The first frame is mainly used when copying transformation from the old camera - * Mainly used in AR - * @optional true - */ - ignoreNativeCameraTransformation?: boolean; - /** - * Optional configuration for the XR input object - * @optional true - */ - inputOptions?: Partial; - /** - * optional configuration for pointer selection - * @optional true - */ - pointerSelectionOptions?: Partial; - /** - * optional configuration for near interaction - * @optional true - */ - nearInteractionOptions?: Partial; - /** - * optional configuration for hand tracking - * @optional true - */ - handSupportOptions?: Partial; - /** - * optional configuration for teleportation - * @optional true - */ - teleportationOptions?: Partial; - /** - * optional configuration for the output canvas - * @optional true - */ - outputCanvasOptions?: BABYLON.WebXRManagedOutputCanvasOptions; - /** - * optional UI options. This can be used among other to change session mode and reference space type - * @optional true - */ - uiOptions?: Partial; - /** - * When loading teleportation and pointer select, use stable versions instead of latest. - * @optional true - */ - useStablePlugins?: boolean; - /** - * An optional rendering group id that will be set globally for teleportation, pointer selection and default controller meshes - * @optional true - */ - renderingGroupId?: number; - /** - * A list of optional features to init the session with - * If set to true, all features we support will be added - * @optional true - */ - optionalFeatures?: boolean | string[]; - } - class DefaultWebXRWithTeleportationDto { - constructor(groundMeshes?: BABYLON.Mesh[]); - /** - * Create XR experience with ground meshes - */ - groundMeshes: BABYLON.Mesh[]; - } - class WebXRDefaultExperienceDto { - constructor(webXRDefaultExperience?: BABYLON.WebXRDefaultExperience); - /** - * Web XR default experience - */ - webXRDefaultExperience: BABYLON.WebXRDefaultExperience; - } - class WebXRExperienceHelperDto { - constructor(baseExperience?: BABYLON.WebXRExperienceHelper); - /** - * Base experience - */ - baseExperience: BABYLON.WebXRExperienceHelper; - } - } - declare namespace Base { - /** - * Defines how colors are mapped to entities when there are more entities than colors. - * - firstColorForAll: Uses the first color for all entities (legacy behavior) - * - lastColorRemainder: Maps colors 1:1, then uses last color for remaining entities - * - repeatColors: Cycles through colors in a repeating pattern - * - reversedColors: After exhausting colors, reverses direction (ping-pong pattern) - */ - enum colorMapStrategyEnum { - /** Uses the first color for all entities (legacy behavior) */ - firstColorForAll = "firstColorForAll", - /** Maps colors 1:1, then uses last color for remaining entities */ - lastColorRemainder = "lastColorRemainder", - /** Cycles through colors in a repeating pattern */ - repeatColors = "repeatColors", - /** After exhausting colors, reverses direction (ping-pong pattern) */ - reversedColors = "reversedColors", - } - enum skyboxEnum { - default = "default", - clearSky = "clearSky", - city = "city", - greyGradient = "greyGradient", - } - enum fogModeEnum { - none = "none", - exponential = "exponential", - exponentialSquared = "exponentialSquared", - linear = "linear", - } - enum gradientDirectionEnum { - toTop = "to top", - toTopRight = "to top right", - toRight = "to right", - toBottomRight = "to bottom right", - toBottom = "to bottom", - toBottomLeft = "to bottom left", - toLeft = "to left", - toTopLeft = "to top left", - deg0 = "0deg", - deg45 = "45deg", - deg90 = "90deg", - deg135 = "135deg", - deg180 = "180deg", - deg225 = "225deg", - deg270 = "270deg", - deg315 = "315deg", - } - enum gradientPositionEnum { - center = "center", - top = "top", - topLeft = "top left", - topRight = "top right", - bottom = "bottom", - bottomLeft = "bottom left", - bottomRight = "bottom right", - left = "left", - right = "right", - centerTop = "50% 0%", - centerBottom = "50% 100%", - leftCenter = "0% 50%", - rightCenter = "100% 50%", - } - enum gradientShapeEnum { - circle = "circle", - ellipse = "ellipse", - } - enum backgroundRepeatEnum { - repeat = "repeat", - repeatX = "repeat-x", - repeatY = "repeat-y", - noRepeat = "no-repeat", - space = "space", - round = "round", - } - enum backgroundSizeEnum { - auto = "auto", - cover = "cover", - contain = "contain", - } - enum backgroundAttachmentEnum { - scroll = "scroll", - fixed = "fixed", - local = "local", - } - enum backgroundOriginClipEnum { - paddingBox = "padding-box", - borderBox = "border-box", - contentBox = "content-box", - } - enum verticalAlignmentEnum { - top = "top", - middle = "middle", - bottom = "bottom", - } - enum topBottomEnum { - top = "top", - bottom = "bottom", - } - type Color = string; - type ColorRGB = { - r: number; - g: number; - b: number; - }; - type Material = any; - type Texture = any; - type Point2 = [number, number]; - type Vector2 = [number, number]; - type Point3 = [number, number, number]; - type Vector3 = [number, number, number]; - type Axis3 = { - origin: Base.Point3; - direction: Base.Vector3; - }; - type Axis2 = { - origin: Base.Point2; - direction: Base.Vector2; - }; - type Segment2 = [Point2, Point2]; - type Segment3 = [Point3, Point3]; - type TrianglePlane3 = { - normal: Vector3; - d: number; - }; - type Triangle3 = [Base.Point3, Base.Point3, Base.Point3]; - type Mesh3 = Triangle3[]; - type Plane3 = { - origin: Base.Point3; - normal: Base.Vector3; - direction: Base.Vector3; - }; - type BoundingBox = { - min: Base.Point3; - max: Base.Point3; - center?: Base.Point3; - width?: number; - height?: number; - length?: number; - }; - type Line2 = { - start: Base.Point2; - end: Base.Point2; - }; - type Line3 = { - start: Base.Point3; - end: Base.Point3; - }; - type Polyline3 = { - points: Base.Point3[]; - isClosed?: boolean; - }; - type Polyline2 = { - points: Base.Point2[]; - isClosed?: boolean; - }; - type VerbCurve = { - tessellate: (options: any) => any; - }; - type VerbSurface = { - tessellate: (options: any) => any; - }; - type TransformMatrix3x3 = [ - number, - number, - number, - number, - number, - number, - number, - number, - number - ]; - type TransformMatrixes3x3 = TransformMatrix3x3[]; - type TransformMatrix = [ - number, - number, - number, - number, - number, - number, - number, - number, - number, - number, - number, - number, - number, - number, - number, - number - ]; - type TransformMatrixes = TransformMatrix[]; - } - declare namespace Draw { - type DrawOptions = - | DrawBasicGeometryOptions - | DrawManifoldOrCrossSectionOptions - | DrawOcctShapeOptions - | DrawOcctShapeSimpleOptions - | DrawOcctShapeMaterialOptions - | DrawNodeOptions; - type Entity = - | Base.Point3 - | Base.Vector3 - | Base.Line3 - | Base.Polyline3 - | Base.VerbCurve - | Base.VerbSurface - | Inputs.OCCT.TopoDSShapePointer - | Inputs.Tag.TagDto - | { - type: string; - name?: string; - entityName?: string; - } - | Base.Point3[] - | Base.Vector3[] - | Base.Line3[] - | Base.Polyline3[] - | Base.VerbCurve[] - | Base.VerbSurface[] - | Inputs.OCCT.TopoDSShapePointer[] - | Inputs.Tag.TagDto[] - | { - type: string[]; - name?: string; - entityName?: string; - }; - class DrawAny { - constructor( - entity?: Entity, - options?: DrawOptions, - babylonMesh?: BABYLON.Mesh | BABYLON.LinesMesh - ); - /** - * Entity to be drawn - can be a single or multiple points, lines, polylines, verb curves, verb surfaces, jscad meshes, jscad polygons, jscad paths, occt shapes, tags, nodes - * @default undefined - */ - entity: Entity; - /** - * Options that help you control how your drawn objects look like. This property is optional. In order to pick the right option you need to know which entity you are going to draw. For example if you draw points, lines, polylines or jscad meshes you can use basic geometry options, but if you want to draw OCCT shapes, use OCCT options. - * @default undefined - * @optional true - */ - options?: DrawOptions; - /** - * Entity to be used when updating already drawn mesh in the render loop - * @default undefined - * @optional true - */ - babylonMesh?: BABYLON.Mesh | BABYLON.LinesMesh; - } - class SceneDrawGridMeshDto { - constructor( - width?: number, - height?: number, - subdivisions?: number, - majorUnitFrequency?: number, - minorUnitVisibility?: number, - gridRatio?: number, - opacity?: number, - backFaceCulling?: boolean, - mainColor?: Base.Color, - secondaryColor?: Base.Color - ); - /** - * Width of the grid - * @default 400 - * @minimum 0 - * @maximum Infinity - * @step 10 - */ - width: number; - /** - * Height of the ground - * @default 400 - * @minimum 0 - * @maximum Infinity - * @step 10 - */ - height: number; - /** - * Ground subdivisions - * @default 10 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - subdivisions: number; - /** - * The frequency of thicker lines. - * @default 10 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - majorUnitFrequency: number; - /** - * The visibility of minor units in the grid. - * @default 0.45 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - minorUnitVisibility: number; - /** - * The scale of the grid compared to unit. - * @default 0.5 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - gridRatio: number; - /** - * The grid opacity outside of the lines. - * @default 0.5 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - opacity: number; - /** - * Cull the back faces - * @default false - */ - backFaceCulling: boolean; - /** - * Main color of the grid (e.g. between lines) - * @default #ffffff - */ - mainColor: Base.Color; - /** - * Color of the grid lines. - * @default #ffffff - */ - secondaryColor: Base.Color; - } - /** - * Draw options for basic geometry types like points, lines, polylines, surfaces and jscad meshes - */ - class DrawBasicGeometryOptions { - constructor( - colours?: string | string[], - size?: number, - opacity?: number, - updatable?: boolean, - hidden?: boolean, - drawTwoSided?: boolean, - backFaceColour?: Base.Color, - backFaceOpacity?: number, - colorMapStrategy?: Base.colorMapStrategyEnum, - arrowSize?: number, - arrowAngle?: number - ); - /** - * Basic geometry colours to use for lines, points, polylines, surfaces, jscad meshes. - * @default #ff0000 - */ - colours: string | string[]; - /** - * Strategy for mapping colors to entities when there are more entities than colors. - * - firstColorForAll: Uses the first color for all entities (legacy behavior) - * - lastColorRemainder: Maps colors 1:1, then uses last color for remaining entities - * - repeatColors: Cycles through colors in a repeating pattern - * - reversedColors: After exhausting colors, reverses direction (ping-pong pattern) - * @default lastColorRemainder - */ - colorMapStrategy: Base.colorMapStrategyEnum; - /** - * Size affect how big the drawn points are and how wide lines are. - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - size: number; - /** - * Opacity of the point 0 to 1 - * @default 1 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - opacity: number; - /** - * If geometry needs to be updated later - * @default false - */ - updatable: boolean; - /** - * Hidden - * @default false - */ - hidden: boolean; - /** - * Draw two-sided faces with different colors for front and back. This helps visualize face orientation. Only applies to surfaces. - * @default true - */ - drawTwoSided: boolean; - /** - * Hex colour string for back face colour (negative side of the face). Only used when drawTwoSided is true and drawing surfaces. - * @default #0000ff - */ - backFaceColour: Base.Color; - /** - * Back face opacity value between 0 and 1. Only used when drawTwoSided is true and drawing surfaces. - * @default 1 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - backFaceOpacity: number; - /** - * Size of the arrow head at the end of lines and polylines. Set to 0 to disable arrows. - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 0.01 - */ - arrowSize: number; - /** - * Angle of the arrow head in degrees. Controls how wide the arrow head spreads. - * @default 15 - * @minimum 0 - * @maximum 90 - * @step 1 - */ - arrowAngle: number; - } - /** - * Draw options for Nodes - */ - class DrawNodeOptions { - constructor( - colourX?: Base.Color, - colourY?: Base.Color, - colourZ?: Base.Color, - size?: number - ); - /** - * X Axis colour - * @default #ff0000 - */ - colorX: Base.Color; - /** - * Y Axis colour - * @default #00ff00 - */ - colorY: Base.Color; - /** - * Z Axis colour - * @default #0000ff - */ - colorZ: Base.Color; - /** - * Length of the node axis - * @default 2 - * @minimum 0 - * @maximum Infinity - */ - size: number; - } - class DrawManifoldOrCrossSectionOptions { - /** - * Provide options without default values - */ - constructor( - faceOpacity?: number, - faceMaterial?: Base.Material, - faceColour?: Base.Color, - crossSectionColour?: Base.Color, - crossSectionWidth?: number, - crossSectionOpacity?: number, - computeNormals?: boolean, - drawTwoSided?: boolean, - backFaceColour?: Base.Color, - backFaceOpacity?: number - ); - /** - * Face opacity value between 0 and 1 - * @default 1 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - faceOpacity: number; - /** - * Hex colour string for face colour - * @default #ff0000 - */ - faceColour: Base.Color; - /** - * Face material - * @default undefined - * @optional true - */ - faceMaterial?: Base.Material; - /** - * Hex colour string for cross section drawing - * @default #ff00ff - */ - crossSectionColour: Base.Color; - /** - * Width of cross section lines - * @default 2 - */ - crossSectionWidth: number; - /** - * Cross section opacity value between 0 and 1 - * @default 1 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - crossSectionOpacity: number; - /** - * Compute normals for the shape - * @default false - */ - computeNormals: boolean; - /** - * Whether to draw two-sided geometry with back face rendering - * @default true - */ - drawTwoSided: boolean; - /** - * Hex colour string for the back face when drawing two-sided geometry - * @default #0000ff - */ - backFaceColour: Base.Color; - /** - * Opacity of the back face when drawing two-sided geometry - * @default 1 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - backFaceOpacity: number; - } - /** - * Draw options for OCCT shapes - */ - class DrawOcctShapeOptions { - /** - * Provide options without default values - */ - constructor( - faceOpacity?: number, - edgeOpacity?: number, - edgeColour?: Base.Color, - faceMaterial?: Base.Material, - faceColour?: Base.Color, - edgeWidth?: number, - drawEdges?: boolean, - drawFaces?: boolean, - drawVertices?: boolean, - vertexColour?: Base.Color, - vertexSize?: number, - precision?: number, - drawEdgeIndexes?: boolean, - edgeIndexHeight?: number, - edgeIndexColour?: Base.Color, - drawFaceIndexes?: boolean, - faceIndexHeight?: number, - faceIndexColour?: Base.Color, - drawTwoSided?: boolean, - backFaceColour?: Base.Color, - backFaceOpacity?: number, - edgeArrowSize?: number, - edgeArrowAngle?: number - ); - /** - * Face opacity value between 0 and 1 - * @default 1 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - faceOpacity: number; - /** - * Edge opacity value between 0 and 1 - * @default 1 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - edgeOpacity: number; - /** - * Hex colour string for the edges - * @default #ffffff - */ - edgeColour: Base.Color; - /** - * Hex colour string for face colour - * @default #ff0000 - */ - faceColour: Base.Color; - /** - * Color of the vertices that will be drawn - * @default #ff00ff - */ - vertexColour: Base.Color; - /** - * Face material - * @default undefined - * @optional true - */ - faceMaterial?: Base.Material; - /** - * Edge width - * @default 2 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - edgeWidth: number; - /** - * The size of a vertices that will be drawn - * @default 0.03 - * @minimum 0 - * @maximum Infinity - * @step 0.01 - */ - vertexSize: number; - /** - * You can turn off drawing of edges via this property - * @default true - */ - drawEdges: boolean; - /** - * You can turn off drawing of faces via this property - * @default true - */ - drawFaces: boolean; - /** - * You can turn off drawing of vertexes via this property - * @default false - */ - drawVertices: boolean; - /** - * Precision of the mesh that will be generated for the shape, lower number will mean more triangles - * @default 0.01 - * @minimum 0 - * @maximum Infinity - * @step 0.01 - */ - precision: number; - /** - * Draw index of edges in space - * @default false - */ - drawEdgeIndexes: boolean; - /** - * Indicates the edge index height if they are drawn - * @default 0.06 - * @minimum 0 - * @maximum Infinity - * @step 0.01 - */ - edgeIndexHeight: number; - /** - * Edge index colour if the edges are drawn - * @default #ff00ff - */ - edgeIndexColour: Base.Color; - /** - * Draw indexes of faces in space - * @default false - */ - drawFaceIndexes: boolean; - /** - * Indicates the edge index height if they are drawn - * @default 0.06 - * @minimum 0 - * @maximum Infinity - * @step 0.01 - */ - faceIndexHeight: number; - /** - * Edge index colour if the edges are drawn - * @default #0000ff - */ - faceIndexColour: Base.Color; - /** - * Draw two-sided faces with different colors for front and back. This helps visualize face orientation. - * @default true - */ - drawTwoSided: boolean; - /** - * Hex colour string for back face colour (negative side of the face). Only used when drawTwoSided is true. - * @default #0000ff - */ - backFaceColour: Base.Color; - /** - * Back face opacity value between 0 and 1. Only used when drawTwoSided is true. - * @default 1 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - backFaceOpacity: number; - /** - * Size of arrow heads at the end of edges to indicate edge/wire orientation. Set to 0 to disable arrows. - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 0.01 - */ - edgeArrowSize: number; - /** - * Angle of the arrow head in degrees. Controls how wide the arrow head spreads. - * @default 15 - * @minimum 0 - * @maximum 90 - * @step 1 - */ - edgeArrowAngle: number; - } - class DrawOcctShapeSimpleOptions { - constructor( - precision?: number, - drawFaces?: boolean, - faceColour?: Base.Color, - drawEdges?: boolean, - edgeColour?: Base.Color, - edgeWidth?: number, - drawTwoSided?: boolean, - backFaceColour?: Base.Color, - backFaceOpacity?: number - ); - /** - * Precision - * @default 0.01 - * @minimum 0 - * @maximum Infinity - */ - precision: number; - /** - * You can turn off drawing of faces via this property - * @default true - */ - drawFaces: boolean; - /** - * Hex colour string for face colour - * @default #ff0000 - */ - faceColour?: Base.Color; - /** - * You can turn off drawing of edges via this property - * @default true - */ - drawEdges: boolean; - /** - * Hex colour string for the edges - * @default #ffffff - */ - edgeColour: Base.Color; - /** - * Edge width - * @default 2 - * @minimum 0 - * @maximum Infinity - */ - edgeWidth: number; - /** - * Whether to draw two-sided geometry with back face rendering - * @default true - */ - drawTwoSided: boolean; - /** - * Hex colour string for the back face when drawing two-sided geometry - * @default #0000ff - */ - backFaceColour: Base.Color; - /** - * Opacity of the back face when drawing two-sided geometry - * @default 1 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - backFaceOpacity: number; - } - class DrawOcctShapeMaterialOptions { - constructor( - precision?: number, - faceMaterial?: any, - drawEdges?: boolean, - edgeColour?: Base.Color, - edgeWidth?: number - ); - /** - * Precision - * @default 0.01 - * @minimum 0 - * @maximum Infinity - */ - precision: number; - /** - * Face material - * @default undefined - */ - faceMaterial: any; - /** - * You can turn off drawing of edges via this property - * @default true - */ - drawEdges: boolean; - /** - * Hex colour string for the edges - * @default #ffffff - */ - edgeColour: Base.Color; - /** - * Edge width - * @default 2 - * @minimum 0 - * @maximum Infinity - */ - edgeWidth: number; - } - /** - * Texture filtering mode - how the texture is sampled when scaled - */ - enum samplingModeEnum { - nearest = "nearest", - bilinear = "bilinear", - trilinear = "trilinear", - } - /** - * Generic texture creation options that work across all supported game engines. - * These options are mapped to engine-specific texture properties. - */ - class GenericTextureDto { - constructor( - url?: string, - name?: string, - uScale?: number, - vScale?: number, - uOffset?: number, - vOffset?: number, - wAng?: number, - invertY?: boolean, - invertZ?: boolean, - samplingMode?: samplingModeEnum - ); - /** - * URL of the texture image. Can be a local path or remote URL. - * @default undefined - */ - url: string; - /** - * Name identifier for the texture - * @default Texture - */ - name: string; - /** - * Horizontal (U) scale/tiling of the texture - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - uScale: number; - /** - * Vertical (V) scale/tiling of the texture - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - vScale: number; - /** - * Horizontal (U) offset of the texture - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - uOffset: number; - /** - * Vertical (V) offset of the texture - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - vOffset: number; - /** - * Rotation angle of the texture in radians around the W axis - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - wAng: number; - /** - * Invert the texture on the Y axis - * @default false - */ - invertY: boolean; - /** - * Invert the texture on the Z axis - * @default false - */ - invertZ: boolean; - /** - * Texture sampling/filtering mode - * @default nearest - */ - samplingMode: samplingModeEnum; - } - /** - * Alpha/blend modes that determine how transparent materials are rendered - */ - enum alphaModeEnum { - opaque = "opaque", - mask = "mask", - blend = "blend", - } - /** - * Generic PBR (Physically Based Rendering) material creation options. - * These properties represent the common subset available across BabylonJS, ThreeJS, and PlayCanvas. - * Property names follow BabylonJS conventions and are mapped to equivalent properties in other engines. - */ - class GenericPBRMaterialDto { - constructor( - name?: string, - baseColor?: Base.Color, - metallic?: number, - roughness?: number, - alpha?: number, - emissiveColor?: Base.Color, - emissiveIntensity?: number, - zOffset?: number, - zOffsetUnits?: number, - baseColorTexture?: Base.Texture, - metallicRoughnessTexture?: Base.Texture, - normalTexture?: Base.Texture, - emissiveTexture?: Base.Texture, - occlusionTexture?: Base.Texture, - alphaMode?: alphaModeEnum, - alphaCutoff?: number, - doubleSided?: boolean, - wireframe?: boolean, - unlit?: boolean - ); - /** - * Name identifier for the material - * @default PBRMaterial - */ - name: string; - /** - * Base/albedo color of the material in hex format - * @default #0000ff - */ - baseColor: Base.Color; - /** - * Metallic factor (0 = dielectric, 1 = metallic) - * @default 0.5 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - metallic: number; - /** - * Roughness factor (0 = smooth/mirror, 1 = rough/diffuse) - * @default 0.5 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - roughness: number; - /** - * Overall opacity/transparency of the material (0 = fully transparent, 1 = fully opaque) - * @default 1 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - alpha: number; - /** - * Emissive color - the color the material appears to emit (glow) - * @default #000000 - */ - emissiveColor?: Base.Color; - /** - * Intensity multiplier for the emissive color - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - emissiveIntensity: number; - /** - * Z-buffer depth offset factor to help with z-fighting on coplanar surfaces - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - zOffset: number; - /** - * Z-buffer depth offset units for fine-tuned z-fighting control - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 1 - */ - zOffsetUnits: number; - /** - * Texture to use for base/albedo color - * @default undefined - * @optional true - */ - baseColorTexture?: Base.Texture; - /** - * Combined metallic-roughness texture (metallic in B channel, roughness in G channel) - * @default undefined - * @optional true - */ - metallicRoughnessTexture?: Base.Texture; - /** - * Normal/bump map texture for surface detail - * @default undefined - * @optional true - */ - normalTexture?: Base.Texture; - /** - * Texture for emissive/glow areas - * @default undefined - * @optional true - */ - emissiveTexture?: Base.Texture; - /** - * Ambient occlusion texture for soft shadows in crevices - * @default undefined - * @optional true - */ - occlusionTexture?: Base.Texture; - /** - * Alpha/transparency mode: opaque, mask (cutout), or blend (translucent) - * @default opaque - */ - alphaMode: alphaModeEnum; - /** - * Alpha threshold for mask mode (pixels below this are fully transparent) - * @default 0.5 - * @minimum 0 - * @maximum 1 - * @step 0.05 - */ - alphaCutoff: number; - /** - * Render both sides of faces (equivalent to disabling backFaceCulling) - * @default false - */ - doubleSided: boolean; - /** - * Render material as wireframe - * @default false - */ - wireframe: boolean; - /** - * Disable lighting calculations and render flat/unlit - * @default false - */ - unlit: boolean; - } - enum drawingTypes { - point = 0, - points = 1, - line = 2, - lines = 3, - node = 4, - nodes = 5, - polyline = 6, - polylines = 7, - verbCurve = 8, - verbCurves = 9, - verbSurface = 10, - verbSurfaces = 11, - jscadMesh = 12, - jscadMeshes = 13, - occt = 14, - manifold = 15, - tag = 16, - tags = 17, - } - } - declare namespace BabylonNode { - class NodeDto { - constructor(node?: BABYLON.TransformNode); - /** - * Transformation node - */ - node: BABYLON.TransformNode; - } - class NodeTranslationDto { - constructor( - node?: BABYLON.TransformNode, - direction?: Base.Vector3, - distance?: number - ); - /** - * Transformation node - */ - node: BABYLON.TransformNode; - /** - * Direction vector expressed in [x, y, z] vector array - */ - direction: Base.Vector3; - /** - * Distance to translate - */ - distance: number; - } - class NodeParentDto { - constructor( - node?: BABYLON.TransformNode, - parentNode?: BABYLON.TransformNode - ); - /** - * Transformation node - */ - node: BABYLON.TransformNode; - /** - * Parent node - */ - parentNode: BABYLON.TransformNode; - } - class NodeDirectionDto { - constructor(node?: BABYLON.TransformNode, direction?: Base.Vector3); - /** - * Transformation node - */ - node: BABYLON.TransformNode; - /** - * Direction vector expressed in [x, y, z] vector array - */ - direction: number[]; - } - class NodePositionDto { - constructor(node?: BABYLON.TransformNode, position?: Base.Point3); - /** - * Transformation node - */ - node: BABYLON.TransformNode; - /** - * Position vector expressed in [x, y, z] vector array - */ - position: Base.Point3; - } - class RotateNodeDto { - constructor( - node?: BABYLON.TransformNode, - axis?: Base.Vector3, - angle?: number - ); - /** - * Transformation node - */ - node: BABYLON.TransformNode; - /** - * Rotate around the axis expressed in [x, y, z] vector array - */ - axis: Base.Vector3; - /** - * The rotation angle expressed in degrees - */ - angle: number; - } - class RotateAroundAxisNodeDto { - constructor( - node?: BABYLON.TransformNode, - position?: Base.Point3, - axis?: Base.Vector3, - angle?: number - ); - /** - * Transformation node - */ - node: BABYLON.TransformNode; - /** - * Position vector expressed in [x, y, z] vector array - */ - position: Base.Point3; - /** - * Rotate around the axis expressed in [x, y, z] vector array - */ - axis: Base.Vector3; - /** - * The rotation angle expressed in degrees - */ - angle: number; - } - class CreateNodeFromRotationDto { - constructor( - parent?: BABYLON.TransformNode, - origin?: Base.Point3, - rotation?: Base.Vector3 - ); - /** - * Optional parent node - */ - parent: BABYLON.TransformNode | null; - /** - * Oirigin of the node - */ - origin: Base.Point3; - /** - * Rotations of the node around x y z axis - */ - rotation: Base.Vector3; - } - class DrawNodeDto { - constructor( - node?: BABYLON.TransformNode, - colorX?: string, - colorY?: string, - colorZ?: string, - size?: number - ); - /** - * Transformation node - */ - node: BABYLON.TransformNode; - /** - * Hex encoded color string for X axis - */ - colorX: string; - /** - * Hex encoded color string for Y axis - */ - colorY: string; - /** - * Hex encoded color string for Z axis - */ - colorZ: string; - /** - * Length of the node axis - */ - size: number; - } - class DrawNodesDto { - constructor( - nodes?: BABYLON.TransformNode[], - colorX?: string, - colorY?: string, - colorZ?: string, - size?: number - ); - /** - * Nodes that will be drawn - */ - nodes: BABYLON.TransformNode[]; - /** - * Hex encoded color string for X axis - */ - colorX: string; - /** - * Hex encoded color string for Y axis - */ - colorY: string; - /** - * Hex encoded color string for Z axis - */ - colorZ: string; - /** - * Length of the node axis - */ - size: number; - } - } - declare namespace BabylonScene { - class SceneBackgroundColourDto { - /** - * Provide options without default values - */ - constructor(colour?: string); - /** - * Hex colour string for the scene background colour - * @default #ffffff - */ - colour: Base.Color; - } - class SceneDto { - /** - * Provide scene - */ - constructor(scene?: BABYLON.Scene); - /** - * The babylonjs scene - * @default undefined - */ - scene: BABYLON.Scene; - } - class EnablePhysicsDto { - constructor(vector?: Base.Vector3); - /** - * The gravity vector - * @default [0, -9.81, 0] - */ - vector: Base.Vector3; - } - class PointLightDto { - constructor( - position?: Base.Point3, - intensity?: number, - diffuse?: Base.Color, - specular?: Base.Color, - radius?: number, - shadowGeneratorMapSize?: number, - enableShadows?: boolean, - shadowDarkness?: number, - transparencyShadow?: boolean, - shadowUsePercentageCloserFiltering?: boolean, - shadowContactHardeningLightSizeUVRatio?: number, - shadowBias?: number, - shadowNormalBias?: number, - shadowMaxZ?: number, - shadowMinZ?: number, - shadowRefreshRate?: number - ); - /** - * Position of the point light - * @default [0, 0, 0] - */ - position: Base.Point3; - /** - * Intensity of the point light, value between 0 and 1 - * @default 2000 - * @minimum 0 - * @maximum Infinity - * @step 500 - */ - intensity: number; - /** - * Diffuse colour of the point light - * @default #ffffff - */ - diffuse: Base.Color; - /** - * Specular colour of the point light - * @default #ffffff - */ - specular: Base.Color; - /** - * Radius of the sphere mesh representing the light bulb. If 0 light gets created without the mesh - * @default 0.1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - radius: number; - /** - * The map size for shadow generator texture if shadows are enabled - * @default 1024 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - shadowGeneratorMapSize?: number; - /** - * Enables shadows - * @default true - */ - enableShadows?: boolean; - /** - * Shadow darkness - * @default 0 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - shadowDarkness?: number; - /** - * Sets the ability to have transparent shadow (useful for Gaussian Splatting Meshes) - * @default false - */ - transparencyShadow: boolean; - /** - * Use percentage closer filtering - * @default true - */ - shadowUsePercentageCloserFiltering: boolean; - /** - * Shadow contact hardening light size UV ratio - only applies if usePercentageCloserFiltering is true - * @default 0.2 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - shadowContactHardeningLightSizeUVRatio: number; - /** - * Shadow bias - * @default 0.0001 - * @minimum 0 - * @maximum Infinity - * @step 0.00001 - */ - shadowBias: number; - /** - * Shadow normal bias - * @default 0.002 - * @minimum 0 - * @maximum Infinity - * @step 0.0001 - */ - shadowNormalBias: number; - /** - * Shadow max Z - * @default 1000 - * @minimum 0 - * @maximum Infinity - * @step 50 - */ - shadowMaxZ: number; - /** - * Shadow min Z - * @default 0.1 - * @minimum 0 - * @maximum Infinity - * @step 50 - */ - shadowMinZ: number; - /** - * Shadow refresh rate - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - shadowRefreshRate: number; - } - class ActiveCameraDto { - constructor(camera?: BABYLON.Camera); - /** - * Camera to activate - * @default undefined - */ - camera: BABYLON.Camera; - } - class UseRightHandedSystemDto { - constructor(use?: boolean); - /** Indicates to use right handed system - * @default true - */ - use: boolean; - } - class DirectionalLightDto { - constructor( - direction?: Base.Vector3, - intensity?: number, - diffuse?: Base.Color, - specular?: Base.Color, - shadowGeneratorMapSize?: number, - enableShadows?: boolean, - shadowDarkness?: number, - shadowUsePercentageCloserFiltering?: boolean, - shadowContactHardeningLightSizeUVRatio?: number, - shadowBias?: number, - shadowNormalBias?: number, - shadowMaxZ?: number, - shadowMinZ?: number, - shadowRefreshRate?: number - ); - /** - * Direction of the directional light - * @default [-100, -100, -100] - */ - direction: Base.Vector3; - /** - * Intensity of the point light, value between 0 and 1 - * @default 0.5 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - intensity: number; - /** - * Diffuse colour of the point light - * @default #ffffff - */ - diffuse: Base.Color; - /** - * Specular colour of the point light - * @default #ffffff - */ - specular: Base.Color; - /** - * The map size for shadow generator texture if shadows are enabled - * @default 1024 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - shadowGeneratorMapSize?: number; - /** - * Enables shadows - * @default true - */ - enableShadows?: boolean; - /** - * Shadow darkness - * @default 0 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - shadowDarkness?: number; - /** - * Use percentage closer filtering - * @default true - */ - shadowUsePercentageCloserFiltering: boolean; - /** - * Sets the ability to have transparent shadow (useful for Gaussian Splatting Meshes) - * @default false - */ - transparencyShadow: boolean; - /** - * Shadow contact hardening light size UV ratio - only applies if usePercentageCloserFiltering is true - * @default 0.2 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - shadowContactHardeningLightSizeUVRatio: number; - /** - * Shadow bias - * @default 0.0001 - * @minimum 0 - * @maximum Infinity - * @step 0.00001 - */ - shadowBias: number; - /** - * Shadow normal bias - * @default 0.002 - * @minimum 0 - * @maximum Infinity - * @step 0.0001 - */ - shadowNormalBias: number; - /** - * Shadow max Z - * @default 1000 - * @minimum 0 - * @maximum Infinity - * @step 50 - */ - shadowMaxZ: number; - /** - * Shadow min Z - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 50 - */ - shadowMinZ: number; - /** - * Shadow refresh rate - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - shadowRefreshRate: number; - } - class CameraConfigurationDto { - constructor( - position?: Base.Point3, - lookAt?: Base.Point3, - lowerRadiusLimit?: number, - upperRadiusLimit?: number, - lowerAlphaLimit?: number, - upperAlphaLimit?: number, - lowerBetaLimit?: number, - upperBetaLimit?: number, - angularSensibilityX?: number, - angularSensibilityY?: number, - maxZ?: number, - panningSensibility?: number, - wheelPrecision?: number - ); - /** - * Position of the point light - * @default [10, 10, 10] - * - */ - position: Base.Point3; - /** - * Look at - */ - lookAt: Base.Point3; - /** - * Lower radius limit - how close can the camera be to the target - * @default undefined - * @minimum -Infinity - * @maximum Infinity - * @step 1 - * @optional true - */ - lowerRadiusLimit: any; - /** - * Upper radius limit - how far can the camera be from the target - * @default undefined - * @minimum -Infinity - * @maximum Infinity - * @step 1 - * @optional true - */ - upperRadiusLimit: any; - /** - * Lower alpha limit - camera rotation along the longitudinal (horizontal) axis in degrees. - * @default undefined - * @minimum -360 - * @maximum 360 - * @step 1 - * @optional true - */ - lowerAlphaLimit: any; - /** - * Upper alpha limit - camera rotation along the longitudinal (horizontal) axis in degrees. - * @default undefined - * @minimum -360 - * @maximum 360 - * @step 1 - * @optional true - */ - upperAlphaLimit: any; - /** - * Lower beta limit - camera rotation along the latitudinal (vertical) axis in degrees. This is counted from the top down, where 0 is looking from top straight down. - * @default 1 - * @minimum -360 - * @maximum 360 - * @step 1 - */ - lowerBetaLimit: number; - /** - * Upper beta limit - camera rotation along the longitudinal (vertical) axis in degrees. This is counted from the top down, where 180 is looking from bottom straight up. - * @default 179 - * @minimum -360 - * @maximum 360 - * @step 1 - */ - upperBetaLimit: number; - /** - * Angular sensibility along x (horizontal) axis of the camera. The lower this number, the faster the camera will move. - * @default 1000 - * @minimum 0 - * @maximum Infinity - * @step 10 - */ - angularSensibilityX: number; - /** - * Angular sensibility along y (vertical) axis of the camera. The lower this number, the faster the camera will move. - * @default 1000 - * @minimum 0 - * @maximum Infinity - * @step 10 - */ - angularSensibilityY: number; - /** - * Change how far the camera can see - * @default 1000 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - maxZ: number; - /** - * Panning sensibility. If large units are used for the model, this number needs to get smaller - * @default 1000 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - panningSensibility: number; - /** - * Zoom precision of the wheel. If large units are used, this number needs to get smaller - * @default 3 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - wheelPrecision: number; - } - class SkyboxDto { - constructor( - skybox?: Base.skyboxEnum, - size?: number, - blur?: number, - environmentIntensity?: number, - hideSkybox?: boolean - ); - /** - * Skybox type - * @default clearSky - */ - skybox: Base.skyboxEnum; - /** - * Skybox size - * @default 1000 - * @minimum 0 - * @maximum Infinity - * @step 10 - */ - size: number; - /** - * Identifies if skybox texture should affect scene environment - * @default 0.1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - blur: number; - /** - * Identifies if skybox texture should affect scene environment - * @default 0.7 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - environmentIntensity: number; - /** - * Hides the skybox mesh but keeps the environment texture - * @default false - */ - hideSkybox?: boolean; - } - class SkyboxCustomTextureDto { - constructor( - textureUrl?: string, - textureSize?: number, - size?: number, - blur?: number, - environmentIntensity?: number, - hideSkybox?: boolean - ); - /** - * Skybox texture URL pointing to .hdr, .env or root of the cubemap images - * @default undefined - * @optional true - */ - textureUrl?: string; - /** - * Skybox texture size (only applies to custom URL texture) - * @default 512 - * @optional true - */ - textureSize?: number; - /** - * Skybox size - * @default 1000 - * @minimum 0 - * @maximum Infinity - * @step 10 - */ - size: number; - /** - * Identifies if skybox texture should affect scene environment - * @default 0.1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - blur: number; - /** - * Identifies if skybox texture should affect scene environment - * @default 0.7 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - environmentIntensity: number; - /** - * Hides the skybox mesh but keeps the environment texture - * @default false - */ - hideSkybox?: boolean; - } - class PointerDto { - statement_update: () => void; - } - class FogDto { - constructor( - mode?: Base.fogModeEnum, - color?: Base.Color, - density?: number, - start?: number, - end?: number - ); - /** - * Fog mode - * @default none - */ - mode: Base.fogModeEnum; - /** - * Fog color - * @default #ffffff - */ - color: Base.Color; - /** - * Fog density - * @default 0.1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - density: number; - /** - * Fog start - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - start: number; - /** - * Fog end - * @default 1000 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - end: number; - } - class SceneCanvasCSSBackgroundImageDto { - /** - * Provide options without default values - */ - constructor(cssBackgroundImage?: string); - /** - * CSS background image string - * @default linear-gradient(to top, #1a1c1f 0%, #93aacd 100%) - */ - cssBackgroundImage: string; - } - class SceneTwoColorLinearGradientDto { - constructor( - colorFrom?: Base.Color, - colorTo?: Base.Color, - direction?: Base.gradientDirectionEnum, - stopFrom?: number, - stopTo?: number - ); - /** - * Starting color in hex format - * @default #1a1c1f - */ - colorFrom: Base.Color; - /** - * Ending color in hex format - * @default #93aacd - */ - colorTo: Base.Color; - /** - * Gradient direction - * @default toBottom - */ - direction: Base.gradientDirectionEnum; - /** - * Starting color stop percentage - * @default 0 - * @minimum 0 - * @maximum 100 - * @step 1 - */ - stopFrom: number; - /** - * Ending color stop percentage - * @default 100 - * @minimum 0 - * @maximum 100 - * @step 1 - */ - stopTo: number; - } - class SceneTwoColorRadialGradientDto { - constructor( - colorFrom?: Base.Color, - colorTo?: Base.Color, - position?: Base.gradientPositionEnum, - stopFrom?: number, - stopTo?: number, - shape?: Base.gradientShapeEnum - ); - /** - * Starting color in hex format - * @default #1a1c1f - */ - colorFrom: Base.Color; - /** - * Ending color in hex format - * @default #93aacd - */ - colorTo: Base.Color; - /** - * Gradient position - * @default center - */ - position: Base.gradientPositionEnum; - /** - * Starting color stop percentage - * @default 0 - * @minimum 0 - * @maximum 100 - * @step 1 - */ - stopFrom: number; - /** - * Ending color stop percentage - * @default 100 - * @minimum 0 - * @maximum 100 - * @step 1 - */ - stopTo: number; - /** - * Gradient shape - * @default circle - */ - shape: Base.gradientShapeEnum; - } - class SceneMultiColorLinearGradientDto { - constructor( - colors?: Base.Color[], - stops?: number[], - direction?: Base.gradientDirectionEnum - ); - /** - * Array of colors in hex format - * @default ["#1a1c1f", "#93aacd"] - */ - colors: Base.Color[]; - /** - * Array of stop percentages for each color - * @default [0, 100] - */ - stops: number[]; - /** - * Gradient direction - * @default toTop - */ - direction: Base.gradientDirectionEnum; - } - class SceneMultiColorRadialGradientDto { - constructor( - colors?: Base.Color[], - stops?: number[], - position?: Base.gradientPositionEnum, - shape?: Base.gradientShapeEnum - ); - /** - * Array of colors in hex format - * @default ["#1a1c1f", "#93aacd"] - */ - colors: Base.Color[]; - /** - * Array of stop percentages for each color - * @default [0, 100] - */ - stops: number[]; - /** - * Gradient position - * @default center - */ - position: Base.gradientPositionEnum; - /** - * Gradient shape - * @default circle - */ - shape: Base.gradientShapeEnum; - } - class SceneCanvasBackgroundImageDto { - constructor( - imageUrl?: string, - repeat?: Base.backgroundRepeatEnum, - size?: Base.backgroundSizeEnum, - position?: Base.gradientPositionEnum, - attachment?: Base.backgroundAttachmentEnum, - origin?: Base.backgroundOriginClipEnum, - clip?: Base.backgroundOriginClipEnum - ); - /** - * URL of the background image - * @default undefined - */ - imageUrl?: string; - /** - * How the background image should repeat - * @default noRepeat - */ - repeat: Base.backgroundRepeatEnum; - /** - * Size of the background image (enum values or specific values like '100px 50px') - * @default cover - */ - size: Base.backgroundSizeEnum; - /** - * Position of the background image (enum values or specific values like '50% 50%') - * @default center - */ - position: Base.gradientPositionEnum; - /** - * Background attachment - * @default scroll - */ - attachment: Base.backgroundAttachmentEnum; - /** - * Background origin - * @default paddingBox - */ - origin: Base.backgroundOriginClipEnum; - /** - * Background clip - * @default borderBox - */ - clip: Base.backgroundOriginClipEnum; - } - } - declare namespace Base { - type Color = string; - type ColorRGB = { - r: number; - g: number; - b: number; - }; - type Material = any; - type Point2 = [number, number]; - type Vector2 = [number, number]; - type Point3 = [number, number, number]; - type Vector3 = [number, number, number]; - type Axis3 = { - origin: Base.Point3; - direction: Base.Vector3; - }; - type Axis2 = { - origin: Base.Point2; - direction: Base.Vector2; - }; - type Segment2 = [Point2, Point2]; - type Segment3 = [Point3, Point3]; - type TrianglePlane3 = { - normal: Vector3; - d: number; - }; - type Triangle3 = [Base.Point3, Base.Point3, Base.Point3]; - type Mesh3 = Triangle3[]; - type Plane3 = { - origin: Base.Point3; - normal: Base.Vector3; - direction: Base.Vector3; - }; - type BoundingBox = { - min: Base.Point3; - max: Base.Point3; - center?: Base.Point3; - width?: number; - height?: number; - length?: number; - }; - type Line2 = { - start: Base.Point2; - end: Base.Point2; - }; - type Line3 = { - start: Base.Point3; - end: Base.Point3; - }; - type Polyline3 = { - points: Base.Point3[]; - isClosed?: boolean; - color?: number[]; - }; - type Polyline2 = { - points: Base.Point2[]; - isClosed?: boolean; - color?: number[]; - }; - type TransformMatrix3x3 = [ - number, - number, - number, - number, - number, - number, - number, - number, - number - ]; - type TransformMatrixes3x3 = TransformMatrix3x3[]; - type TransformMatrix = [ - number, - number, - number, - number, - number, - number, - number, - number, - number, - number, - number, - number, - number, - number, - number, - number - ]; - type TransformMatrixes = TransformMatrix[]; - enum horizontalAlignEnum { - left = "left", - center = "center", - right = "right", - } - enum verticalAlignmentEnum { - top = "top", - middle = "middle", - bottom = "bottom", - } - enum topBottomEnum { - top = "top", - bottom = "bottom", - } - enum basicAlignmentEnum { - topLeft = "topLeft", - topMid = "topMid", - topRight = "topRight", - midLeft = "midLeft", - midMid = "midMid", - midRight = "midRight", - bottomLeft = "bottomLeft", - bottomMid = "bottomMid", - bottomRight = "bottomRight", - } - } - declare namespace Color { - class HexDto { - constructor(color?: Base.Color); - /** - * Color hex - * @default #0000ff - */ - color: Base.Color; - } - class InvertHexDto { - constructor(color?: Base.Color); - /** - * Color hex - * @default #0000ff - */ - color: Base.Color; - /** - * Choose to invert the color to black and white (useful for text color) - */ - blackAndWhite: boolean; - } - class HexDtoMapped { - constructor(color?: Base.Color, from?: number, to?: number); - /** - * Color hex - * @default #0000ff - */ - color: Base.Color; - /** - * From min bound - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 1 - */ - from: number; - /** - * To max bound - * @default 255 - * @minimum -Infinity - * @maximum Infinity - * @step 1 - */ - to: number; - } - class RGBObjectMaxDto { - constructor(rgb?: Base.ColorRGB, max?: number); - /** - * Red value component - * @default undefined - */ - rgb: Base.ColorRGB; - /** - * Min value of the range - * @default 0 - * @minimum 0 - * @maximum 255 - * @step 0.1 - */ - min: number; - /** - * Max value, it would automatically be remapped to whatever is needed if lower comes in - * @default 255 - * @minimum 0 - * @maximum 255 - * @step 0.1 - */ - max: number; - } - class RGBMinMaxDto { - constructor( - r?: number, - g?: number, - b?: number, - min?: number, - max?: number - ); - /** - * Red value component - * @default 255 - * @minimum 0 - * @maximum 255 - * @step 1 - */ - r: number; - /** - * Green value component - * @default 255 - * @minimum 0 - * @maximum 255 - * @step 1 - */ - g: number; - /** - * Blue value component - * @default 255 - * @minimum 0 - * @maximum 255 - * @step 1 - */ - b: number; - /** - * Min value of the range - * @default 0 - * @minimum 0 - * @maximum 255 - * @step 0.1 - */ - min: number; - /** - * Max value of the range - * @default 255 - * @minimum 0 - * @maximum 255 - * @step 0.1 - */ - max: number; - } - class RGBObjectDto { - constructor(rgb?: Base.ColorRGB); - /** - * Red value component - * @default undefined - */ - rgb: Base.ColorRGB; - } - } - declare namespace Dates { - class DateDto { - constructor(date?: Date); - /** - * The date - * @default undefined - */ - date: Date; - } - class DateStringDto { - constructor(dateString?: string); - /** - * The date string - * @default undefined - */ - dateString: string; - } - class DateSecondsDto { - constructor(date?: Date, seconds?: number); - /** - * The date to update the seconds for - * @default undefined - */ - date: Date; - /** - * The seconds of the date - * @default 30 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - seconds: number; - } - class DateDayDto { - constructor(date?: Date, day?: number); - /** - * The date - * @default undefined - */ - date: Date; - /** - * The day of the date - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - day: number; - } - class DateYearDto { - constructor(date?: Date, year?: number); - /** - * The date - * @default undefined - */ - date: Date; - /** - * The year of the date - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - year: number; - } - class DateMonthDto { - constructor(date?: Date, month?: number); - /** - * The date - * @default undefined - */ - date: Date; - /** - * The month of the date - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - month: number; - } - class DateHoursDto { - constructor(date?: Date, hours?: number); - /** - * The date - * @default undefined - */ - date: Date; - /** - * The hours of the date - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - hours: number; - } - class DateMinutesDto { - constructor(date?: Date, minutes?: number); - /** - * The date - * @default undefined - */ - date: Date; - /** - * The minutes of the date - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - minutes: number; - } - class DateMillisecondsDto { - constructor(date?: Date, milliseconds?: number); - /** - * The date - * @default undefined - */ - date: Date; - /** - * The milliseconds of the date - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - milliseconds: number; - } - class DateTimeDto { - constructor(date?: Date, time?: number); - /** - * The date - * @default undefined - */ - date: Date; - /** - * The time of the date - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - time: number; - } - class CreateFromUnixTimeStampDto { - constructor(unixTimeStamp?: number); - /** - * The unix time stamp - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - unixTimeStamp: number; - } - class CreateDateDto { - constructor( - year?: number, - month?: number, - day?: number, - hours?: number, - minutes?: number, - seconds?: number, - milliseconds?: number - ); - /** - * The year of the date - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - year: number; - /** - * The month of the date - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - month: number; - /** - * The day of the month - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - day: number; - /** - * The hours of the date - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - hours: number; - /** - * The minutes of the date - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - minutes: number; - /** - * The seconds of the date - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - seconds: number; - /** - * The milliseconds of the date - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - milliseconds: number; - } - } - declare namespace IO { - /** - * Line segment defined by start and end points - */ - class DxfLineSegmentDto { - constructor(start?: Base.Point2, end?: Base.Point2); - /** - * Start point of the line - * @default undefined - */ - start: Base.Point2; - /** - * End point of the line - * @default undefined - */ - end: Base.Point2; - } - /** - * Arc segment defined by center, radius, and start/end angles in degrees - */ - class DxfArcSegmentDto { - constructor( - center?: Base.Point2, - radius?: number, - startAngle?: number, - endAngle?: number - ); - /** - * Center point of the arc - * @default undefined - */ - center: Base.Point2; - /** - * Radius of the arc - * @default undefined - */ - radius: number; - /** - * Start angle in degrees - * @default undefined - */ - startAngle: number; - /** - * End angle in degrees (counter-clockwise from start angle) - * @default undefined - */ - endAngle: number; - } - /** - * Circle defined by center and radius - */ - class DxfCircleSegmentDto { - constructor(center?: Base.Point2, radius?: number); - /** - * Center point of the circle - * @default undefined - */ - center: Base.Point2; - /** - * Radius of the circle - * @default undefined - */ - radius: number; - } - /** - * Polyline segment defined by multiple points - * Can include bulge values to create arc segments between vertices - */ - class DxfPolylineSegmentDto { - constructor( - points?: Base.Point2[], - closed?: boolean, - bulges?: number[] - ); - /** - * Points defining the polyline vertices - * @default undefined - */ - points: Base.Point2[]; - /** - * Whether the polyline is closed - * @default false - */ - closed?: boolean; - /** - * Bulge values for each vertex (optional) - * Bulge = tan(angle/4) where angle is the arc angle in radians - * Positive = counterclockwise, Negative = clockwise - * 0 = straight line segment - * Array length should match points length (or be undefined for all straight segments) - * @default undefined - */ - bulges?: number[]; - } - /** - * Spline/B-spline segment defined by control points and degree - */ - class DxfSplineSegmentDto { - constructor( - controlPoints?: Base.Point2[], - degree?: number, - closed?: boolean - ); - /** - * Control points defining the spline - * @default undefined - */ - controlPoints: Base.Point2[]; - /** - * Degree of the spline (typically 2 or 3) - * @default 3 - */ - degree?: number; - /** - * Whether the spline is closed - * @default false - */ - closed?: boolean; - } - /** - * A path can contain multiple segments of different types (lines, arcs, polylines, circles, splines) - * Similar to OCCT wires that can combine different edge types - */ - class DxfPathDto { - constructor( - segments?: ( - | DxfLineSegmentDto - | DxfArcSegmentDto - | DxfCircleSegmentDto - | DxfPolylineSegmentDto - | DxfSplineSegmentDto - )[] - ); - /** - * Array of segments that make up this path - * Can include lines, arcs, circles, polylines, and splines - * @default undefined - */ - segments: ( - | DxfLineSegmentDto - | DxfArcSegmentDto - | DxfCircleSegmentDto - | DxfPolylineSegmentDto - | DxfSplineSegmentDto - )[]; - } - /** - * A part containing multiple paths on the same layer with the same color - */ - class DxfPathsPartDto { - constructor(layer?: string, color?: Base.Color, paths?: DxfPathDto[]); - /** - * Layer name for all paths in this part - * @default Default - */ - layer: string; - /** - * Color for all paths in this part - * @default #000000 - */ - color: Base.Color; - /** - * Array of paths, each containing multiple segments - * @default undefined - */ - paths: DxfPathDto[]; - } - /** - * Main DXF model containing all path parts - */ - class DxfModelDto { - constructor( - dxfPathsParts?: DxfPathsPartDto[], - colorFormat?: "aci" | "truecolor", - acadVersion?: "AC1009" | "AC1015" - ); - /** - * Array of path parts, each containing paths with segments - * @default undefined - */ - dxfPathsParts: DxfPathsPartDto[]; - /** - * Color format to use in the DXF file - * - "aci": AutoCAD Color Index (1-255) - Better compatibility with older CAD software like Design CAD 3D Max - * - "truecolor": 24-bit RGB true color - Full color spectrum, requires newer CAD software - * @default aci - */ - colorFormat?: "aci" | "truecolor"; - /** - * AutoCAD version format for DXF file - * - "AC1009": AutoCAD R12/R11 - Maximum compatibility with older CAD software (e.g., Design CAD 3D Max) - * - "AC1015": AutoCAD 2000 - Modern format with extended features - * @default AC1009 - */ - acadVersion?: "AC1009" | "AC1015"; - } - } - declare namespace Line { - class LinePointsDto { - /** - * Provide options without default values - */ - constructor(start?: Base.Point3, end?: Base.Point3); - /** - * Start point - * @default undefined - */ - start?: Base.Point3; - /** - * End point - * @default undefined - */ - end?: Base.Point3; - } - class LineStartEndPointsDto { - /** - * Provide options without default values - */ - constructor(startPoints?: Base.Point3[], endPoints?: Base.Point3[]); - /** - * Start points - * @default undefined - */ - startPoints: Base.Point3[]; - /** - * End points - * @default undefined - */ - endPoints: Base.Point3[]; - } - class DrawLineDto { - /** - * Provide options without default values - */ - constructor( - line?: LinePointsDto, - opacity?: number, - colours?: string | string[], - size?: number, - updatable?: boolean, - lineMesh?: T - ); - /** - * Line - * @default undefined - */ - line?: LinePointsDto; - /** - * Value between 0 and 1 - * @default 1 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - opacity?: number; - /** - * Hex colour string - * @default #444444 - */ - colours?: string | string[]; - /** - * Width of the line - * @default 3 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - size?: number; - /** - * Indicates wether the position of this line will change in time - * @default false - */ - updatable?: boolean; - /** - * Line mesh variable in case it already exists and needs updating - * @default undefined - */ - lineMesh?: T; - } - class DrawLinesDto { - /** - * Provide options without default values - */ - constructor( - lines?: LinePointsDto[], - opacity?: number, - colours?: string | string[], - size?: number, - updatable?: boolean, - linesMesh?: T - ); - /** - * Lines - * @default undefined - */ - lines?: LinePointsDto[]; - /** - * Value between 0 and 1 - * @default 1 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - opacity?: number; - /** - * Hex colour string - * @default #444444 - */ - colours?: string | string[]; - /** - * Width of the line - * @default 3 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - size?: number; - /** - * Indicates wether the position of these lines will change in time - * @default false - */ - updatable?: boolean; - /** - * Line mesh variable in case it already exists and needs updating - * @default undefined - */ - linesMesh?: T; - } - class PointsLinesDto { - constructor(points?: Base.Point3[]); - /** - * Points - * @default undefined - */ - points?: Base.Point3[]; - } - class LineDto { - constructor(line?: LinePointsDto); - /** - * Line to convert - * @default undefined - */ - line?: LinePointsDto; - } - class SegmentDto { - constructor(segment?: Base.Segment3); - /** - * Segment - * @default undefined - */ - segment?: Base.Segment3; - } - class SegmentsDto { - constructor(segments?: Base.Segment3[]); - /** - * Segments - * @default undefined - */ - segments?: Base.Segment3[]; - } - class LinesDto { - constructor(lines?: LinePointsDto[]); - /** - * Lines to convert - * @default undefined - */ - lines?: LinePointsDto[]; - } - class LineLineIntersectionDto { - constructor( - line1?: LinePointsDto, - line2?: LinePointsDto, - tolerance?: number - ); - /** - * First line - * @default undefined - */ - line1?: LinePointsDto; - /** - * Second line - * @default undefined - */ - line2?: LinePointsDto; - /** - * Set to false if you want to check for infinite lines - * @default true - */ - checkSegmentsOnly?: boolean; - /** - * Tolerance for intersection - * @default 0.01 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - tolerance?: number; - } - class PointOnLineDto { - constructor(line?: LinePointsDto, param?: number); - /** - * Line to get point on - * @default undefined - */ - line?: LinePointsDto; - /** - * Param to use for point on line - * @default 0.5 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - param?: number; - } - class TransformLineDto { - constructor( - line?: LinePointsDto, - transformation?: Base.TransformMatrixes - ); - /** - * Line to transform - * @default undefined - */ - line?: LinePointsDto; - /** - * Transformation matrix or a list of transformation matrixes - * @default undefined - */ - transformation?: Base.TransformMatrixes; - } - class TransformsLinesDto { - constructor( - lines?: LinePointsDto[], - transformation?: Base.TransformMatrixes[] - ); - /** - * Lines to transform - * @default undefined - */ - lines?: LinePointsDto[]; - /** - * Transformations matrix or a list of transformations matrixes - * @default undefined - */ - transformation?: Base.TransformMatrixes[]; - } - class TransformLinesDto { - constructor( - lines?: LinePointsDto[], - transformation?: Base.TransformMatrixes - ); - /** - * Lines to transform - * @default undefined - */ - lines?: LinePointsDto[]; - /** - * Transformation matrix or a list of transformation matrixes - * @default undefined - */ - transformation?: Base.TransformMatrixes; - } - } - declare namespace Lists { - enum firstLastEnum { - first = "first", - last = "last", - } - class ListItemDto { - constructor(list?: T[], index?: number, clone?: boolean); - /** - * The list to interrogate - * @default undefined - */ - list: T[]; - /** - * Index of the item in the list - 0 means first. - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - index: number; - /** - * Tries to make structured clone of the incoming list data in the component, sometimes it may not be possible due to circular structures or other types of error - * @default true - */ - clone?: boolean; - } - class SubListDto { - constructor( - list?: T[], - indexStart?: number, - indexEnd?: number, - clone?: boolean - ); - /** - * The list to split into a sublist - * @default undefined - */ - list: T[]; - /** - * Index from which to start the sublist - 0 means first. - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - indexStart: number; - /** - * Index to which to end the sublist - 0 means first. - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - indexEnd: number; - /** - * Tries to clone the data in the component, sometimes it may not be possible if structure is circular - * @default true - */ - clone?: boolean; - } - class ListCloneDto { - constructor(list?: T[], clone?: boolean); - /** - * The list to interrogate - * @default undefined - */ - list: T[]; - /** - * Tries to make structured clone of the incoming list data in the component, sometimes it may not be possible due to circular structures or other types of error - * @default true - */ - clone?: boolean; - } - class RepeatInPatternDto { - constructor(list?: T[]); - /** - * The list to interrogate - * @default undefined - */ - list: T[]; - /** - * Tries to make structured clone of the incoming list data in the component, sometimes it may not be possible due to circular structures or other types of error - * @default true - */ - clone?: boolean; - /** - * The limit of the length of the list - * @default 100 - * @minimum 1 - * @maximum Infinity - * @step 1 - */ - lengthLimit: number; - } - class SortDto { - constructor(list?: T[], clone?: boolean, orderAsc?: boolean); - /** - * The list to interrogate - * @default undefined - */ - list: T[]; - /** - * Tries to make structured clone of the incoming list data in the component, sometimes it may not be possible due to circular structures or other types of error - * @default true - */ - clone?: boolean; - /** - * If true, the list will be sorted in ascending order, otherwise in descending order - * @default true - */ - orderAsc: boolean; - } - class SortJsonDto { - constructor(list?: T[], clone?: boolean, orderAsc?: boolean); - /** - * The list to interrogate - * @default undefined - */ - list: T[]; - /** - * Tries to make structured clone of the incoming list data in the component, sometimes it may not be possible due to circular structures or other types of error - * @default true - */ - clone?: boolean; - /** - * If true, the list will be sorted in ascending order, otherwise in descending order - * @default true - */ - orderAsc: boolean; - /** - * The property to sort by - * @default propName - */ - property: string; - } - class ListDto { - constructor(list?: T[]); - /** - * The list - * @default undefined - */ - list: T[]; - } - class GroupListDto { - constructor(list?: T[], nrElements?: number, keepRemainder?: boolean); - /** - * The list of elements to group together - * @default undefined - */ - list: T[]; - /** - * The number of elements in each group - * @default 2 - * @minimum 1 - * @maximum Infinity - * @step 1 - */ - nrElements: number; - /** - * If true, the remainder of the list will be added as a separate group - * @default false - */ - keepRemainder: boolean; - } - class MultiplyItemDto { - constructor(item?: T, times?: number); - /** - * The item to multiply - * @default undefined - */ - item: T; - /** - * Times to multiply - * @default 10 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - times: number; - } - class AddItemAtIndexDto { - constructor(list?: T[], item?: T, index?: number, clone?: boolean); - /** - * The list to which item needs to be added - * @default undefined - */ - list: T[]; - /** - * The item to add - * @default undefined - */ - item: T; - /** - * The index to add the item at - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - index: number; - /** - * Tries to make structured clone of the incoming list data in the component, sometimes it may not be possible due to circular structures or other types of error - * @default true - */ - clone?: boolean; - } - class AddItemAtIndexesDto { - constructor(list?: T[], item?: T, indexes?: number[], clone?: boolean); - /** - * The list to which item needs to be added - * @default undefined - */ - list: T[]; - /** - * The item to add - * @default undefined - */ - item: T; - /** - * The index to add the item at - * @default [0] - */ - indexes: number[]; - /** - * Tries to make structured clone of the incoming list data in the component, sometimes it may not be possible due to circular structures or other types of error - * @default true - */ - clone?: boolean; - } - class AddItemsAtIndexesDto { - constructor( - list?: T[], - items?: T[], - indexes?: number[], - clone?: boolean - ); - /** - * The list to which item needs to be added - * @default undefined - */ - list: T[]; - /** - * The item to add - * @default undefined - */ - items: T[]; - /** - * The index to add the item at - * @default [0] - */ - indexes: number[]; - /** - * Tries to make structured clone of the incoming list data in the component, sometimes it may not be possible due to circular structures or other types of error - * @default true - */ - clone?: boolean; - } - class RemoveItemAtIndexDto { - constructor(list?: T[], index?: number, clone?: boolean); - /** - * The list from which item needs to be removed - * @default undefined - */ - list: T[]; - /** - * The index to on which remove item - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - index: number; - /** - * Tries to make structured clone of the incoming list data in the component, sometimes it may not be possible due to circular structures or other types of error - * @default true - */ - clone?: boolean; - } - class RemoveItemsAtIndexesDto { - constructor(list?: T[], indexes?: number[], clone?: boolean); - /** - * The list from which item needs to be removed - * @default undefined - */ - list: T[]; - /** - * The indexes that should be removed - * @default undefined - */ - indexes: number[]; - /** - * Tries to make structured clone of the incoming list data in the component, sometimes it may not be possible due to circular structures or other types of error - * @default true - */ - clone?: boolean; - } - class RemoveNthItemDto { - constructor(list?: T[], nth?: number, offset?: number, clone?: boolean); - /** - * The list from which item needs to be removed - * @default undefined - */ - list: T[]; - /** - * The nth item to remove - * @default 2 - * @minimum 1 - * @maximum Infinity - * @step 1 - */ - nth: number; - /** - * The offset from which to start counting - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - offset: number; - /** - * Tries to make structured clone of the incoming list data in the component, sometimes it may not be possible due to circular structures or other types of error - * @default true - */ - clone?: boolean; - } - class RandomThresholdDto { - constructor(list?: T[], threshold?: number, clone?: boolean); - /** - * The list from which item needs to be updated - * @default undefined - */ - list: T[]; - /** - * Threshold for items - * @default 0.5 - * @minimum 0 - * @maximum 1 - * @step 1 - */ - threshold: number; - /** - * Tries to make structured clone of the incoming list data in the component, sometimes it may not be possible due to circular structures or other types of error - * @default true - */ - clone?: boolean; - } - class RemoveDuplicatesDto { - constructor(list?: T[], clone?: boolean); - /** - * The list from which item needs to be removed - * @default undefined - */ - list: T[]; - /** - * Tries to make structured clone of the incoming list data in the component, sometimes it may not be possible due to circular structures or other types of error - * @default true - */ - clone?: boolean; - } - class RemoveDuplicatesToleranceDto { - constructor(list?: T[], clone?: boolean, tolerance?: number); - /** - * The list from which item needs to be removed - * @default undefined - */ - list: T[]; - /** - * The tolerance to apply - * @default 1e-7 - * @minimum 0 - * @maximum Infinity - * @step 1e-7 - */ - tolerance: number; - /** - * Tries to make structured clone of the incoming list data in the component, sometimes it may not be possible due to circular structures or other types of error - * @default true - */ - clone?: boolean; - } - class GetByPatternDto { - constructor(list?: T[], pattern?: boolean[]); - /** - * The list from which we need to get an item - * @default undefined - */ - list: T[]; - /** - * The list of booleans to be used as a pattern (true means get, false means skip) - * @default [true, true, false] - */ - pattern: boolean[]; - } - class GetNthItemDto { - constructor(list?: T[], nth?: number, offset?: number, clone?: boolean); - /** - * The list from which we need to get an item - * @default undefined - */ - list: T[]; - /** - * The nth item to get - * @default 2 - * @minimum 1 - * @maximum Infinity - * @step 1 - */ - nth: number; - /** - * The offset from which to start counting - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - offset: number; - /** - * Tries to make structured clone of the incoming list data in the component, sometimes it may not be possible due to circular structures or other types of error - * @default true - */ - clone?: boolean; - } - class GetLongestListLength { - constructor(lists?: T[]); - /** - * The list from which we need to get an item - * @default undefined - */ - lists: T[]; - } - class MergeElementsOfLists { - constructor(lists?: T[], level?: number); - /** - * The list from which we need to get an item - * @default undefined - */ - lists: T[]; - /** - * The level on which to merge the elements. 0 means first level - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - level: number; - } - class AddItemDto { - constructor(list?: T[], item?: T, clone?: boolean); - /** - * The list to which item needs to be added - * @default undefined - */ - list: T[]; - /** - * The item to add - * @default undefined - */ - item: T; - /** - * Tries to make structured clone of the incoming list data in the component, sometimes it may not be possible due to circular structures or other types of error - * @default true - */ - clone?: boolean; - } - class AddItemFirstLastDto { - constructor( - list?: T[], - item?: T, - position?: firstLastEnum, - clone?: boolean - ); - /** - * The list to which item needs to be added - * @default undefined - */ - list: T[]; - /** - * The item to add - * @default undefined - */ - item: T; - /** - * The option if the item needs to be added at the beginning or the end of the list - * @default last - */ - position: firstLastEnum; - /** - * Tries to make structured clone of the incoming list data in the component, sometimes it may not be possible due to circular structures or other types of error - * @default true - */ - clone?: boolean; - } - class ConcatenateDto { - constructor(lists?: T[][], clone?: boolean); - /** - * The lists to concatenate - * @default undefined - */ - lists: T[][]; - /** - * Tries to make structured clone of the incoming list data in the component, sometimes it may not be possible due to circular structures or other types of error - * @default true - */ - clone?: boolean; - } - class IncludesDto { - constructor(list?: T[], item?: T); - /** - * The list to check - * @default undefined - */ - list: T[]; - /** - * The item to look for - * @default undefined - */ - item: T; - } - class InterleaveDto { - constructor(lists?: T[][], clone?: boolean); - /** - * The lists to interleave - * @default undefined - */ - lists: T[][]; - /** - * Tries to make structured clone of the incoming list data in the component, sometimes it may not be possible due to circular structures or other types of error - * @default true - */ - clone?: boolean; - } - } - declare namespace Logic { - enum BooleanOperatorsEnum { - less = "<", - lessOrEqual = "<=", - greater = ">", - greaterOrEqual = ">=", - tripleEqual = "===", - tripleNotEqual = "!==", - equal = "==", - notEqual = "!=", - } - class ComparisonDto { - constructor(first?: T, second?: T, operator?: BooleanOperatorsEnum); - /** - * First item - * @default undefined - */ - first: T; - /** - * Second item - * @default undefined - */ - second: T; - /** - * Operator - * @default less - */ - operator: BooleanOperatorsEnum; - } - class BooleanDto { - constructor(boolean?: boolean); - /** - * Boolean value - * @default false - */ - boolean: boolean; - } - class BooleanListDto { - constructor(booleans?: boolean); - /** - * Boolean value - * @default undefined - */ - booleans: any; - } - class ValueGateDto { - constructor(value?: T, boolean?: boolean); - /** - * Value to transmit when gate will be released. When value is not released we will transmit undefined value - * @default undefined - */ - value: T; - /** - * Boolean value to release the gate - * @default false - */ - boolean: boolean; - } - class TwoValueGateDto { - constructor(value1?: T, value2?: U); - /** - * First value to check - * @default undefined - * @optional true - */ - value1?: T; - /** - * Second value to check - * @default undefined - * @optional true - */ - value2?: U; - } - class RandomBooleansDto { - constructor(length?: number); - /** - * Length of the list - * @default 10 - * @minimum 1 - * @maximum Infinity - * @step 1 - */ - length: number; - /** - * Threshold for true value between 0 and 1. The closer the value is to 1 the more true values there will be in the list. - * @default 0.5 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - trueThreshold: number; - } - class TwoThresholdRandomGradientDto { - /** - * Numbers to remap to bools - * @default undefined - */ - numbers: number[]; - /** - * Threshold for the numeric value until which the output will be true - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - thresholdTotalTrue: number; - /** - * Threshold for the numeric value until which the output will be true - * @default 2 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - thresholdTotalFalse: number; - /** - * Number of levels to go through in between thresholds for gradient - * @default 10 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - nrLevels: number; - } - class ThresholdBooleanListDto { - /** - * Numbers to remap to bools based on threshold - * @default undefined - */ - numbers: number[]; - /** - * Threshold for the numeric value until which the output will be true. - * If number in the list is larger than this threshold it will become false if inverse stays false. - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - threshold: number; - /** - * True values become false and false values become true - * @default false - */ - inverse: boolean; - } - class ThresholdGapsBooleanListDto { - /** - * Numbers to remap to bools based on threshold - * @default undefined - */ - numbers: number[]; - /** - * 2D arrays representing gaps of the thresholds on which numbers should be flipped from false to true if inverse is false. - * @default undefined - */ - gapThresholds: Base.Vector2[]; - /** - * True values become false and false values become true - * @default false - */ - inverse: boolean; - } - } - declare namespace Math { - enum mathTwoNrOperatorEnum { - add = "add", - subtract = "subtract", - multiply = "multiply", - divide = "divide", - power = "power", - modulus = "modulus", - } - enum mathOneNrOperatorEnum { - absolute = "absolute", - negate = "negate", - ln = "ln", - log10 = "log10", - tenPow = "tenPow", - round = "round", - floor = "floor", - ceil = "ceil", - sqrt = "sqrt", - sin = "sin", - cos = "cos", - tan = "tan", - asin = "asin", - acos = "acos", - atan = "atan", - log = "log", - exp = "exp", - radToDeg = "radToDeg", - degToRad = "degToRad", - } - enum easeEnum { - easeInSine = "easeInSine", - easeOutSine = "easeOutSine", - easeInOutSine = "easeInOutSine", - easeInQuad = "easeInQuad", - easeOutQuad = "easeOutQuad", - easeInOutQuad = "easeInOutQuad", - easeInCubic = "easeInCubic", - easeOutCubic = "easeOutCubic", - easeInOutCubic = "easeInOutCubic", - easeInQuart = "easeInQuart", - easeOutQuart = "easeOutQuart", - easeInOutQuart = "easeInOutQuart", - easeInQuint = "easeInQuint", - easeOutQuint = "easeOutQuint", - easeInOutQuint = "easeInOutQuint", - easeInExpo = "easeInExpo", - easeOutExpo = "easeOutExpo", - easeInOutExpo = "easeInOutExpo", - easeInCirc = "easeInCirc", - easeOutCirc = "easeOutCirc", - easeInOutCirc = "easeInOutCirc", - easeInElastic = "easeInElastic", - easeOutElastic = "easeOutElastic", - easeInOutElastic = "easeInOutElastic", - easeInBack = "easeInBack", - easeOutBack = "easeOutBack", - easeInOutBack = "easeInOutBack", - easeInBounce = "easeInBounce", - easeOutBounce = "easeOutBounce", - easeInOutBounce = "easeInOutBounce", - } - class ModulusDto { - constructor(number?: number, modulus?: number); - /** - * Number - * @default 1 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - number: number; - /** - * Modulus - * @default 1 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - modulus: number; - } - class NumberDto { - constructor(number?: number); - /** - * Number - * @default 1 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - number: number; - } - class EaseDto { - constructor(x?: number); - /** - * X value param between 0-1 - * @default 0.5 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - x: number; - /** - * Minimum value - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - min: number; - /** - * Maximum value - * @default 1 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - max: number; - /** - * Ease function - * @default easeInSine - */ - ease: easeEnum; - } - class RoundToDecimalsDto { - constructor(number?: number, decimalPlaces?: number); - /** - * Number to round - * @default 1.123456 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - number: number; - /** - * Number of decimal places - * @default 2 - * @minimum -Infinity - * @maximum Infinity - * @step 1 - */ - decimalPlaces: number; - } - class ActionOnTwoNumbersDto { - constructor( - first?: number, - second?: number, - operation?: mathTwoNrOperatorEnum - ); - /** - * First number - * @default 1 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - first: number; - /** - * Second number - * @default 1 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - second: number; - /** - * Point - * @default add - */ - operation: mathTwoNrOperatorEnum; - } - class TwoNumbersDto { - constructor(first?: number, second?: number); - /** - * First number - * @default 1 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - first: number; - /** - * Second number - * @default 2 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - second: number; - } - class ActionOnOneNumberDto { - constructor(number?: number, operation?: mathOneNrOperatorEnum); - /** - * First number - * @default 1 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - number: number; - /** - * Point - * @default absolute - */ - operation: mathOneNrOperatorEnum; - } - class RemapNumberDto { - constructor( - number?: number, - fromLow?: number, - fromHigh?: number, - toLow?: number, - toHigh?: number - ); - /** - * Number to remap - * @default 0.5 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - number: number; - /** - * First number range min - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - fromLow: number; - /** - * Map to range min - * @default 1 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - fromHigh: number; - /** - * First number range max - * @default 1 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - toLow: number; - /** - * Map to range max - * @default 2 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - toHigh: number; - } - class RandomNumberDto { - constructor(low?: number, high?: number); - /** - * Low range of random value - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - low: number; - /** - * High range of random value - * @default 1 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - high: number; - } - class RandomNumbersDto { - constructor(low?: number, high?: number, count?: number); - /** - * Low range of random value - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - low: number; - /** - * High range of random value - * @default 1 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - high: number; - /** - * Number of produced random values - * @default 10 - * @minimum -Infinity - * @maximum Infinity - * @step 1 - */ - count: number; - } - class ToFixedDto { - constructor(number?: number, decimalPlaces?: number); - /** - * Number to round - * @default undefined - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - number: number; - /** - * Number of decimal places - * @default 2 - * @minimum -Infinity - * @maximum Infinity - * @step 1 - */ - decimalPlaces: number; - } - class ClampDto { - constructor(number?: number, min?: number, max?: number); - /** - * Number to clamp - * @default 0.5 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - number: number; - /** - * Minimum value - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - min: number; - /** - * Maximum value - * @default 1 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - max: number; - } - class LerpDto { - constructor(start?: number, end?: number, t?: number); - /** - * Start value - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - start: number; - /** - * End value - * @default 1 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - end: number; - /** - * Interpolation value (0-1) - * @default 0.5 - * @minimum -Infinity - * @maximum Infinity - * @step 0.01 - */ - t: number; - } - class InverseLerpDto { - constructor(start?: number, end?: number, value?: number); - /** - * Start value - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - start: number; - /** - * End value - * @default 1 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - end: number; - /** - * Value to find t for - * @default 0.5 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - value: number; - } - class WrapDto { - constructor(number?: number, min?: number, max?: number); - /** - * Number to wrap - * @default 1.5 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - number: number; - /** - * Minimum value - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - min: number; - /** - * Maximum value - * @default 1 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - max: number; - } - class PingPongDto { - constructor(t?: number, length?: number); - /** - * Time value - * @default 0.5 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - t: number; - /** - * Length of ping pong - * @default 1 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - length: number; - } - class MoveTowardsDto { - constructor(current?: number, target?: number, maxDelta?: number); - /** - * Current value - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - current: number; - /** - * Target value - * @default 1 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - target: number; - /** - * Maximum change amount - * @default 0.1 - * @minimum -Infinity - * @maximum Infinity - * @step 0.01 - */ - maxDelta: number; - } - } - declare namespace Mesh { - class SignedDistanceFromPlaneToPointDto { - constructor(point?: Base.Point3, plane?: Base.TrianglePlane3); - /** - * Point from which to find the distance - * @default undefined - */ - point?: Base.Point3; - /** - * Triangle plane to which the distance is calculated - * @default undefined - */ - plane?: Base.TrianglePlane3; - } - class TriangleDto { - constructor(triangle?: Base.Triangle3); - /** - * Triangle to be used - * @default undefined - */ - triangle?: Base.Triangle3; - } - class TriangleToleranceDto { - constructor(triangle?: Base.Triangle3); - /** - * Triangle to be used - * @default undefined - */ - triangle?: Base.Triangle3; - /** - * Tolerance for the calculation - * @default 1e-7 - * @minimum -Infinity - * @maximum Infinity - * @step 1e-7 - */ - tolerance?: number; - } - class TriangleTriangleToleranceDto { - constructor( - triangle1?: Base.Triangle3, - triangle2?: Base.Triangle3, - tolerance?: number - ); - /** - * First triangle - * @default undefined - */ - triangle1?: Base.Triangle3; - /** - * Second triangle - * @default undefined - */ - triangle2?: Base.Triangle3; - /** - * Tolerance for the calculation - * @default 1e-7 - * @minimum -Infinity - * @maximum Infinity - * @step 1e-7 - */ - tolerance?: number; - } - class MeshMeshToleranceDto { - constructor(mesh1?: Base.Mesh3, mesh2?: Base.Mesh3, tolerance?: number); - /** - * First mesh - * @default undefined - */ - mesh1?: Base.Mesh3; - /** - * Second mesh - * @default undefined - */ - mesh2?: Base.Mesh3; - /** - * Tolerance for the calculation - * @default 1e-7 - * @minimum -Infinity - * @maximum Infinity - * @step 1e-7 - */ - tolerance?: number; - } - } - declare namespace Point { - class PointDto { - constructor(point?: Base.Point3); - /** - * Point - * @default undefined - */ - point: Base.Point3; - } - class PointXYZDto { - constructor(x?: number, y?: number, z?: number); - /** - * Point - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - x: number; - /** - * Point - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - y: number; - /** - * Point - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - z: number; - } - class PointXYDto { - constructor(x?: number, y?: number); - /** - * Point - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - x: number; - /** - * Point - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - y: number; - } - class PointsDto { - constructor(points?: Base.Point3[]); - /** - * Points - * @default undefined - */ - points: Base.Point3[]; - } - class TwoPointsDto { - constructor(point1?: Base.Point3, point2?: Base.Point3); - /** - * Point 1 - * @default undefined - */ - point1: Base.Point3; - /** - * Point 2 - * @default undefined - */ - point2: Base.Point3; - } - class DrawPointDto { - /** - * Provide options without default values - */ - constructor( - point?: Base.Point3, - opacity?: number, - size?: number, - colours?: string | string[], - updatable?: boolean, - pointMesh?: T - ); - /** - * Point - * @default undefined - */ - point: Base.Point3; - /** - * Value between 0 and 1 - * @default 1 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - opacity: number; - /** - * Size of the point - * @default 3 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - size: number; - /** - * Hex colour string - * @default #444444 - */ - colours: string | string[]; - /** - * Indicates wether the position of this point will change in time - * @default false - */ - updatable: boolean; - /** - * Point mesh variable in case it already exists and needs updating - * @default undefined - */ - pointMesh?: T; - } - class DrawPointsDto { - /** - * Provide options without default values - */ - constructor( - points?: Base.Point3[], - opacity?: number, - size?: number, - colours?: string | string[], - updatable?: boolean, - pointsMesh?: T - ); - /** - * Point - * @default undefined - */ - points: Base.Point3[]; - /** - * Value between 0 and 1 - * @default 1 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - opacity: number; - /** - * Size of the points - * @default 0.1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - size: number; - /** - * Hex colour string or collection of strings - * @default #444444 - */ - colours: string | string[]; - /** - * Indicates wether the position of this point will change in time - * @default false - */ - updatable: boolean; - /** - * Points mesh variable in case it already exists and needs updating - * @default undefined - */ - pointsMesh?: T; - } - class TransformPointDto { - constructor( - point?: Base.Point3, - transformation?: Base.TransformMatrixes - ); - /** - * Point to transform - * @default undefined - */ - point: Base.Point3; - /** - * Transformation matrix or a list of transformation matrixes - * @default undefined - */ - transformation: Base.TransformMatrixes; - } - class TransformPointsDto { - constructor( - points?: Base.Point3[], - transformation?: Base.TransformMatrixes - ); - /** - * Points to transform - * @default undefined - */ - points: Base.Point3[]; - /** - * Transformation matrix or a list of transformation matrixes - * @default undefined - */ - transformation: Base.TransformMatrixes; - } - class TranslatePointsWithVectorsDto { - constructor(points?: Base.Point3[], translations?: Base.Vector3[]); - /** - * Points to transform - * @default undefined - */ - points: Base.Point3[]; - /** - * Translation vectors for each point - * @default undefined - */ - translations: Base.Vector3[]; - } - class TranslatePointsDto { - constructor(points?: Base.Point3[], translation?: Base.Vector3); - /** - * Points to transform - * @default undefined - */ - points: Base.Point3[]; - /** - * Translation vector with x, y and z values - * @default undefined - */ - translation: Base.Vector3; - } - class TranslateXYZPointsDto { - constructor(points?: Base.Point3[], x?: number, y?: number, z?: number); - /** - * Points to transform - * @default undefined - */ - points: Base.Point3[]; - /** - * X vector value - * @default 0 - */ - x: number; - /** - * Y vector value - * @default 1 - */ - y: number; - /** - * Z vector value - * @default 0 - */ - z: number; - } - class ScalePointsCenterXYZDto { - constructor( - points?: Base.Point3[], - center?: Base.Point3, - scaleXyz?: Base.Vector3 - ); - /** - * Points to transform - * @default undefined - */ - points: Base.Point3[]; - /** - * The center from which the scaling is applied - * @default [0, 0, 0] - */ - center: Base.Point3; - /** - * Scaling factors for each axis [1, 2, 1] means that Y axis will be scaled 200% and both x and z axis will remain on 100% - * @default [1, 1, 1] - */ - scaleXyz: Base.Vector3; - } - class StretchPointsDirFromCenterDto { - constructor( - points?: Base.Point3[], - center?: Base.Point3, - direction?: Base.Vector3, - scale?: number - ); - /** - * Points to transform - * @default undefined - */ - points?: Base.Point3[]; - /** - * The center from which the scaling is applied - * @default [0, 0, 0] - */ - center?: Base.Point3; - /** - * Stretch direction vector - * @default [0, 0, 1] - */ - direction?: Base.Vector3; - /** - * The scale factor to apply along the direction vector. 1.0 means no change. - * @default 2 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - scale?: number; - } - class RotatePointsCenterAxisDto { - constructor( - points?: Base.Point3[], - angle?: number, - axis?: Base.Vector3, - center?: Base.Point3 - ); - /** - * Points to transform - * @default undefined - */ - points: Base.Point3[]; - /** - * Angle of rotation in degrees - * @default 90 - * @minimum -Infinity - * @maximum Infinity - * @step 1 - */ - angle: number; - /** - * Axis vector for rotation - * @default [0, 1, 0] - */ - axis: Base.Vector3; - /** - * The center from which the axis is pointing - * @default [0, 0, 0] - */ - center: Base.Point3; - } - class TransformsForPointsDto { - constructor( - points?: Base.Point3[], - transformation?: Base.TransformMatrixes[] - ); - /** - * Points to transform - * @default undefined - */ - points: Base.Point3[]; - /** - * Transformations that have to match nr of points - * @default undefined - */ - transformation: Base.TransformMatrixes[]; - } - class ThreePointsNormalDto { - constructor( - point1?: Base.Point3, - point2?: Base.Point3, - point3?: Base.Point3, - reverseNormal?: boolean - ); - /** - * Point 1 - * @default undefined - */ - point1: Base.Point3; - /** - * Point 2 - * @default undefined - */ - point2: Base.Point3; - /** - * Point 3 - * @default undefined - */ - point3: Base.Point3; - /** - * Reverse normal direction - * @default false - */ - reverseNormal: boolean; - } - class ThreePointsToleranceDto { - constructor( - start?: Base.Point3, - center?: Base.Point3, - end?: Base.Point3, - tolerance?: number - ); - /** - * Start point - * @default undefined - */ - start?: Base.Point3; - /** - * Center point - * @default undefined - */ - center?: Base.Point3; - /** - * End point - * @default undefined - */ - end?: Base.Point3; - /** - * Tolerance for the calculation - * @default 1e-7 - * @minimum -Infinity - * @maximum Infinity - * @step 1e-7 - */ - tolerance: number; - } - class PointsMaxFilletsHalfLineDto { - constructor( - points?: Base.Point3[], - checkLastWithFirst?: boolean, - tolerance?: number - ); - /** - * Points to transform - * @default undefined - */ - points?: Base.Point3[]; - /** - * Check first and last point for duplicates - * @default false - */ - checkLastWithFirst?: boolean; - /** - * Tolerance for the calculation - * @default 1e-7 - * @minimum -Infinity - * @maximum Infinity - * @step 1e-7 - */ - tolerance?: number; - } - class RemoveConsecutiveDuplicatesDto { - constructor( - points?: Base.Point3[], - tolerance?: number, - checkFirstAndLast?: boolean - ); - /** - * Points to transform - * @default undefined - */ - points: Base.Point3[]; - /** - * Tolerance for removing duplicates - * @default 1e-7 - * @minimum 0 - * @maximum Infinity - * @step 1e-7 - */ - tolerance: number; - /** - * Check first and last point for duplicates - */ - checkFirstAndLast: boolean; - } - class ClosestPointFromPointsDto { - constructor(points?: Base.Point3[], point?: Base.Point3); - /** - * Points to transform - * @default undefined - */ - points: Base.Point3[]; - /** - * Transformation matrix or a list of transformation matrixes - * @default undefined - */ - point: Base.Point3; - } - class TwoPointsToleranceDto { - constructor( - point1?: Base.Point3, - point2?: Base.Point3, - tolerance?: number - ); - /** - * First point to compare - * @default undefined - */ - point1?: Base.Point3; - /** - * Second point to compare - * @default undefined - */ - point2?: Base.Point3; - /** - * Tolerance for the calculation - * @default 1e-7 - * @minimum -Infinity - * @maximum Infinity - * @step 1e-7 - */ - tolerance?: number; - } - class StartEndPointsDto { - constructor(startPoint?: Base.Point3, endPoint?: Base.Point3); - /** - * Start point - * @default undefined - */ - startPoint: Base.Point3; - /** - * End point - * @default undefined - */ - endPoint: Base.Point3; - } - class StartEndPointsListDto { - constructor(startPoint?: Base.Point3, endPoints?: Base.Point3[]); - /** - * Start point - * @default undefined - */ - startPoint: Base.Point3; - /** - * End point - * @default undefined - */ - endPoints: Base.Point3[]; - } - class MultiplyPointDto { - constructor(point?: Base.Point3, amountOfPoints?: number); - /** - * Point for multiplication - * @default undefined - */ - point: Base.Point3; - /** - * Number of points to create in the list - * @default undefined - */ - amountOfPoints: number; - } - class SpiralDto { - constructor( - radius?: number, - numberPoints?: number, - widening?: number, - factor?: number, - phi?: number - ); - /** - * Identifies phi angle - * @default 0.9 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - phi: number; - /** - * Identifies how many points will be created - * @default 200 - * @minimum 0 - * @maximum Infinity - * @step 10 - */ - numberPoints: number; - /** - * Widening factor of the spiral - * @default 3 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - widening: number; - /** - * Radius of the spiral - * @default 6 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - radius: number; - /** - * Factor of the spiral - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - factor: number; - } - class HexGridScaledToFitDto { - constructor( - wdith?: number, - height?: number, - nrHexagonsU?: number, - nrHexagonsV?: number, - centerGrid?: boolean, - pointsOnGround?: boolean - ); - /** Total desired width for the grid area. The hexagon size will be derived from this and nrHexagonsU. - * @default 10 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - width?: number; - /** Total desired height for the grid area. Note: due to hexagon geometry, the actual grid height might differ slightly if maintaining regular hexagons based on width. - * @default 10 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - height?: number; - /** Number of hexagons desired in width. - * @default 10 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - nrHexagonsInWidth?: number; - /** Number of hexagons desired in height. - * @default 10 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - nrHexagonsInHeight?: number; - /** If true, the hexagons will be oriented with their flat sides facing up and down. - * @default false - */ - flatTop?: boolean; - /** If true, shift the entire grid up by half hex height. - * @default false - */ - extendTop?: boolean; - /** If true, shift the entire grid down by half hex height. - * @default false - */ - extendBottom?: boolean; - /** If true, shift the entire grid left by half hex width. - * @default false - */ - extendLeft?: boolean; - /** If true, shift the entire grid right by half hex width. - * @default false - */ - extendRight?: boolean; - /** If true, the grid center (based on totalWidth/totalHeight) will be at [0,0,0]. - * @default false - */ - centerGrid?: boolean; - /** If true, swaps Y and Z coordinates and sets Y to 0, placing points on the XZ ground plane. - * @default false - */ - pointsOnGround?: boolean; - } - class HexGridCentersDto { - constructor( - nrHexagonsX?: number, - nrHexagonsY?: number, - radiusHexagon?: number, - orientOnCenter?: boolean, - pointsOnGround?: boolean - ); - /** - * Number of hexagons on Y direction - * @default 21 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - nrHexagonsY: number; - /** - * Number of Hexagons on Z direction - * @default 21 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - nrHexagonsX: number; - /** - * radius of a single hexagon - * @default 0.2 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - radiusHexagon: number; - /** - * Orient hexagon points grid on center - * @default false - */ - orientOnCenter: boolean; - /** - * Orient points on the ground - * @default false - */ - pointsOnGround: boolean; - } - } - declare namespace Polyline { - class PolylineCreateDto { - /** - * Provide options without default values - */ - constructor(points?: Base.Point3[], isClosed?: boolean); - /** - * Points of the polyline - * @default undefined - */ - points?: Base.Point3[]; - /** - * Can contain is closed information - * @default false - */ - isClosed?: boolean; - } - class PolylinePropertiesDto { - /** - * Provide options without default values - */ - constructor(points?: Base.Point3[], isClosed?: boolean); - /** - * Points of the polyline - * @default undefined - */ - points?: Base.Point3[]; - /** - * Can contain is closed information - * @default false - */ - isClosed?: boolean; - /** - * Optional polyline color - * @default #444444 - */ - color?: string | number[]; - } - class PolylineDto { - constructor(polyline?: PolylinePropertiesDto); - /** - * Polyline with points - * @default undefined - */ - polyline?: PolylinePropertiesDto; - } - class PolylinesDto { - constructor(polylines?: PolylinePropertiesDto[]); - /** - * Polylines array - * @default undefined - */ - polylines?: PolylinePropertiesDto[]; - } - class TransformPolylineDto { - constructor( - polyline?: PolylinePropertiesDto, - transformation?: Base.TransformMatrixes - ); - /** - * Polyline to transform - * @default undefined - */ - polyline?: PolylinePropertiesDto; - /** - * Transformation matrix or a list of transformation matrixes - * @default undefined - */ - transformation?: Base.TransformMatrixes; - } - class DrawPolylineDto { - /** - * Provide options without default values - */ - constructor( - polyline?: PolylinePropertiesDto, - opacity?: number, - colours?: string | string[], - size?: number, - updatable?: boolean, - polylineMesh?: T - ); - /** - * Polyline - * @default undefined - */ - polyline?: PolylinePropertiesDto; - /** - * Value between 0 and 1 - * @default 1 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - opacity?: number; - /** - * Hex colour string - * @default #444444 - */ - colours?: string | string[]; - /** - * Width of the polyline - * @default 3 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - size?: number; - /** - * Indicates wether the position of this polyline will change in time - * @default false - */ - updatable?: boolean; - /** - * Line mesh variable in case it already exists and needs updating - * @default undefined - */ - polylineMesh?: T; - } - class DrawPolylinesDto { - /** - * Provide options without default values - */ - constructor( - polylines?: PolylinePropertiesDto[], - opacity?: number, - colours?: string | string[], - size?: number, - updatable?: boolean, - polylinesMesh?: T - ); - /** - * Polylines - * @default undefined - */ - polylines?: PolylinePropertiesDto[]; - /** - * Value between 0 and 1 - * @default 1 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - opacity?: number; - /** - * Hex colour string - * @default #444444 - */ - colours?: string | string[]; - /** - * Width of the polyline - * @default 3 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - size?: number; - /** - * Indicates wether the position of this polyline will change in time - * @default false - */ - updatable?: boolean; - /** - * Polyline mesh variable in case it already exists and needs updating - * @default undefined - */ - polylinesMesh?: T; - } - class SegmentsToleranceDto { - constructor(segments?: Base.Segment3[]); - /** - * Segments array - * @default undefined - */ - segments?: Base.Segment3[]; - /** - * Tolerance for the calculation - * @default 1e-5 - * @minimum -Infinity - * @maximum Infinity - * @step 1e-5 - */ - tolerance?: number; - } - class PolylineToleranceDto { - constructor(polyline?: PolylinePropertiesDto, tolerance?: number); - /** - * Polyline to check - * @default undefined - */ - polyline?: PolylinePropertiesDto; - /** - * Tolerance for the calculation - * @default 1e-5 - * @minimum -Infinity - * @maximum Infinity - * @step 1e-5 - */ - tolerance?: number; - } - class TwoPolylinesToleranceDto { - constructor( - polyline1?: PolylinePropertiesDto, - polyline2?: PolylinePropertiesDto, - tolerance?: number - ); - /** - * First polyline to check - * @default undefined - */ - polyline1?: PolylinePropertiesDto; - /** - * Second polyline to check - * @default undefined - */ - polyline2?: PolylinePropertiesDto; - /** - * Tolerance for the calculation - * @default 1e-5 - * @minimum -Infinity - * @maximum Infinity - * @step 1e-5 - */ - tolerance?: number; - } - } - declare namespace Text { - class TextDto { - constructor(text?: string); - /** - * The text - * @default Hello World - */ - text: string; - } - class TextSplitDto { - constructor(text?: string, separator?: string); - /** - * Text to split - * @default a,b,c - */ - text: string; - /** - * Text to split by - * @default , - */ - separator: string; - } - class TextReplaceDto { - constructor(text?: string, search?: string, replaceWith?: string); - /** - * Text to replace - * @default a-c - */ - text: string; - /** - * Text to search for - * @default - - */ - search: string; - /** - * Text to replace found occurences - * @default b - */ - replaceWith: string; - } - class TextJoinDto { - constructor(list?: string[], separator?: string); - /** - * Text to join - * @default undefined - */ - list: string[]; - /** - * Text to join by - * @default , - */ - separator: string; - } - class ToStringDto { - constructor(item?: T); - /** - * Item to stringify - * @default undefined - */ - item: T; - } - class ToStringEachDto { - constructor(list?: T[]); - /** - * Item to stringify - * @default undefined - */ - list: T[]; - } - class TextFormatDto { - constructor(text?: string, values?: string[]); - /** - * Text to format - * @default Hello {0} - */ - text: string; - /** - * Values to format - * @default ["World"] - */ - values: string[]; - } - class TextSearchDto { - constructor(text?: string, search?: string); - /** - * Text to search in - * @default hello world - */ - text: string; - /** - * Text to search for - * @default world - */ - search: string; - } - class TextSubstringDto { - constructor(text?: string, start?: number, end?: number); - /** - * Text to extract from - * @default hello world - */ - text: string; - /** - * Start index - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - start: number; - /** - * End index - * @default 5 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - end?: number; - } - class TextIndexDto { - constructor(text?: string, index?: number); - /** - * Text to get character from - * @default hello - */ - text: string; - /** - * Index of character - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - index: number; - } - class TextPadDto { - constructor(text?: string, length?: number, padString?: string); - /** - * Text to pad - * @default x - */ - text: string; - /** - * Target length - * @default 3 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - length: number; - /** - * String to pad with - * @default a - */ - padString: string; - } - class TextRepeatDto { - constructor(text?: string, count?: number); - /** - * Text to repeat - * @default ha - */ - text: string; - /** - * Number of repetitions - * @default 3 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - count: number; - } - class TextConcatDto { - constructor(texts?: string[]); - /** - * Texts to concatenate - * @default ["hello", " ", "world"] - */ - texts: string[]; - } - class TextRegexDto { - constructor(text?: string, pattern?: string, flags?: string); - /** - * Text to search in - * @default hello123world - */ - text: string; - /** - * Regular expression pattern - * @default [0-9]+ - */ - pattern: string; - /** - * Regular expression flags (g, i, m, s, u, y) - * @default g - */ - flags: string; - } - class TextRegexReplaceDto { - constructor( - text?: string, - pattern?: string, - flags?: string, - replaceWith?: string - ); - /** - * Text to search in - * @default hello123world456 - */ - text: string; - /** - * Regular expression pattern - * @default [0-9]+ - */ - pattern: string; - /** - * Regular expression flags (g, i, m, s, u, y) - * @default g - */ - flags: string; - /** - * Text to replace matches with - * @default X - */ - replaceWith: string; - } - class VectorCharDto { - constructor( - char?: string, - xOffset?: number, - yOffset?: number, - height?: number, - extrudeOffset?: number - ); - /** - * The text - * @default A - */ - char: string; - /** - * The x offset - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - xOffset?: number; - /** - * The y offset - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - yOffset?: number; - /** - * The height of the text - * @default 1 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - height?: number; - /** - * The extrude offset - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - extrudeOffset?: number; - } - class VectorTextDto { - constructor( - text?: string, - xOffset?: number, - yOffset?: number, - height?: number, - lineSpacing?: number, - letterSpacing?: number, - align?: Base.horizontalAlignEnum, - extrudeOffset?: number, - centerOnOrigin?: boolean - ); - /** - * The text - * @default Hello World - */ - text?: string; - /** - * The x offset - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - xOffset?: number; - /** - * The y offset - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - yOffset?: number; - /** - * The height of the text - * @default 1 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - height?: number; - /** - * The line spacing - * @default 1.4 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - lineSpacing?: number; - /** - * The letter spacing offset - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - letterSpacing?: number; - /** - * The extrude offset - * @default left - */ - align?: Base.horizontalAlignEnum; - /** - * The extrude offset - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - extrudeOffset?: number; - /** - * Will center text on 0, 0, 0 - * @default false - */ - centerOnOrigin?: boolean; - } - } - declare namespace Transforms { - class RotationCenterAxisDto { - constructor(angle?: number, axis?: Base.Vector3, center?: Base.Point3); - /** - * Angle of rotation in degrees - * @default 90 - * @minimum -Infinity - * @maximum Infinity - * @step 1 - */ - angle: number; - /** - * Axis vector for rotation - * @default [0, 1, 0] - */ - axis: Base.Vector3; - /** - * The center from which the axis is pointing - * @default [0, 0, 0] - */ - center: Base.Point3; - } - class RotationCenterDto { - constructor(angle?: number, center?: Base.Point3); - /** - * Angle of rotation in degrees - * @default 90 - * @minimum -Infinity - * @maximum Infinity - * @step 1 - */ - angle: number; - /** - * The center from which the axis is pointing - * @default [0, 0, 0] - */ - center: Base.Point3; - } - class RotationCenterYawPitchRollDto { - constructor( - yaw?: number, - pitch?: number, - roll?: number, - center?: Base.Point3 - ); - /** - * Yaw angle (Rotation around X) in degrees - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 1 - */ - yaw: number; - /** - * Pitch angle (Rotation around Y) in degrees - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 1 - */ - pitch: number; - /** - * Roll angle (Rotation around Z) in degrees - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 1 - */ - roll: number; - /** - * The center from which the rotations are applied - * @default [0, 0, 0] - */ - center: Base.Point3; - } - class ScaleXYZDto { - constructor(scaleXyz?: Base.Vector3); - /** - * Scaling factors for each axis [1, 2, 1] means that Y axis will be scaled 200% and both x and z axis will remain on 100% - * @default [1, 1, 1] - */ - scaleXyz: Base.Vector3; - } - class StretchDirCenterDto { - constructor( - scale?: number, - center?: Base.Point3, - direction?: Base.Vector3 - ); - /** The center point around which to stretch. - * @default [0, 0, 0] - */ - center?: Base.Point3; - /** The direction vector along which to stretch. Does not need to be normalized initially. - * @default [0, 0, 1] - */ - direction?: Base.Vector3; - /** The scale factor to apply along the direction vector. 1.0 means no change. - * @default 2 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - scale?: number; - } - class ScaleCenterXYZDto { - constructor(center?: Base.Point3, scaleXyz?: Base.Vector3); - /** - * The center from which the scaling is applied - * @default [0, 0, 0] - */ - center: Base.Point3; - /** - * Scaling factors for each axis [1, 2, 1] means that Y axis will be scaled 200% and both x and z axis will remain on 100% - * @default [1, 1, 1] - */ - scaleXyz: Base.Vector3; - } - class UniformScaleDto { - constructor(scale?: number); - /** - * Uniform scale factor for all x, y, z directions. 1 will keep everything on original size, 2 will scale 200%; - * @default 1 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - scale: number; - } - class UniformScaleFromCenterDto { - constructor(scale?: number, center?: Base.Point3); - /** - * Scale factor for all x, y, z directions. 1 will keep everything on original size, 2 will scale 200%; - * @default 1 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - scale: number; - /** - * Center position of the scaling - * @default [0, 0, 0] - */ - center: Base.Point3; - } - class TranslationXYZDto { - constructor(translation?: Base.Vector3); - /** - * Translation vector with [x, y, z] distances - * @default [0, 0, 0] - */ - translation: Base.Vector3; - } - class TranslationsXYZDto { - constructor(translations?: Base.Vector3[]); - /** - * Translation vectors with [x, y, z] distances - * @default undefined - */ - translations: Base.Vector3[]; - } - } - declare namespace Vector { - class TwoVectorsDto { - constructor(first?: number[], second?: number[]); - /** - * First vector - * @default undefined - */ - first: number[]; - /** - * Second vector - * @default undefined - */ - second: number[]; - } - class VectorBoolDto { - constructor(vector?: boolean[]); - /** - * Vector of booleans - * @default undefined - */ - vector: boolean[]; - } - class RemoveAllDuplicateVectorsDto { - constructor(vectors?: number[][], tolerance?: number); - /** - * Vectors array - * @default undefined - */ - vectors: number[][]; - /** - * Tolerance value - * @default 1e-7 - * @minimum 0 - * @maximum Infinity - */ - tolerance: number; - } - class RemoveConsecutiveDuplicateVectorsDto { - constructor( - vectors?: number[][], - checkFirstAndLast?: boolean, - tolerance?: number - ); - /** - * Vectors array - * @default undefined - */ - vectors: number[][]; - /** - * Check first and last vectors - * @default false - */ - checkFirstAndLast: boolean; - /** - * Tolerance value - * @default 1e-7 - * @minimum 0 - * @maximum Infinity - */ - tolerance: number; - } - class VectorsTheSameDto { - constructor(vec1?: number[], vec2?: number[], tolerance?: number); - /** - * First vector - * @default undefined - */ - vec1: number[]; - /** - * Second vector - * @default undefined - */ - vec2: number[]; - /** - * Tolerance value - * @default 1e-7 - * @minimum 0 - * @maximum Infinity - */ - tolerance: number; - } - class VectorDto { - constructor(vector?: number[]); - /** - * Vector array of numbers - * @default undefined - */ - vector: number[]; - } - class VectorStringDto { - constructor(vector?: string[]); - /** - * Vector array of stringified numbers - * @default undefined - */ - vector: string[]; - } - class Vector3Dto { - constructor(vector?: Base.Vector3); - /** - * Vector array of 3 numbers - * @default undefined - */ - vector: Base.Vector3; - } - class RangeMaxDto { - constructor(max?: number); - /** - * Maximum range boundary - * @default 10 - * @minimum -Infinity - * @maximum Infinity - * @step 1 - */ - max: number; - } - class VectorXYZDto { - constructor(x?: number, y?: number, z?: number); - /** - * X value of vector - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 0.5 - */ - x: number; - /** - * Y value of vector - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 0.5 - */ - y: number; - /** - * Z value of vector - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 0.5 - */ - z: number; - } - class VectorXYDto { - constructor(x?: number, y?: number); - /** - * X value of vector - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 0.5 - */ - x: number; - /** - * Y value of vector - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 0.5 - */ - y: number; - } - class SpanDto { - constructor(step?: number, min?: number, max?: number); - /** - * Step of the span - * @default 0.1 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - step: number; - /** - * Min value of the span - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 1 - */ - min: number; - /** - * Max value of the span - * @default 1 - * @minimum -Infinity - * @maximum Infinity - * @step 1 - */ - max: number; - } - class SpanEaseItemsDto { - constructor( - nrItems?: number, - min?: number, - max?: number, - ease?: Math.easeEnum - ); - /** - * Nr of items in the span - * @default 100 - * @minimum 2 - * @maximum Infinity - * @step 1 - */ - nrItems: number; - /** - * Min value of the span - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 1 - */ - min: number; - /** - * Max value of the span - * @default 1 - * @minimum -Infinity - * @maximum Infinity - * @step 1 - */ - max: number; - /** - * Ease type - * @default easeInSine - */ - ease: Math.easeEnum; - /** - * Indicates wether only intervals should be outputed. This will output step lengths between the values. - * @default false - */ - intervals: boolean; - } - class SpanLinearItemsDto { - constructor(nrItems?: number, min?: number, max?: number); - /** - * Nr of items in the span - * @default 100 - * @minimum 2 - * @maximum Infinity - * @step 1 - */ - nrItems: number; - /** - * Min value of the span - * @default 0 - * @minimum -Infinity - * @maximum Infinity - * @step 1 - */ - min: number; - /** - * Max value of the span - * @default 1 - * @minimum -Infinity - * @maximum Infinity - * @step 1 - */ - max: number; - } - class RayPointDto { - constructor(point?: Base.Point3, distance?: number, vector?: number[]); - /** - * Origin location of the ray - * @default undefined - */ - point: Base.Point3; - /** - * Distance to the point on the ray - * @default 1 - * @minimum -Infinity - * @maximum Infinity - * @step 1 - */ - distance: number; - /** - * Vector array of numbers - * @default undefined - */ - vector: number[]; - } - class VectorsDto { - constructor(vectors?: number[][]); - /** - * Vectors array - * @default undefined - */ - vectors: number[][]; - } - class FractionTwoVectorsDto { - constructor( - fraction?: number, - first?: Base.Vector3, - second?: Base.Vector3 - ); - /** - * Fraction number - * @default 0.5 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - fraction: number; - /** - * First vector - * @default undefined - */ - first: Base.Vector3; - /** - * Second vector - * @default undefined - */ - second: Base.Vector3; - } - class VectorScalarDto { - constructor(scalar?: number, vector?: number[]); - /** - * Scalar number - * @default 1 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - scalar: number; - /** - * Vector array of numbers - * @default undefined - */ - vector: number[]; - } - class TwoVectorsReferenceDto { - constructor( - reference?: number[], - first?: Base.Vector3, - second?: Base.Vector3 - ); - /** - * Reference vector - * @default undefined - */ - reference: number[]; - /** - * First vector - * @default undefined - */ - first: Base.Vector3; - /** - * Second vector - * @default undefined - */ - second: Base.Vector3; - } - } - declare namespace Asset { - class GetAssetDto { - constructor(fileName?: string); - /** - * The fileName associated with the projects asset - * @default undefined - */ - fileName: string; - } - class FetchDto { - constructor(url?: string); - /** - * The url to fetch from - * @default undefined - */ - url: string; - } - class FileDto { - constructor(file?: File | Blob); - /** - * Asset file that was loaded - * @default undefined - */ - file: File | Blob; - } - class FilesDto { - constructor(files?: (File | Blob)[]); - /** - * Asset file that was loaded - * @default undefined - */ - files: (File | Blob)[]; - } - class AssetFileDto { - constructor(assetFile?: File, hidden?: boolean); - /** - * Asset file that was loaded - * @default undefined - */ - assetFile: File; - /** - * Import the asset hidden - * @default false - */ - hidden: boolean; - } - class AssetFileByUrlDto { - constructor(assetFile?: string, rootUrl?: string, hidden?: boolean); - /** - * Asset file name - * @default undefined - */ - assetFile: string; - /** - * Root url - * @default undefined - */ - rootUrl: string; - /** - * Import the asset hidden - * @default false - */ - hidden: boolean; - } - class DownloadDto { - constructor( - fileName?: string, - content?: string | Blob, - extension?: string, - contentType?: string - ); - /** - * The file name for the downloaded file - * @default undefined - */ - fileName: string; - /** - * The content to download (string or Blob) - * @default undefined - */ - content: string | Blob; - /** - * The file extension (without dot) - * @default txt - */ - extension: string; - /** - * The content type for the file - * @default text/plain - */ - contentType: string; - } - } - declare namespace Base { - /** - * Defines how colors are mapped to entities when there are more entities than colors. - * - firstColorForAll: Uses the first color for all entities (legacy behavior) - * - lastColorRemainder: Maps colors 1:1, then uses last color for remaining entities - * - repeatColors: Cycles through colors in a repeating pattern - * - reversedColors: After exhausting colors, reverses direction (ping-pong pattern) - */ - enum colorMapStrategyEnum { - /** Uses the first color for all entities (legacy behavior) */ - firstColorForAll = "firstColorForAll", - /** Maps colors 1:1, then uses last color for remaining entities */ - lastColorRemainder = "lastColorRemainder", - /** Cycles through colors in a repeating pattern */ - repeatColors = "repeatColors", - /** After exhausting colors, reverses direction (ping-pong pattern) */ - reversedColors = "reversedColors", - } - enum skyboxEnum { - default = "default", - clearSky = "clearSky", - city = "city", - greyGradient = "greyGradient", - } - enum fogModeEnum { - none = "none", - exponential = "exponential", - exponentialSquared = "exponentialSquared", - linear = "linear", - } - enum horizontalAlignEnum { - left = "left", - center = "center", - right = "right", - } - enum verticalAlignmentEnum { - top = "top", - middle = "middle", - bottom = "bottom", - } - enum topBottomEnum { - top = "top", - bottom = "bottom", - } - enum basicAlignmentEnum { - topLeft = "topLeft", - topMid = "topMid", - topRight = "topRight", - midLeft = "midLeft", - midMid = "midMid", - midRight = "midRight", - bottomLeft = "bottomLeft", - bottomMid = "bottomMid", - bottomRight = "bottomRight", - } - type Color = string; - type ColorRGB = { - r: number; - g: number; - b: number; - }; - type Point2 = [number, number]; - type Vector2 = [number, number]; - type Point3 = [number, number, number]; - type Vector3 = [number, number, number]; - type Axis3 = { - origin: Base.Point3; - direction: Base.Vector3; - }; - type Axis2 = { - origin: Base.Point2; - direction: Base.Vector2; - }; - type Segment2 = [Point2, Point2]; - type Segment3 = [Point3, Point3]; - type TrianglePlane3 = { - normal: Vector3; - d: number; - }; - type Triangle3 = [Base.Point3, Base.Point3, Base.Point3]; - type Mesh3 = Triangle3[]; - type Plane3 = { - origin: Base.Point3; - normal: Base.Vector3; - direction: Base.Vector3; - }; - type BoundingBox = { - min: Base.Point3; - max: Base.Point3; - center?: Base.Point3; - width?: number; - height?: number; - length?: number; - }; - type Line2 = { - start: Base.Point2; - end: Base.Point2; - }; - type Line3 = { - start: Base.Point3; - end: Base.Point3; - }; - type Polyline3 = { - points: Base.Point3[]; - isClosed?: boolean; - }; - type Polyline2 = { - points: Base.Point2[]; - isClosed?: boolean; - }; - type VerbCurve = { - tessellate: (options: any) => any; - }; - type VerbSurface = { - tessellate: (options: any) => any; - }; - type TransformMatrix3x3 = [ - number, - number, - number, - number, - number, - number, - number, - number, - number - ]; - type TransformMatrixes3x3 = TransformMatrix3x3[]; - type TransformMatrix = [ - number, - number, - number, - number, - number, - number, - number, - number, - number, - number, - number, - number, - number, - number, - number, - number - ]; - type TransformMatrixes = TransformMatrix[]; - } - declare namespace CSV { - class ParseToArrayDto { - constructor( - csv?: string, - rowSeparator?: string, - columnSeparator?: string - ); - /** - * CSV text to parse - * @default name,age - John,30 - */ - csv: string; - /** - * Row separator (newline character) - * @default - - */ - rowSeparator?: string; - /** - * Column separator (delimiter) - * @default , - */ - columnSeparator?: string; - } - class ParseToJsonDto { - constructor( - csv?: string, - headerRow?: number, - dataStartRow?: number, - rowSeparator?: string, - columnSeparator?: string, - numberColumns?: string[] - ); - /** - * CSV text to parse - * @default name,age - John,30 - Jane,25 - */ - csv: string; - /** - * Row index where headers are located - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - headerRow?: number; - /** - * Row index where data starts - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - dataStartRow?: number; - /** - * Row separator (newline character) - * @default - - */ - rowSeparator?: string; - /** - * Column separator (delimiter) - * @default , - */ - columnSeparator?: string; - /** - * Column names that should be converted to numbers - * @default undefined - * @optional true - */ - numberColumns?: string[]; - } - class ParseToJsonWithHeadersDto { - constructor( - csv?: string, - headers?: string[], - dataStartRow?: number, - rowSeparator?: string, - columnSeparator?: string, - numberColumns?: string[] - ); - /** - * CSV text to parse - * @default John,30 - Jane,25 - */ - csv: string; - /** - * Custom header names to use - * @default ["name", "age"] - */ - headers: string[]; - /** - * Row index where data starts - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - dataStartRow?: number; - /** - * Row separator (newline character) - * @default - - */ - rowSeparator?: string; - /** - * Column separator (delimiter) - * @default , - */ - columnSeparator?: string; - /** - * Column names that should be converted to numbers - * @default undefined - * @optional true - */ - numberColumns?: string[]; - } - class QueryColumnDto { - constructor( - csv?: string, - column?: string, - headerRow?: number, - dataStartRow?: number, - rowSeparator?: string, - columnSeparator?: string, - asNumber?: boolean - ); - /** - * CSV text to query - * @default name,age - John,30 - Jane,25 - */ - csv: string; - /** - * Column name to query - * @default name - */ - column: string; - /** - * Row index where headers are located - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - headerRow?: number; - /** - * Row index where data starts - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - dataStartRow?: number; - /** - * Row separator (newline character) - * @default - - */ - rowSeparator?: string; - /** - * Column separator (delimiter) - * @default , - */ - columnSeparator?: string; - /** - * Convert column values to numbers - * @default false - */ - asNumber?: boolean; - } - class QueryRowsByValueDto { - constructor( - csv?: string, - column?: string, - value?: string, - headerRow?: number, - dataStartRow?: number, - rowSeparator?: string, - columnSeparator?: string, - numberColumns?: string[] - ); - /** - * CSV text to query - * @default name,age - John,30 - Jane,25 - */ - csv: string; - /** - * Column name to filter by - * @default age - */ - column: string; - /** - * Value to match - * @default 30 - */ - value: string; - /** - * Row index where headers are located - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - headerRow?: number; - /** - * Row index where data starts - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - dataStartRow?: number; - /** - * Row separator (newline character) - * @default - - */ - rowSeparator?: string; - /** - * Column separator (delimiter) - * @default , - */ - columnSeparator?: string; - /** - * Column names that should be converted to numbers - * @default undefined - * @optional true - */ - numberColumns?: string[]; - } - class ArrayToCsvDto { - constructor( - array?: (string | number | boolean | null | undefined)[][], - rowSeparator?: string, - columnSeparator?: string - ); - /** - * 2D array to convert - * @default [["name", "age"], ["John", "30"]] - */ - array: (string | number | boolean | null | undefined)[][]; - /** - * Row separator (newline character) - * @default - - */ - rowSeparator?: string; - /** - * Column separator (delimiter) - * @default , - */ - columnSeparator?: string; - } - class JsonToCsvDto> { - constructor( - json?: T[], - headers?: string[], - includeHeaders?: boolean, - rowSeparator?: string, - columnSeparator?: string - ); - /** - * Array of JSON objects to convert - * @default [{"name": "John", "age": "30"}] - */ - json: T[]; - /** - * Headers to use (in order) - * @default ["name", "age"] - */ - headers: string[]; - /** - * Whether to include headers in output - * @default true - */ - includeHeaders?: boolean; - /** - * Row separator (newline character) - * @default - - */ - rowSeparator?: string; - /** - * Column separator (delimiter) - * @default , - */ - columnSeparator?: string; - } - class JsonToCsvAutoDto> { - constructor( - json?: T[], - includeHeaders?: boolean, - rowSeparator?: string, - columnSeparator?: string - ); - /** - * Array of JSON objects to convert - * @default [{"name": "John", "age": "30"}] - */ - json: T[]; - /** - * Whether to include headers in output - * @default true - */ - includeHeaders?: boolean; - /** - * Row separator (newline character) - * @default - - */ - rowSeparator?: string; - /** - * Column separator (delimiter) - * @default , - */ - columnSeparator?: string; - } - class GetHeadersDto { - constructor( - csv?: string, - headerRow?: number, - rowSeparator?: string, - columnSeparator?: string - ); - /** - * CSV text to get headers from - * @default name,age - John,30 - */ - csv: string; - /** - * Row index where headers are located - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - headerRow?: number; - /** - * Row separator (newline character) - * @default - - */ - rowSeparator?: string; - /** - * Column separator (delimiter) - * @default , - */ - columnSeparator?: string; - } - class GetRowCountDto { - constructor( - csv?: string, - hasHeaders?: boolean, - dataStartRow?: number, - rowSeparator?: string, - columnSeparator?: string - ); - /** - * CSV text to count rows - * @default name,age - John,30 - Jane,25 - */ - csv: string; - /** - * Whether CSV has headers - * @default true - */ - hasHeaders?: boolean; - /** - * Row index where data starts (overrides hasHeaders if set) - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - dataStartRow?: number; - /** - * Row separator (newline character) - * @default - - */ - rowSeparator?: string; - /** - * Column separator (delimiter) - * @default , - */ - columnSeparator?: string; - } - } - declare namespace JSON { - class StringifyDto { - constructor(json?: any); - /** - * Stringify value - * @default undefined - */ - json: any; - } - class ParseDto { - constructor(text?: string); - /** - * Stringify value - * @default "[0, 0, 0]" - */ - text: string; - } - class QueryDto { - constructor(json?: any, query?: string); - /** - * query json structure - * @default undefined - */ - json: any; - /** - * query path - * @default undefined - */ - query: string; - } - class SetValueOnPropDto { - constructor(json?: any, value?: any, property?: string); - /** - * query json structure - * @default undefined - */ - json: any; - /** - * value to be set - * @default undefined - */ - value: any; - /** - * query json structure - * @default propName - */ - property: string; - } - class GetJsonFromArrayByFirstPropMatchDto { - constructor(jsonArray?: any[], property?: string, match?: any); - /** - * Array - * @default undefined - */ - jsonArray: any[]; - /** - * property to check - * @default propName - */ - property: string; - /** - * Value to match for the property - * @default undefined - */ - match: any; - } - class GetValueOnPropDto { - constructor(json?: any, property?: string); - /** - * query json structure - * @default undefined - */ - json: any; - /** - * query json structure - * @default propName - */ - property: string; - } - class SetValueDto { - constructor(json?: any, value?: any, path?: string, prop?: string); - /** - * query json structure - * @default undefined - */ - json: any; - /** - * value to be set - * @default undefined - */ - value: any; - /** - * query to json structure elements on which given prop has to be updated - * @default $.pathToParent - */ - path: string; - /** - * property to update - * @default propertyName - */ - prop: string; - } - class SetValuesOnPathsDto { - constructor(json?: any, values?: any[], paths?: string[], props?: []); - /** - * query json structure - * @default undefined - */ - json: any; - /** - * values to be set - * @default undefined - */ - values: any[]; - /** - * query json structures - * @default undefined - */ - paths: string[]; - /** - * properties to update - * @default undefined - */ - props: string[]; - } - class PathsDto { - constructor(json?: any, query?: string); - /** - * query json structure - * @default undefined - */ - json: any; - /** - * query path - * @default undefined - */ - query: string; - } - class JsonDto { - constructor(json?: any); - /** - * json value - * @default undefined - */ - json: any; - } - } - declare namespace Tag { - class DrawTagDto { - constructor(tag?: TagDto, updatable?: boolean, tagVariable?: TagDto); - /** - * Text tag to draw - */ - tag: TagDto; - /** - * Indicates that it is updatable tag - */ - updatable: boolean; - /** - * Optional existing tag in case it needs updating - */ - tagVariable?: TagDto; - } - class DrawTagsDto { - constructor( - tags?: TagDto[], - updatable?: boolean, - tagsVariable?: TagDto[] - ); - /** - * Text tag to draw - */ - tags: TagDto[]; - /** - * Indicates that it is updatable tag - */ - updatable: boolean; - /** - * Optional existing tag in case it needs updating - */ - tagsVariable?: TagDto[]; - } - /** - * Class representing a tag - */ - class TagDto { - constructor( - text?: string, - position?: Base.Point3, - colour?: string, - size?: number, - adaptDepth?: boolean, - needsUpdate?: boolean, - id?: string - ); - /** - * Text of the tag - */ - text: string; - /** - * Position of the tag - */ - position: Base.Point3; - /** - * Colour of the tag - */ - colour: string; - /** - * Text size - */ - size: number; - /** - * Make tags that are further away smaller - */ - adaptDepth: boolean; - /** - * Indicates if tag needs updating - */ - needsUpdate?: boolean; - /** - * Unique id of the tag - */ - id?: string; - } - } - declare namespace Time { - class PostFromIframe { - constructor(data?: any, targetOrigin?: string); - /** - * The data object to post - */ - data: any; - /** - * Thir party iframe origin url to which data should be posted - */ - targetOrigin: string; - } - } - declare namespace Verb { - class CurveDto { - constructor(curve?: any); - /** - * Nurbs curve - */ - curve: any; - } - class LineDto { - constructor(line?: Base.Line3); - /** - * Basic line - */ - line: Base.Line3; - } - class LinesDto { - constructor(lines?: Base.Line3[]); - /** - * Basic lines - */ - lines: Base.Line3[]; - } - class PolylineDto { - constructor(polyline?: Base.Polyline3); - /** - * Basic polyline - */ - polyline: Base.Polyline3; - } - class PolylinesDto { - constructor(polylines?: Base.Polyline3[]); - /** - * Basic polyline - */ - polylines: Base.Polyline3[]; - } - class CurvesDto { - constructor(curves?: any[]); - /** - * Nurbs curves - */ - curves: any[]; - } - class ClosestPointDto { - constructor(curve?: any, point?: Base.Point3); - /** - * Nurbs curve - */ - curve: any; - /** - * Point - */ - point: Base.Point3; - } - class ClosestPointsDto { - constructor(curve?: any, points?: Base.Point3[]); - /** - * Nurbs curve - */ - curve: any; - /** - * Points - */ - points: Base.Point3[]; - } - class BezierCurveDto { - constructor(points?: Base.Point3[], weights?: number[]); - /** - * Control points - */ - points: Base.Point3[]; - /** - * Weights - */ - weights: number[]; - } - class DrawCurveDto { - /** - * Provide options without default values - */ - constructor( - curve?: any, - opacity?: number, - colours?: string | string[], - size?: number, - updatable?: boolean, - curveMesh?: T - ); - /** - * Nurbs curve - */ - curve: any; - /** - * Value between 0 and 1 - */ - opacity: number; - /** - * Hex colour string - */ - colours: string | string[]; - /** - * Width of the polyline - */ - size: number; - /** - * Indicates wether the position of this curve will change in time - */ - updatable: boolean; - /** - * Curve mesh variable in case it already exists and needs updating - */ - curveMesh?: T; - } - class CurveParameterDto { - constructor(curve?: any, parameter?: number); - /** - * Nurbs curve - */ - curve: any; - /** - * Parameter on the curve - */ - parameter: number; - } - class CurvesParameterDto { - constructor(curves?: any[], parameter?: number); - /** - * Nurbs curve - */ - curves: any; - /** - * Parameter on the curve - */ - parameter: number; - } - class CurveTransformDto { - constructor(curve?: any, transformation?: Base.TransformMatrixes); - /** - * Nurbs curve - */ - curve: any; - /** - * Transformation matrixes - */ - transformation: Base.TransformMatrixes; - } - class CurvesTransformDto { - constructor(curves?: any[], transformation?: Base.TransformMatrixes); - /** - * Nurbs curve - */ - curves: any[]; - /** - * Transformation matrixes - */ - transformation: Base.TransformMatrixes; - } - class CurveToleranceDto { - constructor(curve?: any, tolerance?: number); - /** - * Nurbs curve - */ - curve: any; - /** - * Optional tolerance - */ - tolerance: number; - } - class CurveLengthToleranceDto { - constructor(curve?: any, length?: number, tolerance?: number); - /** - * Nurbs curve - */ - curve: any; - /** - * Length on the curve - */ - length: number; - /** - * Tolerance - */ - tolerance: number; - } - class CurveDerivativesDto { - constructor(curve?: any, parameter?: number, numDerivatives?: number); - /** - * Nurbs curve - */ - curve: any; - /** - * Number of derivatives - */ - numDerivatives: number; - /** - * Parameter on the curve - */ - parameter: number; - } - class CurveSubdivisionsDto { - constructor(curve?: any, subdivision?: number); - /** - * Nurbs curve - */ - curve: any; - /** - * Number of subdivisions - */ - subdivision: number; - } - class CurvesSubdivisionsDto { - constructor(curves?: any[], subdivision?: number); - /** - * Nurbs curves - */ - curves: any[]; - /** - * Number of subdivisions - */ - subdivision: number; - } - class CurvesDivideLengthDto { - constructor(curves?: any[], length?: number); - /** - * Nurbs curves - */ - curves: any[]; - /** - * Length of subdivisions - */ - length: number; - } - class CurveDivideLengthDto { - constructor(curve?: any, length?: number); - /** - * Nurbs curve - */ - curve: any; - /** - * Length of subdivisions - */ - length: number; - } - class DrawCurvesDto { - /** - * Provide options without default values - */ - constructor( - curves?: any[], - opacity?: number, - colours?: string | string[], - size?: number, - updatable?: boolean, - curvesMesh?: T - ); - /** - * Nurbs curves - */ - curves: any[]; - /** - * Value between 0 and 1 - */ - opacity: number; - /** - * Hex colour string - */ - colours: string | string[]; - /** - * Width of the polyline - */ - size: number; - /** - * Indicates wether the position of this polyline will change in time - */ - updatable: boolean; - /** - * Curve mesh variable in case it already exists and needs updating - */ - curvesMesh?: T; - } - class CurveNurbsDataDto { - constructor( - degree?: number, - weights?: number[], - knots?: number[], - points?: Base.Point3[] - ); - /** - * Nurbs curve degree - */ - degree: number; - /** - * Weights that identify strength that attracts curve to control points - */ - weights: number[]; - /** - * Knots of the Nurbs curve - */ - knots: number[]; - /** - * Control points of the nurbs curve - */ - points: Base.Point3[]; - } - class CurvePathDataDto { - constructor(degree?: number, points?: Base.Point3[]); - /** - * Nurbs curve degree - */ - degree: number; - /** - * Control points of the nurbs curve - */ - points: Base.Point3[]; - } - class EllipseDto { - constructor(ellipse?: any); - /** - * Nurbs ellipse - */ - ellipse: any; - } - class CircleDto { - constructor(circle?: any); - /** - * Nurbs circle - */ - circle: any; - } - class ArcDto { - constructor(arc?: any); - /** - * Nurbs arc - */ - arc: any; - } - class EllipseParametersDto { - constructor( - xAxis?: Base.Vector3, - yAxis?: Base.Vector3, - center?: Base.Point3 - ); - /** - * X axis of the circle - */ - xAxis: Base.Vector3; - /** - * Y axis of the circle - */ - yAxis: Base.Vector3; - /** - * Center of the circle - */ - center: Base.Point3; - } - class CircleParametersDto { - constructor( - xAxis?: Base.Vector3, - yAxis?: Base.Vector3, - radius?: number, - center?: Base.Point3 - ); - /** - * X axis of the circle - */ - xAxis: Base.Vector3; - /** - * Y axis of the circle - */ - yAxis: Base.Vector3; - /** - * Radius of the circle - */ - radius: number; - /** - * Center of the circle - */ - center: Base.Point3; - } - class ArcParametersDto { - constructor( - minAngle?: number, - maxAngle?: number, - xAxis?: Base.Vector3, - yAxis?: Base.Vector3, - radius?: number, - center?: Base.Point3 - ); - /** - * Minimum angle in degrees - */ - minAngle: number; - /** - * Maximum angle in degrees - */ - maxAngle: number; - /** - * X axis of the circle - */ - xAxis: Base.Vector3; - /** - * Y axis of the circle - */ - yAxis: Base.Vector3; - /** - * Radius of the circle - */ - radius: number; - /** - * Center of the circle - */ - center: Base.Point3; - } - class EllipseArcParametersDto { - constructor( - minAngle?: number, - maxAngle?: number, - xAxis?: Base.Vector3, - yAxis?: Base.Vector3, - center?: Base.Point3 - ); - /** - * Minimum angle in degrees - */ - minAngle: number; - /** - * Maximum angle in degrees - */ - maxAngle: number; - /** - * X axis of the circle - */ - xAxis: Base.Vector3; - /** - * Y axis of the circle - */ - yAxis: Base.Vector3; - /** - * Center of the circle - */ - center: Base.Point3; - } - class SurfaceDto { - constructor(surface?: any); - /** - * Nurbs surface - */ - surface: any; - } - class SurfaceTransformDto { - constructor(surface?: any, transformation?: Base.TransformMatrixes); - /** - * Nurbs surface - */ - surface: any; - /** - * Transformations - */ - transformation: Base.TransformMatrixes; - } - class SurfaceParameterDto { - constructor(surface?: any, parameter?: number, useV?: boolean); - /** - * Nurbs surface - */ - surface: any; - /** - * Parameter on the surface - */ - parameter: number; - /** - * Default parameter is on U direction, use V to switch - */ - useV: boolean; - } - class IsocurvesParametersDto { - constructor(surface?: any, parameters?: number[], useV?: boolean); - /** - * Nurbs surface - */ - surface: any; - /** - * Parameter on the surface - */ - parameters: number[]; - /** - * Default parameter is on U direction, use V to switch - */ - useV: boolean; - } - class IsocurveSubdivisionDto { - /** - * Provide undefined options - */ - constructor( - surface?: any, - useV?: boolean, - includeLast?: boolean, - includeFirst?: boolean, - isocurveSegments?: number - ); - /** - * Nurbs surface - */ - surface: any; - /** - * Default parameter is on U direction, use V to switch - */ - useV: boolean; - /** - * Check to include the last isocurve - */ - includeLast: boolean; - /** - * Check to include the first isocurve - */ - includeFirst: boolean; - /** - * Number of segments including surface start and end - */ - isocurveSegments: number; - } - class DerivativesDto { - constructor( - surface?: any, - u?: number, - v?: number, - numDerivatives?: number - ); - /** - * Nurbs surface - */ - surface: any; - /** - * U coordinate - */ - u: number; - /** - * V coordinate - */ - v: number; - /** - * Number of derivatives - */ - numDerivatives: number; - } - class SurfaceLocationDto { - constructor(surface?: any, u?: number, v?: number); - /** - * Nurbs surface - */ - surface: any; - /** - * U coordinate - */ - u: number; - /** - * V coordinate - */ - v: number; - } - class CornersDto { - constructor( - point1?: Base.Point3, - point2?: Base.Point3, - point3?: Base.Point3, - point4?: Base.Point3 - ); - /** - * Corner 1 - */ - point1: Base.Point3; - /** - * Corner 2 - */ - point2: Base.Point3; - /** - * Corner 3 - */ - point3: Base.Point3; - /** - * Corner 4 - */ - point4: Base.Point3; - } - class SurfaceParamDto { - constructor(surface?: any, point?: Base.Point3); - /** - * Nurbs surface - */ - surface: any; - /** - * Point - */ - point: Base.Point3; - } - class KnotsControlPointsWeightsDto { - constructor( - degreeU?: number, - degreeV?: number, - knotsU?: number[], - knotsV?: number[], - points?: Base.Point3[], - weights?: number[] - ); - /** - * U direction degree - */ - degreeU: number; - /** - * V direction degree - */ - degreeV: number; - /** - * U direction knots - */ - knotsU: number[]; - /** - * V direction knots - */ - knotsV: number[]; - /** - * Points - */ - points: Base.Point3[]; - /** - * Weights - */ - weights: number[]; - } - class LoftCurvesDto { - constructor(degreeV?: number, curves?: any[]); - /** - * V direction degree - */ - degreeV: number; - /** - * Nurbs curves - */ - curves: any[]; - } - class DrawSurfaceDto { - /** - * Provide options without default values - */ - constructor( - surface?: any, - opacity?: number, - colours?: string | string[], - updatable?: boolean, - hidden?: boolean, - surfaceMesh?: T, - drawTwoSided?: boolean, - backFaceColour?: string, - backFaceOpacity?: number - ); - /** - * Nurbs surface - */ - surface: any; - /** - * Value between 0 and 1 - */ - opacity: number; - /** - * Hex colour string - */ - colours: string | string[]; - /** - * Indicates wether the position of this surface will change in time - */ - updatable: boolean; - /** - * Should be hidden - */ - hidden: boolean; - /** - * Surface mesh variable in case it already exists and needs updating - */ - surfaceMesh?: T; - /** - * Draw two-sided faces with different colors for front and back. This helps visualize face orientation. - * @default true - */ - drawTwoSided: boolean; - /** - * Hex colour string for back face colour (negative side of the face). Only used when drawTwoSided is true. - * @default #0000ff - */ - backFaceColour: string; - /** - * Back face opacity value between 0 and 1. Only used when drawTwoSided is true. - * @default 1 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - backFaceOpacity: number; - } - class DrawSurfacesDto { - /** - * Provide options without default values - */ - constructor( - surfaces?: any[], - opacity?: number, - colours?: string | string[], - updatable?: boolean, - hidden?: boolean, - surfacesMesh?: T, - drawTwoSided?: boolean, - backFaceColour?: string, - backFaceOpacity?: number - ); - /** - * Nurbs surfaces - */ - surfaces: any[]; - /** - * Value between 0 and 1 - */ - opacity: number; - /** - * Hex colour string - */ - colours: string | string[]; - /** - * Indicates wether the position of these surfaces will change in time - */ - updatable: boolean; - /** - * Should be hidden - */ - hidden: boolean; - /** - * Surfaces mesh variable in case it already exists and needs updating - */ - surfacesMesh?: T; - /** - * Draw two-sided faces with different colors for front and back. This helps visualize face orientation. - * @default true - */ - drawTwoSided: boolean; - /** - * Hex colour string for back face colour (negative side of the face). Only used when drawTwoSided is true. - * @default #0000ff - */ - backFaceColour: string; - /** - * Back face opacity value between 0 and 1. Only used when drawTwoSided is true. - * @default 1 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - backFaceOpacity: number; - } - class DrawSurfacesColoursDto { - /** - * Provide options without default values - */ - constructor( - surfaces?: any[], - colours?: string[], - opacity?: number, - updatable?: boolean, - hidden?: boolean, - surfacesMesh?: T, - drawTwoSided?: boolean, - backFaceColour?: string, - backFaceOpacity?: number - ); - /** - * Nurbs surfaces - */ - surfaces: any[]; - /** - * Value between 0 and 1 - */ - opacity: number; - /** - * Hex colour strings, there has to be a colour for every single surface and lengths of arrays need to match - */ - colours: string | string[]; - /** - * Indicates wether the position of these surfaces will change in time - */ - updatable: boolean; - /** - * Indicates if surface should be hidden - */ - hidden: boolean; - /** - * Surfaces mesh variable in case it already exists and needs updating - */ - surfacesMesh?: T; - /** - * Draw two-sided faces with different colors for front and back. This helps visualize face orientation. - * @default true - */ - drawTwoSided: boolean; - /** - * Hex colour string for back face colour (negative side of the face). Only used when drawTwoSided is true. - * @default #0000ff - */ - backFaceColour: string; - /** - * Back face opacity value between 0 and 1. Only used when drawTwoSided is true. - * @default 1 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - backFaceOpacity: number; - } - class ConeAndCylinderParametersDto { - constructor( - axis?: Base.Vector3, - xAxis?: Base.Vector3, - base?: Base.Point3, - height?: number, - radius?: number - ); - /** - * Defines main axis of the cone - */ - axis: Base.Vector3; - /** - * X axis of the cone - */ - xAxis: Base.Vector3; - /** - * Base point for the cone - */ - base: Base.Point3; - /** - * Height of the cone - */ - height: number; - /** - * Radius of the cone - */ - radius: number; - } - class ConeDto { - constructor(cone?: any); - /** - * Conical Nurbs surface - */ - cone: any; - } - class CylinderDto { - constructor(cylinder?: any); - /** - * Cylindrical Nurbs surface - */ - cylinder: any; - } - class ExtrusionParametersDto { - constructor(profile?: any, direction?: Base.Vector3); - /** - * Profile Nurbs curve - */ - profile: any; - /** - * Direction vector - */ - direction: Base.Vector3; - } - class ExtrusionDto { - constructor(extrusion?: any); - /** - * Nurbs surface created through extrusion - */ - extrusion: any; - } - class SphericalParametersDto { - constructor(radius?: number, center?: number[]); - /** - * Radius of the sphere - */ - radius: number; - /** - * Center point - */ - center: number[]; - } - class SphereDto { - constructor(sphere?: any); - /** - * Spherical Nurbs surface - */ - sphere: any; - } - class RevolutionParametersDto { - constructor( - profile?: any, - center?: number[], - axis?: number[], - angle?: number - ); - /** - * Profile Nurbs curve - */ - profile: any; - /** - * Center point - */ - center: number[]; - /** - * Axis around which rotation will happen - */ - axis: number[]; - /** - * Angle at which to rotate in degrees - */ - angle: number; - } - class RevolutionDto { - constructor(revolution?: any); - /** - * Revolved Nurbs surface - */ - revolution: any; - } - class SweepParametersDto { - constructor(profile?: any, rail?: any); - /** - * Profile Nurbs curve - */ - profile: any; - /** - * Rail Nurbs curve - */ - rail: any; - } - class SweepDto { - constructor(sweep?: any); - /** - * Revolved Nurbs surface - */ - sweep: any; - } - class CurveCurveDto { - constructor(firstCurve?: any, secondCurve?: any, tolerance?: number); - /** - * First Nurbs curve - */ - firstCurve: any; - /** - * Second Nurbs curve - */ - secondCurve: number[]; - /** - * Optional tolerance parameter - */ - tolerance?: number; - } - class CurveSurfaceDto { - constructor(curve?: any, surface?: any, tolerance?: number); - /** - * Nurbs curve - */ - curve: any; - /** - * Nurbs surface - */ - surface: any; - /** - * Optional tolerance parameter - */ - tolerance?: number; - } - class SurfaceSurfaceDto { - constructor( - firstSurface?: any, - secondSurface?: any, - tolerance?: number - ); - /** - * Nurbs curve - */ - firstSurface: any; - /** - * Nurbs surface - */ - secondSurface: any; - /** - * Optional tolerance parameter - */ - tolerance?: number; - } - class CurveCurveIntersectionsDto { - constructor(intersections?: BaseTypes.CurveCurveIntersection[]); - /** - * Curve curve intersections - */ - intersections: BaseTypes.CurveCurveIntersection[]; - } - class CurveSurfaceIntersectionsDto { - constructor(intersections?: BaseTypes.CurveSurfaceIntersection[]); - /** - * Curve curve intersections - */ - intersections: BaseTypes.CurveSurfaceIntersection[]; - } - } - } - - declare namespace Models { - declare namespace Point { - declare class HexGridData { - centers: Base.Point3[]; - hexagons: Base.Point3[][]; - shortestDistEdge: number; - longestDistEdge: number; - maxFilletRadius: number; - } - } - declare namespace Text { - declare class VectorCharData { - constructor(width?: number, height?: number, paths?: Base.Point3[][]); - /** - * The width of the char - * @default undefined - */ - width?: number; - /** - * The height of the char - * @default undefined - */ - height?: number; - /** - * The segments of the char - * @default undefined - */ - paths?: Base.Point3[][]; - } - declare class VectorTextData { - constructor(width?: number, height?: number, chars?: VectorCharData[]); - /** - * The width of the char - * @default undefined - */ - width?: number; - /** - * The height of the char - * @default undefined - */ - height?: number; - /** - * The segments of the char - * @default undefined - */ - chars?: VectorCharData[]; - } - } - declare namespace OCCT { - declare class ShapeWithId { - id: string; - shape: U; - } - declare class ObjectDefinition { - compound?: U; - shapes?: ShapeWithId[]; - data?: M; - } - declare class TextWiresCharShapePart { - id?: string; - shapes?: { - compound?: T; - }; - } - declare class TextWiresDataDto { - type: string; - name: string; - compound?: T; - characters?: TextWiresCharShapePart[]; - width: number; - height: number; - center: Base.Point3; - } - } - } - - declare namespace Things { - declare namespace Enums { - declare class LodDto { - /** - * Level of detail - * @default low - */ - lod: lodEnum; - } - declare enum lodEnum { - low = "low", - middle = "middle", - high = "high", - } - } - declare namespace Architecture { - declare namespace Houses { - declare namespace ZenHideout { - declare class ZenHideoutData { - /** - * Type of the object being configured - */ - type: string; - /** - * Default name of the object - */ - name: string; - /** - * Original inputs - */ - originalInputs?: ZenHideoutDto; - /** - * Compounded shape representation of all of the geometric objects of the building - */ - compound?: T; - /** - * All the shapes of the building - */ - shapes?: Models.OCCT.ShapeWithId[]; - /** - * Representation of zen hideout parts that are useful for drawing the object efficiently - */ - drawingPart?: ZenHideoutDrawingPart; - /** - * Sandwitch parts that have inner and outer panels, can have windows and doors - */ - sandwitchPartsBetweenColumns?: Things.Architecture.SandwitchPart[]; - /** - * Corner part panels forming 90 degree angle - */ - cornerParts?: Things.Architecture.CornerPart[]; - /** - * Column parts of the building - */ - columnParts?: Things.Architecture.ColumnPart[]; - /** - * Roof parts of the building. Contain all the upper geometry, together with beams and columns. - */ - roofParts?: Things.Architecture.RoofPart[]; - /** - * Entrance corner part of the building, containing interior and exterior panels, staircase, and a corner window part - */ - entranceCorner?: Things.Architecture.CornerEntrancePart; - /** - * Terrace corner of the building, containing interior and exterior panels, staircase, and a corner window part - */ - entranceTerrace?: Things.Architecture.CornerEntrancePart; - /** - * Floor parts of the building - */ - floors?: Things.Architecture.FloorPart[]; - /** - * Ceiling parts of the building - */ - ceilings?: Things.Architecture.CeilingPart[]; - } - /** - * This defines useful compounded objects for representing zen hideout in optimal and fast way. - */ - declare class ZenHideoutDrawingPartShapes { - /** - * The representation of all window glass objects in the building - */ - windowGlassCompound?: T; - /** - * The representation of all glass frame objects in the building - */ - glassFramesCompound?: T; - /** - * The representation of all window frame objects in the building - */ - windowFrameCompound?: T; - /** - * The representation of all beam objects in the building - */ - beamsCompound?: T; - /** - * The representation of all column objects in the building - */ - columnsCompound?: T; - /** - * The representation of all exterior panels on the first floor - * of the building - */ - firstFloorExteriorPanelsCompound?: T; - /** - * The representation of all interior panels on the first floor - * of the building - */ - firstFloorInteriorPanelsCompound?: T; - /** - * The representation of all exterior panels on the roof - * of the building - */ - roofExteriorPanelsCompound?: T; - /** - * The representation of all interior panels on the roof - * of the building - */ - roofInteriorPanelsCompound?: T; - /** - * The representation of the first roof cover - * of the building - */ - roofCoverFirstCompound?: T; - /** - * The representation of the second roof cover - * of the building - */ - roofCoverSecondCompound?: T; - /** - * The representation of the floor - * of the building - */ - floorCompound?: T; - /** - * The representation of the ceiling - * of the building - */ - ceilingCompound?: T; - /** - * The representation of stairs - */ - stairsCompound?: T; - } - /** - * Information needed to draw the part in an optimal way - */ - declare class ZenHideoutDrawingPart { - /** - * Shapes that exist in the drawing part, T can represent opancascade geometry, - * babylonjs mesh, materials or other things that map to these drawing categories. - */ - shapes?: ZenHideoutDrawingPartShapes; - } - declare class ZenHideoutDtoBase { - widthFirstWing: T; - lengthFirstWing: T; - terraceWidth: T; - widthSecondWing: T; - lengthSecondWing: T; - heightWalls: T; - roofAngleFirstWing: T; - roofAngleSecondWing: T; - roofOffset: T; - roofInsideOverhang: T; - roofMaxDistAttachmentBeams: T; - roofAttachmentBeamWidth: T; - roofAttachmentBeamHeight: T; - roofOutsideOverhang: T; - columnSize: T; - ceilingBeamHeight: T; - ceilingBeamWidth: T; - nrCeilingBeamsBetweenColumns: T; - distBetweenColumns: T; - floorHeight: T; - groundLevel: T; - facadePanelThickness: T; - windowWidthOffset: T; - windowHeightOffset: T; - windowFrameThickness: T; - windowGlassFrameThickness: T; - lod: U; - rotation?: T; - origin?: V; - } - declare class ZenHideoutDto - implements - ZenHideoutDtoBase< - number, - Things.Enums.lodEnum, - Inputs.Base.Point3 - > - { - constructor( - widthFirstWing?: number, - lengthFirstWing?: number, - terraceWidth?: number, - widthSecondWing?: number, - lengthSecondWing?: number, - heightWalls?: number, - roofAngleFirstWing?: number, - roofAngleSecondWing?: number, - roofOffset?: number, - roofInsideOverhang?: number, - roofMaxDistAttachmentBeams?: number, - roofAttachmentBeamWidth?: number, - roofAttachmentBeamHeight?: number, - roofOutsideOverhang?: number, - columnSize?: number, - ceilingBeamHeight?: number, - ceilingBeamWidth?: number, - nrCeilingBeamsBetweenColumns?: number, - distBetweenColumns?: number, - floorHeight?: number, - groundLevel?: number, - facadePanelThickness?: number, - windowWidthOffset?: number, - windowHeightOffset?: number, - windowFrameThickness?: number, - windowGlassFrameThickness?: number, - lod?: Things.Enums.lodEnum, - skinOpacity?: number, - rotation?: number, - origin?: Inputs.Base.Point3 - ); - /** - * Width of the first wing of L shaped building - * @default 4 - * @minimum 3 - * @maximum Infinity - * @step 0.5 - */ - widthFirstWing: number; - /** - * Length of the first wing of L shaped building - * @default 10 - * @minimum 3 - * @maximum Infinity - * @step 0.5 - */ - lengthFirstWing: number; - /** - * Width of the terrace - * @default 3 - * @minimum 1 - * @maximum Infinity - * @step 0.25 - */ - terraceWidth: number; - /** - * Width of the second wing of L shaped building - * @default 5 - * @minimum 3 - * @maximum Infinity - * @step 0.5 - */ - widthSecondWing: number; - /** - * Length of the second wing of L shaped building - * @default 10 - * @minimum 3 - * @maximum Infinity - * @step 0.5 - */ - lengthSecondWing: number; - /** - * Height of the walls - * @default 3 - * @minimum 3 - * @maximum Infinity - * @step 0.1 - */ - heightWalls: number; - /** - * Height of the first wing end - * @default 15 - * @minimum 5 - * @maximum Infinity - * @step 5 - */ - roofAngleFirstWing: number; - /** - * Height of the first wing end - * @default 25 - * @minimum 5 - * @maximum Infinity - * @step 5 - */ - roofAngleSecondWing: number; - /** - * The offset to be applied to where the roof starts - * @default 0.5 - * @minimum 0.2 - * @maximum Infinity - * @step 0.25 - */ - roofOffset: number; - /** - * Roof overhang on the inside of the building (where the terrace is) - * @default 0.5 - * @minimum 0 - * @maximum Infinity - * @step 0.25 - */ - roofInsideOverhang: number; - /** - * Roof max distance between top attachment beams - * @default 0.8 - * @minimum 0.1 - * @maximum Infinity - * @step 0.25 - */ - roofMaxDistAttachmentBeams: number; - /** - * Roof attachment beam width - * @default 0.2 - * @minimum 0.01 - * @maximum Infinity - * @step 0.05 - */ - roofAttachmentBeamWidth: number; - /** - * Roof attachment beam height - * @default 0.05 - * @minimum 0.01 - * @maximum Infinity - * @step 0.05 - */ - roofAttachmentBeamHeight: number; - /** - * Roof overhang on the inside of the building - * @default 0.5 - * @minimum 0 - * @maximum Infinity - * @step 0.25 - */ - roofOutsideOverhang: number; - /** - * Column size - * @default 0.3 - * @minimum 0.01 - * @maximum Infinity - * @step 0.1 - */ - columnSize: number; - /** Ceiling beam height - * @default 0.25 - * @minimum 0.01 - * @maximum Infinity - * @step 0.05 - */ - ceilingBeamHeight: number; - /** Ceiling beam width - * @default 0.1 - * @minimum 0.01 - * @maximum Infinity - * @step 0.05 - */ - ceilingBeamWidth: number; - /** Nr ceiling beams between columns - * @default 3 - * @minimum 1 - * @maximum Infinity - * @step 1 - */ - nrCeilingBeamsBetweenColumns: number; - /** Distance between columns - * @default 2 - * @minimum 0.5 - * @maximum Infinity - * @step 0.25 - */ - distBetweenColumns: number; - /** The height of the floor - * @default 0.1 - * @minimum 0.1 - * @maximum Infinity - * @step 0.1 - */ - floorHeight: number; - /** ground level from the floor - * @default 0.6 - * @minimum 0.1 - * @maximum Infinity - * @step 0.1 - */ - groundLevel: number; - /** Facade panel thickness - * @default 0.05 - * @minimum 0.01 - * @maximum Infinity - * @step 0.01 - */ - facadePanelThickness: number; - /** Window width parameter - * @default 0.1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - windowWidthOffset: number; - /** Window bottom offset - * @default 0.2 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - windowHeightOffset: number; - /** Window frame thickness - * @default 0.1 - * @minimum 0.01 - * @maximum Infinity - * @step 0.01 - */ - windowFrameThickness: number; - /** Window glass frame thickness - * @default 0.05 - * @minimum 0.01 - * @maximum Infinity - * @step 0.01 - */ - windowGlassFrameThickness: number; - /** - * Level of detail to compute - * @default high - */ - lod: Things.Enums.lodEnum; - /** - * The opacity of the skin - only applied if lod is set to high - * @default 1 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - skinOpacity: number; - /** - * Rotation of the zen hideout - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 10 - */ - rotation: number; - /** - * Origin of the zen hideout - * @default [0, 0, 0] - */ - origin: Inputs.Base.Point3; - } - } - } - declare class BeamPart { - id?: string; - name?: string; - width?: number; - length?: number; - height?: number; - shapes?: { - beam?: T; - }; - } - declare class CeilingPart { - id?: string; - name?: string; - area?: number; - thickness?: number; - polygonPoints?: Inputs.Base.Point3[]; - shapes?: { - compound?: T; - }; - } - declare class ColumnPart { - id?: string; - name?: string; - width?: number; - length?: number; - height?: number; - shapes?: { - column?: T; - }; - } - declare class CornerEntranceDto { - /** - * Width first wing - * @default 1 - * @minimum 0.1 - * @maximum Infinity - * @step 0.1 - */ - widthFirstWing: number; - /** - * Width second wing - * @default 1 - * @minimum 0.1 - * @maximum Infinity - * @step 0.1 - */ - widthSecondWing: number; - /** - * Length stair first wing - * @default 1 - * @minimum 0.1 - * @maximum Infinity - * @step 0.1 - */ - lengthStairFirstWing: number; - /** - * Length stair second wing - * @default 1 - * @minimum 0.1 - * @maximum Infinity - * @step 0.1 - */ - lengthStairSecondWing: number; - /** - * Length wall first wing - * @default 1 - * @minimum 0.1 - * @maximum Infinity - * @step 0.1 - */ - lengthWallFirstWing: number; - /** - * Length wall second wing - * @default 1 - * @minimum 0.1 - * @maximum Infinity - * @step 0.1 - */ - lengthWallSecondWing: number; - /** Facade panel thickness - * @default 0.05 - * @minimum 0.01 - * @maximum Infinity - * @step 0.01 - */ - facadePanelThickness: number; - /** Wall thickness - * @default 0.3 - * @minimum 0.01 - * @maximum Infinity - * @step 0.05 - */ - wallThickness: number; - /** Height of the walls on the exterior side - * @default 3 - * @minimum 0.1 - * @maximum Infinity - * @step 0.1 - */ - wallHeightExterior: number; - /** Height of the walls on the interior side - * @default 3 - * @minimum 0.1 - * @maximum Infinity - * @step 0.1 - */ - wallHeightInterior: number; - /** Window offset top - * @default 0.3 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - windowFrameOffsetTop: number; - /** Window frame thickness - * @default 0.1 - * @minimum 0.01 - * @maximum Infinity - * @step 0.1 - */ - windowFrameThickness: number; - /** Glass frame thickness - * @default 0.1 - * @minimum 0.01 - * @maximum Infinity - * @step 0.1 - */ - glassFrameThickness: number; - /** Door width - * @default 1 - * @minimum 0.7 - * @maximum Infinity - * @step 0.1 - */ - doorWidth: number; - /** Corner Window Width Offset - * @default 0.3 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - windowWidthOffset: number; - /** Stair total height - * @default 1 - * @minimum 0.7 - * @maximum Infinity - * @step 0.1 - */ - stairTotalHeight: number; - /** Create stairs - * @default false - */ - createStair: boolean; - /** - * Flips the direction - outside things become inside and vice versa - * @default false - */ - flipDirection: boolean; - /** - * Rotation of the entrance - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 15 - */ - rotation: number; - /** - * Origin of the stairs - * @default [0, 0, 0] - */ - origin: Inputs.Base.Point3; - } - declare class CornerEntrancePart { - id?: string; - name?: string; - panelThickness?: number; - widthPanelExteriorOne?: number; - heightPanelsExterior?: number; - stair?: CornerStairPart; - window?: WindowCornerPart; - shapes?: { - compound?: T; - panelExterior?: T; - panelInterior?: T; - }; - } - declare class CornerPart { - /** - * Unique id of the corner part - */ - id?: string; - /** - * Name of the corner part - */ - name?: string; - /** - * Width of the panel - */ - widthPanel?: number; - /** - * Height of the panel - */ - heightPanel?: number; - /** - * Thickness of the panel - */ - thicknessPanel?: number; - /** - * Corner shapes - */ - shapes?: { - corner?: T; - }; - } - declare class CornerStairDto { - /** - * Inverts the side of the stair from going out to going inside of the L shape. This kind of stair can produce self intersecting result. - * @default false - */ - invert: boolean; - /** - * Width first wing - * @default 1 - * @minimum 0.1 - * @maximum Infinity - * @step 0.1 - */ - widthFirstLanding: number; - /** - * Width second wing - * @default 1 - * @minimum 0.1 - * @maximum Infinity - * @step 0.1 - */ - widthSecondLanding: number; - /** - * Length first wing - * @default 2 - * @minimum 0.1 - * @maximum Infinity - * @step 0.1 - */ - lengthFirstWing: number; - /** - * Length second wing - * @default 1 - * @minimum 0.1 - * @maximum Infinity - * @step 0.1 - */ - lengthSecondWing: number; - /** - * Max wished step height - * @default 0.25 - * @minimum 0.01 - * @maximum Infinity - * @step 0.05 - */ - maxWishedStepHeight: number; - /** - * Max wished step height - * @default 0.25 - * @minimum 0.01 - * @maximum Infinity - * @step 0.05 - */ - stepHeightWidthProportion: number; - /** - * Total height of the corner stairs - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - totalHeight: number; - /** - * Rotation of the stairs - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 15 - */ - rotation: number; - /** - * Origin of the stairs - * @default [0, 0, 0] - */ - origin: Inputs.Base.Point3; - } - declare class CornerStairPart extends CornerStairDto { - id?: string; - name?: string; - steps?: number; - stepWidth?: number; - stepHeight?: number; - shapes?: { - stair?: T; - }; - } - declare class FloorPart { - id?: string; - name?: string; - area?: number; - thickness?: number; - polygonPoints?: Inputs.Base.Point3[]; - shapes?: { - compound?: T; - }; - } - declare class ZenHideoutData { - /** - * Type of the object being configured - */ - type: string; - /** - * Default name of the object - */ - name: string; - /** - * Original inputs - */ - originalInputs?: ZenHideoutDto; - /** - * Compounded shape representation of all of the geometric objects of the building - */ - compound?: T; - /** - * All the shapes of the building - */ - shapes?: Models.OCCT.ShapeWithId[]; - /** - * Representation of zen hideout parts that are useful for drawing the object efficiently - */ - drawingPart?: ZenHideoutDrawingPart; - /** - * Sandwitch parts that have inner and outer panels, can have windows and doors - */ - sandwitchPartsBetweenColumns?: Things.Architecture.SandwitchPart[]; - /** - * Corner part panels forming 90 degree angle - */ - cornerParts?: Things.Architecture.CornerPart[]; - /** - * Column parts of the building - */ - columnParts?: Things.Architecture.ColumnPart[]; - /** - * Roof parts of the building. Contain all the upper geometry, together with beams and columns. - */ - roofParts?: Things.Architecture.RoofPart[]; - /** - * Entrance corner part of the building, containing interior and exterior panels, staircase, and a corner window part - */ - entranceCorner?: Things.Architecture.CornerEntrancePart; - /** - * Terrace corner of the building, containing interior and exterior panels, staircase, and a corner window part - */ - entranceTerrace?: Things.Architecture.CornerEntrancePart; - /** - * Floor parts of the building - */ - floors?: Things.Architecture.FloorPart[]; - /** - * Ceiling parts of the building - */ - ceilings?: Things.Architecture.CeilingPart[]; - } - /** - * This defines useful compounded objects for representing zen hideout in optimal and fast way. - */ - declare class ZenHideoutDrawingPartShapes { - /** - * The representation of all window glass objects in the building - */ - windowGlassCompound?: T; - /** - * The representation of all glass frame objects in the building - */ - glassFramesCompound?: T; - /** - * The representation of all window frame objects in the building - */ - windowFrameCompound?: T; - /** - * The representation of all beam objects in the building - */ - beamsCompound?: T; - /** - * The representation of all column objects in the building - */ - columnsCompound?: T; - /** - * The representation of all exterior panels on the first floor - * of the building - */ - firstFloorExteriorPanelsCompound?: T; - /** - * The representation of all interior panels on the first floor - * of the building - */ - firstFloorInteriorPanelsCompound?: T; - /** - * The representation of all exterior panels on the roof - * of the building - */ - roofExteriorPanelsCompound?: T; - /** - * The representation of all interior panels on the roof - * of the building - */ - roofInteriorPanelsCompound?: T; - /** - * The representation of the first roof cover - * of the building - */ - roofCoverFirstCompound?: T; - /** - * The representation of the second roof cover - * of the building - */ - roofCoverSecondCompound?: T; - /** - * The representation of the floor - * of the building - */ - floorCompound?: T; - /** - * The representation of the ceiling - * of the building - */ - ceilingCompound?: T; - /** - * The representation of stairs - */ - stairsCompound?: T; - } - /** - * Information needed to draw the part in an optimal way - */ - declare class ZenHideoutDrawingPart { - /** - * Shapes that exist in the drawing part, T can represent opancascade geometry, - * babylonjs mesh, materials or other things that map to these drawing categories. - */ - shapes?: ZenHideoutDrawingPartShapes; - } - declare class ZenHideoutDtoBase { - widthFirstWing: T; - lengthFirstWing: T; - terraceWidth: T; - widthSecondWing: T; - lengthSecondWing: T; - heightWalls: T; - roofAngleFirstWing: T; - roofAngleSecondWing: T; - roofOffset: T; - roofInsideOverhang: T; - roofMaxDistAttachmentBeams: T; - roofAttachmentBeamWidth: T; - roofAttachmentBeamHeight: T; - roofOutsideOverhang: T; - columnSize: T; - ceilingBeamHeight: T; - ceilingBeamWidth: T; - nrCeilingBeamsBetweenColumns: T; - distBetweenColumns: T; - floorHeight: T; - groundLevel: T; - facadePanelThickness: T; - windowWidthOffset: T; - windowHeightOffset: T; - windowFrameThickness: T; - windowGlassFrameThickness: T; - lod: U; - rotation?: T; - origin?: V; - } - declare class ZenHideoutDto - implements - ZenHideoutDtoBase - { - constructor( - widthFirstWing?: number, - lengthFirstWing?: number, - terraceWidth?: number, - widthSecondWing?: number, - lengthSecondWing?: number, - heightWalls?: number, - roofAngleFirstWing?: number, - roofAngleSecondWing?: number, - roofOffset?: number, - roofInsideOverhang?: number, - roofMaxDistAttachmentBeams?: number, - roofAttachmentBeamWidth?: number, - roofAttachmentBeamHeight?: number, - roofOutsideOverhang?: number, - columnSize?: number, - ceilingBeamHeight?: number, - ceilingBeamWidth?: number, - nrCeilingBeamsBetweenColumns?: number, - distBetweenColumns?: number, - floorHeight?: number, - groundLevel?: number, - facadePanelThickness?: number, - windowWidthOffset?: number, - windowHeightOffset?: number, - windowFrameThickness?: number, - windowGlassFrameThickness?: number, - lod?: Things.Enums.lodEnum, - skinOpacity?: number, - rotation?: number, - origin?: Inputs.Base.Point3 - ); - /** - * Width of the first wing of L shaped building - * @default 4 - * @minimum 3 - * @maximum Infinity - * @step 0.5 - */ - widthFirstWing: number; - /** - * Length of the first wing of L shaped building - * @default 10 - * @minimum 3 - * @maximum Infinity - * @step 0.5 - */ - lengthFirstWing: number; - /** - * Width of the terrace - * @default 3 - * @minimum 1 - * @maximum Infinity - * @step 0.25 - */ - terraceWidth: number; - /** - * Width of the second wing of L shaped building - * @default 5 - * @minimum 3 - * @maximum Infinity - * @step 0.5 - */ - widthSecondWing: number; - /** - * Length of the second wing of L shaped building - * @default 10 - * @minimum 3 - * @maximum Infinity - * @step 0.5 - */ - lengthSecondWing: number; - /** - * Height of the walls - * @default 3 - * @minimum 3 - * @maximum Infinity - * @step 0.1 - */ - heightWalls: number; - /** - * Height of the first wing end - * @default 15 - * @minimum 5 - * @maximum Infinity - * @step 5 - */ - roofAngleFirstWing: number; - /** - * Height of the first wing end - * @default 25 - * @minimum 5 - * @maximum Infinity - * @step 5 - */ - roofAngleSecondWing: number; - /** - * The offset to be applied to where the roof starts - * @default 0.5 - * @minimum 0.2 - * @maximum Infinity - * @step 0.25 - */ - roofOffset: number; - /** - * Roof overhang on the inside of the building (where the terrace is) - * @default 0.5 - * @minimum 0 - * @maximum Infinity - * @step 0.25 - */ - roofInsideOverhang: number; - /** - * Roof max distance between top attachment beams - * @default 0.8 - * @minimum 0.1 - * @maximum Infinity - * @step 0.25 - */ - roofMaxDistAttachmentBeams: number; - /** - * Roof attachment beam width - * @default 0.2 - * @minimum 0.01 - * @maximum Infinity - * @step 0.05 - */ - roofAttachmentBeamWidth: number; - /** - * Roof attachment beam height - * @default 0.05 - * @minimum 0.01 - * @maximum Infinity - * @step 0.05 - */ - roofAttachmentBeamHeight: number; - /** - * Roof overhang on the inside of the building - * @default 0.5 - * @minimum 0 - * @maximum Infinity - * @step 0.25 - */ - roofOutsideOverhang: number; - /** - * Column size - * @default 0.3 - * @minimum 0.01 - * @maximum Infinity - * @step 0.1 - */ - columnSize: number; - /** Ceiling beam height - * @default 0.25 - * @minimum 0.01 - * @maximum Infinity - * @step 0.05 - */ - ceilingBeamHeight: number; - /** Ceiling beam width - * @default 0.1 - * @minimum 0.01 - * @maximum Infinity - * @step 0.05 - */ - ceilingBeamWidth: number; - /** Nr ceiling beams between columns - * @default 3 - * @minimum 1 - * @maximum Infinity - * @step 1 - */ - nrCeilingBeamsBetweenColumns: number; - /** Distance between columns - * @default 2 - * @minimum 0.5 - * @maximum Infinity - * @step 0.25 - */ - distBetweenColumns: number; - /** The height of the floor - * @default 0.1 - * @minimum 0.1 - * @maximum Infinity - * @step 0.1 - */ - floorHeight: number; - /** ground level from the floor - * @default 0.6 - * @minimum 0.1 - * @maximum Infinity - * @step 0.1 - */ - groundLevel: number; - /** Facade panel thickness - * @default 0.05 - * @minimum 0.01 - * @maximum Infinity - * @step 0.01 - */ - facadePanelThickness: number; - /** Window width parameter - * @default 0.1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - windowWidthOffset: number; - /** Window bottom offset - * @default 0.2 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - windowHeightOffset: number; - /** Window frame thickness - * @default 0.1 - * @minimum 0.01 - * @maximum Infinity - * @step 0.01 - */ - windowFrameThickness: number; - /** Window glass frame thickness - * @default 0.05 - * @minimum 0.01 - * @maximum Infinity - * @step 0.01 - */ - windowGlassFrameThickness: number; - /** - * Level of detail to compute - * @default high - */ - lod: Things.Enums.lodEnum; - /** - * The opacity of the skin - only applied if lod is set to high - * @default 1 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - skinOpacity: number; - /** - * Rotation of the zen hideout - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 10 - */ - rotation: number; - /** - * Origin of the zen hideout - * @default [0, 0, 0] - */ - origin: Inputs.Base.Point3; - } - declare class RoofBeamsPart { - beamsCeiling?: BeamPart[]; - beamsVerticalHigh?: BeamPart[]; - beamsVerticalLow?: BeamPart[]; - beamsTop?: BeamPart[]; - beamsAttachment: BeamPart[]; - shapes?: { - compound?: T; - }; - } - declare class RoofCoverOneSidedDto { - /** - * Roof cover name - * @default roof-cover - */ - name: string; - /** - * Roof angle - * @default 15 - * @minimum 0 - * @maximum Infinity - * @step 5 - */ - roofAngle: number; - /** - * Roof length - * @default 3 - * @minimum 0.1 - * @maximum Infinity - * @step 0.1 - */ - roofLength: number; - /** - * Roof width along the angle part, total width contains roof inside and outside overhangs - * @default 3 - * @minimum 0.01 - * @maximum Infinity - * @step 0.1 - */ - roofWidth: number; - /** - * Roof outside overhang - * @default 0.5 - * @minimum 0.1 - * @maximum Infinity - * @step 0.1 - */ - roofOutsideOverhang: number; - /** - * Roof inside overhang - * @default 1 - * @minimum 0.1 - * @maximum Infinity - * @step 0.1 - */ - roofInsideOverhang: number; - /** - * Roof overhang facade - * @default 0.1 - * @minimum 0.01 - * @maximum Infinity - * @step 0.1 - */ - roofOverhangFacade: number; - /** - * Roof thickness - * @default 0.05 - * @minimum 0.001 - * @maximum Infinity - * @step 0.01 - */ - roofThickness: number; - /** - * Roof cover height - * @default 0.3 - * @minimum 0.01 - * @maximum Infinity - * @step 0.1 - */ - roofCoverHeight: number; - /** - * Rotation of the window - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 15 - */ - rotation: number; - /** - * Level of detail - * @default high - */ - lod: Things.Enums.lodEnum; - /** - * Origin of the stairs - * @default [0, 0, 0] - */ - center: Inputs.Base.Point3; - /** - * Direction of the window - * @default [0, 1, 0] - */ - direction: Inputs.Base.Vector3; - } - declare class RoofCoverPart extends RoofCoverOneSidedDto { - id?: string; - shapes?: { - compound?: T; - }; - } - declare class RoofPanelPart { - id?: string; - name?: string; - innerPanels?: SandwitchPart[]; - innerFillPanels?: SandwitchPart[]; - outerPanels?: SandwitchPart[]; - outerFillPanels?: SandwitchPart[]; - ends?: SandwitchPartFlex[]; - shapes?: { - compoundInnerExteriorPanels?: T; - compoundInnerInteriorPanels?: T; - compoundInnerFillExteriorPanels?: T; - compoundInnerFillInteriorPanels?: T; - compoundOuterExteriorPanels?: T; - compoundOuterInteriorPanels?: T; - compoundOuterFillExteriorPanels?: T; - compoundOuterFillInteriorPanels?: T; - compoundEndsInteriorPanels?: T; - compoundEndsExteriorPanels?: T; - compound?: T; - }; - } - declare class RoofPart { - id?: string; - name?: string; - beams: RoofBeamsPart; - panels?: RoofPanelPart; - covers?: RoofCoverPart[]; - shapes?: { - compound?: T; - }; - } - declare class SandwitchPanelDto { - /** Name of the sandwitch panel - * @default sandwitch-panel - */ - name: string; - /** Indicates wether a window should be created - * @default true - */ - createWindow: boolean; - /** Indicates wether the inner panel should be created - * @default true - */ - createInnerPanel: boolean; - /** Indicates wether the exterior panel should be created - * @default true - */ - createExteriorPanel: boolean; - /** Wall thickness - * @default 0.3 - * @minimum 0.01 - * @maximum Infinity - * @step 0.05 - */ - wallWidth: number; - /** Exterior panel width - * @default 0.4 - * @minimum 0.01 - * @maximum Infinity - * @step 0.05 - */ - exteriorPanelWidth: number; - /** Exterior panel height - * @default 3 - * @minimum 0.01 - * @maximum Infinity - * @step 0.1 - */ - exteriorPanelHeight: number; - /** Exterior panel thickness - * @default 0.05 - * @minimum 0.01 - * @maximum Infinity - * @step 0.1 - */ - exteriorPanelThickness: number; - /** Exterior panel bottom offset - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - exteriorPanelBottomOffset: number; - /** Interior panel width - * @default 0.4 - * @minimum 0.01 - * @maximum Infinity - * @step 0.05 - */ - interiorPanelWidth: number; - /** Interior panel height - * @default 3 - * @minimum 0.01 - * @maximum Infinity - * @step 0.1 - */ - interiorPanelHeight: number; - /** Interior panel thickness - * @default 0.05 - * @minimum 0.01 - * @maximum Infinity - * @step 0.1 - */ - interiorPanelThickness: number; - /** Interior panel bottom offset - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - interiorPanelBottomOffset: number; - /** Window width parameter - * @default 0.1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - windowWidthOffset: number; - /** Window bottom offset - * @default 0.2 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - windowHeightOffset: number; - /** Window frame thickness - * @default 0.1 - * @minimum 0.01 - * @maximum Infinity - * @step 0.01 - */ - windowFrameThickness: number; - /** Window glass frame thickness - * @default 0.05 - * @minimum 0.01 - * @maximum Infinity - * @step 0.01 - */ - windowGlassFrameThickness: number; - } - declare class SandwitchPanelFlexDto { - /** Name of the sandwitch panel - * @default sandwitch-panel - */ - name: string; - /** Indicates wether a window should be created - * @default true - */ - createInteriorPanel: boolean; - /** Indicates wether the exterior panel should be created - * @default true - */ - createExteriorPanel: boolean; - /** Wall thickness - * @default 0.3 - * @minimum 0.01 - * @maximum Infinity - * @step 0.05 - */ - wallWidth: number; - /** Exterior panel thickness - * @default 0.05 - * @minimum 0.01 - * @maximum Infinity - * @step 0.1 - */ - exteriorPanelThickness: number; - /** Interior panel thickness - * @default 0.05 - * @minimum 0.01 - * @maximum Infinity - * @step 0.1 - */ - interiorPanelThickness: number; - /** - * Interior wall panel polygon points - * @default [] - */ - interiorPanelPolygonPoints: Inputs.Base.Point2[]; - /** - * Exterior wall panel polygon points - * @default [] - */ - exteriorPanelPolygonPoints: Inputs.Base.Point2[]; - } - declare class SandwitchPart extends SandwitchPanelDto { - id?: string; - rotation?: number; - center?: Inputs.Base.Point3; - direction?: Inputs.Base.Vector3; - windows?: WindowRectangularPart[]; - shapes?: { - panelExterior?: T; - panelInterior?: T; - compound?: T; - }; - } - declare class SandwitchPartFlex extends SandwitchPanelFlexDto { - id?: string; - rotation?: number; - center?: Inputs.Base.Point3; - direction?: Inputs.Base.Vector3; - windows?: WindowRectangularPart[]; - shapes?: { - panelExterior?: T; - panelInterior?: T; - compound?: T; - }; - } - declare class WindowCornerDto { - /** Wall thickness - * @default 0.4 - * @minimum 0.01 - * @maximum Infinity - * @step 0.05 - */ - wallThickness: number; - /** Facade panel thickness - * @default 0.05 - * @minimum 0.01 - * @maximum Infinity - * @step 0.05 - */ - facadePanelThickness: number; - /** Glass frame thickness - * @default 0.02 - * @minimum 0.01 - * @maximum Infinity - * @step 0.01 - */ - glassFrameThickness: number; - /** Glass thickness - * @default 0.005 - * @minimum 0.001 - * @maximum Infinity - * @step 0.001 - */ - glassThickness: number; - /** Frame thickness - * @default 0.05 - * @minimum 0.01 - * @maximum Infinity - * @step 0.01 - */ - frameThckness: number; - /** Window height - * @default 0.05 - * @minimum 0.01 - * @maximum Infinity - * @step 0.01 - */ - height: number; - /** Length first window - * @default 1 - * @minimum 0.01 - * @maximum Infinity - * @step 0.1 - */ - lengthFirst: number; - /** Length second window - * @default 1 - * @minimum 0.01 - * @maximum Infinity - * @step 0.1 - */ - lengthSecond: number; - /** - * Rotation of the window - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 15 - */ - rotation: number; - /** - * Origin of the stairs - * @default [0, 0, 0] - */ - origin: Inputs.Base.Point3; - } - declare class WindowPartShapes { - /** - * Cutout of the window - this can be used to make the hole in the wall and usually should not be visualised - */ - cutout?: T; - /** - * Shape of the glass of the window - */ - glass?: T; - /** - * Glass frame of the window - */ - glassFrame?: T; - /** - * Frame of the window that usually is as thick as the wall and that touches glass frame - */ - frame?: T; - /** - * Compounded shape of the window with all other shapes joined together - */ - compound?: T; - } - declare class WindowRectangularPart extends WindowRectangularDto { - /** - * The name of the window part - */ - name: string; - /** - * The unique id of the window part - */ - id?: string; - /** - * Generic shapes that represent the window part - */ - shapes?: WindowPartShapes; - } - declare class WindowCornerPart extends WindowCornerDto { - /** - * The name of the window part - */ - name: string; - /** - * The unique id of the window part - */ - id?: string; - /** - * Generic shapes that represent the window part - */ - shapes?: WindowPartShapes; - } - declare class WindowRectangularDto { - /** Window thickness - * @default 0.3 - * @minimum 0.01 - * @maximum Infinity - * @step 0.05 - */ - thickness: number; - /** Glass frame thickness - * @default 0.02 - * @minimum 0.01 - * @maximum Infinity - * @step 0.01 - */ - glassFrameThickness: number; - /** Glass thickness - * @default 0.005 - * @minimum 0.001 - * @maximum Infinity - * @step 0.001 - */ - glassThickness: number; - /** Frame thickness - * @default 0.05 - * @minimum 0.01 - * @maximum Infinity - * @step 0.01 - */ - frameThickness: number; - /** Window height - * @default 0.05 - * @minimum 0.01 - * @maximum Infinity - * @step 0.01 - */ - height: number; - /** Width first window - * @default 1 - * @minimum 0.01 - * @maximum Infinity - * @step 0.1 - */ - width: number; - /** - * Rotation of the window - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 15 - */ - rotation: number; - /** - * Origin of the stairs - * @default [0, 0, 0] - */ - center: Inputs.Base.Point3; - /** - * Direction of the window - * @default [0, 1, 0] - */ - direction: Inputs.Base.Vector3; - } - } - declare namespace KidsCorner { - declare namespace BirdHouses { - declare namespace WingtipVilla { - declare class WingtipVillaData { - type: string; - name: string; - compound?: T; - roof: { - compound: T; - shapes: T[]; - }; - walls: { - compound: T; - shapes: T[]; - }; - stick: { - shape: T; - }; - floor: { - shape: T; - }; - chimney: { - shape: T; - }; - basicPoints: { - kind: string; - point: Inputs.Base.Point3; - }[]; - } - declare class WingtipVillaDto { - constructor( - interiorWidth?: number, - interiorLength?: number, - interiorHeight?: number, - thickness?: number, - holeDiameter?: number, - holeDistToBottom?: number, - stickLength?: number, - stickDiameter?: number, - baseAttachmentHeight?: number, - roofOverhang?: number, - rotation?: number, - chimneyHeight?: number, - origin?: Inputs.Base.Point3 - ); - /** - * Width of the house - * @default 3 - * @minimum 0 - * @maximum Infinity - * @step 0.5 - */ - interiorWidth: number; - /** - * Interior length of the house - * @default 3 - * @minimum 0 - * @maximum Infinity - * @step 0.5 - */ - interiorLength: number; - /** - * Interior height that goes from the floor to where the roof starts - * @default 5 - * @minimum 0 - * @maximum Infinity - * @step 0.5 - */ - interiorHeight: number; - /** - * thickness of the house - * @default 0.5 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - thickness: number; - /** - * hole diameter of the house - * @default 1.5 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - holeDiameter: number; - /** - * hole distance to the bottom of the house - * @default 2.5 - * @minimum 0 - * @maximum Infinity - * @step 0.5 - */ - holeDistToBottom: number; - /** - * stick length - * @default 1.2 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - stickLength: number; - /** - * stick diameter - * @default 0.5 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - stickDiameter: number; - /** - * base attachment height - * @default 2 - * @minimum 0 - * @maximum Infinity - * @step 0.5 - */ - baseAttachmentHeight: number; - /** - * roof overhang - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.5 - */ - roofOverhang: number; - /** - * Rotation of the bird house around the origin. - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 10 - */ - rotation: number; - /** - * Chimney height - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.5 - */ - chimneyHeight: number; - /** - * Origin of the bird house (where the bird house would be attached to the tree or the wall) - * @default [0, 0, 0] - */ - origin: Inputs.Base.Point3; - } - } - declare namespace ChirpyChalet { - declare class ChirpyChaletData { - type: string; - name: string; - compound?: T; - roof: { - compound: T; - shapes: T[]; - }; - walls: { - compound: T; - shapes: T[]; - }; - stick: { - shape: T; - }; - floor: { - shape: T; - }; - basicPoints: { - kind: string; - point: Inputs.Base.Point3; - }[]; - } - declare class ChirpyChaletDto { - constructor( - interiorWidth?: number, - interiorLength?: number, - interiorHeight?: number, - thickness?: number, - holeDiameter?: number, - holeDistToBottom?: number, - stickLength?: number, - stickDiameter?: number, - baseAttachmentHeight?: number, - roofOverhang?: number, - roofAngle?: number, - rotation?: number, - origin?: Inputs.Base.Point3 - ); - /** - * Width of the house - * @default 3 - * @minimum 0 - * @maximum Infinity - * @step 0.5 - */ - interiorWidth: number; - /** - * Interior length of the house - * @default 3 - * @minimum 0 - * @maximum Infinity - * @step 0.5 - */ - interiorLength: number; - /** - * Interior height that goes from the floor to where the roof starts - * @default 5 - * @minimum 0 - * @maximum Infinity - * @step 0.5 - */ - interiorHeight: number; - /** - * thickness of the house - * @default 0.3 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - thickness: number; - /** - * hole diameter of the house - * @default 1.2 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - holeDiameter: number; - /** - * hole distance to the bottom of the house - * @default 2.5 - * @minimum 0 - * @maximum Infinity - * @step 0.5 - */ - holeDistToBottom: number; - /** - * stick length - * @default 0.9 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - stickLength: number; - /** - * stick diameter - * @default 0.3 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - stickDiameter: number; - /** - * base attachment height - * @default 2 - * @minimum 0 - * @maximum Infinity - * @step 0.5 - */ - baseAttachmentHeight: number; - /** - * roof overhang - * @default 0.5 - * @minimum 0 - * @maximum Infinity - * @step 0.5 - */ - roofOverhang: number; - /** - * roof overhang - * @default 20 - * @minimum 0 - * @maximum 80 - * @step 5 - */ - roofAngle: number; - /** - * Rotation of the bird house around the origin. - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 10 - */ - rotation: number; - /** - * Origin of the bird house (where the bird house would be attached to the tree or the wall) - * @default [0, 0, 0] - */ - origin: Inputs.Base.Point3; - } - } - } - } - - declare namespace ThreeDPrinting { - declare namespace Vases { - declare namespace SerenitySwirl { - declare class SerenitySwirlData { - type: string; - name: string; - compound?: T; - } - declare class SerenitySwirlDto { - constructor( - swirl?: number, - nrOfDivisions?: number, - addRadiusNarrow?: number, - addRadiusWide?: number, - addMiddleHeight?: number, - addTopHeight?: number, - thickness?: number, - rotation?: number, - origin?: Inputs.Base.Point3 - ); - /** - * Swirl 0 - no swirl 1 max swirl - * @default 0.6 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - swirl: number; - /** - * Nr of divisions - * @default 10 - * @minimum 1 - * @maximum Infinity - * @step 1 - */ - nrOfDivisions: number; - /** - * Add to narrow radius - * @default 0.4 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - addRadiusNarrow: number; - /** - * Add to radius wide - * @default 0.2 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - addRadiusWide: number; - /** - * Add to middle height - * @default 1.6 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - addMiddleHeight: number; - /** - * Add to top height - * @default 1.5 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - addTopHeight: number; - /** - * Thickness of the vase on the widest part - * @default 1 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - thickness: number; - /** - * Rotation of the serenity swirl - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 10 - */ - rotation: number; - /** - * Origin of the vase - * @default [0, 0, 0] - */ - origin: Inputs.Base.Point3; - } - } - declare namespace ArabicArchway { - declare class ArabicArchwayData { - /** - * Type of the object being configured - */ - type: string; - /** - * Default name of the object - */ - name: string; - /** - * Compound shape of all the parts - */ - compound?: T; - /** - * Original inputs - */ - originalInputs: ArabicArchwayDto; - /** - * All the shapes of the vase - */ - shapes?: Models.OCCT.ShapeWithId[]; - /** - * Representation of arabic archway parts that are useful for drawing the object efficiently - */ - drawingPart?: ArabicArchwayDrawingPart; - } - declare class ArabicArchwayDrawingPartShapes { - /** - * The representation of all objects in the vase - */ - compound?: T; - /** - * The representation of all vase part objects in the vase - */ - vasePartsCompound?: T; - /** - * The representation of all glass objects in the vase - */ - glassPartsCompound?: T; - /** - * The representation of the base of the vase - */ - vaseBaseCompound?: T; - } - /** - * Information needed to draw the part in an optimal way - */ - declare class ArabicArchwayDrawingPart { - /** - * Shapes that exist in the drawing part, T can represent opancascade geometry, - * babylonjs mesh, materials or other things that map to these drawing categories. - */ - shapes?: - | ArabicArchwayDrawingPartShapes - | { - [x: string]: T; - }; - } - declare class ArabicArchwayDtoBase { - profilePoints?: P; - nrOfSides: T; - nrOfVerticalArches: T; - thickness: T; - edgesThickness: T; - archCenterThickness: T; - baseHeight: T; - patchHoles: B; - lod?: U; - rotation?: T; - direction?: V; - scale?: V; - origin?: V; - } - declare class ArabicArchwayDto - implements - ArabicArchwayDtoBase< - number, - Inputs.Base.Point3, - Inputs.Base.Point3[], - Things.Enums.lodEnum, - boolean - > - { - constructor( - nrOfSides?: number, - nrOfVerticalArches?: number, - archCenterThickness?: number, - edgesThickness?: number, - thickness?: number, - baseHeight?: number, - patchHoles?: boolean, - lod?: Things.Enums.lodEnum, - rotation?: number, - origin?: Inputs.Base.Point3, - direction?: Inputs.Base.Point3, - scale?: Inputs.Base.Vector3 - ); - /** - * nr of sides for arabic archway vase - * @default [[2, 0, 0],[4, 5, 0],[1.5, 10, 0],[2, 14, 0]] - */ - profilePoints: Inputs.Base.Point3[]; - /** - * nr of sides for arabic archway vase - * @default 3 - * @minimum 3 - * @maximum 30 - * @step 1 - */ - nrOfSides: number; - /** - * nr of vertical arches - * @default 6 - * @minimum 2 - * @maximum 30 - * @step 1 - */ - nrOfVerticalArches: number; - /** - * Arch center thickness - * @default 0.8 - * @minimum 0 - * @maximum 10 - * @step 0.1 - */ - archCenterThickness: number; - /** - * Edges thickness - * @default 0.2 - * @minimum 0 - * @maximum 10 - * @step 0.1 - */ - edgesThickness: number; - /** - * Thickness of the vase on the widest part - * @default 1 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - thickness: number; - /** - * Indicates how high the base should be, if 0 then no base will be made - * @default 0.4 - * @minimum 0 - * @maximum 10 - * @step 0.1 - */ - baseHeight: number; - /** - * Indicates whether holes of the vase should be patched - * @default true - */ - patchHoles: boolean; - /** - * Level of details for the model - * @default high - */ - lod: Things.Enums.lodEnum; - /** - * Rotation of the serenity swirl - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 10 - */ - rotation: number; - /** - * Origin of the vase - * @default [0, 0, 0] - */ - origin: Inputs.Base.Point3; - /** - * Direction of the vase - * @default [0, 1, 0] - */ - direction: Inputs.Base.Point3; - /** - * Scale of the vase - * @default [1, 1, 1] - */ - scale: Inputs.Base.Vector3; - } - } - } - declare namespace Cups { - declare namespace CalmCup { - declare class CalmCupData { - type: string; - name: string; - originalInputs: CalmCupDto; - compound?: T; - } - declare class CalmCupDtoBase { - height: T; - radiusBottom: T; - radiusTopOffset: T; - thickness: T; - fillet: T; - nrOfHandles: T; - handleDist: T; - precision: T; - rotation?: T; - scale?: T; - origin?: U; - direction?: U; - } - declare class CalmCupDto - implements CalmCupDtoBase - { - constructor( - height?: number, - radiusBottom?: number, - radiusTopOffset?: number, - thickness?: number, - fillet?: number, - nrOfHandles?: number, - handleDist?: number, - precision?: number, - rotation?: number, - scale?: number, - origin?: Inputs.Base.Point3, - direction?: Inputs.Base.Vector3 - ); - /** - * Height of the cup - * @default 6 - * @minimum 0.1 - * @maximum Infinity - * @step 0.1 - */ - height: number; - /** - * Radius top offset - * @default 4 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - radiusBottom: number; - /** - * Radius top offset - * @default 2 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - radiusTopOffset: number; - /** - * Thickness of the cup - * @default 0.6 - * @minimum 0.05 - * @maximum 3 - * @step 0.01 - */ - thickness: number; - /** - * Fillet of the cup - * @default 0.2 - * @minimum 0.01 - * @maximum Infinity - * @step 0.01 - */ - fillet: number; - /** - * Nr of handles, 0 will create a cup without handles - * @default 1 - * @minimum 0 - * @maximum 2 - * @step 1 - */ - nrOfHandles: number; - /** - * Handle distance from the cup - * @default 2 - * @minimum 0.1 - * @maximum Infinity - * @step 0.1 - */ - handleDist: number; - /** - * Meshing precision of the drawn model. Scale scales precision as well. The lower the number the more precise the drawn model is. Keep in mind that output of this algorithm also contains pure occt shape that can be meshed separately in draw any async commands - * @default 0.01 - * @minimum 0.000001 - * @maximum 5 - * @step 0.001 - */ - precision: number; - /** - * Rotation of the cup - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 10 - */ - rotation: number; - /** - * Scale of the cup - affects edge width and precision - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 10 - */ - scale: number; - /** - * Origin of the medal - * @default [0, 0, 0] - */ - origin: Inputs.Base.Point3; - /** - * Direction of the model - * @default [0, 1, 0] - */ - direction: Inputs.Base.Vector3; - } - } - declare namespace DragonCup { - declare class DragonCupData { - type: string; - name: string; - originalInputs: DragonCupDto; - compound?: T; - } - declare class DragonCupDtoBase { - height: T; - radiusBottom: T; - radiusTopOffset: T; - radiusMidOffset: T; - rotationMidAngle: T; - rotationTopAngle: T; - thickness: T; - bottomThickness: T; - nrSkinCellsHorizontal: T; - nrSkinCellsVertical: T; - nrSkinCellDivisionsTop: T; - nrSkinCellDivisionsBottom: T; - skinCellOuterHeight: T; - skinCellInnerHeight: T; - skinCellBottomHeight: T; - skinCellTopHeight: T; - precision: T; - rotation?: T; - scale?: T; - origin?: U; - direction?: U; - } - declare class DragonCupDto - implements DragonCupDtoBase - { - constructor( - height?: number, - radiusBottom?: number, - radiusTopOffset?: number, - radiusMidOffset?: number, - rotationTopAngle?: number, - rotationMidAngle?: number, - nrSkinCellsVertical?: number, - nrSkinCellsHorizontal?: number, - nrSkinCellDivisionsTop?: number, - nrSkinCellDivisionsBottom?: number, - skinCellOuterHeight?: number, - skinCellInnerHeight?: number, - skinCellBottomHeight?: number, - skinCellTopHeight?: number, - thickness?: number, - bottomThickness?: number, - precision?: number, - rotation?: number, - scale?: number, - origin?: Inputs.Base.Point3, - direction?: Inputs.Base.Vector3 - ); - /** - * Height of the cup - * @default 6 - * @minimum 0.1 - * @maximum Infinity - * @step 0.1 - */ - height: number; - /** - * Radius top offset - * @default 4 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - radiusBottom: number; - /** - * Radius top offset - * @default 2 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - radiusTopOffset: number; - /** - * Radius middle offset - * @default 2 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - radiusMidOffset: number; - /** - * Rotation of the top from the middle (angle in degrees) - * @default 20 - * @minimum -90 - * @maximum 90 - * @step 1 - */ - rotationTopAngle: number; - /** - * Rotation of the middle from the bottom (angle in degrees) - * @default 20 - * @minimum -90 - * @maximum 90 - * @step 1 - */ - rotationMidAngle: number; - /** - * Nr of skin cells along vertical direction - * @default 5 - * @minimum 1 - * @maximum Infinity - * @step 1 - */ - nrSkinCellsVertical: number; - /** - * Nr of skin cells along horizontal direction - * @default 10 - * @minimum 3 - * @maximum Infinity - * @step 1 - */ - nrSkinCellsHorizontal: number; - /** - * Nr of skin cell divisions on the top of the cup - * @default 1 - * @minimum 1 - * @maximum Infinity - * @step 1 - */ - nrSkinCellDivisionsTop: number; - /** - * Nr of skin cell divisions on the bottom of the cup - * @default 3 - * @minimum 1 - * @maximum Infinity - * @step 1 - */ - nrSkinCellDivisionsBottom: number; - /** - * skin cell outer height - * @default 0.4 - * @minimum -Infinity - * @maximum Infinity - * @step 0.01 - */ - skinCellOuterHeight: number; - /** - * skin cell inner height - * @default 0.3 - * @minimum -Infinity - * @maximum Infinity - * @step 0.01 - */ - skinCellInnerHeight: number; - /** - * skin cell bottom height - * @default 0.4 - * @minimum -Infinity - * @maximum Infinity - * @step 0.01 - */ - skinCellBottomHeight: number; - /** - * skin cell top height - * @default 0.4 - * @minimum -Infinity - * @maximum Infinity - * @step 0.01 - */ - skinCellTopHeight: number; - /** - * Thickness of the cup - * @default 0.6 - * @minimum 0.05 - * @maximum Infinity - * @step 0.01 - */ - thickness: number; - /** - * Bottom thickness of the cup - * @default 1 - * @minimum 0.05 - * @maximum Infinity - * @step 0.01 - */ - bottomThickness: number; - /** - * Meshing precision of the drawn model. Scale scales precision as well. The lower the number the more precise the drawn model is. Keep in mind that output of this algorithm also contains pure occt shape that can be meshed separately in draw any async commands - * @default 0.01 - * @minimum 0.000001 - * @maximum 5 - * @step 0.001 - */ - precision: number; - /** - * Rotation of the cup - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 10 - */ - rotation: number; - /** - * Scale of the cup - affects edge width and precision - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 10 - */ - scale: number; - /** - * Origin of the medal - * @default [0, 0, 0] - */ - origin: Inputs.Base.Point3; - /** - * Direction of the model - * @default [0, 1, 0] - */ - direction: Inputs.Base.Vector3; - } - declare class DragonCupModelDto { - /** - * The model that represents result of the dragon cup - * @default undefined - */ - model: DragonCupData; - } - } - } - declare namespace Boxes { - declare namespace SpicyBox { - declare class SpicyBoxData { - type: string; - name: string; - originalInputs: SpicyBoxDto; - compound?: T; - } - declare class SpicyBoxDtoBase { - textTop: V; - textFront: V; - height: T; - coverHeight: T; - baseHeight: T; - radiusBase: T; - radiusOffset: T; - thickness: T; - ornamentalThickness: T; - nrOrnamnetsPerSide: T; - invertOrnaments: Z; - fillet: T; - nrSides: T; - nrOffsets: T; - precision: T; - rotation?: T; - scale?: T; - origin?: U; - direction?: U; - } - declare class SpicyBoxDto - implements - SpicyBoxDtoBase - { - constructor( - textTop?: string, - textFront?: string, - nrSides?: number, - nrOffsets?: number, - height?: number, - coverHeight?: number, - baseHeight?: number, - radiusBottom?: number, - radiusTopOffset?: number, - thickness?: number, - ornamentalThickness?: number, - nrOrnamnetsPerSide?: number, - invertOrnaments?: boolean, - fillet?: number, - precision?: number, - rotation?: number, - scale?: number, - origin?: Inputs.Base.Point3, - direction?: Inputs.Base.Vector3 - ); - /** - * Text on the top of the box - * @default Pepper - */ - textTop: string; - /** - * Text on the front of the box - * @default For Your Spicy Needs - */ - textFront: string; - /** - * Nr of sides of the box - * @default 4 - * @minimum 3 - * @maximum 16 - * @step 1 - */ - nrSides: number; - /** - * Nr vertical offsets - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - nrOffsets: number; - /** - * Height of the cup - * @default 6 - * @minimum 0.1 - * @maximum Infinity - * @step 0.1 - */ - height: number; - /** - * Radius top offset - * @default 4 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - radiusBase: number; - /** - * Radius top offset - * @default 2 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - radiusOffset: number; - /** - * Cover height - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - coverHeight: number; - /** - * Base height - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - baseHeight: number; - /** - * Thickness of the cup - * @default 0.6 - * @minimum 0.05 - * @maximum Infinity - * @step 0.01 - */ - thickness: number; - /** - * Ornamental thickness - * @default 0.1 - * @minimum 0.05 - * @maximum Infinity - * @step 0.01 - */ - ornamentalThickness: number; - /** - * Ornamental thickness - * @default 10 - * @minimum 1 - * @maximum Infinity - * @step 1 - */ - nrOrnamnetsPerSide: number; - /** - * Inverst the ornaments - * @default false - */ - invertOrnaments: boolean; - /** - * Fillet of the cup - * @default 0.2 - * @minimum 0.01 - * @maximum Infinity - * @step 0.01 - */ - fillet: number; - /** - * Meshing precision of the drawn model. Scale scales precision as well. The lower the number the more precise the drawn model is. Keep in mind that output of this algorithm also contains pure occt shape that can be meshed separately in draw any async commands - * @default 0.01 - * @minimum 0.000001 - * @maximum 5 - * @step 0.001 - */ - precision: number; - /** - * Rotation of the cup - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 10 - */ - rotation: number; - /** - * Scale of the cup - affects edge width and precision - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 10 - */ - scale: number; - /** - * Origin of the medal - * @default [0, 0, 0] - */ - origin: Inputs.Base.Point3; - /** - * Direction of the model - * @default [0, 1, 0] - */ - direction: Inputs.Base.Vector3; - } - declare class SpicyBoxModelDto { - /** - * The model that represents result of the spicy box - * @default undefined - */ - model: SpicyBoxData; - } - } - } - declare namespace Medals { - declare namespace EternalLove { - declare class EternalLoveData { - type: string; - name: string; - originalInputs: EternalLoveDto; - compound?: T; - } - declare class EternalLoveDtoBase { - textHeading: T; - textName: T; - fullModel: B; - thickness: U; - decorationThickness: U; - rotation?: U; - origin?: V; - direction?: V; - } - declare class EternalLoveDto - implements - EternalLoveDtoBase - { - constructor( - textHeading?: string, - textName?: string, - fullModel?: boolean, - thickness?: number, - decorationThickness?: number, - rotation?: number, - origin?: Inputs.Base.Point3, - direction?: Inputs.Base.Vector3 - ); - /** - * The head text - * @default LOVE YOU - */ - textHeading: string; - /** - * Name of the person - * @default NORA - */ - textName: string; - /** - * Choose whether to produce half of the model (better for 3d printing) or full model with two sides - * @default true - */ - fullModel: boolean; - /** - * Thickness of the model - * @default 6 - * @minimum 0.5 - * @maximum 20 - * @step 0.1 - */ - thickness: number; - /** - * Additional thickness of the decorations - * @default 1 - * @minimum 0.1 - * @maximum 3 - * @step 0.1 - */ - decorationThickness: number; - /** - * Rotation of the erenal love medal - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 10 - */ - rotation: number; - /** - * Origin of the medal - * @default [0, 0, 0] - */ - origin: Inputs.Base.Point3; - /** - * Direction of the model - * @default [0, 1, 0] - */ - direction: Inputs.Base.Vector3; - } - } - } - declare namespace Desktop { - declare namespace PhoneNest { - declare class PhoneNestData { - type: string; - /** - * The name of the model - */ - name: string; - /** - * Original inputs that were used to create the model - */ - originalInputs: PhoneNestDto; - /** - * Compound shape of the table geometry - */ - compound?: T; - /** - * Representation of table parts that are useful for drawing the object efficiently - */ - drawingPart?: PhoneNestDrawingPart; - /** - * Data that contains information and shapes of the top part of the table - */ - mainPart?: PhoneNestMainPart; - /** - * All the shapes of the vase - */ - shapes?: Models.OCCT.ShapeWithId[]; - } - declare class PhoneNestDrawDto { - /** - * Main material - * @defaul undefined - * @optional true - */ - mainMaterial?: T; - /** - * Phone material - * @defaul undefined - * @optional true - */ - phoneMaterial?: T; - /** - * You can turn off drawing of faces via this property - * @default true - */ - drawFaces: boolean; - /** - * Meshing precision of the drawn model. The lower the number the more precise the drawn model is. Keep in mind that output of this algorithm also contains pure occt shape that can be meshed separately in draw any async commands - * @default 0.001 - * @minimum 0.000001 - * @maximum 5 - * @step 0.001 - */ - precision: number; - /** - * Defines if the edges of the model should be drawn - * @default true - */ - drawEdges: boolean; - /** - * Hex colour string for the edges - * @default #ffffff - */ - edgeColour: Inputs.Base.Color; - /** - * Edge width - * @default 0.06 - * @minimum 0 - * @maximum Infinity - */ - edgeWidth: number; - } - /** - * This defines useful compounded objects for representing model in optimal and fast way. - */ - declare class PhoneNestDrawingPartShapes { - /** - * The representation of main part of the table - */ - main?: T; - /** - * The representation of the glass of the table - */ - phone?: T; - } - /** - * Information needed to draw the part in an optimal way - */ - declare class PhoneNestDrawingPart extends Part { - /** - * Shapes that exist in the drawing part, T can represent opancascade geometry, - * babylonjs mesh, materials or other things that map to these drawing categories. - */ - shapes?: PhoneNestDrawingPartShapes; - } - declare class PhoneNestDtoBase { - heightBottom: T; - heightTop: T; - widthBack: T; - widthFront: T; - length: T; - backOffset: T; - thickness: T; - filletRadius: T; - applyOrnaments: B; - phoneHeight: T; - phoneWidth: T; - phoneThickness: T; - precision: T; - rotation?: T; - scale?: T; - origin?: U; - direction?: U; - } - declare class PhoneNestDto - implements PhoneNestDtoBase - { - constructor( - heightBottom?: number, - heightTop?: number, - widthBack?: number, - widthFront?: number, - length?: number, - backOffset?: number, - thickness?: number, - applyOrnaments?: boolean, - filletRadius?: number, - phoneHeight?: number, - phoneWidth?: number, - phoneThickness?: number, - precision?: number, - drawEdges?: boolean, - rotation?: number, - scale?: number, - origin?: Inputs.Base.Point3, - direction?: Inputs.Base.Vector3 - ); - /** - * Height of the phone holder at the bottom - * @default 5 - * @minimum 0 - * @maximum Infinity - * @step 0.01 - */ - heightBottom: number; - /** - * Height of the phone holder at the top - * @default 16 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - heightTop: number; - /** - * Width of the phone holder on the back - * @default 25 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - widthBack: number; - /** - * Width of the phone holder on the front and holder - * @default 10 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - widthFront: number; - /** - * Length of the holder base - * @default 16 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - length: number; - /** - * The back offset - * @default 6 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - backOffset: number; - /** - * The thickness of the table - * @default 0.4 - * @minimum 0.01 - * @maximum Infinity - * @step 0.01 - */ - thickness: number; - /** - * Apply final ornaments - * @default false - */ - applyOrnaments: boolean; - /** - * The radius of the fillet - * @default 2 - * @minimum 0.001 - * @maximum Infinity - * @step 0.1 - */ - filletRadius: number; - /** - * The height of the phone - * @default 16.8 - * @minimum 0 - * @maximum Infinitypho - * @step 0.01 - */ - phoneHeight: number; - /** - * The width of the phone - * @default 7.8 - * @minimum 0 - * @maximum Infinity - * @step 0.01 - */ - phoneWidth: number; - /** - * The thickness of the phone - * @default 0.7 - * @minimum 0 - * @maximum Infinity - * @step 0.01 - */ - phoneThickness: number; - /** - * Meshing precision of the drawn model. The lower the number the more precise the drawn model is. Keep in mind that output of this algorithm also contains pure occt shape that can be meshed separately in draw any async commands - * @default 0.01 - * @minimum 0.000001 - * @maximum 5 - * @step 0.001 - */ - precision: number; - /** - * Defines if the edges of the model should be drawn - * @default true - */ - drawEdges: boolean; - /** - * Rotation of the table in degrees - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 10 - */ - rotation: number; - /** - * Scale of the table - * @default 1 - * @minimum 0 - * @maximum Infinity - */ - scale: number; - /** - * Origin of the medal - * @default [0, 0, 0] - */ - origin: Inputs.Base.Point3; - /** - * Direction of the model - * @default [0, 1, 0] - */ - direction: Inputs.Base.Vector3; - } - declare class PhoneNestModelDto { - /** - * The model that represents result of the good coffee table create operation - * @default undefined - */ - model: PhoneNestData; - } - declare class PhoneNestMainPart extends Part { - shapes?: { - phone?: T; - main?: T; - compound?: T; - }; - } - } - } - } - - declare namespace LaserCutting { - declare namespace Gadgets { - declare namespace DropletsPhoneHolder { - declare class DropletsPhoneHolderData { - /** - * Type of the object being configured - */ - type: string; - /** - * Default name of the object - */ - name: string; - /** - * Compound shape of all the parts - */ - compound?: T; - /** - * Original inputs - */ - originalInputs: DropletsPhoneHolderDto; - /** - * All the shapes of the vase - */ - shapes?: Models.OCCT.ShapeWithId[]; - /** - * Representation of arabic archway parts that are useful for drawing the object efficiently - */ - drawingPart?: DropletsPhoneHolderDrawingPart; - } - declare class DropletsPhoneHolderDrawingPartShapes { - /** - * The representation of all the objects in the phone holder, including all wires - */ - compound?: T; - /** - * The representation of 3D model of the phone holder - */ - phoneHolderCompound?: T; - /** - * The representation of all cut wires - */ - cutWiresCompound?: T; - /** - * The representation of the engraving wires - */ - engravingWiresCompound?: T; - } - /** - * Information needed to draw the part in an optimal way - */ - declare class DropletsPhoneHolderDrawingPart { - /** - * Shapes that exist in the drawing part, T can represent opancascade geometry, - * babylonjs mesh, materials or other things that map to these drawing categories. - */ - shapes?: - | DropletsPhoneHolderDrawingPartShapes - | { - [x: string]: T; - }; - } - declare class DropletsPhoneHolderDtoBase { - title?: S; - subtitle: S; - includeLogo: B; - thickness: T; - kerf: T; - phoneWidth: T; - phoneHeight: T; - phoneThickness: T; - backLength: T; - angle: T; - offsetAroundPhone: T; - penShelf: T; - phoneLockHeight: T; - filletRadius: T; - includePattern: B; - densityPattern: T; - holesForWire: B; - wireInputThickness: T; - includeModel: B; - includeDrawings: B; - spacingDrawings: T; - rotation?: T; - direction?: V; - scale?: V; - origin?: V; - } - declare class DropletsPhoneHolderDto - implements - DropletsPhoneHolderDtoBase< - string, - boolean, - number, - Inputs.Base.Vector3 - > - { - constructor( - title?: string, - subtitle?: string, - includeLogo?: boolean, - thickness?: number, - kerf?: number, - phoneWidth?: number, - phoneHeight?: number, - phoneThickness?: number, - backLength?: number, - angle?: number, - offsetAroundPhone?: number, - penShelf?: number, - phoneLockHeight?: number, - filletRadius?: number, - includePattern?: boolean, - densityPattern?: number, - holesForWire?: boolean, - wireInputThickness?: number, - includeModel?: boolean, - includeDrawings?: boolean, - spacingDrawings?: number, - rotation?: number, - origin?: Inputs.Base.Point3, - direction?: Inputs.Base.Point3, - scale?: Inputs.Base.Vector3 - ); - /** - * Title of the phone holder - * @default Your Name - */ - title: string; - /** - * Subtitle of the phone holder - * @default And Message - */ - subtitle: string; - /** - * Include the logo - * @default true - */ - includeLogo: boolean; - /** - * Thickness of the phone holder - * @default 0.4 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - thickness: number; - /** - * Kerf value for the laser cutting of joints - * @default 0.01 - * @minimum 0 - * @maximum Infinity - * @step 0.001 - */ - kerf: number; - /** - * Width of the phone - * @default 8 - * @minimum 4 - * @maximum Infinity - * @step 0.1 - */ - phoneWidth: number; - /** - * Height of the phone - * @default 16 - * @minimum 4 - * @maximum Infinity - * @step 0.1 - */ - phoneHeight: number; - /** - * Thickness of the phone - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - phoneThickness: number; - /** - * Length of the back - * @default 10 - * @minimum 5 - * @maximum Infinity - * @step 0.1 - */ - backLength: number; - /** - * Angle of the back - * @default 20 - * @minimum 0 - * @maximum 60 - * @step 1 - */ - angle: number; - /** - * Offset around the phone - * @default 0.5 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - offsetAroundPhone: number; - /** - * Pen shelf - * @default 1 - * @minimum 0.5 - * @maximum Infinity - * @step 0.1 - */ - penShelf: number; - /** - * Phone lock height - * @default 2 - * @minimum 0.5 - * @maximum Infinity - * @step 0.1 - */ - phoneLockHeight: number; - /** - * Fillet radius - * @default 0.3 - * @minimum 0.1 - * @maximum 0.4 - * @step 0.1 - */ - filletRadius: number; - /** - * Include pattern - * @default false - */ - includePattern: boolean; - /** - * Density of the pattern - * @default 0.4 - * @minimum 0 - * @maximum 2 - * @step 0.1 - */ - densityPattern: number; - /** - * Include pattern - * @default true - */ - holesForWire: boolean; - /** - * Wire input thickness - * @default 1.5 - * @minimum 0.7 - * @maximum Infinity - * @step 0.1 - */ - wireInputThickness: number; - /** - * Include 3D model - * @default true - */ - includeModel: boolean; - /** - * Include drawings - * @default true - */ - includeDrawings: boolean; - /** - * Spacing of the drawings - * @default 0.5 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - spacingDrawings: number; - /** - * Rotation of the model - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 10 - */ - rotation: number; - /** - * Origin of the model - * @default [0, 0, 0] - */ - origin: Inputs.Base.Point3; - /** - * Direction of the model - * @default [0, 1, 0] - */ - direction: Inputs.Base.Point3; - /** - * Scale of the model - * @default [1, 1, 1] - */ - scale: Inputs.Base.Vector3; - } - declare class DropletsPhoneHolderModelDto { - /** - * The model that represents result of the model - * @default undefined - */ - model: DropletsPhoneHolderData; - } - declare class DropletsPhoneHolderModelDxfDto { - /** - * The model that represents result of the model - * @default undefined - */ - model: DropletsPhoneHolderData; - /** - * The laser cut wires color - * @default #000000 - */ - cutWiresColor: Inputs.Base.Color; - /** - * The laser engraving wires color - * @default #0000ff - */ - engravingWiresColor: Inputs.Base.Color; - /** - * The file name - * @default bitbybit-droplets-phone-holder - */ - fileName: string; - /** - * The angular deflection - * @default 0.1 - * @minimum 0 - * @maximum Infinity - * @step 0.01 - */ - angularDeflection: number; - /** - * The curvature deflection - * @default 0.1 - * @minimum 0 - * @maximum Infinity - * @step 0.001 - */ - curvatureDeflection: number; - /** - * Minimum of points - * @default 2 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - minimumOfPoints: number; - /** - * U tolerance - * @default 1.0e-9 - * @minimum 0 - * @maximum Infinity - * @step 1.0e-9 - */ - uTolerance: number; - /** - * Minimum length - * @default 1.0e-7 - * @minimum 0 - * @maximum Infinity - * @step 1.0e-7 - */ - minimumLength: number; - } - declare class DropletsPhoneHolderModelStepDto { - /** - * The model that represents result of the model - * @default undefined - */ - model: DropletsPhoneHolderData; - /** - * The file name - * @default bitbybit-droplets-phone-holder - */ - fileName: string; - /** - * Adjust Y to Z axis - * @default true - */ - adjustYZ: boolean; - } - } - } - } - - declare namespace Furniture { - declare namespace Chairs { - declare namespace SnakeChair { - declare class SnakeChairData { - type: string; - /** - * The name of the model - */ - name: string; - /** - * Original inputs that were used to create the model - */ - originalInputs: SnakeChairDto; - /** - * Compound shape of the table geometry - */ - compound?: T; - /** - * Representation of table parts that are useful for drawing the object efficiently - */ - drawingPart?: SnakeChairDrawingPart; - /** - * Data that contains information and shapes of the top part of the table - */ - mainPart?: SnakeChairMainPart; - /** - * All the shapes of the vase - */ - shapes?: Models.OCCT.ShapeWithId[]; - } - declare class SnakeChairDrawDto { - /** - * Main material - * @defaul undefined - * @optional true - */ - mainMaterial?: T; - /** - * You can turn off drawing of faces via this property - * @default true - */ - drawFaces: boolean; - /** - * Meshing precision of the drawn model. The lower the number the more precise the drawn model is. Keep in mind that output of this algorithm also contains pure occt shape that can be meshed separately in draw any async commands - * @default 0.001 - * @minimum 0.000001 - * @maximum 5 - * @step 0.001 - */ - precision: number; - /** - * Defines if the edges of the model should be drawn - * @default true - */ - drawEdges: boolean; - /** - * Hex colour string for the edges - * @default #ffffff - */ - edgeColour: Inputs.Base.Color; - /** - * Edge width - * @default 0.06 - * @minimum 0 - * @maximum Infinity - */ - edgeWidth: number; - } - /** - * This defines useful compounded objects for representing model in optimal and fast way. - */ - declare class SnakeChairDrawingPartShapes { - /** - * The representation of main part of the chair - */ - main?: T; - } - /** - * Information needed to draw the part in an optimal way - */ - declare class SnakeChairDrawingPart extends Part { - /** - * Shapes that exist in the drawing part, T can represent opancascade geometry, - * babylonjs mesh, materials or other things that map to these drawing categories. - */ - shapes?: SnakeChairDrawingPartShapes; - } - declare class SnakeChairDtoBase { - sittingHeight: T; - backRestOffset: T; - backRestHeight: T; - width: T; - length: T; - thickness: T; - ornamentDepth: T; - nrOrnamentPlanks: T; - filletRadius: T; - precision: T; - rotation?: T; - scale?: T; - origin?: U; - direction?: U; - } - declare class SnakeChairDto - implements SnakeChairDtoBase - { - constructor( - sittingHeight?: number, - backRestOffset?: number, - backRestHeight?: number, - width?: number, - length?: number, - thickness?: number, - nrOrnamentPlanks?: number, - ornamentDepth?: number, - filletRadius?: number, - precision?: number, - drawEdges?: boolean, - rotation?: number, - scale?: number, - origin?: Inputs.Base.Point3, - direction?: Inputs.Base.Vector3 - ); - /** - * Height of the sitting area - * @default 0.45 - * @minimum 0.1 - * @maximum Infinity - * @step 0.01 - */ - sittingHeight: number; - /** - * Sitting top offset from perpendicular ending of the chair - * @default 0.1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - backRestOffset: number; - /** - * Height of the back rest - * @default 0.7 - * @minimum 0.1 - * @maximum Infinity - * @step 0.01 - */ - backRestHeight: number; - /** - * Width of the table - * @default 0.45 - * @minimum 0 - * @maximum Infinity - * @step 0.01 - */ - width: number; - /** - * Length of the table - * @default 0.45 - * @minimum 0 - * @maximum Infinity - * @step 0.01 - */ - length: number; - /** - * The thickness of the chair - * @default 0.05 - * @minimum 0.01 - * @maximum Infinity - * @step 0.01 - */ - thickness: number; - /** - * The number of ornament planks - * @default 7 - * @minimum 1 - * @maximum Infinity - * @step 1 - */ - nrOrnamentPlanks: number; - /** - * The ornament depth of the chair - * @default 0.01 - * @minimum 0.001 - * @maximum Infinity - * @step 0.001 - */ - ornamentDepth: number; - /** - * The radius of the fillet - * @default 0.05 - * @minimum 0.001 - * @maximum Infinity - * @step 0.01 - */ - filletRadius: number; - /** - * Meshing precision of the drawn model. The lower the number the more precise the drawn model is. Keep in mind that output of this algorithm also contains pure occt shape that can be meshed separately in draw any async commands - * @default 0.01 - * @minimum 0.000001 - * @maximum 5 - * @step 0.001 - */ - precision: number; - /** - * Defines if the edges of the model should be drawn - * @default true - */ - drawEdges: boolean; - /** - * Rotation of the table in degrees - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 10 - */ - rotation: number; - /** - * Scale of the table - * @default 1 - * @minimum 0 - * @maximum Infinity - */ - scale: number; - /** - * Origin of the medal - * @default [0, 0, 0] - */ - origin: Inputs.Base.Point3; - /** - * Direction of the model - * @default [0, 1, 0] - */ - direction: Inputs.Base.Vector3; - } - declare class SnakeChairModelDto { - /** - * The model that represents result of the good coffee table create operation - * @default undefined - */ - model: SnakeChairData; - } - declare class SnakeChairMainPart extends Part { - sittingCenter?: Inputs.Base.Point3; - shapes?: { - sittingWire?: T; - compound?: T; - }; - } - } - } - declare namespace Tables { - declare namespace ElegantTable { - declare class ElegantTableData { - type: string; - /** - * The name of the model - */ - name: string; - /** - * Original inputs that were used to create the model - */ - originalInputs: ElegantTableDto; - /** - * Compound shape of the table geometry - */ - compound?: T; - /** - * Representation of table parts that are useful for drawing the object efficiently - */ - drawingPart?: ElegantTableDrawingPart; - /** - * Data that contains information and shapes of the top part of the table - */ - topPart?: ElegantTableTopPart; - /** - * Data that contains information and shapes repreesenting the legs of the table - */ - legParts?: ElegantTableLegPart[]; - /** - * All the shapes of the vase - */ - shapes?: Models.OCCT.ShapeWithId[]; - } - declare class ElegantTableDrawDto { - /** - * Material of the top of the table - * @defaul undefined - * @optional true - */ - topMaterial?: T; - /** - * Material of the top base of the table - * @defaul undefined - * @optional true - */ - topBaseMaterial?: T; - /** - * Material of the legs of the table - * @defaul undefined - * @optional true - */ - legsMaterial?: T; - /** - * You can turn off drawing of faces via this property - * @default true - */ - drawFaces: boolean; - /** - * Meshing precision of the drawn model. The lower the number the more precise the drawn model is. Keep in mind that output of this algorithm also contains pure occt shape that can be meshed separately in draw any async commands - * @default 0.001 - * @minimum 0.000001 - * @maximum 5 - * @step 0.001 - */ - precision: number; - /** - * Defines if the edges of the model should be drawn - * @default true - */ - drawEdges: boolean; - /** - * Hex colour string for the edges - * @default #ffffff - */ - edgeColour: Inputs.Base.Color; - /** - * Edge width - * @default 0.06 - * @minimum 0 - * @maximum Infinity - */ - edgeWidth: number; - } - /** - * This defines useful compounded objects for representing elegant table in optimal and fast way. - */ - declare class ElegantTableDrawingPartShapes { - /** - * The representation of top of the table - */ - top?: T; - /** - * The representation of base of the table top - */ - topBase?: T; - /** - * The representation of all legs as compound of the table - */ - legs?: T; - } - /** - * Information needed to draw the part in an optimal way - */ - declare class ElegantTableDrawingPart extends Part { - /** - * Shapes that exist in the drawing part, T can represent opancascade geometry, - * babylonjs mesh, materials or other things that map to these drawing categories. - */ - shapes?: ElegantTableDrawingPartShapes; - } - declare class ElegantTableDtoBase { - height: T; - width: T; - length: T; - topThickness: T; - topOffset: T; - bottomThickness: T; - minFillet: T; - radiusLegTop: T; - radiusLegBottom: T; - nrLegPairs: T; - precision: T; - rotation?: T; - scale?: T; - origin?: U; - direction?: U; - } - declare class ElegantTableDto - implements ElegantTableDtoBase - { - constructor( - height?: number, - width?: number, - length?: number, - topThickness?: number, - topOffset?: number, - bottomThickness?: number, - minFillet?: number, - radiusLegTop?: number, - radiusLegBottom?: number, - nrLegPairs?: number, - precision?: number, - drawEdges?: boolean, - rotation?: number, - scale?: number, - origin?: Inputs.Base.Point3, - direction?: Inputs.Base.Vector3 - ); - /** - * Height of the table - * @default 0.74 - * @minimum 0.1 - * @maximum Infinity - * @step 0.01 - */ - height: number; - /** - * Width of the table - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - width: number; - /** - * Length of the table - * @default 2 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - length: number; - /** - * Top thickness of the table - * @default 0.02 - * @minimum 0.001 - * @maximum Infinity - * @step 0.001 - */ - topThickness: number; - /** - * Top offset from the base of the table - * @default 0.03 - * @minimum 0 - * @maximum Infinity - * @step 0.01 - */ - topOffset: number; - /** - * Bottom thickness of the table - * @default 0.05 - * @minimum 0.01 - * @maximum Infinity - * @step 0.01 - */ - bottomThickness: number; - /** - * Fillet table corners - * @default 0.2 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - minFillet: number; - /** - * Radius leg top - * @default 0.03 - * @minimum 0.01 - * @maximum Infinity - * @step 0.01 - */ - radiusLegTop: number; - /** - * Radius leg top - * @default 0.01 - * @minimum 0.01 - * @maximum Infinity - * @step 0.01 - */ - radiusLegBottom: number; - /** - * The number of leg pairs of the table - * @default 2 - * @minimum 2 - * @maximum Infinity - * @step 1 - */ - nrLegPairs: number; - /** - * Meshing precision of the drawn model. The lower the number the more precise the drawn model is. Keep in mind that output of this algorithm also contains pure occt shape that can be meshed separately in draw any async commands - * @default 0.001 - * @minimum 0.000001 - * @maximum 5 - * @step 0.001 - */ - precision: number; - /** - * Defines if the edges of the model should be drawn - * @default true - */ - drawEdges: boolean; - /** - * Rotation of the table in degrees - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 10 - */ - rotation: number; - /** - * Scale of the table - * @default 1 - * @minimum 0 - * @maximum Infinity - */ - scale: number; - /** - * Origin of the medal - * @default [0, 0, 0] - */ - origin: Inputs.Base.Point3; - /** - * Direction of the model - * @default [0, 1, 0] - */ - direction: Inputs.Base.Vector3; - } - declare class ElegantTableLegByIndexDto { - /** - * The model that represents result of the elegant table create operation - * @default undefined - */ - model: ElegantTableData; - /** - * The index of the leg to be returned - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - index: number; - } - declare class ElegantTableLegPart extends Part { - topCenter?: Inputs.Base.Point3; - bottomCenter?: Inputs.Base.Point3; - topRadius?: number; - bottomRadius?: number; - shapes?: { - topCircleWire?: T; - bottomCircleWire?: T; - leg?: T; - }; - } - declare class ElegantTableModelDto { - /** - * The model that represents result of the elegant table create operation - * @default undefined - */ - model: ElegantTableData; - } - declare class ElegantTableTopPart extends Part { - topCenter?: Inputs.Base.Point3; - bottomCenter?: Inputs.Base.Point3; - shapes?: { - topPanel?: T; - topWire?: T; - bottomWire?: T; - bottomPanel?: T; - compound?: T; - }; - } - } - declare namespace GoodCoffeeTable { - declare class GoodCoffeeTableData { - type: string; - /** - * The name of the model - */ - name: string; - /** - * Original inputs that were used to create the model - */ - originalInputs: GoodCoffeeTableDto; - /** - * Compound shape of the table geometry - */ - compound?: T; - /** - * Representation of table parts that are useful for drawing the object efficiently - */ - drawingPart?: GoodCoffeeTableDrawingPart; - /** - * Data that contains information and shapes of the top part of the table - */ - topPart?: GoodCoffeeTableTopPart; - /** - * Data that contains information and shapes of the shelf part of the table - */ - shelfPart?: GoodCoffeeTableShelfPart; - /** - * Data that contains information and shapes repreesenting the legs of the table - */ - legParts?: GoodCoffeeTableLegPart[]; - /** - * All the shapes of the vase - */ - shapes?: Models.OCCT.ShapeWithId[]; - } - declare class GoodCoffeeTableDrawDto { - /** - * Material of the glass - * @defaul undefined - * @optional true - */ - topGlassMaterial?: T; - /** - * Material of the top frame of the table - * @defaul undefined - * @optional true - */ - topMaterial?: T; - /** - * Material of the shelf of the table - * @defaul undefined - * @optional true - */ - shelfMaterial?: T; - /** - * Material of the legs of the table - * @defaul undefined - * @optional true - */ - legsMaterial?: T; - /** - * You can turn off drawing of faces via this property - * @default true - */ - drawFaces: boolean; - /** - * Meshing precision of the drawn model. The lower the number the more precise the drawn model is. Keep in mind that output of this algorithm also contains pure occt shape that can be meshed separately in draw any async commands - * @default 0.001 - * @minimum 0.000001 - * @maximum 5 - * @step 0.001 - */ - precision: number; - /** - * Defines if the edges of the model should be drawn - * @default true - */ - drawEdges: boolean; - /** - * Hex colour string for the edges - * @default #ffffff - */ - edgeColour: Inputs.Base.Color; - /** - * Edge width - * @default 0.06 - * @minimum 0 - * @maximum Infinity - */ - edgeWidth: number; - } - /** - * This defines useful compounded objects for representing elegant table in optimal and fast way. - */ - declare class GoodCoffeeTableDrawingPartShapes { - /** - * The representation of top of the table - */ - top?: T; - /** - * The representation of glass of the table top - */ - topGlass?: T; - /** - * The shelf of the table - */ - shelf?: T; - /** - * The representation of all legs as compound of the table - */ - legs?: T; - } - /** - * Information needed to draw the part in an optimal way - */ - declare class GoodCoffeeTableDrawingPart extends Part { - /** - * Shapes that exist in the drawing part, T can represent opancascade geometry, - * babylonjs mesh, materials or other things that map to these drawing categories. - */ - shapes?: GoodCoffeeTableDrawingPartShapes; - } - declare class GoodCoffeeTableDtoBase { - height: T; - width: T; - length: T; - topThickness: T; - topGlassOffset: T; - glassThickness: T; - glassHolderLength: T; - chamfer: T; - shelfTopOffset: T; - shelfThickness: T; - legWidth: T; - legDepth: T; - precision: T; - rotation?: T; - scale?: T; - origin?: U; - direction?: U; - } - declare class GoodCoffeeTableDto - implements GoodCoffeeTableDtoBase - { - constructor( - height?: number, - width?: number, - length?: number, - chamfer?: number, - topThickness?: number, - topGlassOffset?: number, - glassThickness?: number, - glassHolderLength?: number, - shelfTopOffset?: number, - shelfThickness?: number, - legWidth?: number, - legDepth?: number, - precision?: number, - drawEdges?: boolean, - rotation?: number, - scale?: number, - origin?: Inputs.Base.Point3, - direction?: Inputs.Base.Vector3 - ); - /** - * Height of the table - * @default 0.4 - * @minimum 0.1 - * @maximum Infinity - * @step 0.01 - */ - height: number; - /** - * Width of the table - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - width: number; - /** - * Length of the table - * @default 1.2 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - length: number; - /** - * Chamfer the corners - * @default 0.01 - * @minimum 0 - * @maximum Infinity - * @step 0.001 - */ - chamfer: number; - /** - * Top thickness of the table - * @default 0.05 - * @minimum 0.001 - * @maximum Infinity - * @step 0.001 - */ - topThickness: number; - /** - * Top offset from the edge of the table till the glass - * @default 0.2 - * @minimum 0 - * @maximum Infinity - * @step 0.01 - */ - topGlassOffset: number; - /** - * Glass thickness of the table - * @default 0.005 - * @minimum 0.001 - * @maximum Infinity - * @step 0.001 - */ - glassThickness: number; - /** - * Glass holder length of the table - * @default 0.02 - * @minimum 0.001 - * @maximum Infinity - * @step 0.001 - */ - glassHolderLength: number; - /** - * The offset of the shelf from the bottom of the top - 0 means that no shelf is made as such shelf would be non-functional. - * @default 0.15 - * @minimum 0 - * @maximum Infinity - * @step 0.01 - */ - shelfTopOffset: number; - /** - * Shelf thickness - * @default 0.03 - * @minimum 0.001 - * @maximum Infinity - * @step 0.001 - */ - shelfThickness: number; - /** - * Width of the leg - * @default 0.1 - * @minimum 0.01 - * @maximum Infinity - * @step 0.01 - */ - legWidth: number; - /** - * The depth of the leg - * @default 0.05 - * @minimum 0.01 - * @maximum Infinity - * @step 0.01 - */ - legDepth: number; - /** - * Meshing precision of the drawn model. The lower the number the more precise the drawn model is. Keep in mind that output of this algorithm also contains pure occt shape that can be meshed separately in draw any async commands - * @default 0.001 - * @minimum 0.000001 - * @maximum 5 - * @step 0.001 - */ - precision: number; - /** - * Defines if the edges of the model should be drawn - * @default true - */ - drawEdges: boolean; - /** - * Rotation of the table in degrees - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 10 - */ - rotation: number; - /** - * Scale of the table - * @default 1 - * @minimum 0 - * @maximum Infinity - */ - scale: number; - /** - * Origin of the medal - * @default [0, 0, 0] - */ - origin: Inputs.Base.Point3; - /** - * Direction of the model - * @default [0, 1, 0] - */ - direction: Inputs.Base.Vector3; - } - declare class GoodCoffeeTableLegByIndexDto { - /** - * The model that represents result of the elegant table create operation - * @default undefined - */ - model: GoodCoffeeTableData; - /** - * The index of the leg to be returned - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - index: number; - } - declare class GoodCoffeeTableLegPart extends Part { - topCenter?: Inputs.Base.Point3; - bottomCenter?: Inputs.Base.Point3; - width: number; - depth: number; - height: number; - shapes?: { - topWire?: T; - bottomWire?: T; - leg?: T; - }; - } - declare class GoodCoffeeTableModelDto { - /** - * The model that represents result of the good coffee table create operation - * @default undefined - */ - model: GoodCoffeeTableData; - } - declare class GoodCoffeeTableShelfPart extends Part { - topCenter?: Inputs.Base.Point3; - bottomCenter?: Inputs.Base.Point3; - shapes?: { - topWire?: T; - bottomWire?: T; - compound?: T; - }; - } - declare class GoodCoffeeTableTopPart extends Part { - topCenter?: Inputs.Base.Point3; - shapes?: { - topFrame?: T; - topWire?: T; - glassWire?: T; - glassPanel?: T; - compound?: T; - }; - } - } - declare namespace SnakeTable { - declare class SnakeTableData { - type: string; - /** - * The name of the model - */ - name: string; - /** - * Original inputs that were used to create the model - */ - originalInputs: SnakeTableDto; - /** - * Compound shape of the table geometry - */ - compound?: T; - /** - * Representation of table parts that are useful for drawing the object efficiently - */ - drawingPart?: SnakeTableDrawingPart; - /** - * Data that contains information and shapes of the top part of the table - */ - mainPart?: SnakeTableMainPart; - /** - * All the shapes of the vase - */ - shapes?: Models.OCCT.ShapeWithId[]; - } - declare class SnakeTableDrawDto { - /** - * Main material - * @defaul undefined - * @optional true - */ - mainMaterial?: T; - /** - * Glass material - * @defaul undefined - * @optional true - */ - glassMaterial?: T; - /** - * You can turn off drawing of faces via this property - * @default true - */ - drawFaces: boolean; - /** - * Meshing precision of the drawn model. The lower the number the more precise the drawn model is. Keep in mind that output of this algorithm also contains pure occt shape that can be meshed separately in draw any async commands - * @default 0.001 - * @minimum 0.000001 - * @maximum 5 - * @step 0.001 - */ - precision: number; - /** - * Defines if the edges of the model should be drawn - * @default true - */ - drawEdges: boolean; - /** - * Hex colour string for the edges - * @default #ffffff - */ - edgeColour: Inputs.Base.Color; - /** - * Edge width - * @default 0.06 - * @minimum 0 - * @maximum Infinity - */ - edgeWidth: number; - } - /** - * This defines useful compounded objects for representing model in optimal and fast way. - */ - declare class SnakeTableDrawingPartShapes { - /** - * The representation of main part of the table - */ - main?: T; - /** - * The representation of the glass of the table - */ - glass?: T; - } - /** - * Information needed to draw the part in an optimal way - */ - declare class SnakeTableDrawingPart extends Part { - /** - * Shapes that exist in the drawing part, T can represent opancascade geometry, - * babylonjs mesh, materials or other things that map to these drawing categories. - */ - shapes?: SnakeTableDrawingPartShapes; - } - declare class SnakeTableDtoBase { - height: T; - width: T; - length: T; - supportLength: T; - shelfHeight: T; - glassThickness: T; - glassOffset: T; - thickness: T; - ornamentDepth: T; - nrOrnamentPlanks: T; - filletRadius: T; - precision: T; - rotation?: T; - scale?: T; - origin?: U; - direction?: U; - } - declare class SnakeTableDto - implements SnakeTableDtoBase - { - constructor( - height?: number, - width?: number, - length?: number, - supportLength?: number, - shelfHeight?: number, - thickness?: number, - glassThickness?: number, - glassOffset?: number, - nrOrnamentPlanks?: number, - ornamentDepth?: number, - filletRadius?: number, - precision?: number, - drawEdges?: boolean, - rotation?: number, - scale?: number, - origin?: Inputs.Base.Point3, - direction?: Inputs.Base.Vector3 - ); - /** - * Height of the table - * @default 0.74 - * @minimum 0 - * @maximum Infinity - * @step 0.01 - */ - height: number; - /** - * Width of the table - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.01 - */ - width: number; - /** - * Length of the table - * @default 2 - * @minimum 0 - * @maximum Infinity - * @step 0.01 - */ - length: number; - /** - * The length of the support - * @default 0.5 - * @minimum 0 - * @maximum Infinity - * @step 0.01 - */ - supportLength: number; - /** - * The height of the shelf - * @default 0.2 - * @minimum 0 - * @maximum Infinity - * @step 0.01 - */ - shelfHeight: number; - /** - * The thickness of the table - * @default 0.05 - * @minimum 0.01 - * @maximum Infinity - * @step 0.01 - */ - thickness: number; - /** - * The thickness of the glass - * @default 0.005 - * @minimum 0.001 - * @maximum Infinity - * @step 0.001 - */ - glassThickness: number; - /** - * The glass offset - goes beyond width and length limitations - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 0.01 - */ - glassOffset: number; - /** - * The number of ornament planks - * @default 7 - * @minimum 1 - * @maximum Infinity - * @step 1 - */ - nrOrnamentPlanks: number; - /** - * The ornament depth of the table - * @default 0.01 - * @minimum 0.001 - * @maximum Infinity - * @step 0.001 - */ - ornamentDepth: number; - /** - * The radius of the fillet - * @default 0.05 - * @minimum 0.001 - * @maximum Infinity - * @step 0.01 - */ - filletRadius: number; - /** - * Meshing precision of the drawn model. The lower the number the more precise the drawn model is. Keep in mind that output of this algorithm also contains pure occt shape that can be meshed separately in draw any async commands - * @default 0.01 - * @minimum 0.000001 - * @maximum 5 - * @step 0.001 - */ - precision: number; - /** - * Defines if the edges of the model should be drawn - * @default true - */ - drawEdges: boolean; - /** - * Rotation of the table in degrees - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 10 - */ - rotation: number; - /** - * Scale of the table - * @default 1 - * @minimum 0 - * @maximum Infinity - */ - scale: number; - /** - * Origin of the medal - * @default [0, 0, 0] - */ - origin: Inputs.Base.Point3; - /** - * Direction of the model - * @default [0, 1, 0] - */ - direction: Inputs.Base.Vector3; - } - declare class SnakeTableModelDto { - /** - * The model that represents result of the good coffee table create operation - * @default undefined - */ - model: SnakeTableData; - } - declare class SnakeTableMainPart extends Part { - topCenter?: Inputs.Base.Point3; - shapes?: { - topWire?: T; - glass?: T; - main?: T; - compound?: T; - }; - } - } - } - } - - declare namespace Shared { - declare class Part { - id?: string; - rotation?: number; - center?: Inputs.Base.Point3; - scale?: Inputs.Base.Vector3; - direction?: Inputs.Base.Vector3; - } - } - } - declare namespace Advanced { - declare namespace Enums { - declare enum outputShapeEnum { - wire = "wire", - face = "face", - solid = "solid", - } - } - declare namespace Text3D { - declare class CharacterPart { - id: string; - shapes?: { - compound?: T; - }; - } - declare class FacePart { - id: string; - type: faceTypeEnum; - shapes?: { - face?: T; - }; - } - declare enum faceTextVarEnum { - separatedExtrusion = "separatedExtrusion", - integratedExtrusion = "integratedExtrusion", - cutout = "cutout", - } - declare enum faceTypeEnum { - compound = "compound", - cutout = "originalCutout", - cutoutInsideCharacter = "cutoutInsideCharacter", - } - declare class FontDefinition { - name: string; - type?: fontsEnum; - variant?: fontVariantsEnum; - font: Font; - } - declare const fontsModel: { - key: string; - variants: string[]; - }[]; - declare enum fontVariantsEnum { - Regular = "Regular", - Black = "Black", - Bold = "Bold", - ExtraBold = "ExtraBold", - Medium = "Medium", - SemiBold = "SemiBold", - BlackItalic = "BlackItalic", - BoldItalic = "BoldItalic", - Italic = "Italic", - Light = "Light", - LightItalic = "LightItalic", - MediumItalic = "MediumItalic", - Thin = "Thin", - ThinItalic = "ThinItalic", - ExtraLight = "ExtraLight", - } - declare enum fontsEnum { - Aboreto = "Aboreto", - Bungee = "Bungee", - IndieFlower = "IndieFlower", - Lugrasimo = "Lugrasimo", - Orbitron = "Orbitron", - Roboto = "Roboto", - RobotoSlab = "RobotoSlab", - Silkscreen = "Silkscreen", - Tektur = "Tektur", - Workbench = "Workbench", - } - declare enum recAlignmentEnum { - leftTop = "leftTop", - leftMiddle = "leftMiddle", - leftBottom = "leftBottom", - centerTop = "centerTop", - centerMiddle = "centerMiddle", - centerBottom = "centerBottom", - rightTop = "rightTop", - rightMiddle = "rightMiddle", - rightBottom = "rightBottom", - } - declare class Text3DData { - /** - * Type of the object being configured - */ - type: string; - /** - * Default name of the object - */ - name: string; - /** - * The advance width of the text - */ - advanceWidth: number; - /** - * The bounding box of the text - */ - boundingBox: { - x1: number; - y1: number; - x2: number; - y2: number; - }; - /** - * Original inputs - */ - originalInputs?: Text3DDto | Texts3DFaceDto; - /** - * Compounded shape of the 3d text - */ - compound?: T; - /** - * The parts of letters - */ - characterParts?: CharacterPart[]; - /** - * This only applies if we use 3d text on face algorithms - */ - faceParts?: FacePart[]; - /** - * All the shapes of the 3d text - */ - shapes?: Models.OCCT.ShapeWithId[]; - /** - * All the letter coordinates of the 3d text - */ - characterCenterCoordinates: Inputs.Base.Point3[]; - } - declare class Text3DDto { - constructor( - text?: string, - fontType?: fontsEnum, - fontVariant?: fontVariantsEnum, - fontSize?: number, - height?: number, - rotation?: number, - origin?: Inputs.Base.Vector3, - direction?: Inputs.Base.Vector3, - originAlignment?: recAlignmentEnum - ); - /** - * The type of font to use - * @default bitbybit.dev - */ - text: string; - /** - * The type of font to use - * @default Roboto - */ - fontType: fontsEnum; - /** - * The type of font to use - * @default Regular - */ - fontVariant: fontVariantsEnum; - /** - * The size of the font - * @default 1.5 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - fontSize: number; - /** - * The height of the font extrusion, if 0 then face will be returned and not a solid - * @default 0.2 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - height: number; - /** - * The rotation of the generated text - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 15 - */ - rotation: number; - /** - * Origin of the text - * @default [0, 0, 0] - */ - origin: Inputs.Base.Vector3; - /** - * Direction of the text - * @default [0, 1, 0] - */ - direction: Inputs.Base.Vector3; - /** - * Origin alignment - * @default centerMiddle - */ - originAlignment: recAlignmentEnum; - } - declare class Text3DFaceDefinitionDto { - constructor( - faceTextVar?: faceTextVarEnum, - text?: string, - fontType?: fontsEnum, - fontVariant?: fontVariantsEnum, - fontSize?: number, - height?: number, - rotation?: number, - originParamU?: number, - originParamV?: number, - originAlignment?: recAlignmentEnum - ); - /** - * You can choose how your face text will be constructed. - * Separated extrusion will only return text letters - * Integrated extrusion will create a shell from the extruded text and original face - * Integrated pull in will create a shell from the negative extrusion and original face - * Cutout will return compound with faces that are left after cutting the original face with text - * @default separatedExtrusion - */ - faceTextVar: faceTextVarEnum; - /** - * The type of font to use - * @default bitbybit.dev - */ - text: string; - /** - * The type of font to use - * @default Roboto - */ - fontType: fontsEnum; - /** - * The type of font to use - * @default Regular - */ - fontVariant: fontVariantsEnum; - /** - * The size of the font - * @default 1.5 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - fontSize: number; - /** - * The height of the font extrusion, if 0 then face will be returned and not a solid - * @default 0.2 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - height: number; - /** - * The rotation of the generated text - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 15 - */ - rotation: number; - /** - * Origin u param for the text 0 - 1 - * @default 0.5 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - originParamU: number; - /** - * Origin v param for the text 0 - 1 - * @default 0.5 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - originParamV: number; - /** - * Origin alignment - * @default centerMiddle - */ - originAlignment: recAlignmentEnum; - } - declare class Text3DFaceDefinitionUrlDto { - constructor( - faceTextVar?: faceTextVarEnum, - text?: string, - fontUrl?: string, - fontSize?: number, - height?: number, - rotation?: number, - originParamU?: number, - originParamV?: number, - originAlignment?: recAlignmentEnum - ); - /** - * You can choose how your face text will be constructed. - * Separated extrusion will only return text letters - * Integrated extrusion will create a shell from the extruded text and original face - * Integrated pull in will create a shell from the negative extrusion and original face - * Cutout will return compound with faces that are left after cutting the original face with text - * @default separatedExtrusion - */ - faceTextVar: faceTextVarEnum; - /** - * The type of font to use - * @default bitbybit.dev - */ - text: string; - /** - * The font URL to load and use. If Url is provided then font will be loaded using opentype.js. - * Supported formats are: ttf, otf, woff. - * Please note that Woff2 is not supported by opentype.js as it is a compressed format. - * @default https://cdn.jsdelivr.net/gh/bitbybit-dev/bitbybit-assets@latest/fonts/Tektur/Tektur-Bold.ttf - */ - fontUrl: string; - /** - * The size of the font - * @default 1.5 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - fontSize: number; - /** - * The height of the font extrusion, if 0 then face will be returned and not a solid - * @default 0.2 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - height: number; - /** - * The rotation of the generated text - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 15 - */ - rotation: number; - /** - * Origin u param for the text 0 - 1 - * @default 0.5 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - originParamU: number; - /** - * Origin v param for the text 0 - 1 - * @default 0.5 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - originParamV: number; - /** - * Origin alignment - * @default centerMiddle - */ - originAlignment: recAlignmentEnum; - } - declare class Text3DFaceDefinitionUrlParsedDto { - constructor( - faceTextVar?: faceTextVarEnum, - text?: string, - letterPaths?: any, - fontSize?: number, - height?: number, - rotation?: number, - originParamU?: number, - originParamV?: number, - originAlignment?: recAlignmentEnum - ); - /** - * You can choose how your face text will be constructed. - * Separated extrusion will only return text letters - * Integrated extrusion will create a shell from the extruded text and original face - * Integrated pull in will create a shell from the negative extrusion and original face - * Cutout will return compound with faces that are left after cutting the original face with text - * @default separatedExtrusion - */ - faceTextVar: faceTextVarEnum; - /** - * The type of font to use - * @default bitbybit.dev - */ - text: string; - /** - * The parsed letter paths that were generated by opentype.js - * @default undefined - */ - letterPaths: any; - /** - * The size of the font - * @default 1.5 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - fontSize: number; - /** - * The height of the font extrusion, if 0 then face will be returned and not a solid - * @default 0.2 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - height: number; - /** - * The rotation of the generated text - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 15 - */ - rotation: number; - /** - * Origin u param for the text 0 - 1 - * @default 0.5 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - originParamU: number; - /** - * Origin v param for the text 0 - 1 - * @default 0.5 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - originParamV: number; - /** - * Origin alignment - * @default centerMiddle - */ - originAlignment: recAlignmentEnum; - } - declare class Text3DFaceDto { - constructor( - face?: T, - facePlanar?: boolean, - faceTextVar?: faceTextVarEnum, - text?: string, - fontType?: fontsEnum, - fontVariant?: fontVariantsEnum, - fontSize?: number, - height?: number, - rotation?: number, - originParamU?: number, - originParamV?: number, - originAlignment?: recAlignmentEnum - ); - /** - * The face of the text - * @default undefined - */ - face: T; - /** - * If the face is planar it should be true - * @default false - */ - facePlanar: boolean; - /** - * You can choose how your face text will be constructed. - * Separated extrusion will only return text letters - * Integrated extrusion will create a shell from the extruded text and original face - * Integrated pull in will create a shell from the negative extrusion and original face - * Cutout will return compound with faces that are left after cutting the original face with text - */ - faceTextVar: faceTextVarEnum; - /** - * The type of font to use - * @default bitbybit.dev - */ - text: string; - /** - * The type of font to use - * @default Roboto - */ - fontType: fontsEnum; - /** - * The type of font to use - * @default Regular - */ - fontVariant: fontVariantsEnum; - /** - * The size of the font - * @default 1.5 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - fontSize: number; - /** - * The height of the font extrusion, if 0 then face will be returned and not a solid - * @default 0.2 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - height: number; - /** - * The rotation of the generated text - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 15 - */ - rotation: number; - /** - * Origin u param for the text 0 - 1 - * @default 0.5 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - originParamU: number; - /** - * Origin v param for the text 0 - 1 - * @default 0.5 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - originParamV: number; - /** - * Origin alignment - * @default centerMiddle - */ - originAlignment: recAlignmentEnum; - } - declare class Text3DFaceUrlDto { - constructor( - face?: T, - facePlanar?: boolean, - faceTextVar?: faceTextVarEnum, - text?: string, - fontUrl?: string, - fontSize?: number, - height?: number, - rotation?: number, - originParamU?: number, - originParamV?: number, - originAlignment?: recAlignmentEnum - ); - /** - * The face of the text - * @default undefined - */ - face: T; - /** - * If the face is planar it should be true - * @default false - */ - facePlanar: boolean; - /** - * You can choose how your face text will be constructed. - * Separated extrusion will only return text letters - * Integrated extrusion will create a shell from the extruded text and original face - * Integrated pull in will create a shell from the negative extrusion and original face - * Cutout will return compound with faces that are left after cutting the original face with text - */ - faceTextVar: faceTextVarEnum; - /** - * The type of font to use - * @default bitbybit.dev - */ - text: string; - /** - * The font URL to load and use. If Url is provided then font will be loaded using opentype.js. - * Supported formats are: ttf, otf, woff. - * Please note that Woff2 is not supported by opentype.js as it is a compressed format. - * @default https://cdn.jsdelivr.net/gh/bitbybit-dev/bitbybit-assets@latest/fonts/Tektur/Tektur-Bold.ttf - */ - fontUrl: string; - /** - * The size of the font - * @default 1.5 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - fontSize: number; - /** - * The height of the font extrusion, if 0 then face will be returned and not a solid - * @default 0.2 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - height: number; - /** - * The rotation of the generated text - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 15 - */ - rotation: number; - /** - * Origin u param for the text 0 - 1 - * @default 0.5 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - originParamU: number; - /** - * Origin v param for the text 0 - 1 - * @default 0.5 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - originParamV: number; - /** - * Origin alignment - * @default centerMiddle - */ - originAlignment: recAlignmentEnum; - } - declare class Text3DFaceUrlParsedDto { - constructor( - face?: T, - facePlanar?: boolean, - faceTextVar?: faceTextVarEnum, - text?: string, - letterPaths?: any, - fontSize?: number, - height?: number, - rotation?: number, - originParamU?: number, - originParamV?: number, - originAlignment?: recAlignmentEnum - ); - /** - * The face of the text - * @default undefined - */ - face: T; - /** - * If the face is planar it should be true - * @default false - */ - facePlanar: boolean; - /** - * You can choose how your face text will be constructed. - * Separated extrusion will only return text letters - * Integrated extrusion will create a shell from the extruded text and original face - * Integrated pull in will create a shell from the negative extrusion and original face - * Cutout will return compound with faces that are left after cutting the original face with text - */ - faceTextVar: faceTextVarEnum; - /** - * The type of font to use - * @default bitbybit.dev - */ - text: string; - /** - * The parsed letter paths that were generated by opentype.js - * @default undefined - */ - letterPaths: any; - /** - * The size of the font - * @default 1.5 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - fontSize: number; - /** - * The height of the font extrusion, if 0 then face will be returned and not a solid - * @default 0.2 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - height: number; - /** - * The rotation of the generated text - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 15 - */ - rotation: number; - /** - * Origin u param for the text 0 - 1 - * @default 0.5 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - originParamU: number; - /** - * Origin v param for the text 0 - 1 - * @default 0.5 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - originParamV: number; - /** - * Origin alignment - * @default centerMiddle - */ - originAlignment: recAlignmentEnum; - } - declare class Text3DLetterByIndexDto { - /** - * The model that represents result of the text3d create operation - * @default undefined - */ - model: Text3DData; - /** - * The index of the letter to be returned - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - index: number; - } - declare class Text3DModelDto { - /** - * The model that represents result of the text3d create operation - * @default undefined - */ - model: Text3DData; - } - declare class Text3DUrlDto { - constructor( - text?: string, - fontUrl?: string, - fontSize?: number, - height?: number, - rotation?: number, - origin?: Inputs.Base.Vector3, - direction?: Inputs.Base.Vector3, - originAlignment?: recAlignmentEnum - ); - /** - * The type of font to use - * @default bitbybit.dev - */ - text: string; - /** - * The font URL to load and use. If Url is provided then font will be loaded using opentype.js. - * Supported formats are: ttf, otf, woff. - * Please note that Woff2 is not supported by opentype.js as it is a compressed format. - * @default https://cdn.jsdelivr.net/gh/bitbybit-dev/bitbybit-assets@latest/fonts/Tektur/Tektur-Bold.ttf - */ - fontUrl: string; - /** - * The size of the font - * @default 1.5 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - fontSize: number; - /** - * The height of the font extrusion, if 0 then face will be returned and not a solid - * @default 0.2 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - height: number; - /** - * The rotation of the generated text - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 15 - */ - rotation: number; - /** - * Origin of the text - * @default [0, 0, 0] - */ - origin: Inputs.Base.Vector3; - /** - * Direction of the text - * @default [0, 1, 0] - */ - direction: Inputs.Base.Vector3; - /** - * Origin alignment - * @default centerMiddle - */ - originAlignment: recAlignmentEnum; - } - declare class Text3DUrlParsedDto { - constructor( - text?: string, - letterPaths?: any, - fontSize?: number, - height?: number, - rotation?: number, - origin?: Inputs.Base.Vector3, - direction?: Inputs.Base.Vector3, - originAlignment?: recAlignmentEnum - ); - /** - * The type of font to use - * @default bitbybit.dev - */ - text: string; - /** - * The parsed letter paths that were generated by opentype.js - * @default undefined - */ - letterPaths: any; - /** - * The size of the font - * @default 1.5 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - fontSize: number; - /** - * The height of the font extrusion, if 0 then face will be returned and not a solid - * @default 0.2 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - height: number; - /** - * The rotation of the generated text - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 15 - */ - rotation: number; - /** - * Origin of the text - * @default [0, 0, 0] - */ - origin: Inputs.Base.Vector3; - /** - * Direction of the text - * @default [0, 1, 0] - */ - direction: Inputs.Base.Vector3; - /** - * Origin alignment - * @default centerMiddle - */ - originAlignment: recAlignmentEnum; - } - declare class Texts3DFaceDto { - constructor( - face: T, - facePlanar?: boolean, - definitions?: Text3DFaceDefinitionDto[] - ); - /** - * The face of the text - * @default undefined - */ - face: T; - /** - * If the face is planar it should be true - * @default false - */ - facePlanar: boolean; - /** - * The definitions of texts to create on the face - * @default undefined - */ - definitions: Text3DFaceDefinitionDto[]; - } - declare class Texts3DFaceUrlDto { - constructor( - face: T, - facePlanar?: boolean, - definitions?: Text3DFaceDefinitionUrlDto[] - ); - /** - * The face of the text - * @default undefined - */ - face: T; - /** - * If the face is planar it should be true - * @default false - */ - facePlanar: boolean; - /** - * The definitions of texts to create on the face - * @default undefined - */ - definitions: Text3DFaceDefinitionUrlDto[]; - } - declare class Texts3DFaceUrlParsedDto { - constructor( - face: T, - facePlanar?: boolean, - definitions?: Text3DFaceDefinitionUrlParsedDto[] - ); - /** - * The face of the text - * @default undefined - */ - face: T; - /** - * If the face is planar it should be true - * @default false - */ - facePlanar: boolean; - /** - * The definitions of texts to create on the face - * @default undefined - */ - definitions: Text3DFaceDefinitionUrlParsedDto[]; - } - } - declare namespace Patterns { - declare namespace FacePatterns { - declare namespace PyramidSimple { - declare class PyramidSimpleAffectorsDto { - constructor( - faces?: T[], - affectorPoints?: Inputs.Base.Point3[], - uNumber?: number, - vNumber?: number, - minHeight?: number, - maxHeight?: number, - precision?: number - ); - /** - * The faces on which to apply the pattern - * @default undefined - */ - faces: T[]; - /** - * The affector points affect the height of the pyramid elements. The distance is measured between a center point of the corner points and the attractor point. Then it is remapped to certain values. - * @default undefined - */ - affectorPoints: Inputs.Base.Point3[]; - /** - * The affector radius indicates the limit of affection. Cells heights that are further away from the affector than this radius will not be adjusted. If value is not provided, all affector points will use the radius of 10. - * @default undefined - * @optional true - */ - affectorRadiusList?: number[]; - /** - * The affector factors determine if a given affector attracts (value 0 to 1) or repulses (values -1 to 0) the default height of the pyramid elements. - * If value is not provided, all affector points will use the factor of 1 and will thus attract the heights. - * @default undefined - * @optional true - */ - affectorFactors?: number[]; - /** - * The nr of pyramids along u direction of the face - * @default 10 - * @minimum 1 - * @maximum Infinity - * @step 1 - */ - uNumber: number; - /** - * The nr of pyramids along v direction of the face - * @default 5 - * @minimum 1 - * @maximum Infinity - * @step 1 - */ - vNumber: number; - /** - * The default height for the pyramid if it is not affected by any of the affectors. - * @default 0.2 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - defaultHeight: number; - /** - * Min value to add to the height if affector factor is 1 or subtract from the height if affector factor is -1. - * This adds to the height if the affector factor > 0 and subtracts from the height if the affector factor is < 0. - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - affectMinHeight: number; - /** - * Max value to add to the height if affector factor is 1 or subtract from the height if affector factor is -1. - * This adds to the height if the affector factor > 0 and subtracts from the height if the affector factor is < 0. - * @default 1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - affectMaxHeight: number; - /** - * Meshing precision of the drawn model. The lower the number the more precise the drawn model is. Keep in mind that output of this algorithm also contains pure occt shape that can be meshed separately in draw any async commands - * @default 0.01 - * @minimum 0.000001 - * @maximum 5 - * @step 0.001 - */ - precision: number; - } - declare class PyramidSimpeByIndexDto { - /** - * The model that represents result of the pyramid - * @default undefined - */ - model: PyramidSimpleData; - /** - * The index of pyramid element to be returned - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - index: number; - } - declare class PyramidSimpleCellPart { - id: string; - uIndex: number; - vIndex: number; - cornerPoint1: Inputs.Base.Point3; - cornerPoint2: Inputs.Base.Point3; - cornerPoint3: Inputs.Base.Point3; - cornerPoint4: Inputs.Base.Point3; - cornerNormal1?: Inputs.Base.Vector3; - cornerNormal2?: Inputs.Base.Vector3; - cornerNormal3?: Inputs.Base.Vector3; - cornerNormal4?: Inputs.Base.Vector3; - centerPoint?: Inputs.Base.Point3; - centerNormal?: Inputs.Base.Point3; - topPoint?: Inputs.Base.Point3; - shapes?: { - wire1?: T; - wire2?: T; - wire3?: T; - wire4?: T; - face1?: T; - face2?: T; - face3?: T; - face4?: T; - compound?: T; - }; - } - declare class PyramidSimpleData { - /** - * Type of the object being configured - */ - type: string; - /** - * Default name of the object - */ - name: string; - /** - * Original inputs - */ - originalInputs?: PyramidSimpleDto | PyramidSimpleAffectorsDto; - /** - * Compounded shape of the pyramids - */ - compound?: T; - /** - * All the shapes of the pyramid - */ - shapes?: Models.OCCT.ShapeWithId[]; - /** - * Data that contains information and shapes about each face on which pyramids were computed - */ - faceParts?: PyramidSimpleFacePart[]; - /** - * All the pyramid top coordinates - */ - topCoordinates: Inputs.Base.Point3[]; - } - declare class PyramidSimpleDto { - constructor( - faces?: T[], - uNumber?: number, - vNumber?: number, - height?: number - ); - /** - * The faces on which to apply the pattern - * @default undefined - */ - faces: T[]; - /** - * The nr of pyramids along u direction of the face - * @default 10 - * @minimum 1 - * @maximum Infinity - * @step 1 - */ - uNumber: number; - /** - * The nr of pyramids along v direction of the face - * @default 10 - * @minimum 1 - * @maximum Infinity - * @step 1 - */ - vNumber: number; - /** - * The height of the pyramid - * @default 0.2 - * @minimum -Infinity - * @maximum Infinity - * @step 0.1 - */ - height: number; - /** - * Meshing precision of the drawn model. The lower the number the more precise the drawn model is. Keep in mind that output of this algorithm also contains pure occt shape that can be meshed separately in draw any async commands - * @default 0.01 - * @minimum 0.000001 - * @maximum 5 - * @step 0.001 - */ - precision: number; - } - declare class PyramidSimpleFacePart { - id: string; - /** - * Data that contains information and shapes of the top part of the table - */ - cells?: PyramidSimpleCellPart[]; - shapes?: { - compound?: T; - startPolylineWireU?: T; - startPolylineWireV?: T; - endPolylineWireU?: T; - endPolylineWireV?: T; - compoundPolylineWiresU?: T; - compoundPolylineWiresV?: T; - compoundPolylineWiresUV?: T; - }; - } - declare class PyramidSimpleModelCellDto { - /** - * The part that represents the cell of the pyramid - * @default undefined - */ - cells: PyramidSimpleCellPart; - } - declare class PyramidSimpleModelCellsDto { - /** - * The part that represents the cells of the pyramid - * @default undefined - */ - cells: PyramidSimpleCellPart[]; - } - declare class PyramidSimpleModelCellsIndexDto { - /** - * The part that represents the cells of the pyramid - * @default undefined - */ - cells: PyramidSimpleCellPart[]; - /** - * The index that can represent a corner, face or a wire in the pyramid - * @default 0 - * @minimum 0 - * @maximum 3 - * @step 1 - */ - index: number; - } - declare class PyramidSimpleModelDto { - /** - * The model that represents result of the pyramid create operation - * @default undefined - */ - model: PyramidSimpleData; - } - declare class PyramidSimpleModelFaceCellIndexDto { - /** - * The model that represents result of the pyramid create operation - * @default undefined - */ - model: PyramidSimpleData; - /** - * Face index for the pyramid queries - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - faceIndex: number; - /** - * Cell u index for the pyramid - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - uIndex: number; - /** - * Cell v index for the pyramid - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - vIndex: number; - } - declare class PyramidSimpleModelFaceCellsUIndexDto { - /** - * The model that represents result of the pyramid create operation - * @default undefined - */ - model: PyramidSimpleData; - /** - * Face index for the pyramid queries - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - faceIndex: number; - /** - * U index of the pyramid cells - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - uIndex: number; - } - declare class PyramidSimpleModelFaceCellsVIndexDto { - /** - * The model that represents result of the pyramid create operation - * @default undefined - */ - model: PyramidSimpleData; - /** - * Face index for the pyramid queries - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - faceIndex: number; - /** - * V index of the pyramid cells - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - vIndex: number; - } - declare class PyramidSimpleModelFaceIndexDto { - /** - * The model that represents result of the pyramid create operation - * @default undefined - */ - model: PyramidSimpleData; - /** - * Face index for the pyramid queries - * @default 0 - * @minimum 0 - * @maximum Infinity - * @step 1 - */ - faceIndex: number; - } - } - } - } - declare namespace Navigation { - declare class FocusFromAngleDto { - constructor( - meshes?: BABYLON.Mesh[], - includeChildren?: boolean, - orientation?: number[], - distance?: number, - padding?: number, - animationSpeed?: number - ); - /** - * List of meshes to focus on - * @default [] - */ - meshes: BABYLON.Mesh[]; - /** - * Whether to include children when computing bounding boxes - * @default true - */ - includeChildren: boolean; - /** - * Orientation vector indicating the direction from which to view the object - * The camera will be positioned in this direction from the center of the bounding box - * @default [1, 1, 1] - */ - orientation: number[]; - /** - * Distance from the center of the bounding box to position the camera - * If not specified, distance will be automatically calculated based on object size - * @default undefined - * @minimum 0.01 - * @maximum Infinity - * @step 0.1 - * @optional true - */ - distance?: number; - /** - * Padding multiplier to control spacing around objects when distance is auto-calculated - * Higher values = more space around object (camera further away) - * Lower values = tighter framing (camera closer) - * Only applies when distance is not manually specified - * @default 1.5 - * @minimum 0.1 - * @maximum Infinity - * @step 0.1 - */ - padding: number; - /** - * Speed of camera animation in seconds - * @default 1.0 - * @minimum 0.01 - * @maximum Infinity - * @step 0.01 - */ - animationSpeed: number; - } - declare class PointOfInterestDto { - constructor( - name?: string, - position?: Inputs.Base.Point3, - cameraTarget?: Inputs.Base.Point3, - cameraPosition?: Inputs.Base.Point3, - style?: PointOfInterestStyleDto - ); - /** Point of Interest name - * @default Point of Interest - */ - name: string; - /** - * Camera look at point - * @default [0, 1, 0] - */ - position: Inputs.Base.Point3; - /** - * Camera look at point - * @default [0, 0, 0] - */ - cameraTarget: Inputs.Base.Point3; - /** - * Camera position - * @default [10, 10, 10] - */ - cameraPosition: Inputs.Base.Point3; - /** - * Point of Interest style - * @default undefined - * @optional true - */ - style?: PointOfInterestStyleDto; - } - declare class PointOfInterestEntity extends PointOfInterestDto { - type: string; - entityName: string; - } - declare class PointOfInterestStyleDto { - constructor( - pointSize?: number, - pointColor?: string, - hoverPointColor?: string, - pulseColor?: string, - pulseMinSize?: number, - pulseMaxSize?: number, - pulseThickness?: number, - pulseSpeed?: number, - textColor?: string, - hoverTextColor?: string, - textSize?: number, - textFontWeight?: number, - textBackgroundColor?: string, - textBackgroundOpacity?: number, - textBackgroundStroke?: boolean, - textBackgroundStrokeThickness?: number, - textBackgroundRadius?: number, - textPosition?: Inputs.Base.topBottomEnum, - stableSize?: boolean, - alwaysOnTop?: boolean - ); - /** - * Diameter of the central point in pixels - * @default 20 - */ - pointSize?: number; - /** Color of the central point - * @default #ffffff - */ - pointColor?: Inputs.Base.Color; - /** Color of the central point on hover - * @default #0000ff - */ - hoverPointColor?: Inputs.Base.Color; - /** Color of the animated pulse - * @default #ffffff - */ - pulseColor?: Inputs.Base.Color; - /** Hover color of the animated pulse - * @default #0000ff - */ - hoverPulseColor?: Inputs.Base.Color; - /** Smallest diameter of the pulse in pixels - * @default 20 - */ - pulseMinSize?: number; - /** Largest diameter of the pulse in pixels - * @default 50 - */ - pulseMaxSize?: number; - /** Thickness of the pulse ring in pixels - * @default 2 - */ - pulseThickness?: number; - /** Speed multiplier for the pulse animation - * @default 3 - */ - pulseSpeed?: number; - /** Color of the text label - * @default #ffffff - */ - textColor?: Inputs.Base.Color; - /** Color of the text label on hover - * @default #0000ff - */ - hoverTextColor?: Inputs.Base.Color; - /** Font size of the text label in pixels - * @default 14 - */ - textSize?: number; - /** Font weight of the text label - * @default 400 - * @minimum 100 - * @maximum 900 - * @step 100 - */ - textFontWeight?: number; - /** Background color of text label - * @default #000000 - */ - textBackgroundColor?: Inputs.Base.Color; - /** Opacity of text background - * @default 0.0 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - textBackgroundOpacity: number; - /** Whether to show stroke around text background - * @default false - */ - textBackgroundStroke: boolean; - /** Thickness of the stroke around text background - * @default 8 - * @minimum 1 - * @maximum 20 - * @step 1 - */ - textBackgroundStrokeThickness: number; - /** Corner radius for text background rounding - * @default 40 - * @minimum 0 - * @maximum 100 - * @step 5 - */ - textBackgroundRadius: number; - /** Position of the text label relative to the point in screen space (top or bottom) - * @default bottom - */ - textPosition: Inputs.Base.topBottomEnum; - /** Whether the entire point of interest should maintain stable size regardless of camera distance - * @default true - */ - stableSize: boolean; - /** Whether the point of interest should always render on top of other objects - * @default false - */ - alwaysOnTop: boolean; - } - declare class ZoomOnDto { - constructor( - meshes?: BABYLON.Mesh[], - includeChildren?: boolean, - animationSpeed?: number, - offset?: number, - doNotUpdateMaxZ?: boolean - ); - /** - * List of meshes to zoom on - * @default [] - */ - meshes: BABYLON.Mesh[]; - /** - * Whether to include children when analyzing bounding boxes - * @default true - */ - includeChildren: boolean; - /** - * Speed of camera animation in seconds - * @default 0.8 - * @minimum 0.01 - * @maximum Infinity - * @step 0.01 - */ - animationSpeed: number; - /** - * Offset multiplier to control spacing around objects - * Negative values = tighter framing (closer to object) - * 0 = default BabylonJS framing (has built-in padding) - * Positive values = more space around object - * @default 0 - * @minimum -0.9 - * @maximum Infinity - * @step 0.1 - */ - offset: number; - /** - * Whether to prevent updating camera's maxZ (far clipping plane) during zoom - * @default true - */ - doNotUpdateMaxZ: boolean; - } - } - declare namespace Dimensions { - declare class AngularDimensionDto { - constructor( - centerPoint?: Inputs.Base.Point3, - direction1?: Inputs.Base.Vector3, - direction2?: Inputs.Base.Vector3, - radius?: number, - labelOffset?: number, - decimalPlaces?: number, - labelSuffix?: string, - labelOverwrite?: string, - radians?: boolean, - removeTrailingZeros?: boolean, - style?: DimensionStyleDto - ); - /** - * Center point of the angle - * @default [0, 0, 0] - */ - centerPoint: Inputs.Base.Point3; - /** - * First direction vector - * @default [1, 0, 0] - */ - direction1: Inputs.Base.Vector3; - /** - * Second direction vector - * @default [0, 1, 0] - */ - direction2: Inputs.Base.Vector3; - /** - * Radius of the dimension arc - * @default 1 - * @minimum 0.1 - * @maximum Infinity - * @step 0.1 - */ - radius: number; - /** - * Label offset from arc - * @default 0.1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - labelOffset: number; - /** - * Decimal places for angle display - * @default 1 - * @minimum 0 - * @maximum 10 - * @step 1 - */ - decimalPlaces: number; - /** - * Suffix to add to the angle label - * @default ° - */ - labelSuffix: string; - /** - * Override label text with custom expression (supports 'val' for computed value, e.g., '100*val', 'Angle: val°') - * @default 1*val - */ - labelOverwrite: string; - /** - * Whether to display angle in radians - * @default false - */ - radians: boolean; - /** - * Remove trailing zeros from decimal places - * @default false - */ - removeTrailingZeros: boolean; - /** - * Dimension style - * @default undefined - * @optional true - */ - style?: DimensionStyleDto; - } - declare class AngularDimensionEntity extends AngularDimensionDto { - type: string; - entityName: string; - /** Identifier for this dimension entity - * @ignore true - */ - id?: string; - } - declare class DiametralDimensionDto { - constructor( - centerPoint?: Inputs.Base.Point3, - direction?: Inputs.Base.Vector3, - diameter?: number, - labelOffset?: number, - decimalPlaces?: number, - labelSuffix?: string, - labelOverwrite?: string, - showCenterMark?: boolean, - removeTrailingZeros?: boolean, - style?: DimensionStyleDto - ); - /** - * Center point of the circle/arc - * @default [0, 0, 0] - */ - centerPoint: Inputs.Base.Point3; - /** - * Direction vector for diameter line - * @default [1, 0, 0] - */ - direction: Inputs.Base.Vector3; - /** - * Diameter value - * @default 2 - * @minimum 0.01 - * @maximum Infinity - * @step 0.1 - */ - diameter: number; - /** - * Label offset from diameter line - * @default 0.1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - labelOffset: number; - /** - * Decimal places for measurement display - * @default 2 - * @minimum 0 - * @maximum 10 - * @step 1 - */ - decimalPlaces: number; - /** - * Label suffix text - * @default mm - */ - labelSuffix: string; - /** - * Override label text with custom expression (supports 'val' for computed value, e.g., '100*val', '⌀ val mm') - * @default 1*val - */ - labelOverwrite: string; - /** - * Whether to show center mark at center point - * @default true - */ - showCenterMark: boolean; - /** - * Remove trailing zeros from decimal places - * @default false - */ - removeTrailingZeros: boolean; - /** - * Dimension style - * @default undefined - * @optional true - */ - style?: DimensionStyleDto; - } - declare class DiametralDimensionEntity extends DiametralDimensionDto { - type: string; - entityName: string; - /** Identifier for this dimension entity - * @ignore true - */ - id?: string; - } - declare class DimensionStyleDto { - constructor( - lineColor?: string, - lineThickness?: number, - extensionLineLength?: number, - arrowTailLength?: number, - textColor?: string, - textSize?: number, - textFontWeight?: number, - textBackgroundColor?: string, - textBackgroundOpacity?: number, - textBackgroundStroke?: boolean, - textBackgroundStrokeThickness?: number, - textBackgroundRadius?: number, - textStableSize?: boolean, - arrowSize?: number, - arrowColor?: string, - showArrows?: boolean, - textBillboard?: boolean, - occlusionCheckInterval?: number, - alwaysOnTop?: boolean - ); - /** - * Color of dimension lines - * @default #ffffff - */ - lineColor: Inputs.Base.Color; - /** - * Thickness of dimension lines - * @default 0.01 - * @minimum 0.01 - * @maximum 0.5 - * @step 0.01 - */ - lineThickness: number; - /** - * Length of extension lines beyond dimension line - * @default 0.2 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - extensionLineLength: number; - /** - * Length of arrow tail extensions beyond arrow tips - * @default 0.2 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - arrowTailLength: number; - /** - * Color of dimension text - * @default #ffffff - */ - textColor: Inputs.Base.Color; - /** - * Size of dimension text - * @default 16 - * @minimum 0 - * @maximum Infinity - * @step 2 - */ - textSize: number; - /** - * Font weight of dimension text - * @default 400 - * @minimum 100 - * @maximum 900 - * @step 100 - */ - textFontWeight: number; - /** - * Background color of text (if needed) - * @default #000000 - */ - textBackgroundColor: Inputs.Base.Color; - /** - * Opacity of text background - * @default 0.0 - * @minimum 0 - * @maximum 1 - * @step 0.1 - */ - textBackgroundOpacity: number; - /** - * Whether to show stroke around text background - * @default false - */ - textBackgroundStroke: boolean; - /** - * Thickness of the stroke around text background - * @default 8 - * @minimum 1 - * @maximum 20 - * @step 1 - */ - textBackgroundStrokeThickness: number; - /** - * Corner radius for text background rounding - * @default 40 - * @minimum 0 - * @maximum 100 - * @step 5 - */ - textBackgroundRadius: number; - /** - * Whether text should maintain stable size regardless of camera distance - * @default false - */ - textStableSize: boolean; - /** - * Size of arrow heads - * @default 0.05 - * @minimum 0 - * @maximum Infinity - * @step 0.01 - */ - arrowSize: number; - /** - * Color of arrow heads - * @default #ffffff - */ - arrowColor: Inputs.Base.Color; - /** - * Whether to show arrow heads/cones - * @default true - */ - showArrows: boolean; - /** - * Whether text should billboard (always face camera) - * @default true - */ - textBillboard: boolean; - /** - * How often to check for occlusion in milliseconds (only for GUI modes) - * @default 100 - * @minimum 50 - * @maximum 1000 - * @step 50 - */ - occlusionCheckInterval: number; - /** - * Whether dimensions should always render on top of other objects - * @default false - */ - alwaysOnTop: boolean; - } - declare class LinearDimensionDto { - constructor( - startPoint?: Inputs.Base.Point3, - endPoint?: Inputs.Base.Point3, - direction?: Inputs.Base.Vector3, - labelOffset?: number, - decimalPlaces?: number, - labelSuffix?: string, - labelOverwrite?: string, - removeTrailingZeros?: boolean, - style?: DimensionStyleDto - ); - /** - * Start point of the dimension - * @default [0, 0, 0] - */ - startPoint: Inputs.Base.Point3; - /** - * End point of the dimension - * @default [1, 0, 0] - */ - endPoint: Inputs.Base.Point3; - /** - * Direction vector for dimension line offset - * @default [0, 1, 0] - */ - direction: Inputs.Base.Vector3; - /** - * Label offset from dimension line - * @default 0.1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - labelOffset: number; - /** - * Decimal places for measurement display - * @default 2 - * @minimum 0 - * @maximum 10 - * @step 1 - */ - decimalPlaces: number; - /** - * Label suffix text - * @default mm - */ - labelSuffix: string; - /** - * Override label text with custom expression (supports 'val' for computed value, e.g., '100*val', 'Length: val mm') - * @default 1*val - */ - labelOverwrite: string; - /** - * Remove trailing zeros from decimal places - * @default false - */ - removeTrailingZeros: boolean; - /** - * Dimension style - * @default undefined - * @optional true - */ - style?: DimensionStyleDto; - } - declare class LinearDimensionEntity extends LinearDimensionDto { - type: string; - entityName: string; - /** Identifier for this dimension entity - * @ignore true - */ - id?: string; - } - declare enum ordinateAxisEnum { - x = "x", - y = "y", - z = "z", - } - declare class OrdinateDimensionDto { - constructor( - measurementPoint?: Inputs.Base.Point3, - referencePoint?: Inputs.Base.Point3, - axis?: ordinateAxisEnum, - labelOffset?: number, - decimalPlaces?: number, - labelSuffix?: string, - labelOverwrite?: string, - showLeaderLine?: boolean, - removeTrailingZeros?: boolean, - style?: DimensionStyleDto - ); - /** - * Point to measure coordinate from - * @default [1, 1, 1] - */ - measurementPoint: Inputs.Base.Point3; - /** - * Reference origin point for coordinate system - * @default [0, 0, 0] - */ - referencePoint: Inputs.Base.Point3; - /** - * Which axis coordinate to display (X, Y, or Z) - * @default x - */ - axis: ordinateAxisEnum; - /** - * Label offset from measurement point - * @default 0.5 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - labelOffset: number; - /** - * Decimal places for measurement display - * @default 2 - * @minimum 0 - * @maximum 10 - * @step 1 - */ - decimalPlaces: number; - /** - * Label suffix text - * @default mm - */ - labelSuffix: string; - /** - * Override label text with custom expression (supports 'val' for computed value, e.g., '100*val', 'X: val mm') - * @default 1*val - */ - labelOverwrite: string; - /** - * Whether to show leader line from measurement point to label - * @default true - */ - showLeaderLine: boolean; - /** - * Remove trailing zeros from decimal places - * @default false - */ - removeTrailingZeros: boolean; - /** - * Dimension style - * @default undefined - * @optional true - */ - style?: DimensionStyleDto; - } - declare class OrdinateDimensionEntity extends OrdinateDimensionDto { - type: string; - entityName: string; - /** Identifier for this dimension entity - * @ignore true - */ - id?: string; - } - declare class RadialDimensionDto { - constructor( - centerPoint?: Inputs.Base.Point3, - radiusPoint?: Inputs.Base.Point3, - labelOffset?: number, - decimalPlaces?: number, - labelSuffix?: string, - labelOverwrite?: string, - showDiameter?: boolean, - showCenterMark?: boolean, - removeTrailingZeros?: boolean, - style?: DimensionStyleDto - ); - /** - * Center point of the circle/arc - * @default [0, 0, 0] - */ - centerPoint: Inputs.Base.Point3; - /** - * Point on the radius/perimeter of the circle/arc - * @default [1, 0, 0] - */ - radiusPoint: Inputs.Base.Point3; - /** - * Label offset from radius line - * @default 0.1 - * @minimum 0 - * @maximum Infinity - * @step 0.1 - */ - labelOffset: number; - /** - * Decimal places for measurement display - * @default 2 - * @minimum 0 - * @maximum 10 - * @step 1 - */ - decimalPlaces: number; - /** - * Label suffix text - * @default mm - */ - labelSuffix: string; - /** - * Override label text with custom expression (supports 'val' for computed value, e.g., '100*val', 'R val mm') - * @default 1*val - */ - labelOverwrite: string; - /** - * Whether to show diameter instead of radius - * @default false - */ - showDiameter: boolean; - /** - * Whether to show center mark at center point - * @default true - */ - showCenterMark: boolean; - /** - * Remove trailing zeros from decimal places - * @default false - */ - removeTrailingZeros: boolean; - /** - * Dimension style - * @default undefined - * @optional true - */ - style?: DimensionStyleDto; - } - declare class RadialDimensionEntity extends RadialDimensionDto { - type: string; - entityName: string; - /** Identifier for this dimension entity - * @ignore true - */ - id?: string; - } - } - } - - /** - * This should be used only if you want to use only JSCAD worker without other of the bitbybit packages - */ - declare class BitByBitJSCAD { - jscadWorkerManager: JSCADWorkerManager; - jscad: JSCAD; - constructor(); - init(jscad: Worker): void; - } - /** - * Contains various functions for Solid booleans from JSCAD library https://github.com/jscad/OpenJSCAD.org - * Thanks JSCAD community for developing this kernel - */ - declare class JSCADBooleans { - private readonly jscadWorkerManager; - constructor(jscadWorkerManager: JSCADWorkerManager); - /** - * Intersect multiple solid mesh objects - * @param inputs Contains multiple solids for intersection - * @returns Solid mesh - * @group boolean - * @shortname intersect - * @drawable true - */ - intersect( - inputs: Inputs.JSCAD.BooleanObjectsDto - ): Promise; - /** - * Subtract multiple solid mesh objects - * @param inputs Contains multiple solids for subtraction - * @returns Solid mesh - * @group boolean - * @shortname subtract - * @drawable true - */ - subtract( - inputs: Inputs.JSCAD.BooleanObjectsDto - ): Promise; - /** - * Union multiple solid mesh objects - * @param inputs Contains multiple solids for union - * @returns Solid mesh - * @group boolean - * @shortname union - * @drawable true - */ - union( - inputs: Inputs.JSCAD.BooleanObjectsDto - ): Promise; - /** - * Intersect two solid mesh objects - * @param inputs Contains multiple solids for intersection - * @returns Solid mesh - * @group boolean - * @shortname intersect two - * @drawable true - */ - intersectTwo( - inputs: Inputs.JSCAD.BooleanTwoObjectsDto - ): Promise; - /** - * Subtract two solid mesh objects - * @param inputs Contains multiple solids for subtraction - * @returns Solid mesh - * @group boolean - * @shortname subtract two - * @drawable true - */ - subtractTwo( - inputs: Inputs.JSCAD.BooleanTwoObjectsDto - ): Promise; - /** - * Union two solid mesh objects - * @param inputs Contains multiple solids for union - * @returns Solid mesh - * @group boolean - * @shortname union two - * @drawable true - */ - unionTwo( - inputs: Inputs.JSCAD.BooleanTwoObjectsDto - ): Promise; - /** - * Subtract multiple meshes from one mesh object - * @param inputs Contains mesh from which to subtract and multiple meshes for subtraction - * @returns mesh - * @group boolean - * @shortname subtract from - * @drawable true - */ - subtractFrom( - inputs: Inputs.JSCAD.BooleanObjectsFromDto - ): Promise; - } - /** - * Contains functions for colorizing objects - */ - declare class JSCADColors { - private readonly jscadWorkerManager; - constructor(jscadWorkerManager: JSCADWorkerManager); - /** - * Colorizes geometry of jscad. If geometry is in the array it will colorize all items and return them. If geometry is a single item it will return a single item. - * Keep in mind that colorized geometry in jscad will always be drawn in that color even if you try to change it via draw options. - * @param inputs contain geometry and hex color - * @returns Colorized geometry of jsacd - * @group colorize - * @shortname colorize geometry - * @drawable true - */ - colorize( - inputs: Inputs.JSCAD.ColorizeDto - ): Promise; - } - /** - * Contains various functions for Solid expansions from JSCAD library https://github.com/jscad/OpenJSCAD.org - * Thanks JSCAD community for developing this kernel - */ - declare class JSCADExpansions { - private readonly jscadWorkerManager; - constructor(jscadWorkerManager: JSCADWorkerManager); - /** - * Expand geometries of solid category - * @param inputs Contains options and geometries for expansion - * @returns Expanded geometry - * @group expansion - * @shortname expand - * @drawable true - */ - expand( - inputs: Inputs.JSCAD.ExpansionDto - ): Promise; - /** - * Offset 2d geometries of solid category - * @param inputs Contains options and geometries for offset - * @returns Expanded geometry - * @group expansion - * @shortname offset - * @drawable true - */ - offset( - inputs: Inputs.JSCAD.ExpansionDto - ): Promise; - } - /** - * Contains various functions for Solid extrusions from JSCAD library https://github.com/jscad/OpenJSCAD.org - * Thanks JSCAD community for developing this kernel - */ - declare class JSCADExtrusions { - private readonly jscadWorkerManager; - constructor(jscadWorkerManager: JSCADWorkerManager); - /** - * Linear extrude 2D geometries of solid category - * @param inputs Contains options and geometries for linear extrude - * @returns Extruded geometry - * @group extrude - * @shortname linear - * @drawable true - */ - extrudeLinear( - inputs: Inputs.JSCAD.ExtrudeLinearDto - ): Promise; - /** - * Rectangular extrude 2D geometries of solid category. Creates a wall-type extrusion of certain height and size. - * @param inputs Contains options and geometries for rectangular extrude - * @returns Extruded geometry - * @group extrude - * @shortname rectangular - * @drawable true - */ - extrudeRectangular( - inputs: Inputs.JSCAD.ExtrudeRectangularDto - ): Promise; - /** - * Rectangular extrude a list of 2D points. Creates a wall-type extrusion of certain height and size. - * @param inputs Contains options and points for extrusion - * @returns Extruded geometry - * @group extrude - * @shortname rectangular points - * @drawable true - */ - extrudeRectangularPoints( - inputs: Inputs.JSCAD.ExtrudeRectangularPointsDto - ): Promise; - /** - * Rectangular extrude a list of 2D points. Creates a wall-type extrusion of certain height and size. - * @param inputs Contains options and points for extrusion - * @returns Extruded geometry - * @group extrude - * @shortname rotational - * @drawable true - */ - extrudeRotate( - inputs: Inputs.JSCAD.ExtrudeRotateDto - ): Promise; - } - /** - * Contains various functions for Solid hulls from JSCAD library https://github.com/jscad/OpenJSCAD.org - * Thanks JSCAD community for developing this kernel - */ - declare class JSCADHulls { - private readonly jscadWorkerManager; - constructor(jscadWorkerManager: JSCADWorkerManager); - /** - * Hull chain connects solids or 2d geometries by filling an empty space in between objects in order. - * Geometries need to be of the same type. - * @param inputs Geometries - * @returns Chain hulled geometry - * @group hulls - * @shortname hull chain - * @drawable true - */ - hullChain(inputs: Inputs.JSCAD.HullDto): Promise; - /** - * Convex hull connects solids or 2d geometries by filling an empty space in between without following order. - * Geometries need to be of the same type. - * @param inputs Geometries - * @returns Hulled geometry - * @group hulls - * @shortname hull - * @drawable true - */ - hull(inputs: Inputs.JSCAD.HullDto): Promise; - } - /** - * Contains various functions for Solid meshes from JSCAD library https://github.com/jscad/OpenJSCAD.org - * Thanks JSCAD community for developing this kernel - */ - declare class JSCAD { - private readonly jscadWorkerManager; - readonly booleans: JSCADBooleans; - readonly expansions: JSCADExpansions; - readonly extrusions: JSCADExtrusions; - readonly hulls: JSCADHulls; - readonly path: JSCADPath; - readonly polygon: JSCADPolygon; - readonly shapes: JSCADShapes; - readonly text: JSCADText; - readonly colors: JSCADColors; - constructor(jscadWorkerManager: JSCADWorkerManager); - /** - * Converts the Jscad mesh to polygon points representing triangles of the mesh. - * @param inputs Jscad mesh - * @returns polygon points - * @group conversions - * @shortname to polygon points - * @drawable false - */ - toPolygonPoints(inputs: Inputs.JSCAD.MeshDto): Promise; - /** - * Transforms the Jscad solid meshes with a given list of transformations. - * @param inputs Solids with the transformation matrixes - * @returns Solids with a transformation - * @group transforms - * @shortname transform solids - * @drawable true - */ - transformSolids( - inputs: Inputs.JSCAD.TransformSolidsDto - ): Promise; - /** - * Transforms the Jscad solid mesh with a given list of transformations. - * @param inputs Solid with the transformation matrixes - * @returns Solid with a transformation - * @group transforms - * @shortname transform solid - * @drawable true - */ - transformSolid( - inputs: Inputs.JSCAD.TransformSolidDto - ): Promise; - /** - * Downloads the binary STL file from a 3D solid - * @param inputs 3D Solid - * @group io - * @shortname solid to stl - */ - downloadSolidSTL(inputs: Inputs.JSCAD.DownloadSolidDto): Promise; - /** - * Downloads the binary STL file from a 3D solids - * @param inputs 3D Solid - * @group io - * @shortname solids to stl - */ - downloadSolidsSTL(inputs: Inputs.JSCAD.DownloadSolidsDto): Promise; - /** - * Downloads the dxf file from jscad geometry. Supports paths and meshes in array. - * @param inputs 3D geometry - * @group io - * @shortname geometry to dxf - */ - downloadGeometryDxf( - inputs: Inputs.JSCAD.DownloadGeometryDto - ): Promise; - /** - * Downloads the 3MF file from jscad geometry. - * @param inputs 3D geometry - * @group io - * @shortname geometry to 3mf - */ - downloadGeometry3MF( - inputs: Inputs.JSCAD.DownloadGeometryDto - ): Promise; - private downloadFile; - } - /** - * Contains various functions for Path from JSCAD library https://github.com/jscad/OpenJSCAD.org - * Thanks JSCAD community for developing this kernel - */ - declare class JSCADPath { - private readonly jscadWorkerManager; - constructor(jscadWorkerManager: JSCADWorkerManager); - /** - * Create a 2D path from a list of points - * @param inputs Points and indication if we want a closed path or not - * @returns Path - * @group from - * @shortname points - * @drawable true - */ - createFromPoints( - inputs: Inputs.JSCAD.PathFromPointsDto - ): Promise; - /** - * Create 2D paths from a lists of points - * @param inputs Points lists - * @returns Paths - * @group from - * @shortname paths from points - * @drawable true - */ - createPathsFromPoints( - inputs: Inputs.JSCAD.PathsFromPointsDto - ): Promise; - /** - * Create a 2D path from a polyline - * @param inputs Polyline and indication if we want a closed path or not - * @returns Path - * @group from - * @shortname polyline - * @drawable true - */ - createFromPolyline( - inputs: Inputs.JSCAD.PathFromPolylineDto - ): Promise; - /** - * Create empty 2D path - * @returns Empty path - * @group create - * @shortname empty - * @drawable false - */ - createEmpty(): Promise; - /** - * Closes an open 2D path - * @param inputs Path - * @returns Closed path - * @group edit - * @shortname close - * @drawable true - */ - close(inputs: Inputs.JSCAD.PathDto): Promise; - /** - * Append the path with 2D points - * @param inputs Path to append and points - * @returns Appended path - * @group append - * @shortname points - * @drawable true - */ - appendPoints( - inputs: Inputs.JSCAD.PathAppendPointsDto - ): Promise; - /** - * Append the path with polyline - * @param inputs Path to append and polyline - * @returns Appended path - * @group append - * @shortname polyline - * @drawable true - */ - appendPolyline( - inputs: Inputs.JSCAD.PathAppendPolylineDto - ): Promise; - /** - * Append the arc to the path - * @param inputs Path and arc parameters - * @returns Appended path - * @group append - * @shortname arc - * @drawable true - */ - appendArc( - inputs: Inputs.JSCAD.PathAppendArcDto - ): Promise; - } - /** - * Contains various functions for Polygon from JSCAD library https://github.com/jscad/OpenJSCAD.org - * Thanks JSCAD community for developing this kernel - */ - declare class JSCADPolygon { - private readonly jscadWorkerManager; - constructor(jscadWorkerManager: JSCADWorkerManager); - /** - * Create a 2D polygon from a list of points - * @param inputs Points - * @returns Polygons - * @group from - * @shortname polygon from points - * @drawable true - */ - createFromPoints( - inputs: Inputs.JSCAD.PointsDto - ): Promise; - /** - * Create a 2D polygon from a polyline - * @param inputs Polyline - * @returns Polygon - * @group from - * @shortname polyline - * @drawable true - */ - createFromPolyline( - inputs: Inputs.JSCAD.PolylineDto - ): Promise; - /** - * Create a 2D polygon from a curve - * @param inputs Nurbs curve - * @returns Polygon - * @group from - * @shortname curve - * @drawable true - */ - createFromCurve( - inputs: Inputs.JSCAD.CurveDto - ): Promise; - /** - * Create a 2D polygon from a path - * @param inputs Path - * @returns Polygon - * @group from - * @shortname path - * @drawable true - */ - createFromPath( - inputs: Inputs.JSCAD.PathDto - ): Promise; - /** - * Create a 2D polygon circle - * @param inputs Circle parameters - * @returns Circle polygon - * @group primitives - * @shortname circle - * @drawable true - */ - circle(inputs: Inputs.JSCAD.CircleDto): Promise; - /** - * Create a 2D polygon ellipse - * @param inputs Ellipse parameters - * @returns Ellipse polygon - * @group primitives - * @shortname ellipse - * @drawable true - */ - ellipse(inputs: Inputs.JSCAD.EllipseDto): Promise; - /** - * Create a 2D polygon rectangle - * @param inputs Rectangle parameters - * @returns Rectangle polygon - * @group primitives - * @shortname rectangle - * @drawable true - */ - rectangle( - inputs: Inputs.JSCAD.RectangleDto - ): Promise; - /** - * Create a 2D rounded rectangle - * @param inputs Rounded rectangle parameters - * @returns Rounded rectangle polygon - * @group primitives - * @shortname rounded rectangle - * @drawable true - */ - roundedRectangle( - inputs: Inputs.JSCAD.RoundedRectangleDto - ): Promise; - /** - * Create a 2D polygon square - * @param inputs Square parameters - * @returns Square polygon - * @group primitives - * @shortname square - * @drawable true - */ - square(inputs: Inputs.JSCAD.SquareDto): Promise; - /** - * Create a 2D polygon star - * @param inputs Star parameters - * @returns Star polygon - * @group primitives - * @shortname star - * @drawable true - */ - star(inputs: Inputs.JSCAD.StarDto): Promise; - } - /** - * Contains various functions for solid 3D shapes from JSCAD library https://github.com/jscad/OpenJSCAD.org - * Thanks JSCAD community for developing this kernel - */ - declare class JSCADShapes { - private readonly jscadWorkerManager; - constructor(jscadWorkerManager: JSCADWorkerManager); - /** - * Create a 3D cube shape - * @param inputs Cube parameters - * @returns Cube solid - * @group primitives - * @shortname cube - * @drawable true - */ - cube(inputs: Inputs.JSCAD.CubeDto): Promise; - /** - * Create a 3D cubes on multiple center points - * @param inputs Cube with multiple center points parameters - * @returns List of cube solids - * @group primitives on centers - * @shortname cubes - * @drawable true - */ - cubesOnCenterPoints( - inputs: Inputs.JSCAD.CubeCentersDto - ): Promise; - /** - * Create a 3D cuboid shape - * @param inputs Cuboid parameters - * @returns Cuboid solid - * @group primitives - * @shortname cuboid - * @drawable true - */ - cuboid(inputs: Inputs.JSCAD.CuboidDto): Promise; - /** - * Create a 3D cuboids on multiple center points - * @param inputs Cuboids with multiple center point parameters - * @returns List of cuboid solids - * @group primitives on centers - * @shortname cuboids - * @drawable true - */ - cuboidsOnCenterPoints( - inputs: Inputs.JSCAD.CuboidCentersDto - ): Promise; - /** - * Create a 3D elliptic cylinder solid - * @param inputs Elliptic cylinder parameters - * @returns Elliptic cylinder solid - * @group primitives - * @shortname cylinder elliptic - * @drawable true - */ - cylinderElliptic( - inputs: Inputs.JSCAD.CylidnerEllipticDto - ): Promise; - /** - * Create a 3D elliptic cylinders on multiple center points - * @param inputs Elliptic cylinders with multiple center point parameters - * @returns List of elliptic cylinders solids - * @group primitives on centers - * @shortname cylinder elliptic - * @drawable true - */ - cylinderEllipticOnCenterPoints( - inputs: Inputs.JSCAD.CylidnerCentersEllipticDto - ): Promise; - /** - * Create a 3D cylinder solid - * @param inputs Cylinder parameters - * @returns Cylinder solid - * @group primitives - * @shortname cylinder - * @drawable true - */ - cylinder( - inputs: Inputs.JSCAD.CylidnerDto - ): Promise; - /** - * Create a 3D cylinders on multiple center points - * @param inputs Cylinders with multiple center point parameters - * @returns List of cylinder solids - * @group primitives on centers - * @shortname cylinder - * @drawable true - */ - cylindersOnCenterPoints( - inputs: Inputs.JSCAD.CylidnerCentersDto - ): Promise; - /** - * Create a 3D ellipsoid solid - * @param inputs Ellipsoid parameters - * @returns Ellipsoid solid - * @group primitives - * @shortname ellipsoid - * @drawable true - */ - ellipsoid( - inputs: Inputs.JSCAD.EllipsoidDto - ): Promise; - /** - * Create a 3D ellipsoids on multiple center points - * @param inputs Ellipsoid parameters with multiple center points - * @returns List of ellipsoid solids - * @group primitives on centers - * @shortname ellipsoid - * @drawable true - */ - ellipsoidsOnCenterPoints( - inputs: Inputs.JSCAD.EllipsoidCentersDto - ): Promise; - /** - * Create a 3D geodesic sphere solid - * @param inputs Geodesic sphere parameters - * @returns Geodesic sphere solid - * @group primitives - * @shortname geodesic sphere - * @drawable true - */ - geodesicSphere( - inputs: Inputs.JSCAD.GeodesicSphereDto - ): Promise; - /** - * Create a 3D geodesic spheres on multiple center points - * @param inputs Geodesic sphere parameters with multiple center points - * @returns List of geodesic spheres - * @group primitives on centers - * @shortname geodesic sphere - * @drawable true - */ - geodesicSpheresOnCenterPoints( - inputs: Inputs.JSCAD.GeodesicSphereCentersDto - ): Promise; - /** - * Create a 3D rounded cuboid solid - * @param inputs Rounded cuboid parameters - * @returns Rounded cuboid solid - * @group primitives - * @shortname rounded cuboid - * @drawable true - */ - roundedCuboid( - inputs: Inputs.JSCAD.RoundedCuboidDto - ): Promise; - /** - * Create a 3D rounded cuboids on multiple center points - * @param inputs Rounded cuboids parameters with multiple center points - * @returns List of rounded cuboids - * @group primitives on centers - * @shortname rounded cuboid - * @drawable true - */ - roundedCuboidsOnCenterPoints( - inputs: Inputs.JSCAD.RoundedCuboidCentersDto - ): Promise; - /** - * Create a 3D rounded cylinder solid - * @param inputs Rounded cylinder parameters - * @returns Rounded cylinder solid - * @group primitives - * @shortname rounded cylinder - * @drawable true - */ - roundedCylinder( - inputs: Inputs.JSCAD.RoundedCylidnerDto - ): Promise; - /** - * Create a 3D rounded cylinders on multiple center points - * @param inputs Rounded cylinders parameters with multiple center points - * @returns List of rounded cylinders - * @group primitives on centers - * @shortname rounded cylinder - * @drawable true - */ - roundedCylindersOnCenterPoints( - inputs: Inputs.JSCAD.RoundedCylidnerCentersDto - ): Promise; - /** - * Create a 3D sphere solid - * @param inputs Sphere parameters - * @returns Sphere solid - * @group primitives - * @shortname sphere - * @drawable true - */ - sphere(inputs: Inputs.JSCAD.SphereDto): Promise; - /** - * Create a 3D sphere on multiple center points - * @param inputs Sphere parameters with multiple center points - * @returns List of spheres - * @group primitives on centers - * @shortname sphere - * @drawable true - */ - spheresOnCenterPoints( - inputs: Inputs.JSCAD.SphereCentersDto - ): Promise; - /** - * Create a 3D torus solid - * @param inputs Torus parameters - * @returns Torus solid - * @group primitives - * @shortname torus - * @drawable true - */ - torus(inputs: Inputs.JSCAD.TorusDto): Promise; - /** - * Create a 3D shape from poylgon points that have to be nested arrays of points - * @param inputs points - * @returns shape - * @group shapes - * @shortname from polygon points - * @drawable true - */ - fromPolygonPoints( - inputs: Inputs.JSCAD.FromPolygonPoints - ): Promise; - } - /** - * Contains various functions for solid 3D texts from JSCAD library https://github.com/jscad/OpenJSCAD.org - * Thanks JSCAD community for developing this kernel - */ - declare class JSCADText { - private readonly jscadWorkerManager; - constructor(jscadWorkerManager: JSCADWorkerManager); - /** - * Creates a text that is based on chain hulling cylinders - * @param inputs Cylindrical text parameters - * @returns List of solids for text - * @group text - * @shortname cylindrical - * @drawable true - */ - cylindricalText( - inputs: Inputs.JSCAD.CylinderTextDto - ): Promise; - /** - * Creates a text that is based on chain hulling spheres - * @param inputs Spherical text parameters - * @returns List of solids for text - * @group text - * @shortname spherical - * @drawable true - */ - sphericalText( - inputs: Inputs.JSCAD.SphereTextDto - ): Promise; - /** - * Creates a vector text - * @param inputs Vector text parameters - * @returns List of polygons - * @group text - * @shortname vector - * @drawable false - */ - createVectorText( - inputs: Inputs.JSCAD.TextDto - ): Promise; - } - /** - * This should be used only if you want to use only Manifold worker without other of the bitbybit packages - */ - declare class BitByBitManifold { - manifoldWorkerManager: ManifoldWorkerManager; - manifold: ManifoldBitByBit; - constructor(); - init(manifold: Worker): void; - } - /** - * Contains various functions for Solid meshes from Manifold library https://github.com/elalish/manifold - * Thanks Manifold community for developing this kernel - */ - declare class CrossSectionBooleans { - private readonly manifoldWorkerManager; - constructor(manifoldWorkerManager: ManifoldWorkerManager); - /** - * Subtract two cross sections - * @param inputs two cross sections - * @returns subtracted cross section - * @group a to b - * @shortname subtract - * @drawable true - */ - subtract( - inputs: Inputs.Manifold.TwoCrossSectionsDto - ): Promise; - /** - * Add two cross sections - * @param inputs two cross sections - * @returns unioned cross section - * @group a to b - * @shortname add - * @drawable true - */ - add( - inputs: Inputs.Manifold.TwoCrossSectionsDto - ): Promise; - /** - * Intersect two cross sections - * @param inputs two cross sections - * @returns intersected cross section - * @group a to b - * @shortname intersect - * @drawable true - */ - intersect( - inputs: Inputs.Manifold.TwoCrossSectionsDto - ): Promise; - /** - * Difference of two cross sections - * @param inputs two cross sections - * @returns difference of two cross sections - * @group 2 cross sections - * @shortname difference 2 cs - * @drawable true - */ - differenceTwo( - inputs: Inputs.Manifold.TwoCrossSectionsDto - ): Promise; - /** - * Union of two cross sections - * @param inputs two cross sections - * @returns union of two cross sections - * @group 2 cross sections - * @shortname union 2 cs - * @drawable true - */ - unionTwo( - inputs: Inputs.Manifold.TwoCrossSectionsDto - ): Promise; - /** - * Intersection of two cross sections - * @param inputs two shapes - * @returns intersection of two cross sections - * @group 2 cross sections - * @shortname intersect 2 cs - * @drawable true - */ - intersectionTwo( - inputs: Inputs.Manifold.TwoCrossSectionsDto - ): Promise; - /** - * Difference of multiple cross sections - * @param inputs multiple cross sections - * @returns difference of cross sections - * @group multiple - * @shortname diff cross sections - * @drawable true - */ - difference( - inputs: Inputs.Manifold.CrossSectionsDto - ): Promise; - /** - * Union of multiple cross sections - * @param inputs multiple cross sections - * @returns union of two cross sections - * @group multiple - * @shortname union cross sections - * @drawable true - */ - union( - inputs: Inputs.Manifold.CrossSectionsDto - ): Promise; - /** - * Intersection of multiple cross sections - * @param inputs two cross sections - * @returns intersection of multiple cross sections - * @group multiple - * @shortname intersection cross sections - * @drawable true - */ - intersection( - inputs: Inputs.Manifold.CrossSectionsDto - ): Promise; - } - /** - * Contains various functions for Solid meshes from Manifold library https://github.com/elalish/manifold - * Thanks Manifold community for developing this kernel - */ - declare class ManifoldCrossSection { - private readonly manifoldWorkerManager; - shapes: CrossSectionShapes; - operations: CrossSectionOperations; - booleans: CrossSectionBooleans; - transforms: CrossSectionTransforms; - evaluate: CrossSectionEvaluate; - constructor(manifoldWorkerManager: ManifoldWorkerManager); - /** - * Creates a cross section from a single polygon points - * @param inputs polygon points - * @returns cross section - * @group create - * @shortname cross section from points - * @drawable true - */ - crossSectionFromPoints( - inputs: Inputs.Manifold.CrossSectionFromPolygonPointsDto - ): Promise; - /** - * Creates a cross section from multiple polygons points - * @param inputs polygons points - * @returns cross section - * @group create - * @shortname cross section from polygons - * @drawable true - */ - crossSectionFromPolygons( - inputs: Inputs.Manifold.CrossSectionFromPolygonsPointsDto - ): Promise; - /** - * Turns cross section into polygons - * @param inputs cross section - * @returns polygons - * @group decompose - * @shortname cross section to polygons - * @drawable false - */ - crossSectionToPolygons( - inputs: Inputs.Manifold.CrossSectionDto - ): Promise; - /** - * Extracts points from a cross section - * @param inputs cross section - * @returns points - * @group decompose - * @shortname cross section to points - * @drawable false - */ - crossSectionToPoints( - inputs: Inputs.Manifold.CrossSectionDto - ): Promise; - /** - * Turns cross sections into polygons - * @param inputs cross sections - * @returns polygons - * @group decompose - * @shortname cross sections to polygons - * @drawable false - */ - crossSectionsToPolygons( - inputs: Inputs.Manifold.CrossSectionsDto - ): Promise; - /** - * Extracts points from cross sections - * @param inputs cross sections - * @returns points - * @group decompose - * @shortname cross sections to points - * @drawable false - */ - crossSectionsToPoints( - inputs: Inputs.Manifold.CrossSectionsDto - ): Promise; - } - /** - * Contains various functions for Solid meshes from Manifold library https://github.com/elalish/manifold - * Thanks Manifold community for developing this kernel - */ - declare class CrossSectionEvaluate { - private readonly manifoldWorkerManager; - constructor(manifoldWorkerManager: ManifoldWorkerManager); - /** - * Get area of cross section - * @param inputs cross section - * @returns area of cross section - * @group basic - * @shortname area - * @drawable false - */ - area( - inputs: Inputs.Manifold.CrossSectionDto - ): Promise; - /** - * Check if cross section is empty - * @param inputs cross section - * @returns boolean indicating emptyness - * @group basic - * @shortname is empty - * @drawable false - */ - isEmpty( - inputs: Inputs.Manifold.CrossSectionDto - ): Promise; - /** - * Get number of vertices in cross section - * @param inputs cross section - * @returns number of vertices of cross section - * @group basic - * @shortname num vert - * @drawable false - */ - numVert( - inputs: Inputs.Manifold.CrossSectionDto - ): Promise; - /** - * Get number of contours in cross section - * @param inputs cross section - * @returns number of contour of cross section - * @group basic - * @shortname num contour - * @drawable false - */ - numContour( - inputs: Inputs.Manifold.CrossSectionDto - ): Promise; - /** - * Get the bounds of the contour as a rectangle. Output is given in two vec2 points in the array. First array is the min point and second array is the max point. - * @param inputs cross section - * @returns bounds of cross section - * @group basic - * @shortname bounds - * @drawable false - */ - bounds( - inputs: Inputs.Manifold.CrossSectionDto - ): Promise; - } - /** - * Contains various functions for Solid meshes from Manifold library https://github.com/elalish/manifold - * Thanks Manifold community for developing this kernel - */ - declare class CrossSectionOperations { - private readonly manifoldWorkerManager; - constructor(manifoldWorkerManager: ManifoldWorkerManager); - /** - * Compute convex hull for the cross section - * @param inputs cross section - * @returns hulled cross section - * @group basic - * @shortname hull - * @drawable true - */ - hull( - inputs: Inputs.Manifold.CrossSectionDto - ): Promise; - /** - * Extrude the cross section to create a 3D shape - * @param inputs cross section and extrusion parameters - * @returns extruded manifold shape - * @group basic - * @shortname extrude - * @drawable true - */ - extrude( - inputs: Inputs.Manifold.ExtrudeDto - ): Promise; - /** - * Revolve the cross section to create a 3D shape - * @param inputs cross section and extrusion parameters - * @returns extruded manifold shape - * @group basic - * @shortname revolve - * @drawable true - */ - revolve( - inputs: Inputs.Manifold.RevolveDto - ): Promise; - /** - * Offsets the cross section to create a new cross section with a given delta (uses Clipper2 algorithm behind). - * @param inputs cross section and offset parameters - * @returns offset cross section - * @group basic - * @shortname offset - * @drawable true - */ - offset( - inputs: Inputs.Manifold.OffsetDto - ): Promise; - /** - * Remove vertices from the contours in this CrossSection that are less than - * the specified distance epsilon from an imaginary line that passes through - * its two adjacent vertices. Near duplicate vertices and collinear points - * will be removed at lower epsilons, with elimination of line segments - * becoming increasingly aggressive with larger epsilons. - * - * It is recommended to apply this function following Offset, in order to - * clean up any spurious tiny line segments introduced that do not improve - * offseting operations are to be performed, which would compound the issue. - * @param inputs cross section and epsilon parameters - * @returns simplified cross section - * @group basic - * @shortname simplify - * @drawable true - */ - simplify( - inputs: Inputs.Manifold.SimplifyDto - ): Promise; - /** - * Composes multiple cross sections or polygons into a single cross section - * @param inputs cross sections or polygons - * @returns composed cross section - * @group composition - * @shortname compose - * @drawable true - */ - compose( - inputs: Inputs.Manifold.ComposeDto< - (Inputs.Manifold.CrossSectionPointer | Inputs.Base.Vector2[])[] - > - ): Promise; - /** - * Decompose cross sections that are topologically - * disconnected, each containing one outline contour with zero or more - * holes. - * @param inputs cross section - * @returns decomposed cross sections - * @group composition - * @shortname decompose - * @drawable true - */ - decompose( - inputs: Inputs.Manifold.CrossSectionDto - ): Promise; - } - /** - * Contains various functions for making shapes Manifold library https://github.com/elalish/manifold - * Thanks Manifold community for developing this kernel - */ - declare class CrossSectionShapes { - private readonly manifoldWorkerManager; - constructor(manifoldWorkerManager: ManifoldWorkerManager); - /** - * Create a 2d cross-section from a set of contours (complex polygons). A - * boolean union operation (with Positive filling rule by default) is - * performed to combine overlapping polygons and ensure the resulting - * CrossSection is free of intersections. - * @param inputs polygons and fill rule - * @returns cross section - * @group base - * @shortname create - * @drawable true - */ - create( - inputs: Inputs.Manifold.CreateContourSectionDto - ): Promise; - /** - * Create a 2D square cross section - * @param inputs Square parameters - * @returns square cross section - * @group primitives - * @shortname square - * @drawable true - */ - square( - inputs: Inputs.Manifold.SquareDto - ): Promise; - /** - * Create a 2D circle cross section - * @param inputs Circle parameters - * @returns circle cross section - * @group primitives - * @shortname circle - * @drawable true - */ - circle( - inputs: Inputs.Manifold.CircleDto - ): Promise; - /** - * Create a 2D rectangle cross section - * @param inputs Rectangle parameters - * @returns rectangle cross section - * @group primitives - * @shortname rectangle - * @drawable true - */ - rectangle( - inputs: Inputs.Manifold.RectangleDto - ): Promise; - } - /** - * Contains various functions for transforming cross section from Manifold library https://github.com/elalish/manifold - * Thanks Manifold community for developing this kernel - */ - declare class CrossSectionTransforms { - private readonly manifoldWorkerManager; - constructor(manifoldWorkerManager: ManifoldWorkerManager); - /** - * Scales a cross section shape with 2D vector - * @param inputs cross section and scale vector - * @returns Scaled cross section shape - * @group transforms - * @shortname scale 2d - * @drawable true - */ - scale2D( - inputs: Inputs.Manifold.Scale2DCrossSectionDto - ): Promise; - /** - * Scales a cross section shape with single factor - * @param inputs cross section and scale factor - * @returns Scaled cross section shape - * @group transforms - * @shortname scale uniform - * @drawable true - */ - scale( - inputs: Inputs.Manifold.ScaleCrossSectionDto - ): Promise; - /** - * Mirrors a cross section shape over a plane defined by a normal vector - * @param inputs cross section and normal vector - * @returns Mirrored cross section shape - * @group transforms - * @shortname mirror - * @drawable true - */ - mirror( - inputs: Inputs.Manifold.MirrorCrossSectionDto - ): Promise; - /** - * Translates a cross section shape along the vector - * @param inputs cross section and trnaslation vector - * @returns Translated cross section shape - * @group transforms - * @shortname translate - * @drawable true - */ - translate( - inputs: Inputs.Manifold.TranslateCrossSectionDto - ): Promise; - /** - * Translates a cross section shape along x, y - * @param inputs cross section and trnaslation coordinates - * @returns Translated cross section shape - * @group transforms - * @shortname translate xy - * @drawable true - */ - translateXY( - inputs: Inputs.Manifold.TranslateXYCrossSectionDto - ): Promise; - /** - * Rotates a cross section shape along the containing degrees - * @param inputs cross section and rotation degrees - * @returns Rotated cross section shape - * @group transforms - * @shortname rotate - * @drawable true - */ - rotate( - inputs: Inputs.Manifold.RotateCrossSectionDto - ): Promise; - /** - * Transforms a cross section shape by using the 3x3 transformation matrix - * @param inputs cross section and transformation matrix - * @returns Transformed cross section shape - * @group matrix - * @shortname transform - * @drawable true - */ - transform( - inputs: Inputs.Manifold.TransformCrossSectionDto - ): Promise; - /** - * Move the vertices of this CrossSection (creating a new one) according to - * any arbitrary input function, followed by a union operation (with a - * Positive fill rule) that ensures any introduced intersections are not - * included in the result. - * @param inputs cross section and warp function - * @returns Warped cross section shape - * @group transforms - * @shortname warp - * @drawable true - */ - warp( - inputs: Inputs.Manifold.CrossSectionWarpDto - ): Promise; - } - /** - * Contains various functions for Solid meshes from Manifold library https://github.com/elalish/manifold - * Thanks Manifold community for developing this kernel - */ - declare class ManifoldBooleans { - private readonly manifoldWorkerManager; - constructor(manifoldWorkerManager: ManifoldWorkerManager); - /** - * Subtract two manifold shapes - * @param inputs two shapes - * @returns subtracted manifold shape - * @group a to b - * @shortname subtract - * @drawable true - */ - subtract( - inputs: Inputs.Manifold.TwoManifoldsDto - ): Promise; - /** - * Add two manifold shapes - * @param inputs two shapes - * @returns unioned manifold shape - * @group a to b - * @shortname add - * @drawable true - */ - add( - inputs: Inputs.Manifold.TwoManifoldsDto - ): Promise; - /** - * Intersect two manifold shapes - * @param inputs two shapes - * @returns intersected manifold shape - * @group a to b - * @shortname intersect - * @drawable true - */ - intersect( - inputs: Inputs.Manifold.TwoManifoldsDto - ): Promise; - /** - * Difference of two manifold shapes - * @param inputs two shapes - * @returns difference of two manifold shapes - * @group 2 manifolds - * @shortname difference 2 manifolds - * @drawable true - */ - differenceTwo( - inputs: Inputs.Manifold.TwoManifoldsDto - ): Promise; - /** - * Union of two manifold shapes - * @param inputs two shapes - * @returns union of two manifold shapes - * @group 2 manifolds - * @shortname union 2 manifolds - * @drawable true - */ - unionTwo( - inputs: Inputs.Manifold.TwoManifoldsDto - ): Promise; - /** - * Intersection of two manifold shapes - * @param inputs two shapes - * @returns intersection of two manifold shapes - * @group 2 manifolds - * @shortname intersection 2 manifolds - * @drawable true - */ - intersectionTwo( - inputs: Inputs.Manifold.TwoManifoldsDto - ): Promise; - /** - * Difference of multiple manifold shapes - * @param inputs multiple shapes - * @returns difference of two manifold shapes - * @group multiple - * @shortname difference manifolds - * @drawable true - */ - difference( - inputs: Inputs.Manifold.ManifoldsDto - ): Promise; - /** - * Union of multiple manifold shapes - * @param inputs multiple shapes - * @returns union of two manifold shapes - * @group multiple - * @shortname union manifolds - * @drawable true - */ - union( - inputs: Inputs.Manifold.ManifoldsDto - ): Promise; - /** - * Intersection of multiple manifold shapes - * @param inputs two shapes - * @returns intersection of multiple manifold shapes - * @group multiple - * @shortname intersection manifolds - * @drawable true - */ - intersection( - inputs: Inputs.Manifold.ManifoldsDto - ): Promise; - /** - * Split manifold by another manifold - * @param inputs manifold to split and manifold cutter - * @returns split manifold - * @group split - * @shortname split - * @drawable true - */ - split( - inputs: Inputs.Manifold.SplitManifoldsDto - ): Promise; - /** - * Split manifold by plane - * @param inputs manifold and plane - * @returns split manifold - * @group split - * @shortname split by plane - * @drawable true - */ - splitByPlane( - inputs: Inputs.Manifold.SplitByPlaneDto - ): Promise; - /** - * Split manifold by plane on various offsets - * @param inputs manifold, plane and the list of offsets - * @returns splitted manifolds - * @group split - * @shortname split by plane on offsets - * @drawable true - */ - splitByPlaneOnOffsets( - inputs: Inputs.Manifold.SplitByPlaneOnOffsetsDto - ): Promise; - /** - * Trim manifold by plane - * @param inputs manifold and plane - * @returns trimmed manifold - * @group trim - * @shortname trim by plane - * @drawable true - */ - trimByPlane( - inputs: Inputs.Manifold.TrimByPlaneDto - ): Promise; - } - /** - * Contains various functions for Solid meshes from Manifold library https://github.com/elalish/manifold - * Thanks Manifold community for developing this kernel - */ - declare class ManifoldEvaluate { - private readonly manifoldWorkerManager; - constructor(manifoldWorkerManager: ManifoldWorkerManager); - /** - * Get surface area of manifold - * @param inputs manifold - * @returns surface area of manifold - * @group basic - * @shortname surface area - * @drawable false - */ - surfaceArea( - inputs: Inputs.Manifold.ManifoldDto - ): Promise; - /** - * Get volume of manifold - * @param inputs manifold - * @returns volume of manifold - * @group basic - * @shortname volume - * @drawable false - */ - volume( - inputs: Inputs.Manifold.ManifoldDto - ): Promise; - /** - * Check if manifold contains triangles - * @param inputs manifold - * @returns boolean indicating emptyness - * @group basic - * @shortname is empty - * @drawable false - */ - isEmpty( - inputs: Inputs.Manifold.ManifoldDto - ): Promise; - /** - * Get number of vertices in manifold - * @param inputs manifold - * @returns number of vertices of manifold - * @group basic - * @shortname num vert - * @drawable false - */ - numVert( - inputs: Inputs.Manifold.ManifoldDto - ): Promise; - /** - * Get number of triangles in manifold - * @param inputs manifold - * @returns number of triangles of manifold - * @group basic - * @shortname num triangles - * @drawable false - */ - numTri( - inputs: Inputs.Manifold.ManifoldDto - ): Promise; - /** - * Get number of edges in manifold - * @param inputs manifold - * @returns number of edges of manifold - * @group basic - * @shortname num edges - * @drawable false - */ - numEdge( - inputs: Inputs.Manifold.ManifoldDto - ): Promise; - /** - * Get number of properties in manifold - * @param inputs manifold - * @returns number of properties of manifold - * @group basic - * @shortname num prop - * @drawable false - */ - numProp( - inputs: Inputs.Manifold.ManifoldDto - ): Promise; - /** - * The number of property vertices in the Manifold. This will always be >= - * numVert, as some physical vertices may be duplicated to account for - * different properties on different neighboring triangles. - * @param inputs manifold - * @returns number of properties of manifold - * @group basic - * @shortname num prop vert - * @drawable false - */ - numPropVert( - inputs: Inputs.Manifold.ManifoldDto - ): Promise; - /** - * Returns the axis-aligned bounding box of all the Manifold's vertices. - * @param inputs manifold - * @returns bounding box corner vectors of manifold - * @group basic - * @shortname bounding box - * @drawable false - */ - boundingBox( - inputs: Inputs.Manifold.ManifoldDto - ): Promise; - /** - * Returns the tolerance of this Manifold's vertices, which tracks the - * approximate rounding error over all the transforms and operations that have - * led to this state. Any triangles that are colinear within this tolerance - * are considered degenerate and removed. This is the value of ε - * defining - * [ε-valid](https://github.com/elalish/manifold/wiki/Manifold-Library#definition-of-%CE%B5-valid). - * @param inputs manifold - * @returns tolerance of manifold - * @group basic - * @shortname tolerance - * @drawable false - */ - tolerance( - inputs: Inputs.Manifold.ManifoldDto - ): Promise; - /** - * The genus is a topological property of the manifold, representing the - * number of handles. A sphere is 0, torus 1, etc. It is only meaningful for - * a single mesh, so it is best to call Decompose() first. - * @param inputs manifold - * @returns genus of manifold - * @group basic - * @shortname genus - * @drawable false - */ - genus( - inputs: Inputs.Manifold.ManifoldDto - ): Promise; - /** - * Returns the minimum gap between two manifolds. Returns a float between - * 0 and searchLength. - * @param inputs two manifolds and search length - * @returns minimum - * @group basic - * @shortname min gap - * @drawable false - */ - minGap( - inputs: Inputs.Manifold.ManifoldsMinGapDto - ): Promise; - /** - * If this mesh is an original, this returns its ID that can be referenced - * by product manifolds. If this manifold is a product, this - * returns -1. - * @param inputs manifold - * @returns original id of manifold - * @group basic - * @shortname original id - * @drawable false - */ - originalID( - inputs: Inputs.Manifold.ManifoldDto - ): Promise; - /** - * Returns the reason for an input Mesh producing an empty Manifold. This - * Status will carry on through operations like NaN propogation, ensuring an - * errored mesh doesn't get mysteriously lost. Empty meshes may still show - * NoError, for instance the intersection of non-overlapping meshes. - * @param inputs manifold - * @returns error status string (NoError, NotManifold, InvalidConstruction, etc.) - * @group basic - * @shortname status - * @drawable false - */ - status( - inputs: Inputs.Manifold.ManifoldDto - ): Promise; - } - /** - * Contains various functions for Solid meshes from Manifold library https://github.com/elalish/manifold - * Thanks Manifold community for developing this kernel - */ - declare class Manifold { - private readonly manifoldWorkerManager; - readonly shapes: ManifoldShapes; - readonly booleans: ManifoldBooleans; - readonly operations: ManifoldOperations; - readonly transforms: ManifoldTransforms; - readonly evaluate: ManifoldEvaluate; - constructor(manifoldWorkerManager: ManifoldWorkerManager); - /** - * Turns manifold shape into a mesh - * @param inputs Manifold shape - * @returns Decomposed mesh definition - * @group meshing - * @shortname manifold to mesh - * @drawable false - */ - manifoldToMesh( - inputs: Inputs.Manifold.ManifoldToMeshDto - ): Promise; - /** - * Turns manifold shapes into meshes - * @param inputs Manifold shapes - * @returns Decomposed mesh definitions - * @group meshing - * @shortname manifolds to meshes - * @drawable false - */ - manifoldsToMeshes( - inputs: Inputs.Manifold.ManifoldsToMeshesDto - ): Promise; - } - /** - * Contains various functions for Solid meshes from Manifold library https://github.com/elalish/manifold - * Thanks Manifold community for developing this kernel - */ - declare class ManifoldOperations { - private readonly manifoldWorkerManager; - constructor(manifoldWorkerManager: ManifoldWorkerManager); - /** - * Computes convex hull of the manifold shape provided - * @param inputs two shapes - * @returns hulled manifold shape - * @group hulls - * @shortname convex hull - * @drawable true - */ - hull( - inputs: Inputs.Manifold.ManifoldDto - ): Promise; - /** - * Hull points or manifolds - * @param inputs manifold - * @returns manifold - * @group hulls - * @shortname hull points - * @drawable true - */ - hullPoints( - inputs: Inputs.Manifold.HullPointsDto< - (Inputs.Base.Point3 | Inputs.Manifold.ManifoldPointer)[] - > - ): Promise; - /** - * Returns the cross section of this object parallel to the X-Y plane at the - * specified height. Using a height equal to the bottom - * of the bounding box will return the bottom faces, while using a height - * equal to the top of the bounding box will return empty. - * @param inputs manifold and height - * @returns sliced cross section - * @group cross sections - * @shortname slice - * @drawable true - */ - slice( - inputs: Inputs.Manifold.SliceDto - ): Promise; - /** - * Creates a projection on xy plane from the shape outline - * @param inputs manifold - * @returns projected cross section - * @group cross sections - * @shortname project - * @drawable true - */ - project( - inputs: Inputs.Manifold.ManifoldDto - ): Promise; - /** - * Return a copy of the manifold with the set tolerance value. - * This performs mesh simplification when the tolerance value is increased. - * @param inputs manifold and tolerance - * @returns manifold with new tolerance - * @group basic - * @shortname set tolerance - * @drawable false - */ - setTolerance( - inputs: Inputs.Manifold.ManifoldRefineToleranceDto - ): Promise; - /** - * Returns the first of n sequential new unique mesh IDs for marking sets of triangles that can be looked up after further operations. Assign to Mesh.runOriginalID vector. - * @param inputs count - * @returns void - * @group basic - * @shortname reserve id - * @drawable false - */ - reserveIds(inputs: Inputs.Manifold.CountDto): Promise; - /** - * If you copy a manifold, but you want this new copy to have new properties - * (e.g. a different UV mapping), you can reset its IDs to a new original, - * meaning it will now be referenced by its descendants instead of the meshes - * it was built from, allowing you to differentiate the copies when applying - * your properties to the final result. - * - * This function also condenses all coplanar faces in the relation, and - * collapses those edges. If you want to have inconsistent properties across - * these faces, meaning you want to preserve some of these edges, you should - * instead call GetMesh(), calculate your properties and use these to - * construct a new manifold. - * @param inputs manifold - * @returns original manifold - * @group basic - * @shortname as original - * @drawable true - */ - asOriginal( - inputs: Inputs.Manifold.ManifoldDto - ): Promise; - /** - * Constructs a new manifold from a list of other manifolds. This is a purely - * topological operation, so care should be taken to avoid creating - * overlapping results. It is the inverse operation of Decompose(). - * @param inputs manifold shapes - * @returns composed manifold - * @group composition - * @shortname compose - * @drawable true - */ - compose( - inputs: Inputs.Manifold.ManifoldsDto - ): Promise; - /** - * This operation returns a vector of Manifolds that are topologically - * disconnected. If everything is connected, the vector is length one, - * containing a copy of the original. It is the inverse operation of - * Compose(). - * @param inputs manifold - * @returns decomposed manifold shapes - * @group composition - * @shortname decompose - * @drawable true - */ - decompose( - inputs: Inputs.Manifold.ManifoldDto - ): Promise; - /** - * Fills in vertex properties for normal vectors, calculated from the mesh - * geometry. Flat faces composed of three or more triangles will remain flat. - * @param inputs manifold and normal index with minimum sharp angle - * @returns manifold with calculated normals - * @group adjustments - * @shortname calculate normals - * @drawable true - */ - calculateNormals( - inputs: Inputs.Manifold.CalculateNormalsDto - ): Promise; - /** - * Curvature is the inverse of the radius of curvature, and signed such that - * positive is convex and negative is concave. There are two orthogonal - * principal curvatures at any point on a manifold, with one maximum and the - * other minimum. Gaussian curvature is their product, while mean - * curvature is their sum. This approximates them for every vertex and assigns - * them as vertex properties on the given channels. - * @param inputs manifold and gaussian and mean index - * @returns manifold with calculated curvature - * @group adjustments - * @shortname calculate curvature - * @drawable true - */ - calculateCurvature( - inputs: Inputs.Manifold.CalculateCurvatureDto - ): Promise; - /** - * Increase the density of the mesh by splitting each edge into pieces such - * that any point on the resulting triangles is roughly within tolerance of - * the smoothly curved surface defined by the tangent vectors. This means - * tightly curving regions will be divided more finely than smoother regions. - * If halfedgeTangents are not present, the result will simply be a copy of - * the original. Quads will ignore their interior triangle bisector. - * @param inputs manifold and tolerance - * @returns refined manifold - * @group adjustments - * @shortname refine to tolerance - * @drawable true - */ - refineToTolerance( - inputs: Inputs.Manifold.ManifoldRefineToleranceDto - ): Promise; - /** - * Increase the density of the mesh by splitting each edge into pieces of - * roughly the input length. Interior verts are added to keep the rest of the - * triangulation edges also of roughly the same length. If halfedgeTangents - * are present (e.g. from the Smooth() constructor), the new vertices will be - * moved to the interpolated surface according to their barycentric - * coordinates. - * @param inputs manifold and length - * @returns refined manifold - * @group adjustments - * @shortname refine to length - * @drawable true - */ - refineToLength( - inputs: Inputs.Manifold.ManifoldRefineLengthDto - ): Promise; - /** - * Increase the density of the mesh by splitting every edge into n pieces. For - * instance, with n = 2, each triangle will be split into 4 triangles. These - * will all be coplanar (and will not be immediately collapsed) unless the - * Mesh/Manifold has halfedgeTangents specified (e.g. from the Smooth() - * constructor), in which case the new vertices will be moved to the - * interpolated surface according to their barycentric coordinates. - * @param inputs manifold and count - * @returns refined manifold - * @group adjustments - * @shortname refine - * @drawable true - */ - refine( - inputs: Inputs.Manifold.ManifoldRefineDto - ): Promise; - /** - * Smooths out the Manifold by filling in the halfedgeTangent vectors. The - * geometry will remain unchanged until Refine or RefineToLength is called to - * interpolate the surface. This version uses the geometry of the triangles - * and pseudo-normals to define the tangent vectors. - * @param inputs manifold and minimum sharp angle and minimum smoothness - * @returns smoothed manifold - * @group adjustments - * @shortname smooth out - * @drawable true - */ - smoothOut( - inputs: Inputs.Manifold.ManifoldSmoothOutDto - ): Promise; - /** - * Smooths out the Manifold by filling in the halfedgeTangent vectors. The - * geometry will remain unchanged until Refine or RefineToLength is called to - * interpolate the surface. This version uses the supplied vertex normal - * properties to define the tangent vectors. - * @param inputs manifold and normal index - * @returns smoothed manifold - * @group adjustments - * @shortname smooth by normals - * @drawable true - */ - smoothByNormals( - inputs: Inputs.Manifold.ManifoldSmoothByNormalsDto - ): Promise; - /** - * Return a copy of the manifold simplified to the given tolerance, but with - * its actual tolerance value unchanged. The result will contain a subset of - * the original verts and all surfaces will have moved by less than tolerance. - * @param inputs manifold and tolerance - * @returns simplified manifold - * @group adjustments - * @shortname simplify - * @drawable true - */ - simplify( - inputs: Inputs.Manifold.ManifoldSimplifyDto - ): Promise; - /** - * Create a new copy of this manifold with updated vertex properties by - * supplying a function that takes the existing position and properties as - * input. You may specify any number of output properties, allowing creation - * and removal of channels. Note: undefined behavior will result if you read - * past the number of input properties or write past the number of output - * properties. - * @param inputs manifold, numProp and property function - * @returns manifold with updated properties - * @group adjustments - * @shortname set properties - * @drawable true - */ - setProperties( - inputs: Inputs.Manifold.ManifoldSetPropertiesDto - ): Promise; - } - /** - * Contains various functions for Solid meshes from Manifold library https://github.com/elalish/manifold - * Thanks Manifold community for developing this kernel - */ - declare class ManifoldShapes { - private readonly manifoldWorkerManager; - constructor(manifoldWorkerManager: ManifoldWorkerManager); - /** - * Convert a Mesh into a Manifold, retaining its properties and merging only - * the positions according to the merge vectors. Will throw an error if the - * result is not an oriented 2-manifold. Will collapse degenerate triangles - * and unnecessary vertices. - * - * All fields are read, making this structure suitable for a lossless - * round-trip of data from manifoldToMesh(). For multi-material input, use - * reserveIDs() to set a unique originalID for each material, and sort the - * materials into triangle runs. - * @param inputs mesh definition - * @returns manifold - * @group create - * @shortname manifold from mesh - * @drawable true - */ - manifoldFromMesh( - inputs: Inputs.Manifold.CreateFromMeshDto - ): Promise; - /** - * Create a Manifold from a set of polygon points describing triangles. - * @param inputs Polygon points - * @returns Manifold - * @group create - * @shortname from polygon points - * @drawable true - */ - fromPolygonPoints( - inputs: Inputs.Manifold.FromPolygonPointsDto - ): Promise; - /** - * Create a 3D cube shape - * @param inputs Cube parameters - * @returns Cube solid - * @group primitives - * @shortname cube - * @drawable true - */ - cube( - inputs: Inputs.Manifold.CubeDto - ): Promise; - /** - * Create a 3D sphere shape - * @param inputs Sphere parameters - * @returns Sphere solid - * @group primitives - * @shortname sphere - * @drawable true - */ - sphere( - inputs: Inputs.Manifold.SphereDto - ): Promise; - /** - * Create a 3D tetrahedron shape - * @returns Tetrahedron solid - * @group primitives - * @shortname tetrahedron - * @drawable true - */ - tetrahedron(): Promise; - /** - * Create a 3D cylinder shape - * @param inputs Cylinder parameters - * @returns Cylinder solid - * @group primitives - * @shortname cylinder - * @drawable true - */ - cylinder( - inputs: Inputs.Manifold.CylinderDto - ): Promise; - } - /** - * Contains various functions for Solid meshes from Manifold library https://github.com/elalish/manifold - * Thanks Manifold community for developing this kernel - */ - declare class ManifoldTransforms { - private readonly manifoldWorkerManager; - constructor(manifoldWorkerManager: ManifoldWorkerManager); - /** - * Scales a manifold shape with 3D vector - * @param inputs manifold and scale vector - * @returns Scaled manifold shape - * @group transforms - * @shortname scale 3d - * @drawable true - */ - scale3D( - inputs: Inputs.Manifold.Scale3DDto - ): Promise; - /** - * Scales a manifold shape with single factor - * @param inputs manifold and scale factor - * @returns Scaled manifold shape - * @group transforms - * @shortname scale uniform - * @drawable true - */ - scale( - inputs: Inputs.Manifold.ScaleDto - ): Promise; - /** - * Mirrors a manifold shape over a plane defined by a normal vector - * @param inputs manifold and normal vector - * @returns Mirrored manifold shape - * @group transforms - * @shortname mirror - * @drawable true - */ - mirror( - inputs: Inputs.Manifold.MirrorDto - ): Promise; - /** - * Translates a manifold shape along the vector - * @param inputs manifold and trnaslation vector - * @returns Translated manifold shape - * @group transforms - * @shortname translate - * @drawable true - */ - translate( - inputs: Inputs.Manifold.TranslateDto - ): Promise; - /** - * Translates a manifold shape along by multiple vectors - * @param inputs manifold and trnaslation vectors - * @returns Translated manifold shapes - * @group multiple - * @shortname translate by vectors - * @drawable true - */ - translateByVectors( - inputs: Inputs.Manifold.TranslateByVectorsDto - ): Promise; - /** - * Translates a manifold shape along x, y, z - * @param inputs manifold and trnaslation coordinates - * @returns Translated manifold shape - * @group transforms - * @shortname translate xyz - * @drawable true - */ - translateXYZ( - inputs: Inputs.Manifold.TranslateXYZDto - ): Promise; - /** - * Rotates a manifold shape along the vector containing euler angles - * @param inputs manifold and rotation vector - * @returns Rotated manifold shape - * @group transforms - * @shortname rotate - * @drawable true - */ - rotate( - inputs: Inputs.Manifold.RotateDto - ): Promise; - /** - * Rotates a manifold shape along the x y z euler angles - * @param inputs manifold and rotation eulers - * @returns Rotated manifold shape - * @group transforms - * @shortname rotate xyz - * @drawable true - */ - rotateXYZ( - inputs: Inputs.Manifold.RotateXYZDto - ): Promise; - /** - * Transforms a manifold shape by using the 4x4 transformation matrix - * @param inputs manifold and transformation matrix - * @returns Transformed manifold shape - * @group matrix - * @shortname transform - * @drawable true - */ - transform( - inputs: Inputs.Manifold.TransformDto - ): Promise; - /** - * Transforms a manifold shape by using the 4x4 transformation matrixes - * @param inputs manifold and transformation matrixes - * @returns Transformed manifold shape - * @group matrix - * @shortname transforms - * @drawable true - */ - transforms( - inputs: Inputs.Manifold.TransformsDto - ): Promise; - /** - * Move the vertices of this Manifold (creating a new one) according to any - * arbitrary input function. It is easy to create a function that warps a - * geometrically valid object into one which overlaps, but that is not checked - * here, so it is up to the user to choose their function with discretion. - * @param inputs manifold and warp function - * @returns Warped manifold shape - * @group transforms - * @shortname warp - * @drawable true - */ - warp( - inputs: Inputs.Manifold.ManifoldWarpDto - ): Promise; - } - /** - * Contains various functions for Solid meshes from Manifold library https://github.com/elalish/manifold - * Thanks Manifold community for developing this kernel - */ - declare class ManifoldBitByBit { - private readonly manifoldWorkerManager; - readonly manifold: Manifold; - readonly crossSection: ManifoldCrossSection; - readonly mesh: Mesh; - constructor(manifoldWorkerManager: ManifoldWorkerManager); - /** - * Turns manifold shape into a mesh pointer that lives in worker's memory. This pointer can be used with bitbybit.manifold.mesh functions - * @param inputs Manifold shape - * @returns Pointer to manifold mesh definition - * @group meshing - * @shortname manifold to mesh pointer - * @drawable false - */ - manifoldToMeshPointer( - inputs: Inputs.Manifold.ManifoldToMeshDto - ): Promise; - /** - * Decomposes manifold or cross section shape into a mesh or simple polygons - * @param inputs Manifold shape or cross section - * @returns Decomposed mesh definition or simple polygons - * @group decompose - * @shortname decompose m or cs - * @drawable false - */ - decomposeManifoldOrCrossSection( - inputs: Inputs.Manifold.DecomposeManifoldOrCrossSectionDto< - Inputs.Manifold.ManifoldPointer | Inputs.Manifold.CrossSectionPointer - > - ): Promise< - Inputs.Manifold.DecomposedManifoldMeshDto | Inputs.Base.Vector2[][] - >; - /** - * Turns manifold shape into a collection of polygon points representing the mesh. - * @param inputs Manifold shape - * @returns polygon points - * @group decompose - * @shortname to polygon points - * @drawable false - */ - toPolygonPoints( - inputs: Inputs.Manifold.ManifoldDto - ): Promise; - /** - * Decomposes manifold or cross section shape into a mesh or simple polygons - * @param inputs Manifold shapes or cross sections - * @returns Decomposed mesh definitions or a list of simple polygons - * @group decompose - * @shortname decompose m's or cs's - * @drawable false - */ - decomposeManifoldsOrCrossSections( - inputs: Inputs.Manifold.DecomposeManifoldsOrCrossSectionsDto< - Inputs.Manifold.ManifoldPointer | Inputs.Manifold.CrossSectionPointer - > - ): Promise< - (Inputs.Manifold.DecomposedManifoldMeshDto | Inputs.Base.Vector2[][])[] - >; - /** - * Delete manifold or cross section from memory - * @param inputs manifold or cross section - * @group cleanup - * @shortname delete m or cs - * @drawable false - */ - deleteManifoldOrCrossSection( - inputs: Inputs.Manifold.ManifoldOrCrossSectionDto - ): Promise; - /** - * Delete manifolds or cross sections from memory - * @param inputs manifolds or cross sections - * @group cleanup - * @shortname delete m's or cs's - * @drawable false - */ - deleteManifoldsOrCrossSections( - inputs: Inputs.Manifold.ManifoldsOrCrossSectionsDto - ): Promise; - } - /** - * Contains various functions for Solid meshes from Manifold library https://github.com/elalish/manifold - * Thanks Manifold community for developing this kernel - */ - declare class MeshEvaluate { - private readonly manifoldWorkerManager; - constructor(manifoldWorkerManager: ManifoldWorkerManager); - /** - * Get position on mesh vertex index - * @param inputs mesh - * @returns point - * @group basic - * @shortname position - * @drawable true - */ - position( - inputs: Inputs.Manifold.MeshVertexIndexDto - ): Promise; - /** - * Gets the three vertex indices of this triangle in CCW order. - * @param inputs mesh - * @returns verts - * @group basic - * @shortname verts - * @drawable false - */ - verts( - inputs: Inputs.Manifold.MeshTriangleIndexDto - ): Promise; - /** - * Gets the tangent vector starting at verts(tri)[j] pointing to the next - * Bezier point along the CCW edge. The fourth value is its weight. - * @param inputs mesh - * @returns tangent - * @group basic - * @shortname tangent - * @drawable true - */ - tangent( - inputs: Inputs.Manifold.MeshHalfEdgeIndexDto - ): Promise; - /** - * Gets any other properties associated with this vertex. - * @param inputs mesh - * @returns extras - * @group basic - * @shortname extras - * @drawable false - */ - extras( - inputs: Inputs.Manifold.MeshVertexIndexDto - ): Promise; - /** - * Gets the column-major 4x4 matrix transform from the original mesh to these - * related triangles. - * @param inputs mesh - * @returns transform matrix - * @group basic - * @shortname transform 4x4 matrix - * @drawable false - */ - transform( - inputs: Inputs.Manifold.MeshVertexIndexDto - ): Promise; - /** - * Number of properties per vertex, always >= 3. - * @param inputs mesh - * @returns number of properties - * @group basic - * @shortname number props - * @drawable false - */ - numProp( - inputs: Inputs.Manifold.MeshDto - ): Promise; - /** - * Number of property vertices - * @param inputs mesh - * @returns number of vertices - * @group basic - * @shortname number vertices - * @drawable false - */ - numVert( - inputs: Inputs.Manifold.MeshDto - ): Promise; - /** - * Get number of triangles on mesh - * @param inputs mesh - * @returns number of triangles - * @group basic - * @shortname number triangles - * @drawable false - */ - numTri( - inputs: Inputs.Manifold.MeshDto - ): Promise; - /** - * Number of triangle runs. Each triangle run is a set of consecutive - * triangles that all come from the same instance of the same input mesh. - * @param inputs mesh - * @returns number of runs - * @group basic - * @shortname number runs - * @drawable false - */ - numRun( - inputs: Inputs.Manifold.MeshDto - ): Promise; - } - /** - * Contains various functions for Solid meshes from Manifold library https://github.com/elalish/manifold - * Thanks Manifold community for developing this kernel - */ - declare class Mesh { - private readonly manifoldWorkerManager; - readonly operations: MeshOperations; - readonly evaluate: MeshEvaluate; - constructor(manifoldWorkerManager: ManifoldWorkerManager); - } - /** - * Contains various functions for Solid meshes from Manifold library https://github.com/elalish/manifold - * Thanks Manifold community for developing this kernel - */ - declare class MeshOperations { - private readonly manifoldWorkerManager; - constructor(manifoldWorkerManager: ManifoldWorkerManager); - /** - * Updates the mergeFromVert and mergeToVert vectors in order to create a - * manifold solid. If the MeshGL is already manifold, no change will occur and - * the function will return false. Otherwise, this will merge verts along open - * edges within tolerance (the maximum of the MeshGL tolerance and the - * baseline bounding-box tolerance), keeping any from the existing merge - * vectors. - * - * There is no guarantee the result will be manifold - this is a best-effort - * helper function designed primarily to aid in the case where a manifold - * multi-material MeshGL was produced, but its merge vectors were lost due to - * a round-trip through a file format. Constructing a Manifold from the result - * will report a Status if it is not manifold. - * @param inputs mesh - * @returns merged mesh - * @group base - * @shortname merge - * @drawable true - */ - merge( - inputs: Inputs.Manifold.MeshDto - ): Promise; - } - declare class BitByBitOCCT { - occtWorkerManager: OCCTWorkerManager; - occt: OCCT; - constructor(); - init(occt: Worker): void; - } - declare class OCCTBooleans { - private readonly occWorkerManager; - constructor(occWorkerManager: OCCTWorkerManager); - /** - * Joins separate objects - * @param inputs Objects to join - * @returns OpenCascade joined shape - * @group booleans - * @shortname union - * @drawable true - */ - union( - inputs: Inputs.OCCT.UnionDto - ): Promise; - /** - * Does boolean difference operation between a main shape and given shapes - * @param inputs Main shape and shapes to differ - * @returns OpenCascade difference shape - * @group booleans - * @shortname difference - * @drawable true - */ - difference( - inputs: Inputs.OCCT.DifferenceDto - ): Promise; - /** - * Does boolean intersection operation between a main shape and given shapes - * @param inputs Main shape and shapes to differ - * @returns OpenCascade intersection of shapes - * @group booleans - * @shortname intersection - * @drawable true - */ - intersection( - inputs: Inputs.OCCT.IntersectionDto - ): Promise; - /** - * Does mesh mesh intersection operation between two shapes - both shapes can have their own meshing precision. - * This algorithm intersects the meshes and returns the wires of the intersection, which are polylines or polygons. - * @param inputs Two shapes to intersect - * @returns Wires where shapes intersect - * @group mesh based - * @shortname mesh mesh intersection as wires - * @drawable true - */ - meshMeshIntersectionWires( - inputs: Inputs.OCCT.MeshMeshIntersectionTwoShapesDto - ): Promise; - /** - * Does mesh mesh intersection operation between two shapes - both shapes can have their own meshing precision. - * This algorithm intersects the meshes and returns the points of the intersection, which are polylines or polygons. - * @param inputs Two shapes to intersect - * @returns Points where shapes intersect - * @group mesh based - * @shortname mesh mesh intersection as points - * @drawable true - */ - meshMeshIntersectionPoints( - inputs: Inputs.OCCT.MeshMeshIntersectionTwoShapesDto - ): Promise; - /** - * Does mesh mesh intersection operation between the shape and multiple other shapes - all shapes can have their own meshing precision. - * This algorithm intersects the meshes and returns the wires of the intersection, which are polylines or polygons. - * @param inputs Two shapes to intersect - * @returns Wires where shapes intersect - * @group mesh based - * @shortname mesh mesh intersection of shapes as wires - * @drawable true - */ - meshMeshIntersectionOfShapesWires( - inputs: Inputs.OCCT.MeshMeshesIntersectionOfShapesDto - ): Promise; - /** - * Does mesh mesh intersection operation between the shape and multiple other shapes - all shapes can have their own meshing precision. - * This algorithm intersects the meshes and returns the points of the intersection. - * @param inputs Two shapes to intersect - * @returns Wires where shapes intersect - * @group mesh based - * @shortname mesh mesh intersection of shapes as points - * @drawable true - */ - meshMeshIntersectionOfShapesPoints( - inputs: Inputs.OCCT.MeshMeshesIntersectionOfShapesDto - ): Promise; - } - declare class OCCTDimensions { - private readonly occWorkerManager; - constructor(occWorkerManager: OCCTWorkerManager); - /** - * Creates simple linear length dimension between two points - measuring units. You decide what kind of units you re using by providing a suffix. - * @param inputs two points, direction, label size, label normal direction, offset, and unit suffix, decimal rounding place - * @returns compound wires representing dimensions - * @group simple - * @shortname linear dimension - * @drawable true - */ - simpleLinearLengthDimension( - inputs: Inputs.OCCT.SimpleLinearLengthDimensionDto - ): Promise; - /** - * Creates simple angular dimension. By default we output degrees, but you can opt to use radians. - * @param inputs a center, two directions, radius and various label parameters - * @returns compound wires representing dimension - * @group simple - * @shortname angular dimension - * @drawable true - */ - simpleAngularDimension( - inputs: Inputs.OCCT.SimpleAngularDimensionDto - ): Promise; - /** - * @param inputs a start and end point, direction and parameters for the label - * @returns compound wires representing dimension - * @group simple - * @shortname pin with label - * @drawable true - */ - pinWithLabel( - inputs: Inputs.OCCT.PinWithLabelDto - ): Promise; - } - declare class OCCTFillets { - private readonly occWorkerManager; - constructor(occWorkerManager: OCCTWorkerManager); - /** - * Fillets OpenCascade Shapes - * @param inputs Shape, radius and edge indexes to fillet - * @returns OpenCascade shape with filleted edges - * @group 3d fillets - * @shortname fillet edges - * @drawable true - */ - filletEdges( - inputs: Inputs.OCCT.FilletDto - ): Promise; - /** - * Fillets edges list with different radius on each edge. - * @param inputs Shape, edges and radius list - * @returns OpenCascade shape with filleted edges - * @group 3d fillets - * @shortname fillet edges list - * @drawable true - */ - filletEdgesList( - inputs: Inputs.OCCT.FilletEdgesListDto< - Inputs.OCCT.TopoDSShapePointer, - Inputs.OCCT.TopoDSEdgePointer - > - ): Promise; - /** - * Fillets edges list with the single radius on all edges. - * @param inputs Shape, edges and radius - * @returns OpenCascade shape with filleted edges - * @group 3d fillets - * @shortname fillet edges list one r - * @drawable true - */ - filletEdgesListOneRadius( - inputs: Inputs.OCCT.FilletEdgesListOneRadiusDto< - Inputs.OCCT.TopoDSShapePointer, - Inputs.OCCT.TopoDSEdgePointer - > - ): Promise; - /** - * Fillets a single edge with variable radius list on given u params. You need to provide a list of params to identify on which U param to apply the radius on. - * @param inputs Shape, edge, radius list and param list - * @returns OpenCascade shape with filleted edges - * @group 3d fillets - * @shortname fillet edge variable r - * @drawable true - */ - filletEdgeVariableRadius( - inputs: Inputs.OCCT.FilletEdgeVariableRadiusDto< - Inputs.OCCT.TopoDSShapePointer, - Inputs.OCCT.TopoDSEdgePointer - > - ): Promise; - /** - * Fillets multiple provided edges with the same variable radiuses on u params for each edge. - * @param inputs Shape, edge, radius list and param list - * @returns OpenCascade shape with filleted edges - * @group 3d fillets - * @shortname fillet edges same variable r - * @drawable true - */ - filletEdgesSameVariableRadius( - inputs: Inputs.OCCT.FilletEdgesSameVariableRadiusDto< - Inputs.OCCT.TopoDSShapePointer, - Inputs.OCCT.TopoDSEdgePointer - > - ): Promise; - /** - * Fillets multiple provided edges with variable radius lists on given params lists. You need to provide a list of params to identify on which U param to apply the radius on. - * @param inputs Shape, edge, radius list and param list - * @returns OpenCascade shape with filleted edges - * @group 3d fillets - * @shortname fillet edges variable r - * @drawable true - */ - filletEdgesVariableRadius( - inputs: Inputs.OCCT.FilletEdgesVariableRadiusDto< - Inputs.OCCT.TopoDSShapePointer, - Inputs.OCCT.TopoDSEdgePointer - > - ): Promise; - /** - * Fillets OpenCascade 3d wire, this algorithm takes one guiding direction for fillets to be formed. - * It does not respect tangent directions on each filleted corner. This algorithm is based on extruding wire along the given direction - * to form a shell, then filleting the shell and finally extracting the filleted wire from the shell itself. - * Make sure you provide a direction that is not parallel to the wire and that forms high enough extrusion for the fillet to succeed. - * @param inputs Shape, radius and edge indexes to fillet - * @returns OpenCascade shape with filleted edges - * @group 3d fillets - * @shortname fillet 3d wire - * @drawable true - */ - fillet3DWire( - inputs: Inputs.OCCT.Fillet3DWireDto - ): Promise; - /** - * Fillets OpenCascade 3d wires, this algorithm takes one guiding direction for fillets to be formed. - * It does not respect tangent directions on each filleted corner. This algorithm is based on extruding wires along the given direction - * to form a shell, then filleting the shell and finally extracting the filleted wire from the shell itself. - * Make sure you provide a direction that is not parallel to the wire and that forms high enough extrusion for the fillet to succeed. - * @param inputs Shapes, radius and edge indexes to fillet - * @returns OpenCascade shape with filleted edges - * @group 3d fillets - * @shortname fillet 3d wires - * @drawable true - */ - fillet3DWires( - inputs: Inputs.OCCT.Fillet3DWiresDto - ): Promise; - /** - * Chamfer OpenCascade Shape edges - * @param inputs Shape, distance and edge indexes to chamfer - * @returns OpenCascade shape with chamfered edges - * @group 3d chamfers - * @shortname chamfer edges - * @drawable true - */ - chamferEdges( - inputs: Inputs.OCCT.ChamferDto - ): Promise; - /** - * Chamfers edges list with different distance on each edge. - * @param inputs Shape, edges and distance list - * @returns OpenCascade shape with chamfered edges - * @group 3d chamfers - * @shortname chamfer edges list - * @drawable true - */ - chamferEdgesList( - inputs: Inputs.OCCT.ChamferEdgesListDto< - Inputs.OCCT.TopoDSShapePointer, - Inputs.OCCT.TopoDSEdgePointer - > - ): Promise; - /** - * Chamfers edge by a by two distances. Face indicates the first distance to be applied - * @param inputs Shape, edge, face, distance1 and distance2 - * @returns OpenCascade shape with chamfered edges - * @group 3d chamfers - * @shortname chamfer edge 2 dist - * @drawable true - */ - chamferEdgeTwoDistances( - inputs: Inputs.OCCT.ChamferEdgeTwoDistancesDto< - Inputs.OCCT.TopoDSShapePointer, - Inputs.OCCT.TopoDSEdgePointer, - Inputs.OCCT.TopoDSFacePointer - > - ): Promise; - /** - * Chamfers edges by a by two distances. Face indicates the first distance to be applied - * @param inputs Shape, edges, faces, distance1 and distance2 - * @returns OpenCascade shape with chamfered edges - * @group 3d chamfers - * @shortname chamfer edges 2 dist - * @drawable true - */ - chamferEdgesTwoDistances( - inputs: Inputs.OCCT.ChamferEdgesTwoDistancesDto< - Inputs.OCCT.TopoDSShapePointer, - Inputs.OCCT.TopoDSEdgePointer, - Inputs.OCCT.TopoDSFacePointer - > - ): Promise; - /** - * Chamfers edges by two distances. Face indicates the first distance to be applied - * @param inputs Shape, edges, faces, distance1 list and distance2 list - * @returns OpenCascade shape with chamfered edges - * @group 3d chamfers - * @shortname chamfer edges 2 dist lists - * @drawable true - */ - chamferEdgesTwoDistancesLists( - inputs: Inputs.OCCT.ChamferEdgesTwoDistancesListsDto< - Inputs.OCCT.TopoDSShapePointer, - Inputs.OCCT.TopoDSEdgePointer, - Inputs.OCCT.TopoDSFacePointer - > - ): Promise; - /** - * Chamfers edge by a given distance and angle from the face - * @param inputs Shape, edge, face, distance and angle - * @returns OpenCascade shape with chamfered edges - * @group 3d chamfers - * @shortname chamfer edge angle - * @drawable true - */ - chamferEdgeDistAngle( - inputs: Inputs.OCCT.ChamferEdgeDistAngleDto< - Inputs.OCCT.TopoDSShapePointer, - Inputs.OCCT.TopoDSEdgePointer, - Inputs.OCCT.TopoDSFacePointer - > - ): Promise; - /** - * Chamfers multiple edges by a given distance and angle from the faces - * @param inputs Shape, edge, face, distance and angle - * @returns OpenCascade shape with chamfered edges - * @group 3d chamfers - * @shortname chamfer edges angle - * @drawable true - */ - chamferEdgesDistAngle( - inputs: Inputs.OCCT.ChamferEdgesDistAngleDto< - Inputs.OCCT.TopoDSShapePointer, - Inputs.OCCT.TopoDSEdgePointer, - Inputs.OCCT.TopoDSFacePointer - > - ): Promise; - /** - * Chamfers edges by a given distances and angles from the faces - * @param inputs Shape, edges, faces, distances and angles - * @returns OpenCascade shape with chamfered edges - * @group 3d chamfers - * @shortname chamfer edges angles - * @drawable true - */ - chamferEdgesDistsAngles( - inputs: Inputs.OCCT.ChamferEdgesDistsAnglesDto< - Inputs.OCCT.TopoDSShapePointer, - Inputs.OCCT.TopoDSEdgePointer, - Inputs.OCCT.TopoDSFacePointer - > - ): Promise; - /** - * Fillets 2d wire or face - * @param inputs Shape - * @returns OpenCascade filleted shape result - * @group 2d fillets - * @shortname fillet 2d wire or face - * @drawable true - */ - fillet2d( - inputs: Inputs.OCCT.FilletDto< - Inputs.OCCT.TopoDSWirePointer | Inputs.OCCT.TopoDSFacePointer - > - ): Promise; - /** - * Fillets 2d wires or faces - * @param inputs Shapes - * @returns OpenCascade filleted shapes result - * @group 2d fillets - * @shortname fillet 2d wires or faces - * @drawable true - */ - fillet2dShapes( - inputs: Inputs.OCCT.FilletShapesDto< - Inputs.OCCT.TopoDSWirePointer | Inputs.OCCT.TopoDSFacePointer - > - ): Promise; - /** - * Fillets two planar edges into a wire by providing a radius, plane, edges and possible solution index if more than one result exists - * @param inputs Definition for fillets - * @returns OpenCascade wire shape if solution is found - * @group 2d fillets - * @shortname fillet 2 edges - * @drawable true - */ - filletTwoEdgesInPlaneIntoAWire( - inputs: Inputs.OCCT.FilletTwoEdgesInPlaneDto - ): Promise; - } - declare class OCCTCurves { - private readonly occWorkerManager; - constructor(occWorkerManager: OCCTWorkerManager); - /** - * Creates a 2d ellipse. Be sure to use this geometry only for constructive purposes of modeling, but not for representation. You need to transform these curves to edges in order to draw them. - * @param inputs 2D Ellipse parameters - * @returns OpenCascade Geom2d_ellipse - * @group primitives - * @shortname ellipse 2d - */ - geom2dEllipse( - inputs: Inputs.OCCT.Geom2dEllipseDto - ): Promise; - /** - * Creates a trimmed curve from the basis curve limited between U1 and U2. This curve can't be drawn. - * @param inputs Bounds and strategy for trimming the curve - * @returns OpenCascade Geom2d_TrimmedCurve - * @group create - * @shortname trimmed 2d - */ - geom2dTrimmedCurve( - inputs: Inputs.OCCT.Geom2dTrimmedCurveDto - ): Promise; - /** - * Creates a trimmed 2d curve segment between two 2d points. This curve can't be drawn. - * @param inputs Two 2d points for start and end - * @returns OpenCascade Geom2d_Segment - * @group primitives - * @shortname segment 2d - */ - geom2dSegment( - inputs: Inputs.OCCT.Geom2dSegmentDto - ): Promise; - /** - * Gets 2d point represented by [number, number] on a curve at parameter. - * @param inputs 2D Curve shape and parameter - * @returns Point as array of 2 numbers - * @group get - * @shortname 2d point on curve - */ - get2dPointFrom2dCurveOnParam( - inputs: Inputs.OCCT.DataOnGeometryAtParamDto - ): Promise; - /** - * Creates a circle geom curve - * @param inputs Axis information and radius - * @returns Opencascade Geom_Circle curve - * @group primitives - * @shortname circle - * @drawable false - */ - geomCircleCurve( - inputs: Inputs.OCCT.CircleDto - ): Promise; - /** - * Creates an ellipse geom curve - * @param inputs Axis information and radius - * @returns Opencascade Geom_Ellipse curve - * @group primitives - * @shortname ellipse - * @drawable false - */ - geomEllipseCurve( - inputs: Inputs.OCCT.EllipseDto - ): Promise; - } - declare class OCCTGeom { - readonly curves: OCCTCurves; - readonly surfaces: OCCTSurfaces; - constructor(occWorkerManager: OCCTWorkerManager); - } - declare class OCCTSurfaces { - private readonly occWorkerManager; - constructor(occWorkerManager: OCCTWorkerManager); - /** - * Creates an infinite cylindrical surface that can not be drawn. Be sure to use this geometry only for constructive purposes of modeling, but not for representation. - * @param inputs Cylinder parameters - * @returns OpenCascade cylindrical surface - * @group surfaces - * @shortname cylindrical - * @drawable false - */ - cylindricalSurface( - inputs: Inputs.OCCT.GeomCylindricalSurfaceDto - ): Promise; - /** - * Creates a surface from the face - * @param inputs Face shape - * @returns OpenCascade geom surface - * @group surfaces - * @shortname from face - * @drawable false - */ - surfaceFromFace( - inputs: Inputs.OCCT.ShapeDto - ): Promise; - } - declare class OCCTIO { - readonly occWorkerManager: OCCTWorkerManager; - constructor(occWorkerManager: OCCTWorkerManager); - /** - * Saves the step file - * @param inputs STEP filename and shape to be saved - * @group io - * @shortname save step - * @drawable false - */ - saveShapeSTEP( - inputs: Inputs.OCCT.SaveStepDto - ): Promise; - /** - * Saves the step file and returns the text value - * @param inputs STEP filename and shape to be saved - * @group io - * @shortname save step and return - * @drawable false - */ - saveShapeSTEPAndReturn( - inputs: Inputs.OCCT.SaveStepDto - ): Promise; - /** - * Saves the stl file - * @param inputs STL filename and shape to be saved - * @group io - * @shortname save stl - * @drawable false - */ - saveShapeStl( - inputs: Inputs.OCCT.SaveStlDto - ): Promise; - /** - * Saves the stl file and returns - * @param inputs STL filename and shape to be saved - * @group io - * @shortname save stl return - * @drawable false - */ - saveShapeStlAndReturn( - inputs: Inputs.OCCT.SaveStlDto - ): Promise; - private saveSTEP; - private saveStl; - /** - * Creates DXF paths from an OCCT shape - * Important - shapes containing wires must lie on XZ plane (Y=0) for correct 2D DXF export. - * @param inputs Shape to convert to DXF paths - * @group dxf - * @shortname shape to dxf paths - * @drawable false - */ - shapeToDxfPaths( - inputs: Inputs.OCCT.ShapeToDxfPathsDto - ): Promise; - /** - * Adds layer and color information to DXF paths - * Important - shapes containing wires must lie on XZ plane (Y=0) for correct 2D DXF export. - * @param inputs DXF paths, layer name, and color - * @group dxf - * @shortname dxf paths with layer - * @drawable false - */ - dxfPathsWithLayer( - inputs: Inputs.OCCT.DxfPathsWithLayerDto - ): Promise; - /** - * Assembles multiple path parts into a complete DXF file. - * Important - shapes containing wires must lie on XZ plane (Y=0) for correct 2D DXF export. - * @param inputs Multiple DXF paths parts - * @group dxf - * @shortname dxf create - * @drawable false - */ - dxfCreate(inputs: Inputs.OCCT.DxfPathsPartsListDto): Promise; - } - /** - * Contains various methods for OpenCascade implementation - */ - declare class OCCT { - readonly occWorkerManager: OCCTWorkerManager; - readonly shapes: OCCTShapes; - readonly geom: OCCTGeom; - readonly fillets: OCCTFillets; - readonly transforms: OCCTTransforms; - readonly operations: OCCTOperations; - readonly booleans: OCCTBooleans; - readonly dimensions: OCCTDimensions; - readonly shapeFix: OCCTShapeFix; - io: OCCTIO; - constructor(occWorkerManager: OCCTWorkerManager); - /** - * Creates polygon points from the shape faces - * @param inputs shape - * @group convert - * @shortname faces to polygon points - * @drawable false - */ - shapeFacesToPolygonPoints( - inputs: Inputs.OCCT.ShapeFacesToPolygonPointsDto - ): Promise; - /** - * Creates mesh from the shape - * @param inputs shape - * @group convert - * @shortname shape to mesh - * @drawable false - */ - shapeToMesh( - inputs: Inputs.OCCT.ShapeToMeshDto - ): Promise; - /** - * Creates mesh from the shape - * @param inputs shape - * @group convert - * @shortname shape to mesh - * @drawable false - */ - shapesToMeshes( - inputs: Inputs.OCCT.ShapesToMeshesDto - ): Promise; - /** - * Deletes shape from the cache to keep memory usage low - * @param inputs shape - * @group memory - * @shortname delete shape - */ - deleteShape( - inputs: Inputs.OCCT.ShapeDto - ): Promise; - /** - * Deletes shapes from the cache to keep memory usage low - * @param inputs shape - * @group memory - * @shortname delete shapes - */ - deleteShapes( - inputs: Inputs.OCCT.ShapesDto - ): Promise; - /** - * Cleans all cache and all shapes from the memory - * @param inputs shape - * @group memory - * @shortname clean all cache - */ - cleanAllCache(): Promise; - } - declare class OCCTOperations { - private readonly occWorkerManager; - constructor(occWorkerManager: OCCTWorkerManager); - /** - * Lofts wires into a shell - * @param inputs Loft wires - * @returns Resulting loft shape - * @group lofts - * @shortname loft - * @drawable true - */ - loft( - inputs: Inputs.OCCT.LoftDto - ): Promise; - /** - * Lofts wires into a shell by using many advanced options - * @param inputs Advanced loft parameters - * @returns Resulting loft shell - * @group lofts - * @shortname loft adv. - * @drawable true - */ - loftAdvanced( - inputs: Inputs.OCCT.LoftAdvancedDto - ): Promise; - /** - * Computes two closest points between two shapes - * @param inputs two shapes - * @returns Resulting points - * @group closest pts - * @shortname two shapes - * @drawable true - */ - closestPointsBetweenTwoShapes( - inputs: Inputs.OCCT.ClosestPointsBetweenTwoShapesDto - ): Promise; - /** - * Computes closest points between a list of points and a given shape - * @param inputs a list of points and a shape - * @returns Resulting points - * @group closest pts - * @shortname on shape - * @drawable true - */ - closestPointsOnShapeFromPoints( - inputs: Inputs.OCCT.ClosestPointsOnShapeFromPointsDto - ): Promise; - /** - * Computes closest points between a list of points and shapes - * @param inputs a list of points and a list of shapes - * @returns Resulting points - * @group closest pts - * @shortname on shapes - * @drawable true - */ - closestPointsOnShapesFromPoints( - inputs: Inputs.OCCT.ClosestPointsOnShapesFromPointsDto - ): Promise; - /** - * Computes distances between a list of points and a corresponding closest points on shapes. - * @param inputs a list of points and a shapes - * @returns Resulting distances - * @group measure - * @shortname distances points to shape - * @drawable false - */ - distancesToShapeFromPoints( - inputs: Inputs.OCCT.ClosestPointsOnShapeFromPointsDto - ): Promise; - /** - * Computes bounding box parameters of the shape - * @param inputs a shape - * @returns Min, max center and size of the bounding box - * @group measure - * @shortname bbox of shape - * @drawable false - */ - boundingBoxOfShape( - inputs: Inputs.OCCT.ShapeDto - ): Promise; - /** - * Get min point of the bounding box of the shape - * @param inputs a shape - * @returns Min point of the bounding box - * @group measure - * @shortname bbox min of shape - * @drawable true - */ - boundingBoxMinOfShape( - inputs: Inputs.OCCT.ShapeDto - ): Promise; - /** - * Get max point of the bounding box of the shape - * @param inputs a shape - * @returns Max point of the bounding box - * @group measure - * @shortname bbox max of shape - * @drawable true - */ - boundingBoxMaxOfShape( - inputs: Inputs.OCCT.ShapeDto - ): Promise; - /** - * Get center point of the bounding box of the shape - * @param inputs a shape - * @returns Center point of the bounding box - * @group measure - * @shortname bbox center of shape - * @drawable true - */ - boundingBoxCenterOfShape( - inputs: Inputs.OCCT.ShapeDto - ): Promise; - /** - * Get size point of the bounding box of the shape - * @param inputs a shape - * @returns Center point of the bounding box - * @group measure - * @shortname bbox size of shape - * @drawable false - */ - boundingBoxSizeOfShape( - inputs: Inputs.OCCT.ShapeDto - ): Promise; - /** - * Get bounding box shape of the shape - * @param inputs a shape - * @returns shape of the bounding box - * @group measure - * @shortname bbox shape of shape - * @drawable true - */ - boundingBoxShapeOfShape( - inputs: Inputs.OCCT.ShapeDto - ): Promise; - /** - * Computes bounding sphere parameters of the shape - * @param inputs a shape - * @returns Center and radius of the bounding sphere - * @group measure - * @shortname bsphere of shape - * @drawable false - */ - boundingSphereOfShape( - inputs: Inputs.OCCT.ShapeDto - ): Promise; - /** - * Get center point of the bounding sphere of the shape - * @param inputs a shape - * @returns Center point of the bounding sphere - * @group measure - * @shortname bsphere center of shape - * @drawable false - */ - boundingSphereCenterOfShape( - inputs: Inputs.OCCT.ShapeDto - ): Promise; - /** - * Get radius of the bounding sphere of the shape - * @param inputs a shape - * @returns Radius of the bounding sphere - * @group measure - * @shortname bsphere radius of shape - * @drawable false - */ - boundingSphereRadiusOfShape( - inputs: Inputs.OCCT.ShapeDto - ): Promise; - /** - * Get bounding sphere shape of the shape - * @param inputs a shape - * @returns shape of the bounding sphere - * @group measure - * @shortname bsphere shape of shape - * @drawable true - */ - boundingSphereShapeOfShape( - inputs: Inputs.OCCT.ShapeDto - ): Promise; - /** - * Extrudes the shape along direction - wire will produce shell, face will produce solid - * @param inputs Shape to extrude and direction parameter with tolerance - * @returns Resulting extruded shape - * @group extrusions - * @shortname extrude - * @drawable true - */ - extrude( - inputs: Inputs.OCCT.ExtrudeDto - ): Promise; - /** - * Extrudes the shapes along direction - * @param inputs Shapes to extrude and direction parameter with tolerance - * @returns Resulting extruded shapes - * @group extrusions - * @shortname extrude shapes - * @drawable true - */ - extrudeShapes( - inputs: Inputs.OCCT.ExtrudeShapesDto - ): Promise; - /** - * Splits the shape with shapes - * @param inputs Shape to split and shapes to split with - * @returns Resulting shapes - * @group divisions - * @shortname split - * @drawable true - */ - splitShapeWithShapes( - inputs: Inputs.OCCT.SplitDto - ): Promise; - /** - * Revolves the shape around the given direction - * @param inputs Revolve parameters - * @returns Resulting revolved shape - * @group revolutions - * @shortname revolve - * @drawable true - */ - revolve( - inputs: Inputs.OCCT.RevolveDto - ): Promise; - /** - * Rotated extrude that is perofrmed on the shape - * @param inputs Rotated extrusion inputs - * @returns OpenCascade shape - * @group extrusions - * @shortname rotated extrude - * @drawable true - */ - rotatedExtrude( - inputs: Inputs.OCCT.RotationExtrudeDto - ): Promise; - /** - * Pipe shapes along the wire - * @param inputs Path wire and shapes along the path - * @returns OpenCascade shape - * @group pipeing - * @shortname pipe - * @drawable true - */ - pipe( - inputs: Inputs.OCCT.ShapeShapesDto< - Inputs.OCCT.TopoDSWirePointer, - Inputs.OCCT.TopoDSShapePointer - > - ): Promise; - /** - * Pipes polyline wire with ngon profile. - * @param inputs Path polyline wire - * @returns OpenCascade piped shapes - * @group pipeing - * @shortname pipe polyline ngon - * @drawable true - */ - pipePolylineWireNGon( - inputs: Inputs.OCCT.PipePolygonWireNGonDto - ): Promise; - /** - * Pipe wires with cylindrical shape - * @param inputs Path wires and radius - * @returns OpenCascade piped shapes - * @group pipeing - * @shortname pipe wires cylindrical - * @drawable true - */ - pipeWiresCylindrical( - inputs: Inputs.OCCT.PipeWiresCylindricalDto - ): Promise; - /** - * Pipe wire with cylindrical shape - * @param inputs Path wire and radius - * @returns OpenCascade piped shapes - * @group pipeing - * @shortname pipe wire cylindrical - * @drawable true - */ - pipeWireCylindrical( - inputs: Inputs.OCCT.PipeWireCylindricalDto - ): Promise; - /** - * Offset for various shapes - * @param inputs Shape to offset and distance with tolerance - * @returns Resulting offset shape - * @group offsets - * @shortname offset - * @drawable true - */ - offset( - inputs: Inputs.OCCT.OffsetDto< - Inputs.OCCT.TopoDSShapePointer, - Inputs.OCCT.TopoDSFacePointer - > - ): Promise; - /** - * Offset advanced that give more options for offset, such as joinType for edges and corners - * @param inputs Shape to offset and advanced parameters - * @returns Resulting offset shape - * @group offsets - * @shortname offset adv. - * @drawable true - */ - offsetAdv( - inputs: Inputs.OCCT.OffsetAdvancedDto< - Inputs.OCCT.TopoDSShapePointer, - Inputs.OCCT.TopoDSFacePointer - > - ): Promise; - /** - * Thickens the shape into a solid by an offset distance - * @param inputs OpenCascade shape - * @returns OpenCascade solid shape - * @group offsets - * @shortname thicken - * @drawable true - */ - makeThickSolidSimple( - inputs: Inputs.OCCT.ThisckSolidSimpleDto - ): Promise; - /** - * Thickens the shape into a solid by joining - * @param inputs OpenCascade shape and options for thickening - * @returns OpenCascade solid shape - * @group offsets - * @shortname joined thicken - * @drawable true - */ - makeThickSolidByJoin( - inputs: Inputs.OCCT.ThickSolidByJoinDto - ): Promise; - /** - * Slices the shape - * @param inputs OpenCascade shape and options for slicing - * @returns OpenCascade shape - * @group divisions - * @shortname slice - * @drawable true - */ - slice( - inputs: Inputs.OCCT.SliceDto - ): Promise; - /** - * Slices the shape in step pattern - * @param inputs OpenCascade shape and options for slicing - * @returns OpenCascade shape - * @group divisions - * @shortname slice in step pattern - * @drawable true - */ - sliceInStepPattern( - inputs: Inputs.OCCT.SliceInStepPatternDto - ): Promise; - /** - * Offset the 3D wire. When using this method consider using it on filleted wires that do not contain sharp corners. - * You can use fillet 3D on it. - * @param inputs wire and shape - * @returns OpenCascade compound - * @group offsets - * @shortname offset 3d wire - * @drawable true - */ - offset3DWire( - inputs: Inputs.OCCT.Offset3DWireDto - ): Promise; - } - declare class OCCTShapeFix { - private readonly occWorkerManager; - constructor(occWorkerManager: OCCTWorkerManager); - /** - * Performs the basic shape repair - * @param inputs the shape to be fixed and some options - * @returns OpenCascade fixed shape - * @group shape - * @shortname basic shape repair - * @drawable true - */ - basicShapeRepair( - inputs: Inputs.OCCT.BasicShapeRepairDto - ): Promise; - /** - * Fix small edge on wire - * @param inputs the wire to be fixed and some options - * @returns OpenCascade fixed wire - * @group wire - * @shortname fix small edge - * @drawable true - */ - fixSmallEdgeOnWire( - inputs: Inputs.OCCT.FixSmallEdgesInWireDto - ): Promise; - /** - * Fix edge orientations along wire - * @param inputs the wire to be fixed and some options - * @returns OpenCascade fixed wire - * @group wire - * @shortname fix edge orientations - * @drawable true - */ - fixEdgeOrientationsAlongWire( - inputs: Inputs.OCCT.ShapeDto - ): Promise; - } - declare class OCCTCompound { - private readonly occWorkerManager; - constructor(occWorkerManager: OCCTWorkerManager); - /** - * Makes the compound shape, which can include any kind of shapes - * @param inputs OpenCascade shapes - * @returns OpenCascade compounded shape - * @group create - * @shortname make - * @drawable true - */ - makeCompound( - inputs: Inputs.OCCT.CompoundShapesDto - ): Promise; - /** - * Gets the shapes that compound is made of - * @param inputs OpenCascade shapes - * @returns OpenCascade compounded shape - * @group get - * @shortname get shapes of compound - * @drawable true - */ - getShapesOfCompound( - inputs: Inputs.OCCT.ShapeDto - ): Promise; - } - declare class OCCTEdge { - private readonly occWorkerManager; - constructor(occWorkerManager: OCCTWorkerManager); - /** - * Creates linear edge from base line format {start: Point3, end: Point3} - * @param inputs base line - * @returns OpenCascade edge - * @group from base - * @shortname edge from base line - * @drawable true - */ - fromBaseLine( - inputs: Inputs.OCCT.LineBaseDto - ): Promise; - /** - * Creates linear edges from base lines format {start: Point3, end: Point3}[] - * @param inputs base lines - * @returns OpenCascade edges - * @group from base - * @shortname edges from base lines - * @drawable true - */ - fromBaseLines( - inputs: Inputs.OCCT.LineBaseDto - ): Promise; - /** - * Creates linear edge from base segment format [Point3, Point3] - * @param inputs base segment - * @returns OpenCascade edge - * @group from base - * @shortname edge from base segment - * @drawable true - */ - fromBaseSegment( - inputs: Inputs.OCCT.SegmentBaseDto - ): Promise; - /** - * Creates linear edge from base segments format [Point3, Point3][] - * @param inputs base segments - * @returns OpenCascade edges - * @group from base - * @shortname edges from base segments - * @drawable true - */ - fromBaseSegments( - inputs: Inputs.OCCT.SegmentsBaseDto - ): Promise; - /** - * Creates linear edges from collection of points - * @param inputs Points - * @returns OpenCascade edges - * @group from base - * @shortname edges from points - * @drawable true - */ - fromPoints( - inputs: Inputs.OCCT.PointsDto - ): Promise; - /** - * Creates linear edges from polyline definition - * @param inputs Polyline - * @returns OpenCascade edges - * @group from base - * @shortname edges from polyline - * @drawable true - */ - fromBasePolyline( - inputs: Inputs.OCCT.PolylineBaseDto - ): Promise; - /** - * Creates linear edges from triangle definition - * @param inputs Triangle - * @returns OpenCascade edges - * @group from base - * @shortname edges from triangle - * @drawable true - */ - fromBaseTriangle( - inputs: Inputs.OCCT.TriangleBaseDto - ): Promise; - /** - * Creates linear edges from mesh definition - * @param inputs Mesh - * @returns OpenCascade edges - * @group from base - * @shortname edges from mesh - * @drawable true - */ - fromBaseMesh( - inputs: Inputs.OCCT.MeshBaseDto - ): Promise; - /** - * Creates linear edge between two points - * @param inputs Two points between which edge should be created - * @returns OpenCascade edge - * @group primitives - * @shortname line - * @drawable true - */ - line(inputs: Inputs.OCCT.LineDto): Promise; - /** - * Creates arc edge between three points - * @param inputs three points - * @returns OpenCascade edge - * @group primitives - * @shortname arc 3 points - * @drawable true - */ - arcThroughThreePoints( - inputs: Inputs.OCCT.ArcEdgeThreePointsDto - ): Promise; - /** - * Creates arc edge between two points given the tangent direction vector on first point. - * @param inputs two points and tangent vector - * @returns OpenCascade edge - * @group primitives - * @shortname arc 2 points tangent - * @drawable true - */ - arcThroughTwoPointsAndTangent( - inputs: Inputs.OCCT.ArcEdgeTwoPointsTangentDto - ): Promise; - /** - * Creates an arc edge between two points on a circle - * @param inputs two points and circle edge - * @returns OpenCascade edge - * @group primitives - * @shortname arc from circle and points - * @drawable true - */ - arcFromCircleAndTwoPoints( - inputs: Inputs.OCCT.ArcEdgeCircleTwoPointsDto - ): Promise; - /** - * Creates an arc edge between two alpha angles on a circle - * @param inputs two angles and circle edge - * @returns OpenCascade edge - * @group primitives - * @shortname arc from circle and angles - * @drawable true - */ - arcFromCircleAndTwoAngles( - inputs: Inputs.OCCT.ArcEdgeCircleTwoAnglesDto - ): Promise; - /** - * Creates an arc edge between the point on a circle and a given alpha angle - * @param inputs point, circle edge and alpha angle - * @returns OpenCascade edge - * @group primitives - * @shortname arc from circle point and angle - * @drawable true - */ - arcFromCirclePointAndAngle( - inputs: Inputs.OCCT.ArcEdgeCirclePointAngleDto - ): Promise; - /** - * Creates OpenCascade circle edge - * @param inputs Circle parameters - * @returns OpenCascade circle edge - * @group primitives - * @shortname circle - * @drawable true - */ - createCircleEdge( - inputs: Inputs.OCCT.CircleDto - ): Promise; - /** - * Creates OpenCascade ellipse edge - * @param inputs Ellipse parameters - * @returns OpenCascade ellipse edge - * @group primitives - * @shortname ellipse - * @drawable true - */ - createEllipseEdge( - inputs: Inputs.OCCT.EllipseDto - ): Promise; - /** - * Removes internal faces for the shape - * @param inputs Shape - * @returns OpenCascade shape with no internal edges - * @group shapes - * @shortname remove internal - * @drawable true - */ - removeInternalEdges( - inputs: Inputs.OCCT.ShapeDto - ): Promise; - /** - * Creates an edge from geom curve and geom surface - * @param inputs shapes are expected to contain 2 array elements - first is geom curve, second geom surface - * @returns OpenCascade TopoDS_Edge - * @group from - * @shortname 2d curve and surface - * @drawable true - */ - makeEdgeFromGeom2dCurveAndSurface( - inputs: Inputs.OCCT.CurveAndSurfaceDto< - Inputs.OCCT.Geom2dCurvePointer, - Inputs.OCCT.GeomSurfacePointer - > - ): Promise; - /** - * Gets the edge by providing an index from the shape - * @param inputs Shape - * @returns OpenCascade edge - * @group get - * @shortname get edge - * @drawable true - */ - getEdge( - inputs: Inputs.OCCT.EdgeIndexDto - ): Promise; - /** - * Gets the edges of a shape in a list - * @param inputs Shape - * @returns OpenCascade edge list - * @group get - * @shortname get edges - * @drawable true - */ - getEdges( - inputs: Inputs.OCCT.ShapeDto - ): Promise; - /** - * Gets the edges of a wire ordered along the direction of the wire - * @param inputs wire shape - * @returns OpenCascade edge list - * @group get - * @shortname get edges along wire - * @drawable true - */ - getEdgesAlongWire( - inputs: Inputs.OCCT.ShapeDto - ): Promise; - /** - * Gets circular edges of a wire ordered along the direction of the wire - * @param inputs wire shape - * @returns OpenCascade edge list - * @group get - * @shortname get circular edges along wire - * @drawable true - */ - getCircularEdgesAlongWire( - inputs: Inputs.OCCT.ShapeDto - ): Promise; - /** - * Gets linear edges of a wire ordered along the direction of the wire - * @param inputs wire shape - * @returns OpenCascade edge list - * @group get - * @shortname get linear edges along wire - * @drawable true - */ - getLinearEdgesAlongWire( - inputs: Inputs.OCCT.ShapeDto - ): Promise; - /** - * Gets corner points of edges for a shape. There's no order guarantee here. All duplicates are removed, so when three edges form one corner, that will be represented by a single point in the list. - * @param inputs Shape that contains edges - wire, face, shell, solid - * @returns List of points - * @group get - * @shortname corners - * @drawable true - */ - getCornerPointsOfEdgesForShape( - inputs: Inputs.OCCT.ShapeDto - ): Promise; - /** - * Gets the edge length - * @param inputs edge - * @returns Length - * @group get - * @shortname edge length - * @drawable false - */ - getEdgeLength( - inputs: Inputs.OCCT.ShapeDto - ): Promise; - /** - * Gets the edge lengths of the shape - * @param inputs shape - * @returns Lengths - * @group get - * @shortname edge lengths of shape - * @drawable false - */ - getEdgeLengthsOfShape( - inputs: Inputs.OCCT.ShapeDto - ): Promise; - /** - * Gets the lengths of the edges - * @param inputs edges - * @returns Lengths - * @group get - * @shortname lengths - * @drawable false - */ - getEdgesLengths( - inputs: Inputs.OCCT.ShapesDto - ): Promise; - /** - * Gets the center of mass for the edge - * @param inputs edge - * @returns Point representing center of mass - * @group get - * @shortname center of mass - * @drawable true - */ - getEdgeCenterOfMass( - inputs: Inputs.OCCT.ShapeDto - ): Promise; - /** - * Gets the centers of mass for the edges - * @param inputs edges - * @returns Points representing centers of mass - * @group get - * @shortname centers of mass - * @drawable true - */ - getEdgesCentersOfMass( - inputs: Inputs.OCCT.ShapesDto - ): Promise; - /** - * Gets the center point of the circular edge. If edge is not circular, point will not be returned. - * @param inputs edge - * @returns Point representing center of the circular edge - * @group get circular edge - * @shortname get center of circular edge - * @drawable true - */ - getCircularEdgeCenterPoint( - inputs: Inputs.OCCT.ShapeDto - ): Promise; - /** - * Gets the radius of the circular edge. If edge is not circular, radius will not be returned. - * @param inputs edge - * @returns Radius of the circular edge - * @group get circular edge - * @shortname get radius of circular edge - * @drawable false - */ - getCircularEdgeRadius( - inputs: Inputs.OCCT.ShapeDto - ): Promise; - /** - * Gets the direction vector of the plane of the circular edge. If edge is not circular, direction vector will not be returned. - * @param inputs edge - * @returns Direction vector of the circular edge - * @group get circular edge - * @shortname get plane direction of circular edge - * @drawable true - */ - getCircularEdgePlaneDirection( - inputs: Inputs.OCCT.ShapeDto - ): Promise; - /** - * Gets the point on edge at param - * @param input edge - * @returns Point on param - * @group extract - * @shortname point at param - * @drawable true - */ - pointOnEdgeAtParam( - inputs: Inputs.OCCT.DataOnGeometryAtParamDto - ): Promise; - /** - * Gets the points on edges at param - * @param input edges - * @returns Points on param - * @group extract - * @shortname points on edges at param - * @drawable true - */ - pointsOnEdgesAtParam( - inputs: Inputs.OCCT.DataOnGeometryesAtParamDto - ): Promise; - /** - * Gets the points of all edges from a shape in separate lists for each edge - * @param inputs Shape - * @returns OpenCascade points lists - * @group extract - * @shortname edges to points - * @drawable false - */ - edgesToPoints( - inputs: Inputs.OCCT.EdgesToPointsDto - ): Promise; - /** - * Computes reversed edge from input edge - * @param inputs Shape - * @returns OpenCascade edge - * @group get - * @shortname reversed edge - * @drawable true - */ - reversedEdge( - inputs: Inputs.OCCT.ShapeDto - ): Promise; - /** - * Gets the tangent vector on edge at param - * @param input edge - * @returns Tangent vector on param - * @group extract - * @shortname tangent at param - * @drawable true - */ - tangentOnEdgeAtParam( - inputs: Inputs.OCCT.DataOnGeometryAtParamDto - ): Promise; - /** - * Gets the tangent vectors on edges at param - * @param input edges - * @returns Tangent vectors on param - * @group extract - * @shortname tangents on edges at param - * @drawable true - */ - tangentsOnEdgesAtParam( - inputs: Inputs.OCCT.DataOnGeometryesAtParamDto - ): Promise; - /** - * Gets the point on edge at length - * @param input edge and length - * @returns Point on edge - * @group extract - * @shortname point at length - * @drawable true - */ - pointOnEdgeAtLength( - inputs: Inputs.OCCT.DataOnGeometryAtLengthDto - ): Promise; - /** - * Gets the points on edges at length - * @param input edges and length - * @returns Points on edges - * @group extract - * @shortname points at length - * @drawable true - */ - pointsOnEdgesAtLength( - inputs: Inputs.OCCT.DataOnGeometryesAtLengthDto - ): Promise; - /** - * Gets the tangent vector on edge at length - * @param input edge and length - * @returns Tangent vector on edge - * @group extract - * @shortname tangent at length - * @drawable true - */ - tangentOnEdgeAtLength( - inputs: Inputs.OCCT.DataOnGeometryAtLengthDto - ): Promise; - /** - * Gets the tangent vectors on edges at length - * @param input edges and length - * @returns Tangent vectors on edges - * @group extract - * @shortname tangents at length - * @drawable true - */ - tangentsOnEdgesAtLength( - inputs: Inputs.OCCT.DataOnGeometryesAtLengthDto - ): Promise; - /** - * Gets the start point on edge - * @param input edge - * @returns Start point - * @group extract - * @shortname start point - * @drawable true - */ - startPointOnEdge( - inputs: Inputs.OCCT.ShapeDto - ): Promise; - /** - * Gets the start points on edges - * @param input edges - * @returns Start points - * @group extract - * @shortname start points - * @drawable true - */ - startPointsOnEdges( - inputs: Inputs.OCCT.ShapesDto - ): Promise; - /** - * Gets the end point on edge - * @param input edge - * @returns End point - * @group extract - * @shortname end point - * @drawable true - */ - endPointOnEdge( - inputs: Inputs.OCCT.ShapeDto - ): Promise; - /** - * Gets the end points on edges - * @param input edges - * @returns End points - * @group extract - * @shortname end points - * @drawable true - */ - endPointsOnEdges( - inputs: Inputs.OCCT.ShapesDto - ): Promise; - /** - * Divides edge by params to points - * @param input edge and division params - * @returns Points - * @group extract - * @shortname points by params - * @drawable true - */ - divideEdgeByParamsToPoints( - inputs: Inputs.OCCT.DivideDto - ): Promise; - /** - * Divides edges by params to points - * @param input edges and division params - * @returns Points - * @group extract - * @shortname points by params on edges - * @drawable false - */ - divideEdgesByParamsToPoints( - inputs: Inputs.OCCT.DivideShapesDto - ): Promise; - /** - * Divides edge by length to points - * @param input edge and division params - * @returns Points - * @group extract - * @shortname points by distance - * @drawable true - */ - divideEdgeByEqualDistanceToPoints( - inputs: Inputs.OCCT.DivideDto - ): Promise; - /** - * Divides edges by length to points - * @param input edges and division params - * @returns Points - * @group extract - * @shortname points by distance on edges - * @drawable false - */ - divideEdgesByEqualDistanceToPoints( - inputs: Inputs.OCCT.DivideShapesDto - ): Promise; - /** - * Creates lines from two given points till circle tangent locations - * @param input resulting lines - * @returns lines - * @group constraint - * @shortname tan lines from 2 pts to circle - * @drawable true - */ - constraintTanLinesFromTwoPtsToCircle( - inputs: Inputs.OCCT.ConstraintTanLinesFromTwoPtsToCircleDto - ): Promise; - /** - * Creates lines from a given point till circle tangent locations - * @param input resulting lines - * @returns lines - * @group constraint - * @shortname tan lines from pt to circle - * @drawable true - */ - constraintTanLinesFromPtToCircle( - inputs: Inputs.OCCT.ConstraintTanLinesFromPtToCircleDto - ): Promise; - /** - * Creates tangent lines between two circles. - * @param input resulting lines - * @returns lines - * @group constraint - * @shortname tan lines on two circles - * @drawable true - */ - constraintTanLinesOnTwoCircles( - inputs: Inputs.OCCT.ConstraintTanLinesOnTwoCirclesDto - ): Promise; - /** - * Creates tangent circles between two circles. - * @param input resulting circles - * @returns circles - * @group constraint - * @shortname tan circles on two circles - * @drawable true - */ - constraintTanCirclesOnTwoCircles( - inputs: Inputs.OCCT.ConstraintTanCirclesOnTwoCirclesDto - ): Promise; - /** - * Creates tangent circles between a point and a circle. - * @param input resulting circles - * @returns circles - * @group constraint - * @shortname tan circles on circle and pnt - * @drawable true - */ - constraintTanCirclesOnCircleAndPnt( - inputs: Inputs.OCCT.ConstraintTanCirclesOnCircleAndPntDto - ): Promise; - /** - * Checks whether an edge is linear - * @param input edge - * @returns boolean if is linear - * @group is - * @shortname is edge linear - * @drawable false - */ - isEdgeLinear( - inputs: Inputs.OCCT.ShapeDto - ): Promise; - /** - * Checks whether an edge is circular - * @param input edge - * @returns boolean if is circular - * @group is - * @shortname is edge circular - * @drawable false - */ - isEdgeCircular( - inputs: Inputs.OCCT.ShapeDto - ): Promise; - } - declare class OCCTFace { - private readonly occWorkerManager; - constructor(occWorkerManager: OCCTWorkerManager); - /** - * Creates face from triangle definition - * @param inputs Triangle - * @returns OpenCascade face - * @group from base - * @shortname face from triangle - * @drawable true - */ - fromBaseTriangle( - inputs: Inputs.OCCT.TriangleBaseDto - ): Promise; - /** - * Creates faces from mesh definition - * @param inputs Mesh - * @returns OpenCascade faces - * @group from base - * @shortname faces from mesh - * @drawable true - */ - fromBaseMesh( - inputs: Inputs.OCCT.MeshBaseDto - ): Promise; - /** - * Creates a faces from wires on face - * @param inputs OpenCascade wires and guiding face - * @returns OpenCascade faces - * @group from - * @shortname faces from wires on face - * @drawable true - */ - createFacesFromWiresOnFace( - inputs: Inputs.OCCT.FacesFromWiresOnFaceDto< - Inputs.OCCT.TopoDSWirePointer, - Inputs.OCCT.TopoDSFacePointer - > - ): Promise; - /** - * Creates a face from wire on face - * @param inputs OpenCascade wire shape and guiding face - * @returns OpenCascade face shape - * @group from - * @shortname face from wire on face - * @drawable true - */ - createFaceFromWireOnFace( - inputs: Inputs.OCCT.FaceFromWireOnFaceDto< - Inputs.OCCT.TopoDSWirePointer, - Inputs.OCCT.TopoDSFacePointer - > - ): Promise; - /** - * Creates a face from wire - * @param inputs OpenCascade wire shape and indication if face should be planar - * @returns OpenCascade face shape - * @group from - * @shortname face from wire - * @drawable true - */ - createFaceFromWire( - inputs: Inputs.OCCT.FaceFromWireDto - ): Promise; - /** - * Creates a face from wires. This can produce hollow faces. - * @param inputs OpenCascade wire shapes and indication if face should be planar - * @returns OpenCascade face shape - * @group from - * @shortname face from wires - * @drawable true - */ - createFaceFromWires( - inputs: Inputs.OCCT.FaceFromWiresDto - ): Promise; - /** - * Creates a face from wires on the guiding face. This can produce hollow faces. - * @param inputs OpenCascade wire shapes and indication if wire is inside the face - * @returns OpenCascade face shape - * @group from - * @shortname face from wires on face - * @drawable true - */ - createFaceFromWiresOnFace( - inputs: Inputs.OCCT.FaceFromWiresOnFaceDto< - Inputs.OCCT.TopoDSWirePointer, - Inputs.OCCT.TopoDSFacePointer - > - ): Promise; - /** - * Creates faces from wires - * @param inputs OpenCascade wire shape and indication if face should be planar - * @returns OpenCascade face shape - * @group from - * @shortname faces from wires - * @drawable true - */ - createFacesFromWires( - inputs: Inputs.OCCT.FacesFromWiresDto - ): Promise; - /** - * Creates face from multiple circle tangent wires - * @param inputs OpenCascade circle wire shapes - * @returns OpenCascade face shape - * @group from - * @shortname face from circles tan - * @drawable true - */ - createFaceFromMultipleCircleTanWires( - inputs: Inputs.OCCT.FaceFromMultipleCircleTanWiresDto - ): Promise; - /** - * Creates face from multiple circle tangent wire collections - * @param inputs OpenCascade circle wire shapes - * @returns OpenCascade face shape - * @group from - * @shortname face from multiple circle tan collections - * @drawable true - */ - createFaceFromMultipleCircleTanWireCollections( - inputs: Inputs.OCCT.FaceFromMultipleCircleTanWireCollectionsDto - ): Promise; - /** - * Creates a face from the surface - * @param inputs Face shape - * @returns OpenCascade surface - * @group from - * @shortname surface - * @drawable true - */ - faceFromSurface( - inputs: Inputs.OCCT.ShapeDto - ): Promise; - /** - * Creates a face from the surface and a wire - * @param inputs OpenCascade surface, a wire and indication wether face should be created inside or not - * @returns Face shape - * @group from - * @shortname surface and wire - * @drawable true - */ - faceFromSurfaceAndWire( - inputs: Inputs.OCCT.FaceFromSurfaceAndWireDto< - Inputs.OCCT.GeomSurfacePointer, - Inputs.OCCT.TopoDSWirePointer - > - ): Promise; - /** - * Creates OpenCascade Polygon face - * @param inputs Polygon points - * @returns OpenCascade polygon face - * @group primitives - * @shortname polygon - * @drawable true - */ - createPolygonFace( - inputs: Inputs.OCCT.PolygonDto - ): Promise; - /** - * Creates OpenCascade circle face - * @param inputs Circle parameters - * @returns OpenCascade circle face - * @group primitives - * @shortname circle - * @drawable true - */ - createCircleFace( - inputs: Inputs.OCCT.CircleDto - ): Promise; - /** - * Creates OpenCascade hexagons in grid - * @param inputs Hexagon parameters - * @returns OpenCascade hexagons in grid - * @group primitives - * @shortname hexagons in grid - * @drawable true - */ - hexagonsInGrid( - inputs: Inputs.OCCT.HexagonsInGridDto - ): Promise; - /** - * Creates OpenCascade ellipse face - * @param inputs Ellipse parameters - * @returns OpenCascade ellipse face - * @group primitives - * @shortname ellipse - * @drawable true - */ - createEllipseFace( - inputs: Inputs.OCCT.EllipseDto - ): Promise; - /** - * Creates OpenCascade square face - * @param inputs Square parameters - * @returns OpenCascade square face - * @group primitives - * @shortname square - * @drawable true - */ - createSquareFace( - inputs: Inputs.OCCT.SquareDto - ): Promise; - /** - * Creates OpenCascade rectangle face - * @param inputs rectangle parameters - * @returns OpenCascade rectangle - * @group primitives - * @shortname rectangle - * @drawable true - */ - createRectangleFace( - inputs: Inputs.OCCT.RectangleDto - ): Promise; - /** - * Creates OpenCascade L-polygon face - * @param inputs L-polygon parameters - * @returns OpenCascade L-polygon face - * @group primitives - * @shortname L-polygon - * @drawable true - */ - createLPolygonFace( - inputs: Inputs.OCCT.LPolygonDto - ): Promise; - /** - * Creates OpenCascade star face - * @param inputs Star parameters - * @returns OpenCascade star face - * @group primitives - * @shortname star - * @drawable true - */ - createStarFace( - inputs: Inputs.OCCT.StarDto - ): Promise; - /** - * Creates OpenCascade christmas tree face - * @param inputs Christmas tree parameters - * @returns OpenCascade christmas tree face - * @group primitives - * @shortname christmas tree - * @drawable true - */ - createChristmasTreeFace( - inputs: Inputs.OCCT.ChristmasTreeDto - ): Promise; - /** - * Creates OpenCascade parallelogram face - * @param inputs Parallelogram parameters - * @returns OpenCascade parallelogram face - * @group primitives - * @shortname parallelogram - * @drawable true - */ - createParallelogramFace( - inputs: Inputs.OCCT.ParallelogramDto - ): Promise; - /** - * Creates OpenCascade heart face - * @param inputs Heart parameters - * @returns OpenCascade heart face - * @group primitives - * @shortname heart - * @drawable true - */ - createHeartFace( - inputs: Inputs.OCCT.Heart2DDto - ): Promise; - /** - * Creates OpenCascade n-gon face - * @param inputs N-gon parameters - * @returns OpenCascade n-gon face - * @group primitives - * @shortname n-gon - * @drawable true - */ - createNGonFace( - inputs: Inputs.OCCT.NGonWireDto - ): Promise; - /** - * Creates OpenCascade I-beam profile face - * @param inputs I-beam profile parameters - * @returns OpenCascade I-beam profile face - * @group beam profiles - * @shortname I-beam profile - * @drawable true - */ - createIBeamProfileFace( - inputs: Inputs.OCCT.IBeamProfileDto - ): Promise; - /** - * Creates OpenCascade H-beam profile face - * @param inputs H-beam profile parameters - * @returns OpenCascade H-beam profile face - * @group beam profiles - * @shortname H-beam profile - * @drawable true - */ - createHBeamProfileFace( - inputs: Inputs.OCCT.HBeamProfileDto - ): Promise; - /** - * Creates OpenCascade T-beam profile face - * @param inputs T-beam profile parameters - * @returns OpenCascade T-beam profile face - * @group beam profiles - * @shortname T-beam profile - * @drawable true - */ - createTBeamProfileFace( - inputs: Inputs.OCCT.TBeamProfileDto - ): Promise; - /** - * Creates OpenCascade U-beam profile face - * @param inputs U-beam profile parameters - * @returns OpenCascade U-beam profile face - * @group beam profiles - * @shortname U-beam profile - * @drawable true - */ - createUBeamProfileFace( - inputs: Inputs.OCCT.UBeamProfileDto - ): Promise; - /** - * Gets the face by providing an index from the shape - * @param inputs Shape - * @returns OpenCascade face - * @group get - * @shortname face - * @drawable true - */ - getFace( - inputs: Inputs.OCCT.ShapeIndexDto - ): Promise; - /** - * Gets the faces of the shape in a list - * @param inputs Shape - * @returns OpenCascade faces array - * @group get - * @shortname faces - * @drawable true - */ - getFaces( - inputs: Inputs.OCCT.ShapeDto - ): Promise; - /** - * Computes reversed face from input face - * @param inputs Face - * @returns OpenCascade face - * @group get - * @shortname reversed - * @drawable true - */ - reversedFace( - inputs: Inputs.OCCT.ShapeDto - ): Promise; - /** - * Subdivides a face to point grid - * @param inputs Face and options for subdivision - * @returns points - * @group extract - * @shortname points - * @drawable true - */ - subdivideToPoints( - inputs: Inputs.OCCT.FaceSubdivisionDto - ): Promise; - /** - * Subdivides a face to wires - * @param inputs Face and options for subdivision - * @returns wires - * @group extract - * @shortname wires - * @drawable true - */ - subdivideToWires( - inputs: Inputs.OCCT.FaceSubdivisionToWiresDto - ): Promise; - /** - * Subdivides a face to rectangle wires - * @param inputs Face and options for subdivision - * @returns wires - * @group patterns - * @shortname rectangle wires on face - * @drawable true - */ - subdivideToRectangleWires( - inputs: Inputs.OCCT.FaceSubdivideToRectangleWiresDto - ): Promise; - /** - * Subdivides a face to rectangle wires - * @param inputs Face and options for subdivision - * @returns wires - * @group patterns - * @shortname rectangle holes on face - * @drawable true - */ - subdivideToRectangleHoles( - inputs: Inputs.OCCT.FaceSubdivideToRectangleHolesDto - ): Promise; - /** - * Subdivides a face to hexagon wires - * @param inputs Face and options for subdivision - * @returns wires - * @group patterns - * @shortname hexagon wires on face - * @drawable true - */ - subdivideToHexagonWires( - inputs: Inputs.OCCT.FaceSubdivideToHexagonWiresDto - ): Promise; - /** - * Subdivides a face to hexagon holes - * @param inputs Face and options for subdivision - * @returns faces - * @group patterns - * @shortname hexagon holes on face - * @drawable true - */ - subdivideToHexagonHoles( - inputs: Inputs.OCCT.FaceSubdivideToHexagonHolesDto - ): Promise; - /** - * Subdivides a face to point grid with shifts and removals on nth uv rows or columns - * @param inputs Face and params for subdivision - * @returns points - * @group extract - * @shortname points nth - * @drawable true - */ - subdivideToPointsControlled( - inputs: Inputs.OCCT.FaceSubdivisionControlledDto - ): Promise; - /** - * Subdivides a face to normals grid - * @param inputs Face and params for subdivision - * @returns normal vectors - * @group extract - * @shortname normals - * @drawable true - */ - subdivideToNormals( - inputs: Inputs.OCCT.FaceSubdivisionDto - ): Promise; - /** - * Subdivides a face to uv grid - * @param inputs Face and params for subdivision - * @returns uv params in array - * @group extract - * @shortname uvs - * @drawable true - */ - subdivideToUV( - inputs: Inputs.OCCT.FaceSubdivisionDto - ): Promise; - /** - * Get point on UV where U and V are described between 0 and 1. These will be mapped to real bounds. - * @param inputs Face and params for subdivision - * @returns point - * @group extract - * @shortname point on uv - * @drawable true - */ - pointOnUV( - inputs: Inputs.OCCT.DataOnUVDto - ): Promise; - /** - * Get normal on UV where U and V are described between 0 and 1. These will be mapped to real bounds. - * @param inputs Face and params for subdivision - * @returns normal vector - * @group extract - * @shortname normal on uv - * @drawable true - */ - normalOnUV( - inputs: Inputs.OCCT.DataOnUVDto - ): Promise; - /** - * Get points on UVs where U and V are described between 0 and 1 in two dimensional arrays. These will be mapped to real bounds. - * @param inputs Face and params for subdivision - * @returns points - * @group extract - * @shortname points on uvs - * @drawable true - */ - pointsOnUVs( - inputs: Inputs.OCCT.DataOnUVsDto - ): Promise; - /** - * Get normals on UVs where U and V are described between 0 and 1 in two dimensional arrays. These will be mapped to real bounds. - * @param inputs Face and params for subdivision - * @returns normals - * @group extract - * @shortname normals on uvs - * @drawable true - */ - normalsOnUVs( - inputs: Inputs.OCCT.DataOnUVsDto - ): Promise; - /** - * Subdivides a face to points along a line on parameter - * @param inputs Face and params for subdivision - * @returns points - * @group extract - * @shortname points on param - * @drawable true - */ - subdivideToPointsOnParam( - inputs: Inputs.OCCT.FaceLinearSubdivisionDto - ): Promise; - /** - * Gets the wire along the parameter on the face - * @param inputs Face and param - * @returns wire - * @group extract - * @shortname wire along param - * @drawable true - */ - wireAlongParam( - inputs: Inputs.OCCT.WireAlongParamDto - ): Promise; - /** - * Gets the wires along the parameters on the face - * @param inputs Face and params - * @returns wires - * @group extract - * @shortname wires along params - * @drawable true - */ - wiresAlongParams( - inputs: Inputs.OCCT.WiresAlongParamsDto - ): Promise; - /** - * Gets the U min bound of the face - * @param inputs OCCT Face - * @returns u min bound - * @group get - * @shortname u min - * @drawable false - */ - getUMinBound( - inputs: Inputs.OCCT.ShapeDto - ): Promise; - /** - * Gets the U max bound of the face - * @param inputs OCCT Face - * @returns u max bound - * @group get - * @shortname u max - * @drawable false - */ - getUMaxBound( - inputs: Inputs.OCCT.ShapeDto - ): Promise; - /** - * Gets the V min bound of the face - * @param inputs OCCT Face - * @returns v min bound - * @group get - * @shortname v min - * @drawable false - */ - getVMinBound( - inputs: Inputs.OCCT.ShapeDto - ): Promise; - /** - * Gets the V max bound of the face - * @param inputs OCCT Face - * @returns v max bound - * @group get - * @shortname v max - * @drawable false - */ - getVMaxBound( - inputs: Inputs.OCCT.ShapeDto - ): Promise; - /** - * Get the area of the face - * @param inputs OCCT Face - * @returns area - * @group get - * @shortname face area - * @drawable false - */ - getFaceArea( - inputs: Inputs.OCCT.ShapeDto - ): Promise; - /** - * Get the areas of the faces - * @param inputs OCCT Faces - * @returns areas - * @group get - * @shortname areas of faces - * @drawable false - */ - getFacesAreas( - inputs: Inputs.OCCT.ShapesDto - ): Promise; - /** - * Get the face center of mass point - * @param inputs OCCT Face - * @returns point - * @group get - * @shortname center of mass - * @drawable true - */ - getFaceCenterOfMass( - inputs: Inputs.OCCT.ShapeDto - ): Promise; - /** - * Get the center of mass points for faces - * @param inputs OCCT Faces - * @returns points - * @group get - * @shortname centers of mass - * @drawable true - */ - getFacesCentersOfMass( - inputs: Inputs.OCCT.ShapesDto - ): Promise; - /** - * Filters points on face - * @param inputs face and collection of points with options - * @returns filtered points - * @group filter - * @shortname filter face points - * @drawable true - */ - filterFacePoints( - inputs: Inputs.OCCT.FilterFacePointsDto - ): Promise; - /** - * Filters points on faces - * @param inputs faces and collection of points with options - * @returns filtered points - * @group filter - * @shortname filter points on faces - * @drawable true - */ - filterFacesPoints( - inputs: Inputs.OCCT.FilterFacesPointsDto - ): Promise; - } - declare class OCCTShape { - private readonly occWorkerManager; - constructor(occWorkerManager: OCCTWorkerManager); - /** - * Remove internal edges that are not connected to any face in the shape - * @param inputs shape - * @returns purged shape - * @group edit - * @shortname purge internal edges - * @drawable true - */ - purgeInternalEdges( - inputs: Inputs.OCCT.ShapeDto - ): Promise; - /** - * Unifies faces, edges in the same domain and has possibility to concatinate bsplines - * @param inputs shape - * @returns unified shape - * @group edit - * @shortname unify same domain - * @drawable true - */ - unifySameDomain( - inputs: Inputs.OCCT.UnifySameDomainDto - ): Promise; - /** - * Check if the shape is closed - * @param inputs shape - * @returns boolean answer - * @group analysis - * @shortname is closed - * @drawable false - */ - isClosed( - inputs: Inputs.OCCT.ShapeDto - ): Promise; - /** - * Check if the shape is convex - * @param inputs shape - * @returns boolean answer - * @group analysis - * @shortname is convex - * @drawable false - */ - isConvex( - inputs: Inputs.OCCT.ShapeDto - ): Promise; - /** - * Check if the shape is checked - * @param inputs shape - * @returns boolean answer - * @group analysis - * @shortname is checked - * @drawable false - */ - isChecked( - inputs: Inputs.OCCT.ShapeDto - ): Promise; - /** - * Check if the shape is free - * @param inputs shape - * @returns boolean answer - * @group analysis - * @shortname is free - * @drawable false - */ - isFree( - inputs: Inputs.OCCT.ShapeDto - ): Promise; - /** - * Check if the shape is infinite - * @param inputs shape - * @returns boolean answer - * @group analysis - * @shortname is infinite - * @drawable false - */ - isInfinite( - inputs: Inputs.OCCT.ShapeDto - ): Promise; - /** - * Check if the shape is modified - * @param inputs shape - * @returns boolean answer - * @group analysis - * @shortname is modified - * @drawable false - */ - isModified( - inputs: Inputs.OCCT.ShapeDto - ): Promise; - /** - * Check if the shape is locked - * @param inputs shape - * @returns boolean answer - * @group analysis - * @shortname is locked - * @drawable false - */ - isLocked( - inputs: Inputs.OCCT.ShapeDto - ): Promise; - /** - * Check if the shape is null - * @param inputs shape - * @returns boolean answer - * @group analysis - * @shortname is null - * @drawable false - */ - isNull( - inputs: Inputs.OCCT.ShapeDto - ): Promise; - /** - * Check if the shape is equal to other shape - * @param inputs shapes - * @returns boolean answer - * @group analysis - * @shortname is equal - * @drawable false - */ - isEqual( - inputs: Inputs.OCCT.CompareShapesDto - ): Promise; - /** - * Check if the shape is not equal to other shape - * @param inputs shapes - * @returns boolean answer - * @group analysis - * @shortname is not equal - * @drawable false - */ - isNotEqual( - inputs: Inputs.OCCT.CompareShapesDto - ): Promise; - /** - * Check if the shape is partner to other shape - * @param inputs shapes - * @returns boolean answer - * @group analysis - * @shortname is partner - * @drawable false - */ - isPartner( - inputs: Inputs.OCCT.CompareShapesDto - ): Promise; - /** - * Check if the shape is the same as the other shape - * @param inputs shapes - * @returns boolean answer - * @group analysis - * @shortname is same - * @drawable false - */ - isSame( - inputs: Inputs.OCCT.CompareShapesDto - ): Promise; - /** - * Get the shape orientation - * @param inputs shape - * @returns shape orientation - * @group analysis - * @shortname get orientation - * @drawable false - */ - getOrientation( - inputs: Inputs.OCCT.ShapeDto - ): Promise; - /** - * Get the shape type - * @param inputs shape - * @returns shape type - * @group analysis - * @shortname get shape type - * @drawable false - */ - getShapeType( - inputs: Inputs.OCCT.ShapeDto - ): Promise; - } - declare class OCCTShapes { - readonly vertex: OCCTVertex; - readonly edge: OCCTEdge; - readonly wire: OCCTWire; - readonly face: OCCTFace; - readonly shell: OCCTShell; - readonly solid: OCCTSolid; - readonly compound: OCCTCompound; - readonly shape: OCCTShape; - constructor(occWorkerManager: OCCTWorkerManager); - } - declare class OCCTShell { - private readonly occWorkerManager; - constructor(occWorkerManager: OCCTWorkerManager); - /** - * Creates a shell from faces - * @param inputs OpenCascade shell and faces - * @returns OpenCascade shell - * @group create - * @shortname sew - * @drawable true - */ - sewFaces( - inputs: Inputs.OCCT.SewDto - ): Promise; - /** - * Get shell surface area - * @param inputs shell shape - * @returns Surface area - * @group get - * @shortname area - * @drawable false - */ - getShellSurfaceArea( - inputs: Inputs.OCCT.ShapeDto - ): Promise; - } - declare class OCCTSolid { - private readonly occWorkerManager; - constructor(occWorkerManager: OCCTWorkerManager); - /** - * Creates Solid From shell that must be closed - * @param inputs Closed shell to make into solid - * @returns OpenCascade Solid - * @group from - * @shortname solid from closed shell - * @drawable true - */ - fromClosedShell( - inputs: Inputs.OCCT.ShapeDto - ): Promise; - /** - * Creates OpenCascade Box - * @param inputs Box size and center - * @returns OpenCascade Box - * @group primitives - * @shortname box - * @drawable true - */ - createBox( - inputs: Inputs.OCCT.BoxDto - ): Promise; - /** - * Creates OpenCascade Cube - * @param inputs Cube size and center - * @returns OpenCascade Cube - * @group primitives - * @shortname cube - * @drawable true - */ - createCube( - inputs: Inputs.OCCT.CubeDto - ): Promise; - /** - * Creates OpenCascade Box from corner - * @param inputs Box size and corner coordinates - * @returns OpenCascade Box - * @group primitives - * @shortname box corner - * @drawable true - */ - createBoxFromCorner( - inputs: Inputs.OCCT.BoxFromCornerDto - ): Promise; - /** - * Creates OpenCascade Cylinder - * @param inputs Cylinder parameters - * @returns OpenCascade Cylinder - * @group primitives - * @shortname cylinder - * @drawable true - */ - createCylinder( - inputs: Inputs.OCCT.CylinderDto - ): Promise; - /** - * Creates OpenCascade Cylinders on simple bit by bit lines represented by two points - * @param inputs Cylinder parameters - * @returns OpenCascade Cylinder - * @group primitives - * @shortname cylinders on lines - * @drawable true - */ - createCylindersOnLines( - inputs: Inputs.OCCT.CylindersOnLinesDto - ): Promise; - /** - * Creates OpenCascade Sphere - * @param inputs Sphere radius and center - * @returns OpenCascade Sphere - * @group primitives - * @shortname sphere - * @drawable true - */ - createSphere( - inputs: Inputs.OCCT.SphereDto - ): Promise; - /** - * Creates OpenCascade Cone - * @param inputs Cone parameters - * @returns OpenCascade cone shape - * @group primitives - * @shortname cone - * @drawable true - */ - createCone( - inputs: Inputs.OCCT.ConeDto - ): Promise; - /** - * Creates OpenCascade star solid - * @param inputs Star solid parameters - * @returns OpenCascade star solid - * @group primitives - * @shortname star - * @drawable true - */ - createStarSolid( - inputs: Inputs.OCCT.StarSolidDto - ): Promise; - /** - * Creates OpenCascade n-gon solid - * @param inputs N-gon solid parameters - * @returns OpenCascade n-gon solid - * @group primitives - * @shortname n-gon - * @drawable true - */ - createNGonSolid( - inputs: Inputs.OCCT.NGonSolidDto - ): Promise; - /** - * Creates OpenCascade parallelogram solid - * @param inputs Parallelogram solid parameters - * @returns OpenCascade parallelogram solid - * @group primitives - * @shortname parallelogram - * @drawable true - */ - createParallelogramSolid( - inputs: Inputs.OCCT.ParallelogramSolidDto - ): Promise; - /** - * Creates OpenCascade heart solid - * @param inputs Heart solid parameters - * @returns OpenCascade heart solid - * @group primitives - * @shortname heart - * @drawable true - */ - createHeartSolid( - inputs: Inputs.OCCT.HeartSolidDto - ): Promise; - /** - * Creates OpenCascade christmas tree solid - * @param inputs Christmas tree solid parameters - * @returns OpenCascade christmas tree solid - * @group primitives - * @shortname christmas tree - * @drawable true - */ - createChristmasTreeSolid( - inputs: Inputs.OCCT.ChristmasTreeSolidDto - ): Promise; - /** - * Creates OpenCascade L-polygon solid - * @param inputs L-polygon solid parameters - * @returns OpenCascade L-polygon solid - * @group primitives - * @shortname L-polygon - * @drawable true - */ - createLPolygonSolid( - inputs: Inputs.OCCT.LPolygonSolidDto - ): Promise; - /** - * Creates OpenCascade I-beam profile solid - * @param inputs I-beam profile solid parameters - * @returns OpenCascade I-beam profile solid - * @group beam - * @shortname I-beam profile - * @drawable true - */ - createIBeamProfileSolid( - inputs: Inputs.OCCT.IBeamProfileSolidDto - ): Promise; - /** - * Creates OpenCascade H-beam profile solid - * @param inputs H-beam profile solid parameters - * @returns OpenCascade H-beam profile solid - * @group beam - * @shortname H-beam profile - * @drawable true - */ - createHBeamProfileSolid( - inputs: Inputs.OCCT.HBeamProfileSolidDto - ): Promise; - /** - * Creates OpenCascade T-beam profile solid - * @param inputs T-beam profile solid parameters - * @returns OpenCascade T-beam profile solid - * @group beam - * @shortname T-beam profile - * @drawable true - */ - createTBeamProfileSolid( - inputs: Inputs.OCCT.TBeamProfileSolidDto - ): Promise; - /** - * Creates OpenCascade U-beam profile solid - * @param inputs U-beam profile solid parameters - * @returns OpenCascade U-beam profile solid - * @group beam - * @shortname U-beam profile - * @drawable true - */ - createUBeamProfileSolid( - inputs: Inputs.OCCT.UBeamProfileSolidDto - ): Promise; - /** - * Get solid surface area - * @param inputs Closed solid shape - * @returns Surface area - * @group get - * @shortname area - * @drawable false - */ - getSolidSurfaceArea( - inputs: Inputs.OCCT.ShapeDto - ): Promise; - /** - * Get solid volume - * @param inputs Closed solid shape - * @returns volume - * @group get - * @shortname volume - * @drawable false - */ - getSolidVolume( - inputs: Inputs.OCCT.ShapeDto - ): Promise; - /** - * Get solids volumes - * @param inputs Closed solid shapes - * @returns volumes - * @group get - * @shortname volumes - * @drawable false - */ - getSolidsVolumes( - inputs: Inputs.OCCT.ShapesDto - ): Promise; - /** - * Get solid center of mass - * @param inputs Closed solid shape - * @returns center of mass point - * @group get - * @shortname center of mass - * @drawable true - */ - getSolidCenterOfMass( - inputs: Inputs.OCCT.ShapeDto - ): Promise; - /** - * Get centers of mass of solids - * @param inputs Closed solid shapes - * @returns Points indicating centers of mass - * @group get - * @shortname centers of mass - * @drawable true - */ - getSolidsCentersOfMass( - inputs: Inputs.OCCT.ShapesDto - ): Promise; - /** - * Gets the solids of the shape in a list - * @param inputs Shape - * @returns OpenCascade solids array - * @group get - * @shortname solids - * @drawable true - */ - getSolids( - inputs: Inputs.OCCT.ShapeDto - ): Promise; - /** - * Filters collection of points based on relationship with the solid. You can choose whether to output in, on or out points. - * @param inputs OpenCascade solid and collection of points with options - * @returns filtered points - * @group filter - * @shortname filter solid points - * @drawable true - */ - filterSolidPoints( - inputs: Inputs.OCCT.FilterSolidPointsDto - ): Promise; - } - declare class OCCTVertex { - private readonly occWorkerManager; - constructor(occWorkerManager: OCCTWorkerManager); - /** - * Creates vertex shape from x y z coordinates - * @param inputs x y z coordinates - * @returns OpenCascade vertex - * @group from - * @shortname vertex from xyz - * @drawable true - */ - vertexFromXYZ( - inputs: Inputs.OCCT.XYZDto - ): Promise; - /** - * Creates vertex shape from point - * @param inputs a point - * @returns OpenCascade vertex - * @group from - * @shortname vertex from point - * @drawable true - */ - vertexFromPoint( - inputs: Inputs.OCCT.PointDto - ): Promise; - /** - * Creates vertices from points - * @param inputs a point - * @returns OpenCascade vertices - * @group from - * @shortname vertices from points - * @drawable true - */ - verticesFromPoints( - inputs: Inputs.OCCT.PointsDto - ): Promise; - /** - * Creates compound shape containing multiple vertices. This simply speeds up rendering and allows to apply occt transformations easily on vertex groups. - * @param inputs points - * @returns OpenCascade vertices as compound shape - * @group from - * @shortname compound vertices from points - * @drawable true - */ - verticesCompoundFromPoints( - inputs: Inputs.OCCT.PointsDto - ): Promise; - /** - * Get all vertices in the list of a shape - * @param inputs a shape - * @returns OpenCascade vertices - * @group get - * @shortname get vertices from shape - * @drawable true - */ - getVertices( - inputs: Inputs.OCCT.ShapeDto - ): Promise; - /** - * Get all vertices in the list of a shape as points - * @param inputs a shape - * @returns Points - * @group get - * @shortname get vertices as points - * @drawable true - */ - getVerticesAsPoints( - inputs: Inputs.OCCT.ShapeDto - ): Promise; - /** - * Transforms vertices to points - * @param inputs a vertex shapes - * @returns Points - * @group transform - * @shortname vertices to points - * @drawable true - */ - verticesToPoints( - inputs: Inputs.OCCT.ShapesDto - ): Promise; - /** - * Transform vertex to point - * @param inputs a vertex shape - * @returns Point - * @group transform - * @shortname vertex to point - * @drawable true - */ - vertexToPoint( - inputs: Inputs.OCCT.ShapesDto - ): Promise; - /** - * @param inputs points, shape and direction that includes the length - * @returns Points - * @group place - * @shortname project points - * @drawable true - */ - projectPoints( - inputs: Inputs.OCCT.ProjectPointsOnShapeDto - ): Promise; - } - declare class OCCTWire { - private readonly occWorkerManager; - constructor(occWorkerManager: OCCTWorkerManager); - /** - * Creates linear wire from base line format {start: Point3, end: Point3} - * @param inputs base line - * @returns OpenCascade wire - * @group from base - * @shortname wire from base line - * @drawable true - */ - fromBaseLine( - inputs: Inputs.OCCT.LineBaseDto - ): Promise; - /** - * Creates linear wires from base lines format {start: Point3, end: Point3}[] - * @param inputs base lines - * @returns OpenCascade wires - * @group from base - * @shortname wires from base lines - * @drawable true - */ - fromBaseLines( - inputs: Inputs.OCCT.LineBaseDto - ): Promise; - /** - * Creates linear wire from base segment format [Point3, Point3] - * @param inputs base segment - * @returns OpenCascade wire - * @group from base - * @shortname wire from base segment - * @drawable true - */ - fromBaseSegment( - inputs: Inputs.OCCT.SegmentBaseDto - ): Promise; - /** - * Creates linear wires from base segments format [Point3, Point3][] - * @param inputs base segments - * @returns OpenCascade wires - * @group from base - * @shortname wires from base segments - * @drawable true - */ - fromBaseSegments( - inputs: Inputs.OCCT.SegmentsBaseDto - ): Promise; - /** - * Creates wire from collection of points - * @param inputs Points - * @returns OpenCascade wire - * @group from base - * @shortname wire from points - * @drawable true - */ - fromPoints( - inputs: Inputs.OCCT.PointsDto - ): Promise; - /** - * Creates wire from polyline definition - * @param inputs Polyline - * @returns OpenCascade wire - * @group from base - * @shortname wire from polyline - * @drawable true - */ - fromBasePolyline( - inputs: Inputs.OCCT.PolylineBaseDto - ): Promise; - /** - * Creates wire from triangle definition - * @param inputs Triangle - * @returns OpenCascade wire - * @group from base - * @shortname wire from triangle - * @drawable true - */ - fromBaseTriangle( - inputs: Inputs.OCCT.TriangleBaseDto - ): Promise; - /** - * Creates wires from mesh definition - * @param inputs Mesh - * @returns OpenCascade wires - * @group from base - * @shortname wires from mesh - * @drawable true - */ - fromBaseMesh( - inputs: Inputs.OCCT.MeshBaseDto - ): Promise; - /** - * Creates OpenCascade Polygon wire - * @param inputs Polygon points - * @returns OpenCascade polygon wire shape - * @group via points - * @shortname polygon - * @drawable true - */ - createPolygonWire( - inputs: Inputs.OCCT.PolygonDto - ): Promise; - /** - * Creates OpenCascade Polygons - * @param inputs Polygon points - * @returns OpenCascade polygon wires shapes - * @group multiple - * @shortname polygons - * @drawable true - */ - createPolygons( - inputs: Inputs.OCCT.PolygonsDto - ): Promise< - Inputs.OCCT.TopoDSWirePointer[] | Inputs.OCCT.TopoDSCompoundPointer - >; - /** - * Creates OpenCascade line wire - * @param inputs line start and end point - * @returns OpenCascade line wire shape - * @group via points - * @shortname line - * @drawable true - */ - createLineWire( - inputs: Inputs.OCCT.LineDto - ): Promise; - /** - * Creates OpenCascade line wire with extensions - * @param inputs line start and end point and extension lengths for both start and end - * @returns OpenCascade line wire shape - * @group via points - * @shortname line with extensions - * @drawable true - */ - createLineWireWithExtensions( - inputs: Inputs.OCCT.LineWithExtensionsDto - ): Promise; - /** - * Creates OpenCascade lines - * @param inputs lines with start and end points - * @returns OpenCascade line wire shapes - * @group multiple - * @shortname lines - * @drawable true - */ - createLines( - inputs: Inputs.OCCT.LinesDto - ): Promise< - Inputs.OCCT.TopoDSWirePointer[] | Inputs.OCCT.TopoDSCompoundPointer - >; - /** - * Splits a wire on a set of given points - * @param inputs wire and a list of points - * @returns OpenCascade line wire shapes - * @group extract - * @shortname split on points - * @drawable true - */ - splitOnPoints( - inputs: Inputs.OCCT.SplitWireOnPointsDto - ): Promise; - /** - * Transform shape wires to points ordered in lists. - * This also removes duplicated points between start end end points of - * consecutive edges on the wire - * @param inputs OCCT shape - * @returns point lists for wires - * @group extract - * @shortname wires to points - * @drawable false - */ - wiresToPoints( - inputs: Inputs.OCCT.WiresToPointsDto - ): Promise; - /** - * Creates OpenCascade polyline wire - * @param inputs polyline points - * @returns OpenCascade polyline wire shape - * @group via points - * @shortname polyline - * @drawable true - */ - createPolylineWire( - inputs: Inputs.OCCT.PolylineDto - ): Promise; - /** - * Creates zig zag between two wires - * @param inputs two wires and zig zag parameters - * @returns OpenCascade polyline wire shape - * @group via wires - * @shortname zig zag between two wires - * @drawable true - */ - createZigZagBetweenTwoWires( - inputs: Inputs.OCCT.ZigZagBetweenTwoWiresDto - ): Promise; - /** - * Creates a tangent wire enclosing two planar circles - * @param inputs two circle wires and tolerance - * @returns OpenCascade wire shape - * @group via wires - * @shortname tangent wire from two circles - * @drawable true - */ - createWireFromTwoCirclesTan( - inputs: Inputs.OCCT.WireFromTwoCirclesTanDto - ): Promise; - /** - * Creates OpenCascade polyline wires - * @param inputs polylines - * @returns OpenCascade polyline wire shapes - * @group multiple - * @shortname polylines - * @drawable true - */ - createPolylines( - inputs: Inputs.OCCT.PolylinesDto - ): Promise< - Inputs.OCCT.TopoDSWirePointer[] | Inputs.OCCT.TopoDSCompoundPointer - >; - /** - * Creates OpenCascade Bezier wire - * @param inputs Points through which to make bezier curve - * @returns OpenCascade Bezier wire - * @group via points - * @shortname bezier - * @drawable true - */ - createBezier( - inputs: Inputs.OCCT.BezierDto - ): Promise; - /** - * Creates OpenCascade Bezier wire with weights - * @param inputs Points through which to make bezier curve and weights on those points which are used to control the curve - * @returns OpenCascade Bezier wire - * @group via points - * @shortname bezier weights - * @drawable true - */ - createBezierWeights( - inputs: Inputs.OCCT.BezierWeightsDto - ): Promise; - /** - * Creates OpenCascade Bezier wires - * @param inputs Multiple bezier wire definitions - * @returns OpenCascade Bezier wires - * @group multiple - * @shortname bezier wires - * @drawable true - */ - createBezierWires( - inputs: Inputs.OCCT.BezierWiresDto - ): Promise< - Inputs.OCCT.TopoDSWirePointer[] | Inputs.OCCT.TopoDSCompoundPointer - >; - /** - * Creates OpenCascade BSpline wire from points. This method can be used to create nicely shaped (periodic) loops. - * @param inputs Points through which to make the curve, periodic bool and tolerance - * @returns OpenCascade BSpline wire - * @group via points - * @shortname interpolate - * @drawable true - */ - interpolatePoints( - inputs: Inputs.OCCT.InterpolationDto - ): Promise; - /** - * Creates OpenCascade multiple interpolated wires - * @param inputs Interpolated wire definitions - * @returns OpenCascade BSpline wires - * @group multiple - * @shortname interpolate wires - * @drawable true - */ - interpolateWires( - inputs: Inputs.OCCT.InterpolateWiresDto - ): Promise< - Inputs.OCCT.TopoDSWirePointer[] | Inputs.OCCT.TopoDSCompoundPointer - >; - /** - * Creates OpenCascade BSPline wire - * @param inputs Points through which to make BSpline - * @returns OpenCascade BSpline wire - * @group via points - * @shortname bspline - * @drawable true - */ - createBSpline( - inputs: Inputs.OCCT.BSplineDto - ): Promise; - /** - * Creates OpenCascade BSPline wires - * @param inputs Points through which to make BSpline - * @returns OpenCascade BSpline wires - * @group multiple - * @shortname bsplines - * @drawable true - */ - createBSplines( - inputs: Inputs.OCCT.BSplinesDto - ): Promise< - Inputs.OCCT.TopoDSWirePointer[] | Inputs.OCCT.TopoDSCompoundPointer - >; - /** - * Combines OpenCascade edges and wires into a single wire - * @param inputs List of shapes of edges and wires - * @returns OpenCascade wire - * @group build - * @shortname combine - * @drawable true - */ - combineEdgesAndWiresIntoAWire( - inputs: Inputs.OCCT.ShapesDto< - Inputs.OCCT.TopoDSWirePointer | Inputs.OCCT.TopoDSEdgePointer - > - ): Promise; - /** - * Creates wire from edge - * @param inputs An edge to transform into a wire - * @returns OpenCascade wire - * @group build - * @shortname wire from edge - * @drawable true - */ - createWireFromEdge( - inputs: Inputs.OCCT.ShapeDto - ): Promise; - /** - * Adds OpenCascade edges and wires into another wire - * @param inputs List of shapes of edges and wires and a single shape wire to which edges need to be added - * @returns OpenCascade wire - * @group build - * @shortname extend - * @drawable true - */ - addEdgesAndWiresToWire( - inputs: Inputs.OCCT.ShapeShapesDto< - Inputs.OCCT.TopoDSWirePointer, - Inputs.OCCT.TopoDSWirePointer | Inputs.OCCT.TopoDSEdgePointer - > - ): Promise; - /** - * Divides OpenCascade wire to points blindly following its parametric space - * @param inputs Describes into how many points should the wire be divided - * @returns Points on wire - * @group extract - * @shortname points by params - * @drawable true - */ - divideWireByParamsToPoints( - inputs: Inputs.OCCT.DivideDto - ): Promise; - /** - * Divides OpenCascade wires to points blindly following its parametric space - * @param inputs Describes into how many points should the wires be divided - * @returns Points on wire - * @group extract from wires - * @shortname points by params - * @drawable true - */ - divideWiresByParamsToPoints( - inputs: Inputs.OCCT.DivideShapesDto - ): Promise; - /** - * Divides OpenCascade wire to equal distance points - * @param inputs Describes into how many points should the wire be divided - * @returns Points on wire - * @group extract - * @shortname points by distance - * @drawable true - */ - divideWireByEqualDistanceToPoints( - inputs: Inputs.OCCT.DivideDto - ): Promise; - /** - * Divides OpenCascade wires to equal distance points - * @param inputs Describes into how many points should the wires be divided - * @returns Points on wire - * @group extract from wires - * @shortname points by distance - * @drawable true - */ - divideWiresByEqualDistanceToPoints( - inputs: Inputs.OCCT.DivideShapesDto - ): Promise; - /** - * Evaluates point on a wire at parameter value between 0 and 1, being start and end points - * @param inputs Wire shape and parameter - * @returns Point as array of 3 numbers - * @group extract - * @shortname point at param - * @drawable true - */ - pointOnWireAtParam( - inputs: Inputs.OCCT.DataOnGeometryAtParamDto - ): Promise; - /** - * Evaluates point on a wire at certain length - * @param inputs Wire shape and length value - * @returns Point as array of 3 numbers - * @group extract - * @shortname point at length - * @drawable true - */ - pointOnWireAtLength( - inputs: Inputs.OCCT.DataOnGeometryAtLengthDto - ): Promise; - /** - * Evaluates points on a wire at certain lengths - * @param inputs Wire shape and lengths array - * @returns Points as arrays of 3 numbers - * @group extract - * @shortname points at lengths - * @drawable true - */ - pointsOnWireAtLengths( - inputs: Inputs.OCCT.DataOnGeometryAtLengthsDto - ): Promise; - /** - * Evaluates points on a wire at equal length - * @param inputs Wire shape and length - * @returns Points as arrays of 3 numbers - * @group extract - * @shortname points at equal length - * @drawable true - */ - pointsOnWireAtEqualLength( - inputs: Inputs.OCCT.PointsOnWireAtEqualLengthDto - ): Promise; - /** - * Evaluates points on a wire at pattern of lengths - * @param inputs Wire shape and lengths pattern - * @returns Points as arrays of 3 numbers - * @group extract - * @shortname points at pattern of lengths - * @drawable true - */ - pointsOnWireAtPatternOfLengths( - inputs: Inputs.OCCT.PointsOnWireAtPatternOfLengthsDto - ): Promise; - /** - * Evaluates tangent vector on a wire at parameter value between 0 and 1, being start and end points - * @param inputs Wire shape and parameter - * @returns Tangent vector as array of 3 numbers - * @group extract - * @shortname tangent at param - * @drawable true - */ - tangentOnWireAtParam( - inputs: Inputs.OCCT.DataOnGeometryAtParamDto - ): Promise; - /** - * Evaluates tangent vector on a wire at certain length - * @param inputs Wire shape and length value - * @returns Tangent vector as array of 3 numbers - * @group extract - * @shortname tangent at length - * @drawable true - */ - tangentOnWireAtLength( - inputs: Inputs.OCCT.DataOnGeometryAtLengthDto - ): Promise; - /** - * Computes 3 derivative vectors of a curve at a given length - * @param inputs Wire shape and length value - * @returns Three arrays of vectors. Each vector represents derivatives in order - first, second, third - * @group extract - * @shortname derivatives at length - * @drawable false - */ - derivativesOnWireAtLength( - inputs: Inputs.OCCT.DataOnGeometryAtLengthDto - ): Promise<[Inputs.Base.Vector3, Inputs.Base.Vector3, Inputs.Base.Vector3]>; - /** - * Computes 3 derivative vectors of a curve on parameter between 0 and 1. - * @param inputs Wire shape and parameter value - * @returns Three arrays of vectors. Each vector represents derivatives in order - first, second, third - * @group extract - * @shortname derivatives at param - * @drawable false - */ - derivativesOnWireAtParam( - inputs: Inputs.OCCT.DataOnGeometryAtParamDto - ): Promise<[Inputs.Base.Vector3, Inputs.Base.Vector3, Inputs.Base.Vector3]>; - /** - * Computes the start point on the wire at param 0 - * @param inputs Wire shape - * @returns The start point on wire - * @group extract - * @shortname start point - * @drawable true - */ - startPointOnWire( - inputs: Inputs.OCCT.ShapeDto - ): Promise; - /** - * Computes the middle point on the wire at param 0.5 - * @param inputs Wire shape - * @returns The middle point on wire - * @group extract - * @shortname mid point - * @drawable true - */ - midPointOnWire( - inputs: Inputs.OCCT.ShapeDto - ): Promise; - /** - * Computes the end point on the wire at param 1 - * @param inputs Wire shape - * @returns The length of the wire - * @group extract - * @shortname end point - * @drawable true - */ - endPointOnWire( - inputs: Inputs.OCCT.ShapeDto - ): Promise; - /** - * Creates OpenCascade circle wire - * @param inputs Circle parameters - * @returns OpenCascade circle wire - * @group primitives - * @shortname circle - * @drawable true - */ - createCircleWire( - inputs: Inputs.OCCT.CircleDto - ): Promise; - /** - * Creates OpenCascade hexagon wires in grid - * @param inputs grid parameters - * @returns OpenCascade hexagon wires - * @group primitives - * @shortname hegagons in grid - * @drawable true - */ - hexagonsInGrid( - inputs: Inputs.OCCT.HexagonsInGridDto - ): Promise; - /** - * Creates OpenCascade square wire - * @param inputs Square parameters - * @returns OpenCascade square wire - * @group primitives - * @shortname square - * @drawable true - */ - createSquareWire( - inputs: Inputs.OCCT.SquareDto - ): Promise; - /** - * Creates OpenCascade star wire - * @param inputs star parameters - * @returns OpenCascade star wire - * @group primitives - * @shortname star - * @drawable true - */ - createStarWire( - inputs: Inputs.OCCT.StarDto - ): Promise; - /** - * Creates Christmas tree wire - * @param inputs christmas tree parameters - * @returns OpenCascade christmas tree wire - * @group primitives - * @shortname christmas tree - * @drawable true - */ - createChristmasTreeWire( - inputs: Inputs.OCCT.ChristmasTreeDto - ): Promise; - /** - * Creates OpenCascade n-gon wire - * @param inputs ngon parameters - * @returns OpenCascade ngon wire - * @group primitives - * @shortname n-gon - * @drawable true - */ - createNGonWire( - inputs: Inputs.OCCT.NGonWireDto - ): Promise; - /** - * Creates n parallelogram wire - * @param inputs parallelogram parameters - * @returns OpenCascade parallelogram wire - * @group primitives - * @shortname parallelogram - * @drawable true - */ - createParallelogramWire( - inputs: Inputs.OCCT.ParallelogramDto - ): Promise; - /** - * Creates a heart wire - * @param inputs heart parameters - * @returns OpenCascade heart shaped wire - * @group primitives - * @shortname heart - * @drawable true - */ - createHeartWire( - inputs: Inputs.OCCT.Heart2DDto - ): Promise; - /** - * Creates OpenCascade rectangle wire - * @param inputs rectangle parameters - * @returns OpenCascade rectangle - * @group primitives - * @shortname rectangle - * @drawable true - */ - createRectangleWire( - inputs: Inputs.OCCT.RectangleDto - ): Promise; - /** - * Creates OpenCascade L polygon wire - * @param inputs L polygon parameters - * @returns OpenCascade polygon - * @group primitives - * @shortname L polygon - * @drawable true - */ - createLPolygonWire( - inputs: Inputs.OCCT.LPolygonDto - ): Promise; - /** - * Creates OpenCascade I-beam profile wire - * @param inputs I-beam profile parameters - * @returns OpenCascade I-beam profile wire - * @group beam profiles - * @shortname I-beam profile - * @drawable true - */ - createIBeamProfileWire( - inputs: Inputs.OCCT.IBeamProfileDto - ): Promise; - /** - * Creates OpenCascade H-beam profile wire - * @param inputs H-beam profile parameters - * @returns OpenCascade H-beam profile wire - * @group beam profiles - * @shortname H-beam profile - * @drawable true - */ - createHBeamProfileWire( - inputs: Inputs.OCCT.HBeamProfileDto - ): Promise; - /** - * Creates OpenCascade T-beam profile wire - * @param inputs T-beam profile parameters - * @returns OpenCascade T-beam profile wire - * @group beam profiles - * @shortname T-beam profile - * @drawable true - */ - createTBeamProfileWire( - inputs: Inputs.OCCT.TBeamProfileDto - ): Promise; - /** - * Creates OpenCascade U-beam profile wire - * @param inputs U-beam profile parameters - * @returns OpenCascade U-beam profile wire - * @group beam profiles - * @shortname U-beam profile - * @drawable true - */ - createUBeamProfileWire( - inputs: Inputs.OCCT.UBeamProfileDto - ): Promise; - /** - * Creates OpenCascade ellipse wire - * @param inputs Ellipse parameters - * @returns OpenCascade ellipse wire - * @group primitives - * @shortname ellipse - * @drawable true - */ - createEllipseWire( - inputs: Inputs.OCCT.EllipseDto - ): Promise; - /** - * Creates OpenCascade text wires based on simplex font created by Dr. A. V. Hershey - * @param inputs Text parameters - * @returns OpenCascade text wires - * @group primitives - * @shortname text wires - * @drawable true - */ - textWires( - inputs: Inputs.OCCT.TextWiresDto - ): Promise; - /** - * Creates OpenCascade compound out of text wires and returns additional information based on simplex font created by Dr. A. V. Hershey - * @param inputs Text parameters - * @returns OpenCascade text compound derivative data - * @group primitives - * @shortname text wires deriv - * @drawable true - */ - textWiresWithData( - inputs: Inputs.OCCT.TextWiresDto - ): Promise>; - /** - * Gets the wire by providing an index from the shape - * @param inputs Shape - * @returns OpenCascade wire - * @group get - * @shortname wire - * @drawable true - */ - getWire( - inputs: Inputs.OCCT.ShapeIndexDto - ): Promise; - /** - * Gets all the wires from the shape - * @param inputs Shape - * @returns OpenCascade wires - * @group get - * @shortname wires - * @drawable true - */ - getWires( - inputs: Inputs.OCCT.ShapeDto - ): Promise; - /** - * Get the wire center of mass point - * @param inputs OCCT Wire - * @returns point - * @group get - * @shortname center of mass - * @drawable true - */ - getWireCenterOfMass( - inputs: Inputs.OCCT.ShapeDto - ): Promise; - /** - * Get the wires centers of mass point - * @param inputs OCCT Wires - * @returns points - * @group get - * @shortname centers of mass - * @drawable true - */ - getWiresCentersOfMass( - inputs: Inputs.OCCT.ShapesDto - ): Promise; - /** - * Computes reversed wire from input wire - * @param inputs Shape - * @returns OpenCascade wire - * @group get - * @shortname reversed - * @drawable true - */ - reversedWire( - inputs: Inputs.OCCT.ShapeDto - ): Promise; - /** - * Computes reversed wire by reversing all edges and combining them into a new wire - * @param inputs Shape - * @returns OpenCascade wire - * @group get - * @shortname reversed wire by rev edges - * @drawable true - */ - reversedWireFromReversedEdges( - inputs: Inputs.OCCT.ShapeDto - ): Promise; - /** - * Checks whether wire is closed - * @param inputs wire - * @returns boolean - * @group get - * @shortname is wire closed - * @drawable false - */ - isWireClosed( - inputs: Inputs.OCCT.ShapeDto - ): Promise; - /** - * Gets the wire length - * @param inputs wire - * @returns Length - * @group get - * @shortname length - * @drawable false - */ - getWireLength( - inputs: Inputs.OCCT.ShapeDto - ): Promise; - /** - * Gets the lengths of wires - * @param inputs wires - * @returns Lengths - * @group get - * @shortname lengths - * @drawable false - */ - getWiresLengths( - inputs: Inputs.OCCT.ShapesDto - ): Promise; - /** - * Places a wire on the face by mapping it's 2d coordinates to UV space. Wire must be positioned on the ground XZ plane for this to work. - * @param inputs two shapes - first a wire and second a face - * @returns OpenCascade wire - * @group place - * @shortname wire on face - * @drawable true - */ - placeWireOnFace( - inputs: Inputs.OCCT.WireOnFaceDto< - Inputs.OCCT.TopoDSWirePointer, - Inputs.OCCT.TopoDSFacePointer - > - ): Promise; - /** - * Places multiple wires on the face by mapping it's 2d coordinates to UV space. Wires must be positioned on the ground XZ plane for this to work. - * @param inputs a face and a list of wires - * @returns OpenCascade wires - * @group place - * @shortname wires on face - * @drawable true - */ - placeWiresOnFace( - inputs: Inputs.OCCT.WiresOnFaceDto< - Inputs.OCCT.TopoDSWirePointer, - Inputs.OCCT.TopoDSFacePointer - > - ): Promise; - /** - * Closes the open wire with additional straight edge joining start and end points - * @param inputs Shape - * @returns OpenCascade wire - * @group edit - * @shortname close open wire - * @drawable true - */ - closeOpenWire( - inputs: Inputs.OCCT.ShapeDto - ): Promise; - /** - * Project wire on the shape - * @param inputs wire and shape - * @returns OpenCascade compound - * @group place - * @shortname project - * @drawable true - */ - project( - inputs: Inputs.OCCT.ProjectWireDto< - Inputs.OCCT.TopoDSWirePointer, - Inputs.OCCT.TopoDSShapePointer - > - ): Promise; - /** - * Project multiple wires on the shape - * @param inputs wire and shape - * @returns OpenCascade compound - * @group place - * @shortname project wires - * @drawable true - */ - projectWires( - inputs: Inputs.OCCT.ProjectWiresDto< - Inputs.OCCT.TopoDSWirePointer, - Inputs.OCCT.TopoDSShapePointer - > - ): Promise; - } - declare class OCCTTransforms { - private readonly occWorkerManager; - constructor(occWorkerManager: OCCTWorkerManager); - /** - * Transforms the shape - * @param inputs Transformation description - * @returns OpenCascade shape - * @group on single shape - * @shortname transform - * @drawable true - */ - transform( - inputs: Inputs.OCCT.TransformDto - ): Promise; - /** - * Rotate the shape - * @param inputs Rotation description - * @returns OpenCascade shape - * @group on single shape - * @shortname rotate - * @drawable true - */ - rotate( - inputs: Inputs.OCCT.RotateDto - ): Promise; - /** - * Rotate the shape around the provided center - * @param inputs Rotation description - * @returns OpenCascade shape - * @group on single shape - * @shortname rotate around center - * @drawable true - */ - rotateAroundCenter( - inputs: Inputs.OCCT.RotateAroundCenterDto - ): Promise; - /** - * Align the shape - * @param inputs Align description - * @returns OpenCascade shape - * @group on single shape - * @shortname align - * @drawable true - */ - align( - inputs: Inputs.OCCT.AlignDto - ): Promise; - /** - * Align the shape with normal and axis - * @param inputs Align description - * @returns OpenCascade shape - * @group on single shape - * @shortname align normal and axis - * @drawable true - */ - alignNormAndAxis( - inputs: Inputs.OCCT.AlignNormAndAxisDto - ): Promise; - /** - * Align and translates the shape - * @param inputs Align description - * @returns OpenCascade shape - * @group on single shape - * @shortname align and translate - * @drawable true - */ - alignAndTranslate( - inputs: Inputs.OCCT.AlignAndTranslateDto - ): Promise; - /** - * Translates the shape - * @param inputs Translation description - * @returns OpenCascade shape - * @group on single shape - * @shortname translate - * @drawable true - */ - translate( - inputs: Inputs.OCCT.TranslateDto - ): Promise; - /** - * Scales the shape - * @param inputs Scale description - * @returns OpenCascade shape - * @group on single shape - * @shortname scale - * @drawable true - */ - scale( - inputs: Inputs.OCCT.ScaleDto - ): Promise; - /** - * Scales the shape in 3D - * @param inputs Scale 3D description - * @returns OpenCascade scaled shape - * @group on single shape - * @shortname scale 3d - * @drawable true - */ - scale3d( - inputs: Inputs.OCCT.Scale3DDto - ): Promise; - /** - * Mirrors the shape - * @param inputs Mirror axis origin, axis direction and shape - * @returns OpenCascade shape - * @group on single shape - * @shortname mirror - * @drawable true - */ - mirror( - inputs: Inputs.OCCT.MirrorDto - ): Promise; - /** - * Mirrors the shape along the normal and origin - * @param inputs Normal for mirroring with origin - * @returns OpenCascade shape - * @group on single shape - * @shortname mirror normal - * @drawable true - */ - mirrorAlongNormal( - inputs: Inputs.OCCT.MirrorAlongNormalDto - ): Promise; - /** - * Transforms the array of shapes with transformations - * @param inputs Transformation descriptions - * @returns OpenCascade shapes - * @group on shapes - * @shortname transforms - * @drawable true - */ - transformShapes( - inputs: Inputs.OCCT.TransformShapesDto - ): Promise; - /** - * Rotate the shapes with rotations - * @param inputs Rotation descriptions - * @returns OpenCascade shapes - * @group on shapes - * @shortname rotations - * @drawable true - */ - rotateShapes( - inputs: Inputs.OCCT.RotateShapesDto - ): Promise; - /** - * Rotate the shapes around the center and an axis - * @param inputs Rotation descriptions - * @returns OpenCascade shapes - * @group on shapes - * @shortname rotations around center - * @drawable true - */ - rotateAroundCenterShapes( - inputs: Inputs.OCCT.RotateAroundCenterShapesDto - ): Promise; - /** - * Align the shapes with alignments - * @param inputs Align descriptions - * @returns OpenCascade shapes - * @group on shapes - * @shortname alignments - * @drawable true - */ - alignShapes( - inputs: Inputs.OCCT.AlignShapesDto - ): Promise; - /** - * Align and translate the shapes - * @param inputs Align descriptions - * @returns OpenCascade shapes - * @group on shapes - * @shortname align and translate - * @drawable true - */ - alignAndTranslateShapes( - inputs: Inputs.OCCT.AlignAndTranslateShapesDto - ): Promise; - /** - * Translates the shapes with translations - * @param inputs Translation descriptions - * @returns OpenCascade shapes - * @group on shapes - * @shortname translations - * @drawable true - */ - translateShapes( - inputs: Inputs.OCCT.TranslateShapesDto - ): Promise; - /** - * Scales the shapes with scale factors - * @param inputs Scale descriptions - * @returns OpenCascade shapes - * @group on shapes - * @shortname scales - * @drawable true - */ - scaleShapes( - inputs: Inputs.OCCT.ScaleShapesDto - ): Promise; - /** - * Scales the shape in 3D - * @param inputs Scale 3D descriptions - * @returns OpenCascade scaled shapes - * @group on shapes - * @shortname scales 3d - * @drawable true - */ - scale3dShapes( - inputs: Inputs.OCCT.Scale3DShapesDto - ): Promise; - /** - * Mirrors the shapes with multiple mirrors - * @param inputs Mirror axis origins, axis directions and shapes - * @returns OpenCascade shapes - * @group on shapes - * @shortname mirrors - * @drawable true - */ - mirrorShapes( - inputs: Inputs.OCCT.MirrorShapesDto - ): Promise; - /** - * Mirrors the shapes along the normal and origin - * @param inputs Normals for mirroring with origins - * @returns OpenCascade shapes - * @group on shapes - * @shortname mirrors normal - * @drawable true - */ - mirrorAlongNormalShapes( - inputs: Inputs.OCCT.MirrorAlongNormalShapesDto - ): Promise; - } - /** - * Contains various functions that expose BABYLONJS objects - */ - declare class Babylon { - mesh: BabylonMesh; - gaussianSplatting: BabylonGaussianSplatting; - camera: BabylonCamera; - webXr: BabylonWebXR; - node: BabylonNode; - engine: BabylonEngine; - scene: BabylonScene; - transforms: BabylonTransforms; - io: BabylonIO; - ray: BabylonRay; - pick: BabylonPick; - material: BabylonMaterial; - lights: BabylonLights; - meshBuilder: BabylonMeshBuilder; - texture: BabylonTexture; - tools: BabylonTools; - gui: BabylonGui; - gizmo: BabylonGizmo; - constructor(context: Context, drawHelper: DrawHelper, color: Color); - } - declare class BabylonArcRotateCamera { - private readonly context; - constructor(context: Context); - /** - * Creates a camera that rotates around a given target while traveling the arc path. This camera is suitable for simple 3D navigation and is a default camera used by bitbybit. - * @param inputs Describes the arc rotate camera - * @returns BabylonJS arc rotate camera - * @group create - * @shortname new arc rotate camera - */ - create( - inputs: Inputs.BabylonCamera.ArcRotateCameraDto - ): BABYLON.ArcRotateCamera; - private getRadians; - } - declare class BabylonCamera { - private readonly context; - free: BabylonFreeCamera; - arcRotate: BabylonArcRotateCamera; - target: BabylonTargetCamera; - constructor(context: Context); - /** - * Freeze projection matrix of the camera - * @param inputs camera to freeze - * @group adjust - * @shortname freeze projection matrix - */ - freezeProjectionMatrix(inputs: Inputs.BabylonCamera.CameraDto): void; - /** - * Unfreeze projection matrix of the camera - * @param inputs camera to unfreeze - * @group adjust - * @shortname unfreeze projection matrix - */ - unfreezeProjectionMatrix(inputs: Inputs.BabylonCamera.CameraDto): void; - /** - * Changes the position of a camera - * @param inputs camera and position - * @group set - * @shortname set camera position - */ - setPosition(inputs: Inputs.BabylonCamera.PositionDto): void; - /** - * Gets the position of a camera - * @param inputs camera - * @group get - * @shortname get camera position - */ - getPosition(inputs: Inputs.BabylonCamera.PositionDto): Base.Point3; - /** - * Changes the target of a camera - * @param inputs camera and target - * @group set - * @shortname set camera target - */ - setTarget(inputs: Inputs.BabylonCamera.TargetDto): void; - /** - * Gets the target of a camera - * @param inputs camera - * @group get - * @shortname get camera target - */ - getTarget(inputs: Inputs.BabylonCamera.PositionDto): Base.Point3; - /** - * Changes the speed of a camera - * @param inputs camera and speed - * @group set - * @shortname set camera speed - */ - setSpeed(inputs: Inputs.BabylonCamera.SpeedDto): void; - /** - * Gets the speed of a camera - * @param inputs camera - * @group get - * @shortname get camera speed - */ - getSpeed(inputs: Inputs.BabylonCamera.PositionDto): Base.Point3; - /** - * Changes the minZ of a camera - * @param inputs camera - * @group set - * @shortname set camera min z - */ - setMinZ(inputs: Inputs.BabylonCamera.MinZDto): void; - /** - * Changes the maxZ of a camera - * @param inputs camera and maxz value - * @group set - * @shortname camera max z - */ - setMaxZ(inputs: Inputs.BabylonCamera.MaxZDto): void; - /** - * Changes the the mode of the camera to orthographic - * @param inputs the camera and orthographic properties - * @group adjust - * @shortname enable orthographic mode - */ - makeCameraOrthographic(inputs: Inputs.BabylonCamera.OrthographicDto): void; - /** - * Changes the mode of a camera to perspective - * @param inputs Changes the camera maxZ - * @group adjust - * @shortname enable perspective mode - */ - makeCameraPerspective(inputs: Inputs.BabylonCamera.CameraDto): void; - } - declare class BabylonFreeCamera { - private readonly context; - constructor(context: Context); - /** - * Creates a free camera - * @param inputs Describes the free camera - * @returns BabylonJS free camera - * @group create - * @shortname new free camera - */ - create(inputs: Inputs.BabylonCamera.FreeCameraDto): BABYLON.FreeCamera; - } - declare class BabylonTargetCamera { - private readonly context; - constructor(context: Context); - /** - * Creates a target camera - * @param inputs Describes the target camera - * @returns BabylonJS target camera - * @group create - * @shortname new target camera - */ - create(inputs: Inputs.BabylonCamera.TargetCameraDto): BABYLON.TargetCamera; - } - declare class BabylonEngine { - private readonly context; - constructor(context: Context); - /** - * Gets the engine for the current context - * @ignore true - * @group engine - * @shortname get engine - */ - getEngine(): BABYLON.Engine | BABYLON.WebGPUEngine; - /** - * Gets the rendering canvas on which scene cameras can be attached - * @ignore true - * @group engine - * @shortname get rendering canvas - */ - getRenderingCanvas(): HTMLCanvasElement; - } - declare class BabylonGaussianSplatting { - private readonly context; - constructor(context: Context); - /** Creates gaussian splatting mesh - * @param inputs Contains url of Gaussian splatting mesh - * @group create - * @shortname gaussian splatting mesh - * @disposableOutput true - */ - create( - inputs: Inputs.BabylonGaussianSplatting.CreateGaussianSplattingMeshDto - ): Promise; - /** Clones gaussian splatting mesh - * @param inputs Contains BabylonJS mesh that should be cloned - * @group multiply - * @shortname clone splat - * @disposableOutput true - */ - clone( - inputs: Inputs.BabylonGaussianSplatting.GaussianSplattingMeshDto - ): BABYLON.GaussianSplattingMesh; - /** - * Gets splat positions of the gaussian splat mesh - * @param inputs Contains BabylonJS mesh - * @group get - * @shortname get splat positions - * @drawable true - */ - getSplatPositions( - inputs: Inputs.BabylonGaussianSplatting.GaussianSplattingMeshDto - ): Inputs.Base.Point3[]; - private enableShadows; - } - declare class BabylonGizmoAxisDragGizmo { - private readonly context; - constructor(context: Context); - /** - * Sets if axis is enabled or not - * @param inputs axis drag gizmo - * @returns axis drag gizmo - * @group set - * @shortname set is axis enabled - */ - setIsEnabled( - inputs: Inputs.BabylonGizmo.SetIsEnabledAxisDragGizmoDto - ): BABYLON.IAxisDragGizmo; - /** - * Checks if axis is enabled - * @param inputs axis drag gizmo - * @returns is enabled - * @group get - * @shortname is axis enabled - */ - getIsEnabled(inputs: Inputs.BabylonGizmo.AxisDragGizmoDto): boolean; - } - declare class BabylonGizmoAxisScaleGizmo { - private readonly context; - constructor(context: Context); - /** - * Sets if axis is enabled or not - * @param inputs axis scale gizmo - * @returns axis scale gizmo - * @group set - * @shortname set is axis enabled - */ - setIsEnabled( - inputs: Inputs.BabylonGizmo.SetIsEnabledAxisScaleGizmoDto - ): BABYLON.IAxisScaleGizmo; - /** - * Checks if axis is enabled - * @param inputs axis scale gizmo - * @returns is enabled - * @group get - * @shortname is axis enabled - */ - getIsEnabled(inputs: Inputs.BabylonGizmo.AxisScaleGizmoDto): boolean; - } - declare class BabylonGizmoBoundingBoxGizmo { - private readonly context; - constructor(context: Context); - /** - * Set bounding box gizmo rotation sphere size - * @param inputs bounding box gizmo - * @returns bounding box gizmo - * @group set - * @shortname set rotation sphere size - */ - setRotationSphereSize( - inputs: Inputs.BabylonGizmo.SetBoundingBoxGizmoRotationSphereSizeDto - ): BABYLON.BoundingBoxGizmo; - /** - * If set, the rotation anchors and scale boxes will increase in size based on the distance away from the camera to have a consistent screen size (Default: false) Note : fixedDragMeshScreenSize takes precedence over fixedDragMeshBoundsSize if both are true - * @param inputs bounding box gizmo - * @returns bounding box gizmo - * @group set - * @shortname set fixed drag mesh screen size - */ - setFixedDragMeshScreenSize( - inputs: Inputs.BabylonGizmo.SetBoundingBoxGizmoFixedDragMeshScreenSizeDto - ): BABYLON.BoundingBoxGizmo; - /** - * Set bounding box gizmo fixed drag mesh bounds size - * @param inputs bounding box gizmo - * @returns bounding box gizmo - * @group set - * @shortname set fixed drag mesh bounds size - */ - setFixedDragMeshBoundsSize( - inputs: Inputs.BabylonGizmo.SetBoundingBoxGizmoFixedDragMeshBoundsSizeDto - ): BABYLON.BoundingBoxGizmo; - /** - * The distance away from the object which the draggable meshes should appear world sized when fixedDragMeshScreenSize is set to true (default: 10) - * @param inputs bounding box gizmo - * @returns bounding box gizmo - * @group set - * @shortname set fixed drag mesh screen size dist factor - */ - setFixedDragMeshScreenSizeDistanceFactor( - inputs: Inputs.BabylonGizmo.SetBoundingBoxGizmoFixedDragMeshScreenSizeDistanceFactorDto - ): BABYLON.BoundingBoxGizmo; - /** - * Set bounding box gizmo scaling snap distance. Drag distance in babylon units that the gizmo will snap scaling to when dragged. - * @param inputs bounding box gizmo - * @returns bounding box gizmo - * @group set - * @shortname set scaling snap dist. - */ - setScalingSnapDistance( - inputs: Inputs.BabylonGizmo.SetBoundingBoxGizmoScalingSnapDistanceDto - ): BABYLON.BoundingBoxGizmo; - /** - * Set bounding box gizmo rotation snap distance. Drag distance in babylon units that the gizmo will snap rotation to when dragged. - * @param inputs bounding box gizmo - * @returns bounding box gizmo - * @group set - * @shortname set rotation snap dist. - */ - setRotationSnapDistance( - inputs: Inputs.BabylonGizmo.SetBoundingBoxGizmoRotationSnapDistanceDto - ): BABYLON.BoundingBoxGizmo; - /** - * Set bounding box gizmo scale box size - * @param inputs bounding box gizmo - * @returns bounding box gizmo - * @group set - * @shortname set scale box size - */ - setScaleBoxSize( - inputs: Inputs.BabylonGizmo.SetBoundingBoxGizmoScaleBoxSizeDto - ): BABYLON.BoundingBoxGizmo; - /** - * Set bounding box gizmo incremental snap. Incremental snap scaling (default is false). When true, with a snapDistance of 0.1, scaling will be 1.1,1.2,1.3 instead of, when false: 1.1,1.21,1.33,... - * @param inputs bounding box gizmo - * @returns bounding box gizmo - * @group set - * @shortname set incremental snap - */ - setIncrementalSnap( - inputs: Inputs.BabylonGizmo.SetBoundingBoxGizmoIncrementalSnapDto - ): BABYLON.BoundingBoxGizmo; - /** - * Set bounding box gizmo scale pivot. Relative bounding box pivot used when scaling the attached node. When null object with scale from the opposite corner. 0.5,0.5,0.5 for center and 0.5,0,0.5 for bottom (Default: null) - * @param inputs bounding box gizmo and scale pivot - * @returns bounding box gizmo - * @group set - * @shortname set scale pivot - */ - setScalePivot( - inputs: Inputs.BabylonGizmo.SetBoundingBoxGizmoScalePivotDto - ): BABYLON.BoundingBoxGizmo; - /** - * Set bounding box gizmo axis factor. Set custom sensitivity value for each axis - * @param inputs bounding box gizmo and axis factor - * @returns bounding box gizmo - * @group set - * @shortname set axis factor - */ - setAxisFactor( - inputs: Inputs.BabylonGizmo.SetBoundingBoxGizmoAxisFactorDto - ): BABYLON.BoundingBoxGizmo; - /** - * Set bounding box gizmo scale drag speed - * @param inputs bounding box gizmo and scale drag speed - * @returns bounding box gizmo - * @group set - * @shortname set scale drag speed - */ - setScaleDragSpeed( - inputs: Inputs.BabylonGizmo.SetBoundingBoxGizmoScaleDragSpeedDto - ): BABYLON.BoundingBoxGizmo; - /** - * Get rotation sphere size - * @param inputs bounding box gizmo - * @returns rotation sphere size - * @group get - * @shortname get rotation sphere size - */ - getRotationSphereSize( - inputs: Inputs.BabylonGizmo.BoundingBoxGizmoDto - ): number; - /** - * Get scale box size - * @param inputs bounding box gizmo - * @returns scale box size - * @group get - * @shortname get scale box size - */ - getScaleBoxSize(inputs: Inputs.BabylonGizmo.BoundingBoxGizmoDto): number; - /** - * Get fixed drag mesh screen size - * @param inputs bounding box gizmo - * @returns fixed drag mesh screen size - * @group get - * @shortname get fixed drag mesh screen size - */ - getFixedDragMeshScreenSize( - inputs: Inputs.BabylonGizmo.BoundingBoxGizmoDto - ): boolean; - /** - * Get fixed drag mesh bounds size - * @param inputs bounding box gizmo - * @returns fixed drag mesh bounds size - * @group get - * @shortname get fixed drag mesh bounds size - */ - getFixedDragMeshBoundsSize( - inputs: Inputs.BabylonGizmo.BoundingBoxGizmoDto - ): boolean; - /** - * Get fixed drag mesh screen size distance factor - * @param inputs bounding box gizmo - * @returns fixed drag mesh screen size distance factor - * @group get - * @shortname get fixed drag mesh screen size distance factor - */ - getFixedDragMeshScreenSizeDistanceFactor( - inputs: Inputs.BabylonGizmo.BoundingBoxGizmoDto - ): number; - /** - * Get scaling snap distance - * @param inputs bounding box gizmo - * @returns scaling snap distance - * @group get - * @shortname get scaling snap distance - */ - getScalingSnapDistance( - inputs: Inputs.BabylonGizmo.BoundingBoxGizmoDto - ): number; - /** - * Get rotation snap distance - * @param inputs bounding box gizmo - * @returns rotation snap distance - * @group get - * @shortname get rotation snap distance - */ - getRotationSnapDistance( - inputs: Inputs.BabylonGizmo.BoundingBoxGizmoDto - ): number; - /** - * Get incremental snap - * @param inputs bounding box gizmo - * @returns incremental snap - * @group get - * @shortname get incremental snap - */ - getIncrementalSnap( - inputs: Inputs.BabylonGizmo.BoundingBoxGizmoDto - ): boolean; - /** - * Get scale pivot - * @param inputs bounding box gizmo - * @returns scale pivot - * @group get - * @shortname get scale pivot - */ - getScalePivot( - inputs: Inputs.BabylonGizmo.BoundingBoxGizmoDto - ): Inputs.Base.Vector3; - /** - * Get axis factor - * @param inputs bounding box gizmo - * @returns axis factor - * @group get - * @shortname get axis factor - */ - getAxisFactor( - inputs: Inputs.BabylonGizmo.BoundingBoxGizmoDto - ): Inputs.Base.Vector3; - /** - * Get scale drag speed - * @param inputs bounding box gizmo - * @returns scale drag speed - * @group get - * @shortname get scale drag speed - */ - getScaleDragSpeed(inputs: Inputs.BabylonGizmo.BoundingBoxGizmoDto): number; - /** - * Creates the selector of an observable for a bounding box gizmo - * @param inputs observable name - * @returns bounding box gizmo observable selector - * @group create - * @shortname bounding box gizmo observable selector - */ - createBoundingBoxGizmoObservableSelector( - inputs: Inputs.BabylonGizmo.BoundingBoxGizmoObservableSelectorDto - ): Inputs.BabylonGizmo.boundingBoxGizmoObservableSelectorEnum; - } - declare class BabylonGizmoBase { - private readonly context; - constructor(context: Context); - /** - * Set gizmo scale ratio - * @param inputs gizmo - * @group set - * @shortname set scale ratio - */ - scaleRatio( - inputs: Inputs.BabylonGizmo.SetGizmoScaleRatioDto - ): BABYLON.IGizmo; - /** - * Gets scale ratio - * @param inputs gizmo - * @returns scale ratio - * @group get - * @shortname get scale ratio - */ - getScaleRatio(inputs: Inputs.BabylonGizmo.GizmoDto): number; - } - declare class BabylonGizmo { - private readonly context; - manager: BabylonGizmoManager; - base: BabylonGizmoBase; - positionGizmo: BabylonGizmoPositionGizmo; - rotationGizmo: BabylonGizmoRotationGizmo; - scaleGizmo: BabylonGizmoScaleGizmo; - boundingBoxGizmo: BabylonGizmoBoundingBoxGizmo; - axisDragGizmo: BabylonGizmoAxisDragGizmo; - axisScaleGizmo: BabylonGizmoAxisScaleGizmo; - planeDragGizmo: BabylonGizmoPlaneDragGizmo; - planeRotationGizmo: BabylonGizmoPlaneRotationGizmo; - constructor(context: Context); - } - declare class BabylonGizmoManager { - private readonly context; - constructor(context: Context); - /** - * Create gizmo manager - * @param inputs gizmo manager options - * @group create - * @shortname create gizmo manager - * @disposableOutput true - */ - createGizmoManager( - inputs: Inputs.BabylonGizmo.CreateGizmoDto - ): BABYLON.GizmoManager; - /** - * Get position gizmo - * @param inputs gizmo manager - * @returns position gizmo - * @group get - * @shortname get position gizmo - */ - getPositionGizmo( - inputs: Inputs.BabylonGizmo.GizmoManagerDto - ): BABYLON.IPositionGizmo; - /** - * Get rotation gizmo - * @param inputs gizmo manager - * @returns rotation gizmo - * @group get - * @shortname get rotation gizmo - */ - getRotationGizmo( - inputs: Inputs.BabylonGizmo.GizmoManagerDto - ): BABYLON.IRotationGizmo; - /** - * Get scale gizmo - * @param inputs gizmo manager - * @returns scale gizmo - * @group get - * @shortname get scale gizmo - */ - getScaleGizmo( - inputs: Inputs.BabylonGizmo.GizmoManagerDto - ): BABYLON.IScaleGizmo; - /** - * Get bounding box gizmo - * @param inputs gizmo manager - * @returns bounding box gizmo - * @group get - * @shortname get bounding box gizmo - */ - getBoundingBoxGizmo( - inputs: Inputs.BabylonGizmo.GizmoManagerDto - ): BABYLON.IBoundingBoxGizmo; - /** - * Attach gizmo manager to mesh - * @param inputs gizmo manager, mesh - * @returns gizmo manager - * @group update - * @shortname attach to mesh - */ - attachToMesh( - inputs: Inputs.BabylonGizmo.AttachToMeshDto - ): BABYLON.GizmoManager; - /** - * Detach gizmo manager from mesh - * @param inputs gizmo manager, mesh - * @returns gizmo manager - * @group update - * @shortname detach mesh - */ - detachMesh( - inputs: Inputs.BabylonGizmo.GizmoManagerDto - ): BABYLON.GizmoManager; - } - declare class BabylonGizmoPlaneDragGizmo { - private readonly context; - constructor(context: Context); - /** - * Sets if plane is enabled or not - * @param inputs plane drag gizmo - * @returns plane drag gizmo - * @group set - * @shortname set is plane enabled - */ - setIsEnabled( - inputs: Inputs.BabylonGizmo.SetIsEnabledPlaneDragGizmoDto - ): BABYLON.IPlaneDragGizmo; - /** - * Checks if plane is enabled - * @param inputs plane drag gizmo - * @returns is enabled - * @group get - * @shortname is plane enabled - */ - getIsEnabled(inputs: Inputs.BabylonGizmo.PlaneDragGizmoDto): boolean; - } - declare class BabylonGizmoPlaneRotationGizmo { - private readonly context; - constructor(context: Context); - /** - * Sets if plane is enabled or not - * @param inputs plane rotation gizmo - * @returns plane rotation gizmo - * @group set - * @shortname set is plane enabled - */ - setIsEnabled( - inputs: Inputs.BabylonGizmo.SetIsEnabledPlaneRotationGizmoDto - ): BABYLON.IPlaneRotationGizmo; - /** - * Checks if plane is enabled - * @param inputs plane rotation gizmo - * @returns is enabled - * @group get - * @shortname is plane enabled - */ - getIsEnabled(inputs: Inputs.BabylonGizmo.PlaneRotationGizmoDto): boolean; - } - declare class BabylonGizmoPositionGizmo { - private readonly context; - constructor(context: Context); - /** - * Set planar gizmo enabled - * @param inputs position gizmo - * @group set - * @shortname set planar gizmo enabled - */ - planarGizmoEnabled( - inputs: Inputs.BabylonGizmo.SetPlanarGizmoEnabled - ): BABYLON.IPositionGizmo; - /** - * Set position gizmo snap distance - * @param inputs position gizmo - * @group set - * @shortname set snap distance - */ - snapDistance( - inputs: Inputs.BabylonGizmo.SetPositionGizmoSnapDistanceDto - ): BABYLON.IPositionGizmo; - /** - * Get attached mesh - * @param inputs position gizmo - * @returns attached mesh - * @group get - * @shortname get attached mesh - */ - getAttachedMesh( - inputs: Inputs.BabylonGizmo.PositionGizmoDto - ): BABYLON.AbstractMesh; - /** - * Get attached node - * @param inputs position gizmo - * @returns attached node - * @group get - * @shortname get attached node - */ - getAttachedNode(inputs: Inputs.BabylonGizmo.PositionGizmoDto): BABYLON.Node; - /** - * Get x gizmo - * @param inputs position gizmo - * @returns x drag gizmo - * @group get - * @shortname get x gizmo - */ - getXGizmo( - inputs: Inputs.BabylonGizmo.PositionGizmoDto - ): BABYLON.IAxisDragGizmo; - /** - * Get y gizmo - * @param inputs position gizmo - * @returns y drag gizmo - * @group get - * @shortname get y gizmo - */ - getYGizmo( - inputs: Inputs.BabylonGizmo.PositionGizmoDto - ): BABYLON.IAxisDragGizmo; - /** - * Get z gizmo - * @param inputs position gizmo - * @returns z drag gizmo - * @group get - * @shortname get z gizmo - */ - getZGizmo( - inputs: Inputs.BabylonGizmo.PositionGizmoDto - ): BABYLON.IAxisDragGizmo; - /** - * Get x plane gizmo - * @param inputs position gizmo - * @group get - * @shortname get x plane gizmo - */ - getXPlaneGizmo( - inputs: Inputs.BabylonGizmo.PositionGizmoDto - ): BABYLON.IPlaneDragGizmo; - /** - * Get y plane gizmo - * @param inputs position gizmo - * @group get - * @shortname get y plane gizmo - */ - getYPlaneGizmo( - inputs: Inputs.BabylonGizmo.PositionGizmoDto - ): BABYLON.IPlaneDragGizmo; - /** - * Get z plane gizmo - * @param inputs position gizmo - * @group get - * @shortname get z plane gizmo - */ - getZPlaneGizmo( - inputs: Inputs.BabylonGizmo.PositionGizmoDto - ): BABYLON.IPlaneDragGizmo; - /** - * Get if planar gizmo enabled - * @param inputs position gizmo - * @returns is enabled - * @group get - * @shortname get planar gizmo enabled - */ - getPlanarGizmoEnabled( - inputs: Inputs.BabylonGizmo.PositionGizmoDto - ): boolean; - /** - * Get snap distance - * @param inputs position gizmo - * @returns snap distance - * @group get - * @shortname get snap distance - */ - getSnapDistance(inputs: Inputs.BabylonGizmo.PositionGizmoDto): number; - /** - * Get if is dragging - * @param inputs position gizmo - * @returns is dragging - * @group get - * @shortname get is dragging - */ - getIsDragging(inputs: Inputs.BabylonGizmo.PositionGizmoDto): boolean; - /** - * Creates the selector of an observable for a position gizmo - * @param inputs observable name - * @returns position gizmo observable selector - * @group create - * @shortname position gizmo observable selector - */ - createPositionGizmoObservableSelector( - inputs: Inputs.BabylonGizmo.PositionGizmoObservableSelectorDto - ): Inputs.BabylonGizmo.positionGizmoObservableSelectorEnum; - } - declare class BabylonGizmoRotationGizmo { - private readonly context; - constructor(context: Context); - /** - * Set rotation gizmo snap distance - * @param inputs rotation gizmo - * @returns rotation gizmo - * @group set - * @shortname set snap distance - */ - snapDistance( - inputs: Inputs.BabylonGizmo.SetRotationGizmoSnapDistanceDto - ): BABYLON.IRotationGizmo; - /** - * Set rotation gizmo sensitivity - * @param inputs rotation gizmo - * @returns rotation gizmo - * @group set - * @shortname set sensitivity - */ - sensitivity( - inputs: Inputs.BabylonGizmo.SetRotationGizmoSensitivityDto - ): BABYLON.IRotationGizmo; - /** - * Get attached mesh - * @param inputs rotation gizmo - * @returns attached mesh - * @group get - * @shortname get attached mesh - */ - getAttachedMesh( - inputs: Inputs.BabylonGizmo.RotationGizmoDto - ): BABYLON.Nullable; - /** - * Get attached node - * @param inputs rotation gizmo - * @returns attached node - * @group get - * @shortname get attached node - */ - getAttachedNode(inputs: Inputs.BabylonGizmo.RotationGizmoDto): BABYLON.Node; - /** - * Get x gizmo - * @param inputs rotation gizmo - * @returns x drag gizmo - * @group get - * @shortname get x gizmo - */ - getXGizmo( - inputs: Inputs.BabylonGizmo.RotationGizmoDto - ): BABYLON.IPlaneRotationGizmo; - /** - * Get y gizmo - * @param inputs rotation gizmo - * @returns y drag gizmo - * @group get - * @shortname get y gizmo - */ - getYGizmo( - inputs: Inputs.BabylonGizmo.RotationGizmoDto - ): BABYLON.IPlaneRotationGizmo; - /** - * Get z gizmo - * @param inputs rotation gizmo - * @returns z drag gizmo - * @group get - * @shortname get z gizmo - */ - getZGizmo( - inputs: Inputs.BabylonGizmo.RotationGizmoDto - ): BABYLON.IPlaneRotationGizmo; - /** - * Get snap distance - * @param inputs rotation gizmo - * @returns snap distance - * @group get - * @shortname get snap distance - */ - getSnapDistance(inputs: Inputs.BabylonGizmo.RotationGizmoDto): number; - /** - * Get sensitivity - * @param inputs rotation gizmo - * @returns sensitivity - * @group get - * @shortname get sensitivity - */ - getSensitivity(inputs: Inputs.BabylonGizmo.RotationGizmoDto): number; - /** - * Creates the selector of an observable for a rotation gizmo - * @param inputs observable name - * @returns rotation gizmo observable selector - * @group create - * @shortname rotation gizmo observable selector - */ - createRotationGizmoObservableSelector( - inputs: Inputs.BabylonGizmo.RotationGizmoObservableSelectorDto - ): Inputs.BabylonGizmo.rotationGizmoObservableSelectorEnum; - } - declare class BabylonGizmoScaleGizmo { - private readonly context; - constructor(context: Context); - /** - * Get x gizmo - * @param inputs scale gizmo - * @returns x scale gizmo - * @group get - * @shortname get x gizmo - */ - getXGizmo( - inputs: Inputs.BabylonGizmo.ScaleGizmoDto - ): BABYLON.IAxisScaleGizmo; - /** - * Get y gizmo - * @param inputs position gizmo - * @returns y scale gizmo - * @group get - * @shortname get y gizmo - */ - getYGizmo( - inputs: Inputs.BabylonGizmo.ScaleGizmoDto - ): BABYLON.IAxisScaleGizmo; - /** - * Get z gizmo - * @param inputs scale gizmo - * @returns z scale gizmo - * @group get - * @shortname get z gizmo - */ - getZGizmo( - inputs: Inputs.BabylonGizmo.ScaleGizmoDto - ): BABYLON.IAxisScaleGizmo; - /** - * Set scale gizmo snap distance - * @param inputs scale gizmo - * @returns scale gizmo - * @group set - * @shortname set snap distance - */ - snapDistance( - inputs: Inputs.BabylonGizmo.SetScaleGizmoSnapDistanceDto - ): BABYLON.IScaleGizmo; - /** - * Set scale gizmo incremental snap - * @param inputs scale gizmo - * @returns scale gizmo - * @group set - * @shortname set incremental snap - */ - setIncrementalSnap( - inputs: Inputs.BabylonGizmo.SetScaleGizmoIncrementalSnapDto - ): BABYLON.IScaleGizmo; - /** - * Set scale gizmo sensitivity - * @param inputs scale gizmo - * @returns scale gizmo - * @group set - * @shortname set sensitivity - */ - sensitivity( - inputs: Inputs.BabylonGizmo.SetScaleGizmoSensitivityDto - ): BABYLON.IScaleGizmo; - /** - * Get incremental snap - * @param inputs scale gizmo - * @returns incremental snap - * @group get - * @shortname get incremental snap - */ - getIncrementalSnap(inputs: Inputs.BabylonGizmo.ScaleGizmoDto): boolean; - /** - * Get snap distance - * @param inputs scale gizmo - * @returns snap distance - * @group get - * @shortname get snap distance - */ - getSnapDistance(inputs: Inputs.BabylonGizmo.ScaleGizmoDto): number; - /** - * Get sensitivity - * @param inputs scale gizmo - * @returns sensitivity - * @group get - * @shortname get sensitivity - */ - getSensitivity(inputs: Inputs.BabylonGizmo.ScaleGizmoDto): number; - /** - * Creates the selector of an observable for a scale gizmo - * @param inputs observable name - * @returns scale gizmo observable selector - * @group create - * @shortname scale gizmo observable selector - */ - createScaleGizmoObservableSelector( - inputs: Inputs.BabylonGizmo.ScaleGizmoObservableSelectorDto - ): Inputs.BabylonGizmo.scaleGizmoObservableSelectorEnum; - } - declare class BabylonGuiAdvancedDynamicTexture { - private readonly context; - constructor(context: Context); - /** - * Creates full screen UI - * @param inputs with name of advanced texture, foreground, sampling and adaptive scaling - * @returns advanced dynamic texture - * @group spaces - * @shortname create full screen ui - * @disposableOutput true - */ - createFullScreenUI( - inputs: Inputs.BabylonGui.CreateFullScreenUIDto - ): BABYLON.GUI.AdvancedDynamicTexture; - /** - * Creates advanced dynamic texture for a mesh - * @param inputs with mesh, width, height, support pointer move, only alpha testing, invert y and sampling - * @returns advanced dynamic texture - * @group spaces - * @shortname create for mesh - * @disposableOutput true - */ - createForMesh( - inputs: Inputs.BabylonGui.CreateForMeshDto - ): BABYLON.GUI.AdvancedDynamicTexture; - } - declare class BabylonGuiButton { - private readonly context; - constructor(context: Context); - /** - * Creates simple button - * @param inputs button properties - * @returns button - * @group create - * @shortname create simple button - * @disposableOutput true - */ - createSimpleButton( - inputs: Inputs.BabylonGui.CreateButtonDto - ): BABYLON.GUI.Button; - /** - * Set button text - * @param inputs button and text - * @returns button with changed text - * @group set - * @shortname set button text - */ - setButtonText( - inputs: Inputs.BabylonGui.SetButtonTextDto - ): BABYLON.GUI.Button; - /** - * Get button text - * @param inputs button - * @returns button text - * @group get - * @shortname get button text - */ - getButtonText(inputs: Inputs.BabylonGui.ButtonDto): string; - } - declare class BabylonGuiCheckbox { - private readonly context; - constructor(context: Context); - /** - * Creates checkbox - * @param inputs checkbox properties - * @returns checkbox - * @group create - * @shortname create checkbox - * @disposableOutput true - */ - createCheckbox( - inputs: Inputs.BabylonGui.CreateCheckboxDto - ): BABYLON.GUI.Checkbox; - /** - * Sets the checkbox background - * @param inputs checkbox and background - * @group set - * @shortname set checkbox background - */ - setBackground( - inputs: Inputs.BabylonGui.SetCheckboxBackgroundDto - ): BABYLON.GUI.Checkbox; - /** - * Sets the checkbox check size ratio - * @param inputs checkbox and check size ratio - * @group set - * @shortname set checkbox check size ratio - */ - setCheckSizeRatio( - inputs: Inputs.BabylonGui.SetCheckboxCheckSizeRatioDto - ): BABYLON.GUI.Checkbox; - /** - * Sets the checkbox is checked - * @param inputs checkbox and is checked - * @group set - * @shortname set checkbox is checked - */ - setIsChecked( - inputs: Inputs.BabylonGui.SetCheckboxIsCheckedDto - ): BABYLON.GUI.Checkbox; - /** - * Gets the check size ratio - * @param inputs checkbox - * @group get - * @shortname get check size ratio - */ - getCheckSizeRatio(inputs: Inputs.BabylonGui.CheckboxDto): number; - /** - * Gets the is checked - * @param inputs checkbox - * @group get - * @shortname get is checked - */ - getIsChecked(inputs: Inputs.BabylonGui.CheckboxDto): boolean; - /** - * Gets the background - * @param inputs checkbox - * @group get - * @shortname get checkbox background - */ - getBackground(inputs: Inputs.BabylonGui.CheckboxDto): string; - /** - * Creates the selector of an observable for the checkbox - * @param inputs observable name - * @group create - * @shortname checkbox observable selector - */ - createCheckboxObservableSelector( - inputs: Inputs.BabylonGui.CheckboxObservableSelectorDto - ): Inputs.BabylonGui.checkboxObservableSelectorEnum; - } - declare class BabylonGuiColorPicker { - private readonly context; - constructor(context: Context); - /** - * Creates color picker - * @param inputs color picker properties - * @returns color picker - * @group create - * @shortname color picker - * @disposableOutput true - */ - createColorPicker( - inputs: Inputs.BabylonGui.CreateColorPickerDto - ): BABYLON.GUI.ColorPicker; - /** - * Sets color picker value color - * @param inputs color picker and color - * @returns color picker - * @group set - * @shortname set colo picker value - */ - setColorPickerValue( - inputs: Inputs.BabylonGui.SetColorPickerValueDto - ): BABYLON.GUI.ColorPicker; - /** - * Sets color picker size (width and height) - * @param inputs color picker and size - * @returns color picker - * @group set - * @shortname set color picker size - */ - setColorPickerSize( - inputs: Inputs.BabylonGui.SetColorPickerSizeDto - ): BABYLON.GUI.ColorPicker; - /** - * Gets color picker value color - * @param inputs color picker - * @returns color - * @group get - * @shortname get color picker value - */ - getColorPickerValue(inputs: Inputs.BabylonGui.ColorPickerDto): string; - /** - * Gets color picker size - * @param inputs color picker - * @returns size - * @group get - * @shortname get color picker size - */ - getColorPickerSize( - inputs: Inputs.BabylonGui.ColorPickerDto - ): string | number; - /** - * Creates the selector of an observable for color picker - * @param inputs observable name - * @returns color picker observable selector - * @group create - * @shortname color picker observable selector - */ - createColorPickerObservableSelector( - inputs: Inputs.BabylonGui.ColorPickerObservableSelectorDto - ): Inputs.BabylonGui.colorPickerObservableSelectorEnum; - } - declare class BabylonGuiContainer { - private readonly context; - constructor(context: Context); - /** - * Adds controls to container and keeps the order - * @param inputs with container and controls - * @returns container - * @group controls - * @shortname add controls to container - */ - addControls( - inputs: Inputs.BabylonGui.AddControlsToContainerDto - ): BABYLON.GUI.Container; - /** - * Sets the container background - * @param inputs container and background - * @group set - * @shortname set container background - */ - setBackground( - inputs: Inputs.BabylonGui.SetContainerBackgroundDto - ): BABYLON.GUI.Container; - /** - * Sets the container is readonly - * @param inputs container and is readonly - * @group set - * @shortname set container is readonly - */ - setIsReadonly( - inputs: Inputs.BabylonGui.SetContainerIsReadonlyDto - ): BABYLON.GUI.Container; - /** - * Gets the container background - * @param inputs container - * @group get - * @shortname get container background - */ - getBackground(inputs: Inputs.BabylonGui.ContainerDto): string; - /** - * Gets the container is readonly - * @param inputs container - * @group get - * @shortname get container is readonly - */ - getIsReadonly(inputs: Inputs.BabylonGui.ContainerDto): boolean; - } - declare class BabylonGuiControl { - private readonly context; - constructor(context: Context); - /** - * Change the padding for the control - * @param inputs the control and the padding values - * @returns control that has changed padding - * @group positioning - * @shortname change padding - */ - changeControlPadding( - inputs: Inputs.BabylonGui.PaddingLeftRightTopBottomDto - ): BABYLON.GUI.Control; - /** - * Change the alignment for the control - * @param inputs the control and the alignment values - * @returns control that has changed alignment - * @group positioning - * @shortname change alignment - */ - changeControlAlignment( - inputs: Inputs.BabylonGui.AlignmentDto - ): BABYLON.GUI.Control; - /** - * Clone control - * @param inputs control to clone - * @returns cloned control - * @group create - * @shortname clone control - * @disposableOutput true - */ - cloneControl( - inputs: Inputs.BabylonGui.CloneControlDto - ): BABYLON.GUI.Control; - /** - * Creates the selector of an observable for a control - * @param inputs observable name - * @group create - * @shortname control observable selector - */ - createControlObservableSelector( - inputs: Inputs.BabylonGui.ControlObservableSelectorDto - ): Inputs.BabylonGui.controlObservableSelectorEnum; - /** - * Get control by name - * @param inputs container and control name - * @returns control with the name - * @group get - * @shortname get control by name - */ - getControlByName( - inputs: Inputs.BabylonGui.GetControlByNameDto - ): BABYLON.GUI.Control; - /** - * Set if control is visible - * @param inputs control and is visible - * @returns control with changed visibility - * @group set - * @shortname set control is visible - */ - setIsVisible( - inputs: Inputs.BabylonGui.SetControlIsVisibleDto - ): BABYLON.GUI.Control; - /** - * Set if control is readonly - * @param inputs control and is readonly - * @returns control with changed readonly - * @group set - * @shortname set control is readonly - */ - setIsReadonly( - inputs: Inputs.BabylonGui.SetControlIsReadonlyDto - ): BABYLON.GUI.Control; - /** - * Set if control is enabled - * @param inputs control and is enabled - * @returns control with changed enabled - * @group set - * @shortname set control is enabled - */ - setIsEnabled( - inputs: Inputs.BabylonGui.SetControlIsEnabledDto - ): BABYLON.GUI.Control; - /** - * Sets the control height - * @param inputs control and height - * @group set - * @shortname set control height - */ - setHeight( - inputs: Inputs.BabylonGui.SetControlHeightDto - ): BABYLON.GUI.Control; - /** - * Sets the control width - * @param inputs control and width - * @group set - * @shortname set control width - */ - setWidth(inputs: Inputs.BabylonGui.SetControlWidthDto): BABYLON.GUI.Control; - /** - * Sets the control color - * @param inputs control and color - * @group set - * @shortname set control color - */ - setColor(inputs: Inputs.BabylonGui.SetControlColorDto): BABYLON.GUI.Control; - /** - * Set font size - * @param inputs control and font size - * @returns control with changed font size - * @group set - * @shortname set control font size - */ - setFontSize( - inputs: Inputs.BabylonGui.SetControlFontSizeDto - ): BABYLON.GUI.Control; - /** - * Gets the height - * @param inputs control - * @group get - * @shortname get control height - */ - getHeight(inputs: Inputs.BabylonGui.ControlDto): string | number; - /** - * Gets the width - * @param inputs control - * @group get - * @shortname get control width - */ - getWidth(inputs: Inputs.BabylonGui.ControlDto): string | number; - /** - * Gets the color - * @param inputs control - * @group get - * @shortname get control color - */ - getColor(inputs: Inputs.BabylonGui.ControlDto): string; - /** - * Get control font size - * @param inputs control - * @returns control font size. Can be in the form of a string "24px" or a number - * @group get - * @shortname get control font size - */ - getFontSize(inputs: Inputs.BabylonGui.ControlDto): string | number; - /** - * Get control is visible - * @param inputs control - * @returns control visibility - * @group get - * @shortname get control is visible - */ - getIsVisible(inputs: Inputs.BabylonGui.ControlDto): boolean; - /** - * Get control is readonly - * @param inputs control - * @returns control readonly - * @group get - * @shortname get control is readonly - */ - getIsReadonly(inputs: Inputs.BabylonGui.ControlDto): boolean; - /** - * Get control is enabled - * @param inputs control - * @returns control enabled - * @group get - * @shortname get control is enabled - */ - getIsEnabled(inputs: Inputs.BabylonGui.ControlDto): boolean; - } - declare class BabylonGui { - private readonly context; - advancedDynamicTexture: BabylonGuiAdvancedDynamicTexture; - control: BabylonGuiControl; - container: BabylonGuiContainer; - stackPanel: BabylonGuiStackPanel; - button: BabylonGuiButton; - slider: BabylonGuiSlider; - textBlock: BabylonGuiTextBlock; - radioButton: BabylonGuiRadioButton; - checkbox: BabylonGuiCheckbox; - inputText: BabylonGuiInputText; - colorPicker: BabylonGuiColorPicker; - image: BabylonGuiImage; - constructor(context: Context); - } - declare class BabylonGuiImage { - private readonly context; - constructor(context: Context); - /** - * Creates image - * @param inputs image properties - * @returns image - * @group create - * @shortname create image - * @disposableOutput true - */ - createImage(inputs: Inputs.BabylonGui.CreateImageDto): BABYLON.GUI.Image; - /** - * Sets image source url - * @param inputs image and url - * @returns image - * @group set - * @shortname set image source url - */ - setSourceUrl(inputs: Inputs.BabylonGui.SetImageUrlDto): BABYLON.GUI.Image; - /** - * Gets image source url - * @param inputs image - * @returns image source url - * @group get - * @shortname get image source url - */ - getSourceUrl(inputs: Inputs.BabylonGui.ImageDto): string; - } - declare class BabylonGuiInputText { - private readonly context; - constructor(context: Context); - /** - * Creates input text - * @param inputs input text properties - * @returns input text - * @group create - * @shortname create input text - * @disposableOutput true - */ - createInputText( - inputs: Inputs.BabylonGui.CreateInputTextDto - ): BABYLON.GUI.InputText; - /** - * Sets the input text background - * @param inputs input text and background - * @returns input text - * @group set - * @shortname set input text background - */ - setBackground( - inputs: Inputs.BabylonGui.SetInputTextBackgroundDto - ): BABYLON.GUI.InputText; - /** - * Sets the input text text - * @param inputs input text and text - * @returns input text - * @group set - * @shortname set input text text - */ - setText( - inputs: Inputs.BabylonGui.SetInputTextTextDto - ): BABYLON.GUI.InputText; - /** - * Sets the input text placeholder - * @param inputs input text and placeholder - * @returns input text - * @group set - * @shortname set input text placeholder - */ - setPlaceholder( - inputs: Inputs.BabylonGui.SetInputTextPlaceholderDto - ): BABYLON.GUI.InputText; - /** - * Gets the input text background - * @param inputs input text - * @returns input text background - * @group get - * @shortname get input text background - */ - getBackground(inputs: Inputs.BabylonGui.InputTextDto): string; - /** - * Gets the input text text - * @param inputs input text - * @returns input text text - * @group get - * @shortname get input text text - */ - getText(inputs: Inputs.BabylonGui.InputTextDto): string; - /** - * Gets the input text placeholder - * @param inputs input text - * @returns input text placeholder - * @group get - * @shortname get input text placeholder - */ - getPlaceholder(inputs: Inputs.BabylonGui.InputTextDto): string; - /** - * Creates the selector of an observable for the input text - * @param inputs observable name - * @group create - * @shortname input text observable selector - */ - createInputTextObservableSelector( - inputs: Inputs.BabylonGui.InputTextObservableSelectorDto - ): Inputs.BabylonGui.inputTextObservableSelectorEnum; - } - declare class BabylonGuiRadioButton { - private readonly context; - constructor(context: Context); - /** - * Creates radio button - * @param inputs radio button properties - * @returns radio button - * @group create - * @shortname create radio button - * @disposableOutput true - */ - createRadioButton( - inputs: Inputs.BabylonGui.CreateRadioButtonDto - ): BABYLON.GUI.RadioButton; - /** - * Sets the radio button check size ratio - * @param inputs radio button and check size ratio - * @group set - * @shortname set radio button check size ratio - */ - setCheckSizeRatio( - inputs: Inputs.BabylonGui.SetRadioButtonCheckSizeRatioDto - ): BABYLON.GUI.RadioButton; - /** - * Sets the radio button group - * @param inputs radio button and group - * @group set - * @shortname set radio button group - */ - setGroup( - inputs: Inputs.BabylonGui.SetRadioButtonGroupDto - ): BABYLON.GUI.RadioButton; - /** - * Sets the radio button background - * @param inputs radio button and background - * @group set - * @shortname set radio button background - */ - setBackground( - inputs: Inputs.BabylonGui.SetRadioButtonBackgroundDto - ): BABYLON.GUI.RadioButton; - /** - * Gets the radio button check size ratio - * @param inputs radio button - * @group get - * @shortname get radio button check size ratio - */ - getCheckSizeRatio(inputs: Inputs.BabylonGui.RadioButtonDto): number; - /** - * Gets the radio button group - * @param inputs radio button - * @group get - * @shortname get radio button group - */ - getGroup(inputs: Inputs.BabylonGui.RadioButtonDto): string; - /** - * Gets the radio button background - * @param inputs radio button - * @group get - * @shortname get radio button background - */ - getBackground(inputs: Inputs.BabylonGui.RadioButtonDto): string; - /** - * Creates the selector of an observable for the radio button - * @param inputs observable name - * @group create - * @shortname radio button observable selector - */ - createRadioButtonObservableSelector( - inputs: Inputs.BabylonGui.RadioButtonObservableSelectorDto - ): Inputs.BabylonGui.radioButtonObservableSelectorEnum; - } - declare class BabylonGuiSlider { - private readonly context; - constructor(context: Context); - /** - * Creates slider - * @param inputs slider properties - * @returns slider - * @group create - * @shortname create slider - * @disposableOutput true - */ - createSlider(inputs: Inputs.BabylonGui.CreateSliderDto): BABYLON.GUI.Slider; - /** - * Changes slider thumb properties - * @param inputs slider properties* - * @returns slider - * @group set - * @shortname set slider thumb - */ - changeSliderThumb( - inputs: Inputs.BabylonGui.SliderThumbDto - ): BABYLON.GUI.Slider; - /** - * Changes slider border color - * @param inputs slider border color - * @returns slider - * @group set - * @shortname set slider border color - */ - setBorderColor( - inputs: Inputs.BabylonGui.SliderBorderColorDto - ): BABYLON.GUI.Slider; - /** - * Changes slider background color - * @param inputs slider background color - * @returns slider - * @group set - * @shortname set slider background color - */ - setBackgroundColor( - inputs: Inputs.BabylonGui.SliderBackgroundColorDto - ): BABYLON.GUI.Slider; - /** - * Changes slider maximum value - * @param inputs slider maximum value - * @returns slider - * @group set - * @shortname set slider maximum - */ - setMaximum(inputs: Inputs.BabylonGui.SetSliderValueDto): BABYLON.GUI.Slider; - /** - * Changes slider minimum value - * @param inputs slider minimum value - * @returns slider - * @group set - * @shortname set slider minimum - */ - setMinimum(inputs: Inputs.BabylonGui.SetSliderValueDto): BABYLON.GUI.Slider; - /** - * Changes slider step value - * @param inputs slider step value - * @returns slider - * @group set - * @shortname set slider step - */ - setStep(inputs: Inputs.BabylonGui.SetSliderValueDto): BABYLON.GUI.Slider; - /** - * Changes slider value - * @param inputs slider value - * @returns slider - * @group set - * @shortname set slider value - */ - setValue(inputs: Inputs.BabylonGui.SetSliderValueDto): BABYLON.GUI.Slider; - /** - * Creates the selector of an observable for a slider - * @param inputs observable name - * @returns slider observable selector - * @group create - * @shortname slider observable selector - */ - createSliderObservableSelector( - inputs: Inputs.BabylonGui.SliderObservableSelectorDto - ): Inputs.BabylonGui.sliderObservableSelectorEnum; - /** - * Gets the slider border color - * @param slider slider - * @returns slider border color - * @group get - * @shortname get slider border color - */ - getBorderColor(inputs: Inputs.BabylonGui.SliderDto): string; - /** - * Gets the slider background color - * @param slider slider - * @returns slider background color - * @group get - * @shortname get slider background color - */ - getBackgroundColor(inputs: Inputs.BabylonGui.SliderDto): string; - /** - * Gets the slider maximum value - * @param slider slider - * @returns slider maximum value - * @group get - * @shortname get slider maximum - */ - getMaximum(inputs: Inputs.BabylonGui.SliderDto): number; - /** - * Gets the slider minimum value - * @param slider slider - * @returns slider minimum value - * @group get - * @shortname get slider minimum - */ - getMinimum(inputs: Inputs.BabylonGui.SliderDto): number; - /** - * Gets the slider step value - * @param slider slider - * @returns slider step value - * @group get - * @shortname get slider step - */ - getStep(inputs: Inputs.BabylonGui.SliderDto): number; - /** - * Gets the slider value - * @param slider slider - * @returns slider value - * @group get - * @shortname get slider value - */ - getValue(inputs: Inputs.BabylonGui.SliderDto): number; - /** - * Gets the slider thumb color - * @param slider slider - * @returns slider thumb color - * @group get - * @shortname get slider thumb color - */ - getThumbColor(inputs: Inputs.BabylonGui.SliderDto): string; - /** - * Gets the slider thumb width - * @param slider slider - * @returns slider thumb width - * @group get - * @shortname get slider thumb width - */ - getThumbWidth(inputs: Inputs.BabylonGui.SliderDto): string | number; - /** - * Gets the slider is vertical - * @param slider slider - * @returns slider is vertical - * @group get - * @shortname get slider is vertical - */ - getIsVertical(inputs: Inputs.BabylonGui.SliderDto): boolean; - /** - * Gets the slider display thumb - * @param slider slider - * @returns slider display thumb - * @group get - * @shortname get slider display thumb - */ - getDisplayThumb(inputs: Inputs.BabylonGui.SliderDto): boolean; - /** - * Gets the slider is thumb circle - * @param slider slider - * @returns slider is thumb circle - * @group get - * @shortname get slider is thumb circle - */ - getIsThumbCircle(inputs: Inputs.BabylonGui.SliderDto): boolean; - /** - * Gets the slider is thumb clamped - * @param slider slider - * @returns slider is thumb clamped - * @group get - * @shortname get slider is thumb clamped - */ - getIsThumbClamped(inputs: Inputs.BabylonGui.SliderDto): boolean; - } - declare class BabylonGuiStackPanel { - private readonly context; - constructor(context: Context); - /** - * Creates stack panel - * @param inputs stack panel props - * @group create - * @shortname create stack panel - * @disposableOutput true - */ - createStackPanel( - inputs: Inputs.BabylonGui.CreateStackPanelDto - ): BABYLON.GUI.StackPanel; - /** - * Set stack panel is vertical - * @param inputs with stack panel and is vertical - * @returns stack panel with changed is vertical - * @group set - * @shortname set stack panel is vertical - */ - setIsVertical( - inputs: Inputs.BabylonGui.SetStackPanelIsVerticalDto - ): BABYLON.GUI.StackPanel; - /** - * Set stack panel spacing - * @param inputs with stack panel and spacing - * @returns stack panel with changed spacing - * @group set - * @shortname set stack panel spacing - */ - setSpacing( - inputs: Inputs.BabylonGui.SetStackPanelSpacingDto - ): BABYLON.GUI.StackPanel; - /** - * Set stack panel width - * @param inputs with stack panel and width - * @returns stack panel with changed width - * @group set - * @shortname set stack panel width - */ - setWidth( - inputs: Inputs.BabylonGui.SetStackPanelWidthDto - ): BABYLON.GUI.StackPanel; - /** - * Set stack panel height - * @param inputs with stack panel and height - * @returns stack panel with changed height - * @group set - * @shortname set stack panel height - */ - setHeight( - inputs: Inputs.BabylonGui.SetStackPanelHeightDto - ): BABYLON.GUI.StackPanel; - /** - * Get stack panel is vertical - * @param inputs with stack panel - * @returns stack panel is vertical - * @group get - * @shortname get stack panel is vertical - */ - getIsVertical(inputs: Inputs.BabylonGui.StackPanelDto): boolean; - /** - * Get stack panel spacing - * @param inputs with stack panel - * @returns stack panel spacing - * @group get - * @shortname get stack panel spacing - */ - getSpacing(inputs: Inputs.BabylonGui.StackPanelDto): number; - /** - * Get stack panel width - * @param inputs with stack panel - * @returns stack panel width - * @group get - * @shortname get stack panel width - */ - getWidth(inputs: Inputs.BabylonGui.StackPanelDto): string | number; - /** - * Get stack panel height - * @param inputs with stack panel - * @returns stack panel height - * @group get - * @shortname get stack panel height - */ - getHeight(inputs: Inputs.BabylonGui.StackPanelDto): string | number; - } - declare class BabylonGuiTextBlock { - private readonly context; - constructor(context: Context); - /** - * Creates text block - * @param inputs text block properties - * @group create - * @shortname create text block - * @disposableOutput true - */ - createTextBlock( - inputs: Inputs.BabylonGui.CreateTextBlockDto - ): BABYLON.GUI.TextBlock; - /** - * Change the alignment for the text - * @param inputs the text block and the alignment values - * @returns control that has changed text alignment - * @group positioning - * @shortname align text block text - */ - alignText( - inputs: Inputs.BabylonGui.AlignmentDto - ): BABYLON.GUI.TextBlock; - /** - * Change the text outline for the text - * @param inputs the text block and the outline values - * @returns control that has changed text outline - * @group set - * @shortname text outline - */ - setTextOutline( - inputs: Inputs.BabylonGui.SetTextBlockTextOutlineDto - ): BABYLON.GUI.TextBlock; - /** - * Sets the new text to the text block - * @param inputs text block and text - * @returns control that has changed text - * @group set - * @shortname set text block text - */ - setText( - inputs: Inputs.BabylonGui.SetTextBlockTextDto - ): BABYLON.GUI.TextBlock; - /** - * Enable or disable resize to fit - * @param inputs text block and boolean value - * @returns control that has enabled or disabled resize to fit - * @group set - * @shortname set resize to fit - */ - setRsizeToFit( - inputs: Inputs.BabylonGui.SetTextBlockResizeToFitDto - ): BABYLON.GUI.TextBlock; - /** - * Sets the new text wrapping to the text block - * @param inputs text block and text wrapping - * @returns control that has changed text wrapping - * @group set - * @shortname set text wrapping - */ - setTextWrapping( - inputs: Inputs.BabylonGui.SetTextBlockTextWrappingDto - ): BABYLON.GUI.TextBlock; - /** - * Sets the line spacing of the text - * @param inputs text block and line spacing - * @returns control that has changed line spacing - * @group set - * @shortname set line spacing - */ - setLineSpacing( - inputs: Inputs.BabylonGui.SetTextBlockLineSpacingDto - ): BABYLON.GUI.TextBlock; - /** - * Gets the text of the text block - * @param inputs text block - * @returns text of the text block - * @group get - * @shortname get text block text - */ - getText(inputs: Inputs.BabylonGui.TextBlockDto): string; - /** - * Gets the text wrapping of the text block - * @param inputs text block - * @returns text wrapping of the text block - * @group get - * @shortname get text wrapping - */ - getTextWrapping( - inputs: Inputs.BabylonGui.TextBlockDto - ): boolean | BABYLON.GUI.TextWrapping; - /** - * Gets the line spacing of the text block - * @param inputs text block - * @returns line spacing of the text block - * @group get - * @shortname get line spacing - */ - getLineSpacing(inputs: Inputs.BabylonGui.TextBlockDto): string | number; - /** - * Gets the outline width of the text block - * @param inputs text block - * @returns outline width of the text block - * @group get - * @shortname get outline width - */ - getOutlineWidth(inputs: Inputs.BabylonGui.TextBlockDto): number; - /** - * Gets the resize to fit of the text block - * @param inputs text block - * @returns resize to fit of the text block - * @group get - * @shortname get resize to fit - */ - getResizeToFit(inputs: Inputs.BabylonGui.TextBlockDto): boolean; - /** - * Gets the text horizontal alignment of the text block - * @param inputs text block - * @returns text horizontal alignment of the text block - * @group get - * @shortname get text horizontal alignment - */ - getTextHorizontalAlignment(inputs: Inputs.BabylonGui.TextBlockDto): number; - /** - * Gets the text vertical alignment of the text block - * @param inputs text block - * @returns text vertical alignment of the text block - * @group get - * @shortname get text vertical alignment - */ - getTextVerticalAlignment(inputs: Inputs.BabylonGui.TextBlockDto): number; - /** - * Creates the selector of an observable for a text block - * @param inputs observable name - * @group create - * @shortname text block observable selector - */ - createTextBlockObservableSelector( - inputs: Inputs.BabylonGui.TextBlockObservableSelectorDto - ): Inputs.BabylonGui.textBlockObservableSelectorEnum; - } - declare class BabylonIO { - private readonly context; - private supportedFileFormats; - private objectUrl; - constructor(context: Context); - /** - * Imports mesh from the asset that you have uploaded for the project. - * You must upload your assets to your project via project management page. - * @returns scene loaded mesh - * @group load - * @shortname asset - */ - loadAssetIntoScene( - inputs: Inputs.Asset.AssetFileDto - ): Promise; - /** - * Imports mesh from the asset that you have uploaded for the project. - * You must upload your assets to your project via project management page. - * @returns scene loaded mesh - * @group load - * @shortname asset - */ - loadAssetIntoSceneNoReturn( - inputs: Inputs.Asset.AssetFileDto - ): Promise; - /** - * Imports mesh from the asset url that you have uploaded to an accessible web storage. - * Keep in mind that files need to be publically accessible for this to work, be sure that CORS access is enabled for the assets. - * @returns scene loaded mesh - * @group load - * @shortname asset from url - */ - loadAssetIntoSceneFromRootUrl( - inputs: Inputs.Asset.AssetFileByUrlDto - ): Promise; - /** - * Imports mesh from the asset url that you have uploaded to an accessible web storage. - * Keep in mind that files need to be publically accessible for this to work, be sure that CORS access is enabled for the assets. - * @returns scene loaded mesh - * @group load - * @shortname asset from url - */ - loadAssetIntoSceneFromRootUrlNoReturn( - inputs: Inputs.Asset.AssetFileByUrlDto - ): Promise; - /** - * Exports the whole scene to .babylon scene format. You can then edit it further in babylonjs editors. - * @param inputs filename - * @group export - * @shortname babylon scene - */ - exportBabylon(inputs: Inputs.BabylonIO.ExportSceneDto): void; - /** - * Exports the whole scene to .glb format. This file format has become industry standard for web models. - * @param inputs filename - * @group export - * @shortname gltf scene - */ - exportGLB(inputs: Inputs.BabylonIO.ExportSceneGlbDto): void; - /** - * Exports the mesh with its children to stl - * @param inputs filename and the mesh - * @group export - * @shortname babylon mesh to stl - */ - exportMeshToStl(inputs: Inputs.BabylonIO.ExportMeshToStlDto): Promise; - /** - * Exports the meshes to stl - * @param inputs filename and the mesh - * @group export - * @shortname babylon meshes to stl - */ - exportMeshesToStl( - inputs: Inputs.BabylonIO.ExportMeshesToStlDto - ): Promise; - private loadAsset; - } - declare class BabylonLights { - private readonly context; - shadowLight: BabylonShadowLight; - constructor(context: Context); - } - declare class BabylonShadowLight { - private readonly context; - constructor(context: Context); - /** - * Sets the direction of the shadow light - * @param inputs shadow light and direction - * @group set - * @shortname set target - */ - setDirectionToTarget( - inputs: Inputs.BabylonLight.ShadowLightDirectionToTargetDto - ): void; - /** - * Sets the position of the shadow light - * @param inputs shadow light and position - * @group set - * @shortname set position - */ - setPosition(inputs: Inputs.BabylonLight.ShadowLightPositionDto): void; - } - declare class BabylonMaterial { - private readonly context; - private readonly color; - pbrMetallicRoughness: BabylonMaterialPbrMetallicRoughness; - skyMaterial: BabylonMaterialSky; - constructor(context: Context, color: Color); - } - declare class BabylonMaterialPbrMetallicRoughness { - private readonly context; - private readonly color; - constructor(context: Context, color: Color); - /** - * Create PBR metallic roughnes material. - * @param inputs required to set up metallic roughness material - * @returns PBR metallic roughness material - * @group create - * @shortname pbr material - * @disposableOutput true - */ - create( - inputs: Inputs.BabylonMaterial.PBRMetallicRoughnessDto - ): BABYLON.PBRMetallicRoughnessMaterial; - /** - * Sets the base color of material - * @param inputs base color and material - * @group set - * @shortname set base color - */ - setBaseColor(inputs: Inputs.BabylonMaterial.BaseColorDto): void; - /** - * Sets the metallic property of material - * @param inputs metallic value - * @group set - * @shortname set metallic - */ - setMetallic(inputs: Inputs.BabylonMaterial.MetallicDto): void; - /** - * Sets the roughness of material - * @param inputs roughness value - * @group set - * @shortname set roughness - */ - setRoughness(inputs: Inputs.BabylonMaterial.RoughnessDto): void; - /** - * Sets the alpha of material - * @param inputs alpha value - * @group set - * @shortname set alpha - */ - setAlpha(inputs: Inputs.BabylonMaterial.AlphaDto): void; - /** - * Sets the back face culling of material - * @param inputs back face culling boolean - * @group set - * @shortname set back face culling - */ - setBackFaceCulling(inputs: Inputs.BabylonMaterial.BackFaceCullingDto): void; - /** - * Sets the texture of material - * @param inputs texture and material - * @group set - * @shortname set base texture - */ - setBaseTexture(inputs: Inputs.BabylonMaterial.BaseTextureDto): void; - /** - * Gets the base color of material - * @param inputs material - * @return base color - * @group get - * @shortname get base color - */ - getBaseColor(inputs: Inputs.BabylonMaterial.MaterialPropDto): string; - /** - * Gets the metallic property of material - * @param inputs material - * @return metallic value - * @group get - * @shortname get metallic - */ - getMetallic(inputs: Inputs.BabylonMaterial.MaterialPropDto): number; - /** - * Gets the roughness of material - * @param inputs material - * @return roughness value - * @group get - * @shortname get roughness - */ - getRoughness(inputs: Inputs.BabylonMaterial.MaterialPropDto): number; - /** - * Gets the alpha of material - * @param inputs material - * @return alpha value - * @group get - * @shortname get alpha - */ - getAlpha(inputs: Inputs.BabylonMaterial.MaterialPropDto): number; - /** - * Gets the back face culling of material - * @param inputs material - * @return backfaceculling boolean - * @group get - * @shortname get back face culling - */ - getBackFaceCulling(inputs: Inputs.BabylonMaterial.MaterialPropDto): boolean; - /** - * Get the base texture of material - * @param inputs material - * @group get - * @shortname get base texture - */ - getBaseTexture( - inputs: Inputs.BabylonMaterial.MaterialPropDto - ): BABYLON.BaseTexture; - } - declare class BabylonMaterialSky { - private readonly context; - constructor(context: Context); - /** - * Create Sky Material - * @param inputs required to set up the sky material - * @returns Sky material - * @group create - * @shortname sky material - */ - create(inputs: Inputs.BabylonMaterial.SkyMaterialDto): SkyMaterial; - /** - * Sets the luminance of the sky material - * @param inputs luminance value and material - * @group set - * @shortname set luminance - */ - setLuminance(inputs: Inputs.BabylonMaterial.LuminanceDto): void; - /** - * Sets the turbidity of the sky material - * @param inputs turbidity value and material - * @group set - * @shortname set turbidity - */ - setTurbidity(inputs: Inputs.BabylonMaterial.TurbidityDto): void; - /** - * Sets the rayleigh of the sky material - * @param inputs rayleigh value and material - * @group set - * @shortname set rayleigh - */ - setRayleigh(inputs: Inputs.BabylonMaterial.RayleighDto): void; - /** - * Sets the mieCoefficient of the sky material - * @param inputs mieCoefficient value and material - * @group set - * @shortname set mieCoefficient - */ - setMieCoefficient(inputs: Inputs.BabylonMaterial.MieCoefficientDto): void; - /** - * Sets the mieDirectionalG of the sky material - * @param inputs mieDirectionalG value and material - * @group set - * @shortname set mieDirectionalG - */ - setMieDirectionalG(inputs: Inputs.BabylonMaterial.MieDirectionalGDto): void; - /** - * Sets the distance of the sky material - * @param inputs distance value and material - * @group set - * @shortname set distance - */ - setDistance(inputs: Inputs.BabylonMaterial.DistanceDto): void; - /** - * Sets the inclination of the sky material - * @param inputs inclination value and material - * @group set - * @shortname set inclination - */ - setInclination(inputs: Inputs.BabylonMaterial.InclinationDto): void; - /** - * Sets the azimuth of the sky material - * @param inputs azimuth value and material - * @group set - * @shortname set azimuth - */ - setAzimuth(inputs: Inputs.BabylonMaterial.AzimuthDto): void; - /** - * Sets the sun position of the sky material - * @param inputs sun position value and material - * @group set - * @shortname set sun position - */ - setSunPosition(inputs: Inputs.BabylonMaterial.SunPositionDto): void; - /** - * Sets the use sun position of the sky material - * @param inputs use sun position value and material - * @group set - * @shortname set use sun position - */ - setUseSunPosition(inputs: Inputs.BabylonMaterial.UseSunPositionDto): void; - /** - * Sets the camera offset of the sky material - * @param inputs camera offset value and material - * @group set - * @shortname set camera offset - */ - setCameraOffset(inputs: Inputs.BabylonMaterial.CameraOffsetDto): void; - /** - * Sets the up of the sky material - * @param inputs up value and material - * @group set - * @shortname set up - */ - setUp(inputs: Inputs.BabylonMaterial.UpDto): void; - /** - * Sets the dithering of the sky material - * @param inputs dithering value and material - * @group set - * @shortname set dithering - */ - setDithering(inputs: Inputs.BabylonMaterial.DitheringDto): void; - /** - * Gets the luminance of the sky material - * @param inputs material - * @group get - * @shortname get luminance - */ - getLuminance(inputs: Inputs.BabylonMaterial.SkyMaterialPropDto): number; - /** - * Gets the turbidity of the sky material - * @param inputs material - * @group get - * @shortname get turbidity - */ - getTurbidity(inputs: Inputs.BabylonMaterial.SkyMaterialPropDto): number; - /** - * Gets the rayleigh of the sky material - * @param inputs material - * @group get - * @shortname get rayleigh - */ - getRayleigh(inputs: Inputs.BabylonMaterial.SkyMaterialPropDto): number; - /** - * Gets the mieCoefficient of the sky material - * @param inputs material - * @group get - * @shortname get mieCoefficient - */ - getMieCoefficient( - inputs: Inputs.BabylonMaterial.SkyMaterialPropDto - ): number; - /** - * Gets the mieDirectionalG of the sky material - * @param inputs material - * @group get - * @shortname get mieDirectionalG - */ - getMieDirectionalG( - inputs: Inputs.BabylonMaterial.SkyMaterialPropDto - ): number; - /** - * Gets the distance of the sky material - * @param inputs material - * @group get - * @shortname get distance - */ - getDistance(inputs: Inputs.BabylonMaterial.SkyMaterialPropDto): number; - /** - * Gets the inclination of the sky material - * @param inputs material - * @group get - * @shortname get inclination - */ - getInclination(inputs: Inputs.BabylonMaterial.SkyMaterialPropDto): number; - /** - * Gets the azimuth of the sky material - * @param inputs material - * @group get - * @shortname get azimuth - */ - getAzimuth(inputs: Inputs.BabylonMaterial.SkyMaterialPropDto): number; - /** - * Gets the sun position of the sky material - * @param inputs material - * @group get - * @shortname get sun position - */ - getSunPosition( - inputs: Inputs.BabylonMaterial.SkyMaterialPropDto - ): Inputs.Base.Vector3; - /** - * Gets the use sun position of the sky material - * @param inputs material - * @group get - * @shortname get use sun position - */ - getUseSunPosition( - inputs: Inputs.BabylonMaterial.SkyMaterialPropDto - ): boolean; - /** - * Gets the camera offset of the sky material - * @param inputs material - * @group get - * @shortname get camera offset - */ - getCameraOffset( - inputs: Inputs.BabylonMaterial.SkyMaterialPropDto - ): Inputs.Base.Vector3; - /** - * Gets the up of the sky material - * @param inputs material - * @group get - * @shortname get up - */ - getUp( - inputs: Inputs.BabylonMaterial.SkyMaterialPropDto - ): Inputs.Base.Vector3; - /** - * Gets the dithering of the sky material - * @param inputs material - * @group get - * @shortname get dithering - */ - getDithering(inputs: Inputs.BabylonMaterial.SkyMaterialPropDto): boolean; - } - declare class BabylonMeshBuilder { - private readonly context; - private readonly mesh; - constructor(context: Context, mesh: BabylonMesh); - /** - * Creates a box mesh - * @param inputs required to set up basic box - * @returns Babylon mesh - * @group create simple - * @shortname create box - * @disposableOutput true - * @drawable true - */ - createBox(inputs: Inputs.BabylonMeshBuilder.CreateBoxDto): BABYLON.Mesh; - /** - * Creates a cube mesh - * @param inputs required to set up basic cube - * @returns Babylon mesh - * @group create simple - * @shortname create cube - * @disposableOutput true - * @drawable true - */ - createCube(inputs: Inputs.BabylonMeshBuilder.CreateCubeDto): BABYLON.Mesh; - /** - * Creates a square plane mesh - * @param inputs required to set up basic cube - * @returns Babylon mesh - * @group create simple - * @shortname square plane - * @disposableOutput true - * @drawable true - */ - createSquarePlane( - inputs: Inputs.BabylonMeshBuilder.CreateSquarePlaneDto - ): BABYLON.Mesh; - /** - * Creates a sphere mesh - * @param inputs required to set up basic sphere - * @returns Babylon mesh - * @group create simple - * @shortname create sphere - * @disposableOutput true - * @drawable true - */ - createSphere( - inputs: Inputs.BabylonMeshBuilder.CreateSphereDto - ): BABYLON.Mesh; - /** - * Create ico sphere - * @param inputs required to set up a ico sphere - * @returns Babylon mesh - * @group create simple - * @shortname create ico sphere - * @disposableOutput true - * @drawable true - */ - createIcoSphere( - inputs: Inputs.BabylonMeshBuilder.CreateIcoSphereDto - ): BABYLON.Mesh; - /** - * Creates a disc - * @param inputs required to set up a disc - * @returns Babylon mesh - * @group create simple - * @shortname create disc - * @disposableOutput true - * @drawable true - */ - createDisc(inputs: Inputs.BabylonMeshBuilder.CreateDiscDto): BABYLON.Mesh; - /** - * Create a torus mesh - * @param inputs required to set up a torus - * @returns Babylon mesh - * @group create simple - * @shortname create torus - * @disposableOutput true - * @drawable true - */ - createTorus(inputs: Inputs.BabylonMeshBuilder.CreateTorusDto): BABYLON.Mesh; - /** - * Create a torus knot mesh - * @param inputs required to set up a torus knot - * @returns Babylon mesh - * @group create simple - * @shortname create torus knot - * @disposableOutput true - * @drawable true - */ - createTorusKnot( - inputs: Inputs.BabylonMeshBuilder.CreateTorusKnotDto - ): BABYLON.Mesh; - /** - * Create a polygon mesh - * @param inputs required to set up a polygon - * @returns Babylon mesh - * @group create simple - * @shortname create polygon - * @disposableOutput true - * @drawable true - */ - createPolygon( - inputs: Inputs.BabylonMeshBuilder.CreatePolygonDto - ): BABYLON.Mesh; - /** - * Create extruded polygon mesh - * @param inputs required to set up a extrude polygon - * @returns Babylon mesh - * @group create simple - * @shortname create extrude polygon - * @disposableOutput true - * @drawable true - */ - extrudePolygon( - inputs: Inputs.BabylonMeshBuilder.ExtrudePolygonDto - ): BABYLON.Mesh; - /** - * Create a tube mesh - * @param inputs required to set up a tube - * @returns Babylon mesh - * @group create simple - * @shortname create tube - * @disposableOutput true - * @drawable true - */ - createTube(inputs: Inputs.BabylonMeshBuilder.CreateTubeDto): BABYLON.Mesh; - /** - * Create a polyhedron mesh - * @param inputs required to set up a polyhedron - * @returns Babylon mesh - * @group create simple - * @shortname create polyhedron - * @disposableOutput true - * @drawable true - */ - createPolyhedron( - inputs: Inputs.BabylonMeshBuilder.CreatePolyhedronDto - ): BABYLON.Mesh; - /** - * Create geodesic mesh - * @param inputs required to set up a geodesic - * @returns Babylon mesh - * @group create simple - * @shortname create geodesic - * @disposableOutput true - * @drawable true - */ - createGeodesic( - inputs: Inputs.BabylonMeshBuilder.CreateGeodesicDto - ): BABYLON.Mesh; - /** - * Create goldberg mesh - * @param inputs required to set up a goldberg mesh - * @returns Babylon mesh - * @group create simple - * @shortname create goldberg - * @disposableOutput true - * @drawable true - */ - createGoldberg( - inputs: Inputs.BabylonMeshBuilder.CreateGoldbergDto - ): BABYLON.Mesh; - /** - * Create capsule mesh - * @param inputs required to set up a capsule - * @returns Babylon mesh - * @group create simple - * @shortname create capsule - * @disposableOutput true - * @drawable true - */ - createCapsule( - inputs: Inputs.BabylonMeshBuilder.CreateCapsuleDto - ): BABYLON.Mesh; - /** - * Create a cylinder mesh - * @param inputs required to set up a cylinder - * @returns Babylon mesh - * @group create simple - * @shortname create cylinder - * @disposableOutput true - * @drawable true - */ - createCylinder( - inputs: Inputs.BabylonMeshBuilder.CreateCylinderDto - ): BABYLON.Mesh; - /** - * Create extruded shape - * @param inputs required to set up a extrude shape - * @returns Babylon mesh - * @group create simple - * @shortname create extruded shape - * @disposableOutput true - * @drawable true - */ - createExtrudedSahpe( - inputs: Inputs.BabylonMeshBuilder.CreateExtrudedShapeDto - ): BABYLON.Mesh; - /** - * Create a ribbon mesh - * @param inputs required to set up a ribbon - * @returns Babylon mesh - * @group create simple - * @shortname create ribbon - * @disposableOutput true - * @drawable true - */ - createRibbon( - inputs: Inputs.BabylonMeshBuilder.CreateRibbonDto - ): BABYLON.Mesh; - /** - * Create lathe mesh - * @param inputs required to set up a lathe - * @returns Babylon mesh - * @group create simple - * @shortname create lathe - * @disposableOutput true - * @drawable true - */ - createLathe(inputs: Inputs.BabylonMeshBuilder.CreateLatheDto): BABYLON.Mesh; - /** - * Create the ground mesh - * @param inputs required to set up a ground - * @returns Babylon mesh - * @group create simple - * @shortname create ground - * @disposableOutput true - * @drawable true - */ - createGround( - inputs: Inputs.BabylonMeshBuilder.CreateGroundDto - ): BABYLON.Mesh; - /** - * Creates a rectangle plane mesh - * @param inputs required to set up basic cube - * @returns Babylon mesh - * @group create simple - * @shortname rectangle plane - * @disposableOutput true - * @drawable true - */ - createRectanglePlane( - inputs: Inputs.BabylonMeshBuilder.CreateRectanglePlaneDto - ): BABYLON.Mesh; - private enableShadows; - } - declare class BabylonMesh { - private readonly context; - constructor(context: Context); - /** Disposes drawn mesh object from the scene - * @param inputs Contains BabylonJS mesh that should be disposed - * @group memory - * @shortname dispose - */ - dispose(inputs: Inputs.BabylonMesh.BabylonMeshDto): void; - /** Udates drawn BabylonJS mesh object without disposing it - * @param inputs Contains BabylonJS mesh that should be updated, together with position, rotation, scaling and colour info - * @returns BabylonJS Mesh - * @group updates - * @shortname update drawn - */ - updateDrawn(inputs: Inputs.BabylonMesh.UpdateDrawnBabylonMesh): void; - /** - * Change the visibility of a drawn BabylonJS mesh - * @param inputs BabylonJS mesh and parent mesh - * @group visibility - * @shortname set visibility - */ - setVisibility(inputs: Inputs.BabylonMesh.SetMeshVisibilityDto): void; - /** - * Hides the mesh - * @param inputs BabylonJS mesh to hide - * @group visibility - * @shortname hide - */ - hide(inputs: Inputs.BabylonMesh.ShowHideMeshDto): void; - /** - * Show the mesh - * @param inputs BabylonJS mesh to hide - * @group visibility - * @shortname show - */ - show(inputs: Inputs.BabylonMesh.ShowHideMeshDto): void; - /** - * Change the parent of the drawn mesh - * @param inputs BabylonJS mesh and parent mesh - * @group set - * @shortname parent - */ - setParent(inputs: Inputs.BabylonMesh.SetParentDto): void; - /** - * Get the parent of the drawn mesh - * @param inputs BabylonJS mesh - * @returns Parent mesh - * @group get - * @shortname parent - */ - getParent(inputs: Inputs.BabylonMesh.SetParentDto): BABYLON.Node; - /** - * Change the check collisions property of the drawn mesh - * @param inputs BabylonJS mesh and check collisions - * @group set - * @shortname check collisions - */ - setCheckCollisions( - inputs: Inputs.BabylonMesh.CheckCollisionsBabylonMeshDto - ): void; - /** - * Get the check collisions property of the drawn mesh - * @param inputs BabylonJS mesh and check collisions - * @group get - * @shortname check collisions - */ - getCheckCollisions( - inputs: Inputs.BabylonMesh.CheckCollisionsBabylonMeshDto - ): boolean; - /** - * Change the pickable property of the drawn mesh - * @param inputs BabylonJS mesh and pickable - * @group get - * @shortname check collisions - */ - setPickable(inputs: Inputs.BabylonMesh.PickableBabylonMeshDto): void; - /** - * Force mesh to be pickable by pointer move events, default is false as it is performance heavy - * @param inputs BabylonJS mesh - * @group set - * @shortname enable pointer move events - */ - enablePointerMoveEvents( - inputs: Inputs.BabylonMesh.BabylonMeshWithChildrenDto - ): void; - /** - * Make mesh ignore pointer move events, default is false - * @param inputs BabylonJS mesh and pickable - * @group set - * @shortname disable pointer move events - */ - disablePointerMoveEvents( - inputs: Inputs.BabylonMesh.BabylonMeshWithChildrenDto - ): void; - /** - * Change the pickable property of the drawn mesh - * @param inputs BabylonJS mesh and pickable - * @group get - * @shortname pickable - */ - getPickable(inputs: Inputs.BabylonMesh.BabylonMeshDto): boolean; - /** - * Gets meshes that have names which contain a given text - * @param inputs BabylonJS mesh and name - * @group get - * @shortname meshes where name contains - */ - getMeshesWhereNameContains( - inputs: Inputs.BabylonMesh.ByNameBabylonMeshDto - ): BABYLON.AbstractMesh[]; - /** - * Gets child meshes - * @param inputs BabylonJS mesh and whether to include only direct descendants - * @group get - * @shortname child meshes - */ - getChildMeshes( - inputs: Inputs.BabylonMesh.ChildMeshesBabylonMeshDto - ): BABYLON.AbstractMesh[]; - /** - * Gets meshes of id - * @param inputs BabylonJS mesh and name - * @group get - * @shortname meshes by id - */ - getMeshesOfId( - inputs: Inputs.BabylonMesh.ByIdBabylonMeshDto - ): BABYLON.AbstractMesh[]; - /** - * Gets mesh of id - * @param inputs BabylonJS mesh and name - * @group get - * @shortname mesh by id - */ - getMeshOfId( - inputs: Inputs.BabylonMesh.ByIdBabylonMeshDto - ): BABYLON.AbstractMesh; - /** - * Gets mesh of unique id - * @param inputs BabylonJS mesh and name - * @group get - * @shortname mesh by unique id - */ - getMeshOfUniqueId( - inputs: Inputs.BabylonMesh.UniqueIdBabylonMeshDto - ): BABYLON.AbstractMesh; - /** - * Merges multiple meshes into one - * @param inputs BabylonJS meshes and options - * @returns a new mesh - * @group edit - * @shortname merge - */ - mergeMeshes(inputs: Inputs.BabylonMesh.MergeMeshesDto): BABYLON.Mesh; - /** Convers mesh to flat shaded mesh - * @param inputs BabylonJS mesh - * @returns a new mesh - * @group edit - * @shortname convert to flat shaded - */ - convertToFlatShadedMesh( - inputs: Inputs.BabylonMesh.BabylonMeshDto - ): BABYLON.Mesh; - /** - * Clones the mesh - * @param inputs BabylonJS mesh to clone - * @returns a new mesh - * @group edit - * @shortname clone - * @disposableOutput true - */ - clone(inputs: Inputs.BabylonMesh.BabylonMeshDto): BABYLON.Mesh; - /** - * Clones the mesh to positions - * @param inputs BabylonJS mesh and positions - * @returns a new mesh - * @group edit - * @shortname clone to positions - * @disposableOutput true - * @drawable true - */ - cloneToPositions( - inputs: Inputs.BabylonMesh.CloneToPositionsDto - ): BABYLON.Mesh[]; - /** - * Change the id of the drawn mesh - * @param inputs BabylonJS mesh and name - * @group set - * @shortname id - */ - setId(inputs: Inputs.BabylonMesh.IdBabylonMeshDto): void; - /** - * Get the id of the drawn mesh - * @param inputs BabylonJS mesh and id - * @group get - * @shortname id - */ - getId(inputs: Inputs.BabylonMesh.IdBabylonMeshDto): string; - /** - * Get the unique id of the drawn mesh - * @param inputs BabylonJS mesh and id - * @returns unique id number - * @group get - * @shortname unique id - */ - getUniqueId(inputs: Inputs.BabylonMesh.BabylonMeshDto): number; - /** - * Change the name of the drawn mesh - * @param inputs BabylonJS mesh and name - * @group set - * @shortname name - */ - setName(inputs: Inputs.BabylonMesh.NameBabylonMeshDto): void; - /** - * Gets the vertices as polygon points. These can be used with other construction methods to create meshes. Mesh must be triangulated. - * @param inputs BabylonJS mesh and name - * @group get - * @shortname vertices as polygon points - */ - getVerticesAsPolygonPoints( - inputs: Inputs.BabylonMesh.BabylonMeshDto - ): Base.Point3[][]; - /** - * Gets the name of babylon mesh - * @param inputs BabylonJS mesh and name - * @group get - * @shortname name - */ - getName(inputs: Inputs.BabylonMesh.BabylonMeshDto): string; - /** - * Change the material of the drawn mesh - * @param inputs BabylonJS mesh and material - * @group set - * @shortname material - */ - setMaterial(inputs: Inputs.BabylonMesh.MaterialBabylonMeshDto): void; - /** - * Gets the material of babylon mesh - * @param inputs BabylonJS mesh - * @group get - * @shortname material - */ - getMaterial(inputs: Inputs.BabylonMesh.BabylonMeshDto): BABYLON.Material; - /** - * Gets the position as point of babylonjs mesh - * @param inputs BabylonJS mesh - * @returns point - * @group get - * @shortname position - */ - getPosition(inputs: Inputs.BabylonMesh.BabylonMeshDto): Base.Point3; - /** - * Gets the absolute position in the world as point of babylonjs mesh - * @param inputs BabylonJS mesh - * @returns point - * @group get - * @shortname absolute position - */ - getAbsolutePosition(inputs: Inputs.BabylonMesh.BabylonMeshDto): Base.Point3; - /** - * Gets the rotation vector of babylonjs mesh - * @param inputs BabylonJS mesh - * @group get - * @shortname rotation - */ - getRotation(inputs: Inputs.BabylonMesh.BabylonMeshDto): Base.Point3; - /** - * Gets the scale vector of babylonjs mesh - * @param inputs BabylonJS mesh - * @group get - * @shortname scale - */ - getScale(inputs: Inputs.BabylonMesh.BabylonMeshDto): Base.Point3; - /** - * Moves babylonjs mesh forward in local space - * @param inputs BabylonJS mesh and distance - * @group move - * @shortname forward - */ - moveForward(inputs: Inputs.BabylonMesh.TranslateBabylonMeshDto): void; - /** - * Moves babylonjs mesh backward in local space - * @param inputs BabylonJS mesh and distance - * @group move - * @shortname backward - */ - moveBackward(inputs: Inputs.BabylonMesh.TranslateBabylonMeshDto): void; - /** - * Moves babylonjs mesh up in local space - * @param inputs BabylonJS mesh and distance - * @group move - * @shortname up - */ - moveUp(inputs: Inputs.BabylonMesh.TranslateBabylonMeshDto): void; - /** - * Moves babylonjs mesh down in local space - * @param inputs BabylonJS mesh and distance - * @group move - * @shortname down - */ - moveDown(inputs: Inputs.BabylonMesh.TranslateBabylonMeshDto): void; - /** - * Moves babylonjs mesh right in local space - * @param inputs BabylonJS mesh and distance - * @group move - * @shortname right - */ - moveRight(inputs: Inputs.BabylonMesh.TranslateBabylonMeshDto): void; - /** - * Moves babylonjs mesh left in local space - * @param inputs BabylonJS mesh and distance - * @group move - * @shortname left - */ - moveLeft(inputs: Inputs.BabylonMesh.TranslateBabylonMeshDto): void; - /** - * Rotates babylonjs mesh around local y axis - * @param inputs BabylonJS mesh and rotation in degrees - * @group move - * @shortname yaw - */ - yaw(inputs: Inputs.BabylonMesh.RotateBabylonMeshDto): void; - /** - * Rotates babylonjs mesh around local x axis - * @param inputs BabylonJS mesh and rotation in degrees - * @group move - * @shortname pitch - */ - pitch(inputs: Inputs.BabylonMesh.RotateBabylonMeshDto): void; - /** - * Rotates babylonjs mesh around local z axis - * @param inputs BabylonJS mesh and rotation in degrees - * @group move - * @shortname roll - */ - roll(inputs: Inputs.BabylonMesh.RotateBabylonMeshDto): void; - /** - * Rotates the mesh around axis and given position by a given angle - * @param inputs Rotation around axis information - * @group move - * @shortname rotate around axis with position - */ - rotateAroundAxisWithPosition( - inputs: Inputs.BabylonMesh.RotateAroundAxisNodeDto - ): void; - /** - * Updates the position of the BabylonJS mesh or instanced mesh - * @param inputs BabylonJS mesh and position point - * @group set - * @shortname position - */ - setPosition( - inputs: Inputs.BabylonMesh.UpdateDrawnBabylonMeshPositionDto - ): void; - /** - * Updates the rotation of the BabylonJS mesh or instanced mesh - * @param inputs BabylonJS mesh and rotation along x, y and z axis in degrees - * @group set - * @shortname rotation - */ - setRotation( - inputs: Inputs.BabylonMesh.UpdateDrawnBabylonMeshRotationDto - ): void; - /** - * Updates the scale of the BabylonJS mesh or instanced mesh - * @param inputs BabylonJS mesh and scale vector - * @group set - * @shortname scale - */ - setScale(inputs: Inputs.BabylonMesh.UpdateDrawnBabylonMeshScaleDto): void; - /** - * Scales the BabylonJS mesh or instanced mesh in place by a given factor - * @param inputs BabylonJS mesh and scale factor - * @group set - * @shortname scale in place - */ - setLocalScale(inputs: Inputs.BabylonMesh.ScaleInPlaceDto): void; - /** - * Checks wether mesh intersects another mesh mesh - * @param inputs Two BabylonJS meshes - * @group intersects - * @shortname mesh - */ - intersectsMesh(inputs: Inputs.BabylonMesh.IntersectsMeshDto): boolean; - /** - * Checks wether mesh intersects point - * @param inputs BabylonJS mesh and point - * @group intersects - * @shortname point - */ - intersectsPoint(inputs: Inputs.BabylonMesh.IntersectsPointDto): boolean; - /** - * Creates mesh instance for optimised rendering. This method will check if mesh contains children and will create instances for each child. - * These are optimised for max performance when rendering many similar objects in the scene. This method returns instances as childrens in a new mesh. - * If the mesh has children, then every child goes a mesh instance. - * @group instance - * @shortname create and transform - * @disposableOutput true - */ - createMeshInstanceAndTransformNoReturn( - inputs: Inputs.BabylonMesh.MeshInstanceAndTransformDto - ): void; - /** - * Creates mesh instance for optimised rendering. This method will check if mesh contains children and will create instances for each child. - * These are optimised for max performance when rendering many similar objects in the scene. This method returns instances as childrens in a new mesh. - * If the mesh has children, then every child goes a mesh instance. - * @group instance - * @returns babylon mesh - * @shortname create and transform - * @disposableOutput true - */ - createMeshInstanceAndTransform( - inputs: Inputs.BabylonMesh.MeshInstanceAndTransformDto - ): BABYLON.Mesh; - /** - * Creates mesh instance. These are optimised for max performance - * when rendering many similar objects in the scene. If the mesh has children, then every child gets a mesh instance. - * @group instance - * @shortname create - * @disposableOutput true - */ - createMeshInstance( - inputs: Inputs.BabylonMesh.MeshInstanceDto - ): BABYLON.Mesh; - /** - * Gets side orientation - * @ignore true - */ - getSideOrientation( - sideOrientation: Inputs.BabylonMesh.sideOrientationEnum - ): number; - private assignColorToMesh; - } - /** - * Nodes help understand the space and construct more complicated space structures. Nodes can be nested together - * into child parent relationships to simplify the creation of 3D objects. - */ - declare class BabylonNode { - private readonly context; - private readonly drawHelper; - constructor(context: Context, drawHelper: DrawHelper); - /** - * Draws a node of given size with given colours for every axis - * @param inputs Contains node data that includes size and colour information - */ - drawNode(inputs: Inputs.BabylonNode.DrawNodeDto): void; - /** - * Draws a nodes of given size with given colours for every axis - * @param inputs Contains node data that includes size and colour information - */ - drawNodes(inputs: Inputs.BabylonNode.DrawNodesDto): void; - /** - * Creates a node on the origin with the given rotations in the parent coordinate system - * @param inputs Contains information for origin, rotation and parent node - * @returns A new node - */ - createNodeFromRotation( - inputs: Inputs.BabylonNode.CreateNodeFromRotationDto - ): BABYLON.TransformNode; - /** - * Creates a world node which has root node as his parent - * @returns A new node whos parent is the root node of the scene - */ - createWorldNode(): BABYLON.TransformNode; - /** - * Gets the absolute forward facing vector in world space - * @param inputs Node from which to get the forward vector - * @returns Vector as an array of numbers - */ - getAbsoluteForwardVector(inputs: Inputs.BabylonNode.NodeDto): number[]; - /** - * Gets the absolute right facing vector in world space - * @param inputs Node from which to get the right vector - * @returns Vector as an array of numbers - */ - getAbsoluteRightVector(inputs: Inputs.BabylonNode.NodeDto): number[]; - /** - * Gets the absolute up facing vector in world space - * @param inputs Node from which to get the up vector - * @returns Vector as an array of numbers - */ - getAbsoluteUpVector(inputs: Inputs.BabylonNode.NodeDto): number[]; - /** - * Gets the absolute position of the node as origin vector in world space - * @param inputs Node from which to get the absolute position - * @returns Vector as an array of numbers indicating location of origin in world space - */ - getAbsolutePosition(inputs: Inputs.BabylonNode.NodeDto): number[]; - /** - * Gets the absolute rotation of the node as a transformation matrix encoded in array of 16 numbers - * @param inputs Node from which to get the rotation transformation - * @returns Transformation as an array of 16 numbers - */ - getAbsoluteRotationTransformation( - inputs: Inputs.BabylonNode.NodeDto - ): number[]; - /** - * Gets the rotation of the node in local parent coordinate space as a transformation matrix encoded in array of 16 numbers - * @param inputs Node from which to get the rotation transformation - * @returns Transformation as an array of 16 numbers - */ - getRotationTransformation(inputs: Inputs.BabylonNode.NodeDto): number[]; - /** - * Gets children of the node - * @param inputs Node from which to get the children - * @returns List of children nodes in the array - */ - getChildren(inputs: Inputs.BabylonNode.NodeDto): BABYLON.Node[]; - /** - * Gets parent of the node - * @param inputs Node from which to get a parent - * @returns Parent node - */ - getParent(inputs: Inputs.BabylonNode.NodeDto): BABYLON.Node; - /** - * Gets the position of the node expressed in local space - * @param inputs Node from which to get the position in local space - * @returns Position vector - */ - getPositionExpressedInLocalSpace( - inputs: Inputs.BabylonNode.NodeDto - ): number[]; - /** - * Gets the root node - * @returns Root node - */ - getRootNode(): BABYLON.TransformNode; - /** - * Gets the euler rotations - * @param inputs Node from which to get rotation - * @returns Euler rotations of x, y and z angles in the number array - */ - getRotation(inputs: Inputs.BabylonNode.NodeDto): number[]; - /** - * Rotates the node around axis and given position by a given angle - * @param inputs Rotation around axis information - */ - rotateAroundAxisWithPosition( - inputs: Inputs.BabylonNode.RotateAroundAxisNodeDto - ): void; - /** - * Rotates the node around the origin and given axis - * @param inputs Rotation information - */ - rotate(inputs: Inputs.BabylonNode.RotateNodeDto): void; - /** - * Sets the absolute position of the node - * @param inputs Node absolute position information - */ - setAbsolutePosition(inputs: Inputs.BabylonNode.NodePositionDto): void; - /** - * Sets the direction of the node - * @param inputs Direction information - */ - setDirection(inputs: Inputs.BabylonNode.NodeDirectionDto): void; - /** - * Sets the new parent to the node - * @param inputs Node parent information - */ - setParent(inputs: Inputs.BabylonNode.NodeParentDto): void; - /** - * Translates the node by a given direction vector and a distance - * @param inputs Node translation information - */ - translate(inputs: Inputs.BabylonNode.NodeTranslationDto): void; - } - declare class BabylonPick { - private readonly context; - constructor(context: Context); - /** - * Get a hit result of picking with ray - * @param inputs ray to use for picking - * @group pick - * @shortname pick with custom ray - * @returns Picking info - */ - pickWithRay(inputs: Inputs.BabylonPick.RayDto): BABYLON.PickingInfo; - /** - * Pick with picking ray of the current mouse position in the active camera - * @group pick - * @shortname pick with picking ray - * @returns Picking info - */ - pickWithPickingRay(): BABYLON.PickingInfo; - /** - * Get the distance to the object if picking result exists - * @param inputs picking result - * @group get from pick info - * @shortname pick distance - * @returns Distance - */ - getDistance(inputs: Inputs.BabylonPick.PickInfo): number; - /** - * Get the picked mesh - * @param inputs picking result - * @group get from pick info - * @shortname picked mesh - * @returns Picked mesh - */ - getPickedMesh(inputs: Inputs.BabylonPick.PickInfo): BABYLON.AbstractMesh; - /** - * Get the picked point - * @param inputs picking result - * @group get from pick info - * @shortname picked point - * @returns Picked point - */ - getPickedPoint(inputs: Inputs.BabylonPick.PickInfo): Base.Point3; - /** - * Check if pick ray hit something in the scene or not - * @param inputs picking result - * @group get from pick info - * @shortname hit - * @returns Indication of a hit - */ - hit(inputs: Inputs.BabylonPick.PickInfo): boolean; - /** - * Gets the unique submesh id if it was picked - * @param inputs picking result - * @group get from pick info - * @shortname sub mesh id - * @returns Submesh id - */ - getSubMeshId(inputs: Inputs.BabylonPick.PickInfo): number; - /** - * Gets the unique submesh face id if it was picked - * @param inputs picking result - * @group get from pick info - * @shortname sub mesh face id - * @returns Submesh face id - */ - getSubMeshFaceId(inputs: Inputs.BabylonPick.PickInfo): number; - /** - * Gets the the barycentric U coordinate that is used when calculating the texture coordinates of the collision - * @param inputs picking result - * @group get from pick info - * @shortname picked bu - * @returns U coordinate - */ - getBU(inputs: Inputs.BabylonPick.PickInfo): number; - /** - * Gets the the barycentric V coordinate that is used when calculating the texture coordinates of the collision - * @param inputs picking result - * @group get from pick info - * @shortname picked bv - * @returns V coordinate - */ - getBV(inputs: Inputs.BabylonPick.PickInfo): number; - /** - * Get the picked sprite - * @param inputs picking result - * @group get from pick info - * @shortname picked sprite - * @returns Picked sprite - */ - getPickedSprite(inputs: Inputs.BabylonPick.PickInfo): BABYLON.Sprite; - } - declare class BabylonRay { - private readonly context; - constructor(context: Context); - /** - * Creates a picking ray of the current mouse position in the active camera - * @group create - * @shortname create picking ray - * @returns Ray - */ - createPickingRay(): BABYLON.Ray; - /** - * Create a ray that start at origin, has direction vector and optionally length - * @param inputs origin, direction and length - * @group create - * @shortname create custom ray - * @returns ray - */ - createRay(inputs: Inputs.BabylonRay.BaseRayDto): BABYLON.Ray; - /** - * Create a ray from one point to another - * @param inputs origin, direction and length - * @group create - * @shortname create ray from to - * @returns ray - */ - createRayFromTo(inputs: Inputs.BabylonRay.FromToDto): BABYLON.Ray; - /** - * Get the origin of the ray - * @param inputs ray - * @group get - * @shortname get ray origin - * @returns origin point - */ - getOrigin(inputs: Inputs.BabylonRay.RayDto): Base.Point3; - /** - * Get the direction of the ray - * @param inputs ray - * @group get - * @shortname get ray direction - * @returns direction vector - */ - getDirection(inputs: Inputs.BabylonRay.RayDto): Base.Vector3; - /** - * Get the length of the ray - * @param inputs ray - * @group get - * @shortname get ray length - * @returns length - */ - getLength(inputs: Inputs.BabylonRay.RayDto): number; - } - declare class BabylonScene { - private readonly context; - constructor(context: Context); - /** - * Gets the scene for the current context - * @ignore true - * @group scene - * @shortname get scene - */ - getScene(): BABYLON.Scene; - /** - * Gets the scene for the current context - * @ignore true - * @group scene - * @shortname get scene - */ - setAndAttachScene(inputs: Inputs.BabylonScene.SceneDto): BABYLON.Scene; - /** - * Activate camera by overwriting currently active camera - * @param inputs Activates the camera - * @group camera - * @shortname activate - */ - activateCamera(inputs: Inputs.BabylonScene.ActiveCameraDto): void; - /** - * Use right handed system - * @param inputs Activates the camera - * @group system - * @shortname hand right - */ - useRightHandedSystem( - inputs: Inputs.BabylonScene.UseRightHandedSystemDto - ): void; - /** - * Creates and draws a point light in the scene but does not output anything - * @param inputs Describes the light source - * @group lights - * @shortname point - * @disposableOutput true - */ - drawPointLightNoReturn(inputs: Inputs.BabylonScene.PointLightDto): void; - /** - * Get shadow generators added by light sources through bitbybit - * @param inputs Describes the light source - * @group lights - * @shortname point - * @disposableOutput true - */ - getShadowGenerators(): BABYLON.ShadowGenerator[]; - /** - * Creates and draws a point light in the scene - * @param inputs Describes the light source - * @returns BabylonJS point light - * @group lights - * @shortname point light - * @disposableOutput true - */ - drawPointLight( - inputs: Inputs.BabylonScene.PointLightDto - ): BABYLON.PointLight; - /** - * Creates and draws a directional light in the scene - * @param inputs Describes the light source - * @group lights - * @shortname directional - * @disposableOutput true - */ - drawDirectionalLightNoReturn( - inputs: Inputs.BabylonScene.DirectionalLightDto - ): void; - /** - * Creates and draws a directional light in the scene - * @param inputs Describes the light source - * @returns BabylonJS directional light - * @group lights - * @shortname directional light - * @disposableOutput true - */ - drawDirectionalLight( - inputs: Inputs.BabylonScene.DirectionalLightDto - ): BABYLON.DirectionalLight; - /** - * Gets the active camera of the scene - * @group camera - * @shortname get active camera - */ - getActiveCamera(): BABYLON.Camera; - /** - * Adjusts the active arc rotate camera with configuration parameters - * @group camera - * @shortname adjust active camera - */ - adjustActiveArcRotateCamera( - inputs: Inputs.BabylonScene.CameraConfigurationDto - ): void; - /** - * Clears all of the drawn objects in the 3D scene - * @group environment - * @shortname clear all drawn - */ - clearAllDrawn(): void; - /** - * Enables skybox - * @param inputs Skybox configuration - * @group environment - * @shortname skybox - */ - enableSkybox(inputs: Inputs.BabylonScene.SkyboxDto): void; - /** - * Enables skybox with custom texture - * @param inputs Skybox configuration - * @group environment - * @shortname skybox - */ - enableSkyboxCustomTexture( - inputs: Inputs.BabylonScene.SkyboxCustomTextureDto - ): void; - /** - * Registers code to run when pointer is down - * @param inputs pointer statement - * @ignore true - */ - onPointerDown(inputs: Inputs.BabylonScene.PointerDto): void; - /** - * Registers code to run when pointer is up - * @param inputs pointer statement - * @ignore true - */ - onPointerUp(inputs: Inputs.BabylonScene.PointerDto): void; - /** - * Registers code to run when pointer is moving - * @param inputs pointer statement - * @ignore true - */ - onPointerMove(inputs: Inputs.BabylonScene.PointerDto): void; - /** - * Enables fog mode - * @param inputs fog options - * @group environment - * @shortname fog - */ - fog(inputs: Inputs.BabylonScene.FogDto): void; - /** - * Enables the physics - * @param inputs the gravity vector - * @ignore true - * @group physics - * @shortname enable - */ - enablePhysics(inputs: Inputs.BabylonScene.EnablePhysicsDto): void; - /** - * Changes the scene background to a css background image for 3D space - * @param inputs Describes the css of the scene background or image - * @group background - * @shortname css background image - */ - canvasCSSBackgroundImage( - inputs: Inputs.BabylonScene.SceneCanvasCSSBackgroundImageDto - ): { - backgroundImage: string; - }; - /** - * Creates a two-color linear gradient background for 3D space - * @param inputs Describes the two-color linear gradient parameters - * @group background - * @shortname two color linear gradient - */ - twoColorLinearGradientBackground( - inputs: Inputs.BabylonScene.SceneTwoColorLinearGradientDto - ): { - backgroundImage: string; - }; - /** - * Creates a two-color radial gradient background for 3D space - * @param inputs Describes the two-color radial gradient parameters - * @group background - * @shortname two color radial gradient - */ - twoColorRadialGradientBackground( - inputs: Inputs.BabylonScene.SceneTwoColorRadialGradientDto - ): { - backgroundImage: string; - }; - /** - * Creates a multi-color linear gradient background for 3D space - * @param inputs Describes the multi-color linear gradient parameters - * @group background - * @shortname multi color linear gradient - */ - multiColorLinearGradientBackground( - inputs: Inputs.BabylonScene.SceneMultiColorLinearGradientDto - ): - | { - backgroundImage: string; - } - | { - error: string; - }; - /** - * Creates a multi-color radial gradient background for 3D space - * @param inputs Describes the multi-color radial gradient parameters - * @group background - * @shortname multi color radial gradient - */ - multiColorRadialGradientBackground( - inputs: Inputs.BabylonScene.SceneMultiColorRadialGradientDto - ): - | { - backgroundImage: string; - } - | { - error: string; - }; - /** - * Sets a background image with various customization options for 3D space - * @param inputs Describes the background image parameters - * @group background - * @shortname background image - */ - canvasBackgroundImage( - inputs: Inputs.BabylonScene.SceneCanvasBackgroundImageDto - ): { - backgroundImage: string; - backgroundRepeat: string; - backgroundSize: string; - backgroundPosition: string; - backgroundAttachment: string; - backgroundOrigin: string; - backgroundClip: string; - }; - /** - * Changes the scene background colour for 3D space - * @param inputs Describes the colour of the scene background - * @group background - * @shortname colour - */ - backgroundColour( - inputs: Inputs.BabylonScene.SceneBackgroundColourDto - ): void; - private getRadians; - private createSkyboxMesh; - } - declare class BabylonTexture { - private readonly context; - constructor(context: Context); - /** - * Creates texture from URL from a few basic options. If you loaded the asset via the file, create object url and pass it here. - * @param inputs required to set up basic texture - * @returns Babylon texture that can be used with materials - * @group create - * @shortname simple texture - * @disposableOutput true - */ - createSimple( - inputs: Inputs.BabylonTexture.TextureSimpleDto - ): BABYLON.Texture; - } - declare class BabylonTools { - private readonly context; - constructor(context: Context); - /** - * Creates a screenshot of the scene - * @group screenshots - * @shortname create screenshot - */ - createScreenshot( - inputs: Inputs.BabylonTools.ScreenshotDto - ): Promise; - /** - * Creates a screenshot of the scene and download file - * @group screenshots - * @shortname create screenshot and download - */ - createScreenshotAndDownload( - inputs: Inputs.BabylonTools.ScreenshotDto - ): Promise; - } - /** - * Transformations help to move, scale, rotate and mirror objects. You can combine multiple transformations - * for object to be placed exactly into position and orientation that you want. - * Contains various methods for transformations that represent 4x4 matrixes in flat 16 number arrays. - */ - declare class BabylonTransforms { - /** - * Creates a rotation transformations around the center and an axis - * @param inputs Rotation around center with an axis information - * @returns array of transformations - * @group rotation - * @shortname center axis - * @drawable false - */ - rotationCenterAxis( - inputs: Inputs.BabylonTransforms.RotationCenterAxisDto - ): Base.TransformMatrixes; - /** - * Creates a rotation transformations around the center and an X axis - * @param inputs Rotation around center with an X axis information - * @returns array of transformations - * @group rotation - * @shortname center x - * @drawable false - */ - rotationCenterX( - inputs: Inputs.BabylonTransforms.RotationCenterDto - ): Base.TransformMatrixes; - /** - * Creates a rotation transformations around the center and an Y axis - * @param inputs Rotation around center with an Y axis information - * @returns array of transformations - * @group rotation - * @shortname center y - * @drawable false - */ - rotationCenterY( - inputs: Inputs.BabylonTransforms.RotationCenterDto - ): Base.TransformMatrixes; - /** - * Creates a rotation transformations around the center and an Z axis - * @param inputs Rotation around center with an Z axis information - * @returns array of transformations - * @group rotation - * @shortname center z - * @drawable false - */ - rotationCenterZ( - inputs: Inputs.BabylonTransforms.RotationCenterDto - ): Base.TransformMatrixes; - /** - * Creates a rotation transformations with yaw pitch and roll - * @param inputs Yaw pitch roll rotation information - * @returns array of transformations - * @group rotation - * @shortname yaw pitch roll - * @drawable false - */ - rotationCenterYawPitchRoll( - inputs: Inputs.BabylonTransforms.RotationCenterYawPitchRollDto - ): Base.TransformMatrixes; - /** - * Scale transformation around center and xyz directions - * @param inputs Scale center xyz trnansformation - * @returns array of transformations - * @group rotation - * @shortname center xyz - * @drawable false - */ - scaleCenterXYZ( - inputs: Inputs.BabylonTransforms.ScaleCenterXYZDto - ): Base.TransformMatrixes; - /** - * Creates the scale transformation in x, y and z directions - * @param inputs Scale XYZ number array information - * @returns transformation - * @group scale - * @shortname xyz - * @drawable false - */ - scaleXYZ( - inputs: Inputs.BabylonTransforms.ScaleXYZDto - ): Base.TransformMatrixes; - /** - * Creates uniform scale transformation - * @param inputs Scale Dto - * @returns transformation - * @group scale - * @shortname uniform - * @drawable false - */ - uniformScale( - inputs: Inputs.BabylonTransforms.UniformScaleDto - ): Base.TransformMatrixes; - /** - * Creates uniform scale transformation from the center - * @param inputs Scale Dto with center point information - * @returns array of transformations - * @group scale - * @shortname uniform from center - * @drawable false - */ - uniformScaleFromCenter( - inputs: Inputs.BabylonTransforms.UniformScaleFromCenterDto - ): Base.TransformMatrixes; - /** - * Creates the translation transformation - * @param inputs Translation information - * @returns transformation - * @group translation - * @shortname xyz - * @drawable false - */ - translationXYZ( - inputs: Inputs.BabylonTransforms.TranslationXYZDto - ): Base.TransformMatrixes; - /** - * Creates the translation transformation - * @param inputs Translation information - * @returns transformation - * @group translations - * @shortname xyz - * @drawable false - */ - translationsXYZ( - inputs: Inputs.BabylonTransforms.TranslationsXYZDto - ): Base.TransformMatrixes[]; - } - declare class BabylonWebXRBase { - private readonly context; - constructor(context: Context); - /** - * Creates default XR experience - * @param inputs Options for basic configuration - * @group scene - * @shortname default xr experience async - * @disposableOutput true - */ - createDefaultXRExperienceAsync( - inputs: Inputs.BabylonWebXR.WebXRDefaultExperienceOptions - ): Promise; - /** - * Creates default XR experience - * @param inputs Options for basic configuration - * @group scene - * @shortname default xr experience no opt. async - * @disposableOutput true - */ - createDefaultXRExperienceNoOptionsAsync(): Promise; - /** - * Returns the base experience of the default XR experience - * @param inputs Inputs with the default XR experience - * @group get - * @shortname get base experience - */ - getBaseExperience( - inputs: Inputs.BabylonWebXR.WebXRDefaultExperienceDto - ): BABYLON.WebXRExperienceHelper; - /** - * Returns the feature manager of the default XR experience - * @param inputs Inputs with the default XR experience - * @group get - * @shortname get feature manager - */ - getFeatureManager( - inputs: Inputs.BabylonWebXR.WebXRExperienceHelperDto - ): BABYLON.WebXRFeaturesManager; - } - declare class BabylonWebXRSimple { - private readonly context; - constructor(context: Context); - /** - * Creates default XR experience in immersive-ar mode - * @param inputs Creates default XR experience with teleportation - * @returns Default XR experience - * @group scene - * @shortname simple immersive ar experience - * @disposableOutput true - */ - createImmersiveARExperience(): Promise; - /** - * Creates default XR experience with teleportation that is very basic and works for simple scenarios - * @param inputs Creates default XR experience with teleportation - * @group scene - * @shortname simple xr with teleportation - */ - createDefaultXRExperienceWithTeleportation( - inputs: Inputs.BabylonWebXR.DefaultWebXRWithTeleportationDto - ): Promise; - /** - * Creates default XR experience with teleportation that is very basic and works for simple scenarios - * @param inputs Creates default XR experience with teleportation - * @group scene - * @shortname simple xr with teleportation return - * @disposableOutput true - */ - createDefaultXRExperienceWithTeleportationReturn( - inputs: Inputs.BabylonWebXR.DefaultWebXRWithTeleportationDto - ): Promise<{ - xr: BABYLON.WebXRDefaultExperience; - torusMat: BABYLON.PBRMetallicRoughnessMaterial; - manager: GUI3DManager; - near: NearMenu; - button: TouchHolographicButton; - text: TextBlock; - dispose: () => void; - }>; - } - declare class BabylonWebXR { - private readonly context; - simple: BabylonWebXRSimple; - constructor(context: Context); - } - declare class Draw extends DrawCore { - /** - * @ignore true - */ - readonly drawHelper: DrawHelper; - /** - * @ignore true - */ - readonly node: BabylonNode; - /** - * @ignore true - */ - readonly tag: Tag; - /** - * @ignore true - */ - readonly context: Context; - private defaultBasicOptions; - private defaultPolylineOptions; - private defaultNodeOptions; - constructor( - /** - * @ignore true - */ - drawHelper: DrawHelper, - /** - * @ignore true - */ - node: BabylonNode, - /** - * @ignore true - */ - tag: Tag, - /** - * @ignore true - */ - context: Context - ); - /** - * Draws any kind of geometry and does not return anything - * @param inputs Contains options and entities to be drawn - * @group draw async - * @shortname draw async void - * @disposableOutput true - * @drawable true - */ - drawAnyAsyncNoReturn(inputs: Inputs.Draw.DrawAny): Promise; - /** - * Draws any kind of geometry and returns the babylon mesh - * @param inputs Contains options and entities to be drawn - * @returns BabylonJS Mesh Promise - * @group draw async - * @shortname draw async - * @drawable true - * @disposableOutput true - */ - drawAnyAsync(inputs: Inputs.Draw.DrawAny): Promise; - private updateAny; - /** - * Draws any kind of geometry that does not need asynchronous computing, thus it cant be used with shapes coming from occt or jscad - * @param inputs Contains options and entities to be drawn - * @returns BabylonJS Mesh - * @group draw sync - * @shortname draw sync void - */ - drawAnyNoReturn(inputs: Inputs.Draw.DrawAny): void; - /** - * Draws any kind of geometry that does not need asynchronous computing, thus it cant be used with shapes coming from occt or jscad - * @param inputs Contains options and entities to be drawn - * @returns BabylonJS Mesh - * @group draw sync - * @shortname draw sync - */ - drawAny(inputs: Inputs.Draw.DrawAny): BABYLON.Mesh; - /** - * Draws a grid mesh on the ground plane in 3D space. This helps to orient yourself in the world. - * @param inputs Describes various parameters of the grid mesh like size, colour, etc. - * @group grid - * @shortname draw grid no return - * @disposableOutput true - */ - drawGridMeshNoReturn(inputs: Inputs.Draw.SceneDrawGridMeshDto): void; - /** - * Draws a grid mesh on the ground plane in 3D space. This helps to orient yourself in the world. - * @param inputs Describes various parameters of the grid mesh like size, colour, etc. - * @returns grid mesh - * @group grid - * @shortname draw grid - * @disposableOutput true - */ - drawGridMesh(inputs: Inputs.Draw.SceneDrawGridMeshDto): BABYLON.Mesh; - /** - * Creates draw options for basic geometry types like points, lines, polylines, surfaces and jscad meshes - * @param inputs option definition - * @returns options - * @group options - * @shortname simple - */ - optionsSimple( - inputs: Inputs.Draw.DrawBasicGeometryOptions - ): Inputs.Draw.DrawBasicGeometryOptions; - /** - * Creates draw options for occt shape geometry like edges, wires, faces, shells, solids and compounds - * @param inputs option definition - * @returns options - * @group options - * @shortname occt shape - */ - optionsOcctShape( - inputs: Inputs.Draw.DrawOcctShapeOptions - ): Inputs.Draw.DrawOcctShapeOptions; - /** - * Creates simple draw options for occt shape geometry - * @param inputs option definition - * @returns options - * @group options - * @shortname occt shape simple - */ - optionsOcctShapeSimple( - inputs: Inputs.Draw.DrawOcctShapeSimpleOptions - ): Inputs.Draw.DrawOcctShapeSimpleOptions; - /** - * Creates simple draw options with custom face material for occt shape geometry - * @param inputs option definition - * @returns options - * @group options - * @shortname occt shape with material - */ - optionsOcctShapeMaterial( - inputs: Inputs.Draw.DrawOcctShapeMaterialOptions - ): Inputs.Draw.DrawOcctShapeMaterialOptions; - /** - * Creates draw options for manifold gemetry - * @param inputs option definition - * @returns options - * @group options - * @shortname manifold shape draw options - */ - optionsManifoldShapeMaterial( - inputs: Inputs.Draw.DrawManifoldOrCrossSectionOptions - ): Inputs.Draw.DrawManifoldOrCrossSectionOptions; - /** - * Creates draw options for babylon js nodes - * @param inputs option definition - * @returns options - * @group options - * @shortname babylon node - */ - optionsBabylonNode( - inputs: Inputs.Draw.DrawNodeOptions - ): Inputs.Draw.DrawNodeOptions; - /** - * Creates a generic texture that can be used with PBR materials. - * This method provides a cross-engine compatible way to create textures. - * @param inputs Texture configuration options - * @returns BabylonJS Texture - * @group material - * @shortname create texture - * @disposableOutput true - */ - createTexture(inputs: Inputs.Draw.GenericTextureDto): BABYLON.Texture; - /** - * Creates a generic PBR (Physically Based Rendering) material. - * This method provides a cross-engine compatible way to create materials - * that can be used with draw options for OCCT shapes and other geometry. - * @param inputs Material configuration options - * @returns BabylonJS PBRMetallicRoughnessMaterial - * @group material - * @shortname create pbr material - * @disposableOutput true - */ - createPBRMaterial( - inputs: Inputs.Draw.GenericPBRMaterialDto - ): BABYLON.PBRMetallicRoughnessMaterial; - private getSamplingMode; - private handleTags; - private handleTag; - private handleVerbSurfaces; - private handleVerbCurves; - private handleNodes; - private handlePoints; - private handleLines; - private handlePolylines; - private handleVerbSurface; - private handleVerbCurve; - private handleNode; - private handlePolyline; - private handlePoint; - private handleLine; - private handleJscadMeshes; - private handleManifoldShape; - private handleManifoldShapes; - private handleOcctShape; - private handleOcctShapes; - private handleJscadMesh; - private applyGlobalSettingsAndMetadataAndShadowCasting; - } - declare class Color { - private readonly math; - constructor(math: MathBitByBit); - /** - * Creates and returns a hex color string (pass-through for color input). - * Example: '#FF5733' → '#FF5733' - * @param inputs Color hex - * @returns color string - * @group create - * @shortname color - * @drawable false - */ - hexColor(inputs: Inputs.Color.HexDto): Inputs.Base.Color; - /** - * Converts hex color to RGB object with r, g, b values (0-255 range). - * Example: '#FF5733' → {r: 255, g: 87, b: 51} - * @param inputs Color hex - * @returns rgb color - * @group convert - * @shortname hex to rgb - * @drawable false - */ - hexToRgb(inputs: Inputs.Color.HexDto): Inputs.Base.ColorRGB; - /** - * Converts RGB values to hex color string (supports custom min/max ranges, auto-remaps to 0-255). - * Example: r=255, g=87, b=51 with range [0,255] → '#ff5733' - * Example: r=1, g=0.5, b=0.2 with range [0,1] → '#ff7f33' - * @param inputs Color hext - * @returns hex color - * @group convert - * @shortname rgb to hex - * @drawable false - */ - rgbToHex(inputs: Inputs.Color.RGBMinMaxDto): Inputs.Base.Color; - /** - * Converts RGB object to hex color string (supports custom min/max ranges). - * Example: {r: 1, g: 0.5, b: 0.2} with range [0,1] → '#ff7f33' - * @param inputs Color hext - * @returns hex color string - * @group convert - * @shortname rgb obj to hex - * @drawable false - */ - rgbObjToHex(inputs: Inputs.Color.RGBObjectMaxDto): Inputs.Base.Color; - /** - * Converts hex color to RGB and remaps values to a custom range. - * Example: '#FF5733' mapped to [0,1] → {r: 1, g: 0.341, b: 0.2} - * Example: '#FF5733' mapped to [0,100] → {r: 100, g: 34.1, b: 20} - * @param inputs Color hext - * @returns rgb color - * @group convert - * @shortname hex to rgb mapped - * @drawable false - */ - hexToRgbMapped(inputs: Inputs.Color.HexDtoMapped): Inputs.Base.ColorRGB; - /** - * Extracts the red channel value from hex color (can be mapped to custom range). - * Example: '#FF5733' with range [0,1] → 1 - * @param inputs Color hext - * @returns rgb color - * @group hex to - * @shortname red - * @drawable false - */ - getRedParam(inputs: Inputs.Color.HexDtoMapped): number; - /** - * Extracts the green channel value from hex color (can be mapped to custom range). - * Example: '#FF5733' with range [0,1] → 0.341 - * @param inputs Color hext - * @returns rgb color - * @group hex to - * @shortname green - * @drawable false - */ - getGreenParam(inputs: Inputs.Color.HexDtoMapped): number; - /** - * Extracts the blue channel value from hex color (can be mapped to custom range). - * Example: '#FF5733' with range [0,1] → 0.2 - * @param inputs Color hext - * @returns blue param - * @group hex to - * @shortname blue - * @drawable false - */ - getBlueParam(inputs: Inputs.Color.HexDtoMapped): number; - /** - * Extracts the red channel value from RGB object. - * Example: {r: 255, g: 87, b: 51} → 255 - * @param inputs Color rgb - * @returns red param - * @group rgb to - * @shortname red - * @drawable false - */ - rgbToRed(inputs: Inputs.Color.RGBObjectDto): number; - /** - * Extracts the green channel value from RGB object. - * Example: {r: 255, g: 87, b: 51} → 87 - * @param inputs Color rgb - * @returns green param - * @group rgb to - * @shortname green - * @drawable false - */ - rgbToGreen(inputs: Inputs.Color.RGBObjectDto): number; - /** - * Extracts the blue channel value from RGB object. - * Example: {r: 255, g: 87, b: 51} → 51 - * @param inputs Color rgb - * @returns blue param - * @group rgb to - * @shortname blue - * @drawable false - */ - rgbToBlue(inputs: Inputs.Color.RGBObjectDto): number; - /** - * Inverts a hex color (flips RGB channels: 255-r, 255-g, 255-b). - * With blackAndWhite=true → returns '#000000' or '#ffffff' based on brightness. - * Example: '#FF5733' → '#00a8cc', '#FF5733' with blackAndWhite=true → '#ffffff' - * @param inputs hex color and black and white option - * @returns inverted color - * @group hex to - * @shortname invert color - * @drawable false - */ - invert(inputs: Inputs.Color.InvertHexDto): Inputs.Base.Color; - } - /** - * Contains various date methods. - */ - declare class Dates { - /** - * Converts date to human-readable date string (excludes time). - * Example: Date(2024,0,15,14,30) → 'Mon Jan 15 2024' - * @param inputs a date - * @returns date as string - * @group convert - * @shortname date to string - * @drawable false - */ - toDateString(inputs: Inputs.Dates.DateDto): string; - /** - * Converts date to ISO 8601 format string (standard format for APIs and data interchange). - * Example: Date(2024,0,15,14,30,45) → '2024-01-15T14:30:45.000Z' - * @param inputs a date - * @returns date as string - * @group convert - * @shortname date to iso string - * @drawable false - */ - toISOString(inputs: Inputs.Dates.DateDto): string; - /** - * Converts date to JSON-compatible string (same as ISO format, used in JSON.stringify). - * Example: Date(2024,0,15,14,30) → '2024-01-15T14:30:00.000Z' - * @param inputs a date - * @returns date as string - * @group convert - * @shortname date to json - * @drawable false - */ - toJSON(inputs: Inputs.Dates.DateDto): string; - /** - * Converts date to full locale-specific string (includes date, time, and timezone). - * Example: Date(2024,0,15,14,30) → 'Mon Jan 15 2024 14:30:00 GMT+0000' - * @param inputs a date - * @returns date as string - * @group convert - * @shortname date to locale string - * @drawable false - */ - toString(inputs: Inputs.Dates.DateDto): string; - /** - * Converts date to time string (excludes date, includes timezone). - * Example: Date(2024,0,15,14,30,45) → '14:30:45 GMT+0000' - * @param inputs a date - * @returns time as string - * @group convert - * @shortname date to time string - * @drawable false - */ - toTimeString(inputs: Inputs.Dates.DateDto): string; - /** - * Converts date to UTC string format (Universal Coordinated Time, no timezone offset). - * Example: Date(2024,0,15,14,30) → 'Mon, 15 Jan 2024 14:30:00 GMT' - * @param inputs a date - * @returns date as utc string - * @group convert - * @shortname date to utc string - * @drawable false - */ - toUTCString(inputs: Inputs.Dates.DateDto): string; - /** - * Returns the current date and time at the moment of execution. - * Example: calling now() → Date object representing current moment (e.g., '2024-01-15T14:30:45') - * @returns date - * @group create - * @shortname now - * @drawable false - */ - now(): Date; - /** - * Creates a new date from individual components using local time. - * Month is 0-indexed: 0=January, 11=December. - * Example: year=2024, month=0, day=15, hours=14, minutes=30 → Date(Jan 15, 2024 14:30) - * @param inputs a date - * @returns date - * @group create - * @shortname create date - * @drawable false - */ - createDate(inputs: Inputs.Dates.CreateDateDto): Date; - /** - * Creates a new date from individual components using UTC (ignores timezone). - * Returns milliseconds since Unix epoch (Jan 1, 1970 00:00:00 UTC). - * Example: year=2024, month=0, day=15 → Date representing Jan 15, 2024 00:00 UTC - * @param inputs a date - * @returns date - * @group create - * @shortname create utc date - * @drawable false - */ - createDateUTC(inputs: Inputs.Dates.CreateDateDto): Date; - /** - * Creates a date from Unix timestamp (milliseconds since Jan 1, 1970 UTC). - * Example: unixTimeStamp=1705329000000 → Date(Jan 15, 2024 14:30:00) - * @param inputs a unix time stamp - * @returns date - * @group create - * @shortname create from unix timestamp - * @drawable false - */ - createFromUnixTimeStamp( - inputs: Inputs.Dates.CreateFromUnixTimeStampDto - ): Date; - /** - * Parses a date string and returns Unix timestamp (milliseconds since Jan 1, 1970 UTC). - * Example: dateString='2024-01-15' → 1705276800000 - * @param inputs a date string - * @returns the number of milliseconds between that date and midnight, January 1, 1970. - * @group parse - * @shortname parse date string - * @drawable false - */ - parseDate(inputs: Inputs.Dates.DateStringDto): number; - /** - * Extracts day of the month from date (1-31) using local time. - * Example: Date(2024,0,15) → 15 - * @returns date - * @group get - * @shortname get date of month - * @drawable false - */ - getDayOfMonth(inputs: Inputs.Dates.DateDto): number; - /** - * Extracts day of the week from date (0=Sunday, 6=Saturday) using local time. - * Example: Date(2024,0,15) → 1 (Monday) - * @returns day - * @group get - * @shortname get weekday - * @drawable false - */ - getWeekday(inputs: Inputs.Dates.DateDto): number; - /** - * Extracts full year from date using local time. - * Example: Date(2024,0,15) → 2024 - * @returns year - * @group get - * @shortname get year - * @drawable false - */ - getYear(inputs: Inputs.Dates.DateDto): number; - /** - * Extracts month from date (0=January, 11=December) using local time. - * Example: Date(2024,0,15) → 0 (January) - * @returns month - * @group get - * @shortname get month - * @drawable false - */ - getMonth(inputs: Inputs.Dates.DateDto): number; - /** - * Extracts hours from date (0-23) using local time. - * Example: Date(2024,0,15,14,30) → 14 - * @returns hours - * @group get - * @shortname get hours - * @drawable false - */ - getHours(inputs: Inputs.Dates.DateDto): number; - /** - * Extracts minutes from date (0-59) using local time. - * Example: Date(2024,0,15,14,30) → 30 - * @returns minutes - * @group get - * @shortname get minutes - * @drawable false - */ - getMinutes(inputs: Inputs.Dates.DateDto): number; - /** - * Extracts seconds from date (0-59) using local time. - * Example: Date(2024,0,15,14,30,45) → 45 - * @returns seconds - * @group get - * @shortname get seconds - * @drawable false - */ - getSeconds(inputs: Inputs.Dates.DateDto): number; - /** - * Extracts milliseconds from date (0-999) using local time. - * Example: Date(2024,0,15,14,30,45,123) → 123 - * @returns milliseconds - * @group get - * @shortname get milliseconds - * @drawable false - */ - getMilliseconds(inputs: Inputs.Dates.DateDto): number; - /** - * Converts date to Unix timestamp (milliseconds since Jan 1, 1970 UTC). - * Example: Date(2024,0,15,14,30) → 1705329000000 - * @returns time - * @group get - * @shortname get time - * @drawable false - */ - getTime(inputs: Inputs.Dates.DateDto): number; - /** - * Extracts full year from date using UTC (ignores timezone). - * Example: Date(2024,0,15) → 2024 - * @returns year - * @group get - * @shortname get utc year - * @drawable false - */ - getUTCYear(inputs: Inputs.Dates.DateDto): number; - /** - * Extracts month from date (0=January, 11=December) using UTC. - * Example: Date.UTC(2024,0,15) → 0 (January) - * @returns month - * @group get - * @shortname get utc month - * @drawable false - */ - getUTCMonth(inputs: Inputs.Dates.DateDto): number; - /** - * Extracts day of the month from date (1-31) using UTC. - * Example: Date.UTC(2024,0,15) → 15 - * @returns day - * @group get - * @shortname get utc day - * @drawable false - */ - getUTCDay(inputs: Inputs.Dates.DateDto): number; - /** - * Extracts hours from date (0-23) using UTC. - * Example: Date.UTC(2024,0,15,14) → 14 - * @returns hours - * @group get - * @shortname get utc hours - * @drawable false - */ - getUTCHours(inputs: Inputs.Dates.DateDto): number; - /** - * Extracts minutes from date (0-59) using UTC. - * Example: Date.UTC(2024,0,15,14,30) → 30 - * @returns minutes - * @group get - * @shortname get utc minutes - * @drawable false - */ - getUTCMinutes(inputs: Inputs.Dates.DateDto): number; - /** - * Extracts seconds from date (0-59) using UTC. - * Example: Date.UTC(2024,0,15,14,30,45) → 45 - * @returns seconds - * @group get - * @shortname get utc seconds - * @drawable false - */ - getUTCSeconds(inputs: Inputs.Dates.DateDto): number; - /** - * Extracts milliseconds from date (0-999) using UTC. - * Example: Date.UTC(2024,0,15,14,30,45,123) → 123 - * @returns milliseconds - * @group get - * @shortname get utc milliseconds - * @drawable false - */ - getUTCMilliseconds(inputs: Inputs.Dates.DateDto): number; - /** - * Creates new date with modified year (returns new date, original unchanged). - * Example: Date(2024,0,15) with year=2025 → Date(2025,0,15) - * @param inputs a date and the year - * @returns date - * @group set - * @shortname set year - * @drawable false - * */ - setYear(inputs: Inputs.Dates.DateYearDto): Date; - /** - * Creates new date with modified month (0=January, 11=December, returns new date). - * Example: Date(2024,0,15) with month=5 → Date(2024,5,15) (June 15) - * @param inputs a date and the month - * @returns date - * @group set - * @shortname set month - * @drawable false - * */ - setMonth(inputs: Inputs.Dates.DateMonthDto): Date; - /** - * Creates new date with modified day of month (1-31, returns new date). - * Example: Date(2024,0,15) with day=20 → Date(2024,0,20) - * @param inputs a date and the day - * @returns date - * @group set - * @shortname set day of month - * @drawable false - */ - setDayOfMonth(inputs: Inputs.Dates.DateDayDto): Date; - /** - * Sets the hour value in the Date object using local time. - * @param inputs a date and the hours - * @returns date - * @group set - * @shortname set hours - * @drawable false - * */ - setHours(inputs: Inputs.Dates.DateHoursDto): Date; - /** - * Sets the minutes value in the Date object using local time. - * @param inputs a date and the minutes - * @returns date - * @group set - * @shortname set minutes - * @drawable false - * */ - setMinutes(inputs: Inputs.Dates.DateMinutesDto): Date; - /** - * Sets the seconds value in the Date object using local time. - * @param inputs a date and the seconds - * @returns date - * @group set - * @shortname set seconds - * @drawable false - */ - setSeconds(inputs: Inputs.Dates.DateSecondsDto): Date; - /** - * Sets the milliseconds value in the Date object using local time. - * @param inputs a date and the milliseconds - * @returns date - * @group set - * @shortname set milliseconds - * @drawable false - */ - setMilliseconds(inputs: Inputs.Dates.DateMillisecondsDto): Date; - /** - * Sets the date and time value in the Date object. - * @param inputs a date and the time - * @returns date - * @group set - * @shortname set time - * @drawable false - */ - setTime(inputs: Inputs.Dates.DateTimeDto): Date; - /** - * Sets the year value in the Date object using Universal Coordinated Time (UTC). - * @param inputs a date and the year - * @returns date - * @group set - * @shortname set utc year - * @drawable false - * */ - setUTCYear(inputs: Inputs.Dates.DateYearDto): Date; - /** - * Sets the month value in the Date object using Universal Coordinated Time (UTC). - * @param inputs a date and the month - * @returns date - * @group set - * @shortname set utc month - * @drawable false - * */ - setUTCMonth(inputs: Inputs.Dates.DateMonthDto): Date; - /** - * Sets the numeric day of the month in the Date object using Universal Coordinated Time (UTC). - * @param inputs a date and the day - * @returns date - * @group set - * @shortname set utc day - * @drawable false - */ - setUTCDay(inputs: Inputs.Dates.DateDayDto): Date; - /** - * Sets the hours value in the Date object using Universal Coordinated Time (UTC). - * @param inputs a date and the hours - * @returns date - * @group set - * @shortname set utc hours - * @drawable false - * */ - setUTCHours(inputs: Inputs.Dates.DateHoursDto): Date; - /** - * Sets the minutes value in the Date object using Universal Coordinated Time (UTC). - * @param inputs a date and the minutes - * @returns date - * @group set - * @shortname set utc minutes - * @drawable false - * */ - setUTCMinutes(inputs: Inputs.Dates.DateMinutesDto): Date; - /** - * Sets the seconds value in the Date object using Universal Coordinated Time (UTC). - * @param inputs a date and the seconds - * @returns date - * @group set - * @shortname set utc seconds - * @drawable false - */ - setUTCSeconds(inputs: Inputs.Dates.DateSecondsDto): Date; - /** - * Sets the milliseconds value in the Date object using Universal Coordinated Time (UTC). - * @param inputs a date and the milliseconds - * @returns date - * @group set - * @shortname set utc milliseconds - * @drawable false - */ - setUTCMilliseconds(inputs: Inputs.Dates.DateMillisecondsDto): Date; - } - declare class GeometryHelper { - /** - * Applies one or more 4×4 transformation matrices to a list of points sequentially. - * Each transformation is applied in order (composition of transformations). - * Example: points=[[0,0,0], [1,0,0]] with translation [5,0,0] → [[5,0,0], [6,0,0]] - */ - transformControlPoints( - transformation: number[][] | number[][][], - transformedControlPoints: Inputs.Base.Point3[] - ): Inputs.Base.Point3[]; - /** - * Flattens nested transformation arrays into a single-level array of transformation matrices. - * Handles both 2D arrays (single transform list) and 3D arrays (nested transform lists). - * Example: [[[matrix1, matrix2]], [[matrix3]]] → [matrix1, matrix2, matrix3] - */ - getFlatTransformations( - transformation: number[][] | number[][][] - ): number[][]; - /** - * Calculates the nesting depth of an array recursively. - * Example: [1,2,3] → 1, [[1,2],[3,4]] → 2, [[[1]]] → 3 - */ - getArrayDepth: (value: any) => number; - /** - * Applies a single 4×4 transformation matrix (as flat 16-element array) to multiple points. - * Example: points=[[0,0,0], [1,0,0]] with translation matrix → transformed points - */ - transformPointsByMatrixArray( - points: Inputs.Base.Point3[], - transform: number[] - ): Inputs.Base.Point3[]; - /** - * Transforms multiple points using a transformation matrix (maps each point through the matrix). - * Example: points=[[1,0,0], [0,1,0]] with 90° rotation → [[0,1,0], [-1,0,0]] - */ - transformPointsCoordinates( - points: Inputs.Base.Point3[], - transform: number[] - ): Inputs.Base.Point3[]; - /** - * Removes all duplicate vectors from a list (works with arbitrary-length numeric vectors). - * Compares vectors using tolerance for floating-point equality. - * Example: [[1,2], [3,4], [1,2], [5,6]] with tolerance=1e-7 → [[1,2], [3,4], [5,6]] - */ - removeAllDuplicateVectors( - vectors: number[][], - tolerance?: number - ): number[][]; - /** - * Removes consecutive duplicate vectors from a list (keeps only first occurrence in each sequence). - * Optionally checks and removes duplicate if first and last vectors match. - * Example: [[1,2], [1,2], [3,4], [3,4], [5,6]] → [[1,2], [3,4], [5,6]] - */ - removeConsecutiveVectorDuplicates( - vectors: number[][], - checkFirstAndLast?: boolean, - tolerance?: number - ): number[][]; - /** - * Compares two vectors for approximate equality using tolerance (element-wise comparison). - * Returns false if vectors have different lengths. - * Example: [1.0000001, 2.0], [1.0, 2.0] with tolerance=1e-6 → true - */ - vectorsTheSame(vec1: number[], vec2: number[], tolerance: number): boolean; - /** - * Checks if two numbers are approximately equal within a tolerance. - * Example: 1.0000001, 1.0 with tolerance=1e-6 → true, 1.001, 1.0 with tolerance=1e-6 → false - */ - approxEq(num1: number, num2: number, tolerance: number): boolean; - /** - * Removes consecutive duplicate points from a list (specialized for 3D/2D points). - * Optionally checks and removes duplicate if first and last points match (for closed loops). - * Example: [[0,0,0], [0,0,0], [1,0,0], [1,0,0]] → [[0,0,0], [1,0,0]] - */ - removeConsecutivePointDuplicates( - points: Inputs.Base.Point3[], - checkFirstAndLast?: boolean, - tolerance?: number - ): Inputs.Base.Point3[]; - /** - * Checks if two points are approximately equal using tolerance (supports 2D and 3D points). - * Example: [1.0000001, 2.0, 3.0], [1.0, 2.0, 3.0] with tolerance=1e-6 → true - */ - arePointsTheSame( - pointA: Inputs.Base.Point3 | Inputs.Base.Point2, - pointB: Inputs.Base.Point3 | Inputs.Base.Point2, - tolerance: number - ): boolean; - private transformCoordinates; - } - declare class DxfGenerator { - private entityHandle; - private colorFormat; - private acadVersion; - /** - * Generate a complete DXF file content from path-based entities - */ - generateDxf(dxfInputs: Inputs.IO.DxfModelDto): string; - /** - * Generate DXF header section - */ - private generateHeader; - /** - * Generate DXF tables section (layers, line types, etc.) - */ - private generateTables; - /** - * Generate line type table - */ - private generateLineTypeTable; - /** - * Generate text style table - */ - private generateStyleTable; - /** - * Generate VPORT table (viewport configuration) - */ - private generateVportTable; - /** - * Generate VIEW table (empty but required for AC1009) - */ - private generateViewTable; - /** - * Generate UCS table (user coordinate system - empty but required for AC1009) - */ - private generateUcsTable; - /** - * Generate APPID table (application ID - required for AC1009) - */ - private generateAppidTable; - /** - * Generate DIMSTYLE table (dimension style - empty but required for AC1009) - */ - private generateDimstyleTable; - /** - * Generate blocks section (empty but required) - */ - private generateBlocks; - /** - * Generate layer table based on unique layers in all parts - */ - private generateLayerTable; - /** - * Generate DXF entities section with all path segments - */ - private generateEntities; - /** - * Generate entity for a single segment based on its type - */ - private generateSegmentEntity; - /** - * Type guard for line segments - */ - private isLineSegment; - /** - * Type guard for arc segments - */ - private isArcSegment; - /** - * Type guard for circle segments - */ - private isCircleSegment; - /** - * Type guard for polyline segments - */ - private isPolylineSegment; - /** - * Type guard for spline segments - */ - private isSplineSegment; - /** - * Generate a LINE entity - */ - private generateLineEntity; - /** - * Generate a CIRCLE entity - */ - private generateCircleEntity; - /** - * Generate an ARC entity - */ - private generateArcEntity; - /** - * Generate a LWPOLYLINE entity - */ - private generatePolylineEntity; - /** - * Generate a SPLINE entity - */ - private generateSplineEntity; - /** - * Check if polyline should be closed (first and last points are the same) - */ - private isClosedPolyline; - /** - * Get next entity handle as hex string - */ - private getNextHandle; - /** - * Convert color to DXF format - * Accepts hex color (#RRGGBB) or ACI color index (1-255) - * Returns appropriate DXF color codes based on colorFormat setting - */ - private convertColorToDxf; - /** - * Convert RGB values to nearest AutoCAD Color Index (ACI) - * Uses a simplified mapping to standard ACI colors - */ - private rgbToAciColorIndex; - } - declare class Dxf { - private dxfGenerator; - /** - * Creates a line segment definition for DXF (pass-through for validation). - * Example: start=[0,0], end=[10,5] → DXF line segment from origin to [10,5] - * @param inputs Line segment definition - * @returns Line segment DTO - * @group dxf - * @shortname line segment - * @drawable false - */ - lineSegment( - inputs: Inputs.IO.DxfLineSegmentDto - ): Inputs.IO.DxfLineSegmentDto; - /** - * Creates an arc segment definition for DXF (curved path between two points). - * Example: center=[5,5], radius=5, startAngle=0°, endAngle=90° → quarter circle arc - * @param inputs Arc segment definition - * @returns Arc segment DTO - * @group dxf - * @shortname arc segment - * @drawable false - */ - arcSegment(inputs: Inputs.IO.DxfArcSegmentDto): Inputs.IO.DxfArcSegmentDto; - /** - * Creates a circle segment definition for DXF (closed circular path). - * Example: center=[10,10], radius=5 → full circle with diameter 10 centered at [10,10] - * @param inputs Circle segment definition - * @returns Circle segment DTO - * @group dxf - * @shortname circle segment - * @drawable false - */ - circleSegment( - inputs: Inputs.IO.DxfCircleSegmentDto - ): Inputs.IO.DxfCircleSegmentDto; - /** - * Creates a polyline segment definition for DXF (connected line segments through points). - * Example: points=[[0,0], [5,0], [5,5], [0,5]] → rectangular polyline path - * @param inputs Polyline segment definition - * @returns Polyline segment DTO - * @group dxf - * @shortname polyline segment - * @drawable false - */ - polylineSegment( - inputs: Inputs.IO.DxfPolylineSegmentDto - ): Inputs.IO.DxfPolylineSegmentDto; - /** - * Creates a spline segment definition for DXF (smooth curve through control points). - * Example: controlPoints=[[0,0], [5,10], [10,0]] → smooth curved path through points - * @param inputs Spline segment definition - * @returns Spline segment DTO - * @group dxf - * @shortname spline segment - * @drawable false - */ - splineSegment( - inputs: Inputs.IO.DxfSplineSegmentDto - ): Inputs.IO.DxfSplineSegmentDto; - /** - * Creates a path from multiple segments (combines lines, arcs, circles, polylines, splines). - * Similar to OCCT wires - segments are connected to form a continuous or multi-part path. - * Example: segments=[lineSegment, arcSegment, polylineSegment] → combined path entity - * @param inputs Path definition with segments - * @returns Path DTO - * @group dxf - * @shortname path - * @drawable false - */ - path(inputs: Inputs.IO.DxfPathDto): Inputs.IO.DxfPathDto; - /** - * Creates a paths part with layer and color assignment for DXF organization. - * Groups multiple paths into a single layer with consistent styling. - * Example: paths=[path1, path2], layer="Outlines", color=red → grouped geometry - * @param inputs Paths part definition - * @returns Paths part DTO - * @group dxf - * @shortname paths part - * @drawable false - */ - pathsPart(inputs: Inputs.IO.DxfPathsPartDto): Inputs.IO.DxfPathsPartDto; - /** - * Generates a complete DXF file from paths parts (exports 2D CAD drawing format). - * Supports lines, arcs, circles, polylines, and splines organized in layered paths. - * Example: model with 3 parts on different layers → valid DXF file string for CAD software - * @param inputs DXF model definition - * @returns DXF file content as string - * @group dxf - * @shortname dxf create - * @drawable false - */ - dxfCreate(inputs: Inputs.IO.DxfModelDto): string; - } - declare class IoBitByBit { - dxf: Dxf; - constructor(); - } - /** - * Contains various methods for lines and segments. Line in bitbybit is a simple object that has start and end point properties. - * { start: [ x, y, z ], end: [ x, y, z ] } - */ - declare class Line { - private readonly vector; - private readonly point; - private readonly geometryHelper; - constructor(vector: Vector, point: Point, geometryHelper: GeometryHelper); - /** - * Extracts start point from a line. - * Example: line={start:[0,0,0], end:[10,5,0]} → [0,0,0] - * @param inputs a line - * @returns start point - * @group get - * @shortname line start point - * @drawable true - */ - getStartPoint(inputs: Inputs.Line.LineDto): Inputs.Base.Point3; - /** - * Extracts end point from a line. - * Example: line={start:[0,0,0], end:[10,5,0]} → [10,5,0] - * @param inputs a line - * @returns end point - * @group get - * @shortname line end point - * @drawable true - */ - getEndPoint(inputs: Inputs.Line.LineDto): Inputs.Base.Point3; - /** - * Calculates length (distance) of a line segment. - * Example: line={start:[0,0,0], end:[3,4,0]} → 5 (using Pythagorean theorem) - * @param inputs a line - * @returns line length - * @group get - * @shortname line length - * @drawable false - */ - length(inputs: Inputs.Line.LineDto): number; - /** - * Reverses line direction by swapping start and end points. - * Example: line={start:[0,0,0], end:[10,5,0]} → {start:[10,5,0], end:[0,0,0]} - * @param inputs a line - * @returns reversed line - * @group operations - * @shortname reversed line - * @drawable true - */ - reverse(inputs: Inputs.Line.LineDto): Inputs.Base.Line3; - /** - * Applies transformation matrix to line (rotates, scales, or translates both endpoints). - * Example: line={start:[0,0,0], end:[10,0,0]} with translation [5,5,0] → {start:[5,5,0], end:[15,5,0]} - * @param inputs a line - * @returns transformed line - * @group transforms - * @shortname transform line - * @drawable true - */ - transformLine(inputs: Inputs.Line.TransformLineDto): Inputs.Base.Line3; - /** - * Applies multiple transformations to multiple lines (one transform per line). - * Example: 3 lines with 3 different translation matrices → each line moved independently - * @param inputs lines - * @returns transformed lines - * @group transforms - * @shortname transform lines - * @drawable true - */ - transformsForLines( - inputs: Inputs.Line.TransformsLinesDto - ): Inputs.Base.Line3[]; - /** - * Creates a line from two points (line object with start and end properties). - * Example: start=[0,0,0], end=[10,5,0] → {start:[0,0,0], end:[10,5,0]} - * @param inputs start and end points of the line - * @returns line - * @group create - * @shortname line - * @drawable true - */ - create(inputs: Inputs.Line.LinePointsDto): Inputs.Base.Line3; - /** - * Creates a segment from two points (array format: [start, end]). - * Example: start=[0,0,0], end=[10,5,0] → [[0,0,0], [10,5,0]] - * @param inputs start and end points of the segment - * @returns segment - * @group create - * @shortname segment - * @drawable true - */ - createSegment(inputs: Inputs.Line.LinePointsDto): Inputs.Base.Segment3; - /** - * Calculates point at parameter t along line segment (0=start, 1=end, linear interpolation). - * Example: line={start:[0,0,0], end:[10,0,0]}, param=0.5 → [5,0,0] (midpoint) - * @param inputs line - * @returns point on line - * @group get - * @shortname point on line - * @drawable true - */ - getPointOnLine(inputs: Inputs.Line.PointOnLineDto): Inputs.Base.Point3; - /** - * Creates line segments connecting consecutive points in a list (forms a polyline path). - * Example: points=[[0,0,0], [5,0,0], [5,5,0]] → 2 lines: [0→5] and [5→5,5] - * @param inputs points - * @returns lines - * @group create - * @shortname lines between points - * @drawable true - */ - linesBetweenPoints(inputs: Inputs.Line.PointsLinesDto): Inputs.Base.Line3[]; - /** - * Creates lines by pairing corresponding start and end points from two arrays. - * Filters out zero-length lines. - * Example: starts=[[0,0,0], [5,0,0]], ends=[[0,5,0], [5,5,0]] → 2 lines connecting paired points - * @param inputs start points and end points - * @returns lines - * @group create - * @shortname start and end points to lines - * @drawable true - */ - linesBetweenStartAndEndPoints( - inputs: Inputs.Line.LineStartEndPointsDto - ): Inputs.Base.Line3[]; - /** - * Converts line object to segment array format. - * Example: {start:[0,0,0], end:[10,5,0]} → [[0,0,0], [10,5,0]] - * @param inputs line - * @returns segment - * @group convert - * @shortname line to segment - * @drawable false - */ - lineToSegment(inputs: Inputs.Line.LineDto): Inputs.Base.Segment3; - /** - * Converts multiple line objects to segment array format (batch conversion). - * Example: 3 line objects → 3 segment arrays [[start1, end1], [start2, end2], ...] - * @param inputs lines - * @returns segments - * @group convert - * @shortname lines to segments - * @drawable false - */ - linesToSegments(inputs: Inputs.Line.LinesDto): Inputs.Base.Segment3[]; - /** - * Converts segment array to line object format. - * Example: [[0,0,0], [10,5,0]] → {start:[0,0,0], end:[10,5,0]} - * @param inputs segment - * @returns line - * @group convert - * @shortname segment to line - * @drawable true - */ - segmentToLine(inputs: Inputs.Line.SegmentDto): Inputs.Base.Line3; - /** - * Converts multiple segment arrays to line object format (batch conversion). - * Example: 3 segment arrays → 3 line objects with start/end properties - * @param inputs segments - * @returns lines - * @group convert - * @shortname segments to lines - * @drawable true - */ - segmentsToLines(inputs: Inputs.Line.SegmentsDto): Inputs.Base.Line3[]; - /** - * Calculates intersection point of two lines (or segments if checkSegmentsOnly=true). - * Returns undefined if lines are parallel, skew, or segments don't overlap. - * Example: line1={start:[0,0,0], end:[10,0,0]}, line2={start:[5,-5,0], end:[5,5,0]} → [5,0,0] - * @param inputs line1 and line2 - * @returns intersection point or undefined if no intersection - * @group intersection - * @shortname line-line int - * @drawable true - */ - lineLineIntersection( - inputs: Inputs.Line.LineLineIntersectionDto - ): Inputs.Base.Point3 | undefined; - } - /** - * Contains various list methods. - */ - declare class Lists { - /** - * Gets an item from the list at a specific position using zero-based indexing. - * Example: From [10, 20, 30, 40], getting index 2 returns 30 - * @param inputs a list and an index - * @returns item - * @group get - * @shortname item by index - * @drawable false - */ - getItem(inputs: Inputs.Lists.ListItemDto): T; - /** - * Gets the first item from the list. - * Example: From [10, 20, 30, 40], returns 10 - * @param inputs a list - * @returns first item - * @group get - * @shortname first item - * @drawable false - */ - getFirstItem(inputs: Inputs.Lists.ListCloneDto): T; - /** - * Gets the last item from the list. - * Example: From [10, 20, 30, 40], returns 40 - * @param inputs a list - * @returns last item - * @group get - * @shortname last item - * @drawable false - */ - getLastItem(inputs: Inputs.Lists.ListCloneDto): T; - /** - * Randomly keeps items from the list based on a probability threshold (0 to 1). - * Example: From [1, 2, 3, 4, 5] with threshold 0.5, might return [1, 3, 5] (50% chance for each item) - * @param inputs a list and a threshold for randomization of items to remove - * @returns list with remaining items - * @group get - * @shortname random get threshold - * @drawable false - */ - randomGetThreshold(inputs: Inputs.Lists.RandomThresholdDto): T[]; - /** - * Extracts a portion of the list between start and end positions (end is exclusive). - * Example: From [10, 20, 30, 40, 50] with start=1 and end=4, returns [20, 30, 40] - * @param inputs a list and start and end indexes - * @returns sub list - * @group get - * @shortname sublist - * @drawable false - */ - getSubList(inputs: Inputs.Lists.SubListDto): T[]; - /** - * Gets every nth item from the list, starting from an optional offset position. - * Example: From [0, 1, 2, 3, 4, 5, 6, 7, 8] with nth=3 and offset=0, returns [0, 3, 6] - * Example: From [0, 1, 2, 3, 4, 5, 6, 7, 8] with nth=2 and offset=1, returns [1, 3, 5, 7] - * @param inputs a list and index - * @returns list with filtered items - * @group get - * @shortname every n-th - * @drawable false - */ - getNthItem(inputs: Inputs.Lists.GetNthItemDto): T[]; - /** - * Filters items from the list using a repeating true/false pattern. - * Example: From [0, 1, 2, 3, 4, 5] with pattern [true, true, false], returns [0, 1, 3, 4] (keeps items where pattern is true) - * @param inputs a list and index - * @returns list with filtered items - * @group get - * @shortname by pattern - * @drawable false - */ - getByPattern(inputs: Inputs.Lists.GetByPatternDto): T[]; - /** - * Merges elements from multiple lists at a specific nesting level, grouping elements by position. - * Example: From [[0, 1, 2], [3, 4, 5]] at level 0, returns [[0, 3], [1, 4], [2, 5]] - * @param inputs lists, level and flatten data - * @returns list with merged lists and flattened lists - * @group get - * @shortname merge levels - * @drawable false - */ - mergeElementsOfLists( - inputs: Inputs.Lists.MergeElementsOfLists - ): T[]; - /** - * Finds the length of the longest list among multiple lists. - * Example: From [[1, 2], [3, 4, 5, 6], [7]], returns 4 (length of [3, 4, 5, 6]) - * @param inputs a list of lists - * @returns number of max length - * @group get - * @shortname longest list length - * @drawable false - */ - getLongestListLength( - inputs: Inputs.Lists.GetLongestListLength - ): number; - /** - * Reverses the order of items in the list. - * Example: From [1, 2, 3, 4, 5], returns [5, 4, 3, 2, 1] - * @param inputs a list and an index - * @returns item - * @group edit - * @shortname reverse - * @drawable false - */ - reverse(inputs: Inputs.Lists.ListCloneDto): T[]; - /** - * Randomly rearranges all items in the list (using Fisher-Yates algorithm). - * Example: From [1, 2, 3, 4, 5], might return [3, 1, 5, 2, 4] (order varies each time) - * @param inputs a list - * @returns shuffled list - * @group edit - * @shortname shuffle - * @drawable false - */ - shuffle(inputs: Inputs.Lists.ListCloneDto): T[]; - /** - * Transposes a 2D list by swapping rows and columns (all sublists must be equal length). - * Example: From [[0, 1, 2], [3, 4, 5]], returns [[0, 3], [1, 4], [2, 5]] - * @param inputs a list of lists to flip - * @returns item - * @group edit - * @shortname flip lists - * @drawable false - */ - flipLists(inputs: Inputs.Lists.ListCloneDto): T[][]; - /** - * Splits the list into smaller lists of n elements each. - * Example: From [0, 1, 2, 3, 4, 5, 6, 7, 8] with n=3, returns [[0, 1, 2], [3, 4, 5], [6, 7, 8]] - * Example: From [0, 1, 2, 3, 4] with n=2 and keepRemainder=true, returns [[0, 1], [2, 3], [4]] - * @param inputs a list - * @returns items grouped in lists of n elements - * @group edit - * @shortname group elements - * @drawable false - */ - groupNth(inputs: Inputs.Lists.GroupListDto): T[][]; - /** - * Checks whether the list contains a specific item. - * Example: List [10, 20, 30, 40] with item 30 returns true, with item 50 returns false - * @param inputs a list and an item - * @returns true if item is in list - * @group get - * @shortname contains item - * @drawable false - */ - includes(inputs: Inputs.Lists.IncludesDto): boolean; - /** - * Finds the position (index) of the first occurrence of an item in the list. - * Example: In [10, 20, 30, 20, 40], finding 20 returns 1 (first occurrence), finding 50 returns -1 (not found) - * @param inputs a list and an item - * @returns index of the item or -1 if not found - * @group get - * @shortname find index - * @drawable false - */ - findIndex(inputs: Inputs.Lists.IncludesDto): number; - /** - * Determines the maximum nesting level (depth) of a list structure. - * Example: [1, 2, 3] has depth 1, [[1, 2], [3, 4]] has depth 2, [[[1]]] has depth 3 - * @param inputs a list - * @returns number of depth - * @group get - * @shortname max list depth - * @drawable false - */ - getListDepth(inputs: Inputs.Lists.ListCloneDto<[]>): number; - /** - * Returns the number of items in the list. - * Example: [10, 20, 30, 40, 50] returns 5, [] returns 0 - * @param inputs a length list - * @returns a number - * @group get - * @shortname list length - * @drawable false - */ - listLength(inputs: Inputs.Lists.ListCloneDto): number; - /** - * Inserts an item at a specific position in the list. - * Example: In [10, 20, 30, 40], adding 99 at index 2 gives [10, 20, 99, 30, 40] - * @param inputs a list, item and an index - * @returns list with added item - * @group add - * @shortname add item - * @drawable false - */ - addItemAtIndex(inputs: Inputs.Lists.AddItemAtIndexDto): T[]; - /** - * Inserts the same item at multiple specified positions in the list. - * Example: In [10, 20, 30], adding 99 at indexes [0, 2] gives [99, 10, 20, 99, 30] - * @param inputs a list, item and an indexes - * @returns list with added item - * @group add - * @shortname add item at indexes - * @drawable false - */ - addItemAtIndexes(inputs: Inputs.Lists.AddItemAtIndexesDto): T[]; - /** - * Inserts multiple items at corresponding positions (first item at first index, second item at second index, etc.). - * Example: In [10, 20, 30], adding items [88, 99] at indexes [1, 2] gives [10, 88, 20, 99, 30] - * @param inputs a list, items and an indexes - * @returns list with added items - * @group add - * @shortname add items - * @drawable false - */ - addItemsAtIndexes(inputs: Inputs.Lists.AddItemsAtIndexesDto): T[]; - /** - * Removes the item at a specific position in the list. - * Example: From [10, 20, 30, 40, 50], removing index 2 gives [10, 20, 40, 50] - * @param inputs a list and index - * @returns list with removed item - * @group remove - * @shortname remove item - * @drawable false - */ - removeItemAtIndex(inputs: Inputs.Lists.RemoveItemAtIndexDto): T[]; - /** - * Removes the first item from the list. - * Example: From [10, 20, 30, 40], returns [20, 30, 40] - * @param inputs a list - * @returns list with first item removed - * @group remove - * @shortname remove first item - * @drawable false - */ - removeFirstItem(inputs: Inputs.Lists.ListCloneDto): T[]; - /** - * Removes the last item from the list. - * Example: From [10, 20, 30, 40], returns [10, 20, 30] - * @param inputs a list - * @returns list with last item removed - * @group remove - * @shortname remove last item - * @drawable false - */ - removeLastItem(inputs: Inputs.Lists.ListCloneDto): T[]; - /** - * Removes an item counting from the end of the list (index 0 = last item, 1 = second-to-last, etc.). - * Example: From [10, 20, 30, 40, 50], removing index 1 from end gives [10, 20, 30, 50] (removes 40) - * @param inputs a list and index from end - * @returns list with removed item - * @group remove - * @shortname remove item from end - * @drawable false - */ - removeItemAtIndexFromEnd( - inputs: Inputs.Lists.RemoveItemAtIndexDto - ): T[]; - /** - * Removes items at multiple specified positions from the list. - * Example: From [10, 20, 30, 40, 50], removing indexes [1, 3] gives [10, 30, 50] - * @param inputs a list and indexes - * @returns list with removed items - * @group remove - * @shortname remove items - * @drawable false - */ - removeItemsAtIndexes( - inputs: Inputs.Lists.RemoveItemsAtIndexesDto - ): T[]; - /** - * Clears all items from the list, resulting in an empty list. - * Example: From [10, 20, 30, 40], returns [] - * @param inputs a list - * @returns The length is set to 0 and same array memory object is returned - * @group remove - * @shortname remove all items - * @drawable false - */ - removeAllItems(inputs: Inputs.Lists.ListDto): T[]; - /** - * Removes every nth item from the list, starting from an optional offset position. - * Example: From [0, 1, 2, 3, 4, 5, 6, 7, 8] with nth=3 and offset=0, returns [1, 2, 4, 5, 7, 8] (removes 0, 3, 6) - * @param inputs a list and index - * @returns list with removed item - * @group remove - * @shortname every n-th - * @drawable false - */ - removeNthItem(inputs: Inputs.Lists.RemoveNthItemDto): T[]; - /** - * Randomly removes items from the list based on a probability threshold (0 to 1). - * Example: From [1, 2, 3, 4, 5] with threshold 0.5, might return [2, 4] (50% chance to remove each item) - * @param inputs a list and a threshold for randomization of items to remove - * @returns list with removed items - * @group remove - * @shortname random remove threshold - * @drawable false - */ - randomRemoveThreshold(inputs: Inputs.Lists.RandomThresholdDto): T[]; - /** - * Removes duplicate numbers from the list, keeping only the first occurrence of each value. - * Example: From [1, 2, 3, 2, 4, 3, 5], returns [1, 2, 3, 4, 5] - * @param inputs a list of numbers - * @returns list with unique numbers - * @group remove - * @shortname remove duplicate numbers - * @drawable false - */ - removeDuplicateNumbers( - inputs: Inputs.Lists.RemoveDuplicatesDto - ): number[]; - /** - * Removes duplicate numbers that are within a specified tolerance range of each other. - * Example: From [1.0, 1.001, 2.0, 2.002, 3.0] with tolerance 0.01, returns [1.0, 2.0, 3.0] - * @param inputs a list of numbers and the tolerance - * @returns list with unique numbers - * @group remove - * @shortname remove duplicates tol - * @drawable false - */ - removeDuplicateNumbersTolerance( - inputs: Inputs.Lists.RemoveDuplicatesToleranceDto - ): number[]; - /** - * Removes duplicate items from the list using strict equality comparison (works with any type). - * Example: From ['a', 'b', 'c', 'a', 'd', 'b'], returns ['a', 'b', 'c', 'd'] - * @param inputs a list - * @returns list with unique items - * @group remove - * @shortname remove duplicates - * @drawable false - */ - removeDuplicates(inputs: Inputs.Lists.RemoveDuplicatesDto): T[]; - /** - * Appends an item to the end of the list. - * Example: To [10, 20, 30], adding 40 gives [10, 20, 30, 40] - * @param inputs a list and an item - * @returns list with added item - * @group add - * @shortname add item to list - * @drawable false - */ - addItem(inputs: Inputs.Lists.AddItemDto): T[]; - /** - * Adds an item to the beginning of the list. - * Example: To [10, 20, 30], prepending 5 gives [5, 10, 20, 30] - * @param inputs a list and an item - * @returns list with added item - * @group add - * @shortname prepend item to list - * @drawable false - */ - prependItem(inputs: Inputs.Lists.AddItemDto): T[]; - /** - * Adds an item either at the beginning or end of the list based on the position parameter. - * Example: To [10, 20, 30], adding 5 at 'first' gives [5, 10, 20, 30], at 'last' gives [10, 20, 30, 5] - * @param inputs a list, item and an option for first or last position - * @returns list with added item - * @group add - * @shortname item at first or last - * @drawable false - */ - addItemFirstLast(inputs: Inputs.Lists.AddItemFirstLastDto): T[]; - /** - * Combines multiple lists into a single list by joining them end-to-end. - * Example: From [[1, 2], [3, 4], [5, 6]], returns [1, 2, 3, 4, 5, 6] - * @param inputs lists to concatenate - * @returns concatenated list - * @group add - * @shortname concatenate lists - * @drawable false - */ - concatenate(inputs: Inputs.Lists.ConcatenateDto): T[]; - /** - * Creates a new empty list with no items. - * Example: Returns [] - * @returns an empty array list - * @group create - * @shortname empty list - * @drawable false - */ - createEmptyList(): []; - /** - * Creates a new list by repeating an item a specified number of times. - * Example: Repeating 5 three times returns [5, 5, 5] - * @param inputs an item to multiply - * @returns list - * @group create - * @shortname repeat - * @drawable false - */ - repeat(inputs: Inputs.Lists.MultiplyItemDto): T[]; - /** - * Repeats a pattern of items cyclically until reaching a target list length. - * Example: Pattern [1, 2, 3] with length 7 returns [1, 2, 3, 1, 2, 3, 1] - * @param inputs a list to multiply and a length limit - * @returns list - * @group create - * @shortname repeat in pattern - * @drawable false - */ - repeatInPattern(inputs: Inputs.Lists.RepeatInPatternDto): T[]; - /** - * Sorts numbers in ascending (lowest to highest) or descending (highest to lowest) order. - * Example: [5, 2, 8, 1, 9] ascending returns [1, 2, 5, 8, 9], descending returns [9, 8, 5, 2, 1] - * @param inputs a list of numbers to sort and an option for ascending or descending order - * @returns list - * @group sorting - * @shortname sort numbers - * @drawable false - */ - sortNumber(inputs: Inputs.Lists.SortDto): number[]; - /** - * Sorts text strings alphabetically in ascending (A to Z) or descending (Z to A) order. - * Example: ['dog', 'apple', 'cat', 'banana'] ascending returns ['apple', 'banana', 'cat', 'dog'] - * @param inputs a list of texts to sort and an option for ascending or descending order - * @returns list - * @group sorting - * @shortname sort texts - * @drawable false - */ - sortTexts(inputs: Inputs.Lists.SortDto): string[]; - /** - * Sorts objects by comparing numeric values of a specified property. - * Example: [{age: 30}, {age: 20}, {age: 25}] sorted by 'age' ascending returns [{age: 20}, {age: 25}, {age: 30}] - * @param inputs a list to sort, a property to sort by and an option for ascending or descending order - * @returns list - * @group sorting - * @shortname sort json objects - * @drawable false - */ - sortByPropValue(inputs: Inputs.Lists.SortJsonDto): any[]; - /** - * Combines multiple lists by alternating elements from each list (first from list1, first from list2, second from list1, etc.). - * Example: From [[0, 1, 2], [3, 4, 5]], returns [0, 3, 1, 4, 2, 5] - * @param inputs Lists to interleave - * @returns Flattened interleaved list - * @group transform - * @shortname interleave lists - * @drawable false - */ - interleave(inputs: Inputs.Lists.InterleaveDto): T[]; - } - /** - * Contains various logic methods. - */ - declare class Logic { - /** - * Creates and returns a boolean value (pass-through for boolean input). - * Example: true → true, false → false - * @param inputs a true or false boolean - * @returns boolean - * @group create - * @shortname boolean - * @drawable false - */ - boolean(inputs: Inputs.Logic.BooleanDto): boolean; - /** - * Generates a random boolean list where each value has a threshold chance of being true. - * Example: length=5, threshold=0.7 → might produce [true, true, false, true, true] - * @param inputs a length and a threshold for randomization of true values - * @returns booleans - * @group create - * @shortname random booleans - * @drawable false - */ - randomBooleans(inputs: Inputs.Logic.RandomBooleansDto): boolean[]; - /** - * Converts numbers to booleans using two thresholds with gradient randomization between them. - * Values below trueThreshold → always true, above falseThreshold → always false. - * Between thresholds → probability gradient (closer to false threshold = higher chance of false). - * Example: [0.1, 0.4, 0.6, 0.9] with thresholds [0.3, 0.7] → [true, gradient, gradient, false] - * @param inputs a length and a threshold for randomization of true values - * @returns booleans - * @group create - * @shortname 2 threshold random gradient - * @drawable false - */ - twoThresholdRandomGradient( - inputs: Inputs.Logic.TwoThresholdRandomGradientDto - ): boolean[]; - /** - * Converts numbers to booleans based on a threshold (below threshold → true, above → false). - * Can be inverted to flip the logic. - * Example: [0.3, 0.7, 0.5] with threshold=0.6 → [true, false, true] - * @param inputs a length and a threshold for randomization of true values - * @returns booleans - * @group create - * @shortname threshold boolean list - * @drawable false - */ - thresholdBooleanList( - inputs: Inputs.Logic.ThresholdBooleanListDto - ): boolean[]; - /** - * Converts numbers to booleans using multiple range thresholds (gaps define true ranges). - * Values within any gap range → true, outside all gaps → false. Can be inverted. - * Example: [0.2, 0.5, 0.8] with gaps [[0.3, 0.6], [0.7, 0.9]] → [false, true, true] - * @param inputs a length and a threshold for randomization of true values - * @returns booleans - * @group create - * @shortname threshold gaps boolean list - * @drawable false - */ - thresholdGapsBooleanList( - inputs: Inputs.Logic.ThresholdGapsBooleanListDto - ): boolean[]; - /** - * Applies NOT operator to flip a boolean value. - * Example: true → false, false → true - * @param inputs a true or false boolean - * @returns boolean - * @group edit - * @shortname not - * @drawable false - */ - not(inputs: Inputs.Logic.BooleanDto): boolean; - /** - * Applies NOT operator to flip all boolean values in a list. - * Example: [true, false, true] → [false, true, false] - * @param inputs a list of true or false booleans - * @returns booleans - * @group edit - * @shortname not list - * @drawable false - */ - notList(inputs: Inputs.Logic.BooleanListDto): boolean[]; - /** - * Compares two values using various operators (==, !=, ===, !==, <, <=, >, >=). - * Example: 5 > 3 → true, 'hello' === 'world' → false - * @param inputs two values to be compared - * @returns Result of the comparison - * @group operations - * @shortname compare - * @drawable false - */ - compare(inputs: Inputs.Logic.ComparisonDto): boolean; - /** - * Conditionally passes a value through if boolean is true, otherwise returns undefined. - * Example: value=42, boolean=true → 42, value=42, boolean=false → undefined - * @param inputs a value and a boolean value - * @returns value or undefined - * @group operations - * @shortname value gate - * @drawable false - */ - valueGate(inputs: Inputs.Logic.ValueGateDto): T | undefined; - /** - * Returns the first defined (non-undefined) value from two options (fallback pattern). - * Example: value1=42, value2=10 → 42, value1=undefined, value2=10 → 10 - * @param inputs two values - * @returns value or undefined - * @group operations - * @shortname first defined value gate - * @drawable false - */ - firstDefinedValueGate( - inputs: Inputs.Logic.TwoValueGateDto - ): T | U | undefined; - } - /** - * Contains various math methods. - */ - declare class MathBitByBit { - /** - * Creates and returns a number value (pass-through for number input). - * Example: Input 42 → 42, Input 3.14 → 3.14 - * @param inputs a number to be created - * @returns number - * @group create - * @shortname number - * @drawable false - */ - number(inputs: Inputs.Math.NumberDto): number; - /** - * Performs basic arithmetic operations on two numbers (add, subtract, multiply, divide, power, modulus). - * Example: 5 + 3 → 8, 10 % 3 → 1, 2 ^ 3 → 8 - * @param inputs two numbers and operator - * @returns Result of math operation action - * @group operations - * @shortname two numbers - * @drawable false - */ - twoNrOperation(inputs: Inputs.Math.ActionOnTwoNumbersDto): number; - /** - * Calculates the remainder after division (modulus operation). - * Example: 10 % 3 → 1, 17 % 5 → 2 - * @param inputs two numbers and operator - * @returns Result of modulus operation - * @group operations - * @shortname modulus - * @drawable false - */ - modulus(inputs: Inputs.Math.ModulusDto): number; - /** - * Rounds a number to specified decimal places. - * Example: 1.32156 with 3 decimals returns 1.322 - * @param inputs a number and decimal places - * @returns Result of rounding - * @group operations - * @shortname round to decimals - * @drawable false - */ - roundToDecimals(inputs: Inputs.Math.RoundToDecimalsDto): number; - /** - * Rounds a number to specified decimal places and removes trailing zeros. - * Example: 1.32156 with 3 decimals returns 1.322, but 1.320000001 returns 1.32, and 1.000 returns 1 - * @param inputs a number and decimal places - * @returns Result of rounding as a number without trailing zeros - * @group operations - * @shortname round trim zeros - * @drawable false - */ - roundAndRemoveTrailingZeros(inputs: Inputs.Math.RoundToDecimalsDto): number; - /** - * Performs mathematical operations on a single number (absolute, negate, sqrt, trig functions, logarithms, etc.). - * Example: sqrt(5) → 2.236, abs(-3) → 3, sin(π/2) → 1 - * @param inputs one number and operator action - * @returns Result of math operation - * @group operations - * @shortname one number - * @drawable false - */ - oneNrOperation(inputs: Inputs.Math.ActionOnOneNumberDto): number; - /** - * Maps a number from one range to another range proportionally. - * Example: 5 from [0,10] to [0,100] → 50, 0.5 from [0,1] to [-10,10] → 0 - * @param inputs one number and operator action - * @returns Result of mapping - * @group operations - * @shortname remap - * @drawable false - */ - remap(inputs: Inputs.Math.RemapNumberDto): number; - /** - * Generates a random decimal number between 0 (inclusive) and 1 (exclusive). - * Example: Outputs like 0.342, 0.891, or any value in [0, 1) - * @returns A random number between 0 and 1 - * @group generate - * @shortname random 0 - 1 - * @drawable false - */ - random(): number; - /** - * Generates a random number within a specified range (low to high). - * Example: Range [0, 10] → outputs like 3.7, 8.2, or any value between 0 and 10 - * @param inputs low and high numbers - * @returns A random number - * @group generate - * @shortname random number - * @drawable false - */ - randomNumber(inputs: Inputs.Math.RandomNumberDto): number; - /** - * Generates multiple random numbers within a specified range. - * Example: Range [0, 10] with 3 items → [2.5, 7.1, 4.8] - * @param inputs low and high numbers - * @returns A list of random numbers - * @group generate - * @shortname random numbers - * @drawable false - */ - randomNumbers(inputs: Inputs.Math.RandomNumbersDto): number[]; - /** - * Returns the mathematical constant π (pi) ≈ 3.14159. - * Example: Outputs 3.141592653589793 - * @returns A number PI - * @group generate - * @shortname π - * @drawable false - */ - pi(): number; - /** - * Formats a number as a string with a fixed number of decimal places (always shows trailing zeros). - * Example: 3.14159 with 2 decimals → '3.14', 5 with 3 decimals → '5.000' - * @param inputs a number to be rounded to decimal places - * @returns number - * @group operations - * @shortname to fixed - * @drawable false - */ - toFixed(inputs: Inputs.Math.ToFixedDto): string; - /** - * Adds two numbers together. - * Example: 5 + 3 → 8, -2 + 7 → 5 - * @param inputs two numbers - * @returns number - * @group basics - * @shortname add - * @drawable false - */ - add(inputs: Inputs.Math.TwoNumbersDto): number; - /** - * Subtracts the second number from the first. - * Example: 10 - 3 → 7, 5 - 8 → -3 - * @param inputs two numbers - * @returns number - * @group basics - * @shortname subtract - * @drawable false - */ - subtract(inputs: Inputs.Math.TwoNumbersDto): number; - /** - * Multiplies two numbers together. - * Example: 5 × 3 → 15, -2 × 4 → -8 - * @param inputs two numbers - * @returns number - * @group basics - * @shortname multiply - * @drawable false - */ - multiply(inputs: Inputs.Math.TwoNumbersDto): number; - /** - * Divides the first number by the second. - * Example: 10 ÷ 2 → 5, 7 ÷ 2 → 3.5 - * @param inputs two numbers - * @returns number - * @group basics - * @shortname divide - * @drawable false - */ - divide(inputs: Inputs.Math.TwoNumbersDto): number; - /** - * Raises the first number to the power of the second (exponentiation). - * Example: 2³ → 8, 5² → 25, 10⁻¹ → 0.1 - * @param inputs two numbers - * @returns number - * @group basics - * @shortname power - * @drawable false - */ - power(inputs: Inputs.Math.TwoNumbersDto): number; - /** - * Calculates the square root of a number. - * Example: √9 → 3, √2 → 1.414, √16 → 4 - * @param inputs a number - * @returns number - * @group basics - * @shortname sqrt - * @drawable false - */ - sqrt(inputs: Inputs.Math.NumberDto): number; - /** - * Returns the absolute value (removes negative sign, always positive or zero). - * Example: |-5| → 5, |3| → 3, |0| → 0 - * @param inputs a number - * @returns number - * @group basics - * @shortname abs - * @drawable false - */ - abs(inputs: Inputs.Math.NumberDto): number; - /** - * Rounds a number to the nearest integer. - * Example: 3.7 → 4, 2.3 → 2, 5.5 → 6 - * @param inputs a number - * @returns number - * @group basics - * @shortname round - * @drawable false - */ - round(inputs: Inputs.Math.NumberDto): number; - /** - * Rounds a number down to the nearest integer (toward negative infinity). - * Example: 3.7 → 3, -2.3 → -3, 5 → 5 - * @param inputs a number - * @returns number - * @group basics - * @shortname floor - * @drawable false - */ - floor(inputs: Inputs.Math.NumberDto): number; - /** - * Rounds a number up to the nearest integer (toward positive infinity). - * Example: 3.2 → 4, -2.8 → -2, 5 → 5 - * @param inputs a number - * @returns number - * @group basics - * @shortname ceil - * @drawable false - */ - ceil(inputs: Inputs.Math.NumberDto): number; - /** - * Negates a number (flips its sign: positive becomes negative, negative becomes positive). - * Example: 5 → -5, -3 → 3, 0 → 0 - * @param inputs a number - * @returns number - * @group basics - * @shortname negate - * @drawable false - */ - negate(inputs: Inputs.Math.NumberDto): number; - /** - * Calculates the natural logarithm (base e) of a number. - * Example: ln(2.718) → ~1, ln(7.389) → ~2, ln(1) → 0 - * @param inputs a number - * @returns number - * @group basics - * @shortname ln - * @drawable false - */ - ln(inputs: Inputs.Math.NumberDto): number; - /** - * Calculates the base 10 logarithm of a number. - * Example: log₁₀(100) → 2, log₁₀(1000) → 3, log₁₀(10) → 1 - * @param inputs a number - * @returns number - * @group basics - * @shortname log10 - * @drawable false - */ - log10(inputs: Inputs.Math.NumberDto): number; - /** - * Raises 10 to the power of the input number. - * Example: 10² → 100, 10³ → 1000, 10⁻¹ → 0.1 - * @param inputs a number - * @returns number - * @group basics - * @shortname ten pow - * @drawable false - */ - tenPow(inputs: Inputs.Math.NumberDto): number; - /** - * Calculates the sine of an angle in radians. - * Example: sin(0) → 0, sin(π/2) → 1, sin(π) → ~0 - * @param inputs a number - * @returns number - * @group basics - * @shortname sin - * @drawable false - */ - sin(inputs: Inputs.Math.NumberDto): number; - /** - * Calculates the cosine of an angle in radians. - * Example: cos(0) → 1, cos(π/2) → ~0, cos(π) → -1 - * @param inputs a number - * @returns number - * @group basics - * @shortname cos - * @drawable false - */ - cos(inputs: Inputs.Math.NumberDto): number; - /** - * Calculates the tangent of an angle in radians. - * Example: tan(0) → 0, tan(π/4) → ~1, tan(π/2) → infinity - * @param inputs a number - * @returns number - * @group basics - * @shortname tan - * @drawable false - */ - tan(inputs: Inputs.Math.NumberDto): number; - /** - * Calculates the arcsine (inverse sine) in radians, returns angle whose sine is the input. - * Example: asin(0) → 0, asin(1) → π/2 (~1.57), asin(0.5) → π/6 (~0.524) - * @param inputs a number - * @returns number - * @group basics - * @shortname asin - * @drawable false - */ - asin(inputs: Inputs.Math.NumberDto): number; - /** - * Calculates the arccosine (inverse cosine) in radians, returns angle whose cosine is the input. - * Example: acos(1) → 0, acos(0) → π/2 (~1.57), acos(-1) → π (~3.14) - * @param inputs a number - * @returns number - * @group basics - * @shortname acos - * @drawable false - */ - acos(inputs: Inputs.Math.NumberDto): number; - /** - * Calculates the arctangent (inverse tangent) in radians, returns angle whose tangent is the input. - * Example: atan(0) → 0, atan(1) → π/4 (~0.785), atan(-1) → -π/4 - * @param inputs a number - * @returns number - * @group basics - * @shortname atan - * @drawable false - */ - atan(inputs: Inputs.Math.NumberDto): number; - /** - * Calculates e raised to the power of the input (exponential function). - * Example: e⁰ → 1, e¹ → ~2.718, e² → ~7.389 - * @param inputs a number - * @returns number - * @group basics - * @shortname exp - * @drawable false - */ - exp(inputs: Inputs.Math.NumberDto): number; - /** - * Converts an angle from degrees to radians. - * Example: 180° → π (~3.14159), 90° → π/2 (~1.5708), 360° → 2π - * @param inputs a number in degrees - * @returns number - * @group basics - * @shortname deg to rad - * @drawable false - */ - degToRad(inputs: Inputs.Math.NumberDto): number; - /** - * Converts an angle from radians to degrees. - * Example: π → 180°, π/2 → 90°, 2π → 360° - * @param inputs a number in radians - * @returns number - * @group basics - * @shortname rad to deg - * @drawable false - */ - radToDeg(inputs: Inputs.Math.NumberDto): number; - /** - * Applies an easing function to interpolate smoothly between min and max values. - * Example: x=0.5 from [0,100] with easeInQuad → applies quadratic acceleration curve - * Useful for smooth animations with various acceleration/deceleration curves. - * @param inputs a number, min and max values, and ease type - * @returns number - * @group operations - * @shortname ease - * @drawable false - */ - ease(inputs: Inputs.Math.EaseDto): number; - /** - * Constrains a value between a minimum and maximum value. - * Example: clamp(5, 0, 3) returns 3, clamp(-1, 0, 3) returns 0, clamp(1.5, 0, 3) returns 1.5 - * @param inputs a number, min and max values - * @returns number clamped between min and max - * @group operations - * @shortname clamp - * @drawable false - */ - clamp(inputs: Inputs.Math.ClampDto): number; - /** - * Linear interpolation between two values using parameter t (0 to 1). - * Example: From 0 to 100 at t=0.5 → 50, From 10 to 20 at t=0.25 → 12.5 - * When t=0 returns start, when t=1 returns end. Useful for smooth transitions. - * @param inputs start value, end value, and interpolation parameter t - * @returns interpolated value - * @group operations - * @shortname lerp - * @drawable false - */ - lerp(inputs: Inputs.Math.LerpDto): number; - /** - * Calculates the interpolation parameter t for a value between start and end (reverse of lerp). - * Example: Value 5 in range [0,10] → t=0.5, Value 2.5 in range [0,10] → t=0.25 - * Returns what t value would produce the given value in a lerp. Useful for finding relative position. - * @param inputs start value, end value, and the value to find t for - * @returns interpolation parameter (typically 0-1) - * @group operations - * @shortname inverse lerp - * @drawable false - */ - inverseLerp(inputs: Inputs.Math.InverseLerpDto): number; - /** - * Hermite interpolation with smooth acceleration and deceleration (smoother than linear lerp). - * Example: x=0 → 0, x=0.5 → 0.5, x=1 → 1 (but with smooth S-curve in between) - * Input is automatically clamped to [0,1]. Output eases in and out smoothly. Great for animations. - * @param inputs a number between 0 and 1 - * @returns smoothly interpolated value - * @group operations - * @shortname smoothstep - * @drawable false - */ - smoothstep(inputs: Inputs.Math.NumberDto): number; - /** - * Returns the sign of a number: -1 for negative, 0 for zero, 1 for positive. - * Example: -5 → -1, 0 → 0, 3.14 → 1 - * Useful for determining direction or polarity. - * @param inputs a number - * @returns -1, 0, or 1 - * @group operations - * @shortname sign - * @drawable false - */ - sign(inputs: Inputs.Math.NumberDto): number; - /** - * Returns the fractional part of a number (removes integer part, keeps decimals). - * Example: 3.14 → 0.14, 5.9 → 0.9, -2.3 → 0.7 - * Useful for wrapping values and creating repeating patterns. - * @param inputs a number - * @returns fractional part (always positive) - * @group operations - * @shortname fract - * @drawable false - */ - fract(inputs: Inputs.Math.NumberDto): number; - /** - * Wraps a number within a specified range (creates repeating cycle). - * Example: 1.5 in range [0,1) → 0.5, -0.3 in range [0,1) → 0.7, 370° in range [0,360) → 10° - * Useful for angles, UVs, or any repeating domain. Like modulo but handles negatives properly. - * @param inputs a number, min and max values - * @returns wrapped value within range - * @group operations - * @shortname wrap - * @drawable false - */ - wrap(inputs: Inputs.Math.WrapDto): number; - /** - * Creates a ping-pong (back-and-forth) effect that bounces a value between 0 and length. - * The value goes from 0→length, then back length→0, repeating this cycle. - * Example: With length=1: t=0→0, t=0.5→0.5, t=1→1 (peak), t=1.5→0.5, t=2→0, t=2.5→0.5 (repeats) - * Useful for creating bouncing animations like a ball or oscillating motion. - * @param inputs time value t and length - * @returns value bouncing between 0 and length - * @group operations - * @shortname ping pong - * @drawable false - */ - pingPong(inputs: Inputs.Math.PingPongDto): number; - /** - * Moves a value toward a target by a maximum delta amount (never overshooting). - * Example: From 0 toward 10 by max 3 → 3, From 8 toward 10 by max 3 → 10 (reached) - * Useful for smooth movement with maximum speed limits. - * @param inputs current value, target value, and maximum delta - * @returns new value moved toward target - * @group operations - * @shortname move towards - * @drawable false - */ - moveTowards(inputs: Inputs.Math.MoveTowardsDto): number; - private easeInSine; - private easeOutSine; - private easeInOutSine; - private easeInQuad; - private easeOutQuad; - private easeInOutQuad; - private easeInCubic; - private easeOutCubic; - private easeInOutCubic; - private easeInQuart; - private easeOutQuart; - private easeInOutQuart; - private easeInQuint; - private easeOutQuint; - private easeInOutQuint; - private easeInExpo; - private easeOutExpo; - private easeInOutExpo; - private easeInCirc; - private easeOutCirc; - private easeInOutCirc; - private easeInBack; - private easeOutBack; - private easeInOutBack; - private easeInElastic; - private easeOutElastic; - private easeInOutElastic; - private easeInBounce; - private easeOutBounce; - private easeInOutBounce; - } - /** - * Contains various mesh helper methods that are not necessarily present in higher level CAD kernels that bitbybit is using. - */ - declare class MeshBitByBit { - private readonly vector; - private readonly polyline; - constructor(vector: Vector, polyline: Polyline); - /** - * Calculates signed distance from a point to a plane (positive=above plane, negative=below). - * Example: point=[0,5,0], plane={normal:[0,1,0], d:0} → 5 (point is 5 units above XZ plane) - * @param inputs a point and a plane - * @returns signed distance - * @group base - * @shortname signed dist to plane - * @drawable false - */ - signedDistanceToPlane( - inputs: Inputs.Mesh.SignedDistanceFromPlaneToPointDto - ): number; - /** - * Calculates plane equation from triangle vertices (normal vector and distance from origin). - * Returns undefined if triangle is degenerate (zero area, collinear points). - * Example: triangle=[[0,0,0], [1,0,0], [0,1,0]] → {normal:[0,0,1], d:0} (XY plane) - * @param inputs triangle and tolerance - * @returns triangle plane - * @group traingle - * @shortname triangle plane - * @drawable false - */ - calculateTrianglePlane( - inputs: Inputs.Mesh.TriangleToleranceDto - ): Inputs.Base.TrianglePlane3 | undefined; - /** - * Calculates intersection segment of two triangles (line segment where they cross). - * Returns undefined if triangles don't intersect, are parallel, or are coplanar. - * Example: triangle1=[[0,0,0], [2,0,0], [1,2,0]], triangle2=[[1,-1,1], [1,1,1], [1,1,-1]] → [[1,0,0], [1,1,0]] - * @param inputs first triangle, second triangle, and tolerance - * @returns intersection segment or undefined if no intersection - * @group traingle - * @shortname triangle-triangle int - * @drawable false - */ - triangleTriangleIntersection( - inputs: Inputs.Mesh.TriangleTriangleToleranceDto - ): Inputs.Base.Segment3 | undefined; - /** - * Calculates all intersection segments between two triangle meshes (pairwise triangle tests). - * Returns array of line segments where mesh surfaces intersect. - * Example: cube mesh intersecting with sphere mesh → multiple segments forming intersection curve - * @param inputs first mesh, second mesh, and tolerance - * @returns array of intersection segments - * @group mesh - * @shortname mesh-mesh int segments - * @drawable false - */ - meshMeshIntersectionSegments( - inputs: Inputs.Mesh.MeshMeshToleranceDto - ): Inputs.Base.Segment3[]; - /** - * Calculates intersection polylines between two meshes by sorting segments into connected paths. - * Segments are joined end-to-end to form continuous or closed curves. - * Example: cube-sphere intersection → closed polyline loops where surfaces meet - * @param inputs first mesh, second mesh, and tolerance - * @returns array of intersection polylines - * @group mesh - * @shortname mesh-mesh int polylines - * @drawable true - */ - meshMeshIntersectionPolylines( - inputs: Inputs.Mesh.MeshMeshToleranceDto - ): Inputs.Base.Polyline3[]; - /** - * Calculates intersection points between two meshes as point arrays (one array per polyline). - * Closed polylines have first point duplicated at end. - * Example: cube-sphere intersection → arrays of points defining intersection curves - * @param inputs first mesh, second mesh, and tolerance - * @returns array of intersection points - * @group mesh - * @shortname mesh-mesh int points - * @drawable false - */ - meshMeshIntersectionPoints( - inputs: Inputs.Mesh.MeshMeshToleranceDto - ): Inputs.Base.Point3[][]; - private computeIntersectionPoint; - } - /** - * Contains various methods for points. Point in bitbybit is simply an array containing 3 numbers for [x, y, z]. - * Because of this form Point can be interchanged with Vector, which also is an array in [x, y, z] form. - * When creating 2D points, z coordinate is simply set to 0 - [x, y, 0]. - */ - declare class Point { - private readonly geometryHelper; - private readonly transforms; - private readonly vector; - private readonly lists; - constructor( - geometryHelper: GeometryHelper, - transforms: Transforms, - vector: Vector, - lists: Lists - ); - /** - * Applies transformation matrix to a single point (rotates, scales, or translates). - * Example: point=[0,0,0] with translation [5,5,0] → [5,5,0] - * @param inputs Contains a point and the transformations to apply - * @returns Transformed point - * @group transforms - * @shortname transform point - * @drawable true - */ - transformPoint(inputs: Inputs.Point.TransformPointDto): Inputs.Base.Point3; - /** - * Applies same transformation matrix to multiple points (batch transform). - * Example: 5 points with rotation 90° → all 5 points rotated together - * @param inputs Contains points and the transformations to apply - * @returns Transformed points - * @group transforms - * @shortname transform points - * @drawable true - */ - transformPoints( - inputs: Inputs.Point.TransformPointsDto - ): Inputs.Base.Point3[]; - /** - * Applies different transformation matrices to corresponding points (one transform per point). - * Arrays must have equal length. - * Example: 3 points with 3 different translations → each point moved independently - * @param inputs Contains points and the transformations to apply - * @returns Transformed points - * @group transforms - * @shortname transforms for points - * @drawable true - */ - transformsForPoints( - inputs: Inputs.Point.TransformsForPointsDto - ): Inputs.Base.Point3[]; - /** - * Moves multiple points by a translation vector (same offset for all points). - * Example: points=[[0,0,0], [1,0,0]], translation=[5,5,0] → [[5,5,0], [6,5,0]] - * @param inputs Contains points and the translation vector - * @returns Translated points - * @group transforms - * @shortname translate points - * @drawable true - */ - translatePoints( - inputs: Inputs.Point.TranslatePointsDto - ): Inputs.Base.Point3[]; - /** - * Moves multiple points by corresponding translation vectors (one vector per point). - * Arrays must have equal length. - * Example: 3 points with 3 different vectors → each point moved by its corresponding vector - * @param inputs Contains points and the translation vector - * @returns Translated points - * @group transforms - * @shortname translate points with vectors - * @drawable true - */ - translatePointsWithVectors( - inputs: Inputs.Point.TranslatePointsWithVectorsDto - ): Inputs.Base.Point3[]; - /** - * Moves multiple points by separate X, Y, Z values (convenience method for translation). - * Example: points=[[0,0,0]], x=10, y=5, z=0 → [[10,5,0]] - * @param inputs Contains points and the translation in x y and z - * @returns Translated points - * @group transforms - * @shortname translate xyz points - * @drawable true - */ - translateXYZPoints( - inputs: Inputs.Point.TranslateXYZPointsDto - ): Inputs.Base.Point3[]; - /** - * Scales multiple points around a center point with different factors per axis. - * Example: points=[[10,0,0]], center=[5,0,0], scaleXyz=[2,1,1] → [[15,0,0]] (doubles X distance from center) - * @param inputs Contains points, center point and scale factors - * @returns Scaled points - * @group transforms - * @shortname scale points on center - * @drawable true - */ - scalePointsCenterXYZ( - inputs: Inputs.Point.ScalePointsCenterXYZDto - ): Inputs.Base.Point3[]; - /** - * Stretches multiple points along a direction from a center point (directional scaling). - * Example: points=[[10,0,0]], center=[0,0,0], direction=[1,0,0], scale=2 → [[20,0,0]] - * @param inputs Contains points, center point, direction and scale factor - * @returns Stretched points - * @group transforms - * @shortname stretch points dir from center - * @drawable true - */ - stretchPointsDirFromCenter( - inputs: Inputs.Point.StretchPointsDirFromCenterDto - ): Inputs.Base.Point3[]; - /** - * Rotates multiple points around a center point along a custom axis. - * Example: points=[[10,0,0]], center=[0,0,0], axis=[0,1,0], angle=90° → [[0,0,-10]] - * @param inputs Contains points, axis, center point and angle of rotation - * @returns Rotated points - * @group transforms - * @shortname rotate points center axis - * @drawable true - */ - rotatePointsCenterAxis( - inputs: Inputs.Point.RotatePointsCenterAxisDto - ): Inputs.Base.Point3[]; - /** - * Calculates axis-aligned bounding box containing all points (min, max, center, width, height, length). - * Example: points=[[0,0,0], [10,5,3]] → {min:[0,0,0], max:[10,5,3], center:[5,2.5,1.5], width:10, height:5, length:3} - * @param inputs Points - * @returns Bounding box of points - * @group extract - * @shortname bounding box pts - * @drawable true - */ - boundingBoxOfPoints( - inputs: Inputs.Point.PointsDto - ): Inputs.Base.BoundingBox; - /** - * Calculates distance to the nearest point in a collection. - * Example: point=[0,0,0], points=[[5,0,0], [10,0,0], [3,0,0]] → 3 (distance to [3,0,0]) - * @param inputs Point from which to measure and points to measure the distance against - * @returns Distance to closest point - * @group extract - * @shortname distance to closest pt - * @drawable false - */ - closestPointFromPointsDistance( - inputs: Inputs.Point.ClosestPointFromPointsDto - ): number; - /** - * Finds array index of the nearest point in a collection (1-based index, not 0-based). - * Example: point=[0,0,0], points=[[5,0,0], [10,0,0], [3,0,0]] → 3 (index of [3,0,0]) - * @param inputs Point from which to find the index in a collection of points - * @returns Closest point index - * @group extract - * @shortname index of closest pt - * @drawable false - */ - closestPointFromPointsIndex( - inputs: Inputs.Point.ClosestPointFromPointsDto - ): number; - /** - * Finds the nearest point in a collection to a reference point. - * Example: point=[0,0,0], points=[[5,0,0], [10,0,0], [3,0,0]] → [3,0,0] - * @param inputs Point and points collection to find the closest point in - * @returns Closest point - * @group extract - * @shortname closest pt - * @drawable true - */ - closestPointFromPoints( - inputs: Inputs.Point.ClosestPointFromPointsDto - ): Inputs.Base.Point3; - /** - * Calculates Euclidean distance between two points. - * Example: start=[0,0,0], end=[3,4,0] → 5 (using Pythagorean theorem: √(3²+4²)) - * @param inputs Coordinates of start and end points - * @returns Distance - * @group measure - * @shortname distance - * @drawable false - */ - distance(inputs: Inputs.Point.StartEndPointsDto): number; - /** - * Calculates distances from a start point to multiple end points. - * Example: start=[0,0,0], endPoints=[[3,0,0], [0,4,0], [5,0,0]] → [3, 4, 5] - * @param inputs Coordinates of start and end points - * @returns Distances - * @group measure - * @shortname distances to points - * @drawable false - */ - distancesToPoints(inputs: Inputs.Point.StartEndPointsListDto): number[]; - /** - * Duplicates a point N times (creates array with N copies of the same point). - * Example: point=[5,5,0], amountOfPoints=3 → [[5,5,0], [5,5,0], [5,5,0]] - * @param inputs The point to be multiplied and the amount of points to create - * @returns Distance - * @group transforms - * @shortname multiply point - * @drawable true - */ - multiplyPoint(inputs: Inputs.Point.MultiplyPointDto): Inputs.Base.Point3[]; - /** - * Extracts X coordinate from a point. - * Example: point=[5,10,3] → 5 - * @param inputs The point - * @returns X coordinate - * @group get - * @shortname x coord - * @drawable false - */ - getX(inputs: Inputs.Point.PointDto): number; - /** - * Extracts Y coordinate from a point. - * Example: point=[5,10,3] → 10 - * @param inputs The point - * @returns Y coordinate - * @group get - * @shortname y coord - * @drawable false - */ - getY(inputs: Inputs.Point.PointDto): number; - /** - * Extracts Z coordinate from a point. - * Example: point=[5,10,3] → 3 - * @param inputs The point - * @returns Z coordinate - * @group get - * @shortname z coord - * @drawable false - */ - getZ(inputs: Inputs.Point.PointDto): number; - /** - * Calculates centroid (average position) of multiple points. - * Example: points=[[0,0,0], [10,0,0], [10,10,0]] → [6.67,3.33,0] - * @param inputs The points - * @returns point - * @group extract - * @shortname average point - * @drawable true - */ - averagePoint(inputs: Inputs.Point.PointsDto): Inputs.Base.Point3; - /** - * Creates a 3D point from X, Y, Z coordinates. - * Example: x=10, y=5, z=3 → [10,5,3] - * @param inputs xyz information - * @returns point 3d - * @group create - * @shortname point xyz - * @drawable true - */ - pointXYZ(inputs: Inputs.Point.PointXYZDto): Inputs.Base.Point3; - /** - * Creates a 2D point from X, Y coordinates. - * Example: x=10, y=5 → [10,5] - * @param inputs xy information - * @returns point 3d - * @group create - * @shortname point xy - * @drawable false - */ - pointXY(inputs: Inputs.Point.PointXYDto): Inputs.Base.Point2; - /** - * Creates logarithmic spiral points using golden angle or custom widening factor. - * Generates natural spiral patterns common in nature (sunflower, nautilus shell). - * Example: numberPoints=100, radius=10, phi=1.618 → 100 points forming outward spiral - * @param inputs Spiral information - * @returns Specified number of points in the array along the spiral - * @group create - * @shortname spiral - * @drawable true - */ - spiral(inputs: Inputs.Point.SpiralDto): Inputs.Base.Point3[]; - /** - * Creates hexagonal grid center points on XY plane (honeycomb pattern). - * Grid size controlled by number of hexagons, not width/height. - * Example: radiusHexagon=1, nrHexagonsX=3, nrHexagonsY=3 → 9 hex centers in grid pattern - * @param inputs Information about hexagon and the grid - * @returns Points in the array on the grid - * @group create - * @shortname hex grid - * @drawable true - */ - hexGrid(inputs: Inputs.Point.HexGridCentersDto): Inputs.Base.Point3[]; - /** - * Creates hexagonal grid scaled to fit within specified width/height bounds (auto-calculates hex size). - * Returns center points and hex vertices. Supports pointy-top or flat-top orientation. - * Example: width=10, height=10, nrHexagonsInHeight=3 → hex grid filling 10×10 area with 3 rows - * @param inputs Information about the desired grid dimensions and hexagon counts. - * @returns An object containing the array of center points and an array of hexagon vertex arrays. - * @group create - * @shortname scaled hex grid to fit - * @drawable false - */ - hexGridScaledToFit( - inputs: Inputs.Point.HexGridScaledToFitDto - ): Models.Point.HexGridData; - /** - * Calculates the maximum possible fillet radius at a corner formed by two line segments - * sharing an endpoint (C), such that the fillet arc is tangent to both segments - * and lies entirely within them. - * @param inputs three points and the tolerance - * @returns the maximum fillet radius - * @group fillet - * @shortname max fillet radius - * @drawable false - */ - maxFilletRadius(inputs: Inputs.Point.ThreePointsToleranceDto): number; - /** - * Calculates the maximum possible fillet radius at a corner C, such that the fillet arc - * is tangent to both segments (P1-C, P2-C) and the tangent points lie within - * the first half of each segment (measured from C). - * @param inputs three points and the tolerance - * @returns the maximum fillet radius - * @group fillet - * @shortname max fillet radius half line - * @drawable false - */ - maxFilletRadiusHalfLine( - inputs: Inputs.Point.ThreePointsToleranceDto - ): number; - /** - * Calculates the maximum possible fillet radius at each corner of a polyline formed by - * formed by a series of points. The fillet radius is calculated for each internal - * corner and optionally for the closing corners if the polyline is closed. - * @param inputs Points, checkLastWithFirst flag, and tolerance - * @returns Array of maximum fillet radii for each corner - * @group fillet - * @shortname max fillets half line - * @drawable false - */ - maxFilletsHalfLine( - inputs: Inputs.Point.PointsMaxFilletsHalfLineDto - ): number[]; - /** - * Calculates the single safest maximum fillet radius that can be applied - * uniformly to all corners of collection of points, based on the 'half-line' constraint. - * This is determined by finding the minimum of the maximum possible fillet - * radii calculated for each individual corner. - * @param inputs Defines the points, whether it's closed, and an optional tolerance. - * @returns The smallest value from the results of pointsMaxFilletsHalfLine. - * Returns 0 if the polyline has fewer than 3 points or if any - * calculated maximum radius is 0. - * @group fillet - * @shortname safest fillet radii points - * @drawable false - */ - safestPointsMaxFilletHalfLine( - inputs: Inputs.Point.PointsMaxFilletsHalfLineDto - ): number; - /** - * Removes consecutive duplicate points from array within tolerance. - * Example: [[0,0,0], [0,0,0], [1,0,0], [1,0,0], [2,0,0]] → [[0,0,0], [1,0,0], [2,0,0]] - * @param inputs points, tolerance and check first and last - * @returns Points in the array without consecutive duplicates - * @group clean - * @shortname remove duplicates - * @drawable true - */ - removeConsecutiveDuplicates( - inputs: Inputs.Point.RemoveConsecutiveDuplicatesDto - ): Inputs.Base.Point3[]; - /** - * Calculates normal vector from three points using cross product (perpendicular to plane). - * Example: p1=[0,0,0], p2=[1,0,0], p3=[0,1,0] → [0,0,1] (pointing up from XY plane) - * @param inputs Three points and the reverse normal flag - * @returns Normal vector - * @group create - * @shortname normal from 3 points - * @drawable true - */ - normalFromThreePoints( - inputs: Inputs.Point.ThreePointsNormalDto - ): Inputs.Base.Vector3; - private closestPointFromPointData; - /** - * Checks if two points are approximately equal within tolerance (distance-based comparison). - * Example: point1=[1.0000001, 2.0, 3.0], point2=[1.0, 2.0, 3.0], tolerance=1e-6 → true - * @param inputs Two points and the tolerance - * @returns true if the points are almost equal - * @group measure - * @shortname two points almost equal - * @drawable false - */ - twoPointsAlmostEqual(inputs: Inputs.Point.TwoPointsToleranceDto): boolean; - /** - * Sorts points lexicographically (by X, then Y, then Z coordinates). - * Example: [[5,0,0], [1,0,0], [3,0,0]] → [[1,0,0], [3,0,0], [5,0,0]] - * @param inputs points - * @returns sorted points - * @group sort - * @shortname sort points - * @drawable true - */ - sortPoints(inputs: Inputs.Point.PointsDto): Inputs.Base.Point3[]; - /** - * Calculates the 6 vertices of a regular flat-top hexagon. - * @param center The center point [x, y, z]. - * @param radius The radius (distance from center to vertex). - * @returns An array of 6 Point3 vertices in counter-clockwise order. - */ - private getRegularHexagonVertices; - } - /** - * Contains various methods for polyline. Polyline in bitbybit is a simple object that has points property containing an array of points. - * { points: number[][] } - */ - declare class Polyline { - private readonly vector; - private readonly point; - private readonly line; - private readonly geometryHelper; - constructor( - vector: Vector, - point: Point, - line: Line, - geometryHelper: GeometryHelper - ); - /** - * Calculates total length of polyline by summing distances between consecutive points. - * Example: points=[[0,0,0], [3,0,0], [3,4,0]] → 3 + 4 = 7 - * @param inputs a polyline - * @returns length - * @group get - * @shortname polyline length - * @drawable false - */ - length(inputs: Inputs.Polyline.PolylineDto): number; - /** - * Counts number of points in polyline. - * Example: polyline with points=[[0,0,0], [1,0,0], [1,1,0]] → 3 - * @param inputs a polyline - * @returns nr of points - * @group get - * @shortname nr polyline points - * @drawable false - */ - countPoints(inputs: Inputs.Polyline.PolylineDto): number; - /** - * Extracts points array from polyline object. - * Example: polyline={points:[[0,0,0], [1,0,0]]} → [[0,0,0], [1,0,0]] - * @param inputs a polyline - * @returns points - * @group get - * @shortname points - * @drawable true - */ - getPoints(inputs: Inputs.Polyline.PolylineDto): Inputs.Base.Point3[]; - /** - * Reverses point order of polyline (flips direction). - * Example: points=[[0,0,0], [1,0,0], [2,0,0]] → [[2,0,0], [1,0,0], [0,0,0]] - * @param inputs a polyline - * @returns reversed polyline - * @group convert - * @shortname reverse polyline - * @drawable true - */ - reverse( - inputs: Inputs.Polyline.PolylineDto - ): Inputs.Polyline.PolylinePropertiesDto; - /** - * Applies transformation matrix to all points in polyline (rotates, scales, or translates). - * Example: polyline with 4 points, translation [5,0,0] → all points moved +5 in X direction - * @param inputs a polyline - * @returns transformed polyline - * @group transforms - * @shortname transform polyline - * @drawable true - */ - transformPolyline( - inputs: Inputs.Polyline.TransformPolylineDto - ): Inputs.Polyline.PolylinePropertiesDto; - /** - * Creates a polyline from points array with optional isClosed flag. - * Example: points=[[0,0,0], [1,0,0], [1,1,0]], isClosed=true → {points:..., isClosed:true} - * @param inputs points and info if its closed - * @returns polyline - * @group create - * @shortname polyline - * @drawable true - */ - create( - inputs: Inputs.Polyline.PolylineCreateDto - ): Inputs.Polyline.PolylinePropertiesDto; - /** - * Converts polyline to line segments (each segment as line object with start/end). - * Closed polylines include closing segment. - * Example: 3 points → 2 or 3 lines (depending on isClosed) - * @param inputs polyline - * @returns lines - * @group convert - * @shortname polyline to lines - * @drawable true - */ - polylineToLines(inputs: Inputs.Polyline.PolylineDto): Inputs.Base.Line3[]; - /** - * Converts polyline to segment arrays (each segment as [point1, point2]). - * Closed polylines include closing segment if endpoints differ. - * Example: 4 points, closed → 4 segments connecting all points in a loop - * @param inputs polyline - * @returns segments - * @group convert - * @shortname polyline to segments - * @drawable false - */ - polylineToSegments( - inputs: Inputs.Polyline.PolylineDto - ): Inputs.Base.Segment3[]; - /** - * Finds points where polyline crosses itself (self-intersection points). - * Skips adjacent segments and deduplicates close points. - * Example: figure-8 shaped polyline → returns center crossing point - * @param inputs points of self intersection - * @returns polyline - * @group intersections - * @shortname polyline self intersections - * @drawable true - */ - polylineSelfIntersection( - inputs: Inputs.Polyline.PolylineToleranceDto - ): Inputs.Base.Point3[]; - /** - * Finds intersection points between two polylines (all segment-segment crossings). - * Tests all segment pairs and deduplicates close points. - * Example: crossing polylines forming an X → returns center intersection point - * @param inputs two polylines and tolerance - * @returns points - * @group intersection - * @shortname two polyline intersection - * @drawable true - */ - twoPolylineIntersection( - inputs: Inputs.Polyline.TwoPolylinesToleranceDto - ): Inputs.Base.Point3[]; - /** - * Sorts scrambled segments into connected polylines by matching endpoints. - * Uses spatial hashing for efficient connection finding. - * Example: 10 random segments that form 2 connected paths → 2 polylines - * @param inputs segments - * @returns polylines - * @group sort - * @shortname segments to polylines - * @drawable true - */ - sortSegmentsIntoPolylines( - inputs: Inputs.Polyline.SegmentsToleranceDto - ): Inputs.Base.Polyline3[]; - /** - * Calculates the maximum possible half-line fillet radius for each corner - * of a given polyline. For a closed polyline, it includes the corners - * connecting the last segment back to the first. - * - * The calculation uses the 'half-line' constraint, meaning the fillet's - * tangent points must lie within the first half of each segment connected - * to the corner. - * - * @param inputs Defines the polyline points, whether it's closed, and an optional tolerance. - * @returns An array containing the maximum fillet radius calculated for each corner. - * The order corresponds to corners P[1]...P[n-2] for open polylines, - * and P[1]...P[n-2], P[0], P[n-1] for closed polylines. - * Returns an empty array if the polyline has fewer than 3 points. - * @group fillet - * @shortname polyline max fillet radii - * @drawable false - */ - maxFilletsHalfLine(inputs: Inputs.Polyline.PolylineToleranceDto): number[]; - /** - * Calculates the single safest maximum fillet radius that can be applied - * uniformly to all corners of a polyline, based on the 'half-line' constraint. - * This is determined by finding the minimum of the maximum possible fillet - * radii calculated for each individual corner. - * - * @param inputs Defines the polyline points, whether it's closed, and an optional tolerance. - * @returns The smallest value from the results of calculatePolylineMaxFillets. - * Returns 0 if the polyline has fewer than 3 points or if any - * calculated maximum radius is 0. - * @group fillet - * @shortname polyline safest fillet radius - * @drawable false - */ - safestFilletRadius(inputs: Inputs.Polyline.PolylineToleranceDto): number; - } - /** - * Contains various text methods. - */ - declare class TextBitByBit { - private readonly point; - constructor(point: Point); - /** - * Creates and returns a text string (pass-through for text input). - * Example: text='Hello World' → 'Hello World' - * @param inputs a text - * @returns text - * @group create - * @shortname text - * @drawable false - */ - create(inputs: Inputs.Text.TextDto): string; - /** - * Splits text into multiple pieces using a separator string. - * Example: text='apple,banana,cherry', separator=',' → ['apple', 'banana', 'cherry'] - * @param inputs a text - * @returns text - * @group transform - * @shortname split - * @drawable false - */ - split(inputs: Inputs.Text.TextSplitDto): string[]; - /** - * Replaces all occurrences of a search string with a replacement string. - * Example: text='hello hello', search='hello', replaceWith='hi' → 'hi hi' - * @param inputs a text - * @returns text - * @group transform - * @shortname replaceAll - * @drawable false - */ - replaceAll(inputs: Inputs.Text.TextReplaceDto): string; - /** - * Joins multiple items into a single text string using a separator. - * Example: list=['apple', 'banana', 'cherry'], separator=', ' → 'apple, banana, cherry' - * @param inputs a list of items - * @returns text - * @group transform - * @shortname join - * @drawable false - */ - join(inputs: Inputs.Text.TextJoinDto): string; - /** - * Transform any item to text - * @param inputs any item - * @returns text - * @group transform - * @shortname to string - * @drawable false - */ - toString(inputs: Inputs.Text.ToStringDto): string; - /** - * Transform each item in list to text - * @param inputs list of items - * @returns texts - * @group transform - * @shortname to strings - * @drawable false - */ - toStringEach(inputs: Inputs.Text.ToStringEachDto): string[]; - /** - * Formats text with placeholder values using {0}, {1}, etc. syntax. - * Example: text='Point: ({0}, {1})', values=[10, 5] → 'Point: (10, 5)' - * @param inputs a text and values - * @returns formatted text - * @group transform - * @shortname format - * @drawable false - */ - format(inputs: Inputs.Text.TextFormatDto): string; - /** - * Checks if text contains a search string. - * Example: text='hello world', search='world' → true - * @param inputs a text and search string - * @returns boolean - * @group query - * @shortname includes - * @drawable false - */ - includes(inputs: Inputs.Text.TextSearchDto): boolean; - /** - * Checks if text starts with a search string. - * Example: text='hello world', search='hello' → true - * @param inputs a text and search string - * @returns boolean - * @group query - * @shortname starts with - * @drawable false - */ - startsWith(inputs: Inputs.Text.TextSearchDto): boolean; - /** - * Checks if text ends with a search string. - * Example: text='hello world', search='world' → true - * @param inputs a text and search string - * @returns boolean - * @group query - * @shortname ends with - * @drawable false - */ - endsWith(inputs: Inputs.Text.TextSearchDto): boolean; - /** - * Returns the index of the first occurrence of a search string. - * Example: text='hello world', search='world' → 6 - * @param inputs a text and search string - * @returns index or -1 if not found - * @group query - * @shortname index of - * @drawable false - */ - indexOf(inputs: Inputs.Text.TextSearchDto): number; - /** - * Returns the index of the last occurrence of a search string. - * Example: text='hello world hello', search='hello' → 12 - * @param inputs a text and search string - * @returns index or -1 if not found - * @group query - * @shortname last index of - * @drawable false - */ - lastIndexOf(inputs: Inputs.Text.TextSearchDto): number; - /** - * Extracts a section of text between two indices. - * Example: text='hello world', start=0, end=5 → 'hello' - * @param inputs a text, start and end indices - * @returns extracted text - * @group transform - * @shortname substring - * @drawable false - */ - substring(inputs: Inputs.Text.TextSubstringDto): string; - /** - * Extracts a section of text and returns a new string. - * Example: text='hello world', start=0, end=5 → 'hello' - * @param inputs a text, start and end indices - * @returns extracted text - * @group transform - * @shortname slice - * @drawable false - */ - slice(inputs: Inputs.Text.TextSubstringDto): string; - /** - * Returns the character at the specified index. - * Example: text='hello', index=1 → 'e' - * @param inputs a text and index - * @returns character - * @group query - * @shortname char at - * @drawable false - */ - charAt(inputs: Inputs.Text.TextIndexDto): string; - /** - * Removes whitespace from both ends of text. - * Example: text=' hello ' → 'hello' - * @param inputs a text - * @returns trimmed text - * @group transform - * @shortname trim - * @drawable false - */ - trim(inputs: Inputs.Text.TextDto): string; - /** - * Removes whitespace from the start of text. - * Example: text=' hello ' → 'hello ' - * @param inputs a text - * @returns trimmed text - * @group transform - * @shortname trim start - * @drawable false - */ - trimStart(inputs: Inputs.Text.TextDto): string; - /** - * Removes whitespace from the end of text. - * Example: text=' hello ' → ' hello' - * @param inputs a text - * @returns trimmed text - * @group transform - * @shortname trim end - * @drawable false - */ - trimEnd(inputs: Inputs.Text.TextDto): string; - /** - * Pads text from the start to reach target length. - * Example: text='x', length=3, padString='a' → 'aax' - * @param inputs a text, target length and pad string - * @returns padded text - * @group transform - * @shortname pad start - * @drawable false - */ - padStart(inputs: Inputs.Text.TextPadDto): string; - /** - * Pads text from the end to reach target length. - * Example: text='x', length=3, padString='a' → 'xaa' - * @param inputs a text, target length and pad string - * @returns padded text - * @group transform - * @shortname pad end - * @drawable false - */ - padEnd(inputs: Inputs.Text.TextPadDto): string; - /** - * Converts text to uppercase. - * Example: text='hello' → 'HELLO' - * @param inputs a text - * @returns uppercase text - * @group transform - * @shortname to upper case - * @drawable false - */ - toUpperCase(inputs: Inputs.Text.TextDto): string; - /** - * Converts text to lowercase. - * Example: text='HELLO' → 'hello' - * @param inputs a text - * @returns lowercase text - * @group transform - * @shortname to lower case - * @drawable false - */ - toLowerCase(inputs: Inputs.Text.TextDto): string; - /** - * Capitalizes the first character of text. - * Example: text='hello world' → 'Hello world' - * @param inputs a text - * @returns text with first character uppercase - * @group transform - * @shortname capitalize first - * @drawable false - */ - toUpperCaseFirst(inputs: Inputs.Text.TextDto): string; - /** - * Lowercases the first character of text. - * Example: text='Hello World' → 'hello World' - * @param inputs a text - * @returns text with first character lowercase - * @group transform - * @shortname uncapitalize first - * @drawable false - */ - toLowerCaseFirst(inputs: Inputs.Text.TextDto): string; - /** - * Repeats text a specified number of times. - * Example: text='ha', count=3 → 'hahaha' - * @param inputs a text and count - * @returns repeated text - * @group transform - * @shortname repeat - * @drawable false - */ - repeat(inputs: Inputs.Text.TextRepeatDto): string; - /** - * Reverses the characters in text. - * Example: text='hello' → 'olleh' - * @param inputs a text - * @returns reversed text - * @group transform - * @shortname reverse - * @drawable false - */ - reverse(inputs: Inputs.Text.TextDto): string; - /** - * Returns the length of text. - * Example: text='hello' → 5 - * @param inputs a text - * @returns length - * @group query - * @shortname length - * @drawable false - */ - length(inputs: Inputs.Text.TextDto): number; - /** - * Checks if text is empty or only whitespace. - * Example: text=' ' → true - * @param inputs a text - * @returns boolean - * @group query - * @shortname is empty - * @drawable false - */ - isEmpty(inputs: Inputs.Text.TextDto): boolean; - /** - * Concatenates multiple text strings. - * Example: texts=['hello', ' ', 'world'] → 'hello world' - * @param inputs array of texts - * @returns concatenated text - * @group transform - * @shortname concat - * @drawable false - */ - concat(inputs: Inputs.Text.TextConcatDto): string; - /** - * Tests if text matches a regular expression pattern. - * Example: text='hello123', pattern='[0-9]+' → true - * @param inputs a text and regex pattern - * @returns boolean - * @group regex - * @shortname test regex - * @drawable false - */ - regexTest(inputs: Inputs.Text.TextRegexDto): boolean; - /** - * Matches text against a regular expression and returns matches. - * Example: text='hello123world456', pattern='[0-9]+', flags='g' → ['123', '456'] - * @param inputs a text and regex pattern - * @returns array of matches or null - * @group regex - * @shortname regex match - * @drawable false - */ - regexMatch(inputs: Inputs.Text.TextRegexDto): string[] | null; - /** - * Replaces text matching a regular expression pattern. - * Example: text='hello123world456', pattern='[0-9]+', flags='g', replaceWith='X' → 'helloXworldX' - * @param inputs a text, regex pattern, and replacement - * @returns text with replacements - * @group regex - * @shortname regex replace - * @drawable false - */ - regexReplace(inputs: Inputs.Text.TextRegexReplaceDto): string; - /** - * Searches text for a regular expression pattern and returns the index. - * Example: text='hello123', pattern='[0-9]+' → 5 - * @param inputs a text and regex pattern - * @returns index or -1 if not found - * @group regex - * @shortname regex search - * @drawable false - */ - regexSearch(inputs: Inputs.Text.TextRegexDto): number; - /** - * Splits text using a regular expression pattern. - * Example: text='a1b2c3', pattern='[0-9]+' → ['a', 'b', 'c'] - * @param inputs a text and regex pattern - * @returns array of split strings - * @group regex - * @shortname regex split - * @drawable false - */ - regexSplit(inputs: Inputs.Text.TextRegexDto): string[]; - /** - * Converts a character to vector paths (polylines) with width and height data for rendering. - * Uses simplex stroke font to generate 2D line segments representing the character shape. - * Example: char='A', height=10 → {width:8, height:10, paths:[[points forming A shape]]} - * @param inputs a text - * @returns width, height and segments as json - * @group vector - * @shortname vector char - * @drawable false - */ - vectorChar(inputs: Inputs.Text.VectorCharDto): Models.Text.VectorCharData; - /** - * Converts multi-line text to vector paths (polylines) with alignment and spacing controls. - * Supports line breaks, letter spacing, line spacing, horizontal alignment, and origin centering. - * Example: text='Hello - World', height=10, align=center → [{line1 chars}, {line2 chars}] - * @param inputs a text as string - * @returns segments - * @group vector - * @shortname vector text - * @drawable false - */ - vectorText(inputs: Inputs.Text.VectorTextDto): Models.Text.VectorTextData[]; - private vectorParamsChar; - private translateLine; - } - /** - * Transformations help to move, scale, rotate objects. You can combine multiple transformations - * for object to be placed exactly into position and orientation that you want. - * Contains various methods for transformations that represent 4x4 matrixes in flat 16 number arrays. - */ - declare class Transforms { - private readonly vector; - private readonly math; - constructor(vector: Vector, math: MathBitByBit); - /** - * Creates rotation transformations around a center point and custom axis. - * Combines translation to origin, axis rotation, then translation back. - * Example: center=[5,0,0], axis=[0,1,0], angle=90° → rotates around vertical axis through point [5,0,0] - * @param inputs Rotation around center with an axis information - * @returns array of transformations - * @group rotation - * @shortname center axis - * @drawable false - */ - rotationCenterAxis( - inputs: Inputs.Transforms.RotationCenterAxisDto - ): Base.TransformMatrixes; - /** - * Creates rotation transformations around a center point along the X axis. - * Example: center=[5,5,5], angle=90° → rotates 90° around X axis through point [5,5,5] - * @param inputs Rotation around center with an X axis information - * @returns array of transformations - * @group rotation - * @shortname center x - * @drawable false - */ - rotationCenterX( - inputs: Inputs.Transforms.RotationCenterDto - ): Base.TransformMatrixes; - /** - * Creates rotation transformations around a center point along the Y axis. - * Example: center=[0,0,0], angle=45° → rotates 45° around Y axis through origin - * @param inputs Rotation around center with an Y axis information - * @returns array of transformations - * @group rotation - * @shortname center y - * @drawable false - */ - rotationCenterY( - inputs: Inputs.Transforms.RotationCenterDto - ): Base.TransformMatrixes; - /** - * Creates rotation transformations around a center point along the Z axis. - * Example: center=[10,10,0], angle=180° → rotates 180° around Z axis through point [10,10,0] - * @param inputs Rotation around center with an Z axis information - * @returns array of transformations - * @group rotation - * @shortname center z - * @drawable false - */ - rotationCenterZ( - inputs: Inputs.Transforms.RotationCenterDto - ): Base.TransformMatrixes; - /** - * Creates rotation transformations using yaw-pitch-roll (Euler angles) around a center point. - * Yaw → Y axis rotation, Pitch → X axis rotation, Roll → Z axis rotation. - * Example: center=[0,0,0], yaw=90°, pitch=0°, roll=0° → rotates 90° around Y axis - * @param inputs Yaw pitch roll rotation information - * @returns array of transformations - * @group rotation - * @shortname yaw pitch roll - * @drawable false - */ - rotationCenterYawPitchRoll( - inputs: Inputs.Transforms.RotationCenterYawPitchRollDto - ): Base.TransformMatrixes; - /** - * Creates non-uniform scale transformation around a center point (different scale per axis). - * Example: center=[5,5,5], scaleXyz=[2,1,0.5] → doubles X, keeps Y, halves Z around point [5,5,5] - * @param inputs Scale center xyz trnansformation - * @returns array of transformations - * @group scale - * @shortname center xyz - * @drawable false - */ - scaleCenterXYZ( - inputs: Inputs.Transforms.ScaleCenterXYZDto - ): Base.TransformMatrixes; - /** - * Creates non-uniform scale transformation from origin (different scale per axis). - * Example: scaleXyz=[2,3,1] → doubles X, triples Y, keeps Z unchanged - * @param inputs Scale XYZ number array information - * @returns transformation - * @group scale - * @shortname xyz - * @drawable false - */ - scaleXYZ(inputs: Inputs.Transforms.ScaleXYZDto): Base.TransformMatrixes; - /** - * Creates directional stretch transformation that scales along a specific direction from a center point. - * Points move only along the direction vector; perpendicular plane remains unchanged. - * Example: center=[0,0,0], direction=[1,0,0], scale=2 → stretches 2× along X axis only - * @param inputs Defines the center, direction, and scale factor for the stretch. - * @returns Array of transformations: [Translate To Origin, Stretch, Translate Back]. - * @group scale - * @shortname stretch dir center - * @drawable false - */ - stretchDirFromCenter( - inputs: Inputs.Transforms.StretchDirCenterDto - ): Base.TransformMatrixes; - /** - * Creates uniform scale transformation from origin (same scale on all axes). - * Example: scale=2 → doubles size in all directions (X, Y, Z) - * @param inputs Scale Dto - * @returns transformation - * @group scale - * @shortname uniform - * @drawable false - */ - uniformScale( - inputs: Inputs.Transforms.UniformScaleDto - ): Base.TransformMatrixes; - /** - * Creates uniform scale transformation around a center point (same scale on all axes). - * Example: center=[5,5,5], scale=0.5 → halves size in all directions around point [5,5,5] - * @param inputs Scale Dto with center point information - * @returns array of transformations - * @group scale - * @shortname uniform from center - * @drawable false - */ - uniformScaleFromCenter( - inputs: Inputs.Transforms.UniformScaleFromCenterDto - ): Base.TransformMatrixes; - /** - * Creates translation transformation (moves objects in space). - * Example: translation=[10,5,0] → moves object 10 units in X, 5 in Y, 0 in Z - * @param inputs Translation information - * @returns transformation - * @group translation - * @shortname xyz - * @drawable false - */ - translationXYZ( - inputs: Inputs.Transforms.TranslationXYZDto - ): Base.TransformMatrixes; - /** - * Creates multiple translation transformations (batch move operations). - * Example: translations=[[1,0,0], [0,2,0]] → generates two transforms: move +X, move +Y - * @param inputs Translation information - * @returns transformation - * @group translations - * @shortname xyz - * @drawable false - */ - translationsXYZ( - inputs: Inputs.Transforms.TranslationsXYZDto - ): Base.TransformMatrixes[]; - /** - * Creates identity transformation matrix (no transformation - leaves objects unchanged). - * Returns 4×4 matrix: [1,0,0,0, 0,1,0,0, 0,0,1,0, 0,0,0,1] - * @returns transformation - * @group identity - * @shortname identity - * @drawable false - */ - identity(): Base.TransformMatrix; - private translation; - private scaling; - private rotationAxis; - private rotationX; - private rotationY; - private rotationZ; - private rotationYawPitchRoll; - private rotationMatrixFromQuat; - /** - * Creates a 4x4 matrix that scales along a given direction vector. - * @param direction The direction vector (will be normalized). - * @param scale The scale factor along the direction. - * @returns A 4x4 column-major transformation matrix. - */ - private stretchDirection; - } - /** - * Contains various methods for vector mathematics. Vector in bitbybit is simply an array, usually containing numbers. - * In 3D [x, y, z] form describes space, where y is the up vector. - * Because of this form Vector can be interchanged with Point, which also is an array in [x, y, z] form. - */ - declare class Vector { - private readonly math; - private readonly geometryHelper; - constructor(math: MathBitByBit, geometryHelper: GeometryHelper); - /** - * Removes all duplicate vectors from the input array (keeps only unique vectors). - * Example: [[1,2,3], [4,5,6], [1,2,3], [7,8,9]] → [[1,2,3], [4,5,6], [7,8,9]] - * @param inputs Contains vectors and a tolerance value - * @returns Array of vectors without duplicates - * @group remove - * @shortname remove all duplicates - * @drawable false - */ - removeAllDuplicateVectors( - inputs: Inputs.Vector.RemoveAllDuplicateVectorsDto - ): number[][]; - /** - * Removes consecutive duplicate vectors from the input array (only removes duplicates that appear next to each other). - * Example: [[1,2], [1,2], [3,4], [1,2]] → [[1,2], [3,4], [1,2]] (only removed consecutive duplicate) - * @param inputs Contains vectors and a tolerance value - * @returns Array of vectors without duplicates - * @group remove - * @shortname remove consecutive duplicates - * @drawable false - */ - removeConsecutiveDuplicateVectors( - inputs: Inputs.Vector.RemoveConsecutiveDuplicateVectorsDto - ): number[][]; - /** - * Checks if two vectors are the same within a given tolerance (accounts for floating point precision). - * Example: [1,2,3] vs [1.0001,2.0001,3.0001] with tolerance 0.001 → true - * @param inputs Contains two vectors and a tolerance value - * @returns Boolean indicating if vectors are the same - * @group validate - * @shortname vectors the same - * @drawable false - */ - vectorsTheSame(inputs: Inputs.Vector.VectorsTheSameDto): boolean; - /** - * Measures the angle between two vectors in degrees (always returns positive angle 0-180°). - * Example: [1,0,0] and [0,1,0] → 90° (perpendicular vectors) - * @param inputs Contains two vectors represented as number arrays - * @group angles - * @shortname angle - * @returns Number in degrees - * @drawable false - */ - angleBetween(inputs: Inputs.Vector.TwoVectorsDto): number; - /** - * Measures the normalized 2D angle between two vectors in degrees (considers direction, can be negative). - * Example: [1,0] to [0,1] → 90°, [0,1] to [1,0] → -90° - * @param inputs Contains two vectors represented as number arrays - * @returns Number in degrees - * @group angles - * @shortname angle normalized 2d - * @drawable false - */ - angleBetweenNormalized2d(inputs: Inputs.Vector.TwoVectorsDto): number; - /** - * Measures a positive angle between two vectors given the reference vector in degrees (always 0-360°). - * Example: converts negative signed angles to positive by adding 360° when needed - * @param inputs Contains information of two vectors and a reference vector - * @returns Number in degrees - * @group angles - * @shortname positive angle - * @drawable false - */ - positiveAngleBetween(inputs: Inputs.Vector.TwoVectorsReferenceDto): number; - /** - * Adds all vector xyz values together element-wise and creates a new vector. - * Example: [[1,2,3], [4,5,6], [7,8,9]] → [12,15,18] (sums each column) - * @param inputs Vectors to be added - * @returns New vector that has xyz values as sums of all the vectors - * @group sum - * @shortname add all - * @drawable false - */ - addAll(inputs: Inputs.Vector.VectorsDto): number[]; - /** - * Adds two vectors together element-wise. - * Example: [1,2,3] + [4,5,6] → [5,7,9] - * @param inputs Two vectors to be added - * @returns Number array representing vector - * @group sum - * @shortname add - * @drawable false - */ - add(inputs: Inputs.Vector.TwoVectorsDto): number[]; - /** - * Checks if the boolean array contains only true values, returns false if there's a single false. - * Example: [true, true, true] → true, [true, false, true] → false - * @param inputs Vectors to be checked - * @returns Boolean indicating if vector contains only true values - * @group sum - * @shortname all - * @drawable false - */ - all(inputs: Inputs.Vector.VectorBoolDto): boolean; - /** - * Computes the cross product of two 3D vectors (perpendicular vector to both inputs). - * Example: [1,0,0] × [0,1,0] → [0,0,1] (right-hand rule) - * @param inputs Two vectors to be crossed - * @group base - * @shortname cross - * @returns Crossed vector - * @drawable false - */ - cross(inputs: Inputs.Vector.TwoVectorsDto): number[]; - /** - * Calculates squared distance between two vectors (faster than distance, avoids sqrt). - * Example: [0,0,0] to [3,4,0] → 25 (distance 5 squared) - * @param inputs Two vectors - * @returns Number representing squared distance between two vectors - * @group distance - * @shortname dist squared - * @drawable false - */ - distSquared(inputs: Inputs.Vector.TwoVectorsDto): number; - /** - * Calculates the Euclidean distance between two vectors. - * Example: [0,0,0] to [3,4,0] → 5, [1,1] to [4,5] → 5 - * @param inputs Two vectors - * @returns Number representing distance between two vectors - * @group distance - * @shortname dist - * @drawable false - */ - dist(inputs: Inputs.Vector.TwoVectorsDto): number; - /** - * Divides each element of the vector by a scalar value. - * Example: [10,20,30] ÷ 2 → [5,10,15] - * @param inputs Contains vector and a scalar - * @returns Vector that is a result of division by a scalar - * @group base - * @shortname div - * @drawable false - */ - div(inputs: Inputs.Vector.VectorScalarDto): number[]; - /** - * Computes the domain (range) between minimum and maximum values of the vector. - * Example: [1,3,5,9] → 8 (difference between last and first: 9-1) - * @param inputs Vector information - * @returns Number representing distance between two vectors - * @group base - * @shortname domain - * @drawable false - */ - domain(inputs: Inputs.Vector.VectorDto): number; - /** - * Calculates the dot product between two vectors (measures similarity/projection). - * Example: [1,2,3] • [4,5,6] → 32 (1×4 + 2×5 + 3×6), perpendicular vectors → 0 - * @param inputs Two vectors - * @returns Number representing dot product of the vector - * @group base - * @shortname dot - * @drawable false - */ - dot(inputs: Inputs.Vector.TwoVectorsDto): number; - /** - * Checks if each element in the vector is finite and returns a boolean array. - * Example: [1, 2, Infinity, 3] → [true, true, false, true] - * @param inputs Vector with possibly infinite values - * @returns Vector array that contains boolean values for each number in the input - * vector that identifies if value is finite (true) or infinite (false) - * @group validate - * @shortname finite - * @drawable false - */ - finite(inputs: Inputs.Vector.VectorDto): boolean[]; - /** - * Checks if the vector has zero length (all elements are zero). - * Example: [0,0,0] → true, [0,0,0.001] → false - * @param inputs Vector to be checked - * @returns Boolean that identifies if vector is zero length - * @group validate - * @shortname isZero - * @drawable false - */ - isZero(inputs: Inputs.Vector.VectorDto): boolean; - /** - * Finds an interpolated vector between two vectors using a fraction (linear interpolation). - * Example: [0,0,0] to [10,10,10] at 0.5 → [5,5,5], fraction=0 → first, fraction=1 → second - * @param inputs Information for finding vector between two vectors using a fraction - * @returns Vector that is in between two vectors - * @group distance - * @shortname lerp - * @drawable false - */ - lerp(inputs: Inputs.Vector.FractionTwoVectorsDto): number[]; - /** - * Finds the maximum (largest) value in the vector. - * Example: [3, 7, 2, 9, 1] → 9 - * @param inputs Vector to be checked - * @returns Largest number in the vector - * @group extract - * @shortname max - * @drawable false - */ - max(inputs: Inputs.Vector.VectorDto): number; - /** - * Finds the minimum (smallest) value in the vector. - * Example: [3, 7, 2, 9, 1] → 1 - * @param inputs Vector to be checked - * @returns Lowest number in the vector - * @group extract - * @shortname min - * @drawable false - */ - min(inputs: Inputs.Vector.VectorDto): number; - /** - * Multiplies each element of the vector by a scalar value. - * Example: [2,3,4] × 5 → [10,15,20] - * @param inputs Vector with a scalar - * @returns Vector that results from multiplication - * @group base - * @shortname mul - * @drawable false - */ - mul(inputs: Inputs.Vector.VectorScalarDto): number[]; - /** - * Negates the vector (flips the sign of each element). - * Example: [5,-3,2] → [-5,3,-2] - * @param inputs Vector to negate - * @returns Negative vector - * @group base - * @shortname neg - * @drawable false - */ - neg(inputs: Inputs.Vector.VectorDto): number[]; - /** - * Computes the squared norm (squared magnitude/length) of the vector. - * Example: [3,4,0] → 25 (length 5 squared) - * @param inputs Vector for squared norm - * @returns Number that is squared norm - * @group base - * @shortname norm squared - * @drawable false - */ - normSquared(inputs: Inputs.Vector.VectorDto): number; - /** - * Calculates the norm (magnitude/length) of the vector. - * Example: [3,4,0] → 5, [1,0,0] → 1 - * @param inputs Vector to compute the norm - * @returns Number that is norm of the vector - * @group base - * @shortname norm - * @drawable false - */ - norm(inputs: Inputs.Vector.VectorDto): number; - /** - * Normalizes the vector into a unit vector that has a length of 1 (maintains direction, scales magnitude to 1). - * Example: [3,4,0] → [0.6,0.8,0], [10,0,0] → [1,0,0] - * @param inputs Vector to normalize - * @returns Unit vector that has length of 1 - * @group base - * @shortname normalized - * @drawable false - */ - normalized(inputs: Inputs.Vector.VectorDto): number[]; - /** - * Finds a point on a ray at a given distance from the origin along the direction vector. - * Example: Point [0,0,0] + direction [1,0,0] at distance 5 → [5,0,0] - * @param inputs Provide a point, vector and a distance for finding a point - * @returns Vector representing point on the ray - * @group base - * @shortname on ray - * @drawable false - */ - onRay(inputs: Inputs.Vector.RayPointDto): number[]; - /** - * Creates a 3D vector from x, y, z coordinates. - * Example: x=1, y=2, z=3 → [1,2,3] - * @param inputs Vector coordinates - * @returns Create a vector of xyz values - * @group create - * @shortname vector XYZ - * @drawable true - */ - vectorXYZ(inputs: Inputs.Vector.VectorXYZDto): Inputs.Base.Vector3; - /** - * Creates a 2D vector from x, y coordinates. - * Example: x=3, y=4 → [3,4] - * @param inputs Vector coordinates - * @returns Create a vector of xy values - * @group create - * @shortname vector XY - * @drawable true - */ - vectorXY(inputs: Inputs.Vector.VectorXYDto): Inputs.Base.Vector2; - /** - * Creates a vector of integers from 0 to max (exclusive). - * Example: max=5 → [0,1,2,3,4], max=3 → [0,1,2] - * @param inputs Max value for the range - * @returns Vector containing items from 0 to max - * @group create - * @shortname range - * @drawable false - */ - range(inputs: Inputs.Vector.RangeMaxDto): number[]; - /** - * Computes signed angle between two vectors using a reference vector (determines rotation direction). - * Example: Returns positive or negative angle depending on rotation direction relative to reference - * @param inputs Contains information of two vectors and a reference vector - * @returns Signed angle in degrees - * @group angles - * @shortname signed angle - * @drawable false - */ - signedAngleBetween(inputs: Inputs.Vector.TwoVectorsReferenceDto): number; - /** - * Creates a vector containing numbers from min to max at a given step increment. - * Example: min=0, max=10, step=2 → [0,2,4,6,8,10] - * @param inputs Span information containing min, max and step values - * @returns Vector containing number between min, max and increasing at a given step - * @group create - * @shortname span - * @drawable false - */ - span(inputs: Inputs.Vector.SpanDto): number[]; - /** - * Creates a vector with numbers from min to max using an easing function for non-linear distribution. - * Example: min=0, max=100, nrItems=5, ease='easeInQuad' → creates accelerating intervals - * @param inputs Span information containing min, max and ease function - * @returns Vector containing numbers between min, max and increasing in non-linear steps defined by nr of items in the vector and type - * @group create - * @shortname span ease items - * @drawable false - */ - spanEaseItems(inputs: Inputs.Vector.SpanEaseItemsDto): number[]; - /** - * Creates a vector with evenly spaced numbers from min to max with a specified number of items. - * Example: min=0, max=10, nrItems=5 → [0, 2.5, 5, 7.5, 10] - * @param inputs Span information containing min, max and step values - * @returns Vector containing number between min, max by giving nr of items - * @group create - * @shortname span linear items - * @drawable false - */ - spanLinearItems(inputs: Inputs.Vector.SpanLinearItemsDto): number[]; - /** - * Subtracts the second vector from the first element-wise. - * Example: [10,20,30] - [1,2,3] → [9,18,27] - * @param inputs Two vectors - * @returns Vector that result by subtraction two vectors - * @group base - * @shortname sub - * @drawable false - */ - sub(inputs: Inputs.Vector.TwoVectorsDto): number[]; - /** - * Sums all values in the vector and returns a single number. - * Example: [1,2,3,4] → 10, [5,10,15] → 30 - * @param inputs Vector to sum - * @returns Number that results by adding up all values in the vector - * @group base - * @shortname sum - * @drawable false - */ - sum(inputs: Inputs.Vector.VectorDto): number; - /** - * Computes the squared length (squared magnitude) of a 3D vector. - * Example: [3,4,0] → 25 (length 5 squared) - * @param inputs Vector to compute the length - * @returns Number that is squared length of the vector - * @group base - * @shortname length squared - * @drawable false - */ - lengthSq(inputs: Inputs.Vector.Vector3Dto): number; - /** - * Computes the length (magnitude) of a 3D vector. - * Example: [3,4,0] → 5, [1,0,0] → 1 - * @param inputs Vector to compute the length - * @returns Number that is length of the vector - * @group base - * @shortname length - * @drawable false - */ - length(inputs: Inputs.Vector.Vector3Dto): number; - /** - * Converts an array of stringified numbers to actual numbers. - * Example: ['1', '2.5', '3'] → [1, 2.5, 3], ['10', '-5', '0.1'] → [10, -5, 0.1] - * @param inputs Array of stringified numbers - * @returns Array of numbers - * @group create - * @shortname parse numbers - * @drawable false - */ - parseNumbers(inputs: Inputs.Vector.VectorStringDto): number[]; - } - declare class Asset { - assetManager: AssetManager; - constructor(); - /** - * Gets the asset file - * @param inputs file name to get from project assets - * @returns Blob of asset - * @group get - * @shortname cloud file - */ - getFile(inputs: Inputs.Asset.GetAssetDto): Promise; - /** - * Gets the text from asset file stored in your cloud account. - * @param inputs asset name to get from project assets - * @returns Text of asset - * @group get - * @shortname text file - */ - getTextFile(inputs: Inputs.Asset.GetAssetDto): Promise; - /** - * Gets the local asset file stored in your browser. - * @param inputs asset name to get from local assets - * @returns Blob of asset - * @group get - * @shortname local file - */ - getLocalFile(inputs: Inputs.Asset.GetAssetDto): Promise; - /** - * Gets the text from asset file stored in your browser. - * @param inputs asset name to get from local assets - * @returns Text of asset or array of texts - * @group get - * @shortname local text file - */ - getLocalTextFile( - inputs: Inputs.Asset.GetAssetDto - ): Promise; - /** - * Fetches the blob from the given url, must be CORS enabled accessible endpoint - * @param inputs url of the asset - * @returns Blob - * @group fetch - * @shortname fetch blob - */ - fetchBlob(inputs: Inputs.Asset.FetchDto): Promise; - /** - * Fetches the file from the given url, must be CORS enabled accessible endpoint - * @param inputs url of the asset - * @returns File - * @group fetch - * @shortname fetch file - */ - fetchFile(inputs: Inputs.Asset.FetchDto): Promise; - /** - * Fetches the json from the given url, must be CORS enabled accessible endpoint - * @param inputs url of the asset - * @returns JSON - * @group fetch - * @shortname fetch json - */ - fetchJSON(inputs: Inputs.Asset.FetchDto): Promise; - /** - * Fetches the json from the given url, must be CORS enabled accessible endpoint - * @param inputs url of the asset - * @returns Text - * @group fetch - * @shortname fetch text - */ - fetchText(inputs: Inputs.Asset.FetchDto): Promise; - /** - * Gets and creates the url string path to your file stored in your memory. - * @param File or a blob - * @returns URL string of a file - * @group create - * @shortname object url - */ - createObjectURL(inputs: Inputs.Asset.FileDto): string; - /** - * Gets and creates the url string paths to your files stored in your memory. - * @param Files or a blobs - * @returns URL strings for given files - * @group create - * @shortname object urls - */ - createObjectURLs(inputs: Inputs.Asset.FilesDto): string[]; - /** - * Downloads a file with the given content, extension, and content type. - * @param inputs file name, content, extension, and content type - * @group download - * @shortname download file - */ - download(inputs: Inputs.Asset.DownloadDto): void; - } - declare namespace BaseTypes { - /** - * Interval represents an object that has two properties - min and max. - */ - class IntervalDto { - /** - * Minimum value of the interval - */ - min: number; - /** - * Maximum value of the interval - */ - max: number; - } - /** - * UV usually represents 2D coordinates on 3D or 2D surfaces. It is similar to XY coordinates in planes. - */ - class UVDto { - /** - * U coordinate of the surface - */ - u: number; - /** - * V coordinate of the surface - */ - v: number; - } - /** - * Intersection result of curve curve - */ - class CurveCurveIntersection { - /** - * Point of intersection on the first curve - */ - point0: number[]; - /** - * Point of intersection on the second curve - */ - point1: number[]; - /** - * Parameter of intersection on the first curve - */ - u0: number; - /** - * Parameter of intersection on the second curve - */ - u1: number; - } - /** - * Intersection result of curve and surface - */ - class CurveSurfaceIntersection { - /** - * Parameter of intersection on the curve - */ - u: number; - /** - * UV Parameters of intersection on the surface - */ - uv: UVDto; - /** - * Point of intersection on the curve - */ - curvePoint: number[]; - /** - * Point of intersection on the surface - */ - surfacePoint: number[]; - } - /** - * Intersection point between two surfaces - */ - class SurfaceSurfaceIntersectionPoint { - /** - * UV parameters of intersection on first surface - */ - uv0: UVDto; - /** - * UV parameters of intersection on second surface - */ - uv1: UVDto; - /** - * Point of intersection - */ - point: number[]; - /** - * Distance - */ - dist: number; - } - } - /** - * Contains various CSV parsing and generation methods. - */ - declare class CSVBitByBit { - /** - * Parses CSV text to a 2D array of strings (rows and columns). - * Example: csv='a,b,c - 1,2,3' → [['a','b','c'], ['1','2','3']] - * @param inputs CSV text and parsing options - * @returns 2D array of strings - * @group parse - * @shortname parse to array - * @drawable false - */ - parseToArray(inputs: Inputs.CSV.ParseToArrayDto): string[][]; - /** - * Parses CSV text to an array of JSON objects using headers. - * Example: csv='name,age - John,30 - Jane,25', headerRow=0, dataStartRow=1 - * → [{'name':'John','age':'30'}, {'name':'Jane','age':'25'}] - * @param inputs CSV text and parsing options - * @returns Array of JSON objects - * @group parse - * @shortname parse to json - * @drawable false - */ - parseToJson>( - inputs: Inputs.CSV.ParseToJsonDto - ): T[]; - /** - * Parses CSV text to JSON using custom headers (ignores CSV headers if present). - * Example: csv='John,30 - Jane,25', headers=['name','age'] - * → [{'name':'John','age':'30'}, {'name':'Jane','age':'25'}] - * @param inputs CSV text, custom headers, and parsing options - * @returns Array of JSON objects - * @group parse - * @shortname parse to json with headers - * @drawable false - */ - parseToJsonWithHeaders>( - inputs: Inputs.CSV.ParseToJsonWithHeadersDto - ): T[]; - /** - * Queries CSV data by column/header name and returns all values in that column. - * Example: csv='name,age - John,30 - Jane,25', column='name' → ['John', 'Jane'] - * @param inputs CSV text, column name, and parsing options - * @returns Array of values from the specified column - * @group query - * @shortname query column - * @drawable false - */ - queryColumn>( - inputs: Inputs.CSV.QueryColumnDto - ): (string | number)[]; - /** - * Queries CSV data and filters rows where a column matches a value. - * Example: csv='name,age - John,30 - Jane,25', column='age', value='30' → [{'name':'John','age':'30'}] - * @param inputs CSV text, column name, value, and parsing options - * @returns Array of matching rows as JSON objects - * @group query - * @shortname query rows by value - * @drawable false - */ - queryRowsByValue>( - inputs: Inputs.CSV.QueryRowsByValueDto - ): T[]; - /** - * Converts a 2D array to CSV text. - * Example: array=[['name','age'], ['John','30']] → 'name,age - John,30' - * @param inputs 2D array and formatting options - * @returns CSV text - * @group generate - * @shortname array to csv - * @drawable false - */ - arrayToCsv(inputs: Inputs.CSV.ArrayToCsvDto): string; - /** - * Converts an array of JSON objects to CSV text. - * Example: json=[{'name':'John','age':'30'}], headers=['name','age'] → 'name,age - John,30' - * @param inputs JSON array, headers, and formatting options - * @returns CSV text - * @group generate - * @shortname json to csv - * @drawable false - */ - jsonToCsv>( - inputs: Inputs.CSV.JsonToCsvDto - ): string; - /** - * Converts an array of JSON objects to CSV text using object keys as headers. - * Example: json=[{'name':'John','age':'30'}] → 'name,age - John,30' - * @param inputs JSON array and formatting options - * @returns CSV text - * @group generate - * @shortname json to csv auto - * @drawable false - */ - jsonToCsvAuto>( - inputs: Inputs.CSV.JsonToCsvAutoDto - ): string; - /** - * Gets the headers from a CSV file. - * Example: csv='name,age - John,30', headerRow=0 → ['name', 'age'] - * @param inputs CSV text and options - * @returns Array of header names - * @group query - * @shortname get headers - * @drawable false - */ - getHeaders(inputs: Inputs.CSV.GetHeadersDto): string[]; - /** - * Gets the number of rows in a CSV file (excluding headers if specified). - * Example: csv='name,age - John,30 - Jane,25', headerRow=0 → 2 - * @param inputs CSV text and options - * @returns Number of data rows - * @group query - * @shortname row count - * @drawable false - */ - getRowCount(inputs: Inputs.CSV.GetRowCountDto): number; - /** - * Gets the number of columns in a CSV file. - * Example: csv='name,age,city - John,30,NYC' → 3 - * @param inputs CSV text and options - * @returns Number of columns - * @group query - * @shortname column count - * @drawable false - */ - getColumnCount(inputs: Inputs.CSV.ParseToArrayDto): number; - private parseCsvLine; - private escapeCsvCell; - /** - * Converts literal escape sequence strings to their actual characters. - * For example, converts "\n" (two characters) to " - " (newline character). - */ - private convertEscapeSequences; - } - /** - * Contains various json path methods. - */ - declare class JSONBitByBit { - private readonly context; - constructor(context: ContextBase); - /** - * Stringifies the input value - * @param inputs a value to be stringified - * @returns string - * @group transform - * @shortname stringify - * @drawable false - */ - stringify(inputs: Inputs.JSON.StringifyDto): string; - /** - * Parses the input value - * @param inputs a value to be parsed - * @returns any - * @group transform - * @shortname parse - * @drawable false - */ - parse(inputs: Inputs.JSON.ParseDto): any; - /** - * Queries the input value - * @param inputs a value to be queried - * @returns any - * @group jsonpath - * @shortname query - * @drawable false - */ - query(inputs: Inputs.JSON.QueryDto): any; - /** - * Sets value on given property of the given json - * @param inputs a value to be added, json and a property name - * @returns any - * @group props - * @shortname set value on property - * @drawable false - */ - setValueOnProp(inputs: Inputs.JSON.SetValueOnPropDto): any; - /** - * Gets json from array by first property match. This is very simplistic search and only returns the first match. - * If you need more complex search, you can use jsonpath query with filters. - * @param inputs an array of json objects, a property name and a value to match - * @returns any - * @group props - * @shortname get json from array by prop match - * @drawable false - */ - getJsonFromArrayByFirstPropMatch( - inputs: Inputs.JSON.GetJsonFromArrayByFirstPropMatchDto - ): any; - /** - * Gets value of the property in the given json - * @param inputs a value to be added, json and a property name - * @returns any - * @group props - * @shortname get value on property - * @drawable false - */ - getValueOnProp(inputs: Inputs.JSON.GetValueOnPropDto): any; - /** - * Sets value to the json by providing a path - * @param inputs a value to be added, json and a path - * @returns any - * @group jsonpath - * @shortname set value on path - * @drawable false - */ - setValue(inputs: Inputs.JSON.SetValueDto): any; - /** - * Sets multiple values to the json by providing paths - * @param inputs a value to be added, json and a path - * @returns any - * @group jsonpath - * @shortname set values on paths - * @drawable false - */ - setValuesOnPaths(inputs: Inputs.JSON.SetValuesOnPathsDto): any; - /** - * Find paths to elements in object matching path expression - * @param inputs a json value and a query - * @returns any - * @group jsonpath - * @shortname paths - * @drawable false - */ - paths(inputs: Inputs.JSON.PathsDto): any; - /** - * Creates an empty JavaScript object - * @returns any - * @group create - * @shortname empty - * @drawable false - */ - createEmpty(): any; - /** - * Previews json and gives option to save it - * @returns any - * @group preview - * @shortname json preview and save - * @drawable false - */ - previewAndSaveJson(inputs: Inputs.JSON.JsonDto): void; - /** - * Previews json - * @returns any - * @group preview - * @shortname json preview - * @drawable false - */ - previewJson(inputs: Inputs.JSON.JsonDto): void; - } - declare class OCCTWIO extends OCCTIO { - readonly occWorkerManager: OCCTWorkerManager; - private readonly context; - constructor(occWorkerManager: OCCTWorkerManager, context: ContextBase); - /** - * Imports the step or iges asset file - * @group io - * @shortname load step | iges - * @returns OCCT Shape - */ - loadSTEPorIGES( - inputs: Inputs.OCCT.ImportStepIgesDto - ): Promise; - /** - * Imports the step or iges asset file from text - * @group io - * @shortname load text step | iges - * @returns OCCT Shape - */ - loadSTEPorIGESFromText( - inputs: Inputs.OCCT.ImportStepIgesFromTextDto - ): Promise; - } - /** - * Contains various methods for OpenCascade implementation - */ - declare class OCCTW extends OCCT { - readonly context: ContextBase; - readonly occWorkerManager: OCCTWorkerManager; - readonly io: OCCTWIO; - constructor(context: ContextBase, occWorkerManager: OCCTWorkerManager); - } - /** - * Tags help you to put text on top of your 3D objects. Tags are heavily used in data visualization scenarios - * where you need to convery additional textual information. - */ - declare class Tag { - private readonly context; - constructor(context: ContextBase); - /** - * Creates a tag dto - * @param inputs Tag description - * @returns A tag - */ - create(inputs: Inputs.Tag.TagDto): Inputs.Tag.TagDto; - /** - * Draws a single tag - * @param inputs Information to draw the tag - * @returns A tag - * @ignore true - */ - drawTag(inputs: Inputs.Tag.DrawTagDto): Inputs.Tag.TagDto; - /** - * Draws multiple tags - * @param inputs Information to draw the tags - * @returns Tags - * @ignore true - */ - drawTags(inputs: Inputs.Tag.DrawTagsDto): Inputs.Tag.TagDto[]; - } - /** - * Time functions help to create various interactions which happen in time - */ - declare class Time { - private context; - constructor(context: ContextBase); - /** - * Registers a function to render loop - * @param update The function to call in render loop - */ - registerRenderFunction(update: (timePassedMs: number) => void): void; - } - /** - * Contains various methods for nurbs circle. - * These methods wrap around Verbnurbs library that you can find here http://verbnurbs.com/. - * Thanks Peter Boyer for his work. - */ - declare class VerbCurveCircle { - private readonly context; - private readonly math; - constructor(context: ContextBase, math: MathBitByBit); - /** - * Creates the circle Nurbs curve - * @param inputs Circle parameters - * @returns Circle Nurbs curve - */ - createCircle(inputs: Inputs.Verb.CircleParametersDto): any; - /** - * Creates the arc Nurbs curve - * @param inputs Arc parameters - * @returns Arc Nurbs curve - */ - createArc(inputs: Inputs.Verb.ArcParametersDto): any; - /** - * Gets the center point of the circle or an arc - * @param inputs An arc or a circle Nurbs curve - * @returns Point - */ - center(inputs: Inputs.Verb.CircleDto): number[]; - /** - * Gets the radius of the circle or an arc - * @param inputs An arc or a circle Nurbs curve - * @returns Radius - */ - radius(inputs: Inputs.Verb.CircleDto): number; - /** - * Gets the max angle of the arc in degrees - * @param inputs Arc - * @returns Max angle in degrees - */ - maxAngle(inputs: Inputs.Verb.CircleDto): number; - /** - * Gets the min angle of the arc in degrees - * @param inputs Arc - * @returns Min angle in degrees - */ - minAngle(inputs: Inputs.Verb.CircleDto): number; - /** - * Gets the x angle of the arc - * @param inputs Circle - * @returns X axis vector - */ - xAxis(inputs: Inputs.Verb.CircleDto): number[]; - /** - * Gets the y angle of the arc - * @param inputs Circle - * @returns Y axis vector - */ - yAxis(inputs: Inputs.Verb.CircleDto): number[]; - } - /** - * Contains various methods for nurbs ellipse. - * These methods wrap around Verbnurbs library that you can find here http://verbnurbs.com/. - * Thanks Peter Boyer for his work. - */ - declare class VerbCurveEllipse { - private readonly context; - private readonly math; - constructor(context: ContextBase, math: MathBitByBit); - /** - * Creates the ellipse Nurbs curve - * @param inputs Ellipse parameters - * @returns Ellipse Nurbs curve - */ - createEllipse(inputs: Inputs.Verb.EllipseParametersDto): any; - /** - * Creates the ellipse arc Nurbs curve - * @param inputs Ellipse arc parameters - * @returns Ellipse arc Nurbs curve - */ - createArc(inputs: Inputs.Verb.EllipseArcParametersDto): any; - /** - * Gets the center point of the ellipse or an arc - * @param inputs The arc or the ellipse Nurbs curve - * @returns Point - */ - center(inputs: Inputs.Verb.EllipseDto): number[]; - /** - * Gets the max angle of the arc in degrees - * @param inputs Arc - * @returns Max angle in degrees - */ - maxAngle(inputs: Inputs.Verb.EllipseDto): number; - /** - * Gets the min angle of the arc in degrees - * @param inputs Arc - * @returns Min angle in degrees - */ - minAngle(inputs: Inputs.Verb.EllipseDto): number; - /** - * Gets the x angle of the arc or an ellipse - * @param inputs Ellipse or an arc - * @returns X axis vector - */ - xAxis(inputs: Inputs.Verb.EllipseDto): number[]; - /** - * Gets the y angle of the arc or an ellipse - * @param inputs Ellipse or an arc - * @returns Y axis vector - */ - yAxis(inputs: Inputs.Verb.EllipseDto): number[]; - } - /** - * Contains various methods for nurbs curves. - * These methods wrap around Verbnurbs library that you can find here http://verbnurbs.com/. - * Thanks Peter Boyer for his work. - */ - declare class VerbCurve { - private readonly context; - private readonly geometryHelper; - private readonly math; - readonly circle: VerbCurveCircle; - readonly ellipse: VerbCurveEllipse; - constructor( - context: ContextBase, - geometryHelper: GeometryHelper, - math: MathBitByBit - ); - /** - * Creates a Nurbs curve by providing knots, control points & weights - * @param inputs Contains knots, control points and weights - * @returns Nurbs curve - */ - createCurveByKnotsControlPointsWeights( - inputs: Inputs.Verb.CurveNurbsDataDto - ): any; - /** - * Creates a Nurbs curve by providing control points - * @param inputs Control points - * @returns Nurbs curve - */ - createCurveByPoints(inputs: Inputs.Verb.CurvePathDataDto): any; - /** - * Converts lines to NURBS curves - * Returns array of the verbnurbs Line objects - * @param inputs Lines to be transformed to curves - * @returns Verb nurbs curves - */ - convertLinesToNurbsCurves(inputs: Inputs.Verb.LinesDto): any[]; - /** - * Converts line to NURBS curve - * Returns the verbnurbs Line object - * @param inputs Line to be transformed to curve - * @returns Verb nurbs curves - */ - convertLineToNurbsCurve(inputs: Inputs.Verb.LineDto): any; - /** - * Converts a polyline to a NURBS curve - * Returns the verbnurbs NurbsCurve object - * @param inputs Polyline to be transformed to curve - * @returns Verb nurbs curve - */ - convertPolylineToNurbsCurve(inputs: Inputs.Verb.PolylineDto): any; - /** - * Converts a polylines to a NURBS curves - * Returns the verbnurbs NurbsCurve objects - * @param inputs Polylines to be transformed to curves - * @returns Verb nurbs curves - */ - convertPolylinesToNurbsCurves(inputs: Inputs.Verb.PolylinesDto): any[]; - /** - * Creates a Bezier Nurbs curve by providing control points and weights - * @param inputs Control points - * @returns Bezier Nurbs curve - */ - createBezierCurve(inputs: Inputs.Verb.BezierCurveDto): any; - /** - * Clone the Nurbs curve - * @param inputs Nurbs curve - * @returns Nurbs curve - */ - clone(inputs: Inputs.Verb.CurveDto): any; - /** - * Finds the closest param on the Nurbs curve from the point - * @param inputs Nurbs curve with point - * @returns Param number - */ - closestParam(inputs: Inputs.Verb.ClosestPointDto): number; - /** - * Finds the closest params on the Nurbs curve from the points - * @param inputs Nurbs curve with points - * @returns Param numbers - */ - closestParams(inputs: Inputs.Verb.ClosestPointsDto): number[]; - /** - * Finds the closest point on the Nurbs curve from the point - * @param inputs Nurbs curve with point - * @returns Point - */ - closestPoint(inputs: Inputs.Verb.ClosestPointDto): Inputs.Base.Point3; - /** - * Finds the closest points on the Nurbs curve from the list of points - * @param inputs Nurbs curve with points - * @returns Points - */ - closestPoints(inputs: Inputs.Verb.ClosestPointsDto): Inputs.Base.Point3[]; - /** - * Finds the control points of the Nurbs curve - * @param inputs Nurbs curve - * @returns Points - */ - controlPoints(inputs: Inputs.Verb.CurveDto): Inputs.Base.Point3[]; - /** - * Finds the degree of the Nurbs curve - * @param inputs Nurbs curve - * @returns Degree number - */ - degree(inputs: Inputs.Verb.CurveDto): number; - /** - * Finds the derivatives of the Nurbs curve at parameter - * @param inputs Nurbs curve with specified derivative number and parameter - * @returns Derivatives - */ - derivatives(inputs: Inputs.Verb.CurveDerivativesDto): number[]; - /** - * Divides the curve by equal arc length to parameters - * @param inputs Nurbs curve - * @returns Parameters - */ - divideByEqualArcLengthToParams( - inputs: Inputs.Verb.CurveSubdivisionsDto - ): number[]; - /** - * Divides the curve by equal arc length to points - * @param inputs Nurbs curve - * @returns Points - */ - divideByEqualArcLengthToPoints( - inputs: Inputs.Verb.CurveSubdivisionsDto - ): Inputs.Base.Point3[]; - /** - * Divides the curve by arc length to parameters - * @param inputs Nurbs curve - * @returns Parameters - */ - divideByArcLengthToParams( - inputs: Inputs.Verb.CurveDivideLengthDto - ): number[]; - /** - * Divides the curve by arc length to points - * @param inputs Nurbs curve - * @returns Points - */ - divideByArcLengthToPoints( - inputs: Inputs.Verb.CurveDivideLengthDto - ): Inputs.Base.Point3[]; - /** - * Divides multiple curves by equal arc length to points - * @param inputs Nurbs curves - * @returns Points placed for each curve in separate arrays - */ - divideCurvesByEqualArcLengthToPoints( - inputs: Inputs.Verb.CurvesSubdivisionsDto - ): Inputs.Base.Point3[][]; - /** - * Divides multiple curves by arc length to points - * @param inputs Nurbs curves - * @returns Points placed for each curve in separate arrays - */ - divideCurvesByArcLengthToPoints( - inputs: Inputs.Verb.CurvesDivideLengthDto - ): Inputs.Base.Point3[][]; - /** - * Finds the domain interval of the curve parameters - * @param inputs Nurbs curve - * @returns Interval domain - */ - domain(inputs: Inputs.Verb.CurveDto): BaseTypes.IntervalDto; - /** - * Start point of the curve - * @param inputs Nurbs curve - * @returns Start point - */ - startPoint(inputs: Inputs.Verb.CurveDto): Inputs.Base.Point3; - /** - * End point of the curve - * @param inputs Nurbs curve - * @returns End point - */ - endPoint(inputs: Inputs.Verb.CurveDto): Inputs.Base.Point3; - /** - * Start points of the curves - * @param inputs Nurbs curves - * @returns Start points - */ - startPoints(inputs: Inputs.Verb.CurvesDto): Inputs.Base.Point3[]; - /** - * End points of the curves - * @param inputs Nurbs curves - * @returns End points - */ - endPoints(inputs: Inputs.Verb.CurvesDto): Inputs.Base.Point3[]; - /** - * Finds the knots of the Nurbs curve - * @param inputs Nurbs curve - * @returns Knots - */ - knots(inputs: Inputs.Verb.CurveDto): number[]; - /** - * Gets the length of the Nurbs curve at specific parameter - * @param inputs Nurbs curve and parameter - * @returns Length - */ - lengthAtParam(inputs: Inputs.Verb.CurveParameterDto): number; - /** - * Gets the length of the Nurbs curve - * @param inputs Nurbs curve - * @returns Length - */ - length(inputs: Inputs.Verb.CurveDto): number; - /** - * Gets the param at specified length on the Nurbs curve - * @param inputs Nurbs curve, length and tolerance - * @returns Parameter - */ - paramAtLength(inputs: Inputs.Verb.CurveLengthToleranceDto): number; - /** - * Gets the point at specified parameter on the Nurbs curve - * @param inputs Nurbs curve and a parameter - * @returns Point - */ - pointAtParam(inputs: Inputs.Verb.CurveParameterDto): Inputs.Base.Point3; - /** - * Gets the points at specified parameter on the Nurbs curves - * @param inputs Nurbs curves and a parameter - * @returns Points in arrays for each curve - */ - pointsAtParam(inputs: Inputs.Verb.CurvesParameterDto): Inputs.Base.Point3[]; - /** - * Reverses the Nurbs curve - * @param inputs Nurbs curve - * @returns Reversed Nurbs curve - */ - reverse(inputs: Inputs.Verb.CurveDto): any; - /** - * Splits the Nurbs curve in two at a given parameter - * @param inputs Nurbs curve with parameter - * @returns Nurbs curves - */ - split(inputs: Inputs.Verb.CurveParameterDto): any[]; - /** - * Tangent of the Nurbs curve at a given parameter - * @param inputs Nurbs curve with parameter - * @returns Tangent vector - */ - tangent(inputs: Inputs.Verb.CurveParameterDto): Inputs.Base.Vector3; - /** - * Tessellates the Nurbs curve into a list of points - * @param inputs Nurbs curve with tolerance - * @returns Points - */ - tessellate(inputs: Inputs.Verb.CurveToleranceDto): Inputs.Base.Point3[]; - /** - * Transforms the Nurbs curve - * @param inputs Nurbs curve with transformation matrixes - * @returns Transformed curve - */ - transform(inputs: Inputs.Verb.CurveTransformDto): any; - /** - * Transforms the Nurbs curves - * @param inputs Nurbs curves with transformation matrixes - * @returns Transformed curves - */ - transformCurves(inputs: Inputs.Verb.CurvesTransformDto): any[]; - /** - * Weights of the Nurbs curve - * @param inputs Nurbs curve - * @returns Weights - */ - weights(inputs: Inputs.Verb.CurveDto): number[]; - } - /** - * Functions that allow to intersect various geometric entities and get the results - */ - declare class VerbIntersect { - private readonly context; - private readonly geometryHelper; - constructor(context: ContextBase, geometryHelper: GeometryHelper); - /** - * Intersects two verb Nurbs curves together and returns intersection results - * @param inputs Two Nurbs curves - * @returns Intersection results - */ - curves( - inputs: Inputs.Verb.CurveCurveDto - ): BaseTypes.CurveCurveIntersection[]; - /** - * Intersects curve and surface - * @param inputs Nurbs curve and a Nurbs surface - * @returns Intersection results - */ - curveAndSurface( - inputs: Inputs.Verb.CurveSurfaceDto - ): BaseTypes.CurveSurfaceIntersection[]; - /** - * Intersects two surfaces - * @param inputs Nurbs curve and a Nurbs surface - * @returns Nurbs curves along the intersection - */ - surfaces(inputs: Inputs.Verb.SurfaceSurfaceDto): any[]; - /** - * Gets intersection parameters on the first curve from curve-curve intersection - * @param inputs Intersections data - * @returns Parameters on first curve - */ - curveCurveFirstParams( - inputs: Inputs.Verb.CurveCurveIntersectionsDto - ): number[]; - /** - * Gets intersection parameters on the second curve from curve-curve intersection - * @param inputs Intersections data - * @returns Parameters on second curve - */ - curveCurveSecondParams( - inputs: Inputs.Verb.CurveCurveIntersectionsDto - ): number[]; - /** - * Gets intersection points on the first curve from curve-curve intersection - * @param inputs Intersections data - * @returns Points on first curve - */ - curveCurveFirstPoints( - inputs: Inputs.Verb.CurveCurveIntersectionsDto - ): number[][]; - /** - * Gets intersection points on the second curve from curve-curve intersection - * @param inputs Intersections data - * @returns Points on second curve - */ - curveCurveSecondPoints( - inputs: Inputs.Verb.CurveCurveIntersectionsDto - ): number[][]; - /** - * Gets intersection parameters on the curve from curve-surface intersection - * @param inputs Intersections data - * @returns Parameters on the curve - */ - curveSurfaceCurveParams( - inputs: Inputs.Verb.CurveSurfaceIntersectionsDto - ): number[]; - /** - * Gets intersection parameters on the surface from curve-surface intersection - * @param inputs Intersections data - * @returns Parameters on the surface - */ - curveSurfaceSurfaceParams( - inputs: Inputs.Verb.CurveSurfaceIntersectionsDto - ): BaseTypes.UVDto[]; - /** - * Gets intersection points on the curve from curve-surface intersection - * @param inputs Intersections data - * @returns Points on the curve - */ - curveSurfaceCurvePoints( - inputs: Inputs.Verb.CurveSurfaceIntersectionsDto - ): number[][]; - /** - * Gets intersection points on the surface from curve-surface intersection - * @param inputs Intersections data - * @returns Points on the surface - */ - curveSurfaceSurfacePoints( - inputs: Inputs.Verb.CurveSurfaceIntersectionsDto - ): number[][]; - } - /** - * Conical surface functions. - * These functions wrap around Verbnurbs library that you can find here http://verbnurbs.com/. - * Thanks Peter Boyer for his work. - */ - declare class VerbSurfaceConical { - private readonly context; - constructor(context: ContextBase); - /** - * Creates the conical Nurbs surface - * @param inputs Parameters for Nurbs conical surface - * @returns Conical Nurbs surface - */ - create(inputs: Inputs.Verb.ConeAndCylinderParametersDto): any; - /** - * Get cone axis - * @param inputs Nurbs conical surface - * @returns Axis vector - */ - axis(inputs: Inputs.Verb.ConeDto): number[]; - /** - * Get cone base - * @param inputs Nurbs conical surface - * @returns Base point - */ - base(inputs: Inputs.Verb.ConeDto): number[]; - /** - * Get cone height - * @param inputs Nurbs conical surface - * @returns Height - */ - height(inputs: Inputs.Verb.ConeDto): number; - /** - * Get cone radius - * @param inputs Nurbs conical surface - * @returns Radius - */ - radius(inputs: Inputs.Verb.ConeDto): number; - /** - * Get cone x axis - * @param inputs Nurbs conical surface - * @returns X axis vector - */ - xAxis(inputs: Inputs.Verb.ConeDto): number[]; - } - /** - * Cylindrical surface functions. - * These functions wrap around Verbnurbs library that you can find here http://verbnurbs.com/. - * Thanks Peter Boyer for his work. - */ - declare class VerbSurfaceCylindrical { - private readonly context; - constructor(context: ContextBase); - /** - * Creates the cylindrical Nurbs surface - * @param inputs Parameters for cylindrical Nurbs surface - * @returns Cylindrical Nurbs surface - */ - create(inputs: Inputs.Verb.ConeAndCylinderParametersDto): any; - /** - * Get cylinder axis - * @param inputs Nurbs cylindrical surface - * @returns Axis vector - */ - axis(inputs: Inputs.Verb.CylinderDto): number[]; - /** - * Get cylinder base - * @param inputs Nurbs cylindrical surface - * @returns Base point - */ - base(inputs: Inputs.Verb.CylinderDto): number[]; - /** - * Get cylinder height - * @param inputs Nurbs cylindrical surface - * @returns Height - */ - height(inputs: Inputs.Verb.CylinderDto): number; - /** - * Get cylinder radius - * @param inputs Nurbs cylindrical surface - * @returns Radius - */ - radius(inputs: Inputs.Verb.CylinderDto): number; - /** - * Get cylinder x axis - * @param inputs Nurbs cylindrical surface - * @returns X axis vector - */ - xAxis(inputs: Inputs.Verb.CylinderDto): number[]; - } - /** - * Extrusion surface functions. - * These functions wrap around Verbnurbs library that you can find here http://verbnurbs.com/. - * Thanks Peter Boyer for his work. - */ - declare class VerbSurfaceExtrusion { - private readonly context; - constructor(context: ContextBase); - /** - * Creates the Nurbs surface extrusion from the curve - * @param inputs Nurbs profile curve and direction vector - * @returns Nurbs surface - */ - create(inputs: Inputs.Verb.ExtrusionParametersDto): any; - /** - * Gets the direction vector of the extrusion - * @param inputs Extruded Nurbs surface - * @returns Vector - */ - direction(inputs: Inputs.Verb.ExtrusionDto): number[]; - /** - * Gets the profile Nurbs curve of the extrusion - * @param inputs Extruded Nurbs surface - * @returns Profile Nurbs curve - */ - profile(inputs: Inputs.Verb.ExtrusionDto): number[]; - } - /** - * Revolved surface functions. - * These functions wrap around Verbnurbs library that you can find here http://verbnurbs.com/. - * Thanks Peter Boyer for his work. - */ - declare class VerbSurfaceRevolved { - private readonly context; - private readonly math; - constructor(context: ContextBase, math: MathBitByBit); - /** - * Creates the revolved Nurbs surface - * @param inputs Parameters for Nurbs revolved surface - * @returns Revolved Nurbs surface - */ - create(inputs: Inputs.Verb.RevolutionParametersDto): any; - /** - * Get the profile Nurbs curve of the revolved Nurbs surface - * @param inputs Revolved Nurbs surface - * @returns Nurbs curve - */ - profile(inputs: Inputs.Verb.RevolutionDto): any; - /** - * Get the center Nurbs curve of the revolved Nurbs surface - * @param inputs Revolved Nurbs surface - * @returns Center point - */ - center(inputs: Inputs.Verb.RevolutionDto): number[]; - /** - * Get the rotation axis of the revolved Nurbs surface - * @param inputs Revolved Nurbs surface - * @returns Axis vector of rotation - */ - axis(inputs: Inputs.Verb.RevolutionDto): number[]; - /** - * Get the angle of rotation from revolved Nurbs surface - * @param inputs Revolved Nurbs surface - * @returns Angle in degrees - */ - angle(inputs: Inputs.Verb.RevolutionDto): number; - } - /** - * Spherical surface functions. - * These functions wrap around Verbnurbs library that you can find here http://verbnurbs.com/. - * Thanks Peter Boyer for his work. - */ - declare class VerbSurfaceSpherical { - private readonly context; - constructor(context: ContextBase); - /** - * Creates the spherical Nurbs surface - * @param inputs Parameters for Nurbs spherical surface - * @returns Spherical Nurbs surface - */ - create(inputs: Inputs.Verb.SphericalParametersDto): any; - /** - * Get the radius of the spherical Nurbs surface - * @param inputs Spherical Nurbs surface - * @returns Radius - */ - radius(inputs: Inputs.Verb.SphereDto): number; - /** - * Get the center of the spherical Nurbs surface - * @param inputs Spherical Nurbs surface - * @returns Center point - */ - center(inputs: Inputs.Verb.SphereDto): number[]; - } - /** - * Sweep surface functions. - * These functions wrap around Verbnurbs library that you can find here http://verbnurbs.com/. - * Thanks Peter Boyer for his work. - */ - declare class VerbSurfaceSweep { - private readonly context; - constructor(context: ContextBase); - /** - * Creates the sweep Nurbs surface - * @param inputs Parameters for Nurbs sweep surface - * @returns Sweep Nurbs surface - */ - create(inputs: Inputs.Verb.SweepParametersDto): any; - /** - * Get the profile Nurbs curve of the swept Nurbs surface - * @param inputs Sweep Nurbs surface - * @returns Profile Nurbs curve - */ - profile(inputs: Inputs.Verb.SweepDto): any; - /** - * Get the rail Nurbs curve of the swept Nurbs surface - * @param inputs Sweep Nurbs surface - * @returns Rail Nurbs curve - */ - rail(inputs: Inputs.Verb.SweepDto): any; - } - /** - * Contains various functions for Nurbs surfaces. - * These functions wrap around Verbnurbs library that you can find here http://verbnurbs.com/. - * Thanks Peter Boyer for his work. - */ - declare class VerbSurface { - private readonly context; - private readonly geometryHelper; - private readonly math; - readonly cone: VerbSurfaceConical; - readonly cylinder: VerbSurfaceCylindrical; - readonly extrusion: VerbSurfaceExtrusion; - readonly sphere: VerbSurfaceSpherical; - readonly revolved: VerbSurfaceRevolved; - readonly sweep: VerbSurfaceSweep; - constructor( - context: ContextBase, - geometryHelper: GeometryHelper, - math: MathBitByBit - ); - /** - * Gets the boundary edge Nurbs curves of the surface in a list - * @param inputs Nurbs surface - * @returns Array of curves - */ - boundaries(inputs: Inputs.Verb.SurfaceDto): any[]; - /** - * Creates the surface by providing 4 points as corners - * @param inputs 4 points - * @returns Nurbs surface - */ - createSurfaceByCorners(inputs: Inputs.Verb.CornersDto): any; - /** - * Creates the Nurbs surface by providing uv knots, uv degrees, points and weights - * @param inputs Surface creation information - * @returns Nurbs surface - */ - createSurfaceByKnotsControlPointsWeights( - inputs: Inputs.Verb.KnotsControlPointsWeightsDto - ): any; - /** - * Creates the Nurbs surface by lofting curves - * @param inputs Curves to loft through - * @returns Nurbs surface - */ - createSurfaceByLoftingCurves(inputs: Inputs.Verb.LoftCurvesDto): any; - /** - * Clone the Nurbs surface - * @param inputs Nurbs surface - * @returns Nurbs surface - */ - clone(inputs: Inputs.Verb.SurfaceDto): any; - /** - * Finds the closest parameter on the surface from the point - * @param inputs Nurbs surface with a point - * @returns UV parameters - */ - closestParam(inputs: Inputs.Verb.SurfaceParamDto): BaseTypes.UVDto; - /** - * Finds the closest point on the surface from the point - * @param inputs Nurbs surface with a point - * @returns Point - */ - closestPoint(inputs: Inputs.Verb.SurfaceParamDto): number[]; - /** - * Gets the control points on the surface - * @param inputs Nurbs surface - * @returns Two dimensional array of points - */ - controlPoints(inputs: Inputs.Verb.SurfaceDto): number[][][]; - /** - * Gets the U degree of the surface - * @param inputs Nurbs surface - * @returns U degree - */ - degreeU(inputs: Inputs.Verb.SurfaceDto): number; - /** - * Gets the V degree of the surface - * @param inputs Nurbs surface - * @returns V degree - */ - degreeV(inputs: Inputs.Verb.SurfaceDto): number; - /** - * Gets the derivatives of the surface at specified uv coordinate - * @param inputs Nurbs surface - * @returns Two dimensional array of vectors - */ - derivatives(inputs: Inputs.Verb.DerivativesDto): number[][][]; - /** - * Gets the U domain of the surface - * @param inputs Nurbs surface - * @returns U domain as interval - */ - domainU(inputs: Inputs.Verb.SurfaceDto): BaseTypes.IntervalDto; - /** - * Gets the V domain of the surface - * @param inputs Nurbs surface - * @returns V domain as interval - */ - domainV(inputs: Inputs.Verb.SurfaceDto): BaseTypes.IntervalDto; - /** - * Gets the Nurbs isocurve on the surface - * @param inputs Nurbs surface - * @returns Nurbs curve - */ - isocurve(inputs: Inputs.Verb.SurfaceParameterDto): any; - /** - * Subdivides surface into preferred number of isocurves - * @param inputs Nurbs surface - * @returns Nurbs curves - */ - isocurvesSubdivision(inputs: Inputs.Verb.IsocurveSubdivisionDto): any[]; - /** - * Subdivides surface into isocurves on specified array of parameters - * @param inputs Nurbs surface - * @returns Nurbs curves - */ - isocurvesAtParams(inputs: Inputs.Verb.IsocurvesParametersDto): any[]; - /** - * Gets the U knots of the surface - * @param inputs Nurbs surface - * @returns Knots on u direction - */ - knotsU(inputs: Inputs.Verb.SurfaceDto): number[]; - /** - * Gets the V knots of the surface - * @param inputs Nurbs surface - * @returns Knots on v direction - */ - knotsV(inputs: Inputs.Verb.SurfaceDto): number[]; - /** - * Gets the normal on the surface at uv coordinate - * @param inputs Nurbs surface - * @returns Normal vector - */ - normal(inputs: Inputs.Verb.SurfaceLocationDto): number[]; - /** - * Gets the point on the surface at uv coordinate - * @param inputs Nurbs surface - * @returns Point - */ - point(inputs: Inputs.Verb.SurfaceLocationDto): number[]; - /** - * Reverse the Nurbs surface. This will reverse the UV origin and isocurve directions - * @param inputs Nurbs surface - * @returns Nurbs surface - */ - reverse(inputs: Inputs.Verb.SurfaceDto): any; - /** - * Splits the Nurbs surface in two halfs. - * @param inputs Nurbs surface - * @returns Two Nurbs surfaces - */ - split(inputs: Inputs.Verb.SurfaceParameterDto): any[]; - /** - * Transforms the Nurbs surface with a given list of transformations. - * @param inputs Nurbs surface with transforms - * @returns Nurbs surface - */ - transformSurface(inputs: Inputs.Verb.SurfaceTransformDto): any; - /** - * Gets the weights of the surface - * @param inputs Nurbs surface - * @returns Two dimensional array of weights - */ - weights(inputs: Inputs.Verb.SurfaceDto): number[][]; - } - /** - * Contains various functions for Nurbs curves and surfaces. - * These functions wrap around Verbnurbs library that you can find here http://verbnurbs.com/. - * Thanks Peter Boyer for his work. - */ - declare class Verb { - private readonly math; - readonly curve: VerbCurve; - readonly surface: VerbSurface; - readonly intersect: VerbIntersect; - constructor( - context: ContextBase, - geometryHelper: GeometryHelper, - math: MathBitByBit - ); - } - declare class AdvancedAdv { - private readonly occWorkerManager; - private readonly context; - private readonly draw; - text3d: Text3D; - patterns: Patterns; - navigation: Navigation; - dimensions: Dimensions; - constructor( - occWorkerManager: OCCTWorkerManager, - context: Context, - draw: Draw - ); - } - declare class Dimensions { - private readonly context; - constructor(context: ContextComplete); - /** - * Creates linear dimension - a measurement line between two points with extension lines and text label. - * The dimension shows the distance between the points and can be styled with DimensionStyleDto. - * @example Dimensions.linearDimension({ name: "Length", startPoint: [0, 0, 0], endPoint: [5, 0, 0], direction: [0, 1, 0] }); - * @param inputs - * @returns Create linear dimension - * @group dimensions - * @shortname linear dimension - * @drawable true - */ - linearDimension( - inputs: Advanced.Dimensions.LinearDimensionDto - ): Advanced.Dimensions.LinearDimensionEntity; - /** - * Creates angular dimension - a measurement arc between two direction vectors with extension lines and text label. - * The dimension shows the angle between the directions and can be styled with DimensionStyleDto. - * @example Dimensions.angularDimension({ name: "Angle", centerPoint: [0, 0, 0], direction1: [1, 0, 0], direction2: [0, 1, 0], radius: 2 }); - * @param inputs - * @returns Create angular dimension - * @group dimensions - * @shortname angular dimension - * @drawable true - */ - angularDimension( - inputs: Advanced.Dimensions.AngularDimensionDto - ): Advanced.Dimensions.AngularDimensionEntity; - /** - * Creates radial dimension - a measurement line from center to perimeter showing radius or diameter. - * Shows 'R' prefix for radius or '⌀' prefix for diameter with optional center mark. - * @example Dimensions.radialDimension({ centerPoint: [0, 0, 0], radiusPoint: [2, 0, 0], showDiameter: false }); - * @param inputs - * @returns Create radial dimension - * @group dimensions - * @shortname radial dimension - * @drawable true - */ - radialDimension( - inputs: Advanced.Dimensions.RadialDimensionDto - ): Advanced.Dimensions.RadialDimensionEntity; - /** - * Creates diametral dimension - a measurement line spanning full diameter of circular features. - * Shows '⌀' prefix with optional center mark and arrows at both ends. - * @example Dimensions.diametralDimension({ centerPoint: [0, 0, 0], direction: [1, 0, 0], diameter: 4 }); - * @param inputs - * @returns Create diametral dimension - * @group dimensions - * @shortname diametral dimension - * @drawable true - */ - diametralDimension( - inputs: Advanced.Dimensions.DiametralDimensionDto - ): Advanced.Dimensions.DiametralDimensionEntity; - /** - * Creates ordinate dimension - shows X, Y, or Z coordinate from a reference point with leader line. - * Useful for coordinate annotations and datum referencing in technical drawings. - * @example Dimensions.ordinateDimension({ measurementPoint: [5, 3, 2], referencePoint: [0, 0, 0], axis: "X" }); - * @param inputs - * @returns Create ordinate dimension - * @group dimensions - * @shortname ordinate dimension - * @drawable true - */ - ordinateDimension( - inputs: Advanced.Dimensions.OrdinateDimensionDto - ): Advanced.Dimensions.OrdinateDimensionEntity; - /** - * Create dimension style - used to style dimension lines, arrows, and text in 3D space. - * You can customize line colors, thickness, text size, arrow size, and background colors. - * @param inputs - * @returns Create dimension style - * @group style - * @shortname dimension style - * @drawable false - */ - dimensionStyle( - inputs: Advanced.Dimensions.DimensionStyleDto - ): Advanced.Dimensions.DimensionStyleDto; - /** - * Draw linear dimension in 3D space - * @param inputs - * @returns Draw linear dimension with dispose method - * @group linear dimension - * @shortname draw linear dimension - * @drawable false - * @ignore true - */ - drawLinearDimension(inputs: Advanced.Dimensions.LinearDimensionEntity): { - dispose: () => void; - }; - /** - * Draw angular dimension in 3D space - * @param inputs - * @returns Draw angular dimension with dispose method - * @group angular dimension - * @shortname draw angular dimension - * @drawable false - * @ignore true - */ - drawAngularDimension(inputs: Advanced.Dimensions.AngularDimensionEntity): { - dispose: () => void; - }; - /** - * Draw radial dimension in 3D space - * @param inputs - * @returns Draw radial dimension with dispose method - * @group radial dimension - * @shortname draw radial dimension - * @drawable false - * @ignore true - */ - drawRadialDimension(inputs: Advanced.Dimensions.RadialDimensionEntity): { - dispose: () => void; - }; - /** - * Draw diametral dimension in 3D space - * @param inputs - * @returns Draw diametral dimension with dispose method - * @group diametral dimension - * @shortname draw diametral dimension - * @drawable false - * @ignore true - */ - drawDiametralDimension( - inputs: Advanced.Dimensions.DiametralDimensionEntity - ): { - dispose: () => void; - }; - /** - * Draw ordinate dimension in 3D space - * @param inputs - * @returns Draw ordinate dimension with dispose method - * @group ordinate dimension - * @shortname draw ordinate dimension - * @drawable false - * @ignore true - */ - drawOrdinateDimension( - inputs: Advanced.Dimensions.OrdinateDimensionEntity - ): { - dispose: () => void; - }; - } - declare class AngularDimension { - private scene; - private data; - private style; - private arc; - private extensionLine1; - private extensionLine2; - private tangentExtension1; - private tangentExtension2; - private arrow1; - private arrow2; - private dimensionText3D; - private static readonly DEFAULT_STYLE; - constructor(options: AngularDimensionDto, scene: BABYLON.Scene); - private createDimension; - private createArc; - private createArrowTailExtensions; - private createLine; - private createArrow; - private createText; - dispose(): void; - } - declare class DiametralDimension { - private scene; - private data; - private style; - private diameterLine; - private centerMark; - private arrow1; - private arrow2; - private dimensionText3D; - constructor(options: DiametralDimensionDto, scene: BABYLON.Scene); - private create; - private createLine; - private createCenterMark; - private createArrow; - private createText; - dispose(): void; - } - /** - * Service for evaluating mathematical expressions in dimension labels. - * Supports basic arithmetic operations and template string replacement. - */ - declare class DimensionExpressionService { - /** - * Evaluates a mathematical expression or template string with a given value - * @param expression The expression to evaluate (can contain 'val' placeholder) - * @param value The numeric value to substitute for 'val' - * @param decimalPlaces Number of decimal places to format the result - * @param removeTrailingZeros Whether to remove trailing zeros from the result - * @returns The evaluated expression as a formatted string - */ - static evaluate( - expression: string, - value: number, - decimalPlaces: number, - removeTrailingZeros?: boolean - ): string; - /** - * Formats dimension text with prefix, suffix, and expression evaluation - * @param value The numeric value to display - * @param labelOverwrite Optional expression to evaluate instead of raw value - * @param decimalPlaces Number of decimal places for formatting - * @param labelSuffix Suffix to append to the text - * @param removeTrailingZeros Whether to remove trailing zeros from the result - * @param prefix Optional prefix to prepend to the text - * @returns Formatted dimension text - */ - static formatDimensionText( - value: number, - labelOverwrite: string | undefined, - decimalPlaces: number, - labelSuffix: string, - removeTrailingZeros?: boolean, - prefix?: string - ): string; - /** - * Formats linear dimension text - */ - static formatLinearText( - distance: number, - labelOverwrite: string | undefined, - decimalPlaces: number, - labelSuffix: string, - removeTrailingZeros?: boolean - ): string; - /** - * Formats angular dimension text - */ - static formatAngularText( - angle: number, - labelOverwrite: string | undefined, - decimalPlaces: number, - labelSuffix: string, - removeTrailingZeros?: boolean - ): string; - /** - * Formats radial dimension text - */ - static formatRadialText( - radius: number, - showDiameter: boolean, - labelOverwrite: string | undefined, - decimalPlaces: number, - labelSuffix: string, - removeTrailingZeros?: boolean - ): string; - /** - * Formats diametral dimension text - */ - static formatDiametralText( - diameter: number, - labelOverwrite: string | undefined, - decimalPlaces: number, - labelSuffix: string, - removeTrailingZeros?: boolean - ): string; - /** - * Formats ordinate dimension text - */ - static formatOrdinateText( - coordinate: number, - axisName: string, - labelOverwrite: string | undefined, - decimalPlaces: number, - labelSuffix: string, - removeTrailingZeros?: boolean - ): string; - } - declare class DimensionManager { - private linearDimensions; - private angularDimensions; - private radialDimensions; - private diametralDimensions; - private ordinateDimensions; - addLinearDimension(dimension: LinearDimension): void; - removeLinearDimension(dimension: LinearDimension): void; - addAngularDimension(dimension: AngularDimension): void; - removeAngularDimension(dimension: AngularDimension): void; - addRadialDimension(dimension: RadialDimension): void; - removeRadialDimension(dimension: RadialDimension): void; - addDiametralDimension(dimension: DiametralDimension): void; - removeDiametralDimension(dimension: DiametralDimension): void; - addOrdinateDimension(dimension: OrdinateDimension): void; - removeOrdinateDimension(dimension: OrdinateDimension): void; - clearAllDimensions(): void; - dispose(): void; - } - /** - * Interface for GUI text creation result - */ - interface GuiTextElements { - textAnchor: BABYLON.TransformNode; - textContainer: GUI.Rectangle; - textBlock: GUI.TextBlock; - } - /** - * Service for creating shared 3D and GUI rendering elements used across all dimension types. - * Eliminates code duplication by providing common mesh and text creation functionality. - */ - declare class DimensionRenderingService { - /** - * Creates a line mesh using tube geometry with consistent styling - * @param scene The Babylon scene - * @param points Array of Vector3 points defining the line path - * @param name Name for the mesh - * @param style Dimension style containing appearance settings - * @param dimensionType Type of dimension for metadata - * @returns The created line mesh - */ - static createLine( - scene: BABYLON.Scene, - points: BABYLON.Vector3[], - name: string, - style: DimensionStyleDto, - dimensionType: string - ): BABYLON.Mesh; - /** - * Creates an arrow mesh (cone) with consistent styling - * @param scene The Babylon scene - * @param position Position for the arrow - * @param direction Direction the arrow should point - * @param name Name for the mesh - * @param style Dimension style containing appearance settings - * @param dimensionType Type of dimension for metadata - * @returns The created arrow mesh - */ - static createArrow( - scene: BABYLON.Scene, - position: BABYLON.Vector3, - direction: BABYLON.Vector3, - name: string, - style: DimensionStyleDto, - dimensionType: string - ): BABYLON.Mesh; - /** - * Creates a 3D text mesh using DimensionText3D - * @param scene The Babylon scene - * @param text The text content - * @param position Position for the text - * @param style Dimension style containing appearance settings - * @returns The created DimensionText3D instance - */ - static create3DText( - scene: BABYLON.Scene, - text: string, - position: BABYLON.Vector3, - style: DimensionStyleDto - ): DimensionText3D; - /** - * Creates GUI text elements (anchor, container, text block) with consistent styling - * @param scene The Babylon scene - * @param adt Advanced Dynamic Texture for GUI - * @param text The text content - * @param position Position for the text anchor - * @param style Dimension style containing appearance settings - * @param dimensionType Type of dimension for unique IDs - * @returns Object containing the created GUI elements - */ - static createGuiText( - scene: BABYLON.Scene, - adt: GUI.AdvancedDynamicTexture, - text: string, - position: BABYLON.Vector3, - style: DimensionStyleDto - ): GuiTextElements; - /** - * Creates a center mark (crossing lines) for radial/diametral dimensions - * @param scene The Babylon scene - * @param center Center position for the mark - * @param style Dimension style containing appearance settings - * @param dimensionType Type of dimension for metadata - * @returns The merged center mark mesh - */ - static createCenterMark( - scene: BABYLON.Scene, - center: BABYLON.Vector3, - style: DimensionStyleDto, - dimensionType: string - ): BABYLON.Mesh; - } - /** - * Manages shared services and utilities for all dimension classes. - * Provides singleton pattern for occlusion services and shared utilities. - */ - declare class DimensionServiceManager { - private static idCounter; - /** - * Generates unique IDs for dimensions using a counter-based approach - */ - static generateId(type: string): string; - /** - * Creates Vector3 from array efficiently - */ - static createVector3FromArray( - arr: [number, number, number] - ): BABYLON.Vector3; - /** - * Creates a fresh material for dimension elements - * No caching to avoid issues with disposed materials and external scene cleanup - */ - static getDimensionMaterial( - scene: BABYLON.Scene, - color: string, - materialType?: "line" | "arrow" - ): BABYLON.StandardMaterial; - } - interface Text3DOptions { - text: string; - position: BABYLON.Vector3; - size?: number; - fontWeight?: number; - color?: string; - backgroundColor?: string; - backgroundOpacity?: number; - backgroundStroke?: boolean; - backgroundStrokeThickness?: number; - backgroundRadius?: number; - stableSize?: boolean; - billboardMode?: boolean; - alwaysOnTop?: boolean; - name?: string; - } - /** - * Helper class for creating 3D text labels that properly participate in depth testing - * and rendering within the 3D scene. - */ - declare class DimensionText3D { - private scene; - private textMesh; - private material; - private dynamicTexture; - private options; - constructor(scene: BABYLON.Scene, options: Text3DOptions); - private createTextMesh; - private setupDistanceScaling; - private measureText; - /** - * Update the text content - */ - updateText(newText: string): void; - /** - * Update the position of the text mesh - */ - updatePosition(position: BABYLON.Vector3): void; - /** - * Get the text mesh for further manipulation - */ - getMesh(): BABYLON.Mesh | null; - /** - * Dispose all resources - */ - dispose(): void; - } - declare class LinearDimension { - private scene; - private data; - private style; - private dimensionLine; - private extensionLine1; - private extensionLine2; - private arrow1; - private arrow2; - private arrowTail1; - private arrowTail2; - private dimensionText3D; - private static readonly DEFAULT_STYLE; - constructor(options: LinearDimensionDto, scene: BABYLON.Scene); - private createDimension; - private createLine; - private createArrow; - private createText; - dispose(): void; - } - declare class OrdinateDimension { - private scene; - private data; - private style; - private leaderLine; - private arrow; - private dimensionText3D; - constructor(options: OrdinateDimensionDto, scene: BABYLON.Scene); - private create; - private calculateOffsetDirection; - private createLine; - private createArrow; - private createText; - dispose(): void; - } - declare class RadialDimension { - private scene; - private data; - private style; - private radiusLine; - private centerMark; - private arrow; - private dimensionText3D; - constructor(options: RadialDimensionDto, scene: BABYLON.Scene); - private create; - private createLine; - private createCenterMark; - private createArrow; - private createText; - dispose(): void; - } - declare class CameraManager { - private scene; - private camera; - private readonly animationFrameRate; - private readonly animationDurationInFrames; - constructor(scene: BABYLON.Scene); - flyTo(newPosition: BABYLON.Vector3, newTarget: BABYLON.Vector3): void; - } - declare class PointOfInterest { - private scene; - private data; - private style; - private time; - private pointSphere; - private pulseRing; - private clickSphere; - private labelText; - private labelContainer; - private containerNode; - private pointMaterial; - private pulseMaterial; - private camera; - private static readonly DEFAULT_STYLE; - constructor( - options: PointOfInterestDto, - scene: BABYLON.Scene, - onClick: () => void - ); - private create3DVisual; - private setupDistanceScaling; - private updateLabelPosition; - private createMaterials; - private createLabelText; - private updateLabelText; - private setupInteractions; - /** Animates the pulse effect using torus scaling and visibility changes for a ring effect. */ - animatePulse(): void; - dispose(): void; - } - declare class Navigation { - private readonly context; - constructor(context: ContextComplete); - /** - * Creates point of interest - clickable indicator in 3D space that can be used to fly the camera to a specific location with predefined camera position and target. - * Point of interest can be styled with PointOfInterestStyleDto and animated with pulse effect. - * Point of interest can also have a text label. - * @example Navigation.pointOfInterest({ name: "Entrance", position: [0, 1, 0], cameraPosition: [10, 10, 10], cameraTarget: [0, 0, 0] }); - * @param inputs - * @returns Create point of interest - * @group point of interest - * @shortname point of interest - * @drawable true - */ - pointOfInterest( - inputs: Advanced.Navigation.PointOfInterestDto - ): Advanced.Navigation.PointOfInterestEntity; - /** - * Create point of interest style - used to style point of interest indicators in 3D space. - * You can customize point size, color, hover color, pulse effect, text label color and size. - * @param inputs - * @returns Create point of interest style - * @group point of interest - * @shortname point of interest style - * @drawable false - */ - pointOfInterestStyle( - inputs: Advanced.Navigation.PointOfInterestStyleDto - ): Advanced.Navigation.PointOfInterestStyleDto; - /** - * Zoom camera to fit specified meshes in the scene with smooth animation. - * Works only with ArcRotateCamera. Animation can be interrupted if called multiple times. - * @param inputs Configuration for zoom operation including meshes, children inclusion, and animation speed - * @returns void - * @group camera - * @shortname zoom on - * @drawable false - */ - zoomOn(inputs: Advanced.Navigation.ZoomOnDto): Promise; - /** - * Zoom camera to fit specified meshes in the scene with smooth animation, considering exact screen aspect ratio. - * Unlike zoomOn, this method precisely calculates camera distance based on viewport dimensions and mesh bounding box - * to ensure better fit at padding=0. Works only with ArcRotateCamera. Animation can be interrupted if called multiple times. - * @param inputs Configuration for zoom operation including meshes, children inclusion, and animation speed - * @returns void - * @group camera - * @shortname zoom on aspect - * @drawable false - */ - zoomOnAspect(inputs: Advanced.Navigation.ZoomOnDto): Promise; - /** - * Focus camera on specified meshes from a specific angle with smooth animation. - * Computes the center of the bounding box of all meshes and positions the camera - * at the specified orientation vector to look at the center. - * Works only with ArcRotateCamera. Animation can be interrupted if called multiple times. - * @param inputs Configuration for focus operation including meshes, orientation, distance, and animation speed - * @returns void - * @group camera - * @shortname focus from angle - * @drawable false - */ - focusFromAngle( - inputs: Advanced.Navigation.FocusFromAngleDto - ): Promise; - /** - * Create fly through node - * @param inputs - * @returns Create fly through node - * @group point of interest - * @shortname fly through node - * @drawable false - * @ignore true - */ - drawPointOfInterest(inputs: Advanced.Navigation.PointOfInterestEntity): { - dispose: () => void; - }; - } - declare class FacePatterns { - private readonly occWorkerManager; - private readonly context; - private readonly draw; - pyramidSimple: PyramidSimple; - constructor( - occWorkerManager: OCCTWorkerManager, - context: Context, - draw: Draw - ); - } - declare class PyramidSimple { - private readonly occWorkerManager; - private readonly context; - private readonly draw; - constructor( - occWorkerManager: OCCTWorkerManager, - context: Context, - draw: Draw - ); - /** - * Creates a simple pyramid pattern on faces - * @param inputs - * @returns pyramid shapes along the wire - * @group create - * @shortname create simple pyramid - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/advanced/patterns/pyramid-simple.jpeg - * @drawable true - */ - createPyramidSimple( - inputs: Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleDto - ): Promise< - Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleData - >; - /** - * Creates a simple pyramid pattern on faces with affectors that change the height - * @param inputs uv numbers, affector points and affector weights -1 to 1 - * @returns pyramid shapes along the wire - * @group create - * @shortname create simple pyramid affector - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/advanced/patterns/pyramid-simple.jpeg - * @drawable true - */ - createPyramidSimpleAffectors( - inputs: Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleAffectorsDto - ): Promise< - Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleData - >; - /** - * Draws pyramids on the screen - * @param inputs Contains a model shapes to be drawn and additional information - * @returns BabylonJS Mesh - * @group drawing - * @shortname draw shape - * @drawable false - * @ignore true - */ - drawModel( - inputs: Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleData - ): Promise; - /** - * Gets the compound shape of all the pyramids - * @param inputs pyramid model - * @returns Compound shape of the pyramid - * @group get shapes - * @shortname get compound - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/advanced/patterns/pyramid-simple.jpeg - * @drawable true - */ - getCompoundShape( - inputs: Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelDto - ): Inputs.OCCT.TopoDSShapePointer; - /** - * Gets the compound shape on the face - * @param inputs pyramid model and face index - * @returns Compound shape of the pyramids on the face - * @group get shapes - * @shortname get compound on face - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/advanced/patterns/pyramid-simple.jpeg - * @drawable true - */ - getCompoundShapeOnFace( - inputs: Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelFaceIndexDto - ): Inputs.OCCT.TopoDSShapePointer; - /** - * Gets the compound shape of the pyramid on the face at particular index - * @param inputs - * @returns Compound shape of the pyramid - * @group get shapes - * @shortname get compound cell on face - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/advanced/patterns/pyramid-simple.jpeg - * @drawable true - */ - getCompoundShapeCellOnFace( - inputs: Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelFaceCellIndexDto - ): Inputs.OCCT.TopoDSShapePointer; - /** - * Gets all of the pyramid cells. This is usually in between action to then read particular information of the cells themselves. - * @param inputs - * @returns Compound shape of the pyramid - * @group get cells - * @shortname get all cells - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/advanced/patterns/pyramid-simple.jpeg - * @drawable false - */ - getAllPyramidCells( - inputs: Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelDto - ): Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleCellPart[]; - /** - * Gets pyramid cells on the face. This is usually in between action to then read particular information of the cells themselves. - * @param inputs - * @returns Cells of the pyramid - * @group get cells - * @shortname get cells on face - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/advanced/patterns/pyramid-simple.jpeg - * @drawable false - */ - getAllPyramidCellsOnFace( - inputs: Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelFaceIndexDto - ): Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleCellPart[]; - /** - * Gets pyramid cells on the face. This is usually in between action to then read particular information of the cells themselves. - * @param inputs - * @returns Cells of the pyramid - * @group get cells - * @shortname get cells on face - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/advanced/patterns/pyramid-simple.jpeg - * @drawable false - */ - getAllPyramidUCellsOnFace( - inputs: Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelFaceIndexDto - ): Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleCellPart[]; - /** - * Gets pyramid cells on the face at u index along v direction. This is usually in between action to then read particular information of the cells themselves. - * @param inputs - * @returns Cells of the pyramid - * @group get cells - * @shortname get cells on face at u - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/advanced/patterns/pyramid-simple.jpeg - * @drawable false - */ - getAllPyramidUCellsOnFaceAtU( - inputs: Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelFaceCellsUIndexDto - ): Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleCellPart[]; - /** - * Gets pyramid cells on the face at v index along u direction. This is usually in between action to then read particular information of the cells themselves. - * @param inputs - * @returns Cells of the pyramid - * @group get cells - * @shortname get cells on face at v - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/advanced/patterns/pyramid-simple.jpeg - * @drawable false - */ - getAllPyramidUCellsOnFaceAtV( - inputs: Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelFaceCellsVIndexDto - ): Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleCellPart[]; - /** - * Gets pyramid cell on the face at u and v index. This is usually in between action to then read particular information of the cell itself. - * @param inputs - * @returns Cell of the pyramid - * @group get cell - * @shortname get cell - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/advanced/patterns/pyramid-simple.jpeg - * @drawable false - */ - getCellOnIndex( - inputs: Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelFaceCellIndexDto - ): Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleCellPart; - /** - * Gets the top points of cells - * @param inputs cells of the pyramid - * @returns Top points on the cells - * @group get from cells - * @shortname get top points - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/advanced/patterns/pyramid-simple.jpeg - * @drawable true - */ - getTopPointsOfCells( - inputs: Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelCellsDto - ): Inputs.Base.Point3[]; - /** - * Gets the center point between cell corners - * @param inputs cells of the pyramid - * @returns Center points on the cells - * @group get from cells - * @shortname get center points - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/advanced/patterns/pyramid-simple.jpeg - * @drawable true - */ - getCenterPointsOfCells( - inputs: Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelCellsDto - ): Inputs.Base.Point3[]; - /** - * Gets the corner points of cells - * @param inputs cells of the pyramid - * @returns Corner points on cells provided - * @group get from cells - * @shortname get corner points of cells - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/advanced/patterns/pyramid-simple.jpeg - * @drawable false - */ - getCornerPointsOfCells( - inputs: Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelCellsDto - ): Inputs.Base.Point3[][]; - /** - * Gets the corner points of cells - * @param inputs cells of the pyramid - * @returns Corner points on cells provided - * @group get from cells - * @shortname get corner point of cells - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/advanced/patterns/pyramid-simple.jpeg - * @drawable true - */ - getCornerPointOfCells( - inputs: Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelCellsIndexDto - ): Inputs.Base.Point3[]; - /** - * Gets the corner normal of cells - * @param inputs cells of the pyramid - * @returns Corner normals on cells provided - * @group get from cells - * @shortname get corner normal of cells - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/advanced/patterns/pyramid-simple.jpeg - * @drawable false - */ - getCornerNormalOfCells( - inputs: Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelCellsIndexDto - ): Inputs.Base.Point3[]; - /** - * Gets the corner normals of cells - * @param inputs cells of the pyramid - * @returns Corner normals on cells provided - * @group get from cells - * @shortname get corner normals of cells - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/advanced/patterns/pyramid-simple.jpeg - * @drawable false - */ - getCornerNormalsOfCells( - inputs: Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelCellsDto - ): Inputs.Base.Point3[][]; - /** - * Gets the compound shapes of the pyramid cells - * @param inputs cells of the pyramid - * @returns Compound shapes on cells provided - * @group get from cells - * @shortname get compound shapes - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/advanced/patterns/pyramid-simple.jpeg - * @drawable true - */ - getCompoundShapesOfCells( - inputs: Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelCellsDto - ): Inputs.OCCT.TopoDSShapePointer[]; - /** - * Gets the face shapes of the pyramid cells provided - * @param inputs cells of the pyramid - * @returns Face shapes on cells provided - * @group get from cells - * @shortname get face shapes - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/advanced/patterns/pyramid-simple.jpeg - * @drawable true - */ - getFaceShapesOfCells( - inputs: Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelCellsIndexDto - ): Inputs.OCCT.TopoDSShapePointer[]; - /** - * Gets the face shapes of the pyramid cells provided - * @param inputs cells of the pyramid - * @returns Wire shapes on cells provided - * @group get from cells - * @shortname get wire shapes - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/advanced/patterns/pyramid-simple.jpeg - * @drawable true - */ - getWireShapesOfCells( - inputs: Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelCellsIndexDto - ): Inputs.OCCT.TopoDSShapePointer[]; - /** - * Gets the polyline wire along the start edge of the face's U direction - * @param inputs pyramid model and face index - * @returns Wire shapes - * @group get from face - * @shortname get start polyline wire u - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/advanced/patterns/pyramid-simple.jpeg - * @drawable true - */ - getStartPolylineWireU( - inputs: Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelFaceIndexDto - ): Inputs.OCCT.TopoDSShapePointer; - /** - * Gets the polyline wire along the end edge of the face's U direction - * @param inputs pyramid model and face index - * @returns Wire shapes - * @group get from face - * @shortname get end polyline wire u - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/advanced/patterns/pyramid-simple.jpeg - * @drawable true - */ - getEndPolylineWireU( - inputs: Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelFaceIndexDto - ): Inputs.OCCT.TopoDSShapePointer; - /** - * Gets the polyline wire along the start edge of the face's V direction - * @param inputs pyramid model and face index - * @returns Wire shapes - * @group get from face - * @shortname get start polyline wire v - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/advanced/patterns/pyramid-simple.jpeg - * @drawable true - */ - getStartPolylineWireV( - inputs: Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelFaceIndexDto - ): Inputs.OCCT.TopoDSShapePointer; - /** - * Gets the polyline wire along the end edge of the face's V direction - * @param inputs pyramid model and face index - * @returns Wire shapes - * @group get from face - * @shortname get end polyline wire v - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/advanced/patterns/pyramid-simple.jpeg - * @drawable true - */ - getEndPolylineWireV( - inputs: Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelFaceIndexDto - ): Inputs.OCCT.TopoDSShapePointer; - /** - * Gets the polyline wires along U direction - * @param inputs pyramid model and face index - * @returns Wire shapes - * @group get from face - * @shortname get compound polyline wires u - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/advanced/patterns/pyramid-simple.jpeg - * @drawable true - */ - getPolylineWiresUCompound( - inputs: Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelFaceIndexDto - ): Inputs.OCCT.TopoDSShapePointer; - /** - * Gets the polyline wires along V direction - * @param inputs pyramid model and face index - * @returns Wire shapes - * @group get from face - * @shortname get compound polyline wires v - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/advanced/patterns/pyramid-simple.jpeg - * @drawable true - */ - getPolylineWiresVCompound( - inputs: Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelFaceIndexDto - ): Inputs.OCCT.TopoDSShapePointer; - } - declare class Patterns { - private readonly occWorkerManager; - private readonly context; - private readonly draw; - facePatterns: FacePatterns; - constructor( - occWorkerManager: OCCTWorkerManager, - context: Context, - draw: Draw - ); - } - declare class Text3D { - private readonly occWorkerManager; - private readonly context; - private readonly draw; - constructor( - occWorkerManager: OCCTWorkerManager, - context: Context, - draw: Draw - ); - /** - * Creates a 3d text - * @param inputs - * @returns 3d text - * @group create - * @shortname create 3d text - * @drawable true - */ - create( - inputs: Advanced.Text3D.Text3DDto - ): Promise>; - /** - * Creates a 3d text with a font URL - * This is useful when you want to use a custom font that is not included in the library. - * The font will be loaded from the provided URL and used to generate the 3d text. - * Make sure that fonts do not contain self intersection and other bad characters - that is common issue with custom fonts. - * Font formats supported are: ttf, otf, woff. - * Please note that Woff2 is not supported by opentype.js as it is a compressed format. - * @param inputs - * @returns 3d text - * @group create - * @shortname create 3d text with url - * @drawable true - */ - createWithUrl( - inputs: Advanced.Text3D.Text3DUrlDto - ): Promise>; - /** - * Creates a 3d text on the face - * @param inputs - * @returns 3d text - * @group create - * @shortname create 3d text on face - * @drawable true - */ - createTextOnFace( - inputs: Advanced.Text3D.Text3DFaceDto - ): Promise>; - /** - * Creates a 3d text on the face using a font URL. - * This is useful when you want to use a custom font that is not included in the library. - * The font will be loaded from the provided URL and used to generate the 3d text. - * Make sure that fonts do not contain self intersection and other bad characters - that is common issue with custom fonts. - * Font formats supported are: ttf, otf, woff. - * Please note that Woff2 is not supported by opentype.js as it is a compressed format. - * @param inputs - * @returns 3d text - * @group create - * @shortname create 3d text on face url - * @drawable true - */ - createTextOnFaceUrl( - inputs: Advanced.Text3D.Text3DFaceUrlDto - ): Promise>; - /** - * Creates 3d texts on the face from multiple definitions - * @param inputs - * @returns 3d text - * @group create - * @shortname create 3d texts on face - * @drawable true - */ - createTextsOnFace( - inputs: Advanced.Text3D.Texts3DFaceDto - ): Promise>; - /** - * Creates 3d texts on the face from multiple url definitions - * This is useful when you want to use a custom font that is not included in the library. - * The font will be loaded from the provided URL and used to generate the 3d text. - * Make sure that fonts do not contain self intersection and other bad characters - that is common issue with custom fonts. - * Font formats supported are: ttf, otf, woff. - * Please note that Woff2 is not supported by opentype.js as it is a compressed format. - * @param inputs - * @returns 3d text - * @group create - * @shortname create 3d texts on face url - * @drawable true - */ - createTextsOnFaceUrl( - inputs: Advanced.Text3D.Texts3DFaceUrlDto - ): Promise>; - /** - * Creates 3d text that will be used on the face defintion - * @param inputs - * @returns definition - * @group definitions - * @shortname 3d text face def - * @drawable false - */ - definition3dTextOnFace( - inputs: Advanced.Text3D.Text3DFaceDefinitionDto - ): Advanced.Text3D.Text3DFaceDefinitionDto; - /** - * Creates 3d text that will be used on the face url defintion - * This is useful when you want to use a custom font that is not included in the library. - * The font will be loaded from the provided URL and used to generate the 3d text. - * Make sure that fonts do not contain self intersection and other bad characters - that is common issue with custom fonts. - * Font formats supported are: ttf, otf, woff. - * Please note that Woff2 is not supported by opentype.js as it is a compressed format. - * @param inputs - * @returns definition - * @group definitions - * @shortname 3d text face url def - * @drawable false - */ - definition3dTextOnFaceUrl( - inputs: Advanced.Text3D.Text3DFaceDefinitionUrlDto - ): Advanced.Text3D.Text3DFaceDefinitionUrlDto; - /** - * Draws 3d text on the screen - * @param inputs Contains a model shapes to be drawn and additional information - * @returns BabylonJS Mesh - * @group drawing - * @shortname draw shape - * @drawable false - * @ignore true - */ - drawModel( - inputs: Advanced.Text3D.Text3DData, - precision?: number - ): Promise; - /** - * Gets compounded shape of the 3d text result - * @param inputs - * @returns compounded OCCT shape - * @group get - * @shortname compound shape - * @drawable true - */ - getCompoundShape( - inputs: Advanced.Text3D.Text3DModelDto - ): Inputs.OCCT.TopoDSShapePointer; - /** - * Gets the character shape at particular index - * @param inputs - * @returns character OCCT shape of the 3d text result at index - * @group get - * @shortname character shape - * @drawable true - */ - getCharacterShape( - inputs: Advanced.Text3D.Text3DLetterByIndexDto - ): Inputs.OCCT.TopoDSShapePointer; - /** - * Gets character shapes of the 3d text result - * @param inputs - * @returns character OCCT shapes of the 3d text result - * @group get - * @shortname character shapes - * @drawable true - */ - getCharacterShapes( - inputs: Advanced.Text3D.Text3DModelDto - ): Inputs.OCCT.TopoDSShapePointer[]; - /** - * Gets the center of mass coordinates of all characters - * @param inputs - * @returns character coordinates as points - * @group get - * @shortname character coordinates - * @drawable true - */ - getCharacterCenterCoordinates( - inputs: Advanced.Text3D.Text3DModelDto - ): Inputs.Base.Point3[]; - /** - * Gets the face cutout from text 3d that was created on the face - * @param inputs - * @returns character coordinates as points - * @group get from face - * @shortname face cutout - * @drawable true - */ - getFaceCutout( - inputs: Advanced.Text3D.Text3DModelDto - ): Inputs.OCCT.TopoDSShapePointer; - /** - * Gets all of the face cutouts from text 3d that was created on the original face - * @param inputs - * @returns character coordinates as points - * @group get from face - * @shortname get all coutout faces - * @drawable true - */ - getAllFacesOfCutout( - inputs: Advanced.Text3D.Text3DModelDto - ): Inputs.OCCT.TopoDSShapePointer[]; - /** - * Gets character face cutouts from text 3d that was created on the original face - * @param inputs - * @returns character coordinates as points - * @group get from face - * @shortname get faces in characters - * @drawable true - */ - getCutoutsInsideCharacters( - inputs: Advanced.Text3D.Text3DModelDto - ): Inputs.OCCT.TopoDSShapePointer[]; - /** - * Get advance width - * @param inputs - * @returns width dimension - * @group dimensions - * @shortname get advance width - * @drawable false - */ - getAdvanceWidth( - inputs: Advanced.Text3D.Text3DModelDto - ): number; - } - declare class ContextComplete extends Context { - advancedDynamicTextureForFullscreenUI: GUI.AdvancedDynamicTexture; - pointsOfInterestSystem: { - observer: BABYLON.Observer; - pois: BABYLON.Nullable[]; - cameraManager: CameraManager; - }; - dimensionsSystem: { - dimensionManager: DimensionManager; - }; - } - declare class DrawComplete extends Draw { - /** - * @ignore true - */ - readonly drawHelper: DrawHelper; - /** - * @ignore true - */ - readonly node: BabylonNode; - /** - * @ignore true - */ - readonly tag: Tag; - /** - * @ignore true - */ - private readonly things; - /** - * @ignore true - */ - private readonly advanced; - /** - * @ignore true - */ - readonly context: Context; - constructor( - /** - * @ignore true - */ - drawHelper: DrawHelper, - /** - * @ignore true - */ - node: BabylonNode, - /** - * @ignore true - */ - tag: Tag, - /** - * @ignore true - */ - things: ThingsAdv, - /** - * @ignore true - */ - advanced: AdvancedAdv, - /** - * @ignore true - */ - context: Context - ); - /** - * Draws any kind of geometry after all input promises are resolved. Inputs can also be non-promise like. - * @param inputs Contains options and entities to be drawn - * @returns BabylonJS Mesh Promise - * @group draw - * @shortname draw anything - * @disposableOutput true - */ - drawAnyAsync(inputs: Inputs.Draw.DrawAny): Promise; - /** - * Draws a grid mesh on the ground plane in 3D space. This helps to orient yourself in the world. - * @param inputs Describes various parameters of the grid mesh like size, colour, etc. - * @group draw - * @shortname draw grid - * @disposableOutput true - */ - drawGridMesh(inputs: Inputs.Draw.SceneDrawGridMeshDto): BABYLON.Mesh; - /** - * Creates draw options for basic geometry types like points, lines, polylines, surfaces and jscad meshes - * @param inputs option definition - * @returns options - * @group options - * @shortname simple - */ - optionsSimple( - inputs: Inputs.Draw.DrawBasicGeometryOptions - ): Inputs.Draw.DrawBasicGeometryOptions; - /** - * Creates draw options for occt shape geometry like edges, wires, faces, shells, solids and compounds - * @param inputs option definition - * @returns options - * @group options - * @shortname occt shape - */ - optionsOcctShape( - inputs: Inputs.Draw.DrawOcctShapeOptions - ): Inputs.Draw.DrawOcctShapeOptions; - /** - * Creates draw options for babylon js nodes - * @param inputs option definition - * @returns options - * @group options - * @shortname babylon node - */ - optionsBabylonNode( - inputs: Inputs.Draw.DrawNodeOptions - ): Inputs.Draw.DrawNodeOptions; - } - declare class CreateMaterialDto { - constructor(s: CreateMaterialDto); - name: string; - scene: BABYLON.Scene | undefined; - wAng?: number; - uScale?: number; - vScale?: number; - color?: string; - albedoTextureUrl?: string; - microSurfaceTextureUrl?: string; - bumpTextureUrl?: string; - metallic: number; - roughness: number; - zOffset: number; - } - declare class MaterialsService { - static textures: { - wood1: { - microSurfaceTexture: string; - light: { - albedo: string; - }; - dark: { - albedo: string; - }; - }; - wood2: { - microSurfaceTexture: string; - light: { - albedo: string; - }; - }; - metal1: { - microSurfaceTexture: string; - light: { - albedo: string; - normalGL: string; - roughness: string; - metalness: string; - }; - }; - brownPlanks: { - microSurfaceTexture: string; - light: { - albedo: string; - }; - }; - woodenPlanks: { - microSurfaceTexture: string; - light: { - albedo: string; - }; - }; - brushedConcrete: { - microSurfaceTexture: string; - sand: { - albedo: string; - }; - grey: { - albedo: string; - }; - }; - rock1: { - microSurfaceTexture: string; - default: { - albedo: string; - roughness: string; - }; - }; - }; - static simpleBlackMaterial(scene: any): BABYLON.PBRMaterial; - static rock1Material( - scene: BABYLON.Scene, - wAng: number, - scale: number - ): BABYLON.PBRMaterial; - static wood1Material( - scene: BABYLON.Scene, - wAng: number, - scale: number - ): BABYLON.PBRMaterial; - static wood2Material( - scene: BABYLON.Scene, - wAng: number, - scale: number - ): BABYLON.PBRMaterial; - static wood3Material( - scene: BABYLON.Scene, - wAng: number, - scale: number - ): BABYLON.PBRMaterial; - static brownPlanks( - scene: BABYLON.Scene, - wAng: number, - scale: number - ): BABYLON.PBRMaterial; - static woodenPlanks( - scene: BABYLON.Scene, - wAng: number, - scale: number - ): BABYLON.PBRMaterial; - static glass( - scene: BABYLON.Scene, - albedoColor: string - ): BABYLON.PBRMaterial; - static brushedConcrete( - scene: BABYLON.Scene, - wAng: number, - scale: number - ): BABYLON.PBRMaterial; - static metal1( - scene: BABYLON.Scene, - wAng: number, - scale: number - ): BABYLON.PBRMaterial; - static roughPlastic( - scene: BABYLON.Scene, - color: string - ): BABYLON.PBRMaterial; - private static createMaterial; - private static createTexture; - } - declare class ThreeDPrinting { - private readonly occWorkerManager; - private readonly context; - private readonly draw; - private readonly occt; - vases: Vases; - medals: Medals; - cups: Cups; - desktop: Desktop; - constructor( - occWorkerManager: OCCTWorkerManager, - context: Context, - draw: Draw, - occt: OCCTW - ); - } - declare class Boxes { - private readonly occWorkerManager; - private readonly context; - private readonly draw; - spicyBox: SpicyBox; - constructor( - occWorkerManager: OCCTWorkerManager, - context: Context, - draw: Draw - ); - } - declare class SpicyBox { - private readonly occWorkerManager; - private readonly context; - private readonly draw; - constructor( - occWorkerManager: OCCTWorkerManager, - context: Context, - draw: Draw - ); - /** - * Creates a spicy box model for your spices - * @param inputs - * @returns Spicy box model - * @group create - * @shortname spicy box - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/3dprinting/cups/dragon-cup.jpeg - * @drawable true - */ - create( - inputs: Things.ThreeDPrinting.Boxes.SpicyBox.SpicyBoxDto - ): Promise< - Things.ThreeDPrinting.Boxes.SpicyBox.SpicyBoxData - >; - /** - * Gets the compound shape of the spicy box - * @param inputs - * @returns Compound shape of the spicy box model - * @group get shapes - * @shortname compound - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/3dprinting/cups/dragon-cup.jpeg - * @drawable true - */ - getCompoundShape( - inputs: Things.ThreeDPrinting.Boxes.SpicyBox.SpicyBoxModelDto - ): Inputs.OCCT.TopoDSShapePointer; - /** - * Draws spicy box model in default settings - * @param inputs Contains a model shapes to be drawn and additional information - * @returns BabylonJS Mesh - * @group drawing - * @shortname draw shape - * @drawable false - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/3dprinting/cups/dragon-cup.jpeg - * @ignore true - */ - drawModel( - inputs: Things.ThreeDPrinting.Boxes.SpicyBox.SpicyBoxData - ): Promise; - } - declare class CalmCup { - private readonly occWorkerManager; - private readonly context; - private readonly draw; - private readonly occt; - constructor( - occWorkerManager: OCCTWorkerManager, - context: Context, - draw: Draw, - occt: OCCTW - ); - /** - * Creates a cup model for your calm moments - * @param inputs - * @returns Calm cup model - * @group create - * @shortname calm cup - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/3dprinting/cups/calm-cup.jpeg - * @drawable true - */ - create( - inputs: Things.ThreeDPrinting.Cups.CalmCup.CalmCupDto - ): Promise< - Things.ThreeDPrinting.Cups.CalmCup.CalmCupData - >; - /** - * Draws calm cup model in default settings - * @param inputs Contains a model shapes to be drawn and additional information - * @returns BabylonJS Mesh - * @group drawing - * @shortname draw shape - * @drawable false - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/3dprinting/cups/calm-cup.jpeg - * @ignore true - */ - drawModel( - inputs: Things.ThreeDPrinting.Cups.CalmCup.CalmCupData - ): Promise; - /** - * Disposes a cup model - * @param inputs Contains a model shapes to be disposed and additional information - * @group drawing - * @shortname dispose calm cup - * @drawable false - * @ignore true - */ - dispose( - inputs: Things.ThreeDPrinting.Vases.SerenitySwirl.SerenitySwirlData - ): Promise; - } - declare class Cups { - private readonly occWorkerManager; - private readonly context; - private readonly draw; - private readonly occt; - calmCup: CalmCup; - dragonCup: DragonCup; - constructor( - occWorkerManager: OCCTWorkerManager, - context: Context, - draw: Draw, - occt: OCCTW - ); - } - declare class DragonCup { - private readonly occWorkerManager; - private readonly context; - private readonly draw; - constructor( - occWorkerManager: OCCTWorkerManager, - context: Context, - draw: Draw - ); - /** - * Creates a cup model for your inner dragon - * @param inputs - * @returns Dragon cup model - * @group create - * @shortname dragon cup - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/3dprinting/cups/dragon-cup.jpeg - * @drawable true - */ - create( - inputs: Things.ThreeDPrinting.Cups.DragonCup.DragonCupDto - ): Promise< - Things.ThreeDPrinting.Cups.DragonCup.DragonCupData - >; - /** - * Gets the compound shape of the dragon cup - * @param inputs - * @returns Compound shape of the dragon cup model - * @group get shapes - * @shortname compound - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/3dprinting/cups/dragon-cup.jpeg - * @drawable true - */ - getCompoundShape( - inputs: Things.ThreeDPrinting.Cups.DragonCup.DragonCupModelDto - ): Inputs.OCCT.TopoDSShapePointer; - /** - * Draws dragon cup model in default settings - * @param inputs Contains a model shapes to be drawn and additional information - * @returns BabylonJS Mesh - * @group drawing - * @shortname draw shape - * @drawable false - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/3dprinting/cups/dragon-cup.jpeg - * @ignore true - */ - drawModel( - inputs: Things.ThreeDPrinting.Cups.DragonCup.DragonCupData - ): Promise; - } - declare class Desktop { - private readonly occWorkerManager; - private readonly context; - private readonly draw; - private readonly occt; - phoneNest: PhoneNest; - constructor( - occWorkerManager: OCCTWorkerManager, - context: Context, - draw: Draw, - occt: OCCTW - ); - } - declare class PhoneNest { - private readonly occWorkerManager; - private readonly context; - private readonly draw; - private readonly occt; - private materials; - constructor( - occWorkerManager: OCCTWorkerManager, - context: Context, - draw: Draw, - occt: OCCTW - ); - /** - * Creates a phone nest model - * @param inputs - * @returns phone nest model - * @group create - * @shortname phone nest - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/3dprinting/desktop/phone-nest.jpeg - * @drawable true - */ - create( - inputs: Things.ThreeDPrinting.Desktop.PhoneNest.PhoneNestDto - ): Promise< - Things.ThreeDPrinting.Desktop.PhoneNest.PhoneNestData - >; - /** - * Gets the compound shape of the phone nest - * @param inputs - * @returns Compound shape of the phone nest model - * @group get shapes - * @shortname compound - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/3dprinting/desktop/phone-nest.jpeg - * @drawable true - */ - getCompoundShape( - inputs: Things.ThreeDPrinting.Desktop.PhoneNest.PhoneNestModelDto - ): Inputs.OCCT.TopoDSShapePointer; - /** - * Creates draw options for model - * @param inputs - * @returns Draw options - * @group draw - * @shortname phone nest draw options - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/3dprinting/desktop/phone-nest.jpeg - * @drawable false - */ - drawOptions( - inputs: Things.ThreeDPrinting.Desktop.PhoneNest.PhoneNestDrawDto - ): Things.ThreeDPrinting.Desktop.PhoneNest.PhoneNestDrawDto; - /** - * Draws phone nest model in default settings - * @param model Contains a model shapes to be drawn and additional information - * @returns BabylonJS Mesh - * @group drawing - * @shortname draw shape - * @drawable false - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/3dprinting/desktop/phone-nest.jpeg - * @ignore true - */ - drawModel( - model: Things.ThreeDPrinting.Desktop.PhoneNest.PhoneNestData, - options: Things.ThreeDPrinting.Desktop.PhoneNest.PhoneNestDrawDto - ): Promise; - /** - * Disposes a model - * @param inputs Contains a model shapes to be disposed and additional information - * @group drawing - * @shortname dispose phone nest - * @drawable false - * @ignore true - */ - dispose( - inputs: Things.ThreeDPrinting.Desktop.PhoneNest.PhoneNestData - ): Promise; - /** - * Creates materials - * @param inputs Contains a model shapes to be disposed and additional information - * @group drawing - * @shortname creates default materials - * @drawable false - * @ignore true - */ - private createMaterials; - } - declare class EternalLove { - private readonly occWorkerManager; - private readonly context; - private readonly draw; - private readonly occt; - constructor( - occWorkerManager: OCCTWorkerManager, - context: Context, - draw: Draw, - occt: OCCTW - ); - /** - * Creates a eternal love medal model - * @param inputs - * @returns Eternal love model - * @group create - * @shortname eternal love - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/3dprinting/Medals/EternalLove.jpeg - * @drawable true - */ - create( - inputs: Things.ThreeDPrinting.Medals.EternalLove.EternalLoveDto - ): Promise< - Things.ThreeDPrinting.Medals.EternalLove.EternalLoveData - >; - /** - * Draws wingtip villa in default settings - * @param inputs Contains a model shapes to be drawn and additional information - * @returns BabylonJS Mesh - * @group drawing - * @shortname draw shape - * @drawable false - * @ignore true - */ - drawModel( - inputs: Things.ThreeDPrinting.Medals.EternalLove.EternalLoveData, - precision?: number - ): Promise; - /** - * Disposes a wingtip villa model objects - * @param inputs Contains a model shapes to be disposed and additional information - * @group drawing - * @shortname dispose wingtip villa - * @drawable false - * @ignore true - */ - dispose( - inputs: Things.ThreeDPrinting.Vases.SerenitySwirl.SerenitySwirlData - ): Promise; - } - declare class Medals { - private readonly occWorkerManager; - private readonly context; - private readonly draw; - private readonly occt; - eternalLove: EternalLove; - constructor( - occWorkerManager: OCCTWorkerManager, - context: Context, - draw: Draw, - occt: OCCTW - ); - } - declare class ArabicArchway { - private readonly occWorkerManager; - private readonly context; - private readonly draw; - private readonly occt; - private materials; - constructor( - occWorkerManager: OCCTWorkerManager, - context: Context, - draw: Draw, - occt: OCCTW - ); - /** - * Creates a arabic archway vase - * @param inputs - * @returns Arabic archway mesh - * @group create - * @shortname arabic archway - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/3dprinting/Vases/ArabicArchway.jpeg - * @drawable true - */ - create( - inputs: Things.ThreeDPrinting.Vases.ArabicArchway.ArabicArchwayDto - ): Promise< - Things.ThreeDPrinting.Vases.ArabicArchway.ArabicArchwayData - >; - /** - * Draws arabic archway in default settings - * @param inputs Contains a model shapes to be drawn and additional information - * @returns BabylonJS Mesh - * @group drawing - * @shortname draw shape - * @drawable false - * @ignore true - */ - drawModel( - model: Things.ThreeDPrinting.Vases.ArabicArchway.ArabicArchwayData, - precision?: number - ): Promise; - /** - * Disposes a arabic archway model objects - * @param inputs Contains a model shapes to be disposed and additional information - * @group drawing - * @shortname dispose arabic archway - * @drawable false - * @ignore true - */ - dispose( - inputs: Things.ThreeDPrinting.Vases.ArabicArchway.ArabicArchwayData - ): Promise; - private createMaterials; - private createOpaqueMaterial; - private createBaseMaterial; - private createGlassMaterial; - } - declare class SerenitySwirl { - private readonly occWorkerManager; - private readonly context; - private readonly draw; - private readonly occt; - constructor( - occWorkerManager: OCCTWorkerManager, - context: Context, - draw: Draw, - occt: OCCTW - ); - /** - * Creates a serenity swirl - * @param inputs - * @returns Serenity swirl mesh - * @group create - * @shortname serenity swirl - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/3dprinting/Vases/SerenitySwirl.webp - * @drawable true - */ - create( - inputs: Things.ThreeDPrinting.Vases.SerenitySwirl.SerenitySwirlDto - ): Promise< - Things.ThreeDPrinting.Vases.SerenitySwirl.SerenitySwirlData - >; - /** - * Draws wingtip villa in default settings - * @param inputs Contains a model shapes to be drawn and additional information - * @returns BabylonJS Mesh - * @group drawing - * @shortname draw shape - * @drawable false - * @ignore true - */ - drawModel( - inputs: Things.ThreeDPrinting.Vases.SerenitySwirl.SerenitySwirlData, - precision?: number - ): Promise; - /** - * Disposes a wingtip villa model objects - * @param inputs Contains a model shapes to be disposed and additional information - * @group drawing - * @shortname dispose wingtip villa - * @drawable false - * @ignore true - */ - dispose( - inputs: Things.ThreeDPrinting.Vases.SerenitySwirl.SerenitySwirlData - ): Promise; - } - declare class Vases { - private readonly occWorkerManager; - private readonly context; - private readonly draw; - private readonly occt; - serenitySwirl: SerenitySwirl; - arabicArchway: ArabicArchway; - constructor( - occWorkerManager: OCCTWorkerManager, - context: Context, - draw: Draw, - occt: OCCTW - ); - } - declare class Architecture { - private readonly occWorkerManager; - private readonly context; - private readonly draw; - private readonly occt; - houses: Houses; - constructor( - occWorkerManager: OCCTWorkerManager, - context: Context, - draw: Draw, - occt: OCCTW - ); - } - declare class Houses { - private readonly occWorkerManager; - private readonly context; - private readonly draw; - private readonly occt; - zenHideout: ZenHideout; - constructor( - occWorkerManager: OCCTWorkerManager, - context: Context, - draw: Draw, - occt: OCCTW - ); - } - declare class ZenHideout { - private readonly occWorkerManager; - private readonly context; - private readonly draw; - private readonly occt; - private materials; - skin: Things.Architecture.Houses.ZenHideout.ZenHideoutDrawingPartShapes; - constructor( - occWorkerManager: OCCTWorkerManager, - context: Context, - draw: Draw, - occt: OCCTW - ); - /** - * Creates a zen hideout - * @param inputs - * @returns Zen hideout mesh - * @group create - * @shortname zen hideout - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/architecture/Houses/ZenHideout.jpeg - * @drawable true - */ - create( - inputs: Things.Architecture.Houses.ZenHideout.ZenHideoutDto - ): Promise< - Things.Architecture.Houses.ZenHideout.ZenHideoutData - >; - /** - * Draws wingtip villa in default settings - * @param model Contains a model shapes to be drawn and additional information - * @returns BabylonJS Mesh - * @group drawing - * @shortname draw shape - * @drawable false - * @ignore true - */ - drawModel( - model: Things.Architecture.Houses.ZenHideout.ZenHideoutData, - precision?: number - ): Promise; - /** - * Disposes a zen hideout model objects - * @param inputs Contains a model shapes to be disposed and additional information - * @group drawing - * @shortname dispose zen hideout - * @drawable false - * @ignore true - */ - dispose( - inputs: Things.Architecture.Houses.ZenHideout.ZenHideoutData - ): Promise; - /** - * Creates materials - * @param inputs Contains a model shapes to be disposed and additional information - * @group drawing - * @shortname creates default materials for zen hideout - * @drawable false - * @ignore true - */ - private createMaterials; - private createSkin; - } - declare class Enums { - /** - * Creates a level of detail enumeration value - * @param inputs - * @returns level of detail - * @group enums - * @shortname lod - * @drawable false - */ - lodEnum(inputs: Things.Enums.LodDto): Things.Enums.lodEnum; - } - declare class Chairs { - private readonly occWorkerManager; - private readonly context; - private readonly draw; - private readonly occt; - snakeChair: SnakeChair; - constructor( - occWorkerManager: OCCTWorkerManager, - context: Context, - draw: Draw, - occt: OCCTW - ); - } - declare class SnakeChair { - private readonly occWorkerManager; - private readonly context; - private readonly draw; - private readonly occt; - private materials; - constructor( - occWorkerManager: OCCTWorkerManager, - context: Context, - draw: Draw, - occt: OCCTW - ); - /** - * Creates a snake chair model - * @param inputs - * @returns Snake chair model - * @group create - * @shortname snake chair - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/chairs/snake-chair.jpeg - * @drawable true - */ - create( - inputs: Things.Furniture.Chairs.SnakeChair.SnakeChairDto - ): Promise< - Things.Furniture.Chairs.SnakeChair.SnakeChairData - >; - /** - * Gets the compound shape of the chair - * @param inputs - * @returns Compound shape of the snake chair model - * @group get shapes - * @shortname compound - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/chairs/snake-chair.jpeg - * @drawable true - */ - getCompoundShape( - inputs: Things.Furniture.Chairs.SnakeChair.SnakeChairModelDto - ): Inputs.OCCT.TopoDSShapePointer; - /** - * Gets the wire shape of the chair sitting area - * @param inputs - * @returns Wire shape of the sitting area - * @group get shapes - * @shortname get sitting wire - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/chairs/snake-chair.jpeg - * @drawable true - */ - getSittingWireShape( - inputs: Things.Furniture.Chairs.SnakeChair.SnakeChairModelDto - ): Inputs.OCCT.TopoDSShapePointer; - /** - * Gets the center point of the chair sitting area - * @param inputs - * @returns The point on the center of the sitting area - * @group get points - * @shortname get sitting area center - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/chairs/snake-chair.jpeg - * @drawable true - */ - getSittingAreaCenterPoint( - inputs: Things.Furniture.Chairs.SnakeChair.SnakeChairModelDto - ): Inputs.Base.Point3; - /** - * Creates draw options for snake chair - * @param inputs - * @returns Draw options - * @group draw - * @shortname snake chair draw options - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/chairs/snake-chair.jpeg - * @drawable false - */ - drawOptions( - inputs: Things.Furniture.Chairs.SnakeChair.SnakeChairDrawDto - ): Things.Furniture.Chairs.SnakeChair.SnakeChairDrawDto; - /** - * Draws snake chair model in default settings - * @param model Contains a model shapes to be drawn and additional information - * @returns BabylonJS Mesh - * @group drawing - * @shortname draw shape - * @drawable false - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/chairs/snake-chair.jpeg - * @ignore true - */ - drawModel( - model: Things.Furniture.Chairs.SnakeChair.SnakeChairData, - options: Things.Furniture.Chairs.SnakeChair.SnakeChairDrawDto - ): Promise; - /** - * Disposes a cup model - * @param inputs Contains a model shapes to be disposed and additional information - * @group drawing - * @shortname dispose calm cup - * @drawable false - * @ignore true - */ - dispose( - inputs: Things.Furniture.Chairs.SnakeChair.SnakeChairData - ): Promise; - /** - * Creates materials - * @param inputs Contains a model shapes to be disposed and additional information - * @group drawing - * @shortname creates default materials for zen hideout - * @drawable false - * @ignore true - */ - private createMaterials; - } - declare class Furniture { - private readonly occWorkerManager; - private readonly context; - private readonly draw; - private readonly occt; - chairs: Chairs; - tables: Tables; - constructor( - occWorkerManager: OCCTWorkerManager, - context: Context, - draw: Draw, - occt: OCCTW - ); - } - declare class ElegantTable { - private readonly occWorkerManager; - private readonly context; - private readonly draw; - private readonly occt; - private materials; - constructor( - occWorkerManager: OCCTWorkerManager, - context: Context, - draw: Draw, - occt: OCCTW - ); - /** - * Creates an elegant table model - * @param inputs - * @returns Elegant table model - * @group create - * @shortname elegant table - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/elegant-table.jpeg - * @drawable true - */ - create( - inputs: Things.Furniture.Tables.ElegantTable.ElegantTableDto - ): Promise< - Things.Furniture.Tables.ElegantTable.ElegantTableData - >; - /** - * Gets the compound shape of the table - * @param inputs - * @returns Compound shape of the elegant table model - * @group get shapes - * @shortname compound - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/elegant-table.jpeg - * @drawable true - */ - getCompoundShape( - inputs: Things.Furniture.Tables.ElegantTable.ElegantTableModelDto - ): Inputs.OCCT.TopoDSShapePointer; - /** - * Gets the leg shapes as a list - * @param inputs - * @returns Leg shapes of the table - * @group get shapes - * @shortname legs - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/elegant-table.jpeg - * @drawable true - */ - getLegShapes( - inputs: Things.Furniture.Tables.ElegantTable.ElegantTableModelDto - ): Inputs.OCCT.TopoDSShapePointer[]; - /** - * Gets the leg shape by index - * @param inputs - * @returns Leg shapes of the table - * @group get shapes - * @shortname leg by index - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/elegant-table.jpeg - * @drawable true - */ - getLegShapeByIndex( - inputs: Things.Furniture.Tables.ElegantTable.ElegantTableLegByIndexDto - ): Inputs.OCCT.TopoDSShapePointer; - /** - * Gets the table top panel shape - * @param inputs - * @returns Top panel shape of the table - * @group get shapes - * @shortname top panel - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/elegant-table.jpeg - * @drawable true - */ - getTopPanelShape( - inputs: Things.Furniture.Tables.ElegantTable.ElegantTableModelDto - ): Inputs.OCCT.TopoDSShapePointer; - /** - * Gets the table top panel wire shape - * @param inputs - * @returns Top panel wire shape of the table - * @group get shapes - * @shortname top panel wire - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/elegant-table.jpeg - * @drawable true - */ - getTopPanelWireShape( - inputs: Things.Furniture.Tables.ElegantTable.ElegantTableModelDto - ): Inputs.OCCT.TopoDSShapePointer; - /** - * Gets the table bottom panel wire shape - * @param inputs - * @returns Bottom panel wire shape of the table - * @group get shapes - * @shortname bottom panel wire - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/elegant-table.jpeg - * @drawable true - */ - getBottomPanelWireShape( - inputs: Things.Furniture.Tables.ElegantTable.ElegantTableModelDto - ): Inputs.OCCT.TopoDSShapePointer; - /** - * Gets the table bottom panel shape - * @param inputs - * @returns Bottom panel shape of the table - * @group get shapes - * @shortname bottom panel - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/elegant-table.jpeg - * @drawable true - */ - getBottomPanelShape( - inputs: Things.Furniture.Tables.ElegantTable.ElegantTableModelDto - ): Inputs.OCCT.TopoDSShapePointer; - /** - * Gets the leg shapes as a compound shape - * @param inputs - * @returns Compound shape of the legs - * @group get shapes - * @shortname legs compound - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/elegant-table.jpeg - * @drawable true - */ - getLegsCompoundShape( - inputs: Things.Furniture.Tables.ElegantTable.ElegantTableModelDto - ): Inputs.OCCT.TopoDSShapePointer; - /** - * Gets the top center point - * @param inputs - * @returns Top center point - * @group get points - * @shortname top center point - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/elegant-table.jpeg - * @drawable true - */ - getTableTopCenterPoint( - inputs: Things.Furniture.Tables.ElegantTable.ElegantTableModelDto - ): Inputs.Base.Point3; - /** - * Gets the bottom center point - * @param inputs - * @returns Bottom center point - * @group get points - * @shortname bottom center point - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/elegant-table.jpeg - * @drawable true - */ - getTableBottomCenterPoint( - inputs: Things.Furniture.Tables.ElegantTable.ElegantTableModelDto - ): Inputs.Base.Point3; - /** - * Gets the leg bottom points - * @param inputs - * @returns Bottom points - * @group get points - * @shortname leg bottom points - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/elegant-table.jpeg - * @drawable true - */ - getLegBottomPoints( - inputs: Things.Furniture.Tables.ElegantTable.ElegantTableModelDto - ): Inputs.Base.Point3[]; - /** - * Gets the leg top points - * @param inputs - * @returns Top points - * @group get points - * @shortname leg top points - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/elegant-table.jpeg - * @drawable true - */ - getLegTopPoints( - inputs: Things.Furniture.Tables.ElegantTable.ElegantTableModelDto - ): Inputs.Base.Point3[]; - /** - * Creates draw options for elegant table - * @param inputs - * @returns Draw options - * @group draw - * @shortname elegant table draw options - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/elegant-table.jpeg - * @drawable false - */ - drawOptions( - inputs: Things.Furniture.Tables.ElegantTable.ElegantTableDrawDto - ): Things.Furniture.Tables.ElegantTable.ElegantTableDrawDto; - /** - * Draws elegant table model in default settings - * @param model Contains a model shapes to be drawn and additional information - * @returns BabylonJS Mesh - * @group drawing - * @shortname draw shape - * @drawable false - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/elegant-table.jpeg - * @ignore true - */ - drawModel( - model: Things.Furniture.Tables.ElegantTable.ElegantTableData, - options: Things.Furniture.Tables.ElegantTable.ElegantTableDrawDto - ): Promise; - /** - * Disposes a cup model - * @param inputs Contains a model shapes to be disposed and additional information - * @group drawing - * @shortname dispose calm cup - * @drawable false - * @ignore true - */ - dispose( - inputs: Things.Furniture.Tables.ElegantTable.ElegantTableData - ): Promise; - /** - * Creates materials - * @param inputs Contains a model shapes to be disposed and additional information - * @group drawing - * @shortname creates default materials for zen hideout - * @drawable false - * @ignore true - */ - private createMaterials; - } - declare class GoodCoffeeTable { - private readonly occWorkerManager; - private readonly context; - private readonly draw; - private readonly occt; - private materials; - constructor( - occWorkerManager: OCCTWorkerManager, - context: Context, - draw: Draw, - occt: OCCTW - ); - /** - * Creates an good coffee table model - * @param inputs - * @returns Good coffee table model - * @group create - * @shortname good coffee table - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/good-coffee-table.jpeg - * @drawable true - */ - create( - inputs: Things.Furniture.Tables.GoodCoffeeTable.GoodCoffeeTableDto - ): Promise< - Things.Furniture.Tables.GoodCoffeeTable.GoodCoffeeTableData - >; - /** - * Gets the compound shape of the table - * @param inputs - * @returns Compound shape of the elegant table model - * @group get shapes - * @shortname get compound - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/good-coffee-table.jpeg - * @drawable true - */ - getCompoundShape( - inputs: Things.Furniture.Tables.GoodCoffeeTable.GoodCoffeeTableModelDto - ): Inputs.OCCT.TopoDSShapePointer; - /** - * Gets the leg shapes as a list - * @param inputs - * @returns Leg shapes of the table - * @group get shapes - * @shortname get legs - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/good-coffee-table.jpeg - * @drawable true - */ - getLegShapes( - inputs: Things.Furniture.Tables.GoodCoffeeTable.GoodCoffeeTableModelDto - ): Inputs.OCCT.TopoDSShapePointer[]; - /** - * Gets the leg shape by index - * @param inputs - * @returns Leg shapes of the table - * @group get shapes - * @shortname get leg by index - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/good-coffee-table.jpeg - * @drawable true - */ - getLegShapeByIndex( - inputs: Things.Furniture.Tables.GoodCoffeeTable.GoodCoffeeTableLegByIndexDto - ): Inputs.OCCT.TopoDSShapePointer; - /** - * Gets the table top panel shape - * @param inputs - * @returns Top panel shape of the table - * @group get shapes - * @shortname get top panel - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/good-coffee-table.jpeg - * @drawable true - */ - getTopPanelShape( - inputs: Things.Furniture.Tables.GoodCoffeeTable.GoodCoffeeTableModelDto - ): Inputs.OCCT.TopoDSShapePointer; - /** - * Gets the table top panel wire shape - * @param inputs - * @returns Top panel wire shape of the table - * @group get shapes - * @shortname get top panel wire - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/good-coffee-table.jpeg - * @drawable true - */ - getTopPanelWireShape( - inputs: Things.Furniture.Tables.GoodCoffeeTable.GoodCoffeeTableModelDto - ): Inputs.OCCT.TopoDSShapePointer; - /** - * Gets the table glass panel shape - * @param inputs - * @returns Glass panel shape of the table - * @group get shapes - * @shortname get glass panel - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/good-coffee-table.jpeg - * @drawable true - */ - getGlassPanelShape( - inputs: Things.Furniture.Tables.GoodCoffeeTable.GoodCoffeeTableModelDto - ): Inputs.OCCT.TopoDSShapePointer; - /** - * Gets the table glass panel wire shape - * @param inputs - * @returns Glass panel wire shape of the table - * @group get shapes - * @shortname get glass panel wire - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/good-coffee-table.jpeg - * @drawable true - */ - getGlassPanelWireShape( - inputs: Things.Furniture.Tables.GoodCoffeeTable.GoodCoffeeTableModelDto - ): Inputs.OCCT.TopoDSShapePointer; - /** - * Gets the table shelf shape - * @param inputs - * @returns Shelf shape of the table - * @group get shapes - * @shortname get shelf shape - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/good-coffee-table.jpeg - * @drawable true - */ - getShelfShape( - inputs: Things.Furniture.Tables.GoodCoffeeTable.GoodCoffeeTableModelDto - ): Inputs.OCCT.TopoDSShapePointer; - /** - * Gets the table shelf top wire shape - * @param inputs - * @returns Shelf wire shape of the table - * @group get shapes - * @shortname get shelf top wire - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/good-coffee-table.jpeg - * @drawable true - */ - getShelfTopWireShape( - inputs: Things.Furniture.Tables.GoodCoffeeTable.GoodCoffeeTableModelDto - ): Inputs.OCCT.TopoDSShapePointer; - /** - * Gets the leg shapes as a compound shape - * @param inputs - * @returns Compound shape of the legs - * @group get shapes - * @shortname get legs compound - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/good-coffee-table.jpeg - * @drawable true - */ - getLegsCompoundShape( - inputs: Things.Furniture.Tables.GoodCoffeeTable.GoodCoffeeTableModelDto - ): Inputs.OCCT.TopoDSShapePointer; - /** - * Gets the top center point - * @param inputs - * @returns Top center point - * @group get points - * @shortname get top center point - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/good-coffee-table.jpeg - * @drawable true - */ - getTableTopCenterPoint( - inputs: Things.Furniture.Tables.GoodCoffeeTable.GoodCoffeeTableModelDto - ): Inputs.Base.Point3; - /** - * Gets the top center point of the shelf - * @param inputs - * @returns Top center point of the shelf - * @group get points - * @shortname get top shelf center point - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/good-coffee-table.jpeg - * @drawable true - */ - getTableShelfTopCenterPoint( - inputs: Things.Furniture.Tables.GoodCoffeeTable.GoodCoffeeTableModelDto - ): Inputs.Base.Point3; - /** - * Gets the leg bottom points - * @param inputs - * @returns Bottom points - * @group get points - * @shortname get leg bottom points - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/good-coffee-table.jpeg - * @drawable true - */ - getLegBottomPoints( - inputs: Things.Furniture.Tables.GoodCoffeeTable.GoodCoffeeTableModelDto - ): Inputs.Base.Point3[]; - /** - * Gets the leg top points - * @param inputs - * @returns Top points - * @group get points - * @shortname get leg top points - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/good-coffee-table.jpeg - * @drawable true - */ - getLegTopPoints( - inputs: Things.Furniture.Tables.GoodCoffeeTable.GoodCoffeeTableModelDto - ): Inputs.Base.Point3[]; - /** - * Creates draw options for good coffee table - * @param inputs - * @returns Draw options - * @group draw - * @shortname good coffee table draw options - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/good-coffee-table.jpeg - * @drawable false - */ - drawOptions( - inputs: Things.Furniture.Tables.GoodCoffeeTable.GoodCoffeeTableDrawDto - ): Things.Furniture.Tables.GoodCoffeeTable.GoodCoffeeTableDrawDto; - /** - * Draws good coffee table model in default settings - * @param model Contains a model shapes to be drawn and additional information - * @returns BabylonJS Mesh - * @group drawing - * @shortname get draw shape - * @drawable false - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/good-coffee-table.jpeg - * @ignore true - */ - drawModel( - model: Things.Furniture.Tables.GoodCoffeeTable.GoodCoffeeTableData, - options: Things.Furniture.Tables.GoodCoffeeTable.GoodCoffeeTableDrawDto - ): Promise; - /** - * Disposes a cup model - * @param inputs Contains a model shapes to be disposed and additional information - * @group drawing - * @shortname dispose calm cup - * @drawable false - * @ignore true - */ - dispose( - inputs: Things.Furniture.Tables.GoodCoffeeTable.GoodCoffeeTableData - ): Promise; - /** - * Creates materials - * @param inputs Contains a model shapes to be disposed and additional information - * @group drawing - * @shortname creates default materials for zen hideout - * @drawable false - * @ignore true - */ - private createMaterials; - } - declare class SnakeTable { - private readonly occWorkerManager; - private readonly context; - private readonly draw; - private readonly occt; - private materials; - constructor( - occWorkerManager: OCCTWorkerManager, - context: Context, - draw: Draw, - occt: OCCTW - ); - /** - * Creates a snake table model - * @param inputs - * @returns Snake table model - * @group create - * @shortname snake table - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/snake-table.jpeg - * @drawable true - */ - create( - inputs: Things.Furniture.Tables.SnakeTable.SnakeTableDto - ): Promise< - Things.Furniture.Tables.SnakeTable.SnakeTableData - >; - /** - * Gets the compound shape of the table - * @param inputs - * @returns Compound shape of the snake table model - * @group get shapes - * @shortname get compound - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/snake-table.jpeg - * @drawable true - */ - getCompoundShape( - inputs: Things.Furniture.Tables.SnakeTable.SnakeTableModelDto - ): Inputs.OCCT.TopoDSShapePointer; - /** - * Gets the glass shape of the table - * @param inputs - * @returns The glass shape solid of the table - * @group get shapes - * @shortname get glass - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/snake-table.jpeg - * @drawable true - */ - getGlassShape( - inputs: Things.Furniture.Tables.SnakeTable.SnakeTableModelDto - ): Inputs.OCCT.TopoDSShapePointer; - /** - * Gets the main solid shape of the table - * @param inputs - * @returns The main shape solid of the table - * @group get shapes - * @shortname get main - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/snake-table.jpeg - * @drawable true - */ - getMainShape( - inputs: Things.Furniture.Tables.SnakeTable.SnakeTableModelDto - ): Inputs.OCCT.TopoDSShapePointer; - /** - * Gets the center point of the table top - * @param inputs - * @returns The point on the center of the top area - * @group get points - * @shortname get top center - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/snake-table.jpeg - * @drawable true - */ - getTopCenterPoint( - inputs: Things.Furniture.Tables.SnakeTable.SnakeTableModelDto - ): Inputs.Base.Point3; - /** - * Creates draw options for snake table - * @param inputs - * @returns Draw options - * @group draw - * @shortname snake table draw options - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/snake-table.jpeg - * @drawable false - */ - drawOptions( - inputs: Things.Furniture.Tables.SnakeTable.SnakeTableDrawDto - ): Things.Furniture.Tables.SnakeTable.SnakeTableDrawDto; - /** - * Draws snake table model in default settings - * @param model Contains a model shapes to be drawn and additional information - * @returns BabylonJS Mesh - * @group drawing - * @shortname draw shape - * @drawable false - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/furniture/tables/snake-table.jpeg - * @ignore true - */ - drawModel( - model: Things.Furniture.Tables.SnakeTable.SnakeTableData, - options: Things.Furniture.Tables.SnakeTable.SnakeTableDrawDto - ): Promise; - /** - * Disposes a cup model - * @param inputs Contains a model shapes to be disposed and additional information - * @group drawing - * @shortname dispose calm cup - * @drawable false - * @ignore true - */ - dispose( - inputs: Things.Furniture.Tables.SnakeTable.SnakeTableData - ): Promise; - /** - * Creates materials - * @param inputs Contains a model shapes to be disposed and additional information - * @group drawing - * @shortname creates default materials for zen hideout - * @drawable false - * @ignore true - */ - private createMaterials; - } - declare class Tables { - private readonly occWorkerManager; - private readonly context; - private readonly draw; - private readonly occt; - elegantTable: ElegantTable; - goodCoffeeTable: GoodCoffeeTable; - snakeTable: SnakeTable; - constructor( - occWorkerManager: OCCTWorkerManager, - context: Context, - draw: Draw, - occt: OCCTW - ); - } - declare class Birdhouses { - private readonly occWorkerManager; - private readonly context; - private readonly draw; - private readonly occt; - wingtipVilla: WingtipVilla; - chirpyChalet: ChirpyChalet; - constructor( - occWorkerManager: OCCTWorkerManager, - context: Context, - draw: Draw, - occt: OCCTW - ); - } - declare class ChirpyChalet { - private readonly occWorkerManager; - private readonly context; - private readonly draw; - private readonly occt; - constructor( - occWorkerManager: OCCTWorkerManager, - context: Context, - draw: Draw, - occt: OCCTW - ); - /** - * Disposes a chirpy chalet model objects - * @param inputs Contains a model shapes to be disposed and additional information - * @group drawing - * @shortname dispose chirpy chalet - * @drawable false - * @ignore true - */ - dispose( - inputs: Things.KidsCorner.BirdHouses.ChirpyChalet.ChirpyChaletData - ): Promise; - /** - * Creates a chirpy chalet birdhouse with a 45 degree roof - * @param inputs Contains points and the transformations to apply - * @returns Transformed points - * @group birdhouse - * @shortname chirpy chalet - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/kids/Birdhouses/ChirpyChaletIcon.webp - * @drawable true - */ - create( - inputs: Things.KidsCorner.BirdHouses.ChirpyChalet.ChirpyChaletDto - ): Promise< - Things.KidsCorner.BirdHouses.ChirpyChalet.ChirpyChaletData - >; - /** - * Draws wingtip villa in default settings - * @param inputs Contains a model shapes to be drawn and additional information - * @returns BabylonJS Mesh - * @group drawing - * @shortname draw shape - * @drawable false - * @ignore true - */ - drawModel( - inputs: Things.KidsCorner.BirdHouses.ChirpyChalet.ChirpyChaletData - ): Promise; - } - declare class WingtipVilla { - private readonly occWorkerManager; - private readonly context; - private readonly draw; - private readonly occt; - constructor( - occWorkerManager: OCCTWorkerManager, - context: Context, - draw: Draw, - occt: OCCTW - ); - /** - * Creates a wingtip villa birdhouse with a 45 degree roof - * @param inputs Contains points and the transformations to apply - * @returns Transformed points - * @group birdhouse - * @shortname wingtip villa - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/kids/Birdhouses/WingtipVillaIcon.webp - * @drawable true - */ - create( - inputs: Things.KidsCorner.BirdHouses.WingtipVilla.WingtipVillaDto - ): Promise< - Things.KidsCorner.BirdHouses.WingtipVilla.WingtipVillaData - >; - /** - * Draws wingtip villa in default settings - * @param inputs Contains a model shapes to be drawn and additional information - * @returns BabylonJS Mesh - * @group drawing - * @shortname draw shape - * @drawable false - * @ignore true - */ - drawModel( - inputs: Things.KidsCorner.BirdHouses.WingtipVilla.WingtipVillaData - ): Promise; - /** - * Disposes a wingtip villa model objects - * @param inputs Contains a model shapes to be disposed and additional information - * @group drawing - * @shortname dispose wingtip villa - * @drawable false - * @ignore true - */ - dispose( - inputs: Things.KidsCorner.BirdHouses.WingtipVilla.WingtipVillaData - ): Promise; - } - declare class KidsCorner { - private readonly occWorkerManager; - private readonly context; - private readonly draw; - private readonly occt; - birdhouses: Birdhouses; - constructor( - occWorkerManager: OCCTWorkerManager, - context: Context, - draw: Draw, - occt: OCCTW - ); - } - declare class DropletsPhoneHolder { - private readonly occWorkerManager; - private readonly context; - private readonly draw; - private readonly occt; - private readonly jscad; - private drawOptions; - constructor( - occWorkerManager: OCCTWorkerManager, - context: Context, - draw: Draw, - occt: OCCTW, - jscad: JSCAD - ); - /** - * Creates droplets phone holder - * @param inputs - * @returns Droplets phone holder data - * @group create - * @shortname droplets phone holder - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/laser-cutting/gadgets/DropletsPhoneHolder.jpeg - * @drawable true - */ - create( - inputs: Things.LaserCutting.Gadgets.DropletsPhoneHolder.DropletsPhoneHolderDto - ): Promise< - Things.LaserCutting.Gadgets.DropletsPhoneHolder.DropletsPhoneHolderData - >; - /** - * Gets the compound shape of the droplets phone holder - * @param inputs - * @returns Compound shape of the droplets phone holder model - * @group get shapes - * @shortname compound - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/laser-cutting/gadgets/DropletsPhoneHolder.jpeg - * @drawable true - */ - getCompoundShape( - inputs: Things.LaserCutting.Gadgets.DropletsPhoneHolder.DropletsPhoneHolderModelDto - ): Inputs.OCCT.TopoDSShapePointer; - /** - * Gets the cut wires compound - * @param inputs - * @returns Compound of the cut wires - * @group get shapes - * @shortname cut wires - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/laser-cutting/gadgets/DropletsPhoneHolder.jpeg - * @drawable true - */ - getCutWiresCompound( - inputs: Things.LaserCutting.Gadgets.DropletsPhoneHolder.DropletsPhoneHolderModelDto - ): Inputs.OCCT.TopoDSShapePointer; - /** - * Gets the engraving wires compound - * @param inputs - * @returns Compound of the engraving wires - * @group get shapes - * @shortname engraving wires - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/laser-cutting/gadgets/DropletsPhoneHolder.jpeg - * @drawable true - */ - getEngravingWiresCompound( - inputs: Things.LaserCutting.Gadgets.DropletsPhoneHolder.DropletsPhoneHolderModelDto - ): Inputs.OCCT.TopoDSShapePointer; - /** - * Downloads DXF drawing - * @param inputs - * @returns DXF File - * @group download - * @shortname dxf drawings - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/laser-cutting/gadgets/DropletsPhoneHolder.jpeg - * @drawable false - */ - downloadDXFDrawings( - inputs: Things.LaserCutting.Gadgets.DropletsPhoneHolder.DropletsPhoneHolderModelDxfDto - ): Promise; - /** - * Downloads STEP drawing - * @param inputs - * @returns STEP File - * @group download - * @shortname step drawings - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/laser-cutting/gadgets/DropletsPhoneHolder.jpeg - * @drawable false - */ - downloadSTEPDrawings( - inputs: Things.LaserCutting.Gadgets.DropletsPhoneHolder.DropletsPhoneHolderModelStepDto - ): Promise; - /** - * Downloads STEP 3D model - * @param inputs - * @returns STEP File - * @group download - * @shortname 3d step model - * @image https://ik.imagekit.io/bitbybit/app/assets/spec-cat/things/laser-cutting/gadgets/DropletsPhoneHolder.jpeg - * @drawable false - */ - download3dSTEPModel( - inputs: Things.LaserCutting.Gadgets.DropletsPhoneHolder.DropletsPhoneHolderModelStepDto - ): Promise; - /** - * Draws droplets phone holder in default settings - * @param inputs Contains a model shapes to be drawn and additional information - * @returns BabylonJS Mesh - * @group drawing - * @shortname draw shape - * @drawable false - * @ignore true - */ - drawModel( - model: Things.LaserCutting.Gadgets.DropletsPhoneHolder.DropletsPhoneHolderData, - precision?: number - ): Promise; - /** - * Disposes a droplets phone holder model objects - * @param inputs Contains a model shapes to be disposed and additional information - * @group drawing - * @shortname dispose droplets phone holder - * @drawable false - * @ignore true - */ - dispose( - inputs: Things.LaserCutting.Gadgets.DropletsPhoneHolder.DropletsPhoneHolderData - ): Promise; - private createDrawOptions; - } - declare class Gadgets { - private readonly occWorkerManager; - private readonly context; - private readonly draw; - private readonly occt; - private readonly jscad; - dropletsPhoneHolder: DropletsPhoneHolder; - constructor( - occWorkerManager: OCCTWorkerManager, - context: Context, - draw: Draw, - occt: OCCTW, - jscad: JSCAD - ); - } - declare class LaserCutting { - private readonly occWorkerManager; - private readonly context; - private readonly draw; - private readonly occt; - private readonly jscad; - gadgets: Gadgets; - constructor( - occWorkerManager: OCCTWorkerManager, - context: Context, - draw: Draw, - occt: OCCTW, - jscad: JSCAD - ); - } - declare class ThingsAdv { - private readonly occWorkerManager; - private readonly context; - private readonly draw; - private readonly occt; - private readonly jscad; - kidsCorner: KidsCorner; - threeDPrinting: ThreeDPrinting; - laserCutting: LaserCutting; - architecture: Architecture; - furniture: Furniture; - enums: Enums; - constructor( - occWorkerManager: OCCTWorkerManager, - context: Context, - draw: Draw, - occt: OCCTW, - jscad: JSCAD - ); - } - - declare class BitByBitBase { - readonly draw: Draw; - readonly babylon: Babylon; - readonly vector: Vector; - readonly point: Point; - readonly line: Line; - readonly polyline: Polyline; - readonly mesh: MeshBitByBit; - readonly occt: OCCTW & OCCT; - readonly advanced: AdvancedAdv; - readonly things: ThingsAdv; - readonly jscad: JSCAD; - readonly manifold: ManifoldBitByBit; - readonly logic: Logic; - readonly math: MathBitByBit; - readonly lists: Lists; - readonly color: Color; - readonly text: TextBitByBit; - readonly dates: Dates; - readonly json: JSONBitByBit; - readonly csv: CSVBitByBit; - readonly verb: Verb; - readonly tag: Tag; - readonly time: Time; - readonly asset: Asset; - } - - declare var isRunnerContext: boolean; - declare function mockBitbybitRunnerInputs(inputs: T): T; - declare function getBitbybitRunnerInputs(): T; - declare function setBitbybitRunnerResult(result: T): void; -} +declare namespace Bit{declare namespace Inputs{declare namespace Base{type Color=string;type ColorRGB={r:number;g:number;b:number;};type Point2=[number,number];type Vector2=[number,number];type Point3=[number,number,number];type Vector3=[number,number,number];type Axis3={origin:Base.Point3;direction:Base.Vector3;};type Axis2={origin:Base.Point2;direction:Base.Vector2;};type Segment2=[Point2,Point2];type Segment3=[Point3,Point3];type TrianglePlane3={normal:Vector3;d:number;};type Triangle3=[Base.Point3,Base.Point3,Base.Point3];type Mesh3=Triangle3[];type Plane3={origin:Base.Point3;normal:Base.Vector3;direction:Base.Vector3;};type BoundingBox={min:Base.Point3;max:Base.Point3;center?:Base.Point3;width?:number;height?:number;length?:number;};type Line2={start:Base.Point2;end:Base.Point2;};type Line3={start:Base.Point3;end:Base.Point3;};type Polyline3={points:Base.Point3[];isClosed?:boolean;};type Polyline2={points:Base.Point2[];isClosed?:boolean;};type VerbCurve={tessellate:(options:any)=>any;};type VerbSurface={tessellate:(options:any)=>any;};type TransformMatrix3x3=[number,number,number,number,number,number,number,number,number];type TransformMatrixes3x3=TransformMatrix3x3[];type TransformMatrix=[number,number,number,number,number,number,number,number,number,number,number,number,number,number,number,number];type TransformMatrixes=TransformMatrix[];}declare namespace JSCAD{type JSCADEntity=any;class PolylinePropertiesDto{constructor(points?:Base.Point3[],isClosed?:boolean);points:Base.Point3[];isClosed?:boolean;color?:string|number[];}enum solidCornerTypeEnum{edge="edge",round="round",chamfer="chamfer"}enum jscadTextAlignEnum{left="left",center="center",right="right"}class MeshDto{constructor(mesh?:JSCADEntity);mesh:JSCADEntity;}class MeshesDto{constructor(meshes?:JSCADEntity[]);meshes:JSCADEntity[];}class DrawSolidMeshDto{constructor(mesh?:JSCADEntity,opacity?:number,colours?:string|string[],updatable?:boolean,hidden?:boolean,jscadMesh?:T,drawTwoSided?:boolean,backFaceColour?:string,backFaceOpacity?:number);mesh:JSCADEntity;opacity:number;colours:string|string[];updatable:boolean;hidden:boolean;jscadMesh?:T;drawTwoSided:boolean;backFaceColour:string;backFaceOpacity:number;}class DrawSolidMeshesDto{constructor(meshes?:JSCADEntity[],opacity?:number,colours?:string|string[],updatable?:boolean,hidden?:boolean,jscadMesh?:T,drawTwoSided?:boolean,backFaceColour?:string,backFaceOpacity?:number);meshes:JSCADEntity[];opacity:number;colours:string|string[];updatable:boolean;hidden:boolean;jscadMesh?:T;drawTwoSided:boolean;backFaceColour:string;backFaceOpacity:number;}class DrawPathDto{constructor(path?:JSCADEntity,colour?:string,opacity?:number,width?:number,updatable?:boolean,pathMesh?:T);path:JSCADEntity;colour:string;opacity:number;width:number;updatable:boolean;pathMesh?:T;}class TransformSolidsDto{constructor(meshes?:JSCADEntity[],transformation?:Base.TransformMatrixes);meshes:JSCADEntity[];transformation:Base.TransformMatrixes;}class TransformSolidDto{constructor(mesh?:JSCADEntity,transformation?:Base.TransformMatrixes);mesh:JSCADEntity;transformation:Base.TransformMatrixes;}class DownloadSolidDto{constructor(mesh?:JSCADEntity,fileName?:string);mesh:JSCADEntity;fileName:string;}class DownloadGeometryDto{constructor(geometry?:JSCADEntity|JSCADEntity[],fileName?:string,options?:any);geometry:JSCADEntity|JSCADEntity[];fileName:string;options:any;}class DownloadSolidsDto{constructor(meshes?:JSCADEntity[],fileName?:string);meshes:JSCADEntity[];fileName:string;}class ColorizeDto{constructor(geometry?:JSCADEntity,color?:string);geometry:JSCADEntity|JSCADEntity[];color:string;}class BooleanObjectsDto{constructor(meshes?:JSCADEntity[]);meshes:JSCADEntity[];}class BooleanTwoObjectsDto{constructor(first?:JSCADEntity,second?:JSCADEntity);first:JSCADEntity;second:JSCADEntity;}class BooleanObjectsFromDto{constructor(from?:JSCADEntity,meshes?:JSCADEntity[]);from:JSCADEntity;meshes:JSCADEntity[];}class ExpansionDto{constructor(geometry?:JSCADEntity,delta?:number,corners?:solidCornerTypeEnum,segments?:number);geometry:JSCADEntity;delta:number;corners:solidCornerTypeEnum;segments:number;}class OffsetDto{constructor(geometry?:JSCADEntity,delta?:number,corners?:solidCornerTypeEnum,segments?:number);geometry:JSCADEntity;delta:number;corners:solidCornerTypeEnum;segments:number;}class ExtrudeLinearDto{constructor(geometry?:JSCADEntity,height?:number,twistAngle?:number,twistSteps?:number);geometry:JSCADEntity;height:number;twistAngle:number;twistSteps:number;}class HullDto{constructor(meshes?:JSCADEntity[]);meshes:JSCADEntity[];}class ExtrudeRectangularDto{constructor(geometry?:JSCADEntity,height?:number,size?:number);geometry:JSCADEntity;height:number;size:number;}class ExtrudeRectangularPointsDto{constructor(points?:Base.Point3[],height?:number,size?:number);points:Base.Point3[];height:number;size:number;}class ExtrudeRotateDto{constructor(polygon?:JSCADEntity,angle?:number,startAngle?:number,segments?:number);polygon:JSCADEntity;angle:number;startAngle:number;segments:number;}class PolylineDto{constructor(polyline?:PolylinePropertiesDto);polyline:PolylinePropertiesDto;}class CurveDto{constructor(curve?:any);curve:any;}class PointsDto{constructor(points?:Base.Point3[]);points:Base.Point3[];}class PathDto{constructor(path?:JSCADEntity);path:JSCADEntity;}class PathFromPointsDto{constructor(points?:Base.Point2[],closed?:boolean);points:Base.Point2[];closed:boolean;}class PathsFromPointsDto{constructor(pointsLists?:Base.Point3[][]|Base.Point2[][]);pointsLists:Base.Point3[][]|Base.Point2[][];}class PathFromPolylineDto{constructor(polyline?:PolylinePropertiesDto,closed?:boolean);polyline:PolylinePropertiesDto;closed:boolean;}class PathAppendCurveDto{constructor(curve?:JSCADEntity,path?:JSCADEntity);curve:JSCADEntity;path:JSCADEntity;}class PathAppendPointsDto{constructor(points?:Base.Point2[],path?:JSCADEntity);points:Base.Point2[];path:JSCADEntity;}class PathAppendPolylineDto{constructor(polyline?:PolylinePropertiesDto,path?:JSCADEntity);polyline:PolylinePropertiesDto;path:JSCADEntity;}class PathAppendArcDto{constructor(path?:JSCADEntity,endPoint?:Base.Point2,xAxisRotation?:number,clockwise?:boolean,large?:boolean,segments?:number,radiusX?:number,radiusY?:number);path:JSCADEntity;endPoint:Base.Point2;xAxisRotation:number;clockwise:boolean;large:boolean;segments:number;radiusX:number;radiusY:number;}class CircleDto{constructor(center?:Base.Point2,radius?:number,segments?:number);center:Base.Point2;radius:number;segments:number;}class EllipseDto{constructor(center?:Base.Point2,radius?:Base.Point2,segments?:number);center:Base.Point2;radius:Base.Point2;segments:number;}class SquareDto{constructor(center?:Base.Point2,size?:number);center:Base.Point2;size:number;}class RectangleDto{constructor(center?:Base.Point2,width?:number,length?:number);center:Base.Point2;width:number;length:number;}class RoundedRectangleDto{constructor(center?:Base.Point2,roundRadius?:number,segments?:number,width?:number,length?:number);center:Base.Point2;roundRadius:number;segments:number;width:number;length:number;}class StarDto{constructor(center?:Base.Point2,vertices?:number,density?:number,outerRadius?:number,innerRadius?:number,startAngle?:number);center:Base.Point2;vertices:number;density:number;outerRadius:number;innerRadius:number;startAngle:number;}class CubeDto{constructor(center?:Base.Point3,size?:number);center:Base.Point3;size:number;}class CubeCentersDto{constructor(centers?:Base.Point3[],size?:number);centers:Base.Point3[];size:number;}class CuboidDto{constructor(center?:Base.Point3,width?:number,length?:number,height?:number);center:Base.Point3;width:number;length:number;height:number;}class CuboidCentersDto{constructor(centers?:Base.Point3[],width?:number,length?:number,height?:number);centers:Base.Point3[];width:number;length:number;height:number;}class RoundedCuboidDto{constructor(center?:Base.Point3,roundRadius?:number,width?:number,length?:number,height?:number,segments?:number);center:Base.Point3;roundRadius:number;width:number;length:number;height:number;segments:number;}class RoundedCuboidCentersDto{constructor(centers?:Base.Point3[],roundRadius?:number,width?:number,length?:number,height?:number,segments?:number);centers:Base.Point3[];roundRadius:number;width:number;length:number;height:number;segments:number;}class CylidnerEllipticDto{constructor(center?:Base.Point3,height?:number,startRadius?:Base.Point2,endRadius?:Base.Point2,segments?:number);center:Base.Point3;height:number;startRadius:Base.Vector2;endRadius:Base.Vector2;segments:number;}class CylidnerCentersEllipticDto{constructor(centers?:Base.Point3[],height?:number,startRadius?:Base.Point2,endRadius?:Base.Point2,segments?:number);centers:Base.Point3[];height:number;startRadius:Base.Point2;endRadius:Base.Point2;segments:number;}class CylidnerDto{constructor(center?:Base.Point3,height?:number,radius?:number,segments?:number);center:Base.Point3;height:number;radius:number;segments:number;}class RoundedCylidnerDto{constructor(center?:Base.Point3,roundRadius?:number,height?:number,radius?:number,segments?:number);center:Base.Point3;roundRadius:number;height:number;radius:number;segments:number;}class EllipsoidDto{constructor(center?:Base.Point3,radius?:Base.Point3,segments?:number);center:Base.Point3;radius:Base.Point3;segments:number;}class EllipsoidCentersDto{constructor(centers?:Base.Point3[],radius?:Base.Point3,segments?:number);centers:Base.Point3[];radius:Base.Point3;segments:number;}class GeodesicSphereDto{constructor(center?:Base.Point3,radius?:number,frequency?:number);center:Base.Point3;radius:number;frequency:number;}class GeodesicSphereCentersDto{constructor(centers?:Base.Point3[],radius?:number,frequency?:number);centers:Base.Point3[];radius:number;frequency:number;}class CylidnerCentersDto{constructor(centers?:Base.Point3[],height?:number,radius?:number,segments?:number);centers:Base.Point3[];height:number;radius:number;segments:number;}class RoundedCylidnerCentersDto{constructor(centers?:Base.Point3[],roundRadius?:number,height?:number,radius?:number,segments?:number);centers:Base.Point3[];roundRadius:number;height:number;radius:number;segments:number;}class SphereDto{constructor(center?:Base.Point3,radius?:number,segments?:number);center:Base.Point3;radius:number;segments:number;}class SphereCentersDto{constructor(centers?:Base.Point3[],radius?:number,segments?:number);centers:Base.Point3[];radius:number;segments:number;}class TorusDto{constructor(center?:Base.Point3,innerRadius?:number,outerRadius?:number,innerSegments?:number,outerSegments?:number,innerRotation?:number,outerRotation?:number,startAngle?:number);center:Base.Point3;innerRadius:number;outerRadius:number;innerSegments:number;outerSegments:number;innerRotation:number;outerRotation:number;startAngle:number;}class TextDto{constructor(text?:string,segments?:number,xOffset?:number,yOffset?:number,height?:number,lineSpacing?:number,letterSpacing?:number,align?:jscadTextAlignEnum,extrudeOffset?:number);text:string;segments:number;xOffset:number;yOffset:number;height:number;lineSpacing:number;letterSpacing:number;align:jscadTextAlignEnum;extrudeOffset:number;}class CylinderTextDto{constructor(text?:string,extrusionHeight?:number,extrusionSize?:number,segments?:number,xOffset?:number,yOffset?:number,height?:number,lineSpacing?:number,letterSpacing?:number,align?:jscadTextAlignEnum,extrudeOffset?:number);text:string;extrusionHeight:number;extrusionSize:number;segments:number;xOffset:number;yOffset:number;height:number;lineSpacing:number;letterSpacing:number;align:jscadTextAlignEnum;extrudeOffset:number;}class SphereTextDto{constructor(text?:string,radius?:number,segments?:number,xOffset?:number,yOffset?:number,height?:number,lineSpacing?:number,letterSpacing?:number,align?:jscadTextAlignEnum,extrudeOffset?:number);text:string;radius:number;segments:number;xOffset:number;yOffset:number;height:number;lineSpacing:number;letterSpacing:number;align:jscadTextAlignEnum;extrudeOffset:number;}class FromPolygonPoints{constructor(polygonPoints?:Base.Point3[][]);polygonPoints?:Base.Point3[][];}}declare namespace Base{type Color=string;type ColorRGB={r:number;g:number;b:number;};type Point2=[number,number];type Vector2=[number,number];type Point3=[number,number,number];type Vector3=[number,number,number];type Axis3={origin:Base.Point3;direction:Base.Vector3;};type Axis2={origin:Base.Point2;direction:Base.Vector2;};type Segment2=[Point2,Point2];type Segment3=[Point3,Point3];type TrianglePlane3={normal:Vector3;d:number;};type Triangle3=[Base.Point3,Base.Point3,Base.Point3];type Mesh3=Triangle3[];type Plane3={origin:Base.Point3;normal:Base.Vector3;direction:Base.Vector3;};type BoundingBox={min:Base.Point3;max:Base.Point3;center?:Base.Point3;width?:number;height?:number;length?:number;};type Line2={start:Base.Point2;end:Base.Point2;};type Line3={start:Base.Point3;end:Base.Point3;};type Polyline3={points:Base.Point3[];isClosed?:boolean;};type Polyline2={points:Base.Point2[];isClosed?:boolean;};type VerbCurve={tessellate:(options:any)=>any;};type VerbSurface={tessellate:(options:any)=>any;};type TransformMatrix3x3=[number,number,number,number,number,number,number,number,number];type TransformMatrixes3x3=TransformMatrix3x3[];type TransformMatrix=[number,number,number,number,number,number,number,number,number,number,number,number,number,number,number,number];type TransformMatrixes=TransformMatrix[];}declare namespace Manifold{type ManifoldPointer={hash:number;type:string;};type CrossSectionPointer={hash:number;type:string;};type MeshPointer={hash:number;type:string;};enum fillRuleEnum{evenOdd="EvenOdd",nonZero="NonZero",positive="Positive",negative="Negative"}enum manifoldJoinTypeEnum{square="Square",round="Round",miter="Miter",bevel="Bevel"}class DecomposedManifoldMeshDto{numProp:number;vertProperties:Float32Array;triVerts:Uint32Array;mergeFromVert?:Uint32Array;mergeToVert?:Uint32Array;runIndex?:Uint32Array;runOriginalID?:Uint32Array;runTransform?:Float32Array;faceID?:Uint32Array;halfedgeTangent?:Float32Array;}class DrawManifoldOrCrossSectionDto{constructor(manifoldOrCrossSection?:T,faceOpacity?:number,faceMaterial?:M,faceColour?:Base.Color,crossSectionColour?:Base.Color,crossSectionWidth?:number,crossSectionOpacity?:number,computeNormals?:boolean,drawTwoSided?:boolean,backFaceColour?:Base.Color,backFaceOpacity?:number);manifoldOrCrossSection?:T;faceOpacity:number;faceMaterial?:M;faceColour:Base.Color;crossSectionColour:Base.Color;crossSectionWidth:number;crossSectionOpacity:number;computeNormals:boolean;drawTwoSided:boolean;backFaceColour:Base.Color;backFaceOpacity:number;}class DrawManifoldsOrCrossSectionsDto{constructor(manifoldsOrCrossSections?:T[],faceOpacity?:number,faceMaterial?:M,faceColour?:Base.Color,crossSectionColour?:Base.Color,crossSectionWidth?:number,crossSectionOpacity?:number,computeNormals?:boolean,drawTwoSided?:boolean,backFaceColour?:Base.Color,backFaceOpacity?:number);manifoldsOrCrossSections?:T[];faceMaterial?:M;faceColour:Base.Color;faceOpacity:number;crossSectionColour:Base.Color;crossSectionWidth:number;crossSectionOpacity:number;computeNormals:boolean;drawTwoSided:boolean;backFaceColour:Base.Color;backFaceOpacity:number;}class CreateFromMeshDto{constructor(mesh?:DecomposedManifoldMeshDto);mesh:DecomposedManifoldMeshDto;}class FromPolygonPointsDto{constructor(polygonPoints?:Base.Point3[][]);polygonPoints?:Base.Point3[][];}class CrossSectionFromPolygonPointsDto{constructor(points?:Base.Point3[],fillRule?:fillRuleEnum,removeDuplicates?:boolean,tolerance?:number);points:Base.Point3[];fillRule?:fillRuleEnum;removeDuplicates?:boolean;tolerance?:number;}class CrossSectionFromPolygonsPointsDto{constructor(polygonPoints?:Base.Point3[][],fillRule?:fillRuleEnum,removeDuplicates?:boolean,tolerance?:number);polygonPoints:Base.Point3[][];fillRule?:fillRuleEnum;removeDuplicates?:boolean;tolerance?:number;}class CubeDto{constructor(center?:boolean,size?:number);center:boolean;size:number;}class CreateContourSectionDto{constructor(polygons?:Base.Vector2[][],fillRule?:fillRuleEnum);polygons:Base.Vector2[][];fillRule:fillRuleEnum;}class SquareDto{constructor(center?:boolean,size?:number);center:boolean;size:number;}class SphereDto{constructor(radius?:number,circularSegments?:number);radius:number;circularSegments:number;}class CylinderDto{constructor(height?:number,radiusLow?:number,radiusHigh?:number,circularSegments?:number,center?:boolean);height:number;radiusLow:number;radiusHigh:number;circularSegments:number;center:boolean;}class CircleDto{constructor(radius?:number,circularSegments?:number);radius:number;circularSegments:number;}class RectangleDto{constructor(length?:number,height?:number,center?:boolean);length:number;height:number;center:boolean;}class ManifoldDto{constructor(manifold?:T);manifold:T;}class CalculateNormalsDto{constructor(manifold?:T,normalIdx?:number,minSharpAngle?:number);manifold:T;normalIdx:number;minSharpAngle:number;}class CalculateCurvatureDto{constructor(manifold?:T);manifold:T;gaussianIdx:number;meanIdx:number;}class CountDto{constructor(count?:number);count:number;}class ManifoldsMinGapDto{constructor(manifold1?:T,manifold2?:T,searchLength?:number);manifold1:T;manifold2:T;searchLength:number;}class ManifoldRefineToleranceDto{constructor(manifold?:T,tolerance?:number);manifold:T;tolerance:number;}class ManifoldRefineLengthDto{constructor(manifold?:T,length?:number);manifold:T;length:number;}class ManifoldRefineDto{constructor(manifold?:T,number?:number);manifold:T;number:number;}class ManifoldSmoothByNormalsDto{constructor(manifold?:T,normalIdx?:number);manifold:T;normalIdx:number;}class ManifoldSimplifyDto{constructor(manifold?:T,tolerance?:number);manifold:T;tolerance?:number;}class ManifoldSetPropertiesDto{constructor(manifold?:T,numProp?:number,propFunc?:(newProp:number[],position:Base.Vector3,oldProp:number[])=>void);manifold:T;numProp:number;propFunc:(newProp:number[],position:Base.Vector3,oldProp:number[])=>void;}class ManifoldSmoothOutDto{constructor(manifold?:T,minSharpAngle?:number,minSmoothness?:number);manifold:T;minSharpAngle:number;minSmoothness:number;}class HullPointsDto{constructor(points?:T);points:T;}class SliceDto{constructor(manifold?:T);manifold:T;height:number;}class MeshDto{constructor(mesh?:T);mesh:T;}class MeshVertexIndexDto{constructor(mesh?:T,vertexIndex?:number);mesh:T;vertexIndex:number;}class MeshTriangleRunIndexDto{constructor(mesh?:T,triangleRunIndex?:number);mesh:T;triangleRunIndex:number;}class MeshHalfEdgeIndexDto{constructor(mesh?:T,halfEdgeIndex?:number);mesh:T;halfEdgeIndex:number;}class MeshTriangleIndexDto{constructor(mesh?:T,triangleIndex?:number);mesh:T;triangleIndex:number;}class CrossSectionDto{constructor(crossSection?:T);crossSection:T;}class CrossSectionsDto{constructor(crossSections?:T[]);crossSections:T[];}class ExtrudeDto{constructor(crossSection?:T);crossSection:T;height:number;nDivisions:number;twistDegrees:number;scaleTopX:number;scaleTopY:number;center:boolean;}class RevolveDto{constructor(crossSection?:T,revolveDegrees?:number,matchProfile?:boolean,circularSegments?:number);crossSection:T;revolveDegrees:number;matchProfile:boolean;circularSegments:number;}class OffsetDto{constructor(crossSection?:T,delta?:number,joinType?:manifoldJoinTypeEnum,miterLimit?:number,circularSegments?:number);crossSection:T;delta:number;joinType:manifoldJoinTypeEnum;miterLimit:number;circularSegments:number;}class SimplifyDto{constructor(crossSection?:T,epsilon?:number);crossSection:T;epsilon:number;}class ComposeDto{constructor(polygons?:T);polygons:T;}class MirrorCrossSectionDto{constructor(crossSection?:T,normal?:Base.Vector2);crossSection:T;normal:Base.Vector2;}class Scale2DCrossSectionDto{constructor(crossSection?:T,vector?:Base.Vector2);crossSection:T;vector:Base.Vector2;}class TranslateCrossSectionDto{constructor(crossSection?:T,vector?:Base.Vector2);crossSection:T;vector:Base.Vector2;}class RotateCrossSectionDto{constructor(crossSection?:T,degrees?:number);crossSection:T;degrees:number;}class ScaleCrossSectionDto{constructor(crossSection?:T,factor?:number);crossSection:T;factor:number;}class TranslateXYCrossSectionDto{constructor(crossSection?:T,x?:number,y?:number);crossSection:T;x:number;y:number;}class TransformCrossSectionDto{constructor(crossSection?:T,transform?:Base.TransformMatrix3x3);crossSection:T;transform:Base.TransformMatrix3x3;}class CrossSectionWarpDto{constructor(crossSection?:T,warpFunc?:(vert:Base.Vector2)=>void);crossSection:T;warpFunc:(vert:Base.Vector2)=>void;}class MirrorDto{constructor(manifold?:T,normal?:Base.Vector3);manifold:T;normal:Base.Vector3;}class Scale3DDto{constructor(manifold?:T,vector?:Base.Vector3);manifold:T;vector:Base.Vector3;}class TranslateDto{constructor(manifold?:T,vector?:Base.Vector3);manifold:T;vector:Base.Vector3;}class TranslateByVectorsDto{constructor(manifold?:T,vectors?:Base.Vector3[]);manifold:T;vectors:Base.Vector3[];}class RotateDto{constructor(manifold?:T,vector?:Base.Vector3);manifold:T;vector:Base.Vector3;}class RotateXYZDto{constructor(manifold?:T,x?:number,y?:number,z?:number);manifold:T;x:number;y:number;z:number;}class ScaleDto{constructor(manifold?:T,factor?:number);manifold:T;factor:number;}class TranslateXYZDto{constructor(manifold?:T,x?:number,y?:number,z?:number);manifold:T;x:number;y:number;z:number;}class TransformDto{constructor(manifold?:T,transform?:Base.TransformMatrix);manifold:T;transform:Base.TransformMatrix;}class TransformsDto{constructor(manifold?:T,transforms?:Base.TransformMatrixes);manifold:T;transforms:Base.TransformMatrixes;}class ManifoldWarpDto{constructor(manifold?:T,warpFunc?:(vert:Base.Vector3)=>void);manifold:T;warpFunc:(vert:Base.Vector3)=>void;}class TwoCrossSectionsDto{constructor(crossSection1?:T,crossSection2?:T);crossSection1:T;crossSection2:T;}class TwoManifoldsDto{constructor(manifold1?:T,manifold2?:T);manifold1:T;manifold2:T;}class SplitManifoldsDto{constructor(manifoldToSplit?:T,manifoldCutter?:T);manifoldToSplit:T;manifoldCutter:T;}class TrimByPlaneDto{constructor(manifold?:T,normal?:Base.Vector3,originOffset?:number);manifold:T;normal:Base.Vector3;originOffset:number;}class SplitByPlaneDto{constructor(manifold?:T,normal?:Base.Vector3,originOffset?:number);manifold:T;normal:Base.Vector3;originOffset:number;}class SplitByPlaneOnOffsetsDto{constructor(manifold?:T,normal?:Base.Vector3,originOffsets?:number[]);manifold:T;normal:Base.Vector3;originOffsets:number[];}class ManifoldsDto{constructor(manifolds?:T[]);manifolds:T[];}class ManifoldToMeshDto{constructor(manifold?:T,normalIdx?:number);manifold:T;normalIdx?:number;}class ManifoldsToMeshesDto{constructor(manifolds?:T[],normalIdx?:number[]);manifolds:T[];normalIdx?:number[];}class DecomposeManifoldOrCrossSectionDto{constructor(manifoldOrCrossSection?:T,normalIdx?:number);manifoldOrCrossSection:T;normalIdx?:number;}class ManifoldOrCrossSectionDto{constructor(manifoldOrCrossSection?:T);manifoldOrCrossSection:T;}class ManifoldsOrCrossSectionsDto{constructor(manifoldsOrCrossSections?:T[]);manifoldsOrCrossSections:T[];}class DecomposeManifoldsOrCrossSectionsDto{constructor(manifoldsOrCrossSections?:T[],normalIdx?:number[]);manifoldsOrCrossSections:T[];normalIdx?:number[];}}declare namespace OCCT{type GeomCurvePointer={hash:number;type:string;};type Geom2dCurvePointer={hash:number;type:string;};type GeomSurfacePointer={hash:number;type:string;};type TopoDSVertexPointer={hash:number;type:string;};type TopoDSEdgePointer={hash:number;type:string;};type TopoDSWirePointer={hash:number;type:string;};type TopoDSFacePointer={hash:number;type:string;};type TopoDSShellPointer={hash:number;type:string;};type TopoDSSolidPointer={hash:number;type:string;};type TopoDSCompSolidPointer={hash:number;type:string;};type TopoDSCompoundPointer={hash:number;type:string;};type TopoDSShapePointer=TopoDSVertexPointer|TopoDSEdgePointer|TopoDSWirePointer|TopoDSFacePointer|TopoDSShellPointer|TopoDSSolidPointer|TopoDSCompoundPointer;enum joinTypeEnum{arc="arc",intersection="intersection",tangent="tangent"}enum bRepOffsetModeEnum{skin="skin",pipe="pipe",rectoVerso="rectoVerso"}enum approxParametrizationTypeEnum{approxChordLength="approxChordLength",approxCentripetal="approxCentripetal",approxIsoParametric="approxIsoParametric"}enum directionEnum{outside="outside",inside="inside",middle="middle"}enum fileTypeEnum{iges="iges",step="step"}enum topAbsOrientationEnum{forward="forward",reversed="reversed",internal="internal",external="external"}enum topAbsStateEnum{in="in",out="out",on="on",unknown="unknown"}enum shapeTypeEnum{unknown="unknown",vertex="vertex",edge="edge",wire="wire",face="face",shell="shell",solid="solid",compSolid="compSolid",compound="compound",shape="shape"}enum gccEntPositionEnum{unqualified="unqualified",enclosing="enclosing",enclosed="enclosed",outside="outside",noqualifier="noqualifier"}enum positionResultEnum{keepSide1="keepSide1",keepSide2="keepSide2",all="all"}enum circleInclusionEnum{none="none",keepSide1="keepSide1",keepSide2="keepSide2"}enum twoCircleInclusionEnum{none="none",outside="outside",inside="inside",outsideInside="outsideInside",insideOutside="insideOutside"}enum fourSidesStrictEnum{outside="outside",inside="inside",outsideInside="outsideInside",insideOutside="insideOutside"}enum twoSidesStrictEnum{outside="outside",inside="inside"}enum combinationCirclesForFaceEnum{allWithAll="allWithAll",inOrder="inOrder",inOrderClosed="inOrderClosed"}enum typeSpecificityEnum{curve=0,edge=1,wire=2,face=3}enum pointProjectionTypeEnum{all="all",closest="closest",furthest="furthest",closestAndFurthest="closestAndFurthest"}enum geomFillTrihedronEnum{isCorrectedFrenet="isCorrectedFrenet",isFixed="isFixed",isFrenet="isFrenet",isConstantNormal="isConstantNormal",isDarboux="isDarboux",isGuideAC="isGuideAC",isGuidePlan="isGuidePlan",isGuideACWithContact="isGuideACWithContact",isGuidePlanWithContact="isGuidePlanWithContact",isDiscreteTrihedron="isDiscreteTrihedron"}enum dxfColorFormatEnum{aci="aci",truecolor="truecolor"}enum dxfAcadVersionEnum{AC1009="AC1009",AC1015="AC1015"}enum dimensionEndTypeEnum{none="none",arrow="arrow"}class DecomposedMeshDto{constructor(faceList?:DecomposedFaceDto[],edgeList?:DecomposedEdgeDto[]);faceList:DecomposedFaceDto[];edgeList:DecomposedEdgeDto[];pointsList:Base.Point3[];}class DecomposedFaceDto{face_index:number;normal_coord:number[];number_of_triangles:number;tri_indexes:number[];vertex_coord:number[];vertex_coord_vec:Base.Vector3[];center_point:Base.Point3;center_normal:Base.Vector3;uvs:number[];}class DecomposedEdgeDto{edge_index:number;middle_point:Base.Point3;vertex_coord:Base.Vector3[];}class ShapesDto{constructor(shapes?:T[]);shapes:T[];}class PointDto{constructor(point?:Base.Point3);point:Base.Point3;}class XYZDto{constructor(x?:number,y?:number,z?:number);x:number;y:number;z:number;}class PointsDto{constructor(points?:Base.Point3[]);points:Base.Point3[];}class ConstraintTanLinesFromPtToCircleDto{constructor(circle?:T,point?:Base.Point3,tolerance?:number,positionResult?:positionResultEnum,circleRemainder?:circleInclusionEnum);circle:T;point:Base.Point3;tolerance:number;positionResult:positionResultEnum;circleRemainder:circleInclusionEnum;}class ConstraintTanLinesFromTwoPtsToCircleDto{constructor(circle?:T,point1?:Base.Point3,point2?:Base.Point3,tolerance?:number,positionResult?:positionResultEnum,circleRemainder?:circleInclusionEnum);circle:T;point1:Base.Point3;point2:Base.Point3;tolerance:number;positionResult:positionResultEnum;circleRemainder:circleInclusionEnum;}class ConstraintTanLinesOnTwoCirclesDto{constructor(circle1?:T,circle2?:T,tolerance?:number,positionResult?:positionResultEnum,circleRemainders?:twoCircleInclusionEnum);circle1:T;circle2:T;tolerance:number;positionResult:positionResultEnum;circleRemainders:twoCircleInclusionEnum;}class ConstraintTanCirclesOnTwoCirclesDto{constructor(circle1?:T,circle2?:T,tolerance?:number,radius?:number);circle1:T;circle2:T;tolerance:number;radius:number;}class ConstraintTanCirclesOnCircleAndPntDto{constructor(circle?:T,point?:Base.Point3,tolerance?:number,radius?:number);circle:T;point:Base.Point3;tolerance:number;radius:number;}class CurveAndSurfaceDto{constructor(curve?:T,surface?:U);curve:T;surface:U;}class FilletTwoEdgesInPlaneDto{constructor(edge1?:T,edge2?:T,planeOrigin?:Base.Point3,planeDirection?:Base.Vector3,radius?:number,solution?:number);edge1:T;edge2:T;planeOrigin:Base.Point3;planeDirection:Base.Vector3;radius:number;solution?:number;}class ClosestPointsOnShapeFromPointsDto{constructor(shape?:T,points?:Base.Point3[]);shape:T;points:Base.Point3[];}class BoundingBoxDto{constructor(bbox?:BoundingBoxPropsDto);bbox?:BoundingBoxPropsDto;}class BoundingBoxPropsDto{constructor(min?:Base.Point3,max?:Base.Point3,center?:Base.Point3,size?:Base.Vector3);min:Base.Point3;max:Base.Point3;center:Base.Point3;size:Base.Vector3;}class BoundingSpherePropsDto{constructor(center?:Base.Point3,radius?:number);center:Base.Point3;radius:number;}class SplitWireOnPointsDto{constructor(shape?:T,points?:Base.Point3[]);shape:T;points:Base.Point3[];}class ClosestPointsOnShapesFromPointsDto{constructor(shapes?:T[],points?:Base.Point3[]);shapes:T[];points:Base.Point3[];}class ClosestPointsBetweenTwoShapesDto{constructor(shape1?:T,shape2?:T);shape1:T;shape2:T;}class FaceFromSurfaceAndWireDto{constructor(surface?:T,wire?:U,inside?:boolean);surface:T;wire:U;inside:boolean;}class WireOnFaceDto{constructor(wire?:T,face?:U);wire:T;face:U;}class DrawShapeDto{constructor(shape?:T,faceOpacity?:number,edgeOpacity?:number,edgeColour?:Base.Color,faceMaterial?:Base.Material,faceColour?:Base.Color,edgeWidth?:number,drawEdges?:boolean,drawFaces?:boolean,drawVertices?:boolean,vertexColour?:Base.Color,vertexSize?:number,precision?:number,drawEdgeIndexes?:boolean,edgeIndexHeight?:number,edgeIndexColour?:Base.Color,drawFaceIndexes?:boolean,faceIndexHeight?:number,faceIndexColour?:Base.Color,drawTwoSided?:boolean,backFaceColour?:Base.Color,backFaceOpacity?:number);shape?:T;faceOpacity:number;edgeOpacity:number;edgeColour:Base.Color;faceMaterial?:Base.Material;faceColour:Base.Color;edgeWidth:number;drawEdges:boolean;drawFaces:boolean;drawVertices:boolean;vertexColour:string;vertexSize:number;precision:number;drawEdgeIndexes:boolean;edgeIndexHeight:number;edgeIndexColour:Base.Color;drawFaceIndexes:boolean;faceIndexHeight:number;faceIndexColour:Base.Color;drawTwoSided:boolean;backFaceColour:Base.Color;backFaceOpacity:number;}class DrawShapesDto{constructor(shapes?:T[],faceOpacity?:number,edgeOpacity?:number,edgeColour?:Base.Color,faceMaterial?:Base.Material,faceColour?:Base.Color,edgeWidth?:number,drawEdges?:boolean,drawFaces?:boolean,drawVertices?:boolean,vertexColour?:Base.Color,vertexSize?:number,precision?:number,drawEdgeIndexes?:boolean,edgeIndexHeight?:number,edgeIndexColour?:Base.Color,drawFaceIndexes?:boolean,faceIndexHeight?:number,faceIndexColour?:Base.Color,drawTwoSided?:boolean,backFaceColour?:Base.Color,backFaceOpacity?:number);shapes:T[];faceOpacity:number;edgeOpacity:number;edgeColour:Base.Color;faceMaterial?:Base.Material;faceColour:Base.Color;edgeWidth:number;drawEdges:boolean;drawFaces:boolean;drawVertices:boolean;vertexColour:string;vertexSize:number;precision:number;drawEdgeIndexes:boolean;edgeIndexHeight:number;edgeIndexColour:Base.Color;drawFaceIndexes:boolean;faceIndexHeight:number;faceIndexColour:Base.Color;drawTwoSided:boolean;backFaceColour:Base.Color;backFaceOpacity:number;}class FaceSubdivisionDto{constructor(shape?:T,nrDivisionsU?:number,nrDivisionsV?:number,shiftHalfStepU?:boolean,removeStartEdgeU?:boolean,removeEndEdgeU?:boolean,shiftHalfStepV?:boolean,removeStartEdgeV?:boolean,removeEndEdgeV?:boolean);shape:T;nrDivisionsU:number;nrDivisionsV:number;shiftHalfStepU:boolean;removeStartEdgeU:boolean;removeEndEdgeU:boolean;shiftHalfStepV:boolean;removeStartEdgeV:boolean;removeEndEdgeV:boolean;}class FaceSubdivisionToWiresDto{constructor(shape?:T,nrDivisions?:number,isU?:boolean,shiftHalfStep?:boolean,removeStart?:boolean,removeEnd?:boolean);shape:T;nrDivisions:number;isU:boolean;shiftHalfStep:boolean;removeStart:boolean;removeEnd:boolean;}class FaceSubdivideToRectangleWiresDto{constructor(shape?:T,nrRectanglesU?:number,nrRectanglesV?:number,scalePatternU?:number[],scalePatternV?:number[],filletPattern?:number[],inclusionPattern?:boolean[],offsetFromBorderU?:number,offsetFromBorderV?:number);shape:T;nrRectanglesU:number;nrRectanglesV:number;scalePatternU:number[];scalePatternV:number[];filletPattern:number[];inclusionPattern:boolean[];offsetFromBorderU:number;offsetFromBorderV:number;}class FaceSubdivideToHexagonWiresDto{constructor(shape?:T,nrHexagonsU?:number,nrHexagonsV?:number,flatU?:boolean,scalePatternU?:number[],scalePatternV?:number[],filletPattern?:number[],inclusionPattern?:boolean[],offsetFromBorderU?:number,offsetFromBorderV?:number,extendUUp?:boolean,extendUBottom?:boolean,extendVUp?:boolean,extendVBottom?:boolean);shape?:T;nrHexagonsU?:number;nrHexagonsV?:number;flatU:boolean;scalePatternU?:number[];scalePatternV?:number[];filletPattern?:number[];inclusionPattern?:boolean[];offsetFromBorderU?:number;offsetFromBorderV?:number;extendUUp?:boolean;extendUBottom?:boolean;extendVUp?:boolean;extendVBottom?:boolean;}class FaceSubdivideToHexagonHolesDto{constructor(shape?:T,nrHexagonsU?:number,nrHexagonsV?:number,flatU?:boolean,holesToFaces?:boolean,scalePatternU?:number[],scalePatternV?:number[],filletPattern?:number[],inclusionPattern?:boolean[],offsetFromBorderU?:number,offsetFromBorderV?:number);shape?:T;nrHexagonsU?:number;nrHexagonsV?:number;flatU:boolean;holesToFaces?:boolean;scalePatternU?:number[];scalePatternV?:number[];filletPattern?:number[];inclusionPattern?:boolean[];offsetFromBorderU?:number;offsetFromBorderV?:number;}class FaceSubdivideToRectangleHolesDto{constructor(shape?:T,nrRectanglesU?:number,nrRectanglesV?:number,scalePatternU?:number[],scalePatternV?:number[],filletPattern?:number[],inclusionPattern?:boolean[],holesToFaces?:boolean,offsetFromBorderU?:number,offsetFromBorderV?:number);shape:T;nrRectanglesU:number;nrRectanglesV:number;scalePatternU:number[];scalePatternV:number[];filletPattern:number[];inclusionPattern:boolean[];holesToFaces:boolean;offsetFromBorderU:number;offsetFromBorderV:number;}class FaceSubdivisionControlledDto{constructor(shape?:T,nrDivisionsU?:number,nrDivisionsV?:number,shiftHalfStepNthU?:number,shiftHalfStepUOffsetN?:number,removeStartEdgeNthU?:number,removeStartEdgeUOffsetN?:number,removeEndEdgeNthU?:number,removeEndEdgeUOffsetN?:number,shiftHalfStepNthV?:number,shiftHalfStepVOffsetN?:number,removeStartEdgeNthV?:number,removeStartEdgeVOffsetN?:number,removeEndEdgeNthV?:number,removeEndEdgeVOffsetN?:number);shape:T;nrDivisionsU:number;nrDivisionsV:number;shiftHalfStepNthU:number;shiftHalfStepUOffsetN:number;removeStartEdgeNthU:number;removeStartEdgeUOffsetN:number;removeEndEdgeNthU:number;removeEndEdgeUOffsetN:number;shiftHalfStepNthV:number;shiftHalfStepVOffsetN:number;removeStartEdgeNthV:number;removeStartEdgeVOffsetN:number;removeEndEdgeNthV:number;removeEndEdgeVOffsetN:number;}class FaceLinearSubdivisionDto{constructor(shape?:T,isU?:boolean,param?:number,nrPoints?:number,shiftHalfStep?:boolean,removeStartPoint?:boolean,removeEndPoint?:boolean);shape:T;isU:boolean;param:number;nrPoints:number;shiftHalfStep:boolean;removeStartPoint:boolean;removeEndPoint:boolean;}class WireAlongParamDto{constructor(shape?:T,isU?:boolean,param?:number);shape:T;isU:boolean;param:number;}class WiresAlongParamsDto{constructor(shape?:T,isU?:boolean,params?:number[]);shape:T;isU:boolean;params:number[];}class DataOnUVDto{constructor(shape?:T,paramU?:number,paramV?:number);shape:T;paramU:number;paramV:number;}class DataOnUVsDto{constructor(shape?:T,paramsUV?:[number,number][]);shape:T;paramsUV:[number,number][];}class PolygonDto{constructor(points?:Base.Point3[]);points:Base.Point3[];}class PolygonsDto{constructor(polygons?:PolygonDto[],returnCompound?:boolean);polygons:PolygonDto[];returnCompound:boolean;}class PolylineDto{constructor(points?:Base.Point3[]);points:Base.Point3[];}class PolylineBaseDto{constructor(polyline?:Base.Polyline3);polyline:Base.Polyline3;}class PolylinesBaseDto{constructor(polylines?:Base.Polyline3[]);polylines:Base.Polyline3[];}class LineBaseDto{constructor(line?:Base.Line3);line:Base.Line3;}class LinesBaseDto{constructor(lines?:Base.Line3[]);lines:Base.Line3[];}class SegmentBaseDto{constructor(segment?:Base.Segment3);segment:Base.Segment3;}class SegmentsBaseDto{constructor(segments?:Base.Segment3[]);segments:Base.Segment3[];}class TriangleBaseDto{constructor(triangle?:Base.Triangle3);triangle:Base.Triangle3;}class MeshBaseDto{constructor(mesh?:Base.Mesh3);mesh:Base.Mesh3;}class PolylinesDto{constructor(polylines?:PolylineDto[],returnCompound?:boolean);polylines:PolylineDto[];returnCompound:boolean;}class SquareDto{constructor(size?:number,center?:Base.Point3,direction?:Base.Vector3);size:number;center:Base.Point3;direction:Base.Vector3;}class RectangleDto{constructor(width?:number,length?:number,center?:Base.Point3,direction?:Base.Vector3);width:number;length:number;center:Base.Point3;direction:Base.Vector3;}class LPolygonDto{constructor(widthFirst?:number,lengthFirst?:number,widthSecond?:number,lengthSecond?:number,align?:directionEnum,rotation?:number,center?:Base.Point3,direction?:Base.Vector3);widthFirst:number;lengthFirst:number;widthSecond:number;lengthSecond:number;align:directionEnum;rotation:number;center:Base.Point3;direction:Base.Vector3;}class IBeamProfileDto{constructor(width?:number,height?:number,webThickness?:number,flangeThickness?:number,alignment?:Base.basicAlignmentEnum,rotation?:number,center?:Base.Point3,direction?:Base.Vector3);width:number;height:number;webThickness:number;flangeThickness:number;alignment:Base.basicAlignmentEnum;rotation:number;center:Base.Point3;direction:Base.Vector3;}class HBeamProfileDto{constructor(width?:number,height?:number,webThickness?:number,flangeThickness?:number,alignment?:Base.basicAlignmentEnum,rotation?:number,center?:Base.Point3,direction?:Base.Vector3);width:number;height:number;webThickness:number;flangeThickness:number;alignment:Base.basicAlignmentEnum;rotation:number;center:Base.Point3;direction:Base.Vector3;}class TBeamProfileDto{constructor(width?:number,height?:number,webThickness?:number,flangeThickness?:number,alignment?:Base.basicAlignmentEnum,rotation?:number,center?:Base.Point3,direction?:Base.Vector3);width:number;height:number;webThickness:number;flangeThickness:number;alignment:Base.basicAlignmentEnum;rotation:number;center:Base.Point3;direction:Base.Vector3;}class UBeamProfileDto{constructor(width?:number,height?:number,webThickness?:number,flangeThickness?:number,flangeWidth?:number,alignment?:Base.basicAlignmentEnum,rotation?:number,center?:Base.Point3,direction?:Base.Vector3);width:number;height:number;webThickness:number;flangeThickness:number;flangeWidth:number;alignment:Base.basicAlignmentEnum;rotation:number;center:Base.Point3;direction:Base.Vector3;}class ExtrudedSolidDto{constructor(extrusionLengthFront?:number,extrusionLengthBack?:number,center?:Base.Point3,direction?:Base.Vector3);extrusionLengthFront:number;extrusionLengthBack:number;center:Base.Point3;direction:Base.Vector3;}class IBeamProfileSolidDto extends IBeamProfileDto{constructor(width?:number,height?:number,webThickness?:number,flangeThickness?:number,alignment?:Base.basicAlignmentEnum,rotation?:number,center?:Base.Point3,direction?:Base.Vector3,extrusionLengthFront?:number,extrusionLengthBack?:number);extrusionLengthFront:number;extrusionLengthBack:number;}class HBeamProfileSolidDto extends HBeamProfileDto{constructor(width?:number,height?:number,webThickness?:number,flangeThickness?:number,alignment?:Base.basicAlignmentEnum,rotation?:number,center?:Base.Point3,direction?:Base.Vector3,extrusionLengthFront?:number,extrusionLengthBack?:number);extrusionLengthFront:number;extrusionLengthBack:number;}class TBeamProfileSolidDto extends TBeamProfileDto{constructor(width?:number,height?:number,webThickness?:number,flangeThickness?:number,alignment?:Base.basicAlignmentEnum,rotation?:number,center?:Base.Point3,direction?:Base.Vector3,extrusionLengthFront?:number,extrusionLengthBack?:number);extrusionLengthFront:number;extrusionLengthBack:number;}class UBeamProfileSolidDto extends UBeamProfileDto{constructor(width?:number,height?:number,webThickness?:number,flangeThickness?:number,flangeWidth?:number,alignment?:Base.basicAlignmentEnum,rotation?:number,center?:Base.Point3,direction?:Base.Vector3,extrusionLengthFront?:number,extrusionLengthBack?:number);extrusionLengthFront:number;extrusionLengthBack:number;}class BoxDto{constructor(width?:number,length?:number,height?:number,center?:Base.Point3,originOnCenter?:boolean);width:number;length:number;height:number;center:Base.Point3;originOnCenter?:boolean;}class CubeDto{constructor(size?:number,center?:Base.Point3,originOnCenter?:boolean);size:number;center:Base.Point3;originOnCenter?:boolean;}class BoxFromCornerDto{constructor(width?:number,length?:number,height?:number,corner?:Base.Point3);width:number;length:number;height:number;corner:Base.Point3;}class SphereDto{constructor(radius?:number,center?:Base.Point3);radius:number;center:Base.Point3;}class ConeDto{constructor(radius1?:number,radius2?:number,height?:number,angle?:number,center?:Base.Point3,direction?:Base.Vector3);radius1:number;radius2:number;height:number;angle:number;center:Base.Point3;direction:Base.Point3;}class LineDto{constructor(start?:Base.Point3,end?:Base.Point3);start:Base.Point3;end:Base.Point3;}class LineWithExtensionsDto{constructor(start?:Base.Point3,end?:Base.Point3,extensionStart?:number,extensionEnd?:number);start:Base.Point3;end:Base.Point3;extensionStart:number;extensionEnd:number;}class LinesDto{constructor(lines?:LineDto[],returnCompound?:boolean);lines:LineDto[];returnCompound:boolean;}class ArcEdgeTwoPointsTangentDto{constructor(start?:Base.Point3,tangentVec?:Base.Vector3,end?:Base.Point3);start:Base.Point3;tangentVec:Base.Vector3;end:Base.Point3;}class ArcEdgeCircleTwoPointsDto{constructor(circle?:T,start?:Base.Point3,end?:Base.Point3,sense?:boolean);circle:T;start:Base.Point3;end:Base.Point3;sense:boolean;}class ArcEdgeCircleTwoAnglesDto{constructor(circle?:T,alphaAngle1?:number,alphaAngle2?:number,sense?:boolean);circle:T;alphaAngle1:number;alphaAngle2:number;sense:boolean;}class ArcEdgeCirclePointAngleDto{constructor(circle?:T,alphaAngle?:number,alphaAngle2?:number,sense?:boolean);circle:T;point:Base.Point3;alphaAngle:number;sense:boolean;}class ArcEdgeThreePointsDto{constructor(start?:Base.Point3,middle?:Base.Point3,end?:Base.Point3);start:Base.Point3;middle:Base.Point3;end:Base.Point3;}class CylinderDto{constructor(radius?:number,height?:number,center?:Base.Point3,direction?:Base.Vector3,angle?:number,originOnCenter?:boolean);radius:number;height:number;center:Base.Point3;direction?:Base.Vector3;angle?:number;originOnCenter?:boolean;}class CylindersOnLinesDto{constructor(radius?:number,lines?:Base.Line3[]);radius:number;lines:Base.Line3[];}class FilletDto{constructor(shape?:T,radius?:number,radiusList?:number[],indexes?:number[]);shape:T;radius?:number;radiusList?:number[];indexes?:number[];}class FilletShapesDto{constructor(shapes?:T[],radius?:number,radiusList?:number[],indexes?:number[]);shapes:T[];radius?:number;radiusList?:number[];indexes?:number[];}class FilletEdgesListDto{constructor(shape?:T,edges?:U[],radiusList?:number[]);shape:T;edges:U[];radiusList:number[];}class FilletEdgesListOneRadiusDto{constructor(shape?:T,edges?:U[],radius?:number);shape:T;edges:U[];radius:number;}class FilletEdgeVariableRadiusDto{constructor(shape?:T,edge?:U,radiusList?:number[],paramsU?:number[]);shape:T;edge:U;radiusList:number[];paramsU:number[];}class FilletEdgesVariableRadiusDto{constructor(shape?:T,edges?:U[],radiusLists?:number[][],paramsULists?:number[][]);shape:T;edges:U[];radiusLists:number[][];paramsULists:number[][];}class FilletEdgesSameVariableRadiusDto{constructor(shape?:T,edges?:U[],radiusList?:number[],paramsU?:number[]);shape:T;edges:U[];radiusList:number[];paramsU:number[];}class Fillet3DWiresDto{constructor(shapes?:T[],radius?:number,direction?:Base.Vector3,radiusList?:number[],indexes?:number[]);shapes:T[];radius?:number;radiusList?:number[];indexes?:number[];direction:Base.Vector3;}class Fillet3DWireDto{constructor(shape?:T,radius?:number,direction?:Base.Vector3,radiusList?:number[],indexes?:number[]);shape:T;radius?:number;radiusList?:number[];indexes?:number[];direction:Base.Vector3;}class ChamferDto{constructor(shape?:T,distance?:number,distanceList?:number[],indexes?:number[]);shape:T;distance?:number;distanceList?:number[];indexes?:number[];}class ChamferEdgesListDto{constructor(shape?:T,edges?:U[],distanceList?:number[]);shape:T;edges:U[];distanceList:number[];}class ChamferEdgeDistAngleDto{constructor(shape?:T,edge?:U,face?:F,distance?:number,angle?:number);shape:T;edge:U;face:F;distance:number;angle:number;}class ChamferEdgeTwoDistancesDto{constructor(shape?:T,edge?:U,face?:F,distance1?:number,distance2?:number);shape:T;edge:U;face:F;distance1:number;distance2:number;}class ChamferEdgesTwoDistancesListsDto{constructor(shape?:T,edges?:U[],faces?:F[],distances1?:number[],distances2?:number[]);shape:T;edges:U[];faces:F[];distances1:number[];distances2:number[];}class ChamferEdgesTwoDistancesDto{constructor(shape?:T,edges?:U[],faces?:F[],distance1?:number,distance2?:number);shape:T;edges:U[];faces:F[];distance1:number;distance2:number;}class ChamferEdgesDistsAnglesDto{constructor(shape?:T,edges?:U[],faces?:F[],distances?:number[],angles?:number[]);shape:T;edges:U[];faces:F[];distances:number[];angles:number[];}class ChamferEdgesDistAngleDto{constructor(shape?:T,edges?:U[],faces?:F[],distance?:number,angle?:number);shape:T;edges:U[];faces:F[];distance:number;angle:number;}class BSplineDto{constructor(points?:Base.Point3[],closed?:boolean);points:Base.Point3[];closed:boolean;}class BSplinesDto{constructor(bSplines?:BSplineDto[],returnCompound?:boolean);bSplines:BSplineDto[];returnCompound:boolean;}class WireFromTwoCirclesTanDto{constructor(circle1?:T,circle2?:T,keepLines?:twoSidesStrictEnum,circleRemainders?:fourSidesStrictEnum,tolerance?:number);circle1:T;circle2:T;keepLines:twoSidesStrictEnum;circleRemainders:fourSidesStrictEnum;tolerance:number;}class FaceFromMultipleCircleTanWiresDto{constructor(circles?:T[],combination?:combinationCirclesForFaceEnum,unify?:boolean,tolerance?:number);circles:T[];combination:combinationCirclesForFaceEnum;unify:boolean;tolerance:number;}class FaceFromMultipleCircleTanWireCollectionsDto{constructor(listsOfCircles?:T[][],combination?:combinationCirclesForFaceEnum,unify?:boolean,tolerance?:number);listsOfCircles:T[][];combination:combinationCirclesForFaceEnum;unify:boolean;tolerance:number;}class ZigZagBetweenTwoWiresDto{constructor(wire1?:T,wire2?:T,nrZigZags?:number,inverse?:boolean,divideByEqualDistance?:boolean,zigZagsPerEdge?:boolean);wire1:T;wire2:T;nrZigZags:number;inverse:boolean;divideByEqualDistance:boolean;zigZagsPerEdge:boolean;}class InterpolationDto{constructor(points?:Base.Point3[],periodic?:boolean,tolerance?:number);points:Base.Point3[];periodic:boolean;tolerance:number;}class InterpolateWiresDto{constructor(interpolations?:InterpolationDto[],returnCompound?:boolean);interpolations:InterpolationDto[];returnCompound:boolean;}class BezierDto{constructor(points?:Base.Point3[],closed?:boolean);points:Base.Point3[];closed:boolean;}class BezierWeightsDto{constructor(points?:Base.Point3[],weights?:number[],closed?:boolean);points:Base.Point3[];weights:number[];closed:boolean;}class BezierWiresDto{constructor(bezierWires?:BezierDto[],returnCompound?:boolean);bezierWires:BezierDto[];returnCompound:boolean;}class DivideDto{constructor(shape?:T,nrOfDivisions?:number,removeStartPoint?:boolean,removeEndPoint?:boolean);shape?:T;nrOfDivisions?:number;removeStartPoint?:boolean;removeEndPoint?:boolean;}class ProjectWireDto{constructor(wire?:T,shape?:U,direction?:Base.Vector3);wire:T;shape:U;direction:Base.Vector3;}class ProjectPointsOnShapeDto{constructor(points?:Base.Point3[],shape?:T,direction?:Base.Vector3,projectionType?:pointProjectionTypeEnum);points:Base.Point3[];shape:T;direction:Base.Vector3;projectionType:pointProjectionTypeEnum;}class WiresToPointsDto{constructor(shape?:T,angularDeflection?:number,curvatureDeflection?:number,minimumOfPoints?:number,uTolerance?:number,minimumLength?:number);shape:T;angularDeflection:number;curvatureDeflection:number;minimumOfPoints:number;uTolerance:number;minimumLength:number;}class EdgesToPointsDto{constructor(shape?:T,angularDeflection?:number,curvatureDeflection?:number,minimumOfPoints?:number,uTolerance?:number,minimumLength?:number);shape:T;angularDeflection:number;curvatureDeflection:number;minimumOfPoints:number;uTolerance:number;minimumLength:number;}class ProjectWiresDto{constructor(wires?:T[],shape?:U,direction?:Base.Vector3);wires:T[];shape:U;direction:Base.Vector3;}class DivideShapesDto{constructor(shapes:T[],nrOfDivisions?:number,removeStartPoint?:boolean,removeEndPoint?:boolean);shapes:T[];nrOfDivisions:number;removeStartPoint:boolean;removeEndPoint:boolean;}class DataOnGeometryAtParamDto{constructor(shape:T,param?:number);shape:T;param:number;}class DataOnGeometryesAtParamDto{constructor(shapes:T[],param?:number);shapes:T[];param:number;}class PointInFaceDto{constructor(face:T,edge:T,tEdgeParam?:number,distance2DParam?:number);face:T;edge:T;tEdgeParam:number;distance2DParam:number;}class PointsOnWireAtEqualLengthDto{constructor(shape:T,length?:number,tryNext?:boolean,includeFirst?:boolean,includeLast?:boolean);shape:T;length:number;tryNext:boolean;includeFirst:boolean;includeLast:boolean;}class PointsOnWireAtPatternOfLengthsDto{constructor(shape:T,lengths?:number[],tryNext?:boolean,includeFirst?:boolean,includeLast?:boolean);shape:T;lengths:number[];tryNext:boolean;includeFirst:boolean;includeLast:boolean;}class DataOnGeometryAtLengthDto{constructor(shape:T,length?:number);shape:T;length:number;}class DataOnGeometryesAtLengthDto{constructor(shapes:T[],length?:number);shapes:T[];length:number;}class DataOnGeometryAtLengthsDto{constructor(shape:T,lengths?:number[]);shape:T;lengths:number[];}class CircleDto{constructor(radius?:number,center?:Base.Point3,direction?:Base.Vector3);radius:number;center:Base.Point3;direction:Base.Vector3;}class HexagonsInGridDto{constructor(wdith?:number,height?:number,nrHexagonsInHeight?:number,nrHexagonsInWidth?:number,flatTop?:boolean,extendTop?:boolean,extendBottom?:boolean,extendLeft?:boolean,extendRight?:boolean,scalePatternWidth?:number[],scalePatternHeight?:number[],filletPattern?:number[],inclusionPattern?:boolean[]);width?:number;height?:number;nrHexagonsInWidth?:number;nrHexagonsInHeight?:number;flatTop?:boolean;extendTop?:boolean;extendBottom?:boolean;extendLeft?:boolean;extendRight?:boolean;scalePatternWidth?:number[];scalePatternHeight?:number[];filletPattern?:number[];inclusionPattern?:boolean[];}class LoftDto{constructor(shapes?:T[],makeSolid?:boolean);shapes:T[];makeSolid:boolean;}class LoftAdvancedDto{constructor(shapes?:T[],makeSolid?:boolean,closed?:boolean,periodic?:boolean,straight?:boolean,nrPeriodicSections?:number,useSmoothing?:boolean,maxUDegree?:number,tolerance?:number,parType?:approxParametrizationTypeEnum,startVertex?:Base.Point3,endVertex?:Base.Point3);shapes:T[];makeSolid:boolean;closed:boolean;periodic:boolean;straight:boolean;nrPeriodicSections:number;useSmoothing:boolean;maxUDegree:number;tolerance:number;parType:approxParametrizationTypeEnum;startVertex?:Base.Point3;endVertex?:Base.Point3;}class OffsetDto{constructor(shape?:T,face?:U,distance?:number,tolerance?:number);shape:T;face?:U;distance:number;tolerance:number;}class OffsetAdvancedDto{constructor(shape?:T,face?:U,distance?:number,tolerance?:number,joinType?:joinTypeEnum,removeIntEdges?:boolean);shape:T;face?:U;distance:number;tolerance:number;joinType:joinTypeEnum;removeIntEdges:boolean;}class RevolveDto{constructor(shape?:T,angle?:number,direction?:Base.Vector3,copy?:boolean);shape:T;angle:number;direction:Base.Vector3;copy:boolean;}class ShapeShapesDto{constructor(shape?:T,shapes?:U[]);shape:T;shapes:U[];}class WiresOnFaceDto{constructor(wires?:T[],face?:U);wires:T[];face:U;}class PipeWiresCylindricalDto{constructor(shapes?:T[],radius?:number,makeSolid?:boolean,trihedronEnum?:geomFillTrihedronEnum,forceApproxC1?:boolean);shapes:T[];radius:number;makeSolid:boolean;trihedronEnum:geomFillTrihedronEnum;forceApproxC1:boolean;}class PipeWireCylindricalDto{constructor(shape?:T,radius?:number,makeSolid?:boolean,trihedronEnum?:geomFillTrihedronEnum,forceApproxC1?:boolean);shape:T;radius:number;makeSolid:boolean;trihedronEnum:geomFillTrihedronEnum;forceApproxC1:boolean;}class PipePolygonWireNGonDto{constructor(shapes?:T,radius?:number,nrCorners?:number,makeSolid?:boolean,trihedronEnum?:geomFillTrihedronEnum,forceApproxC1?:boolean);shape:T;radius:number;nrCorners:number;makeSolid:boolean;trihedronEnum:geomFillTrihedronEnum;forceApproxC1:boolean;}class ExtrudeDto{constructor(shape?:T,direction?:Base.Vector3);shape:T;direction:Base.Vector3;}class ExtrudeShapesDto{constructor(shapes?:T[],direction?:Base.Vector3);shapes:T[];direction:Base.Vector3;}class SplitDto{constructor(shape?:T,shapes?:T[]);shape:T;shapes:T[];localFuzzyTolerance:number;nonDestructive:boolean;}class UnionDto{constructor(shapes?:T[],keepEdges?:boolean);shapes:T[];keepEdges:boolean;}class DifferenceDto{constructor(shape?:T,shapes?:T[],keepEdges?:boolean);shape:T;shapes:T[];keepEdges:boolean;}class IntersectionDto{constructor(shapes?:T[],keepEdges?:boolean);shapes:T[];keepEdges:boolean;}class ShapeDto{constructor(shape?:T);shape:T;}class MeshMeshIntersectionTwoShapesDto{constructor(shape1?:T,shape2?:T,precision1?:number,precision2?:number);shape1:T;precision1?:number;shape2:T;precision2?:number;}class MeshMeshesIntersectionOfShapesDto{constructor(shape?:T,shapes?:T[],precision?:number,precisionShapes?:number[]);shape?:T;precision?:number;shapes?:T[];precisionShapes?:number[];}class CompareShapesDto{constructor(shape?:T,otherShape?:T);shape:T;otherShape:T;}class FixSmallEdgesInWireDto{constructor(shape?:T,lockvtx?:boolean,precsmall?:number);shape:T;lockvtx:boolean;precsmall:number;}class BasicShapeRepairDto{constructor(shape?:T,precision?:number,maxTolerance?:number,minTolerance?:number);shape:T;precision:number;maxTolerance:number;minTolerance:number;}class FixClosedDto{constructor(shape?:T,precision?:number);shape:T;precision:number;}class ShapesWithToleranceDto{constructor(shapes?:T[],tolerance?:number);shapes:T[];tolerance:number;}class ShapeWithToleranceDto{constructor(shape?:T,tolerance?:number);shape:T;tolerance:number;}class ShapeIndexDto{constructor(shape?:T,index?:number);shape:T;index:number;}class EdgeIndexDto{constructor(shape?:T,index?:number);shape:T;index:number;}class RotationExtrudeDto{constructor(shape?:T,height?:number,angle?:number,makeSolid?:boolean);shape:T;height:number;angle:number;makeSolid:boolean;}class ThickSolidByJoinDto{constructor(shape?:T,shapes?:T[],offset?:number,tolerance?:number,intersection?:boolean,selfIntersection?:boolean,joinType?:joinTypeEnum,removeIntEdges?:boolean);shape:T;shapes:T[];offset:number;tolerance:number;intersection:boolean;selfIntersection:boolean;joinType:joinTypeEnum;removeIntEdges:boolean;}class TransformDto{constructor(shape?:T,translation?:Base.Vector3,rotationAxis?:Base.Vector3,rotationAngle?:number,scaleFactor?:number);shape:T;translation:Base.Vector3;rotationAxis:Base.Vector3;rotationAngle:number;scaleFactor:number;}class TransformShapesDto{constructor(shapes?:T[],translation?:Base.Vector3[],rotationAxes?:Base.Vector3[],rotationDegrees?:number[],scaleFactors?:number[]);shapes:T[];translations:Base.Vector3[];rotationAxes:Base.Vector3[];rotationAngles:number[];scaleFactors:number[];}class TranslateDto{constructor(shape?:T,translation?:Base.Vector3);shape:T;translation:Base.Vector3;}class TranslateShapesDto{constructor(shapes?:T[],translations?:Base.Vector3[]);shapes:T[];translations:Base.Vector3[];}class AlignNormAndAxisDto{constructor(shape?:T,fromOrigin?:Base.Point3,fromNorm?:Base.Vector3,fromAx?:Base.Vector3,toOrigin?:Base.Point3,toNorm?:Base.Vector3,toAx?:Base.Vector3);shape:T;fromOrigin:Base.Point3;fromNorm:Base.Vector3;fromAx:Base.Vector3;toOrigin:Base.Point3;toNorm:Base.Vector3;toAx:Base.Vector3;}class AlignDto{constructor(shape?:T,fromOrigin?:Base.Point3,fromDirection?:Base.Vector3,toOrigin?:Base.Point3,toDirection?:Base.Vector3);shape:T;fromOrigin:Base.Point3;fromDirection:Base.Vector3;toOrigin:Base.Point3;toDirection:Base.Vector3;}class AlignShapesDto{constructor(shapes?:T[],fromOrigins?:Base.Vector3[],fromDirections?:Base.Vector3[],toOrigins?:Base.Vector3[],toDirections?:Base.Vector3[]);shapes:T[];fromOrigins:Base.Point3[];fromDirections:Base.Vector3[];toOrigins:Base.Point3[];toDirections:Base.Vector3[];}class MirrorDto{constructor(shape?:T,origin?:Base.Point3,direction?:Base.Vector3);shape:T;origin:Base.Point3;direction:Base.Vector3;}class MirrorShapesDto{constructor(shapes?:T[],origins?:Base.Point3[],directions?:Base.Vector3[]);shapes:T[];origins:Base.Point3[];directions:Base.Vector3[];}class MirrorAlongNormalDto{constructor(shape?:T,origin?:Base.Point3,normal?:Base.Vector3);shape:T;origin:Base.Point3;normal:Base.Vector3;}class MirrorAlongNormalShapesDto{constructor(shapes?:T[],origins?:Base.Point3[],normals?:Base.Vector3[]);shapes:T[];origins:Base.Point3[];normals:Base.Vector3[];}class AlignAndTranslateDto{constructor(shape?:T,direction?:Base.Vector3,center?:Base.Vector3);shape:T;direction:Base.Vector3;center:Base.Vector3;}class UnifySameDomainDto{constructor(shape?:T,unifyEdges?:boolean,unifyFaces?:boolean,concatBSplines?:boolean);shape:T;unifyEdges:boolean;unifyFaces:boolean;concatBSplines:boolean;}class FilterFacesPointsDto{constructor(shapes?:T[],points?:Base.Point3[],tolerance?:number,useBndBox?:boolean,gapTolerance?:number,keepIn?:boolean,keepOn?:boolean,keepOut?:boolean,keepUnknown?:boolean,flatPointsArray?:boolean);shapes:T[];points:Base.Point3[];tolerance:number;useBndBox:boolean;gapTolerance:number;keepIn:boolean;keepOn:boolean;keepOut:boolean;keepUnknown:boolean;flatPointsArray:boolean;}class FilterFacePointsDto{constructor(shape?:T,points?:Base.Point3[],tolerance?:number,useBndBox?:boolean,gapTolerance?:number,keepIn?:boolean,keepOn?:boolean,keepOut?:boolean,keepUnknown?:boolean);shape:T;points:Base.Point3[];tolerance:number;useBndBox:boolean;gapTolerance:number;keepIn:boolean;keepOn:boolean;keepOut:boolean;keepUnknown:boolean;}class FilterSolidPointsDto{constructor(shape?:T,points?:Base.Point3[],tolerance?:number,keepIn?:boolean,keepOn?:boolean,keepOut?:boolean,keepUnknown?:boolean);shape:T;points:Base.Point3[];tolerance:number;keepIn:boolean;keepOn:boolean;keepOut:boolean;keepUnknown:boolean;}class AlignAndTranslateShapesDto{constructor(shapes?:T[],directions?:Base.Vector3[],centers?:Base.Vector3[]);shapes:T[];directions:Base.Vector3[];centers:Base.Vector3[];}class RotateDto{constructor(shape?:T,axis?:Base.Vector3,angle?:number);shape:T;axis:Base.Vector3;angle:number;}class RotateAroundCenterDto{constructor(shape?:T,angle?:number,center?:Base.Point3,axis?:Base.Vector3);shape:T;angle:number;center:Base.Point3;axis:Base.Vector3;}class RotateShapesDto{constructor(shapes?:T[],axes?:Base.Vector3[],angles?:number[]);shapes:T[];axes:Base.Vector3[];angles:number[];}class RotateAroundCenterShapesDto{constructor(shapes?:T[],angles?:number[],centers?:Base.Point3[],axes?:Base.Vector3[]);shapes:T[];angles:number[];centers:Base.Point3[];axes:Base.Vector3[];}class ScaleDto{constructor(shape?:T,factor?:number);shape:T;factor:number;}class ScaleShapesDto{constructor(shapes?:T[],factors?:number[]);shapes:T[];factors:number[];}class Scale3DDto{constructor(shape?:T,scale?:Base.Vector3,center?:Base.Point3);shape:T;scale:Base.Vector3;center:Base.Point3;}class Scale3DShapesDto{constructor(shapes?:T[],scales?:Base.Vector3[],centers?:Base.Point3[]);shapes:T[];scales:Base.Vector3[];centers:Base.Point3[];}class ShapeToMeshDto{constructor(shape?:T,precision?:number,adjustYtoZ?:boolean);shape:T;precision:number;adjustYtoZ:boolean;}class ShapeFacesToPolygonPointsDto{constructor(shape?:T,precision?:number,adjustYtoZ?:boolean,reversedPoints?:boolean);shape:T;precision:number;adjustYtoZ:boolean;reversedPoints:boolean;}class ShapesToMeshesDto{constructor(shapes?:T[],precision?:number,adjustYtoZ?:boolean);shapes:T[];precision:number;adjustYtoZ:boolean;}class SaveStepDto{constructor(shape?:T,fileName?:string,adjustYtoZ?:boolean,tryDownload?:boolean);shape:T;fileName:string;adjustYtoZ:boolean;fromRightHanded?:boolean;tryDownload?:boolean;}class SaveStlDto{constructor(shape?:T,fileName?:string,precision?:number,adjustYtoZ?:boolean,tryDownload?:boolean,binary?:boolean);shape:T;fileName:string;precision:number;adjustYtoZ:boolean;tryDownload?:boolean;binary?:boolean;}class ShapeToDxfPathsDto{constructor(shape?:T,angularDeflection?:number,curvatureDeflection?:number,minimumOfPoints?:number,uTolerance?:number,minimumLength?:number);shape:T;angularDeflection:number;curvatureDeflection:number;minimumOfPoints:number;uTolerance:number;minimumLength:number;}class DxfPathsWithLayerDto{constructor(paths?:IO.DxfPathDto[],layer?:string,color?:Base.Color);paths:IO.DxfPathDto[];layer:string;color:Base.Color;}class DxfPathsPartsListDto{constructor(pathsParts?:IO.DxfPathsPartDto[],colorFormat?:dxfColorFormatEnum,acadVersion?:dxfAcadVersionEnum,tryDownload?:boolean);pathsParts:IO.DxfPathsPartDto[];colorFormat:dxfColorFormatEnum;acadVersion:dxfAcadVersionEnum;fileName?:string;tryDownload?:boolean;}class SaveDxfDto{constructor(shape?:T,fileName?:string,tryDownload?:boolean,angularDeflection?:number,curvatureDeflection?:number,minimumOfPoints?:number,uTolerance?:number,minimumLength?:number);shape:T;fileName:string;tryDownload?:boolean;angularDeflection:number;curvatureDeflection:number;minimumOfPoints:number;uTolerance:number;minimumLength:number;}class ImportStepIgesFromTextDto{constructor(text?:string,fileType?:fileTypeEnum,adjustZtoY?:boolean);text:string;fileType:fileTypeEnum;adjustZtoY:boolean;}class ImportStepIgesDto{constructor(assetFile?:File,adjustZtoY?:boolean);assetFile:File;adjustZtoY:boolean;}class LoadStepOrIgesDto{constructor(filetext?:string|ArrayBuffer,fileName?:string,adjustZtoY?:boolean);filetext:string|ArrayBuffer;fileName:string;adjustZtoY:boolean;}class CompoundShapesDto{constructor(shapes?:T[]);shapes:T[];}class ThisckSolidSimpleDto{constructor(shape?:T,offset?:number);shape:T;offset:number;}class Offset3DWireDto{constructor(shape?:T,offset?:number,direction?:Base.Vector3);shape:T;offset:number;direction:Base.Vector3;}class FaceFromWireDto{constructor(shape?:T,planar?:boolean);shape:T;planar:boolean;}class FaceFromWireOnFaceDto{constructor(wire?:T,face?:U,inside?:boolean);wire:T;face:U;inside:boolean;}class FacesFromWiresOnFaceDto{constructor(wires?:T[],face?:U,inside?:boolean);wires:T[];face:U;inside:boolean;}class FaceFromWiresDto{constructor(shapes?:T[],planar?:boolean);shapes:T[];planar:boolean;}class FacesFromWiresDto{constructor(shapes?:T[],planar?:boolean);shapes:T[];planar:boolean;}class FaceFromWiresOnFaceDto{constructor(wires?:T[],face?:U,inside?:boolean);wires:T[];face:U;inside:boolean;}class SewDto{constructor(shapes?:T[],tolerance?:number);shapes:T[];tolerance:number;}class FaceIsoCurveAtParamDto{constructor(shape?:T,param?:number,dir?:"u"|"v");shape:T;param:number;dir:"u"|"v";}class DivideFaceToUVPointsDto{constructor(shape?:T,nrOfPointsU?:number,nrOfPointsV?:number,flat?:boolean);shape:T;nrOfPointsU:number;nrOfPointsV:number;flat:boolean;}class Geom2dEllipseDto{constructor(center?:Base.Point2,direction?:Base.Vector2,radiusMinor?:number,radiusMajor?:number,sense?:boolean);center:Base.Point2;direction:Base.Vector2;radiusMinor:number;radiusMajor:number;sense:boolean;}class Geom2dCircleDto{constructor(center?:Base.Point2,direction?:Base.Vector2,radius?:number,sense?:boolean);center:Base.Point2;direction:Base.Vector2;radius:number;sense:boolean;}class ChristmasTreeDto{constructor(height?:number,innerDist?:number,outerDist?:number,nrSkirts?:number,trunkHeight?:number,trunkWidth?:number,half?:boolean,rotation?:number,origin?:Base.Point3,direction?:Base.Vector3);height:number;innerDist:number;outerDist:number;nrSkirts:number;trunkHeight:number;trunkWidth:number;half:boolean;rotation:number;origin:Base.Point3;direction:Base.Vector3;}class StarDto{constructor(outerRadius?:number,innerRadius?:number,numRays?:number,center?:Base.Point3,direction?:Base.Vector3,offsetOuterEdges?:number,half?:boolean);center:Base.Point3;direction:Base.Vector3;numRays:number;outerRadius:number;innerRadius:number;offsetOuterEdges?:number;half:boolean;}class ParallelogramDto{constructor(center?:Base.Point3,direction?:Base.Vector3,aroundCenter?:boolean,width?:number,height?:number,angle?:number);center:Base.Point3;direction:Base.Vector3;aroundCenter:boolean;width:number;height:number;angle:number;}class Heart2DDto{constructor(center?:Base.Point3,direction?:Base.Vector3,rotation?:number,sizeApprox?:number);center:Base.Point3;direction:Base.Vector3;rotation:number;sizeApprox:number;}class NGonWireDto{constructor(center?:Base.Point3,direction?:Base.Vector3,nrCorners?:number,radius?:number);center:Base.Point3;direction:Base.Vector3;nrCorners:number;radius:number;}class EllipseDto{constructor(center?:Base.Point3,direction?:Base.Vector3,radiusMinor?:number,radiusMajor?:number);center:Base.Point3;direction:Base.Vector3;radiusMinor:number;radiusMajor:number;}class TextWiresDto{constructor(text?:string,xOffset?:number,yOffset?:number,height?:number,lineSpacing?:number,letterSpacing?:number,align?:Base.horizontalAlignEnum,extrudeOffset?:number,origin?:Base.Point3,rotation?:number,direction?:Base.Vector3,centerOnOrigin?:boolean);text?:string;xOffset?:number;yOffset?:number;height?:number;lineSpacing?:number;letterSpacing?:number;align?:Base.horizontalAlignEnum;extrudeOffset?:number;centerOnOrigin:boolean;}class GeomCylindricalSurfaceDto{constructor(radius?:number,center?:Base.Point3,direction?:Base.Vector3);radius:number;center:Base.Point3;direction:Base.Vector3;}class Geom2dTrimmedCurveDto{constructor(shape?:T,u1?:number,u2?:number,sense?:boolean,adjustPeriodic?:boolean);shape:T;u1:number;u2:number;sense:boolean;adjustPeriodic:boolean;}class Geom2dSegmentDto{constructor(start?:Base.Point2,end?:Base.Point2);start:Base.Point2;end:Base.Point2;}class SliceDto{constructor(shape?:T,step?:number,direction?:Base.Vector3);shape:T;step:number;direction:Base.Vector3;}class SliceInStepPatternDto{constructor(shape?:T,steps?:number[],direction?:Base.Vector3);shape:T;steps:number[];direction:Base.Vector3;}class SimpleLinearLengthDimensionDto{constructor(start?:Base.Point3,end?:Base.Point3,direction?:Base.Vector3,offsetFromPoints?:number,crossingSize?:number,labelSuffix?:string,labelSize?:number,labelOffset?:number,labelRotation?:number,arrowType?:dimensionEndTypeEnum,arrowSize?:number,arrowAngle?:number,arrowsFlipped?:boolean,labelFlipHorizontal?:boolean,labelFlipVertical?:boolean,labelOverwrite?:string,removeTrailingZeros?:boolean);start:Base.Point3;end?:Base.Point3;direction?:Base.Vector3;offsetFromPoints?:number;crossingSize?:number;decimalPlaces?:number;labelSuffix?:string;labelSize?:number;labelOffset?:number;labelRotation?:number;endType?:dimensionEndTypeEnum;arrowSize?:number;arrowAngle?:number;arrowsFlipped?:boolean;labelFlipHorizontal?:boolean;labelFlipVertical?:boolean;labelOverwrite?:string;removeTrailingZeros?:boolean;}class SimpleAngularDimensionDto{constructor(direction1?:Base.Point3,direction2?:Base.Point3,center?:Base.Point3,radius?:number,offsetFromCenter?:number,crossingSize?:number,radians?:boolean,labelSuffix?:string,labelSize?:number,labelOffset?:number,endType?:dimensionEndTypeEnum,arrowSize?:number,arrowAngle?:number,arrowsFlipped?:boolean,labelRotation?:number,labelFlipHorizontal?:boolean,labelFlipVertical?:boolean,labelOverwrite?:string,removeTrailingZeros?:boolean);direction1:Base.Point3;direction2:Base.Point3;center:Base.Point3;radius:number;offsetFromCenter:number;extraSize:number;decimalPlaces:number;labelSuffix:string;labelSize:number;labelOffset:number;radians:boolean;endType?:dimensionEndTypeEnum;arrowSize?:number;arrowAngle?:number;arrowsFlipped?:boolean;labelRotation?:number;labelFlipHorizontal?:boolean;labelFlipVertical?:boolean;labelOverwrite?:string;removeTrailingZeros?:boolean;}class PinWithLabelDto{constructor(startPoint?:Base.Point3,endPoint?:Base.Point3,direction?:Base.Vector3,offsetFromStart?:number,label?:string,labelOffset?:number,labelSize?:number,endType?:dimensionEndTypeEnum,arrowSize?:number,arrowAngle?:number,arrowsFlipped?:boolean,labelRotation?:number,labelFlipHorizontal?:boolean,labelFlipVertical?:boolean);startPoint:Base.Point3;endPoint?:Base.Point3;direction?:Base.Vector3;offsetFromStart?:number;label?:string;labelOffset?:number;labelSize?:number;endType?:dimensionEndTypeEnum;arrowSize?:number;arrowAngle?:number;arrowsFlipped?:boolean;labelRotation?:number;labelFlipHorizontal?:boolean;labelFlipVertical?:boolean;}class StarSolidDto extends StarDto{constructor(outerRadius?:number,innerRadius?:number,numRays?:number,center?:Base.Point3,direction?:Base.Vector3,offsetOuterEdges?:number,half?:boolean,extrusionLengthFront?:number,extrusionLengthBack?:number);extrusionLengthFront:number;extrusionLengthBack:number;}class NGonSolidDto extends NGonWireDto{constructor(center?:Base.Point3,direction?:Base.Vector3,nrCorners?:number,radius?:number,extrusionLengthFront?:number,extrusionLengthBack?:number);extrusionLengthFront:number;extrusionLengthBack:number;}class ParallelogramSolidDto extends ParallelogramDto{constructor(center?:Base.Point3,direction?:Base.Vector3,aroundCenter?:boolean,width?:number,height?:number,angle?:number,extrusionLengthFront?:number,extrusionLengthBack?:number);extrusionLengthFront:number;extrusionLengthBack:number;}class HeartSolidDto extends Heart2DDto{constructor(center?:Base.Point3,direction?:Base.Vector3,rotation?:number,sizeApprox?:number,extrusionLengthFront?:number,extrusionLengthBack?:number);extrusionLengthFront:number;extrusionLengthBack:number;}class ChristmasTreeSolidDto extends ChristmasTreeDto{constructor(height?:number,innerDist?:number,outerDist?:number,nrSkirts?:number,trunkHeight?:number,trunkWidth?:number,half?:boolean,rotation?:number,origin?:Base.Point3,direction?:Base.Vector3,extrusionLengthFront?:number,extrusionLengthBack?:number);extrusionLengthFront:number;extrusionLengthBack:number;}class LPolygonSolidDto extends LPolygonDto{constructor(widthFirst?:number,lengthFirst?:number,widthSecond?:number,lengthSecond?:number,align?:directionEnum,rotation?:number,center?:Base.Point3,direction?:Base.Vector3,extrusionLengthFront?:number,extrusionLengthBack?:number);extrusionLengthFront:number;extrusionLengthBack:number;}}declare namespace Base{enum colorMapStrategyEnum{firstColorForAll="firstColorForAll",lastColorRemainder="lastColorRemainder",repeatColors="repeatColors",reversedColors="reversedColors"}type Color=string;type ColorRGB={r:number;g:number;b:number;};type Material=any;type Texture=any;type Point2=[number,number];type Vector2=[number,number];type Point3=[number,number,number];type Vector3=[number,number,number];type Axis3={origin:Base.Point3;direction:Base.Vector3;};type Axis2={origin:Base.Point2;direction:Base.Vector2;};type Segment2=[Point2,Point2];type Segment3=[Point3,Point3];type TrianglePlane3={normal:Vector3;d:number;};type Triangle3=[Base.Point3,Base.Point3,Base.Point3];type Mesh3=Triangle3[];type Plane3={origin:Base.Point3;normal:Base.Vector3;direction:Base.Vector3;};type BoundingBox={min:Base.Point3;max:Base.Point3;center?:Base.Point3;width?:number;height?:number;length?:number;};type Line2={start:Base.Point2;end:Base.Point2;};type Line3={start:Base.Point3;end:Base.Point3;};type Polyline3={points:Base.Point3[];isClosed?:boolean;color?:number[];};type Polyline2={points:Base.Point2[];isClosed?:boolean;color?:number[];};type VerbCurve={tessellate:(options:any)=>any;};type VerbSurface={tessellate:(options:any)=>any;};type TransformMatrix3x3=[number,number,number,number,number,number,number,number,number];type TransformMatrixes3x3=TransformMatrix3x3[];type TransformMatrix=[number,number,number,number,number,number,number,number,number,number,number,number,number,number,number,number];type TransformMatrixes=TransformMatrix[];}declare namespace Draw{type DrawOptions=DrawOcctShapeOptions|DrawBasicGeometryOptions|DrawManifoldOrCrossSectionOptions;type Entity=Base.Point3|Base.Vector3|Base.Line3|Base.Polyline3|Base.VerbCurve|Base.VerbSurface|Inputs.OCCT.TopoDSShapePointer|Inputs.Tag.TagDto|Base.Point3[]|Base.Vector3[]|Base.Line3[]|Base.Polyline3[]|Base.VerbCurve[]|Base.VerbSurface[]|Inputs.OCCT.TopoDSShapePointer[]|Inputs.Tag.TagDto[];class DrawAny{constructor(entity?:Entity,options?:DrawOptions);entity:Entity;options?:DrawOptions;group?:U;}class DrawManifoldOrCrossSectionOptions{constructor(faceOpacity?:number,faceMaterial?:Base.Material,faceColour?:Base.Color,crossSectionColour?:Base.Color,crossSectionWidth?:number,crossSectionOpacity?:number,computeNormals?:boolean,drawTwoSided?:boolean,backFaceColour?:Base.Color,backFaceOpacity?:number);faceOpacity:number;faceColour:Base.Color;faceMaterial?:Base.Material;crossSectionColour:Base.Color;crossSectionWidth:number;crossSectionOpacity:number;computeNormals:boolean;drawTwoSided:boolean;backFaceColour:Base.Color;backFaceOpacity:number;}class DrawOcctShapeOptions{constructor(faceOpacity?:number,edgeOpacity?:number,edgeColour?:Base.Color,faceMaterial?:Base.Material,faceColour?:Base.Color,edgeWidth?:number,drawEdges?:boolean,drawFaces?:boolean,drawVertices?:boolean,vertexColour?:Base.Color,vertexSize?:number,precision?:number,drawEdgeIndexes?:boolean,edgeIndexHeight?:number,edgeIndexColour?:Base.Color,drawFaceIndexes?:boolean,faceIndexHeight?:number,faceIndexColour?:Base.Color,drawTwoSided?:boolean,backFaceColour?:Base.Color,backFaceOpacity?:number,edgeArrowSize?:number,edgeArrowAngle?:number);faceOpacity:number;edgeOpacity:number;edgeColour:Base.Color;faceColour:Base.Color;vertexColour:Base.Color;faceMaterial?:Base.Material;edgeWidth:number;vertexSize:number;drawEdges:boolean;drawFaces:boolean;drawVertices:boolean;precision:number;drawEdgeIndexes:boolean;edgeIndexHeight:number;edgeIndexColour:Base.Color;drawFaceIndexes:boolean;faceIndexHeight:number;faceIndexColour:Base.Color;drawTwoSided:boolean;backFaceColour:Base.Color;backFaceOpacity:number;edgeArrowSize:number;edgeArrowAngle:number;}class DrawBasicGeometryOptions{constructor(colours?:string|string[],size?:number,opacity?:number,updatable?:boolean,hidden?:boolean,drawTwoSided?:boolean,backFaceColour?:Base.Color,backFaceOpacity?:number,colorMapStrategy?:Base.colorMapStrategyEnum,arrowSize?:number,arrowAngle?:number);colours:string|string[];colorMapStrategy:Base.colorMapStrategyEnum;size:number;opacity:number;updatable:boolean;hidden:boolean;drawTwoSided:boolean;backFaceColour:Base.Color;backFaceOpacity:number;arrowSize:number;arrowAngle:number;}enum samplingModeEnum{nearest="nearest",bilinear="bilinear",trilinear="trilinear"}class GenericTextureDto{constructor(url?:string,name?:string,uScale?:number,vScale?:number,uOffset?:number,vOffset?:number,wAng?:number,invertY?:boolean,invertZ?:boolean,samplingMode?:samplingModeEnum);url:string;name:string;uScale:number;vScale:number;uOffset:number;vOffset:number;wAng:number;invertY:boolean;invertZ:boolean;samplingMode:samplingModeEnum;}enum alphaModeEnum{opaque="opaque",mask="mask",blend="blend"}class GenericPBRMaterialDto{constructor(name?:string,baseColor?:Base.Color,metallic?:number,roughness?:number,alpha?:number,emissiveColor?:Base.Color,emissiveIntensity?:number,zOffset?:number,zOffsetUnits?:number,baseColorTexture?:Base.Texture,metallicRoughnessTexture?:Base.Texture,normalTexture?:Base.Texture,emissiveTexture?:Base.Texture,occlusionTexture?:Base.Texture,alphaMode?:alphaModeEnum,alphaCutoff?:number,doubleSided?:boolean,wireframe?:boolean,unlit?:boolean);name:string;baseColor:Base.Color;metallic:number;roughness:number;alpha:number;emissiveColor?:Base.Color;emissiveIntensity:number;zOffset:number;zOffsetUnits:number;baseColorTexture?:Base.Texture;metallicRoughnessTexture?:Base.Texture;normalTexture?:Base.Texture;emissiveTexture?:Base.Texture;occlusionTexture?:Base.Texture;alphaMode:alphaModeEnum;alphaCutoff:number;doubleSided:boolean;wireframe:boolean;unlit:boolean;}enum drawingTypes{point=0,points=1,line=2,lines=3,node=4,nodes=5,polyline=6,polylines=7,verbCurve=8,verbCurves=9,verbSurface=10,verbSurfaces=11,jscadMesh=12,jscadMeshes=13,occt=14,occtShapes=15,tag=16,tags=17}}declare namespace Base{type Color=string;type ColorRGB={r:number;g:number;b:number;};type Material=any;type Point2=[number,number];type Vector2=[number,number];type Point3=[number,number,number];type Vector3=[number,number,number];type Axis3={origin:Base.Point3;direction:Base.Vector3;};type Axis2={origin:Base.Point2;direction:Base.Vector2;};type Segment2=[Point2,Point2];type Segment3=[Point3,Point3];type TrianglePlane3={normal:Vector3;d:number;};type Triangle3=[Base.Point3,Base.Point3,Base.Point3];type Mesh3=Triangle3[];type Plane3={origin:Base.Point3;normal:Base.Vector3;direction:Base.Vector3;};type BoundingBox={min:Base.Point3;max:Base.Point3;center?:Base.Point3;width?:number;height?:number;length?:number;};type Line2={start:Base.Point2;end:Base.Point2;};type Line3={start:Base.Point3;end:Base.Point3;};type Polyline3={points:Base.Point3[];isClosed?:boolean;color?:number[];};type Polyline2={points:Base.Point2[];isClosed?:boolean;color?:number[];};type TransformMatrix3x3=[number,number,number,number,number,number,number,number,number];type TransformMatrixes3x3=TransformMatrix3x3[];type TransformMatrix=[number,number,number,number,number,number,number,number,number,number,number,number,number,number,number,number];type TransformMatrixes=TransformMatrix[];enum horizontalAlignEnum{left="left",center="center",right="right"}enum verticalAlignmentEnum{top="top",middle="middle",bottom="bottom"}enum topBottomEnum{top="top",bottom="bottom"}enum basicAlignmentEnum{topLeft="topLeft",topMid="topMid",topRight="topRight",midLeft="midLeft",midMid="midMid",midRight="midRight",bottomLeft="bottomLeft",bottomMid="bottomMid",bottomRight="bottomRight"}}declare namespace Color{class HexDto{constructor(color?:Base.Color);color:Base.Color;}class InvertHexDto{constructor(color?:Base.Color);color:Base.Color;blackAndWhite:boolean;}class HexDtoMapped{constructor(color?:Base.Color,from?:number,to?:number);color:Base.Color;from:number;to:number;}class RGBObjectMaxDto{constructor(rgb?:Base.ColorRGB,max?:number);rgb:Base.ColorRGB;min:number;max:number;}class RGBMinMaxDto{constructor(r?:number,g?:number,b?:number,min?:number,max?:number);r:number;g:number;b:number;min:number;max:number;}class RGBObjectDto{constructor(rgb?:Base.ColorRGB);rgb:Base.ColorRGB;}}declare namespace Dates{class DateDto{constructor(date?:Date);date:Date;}class DateStringDto{constructor(dateString?:string);dateString:string;}class DateSecondsDto{constructor(date?:Date,seconds?:number);date:Date;seconds:number;}class DateDayDto{constructor(date?:Date,day?:number);date:Date;day:number;}class DateYearDto{constructor(date?:Date,year?:number);date:Date;year:number;}class DateMonthDto{constructor(date?:Date,month?:number);date:Date;month:number;}class DateHoursDto{constructor(date?:Date,hours?:number);date:Date;hours:number;}class DateMinutesDto{constructor(date?:Date,minutes?:number);date:Date;minutes:number;}class DateMillisecondsDto{constructor(date?:Date,milliseconds?:number);date:Date;milliseconds:number;}class DateTimeDto{constructor(date?:Date,time?:number);date:Date;time:number;}class CreateFromUnixTimeStampDto{constructor(unixTimeStamp?:number);unixTimeStamp:number;}class CreateDateDto{constructor(year?:number,month?:number,day?:number,hours?:number,minutes?:number,seconds?:number,milliseconds?:number);year:number;month:number;day:number;hours:number;minutes:number;seconds:number;milliseconds:number;}}declare namespace IO{class DxfLineSegmentDto{constructor(start?:Base.Point2,end?:Base.Point2);start:Base.Point2;end:Base.Point2;}class DxfArcSegmentDto{constructor(center?:Base.Point2,radius?:number,startAngle?:number,endAngle?:number);center:Base.Point2;radius:number;startAngle:number;endAngle:number;}class DxfCircleSegmentDto{constructor(center?:Base.Point2,radius?:number);center:Base.Point2;radius:number;}class DxfPolylineSegmentDto{constructor(points?:Base.Point2[],closed?:boolean,bulges?:number[]);points:Base.Point2[];closed?:boolean;bulges?:number[];}class DxfSplineSegmentDto{constructor(controlPoints?:Base.Point2[],degree?:number,closed?:boolean);controlPoints:Base.Point2[];degree?:number;closed?:boolean;}class DxfPathDto{constructor(segments?:(DxfLineSegmentDto|DxfArcSegmentDto|DxfCircleSegmentDto|DxfPolylineSegmentDto|DxfSplineSegmentDto)[]);segments:(DxfLineSegmentDto|DxfArcSegmentDto|DxfCircleSegmentDto|DxfPolylineSegmentDto|DxfSplineSegmentDto)[];}class DxfPathsPartDto{constructor(layer?:string,color?:Base.Color,paths?:DxfPathDto[]);layer:string;color:Base.Color;paths:DxfPathDto[];}class DxfModelDto{constructor(dxfPathsParts?:DxfPathsPartDto[],colorFormat?:"aci"|"truecolor",acadVersion?:"AC1009"|"AC1015");dxfPathsParts:DxfPathsPartDto[];colorFormat?:"aci"|"truecolor";acadVersion?:"AC1009"|"AC1015";}}declare namespace Line{class LinePointsDto{constructor(start?:Base.Point3,end?:Base.Point3);start?:Base.Point3;end?:Base.Point3;}class LineStartEndPointsDto{constructor(startPoints?:Base.Point3[],endPoints?:Base.Point3[]);startPoints:Base.Point3[];endPoints:Base.Point3[];}class DrawLineDto{constructor(line?:LinePointsDto,opacity?:number,colours?:string|string[],size?:number,updatable?:boolean,lineMesh?:T);line?:LinePointsDto;opacity?:number;colours?:string|string[];size?:number;updatable?:boolean;lineMesh?:T;}class DrawLinesDto{constructor(lines?:LinePointsDto[],opacity?:number,colours?:string|string[],size?:number,updatable?:boolean,linesMesh?:T);lines?:LinePointsDto[];opacity?:number;colours?:string|string[];size?:number;updatable?:boolean;linesMesh?:T;}class PointsLinesDto{constructor(points?:Base.Point3[]);points?:Base.Point3[];}class LineDto{constructor(line?:LinePointsDto);line?:LinePointsDto;}class SegmentDto{constructor(segment?:Base.Segment3);segment?:Base.Segment3;}class SegmentsDto{constructor(segments?:Base.Segment3[]);segments?:Base.Segment3[];}class LinesDto{constructor(lines?:LinePointsDto[]);lines?:LinePointsDto[];}class LineLineIntersectionDto{constructor(line1?:LinePointsDto,line2?:LinePointsDto,tolerance?:number);line1?:LinePointsDto;line2?:LinePointsDto;checkSegmentsOnly?:boolean;tolerance?:number;}class PointOnLineDto{constructor(line?:LinePointsDto,param?:number);line?:LinePointsDto;param?:number;}class TransformLineDto{constructor(line?:LinePointsDto,transformation?:Base.TransformMatrixes);line?:LinePointsDto;transformation?:Base.TransformMatrixes;}class TransformsLinesDto{constructor(lines?:LinePointsDto[],transformation?:Base.TransformMatrixes[]);lines?:LinePointsDto[];transformation?:Base.TransformMatrixes[];}class TransformLinesDto{constructor(lines?:LinePointsDto[],transformation?:Base.TransformMatrixes);lines?:LinePointsDto[];transformation?:Base.TransformMatrixes;}}declare namespace Lists{enum firstLastEnum{first="first",last="last"}class ListItemDto{constructor(list?:T[],index?:number,clone?:boolean);list:T[];index:number;clone?:boolean;}class SubListDto{constructor(list?:T[],indexStart?:number,indexEnd?:number,clone?:boolean);list:T[];indexStart:number;indexEnd:number;clone?:boolean;}class ListCloneDto{constructor(list?:T[],clone?:boolean);list:T[];clone?:boolean;}class RepeatInPatternDto{constructor(list?:T[]);list:T[];clone?:boolean;lengthLimit:number;}class SortDto{constructor(list?:T[],clone?:boolean,orderAsc?:boolean);list:T[];clone?:boolean;orderAsc:boolean;}class SortJsonDto{constructor(list?:T[],clone?:boolean,orderAsc?:boolean);list:T[];clone?:boolean;orderAsc:boolean;property:string;}class ListDto{constructor(list?:T[]);list:T[];}class GroupListDto{constructor(list?:T[],nrElements?:number,keepRemainder?:boolean);list:T[];nrElements:number;keepRemainder:boolean;}class MultiplyItemDto{constructor(item?:T,times?:number);item:T;times:number;}class AddItemAtIndexDto{constructor(list?:T[],item?:T,index?:number,clone?:boolean);list:T[];item:T;index:number;clone?:boolean;}class AddItemAtIndexesDto{constructor(list?:T[],item?:T,indexes?:number[],clone?:boolean);list:T[];item:T;indexes:number[];clone?:boolean;}class AddItemsAtIndexesDto{constructor(list?:T[],items?:T[],indexes?:number[],clone?:boolean);list:T[];items:T[];indexes:number[];clone?:boolean;}class RemoveItemAtIndexDto{constructor(list?:T[],index?:number,clone?:boolean);list:T[];index:number;clone?:boolean;}class RemoveItemsAtIndexesDto{constructor(list?:T[],indexes?:number[],clone?:boolean);list:T[];indexes:number[];clone?:boolean;}class RemoveNthItemDto{constructor(list?:T[],nth?:number,offset?:number,clone?:boolean);list:T[];nth:number;offset:number;clone?:boolean;}class RandomThresholdDto{constructor(list?:T[],threshold?:number,clone?:boolean);list:T[];threshold:number;clone?:boolean;}class RemoveDuplicatesDto{constructor(list?:T[],clone?:boolean);list:T[];clone?:boolean;}class RemoveDuplicatesToleranceDto{constructor(list?:T[],clone?:boolean,tolerance?:number);list:T[];tolerance:number;clone?:boolean;}class GetByPatternDto{constructor(list?:T[],pattern?:boolean[]);list:T[];pattern:boolean[];}class GetNthItemDto{constructor(list?:T[],nth?:number,offset?:number,clone?:boolean);list:T[];nth:number;offset:number;clone?:boolean;}class GetLongestListLength{constructor(lists?:T[]);lists:T[];}class MergeElementsOfLists{constructor(lists?:T[],level?:number);lists:T[];level:number;}class AddItemDto{constructor(list?:T[],item?:T,clone?:boolean);list:T[];item:T;clone?:boolean;}class AddItemFirstLastDto{constructor(list?:T[],item?:T,position?:firstLastEnum,clone?:boolean);list:T[];item:T;position:firstLastEnum;clone?:boolean;}class ConcatenateDto{constructor(lists?:T[][],clone?:boolean);lists:T[][];clone?:boolean;}class IncludesDto{constructor(list?:T[],item?:T);list:T[];item:T;}class InterleaveDto{constructor(lists?:T[][],clone?:boolean);lists:T[][];clone?:boolean;}}declare namespace Logic{enum BooleanOperatorsEnum{less="<",lessOrEqual="<=",greater=">",greaterOrEqual=">=",tripleEqual="===",tripleNotEqual="!==",equal="==",notEqual="!="}class ComparisonDto{constructor(first?:T,second?:T,operator?:BooleanOperatorsEnum);first:T;second:T;operator:BooleanOperatorsEnum;}class BooleanDto{constructor(boolean?:boolean);boolean:boolean;}class BooleanListDto{constructor(booleans?:boolean);booleans:any;}class ValueGateDto{constructor(value?:T,boolean?:boolean);value:T;boolean:boolean;}class TwoValueGateDto{constructor(value1?:T,value2?:U);value1?:T;value2?:U;}class RandomBooleansDto{constructor(length?:number);length:number;trueThreshold:number;}class TwoThresholdRandomGradientDto{numbers:number[];thresholdTotalTrue:number;thresholdTotalFalse:number;nrLevels:number;}class ThresholdBooleanListDto{numbers:number[];threshold:number;inverse:boolean;}class ThresholdGapsBooleanListDto{numbers:number[];gapThresholds:Base.Vector2[];inverse:boolean;}}declare namespace Math{enum mathTwoNrOperatorEnum{add="add",subtract="subtract",multiply="multiply",divide="divide",power="power",modulus="modulus"}enum mathOneNrOperatorEnum{absolute="absolute",negate="negate",ln="ln",log10="log10",tenPow="tenPow",round="round",floor="floor",ceil="ceil",sqrt="sqrt",sin="sin",cos="cos",tan="tan",asin="asin",acos="acos",atan="atan",log="log",exp="exp",radToDeg="radToDeg",degToRad="degToRad"}enum easeEnum{easeInSine="easeInSine",easeOutSine="easeOutSine",easeInOutSine="easeInOutSine",easeInQuad="easeInQuad",easeOutQuad="easeOutQuad",easeInOutQuad="easeInOutQuad",easeInCubic="easeInCubic",easeOutCubic="easeOutCubic",easeInOutCubic="easeInOutCubic",easeInQuart="easeInQuart",easeOutQuart="easeOutQuart",easeInOutQuart="easeInOutQuart",easeInQuint="easeInQuint",easeOutQuint="easeOutQuint",easeInOutQuint="easeInOutQuint",easeInExpo="easeInExpo",easeOutExpo="easeOutExpo",easeInOutExpo="easeInOutExpo",easeInCirc="easeInCirc",easeOutCirc="easeOutCirc",easeInOutCirc="easeInOutCirc",easeInElastic="easeInElastic",easeOutElastic="easeOutElastic",easeInOutElastic="easeInOutElastic",easeInBack="easeInBack",easeOutBack="easeOutBack",easeInOutBack="easeInOutBack",easeInBounce="easeInBounce",easeOutBounce="easeOutBounce",easeInOutBounce="easeInOutBounce"}class ModulusDto{constructor(number?:number,modulus?:number);number:number;modulus:number;}class NumberDto{constructor(number?:number);number:number;}class EaseDto{constructor(x?:number);x:number;min:number;max:number;ease:easeEnum;}class RoundToDecimalsDto{constructor(number?:number,decimalPlaces?:number);number:number;decimalPlaces:number;}class ActionOnTwoNumbersDto{constructor(first?:number,second?:number,operation?:mathTwoNrOperatorEnum);first:number;second:number;operation:mathTwoNrOperatorEnum;}class TwoNumbersDto{constructor(first?:number,second?:number);first:number;second:number;}class ActionOnOneNumberDto{constructor(number?:number,operation?:mathOneNrOperatorEnum);number:number;operation:mathOneNrOperatorEnum;}class RemapNumberDto{constructor(number?:number,fromLow?:number,fromHigh?:number,toLow?:number,toHigh?:number);number:number;fromLow:number;fromHigh:number;toLow:number;toHigh:number;}class RandomNumberDto{constructor(low?:number,high?:number);low:number;high:number;}class RandomNumbersDto{constructor(low?:number,high?:number,count?:number);low:number;high:number;count:number;}class ToFixedDto{constructor(number?:number,decimalPlaces?:number);number:number;decimalPlaces:number;}class ClampDto{constructor(number?:number,min?:number,max?:number);number:number;min:number;max:number;}class LerpDto{constructor(start?:number,end?:number,t?:number);start:number;end:number;t:number;}class InverseLerpDto{constructor(start?:number,end?:number,value?:number);start:number;end:number;value:number;}class WrapDto{constructor(number?:number,min?:number,max?:number);number:number;min:number;max:number;}class PingPongDto{constructor(t?:number,length?:number);t:number;length:number;}class MoveTowardsDto{constructor(current?:number,target?:number,maxDelta?:number);current:number;target:number;maxDelta:number;}}declare namespace Mesh{class SignedDistanceFromPlaneToPointDto{constructor(point?:Base.Point3,plane?:Base.TrianglePlane3);point?:Base.Point3;plane?:Base.TrianglePlane3;}class TriangleDto{constructor(triangle?:Base.Triangle3);triangle?:Base.Triangle3;}class TriangleToleranceDto{constructor(triangle?:Base.Triangle3);triangle?:Base.Triangle3;tolerance?:number;}class TriangleTriangleToleranceDto{constructor(triangle1?:Base.Triangle3,triangle2?:Base.Triangle3,tolerance?:number);triangle1?:Base.Triangle3;triangle2?:Base.Triangle3;tolerance?:number;}class MeshMeshToleranceDto{constructor(mesh1?:Base.Mesh3,mesh2?:Base.Mesh3,tolerance?:number);mesh1?:Base.Mesh3;mesh2?:Base.Mesh3;tolerance?:number;}}declare namespace Point{class PointDto{constructor(point?:Base.Point3);point:Base.Point3;}class PointXYZDto{constructor(x?:number,y?:number,z?:number);x:number;y:number;z:number;}class PointXYDto{constructor(x?:number,y?:number);x:number;y:number;}class PointsDto{constructor(points?:Base.Point3[]);points:Base.Point3[];}class TwoPointsDto{constructor(point1?:Base.Point3,point2?:Base.Point3);point1:Base.Point3;point2:Base.Point3;}class DrawPointDto{constructor(point?:Base.Point3,opacity?:number,size?:number,colours?:string|string[],updatable?:boolean,pointMesh?:T);point:Base.Point3;opacity:number;size:number;colours:string|string[];updatable:boolean;pointMesh?:T;}class DrawPointsDto{constructor(points?:Base.Point3[],opacity?:number,size?:number,colours?:string|string[],updatable?:boolean,pointsMesh?:T);points:Base.Point3[];opacity:number;size:number;colours:string|string[];updatable:boolean;pointsMesh?:T;}class TransformPointDto{constructor(point?:Base.Point3,transformation?:Base.TransformMatrixes);point:Base.Point3;transformation:Base.TransformMatrixes;}class TransformPointsDto{constructor(points?:Base.Point3[],transformation?:Base.TransformMatrixes);points:Base.Point3[];transformation:Base.TransformMatrixes;}class TranslatePointsWithVectorsDto{constructor(points?:Base.Point3[],translations?:Base.Vector3[]);points:Base.Point3[];translations:Base.Vector3[];}class TranslatePointsDto{constructor(points?:Base.Point3[],translation?:Base.Vector3);points:Base.Point3[];translation:Base.Vector3;}class TranslateXYZPointsDto{constructor(points?:Base.Point3[],x?:number,y?:number,z?:number);points:Base.Point3[];x:number;y:number;z:number;}class ScalePointsCenterXYZDto{constructor(points?:Base.Point3[],center?:Base.Point3,scaleXyz?:Base.Vector3);points:Base.Point3[];center:Base.Point3;scaleXyz:Base.Vector3;}class StretchPointsDirFromCenterDto{constructor(points?:Base.Point3[],center?:Base.Point3,direction?:Base.Vector3,scale?:number);points?:Base.Point3[];center?:Base.Point3;direction?:Base.Vector3;scale?:number;}class RotatePointsCenterAxisDto{constructor(points?:Base.Point3[],angle?:number,axis?:Base.Vector3,center?:Base.Point3);points:Base.Point3[];angle:number;axis:Base.Vector3;center:Base.Point3;}class TransformsForPointsDto{constructor(points?:Base.Point3[],transformation?:Base.TransformMatrixes[]);points:Base.Point3[];transformation:Base.TransformMatrixes[];}class ThreePointsNormalDto{constructor(point1?:Base.Point3,point2?:Base.Point3,point3?:Base.Point3,reverseNormal?:boolean);point1:Base.Point3;point2:Base.Point3;point3:Base.Point3;reverseNormal:boolean;}class ThreePointsToleranceDto{constructor(start?:Base.Point3,center?:Base.Point3,end?:Base.Point3,tolerance?:number);start?:Base.Point3;center?:Base.Point3;end?:Base.Point3;tolerance:number;}class PointsMaxFilletsHalfLineDto{constructor(points?:Base.Point3[],checkLastWithFirst?:boolean,tolerance?:number);points?:Base.Point3[];checkLastWithFirst?:boolean;tolerance?:number;}class RemoveConsecutiveDuplicatesDto{constructor(points?:Base.Point3[],tolerance?:number,checkFirstAndLast?:boolean);points:Base.Point3[];tolerance:number;checkFirstAndLast:boolean;}class ClosestPointFromPointsDto{constructor(points?:Base.Point3[],point?:Base.Point3);points:Base.Point3[];point:Base.Point3;}class TwoPointsToleranceDto{constructor(point1?:Base.Point3,point2?:Base.Point3,tolerance?:number);point1?:Base.Point3;point2?:Base.Point3;tolerance?:number;}class StartEndPointsDto{constructor(startPoint?:Base.Point3,endPoint?:Base.Point3);startPoint:Base.Point3;endPoint:Base.Point3;}class StartEndPointsListDto{constructor(startPoint?:Base.Point3,endPoints?:Base.Point3[]);startPoint:Base.Point3;endPoints:Base.Point3[];}class MultiplyPointDto{constructor(point?:Base.Point3,amountOfPoints?:number);point:Base.Point3;amountOfPoints:number;}class SpiralDto{constructor(radius?:number,numberPoints?:number,widening?:number,factor?:number,phi?:number);phi:number;numberPoints:number;widening:number;radius:number;factor:number;}class HexGridScaledToFitDto{constructor(wdith?:number,height?:number,nrHexagonsU?:number,nrHexagonsV?:number,centerGrid?:boolean,pointsOnGround?:boolean);width?:number;height?:number;nrHexagonsInWidth?:number;nrHexagonsInHeight?:number;flatTop?:boolean;extendTop?:boolean;extendBottom?:boolean;extendLeft?:boolean;extendRight?:boolean;centerGrid?:boolean;pointsOnGround?:boolean;}class HexGridCentersDto{constructor(nrHexagonsX?:number,nrHexagonsY?:number,radiusHexagon?:number,orientOnCenter?:boolean,pointsOnGround?:boolean);nrHexagonsY:number;nrHexagonsX:number;radiusHexagon:number;orientOnCenter:boolean;pointsOnGround:boolean;}}declare namespace Polyline{class PolylineCreateDto{constructor(points?:Base.Point3[],isClosed?:boolean);points?:Base.Point3[];isClosed?:boolean;}class PolylinePropertiesDto{constructor(points?:Base.Point3[],isClosed?:boolean);points?:Base.Point3[];isClosed?:boolean;color?:string|number[];}class PolylineDto{constructor(polyline?:PolylinePropertiesDto);polyline?:PolylinePropertiesDto;}class PolylinesDto{constructor(polylines?:PolylinePropertiesDto[]);polylines?:PolylinePropertiesDto[];}class TransformPolylineDto{constructor(polyline?:PolylinePropertiesDto,transformation?:Base.TransformMatrixes);polyline?:PolylinePropertiesDto;transformation?:Base.TransformMatrixes;}class DrawPolylineDto{constructor(polyline?:PolylinePropertiesDto,opacity?:number,colours?:string|string[],size?:number,updatable?:boolean,polylineMesh?:T);polyline?:PolylinePropertiesDto;opacity?:number;colours?:string|string[];size?:number;updatable?:boolean;polylineMesh?:T;}class DrawPolylinesDto{constructor(polylines?:PolylinePropertiesDto[],opacity?:number,colours?:string|string[],size?:number,updatable?:boolean,polylinesMesh?:T);polylines?:PolylinePropertiesDto[];opacity?:number;colours?:string|string[];size?:number;updatable?:boolean;polylinesMesh?:T;}class SegmentsToleranceDto{constructor(segments?:Base.Segment3[]);segments?:Base.Segment3[];tolerance?:number;}class PolylineToleranceDto{constructor(polyline?:PolylinePropertiesDto,tolerance?:number);polyline?:PolylinePropertiesDto;tolerance?:number;}class TwoPolylinesToleranceDto{constructor(polyline1?:PolylinePropertiesDto,polyline2?:PolylinePropertiesDto,tolerance?:number);polyline1?:PolylinePropertiesDto;polyline2?:PolylinePropertiesDto;tolerance?:number;}}declare namespace Text{class TextDto{constructor(text?:string);text:string;}class TextSplitDto{constructor(text?:string,separator?:string);text:string;separator:string;}class TextReplaceDto{constructor(text?:string,search?:string,replaceWith?:string);text:string;search:string;replaceWith:string;}class TextJoinDto{constructor(list?:string[],separator?:string);list:string[];separator:string;}class ToStringDto{constructor(item?:T);item:T;}class ToStringEachDto{constructor(list?:T[]);list:T[];}class TextFormatDto{constructor(text?:string,values?:string[]);text:string;values:string[];}class TextSearchDto{constructor(text?:string,search?:string);text:string;search:string;}class TextSubstringDto{constructor(text?:string,start?:number,end?:number);text:string;start:number;end?:number;}class TextIndexDto{constructor(text?:string,index?:number);text:string;index:number;}class TextPadDto{constructor(text?:string,length?:number,padString?:string);text:string;length:number;padString:string;}class TextRepeatDto{constructor(text?:string,count?:number);text:string;count:number;}class TextConcatDto{constructor(texts?:string[]);texts:string[];}class TextRegexDto{constructor(text?:string,pattern?:string,flags?:string);text:string;pattern:string;flags:string;}class TextRegexReplaceDto{constructor(text?:string,pattern?:string,flags?:string,replaceWith?:string);text:string;pattern:string;flags:string;replaceWith:string;}class VectorCharDto{constructor(char?:string,xOffset?:number,yOffset?:number,height?:number,extrudeOffset?:number);char:string;xOffset?:number;yOffset?:number;height?:number;extrudeOffset?:number;}class VectorTextDto{constructor(text?:string,xOffset?:number,yOffset?:number,height?:number,lineSpacing?:number,letterSpacing?:number,align?:Base.horizontalAlignEnum,extrudeOffset?:number,centerOnOrigin?:boolean);text?:string;xOffset?:number;yOffset?:number;height?:number;lineSpacing?:number;letterSpacing?:number;align?:Base.horizontalAlignEnum;extrudeOffset?:number;centerOnOrigin?:boolean;}}declare namespace Transforms{class RotationCenterAxisDto{constructor(angle?:number,axis?:Base.Vector3,center?:Base.Point3);angle:number;axis:Base.Vector3;center:Base.Point3;}class RotationCenterDto{constructor(angle?:number,center?:Base.Point3);angle:number;center:Base.Point3;}class RotationCenterYawPitchRollDto{constructor(yaw?:number,pitch?:number,roll?:number,center?:Base.Point3);yaw:number;pitch:number;roll:number;center:Base.Point3;}class ScaleXYZDto{constructor(scaleXyz?:Base.Vector3);scaleXyz:Base.Vector3;}class StretchDirCenterDto{constructor(scale?:number,center?:Base.Point3,direction?:Base.Vector3);center?:Base.Point3;direction?:Base.Vector3;scale?:number;}class ScaleCenterXYZDto{constructor(center?:Base.Point3,scaleXyz?:Base.Vector3);center:Base.Point3;scaleXyz:Base.Vector3;}class UniformScaleDto{constructor(scale?:number);scale:number;}class UniformScaleFromCenterDto{constructor(scale?:number,center?:Base.Point3);scale:number;center:Base.Point3;}class TranslationXYZDto{constructor(translation?:Base.Vector3);translation:Base.Vector3;}class TranslationsXYZDto{constructor(translations?:Base.Vector3[]);translations:Base.Vector3[];}}declare namespace Vector{class TwoVectorsDto{constructor(first?:number[],second?:number[]);first:number[];second:number[];}class VectorBoolDto{constructor(vector?:boolean[]);vector:boolean[];}class RemoveAllDuplicateVectorsDto{constructor(vectors?:number[][],tolerance?:number);vectors:number[][];tolerance:number;}class RemoveConsecutiveDuplicateVectorsDto{constructor(vectors?:number[][],checkFirstAndLast?:boolean,tolerance?:number);vectors:number[][];checkFirstAndLast:boolean;tolerance:number;}class VectorsTheSameDto{constructor(vec1?:number[],vec2?:number[],tolerance?:number);vec1:number[];vec2:number[];tolerance:number;}class VectorDto{constructor(vector?:number[]);vector:number[];}class VectorStringDto{constructor(vector?:string[]);vector:string[];}class Vector3Dto{constructor(vector?:Base.Vector3);vector:Base.Vector3;}class RangeMaxDto{constructor(max?:number);max:number;}class VectorXYZDto{constructor(x?:number,y?:number,z?:number);x:number;y:number;z:number;}class VectorXYDto{constructor(x?:number,y?:number);x:number;y:number;}class SpanDto{constructor(step?:number,min?:number,max?:number);step:number;min:number;max:number;}class SpanEaseItemsDto{constructor(nrItems?:number,min?:number,max?:number,ease?:Math.easeEnum);nrItems:number;min:number;max:number;ease:Math.easeEnum;intervals:boolean;}class SpanLinearItemsDto{constructor(nrItems?:number,min?:number,max?:number);nrItems:number;min:number;max:number;}class RayPointDto{constructor(point?:Base.Point3,distance?:number,vector?:number[]);point:Base.Point3;distance:number;vector:number[];}class VectorsDto{constructor(vectors?:number[][]);vectors:number[][];}class FractionTwoVectorsDto{constructor(fraction?:number,first?:Base.Vector3,second?:Base.Vector3);fraction:number;first:Base.Vector3;second:Base.Vector3;}class VectorScalarDto{constructor(scalar?:number,vector?:number[]);scalar:number;vector:number[];}class TwoVectorsReferenceDto{constructor(reference?:number[],first?:Base.Vector3,second?:Base.Vector3);reference:number[];first:Base.Vector3;second:Base.Vector3;}}declare namespace Asset{class GetAssetDto{constructor(fileName?:string);fileName:string;}class FetchDto{constructor(url?:string);url:string;}class FileDto{constructor(file?:File|Blob);file:File|Blob;}class FilesDto{constructor(files?:(File|Blob)[]);files:(File|Blob)[];}class AssetFileDto{constructor(assetFile?:File,hidden?:boolean);assetFile:File;hidden:boolean;}class AssetFileByUrlDto{constructor(assetFile?:string,rootUrl?:string,hidden?:boolean);assetFile:string;rootUrl:string;hidden:boolean;}class DownloadDto{constructor(fileName?:string,content?:string|Blob,extension?:string,contentType?:string);fileName:string;content:string|Blob;extension:string;contentType:string;}}declare namespace Base{enum colorMapStrategyEnum{firstColorForAll="firstColorForAll",lastColorRemainder="lastColorRemainder",repeatColors="repeatColors",reversedColors="reversedColors"}enum skyboxEnum{default="default",clearSky="clearSky",city="city",greyGradient="greyGradient"}enum fogModeEnum{none="none",exponential="exponential",exponentialSquared="exponentialSquared",linear="linear"}enum horizontalAlignEnum{left="left",center="center",right="right"}enum verticalAlignmentEnum{top="top",middle="middle",bottom="bottom"}enum topBottomEnum{top="top",bottom="bottom"}enum basicAlignmentEnum{topLeft="topLeft",topMid="topMid",topRight="topRight",midLeft="midLeft",midMid="midMid",midRight="midRight",bottomLeft="bottomLeft",bottomMid="bottomMid",bottomRight="bottomRight"}type Color=string;type ColorRGB={r:number;g:number;b:number;};type Point2=[number,number];type Vector2=[number,number];type Point3=[number,number,number];type Vector3=[number,number,number];type Axis3={origin:Base.Point3;direction:Base.Vector3;};type Axis2={origin:Base.Point2;direction:Base.Vector2;};type Segment2=[Point2,Point2];type Segment3=[Point3,Point3];type TrianglePlane3={normal:Vector3;d:number;};type Triangle3=[Base.Point3,Base.Point3,Base.Point3];type Mesh3=Triangle3[];type Plane3={origin:Base.Point3;normal:Base.Vector3;direction:Base.Vector3;};type BoundingBox={min:Base.Point3;max:Base.Point3;center?:Base.Point3;width?:number;height?:number;length?:number;};type Line2={start:Base.Point2;end:Base.Point2;};type Line3={start:Base.Point3;end:Base.Point3;};type Polyline3={points:Base.Point3[];isClosed?:boolean;};type Polyline2={points:Base.Point2[];isClosed?:boolean;};type VerbCurve={tessellate:(options:any)=>any;};type VerbSurface={tessellate:(options:any)=>any;};type TransformMatrix3x3=[number,number,number,number,number,number,number,number,number];type TransformMatrixes3x3=TransformMatrix3x3[];type TransformMatrix=[number,number,number,number,number,number,number,number,number,number,number,number,number,number,number,number];type TransformMatrixes=TransformMatrix[];}declare namespace CSV{class ParseToArrayDto{constructor(csv?:string,rowSeparator?:string,columnSeparator?:string);csv:string;rowSeparator?:string;columnSeparator?:string;}class ParseToJsonDto{constructor(csv?:string,headerRow?:number,dataStartRow?:number,rowSeparator?:string,columnSeparator?:string,numberColumns?:string[]);csv:string;headerRow?:number;dataStartRow?:number;rowSeparator?:string;columnSeparator?:string;numberColumns?:string[];}class ParseToJsonWithHeadersDto{constructor(csv?:string,headers?:string[],dataStartRow?:number,rowSeparator?:string,columnSeparator?:string,numberColumns?:string[]);csv:string;headers:string[];dataStartRow?:number;rowSeparator?:string;columnSeparator?:string;numberColumns?:string[];}class QueryColumnDto{constructor(csv?:string,column?:string,headerRow?:number,dataStartRow?:number,rowSeparator?:string,columnSeparator?:string,asNumber?:boolean);csv:string;column:string;headerRow?:number;dataStartRow?:number;rowSeparator?:string;columnSeparator?:string;asNumber?:boolean;}class QueryRowsByValueDto{constructor(csv?:string,column?:string,value?:string,headerRow?:number,dataStartRow?:number,rowSeparator?:string,columnSeparator?:string,numberColumns?:string[]);csv:string;column:string;value:string;headerRow?:number;dataStartRow?:number;rowSeparator?:string;columnSeparator?:string;numberColumns?:string[];}class ArrayToCsvDto{constructor(array?:(string|number|boolean|null|undefined)[][],rowSeparator?:string,columnSeparator?:string);array:(string|number|boolean|null|undefined)[][];rowSeparator?:string;columnSeparator?:string;}class JsonToCsvDto>{constructor(json?:T[],headers?:string[],includeHeaders?:boolean,rowSeparator?:string,columnSeparator?:string);json:T[];headers:string[];includeHeaders?:boolean;rowSeparator?:string;columnSeparator?:string;}class JsonToCsvAutoDto>{constructor(json?:T[],includeHeaders?:boolean,rowSeparator?:string,columnSeparator?:string);json:T[];includeHeaders?:boolean;rowSeparator?:string;columnSeparator?:string;}class GetHeadersDto{constructor(csv?:string,headerRow?:number,rowSeparator?:string,columnSeparator?:string);csv:string;headerRow?:number;rowSeparator?:string;columnSeparator?:string;}class GetRowCountDto{constructor(csv?:string,hasHeaders?:boolean,dataStartRow?:number,rowSeparator?:string,columnSeparator?:string);csv:string;hasHeaders?:boolean;dataStartRow?:number;rowSeparator?:string;columnSeparator?:string;}}declare namespace JSON{class StringifyDto{constructor(json?:any);json:any;}class ParseDto{constructor(text?:string);text:string;}class QueryDto{constructor(json?:any,query?:string);json:any;query:string;}class SetValueOnPropDto{constructor(json?:any,value?:any,property?:string);json:any;value:any;property:string;}class GetJsonFromArrayByFirstPropMatchDto{constructor(jsonArray?:any[],property?:string,match?:any);jsonArray:any[];property:string;match:any;}class GetValueOnPropDto{constructor(json?:any,property?:string);json:any;property:string;}class SetValueDto{constructor(json?:any,value?:any,path?:string,prop?:string);json:any;value:any;path:string;prop:string;}class SetValuesOnPathsDto{constructor(json?:any,values?:any[],paths?:string[],props?:[]);json:any;values:any[];paths:string[];props:string[];}class PathsDto{constructor(json?:any,query?:string);json:any;query:string;}class JsonDto{constructor(json?:any);json:any;}}declare namespace Tag{class DrawTagDto{constructor(tag?:TagDto,updatable?:boolean,tagVariable?:TagDto);tag:TagDto;updatable:boolean;tagVariable?:TagDto;}class DrawTagsDto{constructor(tags?:TagDto[],updatable?:boolean,tagsVariable?:TagDto[]);tags:TagDto[];updatable:boolean;tagsVariable?:TagDto[];}class TagDto{constructor(text?:string,position?:Base.Point3,colour?:string,size?:number,adaptDepth?:boolean,needsUpdate?:boolean,id?:string);text:string;position:Base.Point3;colour:string;size:number;adaptDepth:boolean;needsUpdate?:boolean;id?:string;}}declare namespace Time{class PostFromIframe{constructor(data?:any,targetOrigin?:string);data:any;targetOrigin:string;}}declare namespace Verb{class CurveDto{constructor(curve?:any);curve:any;}class LineDto{constructor(line?:Base.Line3);line:Base.Line3;}class LinesDto{constructor(lines?:Base.Line3[]);lines:Base.Line3[];}class PolylineDto{constructor(polyline?:Base.Polyline3);polyline:Base.Polyline3;}class PolylinesDto{constructor(polylines?:Base.Polyline3[]);polylines:Base.Polyline3[];}class CurvesDto{constructor(curves?:any[]);curves:any[];}class ClosestPointDto{constructor(curve?:any,point?:Base.Point3);curve:any;point:Base.Point3;}class ClosestPointsDto{constructor(curve?:any,points?:Base.Point3[]);curve:any;points:Base.Point3[];}class BezierCurveDto{constructor(points?:Base.Point3[],weights?:number[]);points:Base.Point3[];weights:number[];}class DrawCurveDto{constructor(curve?:any,opacity?:number,colours?:string|string[],size?:number,updatable?:boolean,curveMesh?:T);curve:any;opacity:number;colours:string|string[];size:number;updatable:boolean;curveMesh?:T;}class CurveParameterDto{constructor(curve?:any,parameter?:number);curve:any;parameter:number;}class CurvesParameterDto{constructor(curves?:any[],parameter?:number);curves:any;parameter:number;}class CurveTransformDto{constructor(curve?:any,transformation?:Base.TransformMatrixes);curve:any;transformation:Base.TransformMatrixes;}class CurvesTransformDto{constructor(curves?:any[],transformation?:Base.TransformMatrixes);curves:any[];transformation:Base.TransformMatrixes;}class CurveToleranceDto{constructor(curve?:any,tolerance?:number);curve:any;tolerance:number;}class CurveLengthToleranceDto{constructor(curve?:any,length?:number,tolerance?:number);curve:any;length:number;tolerance:number;}class CurveDerivativesDto{constructor(curve?:any,parameter?:number,numDerivatives?:number);curve:any;numDerivatives:number;parameter:number;}class CurveSubdivisionsDto{constructor(curve?:any,subdivision?:number);curve:any;subdivision:number;}class CurvesSubdivisionsDto{constructor(curves?:any[],subdivision?:number);curves:any[];subdivision:number;}class CurvesDivideLengthDto{constructor(curves?:any[],length?:number);curves:any[];length:number;}class CurveDivideLengthDto{constructor(curve?:any,length?:number);curve:any;length:number;}class DrawCurvesDto{constructor(curves?:any[],opacity?:number,colours?:string|string[],size?:number,updatable?:boolean,curvesMesh?:T);curves:any[];opacity:number;colours:string|string[];size:number;updatable:boolean;curvesMesh?:T;}class CurveNurbsDataDto{constructor(degree?:number,weights?:number[],knots?:number[],points?:Base.Point3[]);degree:number;weights:number[];knots:number[];points:Base.Point3[];}class CurvePathDataDto{constructor(degree?:number,points?:Base.Point3[]);degree:number;points:Base.Point3[];}class EllipseDto{constructor(ellipse?:any);ellipse:any;}class CircleDto{constructor(circle?:any);circle:any;}class ArcDto{constructor(arc?:any);arc:any;}class EllipseParametersDto{constructor(xAxis?:Base.Vector3,yAxis?:Base.Vector3,center?:Base.Point3);xAxis:Base.Vector3;yAxis:Base.Vector3;center:Base.Point3;}class CircleParametersDto{constructor(xAxis?:Base.Vector3,yAxis?:Base.Vector3,radius?:number,center?:Base.Point3);xAxis:Base.Vector3;yAxis:Base.Vector3;radius:number;center:Base.Point3;}class ArcParametersDto{constructor(minAngle?:number,maxAngle?:number,xAxis?:Base.Vector3,yAxis?:Base.Vector3,radius?:number,center?:Base.Point3);minAngle:number;maxAngle:number;xAxis:Base.Vector3;yAxis:Base.Vector3;radius:number;center:Base.Point3;}class EllipseArcParametersDto{constructor(minAngle?:number,maxAngle?:number,xAxis?:Base.Vector3,yAxis?:Base.Vector3,center?:Base.Point3);minAngle:number;maxAngle:number;xAxis:Base.Vector3;yAxis:Base.Vector3;center:Base.Point3;}class SurfaceDto{constructor(surface?:any);surface:any;}class SurfaceTransformDto{constructor(surface?:any,transformation?:Base.TransformMatrixes);surface:any;transformation:Base.TransformMatrixes;}class SurfaceParameterDto{constructor(surface?:any,parameter?:number,useV?:boolean);surface:any;parameter:number;useV:boolean;}class IsocurvesParametersDto{constructor(surface?:any,parameters?:number[],useV?:boolean);surface:any;parameters:number[];useV:boolean;}class IsocurveSubdivisionDto{constructor(surface?:any,useV?:boolean,includeLast?:boolean,includeFirst?:boolean,isocurveSegments?:number);surface:any;useV:boolean;includeLast:boolean;includeFirst:boolean;isocurveSegments:number;}class DerivativesDto{constructor(surface?:any,u?:number,v?:number,numDerivatives?:number);surface:any;u:number;v:number;numDerivatives:number;}class SurfaceLocationDto{constructor(surface?:any,u?:number,v?:number);surface:any;u:number;v:number;}class CornersDto{constructor(point1?:Base.Point3,point2?:Base.Point3,point3?:Base.Point3,point4?:Base.Point3);point1:Base.Point3;point2:Base.Point3;point3:Base.Point3;point4:Base.Point3;}class SurfaceParamDto{constructor(surface?:any,point?:Base.Point3);surface:any;point:Base.Point3;}class KnotsControlPointsWeightsDto{constructor(degreeU?:number,degreeV?:number,knotsU?:number[],knotsV?:number[],points?:Base.Point3[],weights?:number[]);degreeU:number;degreeV:number;knotsU:number[];knotsV:number[];points:Base.Point3[];weights:number[];}class LoftCurvesDto{constructor(degreeV?:number,curves?:any[]);degreeV:number;curves:any[];}class DrawSurfaceDto{constructor(surface?:any,opacity?:number,colours?:string|string[],updatable?:boolean,hidden?:boolean,surfaceMesh?:T,drawTwoSided?:boolean,backFaceColour?:string,backFaceOpacity?:number);surface:any;opacity:number;colours:string|string[];updatable:boolean;hidden:boolean;surfaceMesh?:T;drawTwoSided:boolean;backFaceColour:string;backFaceOpacity:number;}class DrawSurfacesDto{constructor(surfaces?:any[],opacity?:number,colours?:string|string[],updatable?:boolean,hidden?:boolean,surfacesMesh?:T,drawTwoSided?:boolean,backFaceColour?:string,backFaceOpacity?:number);surfaces:any[];opacity:number;colours:string|string[];updatable:boolean;hidden:boolean;surfacesMesh?:T;drawTwoSided:boolean;backFaceColour:string;backFaceOpacity:number;}class DrawSurfacesColoursDto{constructor(surfaces?:any[],colours?:string[],opacity?:number,updatable?:boolean,hidden?:boolean,surfacesMesh?:T,drawTwoSided?:boolean,backFaceColour?:string,backFaceOpacity?:number);surfaces:any[];opacity:number;colours:string|string[];updatable:boolean;hidden:boolean;surfacesMesh?:T;drawTwoSided:boolean;backFaceColour:string;backFaceOpacity:number;}class ConeAndCylinderParametersDto{constructor(axis?:Base.Vector3,xAxis?:Base.Vector3,base?:Base.Point3,height?:number,radius?:number);axis:Base.Vector3;xAxis:Base.Vector3;base:Base.Point3;height:number;radius:number;}class ConeDto{constructor(cone?:any);cone:any;}class CylinderDto{constructor(cylinder?:any);cylinder:any;}class ExtrusionParametersDto{constructor(profile?:any,direction?:Base.Vector3);profile:any;direction:Base.Vector3;}class ExtrusionDto{constructor(extrusion?:any);extrusion:any;}class SphericalParametersDto{constructor(radius?:number,center?:number[]);radius:number;center:number[];}class SphereDto{constructor(sphere?:any);sphere:any;}class RevolutionParametersDto{constructor(profile?:any,center?:number[],axis?:number[],angle?:number);profile:any;center:number[];axis:number[];angle:number;}class RevolutionDto{constructor(revolution?:any);revolution:any;}class SweepParametersDto{constructor(profile?:any,rail?:any);profile:any;rail:any;}class SweepDto{constructor(sweep?:any);sweep:any;}class CurveCurveDto{constructor(firstCurve?:any,secondCurve?:any,tolerance?:number);firstCurve:any;secondCurve:number[];tolerance?:number;}class CurveSurfaceDto{constructor(curve?:any,surface?:any,tolerance?:number);curve:any;surface:any;tolerance?:number;}class SurfaceSurfaceDto{constructor(firstSurface?:any,secondSurface?:any,tolerance?:number);firstSurface:any;secondSurface:any;tolerance?:number;}class CurveCurveIntersectionsDto{constructor(intersections?:BaseTypes.CurveCurveIntersection[]);intersections:BaseTypes.CurveCurveIntersection[];}class CurveSurfaceIntersectionsDto{constructor(intersections?:BaseTypes.CurveSurfaceIntersection[]);intersections:BaseTypes.CurveSurfaceIntersection[];}}}declare namespace Models{declare namespace Point{declare class HexGridData{centers:Base.Point3[];hexagons:Base.Point3[][];shortestDistEdge:number;longestDistEdge:number;maxFilletRadius:number;}}declare namespace Text{declare class VectorCharData{constructor(width?:number,height?:number,paths?:Base.Point3[][]);width?:number;height?:number;paths?:Base.Point3[][];}declare class VectorTextData{constructor(width?:number,height?:number,chars?:VectorCharData[]);width?:number;height?:number;chars?:VectorCharData[];}}declare namespace OCCT{declare class ShapeWithId{id:string;shape:U;}declare class ObjectDefinition{compound?:U;shapes?:ShapeWithId[];data?:M;}declare class TextWiresCharShapePart{id?:string;shapes?:{compound?:T;};}declare class TextWiresDataDto{type:string;name:string;compound?:T;characters?:TextWiresCharShapePart[];width:number;height:number;center:Base.Point3;}}}declare namespace Things{declare namespace Enums{declare class LodDto{lod:lodEnum;}declare enum lodEnum{low="low",middle="middle",high="high"}}declare namespace Architecture{declare namespace Houses{declare namespace ZenHideout{declare class ZenHideoutData{type:string;name:string;originalInputs?:ZenHideoutDto;compound?:T;shapes?:Models.OCCT.ShapeWithId[];drawingPart?:ZenHideoutDrawingPart;sandwitchPartsBetweenColumns?:Things.Architecture.SandwitchPart[];cornerParts?:Things.Architecture.CornerPart[];columnParts?:Things.Architecture.ColumnPart[];roofParts?:Things.Architecture.RoofPart[];entranceCorner?:Things.Architecture.CornerEntrancePart;entranceTerrace?:Things.Architecture.CornerEntrancePart;floors?:Things.Architecture.FloorPart[];ceilings?:Things.Architecture.CeilingPart[];}declare class ZenHideoutDrawingPartShapes{windowGlassCompound?:T;glassFramesCompound?:T;windowFrameCompound?:T;beamsCompound?:T;columnsCompound?:T;firstFloorExteriorPanelsCompound?:T;firstFloorInteriorPanelsCompound?:T;roofExteriorPanelsCompound?:T;roofInteriorPanelsCompound?:T;roofCoverFirstCompound?:T;roofCoverSecondCompound?:T;floorCompound?:T;ceilingCompound?:T;stairsCompound?:T;}declare class ZenHideoutDrawingPart{shapes?:ZenHideoutDrawingPartShapes;}declare class ZenHideoutDtoBase{widthFirstWing:T;lengthFirstWing:T;terraceWidth:T;widthSecondWing:T;lengthSecondWing:T;heightWalls:T;roofAngleFirstWing:T;roofAngleSecondWing:T;roofOffset:T;roofInsideOverhang:T;roofMaxDistAttachmentBeams:T;roofAttachmentBeamWidth:T;roofAttachmentBeamHeight:T;roofOutsideOverhang:T;columnSize:T;ceilingBeamHeight:T;ceilingBeamWidth:T;nrCeilingBeamsBetweenColumns:T;distBetweenColumns:T;floorHeight:T;groundLevel:T;facadePanelThickness:T;windowWidthOffset:T;windowHeightOffset:T;windowFrameThickness:T;windowGlassFrameThickness:T;lod:U;rotation?:T;origin?:V;}declare class ZenHideoutDto implements ZenHideoutDtoBase{constructor(widthFirstWing?:number,lengthFirstWing?:number,terraceWidth?:number,widthSecondWing?:number,lengthSecondWing?:number,heightWalls?:number,roofAngleFirstWing?:number,roofAngleSecondWing?:number,roofOffset?:number,roofInsideOverhang?:number,roofMaxDistAttachmentBeams?:number,roofAttachmentBeamWidth?:number,roofAttachmentBeamHeight?:number,roofOutsideOverhang?:number,columnSize?:number,ceilingBeamHeight?:number,ceilingBeamWidth?:number,nrCeilingBeamsBetweenColumns?:number,distBetweenColumns?:number,floorHeight?:number,groundLevel?:number,facadePanelThickness?:number,windowWidthOffset?:number,windowHeightOffset?:number,windowFrameThickness?:number,windowGlassFrameThickness?:number,lod?:Things.Enums.lodEnum,skinOpacity?:number,rotation?:number,origin?:Inputs.Base.Point3);widthFirstWing:number;lengthFirstWing:number;terraceWidth:number;widthSecondWing:number;lengthSecondWing:number;heightWalls:number;roofAngleFirstWing:number;roofAngleSecondWing:number;roofOffset:number;roofInsideOverhang:number;roofMaxDistAttachmentBeams:number;roofAttachmentBeamWidth:number;roofAttachmentBeamHeight:number;roofOutsideOverhang:number;columnSize:number;ceilingBeamHeight:number;ceilingBeamWidth:number;nrCeilingBeamsBetweenColumns:number;distBetweenColumns:number;floorHeight:number;groundLevel:number;facadePanelThickness:number;windowWidthOffset:number;windowHeightOffset:number;windowFrameThickness:number;windowGlassFrameThickness:number;lod:Things.Enums.lodEnum;skinOpacity:number;rotation:number;origin:Inputs.Base.Point3;}}}declare class BeamPart{id?:string;name?:string;width?:number;length?:number;height?:number;shapes?:{beam?:T;};}declare class CeilingPart{id?:string;name?:string;area?:number;thickness?:number;polygonPoints?:Inputs.Base.Point3[];shapes?:{compound?:T;};}declare class ColumnPart{id?:string;name?:string;width?:number;length?:number;height?:number;shapes?:{column?:T;};}declare class CornerEntranceDto{widthFirstWing:number;widthSecondWing:number;lengthStairFirstWing:number;lengthStairSecondWing:number;lengthWallFirstWing:number;lengthWallSecondWing:number;facadePanelThickness:number;wallThickness:number;wallHeightExterior:number;wallHeightInterior:number;windowFrameOffsetTop:number;windowFrameThickness:number;glassFrameThickness:number;doorWidth:number;windowWidthOffset:number;stairTotalHeight:number;createStair:boolean;flipDirection:boolean;rotation:number;origin:Inputs.Base.Point3;}declare class CornerEntrancePart{id?:string;name?:string;panelThickness?:number;widthPanelExteriorOne?:number;heightPanelsExterior?:number;stair?:CornerStairPart;window?:WindowCornerPart;shapes?:{compound?:T;panelExterior?:T;panelInterior?:T;};}declare class CornerPart{id?:string;name?:string;widthPanel?:number;heightPanel?:number;thicknessPanel?:number;shapes?:{corner?:T;};}declare class CornerStairDto{invert:boolean;widthFirstLanding:number;widthSecondLanding:number;lengthFirstWing:number;lengthSecondWing:number;maxWishedStepHeight:number;stepHeightWidthProportion:number;totalHeight:number;rotation:number;origin:Inputs.Base.Point3;}declare class CornerStairPart extends CornerStairDto{id?:string;name?:string;steps?:number;stepWidth?:number;stepHeight?:number;shapes?:{stair?:T;};}declare class FloorPart{id?:string;name?:string;area?:number;thickness?:number;polygonPoints?:Inputs.Base.Point3[];shapes?:{compound?:T;};}declare class ZenHideoutData{type:string;name:string;originalInputs?:ZenHideoutDto;compound?:T;shapes?:Models.OCCT.ShapeWithId[];drawingPart?:ZenHideoutDrawingPart;sandwitchPartsBetweenColumns?:Things.Architecture.SandwitchPart[];cornerParts?:Things.Architecture.CornerPart[];columnParts?:Things.Architecture.ColumnPart[];roofParts?:Things.Architecture.RoofPart[];entranceCorner?:Things.Architecture.CornerEntrancePart;entranceTerrace?:Things.Architecture.CornerEntrancePart;floors?:Things.Architecture.FloorPart[];ceilings?:Things.Architecture.CeilingPart[];}declare class ZenHideoutDrawingPartShapes{windowGlassCompound?:T;glassFramesCompound?:T;windowFrameCompound?:T;beamsCompound?:T;columnsCompound?:T;firstFloorExteriorPanelsCompound?:T;firstFloorInteriorPanelsCompound?:T;roofExteriorPanelsCompound?:T;roofInteriorPanelsCompound?:T;roofCoverFirstCompound?:T;roofCoverSecondCompound?:T;floorCompound?:T;ceilingCompound?:T;stairsCompound?:T;}declare class ZenHideoutDrawingPart{shapes?:ZenHideoutDrawingPartShapes;}declare class ZenHideoutDtoBase{widthFirstWing:T;lengthFirstWing:T;terraceWidth:T;widthSecondWing:T;lengthSecondWing:T;heightWalls:T;roofAngleFirstWing:T;roofAngleSecondWing:T;roofOffset:T;roofInsideOverhang:T;roofMaxDistAttachmentBeams:T;roofAttachmentBeamWidth:T;roofAttachmentBeamHeight:T;roofOutsideOverhang:T;columnSize:T;ceilingBeamHeight:T;ceilingBeamWidth:T;nrCeilingBeamsBetweenColumns:T;distBetweenColumns:T;floorHeight:T;groundLevel:T;facadePanelThickness:T;windowWidthOffset:T;windowHeightOffset:T;windowFrameThickness:T;windowGlassFrameThickness:T;lod:U;rotation?:T;origin?:V;}declare class ZenHideoutDto implements ZenHideoutDtoBase{constructor(widthFirstWing?:number,lengthFirstWing?:number,terraceWidth?:number,widthSecondWing?:number,lengthSecondWing?:number,heightWalls?:number,roofAngleFirstWing?:number,roofAngleSecondWing?:number,roofOffset?:number,roofInsideOverhang?:number,roofMaxDistAttachmentBeams?:number,roofAttachmentBeamWidth?:number,roofAttachmentBeamHeight?:number,roofOutsideOverhang?:number,columnSize?:number,ceilingBeamHeight?:number,ceilingBeamWidth?:number,nrCeilingBeamsBetweenColumns?:number,distBetweenColumns?:number,floorHeight?:number,groundLevel?:number,facadePanelThickness?:number,windowWidthOffset?:number,windowHeightOffset?:number,windowFrameThickness?:number,windowGlassFrameThickness?:number,lod?:Things.Enums.lodEnum,skinOpacity?:number,rotation?:number,origin?:Inputs.Base.Point3);widthFirstWing:number;lengthFirstWing:number;terraceWidth:number;widthSecondWing:number;lengthSecondWing:number;heightWalls:number;roofAngleFirstWing:number;roofAngleSecondWing:number;roofOffset:number;roofInsideOverhang:number;roofMaxDistAttachmentBeams:number;roofAttachmentBeamWidth:number;roofAttachmentBeamHeight:number;roofOutsideOverhang:number;columnSize:number;ceilingBeamHeight:number;ceilingBeamWidth:number;nrCeilingBeamsBetweenColumns:number;distBetweenColumns:number;floorHeight:number;groundLevel:number;facadePanelThickness:number;windowWidthOffset:number;windowHeightOffset:number;windowFrameThickness:number;windowGlassFrameThickness:number;lod:Things.Enums.lodEnum;skinOpacity:number;rotation:number;origin:Inputs.Base.Point3;}declare class RoofBeamsPart{beamsCeiling?:BeamPart[];beamsVerticalHigh?:BeamPart[];beamsVerticalLow?:BeamPart[];beamsTop?:BeamPart[];beamsAttachment:BeamPart[];shapes?:{compound?:T;};}declare class RoofCoverOneSidedDto{name:string;roofAngle:number;roofLength:number;roofWidth:number;roofOutsideOverhang:number;roofInsideOverhang:number;roofOverhangFacade:number;roofThickness:number;roofCoverHeight:number;rotation:number;lod:Things.Enums.lodEnum;center:Inputs.Base.Point3;direction:Inputs.Base.Vector3;}declare class RoofCoverPart extends RoofCoverOneSidedDto{id?:string;shapes?:{compound?:T;};}declare class RoofPanelPart{id?:string;name?:string;innerPanels?:SandwitchPart[];innerFillPanels?:SandwitchPart[];outerPanels?:SandwitchPart[];outerFillPanels?:SandwitchPart[];ends?:SandwitchPartFlex[];shapes?:{compoundInnerExteriorPanels?:T;compoundInnerInteriorPanels?:T;compoundInnerFillExteriorPanels?:T;compoundInnerFillInteriorPanels?:T;compoundOuterExteriorPanels?:T;compoundOuterInteriorPanels?:T;compoundOuterFillExteriorPanels?:T;compoundOuterFillInteriorPanels?:T;compoundEndsInteriorPanels?:T;compoundEndsExteriorPanels?:T;compound?:T;};}declare class RoofPart{id?:string;name?:string;beams:RoofBeamsPart;panels?:RoofPanelPart;covers?:RoofCoverPart[];shapes?:{compound?:T;};}declare class SandwitchPanelDto{name:string;createWindow:boolean;createInnerPanel:boolean;createExteriorPanel:boolean;wallWidth:number;exteriorPanelWidth:number;exteriorPanelHeight:number;exteriorPanelThickness:number;exteriorPanelBottomOffset:number;interiorPanelWidth:number;interiorPanelHeight:number;interiorPanelThickness:number;interiorPanelBottomOffset:number;windowWidthOffset:number;windowHeightOffset:number;windowFrameThickness:number;windowGlassFrameThickness:number;}declare class SandwitchPanelFlexDto{name:string;createInteriorPanel:boolean;createExteriorPanel:boolean;wallWidth:number;exteriorPanelThickness:number;interiorPanelThickness:number;interiorPanelPolygonPoints:Inputs.Base.Point2[];exteriorPanelPolygonPoints:Inputs.Base.Point2[];}declare class SandwitchPart extends SandwitchPanelDto{id?:string;rotation?:number;center?:Inputs.Base.Point3;direction?:Inputs.Base.Vector3;windows?:WindowRectangularPart[];shapes?:{panelExterior?:T;panelInterior?:T;compound?:T;};}declare class SandwitchPartFlex extends SandwitchPanelFlexDto{id?:string;rotation?:number;center?:Inputs.Base.Point3;direction?:Inputs.Base.Vector3;windows?:WindowRectangularPart[];shapes?:{panelExterior?:T;panelInterior?:T;compound?:T;};}declare class WindowCornerDto{wallThickness:number;facadePanelThickness:number;glassFrameThickness:number;glassThickness:number;frameThckness:number;height:number;lengthFirst:number;lengthSecond:number;rotation:number;origin:Inputs.Base.Point3;}declare class WindowPartShapes{cutout?:T;glass?:T;glassFrame?:T;frame?:T;compound?:T;}declare class WindowRectangularPart extends WindowRectangularDto{name:string;id?:string;shapes?:WindowPartShapes;}declare class WindowCornerPart extends WindowCornerDto{name:string;id?:string;shapes?:WindowPartShapes;}declare class WindowRectangularDto{thickness:number;glassFrameThickness:number;glassThickness:number;frameThickness:number;height:number;width:number;rotation:number;center:Inputs.Base.Point3;direction:Inputs.Base.Vector3;}}declare namespace KidsCorner{declare namespace BirdHouses{declare namespace WingtipVilla{declare class WingtipVillaData{type:string;name:string;compound?:T;roof:{compound:T;shapes:T[];};walls:{compound:T;shapes:T[];};stick:{shape:T;};floor:{shape:T;};chimney:{shape:T;};basicPoints:{kind:string;point:Inputs.Base.Point3;}[];}declare class WingtipVillaDto{constructor(interiorWidth?:number,interiorLength?:number,interiorHeight?:number,thickness?:number,holeDiameter?:number,holeDistToBottom?:number,stickLength?:number,stickDiameter?:number,baseAttachmentHeight?:number,roofOverhang?:number,rotation?:number,chimneyHeight?:number,origin?:Inputs.Base.Point3);interiorWidth:number;interiorLength:number;interiorHeight:number;thickness:number;holeDiameter:number;holeDistToBottom:number;stickLength:number;stickDiameter:number;baseAttachmentHeight:number;roofOverhang:number;rotation:number;chimneyHeight:number;origin:Inputs.Base.Point3;}}declare namespace ChirpyChalet{declare class ChirpyChaletData{type:string;name:string;compound?:T;roof:{compound:T;shapes:T[];};walls:{compound:T;shapes:T[];};stick:{shape:T;};floor:{shape:T;};basicPoints:{kind:string;point:Inputs.Base.Point3;}[];}declare class ChirpyChaletDto{constructor(interiorWidth?:number,interiorLength?:number,interiorHeight?:number,thickness?:number,holeDiameter?:number,holeDistToBottom?:number,stickLength?:number,stickDiameter?:number,baseAttachmentHeight?:number,roofOverhang?:number,roofAngle?:number,rotation?:number,origin?:Inputs.Base.Point3);interiorWidth:number;interiorLength:number;interiorHeight:number;thickness:number;holeDiameter:number;holeDistToBottom:number;stickLength:number;stickDiameter:number;baseAttachmentHeight:number;roofOverhang:number;roofAngle:number;rotation:number;origin:Inputs.Base.Point3;}}}}declare namespace ThreeDPrinting{declare namespace Vases{declare namespace SerenitySwirl{declare class SerenitySwirlData{type:string;name:string;compound?:T;}declare class SerenitySwirlDto{constructor(swirl?:number,nrOfDivisions?:number,addRadiusNarrow?:number,addRadiusWide?:number,addMiddleHeight?:number,addTopHeight?:number,thickness?:number,rotation?:number,origin?:Inputs.Base.Point3);swirl:number;nrOfDivisions:number;addRadiusNarrow:number;addRadiusWide:number;addMiddleHeight:number;addTopHeight:number;thickness:number;rotation:number;origin:Inputs.Base.Point3;}}declare namespace ArabicArchway{declare class ArabicArchwayData{type:string;name:string;compound?:T;originalInputs:ArabicArchwayDto;shapes?:Models.OCCT.ShapeWithId[];drawingPart?:ArabicArchwayDrawingPart;}declare class ArabicArchwayDrawingPartShapes{compound?:T;vasePartsCompound?:T;glassPartsCompound?:T;vaseBaseCompound?:T;}declare class ArabicArchwayDrawingPart{shapes?:ArabicArchwayDrawingPartShapes|{[x:string]:T;};}declare class ArabicArchwayDtoBase{profilePoints?:P;nrOfSides:T;nrOfVerticalArches:T;thickness:T;edgesThickness:T;archCenterThickness:T;baseHeight:T;patchHoles:B;lod?:U;rotation?:T;direction?:V;scale?:V;origin?:V;}declare class ArabicArchwayDto implements ArabicArchwayDtoBase{constructor(nrOfSides?:number,nrOfVerticalArches?:number,archCenterThickness?:number,edgesThickness?:number,thickness?:number,baseHeight?:number,patchHoles?:boolean,lod?:Things.Enums.lodEnum,rotation?:number,origin?:Inputs.Base.Point3,direction?:Inputs.Base.Point3,scale?:Inputs.Base.Vector3);profilePoints:Inputs.Base.Point3[];nrOfSides:number;nrOfVerticalArches:number;archCenterThickness:number;edgesThickness:number;thickness:number;baseHeight:number;patchHoles:boolean;lod:Things.Enums.lodEnum;rotation:number;origin:Inputs.Base.Point3;direction:Inputs.Base.Point3;scale:Inputs.Base.Vector3;}}}declare namespace Cups{declare namespace CalmCup{declare class CalmCupData{type:string;name:string;originalInputs:CalmCupDto;compound?:T;}declare class CalmCupDtoBase{height:T;radiusBottom:T;radiusTopOffset:T;thickness:T;fillet:T;nrOfHandles:T;handleDist:T;precision:T;rotation?:T;scale?:T;origin?:U;direction?:U;}declare class CalmCupDto implements CalmCupDtoBase{constructor(height?:number,radiusBottom?:number,radiusTopOffset?:number,thickness?:number,fillet?:number,nrOfHandles?:number,handleDist?:number,precision?:number,rotation?:number,scale?:number,origin?:Inputs.Base.Point3,direction?:Inputs.Base.Vector3);height:number;radiusBottom:number;radiusTopOffset:number;thickness:number;fillet:number;nrOfHandles:number;handleDist:number;precision:number;rotation:number;scale:number;origin:Inputs.Base.Point3;direction:Inputs.Base.Vector3;}}declare namespace DragonCup{declare class DragonCupData{type:string;name:string;originalInputs:DragonCupDto;compound?:T;}declare class DragonCupDtoBase{height:T;radiusBottom:T;radiusTopOffset:T;radiusMidOffset:T;rotationMidAngle:T;rotationTopAngle:T;thickness:T;bottomThickness:T;nrSkinCellsHorizontal:T;nrSkinCellsVertical:T;nrSkinCellDivisionsTop:T;nrSkinCellDivisionsBottom:T;skinCellOuterHeight:T;skinCellInnerHeight:T;skinCellBottomHeight:T;skinCellTopHeight:T;precision:T;rotation?:T;scale?:T;origin?:U;direction?:U;}declare class DragonCupDto implements DragonCupDtoBase{constructor(height?:number,radiusBottom?:number,radiusTopOffset?:number,radiusMidOffset?:number,rotationTopAngle?:number,rotationMidAngle?:number,nrSkinCellsVertical?:number,nrSkinCellsHorizontal?:number,nrSkinCellDivisionsTop?:number,nrSkinCellDivisionsBottom?:number,skinCellOuterHeight?:number,skinCellInnerHeight?:number,skinCellBottomHeight?:number,skinCellTopHeight?:number,thickness?:number,bottomThickness?:number,precision?:number,rotation?:number,scale?:number,origin?:Inputs.Base.Point3,direction?:Inputs.Base.Vector3);height:number;radiusBottom:number;radiusTopOffset:number;radiusMidOffset:number;rotationTopAngle:number;rotationMidAngle:number;nrSkinCellsVertical:number;nrSkinCellsHorizontal:number;nrSkinCellDivisionsTop:number;nrSkinCellDivisionsBottom:number;skinCellOuterHeight:number;skinCellInnerHeight:number;skinCellBottomHeight:number;skinCellTopHeight:number;thickness:number;bottomThickness:number;precision:number;rotation:number;scale:number;origin:Inputs.Base.Point3;direction:Inputs.Base.Vector3;}declare class DragonCupModelDto{model:DragonCupData;}}}declare namespace Boxes{declare namespace SpicyBox{declare class SpicyBoxData{type:string;name:string;originalInputs:SpicyBoxDto;compound?:T;}declare class SpicyBoxDtoBase{textTop:V;textFront:V;height:T;coverHeight:T;baseHeight:T;radiusBase:T;radiusOffset:T;thickness:T;ornamentalThickness:T;nrOrnamnetsPerSide:T;invertOrnaments:Z;fillet:T;nrSides:T;nrOffsets:T;precision:T;rotation?:T;scale?:T;origin?:U;direction?:U;}declare class SpicyBoxDto implements SpicyBoxDtoBase{constructor(textTop?:string,textFront?:string,nrSides?:number,nrOffsets?:number,height?:number,coverHeight?:number,baseHeight?:number,radiusBottom?:number,radiusTopOffset?:number,thickness?:number,ornamentalThickness?:number,nrOrnamnetsPerSide?:number,invertOrnaments?:boolean,fillet?:number,precision?:number,rotation?:number,scale?:number,origin?:Inputs.Base.Point3,direction?:Inputs.Base.Vector3);textTop:string;textFront:string;nrSides:number;nrOffsets:number;height:number;radiusBase:number;radiusOffset:number;coverHeight:number;baseHeight:number;thickness:number;ornamentalThickness:number;nrOrnamnetsPerSide:number;invertOrnaments:boolean;fillet:number;precision:number;rotation:number;scale:number;origin:Inputs.Base.Point3;direction:Inputs.Base.Vector3;}declare class SpicyBoxModelDto{model:SpicyBoxData;}}}declare namespace Medals{declare namespace EternalLove{declare class EternalLoveData{type:string;name:string;originalInputs:EternalLoveDto;compound?:T;}declare class EternalLoveDtoBase{textHeading:T;textName:T;fullModel:B;thickness:U;decorationThickness:U;rotation?:U;origin?:V;direction?:V;}declare class EternalLoveDto implements EternalLoveDtoBase{constructor(textHeading?:string,textName?:string,fullModel?:boolean,thickness?:number,decorationThickness?:number,rotation?:number,origin?:Inputs.Base.Point3,direction?:Inputs.Base.Vector3);textHeading:string;textName:string;fullModel:boolean;thickness:number;decorationThickness:number;rotation:number;origin:Inputs.Base.Point3;direction:Inputs.Base.Vector3;}}}declare namespace Desktop{declare namespace PhoneNest{declare class PhoneNestData{type:string;name:string;originalInputs:PhoneNestDto;compound?:T;drawingPart?:PhoneNestDrawingPart;mainPart?:PhoneNestMainPart;shapes?:Models.OCCT.ShapeWithId[];}declare class PhoneNestDrawDto{mainMaterial?:T;phoneMaterial?:T;drawFaces:boolean;precision:number;drawEdges:boolean;edgeColour:Inputs.Base.Color;edgeWidth:number;}declare class PhoneNestDrawingPartShapes{main?:T;phone?:T;}declare class PhoneNestDrawingPart extends Part{shapes?:PhoneNestDrawingPartShapes;}declare class PhoneNestDtoBase{heightBottom:T;heightTop:T;widthBack:T;widthFront:T;length:T;backOffset:T;thickness:T;filletRadius:T;applyOrnaments:B;phoneHeight:T;phoneWidth:T;phoneThickness:T;precision:T;rotation?:T;scale?:T;origin?:U;direction?:U;}declare class PhoneNestDto implements PhoneNestDtoBase{constructor(heightBottom?:number,heightTop?:number,widthBack?:number,widthFront?:number,length?:number,backOffset?:number,thickness?:number,applyOrnaments?:boolean,filletRadius?:number,phoneHeight?:number,phoneWidth?:number,phoneThickness?:number,precision?:number,drawEdges?:boolean,rotation?:number,scale?:number,origin?:Inputs.Base.Point3,direction?:Inputs.Base.Vector3);heightBottom:number;heightTop:number;widthBack:number;widthFront:number;length:number;backOffset:number;thickness:number;applyOrnaments:boolean;filletRadius:number;phoneHeight:number;phoneWidth:number;phoneThickness:number;precision:number;drawEdges:boolean;rotation:number;scale:number;origin:Inputs.Base.Point3;direction:Inputs.Base.Vector3;}declare class PhoneNestModelDto{model:PhoneNestData;}declare class PhoneNestMainPart extends Part{shapes?:{phone?:T;main?:T;compound?:T;};}}}}declare namespace LaserCutting{declare namespace Gadgets{declare namespace DropletsPhoneHolder{declare class DropletsPhoneHolderData{type:string;name:string;compound?:T;originalInputs:DropletsPhoneHolderDto;shapes?:Models.OCCT.ShapeWithId[];drawingPart?:DropletsPhoneHolderDrawingPart;}declare class DropletsPhoneHolderDrawingPartShapes{compound?:T;phoneHolderCompound?:T;cutWiresCompound?:T;engravingWiresCompound?:T;}declare class DropletsPhoneHolderDrawingPart{shapes?:DropletsPhoneHolderDrawingPartShapes|{[x:string]:T;};}declare class DropletsPhoneHolderDtoBase{title?:S;subtitle:S;includeLogo:B;thickness:T;kerf:T;phoneWidth:T;phoneHeight:T;phoneThickness:T;backLength:T;angle:T;offsetAroundPhone:T;penShelf:T;phoneLockHeight:T;filletRadius:T;includePattern:B;densityPattern:T;holesForWire:B;wireInputThickness:T;includeModel:B;includeDrawings:B;spacingDrawings:T;rotation?:T;direction?:V;scale?:V;origin?:V;}declare class DropletsPhoneHolderDto implements DropletsPhoneHolderDtoBase{constructor(title?:string,subtitle?:string,includeLogo?:boolean,thickness?:number,kerf?:number,phoneWidth?:number,phoneHeight?:number,phoneThickness?:number,backLength?:number,angle?:number,offsetAroundPhone?:number,penShelf?:number,phoneLockHeight?:number,filletRadius?:number,includePattern?:boolean,densityPattern?:number,holesForWire?:boolean,wireInputThickness?:number,includeModel?:boolean,includeDrawings?:boolean,spacingDrawings?:number,rotation?:number,origin?:Inputs.Base.Point3,direction?:Inputs.Base.Point3,scale?:Inputs.Base.Vector3);title:string;subtitle:string;includeLogo:boolean;thickness:number;kerf:number;phoneWidth:number;phoneHeight:number;phoneThickness:number;backLength:number;angle:number;offsetAroundPhone:number;penShelf:number;phoneLockHeight:number;filletRadius:number;includePattern:boolean;densityPattern:number;holesForWire:boolean;wireInputThickness:number;includeModel:boolean;includeDrawings:boolean;spacingDrawings:number;rotation:number;origin:Inputs.Base.Point3;direction:Inputs.Base.Point3;scale:Inputs.Base.Vector3;}declare class DropletsPhoneHolderModelDto{model:DropletsPhoneHolderData;}declare class DropletsPhoneHolderModelDxfDto{model:DropletsPhoneHolderData;cutWiresColor:Inputs.Base.Color;engravingWiresColor:Inputs.Base.Color;fileName:string;angularDeflection:number;curvatureDeflection:number;minimumOfPoints:number;uTolerance:number;minimumLength:number;}declare class DropletsPhoneHolderModelStepDto{model:DropletsPhoneHolderData;fileName:string;adjustYZ:boolean;}}}}declare namespace Furniture{declare namespace Chairs{declare namespace SnakeChair{declare class SnakeChairData{type:string;name:string;originalInputs:SnakeChairDto;compound?:T;drawingPart?:SnakeChairDrawingPart;mainPart?:SnakeChairMainPart;shapes?:Models.OCCT.ShapeWithId[];}declare class SnakeChairDrawDto{mainMaterial?:T;drawFaces:boolean;precision:number;drawEdges:boolean;edgeColour:Inputs.Base.Color;edgeWidth:number;}declare class SnakeChairDrawingPartShapes{main?:T;}declare class SnakeChairDrawingPart extends Part{shapes?:SnakeChairDrawingPartShapes;}declare class SnakeChairDtoBase{sittingHeight:T;backRestOffset:T;backRestHeight:T;width:T;length:T;thickness:T;ornamentDepth:T;nrOrnamentPlanks:T;filletRadius:T;precision:T;rotation?:T;scale?:T;origin?:U;direction?:U;}declare class SnakeChairDto implements SnakeChairDtoBase{constructor(sittingHeight?:number,backRestOffset?:number,backRestHeight?:number,width?:number,length?:number,thickness?:number,nrOrnamentPlanks?:number,ornamentDepth?:number,filletRadius?:number,precision?:number,drawEdges?:boolean,rotation?:number,scale?:number,origin?:Inputs.Base.Point3,direction?:Inputs.Base.Vector3);sittingHeight:number;backRestOffset:number;backRestHeight:number;width:number;length:number;thickness:number;nrOrnamentPlanks:number;ornamentDepth:number;filletRadius:number;precision:number;drawEdges:boolean;rotation:number;scale:number;origin:Inputs.Base.Point3;direction:Inputs.Base.Vector3;}declare class SnakeChairModelDto{model:SnakeChairData;}declare class SnakeChairMainPart extends Part{sittingCenter?:Inputs.Base.Point3;shapes?:{sittingWire?:T;compound?:T;};}}}declare namespace Tables{declare namespace ElegantTable{declare class ElegantTableData{type:string;name:string;originalInputs:ElegantTableDto;compound?:T;drawingPart?:ElegantTableDrawingPart;topPart?:ElegantTableTopPart;legParts?:ElegantTableLegPart[];shapes?:Models.OCCT.ShapeWithId[];}declare class ElegantTableDrawDto{topMaterial?:T;topBaseMaterial?:T;legsMaterial?:T;drawFaces:boolean;precision:number;drawEdges:boolean;edgeColour:Inputs.Base.Color;edgeWidth:number;}declare class ElegantTableDrawingPartShapes{top?:T;topBase?:T;legs?:T;}declare class ElegantTableDrawingPart extends Part{shapes?:ElegantTableDrawingPartShapes;}declare class ElegantTableDtoBase{height:T;width:T;length:T;topThickness:T;topOffset:T;bottomThickness:T;minFillet:T;radiusLegTop:T;radiusLegBottom:T;nrLegPairs:T;precision:T;rotation?:T;scale?:T;origin?:U;direction?:U;}declare class ElegantTableDto implements ElegantTableDtoBase{constructor(height?:number,width?:number,length?:number,topThickness?:number,topOffset?:number,bottomThickness?:number,minFillet?:number,radiusLegTop?:number,radiusLegBottom?:number,nrLegPairs?:number,precision?:number,drawEdges?:boolean,rotation?:number,scale?:number,origin?:Inputs.Base.Point3,direction?:Inputs.Base.Vector3);height:number;width:number;length:number;topThickness:number;topOffset:number;bottomThickness:number;minFillet:number;radiusLegTop:number;radiusLegBottom:number;nrLegPairs:number;precision:number;drawEdges:boolean;rotation:number;scale:number;origin:Inputs.Base.Point3;direction:Inputs.Base.Vector3;}declare class ElegantTableLegByIndexDto{model:ElegantTableData;index:number;}declare class ElegantTableLegPart extends Part{topCenter?:Inputs.Base.Point3;bottomCenter?:Inputs.Base.Point3;topRadius?:number;bottomRadius?:number;shapes?:{topCircleWire?:T;bottomCircleWire?:T;leg?:T;};}declare class ElegantTableModelDto{model:ElegantTableData;}declare class ElegantTableTopPart extends Part{topCenter?:Inputs.Base.Point3;bottomCenter?:Inputs.Base.Point3;shapes?:{topPanel?:T;topWire?:T;bottomWire?:T;bottomPanel?:T;compound?:T;};}}declare namespace GoodCoffeeTable{declare class GoodCoffeeTableData{type:string;name:string;originalInputs:GoodCoffeeTableDto;compound?:T;drawingPart?:GoodCoffeeTableDrawingPart;topPart?:GoodCoffeeTableTopPart;shelfPart?:GoodCoffeeTableShelfPart;legParts?:GoodCoffeeTableLegPart[];shapes?:Models.OCCT.ShapeWithId[];}declare class GoodCoffeeTableDrawDto{topGlassMaterial?:T;topMaterial?:T;shelfMaterial?:T;legsMaterial?:T;drawFaces:boolean;precision:number;drawEdges:boolean;edgeColour:Inputs.Base.Color;edgeWidth:number;}declare class GoodCoffeeTableDrawingPartShapes{top?:T;topGlass?:T;shelf?:T;legs?:T;}declare class GoodCoffeeTableDrawingPart extends Part{shapes?:GoodCoffeeTableDrawingPartShapes;}declare class GoodCoffeeTableDtoBase{height:T;width:T;length:T;topThickness:T;topGlassOffset:T;glassThickness:T;glassHolderLength:T;chamfer:T;shelfTopOffset:T;shelfThickness:T;legWidth:T;legDepth:T;precision:T;rotation?:T;scale?:T;origin?:U;direction?:U;}declare class GoodCoffeeTableDto implements GoodCoffeeTableDtoBase{constructor(height?:number,width?:number,length?:number,chamfer?:number,topThickness?:number,topGlassOffset?:number,glassThickness?:number,glassHolderLength?:number,shelfTopOffset?:number,shelfThickness?:number,legWidth?:number,legDepth?:number,precision?:number,drawEdges?:boolean,rotation?:number,scale?:number,origin?:Inputs.Base.Point3,direction?:Inputs.Base.Vector3);height:number;width:number;length:number;chamfer:number;topThickness:number;topGlassOffset:number;glassThickness:number;glassHolderLength:number;shelfTopOffset:number;shelfThickness:number;legWidth:number;legDepth:number;precision:number;drawEdges:boolean;rotation:number;scale:number;origin:Inputs.Base.Point3;direction:Inputs.Base.Vector3;}declare class GoodCoffeeTableLegByIndexDto{model:GoodCoffeeTableData;index:number;}declare class GoodCoffeeTableLegPart extends Part{topCenter?:Inputs.Base.Point3;bottomCenter?:Inputs.Base.Point3;width:number;depth:number;height:number;shapes?:{topWire?:T;bottomWire?:T;leg?:T;};}declare class GoodCoffeeTableModelDto{model:GoodCoffeeTableData;}declare class GoodCoffeeTableShelfPart extends Part{topCenter?:Inputs.Base.Point3;bottomCenter?:Inputs.Base.Point3;shapes?:{topWire?:T;bottomWire?:T;compound?:T;};}declare class GoodCoffeeTableTopPart extends Part{topCenter?:Inputs.Base.Point3;shapes?:{topFrame?:T;topWire?:T;glassWire?:T;glassPanel?:T;compound?:T;};}}declare namespace SnakeTable{declare class SnakeTableData{type:string;name:string;originalInputs:SnakeTableDto;compound?:T;drawingPart?:SnakeTableDrawingPart;mainPart?:SnakeTableMainPart;shapes?:Models.OCCT.ShapeWithId[];}declare class SnakeTableDrawDto{mainMaterial?:T;glassMaterial?:T;drawFaces:boolean;precision:number;drawEdges:boolean;edgeColour:Inputs.Base.Color;edgeWidth:number;}declare class SnakeTableDrawingPartShapes{main?:T;glass?:T;}declare class SnakeTableDrawingPart extends Part{shapes?:SnakeTableDrawingPartShapes;}declare class SnakeTableDtoBase{height:T;width:T;length:T;supportLength:T;shelfHeight:T;glassThickness:T;glassOffset:T;thickness:T;ornamentDepth:T;nrOrnamentPlanks:T;filletRadius:T;precision:T;rotation?:T;scale?:T;origin?:U;direction?:U;}declare class SnakeTableDto implements SnakeTableDtoBase{constructor(height?:number,width?:number,length?:number,supportLength?:number,shelfHeight?:number,thickness?:number,glassThickness?:number,glassOffset?:number,nrOrnamentPlanks?:number,ornamentDepth?:number,filletRadius?:number,precision?:number,drawEdges?:boolean,rotation?:number,scale?:number,origin?:Inputs.Base.Point3,direction?:Inputs.Base.Vector3);height:number;width:number;length:number;supportLength:number;shelfHeight:number;thickness:number;glassThickness:number;glassOffset:number;nrOrnamentPlanks:number;ornamentDepth:number;filletRadius:number;precision:number;drawEdges:boolean;rotation:number;scale:number;origin:Inputs.Base.Point3;direction:Inputs.Base.Vector3;}declare class SnakeTableModelDto{model:SnakeTableData;}declare class SnakeTableMainPart extends Part{topCenter?:Inputs.Base.Point3;shapes?:{topWire?:T;glass?:T;main?:T;compound?:T;};}}}}declare namespace Shared{declare class Part{id?:string;rotation?:number;center?:Inputs.Base.Point3;scale?:Inputs.Base.Vector3;direction?:Inputs.Base.Vector3;}}}declare namespace Advanced{declare namespace Enums{declare enum outputShapeEnum{wire="wire",face="face",solid="solid"}}declare namespace Text3D{declare class CharacterPart{id:string;shapes?:{compound?:T;};}declare class FacePart{id:string;type:faceTypeEnum;shapes?:{face?:T;};}declare enum faceTextVarEnum{separatedExtrusion="separatedExtrusion",integratedExtrusion="integratedExtrusion",cutout="cutout"}declare enum faceTypeEnum{compound="compound",cutout="originalCutout",cutoutInsideCharacter="cutoutInsideCharacter"}declare class FontDefinition{name:string;type?:fontsEnum;variant?:fontVariantsEnum;font:Font;}declare const fontsModel:{key:string;variants:string[];}[];declare enum fontVariantsEnum{Regular="Regular",Black="Black",Bold="Bold",ExtraBold="ExtraBold",Medium="Medium",SemiBold="SemiBold",BlackItalic="BlackItalic",BoldItalic="BoldItalic",Italic="Italic",Light="Light",LightItalic="LightItalic",MediumItalic="MediumItalic",Thin="Thin",ThinItalic="ThinItalic",ExtraLight="ExtraLight"}declare enum fontsEnum{Aboreto="Aboreto",Bungee="Bungee",IndieFlower="IndieFlower",Lugrasimo="Lugrasimo",Orbitron="Orbitron",Roboto="Roboto",RobotoSlab="RobotoSlab",Silkscreen="Silkscreen",Tektur="Tektur",Workbench="Workbench"}declare enum recAlignmentEnum{leftTop="leftTop",leftMiddle="leftMiddle",leftBottom="leftBottom",centerTop="centerTop",centerMiddle="centerMiddle",centerBottom="centerBottom",rightTop="rightTop",rightMiddle="rightMiddle",rightBottom="rightBottom"}declare class Text3DData{type:string;name:string;advanceWidth:number;boundingBox:{x1:number;y1:number;x2:number;y2:number;};originalInputs?:Text3DDto|Texts3DFaceDto;compound?:T;characterParts?:CharacterPart[];faceParts?:FacePart[];shapes?:Models.OCCT.ShapeWithId[];characterCenterCoordinates:Inputs.Base.Point3[];}declare class Text3DDto{constructor(text?:string,fontType?:fontsEnum,fontVariant?:fontVariantsEnum,fontSize?:number,height?:number,rotation?:number,origin?:Inputs.Base.Vector3,direction?:Inputs.Base.Vector3,originAlignment?:recAlignmentEnum);text:string;fontType:fontsEnum;fontVariant:fontVariantsEnum;fontSize:number;height:number;rotation:number;origin:Inputs.Base.Vector3;direction:Inputs.Base.Vector3;originAlignment:recAlignmentEnum;}declare class Text3DFaceDefinitionDto{constructor(faceTextVar?:faceTextVarEnum,text?:string,fontType?:fontsEnum,fontVariant?:fontVariantsEnum,fontSize?:number,height?:number,rotation?:number,originParamU?:number,originParamV?:number,originAlignment?:recAlignmentEnum);faceTextVar:faceTextVarEnum;text:string;fontType:fontsEnum;fontVariant:fontVariantsEnum;fontSize:number;height:number;rotation:number;originParamU:number;originParamV:number;originAlignment:recAlignmentEnum;}declare class Text3DFaceDefinitionUrlDto{constructor(faceTextVar?:faceTextVarEnum,text?:string,fontUrl?:string,fontSize?:number,height?:number,rotation?:number,originParamU?:number,originParamV?:number,originAlignment?:recAlignmentEnum);faceTextVar:faceTextVarEnum;text:string;fontUrl:string;fontSize:number;height:number;rotation:number;originParamU:number;originParamV:number;originAlignment:recAlignmentEnum;}declare class Text3DFaceDefinitionUrlParsedDto{constructor(faceTextVar?:faceTextVarEnum,text?:string,letterPaths?:any,fontSize?:number,height?:number,rotation?:number,originParamU?:number,originParamV?:number,originAlignment?:recAlignmentEnum);faceTextVar:faceTextVarEnum;text:string;letterPaths:any;fontSize:number;height:number;rotation:number;originParamU:number;originParamV:number;originAlignment:recAlignmentEnum;}declare class Text3DFaceDto{constructor(face?:T,facePlanar?:boolean,faceTextVar?:faceTextVarEnum,text?:string,fontType?:fontsEnum,fontVariant?:fontVariantsEnum,fontSize?:number,height?:number,rotation?:number,originParamU?:number,originParamV?:number,originAlignment?:recAlignmentEnum);face:T;facePlanar:boolean;faceTextVar:faceTextVarEnum;text:string;fontType:fontsEnum;fontVariant:fontVariantsEnum;fontSize:number;height:number;rotation:number;originParamU:number;originParamV:number;originAlignment:recAlignmentEnum;}declare class Text3DFaceUrlDto{constructor(face?:T,facePlanar?:boolean,faceTextVar?:faceTextVarEnum,text?:string,fontUrl?:string,fontSize?:number,height?:number,rotation?:number,originParamU?:number,originParamV?:number,originAlignment?:recAlignmentEnum);face:T;facePlanar:boolean;faceTextVar:faceTextVarEnum;text:string;fontUrl:string;fontSize:number;height:number;rotation:number;originParamU:number;originParamV:number;originAlignment:recAlignmentEnum;}declare class Text3DFaceUrlParsedDto{constructor(face?:T,facePlanar?:boolean,faceTextVar?:faceTextVarEnum,text?:string,letterPaths?:any,fontSize?:number,height?:number,rotation?:number,originParamU?:number,originParamV?:number,originAlignment?:recAlignmentEnum);face:T;facePlanar:boolean;faceTextVar:faceTextVarEnum;text:string;letterPaths:any;fontSize:number;height:number;rotation:number;originParamU:number;originParamV:number;originAlignment:recAlignmentEnum;}declare class Text3DLetterByIndexDto{model:Text3DData;index:number;}declare class Text3DModelDto{model:Text3DData;}declare class Text3DUrlDto{constructor(text?:string,fontUrl?:string,fontSize?:number,height?:number,rotation?:number,origin?:Inputs.Base.Vector3,direction?:Inputs.Base.Vector3,originAlignment?:recAlignmentEnum);text:string;fontUrl:string;fontSize:number;height:number;rotation:number;origin:Inputs.Base.Vector3;direction:Inputs.Base.Vector3;originAlignment:recAlignmentEnum;}declare class Text3DUrlParsedDto{constructor(text?:string,letterPaths?:any,fontSize?:number,height?:number,rotation?:number,origin?:Inputs.Base.Vector3,direction?:Inputs.Base.Vector3,originAlignment?:recAlignmentEnum);text:string;letterPaths:any;fontSize:number;height:number;rotation:number;origin:Inputs.Base.Vector3;direction:Inputs.Base.Vector3;originAlignment:recAlignmentEnum;}declare class Texts3DFaceDto{constructor(face:T,facePlanar?:boolean,definitions?:Text3DFaceDefinitionDto[]);face:T;facePlanar:boolean;definitions:Text3DFaceDefinitionDto[];}declare class Texts3DFaceUrlDto{constructor(face:T,facePlanar?:boolean,definitions?:Text3DFaceDefinitionUrlDto[]);face:T;facePlanar:boolean;definitions:Text3DFaceDefinitionUrlDto[];}declare class Texts3DFaceUrlParsedDto{constructor(face:T,facePlanar?:boolean,definitions?:Text3DFaceDefinitionUrlParsedDto[]);face:T;facePlanar:boolean;definitions:Text3DFaceDefinitionUrlParsedDto[];}}declare namespace Patterns{declare namespace FacePatterns{declare namespace PyramidSimple{declare class PyramidSimpleAffectorsDto{constructor(faces?:T[],affectorPoints?:Inputs.Base.Point3[],uNumber?:number,vNumber?:number,minHeight?:number,maxHeight?:number,precision?:number);faces:T[];affectorPoints:Inputs.Base.Point3[];affectorRadiusList?:number[];affectorFactors?:number[];uNumber:number;vNumber:number;defaultHeight:number;affectMinHeight:number;affectMaxHeight:number;precision:number;}declare class PyramidSimpeByIndexDto{model:PyramidSimpleData;index:number;}declare class PyramidSimpleCellPart{id:string;uIndex:number;vIndex:number;cornerPoint1:Inputs.Base.Point3;cornerPoint2:Inputs.Base.Point3;cornerPoint3:Inputs.Base.Point3;cornerPoint4:Inputs.Base.Point3;cornerNormal1?:Inputs.Base.Vector3;cornerNormal2?:Inputs.Base.Vector3;cornerNormal3?:Inputs.Base.Vector3;cornerNormal4?:Inputs.Base.Vector3;centerPoint?:Inputs.Base.Point3;centerNormal?:Inputs.Base.Point3;topPoint?:Inputs.Base.Point3;shapes?:{wire1?:T;wire2?:T;wire3?:T;wire4?:T;face1?:T;face2?:T;face3?:T;face4?:T;compound?:T;};}declare class PyramidSimpleData{type:string;name:string;originalInputs?:PyramidSimpleDto|PyramidSimpleAffectorsDto;compound?:T;shapes?:Models.OCCT.ShapeWithId[];faceParts?:PyramidSimpleFacePart[];topCoordinates:Inputs.Base.Point3[];}declare class PyramidSimpleDto{constructor(faces?:T[],uNumber?:number,vNumber?:number,height?:number);faces:T[];uNumber:number;vNumber:number;height:number;precision:number;}declare class PyramidSimpleFacePart{id:string;cells?:PyramidSimpleCellPart[];shapes?:{compound?:T;startPolylineWireU?:T;startPolylineWireV?:T;endPolylineWireU?:T;endPolylineWireV?:T;compoundPolylineWiresU?:T;compoundPolylineWiresV?:T;compoundPolylineWiresUV?:T;};}declare class PyramidSimpleModelCellDto{cells:PyramidSimpleCellPart;}declare class PyramidSimpleModelCellsDto{cells:PyramidSimpleCellPart[];}declare class PyramidSimpleModelCellsIndexDto{cells:PyramidSimpleCellPart[];index:number;}declare class PyramidSimpleModelDto{model:PyramidSimpleData;}declare class PyramidSimpleModelFaceCellIndexDto{model:PyramidSimpleData;faceIndex:number;uIndex:number;vIndex:number;}declare class PyramidSimpleModelFaceCellsUIndexDto{model:PyramidSimpleData;faceIndex:number;uIndex:number;}declare class PyramidSimpleModelFaceCellsVIndexDto{model:PyramidSimpleData;faceIndex:number;vIndex:number;}declare class PyramidSimpleModelFaceIndexDto{model:PyramidSimpleData;faceIndex:number;}}}}declare namespace Navigation{declare class FocusFromAngleDto{constructor(meshes?:BABYLON.Mesh[],includeChildren?:boolean,orientation?:number[],distance?:number,padding?:number,animationSpeed?:number);meshes:BABYLON.Mesh[];includeChildren:boolean;orientation:number[];distance?:number;padding:number;animationSpeed:number;}declare class PointOfInterestDto{constructor(name?:string,position?:Inputs.Base.Point3,cameraTarget?:Inputs.Base.Point3,cameraPosition?:Inputs.Base.Point3,style?:PointOfInterestStyleDto);name:string;position:Inputs.Base.Point3;cameraTarget:Inputs.Base.Point3;cameraPosition:Inputs.Base.Point3;style?:PointOfInterestStyleDto;}declare class PointOfInterestEntity extends PointOfInterestDto{type:string;entityName:string;}declare class PointOfInterestStyleDto{constructor(pointSize?:number,pointColor?:string,hoverPointColor?:string,pulseColor?:string,pulseMinSize?:number,pulseMaxSize?:number,pulseThickness?:number,pulseSpeed?:number,textColor?:string,hoverTextColor?:string,textSize?:number,textFontWeight?:number,textBackgroundColor?:string,textBackgroundOpacity?:number,textBackgroundStroke?:boolean,textBackgroundStrokeThickness?:number,textBackgroundRadius?:number,textPosition?:Inputs.Base.topBottomEnum,stableSize?:boolean,alwaysOnTop?:boolean);pointSize?:number;pointColor?:Inputs.Base.Color;hoverPointColor?:Inputs.Base.Color;pulseColor?:Inputs.Base.Color;hoverPulseColor?:Inputs.Base.Color;pulseMinSize?:number;pulseMaxSize?:number;pulseThickness?:number;pulseSpeed?:number;textColor?:Inputs.Base.Color;hoverTextColor?:Inputs.Base.Color;textSize?:number;textFontWeight?:number;textBackgroundColor?:Inputs.Base.Color;textBackgroundOpacity:number;textBackgroundStroke:boolean;textBackgroundStrokeThickness:number;textBackgroundRadius:number;textPosition:Inputs.Base.topBottomEnum;stableSize:boolean;alwaysOnTop:boolean;}declare class ZoomOnDto{constructor(meshes?:BABYLON.Mesh[],includeChildren?:boolean,animationSpeed?:number,offset?:number,doNotUpdateMaxZ?:boolean);meshes:BABYLON.Mesh[];includeChildren:boolean;animationSpeed:number;offset:number;doNotUpdateMaxZ:boolean;}}declare namespace Dimensions{declare class AngularDimensionDto{constructor(centerPoint?:Inputs.Base.Point3,direction1?:Inputs.Base.Vector3,direction2?:Inputs.Base.Vector3,radius?:number,labelOffset?:number,decimalPlaces?:number,labelSuffix?:string,labelOverwrite?:string,radians?:boolean,removeTrailingZeros?:boolean,style?:DimensionStyleDto);centerPoint:Inputs.Base.Point3;direction1:Inputs.Base.Vector3;direction2:Inputs.Base.Vector3;radius:number;labelOffset:number;decimalPlaces:number;labelSuffix:string;labelOverwrite:string;radians:boolean;removeTrailingZeros:boolean;style?:DimensionStyleDto;}declare class AngularDimensionEntity extends AngularDimensionDto{type:string;entityName:string;id?:string;}declare class DiametralDimensionDto{constructor(centerPoint?:Inputs.Base.Point3,direction?:Inputs.Base.Vector3,diameter?:number,labelOffset?:number,decimalPlaces?:number,labelSuffix?:string,labelOverwrite?:string,showCenterMark?:boolean,removeTrailingZeros?:boolean,style?:DimensionStyleDto);centerPoint:Inputs.Base.Point3;direction:Inputs.Base.Vector3;diameter:number;labelOffset:number;decimalPlaces:number;labelSuffix:string;labelOverwrite:string;showCenterMark:boolean;removeTrailingZeros:boolean;style?:DimensionStyleDto;}declare class DiametralDimensionEntity extends DiametralDimensionDto{type:string;entityName:string;id?:string;}declare class DimensionStyleDto{constructor(lineColor?:string,lineThickness?:number,extensionLineLength?:number,arrowTailLength?:number,textColor?:string,textSize?:number,textFontWeight?:number,textBackgroundColor?:string,textBackgroundOpacity?:number,textBackgroundStroke?:boolean,textBackgroundStrokeThickness?:number,textBackgroundRadius?:number,textStableSize?:boolean,arrowSize?:number,arrowColor?:string,showArrows?:boolean,textBillboard?:boolean,occlusionCheckInterval?:number,alwaysOnTop?:boolean);lineColor:Inputs.Base.Color;lineThickness:number;extensionLineLength:number;arrowTailLength:number;textColor:Inputs.Base.Color;textSize:number;textFontWeight:number;textBackgroundColor:Inputs.Base.Color;textBackgroundOpacity:number;textBackgroundStroke:boolean;textBackgroundStrokeThickness:number;textBackgroundRadius:number;textStableSize:boolean;arrowSize:number;arrowColor:Inputs.Base.Color;showArrows:boolean;textBillboard:boolean;occlusionCheckInterval:number;alwaysOnTop:boolean;}declare class LinearDimensionDto{constructor(startPoint?:Inputs.Base.Point3,endPoint?:Inputs.Base.Point3,direction?:Inputs.Base.Vector3,labelOffset?:number,decimalPlaces?:number,labelSuffix?:string,labelOverwrite?:string,removeTrailingZeros?:boolean,style?:DimensionStyleDto);startPoint:Inputs.Base.Point3;endPoint:Inputs.Base.Point3;direction:Inputs.Base.Vector3;labelOffset:number;decimalPlaces:number;labelSuffix:string;labelOverwrite:string;removeTrailingZeros:boolean;style?:DimensionStyleDto;}declare class LinearDimensionEntity extends LinearDimensionDto{type:string;entityName:string;id?:string;}declare enum ordinateAxisEnum{x="x",y="y",z="z"}declare class OrdinateDimensionDto{constructor(measurementPoint?:Inputs.Base.Point3,referencePoint?:Inputs.Base.Point3,axis?:ordinateAxisEnum,labelOffset?:number,decimalPlaces?:number,labelSuffix?:string,labelOverwrite?:string,showLeaderLine?:boolean,removeTrailingZeros?:boolean,style?:DimensionStyleDto);measurementPoint:Inputs.Base.Point3;referencePoint:Inputs.Base.Point3;axis:ordinateAxisEnum;labelOffset:number;decimalPlaces:number;labelSuffix:string;labelOverwrite:string;showLeaderLine:boolean;removeTrailingZeros:boolean;style?:DimensionStyleDto;}declare class OrdinateDimensionEntity extends OrdinateDimensionDto{type:string;entityName:string;id?:string;}declare class RadialDimensionDto{constructor(centerPoint?:Inputs.Base.Point3,radiusPoint?:Inputs.Base.Point3,labelOffset?:number,decimalPlaces?:number,labelSuffix?:string,labelOverwrite?:string,showDiameter?:boolean,showCenterMark?:boolean,removeTrailingZeros?:boolean,style?:DimensionStyleDto);centerPoint:Inputs.Base.Point3;radiusPoint:Inputs.Base.Point3;labelOffset:number;decimalPlaces:number;labelSuffix:string;labelOverwrite:string;showDiameter:boolean;showCenterMark:boolean;removeTrailingZeros:boolean;style?:DimensionStyleDto;}declare class RadialDimensionEntity extends RadialDimensionDto{type:string;entityName:string;id?:string;}}}declare class BitByBitJSCAD{jscadWorkerManager:JSCADWorkerManager;jscad:JSCAD;constructor();init(jscad:Worker):void;}declare class JSCADBooleans{private readonly jscadWorkerManager;constructor(jscadWorkerManager:JSCADWorkerManager);intersect(inputs:Inputs.JSCAD.BooleanObjectsDto):Promise;subtract(inputs:Inputs.JSCAD.BooleanObjectsDto):Promise;union(inputs:Inputs.JSCAD.BooleanObjectsDto):Promise;intersectTwo(inputs:Inputs.JSCAD.BooleanTwoObjectsDto):Promise;subtractTwo(inputs:Inputs.JSCAD.BooleanTwoObjectsDto):Promise;unionTwo(inputs:Inputs.JSCAD.BooleanTwoObjectsDto):Promise;subtractFrom(inputs:Inputs.JSCAD.BooleanObjectsFromDto):Promise;}declare class JSCADColors{private readonly jscadWorkerManager;constructor(jscadWorkerManager:JSCADWorkerManager);colorize(inputs:Inputs.JSCAD.ColorizeDto):Promise;}declare class JSCADExpansions{private readonly jscadWorkerManager;constructor(jscadWorkerManager:JSCADWorkerManager);expand(inputs:Inputs.JSCAD.ExpansionDto):Promise;offset(inputs:Inputs.JSCAD.ExpansionDto):Promise;}declare class JSCADExtrusions{private readonly jscadWorkerManager;constructor(jscadWorkerManager:JSCADWorkerManager);extrudeLinear(inputs:Inputs.JSCAD.ExtrudeLinearDto):Promise;extrudeRectangular(inputs:Inputs.JSCAD.ExtrudeRectangularDto):Promise;extrudeRectangularPoints(inputs:Inputs.JSCAD.ExtrudeRectangularPointsDto):Promise;extrudeRotate(inputs:Inputs.JSCAD.ExtrudeRotateDto):Promise;}declare class JSCADHulls{private readonly jscadWorkerManager;constructor(jscadWorkerManager:JSCADWorkerManager);hullChain(inputs:Inputs.JSCAD.HullDto):Promise;hull(inputs:Inputs.JSCAD.HullDto):Promise;}declare class JSCAD{private readonly jscadWorkerManager;readonly booleans:JSCADBooleans;readonly expansions:JSCADExpansions;readonly extrusions:JSCADExtrusions;readonly hulls:JSCADHulls;readonly path:JSCADPath;readonly polygon:JSCADPolygon;readonly shapes:JSCADShapes;readonly text:JSCADText;readonly colors:JSCADColors;constructor(jscadWorkerManager:JSCADWorkerManager);toPolygonPoints(inputs:Inputs.JSCAD.MeshDto):Promise;transformSolids(inputs:Inputs.JSCAD.TransformSolidsDto):Promise;transformSolid(inputs:Inputs.JSCAD.TransformSolidDto):Promise;downloadSolidSTL(inputs:Inputs.JSCAD.DownloadSolidDto):Promise;downloadSolidsSTL(inputs:Inputs.JSCAD.DownloadSolidsDto):Promise;downloadGeometryDxf(inputs:Inputs.JSCAD.DownloadGeometryDto):Promise;downloadGeometry3MF(inputs:Inputs.JSCAD.DownloadGeometryDto):Promise;private downloadFile;}declare class JSCADPath{private readonly jscadWorkerManager;constructor(jscadWorkerManager:JSCADWorkerManager);createFromPoints(inputs:Inputs.JSCAD.PathFromPointsDto):Promise;createPathsFromPoints(inputs:Inputs.JSCAD.PathsFromPointsDto):Promise;createFromPolyline(inputs:Inputs.JSCAD.PathFromPolylineDto):Promise;createEmpty():Promise;close(inputs:Inputs.JSCAD.PathDto):Promise;appendPoints(inputs:Inputs.JSCAD.PathAppendPointsDto):Promise;appendPolyline(inputs:Inputs.JSCAD.PathAppendPolylineDto):Promise;appendArc(inputs:Inputs.JSCAD.PathAppendArcDto):Promise;}declare class JSCADPolygon{private readonly jscadWorkerManager;constructor(jscadWorkerManager:JSCADWorkerManager);createFromPoints(inputs:Inputs.JSCAD.PointsDto):Promise;createFromPolyline(inputs:Inputs.JSCAD.PolylineDto):Promise;createFromCurve(inputs:Inputs.JSCAD.CurveDto):Promise;createFromPath(inputs:Inputs.JSCAD.PathDto):Promise;circle(inputs:Inputs.JSCAD.CircleDto):Promise;ellipse(inputs:Inputs.JSCAD.EllipseDto):Promise;rectangle(inputs:Inputs.JSCAD.RectangleDto):Promise;roundedRectangle(inputs:Inputs.JSCAD.RoundedRectangleDto):Promise;square(inputs:Inputs.JSCAD.SquareDto):Promise;star(inputs:Inputs.JSCAD.StarDto):Promise;}declare class JSCADShapes{private readonly jscadWorkerManager;constructor(jscadWorkerManager:JSCADWorkerManager);cube(inputs:Inputs.JSCAD.CubeDto):Promise;cubesOnCenterPoints(inputs:Inputs.JSCAD.CubeCentersDto):Promise;cuboid(inputs:Inputs.JSCAD.CuboidDto):Promise;cuboidsOnCenterPoints(inputs:Inputs.JSCAD.CuboidCentersDto):Promise;cylinderElliptic(inputs:Inputs.JSCAD.CylidnerEllipticDto):Promise;cylinderEllipticOnCenterPoints(inputs:Inputs.JSCAD.CylidnerCentersEllipticDto):Promise;cylinder(inputs:Inputs.JSCAD.CylidnerDto):Promise;cylindersOnCenterPoints(inputs:Inputs.JSCAD.CylidnerCentersDto):Promise;ellipsoid(inputs:Inputs.JSCAD.EllipsoidDto):Promise;ellipsoidsOnCenterPoints(inputs:Inputs.JSCAD.EllipsoidCentersDto):Promise;geodesicSphere(inputs:Inputs.JSCAD.GeodesicSphereDto):Promise;geodesicSpheresOnCenterPoints(inputs:Inputs.JSCAD.GeodesicSphereCentersDto):Promise;roundedCuboid(inputs:Inputs.JSCAD.RoundedCuboidDto):Promise;roundedCuboidsOnCenterPoints(inputs:Inputs.JSCAD.RoundedCuboidCentersDto):Promise;roundedCylinder(inputs:Inputs.JSCAD.RoundedCylidnerDto):Promise;roundedCylindersOnCenterPoints(inputs:Inputs.JSCAD.RoundedCylidnerCentersDto):Promise;sphere(inputs:Inputs.JSCAD.SphereDto):Promise;spheresOnCenterPoints(inputs:Inputs.JSCAD.SphereCentersDto):Promise;torus(inputs:Inputs.JSCAD.TorusDto):Promise;fromPolygonPoints(inputs:Inputs.JSCAD.FromPolygonPoints):Promise;}declare class JSCADText{private readonly jscadWorkerManager;constructor(jscadWorkerManager:JSCADWorkerManager);cylindricalText(inputs:Inputs.JSCAD.CylinderTextDto):Promise;sphericalText(inputs:Inputs.JSCAD.SphereTextDto):Promise;createVectorText(inputs:Inputs.JSCAD.TextDto):Promise;}declare class BitByBitManifold{manifoldWorkerManager:ManifoldWorkerManager;manifold:ManifoldBitByBit;constructor();init(manifold:Worker):void;}declare class CrossSectionBooleans{private readonly manifoldWorkerManager;constructor(manifoldWorkerManager:ManifoldWorkerManager);subtract(inputs:Inputs.Manifold.TwoCrossSectionsDto):Promise;add(inputs:Inputs.Manifold.TwoCrossSectionsDto):Promise;intersect(inputs:Inputs.Manifold.TwoCrossSectionsDto):Promise;differenceTwo(inputs:Inputs.Manifold.TwoCrossSectionsDto):Promise;unionTwo(inputs:Inputs.Manifold.TwoCrossSectionsDto):Promise;intersectionTwo(inputs:Inputs.Manifold.TwoCrossSectionsDto):Promise;difference(inputs:Inputs.Manifold.CrossSectionsDto):Promise;union(inputs:Inputs.Manifold.CrossSectionsDto):Promise;intersection(inputs:Inputs.Manifold.CrossSectionsDto):Promise;}declare class ManifoldCrossSection{private readonly manifoldWorkerManager;shapes:CrossSectionShapes;operations:CrossSectionOperations;booleans:CrossSectionBooleans;transforms:CrossSectionTransforms;evaluate:CrossSectionEvaluate;constructor(manifoldWorkerManager:ManifoldWorkerManager);crossSectionFromPoints(inputs:Inputs.Manifold.CrossSectionFromPolygonPointsDto):Promise;crossSectionFromPolygons(inputs:Inputs.Manifold.CrossSectionFromPolygonsPointsDto):Promise;crossSectionToPolygons(inputs:Inputs.Manifold.CrossSectionDto):Promise;crossSectionToPoints(inputs:Inputs.Manifold.CrossSectionDto):Promise;crossSectionsToPolygons(inputs:Inputs.Manifold.CrossSectionsDto):Promise;crossSectionsToPoints(inputs:Inputs.Manifold.CrossSectionsDto):Promise;}declare class CrossSectionEvaluate{private readonly manifoldWorkerManager;constructor(manifoldWorkerManager:ManifoldWorkerManager);area(inputs:Inputs.Manifold.CrossSectionDto):Promise;isEmpty(inputs:Inputs.Manifold.CrossSectionDto):Promise;numVert(inputs:Inputs.Manifold.CrossSectionDto):Promise;numContour(inputs:Inputs.Manifold.CrossSectionDto):Promise;bounds(inputs:Inputs.Manifold.CrossSectionDto):Promise;}declare class CrossSectionOperations{private readonly manifoldWorkerManager;constructor(manifoldWorkerManager:ManifoldWorkerManager);hull(inputs:Inputs.Manifold.CrossSectionDto):Promise;extrude(inputs:Inputs.Manifold.ExtrudeDto):Promise;revolve(inputs:Inputs.Manifold.RevolveDto):Promise;offset(inputs:Inputs.Manifold.OffsetDto):Promise;simplify(inputs:Inputs.Manifold.SimplifyDto):Promise;compose(inputs:Inputs.Manifold.ComposeDto<(Inputs.Manifold.CrossSectionPointer|Inputs.Base.Vector2[])[]>):Promise;decompose(inputs:Inputs.Manifold.CrossSectionDto):Promise;}declare class CrossSectionShapes{private readonly manifoldWorkerManager;constructor(manifoldWorkerManager:ManifoldWorkerManager);create(inputs:Inputs.Manifold.CreateContourSectionDto):Promise;square(inputs:Inputs.Manifold.SquareDto):Promise;circle(inputs:Inputs.Manifold.CircleDto):Promise;rectangle(inputs:Inputs.Manifold.RectangleDto):Promise;}declare class CrossSectionTransforms{private readonly manifoldWorkerManager;constructor(manifoldWorkerManager:ManifoldWorkerManager);scale2D(inputs:Inputs.Manifold.Scale2DCrossSectionDto):Promise;scale(inputs:Inputs.Manifold.ScaleCrossSectionDto):Promise;mirror(inputs:Inputs.Manifold.MirrorCrossSectionDto):Promise;translate(inputs:Inputs.Manifold.TranslateCrossSectionDto):Promise;translateXY(inputs:Inputs.Manifold.TranslateXYCrossSectionDto):Promise;rotate(inputs:Inputs.Manifold.RotateCrossSectionDto):Promise;transform(inputs:Inputs.Manifold.TransformCrossSectionDto):Promise;warp(inputs:Inputs.Manifold.CrossSectionWarpDto):Promise;}declare class ManifoldBooleans{private readonly manifoldWorkerManager;constructor(manifoldWorkerManager:ManifoldWorkerManager);subtract(inputs:Inputs.Manifold.TwoManifoldsDto):Promise;add(inputs:Inputs.Manifold.TwoManifoldsDto):Promise;intersect(inputs:Inputs.Manifold.TwoManifoldsDto):Promise;differenceTwo(inputs:Inputs.Manifold.TwoManifoldsDto):Promise;unionTwo(inputs:Inputs.Manifold.TwoManifoldsDto):Promise;intersectionTwo(inputs:Inputs.Manifold.TwoManifoldsDto):Promise;difference(inputs:Inputs.Manifold.ManifoldsDto):Promise;union(inputs:Inputs.Manifold.ManifoldsDto):Promise;intersection(inputs:Inputs.Manifold.ManifoldsDto):Promise;split(inputs:Inputs.Manifold.SplitManifoldsDto):Promise;splitByPlane(inputs:Inputs.Manifold.SplitByPlaneDto):Promise;splitByPlaneOnOffsets(inputs:Inputs.Manifold.SplitByPlaneOnOffsetsDto):Promise;trimByPlane(inputs:Inputs.Manifold.TrimByPlaneDto):Promise;}declare class ManifoldEvaluate{private readonly manifoldWorkerManager;constructor(manifoldWorkerManager:ManifoldWorkerManager);surfaceArea(inputs:Inputs.Manifold.ManifoldDto):Promise;volume(inputs:Inputs.Manifold.ManifoldDto):Promise;isEmpty(inputs:Inputs.Manifold.ManifoldDto):Promise;numVert(inputs:Inputs.Manifold.ManifoldDto):Promise;numTri(inputs:Inputs.Manifold.ManifoldDto):Promise;numEdge(inputs:Inputs.Manifold.ManifoldDto):Promise;numProp(inputs:Inputs.Manifold.ManifoldDto):Promise;numPropVert(inputs:Inputs.Manifold.ManifoldDto):Promise;boundingBox(inputs:Inputs.Manifold.ManifoldDto):Promise;tolerance(inputs:Inputs.Manifold.ManifoldDto):Promise;genus(inputs:Inputs.Manifold.ManifoldDto):Promise;minGap(inputs:Inputs.Manifold.ManifoldsMinGapDto):Promise;originalID(inputs:Inputs.Manifold.ManifoldDto):Promise;status(inputs:Inputs.Manifold.ManifoldDto):Promise;}declare class Manifold{private readonly manifoldWorkerManager;readonly shapes:ManifoldShapes;readonly booleans:ManifoldBooleans;readonly operations:ManifoldOperations;readonly transforms:ManifoldTransforms;readonly evaluate:ManifoldEvaluate;constructor(manifoldWorkerManager:ManifoldWorkerManager);manifoldToMesh(inputs:Inputs.Manifold.ManifoldToMeshDto):Promise;manifoldsToMeshes(inputs:Inputs.Manifold.ManifoldsToMeshesDto):Promise;}declare class ManifoldOperations{private readonly manifoldWorkerManager;constructor(manifoldWorkerManager:ManifoldWorkerManager);hull(inputs:Inputs.Manifold.ManifoldDto):Promise;hullPoints(inputs:Inputs.Manifold.HullPointsDto<(Inputs.Base.Point3|Inputs.Manifold.ManifoldPointer)[]>):Promise;slice(inputs:Inputs.Manifold.SliceDto):Promise;project(inputs:Inputs.Manifold.ManifoldDto):Promise;setTolerance(inputs:Inputs.Manifold.ManifoldRefineToleranceDto):Promise;reserveIds(inputs:Inputs.Manifold.CountDto):Promise;asOriginal(inputs:Inputs.Manifold.ManifoldDto):Promise;compose(inputs:Inputs.Manifold.ManifoldsDto):Promise;decompose(inputs:Inputs.Manifold.ManifoldDto):Promise;calculateNormals(inputs:Inputs.Manifold.CalculateNormalsDto):Promise;calculateCurvature(inputs:Inputs.Manifold.CalculateCurvatureDto):Promise;refineToTolerance(inputs:Inputs.Manifold.ManifoldRefineToleranceDto):Promise;refineToLength(inputs:Inputs.Manifold.ManifoldRefineLengthDto):Promise;refine(inputs:Inputs.Manifold.ManifoldRefineDto):Promise;smoothOut(inputs:Inputs.Manifold.ManifoldSmoothOutDto):Promise;smoothByNormals(inputs:Inputs.Manifold.ManifoldSmoothByNormalsDto):Promise;simplify(inputs:Inputs.Manifold.ManifoldSimplifyDto):Promise;setProperties(inputs:Inputs.Manifold.ManifoldSetPropertiesDto):Promise;}declare class ManifoldShapes{private readonly manifoldWorkerManager;constructor(manifoldWorkerManager:ManifoldWorkerManager);manifoldFromMesh(inputs:Inputs.Manifold.CreateFromMeshDto):Promise;fromPolygonPoints(inputs:Inputs.Manifold.FromPolygonPointsDto):Promise;cube(inputs:Inputs.Manifold.CubeDto):Promise;sphere(inputs:Inputs.Manifold.SphereDto):Promise;tetrahedron():Promise;cylinder(inputs:Inputs.Manifold.CylinderDto):Promise;}declare class ManifoldTransforms{private readonly manifoldWorkerManager;constructor(manifoldWorkerManager:ManifoldWorkerManager);scale3D(inputs:Inputs.Manifold.Scale3DDto):Promise;scale(inputs:Inputs.Manifold.ScaleDto):Promise;mirror(inputs:Inputs.Manifold.MirrorDto):Promise;translate(inputs:Inputs.Manifold.TranslateDto):Promise;translateByVectors(inputs:Inputs.Manifold.TranslateByVectorsDto):Promise;translateXYZ(inputs:Inputs.Manifold.TranslateXYZDto):Promise;rotate(inputs:Inputs.Manifold.RotateDto):Promise;rotateXYZ(inputs:Inputs.Manifold.RotateXYZDto):Promise;transform(inputs:Inputs.Manifold.TransformDto):Promise;transforms(inputs:Inputs.Manifold.TransformsDto):Promise;warp(inputs:Inputs.Manifold.ManifoldWarpDto):Promise;}declare class ManifoldBitByBit{private readonly manifoldWorkerManager;readonly manifold:Manifold;readonly crossSection:ManifoldCrossSection;readonly mesh:Mesh;constructor(manifoldWorkerManager:ManifoldWorkerManager);manifoldToMeshPointer(inputs:Inputs.Manifold.ManifoldToMeshDto):Promise;decomposeManifoldOrCrossSection(inputs:Inputs.Manifold.DecomposeManifoldOrCrossSectionDto):Promise;toPolygonPoints(inputs:Inputs.Manifold.ManifoldDto):Promise;decomposeManifoldsOrCrossSections(inputs:Inputs.Manifold.DecomposeManifoldsOrCrossSectionsDto):Promise<(Inputs.Manifold.DecomposedManifoldMeshDto|Inputs.Base.Vector2[][])[]>;deleteManifoldOrCrossSection(inputs:Inputs.Manifold.ManifoldOrCrossSectionDto):Promise;deleteManifoldsOrCrossSections(inputs:Inputs.Manifold.ManifoldsOrCrossSectionsDto):Promise;}declare class MeshEvaluate{private readonly manifoldWorkerManager;constructor(manifoldWorkerManager:ManifoldWorkerManager);position(inputs:Inputs.Manifold.MeshVertexIndexDto):Promise;verts(inputs:Inputs.Manifold.MeshTriangleIndexDto):Promise;tangent(inputs:Inputs.Manifold.MeshHalfEdgeIndexDto):Promise;extras(inputs:Inputs.Manifold.MeshVertexIndexDto):Promise;transform(inputs:Inputs.Manifold.MeshVertexIndexDto):Promise;numProp(inputs:Inputs.Manifold.MeshDto):Promise;numVert(inputs:Inputs.Manifold.MeshDto):Promise;numTri(inputs:Inputs.Manifold.MeshDto):Promise;numRun(inputs:Inputs.Manifold.MeshDto):Promise;}declare class Mesh{private readonly manifoldWorkerManager;readonly operations:MeshOperations;readonly evaluate:MeshEvaluate;constructor(manifoldWorkerManager:ManifoldWorkerManager);}declare class MeshOperations{private readonly manifoldWorkerManager;constructor(manifoldWorkerManager:ManifoldWorkerManager);merge(inputs:Inputs.Manifold.MeshDto):Promise;}declare class BitByBitOCCT{occtWorkerManager:OCCTWorkerManager;occt:OCCT;constructor();init(occt:Worker):void;}declare class OCCTBooleans{private readonly occWorkerManager;constructor(occWorkerManager:OCCTWorkerManager);union(inputs:Inputs.OCCT.UnionDto):Promise;difference(inputs:Inputs.OCCT.DifferenceDto):Promise;intersection(inputs:Inputs.OCCT.IntersectionDto):Promise;meshMeshIntersectionWires(inputs:Inputs.OCCT.MeshMeshIntersectionTwoShapesDto):Promise;meshMeshIntersectionPoints(inputs:Inputs.OCCT.MeshMeshIntersectionTwoShapesDto):Promise;meshMeshIntersectionOfShapesWires(inputs:Inputs.OCCT.MeshMeshesIntersectionOfShapesDto):Promise;meshMeshIntersectionOfShapesPoints(inputs:Inputs.OCCT.MeshMeshesIntersectionOfShapesDto):Promise;}declare class OCCTDimensions{private readonly occWorkerManager;constructor(occWorkerManager:OCCTWorkerManager);simpleLinearLengthDimension(inputs:Inputs.OCCT.SimpleLinearLengthDimensionDto):Promise;simpleAngularDimension(inputs:Inputs.OCCT.SimpleAngularDimensionDto):Promise;pinWithLabel(inputs:Inputs.OCCT.PinWithLabelDto):Promise;}declare class OCCTFillets{private readonly occWorkerManager;constructor(occWorkerManager:OCCTWorkerManager);filletEdges(inputs:Inputs.OCCT.FilletDto):Promise;filletEdgesList(inputs:Inputs.OCCT.FilletEdgesListDto):Promise;filletEdgesListOneRadius(inputs:Inputs.OCCT.FilletEdgesListOneRadiusDto):Promise;filletEdgeVariableRadius(inputs:Inputs.OCCT.FilletEdgeVariableRadiusDto):Promise;filletEdgesSameVariableRadius(inputs:Inputs.OCCT.FilletEdgesSameVariableRadiusDto):Promise;filletEdgesVariableRadius(inputs:Inputs.OCCT.FilletEdgesVariableRadiusDto):Promise;fillet3DWire(inputs:Inputs.OCCT.Fillet3DWireDto):Promise;fillet3DWires(inputs:Inputs.OCCT.Fillet3DWiresDto):Promise;chamferEdges(inputs:Inputs.OCCT.ChamferDto):Promise;chamferEdgesList(inputs:Inputs.OCCT.ChamferEdgesListDto):Promise;chamferEdgeTwoDistances(inputs:Inputs.OCCT.ChamferEdgeTwoDistancesDto):Promise;chamferEdgesTwoDistances(inputs:Inputs.OCCT.ChamferEdgesTwoDistancesDto):Promise;chamferEdgesTwoDistancesLists(inputs:Inputs.OCCT.ChamferEdgesTwoDistancesListsDto):Promise;chamferEdgeDistAngle(inputs:Inputs.OCCT.ChamferEdgeDistAngleDto):Promise;chamferEdgesDistAngle(inputs:Inputs.OCCT.ChamferEdgesDistAngleDto):Promise;chamferEdgesDistsAngles(inputs:Inputs.OCCT.ChamferEdgesDistsAnglesDto):Promise;fillet2d(inputs:Inputs.OCCT.FilletDto):Promise;fillet2dShapes(inputs:Inputs.OCCT.FilletShapesDto):Promise;filletTwoEdgesInPlaneIntoAWire(inputs:Inputs.OCCT.FilletTwoEdgesInPlaneDto):Promise;}declare class OCCTCurves{private readonly occWorkerManager;constructor(occWorkerManager:OCCTWorkerManager);geom2dEllipse(inputs:Inputs.OCCT.Geom2dEllipseDto):Promise;geom2dTrimmedCurve(inputs:Inputs.OCCT.Geom2dTrimmedCurveDto):Promise;geom2dSegment(inputs:Inputs.OCCT.Geom2dSegmentDto):Promise;get2dPointFrom2dCurveOnParam(inputs:Inputs.OCCT.DataOnGeometryAtParamDto):Promise;geomCircleCurve(inputs:Inputs.OCCT.CircleDto):Promise;geomEllipseCurve(inputs:Inputs.OCCT.EllipseDto):Promise;}declare class OCCTGeom{readonly curves:OCCTCurves;readonly surfaces:OCCTSurfaces;constructor(occWorkerManager:OCCTWorkerManager);}declare class OCCTSurfaces{private readonly occWorkerManager;constructor(occWorkerManager:OCCTWorkerManager);cylindricalSurface(inputs:Inputs.OCCT.GeomCylindricalSurfaceDto):Promise;surfaceFromFace(inputs:Inputs.OCCT.ShapeDto):Promise;}declare class OCCTIO{readonly occWorkerManager:OCCTWorkerManager;constructor(occWorkerManager:OCCTWorkerManager);saveShapeSTEP(inputs:Inputs.OCCT.SaveStepDto):Promise;saveShapeSTEPAndReturn(inputs:Inputs.OCCT.SaveStepDto):Promise;saveShapeStl(inputs:Inputs.OCCT.SaveStlDto):Promise;saveShapeStlAndReturn(inputs:Inputs.OCCT.SaveStlDto):Promise;private saveSTEP;private saveStl;shapeToDxfPaths(inputs:Inputs.OCCT.ShapeToDxfPathsDto):Promise;dxfPathsWithLayer(inputs:Inputs.OCCT.DxfPathsWithLayerDto):Promise;dxfCreate(inputs:Inputs.OCCT.DxfPathsPartsListDto):Promise;}declare class OCCT{readonly occWorkerManager:OCCTWorkerManager;readonly shapes:OCCTShapes;readonly geom:OCCTGeom;readonly fillets:OCCTFillets;readonly transforms:OCCTTransforms;readonly operations:OCCTOperations;readonly booleans:OCCTBooleans;readonly dimensions:OCCTDimensions;readonly shapeFix:OCCTShapeFix;io:OCCTIO;constructor(occWorkerManager:OCCTWorkerManager);shapeFacesToPolygonPoints(inputs:Inputs.OCCT.ShapeFacesToPolygonPointsDto):Promise;shapeToMesh(inputs:Inputs.OCCT.ShapeToMeshDto):Promise;shapesToMeshes(inputs:Inputs.OCCT.ShapesToMeshesDto):Promise;deleteShape(inputs:Inputs.OCCT.ShapeDto):Promise;deleteShapes(inputs:Inputs.OCCT.ShapesDto):Promise;cleanAllCache():Promise;}declare class OCCTOperations{private readonly occWorkerManager;constructor(occWorkerManager:OCCTWorkerManager);loft(inputs:Inputs.OCCT.LoftDto):Promise;loftAdvanced(inputs:Inputs.OCCT.LoftAdvancedDto):Promise;closestPointsBetweenTwoShapes(inputs:Inputs.OCCT.ClosestPointsBetweenTwoShapesDto):Promise;closestPointsOnShapeFromPoints(inputs:Inputs.OCCT.ClosestPointsOnShapeFromPointsDto):Promise;closestPointsOnShapesFromPoints(inputs:Inputs.OCCT.ClosestPointsOnShapesFromPointsDto):Promise;distancesToShapeFromPoints(inputs:Inputs.OCCT.ClosestPointsOnShapeFromPointsDto):Promise;boundingBoxOfShape(inputs:Inputs.OCCT.ShapeDto):Promise;boundingBoxMinOfShape(inputs:Inputs.OCCT.ShapeDto):Promise;boundingBoxMaxOfShape(inputs:Inputs.OCCT.ShapeDto):Promise;boundingBoxCenterOfShape(inputs:Inputs.OCCT.ShapeDto):Promise;boundingBoxSizeOfShape(inputs:Inputs.OCCT.ShapeDto):Promise;boundingBoxShapeOfShape(inputs:Inputs.OCCT.ShapeDto):Promise;boundingSphereOfShape(inputs:Inputs.OCCT.ShapeDto):Promise;boundingSphereCenterOfShape(inputs:Inputs.OCCT.ShapeDto):Promise;boundingSphereRadiusOfShape(inputs:Inputs.OCCT.ShapeDto):Promise;boundingSphereShapeOfShape(inputs:Inputs.OCCT.ShapeDto):Promise;extrude(inputs:Inputs.OCCT.ExtrudeDto):Promise;extrudeShapes(inputs:Inputs.OCCT.ExtrudeShapesDto):Promise;splitShapeWithShapes(inputs:Inputs.OCCT.SplitDto):Promise;revolve(inputs:Inputs.OCCT.RevolveDto):Promise;rotatedExtrude(inputs:Inputs.OCCT.RotationExtrudeDto):Promise;pipe(inputs:Inputs.OCCT.ShapeShapesDto):Promise;pipePolylineWireNGon(inputs:Inputs.OCCT.PipePolygonWireNGonDto):Promise;pipeWiresCylindrical(inputs:Inputs.OCCT.PipeWiresCylindricalDto):Promise;pipeWireCylindrical(inputs:Inputs.OCCT.PipeWireCylindricalDto):Promise;offset(inputs:Inputs.OCCT.OffsetDto):Promise;offsetAdv(inputs:Inputs.OCCT.OffsetAdvancedDto):Promise;makeThickSolidSimple(inputs:Inputs.OCCT.ThisckSolidSimpleDto):Promise;makeThickSolidByJoin(inputs:Inputs.OCCT.ThickSolidByJoinDto):Promise;slice(inputs:Inputs.OCCT.SliceDto):Promise;sliceInStepPattern(inputs:Inputs.OCCT.SliceInStepPatternDto):Promise;offset3DWire(inputs:Inputs.OCCT.Offset3DWireDto):Promise;}declare class OCCTShapeFix{private readonly occWorkerManager;constructor(occWorkerManager:OCCTWorkerManager);basicShapeRepair(inputs:Inputs.OCCT.BasicShapeRepairDto):Promise;fixSmallEdgeOnWire(inputs:Inputs.OCCT.FixSmallEdgesInWireDto):Promise;fixEdgeOrientationsAlongWire(inputs:Inputs.OCCT.ShapeDto):Promise;}declare class OCCTCompound{private readonly occWorkerManager;constructor(occWorkerManager:OCCTWorkerManager);makeCompound(inputs:Inputs.OCCT.CompoundShapesDto):Promise;getShapesOfCompound(inputs:Inputs.OCCT.ShapeDto):Promise;}declare class OCCTEdge{private readonly occWorkerManager;constructor(occWorkerManager:OCCTWorkerManager);fromBaseLine(inputs:Inputs.OCCT.LineBaseDto):Promise;fromBaseLines(inputs:Inputs.OCCT.LineBaseDto):Promise;fromBaseSegment(inputs:Inputs.OCCT.SegmentBaseDto):Promise;fromBaseSegments(inputs:Inputs.OCCT.SegmentsBaseDto):Promise;fromPoints(inputs:Inputs.OCCT.PointsDto):Promise;fromBasePolyline(inputs:Inputs.OCCT.PolylineBaseDto):Promise;fromBaseTriangle(inputs:Inputs.OCCT.TriangleBaseDto):Promise;fromBaseMesh(inputs:Inputs.OCCT.MeshBaseDto):Promise;line(inputs:Inputs.OCCT.LineDto):Promise;arcThroughThreePoints(inputs:Inputs.OCCT.ArcEdgeThreePointsDto):Promise;arcThroughTwoPointsAndTangent(inputs:Inputs.OCCT.ArcEdgeTwoPointsTangentDto):Promise;arcFromCircleAndTwoPoints(inputs:Inputs.OCCT.ArcEdgeCircleTwoPointsDto):Promise;arcFromCircleAndTwoAngles(inputs:Inputs.OCCT.ArcEdgeCircleTwoAnglesDto):Promise;arcFromCirclePointAndAngle(inputs:Inputs.OCCT.ArcEdgeCirclePointAngleDto):Promise;createCircleEdge(inputs:Inputs.OCCT.CircleDto):Promise;createEllipseEdge(inputs:Inputs.OCCT.EllipseDto):Promise;removeInternalEdges(inputs:Inputs.OCCT.ShapeDto):Promise;makeEdgeFromGeom2dCurveAndSurface(inputs:Inputs.OCCT.CurveAndSurfaceDto):Promise;getEdge(inputs:Inputs.OCCT.EdgeIndexDto):Promise;getEdges(inputs:Inputs.OCCT.ShapeDto):Promise;getEdgesAlongWire(inputs:Inputs.OCCT.ShapeDto):Promise;getCircularEdgesAlongWire(inputs:Inputs.OCCT.ShapeDto):Promise;getLinearEdgesAlongWire(inputs:Inputs.OCCT.ShapeDto):Promise;getCornerPointsOfEdgesForShape(inputs:Inputs.OCCT.ShapeDto):Promise;getEdgeLength(inputs:Inputs.OCCT.ShapeDto):Promise;getEdgeLengthsOfShape(inputs:Inputs.OCCT.ShapeDto):Promise;getEdgesLengths(inputs:Inputs.OCCT.ShapesDto):Promise;getEdgeCenterOfMass(inputs:Inputs.OCCT.ShapeDto):Promise;getEdgesCentersOfMass(inputs:Inputs.OCCT.ShapesDto):Promise;getCircularEdgeCenterPoint(inputs:Inputs.OCCT.ShapeDto):Promise;getCircularEdgeRadius(inputs:Inputs.OCCT.ShapeDto):Promise;getCircularEdgePlaneDirection(inputs:Inputs.OCCT.ShapeDto):Promise;pointOnEdgeAtParam(inputs:Inputs.OCCT.DataOnGeometryAtParamDto):Promise;pointsOnEdgesAtParam(inputs:Inputs.OCCT.DataOnGeometryesAtParamDto):Promise;edgesToPoints(inputs:Inputs.OCCT.EdgesToPointsDto):Promise;reversedEdge(inputs:Inputs.OCCT.ShapeDto):Promise;tangentOnEdgeAtParam(inputs:Inputs.OCCT.DataOnGeometryAtParamDto):Promise;tangentsOnEdgesAtParam(inputs:Inputs.OCCT.DataOnGeometryesAtParamDto):Promise;pointOnEdgeAtLength(inputs:Inputs.OCCT.DataOnGeometryAtLengthDto):Promise;pointsOnEdgesAtLength(inputs:Inputs.OCCT.DataOnGeometryesAtLengthDto):Promise;tangentOnEdgeAtLength(inputs:Inputs.OCCT.DataOnGeometryAtLengthDto):Promise;tangentsOnEdgesAtLength(inputs:Inputs.OCCT.DataOnGeometryesAtLengthDto):Promise;startPointOnEdge(inputs:Inputs.OCCT.ShapeDto):Promise;startPointsOnEdges(inputs:Inputs.OCCT.ShapesDto):Promise;endPointOnEdge(inputs:Inputs.OCCT.ShapeDto):Promise;endPointsOnEdges(inputs:Inputs.OCCT.ShapesDto):Promise;divideEdgeByParamsToPoints(inputs:Inputs.OCCT.DivideDto):Promise;divideEdgesByParamsToPoints(inputs:Inputs.OCCT.DivideShapesDto):Promise;divideEdgeByEqualDistanceToPoints(inputs:Inputs.OCCT.DivideDto):Promise;divideEdgesByEqualDistanceToPoints(inputs:Inputs.OCCT.DivideShapesDto):Promise;constraintTanLinesFromTwoPtsToCircle(inputs:Inputs.OCCT.ConstraintTanLinesFromTwoPtsToCircleDto):Promise;constraintTanLinesFromPtToCircle(inputs:Inputs.OCCT.ConstraintTanLinesFromPtToCircleDto):Promise;constraintTanLinesOnTwoCircles(inputs:Inputs.OCCT.ConstraintTanLinesOnTwoCirclesDto):Promise;constraintTanCirclesOnTwoCircles(inputs:Inputs.OCCT.ConstraintTanCirclesOnTwoCirclesDto):Promise;constraintTanCirclesOnCircleAndPnt(inputs:Inputs.OCCT.ConstraintTanCirclesOnCircleAndPntDto):Promise;isEdgeLinear(inputs:Inputs.OCCT.ShapeDto):Promise;isEdgeCircular(inputs:Inputs.OCCT.ShapeDto):Promise;}declare class OCCTFace{private readonly occWorkerManager;constructor(occWorkerManager:OCCTWorkerManager);fromBaseTriangle(inputs:Inputs.OCCT.TriangleBaseDto):Promise;fromBaseMesh(inputs:Inputs.OCCT.MeshBaseDto):Promise;createFacesFromWiresOnFace(inputs:Inputs.OCCT.FacesFromWiresOnFaceDto):Promise;createFaceFromWireOnFace(inputs:Inputs.OCCT.FaceFromWireOnFaceDto):Promise;createFaceFromWire(inputs:Inputs.OCCT.FaceFromWireDto):Promise;createFaceFromWires(inputs:Inputs.OCCT.FaceFromWiresDto):Promise;createFaceFromWiresOnFace(inputs:Inputs.OCCT.FaceFromWiresOnFaceDto):Promise;createFacesFromWires(inputs:Inputs.OCCT.FacesFromWiresDto):Promise;createFaceFromMultipleCircleTanWires(inputs:Inputs.OCCT.FaceFromMultipleCircleTanWiresDto):Promise;createFaceFromMultipleCircleTanWireCollections(inputs:Inputs.OCCT.FaceFromMultipleCircleTanWireCollectionsDto):Promise;faceFromSurface(inputs:Inputs.OCCT.ShapeDto):Promise;faceFromSurfaceAndWire(inputs:Inputs.OCCT.FaceFromSurfaceAndWireDto):Promise;createPolygonFace(inputs:Inputs.OCCT.PolygonDto):Promise;createCircleFace(inputs:Inputs.OCCT.CircleDto):Promise;hexagonsInGrid(inputs:Inputs.OCCT.HexagonsInGridDto):Promise;createEllipseFace(inputs:Inputs.OCCT.EllipseDto):Promise;createSquareFace(inputs:Inputs.OCCT.SquareDto):Promise;createRectangleFace(inputs:Inputs.OCCT.RectangleDto):Promise;createLPolygonFace(inputs:Inputs.OCCT.LPolygonDto):Promise;createStarFace(inputs:Inputs.OCCT.StarDto):Promise;createChristmasTreeFace(inputs:Inputs.OCCT.ChristmasTreeDto):Promise;createParallelogramFace(inputs:Inputs.OCCT.ParallelogramDto):Promise;createHeartFace(inputs:Inputs.OCCT.Heart2DDto):Promise;createNGonFace(inputs:Inputs.OCCT.NGonWireDto):Promise;createIBeamProfileFace(inputs:Inputs.OCCT.IBeamProfileDto):Promise;createHBeamProfileFace(inputs:Inputs.OCCT.HBeamProfileDto):Promise;createTBeamProfileFace(inputs:Inputs.OCCT.TBeamProfileDto):Promise;createUBeamProfileFace(inputs:Inputs.OCCT.UBeamProfileDto):Promise;getFace(inputs:Inputs.OCCT.ShapeIndexDto):Promise;getFaces(inputs:Inputs.OCCT.ShapeDto):Promise;reversedFace(inputs:Inputs.OCCT.ShapeDto):Promise;subdivideToPoints(inputs:Inputs.OCCT.FaceSubdivisionDto):Promise;subdivideToWires(inputs:Inputs.OCCT.FaceSubdivisionToWiresDto):Promise;subdivideToRectangleWires(inputs:Inputs.OCCT.FaceSubdivideToRectangleWiresDto):Promise;subdivideToRectangleHoles(inputs:Inputs.OCCT.FaceSubdivideToRectangleHolesDto):Promise;subdivideToHexagonWires(inputs:Inputs.OCCT.FaceSubdivideToHexagonWiresDto):Promise;subdivideToHexagonHoles(inputs:Inputs.OCCT.FaceSubdivideToHexagonHolesDto):Promise;subdivideToPointsControlled(inputs:Inputs.OCCT.FaceSubdivisionControlledDto):Promise;subdivideToNormals(inputs:Inputs.OCCT.FaceSubdivisionDto):Promise;subdivideToUV(inputs:Inputs.OCCT.FaceSubdivisionDto):Promise;pointOnUV(inputs:Inputs.OCCT.DataOnUVDto):Promise;normalOnUV(inputs:Inputs.OCCT.DataOnUVDto):Promise;pointsOnUVs(inputs:Inputs.OCCT.DataOnUVsDto):Promise;normalsOnUVs(inputs:Inputs.OCCT.DataOnUVsDto):Promise;subdivideToPointsOnParam(inputs:Inputs.OCCT.FaceLinearSubdivisionDto):Promise;wireAlongParam(inputs:Inputs.OCCT.WireAlongParamDto):Promise;wiresAlongParams(inputs:Inputs.OCCT.WiresAlongParamsDto):Promise;getUMinBound(inputs:Inputs.OCCT.ShapeDto):Promise;getUMaxBound(inputs:Inputs.OCCT.ShapeDto):Promise;getVMinBound(inputs:Inputs.OCCT.ShapeDto):Promise;getVMaxBound(inputs:Inputs.OCCT.ShapeDto):Promise;getFaceArea(inputs:Inputs.OCCT.ShapeDto):Promise;getFacesAreas(inputs:Inputs.OCCT.ShapesDto):Promise;getFaceCenterOfMass(inputs:Inputs.OCCT.ShapeDto):Promise;getFacesCentersOfMass(inputs:Inputs.OCCT.ShapesDto):Promise;filterFacePoints(inputs:Inputs.OCCT.FilterFacePointsDto):Promise;filterFacesPoints(inputs:Inputs.OCCT.FilterFacesPointsDto):Promise;}declare class OCCTShape{private readonly occWorkerManager;constructor(occWorkerManager:OCCTWorkerManager);purgeInternalEdges(inputs:Inputs.OCCT.ShapeDto):Promise;unifySameDomain(inputs:Inputs.OCCT.UnifySameDomainDto):Promise;isClosed(inputs:Inputs.OCCT.ShapeDto):Promise;isConvex(inputs:Inputs.OCCT.ShapeDto):Promise;isChecked(inputs:Inputs.OCCT.ShapeDto):Promise;isFree(inputs:Inputs.OCCT.ShapeDto):Promise;isInfinite(inputs:Inputs.OCCT.ShapeDto):Promise;isModified(inputs:Inputs.OCCT.ShapeDto):Promise;isLocked(inputs:Inputs.OCCT.ShapeDto):Promise;isNull(inputs:Inputs.OCCT.ShapeDto):Promise;isEqual(inputs:Inputs.OCCT.CompareShapesDto):Promise;isNotEqual(inputs:Inputs.OCCT.CompareShapesDto):Promise;isPartner(inputs:Inputs.OCCT.CompareShapesDto):Promise;isSame(inputs:Inputs.OCCT.CompareShapesDto):Promise;getOrientation(inputs:Inputs.OCCT.ShapeDto):Promise;getShapeType(inputs:Inputs.OCCT.ShapeDto):Promise;}declare class OCCTShapes{readonly vertex:OCCTVertex;readonly edge:OCCTEdge;readonly wire:OCCTWire;readonly face:OCCTFace;readonly shell:OCCTShell;readonly solid:OCCTSolid;readonly compound:OCCTCompound;readonly shape:OCCTShape;constructor(occWorkerManager:OCCTWorkerManager);}declare class OCCTShell{private readonly occWorkerManager;constructor(occWorkerManager:OCCTWorkerManager);sewFaces(inputs:Inputs.OCCT.SewDto):Promise;getShellSurfaceArea(inputs:Inputs.OCCT.ShapeDto):Promise;}declare class OCCTSolid{private readonly occWorkerManager;constructor(occWorkerManager:OCCTWorkerManager);fromClosedShell(inputs:Inputs.OCCT.ShapeDto):Promise;createBox(inputs:Inputs.OCCT.BoxDto):Promise;createCube(inputs:Inputs.OCCT.CubeDto):Promise;createBoxFromCorner(inputs:Inputs.OCCT.BoxFromCornerDto):Promise;createCylinder(inputs:Inputs.OCCT.CylinderDto):Promise;createCylindersOnLines(inputs:Inputs.OCCT.CylindersOnLinesDto):Promise;createSphere(inputs:Inputs.OCCT.SphereDto):Promise;createCone(inputs:Inputs.OCCT.ConeDto):Promise;createStarSolid(inputs:Inputs.OCCT.StarSolidDto):Promise;createNGonSolid(inputs:Inputs.OCCT.NGonSolidDto):Promise;createParallelogramSolid(inputs:Inputs.OCCT.ParallelogramSolidDto):Promise;createHeartSolid(inputs:Inputs.OCCT.HeartSolidDto):Promise;createChristmasTreeSolid(inputs:Inputs.OCCT.ChristmasTreeSolidDto):Promise;createLPolygonSolid(inputs:Inputs.OCCT.LPolygonSolidDto):Promise;createIBeamProfileSolid(inputs:Inputs.OCCT.IBeamProfileSolidDto):Promise;createHBeamProfileSolid(inputs:Inputs.OCCT.HBeamProfileSolidDto):Promise;createTBeamProfileSolid(inputs:Inputs.OCCT.TBeamProfileSolidDto):Promise;createUBeamProfileSolid(inputs:Inputs.OCCT.UBeamProfileSolidDto):Promise;getSolidSurfaceArea(inputs:Inputs.OCCT.ShapeDto):Promise;getSolidVolume(inputs:Inputs.OCCT.ShapeDto):Promise;getSolidsVolumes(inputs:Inputs.OCCT.ShapesDto):Promise;getSolidCenterOfMass(inputs:Inputs.OCCT.ShapeDto):Promise;getSolidsCentersOfMass(inputs:Inputs.OCCT.ShapesDto):Promise;getSolids(inputs:Inputs.OCCT.ShapeDto):Promise;filterSolidPoints(inputs:Inputs.OCCT.FilterSolidPointsDto):Promise;}declare class OCCTVertex{private readonly occWorkerManager;constructor(occWorkerManager:OCCTWorkerManager);vertexFromXYZ(inputs:Inputs.OCCT.XYZDto):Promise;vertexFromPoint(inputs:Inputs.OCCT.PointDto):Promise;verticesFromPoints(inputs:Inputs.OCCT.PointsDto):Promise;verticesCompoundFromPoints(inputs:Inputs.OCCT.PointsDto):Promise;getVertices(inputs:Inputs.OCCT.ShapeDto):Promise;getVerticesAsPoints(inputs:Inputs.OCCT.ShapeDto):Promise;verticesToPoints(inputs:Inputs.OCCT.ShapesDto):Promise;vertexToPoint(inputs:Inputs.OCCT.ShapesDto):Promise;projectPoints(inputs:Inputs.OCCT.ProjectPointsOnShapeDto):Promise;}declare class OCCTWire{private readonly occWorkerManager;constructor(occWorkerManager:OCCTWorkerManager);fromBaseLine(inputs:Inputs.OCCT.LineBaseDto):Promise;fromBaseLines(inputs:Inputs.OCCT.LineBaseDto):Promise;fromBaseSegment(inputs:Inputs.OCCT.SegmentBaseDto):Promise;fromBaseSegments(inputs:Inputs.OCCT.SegmentsBaseDto):Promise;fromPoints(inputs:Inputs.OCCT.PointsDto):Promise;fromBasePolyline(inputs:Inputs.OCCT.PolylineBaseDto):Promise;fromBaseTriangle(inputs:Inputs.OCCT.TriangleBaseDto):Promise;fromBaseMesh(inputs:Inputs.OCCT.MeshBaseDto):Promise;createPolygonWire(inputs:Inputs.OCCT.PolygonDto):Promise;createPolygons(inputs:Inputs.OCCT.PolygonsDto):Promise;createLineWire(inputs:Inputs.OCCT.LineDto):Promise;createLineWireWithExtensions(inputs:Inputs.OCCT.LineWithExtensionsDto):Promise;createLines(inputs:Inputs.OCCT.LinesDto):Promise;splitOnPoints(inputs:Inputs.OCCT.SplitWireOnPointsDto):Promise;wiresToPoints(inputs:Inputs.OCCT.WiresToPointsDto):Promise;createPolylineWire(inputs:Inputs.OCCT.PolylineDto):Promise;createZigZagBetweenTwoWires(inputs:Inputs.OCCT.ZigZagBetweenTwoWiresDto):Promise;createWireFromTwoCirclesTan(inputs:Inputs.OCCT.WireFromTwoCirclesTanDto):Promise;createPolylines(inputs:Inputs.OCCT.PolylinesDto):Promise;createBezier(inputs:Inputs.OCCT.BezierDto):Promise;createBezierWeights(inputs:Inputs.OCCT.BezierWeightsDto):Promise;createBezierWires(inputs:Inputs.OCCT.BezierWiresDto):Promise;interpolatePoints(inputs:Inputs.OCCT.InterpolationDto):Promise;interpolateWires(inputs:Inputs.OCCT.InterpolateWiresDto):Promise;createBSpline(inputs:Inputs.OCCT.BSplineDto):Promise;createBSplines(inputs:Inputs.OCCT.BSplinesDto):Promise;combineEdgesAndWiresIntoAWire(inputs:Inputs.OCCT.ShapesDto):Promise;createWireFromEdge(inputs:Inputs.OCCT.ShapeDto):Promise;addEdgesAndWiresToWire(inputs:Inputs.OCCT.ShapeShapesDto):Promise;divideWireByParamsToPoints(inputs:Inputs.OCCT.DivideDto):Promise;divideWiresByParamsToPoints(inputs:Inputs.OCCT.DivideShapesDto):Promise;divideWireByEqualDistanceToPoints(inputs:Inputs.OCCT.DivideDto):Promise;divideWiresByEqualDistanceToPoints(inputs:Inputs.OCCT.DivideShapesDto):Promise;pointOnWireAtParam(inputs:Inputs.OCCT.DataOnGeometryAtParamDto):Promise;pointOnWireAtLength(inputs:Inputs.OCCT.DataOnGeometryAtLengthDto):Promise;pointsOnWireAtLengths(inputs:Inputs.OCCT.DataOnGeometryAtLengthsDto):Promise;pointsOnWireAtEqualLength(inputs:Inputs.OCCT.PointsOnWireAtEqualLengthDto):Promise;pointsOnWireAtPatternOfLengths(inputs:Inputs.OCCT.PointsOnWireAtPatternOfLengthsDto):Promise;tangentOnWireAtParam(inputs:Inputs.OCCT.DataOnGeometryAtParamDto):Promise;tangentOnWireAtLength(inputs:Inputs.OCCT.DataOnGeometryAtLengthDto):Promise;derivativesOnWireAtLength(inputs:Inputs.OCCT.DataOnGeometryAtLengthDto):Promise<[Inputs.Base.Vector3,Inputs.Base.Vector3,Inputs.Base.Vector3]>;derivativesOnWireAtParam(inputs:Inputs.OCCT.DataOnGeometryAtParamDto):Promise<[Inputs.Base.Vector3,Inputs.Base.Vector3,Inputs.Base.Vector3]>;startPointOnWire(inputs:Inputs.OCCT.ShapeDto):Promise;midPointOnWire(inputs:Inputs.OCCT.ShapeDto):Promise;endPointOnWire(inputs:Inputs.OCCT.ShapeDto):Promise;createCircleWire(inputs:Inputs.OCCT.CircleDto):Promise;hexagonsInGrid(inputs:Inputs.OCCT.HexagonsInGridDto):Promise;createSquareWire(inputs:Inputs.OCCT.SquareDto):Promise;createStarWire(inputs:Inputs.OCCT.StarDto):Promise;createChristmasTreeWire(inputs:Inputs.OCCT.ChristmasTreeDto):Promise;createNGonWire(inputs:Inputs.OCCT.NGonWireDto):Promise;createParallelogramWire(inputs:Inputs.OCCT.ParallelogramDto):Promise;createHeartWire(inputs:Inputs.OCCT.Heart2DDto):Promise;createRectangleWire(inputs:Inputs.OCCT.RectangleDto):Promise;createLPolygonWire(inputs:Inputs.OCCT.LPolygonDto):Promise;createIBeamProfileWire(inputs:Inputs.OCCT.IBeamProfileDto):Promise;createHBeamProfileWire(inputs:Inputs.OCCT.HBeamProfileDto):Promise;createTBeamProfileWire(inputs:Inputs.OCCT.TBeamProfileDto):Promise;createUBeamProfileWire(inputs:Inputs.OCCT.UBeamProfileDto):Promise;createEllipseWire(inputs:Inputs.OCCT.EllipseDto):Promise;textWires(inputs:Inputs.OCCT.TextWiresDto):Promise;textWiresWithData(inputs:Inputs.OCCT.TextWiresDto):Promise>;getWire(inputs:Inputs.OCCT.ShapeIndexDto):Promise;getWires(inputs:Inputs.OCCT.ShapeDto):Promise;getWireCenterOfMass(inputs:Inputs.OCCT.ShapeDto):Promise;getWiresCentersOfMass(inputs:Inputs.OCCT.ShapesDto):Promise;reversedWire(inputs:Inputs.OCCT.ShapeDto):Promise;reversedWireFromReversedEdges(inputs:Inputs.OCCT.ShapeDto):Promise;isWireClosed(inputs:Inputs.OCCT.ShapeDto):Promise;getWireLength(inputs:Inputs.OCCT.ShapeDto):Promise;getWiresLengths(inputs:Inputs.OCCT.ShapesDto):Promise;placeWireOnFace(inputs:Inputs.OCCT.WireOnFaceDto):Promise;placeWiresOnFace(inputs:Inputs.OCCT.WiresOnFaceDto):Promise;closeOpenWire(inputs:Inputs.OCCT.ShapeDto):Promise;project(inputs:Inputs.OCCT.ProjectWireDto):Promise;projectWires(inputs:Inputs.OCCT.ProjectWiresDto):Promise;}declare class OCCTTransforms{private readonly occWorkerManager;constructor(occWorkerManager:OCCTWorkerManager);transform(inputs:Inputs.OCCT.TransformDto):Promise;rotate(inputs:Inputs.OCCT.RotateDto):Promise;rotateAroundCenter(inputs:Inputs.OCCT.RotateAroundCenterDto):Promise;align(inputs:Inputs.OCCT.AlignDto):Promise;alignNormAndAxis(inputs:Inputs.OCCT.AlignNormAndAxisDto):Promise;alignAndTranslate(inputs:Inputs.OCCT.AlignAndTranslateDto):Promise;translate(inputs:Inputs.OCCT.TranslateDto):Promise;scale(inputs:Inputs.OCCT.ScaleDto):Promise;scale3d(inputs:Inputs.OCCT.Scale3DDto):Promise;mirror(inputs:Inputs.OCCT.MirrorDto):Promise;mirrorAlongNormal(inputs:Inputs.OCCT.MirrorAlongNormalDto):Promise;transformShapes(inputs:Inputs.OCCT.TransformShapesDto):Promise;rotateShapes(inputs:Inputs.OCCT.RotateShapesDto):Promise;rotateAroundCenterShapes(inputs:Inputs.OCCT.RotateAroundCenterShapesDto):Promise;alignShapes(inputs:Inputs.OCCT.AlignShapesDto):Promise;alignAndTranslateShapes(inputs:Inputs.OCCT.AlignAndTranslateShapesDto):Promise;translateShapes(inputs:Inputs.OCCT.TranslateShapesDto):Promise;scaleShapes(inputs:Inputs.OCCT.ScaleShapesDto):Promise;scale3dShapes(inputs:Inputs.OCCT.Scale3DShapesDto):Promise;mirrorShapes(inputs:Inputs.OCCT.MirrorShapesDto):Promise;mirrorAlongNormalShapes(inputs:Inputs.OCCT.MirrorAlongNormalShapesDto):Promise;}declare class Draw extends DrawCore{readonly drawHelper:DrawHelper;readonly context:Context;readonly tag:Tag;private defaultBasicOptions;private defaultPolylineOptions;constructor(drawHelper:DrawHelper,context:Context,tag:Tag);drawAnyAsync(inputs:Inputs.Draw.DrawAny):Promise;drawAny(inputs:Inputs.Draw.DrawAny):THREEJS.Group;optionsSimple(inputs:Inputs.Draw.DrawBasicGeometryOptions):Inputs.Draw.DrawBasicGeometryOptions;optionsOcctShape(inputs:Inputs.Draw.DrawOcctShapeOptions):Inputs.Draw.DrawOcctShapeOptions;createTexture(inputs:Inputs.Draw.GenericTextureDto):THREEJS.Texture;createPBRMaterial(inputs:Inputs.Draw.GenericPBRMaterialDto):THREEJS.MeshStandardMaterial;private handleJscadMesh;private handleJscadMeshes;private handleManifoldShape;private handleManifoldShapes;private handleOcctShape;private handleOcctShapes;private handleLine;private handlePoint;private handlePolyline;private handleVerbCurve;private handleVerbSurface;private handlePolylines;private handleLines;private handlePoints;private handleVerbCurves;private handleVerbSurfaces;private handleTag;private handleTags;private updateAny;private handle;private handleAsync;private applyGlobalSettingsAndMetadataAndShadowCasting;}declare class ThreeJS{private readonly drawHelper;constructor(drawHelper:DrawHelper);}declare class Color{private readonly math;constructor(math:MathBitByBit);hexColor(inputs:Inputs.Color.HexDto):Inputs.Base.Color;hexToRgb(inputs:Inputs.Color.HexDto):Inputs.Base.ColorRGB;rgbToHex(inputs:Inputs.Color.RGBMinMaxDto):Inputs.Base.Color;rgbObjToHex(inputs:Inputs.Color.RGBObjectMaxDto):Inputs.Base.Color;hexToRgbMapped(inputs:Inputs.Color.HexDtoMapped):Inputs.Base.ColorRGB;getRedParam(inputs:Inputs.Color.HexDtoMapped):number;getGreenParam(inputs:Inputs.Color.HexDtoMapped):number;getBlueParam(inputs:Inputs.Color.HexDtoMapped):number;rgbToRed(inputs:Inputs.Color.RGBObjectDto):number;rgbToGreen(inputs:Inputs.Color.RGBObjectDto):number;rgbToBlue(inputs:Inputs.Color.RGBObjectDto):number;invert(inputs:Inputs.Color.InvertHexDto):Inputs.Base.Color;}declare class Dates{toDateString(inputs:Inputs.Dates.DateDto):string;toISOString(inputs:Inputs.Dates.DateDto):string;toJSON(inputs:Inputs.Dates.DateDto):string;toString(inputs:Inputs.Dates.DateDto):string;toTimeString(inputs:Inputs.Dates.DateDto):string;toUTCString(inputs:Inputs.Dates.DateDto):string;now():Date;createDate(inputs:Inputs.Dates.CreateDateDto):Date;createDateUTC(inputs:Inputs.Dates.CreateDateDto):Date;createFromUnixTimeStamp(inputs:Inputs.Dates.CreateFromUnixTimeStampDto):Date;parseDate(inputs:Inputs.Dates.DateStringDto):number;getDayOfMonth(inputs:Inputs.Dates.DateDto):number;getWeekday(inputs:Inputs.Dates.DateDto):number;getYear(inputs:Inputs.Dates.DateDto):number;getMonth(inputs:Inputs.Dates.DateDto):number;getHours(inputs:Inputs.Dates.DateDto):number;getMinutes(inputs:Inputs.Dates.DateDto):number;getSeconds(inputs:Inputs.Dates.DateDto):number;getMilliseconds(inputs:Inputs.Dates.DateDto):number;getTime(inputs:Inputs.Dates.DateDto):number;getUTCYear(inputs:Inputs.Dates.DateDto):number;getUTCMonth(inputs:Inputs.Dates.DateDto):number;getUTCDay(inputs:Inputs.Dates.DateDto):number;getUTCHours(inputs:Inputs.Dates.DateDto):number;getUTCMinutes(inputs:Inputs.Dates.DateDto):number;getUTCSeconds(inputs:Inputs.Dates.DateDto):number;getUTCMilliseconds(inputs:Inputs.Dates.DateDto):number;setYear(inputs:Inputs.Dates.DateYearDto):Date;setMonth(inputs:Inputs.Dates.DateMonthDto):Date;setDayOfMonth(inputs:Inputs.Dates.DateDayDto):Date;setHours(inputs:Inputs.Dates.DateHoursDto):Date;setMinutes(inputs:Inputs.Dates.DateMinutesDto):Date;setSeconds(inputs:Inputs.Dates.DateSecondsDto):Date;setMilliseconds(inputs:Inputs.Dates.DateMillisecondsDto):Date;setTime(inputs:Inputs.Dates.DateTimeDto):Date;setUTCYear(inputs:Inputs.Dates.DateYearDto):Date;setUTCMonth(inputs:Inputs.Dates.DateMonthDto):Date;setUTCDay(inputs:Inputs.Dates.DateDayDto):Date;setUTCHours(inputs:Inputs.Dates.DateHoursDto):Date;setUTCMinutes(inputs:Inputs.Dates.DateMinutesDto):Date;setUTCSeconds(inputs:Inputs.Dates.DateSecondsDto):Date;setUTCMilliseconds(inputs:Inputs.Dates.DateMillisecondsDto):Date;}declare class GeometryHelper{transformControlPoints(transformation:number[][]|number[][][],transformedControlPoints:Inputs.Base.Point3[]):Inputs.Base.Point3[];getFlatTransformations(transformation:number[][]|number[][][]):number[][];getArrayDepth:(value:any)=>number;transformPointsByMatrixArray(points:Inputs.Base.Point3[],transform:number[]):Inputs.Base.Point3[];transformPointsCoordinates(points:Inputs.Base.Point3[],transform:number[]):Inputs.Base.Point3[];removeAllDuplicateVectors(vectors:number[][],tolerance?:number):number[][];removeConsecutiveVectorDuplicates(vectors:number[][],checkFirstAndLast?:boolean,tolerance?:number):number[][];vectorsTheSame(vec1:number[],vec2:number[],tolerance:number):boolean;approxEq(num1:number,num2:number,tolerance:number):boolean;removeConsecutivePointDuplicates(points:Inputs.Base.Point3[],checkFirstAndLast?:boolean,tolerance?:number):Inputs.Base.Point3[];arePointsTheSame(pointA:Inputs.Base.Point3|Inputs.Base.Point2,pointB:Inputs.Base.Point3|Inputs.Base.Point2,tolerance:number):boolean;private transformCoordinates;}declare class DxfGenerator{private entityHandle;private colorFormat;private acadVersion;generateDxf(dxfInputs:Inputs.IO.DxfModelDto):string;private generateHeader;private generateTables;private generateLineTypeTable;private generateStyleTable;private generateVportTable;private generateViewTable;private generateUcsTable;private generateAppidTable;private generateDimstyleTable;private generateBlocks;private generateLayerTable;private generateEntities;private generateSegmentEntity;private isLineSegment;private isArcSegment;private isCircleSegment;private isPolylineSegment;private isSplineSegment;private generateLineEntity;private generateCircleEntity;private generateArcEntity;private generatePolylineEntity;private generateSplineEntity;private isClosedPolyline;private getNextHandle;private convertColorToDxf;private rgbToAciColorIndex;}declare class Dxf{private dxfGenerator;lineSegment(inputs:Inputs.IO.DxfLineSegmentDto):Inputs.IO.DxfLineSegmentDto;arcSegment(inputs:Inputs.IO.DxfArcSegmentDto):Inputs.IO.DxfArcSegmentDto;circleSegment(inputs:Inputs.IO.DxfCircleSegmentDto):Inputs.IO.DxfCircleSegmentDto;polylineSegment(inputs:Inputs.IO.DxfPolylineSegmentDto):Inputs.IO.DxfPolylineSegmentDto;splineSegment(inputs:Inputs.IO.DxfSplineSegmentDto):Inputs.IO.DxfSplineSegmentDto;path(inputs:Inputs.IO.DxfPathDto):Inputs.IO.DxfPathDto;pathsPart(inputs:Inputs.IO.DxfPathsPartDto):Inputs.IO.DxfPathsPartDto;dxfCreate(inputs:Inputs.IO.DxfModelDto):string;}declare class IoBitByBit{dxf:Dxf;constructor();}declare class Line{private readonly vector;private readonly point;private readonly geometryHelper;constructor(vector:Vector,point:Point,geometryHelper:GeometryHelper);getStartPoint(inputs:Inputs.Line.LineDto):Inputs.Base.Point3;getEndPoint(inputs:Inputs.Line.LineDto):Inputs.Base.Point3;length(inputs:Inputs.Line.LineDto):number;reverse(inputs:Inputs.Line.LineDto):Inputs.Base.Line3;transformLine(inputs:Inputs.Line.TransformLineDto):Inputs.Base.Line3;transformsForLines(inputs:Inputs.Line.TransformsLinesDto):Inputs.Base.Line3[];create(inputs:Inputs.Line.LinePointsDto):Inputs.Base.Line3;createSegment(inputs:Inputs.Line.LinePointsDto):Inputs.Base.Segment3;getPointOnLine(inputs:Inputs.Line.PointOnLineDto):Inputs.Base.Point3;linesBetweenPoints(inputs:Inputs.Line.PointsLinesDto):Inputs.Base.Line3[];linesBetweenStartAndEndPoints(inputs:Inputs.Line.LineStartEndPointsDto):Inputs.Base.Line3[];lineToSegment(inputs:Inputs.Line.LineDto):Inputs.Base.Segment3;linesToSegments(inputs:Inputs.Line.LinesDto):Inputs.Base.Segment3[];segmentToLine(inputs:Inputs.Line.SegmentDto):Inputs.Base.Line3;segmentsToLines(inputs:Inputs.Line.SegmentsDto):Inputs.Base.Line3[];lineLineIntersection(inputs:Inputs.Line.LineLineIntersectionDto):Inputs.Base.Point3|undefined;}declare class Lists{getItem(inputs:Inputs.Lists.ListItemDto):T;getFirstItem(inputs:Inputs.Lists.ListCloneDto):T;getLastItem(inputs:Inputs.Lists.ListCloneDto):T;randomGetThreshold(inputs:Inputs.Lists.RandomThresholdDto):T[];getSubList(inputs:Inputs.Lists.SubListDto):T[];getNthItem(inputs:Inputs.Lists.GetNthItemDto):T[];getByPattern(inputs:Inputs.Lists.GetByPatternDto):T[];mergeElementsOfLists(inputs:Inputs.Lists.MergeElementsOfLists):T[];getLongestListLength(inputs:Inputs.Lists.GetLongestListLength):number;reverse(inputs:Inputs.Lists.ListCloneDto):T[];shuffle(inputs:Inputs.Lists.ListCloneDto):T[];flipLists(inputs:Inputs.Lists.ListCloneDto):T[][];groupNth(inputs:Inputs.Lists.GroupListDto):T[][];includes(inputs:Inputs.Lists.IncludesDto):boolean;findIndex(inputs:Inputs.Lists.IncludesDto):number;getListDepth(inputs:Inputs.Lists.ListCloneDto<[]>):number;listLength(inputs:Inputs.Lists.ListCloneDto):number;addItemAtIndex(inputs:Inputs.Lists.AddItemAtIndexDto):T[];addItemAtIndexes(inputs:Inputs.Lists.AddItemAtIndexesDto):T[];addItemsAtIndexes(inputs:Inputs.Lists.AddItemsAtIndexesDto):T[];removeItemAtIndex(inputs:Inputs.Lists.RemoveItemAtIndexDto):T[];removeFirstItem(inputs:Inputs.Lists.ListCloneDto):T[];removeLastItem(inputs:Inputs.Lists.ListCloneDto):T[];removeItemAtIndexFromEnd(inputs:Inputs.Lists.RemoveItemAtIndexDto):T[];removeItemsAtIndexes(inputs:Inputs.Lists.RemoveItemsAtIndexesDto):T[];removeAllItems(inputs:Inputs.Lists.ListDto):T[];removeNthItem(inputs:Inputs.Lists.RemoveNthItemDto):T[];randomRemoveThreshold(inputs:Inputs.Lists.RandomThresholdDto):T[];removeDuplicateNumbers(inputs:Inputs.Lists.RemoveDuplicatesDto):number[];removeDuplicateNumbersTolerance(inputs:Inputs.Lists.RemoveDuplicatesToleranceDto):number[];removeDuplicates(inputs:Inputs.Lists.RemoveDuplicatesDto):T[];addItem(inputs:Inputs.Lists.AddItemDto):T[];prependItem(inputs:Inputs.Lists.AddItemDto):T[];addItemFirstLast(inputs:Inputs.Lists.AddItemFirstLastDto):T[];concatenate(inputs:Inputs.Lists.ConcatenateDto):T[];createEmptyList():[];repeat(inputs:Inputs.Lists.MultiplyItemDto):T[];repeatInPattern(inputs:Inputs.Lists.RepeatInPatternDto):T[];sortNumber(inputs:Inputs.Lists.SortDto):number[];sortTexts(inputs:Inputs.Lists.SortDto):string[];sortByPropValue(inputs:Inputs.Lists.SortJsonDto):any[];interleave(inputs:Inputs.Lists.InterleaveDto):T[];}declare class Logic{boolean(inputs:Inputs.Logic.BooleanDto):boolean;randomBooleans(inputs:Inputs.Logic.RandomBooleansDto):boolean[];twoThresholdRandomGradient(inputs:Inputs.Logic.TwoThresholdRandomGradientDto):boolean[];thresholdBooleanList(inputs:Inputs.Logic.ThresholdBooleanListDto):boolean[];thresholdGapsBooleanList(inputs:Inputs.Logic.ThresholdGapsBooleanListDto):boolean[];not(inputs:Inputs.Logic.BooleanDto):boolean;notList(inputs:Inputs.Logic.BooleanListDto):boolean[];compare(inputs:Inputs.Logic.ComparisonDto):boolean;valueGate(inputs:Inputs.Logic.ValueGateDto):T|undefined;firstDefinedValueGate(inputs:Inputs.Logic.TwoValueGateDto):T|U|undefined;}declare class MathBitByBit{number(inputs:Inputs.Math.NumberDto):number;twoNrOperation(inputs:Inputs.Math.ActionOnTwoNumbersDto):number;modulus(inputs:Inputs.Math.ModulusDto):number;roundToDecimals(inputs:Inputs.Math.RoundToDecimalsDto):number;roundAndRemoveTrailingZeros(inputs:Inputs.Math.RoundToDecimalsDto):number;oneNrOperation(inputs:Inputs.Math.ActionOnOneNumberDto):number;remap(inputs:Inputs.Math.RemapNumberDto):number;random():number;randomNumber(inputs:Inputs.Math.RandomNumberDto):number;randomNumbers(inputs:Inputs.Math.RandomNumbersDto):number[];pi():number;toFixed(inputs:Inputs.Math.ToFixedDto):string;add(inputs:Inputs.Math.TwoNumbersDto):number;subtract(inputs:Inputs.Math.TwoNumbersDto):number;multiply(inputs:Inputs.Math.TwoNumbersDto):number;divide(inputs:Inputs.Math.TwoNumbersDto):number;power(inputs:Inputs.Math.TwoNumbersDto):number;sqrt(inputs:Inputs.Math.NumberDto):number;abs(inputs:Inputs.Math.NumberDto):number;round(inputs:Inputs.Math.NumberDto):number;floor(inputs:Inputs.Math.NumberDto):number;ceil(inputs:Inputs.Math.NumberDto):number;negate(inputs:Inputs.Math.NumberDto):number;ln(inputs:Inputs.Math.NumberDto):number;log10(inputs:Inputs.Math.NumberDto):number;tenPow(inputs:Inputs.Math.NumberDto):number;sin(inputs:Inputs.Math.NumberDto):number;cos(inputs:Inputs.Math.NumberDto):number;tan(inputs:Inputs.Math.NumberDto):number;asin(inputs:Inputs.Math.NumberDto):number;acos(inputs:Inputs.Math.NumberDto):number;atan(inputs:Inputs.Math.NumberDto):number;exp(inputs:Inputs.Math.NumberDto):number;degToRad(inputs:Inputs.Math.NumberDto):number;radToDeg(inputs:Inputs.Math.NumberDto):number;ease(inputs:Inputs.Math.EaseDto):number;clamp(inputs:Inputs.Math.ClampDto):number;lerp(inputs:Inputs.Math.LerpDto):number;inverseLerp(inputs:Inputs.Math.InverseLerpDto):number;smoothstep(inputs:Inputs.Math.NumberDto):number;sign(inputs:Inputs.Math.NumberDto):number;fract(inputs:Inputs.Math.NumberDto):number;wrap(inputs:Inputs.Math.WrapDto):number;pingPong(inputs:Inputs.Math.PingPongDto):number;moveTowards(inputs:Inputs.Math.MoveTowardsDto):number;private easeInSine;private easeOutSine;private easeInOutSine;private easeInQuad;private easeOutQuad;private easeInOutQuad;private easeInCubic;private easeOutCubic;private easeInOutCubic;private easeInQuart;private easeOutQuart;private easeInOutQuart;private easeInQuint;private easeOutQuint;private easeInOutQuint;private easeInExpo;private easeOutExpo;private easeInOutExpo;private easeInCirc;private easeOutCirc;private easeInOutCirc;private easeInBack;private easeOutBack;private easeInOutBack;private easeInElastic;private easeOutElastic;private easeInOutElastic;private easeInBounce;private easeOutBounce;private easeInOutBounce;}declare class MeshBitByBit{private readonly vector;private readonly polyline;constructor(vector:Vector,polyline:Polyline);signedDistanceToPlane(inputs:Inputs.Mesh.SignedDistanceFromPlaneToPointDto):number;calculateTrianglePlane(inputs:Inputs.Mesh.TriangleToleranceDto):Inputs.Base.TrianglePlane3|undefined;triangleTriangleIntersection(inputs:Inputs.Mesh.TriangleTriangleToleranceDto):Inputs.Base.Segment3|undefined;meshMeshIntersectionSegments(inputs:Inputs.Mesh.MeshMeshToleranceDto):Inputs.Base.Segment3[];meshMeshIntersectionPolylines(inputs:Inputs.Mesh.MeshMeshToleranceDto):Inputs.Base.Polyline3[];meshMeshIntersectionPoints(inputs:Inputs.Mesh.MeshMeshToleranceDto):Inputs.Base.Point3[][];private computeIntersectionPoint;}declare class Point{private readonly geometryHelper;private readonly transforms;private readonly vector;private readonly lists;constructor(geometryHelper:GeometryHelper,transforms:Transforms,vector:Vector,lists:Lists);transformPoint(inputs:Inputs.Point.TransformPointDto):Inputs.Base.Point3;transformPoints(inputs:Inputs.Point.TransformPointsDto):Inputs.Base.Point3[];transformsForPoints(inputs:Inputs.Point.TransformsForPointsDto):Inputs.Base.Point3[];translatePoints(inputs:Inputs.Point.TranslatePointsDto):Inputs.Base.Point3[];translatePointsWithVectors(inputs:Inputs.Point.TranslatePointsWithVectorsDto):Inputs.Base.Point3[];translateXYZPoints(inputs:Inputs.Point.TranslateXYZPointsDto):Inputs.Base.Point3[];scalePointsCenterXYZ(inputs:Inputs.Point.ScalePointsCenterXYZDto):Inputs.Base.Point3[];stretchPointsDirFromCenter(inputs:Inputs.Point.StretchPointsDirFromCenterDto):Inputs.Base.Point3[];rotatePointsCenterAxis(inputs:Inputs.Point.RotatePointsCenterAxisDto):Inputs.Base.Point3[];boundingBoxOfPoints(inputs:Inputs.Point.PointsDto):Inputs.Base.BoundingBox;closestPointFromPointsDistance(inputs:Inputs.Point.ClosestPointFromPointsDto):number;closestPointFromPointsIndex(inputs:Inputs.Point.ClosestPointFromPointsDto):number;closestPointFromPoints(inputs:Inputs.Point.ClosestPointFromPointsDto):Inputs.Base.Point3;distance(inputs:Inputs.Point.StartEndPointsDto):number;distancesToPoints(inputs:Inputs.Point.StartEndPointsListDto):number[];multiplyPoint(inputs:Inputs.Point.MultiplyPointDto):Inputs.Base.Point3[];getX(inputs:Inputs.Point.PointDto):number;getY(inputs:Inputs.Point.PointDto):number;getZ(inputs:Inputs.Point.PointDto):number;averagePoint(inputs:Inputs.Point.PointsDto):Inputs.Base.Point3;pointXYZ(inputs:Inputs.Point.PointXYZDto):Inputs.Base.Point3;pointXY(inputs:Inputs.Point.PointXYDto):Inputs.Base.Point2;spiral(inputs:Inputs.Point.SpiralDto):Inputs.Base.Point3[];hexGrid(inputs:Inputs.Point.HexGridCentersDto):Inputs.Base.Point3[];hexGridScaledToFit(inputs:Inputs.Point.HexGridScaledToFitDto):Models.Point.HexGridData;maxFilletRadius(inputs:Inputs.Point.ThreePointsToleranceDto):number;maxFilletRadiusHalfLine(inputs:Inputs.Point.ThreePointsToleranceDto):number;maxFilletsHalfLine(inputs:Inputs.Point.PointsMaxFilletsHalfLineDto):number[];safestPointsMaxFilletHalfLine(inputs:Inputs.Point.PointsMaxFilletsHalfLineDto):number;removeConsecutiveDuplicates(inputs:Inputs.Point.RemoveConsecutiveDuplicatesDto):Inputs.Base.Point3[];normalFromThreePoints(inputs:Inputs.Point.ThreePointsNormalDto):Inputs.Base.Vector3;private closestPointFromPointData;twoPointsAlmostEqual(inputs:Inputs.Point.TwoPointsToleranceDto):boolean;sortPoints(inputs:Inputs.Point.PointsDto):Inputs.Base.Point3[];private getRegularHexagonVertices;}declare class Polyline{private readonly vector;private readonly point;private readonly line;private readonly geometryHelper;constructor(vector:Vector,point:Point,line:Line,geometryHelper:GeometryHelper);length(inputs:Inputs.Polyline.PolylineDto):number;countPoints(inputs:Inputs.Polyline.PolylineDto):number;getPoints(inputs:Inputs.Polyline.PolylineDto):Inputs.Base.Point3[];reverse(inputs:Inputs.Polyline.PolylineDto):Inputs.Polyline.PolylinePropertiesDto;transformPolyline(inputs:Inputs.Polyline.TransformPolylineDto):Inputs.Polyline.PolylinePropertiesDto;create(inputs:Inputs.Polyline.PolylineCreateDto):Inputs.Polyline.PolylinePropertiesDto;polylineToLines(inputs:Inputs.Polyline.PolylineDto):Inputs.Base.Line3[];polylineToSegments(inputs:Inputs.Polyline.PolylineDto):Inputs.Base.Segment3[];polylineSelfIntersection(inputs:Inputs.Polyline.PolylineToleranceDto):Inputs.Base.Point3[];twoPolylineIntersection(inputs:Inputs.Polyline.TwoPolylinesToleranceDto):Inputs.Base.Point3[];sortSegmentsIntoPolylines(inputs:Inputs.Polyline.SegmentsToleranceDto):Inputs.Base.Polyline3[];maxFilletsHalfLine(inputs:Inputs.Polyline.PolylineToleranceDto):number[];safestFilletRadius(inputs:Inputs.Polyline.PolylineToleranceDto):number;}declare class TextBitByBit{private readonly point;constructor(point:Point);create(inputs:Inputs.Text.TextDto):string;split(inputs:Inputs.Text.TextSplitDto):string[];replaceAll(inputs:Inputs.Text.TextReplaceDto):string;join(inputs:Inputs.Text.TextJoinDto):string;toString(inputs:Inputs.Text.ToStringDto):string;toStringEach(inputs:Inputs.Text.ToStringEachDto):string[];format(inputs:Inputs.Text.TextFormatDto):string;includes(inputs:Inputs.Text.TextSearchDto):boolean;startsWith(inputs:Inputs.Text.TextSearchDto):boolean;endsWith(inputs:Inputs.Text.TextSearchDto):boolean;indexOf(inputs:Inputs.Text.TextSearchDto):number;lastIndexOf(inputs:Inputs.Text.TextSearchDto):number;substring(inputs:Inputs.Text.TextSubstringDto):string;slice(inputs:Inputs.Text.TextSubstringDto):string;charAt(inputs:Inputs.Text.TextIndexDto):string;trim(inputs:Inputs.Text.TextDto):string;trimStart(inputs:Inputs.Text.TextDto):string;trimEnd(inputs:Inputs.Text.TextDto):string;padStart(inputs:Inputs.Text.TextPadDto):string;padEnd(inputs:Inputs.Text.TextPadDto):string;toUpperCase(inputs:Inputs.Text.TextDto):string;toLowerCase(inputs:Inputs.Text.TextDto):string;toUpperCaseFirst(inputs:Inputs.Text.TextDto):string;toLowerCaseFirst(inputs:Inputs.Text.TextDto):string;repeat(inputs:Inputs.Text.TextRepeatDto):string;reverse(inputs:Inputs.Text.TextDto):string;length(inputs:Inputs.Text.TextDto):number;isEmpty(inputs:Inputs.Text.TextDto):boolean;concat(inputs:Inputs.Text.TextConcatDto):string;regexTest(inputs:Inputs.Text.TextRegexDto):boolean;regexMatch(inputs:Inputs.Text.TextRegexDto):string[]|null;regexReplace(inputs:Inputs.Text.TextRegexReplaceDto):string;regexSearch(inputs:Inputs.Text.TextRegexDto):number;regexSplit(inputs:Inputs.Text.TextRegexDto):string[];vectorChar(inputs:Inputs.Text.VectorCharDto):Models.Text.VectorCharData;vectorText(inputs:Inputs.Text.VectorTextDto):Models.Text.VectorTextData[];private vectorParamsChar;private translateLine;}declare class Transforms{private readonly vector;private readonly math;constructor(vector:Vector,math:MathBitByBit);rotationCenterAxis(inputs:Inputs.Transforms.RotationCenterAxisDto):Base.TransformMatrixes;rotationCenterX(inputs:Inputs.Transforms.RotationCenterDto):Base.TransformMatrixes;rotationCenterY(inputs:Inputs.Transforms.RotationCenterDto):Base.TransformMatrixes;rotationCenterZ(inputs:Inputs.Transforms.RotationCenterDto):Base.TransformMatrixes;rotationCenterYawPitchRoll(inputs:Inputs.Transforms.RotationCenterYawPitchRollDto):Base.TransformMatrixes;scaleCenterXYZ(inputs:Inputs.Transforms.ScaleCenterXYZDto):Base.TransformMatrixes;scaleXYZ(inputs:Inputs.Transforms.ScaleXYZDto):Base.TransformMatrixes;stretchDirFromCenter(inputs:Inputs.Transforms.StretchDirCenterDto):Base.TransformMatrixes;uniformScale(inputs:Inputs.Transforms.UniformScaleDto):Base.TransformMatrixes;uniformScaleFromCenter(inputs:Inputs.Transforms.UniformScaleFromCenterDto):Base.TransformMatrixes;translationXYZ(inputs:Inputs.Transforms.TranslationXYZDto):Base.TransformMatrixes;translationsXYZ(inputs:Inputs.Transforms.TranslationsXYZDto):Base.TransformMatrixes[];identity():Base.TransformMatrix;private translation;private scaling;private rotationAxis;private rotationX;private rotationY;private rotationZ;private rotationYawPitchRoll;private rotationMatrixFromQuat;private stretchDirection;}declare class Vector{private readonly math;private readonly geometryHelper;constructor(math:MathBitByBit,geometryHelper:GeometryHelper);removeAllDuplicateVectors(inputs:Inputs.Vector.RemoveAllDuplicateVectorsDto):number[][];removeConsecutiveDuplicateVectors(inputs:Inputs.Vector.RemoveConsecutiveDuplicateVectorsDto):number[][];vectorsTheSame(inputs:Inputs.Vector.VectorsTheSameDto):boolean;angleBetween(inputs:Inputs.Vector.TwoVectorsDto):number;angleBetweenNormalized2d(inputs:Inputs.Vector.TwoVectorsDto):number;positiveAngleBetween(inputs:Inputs.Vector.TwoVectorsReferenceDto):number;addAll(inputs:Inputs.Vector.VectorsDto):number[];add(inputs:Inputs.Vector.TwoVectorsDto):number[];all(inputs:Inputs.Vector.VectorBoolDto):boolean;cross(inputs:Inputs.Vector.TwoVectorsDto):number[];distSquared(inputs:Inputs.Vector.TwoVectorsDto):number;dist(inputs:Inputs.Vector.TwoVectorsDto):number;div(inputs:Inputs.Vector.VectorScalarDto):number[];domain(inputs:Inputs.Vector.VectorDto):number;dot(inputs:Inputs.Vector.TwoVectorsDto):number;finite(inputs:Inputs.Vector.VectorDto):boolean[];isZero(inputs:Inputs.Vector.VectorDto):boolean;lerp(inputs:Inputs.Vector.FractionTwoVectorsDto):number[];max(inputs:Inputs.Vector.VectorDto):number;min(inputs:Inputs.Vector.VectorDto):number;mul(inputs:Inputs.Vector.VectorScalarDto):number[];neg(inputs:Inputs.Vector.VectorDto):number[];normSquared(inputs:Inputs.Vector.VectorDto):number;norm(inputs:Inputs.Vector.VectorDto):number;normalized(inputs:Inputs.Vector.VectorDto):number[];onRay(inputs:Inputs.Vector.RayPointDto):number[];vectorXYZ(inputs:Inputs.Vector.VectorXYZDto):Inputs.Base.Vector3;vectorXY(inputs:Inputs.Vector.VectorXYDto):Inputs.Base.Vector2;range(inputs:Inputs.Vector.RangeMaxDto):number[];signedAngleBetween(inputs:Inputs.Vector.TwoVectorsReferenceDto):number;span(inputs:Inputs.Vector.SpanDto):number[];spanEaseItems(inputs:Inputs.Vector.SpanEaseItemsDto):number[];spanLinearItems(inputs:Inputs.Vector.SpanLinearItemsDto):number[];sub(inputs:Inputs.Vector.TwoVectorsDto):number[];sum(inputs:Inputs.Vector.VectorDto):number;lengthSq(inputs:Inputs.Vector.Vector3Dto):number;length(inputs:Inputs.Vector.Vector3Dto):number;parseNumbers(inputs:Inputs.Vector.VectorStringDto):number[];}declare class Asset{assetManager:AssetManager;constructor();getFile(inputs:Inputs.Asset.GetAssetDto):Promise;getTextFile(inputs:Inputs.Asset.GetAssetDto):Promise;getLocalFile(inputs:Inputs.Asset.GetAssetDto):Promise;getLocalTextFile(inputs:Inputs.Asset.GetAssetDto):Promise;fetchBlob(inputs:Inputs.Asset.FetchDto):Promise;fetchFile(inputs:Inputs.Asset.FetchDto):Promise;fetchJSON(inputs:Inputs.Asset.FetchDto):Promise;fetchText(inputs:Inputs.Asset.FetchDto):Promise;createObjectURL(inputs:Inputs.Asset.FileDto):string;createObjectURLs(inputs:Inputs.Asset.FilesDto):string[];download(inputs:Inputs.Asset.DownloadDto):void;}declare namespace BaseTypes{class IntervalDto{min:number;max:number;}class UVDto{u:number;v:number;}class CurveCurveIntersection{point0:number[];point1:number[];u0:number;u1:number;}class CurveSurfaceIntersection{u:number;uv:UVDto;curvePoint:number[];surfacePoint:number[];}class SurfaceSurfaceIntersectionPoint{uv0:UVDto;uv1:UVDto;point:number[];dist:number;}}declare class CSVBitByBit{parseToArray(inputs:Inputs.CSV.ParseToArrayDto):string[][];parseToJson>(inputs:Inputs.CSV.ParseToJsonDto):T[];parseToJsonWithHeaders>(inputs:Inputs.CSV.ParseToJsonWithHeadersDto):T[];queryColumn>(inputs:Inputs.CSV.QueryColumnDto):(string|number)[];queryRowsByValue>(inputs:Inputs.CSV.QueryRowsByValueDto):T[];arrayToCsv(inputs:Inputs.CSV.ArrayToCsvDto):string;jsonToCsv>(inputs:Inputs.CSV.JsonToCsvDto):string;jsonToCsvAuto>(inputs:Inputs.CSV.JsonToCsvAutoDto):string;getHeaders(inputs:Inputs.CSV.GetHeadersDto):string[];getRowCount(inputs:Inputs.CSV.GetRowCountDto):number;getColumnCount(inputs:Inputs.CSV.ParseToArrayDto):number;private parseCsvLine;private escapeCsvCell;private convertEscapeSequences;}declare class JSONBitByBit{private readonly context;constructor(context:ContextBase);stringify(inputs:Inputs.JSON.StringifyDto):string;parse(inputs:Inputs.JSON.ParseDto):any;query(inputs:Inputs.JSON.QueryDto):any;setValueOnProp(inputs:Inputs.JSON.SetValueOnPropDto):any;getJsonFromArrayByFirstPropMatch(inputs:Inputs.JSON.GetJsonFromArrayByFirstPropMatchDto):any;getValueOnProp(inputs:Inputs.JSON.GetValueOnPropDto):any;setValue(inputs:Inputs.JSON.SetValueDto):any;setValuesOnPaths(inputs:Inputs.JSON.SetValuesOnPathsDto):any;paths(inputs:Inputs.JSON.PathsDto):any;createEmpty():any;previewAndSaveJson(inputs:Inputs.JSON.JsonDto):void;previewJson(inputs:Inputs.JSON.JsonDto):void;}declare class OCCTWIO extends OCCTIO{readonly occWorkerManager:OCCTWorkerManager;private readonly context;constructor(occWorkerManager:OCCTWorkerManager,context:ContextBase);loadSTEPorIGES(inputs:Inputs.OCCT.ImportStepIgesDto):Promise;loadSTEPorIGESFromText(inputs:Inputs.OCCT.ImportStepIgesFromTextDto):Promise;}declare class OCCTW extends OCCT{readonly context:ContextBase;readonly occWorkerManager:OCCTWorkerManager;readonly io:OCCTWIO;constructor(context:ContextBase,occWorkerManager:OCCTWorkerManager);}declare class Tag{private readonly context;constructor(context:ContextBase);create(inputs:Inputs.Tag.TagDto):Inputs.Tag.TagDto;drawTag(inputs:Inputs.Tag.DrawTagDto):Inputs.Tag.TagDto;drawTags(inputs:Inputs.Tag.DrawTagsDto):Inputs.Tag.TagDto[];}declare class Time{private context;constructor(context:ContextBase);registerRenderFunction(update:(timePassedMs:number)=>void):void;}declare class VerbCurveCircle{private readonly context;private readonly math;constructor(context:ContextBase,math:MathBitByBit);createCircle(inputs:Inputs.Verb.CircleParametersDto):any;createArc(inputs:Inputs.Verb.ArcParametersDto):any;center(inputs:Inputs.Verb.CircleDto):number[];radius(inputs:Inputs.Verb.CircleDto):number;maxAngle(inputs:Inputs.Verb.CircleDto):number;minAngle(inputs:Inputs.Verb.CircleDto):number;xAxis(inputs:Inputs.Verb.CircleDto):number[];yAxis(inputs:Inputs.Verb.CircleDto):number[];}declare class VerbCurveEllipse{private readonly context;private readonly math;constructor(context:ContextBase,math:MathBitByBit);createEllipse(inputs:Inputs.Verb.EllipseParametersDto):any;createArc(inputs:Inputs.Verb.EllipseArcParametersDto):any;center(inputs:Inputs.Verb.EllipseDto):number[];maxAngle(inputs:Inputs.Verb.EllipseDto):number;minAngle(inputs:Inputs.Verb.EllipseDto):number;xAxis(inputs:Inputs.Verb.EllipseDto):number[];yAxis(inputs:Inputs.Verb.EllipseDto):number[];}declare class VerbCurve{private readonly context;private readonly geometryHelper;private readonly math;readonly circle:VerbCurveCircle;readonly ellipse:VerbCurveEllipse;constructor(context:ContextBase,geometryHelper:GeometryHelper,math:MathBitByBit);createCurveByKnotsControlPointsWeights(inputs:Inputs.Verb.CurveNurbsDataDto):any;createCurveByPoints(inputs:Inputs.Verb.CurvePathDataDto):any;convertLinesToNurbsCurves(inputs:Inputs.Verb.LinesDto):any[];convertLineToNurbsCurve(inputs:Inputs.Verb.LineDto):any;convertPolylineToNurbsCurve(inputs:Inputs.Verb.PolylineDto):any;convertPolylinesToNurbsCurves(inputs:Inputs.Verb.PolylinesDto):any[];createBezierCurve(inputs:Inputs.Verb.BezierCurveDto):any;clone(inputs:Inputs.Verb.CurveDto):any;closestParam(inputs:Inputs.Verb.ClosestPointDto):number;closestParams(inputs:Inputs.Verb.ClosestPointsDto):number[];closestPoint(inputs:Inputs.Verb.ClosestPointDto):Inputs.Base.Point3;closestPoints(inputs:Inputs.Verb.ClosestPointsDto):Inputs.Base.Point3[];controlPoints(inputs:Inputs.Verb.CurveDto):Inputs.Base.Point3[];degree(inputs:Inputs.Verb.CurveDto):number;derivatives(inputs:Inputs.Verb.CurveDerivativesDto):number[];divideByEqualArcLengthToParams(inputs:Inputs.Verb.CurveSubdivisionsDto):number[];divideByEqualArcLengthToPoints(inputs:Inputs.Verb.CurveSubdivisionsDto):Inputs.Base.Point3[];divideByArcLengthToParams(inputs:Inputs.Verb.CurveDivideLengthDto):number[];divideByArcLengthToPoints(inputs:Inputs.Verb.CurveDivideLengthDto):Inputs.Base.Point3[];divideCurvesByEqualArcLengthToPoints(inputs:Inputs.Verb.CurvesSubdivisionsDto):Inputs.Base.Point3[][];divideCurvesByArcLengthToPoints(inputs:Inputs.Verb.CurvesDivideLengthDto):Inputs.Base.Point3[][];domain(inputs:Inputs.Verb.CurveDto):BaseTypes.IntervalDto;startPoint(inputs:Inputs.Verb.CurveDto):Inputs.Base.Point3;endPoint(inputs:Inputs.Verb.CurveDto):Inputs.Base.Point3;startPoints(inputs:Inputs.Verb.CurvesDto):Inputs.Base.Point3[];endPoints(inputs:Inputs.Verb.CurvesDto):Inputs.Base.Point3[];knots(inputs:Inputs.Verb.CurveDto):number[];lengthAtParam(inputs:Inputs.Verb.CurveParameterDto):number;length(inputs:Inputs.Verb.CurveDto):number;paramAtLength(inputs:Inputs.Verb.CurveLengthToleranceDto):number;pointAtParam(inputs:Inputs.Verb.CurveParameterDto):Inputs.Base.Point3;pointsAtParam(inputs:Inputs.Verb.CurvesParameterDto):Inputs.Base.Point3[];reverse(inputs:Inputs.Verb.CurveDto):any;split(inputs:Inputs.Verb.CurveParameterDto):any[];tangent(inputs:Inputs.Verb.CurveParameterDto):Inputs.Base.Vector3;tessellate(inputs:Inputs.Verb.CurveToleranceDto):Inputs.Base.Point3[];transform(inputs:Inputs.Verb.CurveTransformDto):any;transformCurves(inputs:Inputs.Verb.CurvesTransformDto):any[];weights(inputs:Inputs.Verb.CurveDto):number[];}declare class VerbIntersect{private readonly context;private readonly geometryHelper;constructor(context:ContextBase,geometryHelper:GeometryHelper);curves(inputs:Inputs.Verb.CurveCurveDto):BaseTypes.CurveCurveIntersection[];curveAndSurface(inputs:Inputs.Verb.CurveSurfaceDto):BaseTypes.CurveSurfaceIntersection[];surfaces(inputs:Inputs.Verb.SurfaceSurfaceDto):any[];curveCurveFirstParams(inputs:Inputs.Verb.CurveCurveIntersectionsDto):number[];curveCurveSecondParams(inputs:Inputs.Verb.CurveCurveIntersectionsDto):number[];curveCurveFirstPoints(inputs:Inputs.Verb.CurveCurveIntersectionsDto):number[][];curveCurveSecondPoints(inputs:Inputs.Verb.CurveCurveIntersectionsDto):number[][];curveSurfaceCurveParams(inputs:Inputs.Verb.CurveSurfaceIntersectionsDto):number[];curveSurfaceSurfaceParams(inputs:Inputs.Verb.CurveSurfaceIntersectionsDto):BaseTypes.UVDto[];curveSurfaceCurvePoints(inputs:Inputs.Verb.CurveSurfaceIntersectionsDto):number[][];curveSurfaceSurfacePoints(inputs:Inputs.Verb.CurveSurfaceIntersectionsDto):number[][];}declare class VerbSurfaceConical{private readonly context;constructor(context:ContextBase);create(inputs:Inputs.Verb.ConeAndCylinderParametersDto):any;axis(inputs:Inputs.Verb.ConeDto):number[];base(inputs:Inputs.Verb.ConeDto):number[];height(inputs:Inputs.Verb.ConeDto):number;radius(inputs:Inputs.Verb.ConeDto):number;xAxis(inputs:Inputs.Verb.ConeDto):number[];}declare class VerbSurfaceCylindrical{private readonly context;constructor(context:ContextBase);create(inputs:Inputs.Verb.ConeAndCylinderParametersDto):any;axis(inputs:Inputs.Verb.CylinderDto):number[];base(inputs:Inputs.Verb.CylinderDto):number[];height(inputs:Inputs.Verb.CylinderDto):number;radius(inputs:Inputs.Verb.CylinderDto):number;xAxis(inputs:Inputs.Verb.CylinderDto):number[];}declare class VerbSurfaceExtrusion{private readonly context;constructor(context:ContextBase);create(inputs:Inputs.Verb.ExtrusionParametersDto):any;direction(inputs:Inputs.Verb.ExtrusionDto):number[];profile(inputs:Inputs.Verb.ExtrusionDto):number[];}declare class VerbSurfaceRevolved{private readonly context;private readonly math;constructor(context:ContextBase,math:MathBitByBit);create(inputs:Inputs.Verb.RevolutionParametersDto):any;profile(inputs:Inputs.Verb.RevolutionDto):any;center(inputs:Inputs.Verb.RevolutionDto):number[];axis(inputs:Inputs.Verb.RevolutionDto):number[];angle(inputs:Inputs.Verb.RevolutionDto):number;}declare class VerbSurfaceSpherical{private readonly context;constructor(context:ContextBase);create(inputs:Inputs.Verb.SphericalParametersDto):any;radius(inputs:Inputs.Verb.SphereDto):number;center(inputs:Inputs.Verb.SphereDto):number[];}declare class VerbSurfaceSweep{private readonly context;constructor(context:ContextBase);create(inputs:Inputs.Verb.SweepParametersDto):any;profile(inputs:Inputs.Verb.SweepDto):any;rail(inputs:Inputs.Verb.SweepDto):any;}declare class VerbSurface{private readonly context;private readonly geometryHelper;private readonly math;readonly cone:VerbSurfaceConical;readonly cylinder:VerbSurfaceCylindrical;readonly extrusion:VerbSurfaceExtrusion;readonly sphere:VerbSurfaceSpherical;readonly revolved:VerbSurfaceRevolved;readonly sweep:VerbSurfaceSweep;constructor(context:ContextBase,geometryHelper:GeometryHelper,math:MathBitByBit);boundaries(inputs:Inputs.Verb.SurfaceDto):any[];createSurfaceByCorners(inputs:Inputs.Verb.CornersDto):any;createSurfaceByKnotsControlPointsWeights(inputs:Inputs.Verb.KnotsControlPointsWeightsDto):any;createSurfaceByLoftingCurves(inputs:Inputs.Verb.LoftCurvesDto):any;clone(inputs:Inputs.Verb.SurfaceDto):any;closestParam(inputs:Inputs.Verb.SurfaceParamDto):BaseTypes.UVDto;closestPoint(inputs:Inputs.Verb.SurfaceParamDto):number[];controlPoints(inputs:Inputs.Verb.SurfaceDto):number[][][];degreeU(inputs:Inputs.Verb.SurfaceDto):number;degreeV(inputs:Inputs.Verb.SurfaceDto):number;derivatives(inputs:Inputs.Verb.DerivativesDto):number[][][];domainU(inputs:Inputs.Verb.SurfaceDto):BaseTypes.IntervalDto;domainV(inputs:Inputs.Verb.SurfaceDto):BaseTypes.IntervalDto;isocurve(inputs:Inputs.Verb.SurfaceParameterDto):any;isocurvesSubdivision(inputs:Inputs.Verb.IsocurveSubdivisionDto):any[];isocurvesAtParams(inputs:Inputs.Verb.IsocurvesParametersDto):any[];knotsU(inputs:Inputs.Verb.SurfaceDto):number[];knotsV(inputs:Inputs.Verb.SurfaceDto):number[];normal(inputs:Inputs.Verb.SurfaceLocationDto):number[];point(inputs:Inputs.Verb.SurfaceLocationDto):number[];reverse(inputs:Inputs.Verb.SurfaceDto):any;split(inputs:Inputs.Verb.SurfaceParameterDto):any[];transformSurface(inputs:Inputs.Verb.SurfaceTransformDto):any;weights(inputs:Inputs.Verb.SurfaceDto):number[][];}declare class Verb{private readonly math;readonly curve:VerbCurve;readonly surface:VerbSurface;readonly intersect:VerbIntersect;constructor(context:ContextBase,geometryHelper:GeometryHelper,math:MathBitByBit);}declare class AdvancedAdv{private readonly occWorkerManager;private readonly context;private readonly draw;private readonly occt;text3d:Text3D;patterns:Patterns;constructor(occWorkerManager:OCCTWorkerManager,context:Context,draw:Draw,occt:OCCTW);}declare class FacePatterns{private readonly occWorkerManager;private readonly context;private readonly draw;private readonly occt;pyramidSimple:PyramidSimple;constructor(occWorkerManager:OCCTWorkerManager,context:Context,draw:Draw,occt:OCCTW);}declare class PyramidSimple{private readonly occWorkerManager;private readonly context;private readonly draw;private readonly occt;constructor(occWorkerManager:OCCTWorkerManager,context:Context,draw:Draw,occt:OCCTW);createPyramidSimple(inputs:Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleDto):Promise>;createPyramidSimpleAffectors(inputs:Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleAffectorsDto):Promise>;drawModel(inputs:Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleData):Promise;getCompoundShape(inputs:Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelDto):Inputs.OCCT.TopoDSShapePointer;getCompoundShapeOnFace(inputs:Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelFaceIndexDto):Inputs.OCCT.TopoDSShapePointer;getCompoundShapeCellOnFace(inputs:Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelFaceCellIndexDto):Inputs.OCCT.TopoDSShapePointer;getAllPyramidCells(inputs:Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelDto):Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleCellPart[];getAllPyramidCellsOnFace(inputs:Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelFaceIndexDto):Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleCellPart[];getAllPyramidUCellsOnFace(inputs:Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelFaceIndexDto):Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleCellPart[];getAllPyramidUCellsOnFaceAtU(inputs:Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelFaceCellsUIndexDto):Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleCellPart[];getAllPyramidUCellsOnFaceAtV(inputs:Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelFaceCellsVIndexDto):Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleCellPart[];getCellOnIndex(inputs:Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelFaceCellIndexDto):Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleCellPart;getTopPointsOfCells(inputs:Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelCellsDto):Inputs.Base.Point3[];getCenterPointsOfCells(inputs:Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelCellsDto):Inputs.Base.Point3[];getCornerPointsOfCells(inputs:Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelCellsDto):Inputs.Base.Point3[][];getCornerPointOfCells(inputs:Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelCellsIndexDto):Inputs.Base.Point3[];getCornerNormalOfCells(inputs:Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelCellsIndexDto):Inputs.Base.Point3[];getCornerNormalsOfCells(inputs:Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelCellsDto):Inputs.Base.Point3[][];getCompoundShapesOfCells(inputs:Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelCellsDto):Inputs.OCCT.TopoDSShapePointer[];getFaceShapesOfCells(inputs:Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelCellsIndexDto):Inputs.OCCT.TopoDSShapePointer[];getWireShapesOfCells(inputs:Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelCellsIndexDto):Inputs.OCCT.TopoDSShapePointer[];getStartPolylineWireU(inputs:Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelFaceIndexDto):Inputs.OCCT.TopoDSShapePointer;getEndPolylineWireU(inputs:Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelFaceIndexDto):Inputs.OCCT.TopoDSShapePointer;getStartPolylineWireV(inputs:Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelFaceIndexDto):Inputs.OCCT.TopoDSShapePointer;getEndPolylineWireV(inputs:Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelFaceIndexDto):Inputs.OCCT.TopoDSShapePointer;getPolylineWiresUCompound(inputs:Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelFaceIndexDto):Inputs.OCCT.TopoDSShapePointer;getPolylineWiresVCompound(inputs:Advanced.Patterns.FacePatterns.PyramidSimple.PyramidSimpleModelFaceIndexDto):Inputs.OCCT.TopoDSShapePointer;}declare class Patterns{private readonly occWorkerManager;private readonly context;private readonly draw;private readonly occt;facePatterns:FacePatterns;constructor(occWorkerManager:OCCTWorkerManager,context:Context,draw:Draw,occt:OCCTW);}declare class Text3D{private readonly occWorkerManager;private readonly context;private readonly draw;private readonly occt;constructor(occWorkerManager:OCCTWorkerManager,context:Context,draw:Draw,occt:OCCTW);create(inputs:Advanced.Text3D.Text3DDto):Promise>;createTextOnFace(inputs:Advanced.Text3D.Text3DFaceDto):Promise>;createTextsOnFace(inputs:Advanced.Text3D.Texts3DFaceDto):Promise>;definition3dTextOnFace(inputs:Advanced.Text3D.Text3DFaceDefinitionDto):Advanced.Text3D.Text3DFaceDefinitionDto;drawModel(inputs:Advanced.Text3D.Text3DData,precision?:number):Promise;getCompoundShape(inputs:Advanced.Text3D.Text3DModelDto):Inputs.OCCT.TopoDSShapePointer;getCharacterShape(inputs:Advanced.Text3D.Text3DLetterByIndexDto):Inputs.OCCT.TopoDSShapePointer;getCharacterShapes(inputs:Advanced.Text3D.Text3DModelDto):Inputs.OCCT.TopoDSShapePointer[];getCharacterCenterCoordinates(inputs:Advanced.Text3D.Text3DModelDto):Inputs.Base.Point3[];getFaceCutout(inputs:Advanced.Text3D.Text3DModelDto):Inputs.OCCT.TopoDSShapePointer;getAllFacesOfCutout(inputs:Advanced.Text3D.Text3DModelDto):Inputs.OCCT.TopoDSShapePointer[];getCutoutsInsideCharacters(inputs:Advanced.Text3D.Text3DModelDto):Inputs.OCCT.TopoDSShapePointer[];getAdvanceWidth(inputs:Advanced.Text3D.Text3DModelDto):number;}declare class DrawComplete extends Draw{readonly drawHelper:DrawHelper;readonly tag:Tag;private readonly advanced;readonly context:Context;constructor(drawHelper:DrawHelper,tag:Tag,advanced:AdvancedAdv,context:Context);drawAnyAsync(inputs:Inputs.Draw.DrawAny):Promise;optionsSimple(inputs:Inputs.Draw.DrawBasicGeometryOptions):Inputs.Draw.DrawBasicGeometryOptions;optionsOcctShape(inputs:Inputs.Draw.DrawOcctShapeOptions):Inputs.Draw.DrawOcctShapeOptions;}declare class ShapeParser{static parse(obj:any,partShapes:Models.OCCT.ShapeWithId[]):any;}declare class BitByBitBase{readonly draw:Draw;readonly three:ThreeJS;readonly vector:Vector;readonly point:Point;readonly line:Line;readonly polyline:Polyline;readonly mesh:MeshBitByBit;readonly occt:OCCTW&OCCT;readonly advanced:AdvancedAdv;readonly things:ThingsAdv;readonly jscad:JSCAD;readonly manifold:ManifoldBitByBit;readonly logic:Logic;readonly math:MathBitByBit;readonly lists:Lists;readonly color:Color;readonly text:TextBitByBit;readonly dates:Dates;readonly json:JSONBitByBit;readonly csv:CSVBitByBit;readonly verb:Verb;readonly tag:Tag;readonly time:Time;readonly asset:Asset;}declare enum runContextEnum{runner="runner",editor="editor"}declare var runContext:runContextEnum;declare function mockBitbybitRunnerInputs(inputs:T):T;declare function getBitbybitRunnerInputs():T;declare function setBitbybitRunnerResult(result:T):void;declare function setBitbybitRunnerResultValue(prop:string,value:T):void;}declare var bitbybitRunnerInputs;declare var bitbybitRunnerResult; \ No newline at end of file diff --git a/examples/vite/threejs/runner-occt-bottle/src/runner/load-runner-script.ts b/examples/vite/threejs/runner-occt-bottle/src/runner/load-runner-script.ts index be6b0837..caa17ff6 100644 --- a/examples/vite/threejs/runner-occt-bottle/src/runner/load-runner-script.ts +++ b/examples/vite/threejs/runner-occt-bottle/src/runner/load-runner-script.ts @@ -1,3 +1,11 @@ + + +import * as THREEJS from "three"; +// eslint-disable-next-line @typescript-eslint/no-explicit-any + +// Dynamically load the runner script after THREE is available on window +(window as any).THREEJS = THREEJS; + export function loadRunnerScript(): Promise { return new Promise((resolve, reject) => { const script = document.createElement("script"); diff --git a/examples/vite/threejs/runner-occt-bottle/src/runner/runner-types.ts b/examples/vite/threejs/runner-occt-bottle/src/runner/runner-types.ts index dd768458..1c14f50b 100644 --- a/examples/vite/threejs/runner-occt-bottle/src/runner/runner-types.ts +++ b/examples/vite/threejs/runner-occt-bottle/src/runner/runner-types.ts @@ -1,5 +1,4 @@ // eslint-disable-next-line @typescript-eslint/triple-slash-reference -/// import type * as THREEJS from "three"; class ExternalThreeJS { diff --git a/examples/vite/threejs/starter-template/src/main.ts b/examples/vite/threejs/starter-template/src/main.ts index 96183414..0ea0e803 100644 --- a/examples/vite/threejs/starter-template/src/main.ts +++ b/examples/vite/threejs/starter-template/src/main.ts @@ -438,7 +438,6 @@ async function createDrawingExamples(bitbybit: BitByBitBase) { }); console.log("Multiple polylines drawn."); - // Example 5: Draw line segments const segments = [ [ [60, -20, 0], @@ -451,13 +450,13 @@ async function createDrawingExamples(bitbybit: BitByBitBase) { [ [60, -20, -5], [70, -20, 5], - ], - ]; + ] , + ]as Inputs.Base.Segment3[]; const segmentsDrawOptions = new Inputs.Draw.DrawBasicGeometryOptions(); segmentsDrawOptions.colours = ["#ffff00", "#ff00ff", "#00ffff"]; // Yellow, Magenta, Cyan segmentsDrawOptions.size = 2.5; await bitbybit.draw.drawAnyAsync({ - entity: segments as Inputs.Base.Polyline3[], + entity: segments, options: segmentsDrawOptions, }); console.log("Line segments drawn."); From fc68fcebf765eb331135f16f5ffb3ae68d15523d Mon Sep 17 00:00:00 2001 From: Matas Ubarevicius Date: Sun, 11 Jan 2026 14:43:07 +0200 Subject: [PATCH 05/31] simplifying bitbybit initialization process --- .../vite/threejs/starter-template/src/main.ts | 278 +++++++++--------- packages/dev/babylonjs/lib/api/index.ts | 2 + .../dev/babylonjs/lib/api/init-kernels.ts | 77 +++++ .../babylonjs/lib/api/inputs/draw-inputs.ts | 6 +- packages/dev/babylonjs/lib/api/worker-urls.ts | 12 + packages/dev/core/lib/api/index.ts | 2 + packages/dev/core/lib/api/init-kernels.ts | 134 +++++++++ packages/dev/core/lib/api/worker-utils.ts | 156 ++++++++++ packages/dev/playcanvas/lib/api/index.ts | 2 + .../dev/playcanvas/lib/api/init-kernels.ts | 78 +++++ .../playcanvas/lib/api/inputs/draw-inputs.ts | 6 +- .../dev/playcanvas/lib/api/worker-urls.ts | 12 + packages/dev/threejs/lib/api/index.ts | 2 + packages/dev/threejs/lib/api/init-kernels.ts | 86 ++++++ .../dev/threejs/lib/api/inputs/draw-inputs.ts | 5 +- packages/dev/threejs/lib/api/worker-urls.ts | 12 + 16 files changed, 717 insertions(+), 153 deletions(-) create mode 100644 packages/dev/babylonjs/lib/api/init-kernels.ts create mode 100644 packages/dev/babylonjs/lib/api/worker-urls.ts create mode 100644 packages/dev/core/lib/api/init-kernels.ts create mode 100644 packages/dev/core/lib/api/worker-utils.ts create mode 100644 packages/dev/playcanvas/lib/api/init-kernels.ts create mode 100644 packages/dev/playcanvas/lib/api/worker-urls.ts create mode 100644 packages/dev/threejs/lib/api/init-kernels.ts create mode 100644 packages/dev/threejs/lib/api/worker-urls.ts diff --git a/examples/vite/threejs/starter-template/src/main.ts b/examples/vite/threejs/starter-template/src/main.ts index 0ea0e803..4a27cc63 100644 --- a/examples/vite/threejs/starter-template/src/main.ts +++ b/examples/vite/threejs/starter-template/src/main.ts @@ -1,9 +1,5 @@ import "./style.css"; // Basic styling -import { BitByBitBase, Inputs } from "@bitbybit-dev/threejs"; -import { OccStateEnum } from "@bitbybit-dev/occt-worker"; -import { JscadStateEnum } from "@bitbybit-dev/jscad-worker"; -import { ManifoldStateEnum } from "@bitbybit-dev/manifold-worker"; - +import { BitByBitBase, Inputs, initBitbybit, type InitBitbybitOptions } from "@bitbybit-dev/threejs"; import { OrbitControls } from "three/examples/jsm/controls/OrbitControls"; import { Color, @@ -12,14 +8,6 @@ import { Scene, WebGLRenderer, } from "three"; -import { first, firstValueFrom, map } from "rxjs"; - -// Define an interface for kernel options -interface KernelOptions { - enableOCCT: boolean; - enableJSCAD: boolean; - enableManifold: boolean; -} // --- 1. Main Application Entry Point --- start(); @@ -31,24 +19,26 @@ async function start() { // Create an instance of BitByBitBase for Three.js const bitbybit = new BitByBitBase(); - // --- 2. Configure and Initialize Kernels --- - // Users can control which kernels are loaded - const kernelOptions: KernelOptions = { + // --- 2. Configure and Initialize BitByBit --- + // Single options object for both workers and kernels + const options: InitBitbybitOptions = { enableOCCT: true, enableJSCAD: true, enableManifold: true, + // loadFonts: ["roboto"], // Optional: specify fonts to load, or omit to skip font loading }; - // Initialize Bitbybit with the selected kernels - await initWithKernels(scene, bitbybit, kernelOptions); + + // Initialize BitByBit in a single call - workers are created from CDN automatically! + await initBitbybit(scene, bitbybit, options); // --- 3. Create Geometry with Active Kernels --- - if (kernelOptions.enableOCCT) { + if (options.enableOCCT) { await createOCCTGeometry(bitbybit, "#ff0000"); // Red } - if (kernelOptions.enableManifold) { + if (options.enableManifold) { await createManifoldGeometry(bitbybit, "#00ff00"); // Green } - if (kernelOptions.enableJSCAD) { + if (options.enableJSCAD) { await createJSCADGeometry(bitbybit, "#0000ff"); // Blue } @@ -56,7 +46,7 @@ async function start() { await createDrawingExamples(bitbybit); // --- 5. Create Textured OCCT Cube Example --- - if (kernelOptions.enableOCCT) { + if (options.enableOCCT) { await createTexturedOCCTCube(bitbybit); } } @@ -108,126 +98,126 @@ function initThreeJS() { return { scene, camera, renderer }; // Return renderer and camera if needed elsewhere } -// --- 5. Bitbybit Kernel Initialization Logic --- -async function initWithKernels( - scene: Scene, - bitbybit: BitByBitBase, - options: KernelOptions -): Promise<{ message: string; initializedKernels: string[] }> { - let occtWorkerInstance: Worker | undefined; - let jscadWorkerInstance: Worker | undefined; - let manifoldWorkerInstance: Worker | undefined; - - // 1. Conditionally create worker instances - if (options.enableOCCT) { - occtWorkerInstance = new Worker( - new URL("./workers/occt.worker.ts", import.meta.url), - { name: "OCC_WORKER", type: "module" } - ); - } - if (options.enableJSCAD) { - jscadWorkerInstance = new Worker( - new URL("./workers/jscad.worker.ts", import.meta.url), - { name: "JSCAD_WORKER", type: "module" } - ); - } - if (options.enableManifold) { - manifoldWorkerInstance = new Worker( - new URL("./workers/manifold.worker.ts", import.meta.url), - { name: "MANIFOLD_WORKER", type: "module" } - ); - } - - // 2. Initialize Bitbybit - await bitbybit.init( - scene, - occtWorkerInstance, - jscadWorkerInstance, - manifoldWorkerInstance - ); - - // 3. Collect promises for kernel initializations - const initializationPromises: Promise[] = []; - let anyKernelSelectedForInit = false; - - if (options.enableOCCT) { - anyKernelSelectedForInit = true; - if (bitbybit.occtWorkerManager) { - initializationPromises.push( - firstValueFrom( - bitbybit.occtWorkerManager.occWorkerState$.pipe( - first((s) => s.state === OccStateEnum.initialised), - map(() => "OCCT") - ) - ) - ); - } else { - console.warn( - "OCCT enabled in options, but occtWorkerManager not found after init." - ); - } - } - - if (options.enableJSCAD) { - anyKernelSelectedForInit = true; - if (bitbybit.jscadWorkerManager) { - initializationPromises.push( - firstValueFrom( - bitbybit.jscadWorkerManager.jscadWorkerState$.pipe( - first((s) => s.state === JscadStateEnum.initialised), - map(() => "JSCAD") - ) - ) - ); - } else { - console.warn( - "JSCAD enabled in options, but jscadWorkerManager not found after init." - ); - } - } - - if (options.enableManifold) { - anyKernelSelectedForInit = true; - if (bitbybit.manifoldWorkerManager && bitbybit.manifoldWorkerManager.manifoldWorkerState$) { - initializationPromises.push( - firstValueFrom( - bitbybit.manifoldWorkerManager.manifoldWorkerState$.pipe( - first((s) => s.state === ManifoldStateEnum.initialised), - map(() => "Manifold") - ) - ) - ); - } else { - console.warn( - "Manifold enabled in options, but manifoldWorkerManager not found after init." - ); - } - } - - // 4. Wait for selected & available kernels or handle no selection/availability - if (!anyKernelSelectedForInit) { - console.log("No kernels selected for initialization."); - return { message: "No kernels selected for initialization.", initializedKernels: [] }; - } - - if (initializationPromises.length === 0) { - // Kernels were selected, but none were awaitable (e.g., managers missing for all selected) - console.log( - "Kernels were selected, but none had managers available for awaiting initialization." - ); - return { - message: "Selected kernels were not awaitable for initialization state.", - initializedKernels: [], - }; - } - - const initializedKernels = await Promise.all(initializationPromises); - console.log("Kernels initialized:", initializedKernels.join(", ")); - return { - message: `Successfully initialized: ${initializedKernels.join(", ")}`, - initializedKernels, - }; -} +// // --- 5. Bitbybit Kernel Initialization Logic --- +// async function initWithKernels( +// scene: Scene, +// bitbybit: BitByBitBase, +// options: KernelOptions +// ): Promise<{ message: string; initializedKernels: string[] }> { +// let occtWorkerInstance: Worker | undefined; +// let jscadWorkerInstance: Worker | undefined; +// let manifoldWorkerInstance: Worker | undefined; + +// // 1. Conditionally create worker instances +// if (options.enableOCCT) { +// occtWorkerInstance = new Worker( +// new URL("./workers/occt.worker.ts", import.meta.url), +// { name: "OCC_WORKER", type: "module" } +// ); +// } +// if (options.enableJSCAD) { +// jscadWorkerInstance = new Worker( +// new URL("./workers/jscad.worker.ts", import.meta.url), +// { name: "JSCAD_WORKER", type: "module" } +// ); +// } +// if (options.enableManifold) { +// manifoldWorkerInstance = new Worker( +// new URL("./workers/manifold.worker.ts", import.meta.url), +// { name: "MANIFOLD_WORKER", type: "module" } +// ); +// } + +// // 2. Initialize Bitbybit +// await bitbybit.init( +// scene, +// occtWorkerInstance, +// jscadWorkerInstance, +// manifoldWorkerInstance +// ); + +// // 3. Collect promises for kernel initializations +// const initializationPromises: Promise[] = []; +// let anyKernelSelectedForInit = false; + +// if (options.enableOCCT) { +// anyKernelSelectedForInit = true; +// if (bitbybit.occtWorkerManager) { +// initializationPromises.push( +// firstValueFrom( +// bitbybit.occtWorkerManager.occWorkerState$.pipe( +// first((s) => s.state === OccStateEnum.initialised), +// map(() => "OCCT") +// ) +// ) +// ); +// } else { +// console.warn( +// "OCCT enabled in options, but occtWorkerManager not found after init." +// ); +// } +// } + +// if (options.enableJSCAD) { +// anyKernelSelectedForInit = true; +// if (bitbybit.jscadWorkerManager) { +// initializationPromises.push( +// firstValueFrom( +// bitbybit.jscadWorkerManager.jscadWorkerState$.pipe( +// first((s) => s.state === JscadStateEnum.initialised), +// map(() => "JSCAD") +// ) +// ) +// ); +// } else { +// console.warn( +// "JSCAD enabled in options, but jscadWorkerManager not found after init." +// ); +// } +// } + +// if (options.enableManifold) { +// anyKernelSelectedForInit = true; +// if (bitbybit.manifoldWorkerManager && bitbybit.manifoldWorkerManager.manifoldWorkerState$) { +// initializationPromises.push( +// firstValueFrom( +// bitbybit.manifoldWorkerManager.manifoldWorkerState$.pipe( +// first((s) => s.state === ManifoldStateEnum.initialised), +// map(() => "Manifold") +// ) +// ) +// ); +// } else { +// console.warn( +// "Manifold enabled in options, but manifoldWorkerManager not found after init." +// ); +// } +// } + +// // 4. Wait for selected & available kernels or handle no selection/availability +// if (!anyKernelSelectedForInit) { +// console.log("No kernels selected for initialization."); +// return { message: "No kernels selected for initialization.", initializedKernels: [] }; +// } + +// if (initializationPromises.length === 0) { +// // Kernels were selected, but none were awaitable (e.g., managers missing for all selected) +// console.log( +// "Kernels were selected, but none had managers available for awaiting initialization." +// ); +// return { +// message: "Selected kernels were not awaitable for initialization state.", +// initializedKernels: [], +// }; +// } + +// const initializedKernels = await Promise.all(initializationPromises); +// console.log("Kernels initialized:", initializedKernels.join(", ")); +// return { +// message: `Successfully initialized: ${initializedKernels.join(", ")}`, +// initializedKernels, +// }; +// } // --- 6. Geometry Creation Functions (Examples) --- async function createOCCTGeometry(bitbybit: BitByBitBase, color: string) { @@ -450,8 +440,8 @@ async function createDrawingExamples(bitbybit: BitByBitBase) { [ [60, -20, -5], [70, -20, 5], - ] , - ]as Inputs.Base.Segment3[]; + ], + ] as Inputs.Base.Segment3[]; const segmentsDrawOptions = new Inputs.Draw.DrawBasicGeometryOptions(); segmentsDrawOptions.colours = ["#ffff00", "#ff00ff", "#00ffff"]; // Yellow, Magenta, Cyan segmentsDrawOptions.size = 2.5; diff --git a/packages/dev/babylonjs/lib/api/index.ts b/packages/dev/babylonjs/lib/api/index.ts index 1c15f59a..bfca0520 100644 --- a/packages/dev/babylonjs/lib/api/index.ts +++ b/packages/dev/babylonjs/lib/api/index.ts @@ -2,4 +2,6 @@ export * from "./bitbybit"; export * from "./context"; export * from "./draw-helper"; export * from "./bitbybit-base"; +export * from "./init-kernels"; +export * from "./worker-urls"; export * as Inputs from "./inputs"; diff --git a/packages/dev/babylonjs/lib/api/init-kernels.ts b/packages/dev/babylonjs/lib/api/init-kernels.ts new file mode 100644 index 00000000..02c3d8c0 --- /dev/null +++ b/packages/dev/babylonjs/lib/api/init-kernels.ts @@ -0,0 +1,77 @@ +import * as BABYLON from "@babylonjs/core"; +import { BitByBitBase } from "./bitbybit-base"; +import { + type InitKernelsResult, + type WorkerInstances, + type WorkerOptions, + getOrCreateWorkers, + waitForKernelInitialization, +} from "@bitbybit-dev/core"; + +/** + * Options for initializing bitbybit with Babylon.js + */ +export interface InitBitbybitOptions extends WorkerOptions { + /** Pre-created worker instances. If not provided, workers will be created from CDN. */ + workers?: WorkerInstances; + /** Havok physics plugin instance (optional) */ + havokPlugin?: BABYLON.HavokPlugin; +} + +// Re-export types for convenience +export { type InitKernelsResult, type WorkerInstances, type WorkerOptions }; + +/** + * Initialize BitByBit with Babylon.js scene in a single call. + * This is the recommended way to set up BitByBit for Babylon.js projects. + * + * Workers are automatically created from CDN if not provided in options. + * If you don't specify loadFonts, fonts will NOT be loaded (empty array is passed). + * + * @param scene - Babylon.js Scene instance + * @param bitbybit - BitByBitBase instance + * @param options - Initialization options including which kernels to enable + * @returns Promise with initialization result and the bitbybit instance + * + * @example + * ```typescript + * import { BitByBitBase, initBitbybit } from "@bitbybit-dev/babylonjs"; + * + * const scene = new BABYLON.Scene(engine); + * const bitbybit = new BitByBitBase(); + * + * await initBitbybit(scene, bitbybit, { + * enableOCCT: true, + * enableJSCAD: true, + * enableManifold: false, + * loadFonts: ["roboto"], // Optional: specify fonts, or omit to skip loading + * }); + * + * // Now you can use bitbybit.occt, bitbybit.jscad, etc. + * ``` + */ +export async function initBitbybit( + scene: BABYLON.Scene, + bitbybit: BitByBitBase, + options: InitBitbybitOptions +): Promise { + // Get or create workers + const workers = getOrCreateWorkers(options); + + // Initialize bitbybit with scene and workers + bitbybit.init( + scene, + workers.occtWorker, + workers.jscadWorker, + workers.manifoldWorker, + options.havokPlugin + ); + + // Wait for kernel initialization + const result = await waitForKernelInitialization(bitbybit, options); + + return { + ...result, + bitbybit, + }; +} diff --git a/packages/dev/babylonjs/lib/api/inputs/draw-inputs.ts b/packages/dev/babylonjs/lib/api/inputs/draw-inputs.ts index a5b587f8..eb84ded5 100644 --- a/packages/dev/babylonjs/lib/api/inputs/draw-inputs.ts +++ b/packages/dev/babylonjs/lib/api/inputs/draw-inputs.ts @@ -1,14 +1,14 @@ /* eslint-disable @typescript-eslint/no-namespace */ import * as BABYLON from "@babylonjs/core"; -import * as Inputs from "./inputs"; +import * as Inputs from "./index"; import { Base } from "./base-inputs"; // tslint:disable-next-line: no-namespace export namespace Draw { export type DrawOptions = DrawBasicGeometryOptions | DrawManifoldOrCrossSectionOptions | DrawOcctShapeOptions | DrawOcctShapeSimpleOptions | DrawOcctShapeMaterialOptions | DrawNodeOptions; - export type Entity = Base.Point3 | Base.Vector3 | Base.Line3 | Base.Polyline3 | Base.VerbCurve | Base.VerbSurface | Inputs.OCCT.TopoDSShapePointer | Inputs.Tag.TagDto | { type: string, name?: string, entityName?: string } | - Base.Point3[] | Base.Vector3[] | Base.Line3[] | Base.Polyline3[] | Base.VerbCurve[] | Base.VerbSurface[] | Inputs.OCCT.TopoDSShapePointer[] | Inputs.Tag.TagDto[] | { type: string[], name?: string, entityName?: string }; + export type Entity = number[] | [number, number, number] | Base.Point3 | Base.Vector3 | Base.Line3 | Base.Segment3 | Base.Polyline3 | Base.VerbCurve | Base.VerbSurface | Inputs.OCCT.TopoDSShapePointer | Inputs.Tag.TagDto | { type: string, name?: string, entityName?: string } | + number[][] | Base.Point3[] | Base.Vector3[] | Base.Line3[] | Base.Segment3[] | Base.Polyline3[] | Base.VerbCurve[] | Base.VerbSurface[] | Inputs.OCCT.TopoDSShapePointer[] | Inputs.Tag.TagDto[] | { type: string[], name?: string, entityName?: string }; export class DrawAny { constructor(entity?: Entity, options?: DrawOptions, babylonMesh?: BABYLON.Mesh | BABYLON.LinesMesh) { diff --git a/packages/dev/babylonjs/lib/api/worker-urls.ts b/packages/dev/babylonjs/lib/api/worker-urls.ts new file mode 100644 index 00000000..70ba3b3d --- /dev/null +++ b/packages/dev/babylonjs/lib/api/worker-urls.ts @@ -0,0 +1,12 @@ +/** + * Re-export worker utilities from @bitbybit-dev/core + */ +export { + type WorkerInstances, + type WorkerOptions, + createOcctWorkerFromCDN, + createJscadWorkerFromCDN, + createManifoldWorkerFromCDN, + createWorkersFromCDN, + createWorkersFromUrls, +} from "@bitbybit-dev/core"; diff --git a/packages/dev/core/lib/api/index.ts b/packages/dev/core/lib/api/index.ts index adef67ad..0175ad04 100644 --- a/packages/dev/core/lib/api/index.ts +++ b/packages/dev/core/lib/api/index.ts @@ -3,4 +3,6 @@ export * from "./constants"; export * from "./context"; export * from "./draw-core"; export * from "./draw-helper-core"; +export * from "./worker-utils"; +export * from "./init-kernels"; export * as Inputs from "./inputs"; diff --git a/packages/dev/core/lib/api/init-kernels.ts b/packages/dev/core/lib/api/init-kernels.ts new file mode 100644 index 00000000..6e19c7c6 --- /dev/null +++ b/packages/dev/core/lib/api/init-kernels.ts @@ -0,0 +1,134 @@ +import { OccStateEnum, OCCTWorkerManager } from "@bitbybit-dev/occt-worker"; +import { JscadStateEnum, JSCADWorkerManager } from "@bitbybit-dev/jscad-worker"; +import { ManifoldStateEnum, ManifoldWorkerManager } from "@bitbybit-dev/manifold-worker"; +import { firstValueFrom, first, map } from "rxjs"; +import type { WorkerInstances, WorkerOptions } from "./worker-utils"; +import { createWorkersFromCDN } from "./worker-utils"; + +/** + * Options for initializing bitbybit + */ +export interface InitBitbybitOptions extends WorkerOptions { + /** Pre-created worker instances. If not provided, workers will be created from CDN. */ + workers?: WorkerInstances; +} + +/** + * Interface for worker managers that engine-specific BitByBitBase classes must implement + */ +export interface BitByBitWorkerManagers { + occtWorkerManager: OCCTWorkerManager; + jscadWorkerManager: JSCADWorkerManager; + manifoldWorkerManager: ManifoldWorkerManager; +} + +/** + * Result of kernel initialization + */ +export interface InitKernelsResult { + message: string; + initializedKernels: string[]; +} + +/** + * Waits for all enabled kernels to be initialized. + * This is engine-agnostic and can be used by all engine packages. + * + * @param managers - The worker managers from BitByBitBase + * @param options - Which kernels are enabled + */ +export async function waitForKernelInitialization( + managers: BitByBitWorkerManagers, + options: WorkerOptions +): Promise { + const initializationPromises: Promise[] = []; + let anyKernelSelectedForInit = false; + + if (options.enableOCCT) { + anyKernelSelectedForInit = true; + if (managers.occtWorkerManager) { + initializationPromises.push( + firstValueFrom( + managers.occtWorkerManager.occWorkerState$.pipe( + first((s) => s.state === OccStateEnum.initialised), + map(() => "OCCT") + ) + ) + ); + } else { + console.warn( + "OCCT enabled in options, but occtWorkerManager not found after init." + ); + } + } + + if (options.enableJSCAD) { + anyKernelSelectedForInit = true; + if (managers.jscadWorkerManager) { + initializationPromises.push( + firstValueFrom( + managers.jscadWorkerManager.jscadWorkerState$.pipe( + first((s) => s.state === JscadStateEnum.initialised), + map(() => "JSCAD") + ) + ) + ); + } else { + console.warn( + "JSCAD enabled in options, but jscadWorkerManager not found after init." + ); + } + } + + if (options.enableManifold) { + anyKernelSelectedForInit = true; + if (managers.manifoldWorkerManager?.manifoldWorkerState$) { + initializationPromises.push( + firstValueFrom( + managers.manifoldWorkerManager.manifoldWorkerState$.pipe( + first((s) => s.state === ManifoldStateEnum.initialised), + map(() => "Manifold") + ) + ) + ); + } else { + console.warn( + "Manifold enabled in options, but manifoldWorkerManager not found after init." + ); + } + } + + if (!anyKernelSelectedForInit) { + console.log("No kernels selected for initialization."); + return { message: "No kernels selected for initialization.", initializedKernels: [] }; + } + + if (initializationPromises.length === 0) { + console.log( + "Kernels were selected, but none had managers available for awaiting initialization." + ); + return { + message: "Selected kernels were not awaitable for initialization state.", + initializedKernels: [], + }; + } + + const initializedKernels = await Promise.all(initializationPromises); + return { + message: `Successfully initialized: ${initializedKernels.join(", ")}`, + initializedKernels, + }; +} + +/** + * Creates worker instances based on options. + * If workers are provided in options, uses those. Otherwise creates from CDN. + * + * @param options - Initialization options + */ +export function getOrCreateWorkers(options: InitBitbybitOptions): WorkerInstances { + if (options.workers) { + return options.workers; + } + return createWorkersFromCDN(options); +} diff --git a/packages/dev/core/lib/api/worker-utils.ts b/packages/dev/core/lib/api/worker-utils.ts new file mode 100644 index 00000000..cc7a2dd3 --- /dev/null +++ b/packages/dev/core/lib/api/worker-utils.ts @@ -0,0 +1,156 @@ +import { GlobalCDNProvider } from "@bitbybit-dev/base"; + +/** + * Worker utilities for bitbybit engine packages. + * + * Provides multiple strategies for creating workers: + * 1. From CDN URLs (zero configuration, no local files needed) + * 2. From local project files (for offline/production use) + */ + +/** + * Worker configuration containing the Worker instance or undefined + */ +export interface WorkerInstances { + occtWorker?: Worker; + jscadWorker?: Worker; + manifoldWorker?: Worker; +} + +/** + * Options for worker creation + */ +export interface WorkerOptions { + /** Enable OCCT (OpenCASCADE) kernel */ + enableOCCT?: boolean; + /** Enable JSCAD kernel */ + enableJSCAD?: boolean; + /** Enable Manifold kernel */ + enableManifold?: boolean; + /** Custom CDN URL (defaults to GlobalCDNProvider.BITBYBIT_CDN_URL) */ + cdnUrl?: string; + /** + * Array of font keys to load for OCCT, or undefined to load all fonts. + * Pass an empty array to skip loading fonts. + */ + loadFonts?: string[]; +} + +/** + * Helper function to create a cross-origin worker URL using importScripts. + * This is required for loading workers from CDN. + */ +function getWorkerURL(url: string): string { + const content = `importScripts("${url}");`; + return URL.createObjectURL(new Blob([content], { type: "text/javascript" })); +} + +/** + * Creates an OCCT worker from CDN. + * No local files needed - worker is loaded from CDN. + * + * @param cdnUrl - Optional custom CDN URL + * @param loadFonts - Array of font keys to load, or undefined to load all fonts. Empty array skips font loading. + */ +export function createOcctWorkerFromCDN(cdnUrl?: string, loadFonts?: string[]): Worker { + const baseUrl = cdnUrl ?? GlobalCDNProvider.BITBYBIT_CDN_URL; + const scriptUrl = `${baseUrl}/workers/bitbybit-occt-webworker.js`; + const workerUrl = getWorkerURL(scriptUrl); + const worker = new Worker(workerUrl, { name: "OCC_WORKER" }); + // Pass empty array if loadFonts is undefined to avoid loading all fonts by default + worker.postMessage({ type: "initialise", loadFonts: loadFonts ?? [] }); + URL.revokeObjectURL(workerUrl); + return worker; +} + +/** + * Creates a JSCAD worker from CDN. + * No local files needed - worker is loaded from CDN. + * + * @param cdnUrl - Optional custom CDN URL + */ +export function createJscadWorkerFromCDN(cdnUrl?: string): Worker { + const baseUrl = cdnUrl ?? GlobalCDNProvider.BITBYBIT_CDN_URL; + const scriptUrl = `${baseUrl}/workers/bitbybit-jscad-webworker.js`; + const workerUrl = getWorkerURL(scriptUrl); + const worker = new Worker(workerUrl, { name: "JSCAD_WORKER" }); + URL.revokeObjectURL(workerUrl); + return worker; +} + +/** + * Creates a Manifold worker from CDN. + * No local files needed - worker is loaded from CDN. + * + * @param cdnUrl - Optional custom CDN URL + */ +export function createManifoldWorkerFromCDN(cdnUrl?: string): Worker { + const baseUrl = cdnUrl ?? GlobalCDNProvider.BITBYBIT_CDN_URL; + const scriptUrl = `${baseUrl}/workers/bitbybit-manifold-webworker.js`; + const workerUrl = getWorkerURL(scriptUrl); + const worker = new Worker(workerUrl, { name: "MANIFOLD_WORKER" }); + URL.revokeObjectURL(workerUrl); + return worker; +} + +/** + * Creates all enabled worker instances from CDN. + * This is the simplest way to get started - no local files needed! + * + * @example + * ```typescript + * const workers = createWorkersFromCDN({ enableOCCT: true, enableJSCAD: true }); + * ``` + */ +export function createWorkersFromCDN(options: WorkerOptions): WorkerInstances { + const workers: WorkerInstances = {}; + const cdnUrl = options.cdnUrl; + // Pass loadFonts as-is; createOcctWorkerFromCDN will handle undefined -> [] + const loadFonts = options.loadFonts; + + if (options.enableOCCT) { + workers.occtWorker = createOcctWorkerFromCDN(cdnUrl, loadFonts); + } + if (options.enableJSCAD) { + workers.jscadWorker = createJscadWorkerFromCDN(cdnUrl); + } + if (options.enableManifold) { + workers.manifoldWorker = createManifoldWorkerFromCDN(cdnUrl); + } + + return workers; +} + +/** + * Creates workers from local project files (ES module workers). + * Use this when you have worker files in your project for offline/production use. + * + * @param workerUrls - URLs to your local worker files + * + * @example + * ```typescript + * const workers = createWorkersFromUrls({ + * occtWorkerUrl: new URL("./workers/occt.worker.ts", import.meta.url), + * jscadWorkerUrl: new URL("./workers/jscad.worker.ts", import.meta.url), + * }); + * ``` + */ +export function createWorkersFromUrls(workerUrls: { + occtWorkerUrl?: URL | string; + jscadWorkerUrl?: URL | string; + manifoldWorkerUrl?: URL | string; +}): WorkerInstances { + const workers: WorkerInstances = {}; + + if (workerUrls.occtWorkerUrl) { + workers.occtWorker = new Worker(workerUrls.occtWorkerUrl, { name: "OCC_WORKER", type: "module" }); + } + if (workerUrls.jscadWorkerUrl) { + workers.jscadWorker = new Worker(workerUrls.jscadWorkerUrl, { name: "JSCAD_WORKER", type: "module" }); + } + if (workerUrls.manifoldWorkerUrl) { + workers.manifoldWorker = new Worker(workerUrls.manifoldWorkerUrl, { name: "MANIFOLD_WORKER", type: "module" }); + } + + return workers; +} diff --git a/packages/dev/playcanvas/lib/api/index.ts b/packages/dev/playcanvas/lib/api/index.ts index 1c15f59a..bfca0520 100644 --- a/packages/dev/playcanvas/lib/api/index.ts +++ b/packages/dev/playcanvas/lib/api/index.ts @@ -2,4 +2,6 @@ export * from "./bitbybit"; export * from "./context"; export * from "./draw-helper"; export * from "./bitbybit-base"; +export * from "./init-kernels"; +export * from "./worker-urls"; export * as Inputs from "./inputs"; diff --git a/packages/dev/playcanvas/lib/api/init-kernels.ts b/packages/dev/playcanvas/lib/api/init-kernels.ts new file mode 100644 index 00000000..eab18a4e --- /dev/null +++ b/packages/dev/playcanvas/lib/api/init-kernels.ts @@ -0,0 +1,78 @@ +import * as pc from "playcanvas"; +import { BitByBitBase } from "./bitbybit-base"; +import { + type InitKernelsResult, + type WorkerInstances, + type WorkerOptions, + getOrCreateWorkers, + waitForKernelInitialization, +} from "@bitbybit-dev/core"; + +/** + * Options for initializing bitbybit with PlayCanvas + */ +export interface InitBitbybitOptions extends WorkerOptions { + /** Pre-created worker instances. If not provided, workers will be created from CDN. */ + workers?: WorkerInstances; +} + +// Re-export types for convenience +export { type InitKernelsResult, type WorkerInstances, type WorkerOptions }; + +/** + * Initialize BitByBit with PlayCanvas in a single call. + * This is the recommended way to set up BitByBit for PlayCanvas projects. + * + * Workers are automatically created from CDN if not provided in options. + * If you don't specify loadFonts, fonts will NOT be loaded (empty array is passed). + * + * @param app - PlayCanvas AppBase instance + * @param scene - PlayCanvas Entity (root entity for the scene) + * @param bitbybit - BitByBitBase instance + * @param options - Initialization options including which kernels to enable + * @returns Promise with initialization result and the bitbybit instance + * + * @example + * ```typescript + * import { BitByBitBase, initBitbybit } from "@bitbybit-dev/playcanvas"; + * + * const app = new pc.Application(canvas); + * const scene = app.root; + * const bitbybit = new BitByBitBase(); + * + * await initBitbybit(app, scene, bitbybit, { + * enableOCCT: true, + * enableJSCAD: true, + * enableManifold: false, + * loadFonts: ["roboto"], // Optional: specify fonts, or omit to skip loading + * }); + * + * // Now you can use bitbybit.occt, bitbybit.jscad, etc. + * ``` + */ +export async function initBitbybit( + app: pc.AppBase, + scene: pc.Entity, + bitbybit: BitByBitBase, + options: InitBitbybitOptions +): Promise { + // Get or create workers + const workers = getOrCreateWorkers(options); + + // Initialize bitbybit with app, scene and workers + bitbybit.init( + app, + scene, + workers.occtWorker, + workers.jscadWorker, + workers.manifoldWorker + ); + + // Wait for kernel initialization + const result = await waitForKernelInitialization(bitbybit, options); + + return { + ...result, + bitbybit, + }; +} diff --git a/packages/dev/playcanvas/lib/api/inputs/draw-inputs.ts b/packages/dev/playcanvas/lib/api/inputs/draw-inputs.ts index 6a091045..a5217803 100644 --- a/packages/dev/playcanvas/lib/api/inputs/draw-inputs.ts +++ b/packages/dev/playcanvas/lib/api/inputs/draw-inputs.ts @@ -8,9 +8,9 @@ import * as pc from "playcanvas"; export namespace Draw { export type DrawOptions = DrawOcctShapeOptions | DrawBasicGeometryOptions | DrawManifoldOrCrossSectionOptions; - export type Entity = Base.Point3 | Base.Vector3 | Base.Line3 | Base.Polyline3 | Base.VerbCurve | Base.VerbSurface | Inputs.OCCT.TopoDSShapePointer | Inputs.Tag.TagDto | - Base.Point3[] | Base.Vector3[] | Base.Line3[] | Base.Polyline3[] | Base.VerbCurve[] | Base.VerbSurface[] | Inputs.OCCT.TopoDSShapePointer[] | Inputs.Tag.TagDto[]; - + export type Entity = number[] | [number, number, number] | Base.Point3 | Base.Vector3 | Base.Line3 | Base.Segment3 | Base.Polyline3 | Base.VerbCurve | Base.VerbSurface | Inputs.OCCT.TopoDSShapePointer | Inputs.Tag.TagDto | { type: string, name?: string, entityName?: string } | + number[][] | Base.Point3[] | Base.Vector3[] | Base.Line3[] | Base.Segment3[] | Base.Polyline3[] | Base.VerbCurve[] | Base.VerbSurface[] | Inputs.OCCT.TopoDSShapePointer[] | Inputs.Tag.TagDto[] | { type: string[], name?: string, entityName?: string }; + /** * Metadata stored on drawn entities to track their type and options for updates */ diff --git a/packages/dev/playcanvas/lib/api/worker-urls.ts b/packages/dev/playcanvas/lib/api/worker-urls.ts new file mode 100644 index 00000000..70ba3b3d --- /dev/null +++ b/packages/dev/playcanvas/lib/api/worker-urls.ts @@ -0,0 +1,12 @@ +/** + * Re-export worker utilities from @bitbybit-dev/core + */ +export { + type WorkerInstances, + type WorkerOptions, + createOcctWorkerFromCDN, + createJscadWorkerFromCDN, + createManifoldWorkerFromCDN, + createWorkersFromCDN, + createWorkersFromUrls, +} from "@bitbybit-dev/core"; diff --git a/packages/dev/threejs/lib/api/index.ts b/packages/dev/threejs/lib/api/index.ts index 1c15f59a..bfca0520 100644 --- a/packages/dev/threejs/lib/api/index.ts +++ b/packages/dev/threejs/lib/api/index.ts @@ -2,4 +2,6 @@ export * from "./bitbybit"; export * from "./context"; export * from "./draw-helper"; export * from "./bitbybit-base"; +export * from "./init-kernels"; +export * from "./worker-urls"; export * as Inputs from "./inputs"; diff --git a/packages/dev/threejs/lib/api/init-kernels.ts b/packages/dev/threejs/lib/api/init-kernels.ts new file mode 100644 index 00000000..1c286966 --- /dev/null +++ b/packages/dev/threejs/lib/api/init-kernels.ts @@ -0,0 +1,86 @@ +import { Scene } from "three"; +import { BitByBitBase } from "./bitbybit-base"; +import { + type InitBitbybitOptions, + type InitKernelsResult, + getOrCreateWorkers, + waitForKernelInitialization, +} from "@bitbybit-dev/core"; + +// Re-export types from core for convenience +export { type InitBitbybitOptions, type InitKernelsResult } from "@bitbybit-dev/core"; + +/** + * Initialize BitByBit with Three.js scene in a single call. + * This is the recommended way to set up BitByBit for Three.js projects. + * + * Workers are automatically created from CDN if not provided in options. + * If you don't specify loadFonts, fonts will NOT be loaded (empty array is passed). + * + * @param scene - Three.js Scene instance + * @param bitbybit - BitByBitBase instance + * @param options - Initialization options including which kernels to enable + * @returns Promise with initialization result and the bitbybit instance + * + * @example + * ```typescript + * import { BitByBitBase, initBitbybit } from "@bitbybit-dev/threejs"; + * + * const scene = new Scene(); + * const bitbybit = new BitByBitBase(); + * + * await initBitbybit(scene, bitbybit, { + * enableOCCT: true, + * enableJSCAD: true, + * enableManifold: false, + * loadFonts: ["roboto"], // Optional: specify fonts, or omit to skip loading + * }); + * + * // Now you can use bitbybit.occt, bitbybit.jscad, etc. + * ``` + */ +export async function initBitbybit( + scene: Scene, + bitbybit: BitByBitBase, + options: InitBitbybitOptions +): Promise { + // Get or create workers + const workers = getOrCreateWorkers(options); + + // Initialize bitbybit with scene and workers + bitbybit.init( + scene, + workers.occtWorker, + workers.jscadWorker, + workers.manifoldWorker + ); + + // Wait for kernel initialization + const result = await waitForKernelInitialization(bitbybit, options); + + return { + ...result, + bitbybit, + }; +} + +/** + * @deprecated Use initBitbybit instead for simpler initialization. + * This function is kept for backward compatibility. + */ +export async function initKernels( + scene: Scene, + bitbybit: BitByBitBase, + options: InitBitbybitOptions, + workers?: { occtWorker?: Worker; jscadWorker?: Worker; manifoldWorker?: Worker } +): Promise { + const mergedOptions: InitBitbybitOptions = { + ...options, + workers: workers ?? options.workers, + }; + const result = await initBitbybit(scene, bitbybit, mergedOptions); + return { + message: result.message, + initializedKernels: result.initializedKernels, + }; +} diff --git a/packages/dev/threejs/lib/api/inputs/draw-inputs.ts b/packages/dev/threejs/lib/api/inputs/draw-inputs.ts index 5d8eedd3..46d2d34a 100644 --- a/packages/dev/threejs/lib/api/inputs/draw-inputs.ts +++ b/packages/dev/threejs/lib/api/inputs/draw-inputs.ts @@ -7,9 +7,8 @@ import { Base } from "./base-inputs"; export namespace Draw { export type DrawOptions = DrawOcctShapeOptions | DrawBasicGeometryOptions | DrawManifoldOrCrossSectionOptions; - export type Entity = Base.Point3 | Base.Vector3 | Base.Line3 | Base.Polyline3 | Base.VerbCurve | Base.VerbSurface | Inputs.OCCT.TopoDSShapePointer | Inputs.Tag.TagDto | - Base.Point3[] | Base.Vector3[] | Base.Line3[] | Base.Polyline3[] | Base.VerbCurve[] | Base.VerbSurface[] | Inputs.OCCT.TopoDSShapePointer[] | Inputs.Tag.TagDto[]; - + export type Entity = number[] | [number, number, number] | Base.Point3 | Base.Vector3 | Base.Line3 | Base.Segment3 | Base.Polyline3 | Base.VerbCurve | Base.VerbSurface | Inputs.OCCT.TopoDSShapePointer | Inputs.Tag.TagDto | { type: string, name?: string, entityName?: string } | + number[][] | Base.Point3[] | Base.Vector3[] | Base.Line3[] | Base.Segment3[] | Base.Polyline3[] | Base.VerbCurve[] | Base.VerbSurface[] | Inputs.OCCT.TopoDSShapePointer[] | Inputs.Tag.TagDto[] | { type: string[], name?: string, entityName?: string }; export class DrawAny { constructor(entity?: Entity, options?: DrawOptions) { if (entity !== undefined) { this.entity = entity; } diff --git a/packages/dev/threejs/lib/api/worker-urls.ts b/packages/dev/threejs/lib/api/worker-urls.ts new file mode 100644 index 00000000..70ba3b3d --- /dev/null +++ b/packages/dev/threejs/lib/api/worker-urls.ts @@ -0,0 +1,12 @@ +/** + * Re-export worker utilities from @bitbybit-dev/core + */ +export { + type WorkerInstances, + type WorkerOptions, + createOcctWorkerFromCDN, + createJscadWorkerFromCDN, + createManifoldWorkerFromCDN, + createWorkersFromCDN, + createWorkersFromUrls, +} from "@bitbybit-dev/core"; From f01800b7a1ad909db056bd2975a0ddece64c8336 Mon Sep 17 00:00:00 2001 From: Matas Ubarevicius Date: Sun, 11 Jan 2026 16:42:49 +0200 Subject: [PATCH 06/31] first iteration of orbit camera for threejs implemented --- .../vite/threejs/starter-template/src/main.ts | 59 +- .../threejs/lib/api/__mocks__/test-helpers.ts | 67 ++ packages/dev/threejs/lib/api/bitbybit-base.ts | 2 +- .../dev/threejs/lib/api/bitbybit/index.ts | 4 +- .../dev/threejs/lib/api/bitbybit/threejs.ts | 14 +- .../lib/api/bitbybit/threejs/camera.ts | 13 + .../threejs/lib/api/bitbybit/threejs/index.ts | 2 + .../api/bitbybit/threejs/orbit-camera.test.ts | 517 +++++++++++++ .../lib/api/bitbybit/threejs/orbit-camera.ts | 693 ++++++++++++++++++ packages/dev/threejs/lib/api/inputs/index.ts | 1 + packages/dev/threejs/lib/api/inputs/inputs.ts | 1 + .../api/inputs/threejs-camera-inputs.test.ts | 248 +++++++ .../lib/api/inputs/threejs-camera-inputs.ts | 394 ++++++++++ 13 files changed, 1984 insertions(+), 31 deletions(-) create mode 100644 packages/dev/threejs/lib/api/bitbybit/threejs/camera.ts create mode 100644 packages/dev/threejs/lib/api/bitbybit/threejs/index.ts create mode 100644 packages/dev/threejs/lib/api/bitbybit/threejs/orbit-camera.test.ts create mode 100644 packages/dev/threejs/lib/api/bitbybit/threejs/orbit-camera.ts create mode 100644 packages/dev/threejs/lib/api/inputs/threejs-camera-inputs.test.ts create mode 100644 packages/dev/threejs/lib/api/inputs/threejs-camera-inputs.ts diff --git a/examples/vite/threejs/starter-template/src/main.ts b/examples/vite/threejs/starter-template/src/main.ts index 4a27cc63..bcc25122 100644 --- a/examples/vite/threejs/starter-template/src/main.ts +++ b/examples/vite/threejs/starter-template/src/main.ts @@ -1,20 +1,21 @@ import "./style.css"; // Basic styling -import { BitByBitBase, Inputs, initBitbybit, type InitBitbybitOptions } from "@bitbybit-dev/threejs"; -import { OrbitControls } from "three/examples/jsm/controls/OrbitControls"; +import { BitByBitBase, Inputs, initBitbybit, type InitBitbybitOptions, type OrbitCameraController } from "@bitbybit-dev/threejs"; import { Color, HemisphereLight, - PerspectiveCamera, Scene, WebGLRenderer, } from "three"; +// Store the orbit camera controller globally so bitbybit can access it +let orbitCameraController: OrbitCameraController | null = null; + // --- 1. Main Application Entry Point --- start(); async function start() { // Initialize basic Three.js scene - const { scene } = initThreeJS(); + const { scene, renderer } = initThreeJS(); // Create an instance of BitByBitBase for Three.js const bitbybit = new BitByBitBase(); @@ -31,6 +32,27 @@ async function start() { // Initialize BitByBit in a single call - workers are created from CDN automatically! await initBitbybit(scene, bitbybit, options); + // --- 2.5. Setup BitByBit Orbit Camera --- + // Setup orbit camera controls using bitbybit library + const cameraOptions = new Inputs.ThreeJSCamera.OrbitCameraDto(); + cameraOptions.distance = 120; + cameraOptions.pitch = 25; + cameraOptions.yaw = 45; + cameraOptions.frameOnStart = false; + cameraOptions.inertiaFactor = 0.1; + cameraOptions.distanceSensitivity = 0.15; + cameraOptions.domElement = renderer.domElement; + orbitCameraController = bitbybit.three.camera.orbitCamera.create(cameraOptions); + + // Update the render loop to use the new camera + const animate = () => { + if (orbitCameraController) { + orbitCameraController.update(0.016); // ~60fps delta time + renderer.render(scene, orbitCameraController.camera); + } + }; + renderer.setAnimationLoop(animate); + // --- 3. Create Geometry with Active Kernels --- if (options.enableOCCT) { await createOCCTGeometry(bitbybit, "#ff0000"); // Red @@ -55,12 +77,6 @@ async function start() { function initThreeJS() { const domNode = document.getElementById("three-canvas") as HTMLCanvasElement; - const camera = new PerspectiveCamera( - 70, - window.innerWidth / window.innerHeight, - 0.1, // Adjusted near plane for typical scenes - 1000 - ); const scene = new Scene(); scene.background = new Color(0x1a1c1f); // Set background color @@ -73,29 +89,16 @@ function initThreeJS() { // Higher values = sharper but more GPU intensive. Use 1 for performance, devicePixelRatio for quality. renderer.setPixelRatio(window.devicePixelRatio); - camera.position.set(50, 50, 100); // Adjusted camera position - camera.lookAt(0, 0, 0); - - const controls = new OrbitControls(camera, renderer.domElement); - controls.enableDamping = true; - controls.dampingFactor = 0.05; // Smoother damping - controls.target.set(0, 0, 0); // Ensure controls target the origin - controls.update(); // Initial update - const onWindowResize = () => { - camera.aspect = window.innerWidth / window.innerHeight; - camera.updateProjectionMatrix(); + if (orbitCameraController) { + orbitCameraController.camera.aspect = window.innerWidth / window.innerHeight; + orbitCameraController.camera.updateProjectionMatrix(); + } renderer.setSize(window.innerWidth, window.innerHeight); }; window.addEventListener("resize", onWindowResize, false); - const animate = () => { - controls.update(); // Important for damping - renderer.render(scene, camera); - }; - renderer.setAnimationLoop(animate); - - return { scene, camera, renderer }; // Return renderer and camera if needed elsewhere + return { scene, renderer }; // Return renderer for camera setup } // // --- 5. Bitbybit Kernel Initialization Logic --- diff --git a/packages/dev/threejs/lib/api/__mocks__/test-helpers.ts b/packages/dev/threejs/lib/api/__mocks__/test-helpers.ts index 047ced13..5900be21 100644 --- a/packages/dev/threejs/lib/api/__mocks__/test-helpers.ts +++ b/packages/dev/threejs/lib/api/__mocks__/test-helpers.ts @@ -197,3 +197,70 @@ export function mockWorkerError(workerManager: any, method: string, error: Error }); }); } + +/** + * Creates a mock window object for testing + */ +export function mockWindow() { + (global as any).window = { + addEventListener: jest.fn(), + removeEventListener: jest.fn(), + innerWidth: 1920, + innerHeight: 1080, + }; +} + +/** + * Creates a mock DOM element for testing orbit camera inputs. + * Supports event listener tracking for simulating user interactions. + */ +export function createMockDOMElement(): HTMLElement { + const listeners: { [key: string]: Array<(...args: unknown[]) => void> } = {}; + return { + addEventListener: jest.fn((type: string, handler: (...args: unknown[]) => void) => { + if (!listeners[type]) { + listeners[type] = []; + } + listeners[type].push(handler); + }), + removeEventListener: jest.fn((type: string, handler: (...args: unknown[]) => void) => { + if (listeners[type]) { + const idx = listeners[type].indexOf(handler); + if (idx >= 0) { + listeners[type].splice(idx, 1); + } + } + }), + dispatchEvent: jest.fn((event: Event) => { + const handlers = listeners[event.type]; + if (handlers) { + handlers.forEach(h => h(event)); + } + }), + getBoundingClientRect: jest.fn(() => ({ + left: 0, + top: 0, + width: 1920, + height: 1080, + })), + } as unknown as HTMLElement; +} + +/** + * Creates mock app and scene for orbit camera tests + */ +export function createOrbitCameraMocks() { + mockWindow(); + const mockScene = new THREEJS.Scene(); + const mockDomElement = createMockDOMElement(); + const mockContext = { + scene: mockScene, + } as Context; + + return { + mockScene, + mockDomElement, + mockContext + }; +} + diff --git a/packages/dev/threejs/lib/api/bitbybit-base.ts b/packages/dev/threejs/lib/api/bitbybit-base.ts index 6dcbd771..95f3511e 100644 --- a/packages/dev/threejs/lib/api/bitbybit-base.ts +++ b/packages/dev/threejs/lib/api/bitbybit-base.ts @@ -72,7 +72,7 @@ export class BitByBitBase { this.math = new MathBitByBit(); this.vector = new Vector(this.math, geometryHelper); const drawHelper = new DrawHelper(this.context, this.jscad.text, this.vector, this.jscadWorkerManager, this.manifoldWorkerManager, this.occtWorkerManager); - this.three = new ThreeJS(drawHelper); + this.three = new ThreeJS(this.context, drawHelper); this.tag = new Tag(this.context); this.draw = new Draw(drawHelper, this.context, this.tag); this.color = new Color(this.math); diff --git a/packages/dev/threejs/lib/api/bitbybit/index.ts b/packages/dev/threejs/lib/api/bitbybit/index.ts index 74add6b8..e9eadc84 100644 --- a/packages/dev/threejs/lib/api/bitbybit/index.ts +++ b/packages/dev/threejs/lib/api/bitbybit/index.ts @@ -1 +1,3 @@ -export * from "./draw"; \ No newline at end of file +export * from "./draw"; +export * from "./threejs"; +export * from "./threejs/index"; diff --git a/packages/dev/threejs/lib/api/bitbybit/threejs.ts b/packages/dev/threejs/lib/api/bitbybit/threejs.ts index 23345aa3..a81c8e2d 100644 --- a/packages/dev/threejs/lib/api/bitbybit/threejs.ts +++ b/packages/dev/threejs/lib/api/bitbybit/threejs.ts @@ -1,5 +1,17 @@ +import { Context } from "../context"; import { DrawHelper } from "../draw-helper"; +import { ThreeJSCamera } from "./threejs/camera"; +/** + * Contains various functions that expose ThreeJS objects + */ export class ThreeJS { - constructor(private readonly drawHelper: DrawHelper) { } + public camera: ThreeJSCamera; + + constructor( + private readonly context: Context, + private readonly drawHelper: DrawHelper + ) { + this.camera = new ThreeJSCamera(this.context); + } } \ No newline at end of file diff --git a/packages/dev/threejs/lib/api/bitbybit/threejs/camera.ts b/packages/dev/threejs/lib/api/bitbybit/threejs/camera.ts new file mode 100644 index 00000000..bc9f4381 --- /dev/null +++ b/packages/dev/threejs/lib/api/bitbybit/threejs/camera.ts @@ -0,0 +1,13 @@ +import { Context } from "../../context"; +import { ThreeJSOrbitCamera } from "./orbit-camera"; + +export class ThreeJSCamera { + + public orbitCamera: ThreeJSOrbitCamera; + + constructor( + private readonly context: Context, + ) { + this.orbitCamera = new ThreeJSOrbitCamera(this.context); + } +} diff --git a/packages/dev/threejs/lib/api/bitbybit/threejs/index.ts b/packages/dev/threejs/lib/api/bitbybit/threejs/index.ts new file mode 100644 index 00000000..c07f33a3 --- /dev/null +++ b/packages/dev/threejs/lib/api/bitbybit/threejs/index.ts @@ -0,0 +1,2 @@ +export * from "./camera"; +export * from "./orbit-camera"; diff --git a/packages/dev/threejs/lib/api/bitbybit/threejs/orbit-camera.test.ts b/packages/dev/threejs/lib/api/bitbybit/threejs/orbit-camera.test.ts new file mode 100644 index 00000000..1b0aee30 --- /dev/null +++ b/packages/dev/threejs/lib/api/bitbybit/threejs/orbit-camera.test.ts @@ -0,0 +1,517 @@ +/* eslint-disable @typescript-eslint/no-unused-vars */ +import { ThreeJSOrbitCamera, OrbitCameraController, OrbitCameraInstance } from "./orbit-camera"; +import { Context } from "../../context"; +import * as Inputs from "../../inputs/inputs"; +import * as THREEJS from "three"; +import { createMockContext, createSimpleMockContext, createMockDOMElement } from "../../__mocks__/test-helpers"; + +describe("ThreeJSOrbitCamera unit tests", () => { + let orbitCamera: ThreeJSOrbitCamera; + let mockContext: Context; + let mockDomElement: HTMLElement; + + beforeEach(() => { + mockContext = createMockContext(); + orbitCamera = new ThreeJSOrbitCamera(mockContext); + + // Create mock DOM element from shared test helpers + mockDomElement = createMockDOMElement(); + }); + + afterEach(() => { + jest.clearAllMocks(); + }); + + describe("Constructor initialization", () => { + it("should create a ThreeJSOrbitCamera instance", () => { + expect(orbitCamera).toBeInstanceOf(ThreeJSOrbitCamera); + }); + }); + + describe("create method", () => { + const createDefaultInputs = (domElement?: HTMLElement): Inputs.ThreeJSCamera.OrbitCameraDto => ({ + autoRender: true, + distanceMax: 1000, + distanceMin: 0.1, + pitchAngleMax: 90, + pitchAngleMin: -90, + inertiaFactor: 0.1, + enableDamping: true, + dampingFactor: 0.1, + focusObject: undefined, + frameOnStart: true, + pivotPoint: [0, 0, 0], + distance: 10, + pitch: 0, + yaw: 0, + orbitSensitivity: 0.3, + distanceSensitivity: 0.15, + panSensitivity: 1, + domElement: domElement, + }); + + it("should throw error if scene is not initialized", () => { + const contextWithoutScene = createSimpleMockContext(); + const cameraWithoutScene = new ThreeJSOrbitCamera(contextWithoutScene); + expect(() => cameraWithoutScene.create(createDefaultInputs())).toThrow(); + }); + + it("should create orbit camera controller with default settings", () => { + const controller = orbitCamera.create(createDefaultInputs(mockDomElement)); + + expect(controller.camera).toBeInstanceOf(THREEJS.PerspectiveCamera); + expect(typeof controller.orbitCamera.distance).toBe("number"); + expect(typeof controller.mouseInput.destroy).toBe("function"); + expect(typeof controller.touchInput.destroy).toBe("function"); + expect(typeof controller.keyboardInput.destroy).toBe("function"); + expect(typeof controller.update).toBe("function"); + expect(typeof controller.destroy).toBe("function"); + }); + + it("should set camera properties correctly", () => { + const controller = orbitCamera.create(createDefaultInputs(mockDomElement)); + + expect(controller.orbitCamera.autoRender).toBe(true); + expect(controller.orbitCamera.distanceMax).toBe(1000); + expect(controller.orbitCamera.distanceMin).toBe(0.1); + expect(controller.orbitCamera.pitchAngleMax).toBe(90); + expect(controller.orbitCamera.pitchAngleMin).toBe(-90); + expect(controller.orbitCamera.inertiaFactor).toBe(0.1); + expect(controller.orbitCamera.distance).toBe(10); + expect(controller.orbitCamera.pitch).toBe(0); + expect(controller.orbitCamera.yaw).toBe(0); + }); + + it("should set pivot point correctly", () => { + const inputs = { ...createDefaultInputs(mockDomElement), pivotPoint: [1, 2, 3] as Inputs.Base.Point3 }; + const controller = orbitCamera.create(inputs); + + const pivot = controller.orbitCamera.pivotPoint; + expect(pivot.x).toBe(1); + expect(pivot.y).toBe(2); + expect(pivot.z).toBe(3); + }); + + it("should create orbit camera with custom parameters", () => { + const customInputs: Inputs.ThreeJSCamera.OrbitCameraDto = { + ...createDefaultInputs(mockDomElement), + distance: 20, + pitch: 45, + yaw: 90, + distanceMax: 500, + distanceMin: 1, + pitchAngleMax: 80, + pitchAngleMin: -80, + inertiaFactor: 0.5, + }; + + const controller = orbitCamera.create(customInputs); + + expect(controller.orbitCamera.distance).toBe(20); + expect(controller.orbitCamera.pitch).toBe(45); + expect(controller.orbitCamera.yaw).toBe(90); + expect(controller.orbitCamera.distanceMax).toBe(500); + expect(controller.orbitCamera.distanceMin).toBe(1); + expect(controller.orbitCamera.pitchAngleMax).toBe(80); + expect(controller.orbitCamera.pitchAngleMin).toBe(-80); + expect(controller.orbitCamera.inertiaFactor).toBe(0.5); + }); + + it("should setup mouse input handlers with destroy method", () => { + const controller = orbitCamera.create(createDefaultInputs(mockDomElement)); + expect(typeof controller.mouseInput.destroy).toBe("function"); + }); + + it("should setup touch input handlers with destroy method", () => { + const controller = orbitCamera.create(createDefaultInputs(mockDomElement)); + expect(typeof controller.touchInput.destroy).toBe("function"); + }); + + it("should setup keyboard input handlers with destroy method", () => { + const controller = orbitCamera.create(createDefaultInputs(mockDomElement)); + expect(typeof controller.keyboardInput.destroy).toBe("function"); + }); + + it("should create camera with correct default properties", () => { + const controller = orbitCamera.create(createDefaultInputs(mockDomElement)); + + expect(controller.camera.fov).toBe(50); + expect(controller.camera.near).toBe(0.1); + expect(controller.camera.far).toBe(10000); + }); + + it("should destroy all input handlers on destroy call", () => { + const controller = orbitCamera.create(createDefaultInputs(mockDomElement)); + + // Verify input handlers exist with destroy methods before destruction + expect(typeof controller.mouseInput.destroy).toBe("function"); + expect(typeof controller.touchInput.destroy).toBe("function"); + expect(typeof controller.keyboardInput.destroy).toBe("function"); + + // Destroy should complete without error + controller.destroy(); + + // After destroy, the controller should still be a valid object + expect(controller.camera).toBeInstanceOf(THREEJS.PerspectiveCamera); + }); + }); + + describe("setPivotPoint method", () => { + it("should set pivot point correctly", () => { + const defaultInputs = { + autoRender: true, + distanceMax: 1000, + distanceMin: 0.1, + pitchAngleMax: 90, + pitchAngleMin: -90, + inertiaFactor: 0.1, + enableDamping: true, + dampingFactor: 0.1, + focusObject: undefined, + frameOnStart: true, + pivotPoint: [0, 0, 0] as Inputs.Base.Point3, + distance: 10, + pitch: 0, + yaw: 0, + orbitSensitivity: 0.3, + distanceSensitivity: 0.15, + panSensitivity: 1, + domElement: mockDomElement, + }; + + const controller = orbitCamera.create(defaultInputs); + + orbitCamera.setPivotPoint({ + orbitCamera: controller, + pivotPoint: [5, 10, 15], + }); + + const pivot = controller.orbitCamera.pivotPoint; + expect(pivot.x).toBe(5); + expect(pivot.y).toBe(10); + expect(pivot.z).toBe(15); + }); + }); + + describe("getPivotPoint method", () => { + it("should return pivot point correctly", () => { + const defaultInputs = { + autoRender: true, + distanceMax: 1000, + distanceMin: 0.1, + pitchAngleMax: 90, + pitchAngleMin: -90, + inertiaFactor: 0.1, + enableDamping: true, + dampingFactor: 0.1, + focusObject: undefined, + frameOnStart: true, + pivotPoint: [3, 6, 9] as Inputs.Base.Point3, + distance: 10, + pitch: 0, + yaw: 0, + orbitSensitivity: 0.3, + distanceSensitivity: 0.15, + panSensitivity: 1, + domElement: mockDomElement, + }; + + const controller = orbitCamera.create(defaultInputs); + + const pivot = orbitCamera.getPivotPoint({ + orbitCamera: controller, + pivotPoint: [0, 0, 0], // This won't be used for getting + }); + + expect(pivot).toEqual([3, 6, 9]); + }); + }); + + describe("resetCamera method", () => { + it("should reset camera to specified values", () => { + const defaultInputs = { + autoRender: true, + distanceMax: 1000, + distanceMin: 0.1, + pitchAngleMax: 90, + pitchAngleMin: -90, + inertiaFactor: 0.1, + enableDamping: true, + dampingFactor: 0.1, + focusObject: undefined, + frameOnStart: true, + pivotPoint: [0, 0, 0] as Inputs.Base.Point3, + distance: 10, + pitch: 0, + yaw: 0, + orbitSensitivity: 0.3, + distanceSensitivity: 0.15, + panSensitivity: 1, + domElement: mockDomElement, + }; + + const controller = orbitCamera.create(defaultInputs); + + orbitCamera.resetCamera({ + orbitCamera: controller, + yaw: 45, + pitch: 30, + distance: 50, + }); + + expect(controller.orbitCamera.yaw).toBe(45); + expect(controller.orbitCamera.pitch).toBe(30); + expect(controller.orbitCamera.distance).toBe(50); + }); + }); + + describe("Distance and pitch getters", () => { + let controller: OrbitCameraController; + + beforeEach(() => { + const defaultInputs = { + autoRender: true, + distanceMax: 1000, + distanceMin: 0.1, + pitchAngleMax: 90, + pitchAngleMin: -90, + inertiaFactor: 0.1, + enableDamping: true, + dampingFactor: 0.1, + focusObject: undefined, + frameOnStart: true, + pivotPoint: [0, 0, 0] as Inputs.Base.Point3, + distance: 25, + pitch: 45, + yaw: 60, + orbitSensitivity: 0.3, + distanceSensitivity: 0.15, + panSensitivity: 1, + domElement: mockDomElement, + }; + controller = orbitCamera.create(defaultInputs); + }); + + it("should get distance correctly", () => { + const distance = orbitCamera.getDistance({ orbitCamera: controller }); + expect(distance).toBe(25); + }); + + it("should get yaw correctly", () => { + const yaw = orbitCamera.getYaw({ orbitCamera: controller }); + expect(yaw).toBe(60); + }); + + it("should get pitch correctly", () => { + const pitch = orbitCamera.getPitch({ orbitCamera: controller }); + expect(pitch).toBe(45); + }); + }); + + describe("Distance and pitch limits", () => { + let controller: OrbitCameraController; + + beforeEach(() => { + const defaultInputs = { + autoRender: true, + distanceMax: 1000, + distanceMin: 0.1, + pitchAngleMax: 90, + pitchAngleMin: -90, + inertiaFactor: 0.1, + enableDamping: true, + dampingFactor: 0.1, + focusObject: undefined, + frameOnStart: true, + pivotPoint: [0, 0, 0] as Inputs.Base.Point3, + distance: 10, + pitch: 0, + yaw: 0, + orbitSensitivity: 0.3, + distanceSensitivity: 0.15, + panSensitivity: 1, + domElement: mockDomElement, + }; + controller = orbitCamera.create(defaultInputs); + }); + + it("should set distance limits", () => { + orbitCamera.setDistanceLimits({ + orbitCamera: controller, + min: 5, + max: 100, + }); + + expect(controller.orbitCamera.distanceMin).toBe(5); + expect(controller.orbitCamera.distanceMax).toBe(100); + }); + + it("should set pitch limits", () => { + orbitCamera.setPitchLimits({ + orbitCamera: controller, + min: -45, + max: 45, + }); + + expect(controller.orbitCamera.pitchAngleMin).toBe(-45); + expect(controller.orbitCamera.pitchAngleMax).toBe(45); + }); + + it("should clamp distance to min/max bounds", () => { + orbitCamera.setDistanceLimits({ + orbitCamera: controller, + min: 5, + max: 100, + }); + + // Try to set distance below min + controller.orbitCamera.distance = 1; + expect(controller.orbitCamera.distance).toBe(5); + + // Try to set distance above max + controller.orbitCamera.distance = 200; + expect(controller.orbitCamera.distance).toBe(100); + }); + + it("should clamp pitch to min/max bounds", () => { + orbitCamera.setPitchLimits({ + orbitCamera: controller, + min: -45, + max: 45, + }); + + // Try to set pitch below min + controller.orbitCamera.pitch = -60; + expect(controller.orbitCamera.pitch).toBe(-45); + + // Try to set pitch above max + controller.orbitCamera.pitch = 60; + expect(controller.orbitCamera.pitch).toBe(45); + }); + }); + + describe("Update method", () => { + it("should update camera position on update call", () => { + const defaultInputs = { + autoRender: true, + distanceMax: 1000, + distanceMin: 0.1, + pitchAngleMax: 90, + pitchAngleMin: -90, + inertiaFactor: 0.1, + enableDamping: true, + dampingFactor: 0.1, + focusObject: undefined, + frameOnStart: true, + pivotPoint: [0, 0, 0] as Inputs.Base.Point3, + distance: 10, + pitch: 0, + yaw: 0, + orbitSensitivity: 0.3, + distanceSensitivity: 0.15, + panSensitivity: 1, + domElement: mockDomElement, + }; + + const controller = orbitCamera.create(defaultInputs); + const initialPosition = controller.camera.position.clone(); + + // Change target values + controller.orbitCamera.yaw = 45; + controller.orbitCamera.pitch = 30; + + // Update with dt + controller.update(0.016); + + // Camera position should have changed + expect(controller.camera.position.equals(initialPosition)).toBe(false); + }); + + it("should interpolate values with damping", () => { + const defaultInputs = { + autoRender: true, + distanceMax: 1000, + distanceMin: 0.1, + pitchAngleMax: 90, + pitchAngleMin: -90, + inertiaFactor: 0.1, + enableDamping: true, + dampingFactor: 0.1, + focusObject: undefined, + frameOnStart: true, + pivotPoint: [0, 0, 0] as Inputs.Base.Point3, + distance: 10, + pitch: 0, + yaw: 0, + orbitSensitivity: 0.3, + distanceSensitivity: 0.15, + panSensitivity: 1, + domElement: mockDomElement, + }; + + const controller = orbitCamera.create(defaultInputs); + + // Set target distance + controller.orbitCamera.distance = 50; + + // Update partially + controller.update(0.016); + + // Should not have reached target yet due to damping + const currentDistance = (controller.orbitCamera as any)._distance || + controller.camera.position.length(); + + // The distance should be somewhere between initial and target + expect(currentDistance).not.toBe(50); + }); + }); + + describe("Focus on object", () => { + it("should focus on object correctly", () => { + const defaultInputs = { + autoRender: true, + distanceMax: 1000, + distanceMin: 0.1, + pitchAngleMax: 90, + pitchAngleMin: -90, + inertiaFactor: 0.1, + enableDamping: true, + dampingFactor: 0.1, + focusObject: undefined, + frameOnStart: true, + pivotPoint: [0, 0, 0] as Inputs.Base.Point3, + distance: 10, + pitch: 0, + yaw: 0, + orbitSensitivity: 0.3, + distanceSensitivity: 0.15, + panSensitivity: 1, + domElement: mockDomElement, + }; + + const controller = orbitCamera.create(defaultInputs); + + // Create a test mesh + const geometry = new THREEJS.BoxGeometry(2, 2, 2); + const material = new THREEJS.MeshBasicMaterial(); + const mesh = new THREEJS.Mesh(geometry, material); + mesh.position.set(5, 5, 5); + mockContext.scene.add(mesh); + + // Focus on the mesh + orbitCamera.focusOnObject({ + orbitCamera: controller, + object: mesh, + padding: 1.5, + }); + + // Pivot should be at mesh center + const pivot = controller.orbitCamera.pivotPoint; + expect(pivot.x).toBeCloseTo(5, 1); + expect(pivot.y).toBeCloseTo(5, 1); + expect(pivot.z).toBeCloseTo(5, 1); + }); + }); +}); + +// Note: DTO constructor tests are in threejs-camera-inputs.test.ts to avoid duplication diff --git a/packages/dev/threejs/lib/api/bitbybit/threejs/orbit-camera.ts b/packages/dev/threejs/lib/api/bitbybit/threejs/orbit-camera.ts new file mode 100644 index 00000000..86d7182e --- /dev/null +++ b/packages/dev/threejs/lib/api/bitbybit/threejs/orbit-camera.ts @@ -0,0 +1,693 @@ +import * as THREEJS from "three"; +import { Context } from "../../context"; +import * as Inputs from "../../inputs/inputs"; +import { OrbitCameraInstance, InputHandler, OrbitCameraController } from "../../inputs/threejs-camera-inputs"; + +// Re-export for backwards compatibility +export { OrbitCameraInstance, InputHandler, OrbitCameraController }; + +const DEG_TO_RAD = Math.PI / 180; +const RAD_TO_DEG = 180 / Math.PI; + +interface OrbitCameraState { + _modelsAabb: THREEJS.Box3; + _pivotPoint: THREEJS.Vector3; + _targetPivotPoint: THREEJS.Vector3; + _lastFramePivotPoint: THREEJS.Vector3; + _yaw: number; + _pitch: number; + _distance: number; + _targetYaw: number; + _targetPitch: number; + _targetDistance: number; + _autoRenderDefault: boolean; +} + +interface OrbitCameraConfig { + autoRender: boolean; + distanceMax: number; + distanceMin: number; + pitchAngleMax: number; + pitchAngleMin: number; + inertiaFactor: number; + enableDamping: boolean; + dampingFactor: number; + focusObject: THREEJS.Object3D | null; + frameOnStart: boolean; +} + +export class ThreeJSOrbitCamera { + + constructor( + private readonly context: Context, + ) { } + + /** + * Creates an orbit camera controller that allows rotating around a pivot point. This camera is suitable for 3D object inspection and scene navigation. + * @param inputs Describes the orbit camera configuration + * @returns Orbit camera controller instance with mouse, touch, and keyboard input handlers + * @group create + * @shortname new orbit camera + */ + create(inputs: Inputs.ThreeJSCamera.OrbitCameraDto): OrbitCameraController { + if (!this.context.scene) { + throw new Error("Scene not initialized. Ensure context.scene is set first."); + } + + // Get aspect ratio - fallback to 1 if window is not available + const aspectRatio = typeof window !== "undefined" + ? window.innerWidth / window.innerHeight + : 1; + + // Create camera + const camera = new THREEJS.PerspectiveCamera( + 50, + aspectRatio, + 0.1, + 10000 + ); + + // Create orbit camera with configuration + const orbitCamera = this.createOrbitCameraInstance(camera, { + autoRender: inputs.autoRender, + distanceMax: inputs.distanceMax, + distanceMin: inputs.distanceMin, + pitchAngleMax: inputs.pitchAngleMax, + pitchAngleMin: inputs.pitchAngleMin, + inertiaFactor: inputs.inertiaFactor, + enableDamping: inputs.enableDamping, + dampingFactor: inputs.dampingFactor, + focusObject: inputs.focusObject || null, + frameOnStart: inputs.frameOnStart + }); + + // Set initial position + const pivotVec = new THREEJS.Vector3(inputs.pivotPoint[0], inputs.pivotPoint[1], inputs.pivotPoint[2]); + orbitCamera.pivotPoint = pivotVec; + orbitCamera.distance = inputs.distance; + orbitCamera.pitch = inputs.pitch; + orbitCamera.yaw = inputs.yaw; + + // Initialize the current pivot point to match the target (no inertia on start) + orbitCamera.initializePivotPoint(pivotVec); + + // Get DOM element for event listeners + const domElement = inputs.domElement || document.body; + + // Setup mouse input + const mouseInput = this.createMouseInput(camera, orbitCamera, domElement, { + orbitSensitivity: inputs.orbitSensitivity, + distanceSensitivity: inputs.distanceSensitivity, + panSensitivity: inputs.panSensitivity + }); + + // Setup touch input + const touchInput = this.createTouchInput(camera, orbitCamera, domElement, { + orbitSensitivity: inputs.orbitSensitivity, + distanceSensitivity: inputs.distanceSensitivity, + panSensitivity: inputs.panSensitivity + }); + + // Setup keyboard input for panning with arrow keys + const keyboardInput = this.createKeyboardInput(orbitCamera); + + // Update function for animation loop + const updateFn = (dt: number) => { + orbitCamera.update(dt); + }; + + // Focus on object if provided + if (inputs.focusObject && inputs.frameOnStart) { + orbitCamera.focus(inputs.focusObject); + } + + return { + orbitCamera, + camera, + mouseInput, + touchInput, + keyboardInput, + update: updateFn, + destroy: () => { + mouseInput?.destroy(); + touchInput?.destroy(); + keyboardInput?.destroy(); + } + }; + } + + /** + * Sets the pivot point of the orbit camera + * @param inputs Orbit camera and pivot point + * @group adjust + * @shortname set pivot point + */ + setPivotPoint(inputs: Inputs.ThreeJSCamera.PivotPointDto): void { + const pivotVec = new THREEJS.Vector3(inputs.pivotPoint[0], inputs.pivotPoint[1], inputs.pivotPoint[2]); + inputs.orbitCamera.orbitCamera.pivotPoint = pivotVec; + } + + /** + * Gets the pivot point of the orbit camera + * @param inputs Orbit camera instance + * @returns Pivot point as [x, y, z] + * @group get + * @shortname get pivot point + */ + getPivotPoint(inputs: Inputs.ThreeJSCamera.PivotPointDto): Inputs.Base.Point3 { + const pivot = inputs.orbitCamera.orbitCamera.pivotPoint; + return [pivot.x, pivot.y, pivot.z]; + } + + /** + * Focus the camera on an object, adjusting distance to frame it properly + * @param inputs Orbit camera and object to focus on + * @group adjust + * @shortname focus on object + */ + focusOnObject(inputs: Inputs.ThreeJSCamera.FocusObjectDto): void { + inputs.orbitCamera.orbitCamera.focus(inputs.object, inputs.padding); + } + + /** + * Reset camera to specific yaw, pitch and distance + * @param inputs Orbit camera and reset parameters + * @group adjust + * @shortname reset camera + */ + resetCamera(inputs: Inputs.ThreeJSCamera.ResetCameraDto): void { + inputs.orbitCamera.orbitCamera.reset(inputs.yaw, inputs.pitch, inputs.distance); + } + + /** + * Gets the current distance from pivot point + * @param inputs Orbit camera controller + * @returns Current distance + * @group get + * @shortname get distance + */ + getDistance(inputs: Inputs.ThreeJSCamera.OrbitCameraControllerDto): number { + return inputs.orbitCamera.orbitCamera.distance; + } + + /** + * Sets the distance from pivot point + * @param inputs Orbit camera controller and distance + * @group adjust + * @shortname set distance + */ + setDistance(inputs: Inputs.ThreeJSCamera.ResetCameraDto): void { + inputs.orbitCamera.orbitCamera.distance = inputs.distance; + } + + /** + * Gets the current yaw angle in degrees + * @param inputs Orbit camera controller + * @returns Current yaw angle + * @group get + * @shortname get yaw + */ + getYaw(inputs: Inputs.ThreeJSCamera.OrbitCameraControllerDto): number { + return inputs.orbitCamera.orbitCamera.yaw; + } + + /** + * Gets the current pitch angle in degrees + * @param inputs Orbit camera controller + * @returns Current pitch angle + * @group get + * @shortname get pitch + */ + getPitch(inputs: Inputs.ThreeJSCamera.OrbitCameraControllerDto): number { + return inputs.orbitCamera.orbitCamera.pitch; + } + + /** + * Sets distance limits for the orbit camera + * @param inputs Orbit camera and min/max distance + * @group adjust + * @shortname set distance limits + */ + setDistanceLimits(inputs: Inputs.ThreeJSCamera.SetDistanceLimitsDto): void { + inputs.orbitCamera.orbitCamera.distanceMin = inputs.min; + inputs.orbitCamera.orbitCamera.distanceMax = inputs.max; + } + + /** + * Sets pitch angle limits for the orbit camera + * @param inputs Orbit camera and min/max pitch angles + * @group adjust + * @shortname set pitch limits + */ + setPitchLimits(inputs: Inputs.ThreeJSCamera.SetPitchLimitsDto): void { + inputs.orbitCamera.orbitCamera.pitchAngleMin = inputs.min; + inputs.orbitCamera.orbitCamera.pitchAngleMax = inputs.max; + } + + private createOrbitCameraInstance(camera: THREEJS.PerspectiveCamera, config: OrbitCameraConfig): OrbitCameraInstance { + const state: OrbitCameraState = { + _modelsAabb: new THREEJS.Box3(), + _pivotPoint: new THREEJS.Vector3(), + _targetPivotPoint: new THREEJS.Vector3(), + _lastFramePivotPoint: new THREEJS.Vector3(), + _yaw: 0, + _pitch: 0, + _distance: 0, + _targetYaw: 0, + _targetPitch: 0, + _targetDistance: 0, + _autoRenderDefault: true + }; + + const distanceBetween = new THREEJS.Vector3(); + + const updatePosition = (): void => { + // Convert spherical coordinates to cartesian + const phi = (90 - state._pitch) * DEG_TO_RAD; + const theta = state._yaw * DEG_TO_RAD; + + const sinPhi = Math.sin(phi); + const cosPhi = Math.cos(phi); + const sinTheta = Math.sin(theta); + const cosTheta = Math.cos(theta); + + const x = state._distance * sinPhi * sinTheta; + const y = state._distance * cosPhi; + const z = state._distance * sinPhi * cosTheta; + + camera.position.set( + state._pivotPoint.x + x, + state._pivotPoint.y + y, + state._pivotPoint.z + z + ); + + camera.lookAt(state._pivotPoint); + }; + + const removeInertia = (): void => { + state._yaw = state._targetYaw; + state._pitch = state._targetPitch; + state._distance = state._targetDistance; + state._pivotPoint.copy(state._targetPivotPoint); + }; + + const buildAabb = (object: THREEJS.Object3D): void => { + state._modelsAabb.setFromObject(object); + }; + + const lerp = (start: number, end: number, t: number): number => { + return start + (end - start) * t; + }; + + return { + autoRender: config.autoRender, + distanceMax: config.distanceMax, + distanceMin: config.distanceMin, + pitchAngleMax: config.pitchAngleMax, + pitchAngleMin: config.pitchAngleMin, + inertiaFactor: config.inertiaFactor, + enableDamping: config.enableDamping, + dampingFactor: config.dampingFactor, + focusObject: config.focusObject, + frameOnStart: config.frameOnStart, + + get distance(): number { + return state._targetDistance; + }, + set distance(value: number) { + // Clamp distance using current instance limits + state._targetDistance = Math.max(this.distanceMin, Math.min(this.distanceMax, value)); + }, + + get pitch(): number { + return state._targetPitch; + }, + set pitch(value: number) { + // Clamp pitch using current instance limits, avoiding gimbal lock + const safeMin = Math.max(this.pitchAngleMin, -89.9); + const safeMax = Math.min(this.pitchAngleMax, 89.9); + state._targetPitch = Math.max(safeMin, Math.min(safeMax, value)); + }, + + get yaw(): number { + return state._targetYaw; + }, + set yaw(value: number) { + state._targetYaw = value; + // Handle wrap-around for smooth rotation + const diff = state._targetYaw - state._yaw; + const remainder = diff % 360; + if (remainder > 180) { + state._yaw += 360; + } else if (remainder < -180) { + state._yaw -= 360; + } + }, + + get pivotPoint(): THREEJS.Vector3 { + return state._targetPivotPoint; + }, + set pivotPoint(value: THREEJS.Vector3) { + state._targetPivotPoint.copy(value); + }, + + focus(focusObject: THREEJS.Object3D, padding = 1.5): void { + buildAabb(focusObject); + + if (state._modelsAabb.isEmpty()) { + return; + } + + const center = new THREEJS.Vector3(); + state._modelsAabb.getCenter(center); + + const size = new THREEJS.Vector3(); + state._modelsAabb.getSize(size); + + const maxDim = Math.max(size.x, size.y, size.z); + const fov = camera.fov * DEG_TO_RAD; + let distance = maxDim / (2 * Math.tan(fov / 2)); + distance *= padding; + + this.distance = distance; + state._targetPivotPoint.copy(center); + removeInertia(); + updatePosition(); + }, + + resetAndLookAtPoint(resetPoint: THREEJS.Vector3, lookAtPoint: THREEJS.Vector3): void { + state._targetPivotPoint.copy(lookAtPoint); + camera.position.copy(resetPoint); + camera.lookAt(lookAtPoint); + + distanceBetween.subVectors(lookAtPoint, resetPoint); + this.distance = distanceBetween.length(); + + // Calculate yaw and pitch from camera orientation + const direction = new THREEJS.Vector3(); + direction.subVectors(resetPoint, lookAtPoint).normalize(); + + this.yaw = Math.atan2(direction.x, direction.z) * RAD_TO_DEG; + this.pitch = Math.asin(direction.y) * RAD_TO_DEG; + + removeInertia(); + updatePosition(); + }, + + resetAndLookAtObject(resetPoint: THREEJS.Vector3, object: THREEJS.Object3D): void { + buildAabb(object); + const center = new THREEJS.Vector3(); + state._modelsAabb.getCenter(center); + this.resetAndLookAtPoint(resetPoint, center); + }, + + reset(yaw: number, pitch: number, distance: number): void { + this.pitch = pitch; + this.yaw = yaw; + this.distance = distance; + removeInertia(); + updatePosition(); + }, + + update(dt: number): void { + const t = config.enableDamping + ? (config.dampingFactor === 0 ? 1 : Math.min(dt / (config.inertiaFactor || 0.1), 1)) + : 1; + + state._distance = lerp(state._distance, state._targetDistance, t); + state._yaw = lerp(state._yaw, state._targetYaw, t); + state._pitch = lerp(state._pitch, state._targetPitch, t); + state._pivotPoint.lerp(state._targetPivotPoint, t); + + updatePosition(); + }, + + initializePivotPoint(point: THREEJS.Vector3): void { + state._pivotPoint.copy(point); + } + }; + } + + private createMouseInput( + camera: THREEJS.PerspectiveCamera, + orbitCamera: OrbitCameraInstance, + domElement: HTMLElement, + options: { orbitSensitivity: number; distanceSensitivity: number; panSensitivity: number } + ): InputHandler | null { + let lookButtonDown = false; + let panButtonDown = false; + let lastMouseX = 0; + let lastMouseY = 0; + + const panVector = new THREEJS.Vector3(); + + const pan = (deltaX: number, deltaY: number): void => { + // Get camera's right and up vectors + const right = new THREEJS.Vector3(); + const up = new THREEJS.Vector3(); + camera.matrix.extractBasis(right, up, new THREEJS.Vector3()); + + // Calculate pan amount based on distance from pivot + const panScale = orbitCamera.distance * 0.001 * options.panSensitivity; + + panVector.set(0, 0, 0); + panVector.addScaledVector(right, -deltaX * panScale); + panVector.addScaledVector(up, deltaY * panScale); + + orbitCamera.pivotPoint.add(panVector); + }; + + const onMouseDown = (event: MouseEvent): void => { + event.preventDefault(); + switch (event.button) { + case 0: // Left button + lookButtonDown = true; + break; + case 1: // Middle button + case 2: // Right button + panButtonDown = true; + break; + } + lastMouseX = event.clientX; + lastMouseY = event.clientY; + }; + + const onMouseUp = (event: MouseEvent): void => { + switch (event.button) { + case 0: + lookButtonDown = false; + break; + case 1: + case 2: + panButtonDown = false; + break; + } + }; + + const onMouseMove = (event: MouseEvent): void => { + const deltaX = event.clientX - lastMouseX; + const deltaY = event.clientY - lastMouseY; + + if (lookButtonDown) { + orbitCamera.pitch += deltaY * options.orbitSensitivity; + orbitCamera.yaw -= deltaX * options.orbitSensitivity; + } else if (panButtonDown) { + pan(deltaX, deltaY); + } + + lastMouseX = event.clientX; + lastMouseY = event.clientY; + }; + + const onMouseWheel = (event: WheelEvent): void => { + event.preventDefault(); + const delta = event.deltaY > 0 ? 1 : -1; + orbitCamera.distance += delta * options.distanceSensitivity * orbitCamera.distance * 0.1; + }; + + const onMouseOut = (): void => { + lookButtonDown = false; + panButtonDown = false; + }; + + const onContextMenu = (event: Event): void => { + event.preventDefault(); + }; + + domElement.addEventListener("mousedown", onMouseDown); + domElement.addEventListener("mouseup", onMouseUp); + domElement.addEventListener("mousemove", onMouseMove); + domElement.addEventListener("wheel", onMouseWheel, { passive: false }); + domElement.addEventListener("mouseout", onMouseOut); + domElement.addEventListener("contextmenu", onContextMenu); + + return { + destroy: () => { + domElement.removeEventListener("mousedown", onMouseDown); + domElement.removeEventListener("mouseup", onMouseUp); + domElement.removeEventListener("mousemove", onMouseMove); + domElement.removeEventListener("wheel", onMouseWheel); + domElement.removeEventListener("mouseout", onMouseOut); + domElement.removeEventListener("contextmenu", onContextMenu); + } + }; + } + + private createTouchInput( + camera: THREEJS.PerspectiveCamera, + orbitCamera: OrbitCameraInstance, + domElement: HTMLElement, + options: { orbitSensitivity: number; distanceSensitivity: number; panSensitivity: number } + ): InputHandler | null { + let lastTouchX = 0; + let lastTouchY = 0; + let lastPinchDistance = 0; + let lastPinchMidX = 0; + let lastPinchMidY = 0; + + const panVector = new THREEJS.Vector3(); + + const getPinchDistance = (touch1: Touch, touch2: Touch): number => { + const dx = touch1.clientX - touch2.clientX; + const dy = touch1.clientY - touch2.clientY; + return Math.sqrt(dx * dx + dy * dy); + }; + + const getPinchMidpoint = (touch1: Touch, touch2: Touch): { x: number; y: number } => { + return { + x: (touch1.clientX + touch2.clientX) / 2, + y: (touch1.clientY + touch2.clientY) / 2 + }; + }; + + const pan = (deltaX: number, deltaY: number): void => { + const right = new THREEJS.Vector3(); + const up = new THREEJS.Vector3(); + camera.matrix.extractBasis(right, up, new THREEJS.Vector3()); + + const panScale = orbitCamera.distance * 0.002 * options.panSensitivity; + + panVector.set(0, 0, 0); + panVector.addScaledVector(right, -deltaX * panScale); + panVector.addScaledVector(up, deltaY * panScale); + + orbitCamera.pivotPoint.add(panVector); + }; + + const onTouchStart = (event: TouchEvent): void => { + event.preventDefault(); + const touches = event.touches; + + if (touches.length === 1) { + lastTouchX = touches[0].clientX; + lastTouchY = touches[0].clientY; + } else if (touches.length === 2) { + lastPinchDistance = getPinchDistance(touches[0], touches[1]); + const mid = getPinchMidpoint(touches[0], touches[1]); + lastPinchMidX = mid.x; + lastPinchMidY = mid.y; + } + }; + + const onTouchEnd = (event: TouchEvent): void => { + const touches = event.touches; + if (touches.length === 1) { + lastTouchX = touches[0].clientX; + lastTouchY = touches[0].clientY; + } else if (touches.length === 2) { + lastPinchDistance = getPinchDistance(touches[0], touches[1]); + const mid = getPinchMidpoint(touches[0], touches[1]); + lastPinchMidX = mid.x; + lastPinchMidY = mid.y; + } + }; + + const onTouchMove = (event: TouchEvent): void => { + event.preventDefault(); + const touches = event.touches; + + if (touches.length === 1) { + const deltaX = touches[0].clientX - lastTouchX; + const deltaY = touches[0].clientY - lastTouchY; + + orbitCamera.pitch += deltaY * options.orbitSensitivity; + orbitCamera.yaw -= deltaX * options.orbitSensitivity; + + lastTouchX = touches[0].clientX; + lastTouchY = touches[0].clientY; + } else if (touches.length === 2) { + // Pinch to zoom + const currentPinchDistance = getPinchDistance(touches[0], touches[1]); + const pinchDelta = currentPinchDistance - lastPinchDistance; + orbitCamera.distance -= pinchDelta * options.distanceSensitivity * 0.1 * (orbitCamera.distance * 0.1); + lastPinchDistance = currentPinchDistance; + + // Two-finger pan + const mid = getPinchMidpoint(touches[0], touches[1]); + const deltaX = mid.x - lastPinchMidX; + const deltaY = mid.y - lastPinchMidY; + pan(deltaX, deltaY); + lastPinchMidX = mid.x; + lastPinchMidY = mid.y; + } + }; + + domElement.addEventListener("touchstart", onTouchStart, { passive: false }); + domElement.addEventListener("touchend", onTouchEnd); + domElement.addEventListener("touchcancel", onTouchEnd); + domElement.addEventListener("touchmove", onTouchMove, { passive: false }); + + return { + destroy: () => { + domElement.removeEventListener("touchstart", onTouchStart); + domElement.removeEventListener("touchend", onTouchEnd); + domElement.removeEventListener("touchcancel", onTouchEnd); + domElement.removeEventListener("touchmove", onTouchMove); + } + }; + } + + private createKeyboardInput( + orbitCamera: OrbitCameraInstance + ): InputHandler | null { + const onKeyDown = (event: KeyboardEvent): void => { + // Only handle if the domElement or document has focus + switch (event.key) { + case "ArrowLeft": + orbitCamera.yaw -= 2; + break; + case "ArrowRight": + orbitCamera.yaw += 2; + break; + case "ArrowUp": + if (event.shiftKey) { + orbitCamera.distance *= 0.95; + } else { + orbitCamera.pitch += 2; + } + break; + case "ArrowDown": + if (event.shiftKey) { + orbitCamera.distance *= 1.05; + } else { + orbitCamera.pitch -= 2; + } + break; + } + }; + + // Use the global window object if available (browser environment) + const win = typeof window !== "undefined" ? window : null; + if (win) { + win.addEventListener("keydown", onKeyDown); + } + + return { + destroy: () => { + if (win) { + win.removeEventListener("keydown", onKeyDown); + } + } + }; + } +} diff --git a/packages/dev/threejs/lib/api/inputs/index.ts b/packages/dev/threejs/lib/api/inputs/index.ts index fc133166..a115bbbb 100644 --- a/packages/dev/threejs/lib/api/inputs/index.ts +++ b/packages/dev/threejs/lib/api/inputs/index.ts @@ -1,3 +1,4 @@ export * from "./draw-inputs"; export * from "./base-inputs"; +export * from "./threejs-camera-inputs"; export * from "@bitbybit-dev/core/lib/api/inputs/inputs"; \ No newline at end of file diff --git a/packages/dev/threejs/lib/api/inputs/inputs.ts b/packages/dev/threejs/lib/api/inputs/inputs.ts index 1edaa749..1e2f9c85 100644 --- a/packages/dev/threejs/lib/api/inputs/inputs.ts +++ b/packages/dev/threejs/lib/api/inputs/inputs.ts @@ -1,2 +1,3 @@ export * from "./draw-inputs"; +export * from "./threejs-camera-inputs"; export * from "@bitbybit-dev/core/lib/api/inputs"; diff --git a/packages/dev/threejs/lib/api/inputs/threejs-camera-inputs.test.ts b/packages/dev/threejs/lib/api/inputs/threejs-camera-inputs.test.ts new file mode 100644 index 00000000..199bb011 --- /dev/null +++ b/packages/dev/threejs/lib/api/inputs/threejs-camera-inputs.test.ts @@ -0,0 +1,248 @@ +import { ThreeJSCamera } from "./threejs-camera-inputs"; + +describe("ThreeJSCamera DTO unit tests", () => { + describe("OrbitCameraDto", () => { + it("should set properties from constructor parameters", () => { + // Arrange + const distance = 50; + const pitch = 60; + const yaw = 90; + const distanceMin = 1; + const distanceMax = 500; + const pitchAngleMin = -60; + const pitchAngleMax = 60; + const orbitSensitivity = 0.5; + const distanceSensitivity = 0.2; + const panSensitivity = 1.5; + const inertiaFactor = 0.3; + const autoRender = false; + const frameOnStart = false; + const enableDamping = true; + const dampingFactor = 0.15; + + // Act + const result = new ThreeJSCamera.OrbitCameraDto( + distance, + pitch, + yaw, + distanceMin, + distanceMax, + pitchAngleMin, + pitchAngleMax, + orbitSensitivity, + distanceSensitivity, + panSensitivity, + inertiaFactor, + autoRender, + frameOnStart, + enableDamping, + dampingFactor + ); + + // Assert + expect(result.distance).toBe(50); + expect(result.pitch).toBe(60); + expect(result.yaw).toBe(90); + expect(result.distanceMin).toBe(1); + expect(result.distanceMax).toBe(500); + expect(result.pitchAngleMin).toBe(-60); + expect(result.pitchAngleMax).toBe(60); + expect(result.orbitSensitivity).toBe(0.5); + expect(result.distanceSensitivity).toBe(0.2); + expect(result.panSensitivity).toBe(1.5); + expect(result.inertiaFactor).toBe(0.3); + expect(result.autoRender).toBe(false); + expect(result.frameOnStart).toBe(false); + expect(result.enableDamping).toBe(true); + expect(result.dampingFactor).toBe(0.15); + }); + + it("should have correct default values when no parameters are provided", () => { + // Arrange & Act + const result = new ThreeJSCamera.OrbitCameraDto(); + + // Assert + expect(result.pivotPoint).toEqual([0, 0, 0]); + expect(result.distance).toBe(20); + expect(result.pitch).toBe(30); + expect(result.yaw).toBe(45); + expect(result.distanceMin).toBe(0.1); + expect(result.distanceMax).toBe(1000); + expect(result.pitchAngleMin).toBe(-90); + expect(result.pitchAngleMax).toBe(90); + expect(result.orbitSensitivity).toBe(0.3); + expect(result.distanceSensitivity).toBe(0.15); + expect(result.panSensitivity).toBe(1); + expect(result.inertiaFactor).toBe(0.1); + expect(result.autoRender).toBe(true); + expect(result.frameOnStart).toBe(true); + expect(result.enableDamping).toBe(true); + expect(result.dampingFactor).toBe(0.1); + expect(result.focusObject).toBeUndefined(); + expect(result.domElement).toBeUndefined(); + }); + }); + + describe("CameraDto", () => { + it("should have correct default values when no parameters are provided", () => { + // Arrange & Act + const result = new ThreeJSCamera.CameraDto(); + + // Assert + expect(result.camera).toBeUndefined(); + }); + }); + + describe("PositionDto", () => { + it("should set properties from constructor parameters", () => { + // Arrange + const position = [1, 2, 3] as [number, number, number]; + + // Act + const result = new ThreeJSCamera.PositionDto(undefined, position); + + // Assert + expect(result.position).toEqual([1, 2, 3]); + }); + + it("should have correct default values when no parameters are provided", () => { + // Arrange & Act + const result = new ThreeJSCamera.PositionDto(); + + // Assert + expect(result.position).toEqual([0, 0, 0]); + }); + }); + + describe("PivotPointDto", () => { + it("should set properties from constructor parameters", () => { + // Arrange + const pivotPoint = [5, 10, 15] as [number, number, number]; + + // Act + const result = new ThreeJSCamera.PivotPointDto(undefined, pivotPoint); + + // Assert + expect(result.pivotPoint).toEqual([5, 10, 15]); + }); + + it("should have correct default values when no parameters are provided", () => { + // Arrange & Act + const result = new ThreeJSCamera.PivotPointDto(); + + // Assert + expect(result.pivotPoint).toEqual([0, 0, 0]); + }); + }); + + describe("FocusObjectDto", () => { + it("should set properties from constructor parameters", () => { + // Arrange + const padding = 2.5; + + // Act + const result = new ThreeJSCamera.FocusObjectDto(undefined, undefined, padding); + + // Assert + expect(result.padding).toBe(2.5); + }); + + it("should have correct default values when no parameters are provided", () => { + // Arrange & Act + const result = new ThreeJSCamera.FocusObjectDto(); + + // Assert + expect(result.padding).toBe(1.5); + expect(result.orbitCamera).toBeUndefined(); + expect(result.object).toBeUndefined(); + }); + }); + + describe("ResetCameraDto", () => { + it("should set properties from constructor parameters", () => { + // Arrange + const yaw = 90; + const pitch = 45; + const distance = 50; + + // Act + const result = new ThreeJSCamera.ResetCameraDto(undefined, yaw, pitch, distance); + + // Assert + expect(result.yaw).toBe(90); + expect(result.pitch).toBe(45); + expect(result.distance).toBe(50); + }); + + it("should have correct default values when no parameters are provided", () => { + // Arrange & Act + const result = new ThreeJSCamera.ResetCameraDto(); + + // Assert + expect(result.yaw).toBe(45); + expect(result.pitch).toBe(30); + expect(result.distance).toBe(20); + expect(result.orbitCamera).toBeUndefined(); + }); + }); + + describe("OrbitCameraControllerDto", () => { + it("should have correct default values when no parameters are provided", () => { + // Arrange & Act + const result = new ThreeJSCamera.OrbitCameraControllerDto(); + + // Assert + expect(result.orbitCamera).toBeUndefined(); + }); + }); + + describe("SetDistanceLimitsDto", () => { + it("should set properties from constructor parameters", () => { + // Arrange + const min = 1; + const max = 500; + + // Act + const result = new ThreeJSCamera.SetDistanceLimitsDto(undefined, min, max); + + // Assert + expect(result.min).toBe(1); + expect(result.max).toBe(500); + }); + + it("should have correct default values when no parameters are provided", () => { + // Arrange & Act + const result = new ThreeJSCamera.SetDistanceLimitsDto(); + + // Assert + expect(result.min).toBe(0.1); + expect(result.max).toBe(1000); + expect(result.orbitCamera).toBeUndefined(); + }); + }); + + describe("SetPitchLimitsDto", () => { + it("should set properties from constructor parameters", () => { + // Arrange + const min = -60; + const max = 60; + + // Act + const result = new ThreeJSCamera.SetPitchLimitsDto(undefined, min, max); + + // Assert + expect(result.min).toBe(-60); + expect(result.max).toBe(60); + }); + + it("should have correct default values when no parameters are provided", () => { + // Arrange & Act + const result = new ThreeJSCamera.SetPitchLimitsDto(); + + // Assert + expect(result.min).toBe(-90); + expect(result.max).toBe(90); + expect(result.orbitCamera).toBeUndefined(); + }); + }); +}); diff --git a/packages/dev/threejs/lib/api/inputs/threejs-camera-inputs.ts b/packages/dev/threejs/lib/api/inputs/threejs-camera-inputs.ts new file mode 100644 index 00000000..03b793e1 --- /dev/null +++ b/packages/dev/threejs/lib/api/inputs/threejs-camera-inputs.ts @@ -0,0 +1,394 @@ +/* eslint-disable @typescript-eslint/no-namespace */ + +import * as THREEJS from "three"; +import { Base } from "./base-inputs"; + +/** + * Interface for orbit camera internal state and methods. + * Exposed through OrbitCameraController.orbitCamera property. + */ +export interface OrbitCameraInstance { + autoRender: boolean; + distanceMax: number; + distanceMin: number; + pitchAngleMax: number; + pitchAngleMin: number; + inertiaFactor: number; + enableDamping: boolean; + dampingFactor: number; + focusObject: THREEJS.Object3D | null; + frameOnStart: boolean; + distance: number; + pitch: number; + yaw: number; + pivotPoint: THREEJS.Vector3; + focus(focusObject: THREEJS.Object3D, padding?: number): void; + resetAndLookAtPoint(resetPoint: THREEJS.Vector3, lookAtPoint: THREEJS.Vector3): void; + resetAndLookAtObject(resetPoint: THREEJS.Vector3, object: THREEJS.Object3D): void; + reset(yaw: number, pitch: number, distance: number): void; + update(dt: number): void; + initializePivotPoint(point: THREEJS.Vector3): void; +} + +/** + * Interface for input handlers (mouse, touch, keyboard). + */ +export interface InputHandler { + destroy(): void; +} + +/** + * Orbit camera controller returned by create method. + * Contains the camera, orbit controls, and input handlers. + */ +export interface OrbitCameraController { + orbitCamera: OrbitCameraInstance; + camera: THREEJS.PerspectiveCamera; + mouseInput: InputHandler | null; + touchInput: InputHandler | null; + keyboardInput: InputHandler | null; + update: (dt: number) => void; + destroy: () => void; +} + +export namespace ThreeJSCamera { + export class OrbitCameraDto { + constructor( + distance?: number, + pitch?: number, + yaw?: number, + distanceMin?: number, + distanceMax?: number, + pitchAngleMin?: number, + pitchAngleMax?: number, + orbitSensitivity?: number, + distanceSensitivity?: number, + panSensitivity?: number, + inertiaFactor?: number, + autoRender?: boolean, + frameOnStart?: boolean, + enableDamping?: boolean, + dampingFactor?: number + ) { + if (distance !== undefined) { this.distance = distance; } + if (pitch !== undefined) { this.pitch = pitch; } + if (yaw !== undefined) { this.yaw = yaw; } + if (distanceMin !== undefined) { this.distanceMin = distanceMin; } + if (distanceMax !== undefined) { this.distanceMax = distanceMax; } + if (pitchAngleMin !== undefined) { this.pitchAngleMin = pitchAngleMin; } + if (pitchAngleMax !== undefined) { this.pitchAngleMax = pitchAngleMax; } + if (orbitSensitivity !== undefined) { this.orbitSensitivity = orbitSensitivity; } + if (distanceSensitivity !== undefined) { this.distanceSensitivity = distanceSensitivity; } + if (panSensitivity !== undefined) { this.panSensitivity = panSensitivity; } + if (inertiaFactor !== undefined) { this.inertiaFactor = inertiaFactor; } + if (autoRender !== undefined) { this.autoRender = autoRender; } + if (frameOnStart !== undefined) { this.frameOnStart = frameOnStart; } + if (enableDamping !== undefined) { this.enableDamping = enableDamping; } + if (dampingFactor !== undefined) { this.dampingFactor = dampingFactor; } + } + /** + * Pivot point of the orbit camera. Camera will look at and rotate around this point. + * @default [0, 0, 0] + */ + pivotPoint: Base.Point3 = [0, 0, 0]; + /** + * Defines the camera distance from its pivot point. This distance will be used to orbit the camera around the pivot. + * @default 20 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + distance = 20; + /** + * Defines the camera pitch angle (rotation along the horizontal axis) in degrees. 0 is horizontal, positive is looking up, negative is looking down. + * @default 30 + * @minimum -90 + * @maximum 90 + * @step 1 + */ + pitch = 30; + /** + * Defines the camera yaw angle (rotation along the vertical axis) in degrees. + * @default 45 + * @minimum -360 + * @maximum 360 + * @step 1 + */ + yaw = 45; + /** + * Minimum distance - how close can the camera be to the pivot point + * @default 0.1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + distanceMin = 0.1; + /** + * Maximum distance - how far can the camera be from the pivot point + * @default 1000 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + distanceMax = 1000; + /** + * Minimum pitch angle in degrees + * @default -90 + * @minimum -90 + * @maximum 90 + * @step 1 + */ + pitchAngleMin = -90; + /** + * Maximum pitch angle in degrees + * @default 90 + * @minimum -90 + * @maximum 90 + * @step 1 + */ + pitchAngleMax = 90; + /** + * Mouse orbit sensitivity (how much the camera rotates with mouse movement) + * @default 0.3 + * @minimum 0 + * @maximum 10 + * @step 0.1 + */ + orbitSensitivity = 0.3; + /** + * Mouse zoom sensitivity (how much the camera zooms with mouse wheel) + * @default 0.15 + * @minimum 0 + * @maximum 10 + * @step 0.01 + */ + distanceSensitivity = 0.15; + /** + * Pan sensitivity (how fast the camera pans with mouse/touch) + * @default 1 + * @minimum 0 + * @maximum 10 + * @step 0.1 + */ + panSensitivity = 1; + /** + * Inertia factor for smooth camera movement (0 = no inertia, higher values = more inertia/smoother movement) + * @default 0.1 + * @minimum 0 + * @maximum 1 + * @step 0.05 + */ + inertiaFactor = 0.1; + /** + * Whether the camera should trigger automatic rendering on changes + * @default true + */ + autoRender = true; + /** + * Whether to frame the focus object on start + * @default true + */ + frameOnStart = true; + /** + * Enable damping (smooth camera transitions) + * @default true + */ + enableDamping = true; + /** + * Damping factor for smooth transitions (lower = smoother but slower) + * @default 0.1 + * @minimum 0.01 + * @maximum 1 + * @step 0.01 + */ + dampingFactor = 0.1; + /** + * Optional focus object to frame the camera on. If provided, camera will adjust to view this object. + * @optional true + */ + focusObject?: THREEJS.Object3D; + /** + * Container element to attach event listeners to. If not provided, uses the renderer's DOM element. + * @optional true + */ + domElement?: HTMLElement; + } + + export class CameraDto { + constructor(camera?: THREEJS.PerspectiveCamera | THREEJS.OrthographicCamera) { + if (camera !== undefined) { this.camera = camera; } + } + /** + * ThreeJS camera + * @default undefined + */ + camera: THREEJS.PerspectiveCamera | THREEJS.OrthographicCamera; + } + + export class PositionDto { + constructor(camera?: THREEJS.PerspectiveCamera | THREEJS.OrthographicCamera, position?: Base.Point3) { + if (camera !== undefined) { this.camera = camera; } + if (position !== undefined) { this.position = position; } + } + /** + * ThreeJS camera + * @default undefined + */ + camera: THREEJS.PerspectiveCamera | THREEJS.OrthographicCamera; + /** + * Position of the camera + * @default [0, 0, 0] + */ + position: Base.Point3 = [0, 0, 0]; + } + + export class PivotPointDto { + constructor(orbitCamera?: OrbitCameraController, pivotPoint?: Base.Point3) { + if (orbitCamera !== undefined) { this.orbitCamera = orbitCamera; } + if (pivotPoint !== undefined) { this.pivotPoint = pivotPoint; } + } + /** + * Orbit camera controller instance + * @default undefined + */ + orbitCamera: OrbitCameraController; + /** + * Pivot point for the orbit camera + * @default [0, 0, 0] + */ + pivotPoint: Base.Point3 = [0, 0, 0]; + } + + export class FocusObjectDto { + constructor(orbitCamera?: OrbitCameraController, object?: THREEJS.Object3D, padding?: number) { + if (orbitCamera !== undefined) { this.orbitCamera = orbitCamera; } + if (object !== undefined) { this.object = object; } + if (padding !== undefined) { this.padding = padding; } + } + /** + * Orbit camera controller instance + * @default undefined + */ + orbitCamera: OrbitCameraController; + /** + * Object to focus the camera on + * @default undefined + */ + object: THREEJS.Object3D; + /** + * Padding multiplier for the focus distance (1 = tight fit, higher = more space around object) + * @default 1.5 + * @minimum 1 + * @maximum 5 + * @step 0.1 + */ + padding = 1.5; + } + + export class ResetCameraDto { + constructor(orbitCamera?: OrbitCameraController, yaw?: number, pitch?: number, distance?: number) { + if (orbitCamera !== undefined) { this.orbitCamera = orbitCamera; } + if (yaw !== undefined) { this.yaw = yaw; } + if (pitch !== undefined) { this.pitch = pitch; } + if (distance !== undefined) { this.distance = distance; } + } + /** + * Orbit camera controller instance + * @default undefined + */ + orbitCamera: OrbitCameraController; + /** + * Yaw angle in degrees + * @default 45 + * @minimum -360 + * @maximum 360 + * @step 1 + */ + yaw = 45; + /** + * Pitch angle in degrees + * @default 30 + * @minimum -90 + * @maximum 90 + * @step 1 + */ + pitch = 30; + /** + * Distance from pivot point + * @default 20 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + distance = 20; + } + + export class OrbitCameraControllerDto { + constructor(orbitCamera?: OrbitCameraController) { + if (orbitCamera !== undefined) { this.orbitCamera = orbitCamera; } + } + /** + * Orbit camera controller instance + * @default undefined + */ + orbitCamera: OrbitCameraController; + } + + export class SetDistanceLimitsDto { + constructor(orbitCamera?: OrbitCameraController, min?: number, max?: number) { + if (orbitCamera !== undefined) { this.orbitCamera = orbitCamera; } + if (min !== undefined) { this.min = min; } + if (max !== undefined) { this.max = max; } + } + /** + * Orbit camera controller instance + * @default undefined + */ + orbitCamera: OrbitCameraController; + /** + * Minimum distance + * @default 0.1 + * @minimum 0 + * @maximum Infinity + * @step 0.1 + */ + min = 0.1; + /** + * Maximum distance + * @default 1000 + * @minimum 0 + * @maximum Infinity + * @step 1 + */ + max = 1000; + } + + export class SetPitchLimitsDto { + constructor(orbitCamera?: OrbitCameraController, min?: number, max?: number) { + if (orbitCamera !== undefined) { this.orbitCamera = orbitCamera; } + if (min !== undefined) { this.min = min; } + if (max !== undefined) { this.max = max; } + } + /** + * Orbit camera controller instance + * @default undefined + */ + orbitCamera: OrbitCameraController; + /** + * Minimum pitch angle in degrees + * @default -90 + * @minimum -90 + * @maximum 90 + * @step 1 + */ + min = -90; + /** + * Maximum pitch angle in degrees + * @default 90 + * @minimum -90 + * @maximum 90 + * @step 1 + */ + max = 90; + } +} From fea30ea208dc376a03c7d26a46394663ecad37fd Mon Sep 17 00:00:00 2001 From: Matas Ubarevicius Date: Sun, 11 Jan 2026 16:47:24 +0200 Subject: [PATCH 07/31] synced property value with playcanvas --- .../threejs/lib/api/inputs/threejs-camera-inputs.test.ts | 2 +- .../dev/threejs/lib/api/inputs/threejs-camera-inputs.ts | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/packages/dev/threejs/lib/api/inputs/threejs-camera-inputs.test.ts b/packages/dev/threejs/lib/api/inputs/threejs-camera-inputs.test.ts index 199bb011..2ba03534 100644 --- a/packages/dev/threejs/lib/api/inputs/threejs-camera-inputs.test.ts +++ b/packages/dev/threejs/lib/api/inputs/threejs-camera-inputs.test.ts @@ -73,7 +73,7 @@ describe("ThreeJSCamera DTO unit tests", () => { expect(result.orbitSensitivity).toBe(0.3); expect(result.distanceSensitivity).toBe(0.15); expect(result.panSensitivity).toBe(1); - expect(result.inertiaFactor).toBe(0.1); + expect(result.inertiaFactor).toBe(0); expect(result.autoRender).toBe(true); expect(result.frameOnStart).toBe(true); expect(result.enableDamping).toBe(true); diff --git a/packages/dev/threejs/lib/api/inputs/threejs-camera-inputs.ts b/packages/dev/threejs/lib/api/inputs/threejs-camera-inputs.ts index 03b793e1..ef441bfa 100644 --- a/packages/dev/threejs/lib/api/inputs/threejs-camera-inputs.ts +++ b/packages/dev/threejs/lib/api/inputs/threejs-camera-inputs.ts @@ -172,13 +172,13 @@ export namespace ThreeJSCamera { */ panSensitivity = 1; /** - * Inertia factor for smooth camera movement (0 = no inertia, higher values = more inertia/smoother movement) - * @default 0.1 + * Inertia factor for smooth camera movement (0 = no inertia, 1 = maximum inertia) + * @default 0 * @minimum 0 * @maximum 1 - * @step 0.05 + * @step 0.1 */ - inertiaFactor = 0.1; + inertiaFactor = 0; /** * Whether the camera should trigger automatic rendering on changes * @default true From 022451e3702c8cfb5a76866fb699b9b1e16b367d Mon Sep 17 00:00:00 2001 From: Matas Ubarevicius Date: Sun, 11 Jan 2026 20:46:33 +0200 Subject: [PATCH 08/31] initThreeJS helper function implemented that simplifies initial setup. starter-template simple and full for clarity, meshes receive and cast shadows by default. --- .../threejs/starter-template-full/index.html | 27 + .../starter-template-full/package-lock.json | 3283 +++++++++++++++++ .../starter-template-full/package.json | 19 + .../starter-template-full/public/vite.svg | 1 + .../threejs/starter-template-full/src/main.ts | 575 +++ .../starter-template-full/src/style.css | 25 + .../starter-template-full/src/vite-env.d.ts | 1 + .../starter-template-full/tsconfig.json | 25 + .../vite/threejs/starter-template/src/main.ts | 666 +--- .../starter-template/src/models/current.ts | 11 - .../starter-template/src/models/model.ts | 24 - .../src/workers/jscad.worker.ts | 12 - .../src/workers/manifold.worker.ts | 21 - .../src/workers/occt.worker.ts | 14 - .../dev/babylonjs/lib/api/init-kernels.ts | 10 +- packages/dev/core/lib/api/init-kernels.ts | 4 +- .../dev/playcanvas/lib/api/init-kernels.ts | 10 +- .../threejs/lib/api/bitbybit/threejs/index.ts | 1 + .../lib/api/bitbybit/threejs/orbit-camera.ts | 17 + .../lib/api/bitbybit/threejs/scene-helper.ts | 213 ++ packages/dev/threejs/lib/api/draw-helper.ts | 32 +- packages/dev/threejs/lib/api/init-kernels.ts | 20 +- packages/dev/threejs/lib/api/inputs/index.ts | 1 + packages/dev/threejs/lib/api/inputs/inputs.ts | 1 + .../api/inputs/threejs-scene-inputs.test.ts | 82 + .../lib/api/inputs/threejs-scene-inputs.ts | 189 + 26 files changed, 4534 insertions(+), 750 deletions(-) create mode 100644 examples/vite/threejs/starter-template-full/index.html create mode 100644 examples/vite/threejs/starter-template-full/package-lock.json create mode 100644 examples/vite/threejs/starter-template-full/package.json create mode 100644 examples/vite/threejs/starter-template-full/public/vite.svg create mode 100644 examples/vite/threejs/starter-template-full/src/main.ts create mode 100644 examples/vite/threejs/starter-template-full/src/style.css create mode 100644 examples/vite/threejs/starter-template-full/src/vite-env.d.ts create mode 100644 examples/vite/threejs/starter-template-full/tsconfig.json delete mode 100644 examples/vite/threejs/starter-template/src/models/current.ts delete mode 100644 examples/vite/threejs/starter-template/src/models/model.ts delete mode 100644 examples/vite/threejs/starter-template/src/workers/jscad.worker.ts delete mode 100644 examples/vite/threejs/starter-template/src/workers/manifold.worker.ts delete mode 100644 examples/vite/threejs/starter-template/src/workers/occt.worker.ts create mode 100644 packages/dev/threejs/lib/api/bitbybit/threejs/scene-helper.ts create mode 100644 packages/dev/threejs/lib/api/inputs/threejs-scene-inputs.test.ts create mode 100644 packages/dev/threejs/lib/api/inputs/threejs-scene-inputs.ts diff --git a/examples/vite/threejs/starter-template-full/index.html b/examples/vite/threejs/starter-template-full/index.html new file mode 100644 index 00000000..36144cab --- /dev/null +++ b/examples/vite/threejs/starter-template-full/index.html @@ -0,0 +1,27 @@ + + + + + + + Bitbybit & ThreeJS All Kernels Example + + + + + + + diff --git a/examples/vite/threejs/starter-template-full/package-lock.json b/examples/vite/threejs/starter-template-full/package-lock.json new file mode 100644 index 00000000..159f71d4 --- /dev/null +++ b/examples/vite/threejs/starter-template-full/package-lock.json @@ -0,0 +1,3283 @@ +{ + "name": "vite-typescript-starter", + "version": "0.0.0", + "lockfileVersion": 2, + "requires": true, + "packages": { + "": { + "name": "vite-typescript-starter", + "version": "0.0.0", + "dependencies": { + "@bitbybit-dev/threejs": "0.21.0" + }, + "devDependencies": { + "@types/three": "0.182.0", + "typescript": "~5.8.3", + "vite": "^6.3.2" + } + }, + "node_modules/@bitbybit-dev/base": { + "version": "0.21.0", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/base/-/base-0.21.0.tgz", + "integrity": "sha512-dNfsf2tu3/QUD1mvZzzTze8RwHyK2Jrt+Ary8EDKdNKMw+abtCpQYNerdrg0ZQPxvwu/OOQz6N1xCsCwsPkQJg==", + "license": "MIT" + }, + "node_modules/@bitbybit-dev/core": { + "version": "0.21.0", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/core/-/core-0.21.0.tgz", + "integrity": "sha512-IbeQ8ROreu0/RkkngUE+Eb19ecvqKOWhGefXvIqQmplxt3zEc0FI4Kw8wR3vYl2XMannuVt1xAIYtqqH0tjBzg==", + "license": "MIT", + "dependencies": { + "@bitbybit-dev/base": "0.21.0", + "@bitbybit-dev/jscad-worker": "0.21.0", + "@bitbybit-dev/manifold-worker": "0.21.0", + "@bitbybit-dev/occt-worker": "0.21.0", + "jsonpath-plus": "10.1.0", + "rxjs": "7.5.5", + "verb-nurbs-web": "2.1.3" + } + }, + "node_modules/@bitbybit-dev/jscad": { + "version": "0.21.0", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/jscad/-/jscad-0.21.0.tgz", + "integrity": "sha512-Q7eE2ILrJRstW4L1711aJZdpwPf1kuhZJqB+KLkkBLsneRsGsh82lBcCbVYAOMuF/q8Lnd4JHxPiIG/m+LYmPQ==", + "license": "MIT", + "dependencies": { + "@bitbybit-dev/base": "0.21.0", + "@jscad/3mf-serializer": "2.1.12", + "@jscad/dxf-serializer": "2.1.18", + "@jscad/io-utils": "2.0.28", + "@jscad/modeling": "2.12.3", + "@jscad/stl-serializer": "2.1.18" + } + }, + "node_modules/@bitbybit-dev/jscad-worker": { + "version": "0.21.0", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/jscad-worker/-/jscad-worker-0.21.0.tgz", + "integrity": "sha512-nIvd7GH5Gg51u6PmFXOADXVYTIvixTkNf0YapS1uix7D2JS9Mx10Z4wHAeRKzvJxUAAbEPPRFNkakE22HFGtLQ==", + "license": "MIT", + "dependencies": { + "@bitbybit-dev/jscad": "0.21.0", + "rxjs": "7.5.5" + } + }, + "node_modules/@bitbybit-dev/manifold": { + "version": "0.21.0", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/manifold/-/manifold-0.21.0.tgz", + "integrity": "sha512-DPpwK9ESB+auDeAbzXcfWRVEzWoMDkpkjc+/uwh+zuSiHSx92PSkzx1/LVTbQCsK+aOfOOy03HQCF5Bu2KQYtw==", + "license": "MIT", + "dependencies": { + "@bitbybit-dev/base": "0.21.0", + "manifold-3d": "3.3.2" + } + }, + "node_modules/@bitbybit-dev/manifold-worker": { + "version": "0.21.0", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/manifold-worker/-/manifold-worker-0.21.0.tgz", + "integrity": "sha512-6Cqv3BP+uI8mHKHI6Jx9TzCxRg1/kMHhCe18+B3KD/rTl9B5mnScCKRBnDansR3bH7aYZGnIw9PmiFnWLkQWEQ==", + "license": "MIT", + "dependencies": { + "@bitbybit-dev/manifold": "0.21.0", + "rxjs": "7.5.5" + } + }, + "node_modules/@bitbybit-dev/occt": { + "version": "0.21.0", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/occt/-/occt-0.21.0.tgz", + "integrity": "sha512-vPu3NmF1kBZMOkOdysolGfFxEEnwdHNGORoX3eWbMWT2JL/Tag5Q2CAc5jwa2VvZnS1nE/9x+DVlFQSo8LQnIg==", + "license": "MIT", + "dependencies": { + "@bitbybit-dev/base": "0.21.0" + } + }, + "node_modules/@bitbybit-dev/occt-worker": { + "version": "0.21.0", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/occt-worker/-/occt-worker-0.21.0.tgz", + "integrity": "sha512-xG1sgo6q/RdVA8AgG72wPe4qxcQlrO1V7/Ksn6MqIhZVTsJcm5RbVYlK+nziIWhvlMc1sKE0GNQFcPdALISLuQ==", + "license": "MIT", + "dependencies": { + "@bitbybit-dev/occt": "0.21.0", + "rxjs": "7.5.5" + } + }, + "node_modules/@bitbybit-dev/threejs": { + "version": "0.21.0", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/threejs/-/threejs-0.21.0.tgz", + "integrity": "sha512-p0fHuLTjoXs3UIWoC2TFUBAhu0F4sTPU//PCvwwPLmLrbrVmpEFV61tGs0739hbU4eKS5goCTUM99RfjbRxW6A==", + "license": "MIT", + "dependencies": { + "@bitbybit-dev/core": "0.21.0", + "three": "0.182.0" + } + }, + "node_modules/@dimforge/rapier3d-compat": { + "version": "0.12.0", + "resolved": "https://registry.npmjs.org/@dimforge/rapier3d-compat/-/rapier3d-compat-0.12.0.tgz", + "integrity": "sha512-uekIGetywIgopfD97oDL5PfeezkFpNhwlzlaEYNOA0N6ghdsOvh/HYjSMek5Q2O1PYvRSDFcqFVJl4r4ZBwOow==", + "dev": true, + "license": "Apache-2.0" + }, + "node_modules/@emnapi/runtime": { + "version": "1.8.1", + "resolved": "https://registry.npmjs.org/@emnapi/runtime/-/runtime-1.8.1.tgz", + "integrity": "sha512-mehfKSMWjjNol8659Z8KxEMrdSJDDot5SXMq00dM8BN4o+CLNXQ0xH2V7EchNHV4RmbZLmmPdEaXZc5H2FXmDg==", + "license": "MIT", + "optional": true, + "dependencies": { + "tslib": "^2.4.0" + } + }, + "node_modules/@esbuild/aix-ppc64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/aix-ppc64/-/aix-ppc64-0.25.3.tgz", + "integrity": "sha512-W8bFfPA8DowP8l//sxjJLSLkD8iEjMc7cBVyP+u4cEv9sM7mdUCkgsj+t0n/BWPFtv7WWCN5Yzj0N6FJNUUqBQ==", + "cpu": [ + "ppc64" + ], + "dev": true, + "optional": true, + "os": [ + "aix" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/android-arm": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/android-arm/-/android-arm-0.25.3.tgz", + "integrity": "sha512-PuwVXbnP87Tcff5I9ngV0lmiSu40xw1At6i3GsU77U7cjDDB4s0X2cyFuBiDa1SBk9DnvWwnGvVaGBqoFWPb7A==", + "cpu": [ + "arm" + ], + "dev": true, + "optional": true, + "os": [ + "android" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/android-arm64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/android-arm64/-/android-arm64-0.25.3.tgz", + "integrity": "sha512-XelR6MzjlZuBM4f5z2IQHK6LkK34Cvv6Rj2EntER3lwCBFdg6h2lKbtRjpTTsdEjD/WSe1q8UyPBXP1x3i/wYQ==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "android" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/android-x64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/android-x64/-/android-x64-0.25.3.tgz", + "integrity": "sha512-ogtTpYHT/g1GWS/zKM0cc/tIebFjm1F9Aw1boQ2Y0eUQ+J89d0jFY//s9ei9jVIlkYi8AfOjiixcLJSGNSOAdQ==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "android" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/darwin-arm64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/darwin-arm64/-/darwin-arm64-0.25.3.tgz", + "integrity": "sha512-eESK5yfPNTqpAmDfFWNsOhmIOaQA59tAcF/EfYvo5/QWQCzXn5iUSOnqt3ra3UdzBv073ykTtmeLJZGt3HhA+w==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/darwin-x64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/darwin-x64/-/darwin-x64-0.25.3.tgz", + "integrity": "sha512-Kd8glo7sIZtwOLcPbW0yLpKmBNWMANZhrC1r6K++uDR2zyzb6AeOYtI6udbtabmQpFaxJ8uduXMAo1gs5ozz8A==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/freebsd-arm64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/freebsd-arm64/-/freebsd-arm64-0.25.3.tgz", + "integrity": "sha512-EJiyS70BYybOBpJth3M0KLOus0n+RRMKTYzhYhFeMwp7e/RaajXvP+BWlmEXNk6uk+KAu46j/kaQzr6au+JcIw==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "freebsd" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/freebsd-x64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/freebsd-x64/-/freebsd-x64-0.25.3.tgz", + "integrity": "sha512-Q+wSjaLpGxYf7zC0kL0nDlhsfuFkoN+EXrx2KSB33RhinWzejOd6AvgmP5JbkgXKmjhmpfgKZq24pneodYqE8Q==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "freebsd" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-arm": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/linux-arm/-/linux-arm-0.25.3.tgz", + "integrity": "sha512-dUOVmAUzuHy2ZOKIHIKHCm58HKzFqd+puLaS424h6I85GlSDRZIA5ycBixb3mFgM0Jdh+ZOSB6KptX30DD8YOQ==", + "cpu": [ + "arm" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-arm64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/linux-arm64/-/linux-arm64-0.25.3.tgz", + "integrity": "sha512-xCUgnNYhRD5bb1C1nqrDV1PfkwgbswTTBRbAd8aH5PhYzikdf/ddtsYyMXFfGSsb/6t6QaPSzxtbfAZr9uox4A==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-ia32": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/linux-ia32/-/linux-ia32-0.25.3.tgz", + "integrity": "sha512-yplPOpczHOO4jTYKmuYuANI3WhvIPSVANGcNUeMlxH4twz/TeXuzEP41tGKNGWJjuMhotpGabeFYGAOU2ummBw==", + "cpu": [ + "ia32" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-loong64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/linux-loong64/-/linux-loong64-0.25.3.tgz", + "integrity": "sha512-P4BLP5/fjyihmXCELRGrLd793q/lBtKMQl8ARGpDxgzgIKJDRJ/u4r1A/HgpBpKpKZelGct2PGI4T+axcedf6g==", + "cpu": [ + "loong64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-mips64el": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/linux-mips64el/-/linux-mips64el-0.25.3.tgz", + "integrity": "sha512-eRAOV2ODpu6P5divMEMa26RRqb2yUoYsuQQOuFUexUoQndm4MdpXXDBbUoKIc0iPa4aCO7gIhtnYomkn2x+bag==", + "cpu": [ + "mips64el" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-ppc64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/linux-ppc64/-/linux-ppc64-0.25.3.tgz", + "integrity": "sha512-ZC4jV2p7VbzTlnl8nZKLcBkfzIf4Yad1SJM4ZMKYnJqZFD4rTI+pBG65u8ev4jk3/MPwY9DvGn50wi3uhdaghg==", + "cpu": [ + "ppc64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-riscv64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/linux-riscv64/-/linux-riscv64-0.25.3.tgz", + "integrity": "sha512-LDDODcFzNtECTrUUbVCs6j9/bDVqy7DDRsuIXJg6so+mFksgwG7ZVnTruYi5V+z3eE5y+BJZw7VvUadkbfg7QA==", + "cpu": [ + "riscv64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-s390x": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/linux-s390x/-/linux-s390x-0.25.3.tgz", + "integrity": "sha512-s+w/NOY2k0yC2p9SLen+ymflgcpRkvwwa02fqmAwhBRI3SC12uiS10edHHXlVWwfAagYSY5UpmT/zISXPMW3tQ==", + "cpu": [ + "s390x" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-x64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/linux-x64/-/linux-x64-0.25.3.tgz", + "integrity": "sha512-nQHDz4pXjSDC6UfOE1Fw9Q8d6GCAd9KdvMZpfVGWSJztYCarRgSDfOVBY5xwhQXseiyxapkiSJi/5/ja8mRFFA==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/netbsd-arm64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/netbsd-arm64/-/netbsd-arm64-0.25.3.tgz", + "integrity": "sha512-1QaLtOWq0mzK6tzzp0jRN3eccmN3hezey7mhLnzC6oNlJoUJz4nym5ZD7mDnS/LZQgkrhEbEiTn515lPeLpgWA==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "netbsd" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/netbsd-x64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/netbsd-x64/-/netbsd-x64-0.25.3.tgz", + "integrity": "sha512-i5Hm68HXHdgv8wkrt+10Bc50zM0/eonPb/a/OFVfB6Qvpiirco5gBA5bz7S2SHuU+Y4LWn/zehzNX14Sp4r27g==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "netbsd" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/openbsd-arm64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/openbsd-arm64/-/openbsd-arm64-0.25.3.tgz", + "integrity": "sha512-zGAVApJEYTbOC6H/3QBr2mq3upG/LBEXr85/pTtKiv2IXcgKV0RT0QA/hSXZqSvLEpXeIxah7LczB4lkiYhTAQ==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "openbsd" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/openbsd-x64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/openbsd-x64/-/openbsd-x64-0.25.3.tgz", + "integrity": "sha512-fpqctI45NnCIDKBH5AXQBsD0NDPbEFczK98hk/aa6HJxbl+UtLkJV2+Bvy5hLSLk3LHmqt0NTkKNso1A9y1a4w==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "openbsd" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/sunos-x64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/sunos-x64/-/sunos-x64-0.25.3.tgz", + "integrity": "sha512-ROJhm7d8bk9dMCUZjkS8fgzsPAZEjtRJqCAmVgB0gMrvG7hfmPmz9k1rwO4jSiblFjYmNvbECL9uhaPzONMfgA==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "sunos" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/win32-arm64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/win32-arm64/-/win32-arm64-0.25.3.tgz", + "integrity": "sha512-YWcow8peiHpNBiIXHwaswPnAXLsLVygFwCB3A7Bh5jRkIBFWHGmNQ48AlX4xDvQNoMZlPYzjVOQDYEzWCqufMQ==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/win32-ia32": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/win32-ia32/-/win32-ia32-0.25.3.tgz", + "integrity": "sha512-qspTZOIGoXVS4DpNqUYUs9UxVb04khS1Degaw/MnfMe7goQ3lTfQ13Vw4qY/Nj0979BGvMRpAYbs/BAxEvU8ew==", + "cpu": [ + "ia32" + ], + "dev": true, + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/win32-x64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/win32-x64/-/win32-x64-0.25.3.tgz", + "integrity": "sha512-ICgUR+kPimx0vvRzf+N/7L7tVSQeE3BYY+NhHRHXS1kBuPO7z2+7ea2HbhDyZdTephgvNvKrlDDKUexuCVBVvg==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@gltf-transform/core": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/@gltf-transform/core/-/core-4.3.0.tgz", + "integrity": "sha512-ZeaQfszGJ9LYwELszu45CuDQCsE26lJNNe36FVmN8xclaT6WDdCj7fwGpQXo0/l/YgAVAHX+uO7YNBW75/SRYw==", + "license": "MIT", + "dependencies": { + "property-graph": "^4.0.0" + }, + "funding": { + "url": "https://github.com/sponsors/donmccurdy" + } + }, + "node_modules/@gltf-transform/extensions": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/@gltf-transform/extensions/-/extensions-4.3.0.tgz", + "integrity": "sha512-XDAjQPYVMHa/VDpSbfCBwI+/1muwRJCaXhUpLgnUzAjn0D//PgvIAcbNm1EwBl3LIWBSwjDUCn2LiMAjp+aXVw==", + "license": "MIT", + "dependencies": { + "@gltf-transform/core": "^4.3.0", + "ktx-parse": "^1.0.1" + }, + "funding": { + "url": "https://github.com/sponsors/donmccurdy" + } + }, + "node_modules/@gltf-transform/functions": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/@gltf-transform/functions/-/functions-4.3.0.tgz", + "integrity": "sha512-FZggHVgt3DHOezgESBrf2vDzuD2FYQYaNT2sT/aP316SIwhuiIwby3z7rhV9joDvWqqUaPkf1UmkjlOaY9riSQ==", + "license": "MIT", + "dependencies": { + "@gltf-transform/core": "^4.3.0", + "@gltf-transform/extensions": "^4.3.0", + "ktx-parse": "^1.0.1", + "ndarray": "^1.0.19", + "ndarray-lanczos": "^0.3.0", + "ndarray-pixels": "^5.0.1" + }, + "funding": { + "url": "https://github.com/sponsors/donmccurdy" + } + }, + "node_modules/@img/colour": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/@img/colour/-/colour-1.0.0.tgz", + "integrity": "sha512-A5P/LfWGFSl6nsckYtjw9da+19jB8hkJ6ACTGcDfEJ0aE+l2n2El7dsVM7UVHZQ9s2lmYMWlrS21YLy2IR1LUw==", + "license": "MIT", + "engines": { + "node": ">=18" + } + }, + "node_modules/@img/sharp-darwin-arm64": { + "version": "0.34.5", + "resolved": "https://registry.npmjs.org/@img/sharp-darwin-arm64/-/sharp-darwin-arm64-0.34.5.tgz", + "integrity": "sha512-imtQ3WMJXbMY4fxb/Ndp6HBTNVtWCUI0WdobyheGf5+ad6xX8VIDO8u2xE4qc/fr08CKG/7dDseFtn6M6g/r3w==", + "cpu": [ + "arm64" + ], + "license": "Apache-2.0", + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": "^18.17.0 || ^20.3.0 || >=21.0.0" + }, + "funding": { + "url": "https://opencollective.com/libvips" + }, + "optionalDependencies": { + "@img/sharp-libvips-darwin-arm64": "1.2.4" + } + }, + "node_modules/@img/sharp-darwin-x64": { + "version": "0.34.5", + "resolved": "https://registry.npmjs.org/@img/sharp-darwin-x64/-/sharp-darwin-x64-0.34.5.tgz", + "integrity": "sha512-YNEFAF/4KQ/PeW0N+r+aVVsoIY0/qxxikF2SWdp+NRkmMB7y9LBZAVqQ4yhGCm/H3H270OSykqmQMKLBhBJDEw==", + "cpu": [ + "x64" + ], + "license": "Apache-2.0", + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": "^18.17.0 || ^20.3.0 || >=21.0.0" + }, + "funding": { + "url": "https://opencollective.com/libvips" + }, + "optionalDependencies": { + "@img/sharp-libvips-darwin-x64": "1.2.4" + } + }, + "node_modules/@img/sharp-libvips-darwin-arm64": { + "version": "1.2.4", + "resolved": "https://registry.npmjs.org/@img/sharp-libvips-darwin-arm64/-/sharp-libvips-darwin-arm64-1.2.4.tgz", + "integrity": "sha512-zqjjo7RatFfFoP0MkQ51jfuFZBnVE2pRiaydKJ1G/rHZvnsrHAOcQALIi9sA5co5xenQdTugCvtb1cuf78Vf4g==", + "cpu": [ + "arm64" + ], + "license": "LGPL-3.0-or-later", + "optional": true, + "os": [ + "darwin" + ], + "funding": { + "url": "https://opencollective.com/libvips" + } + }, + "node_modules/@img/sharp-libvips-darwin-x64": { + "version": "1.2.4", + "resolved": "https://registry.npmjs.org/@img/sharp-libvips-darwin-x64/-/sharp-libvips-darwin-x64-1.2.4.tgz", + "integrity": "sha512-1IOd5xfVhlGwX+zXv2N93k0yMONvUlANylbJw1eTah8K/Jtpi15KC+WSiaX/nBmbm2HxRM1gZ0nSdjSsrZbGKg==", + "cpu": [ + "x64" + ], + "license": "LGPL-3.0-or-later", + "optional": true, + "os": [ + "darwin" + ], + "funding": { + "url": "https://opencollective.com/libvips" + } + }, + "node_modules/@img/sharp-libvips-linux-arm": { + "version": "1.2.4", + "resolved": "https://registry.npmjs.org/@img/sharp-libvips-linux-arm/-/sharp-libvips-linux-arm-1.2.4.tgz", + "integrity": "sha512-bFI7xcKFELdiNCVov8e44Ia4u2byA+l3XtsAj+Q8tfCwO6BQ8iDojYdvoPMqsKDkuoOo+X6HZA0s0q11ANMQ8A==", + "cpu": [ + "arm" + ], + "license": "LGPL-3.0-or-later", + "optional": true, + "os": [ + "linux" + ], + "funding": { + "url": "https://opencollective.com/libvips" + } + }, + "node_modules/@img/sharp-libvips-linux-arm64": { + "version": "1.2.4", + "resolved": "https://registry.npmjs.org/@img/sharp-libvips-linux-arm64/-/sharp-libvips-linux-arm64-1.2.4.tgz", + "integrity": "sha512-excjX8DfsIcJ10x1Kzr4RcWe1edC9PquDRRPx3YVCvQv+U5p7Yin2s32ftzikXojb1PIFc/9Mt28/y+iRklkrw==", + "cpu": [ + "arm64" + ], + "license": "LGPL-3.0-or-later", + "optional": true, + "os": [ + "linux" + ], + "funding": { + "url": "https://opencollective.com/libvips" + } + }, + "node_modules/@img/sharp-libvips-linux-ppc64": { + "version": "1.2.4", + "resolved": "https://registry.npmjs.org/@img/sharp-libvips-linux-ppc64/-/sharp-libvips-linux-ppc64-1.2.4.tgz", + "integrity": "sha512-FMuvGijLDYG6lW+b/UvyilUWu5Ayu+3r2d1S8notiGCIyYU/76eig1UfMmkZ7vwgOrzKzlQbFSuQfgm7GYUPpA==", + "cpu": [ + "ppc64" + ], + "license": "LGPL-3.0-or-later", + "optional": true, + "os": [ + "linux" + ], + "funding": { + "url": "https://opencollective.com/libvips" + } + }, + "node_modules/@img/sharp-libvips-linux-riscv64": { + "version": "1.2.4", + "resolved": "https://registry.npmjs.org/@img/sharp-libvips-linux-riscv64/-/sharp-libvips-linux-riscv64-1.2.4.tgz", + "integrity": "sha512-oVDbcR4zUC0ce82teubSm+x6ETixtKZBh/qbREIOcI3cULzDyb18Sr/Wcyx7NRQeQzOiHTNbZFF1UwPS2scyGA==", + "cpu": [ + "riscv64" + ], + "license": "LGPL-3.0-or-later", + "optional": true, + "os": [ + "linux" + ], + "funding": { + "url": "https://opencollective.com/libvips" + } + }, + "node_modules/@img/sharp-libvips-linux-s390x": { + "version": "1.2.4", + "resolved": "https://registry.npmjs.org/@img/sharp-libvips-linux-s390x/-/sharp-libvips-linux-s390x-1.2.4.tgz", + "integrity": "sha512-qmp9VrzgPgMoGZyPvrQHqk02uyjA0/QrTO26Tqk6l4ZV0MPWIW6LTkqOIov+J1yEu7MbFQaDpwdwJKhbJvuRxQ==", + "cpu": [ + "s390x" + ], + "license": "LGPL-3.0-or-later", + "optional": true, + "os": [ + "linux" + ], + "funding": { + "url": "https://opencollective.com/libvips" + } + }, + "node_modules/@img/sharp-libvips-linux-x64": { + "version": "1.2.4", + "resolved": "https://registry.npmjs.org/@img/sharp-libvips-linux-x64/-/sharp-libvips-linux-x64-1.2.4.tgz", + "integrity": "sha512-tJxiiLsmHc9Ax1bz3oaOYBURTXGIRDODBqhveVHonrHJ9/+k89qbLl0bcJns+e4t4rvaNBxaEZsFtSfAdquPrw==", + "cpu": [ + "x64" + ], + "license": "LGPL-3.0-or-later", + "optional": true, + "os": [ + "linux" + ], + "funding": { + "url": "https://opencollective.com/libvips" + } + }, + "node_modules/@img/sharp-libvips-linuxmusl-arm64": { + "version": "1.2.4", + "resolved": "https://registry.npmjs.org/@img/sharp-libvips-linuxmusl-arm64/-/sharp-libvips-linuxmusl-arm64-1.2.4.tgz", + "integrity": "sha512-FVQHuwx1IIuNow9QAbYUzJ+En8KcVm9Lk5+uGUQJHaZmMECZmOlix9HnH7n1TRkXMS0pGxIJokIVB9SuqZGGXw==", + "cpu": [ + "arm64" + ], + "license": "LGPL-3.0-or-later", + "optional": true, + "os": [ + "linux" + ], + "funding": { + "url": "https://opencollective.com/libvips" + } + }, + "node_modules/@img/sharp-libvips-linuxmusl-x64": { + "version": "1.2.4", + "resolved": "https://registry.npmjs.org/@img/sharp-libvips-linuxmusl-x64/-/sharp-libvips-linuxmusl-x64-1.2.4.tgz", + "integrity": "sha512-+LpyBk7L44ZIXwz/VYfglaX/okxezESc6UxDSoyo2Ks6Jxc4Y7sGjpgU9s4PMgqgjj1gZCylTieNamqA1MF7Dg==", + "cpu": [ + "x64" + ], + "license": "LGPL-3.0-or-later", + "optional": true, + "os": [ + "linux" + ], + "funding": { + "url": "https://opencollective.com/libvips" + } + }, + "node_modules/@img/sharp-linux-arm": { + "version": "0.34.5", + "resolved": "https://registry.npmjs.org/@img/sharp-linux-arm/-/sharp-linux-arm-0.34.5.tgz", + "integrity": "sha512-9dLqsvwtg1uuXBGZKsxem9595+ujv0sJ6Vi8wcTANSFpwV/GONat5eCkzQo/1O6zRIkh0m/8+5BjrRr7jDUSZw==", + "cpu": [ + "arm" + ], + "license": "Apache-2.0", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": "^18.17.0 || ^20.3.0 || >=21.0.0" + }, + "funding": { + "url": "https://opencollective.com/libvips" + }, + "optionalDependencies": { + "@img/sharp-libvips-linux-arm": "1.2.4" + } + }, + "node_modules/@img/sharp-linux-arm64": { + "version": "0.34.5", + "resolved": "https://registry.npmjs.org/@img/sharp-linux-arm64/-/sharp-linux-arm64-0.34.5.tgz", + "integrity": "sha512-bKQzaJRY/bkPOXyKx5EVup7qkaojECG6NLYswgktOZjaXecSAeCWiZwwiFf3/Y+O1HrauiE3FVsGxFg8c24rZg==", + "cpu": [ + "arm64" + ], + "license": "Apache-2.0", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": "^18.17.0 || ^20.3.0 || >=21.0.0" + }, + "funding": { + "url": "https://opencollective.com/libvips" + }, + "optionalDependencies": { + "@img/sharp-libvips-linux-arm64": "1.2.4" + } + }, + "node_modules/@img/sharp-linux-ppc64": { + "version": "0.34.5", + "resolved": "https://registry.npmjs.org/@img/sharp-linux-ppc64/-/sharp-linux-ppc64-0.34.5.tgz", + "integrity": "sha512-7zznwNaqW6YtsfrGGDA6BRkISKAAE1Jo0QdpNYXNMHu2+0dTrPflTLNkpc8l7MUP5M16ZJcUvysVWWrMefZquA==", + "cpu": [ + "ppc64" + ], + "license": "Apache-2.0", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": "^18.17.0 || ^20.3.0 || >=21.0.0" + }, + "funding": { + "url": "https://opencollective.com/libvips" + }, + "optionalDependencies": { + "@img/sharp-libvips-linux-ppc64": "1.2.4" + } + }, + "node_modules/@img/sharp-linux-riscv64": { + "version": "0.34.5", + "resolved": "https://registry.npmjs.org/@img/sharp-linux-riscv64/-/sharp-linux-riscv64-0.34.5.tgz", + "integrity": "sha512-51gJuLPTKa7piYPaVs8GmByo7/U7/7TZOq+cnXJIHZKavIRHAP77e3N2HEl3dgiqdD/w0yUfiJnII77PuDDFdw==", + "cpu": [ + "riscv64" + ], + "license": "Apache-2.0", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": "^18.17.0 || ^20.3.0 || >=21.0.0" + }, + "funding": { + "url": "https://opencollective.com/libvips" + }, + "optionalDependencies": { + "@img/sharp-libvips-linux-riscv64": "1.2.4" + } + }, + "node_modules/@img/sharp-linux-s390x": { + "version": "0.34.5", + "resolved": "https://registry.npmjs.org/@img/sharp-linux-s390x/-/sharp-linux-s390x-0.34.5.tgz", + "integrity": "sha512-nQtCk0PdKfho3eC5MrbQoigJ2gd1CgddUMkabUj+rBevs8tZ2cULOx46E7oyX+04WGfABgIwmMC0VqieTiR4jg==", + "cpu": [ + "s390x" + ], + "license": "Apache-2.0", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": "^18.17.0 || ^20.3.0 || >=21.0.0" + }, + "funding": { + "url": "https://opencollective.com/libvips" + }, + "optionalDependencies": { + "@img/sharp-libvips-linux-s390x": "1.2.4" + } + }, + "node_modules/@img/sharp-linux-x64": { + "version": "0.34.5", + "resolved": "https://registry.npmjs.org/@img/sharp-linux-x64/-/sharp-linux-x64-0.34.5.tgz", + "integrity": "sha512-MEzd8HPKxVxVenwAa+JRPwEC7QFjoPWuS5NZnBt6B3pu7EG2Ge0id1oLHZpPJdn3OQK+BQDiw9zStiHBTJQQQQ==", + "cpu": [ + "x64" + ], + "license": "Apache-2.0", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": "^18.17.0 || ^20.3.0 || >=21.0.0" + }, + "funding": { + "url": "https://opencollective.com/libvips" + }, + "optionalDependencies": { + "@img/sharp-libvips-linux-x64": "1.2.4" + } + }, + "node_modules/@img/sharp-linuxmusl-arm64": { + "version": "0.34.5", + "resolved": "https://registry.npmjs.org/@img/sharp-linuxmusl-arm64/-/sharp-linuxmusl-arm64-0.34.5.tgz", + "integrity": "sha512-fprJR6GtRsMt6Kyfq44IsChVZeGN97gTD331weR1ex1c1rypDEABN6Tm2xa1wE6lYb5DdEnk03NZPqA7Id21yg==", + "cpu": [ + "arm64" + ], + "license": "Apache-2.0", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": "^18.17.0 || ^20.3.0 || >=21.0.0" + }, + "funding": { + "url": "https://opencollective.com/libvips" + }, + "optionalDependencies": { + "@img/sharp-libvips-linuxmusl-arm64": "1.2.4" + } + }, + "node_modules/@img/sharp-linuxmusl-x64": { + "version": "0.34.5", + "resolved": "https://registry.npmjs.org/@img/sharp-linuxmusl-x64/-/sharp-linuxmusl-x64-0.34.5.tgz", + "integrity": "sha512-Jg8wNT1MUzIvhBFxViqrEhWDGzqymo3sV7z7ZsaWbZNDLXRJZoRGrjulp60YYtV4wfY8VIKcWidjojlLcWrd8Q==", + "cpu": [ + "x64" + ], + "license": "Apache-2.0", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": "^18.17.0 || ^20.3.0 || >=21.0.0" + }, + "funding": { + "url": "https://opencollective.com/libvips" + }, + "optionalDependencies": { + "@img/sharp-libvips-linuxmusl-x64": "1.2.4" + } + }, + "node_modules/@img/sharp-wasm32": { + "version": "0.34.5", + "resolved": "https://registry.npmjs.org/@img/sharp-wasm32/-/sharp-wasm32-0.34.5.tgz", + "integrity": "sha512-OdWTEiVkY2PHwqkbBI8frFxQQFekHaSSkUIJkwzclWZe64O1X4UlUjqqqLaPbUpMOQk6FBu/HtlGXNblIs0huw==", + "cpu": [ + "wasm32" + ], + "license": "Apache-2.0 AND LGPL-3.0-or-later AND MIT", + "optional": true, + "dependencies": { + "@emnapi/runtime": "^1.7.0" + }, + "engines": { + "node": "^18.17.0 || ^20.3.0 || >=21.0.0" + }, + "funding": { + "url": "https://opencollective.com/libvips" + } + }, + "node_modules/@img/sharp-win32-arm64": { + "version": "0.34.5", + "resolved": "https://registry.npmjs.org/@img/sharp-win32-arm64/-/sharp-win32-arm64-0.34.5.tgz", + "integrity": "sha512-WQ3AgWCWYSb2yt+IG8mnC6Jdk9Whs7O0gxphblsLvdhSpSTtmu69ZG1Gkb6NuvxsNACwiPV6cNSZNzt0KPsw7g==", + "cpu": [ + "arm64" + ], + "license": "Apache-2.0 AND LGPL-3.0-or-later", + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": "^18.17.0 || ^20.3.0 || >=21.0.0" + }, + "funding": { + "url": "https://opencollective.com/libvips" + } + }, + "node_modules/@img/sharp-win32-ia32": { + "version": "0.34.5", + "resolved": "https://registry.npmjs.org/@img/sharp-win32-ia32/-/sharp-win32-ia32-0.34.5.tgz", + "integrity": "sha512-FV9m/7NmeCmSHDD5j4+4pNI8Cp3aW+JvLoXcTUo0IqyjSfAZJ8dIUmijx1qaJsIiU+Hosw6xM5KijAWRJCSgNg==", + "cpu": [ + "ia32" + ], + "license": "Apache-2.0 AND LGPL-3.0-or-later", + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": "^18.17.0 || ^20.3.0 || >=21.0.0" + }, + "funding": { + "url": "https://opencollective.com/libvips" + } + }, + "node_modules/@img/sharp-win32-x64": { + "version": "0.34.5", + "resolved": "https://registry.npmjs.org/@img/sharp-win32-x64/-/sharp-win32-x64-0.34.5.tgz", + "integrity": "sha512-+29YMsqY2/9eFEiW93eqWnuLcWcufowXewwSNIT6UwZdUUCrM3oFjMWH/Z6/TMmb4hlFenmfAVbpWeup2jryCw==", + "cpu": [ + "x64" + ], + "license": "Apache-2.0 AND LGPL-3.0-or-later", + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": "^18.17.0 || ^20.3.0 || >=21.0.0" + }, + "funding": { + "url": "https://opencollective.com/libvips" + } + }, + "node_modules/@jridgewell/resolve-uri": { + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/@jridgewell/resolve-uri/-/resolve-uri-3.1.2.tgz", + "integrity": "sha512-bRISgCIjP20/tbWSPWMEi54QVPRZExkuD9lJL+UIxUKtwVJA8wW1Trb1jMs1RFXo1CBTNZ/5hpC9QvmKWdopKw==", + "license": "MIT", + "engines": { + "node": ">=6.0.0" + } + }, + "node_modules/@jridgewell/sourcemap-codec": { + "version": "1.5.5", + "resolved": "https://registry.npmjs.org/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.5.5.tgz", + "integrity": "sha512-cYQ9310grqxueWbl+WuIUIaiUaDcj7WOq5fVhEljNVgRfOUhY9fy2zTvfoqWsnebh8Sl70VScFbICvJnLKB0Og==", + "license": "MIT" + }, + "node_modules/@jridgewell/trace-mapping": { + "version": "0.3.31", + "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.31.tgz", + "integrity": "sha512-zzNR+SdQSDJzc8joaeP8QQoCQr8NuYx2dIIytl1QeBEZHJ9uW6hebsrYgbz8hJwUQao3TWCMtmfV8Nu1twOLAw==", + "license": "MIT", + "dependencies": { + "@jridgewell/resolve-uri": "^3.1.0", + "@jridgewell/sourcemap-codec": "^1.4.14" + } + }, + "node_modules/@jscad/3mf-serializer": { + "version": "2.1.12", + "resolved": "https://registry.npmjs.org/@jscad/3mf-serializer/-/3mf-serializer-2.1.12.tgz", + "integrity": "sha512-+rxAIKIHCpaplupwwsdXtG1IdimPXFFB45nrjy6gdFHi36bEQW6y/RQD/ngenRiKnYSxu7/M0LatHcjve8z64A==", + "license": "MIT", + "dependencies": { + "@jscad/array-utils": "2.1.4", + "@jscad/modeling": "2.12.3", + "fflate": "0.7.3", + "onml": "1.2.0" + } + }, + "node_modules/@jscad/array-utils": { + "version": "2.1.4", + "resolved": "https://registry.npmjs.org/@jscad/array-utils/-/array-utils-2.1.4.tgz", + "integrity": "sha512-c31r4zSKsE+4Xfwk2V8monDA0hx5G89QGzaakWVUvuGNowYS9WSsYCwHiTIXodjR+HEnDu4okQ7k/whmP0Ne2g==", + "license": "MIT" + }, + "node_modules/@jscad/dxf-serializer": { + "version": "2.1.18", + "resolved": "https://registry.npmjs.org/@jscad/dxf-serializer/-/dxf-serializer-2.1.18.tgz", + "integrity": "sha512-T5Qe2jbEphcWAk7GaOY8PCMD4DPhTm6gWk/MPJCExphhnUwJqcU/1RiMb5hiD+N6hHzmlxD59I8QTjlp9LbLSA==", + "license": "MIT", + "dependencies": { + "@jscad/array-utils": "2.1.4", + "@jscad/modeling": "2.12.3" + } + }, + "node_modules/@jscad/io-utils": { + "version": "2.0.28", + "resolved": "https://registry.npmjs.org/@jscad/io-utils/-/io-utils-2.0.28.tgz", + "integrity": "sha512-spXh37wAgmwjKztoH/HANLgImcqRHX5+H/cRIxPfpqDIWvu7I5bRg2ZTwh25SYlKIzxPk4qX5Nu7Ax5+Kg+QXQ==", + "license": "MIT" + }, + "node_modules/@jscad/modeling": { + "version": "2.12.3", + "resolved": "https://registry.npmjs.org/@jscad/modeling/-/modeling-2.12.3.tgz", + "integrity": "sha512-DnAacXq3zhlYWIixGlFD7RMpgZAMuCaMZNQov0NaoFfs2GaBuTC5eqkqKcEVbhEerBmTllbjjF5IXjJMt9jcOA==", + "license": "MIT" + }, + "node_modules/@jscad/stl-serializer": { + "version": "2.1.18", + "resolved": "https://registry.npmjs.org/@jscad/stl-serializer/-/stl-serializer-2.1.18.tgz", + "integrity": "sha512-pz++TRjHI7jBPnnxQUi4B/uYUG3yCDsKlw8+xL2kumwjb+auc6Ng6Rnr/GqUTkgHrnGut08wg/8AekyWjvBwYg==", + "license": "MIT", + "dependencies": { + "@jscad/array-utils": "2.1.4", + "@jscad/modeling": "2.12.3" + } + }, + "node_modules/@jscadui/3mf-export": { + "version": "0.5.0", + "resolved": "https://registry.npmjs.org/@jscadui/3mf-export/-/3mf-export-0.5.0.tgz", + "integrity": "sha512-y5vZktqCjyi7wA38zqNlLIdZUIRZoOO9vCjLzwmL4bR0hk7B/Zm1IeffzJPFe1vFc0C1IEv3hm8caDv3doRk9g==", + "license": "MIT" + }, + "node_modules/@jsep-plugin/assignment": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/@jsep-plugin/assignment/-/assignment-1.3.0.tgz", + "integrity": "sha512-VVgV+CXrhbMI3aSusQyclHkenWSAm95WaiKrMxRFam3JSUiIaQjoMIw2sEs/OX4XifnqeQUN4DYbJjlA8EfktQ==", + "license": "MIT", + "engines": { + "node": ">= 10.16.0" + }, + "peerDependencies": { + "jsep": "^0.4.0||^1.0.0" + } + }, + "node_modules/@jsep-plugin/regex": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/@jsep-plugin/regex/-/regex-1.0.4.tgz", + "integrity": "sha512-q7qL4Mgjs1vByCaTnDFcBnV9HS7GVPJX5vyVoCgZHNSC9rjwIlmbXG5sUuorR5ndfHAIlJ8pVStxvjXHbNvtUg==", + "license": "MIT", + "engines": { + "node": ">= 10.16.0" + }, + "peerDependencies": { + "jsep": "^0.4.0||^1.0.0" + } + }, + "node_modules/@rollup/rollup-android-arm-eabi": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-android-arm-eabi/-/rollup-android-arm-eabi-4.40.1.tgz", + "integrity": "sha512-kxz0YeeCrRUHz3zyqvd7n+TVRlNyTifBsmnmNPtk3hQURUyG9eAB+usz6DAwagMusjx/zb3AjvDUvhFGDAexGw==", + "cpu": [ + "arm" + ], + "dev": true, + "optional": true, + "os": [ + "android" + ] + }, + "node_modules/@rollup/rollup-android-arm64": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-android-arm64/-/rollup-android-arm64-4.40.1.tgz", + "integrity": "sha512-PPkxTOisoNC6TpnDKatjKkjRMsdaWIhyuMkA4UsBXT9WEZY4uHezBTjs6Vl4PbqQQeu6oION1w2voYZv9yquCw==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "android" + ] + }, + "node_modules/@rollup/rollup-darwin-arm64": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-darwin-arm64/-/rollup-darwin-arm64-4.40.1.tgz", + "integrity": "sha512-VWXGISWFY18v/0JyNUy4A46KCFCb9NVsH+1100XP31lud+TzlezBbz24CYzbnA4x6w4hx+NYCXDfnvDVO6lcAA==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "darwin" + ] + }, + "node_modules/@rollup/rollup-darwin-x64": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-darwin-x64/-/rollup-darwin-x64-4.40.1.tgz", + "integrity": "sha512-nIwkXafAI1/QCS7pxSpv/ZtFW6TXcNUEHAIA9EIyw5OzxJZQ1YDrX+CL6JAIQgZ33CInl1R6mHet9Y/UZTg2Bw==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "darwin" + ] + }, + "node_modules/@rollup/rollup-freebsd-arm64": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-freebsd-arm64/-/rollup-freebsd-arm64-4.40.1.tgz", + "integrity": "sha512-BdrLJ2mHTrIYdaS2I99mriyJfGGenSaP+UwGi1kB9BLOCu9SR8ZpbkmmalKIALnRw24kM7qCN0IOm6L0S44iWw==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "freebsd" + ] + }, + "node_modules/@rollup/rollup-freebsd-x64": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-freebsd-x64/-/rollup-freebsd-x64-4.40.1.tgz", + "integrity": "sha512-VXeo/puqvCG8JBPNZXZf5Dqq7BzElNJzHRRw3vjBE27WujdzuOPecDPc/+1DcdcTptNBep3861jNq0mYkT8Z6Q==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "freebsd" + ] + }, + "node_modules/@rollup/rollup-linux-arm-gnueabihf": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm-gnueabihf/-/rollup-linux-arm-gnueabihf-4.40.1.tgz", + "integrity": "sha512-ehSKrewwsESPt1TgSE/na9nIhWCosfGSFqv7vwEtjyAqZcvbGIg4JAcV7ZEh2tfj/IlfBeZjgOXm35iOOjadcg==", + "cpu": [ + "arm" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/rollup-linux-arm-musleabihf": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm-musleabihf/-/rollup-linux-arm-musleabihf-4.40.1.tgz", + "integrity": "sha512-m39iO/aaurh5FVIu/F4/Zsl8xppd76S4qoID8E+dSRQvTyZTOI2gVk3T4oqzfq1PtcvOfAVlwLMK3KRQMaR8lg==", + "cpu": [ + "arm" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/rollup-linux-arm64-gnu": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm64-gnu/-/rollup-linux-arm64-gnu-4.40.1.tgz", + "integrity": "sha512-Y+GHnGaku4aVLSgrT0uWe2o2Rq8te9hi+MwqGF9r9ORgXhmHK5Q71N757u0F8yU1OIwUIFy6YiJtKjtyktk5hg==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/rollup-linux-arm64-musl": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm64-musl/-/rollup-linux-arm64-musl-4.40.1.tgz", + "integrity": "sha512-jEwjn3jCA+tQGswK3aEWcD09/7M5wGwc6+flhva7dsQNRZZTe30vkalgIzV4tjkopsTS9Jd7Y1Bsj6a4lzz8gQ==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/rollup-linux-loongarch64-gnu": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-loongarch64-gnu/-/rollup-linux-loongarch64-gnu-4.40.1.tgz", + "integrity": "sha512-ySyWikVhNzv+BV/IDCsrraOAZ3UaC8SZB67FZlqVwXwnFhPihOso9rPOxzZbjp81suB1O2Topw+6Ug3JNegejQ==", + "cpu": [ + "loong64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/rollup-linux-powerpc64le-gnu": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-powerpc64le-gnu/-/rollup-linux-powerpc64le-gnu-4.40.1.tgz", + "integrity": "sha512-BvvA64QxZlh7WZWqDPPdt0GH4bznuL6uOO1pmgPnnv86rpUpc8ZxgZwcEgXvo02GRIZX1hQ0j0pAnhwkhwPqWg==", + "cpu": [ + "ppc64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/rollup-linux-riscv64-gnu": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-riscv64-gnu/-/rollup-linux-riscv64-gnu-4.40.1.tgz", + "integrity": "sha512-EQSP+8+1VuSulm9RKSMKitTav89fKbHymTf25n5+Yr6gAPZxYWpj3DzAsQqoaHAk9YX2lwEyAf9S4W8F4l3VBQ==", + "cpu": [ + "riscv64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/rollup-linux-riscv64-musl": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-riscv64-musl/-/rollup-linux-riscv64-musl-4.40.1.tgz", + "integrity": "sha512-n/vQ4xRZXKuIpqukkMXZt9RWdl+2zgGNx7Uda8NtmLJ06NL8jiHxUawbwC+hdSq1rrw/9CghCpEONor+l1e2gA==", + "cpu": [ + "riscv64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/rollup-linux-s390x-gnu": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-s390x-gnu/-/rollup-linux-s390x-gnu-4.40.1.tgz", + "integrity": "sha512-h8d28xzYb98fMQKUz0w2fMc1XuGzLLjdyxVIbhbil4ELfk5/orZlSTpF/xdI9C8K0I8lCkq+1En2RJsawZekkg==", + "cpu": [ + "s390x" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/rollup-linux-x64-gnu": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-x64-gnu/-/rollup-linux-x64-gnu-4.40.1.tgz", + "integrity": "sha512-XiK5z70PEFEFqcNj3/zRSz/qX4bp4QIraTy9QjwJAb/Z8GM7kVUsD0Uk8maIPeTyPCP03ChdI+VVmJriKYbRHQ==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/rollup-linux-x64-musl": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-x64-musl/-/rollup-linux-x64-musl-4.40.1.tgz", + "integrity": "sha512-2BRORitq5rQ4Da9blVovzNCMaUlyKrzMSvkVR0D4qPuOy/+pMCrh1d7o01RATwVy+6Fa1WBw+da7QPeLWU/1mQ==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/rollup-win32-arm64-msvc": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-arm64-msvc/-/rollup-win32-arm64-msvc-4.40.1.tgz", + "integrity": "sha512-b2bcNm9Kbde03H+q+Jjw9tSfhYkzrDUf2d5MAd1bOJuVplXvFhWz7tRtWvD8/ORZi7qSCy0idW6tf2HgxSXQSg==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "win32" + ] + }, + "node_modules/@rollup/rollup-win32-ia32-msvc": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-ia32-msvc/-/rollup-win32-ia32-msvc-4.40.1.tgz", + "integrity": "sha512-DfcogW8N7Zg7llVEfpqWMZcaErKfsj9VvmfSyRjCyo4BI3wPEfrzTtJkZG6gKP/Z92wFm6rz2aDO7/JfiR/whA==", + "cpu": [ + "ia32" + ], + "dev": true, + "optional": true, + "os": [ + "win32" + ] + }, + "node_modules/@rollup/rollup-win32-x64-msvc": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-x64-msvc/-/rollup-win32-x64-msvc-4.40.1.tgz", + "integrity": "sha512-ECyOuDeH3C1I8jH2MK1RtBJW+YPMvSfT0a5NN0nHfQYnDSJ6tUiZH3gzwVP5/Kfh/+Tt7tpWVF9LXNTnhTJ3kA==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "win32" + ] + }, + "node_modules/@tweenjs/tween.js": { + "version": "23.1.3", + "resolved": "https://registry.npmjs.org/@tweenjs/tween.js/-/tween.js-23.1.3.tgz", + "integrity": "sha512-vJmvvwFxYuGnF2axRtPYocag6Clbb5YS7kLL+SO/TeVFzHqDIWrNKYtcsPMibjDx9O+bu+psAy9NKfWklassUA==", + "dev": true, + "license": "MIT" + }, + "node_modules/@types/estree": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/@types/estree/-/estree-1.0.7.tgz", + "integrity": "sha512-w28IoSUCJpidD/TGviZwwMJckNESJZXFu7NBZ5YJ4mEUnNraUn9Pm8HSZm/jDF1pDWYKspWE7oVphigUPRakIQ==", + "dev": true + }, + "node_modules/@types/ndarray": { + "version": "1.0.14", + "resolved": "https://registry.npmjs.org/@types/ndarray/-/ndarray-1.0.14.tgz", + "integrity": "sha512-oANmFZMnFQvb219SSBIhI1Ih/r4CvHDOzkWyJS/XRqkMrGH5/kaPSA1hQhdIBzouaE+5KpE/f5ylI9cujmckQg==", + "license": "MIT" + }, + "node_modules/@types/stats.js": { + "version": "0.17.3", + "resolved": "https://registry.npmjs.org/@types/stats.js/-/stats.js-0.17.3.tgz", + "integrity": "sha512-pXNfAD3KHOdif9EQXZ9deK82HVNaXP5ZIF5RP2QG6OQFNTaY2YIetfrE9t528vEreGQvEPRDDc8muaoYeK0SxQ==", + "dev": true, + "license": "MIT" + }, + "node_modules/@types/three": { + "version": "0.182.0", + "resolved": "https://registry.npmjs.org/@types/three/-/three-0.182.0.tgz", + "integrity": "sha512-WByN9V3Sbwbe2OkWuSGyoqQO8Du6yhYaXtXLoA5FkKTUJorZ+yOHBZ35zUUPQXlAKABZmbYp5oAqpA4RBjtJ/Q==", + "dev": true, + "license": "MIT", + "dependencies": { + "@dimforge/rapier3d-compat": "~0.12.0", + "@tweenjs/tween.js": "~23.1.3", + "@types/stats.js": "*", + "@types/webxr": ">=0.5.17", + "@webgpu/types": "*", + "fflate": "~0.8.2", + "meshoptimizer": "~0.22.0" + } + }, + "node_modules/@types/three/node_modules/fflate": { + "version": "0.8.2", + "resolved": "https://registry.npmjs.org/fflate/-/fflate-0.8.2.tgz", + "integrity": "sha512-cPJU47OaAoCbg0pBvzsgpTPhmhqI5eJjh/JIu8tPj5q+T7iLvW/JAYUqmE7KOB4R1ZyEhzBaIQpQpardBF5z8A==", + "dev": true, + "license": "MIT" + }, + "node_modules/@types/webxr": { + "version": "0.5.22", + "resolved": "https://registry.npmjs.org/@types/webxr/-/webxr-0.5.22.tgz", + "integrity": "sha512-Vr6Stjv5jPRqH690f5I5GLjVk8GSsoQSYJ2FVd/3jJF7KaqfwPi3ehfBS96mlQ2kPCwZaX6U0rG2+NGHBKkA/A==", + "dev": true, + "license": "MIT" + }, + "node_modules/@webgpu/types": { + "version": "0.1.60", + "resolved": "https://registry.npmjs.org/@webgpu/types/-/types-0.1.60.tgz", + "integrity": "sha512-8B/tdfRFKdrnejqmvq95ogp8tf52oZ51p3f4QD5m5Paey/qlX4Rhhy5Y8tgFMi7Ms70HzcMMw3EQjH/jdhTwlA==", + "dev": true, + "license": "BSD-3-Clause" + }, + "node_modules/bindings": { + "version": "1.5.0", + "resolved": "https://registry.npmjs.org/bindings/-/bindings-1.5.0.tgz", + "integrity": "sha512-p2q/t/mhvuOj/UeLlV6566GD/guowlr0hHxClI0W9m7MWYkL1F0hLo+0Aexs9HSPCtR1SXQ0TD3MMKrXZajbiQ==", + "license": "MIT", + "optional": true, + "dependencies": { + "file-uri-to-path": "1.0.0" + } + }, + "node_modules/commander": { + "version": "13.1.0", + "resolved": "https://registry.npmjs.org/commander/-/commander-13.1.0.tgz", + "integrity": "sha512-/rFeCpNJQbhSZjGVwO9RFV3xPqbnERS8MmIQzCtD/zl6gpJuV/bMLuN92oG3F7d8oDEHHRrujSXNUr8fpjntKw==", + "license": "MIT", + "engines": { + "node": ">=18" + } + }, + "node_modules/convert-source-map": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/convert-source-map/-/convert-source-map-2.0.0.tgz", + "integrity": "sha512-Kvp459HrV2FEJ1CAsi1Ku+MY3kasH19TFykTz2xWmMeq6bk2NU3XXvfJ+Q61m0xktWwt+1HSYf3JZsTms3aRJg==", + "license": "MIT" + }, + "node_modules/core-js": { + "version": "3.47.0", + "resolved": "https://registry.npmjs.org/core-js/-/core-js-3.47.0.tgz", + "integrity": "sha512-c3Q2VVkGAUyupsjRnaNX6u8Dq2vAdzm9iuPj5FW0fRxzlxgq9Q39MDq10IvmQSpLgHQNyQzQmOo6bgGHmH3NNg==", + "hasInstallScript": true, + "license": "MIT", + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/core-js" + } + }, + "node_modules/cwise-compiler": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/cwise-compiler/-/cwise-compiler-1.1.3.tgz", + "integrity": "sha512-WXlK/m+Di8DMMcCjcWr4i+XzcQra9eCdXIJrgh4TUgh0pIS/yJduLxS9JgefsHJ/YVLdgPtXm9r62W92MvanEQ==", + "license": "MIT", + "dependencies": { + "uniq": "^1.0.0" + } + }, + "node_modules/detect-libc": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/detect-libc/-/detect-libc-2.1.2.tgz", + "integrity": "sha512-Btj2BOOO83o3WyH59e8MgXsxEQVcarkUOpEYrubB0urwnN10yQ364rsiByU11nZlqWYZm05i/of7io4mzihBtQ==", + "license": "Apache-2.0", + "engines": { + "node": ">=8" + } + }, + "node_modules/esbuild": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/esbuild/-/esbuild-0.25.3.tgz", + "integrity": "sha512-qKA6Pvai73+M2FtftpNKRxJ78GIjmFXFxd/1DVBqGo/qNhLSfv+G12n9pNoWdytJC8U00TrViOwpjT0zgqQS8Q==", + "dev": true, + "hasInstallScript": true, + "bin": { + "esbuild": "bin/esbuild" + }, + "engines": { + "node": ">=18" + }, + "optionalDependencies": { + "@esbuild/aix-ppc64": "0.25.3", + "@esbuild/android-arm": "0.25.3", + "@esbuild/android-arm64": "0.25.3", + "@esbuild/android-x64": "0.25.3", + "@esbuild/darwin-arm64": "0.25.3", + "@esbuild/darwin-x64": "0.25.3", + "@esbuild/freebsd-arm64": "0.25.3", + "@esbuild/freebsd-x64": "0.25.3", + "@esbuild/linux-arm": "0.25.3", + "@esbuild/linux-arm64": "0.25.3", + "@esbuild/linux-ia32": "0.25.3", + "@esbuild/linux-loong64": "0.25.3", + "@esbuild/linux-mips64el": "0.25.3", + "@esbuild/linux-ppc64": "0.25.3", + "@esbuild/linux-riscv64": "0.25.3", + "@esbuild/linux-s390x": "0.25.3", + "@esbuild/linux-x64": "0.25.3", + "@esbuild/netbsd-arm64": "0.25.3", + "@esbuild/netbsd-x64": "0.25.3", + "@esbuild/openbsd-arm64": "0.25.3", + "@esbuild/openbsd-x64": "0.25.3", + "@esbuild/sunos-x64": "0.25.3", + "@esbuild/win32-arm64": "0.25.3", + "@esbuild/win32-ia32": "0.25.3", + "@esbuild/win32-x64": "0.25.3" + } + }, + "node_modules/esbuild-plugin-text-replace": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/esbuild-plugin-text-replace/-/esbuild-plugin-text-replace-1.3.0.tgz", + "integrity": "sha512-RWB/bbdP0xDHBOtA0st4CAE6UZtky76aCB7Shw5r350JY403lfvrj2UMkInUB346tMtFWXKWXNf4gqNM+WbXag==", + "license": "BSD-2-Clause", + "dependencies": { + "ts-replace-all": "^1.0.0" + }, + "engines": { + "node": ">=10.1.0" + } + }, + "node_modules/esbuild-wasm": { + "version": "0.25.12", + "resolved": "https://registry.npmjs.org/esbuild-wasm/-/esbuild-wasm-0.25.12.tgz", + "integrity": "sha512-rZqkjL3Y6FwLpSHzLnaEy8Ps6veCNo1kZa9EOfJvmWtBq5dJH4iVjfmOO6Mlkv9B0tt9WFPFmb/VxlgJOnueNg==", + "license": "MIT", + "bin": { + "esbuild": "bin/esbuild" + }, + "engines": { + "node": ">=18" + } + }, + "node_modules/fdir": { + "version": "6.4.4", + "resolved": "https://registry.npmjs.org/fdir/-/fdir-6.4.4.tgz", + "integrity": "sha512-1NZP+GK4GfuAv3PqKvxQRDMjdSRZjnkq7KfhlNrCNNlZ0ygQFpebfrnfnq/W7fpUnAv9aGWmY1zKx7FYL3gwhg==", + "dev": true, + "peerDependencies": { + "picomatch": "^3 || ^4" + }, + "peerDependenciesMeta": { + "picomatch": { + "optional": true + } + } + }, + "node_modules/fflate": { + "version": "0.7.3", + "resolved": "https://registry.npmjs.org/fflate/-/fflate-0.7.3.tgz", + "integrity": "sha512-0Zz1jOzJWERhyhsimS54VTqOteCNwRtIlh8isdL0AXLo0g7xNTfTL7oWrkmCnPhZGocKIkWHBistBrrpoNH3aw==", + "license": "MIT" + }, + "node_modules/file-uri-to-path": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/file-uri-to-path/-/file-uri-to-path-1.0.0.tgz", + "integrity": "sha512-0Zt+s3L7Vf1biwWZ29aARiVYLx7iMGnEUl9x33fbB/j3jR81u/O2LbqK+Bm1CDSNDKVtJ/YjwY7TUd5SkeLQLw==", + "license": "MIT", + "optional": true + }, + "node_modules/fsevents": { + "version": "2.3.3", + "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.3.tgz", + "integrity": "sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw==", + "dev": true, + "hasInstallScript": true, + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": "^8.16.0 || ^10.6.0 || >=11.0.0" + } + }, + "node_modules/iota-array": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/iota-array/-/iota-array-1.0.0.tgz", + "integrity": "sha512-pZ2xT+LOHckCatGQ3DcG/a+QuEqvoxqkiL7tvE8nn3uuu+f6i1TtpB5/FtWFbxUuVr5PZCx8KskuGatbJDXOWA==", + "license": "MIT" + }, + "node_modules/is-buffer": { + "version": "1.1.6", + "resolved": "https://registry.npmjs.org/is-buffer/-/is-buffer-1.1.6.tgz", + "integrity": "sha512-NcdALwpXkTm5Zvvbk7owOUSvVvBKDgKP5/ewfXEznmQFfs4ZRmanOeKBTjRVjka3QFoN6XJ+9F3USqfHqTaU5w==", + "license": "MIT" + }, + "node_modules/jsep": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/jsep/-/jsep-1.4.0.tgz", + "integrity": "sha512-B7qPcEVE3NVkmSJbaYxvv4cHkVW7DQsZz13pUMrfS8z8Q/BuShN+gcTXrUlPiGqM2/t/EEaI030bpxMqY8gMlw==", + "license": "MIT", + "engines": { + "node": ">= 10.16.0" + } + }, + "node_modules/jsonpath-plus": { + "version": "10.1.0", + "resolved": "https://registry.npmjs.org/jsonpath-plus/-/jsonpath-plus-10.1.0.tgz", + "integrity": "sha512-gHfV1IYqH8uJHYVTs8BJX1XKy2/rR93+f8QQi0xhx95aCiXn1ettYAd5T+7FU6wfqyDoX/wy0pm/fL3jOKJ9Lg==", + "license": "MIT", + "dependencies": { + "@jsep-plugin/assignment": "^1.2.1", + "@jsep-plugin/regex": "^1.0.3", + "jsep": "^1.3.9" + }, + "bin": { + "jsonpath": "bin/jsonpath-cli.js", + "jsonpath-plus": "bin/jsonpath-cli.js" + }, + "engines": { + "node": ">=18.0.0" + } + }, + "node_modules/ktx-parse": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/ktx-parse/-/ktx-parse-1.1.0.tgz", + "integrity": "sha512-mKp3y+FaYgR7mXWAbyyzpa/r1zDWeaunH+INJO4fou3hb45XuNSwar+7llrRyvpMWafxSIi99RNFJ05MHedaJQ==", + "license": "MIT" + }, + "node_modules/manifold-3d": { + "version": "3.3.2", + "resolved": "https://registry.npmjs.org/manifold-3d/-/manifold-3d-3.3.2.tgz", + "integrity": "sha512-Xx+S7kkbqlZxSPfBKH5yVKDO6k/eW7JRvnG1dKCFO0D4zjifOV5GM18TR0sREDcbKAzglHZ5OoxxpZRkxg6U5A==", + "license": "Apache-2.0", + "dependencies": { + "@gltf-transform/core": "^4.2.0", + "@gltf-transform/extensions": "^4.2.0", + "@gltf-transform/functions": "^4.2.0", + "@jridgewell/trace-mapping": "^0.3.31", + "@jscadui/3mf-export": "^0.5.0", + "commander": "^13.1.0", + "convert-source-map": "^2.0.0", + "esbuild-plugin-text-replace": "^1.3.0", + "esbuild-wasm": "^0.25.11", + "fflate": "^0.8.0" + }, + "bin": { + "manifold-cad": "bin/manifold-cad" + } + }, + "node_modules/manifold-3d/node_modules/fflate": { + "version": "0.8.2", + "resolved": "https://registry.npmjs.org/fflate/-/fflate-0.8.2.tgz", + "integrity": "sha512-cPJU47OaAoCbg0pBvzsgpTPhmhqI5eJjh/JIu8tPj5q+T7iLvW/JAYUqmE7KOB4R1ZyEhzBaIQpQpardBF5z8A==", + "license": "MIT" + }, + "node_modules/meshoptimizer": { + "version": "0.22.0", + "resolved": "https://registry.npmjs.org/meshoptimizer/-/meshoptimizer-0.22.0.tgz", + "integrity": "sha512-IebiK79sqIy+E4EgOr+CAw+Ke8hAspXKzBd0JdgEmPHiAwmvEj2S4h1rfvo+o/BnfEYd/jAOg5IeeIjzlzSnDg==", + "dev": true + }, + "node_modules/nan": { + "version": "2.24.0", + "resolved": "https://registry.npmjs.org/nan/-/nan-2.24.0.tgz", + "integrity": "sha512-Vpf9qnVW1RaDkoNKFUvfxqAbtI8ncb8OJlqZ9wwpXzWPEsvsB1nvdUi6oYrHIkQ1Y/tMDnr1h4nczS0VB9Xykg==", + "license": "MIT", + "optional": true + }, + "node_modules/nanoid": { + "version": "3.3.11", + "resolved": "https://registry.npmjs.org/nanoid/-/nanoid-3.3.11.tgz", + "integrity": "sha512-N8SpfPUnUp1bK+PMYW8qSWdl9U+wwNWI4QKxOYDy9JAro3WMX7p2OeVRF9v+347pnakNevPmiHhNmZ2HbFA76w==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/ai" + } + ], + "bin": { + "nanoid": "bin/nanoid.cjs" + }, + "engines": { + "node": "^10 || ^12 || ^13.7 || ^14 || >=15.0.1" + } + }, + "node_modules/ndarray": { + "version": "1.0.19", + "resolved": "https://registry.npmjs.org/ndarray/-/ndarray-1.0.19.tgz", + "integrity": "sha512-B4JHA4vdyZU30ELBw3g7/p9bZupyew5a7tX1Y/gGeF2hafrPaQZhgrGQfsvgfYbgdFZjYwuEcnaobeM/WMW+HQ==", + "license": "MIT", + "dependencies": { + "iota-array": "^1.0.0", + "is-buffer": "^1.0.2" + } + }, + "node_modules/ndarray-lanczos": { + "version": "0.3.0", + "resolved": "https://registry.npmjs.org/ndarray-lanczos/-/ndarray-lanczos-0.3.0.tgz", + "integrity": "sha512-5kBmmG3Zvyj77qxIAC4QFLKuYdDIBJwCG+DukT6jQHNa1Ft74/hPH1z5mbQXeHBt8yvGPBGVrr3wEOdJPYYZYg==", + "license": "MIT", + "dependencies": { + "@types/ndarray": "^1.0.11", + "ndarray": "^1.0.19" + } + }, + "node_modules/ndarray-ops": { + "version": "1.2.2", + "resolved": "https://registry.npmjs.org/ndarray-ops/-/ndarray-ops-1.2.2.tgz", + "integrity": "sha512-BppWAFRjMYF7N/r6Ie51q6D4fs0iiGmeXIACKY66fLpnwIui3Wc3CXiD/30mgLbDjPpSLrsqcp3Z62+IcHZsDw==", + "license": "MIT", + "dependencies": { + "cwise-compiler": "^1.0.0" + } + }, + "node_modules/ndarray-pixels": { + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/ndarray-pixels/-/ndarray-pixels-5.0.1.tgz", + "integrity": "sha512-IBtrpefpqlI8SPDCGjXk4v5NV5z7r3JSuCbfuEEXaM0vrOJtNGgYUa4C3Lt5H+qWdYF4BCPVFsnXhNC7QvZwkw==", + "license": "MIT", + "dependencies": { + "@types/ndarray": "^1.0.14", + "ndarray": "^1.0.19", + "ndarray-ops": "^1.2.2", + "sharp": "^0.34.0" + } + }, + "node_modules/onml": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/onml/-/onml-1.2.0.tgz", + "integrity": "sha512-olqYAg18XoHAhm7tK9DdBCOVdts70DGmMgCNLOWyqZokht2utgGSKBB4JHi6pBZpmioAhcYlxK+91L3tsrz+GA==", + "license": "MIT", + "dependencies": { + "sax": "^1.2.1" + } + }, + "node_modules/picocolors": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.1.1.tgz", + "integrity": "sha512-xceH2snhtb5M9liqDsmEw56le376mTZkEX/jEb/RxNFyegNul7eNslCXP9FDj/Lcu0X8KEyMceP2ntpaHrDEVA==", + "dev": true + }, + "node_modules/picomatch": { + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.2.tgz", + "integrity": "sha512-M7BAV6Rlcy5u+m6oPhAPFgJTzAioX/6B0DxyvDlo9l8+T3nLKbrczg2WLUyzd45L8RqfUMyGPzekbMvX2Ldkwg==", + "dev": true, + "engines": { + "node": ">=12" + }, + "funding": { + "url": "https://github.com/sponsors/jonschlinkert" + } + }, + "node_modules/postcss": { + "version": "8.5.3", + "resolved": "https://registry.npmjs.org/postcss/-/postcss-8.5.3.tgz", + "integrity": "sha512-dle9A3yYxlBSrt8Fu+IpjGT8SY8hN0mlaA6GY8t0P5PjIOZemULz/E2Bnm/2dcUOena75OTNkHI76uZBNUUq3A==", + "dev": true, + "funding": [ + { + "type": "opencollective", + "url": "https://opencollective.com/postcss/" + }, + { + "type": "tidelift", + "url": "https://tidelift.com/funding/github/npm/postcss" + }, + { + "type": "github", + "url": "https://github.com/sponsors/ai" + } + ], + "dependencies": { + "nanoid": "^3.3.8", + "picocolors": "^1.1.1", + "source-map-js": "^1.2.1" + }, + "engines": { + "node": "^10 || ^12 || >=14" + } + }, + "node_modules/property-graph": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/property-graph/-/property-graph-4.0.0.tgz", + "integrity": "sha512-I0hojAJfTbSCZy3y6xyK29eayxo14v1bj1VPiDkHjTdz33SV6RdfMz2AHnf4ai62Vng2mN5GkaKahkooBIo9gA==", + "license": "MIT" + }, + "node_modules/rollup": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/rollup/-/rollup-4.40.1.tgz", + "integrity": "sha512-C5VvvgCCyfyotVITIAv+4efVytl5F7wt+/I2i9q9GZcEXW9BP52YYOXC58igUi+LFZVHukErIIqQSWwv/M3WRw==", + "dev": true, + "dependencies": { + "@types/estree": "1.0.7" + }, + "bin": { + "rollup": "dist/bin/rollup" + }, + "engines": { + "node": ">=18.0.0", + "npm": ">=8.0.0" + }, + "optionalDependencies": { + "@rollup/rollup-android-arm-eabi": "4.40.1", + "@rollup/rollup-android-arm64": "4.40.1", + "@rollup/rollup-darwin-arm64": "4.40.1", + "@rollup/rollup-darwin-x64": "4.40.1", + "@rollup/rollup-freebsd-arm64": "4.40.1", + "@rollup/rollup-freebsd-x64": "4.40.1", + "@rollup/rollup-linux-arm-gnueabihf": "4.40.1", + "@rollup/rollup-linux-arm-musleabihf": "4.40.1", + "@rollup/rollup-linux-arm64-gnu": "4.40.1", + "@rollup/rollup-linux-arm64-musl": "4.40.1", + "@rollup/rollup-linux-loongarch64-gnu": "4.40.1", + "@rollup/rollup-linux-powerpc64le-gnu": "4.40.1", + "@rollup/rollup-linux-riscv64-gnu": "4.40.1", + "@rollup/rollup-linux-riscv64-musl": "4.40.1", + "@rollup/rollup-linux-s390x-gnu": "4.40.1", + "@rollup/rollup-linux-x64-gnu": "4.40.1", + "@rollup/rollup-linux-x64-musl": "4.40.1", + "@rollup/rollup-win32-arm64-msvc": "4.40.1", + "@rollup/rollup-win32-ia32-msvc": "4.40.1", + "@rollup/rollup-win32-x64-msvc": "4.40.1", + "fsevents": "~2.3.2" + } + }, + "node_modules/rxjs": { + "version": "7.5.5", + "resolved": "https://registry.npmjs.org/rxjs/-/rxjs-7.5.5.tgz", + "integrity": "sha512-sy+H0pQofO95VDmFLzyaw9xNJU4KTRSwQIGM6+iG3SypAtCiLDzpeG8sJrNCWn2Up9km+KhkvTdbkrdy+yzZdw==", + "license": "Apache-2.0", + "dependencies": { + "tslib": "^2.1.0" + } + }, + "node_modules/sax": { + "version": "1.4.3", + "resolved": "https://registry.npmjs.org/sax/-/sax-1.4.3.tgz", + "integrity": "sha512-yqYn1JhPczigF94DMS+shiDMjDowYO6y9+wB/4WgO0Y19jWYk0lQ4tuG5KI7kj4FTp1wxPj5IFfcrz/s1c3jjQ==", + "license": "BlueOak-1.0.0" + }, + "node_modules/semver": { + "version": "7.7.3", + "resolved": "https://registry.npmjs.org/semver/-/semver-7.7.3.tgz", + "integrity": "sha512-SdsKMrI9TdgjdweUSR9MweHA4EJ8YxHn8DFaDisvhVlUOe4BF1tLD7GAj0lIqWVl+dPb/rExr0Btby5loQm20Q==", + "license": "ISC", + "bin": { + "semver": "bin/semver.js" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/sharp": { + "version": "0.34.5", + "resolved": "https://registry.npmjs.org/sharp/-/sharp-0.34.5.tgz", + "integrity": "sha512-Ou9I5Ft9WNcCbXrU9cMgPBcCK8LiwLqcbywW3t4oDV37n1pzpuNLsYiAV8eODnjbtQlSDwZ2cUEeQz4E54Hltg==", + "hasInstallScript": true, + "license": "Apache-2.0", + "dependencies": { + "@img/colour": "^1.0.0", + "detect-libc": "^2.1.2", + "semver": "^7.7.3" + }, + "engines": { + "node": "^18.17.0 || ^20.3.0 || >=21.0.0" + }, + "funding": { + "url": "https://opencollective.com/libvips" + }, + "optionalDependencies": { + "@img/sharp-darwin-arm64": "0.34.5", + "@img/sharp-darwin-x64": "0.34.5", + "@img/sharp-libvips-darwin-arm64": "1.2.4", + "@img/sharp-libvips-darwin-x64": "1.2.4", + "@img/sharp-libvips-linux-arm": "1.2.4", + "@img/sharp-libvips-linux-arm64": "1.2.4", + "@img/sharp-libvips-linux-ppc64": "1.2.4", + "@img/sharp-libvips-linux-riscv64": "1.2.4", + "@img/sharp-libvips-linux-s390x": "1.2.4", + "@img/sharp-libvips-linux-x64": "1.2.4", + "@img/sharp-libvips-linuxmusl-arm64": "1.2.4", + "@img/sharp-libvips-linuxmusl-x64": "1.2.4", + "@img/sharp-linux-arm": "0.34.5", + "@img/sharp-linux-arm64": "0.34.5", + "@img/sharp-linux-ppc64": "0.34.5", + "@img/sharp-linux-riscv64": "0.34.5", + "@img/sharp-linux-s390x": "0.34.5", + "@img/sharp-linux-x64": "0.34.5", + "@img/sharp-linuxmusl-arm64": "0.34.5", + "@img/sharp-linuxmusl-x64": "0.34.5", + "@img/sharp-wasm32": "0.34.5", + "@img/sharp-win32-arm64": "0.34.5", + "@img/sharp-win32-ia32": "0.34.5", + "@img/sharp-win32-x64": "0.34.5" + } + }, + "node_modules/source-map-js": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/source-map-js/-/source-map-js-1.2.1.tgz", + "integrity": "sha512-UXWMKhLOwVKb728IUtQPXxfYU+usdybtUrK/8uGE8CQMvrhOpwvzDBwj0QhSL7MQc7vIsISBG8VQ8+IDQxpfQA==", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/three": { + "version": "0.182.0", + "resolved": "https://registry.npmjs.org/three/-/three-0.182.0.tgz", + "integrity": "sha512-GbHabT+Irv+ihI1/f5kIIsZ+Ef9Sl5A1Y7imvS5RQjWgtTPfPnZ43JmlYI7NtCRDK9zir20lQpfg8/9Yd02OvQ==", + "license": "MIT" + }, + "node_modules/tinyglobby": { + "version": "0.2.13", + "resolved": "https://registry.npmjs.org/tinyglobby/-/tinyglobby-0.2.13.tgz", + "integrity": "sha512-mEwzpUgrLySlveBwEVDMKk5B57bhLPYovRfPAXD5gA/98Opn0rCDj3GtLwFvCvH5RK9uPCExUROW5NjDwvqkxw==", + "dev": true, + "dependencies": { + "fdir": "^6.4.4", + "picomatch": "^4.0.2" + }, + "engines": { + "node": ">=12.0.0" + }, + "funding": { + "url": "https://github.com/sponsors/SuperchupuDev" + } + }, + "node_modules/ts-replace-all": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/ts-replace-all/-/ts-replace-all-1.0.0.tgz", + "integrity": "sha512-6uBtdkw3jHXkPtx/e9xB/5vcngMm17CyJYsS2YZeQ+9FdRnt6Ev5g931Sg2p+dxbtMGoCm13m3ax/obicTZIkQ==", + "license": "MIT", + "dependencies": { + "core-js": "^3.4.1" + } + }, + "node_modules/tslib": { + "version": "2.8.1", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.8.1.tgz", + "integrity": "sha512-oJFu94HQb+KVduSUQL7wnpmqnfmLsOA/nAh6b6EH0wCEoK0/mPeXU6c3wKDV83MkOuHPRHtSXKKU99IBazS/2w==", + "license": "0BSD" + }, + "node_modules/typescript": { + "version": "5.8.3", + "resolved": "https://registry.npmjs.org/typescript/-/typescript-5.8.3.tgz", + "integrity": "sha512-p1diW6TqL9L07nNxvRMM7hMMw4c5XOo/1ibL4aAIGmSAt9slTE1Xgw5KWuof2uTOvCg9BY7ZRi+GaF+7sfgPeQ==", + "dev": true, + "bin": { + "tsc": "bin/tsc", + "tsserver": "bin/tsserver" + }, + "engines": { + "node": ">=14.17" + } + }, + "node_modules/uniq": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/uniq/-/uniq-1.0.1.tgz", + "integrity": "sha512-Gw+zz50YNKPDKXs+9d+aKAjVwpjNwqzvNpLigIruT4HA9lMZNdMqs9x07kKHB/L9WRzqp4+DlTU5s4wG2esdoA==", + "license": "MIT" + }, + "node_modules/verb-nurbs-web": { + "version": "2.1.3", + "resolved": "https://registry.npmjs.org/verb-nurbs-web/-/verb-nurbs-web-2.1.3.tgz", + "integrity": "sha512-2PvI2bx7dn0r3kWtk+JuDIDZ+p7I5Piu8y6/ZNhUVpilOyHKK1nNzLHtgown+dFOmBnKnuAKIMh1xn/5kzrxZA==", + "license": "MIT", + "optionalDependencies": { + "webworker-threads": "^0.7.12" + } + }, + "node_modules/vite": { + "version": "6.3.4", + "resolved": "https://registry.npmjs.org/vite/-/vite-6.3.4.tgz", + "integrity": "sha512-BiReIiMS2fyFqbqNT/Qqt4CVITDU9M9vE+DKcVAsB+ZV0wvTKd+3hMbkpxz1b+NmEDMegpVbisKiAZOnvO92Sw==", + "dev": true, + "dependencies": { + "esbuild": "^0.25.0", + "fdir": "^6.4.4", + "picomatch": "^4.0.2", + "postcss": "^8.5.3", + "rollup": "^4.34.9", + "tinyglobby": "^0.2.13" + }, + "bin": { + "vite": "bin/vite.js" + }, + "engines": { + "node": "^18.0.0 || ^20.0.0 || >=22.0.0" + }, + "funding": { + "url": "https://github.com/vitejs/vite?sponsor=1" + }, + "optionalDependencies": { + "fsevents": "~2.3.3" + }, + "peerDependencies": { + "@types/node": "^18.0.0 || ^20.0.0 || >=22.0.0", + "jiti": ">=1.21.0", + "less": "*", + "lightningcss": "^1.21.0", + "sass": "*", + "sass-embedded": "*", + "stylus": "*", + "sugarss": "*", + "terser": "^5.16.0", + "tsx": "^4.8.1", + "yaml": "^2.4.2" + }, + "peerDependenciesMeta": { + "@types/node": { + "optional": true + }, + "jiti": { + "optional": true + }, + "less": { + "optional": true + }, + "lightningcss": { + "optional": true + }, + "sass": { + "optional": true + }, + "sass-embedded": { + "optional": true + }, + "stylus": { + "optional": true + }, + "sugarss": { + "optional": true + }, + "terser": { + "optional": true + }, + "tsx": { + "optional": true + }, + "yaml": { + "optional": true + } + } + }, + "node_modules/webworker-threads": { + "version": "0.7.17", + "resolved": "https://registry.npmjs.org/webworker-threads/-/webworker-threads-0.7.17.tgz", + "integrity": "sha512-Y2w2aXBbDLk9IzTEb9u+MsODC3s4YlGI7g4h0t+1OAwIO8yBI9rQL35ZYlyayiCuWu1dZMH/P7kGU8OwW7YsyA==", + "hasInstallScript": true, + "license": "(MIT AND Apache-2.0)", + "optional": true, + "dependencies": { + "bindings": "^1.3.0", + "nan": "^2.11.0" + }, + "engines": { + "node": ">= 0.10.16" + } + } + }, + "dependencies": { + "@bitbybit-dev/base": { + "version": "0.21.0", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/base/-/base-0.21.0.tgz", + "integrity": "sha512-dNfsf2tu3/QUD1mvZzzTze8RwHyK2Jrt+Ary8EDKdNKMw+abtCpQYNerdrg0ZQPxvwu/OOQz6N1xCsCwsPkQJg==" + }, + "@bitbybit-dev/core": { + "version": "0.21.0", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/core/-/core-0.21.0.tgz", + "integrity": "sha512-IbeQ8ROreu0/RkkngUE+Eb19ecvqKOWhGefXvIqQmplxt3zEc0FI4Kw8wR3vYl2XMannuVt1xAIYtqqH0tjBzg==", + "requires": { + "@bitbybit-dev/base": "0.21.0", + "@bitbybit-dev/jscad-worker": "0.21.0", + "@bitbybit-dev/manifold-worker": "0.21.0", + "@bitbybit-dev/occt-worker": "0.21.0", + "jsonpath-plus": "10.1.0", + "rxjs": "7.5.5", + "verb-nurbs-web": "2.1.3" + } + }, + "@bitbybit-dev/jscad": { + "version": "0.21.0", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/jscad/-/jscad-0.21.0.tgz", + "integrity": "sha512-Q7eE2ILrJRstW4L1711aJZdpwPf1kuhZJqB+KLkkBLsneRsGsh82lBcCbVYAOMuF/q8Lnd4JHxPiIG/m+LYmPQ==", + "requires": { + "@bitbybit-dev/base": "0.21.0", + "@jscad/3mf-serializer": "2.1.12", + "@jscad/dxf-serializer": "2.1.18", + "@jscad/io-utils": "2.0.28", + "@jscad/modeling": "2.12.3", + "@jscad/stl-serializer": "2.1.18" + } + }, + "@bitbybit-dev/jscad-worker": { + "version": "0.21.0", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/jscad-worker/-/jscad-worker-0.21.0.tgz", + "integrity": "sha512-nIvd7GH5Gg51u6PmFXOADXVYTIvixTkNf0YapS1uix7D2JS9Mx10Z4wHAeRKzvJxUAAbEPPRFNkakE22HFGtLQ==", + "requires": { + "@bitbybit-dev/jscad": "0.21.0", + "rxjs": "7.5.5" + } + }, + "@bitbybit-dev/manifold": { + "version": "0.21.0", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/manifold/-/manifold-0.21.0.tgz", + "integrity": "sha512-DPpwK9ESB+auDeAbzXcfWRVEzWoMDkpkjc+/uwh+zuSiHSx92PSkzx1/LVTbQCsK+aOfOOy03HQCF5Bu2KQYtw==", + "requires": { + "@bitbybit-dev/base": "0.21.0", + "manifold-3d": "3.3.2" + } + }, + "@bitbybit-dev/manifold-worker": { + "version": "0.21.0", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/manifold-worker/-/manifold-worker-0.21.0.tgz", + "integrity": "sha512-6Cqv3BP+uI8mHKHI6Jx9TzCxRg1/kMHhCe18+B3KD/rTl9B5mnScCKRBnDansR3bH7aYZGnIw9PmiFnWLkQWEQ==", + "requires": { + "@bitbybit-dev/manifold": "0.21.0", + "rxjs": "7.5.5" + } + }, + "@bitbybit-dev/occt": { + "version": "0.21.0", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/occt/-/occt-0.21.0.tgz", + "integrity": "sha512-vPu3NmF1kBZMOkOdysolGfFxEEnwdHNGORoX3eWbMWT2JL/Tag5Q2CAc5jwa2VvZnS1nE/9x+DVlFQSo8LQnIg==", + "requires": { + "@bitbybit-dev/base": "0.21.0" + } + }, + "@bitbybit-dev/occt-worker": { + "version": "0.21.0", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/occt-worker/-/occt-worker-0.21.0.tgz", + "integrity": "sha512-xG1sgo6q/RdVA8AgG72wPe4qxcQlrO1V7/Ksn6MqIhZVTsJcm5RbVYlK+nziIWhvlMc1sKE0GNQFcPdALISLuQ==", + "requires": { + "@bitbybit-dev/occt": "0.21.0", + "rxjs": "7.5.5" + } + }, + "@bitbybit-dev/threejs": { + "version": "0.21.0", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/threejs/-/threejs-0.21.0.tgz", + "integrity": "sha512-p0fHuLTjoXs3UIWoC2TFUBAhu0F4sTPU//PCvwwPLmLrbrVmpEFV61tGs0739hbU4eKS5goCTUM99RfjbRxW6A==", + "requires": { + "@bitbybit-dev/core": "0.21.0", + "three": "0.182.0" + } + }, + "@dimforge/rapier3d-compat": { + "version": "0.12.0", + "resolved": "https://registry.npmjs.org/@dimforge/rapier3d-compat/-/rapier3d-compat-0.12.0.tgz", + "integrity": "sha512-uekIGetywIgopfD97oDL5PfeezkFpNhwlzlaEYNOA0N6ghdsOvh/HYjSMek5Q2O1PYvRSDFcqFVJl4r4ZBwOow==", + "dev": true + }, + "@emnapi/runtime": { + "version": "1.8.1", + "resolved": "https://registry.npmjs.org/@emnapi/runtime/-/runtime-1.8.1.tgz", + "integrity": "sha512-mehfKSMWjjNol8659Z8KxEMrdSJDDot5SXMq00dM8BN4o+CLNXQ0xH2V7EchNHV4RmbZLmmPdEaXZc5H2FXmDg==", + "optional": true, + "requires": { + "tslib": "^2.4.0" + } + }, + "@esbuild/aix-ppc64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/aix-ppc64/-/aix-ppc64-0.25.3.tgz", + "integrity": "sha512-W8bFfPA8DowP8l//sxjJLSLkD8iEjMc7cBVyP+u4cEv9sM7mdUCkgsj+t0n/BWPFtv7WWCN5Yzj0N6FJNUUqBQ==", + "dev": true, + "optional": true + }, + "@esbuild/android-arm": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/android-arm/-/android-arm-0.25.3.tgz", + "integrity": "sha512-PuwVXbnP87Tcff5I9ngV0lmiSu40xw1At6i3GsU77U7cjDDB4s0X2cyFuBiDa1SBk9DnvWwnGvVaGBqoFWPb7A==", + "dev": true, + "optional": true + }, + "@esbuild/android-arm64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/android-arm64/-/android-arm64-0.25.3.tgz", + "integrity": "sha512-XelR6MzjlZuBM4f5z2IQHK6LkK34Cvv6Rj2EntER3lwCBFdg6h2lKbtRjpTTsdEjD/WSe1q8UyPBXP1x3i/wYQ==", + "dev": true, + "optional": true + }, + "@esbuild/android-x64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/android-x64/-/android-x64-0.25.3.tgz", + "integrity": "sha512-ogtTpYHT/g1GWS/zKM0cc/tIebFjm1F9Aw1boQ2Y0eUQ+J89d0jFY//s9ei9jVIlkYi8AfOjiixcLJSGNSOAdQ==", + "dev": true, + "optional": true + }, + "@esbuild/darwin-arm64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/darwin-arm64/-/darwin-arm64-0.25.3.tgz", + "integrity": "sha512-eESK5yfPNTqpAmDfFWNsOhmIOaQA59tAcF/EfYvo5/QWQCzXn5iUSOnqt3ra3UdzBv073ykTtmeLJZGt3HhA+w==", + "dev": true, + "optional": true + }, + "@esbuild/darwin-x64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/darwin-x64/-/darwin-x64-0.25.3.tgz", + "integrity": "sha512-Kd8glo7sIZtwOLcPbW0yLpKmBNWMANZhrC1r6K++uDR2zyzb6AeOYtI6udbtabmQpFaxJ8uduXMAo1gs5ozz8A==", + "dev": true, + "optional": true + }, + "@esbuild/freebsd-arm64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/freebsd-arm64/-/freebsd-arm64-0.25.3.tgz", + "integrity": "sha512-EJiyS70BYybOBpJth3M0KLOus0n+RRMKTYzhYhFeMwp7e/RaajXvP+BWlmEXNk6uk+KAu46j/kaQzr6au+JcIw==", + "dev": true, + "optional": true + }, + "@esbuild/freebsd-x64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/freebsd-x64/-/freebsd-x64-0.25.3.tgz", + "integrity": "sha512-Q+wSjaLpGxYf7zC0kL0nDlhsfuFkoN+EXrx2KSB33RhinWzejOd6AvgmP5JbkgXKmjhmpfgKZq24pneodYqE8Q==", + "dev": true, + "optional": true + }, + "@esbuild/linux-arm": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/linux-arm/-/linux-arm-0.25.3.tgz", + "integrity": "sha512-dUOVmAUzuHy2ZOKIHIKHCm58HKzFqd+puLaS424h6I85GlSDRZIA5ycBixb3mFgM0Jdh+ZOSB6KptX30DD8YOQ==", + "dev": true, + "optional": true + }, + "@esbuild/linux-arm64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/linux-arm64/-/linux-arm64-0.25.3.tgz", + "integrity": "sha512-xCUgnNYhRD5bb1C1nqrDV1PfkwgbswTTBRbAd8aH5PhYzikdf/ddtsYyMXFfGSsb/6t6QaPSzxtbfAZr9uox4A==", + "dev": true, + "optional": true + }, + "@esbuild/linux-ia32": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/linux-ia32/-/linux-ia32-0.25.3.tgz", + "integrity": "sha512-yplPOpczHOO4jTYKmuYuANI3WhvIPSVANGcNUeMlxH4twz/TeXuzEP41tGKNGWJjuMhotpGabeFYGAOU2ummBw==", + "dev": true, + "optional": true + }, + "@esbuild/linux-loong64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/linux-loong64/-/linux-loong64-0.25.3.tgz", + "integrity": "sha512-P4BLP5/fjyihmXCELRGrLd793q/lBtKMQl8ARGpDxgzgIKJDRJ/u4r1A/HgpBpKpKZelGct2PGI4T+axcedf6g==", + "dev": true, + "optional": true + }, + "@esbuild/linux-mips64el": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/linux-mips64el/-/linux-mips64el-0.25.3.tgz", + "integrity": "sha512-eRAOV2ODpu6P5divMEMa26RRqb2yUoYsuQQOuFUexUoQndm4MdpXXDBbUoKIc0iPa4aCO7gIhtnYomkn2x+bag==", + "dev": true, + "optional": true + }, + "@esbuild/linux-ppc64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/linux-ppc64/-/linux-ppc64-0.25.3.tgz", + "integrity": "sha512-ZC4jV2p7VbzTlnl8nZKLcBkfzIf4Yad1SJM4ZMKYnJqZFD4rTI+pBG65u8ev4jk3/MPwY9DvGn50wi3uhdaghg==", + "dev": true, + "optional": true + }, + "@esbuild/linux-riscv64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/linux-riscv64/-/linux-riscv64-0.25.3.tgz", + "integrity": "sha512-LDDODcFzNtECTrUUbVCs6j9/bDVqy7DDRsuIXJg6so+mFksgwG7ZVnTruYi5V+z3eE5y+BJZw7VvUadkbfg7QA==", + "dev": true, + "optional": true + }, + "@esbuild/linux-s390x": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/linux-s390x/-/linux-s390x-0.25.3.tgz", + "integrity": "sha512-s+w/NOY2k0yC2p9SLen+ymflgcpRkvwwa02fqmAwhBRI3SC12uiS10edHHXlVWwfAagYSY5UpmT/zISXPMW3tQ==", + "dev": true, + "optional": true + }, + "@esbuild/linux-x64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/linux-x64/-/linux-x64-0.25.3.tgz", + "integrity": "sha512-nQHDz4pXjSDC6UfOE1Fw9Q8d6GCAd9KdvMZpfVGWSJztYCarRgSDfOVBY5xwhQXseiyxapkiSJi/5/ja8mRFFA==", + "dev": true, + "optional": true + }, + "@esbuild/netbsd-arm64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/netbsd-arm64/-/netbsd-arm64-0.25.3.tgz", + "integrity": "sha512-1QaLtOWq0mzK6tzzp0jRN3eccmN3hezey7mhLnzC6oNlJoUJz4nym5ZD7mDnS/LZQgkrhEbEiTn515lPeLpgWA==", + "dev": true, + "optional": true + }, + "@esbuild/netbsd-x64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/netbsd-x64/-/netbsd-x64-0.25.3.tgz", + "integrity": "sha512-i5Hm68HXHdgv8wkrt+10Bc50zM0/eonPb/a/OFVfB6Qvpiirco5gBA5bz7S2SHuU+Y4LWn/zehzNX14Sp4r27g==", + "dev": true, + "optional": true + }, + "@esbuild/openbsd-arm64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/openbsd-arm64/-/openbsd-arm64-0.25.3.tgz", + "integrity": "sha512-zGAVApJEYTbOC6H/3QBr2mq3upG/LBEXr85/pTtKiv2IXcgKV0RT0QA/hSXZqSvLEpXeIxah7LczB4lkiYhTAQ==", + "dev": true, + "optional": true + }, + "@esbuild/openbsd-x64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/openbsd-x64/-/openbsd-x64-0.25.3.tgz", + "integrity": "sha512-fpqctI45NnCIDKBH5AXQBsD0NDPbEFczK98hk/aa6HJxbl+UtLkJV2+Bvy5hLSLk3LHmqt0NTkKNso1A9y1a4w==", + "dev": true, + "optional": true + }, + "@esbuild/sunos-x64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/sunos-x64/-/sunos-x64-0.25.3.tgz", + "integrity": "sha512-ROJhm7d8bk9dMCUZjkS8fgzsPAZEjtRJqCAmVgB0gMrvG7hfmPmz9k1rwO4jSiblFjYmNvbECL9uhaPzONMfgA==", + "dev": true, + "optional": true + }, + "@esbuild/win32-arm64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/win32-arm64/-/win32-arm64-0.25.3.tgz", + "integrity": "sha512-YWcow8peiHpNBiIXHwaswPnAXLsLVygFwCB3A7Bh5jRkIBFWHGmNQ48AlX4xDvQNoMZlPYzjVOQDYEzWCqufMQ==", + "dev": true, + "optional": true + }, + "@esbuild/win32-ia32": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/win32-ia32/-/win32-ia32-0.25.3.tgz", + "integrity": "sha512-qspTZOIGoXVS4DpNqUYUs9UxVb04khS1Degaw/MnfMe7goQ3lTfQ13Vw4qY/Nj0979BGvMRpAYbs/BAxEvU8ew==", + "dev": true, + "optional": true + }, + "@esbuild/win32-x64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/win32-x64/-/win32-x64-0.25.3.tgz", + "integrity": "sha512-ICgUR+kPimx0vvRzf+N/7L7tVSQeE3BYY+NhHRHXS1kBuPO7z2+7ea2HbhDyZdTephgvNvKrlDDKUexuCVBVvg==", + "dev": true, + "optional": true + }, + "@gltf-transform/core": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/@gltf-transform/core/-/core-4.3.0.tgz", + "integrity": "sha512-ZeaQfszGJ9LYwELszu45CuDQCsE26lJNNe36FVmN8xclaT6WDdCj7fwGpQXo0/l/YgAVAHX+uO7YNBW75/SRYw==", + "requires": { + "property-graph": "^4.0.0" + } + }, + "@gltf-transform/extensions": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/@gltf-transform/extensions/-/extensions-4.3.0.tgz", + "integrity": "sha512-XDAjQPYVMHa/VDpSbfCBwI+/1muwRJCaXhUpLgnUzAjn0D//PgvIAcbNm1EwBl3LIWBSwjDUCn2LiMAjp+aXVw==", + "requires": { + "@gltf-transform/core": "^4.3.0", + "ktx-parse": "^1.0.1" + } + }, + "@gltf-transform/functions": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/@gltf-transform/functions/-/functions-4.3.0.tgz", + "integrity": "sha512-FZggHVgt3DHOezgESBrf2vDzuD2FYQYaNT2sT/aP316SIwhuiIwby3z7rhV9joDvWqqUaPkf1UmkjlOaY9riSQ==", + "requires": { + "@gltf-transform/core": "^4.3.0", + "@gltf-transform/extensions": "^4.3.0", + "ktx-parse": "^1.0.1", + "ndarray": "^1.0.19", + "ndarray-lanczos": "^0.3.0", + "ndarray-pixels": "^5.0.1" + } + }, + "@img/colour": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/@img/colour/-/colour-1.0.0.tgz", + "integrity": "sha512-A5P/LfWGFSl6nsckYtjw9da+19jB8hkJ6ACTGcDfEJ0aE+l2n2El7dsVM7UVHZQ9s2lmYMWlrS21YLy2IR1LUw==" + }, + "@img/sharp-darwin-arm64": { + "version": "0.34.5", + "resolved": "https://registry.npmjs.org/@img/sharp-darwin-arm64/-/sharp-darwin-arm64-0.34.5.tgz", + "integrity": "sha512-imtQ3WMJXbMY4fxb/Ndp6HBTNVtWCUI0WdobyheGf5+ad6xX8VIDO8u2xE4qc/fr08CKG/7dDseFtn6M6g/r3w==", + "optional": true, + "requires": { + "@img/sharp-libvips-darwin-arm64": "1.2.4" + } + }, + "@img/sharp-darwin-x64": { + "version": "0.34.5", + "resolved": "https://registry.npmjs.org/@img/sharp-darwin-x64/-/sharp-darwin-x64-0.34.5.tgz", + "integrity": "sha512-YNEFAF/4KQ/PeW0N+r+aVVsoIY0/qxxikF2SWdp+NRkmMB7y9LBZAVqQ4yhGCm/H3H270OSykqmQMKLBhBJDEw==", + "optional": true, + "requires": { + "@img/sharp-libvips-darwin-x64": "1.2.4" + } + }, + "@img/sharp-libvips-darwin-arm64": { + "version": "1.2.4", + "resolved": "https://registry.npmjs.org/@img/sharp-libvips-darwin-arm64/-/sharp-libvips-darwin-arm64-1.2.4.tgz", + "integrity": "sha512-zqjjo7RatFfFoP0MkQ51jfuFZBnVE2pRiaydKJ1G/rHZvnsrHAOcQALIi9sA5co5xenQdTugCvtb1cuf78Vf4g==", + "optional": true + }, + "@img/sharp-libvips-darwin-x64": { + "version": "1.2.4", + "resolved": "https://registry.npmjs.org/@img/sharp-libvips-darwin-x64/-/sharp-libvips-darwin-x64-1.2.4.tgz", + "integrity": "sha512-1IOd5xfVhlGwX+zXv2N93k0yMONvUlANylbJw1eTah8K/Jtpi15KC+WSiaX/nBmbm2HxRM1gZ0nSdjSsrZbGKg==", + "optional": true + }, + "@img/sharp-libvips-linux-arm": { + "version": "1.2.4", + "resolved": "https://registry.npmjs.org/@img/sharp-libvips-linux-arm/-/sharp-libvips-linux-arm-1.2.4.tgz", + "integrity": "sha512-bFI7xcKFELdiNCVov8e44Ia4u2byA+l3XtsAj+Q8tfCwO6BQ8iDojYdvoPMqsKDkuoOo+X6HZA0s0q11ANMQ8A==", + "optional": true + }, + "@img/sharp-libvips-linux-arm64": { + "version": "1.2.4", + "resolved": "https://registry.npmjs.org/@img/sharp-libvips-linux-arm64/-/sharp-libvips-linux-arm64-1.2.4.tgz", + "integrity": "sha512-excjX8DfsIcJ10x1Kzr4RcWe1edC9PquDRRPx3YVCvQv+U5p7Yin2s32ftzikXojb1PIFc/9Mt28/y+iRklkrw==", + "optional": true + }, + "@img/sharp-libvips-linux-ppc64": { + "version": "1.2.4", + "resolved": "https://registry.npmjs.org/@img/sharp-libvips-linux-ppc64/-/sharp-libvips-linux-ppc64-1.2.4.tgz", + "integrity": "sha512-FMuvGijLDYG6lW+b/UvyilUWu5Ayu+3r2d1S8notiGCIyYU/76eig1UfMmkZ7vwgOrzKzlQbFSuQfgm7GYUPpA==", + "optional": true + }, + "@img/sharp-libvips-linux-riscv64": { + "version": "1.2.4", + "resolved": "https://registry.npmjs.org/@img/sharp-libvips-linux-riscv64/-/sharp-libvips-linux-riscv64-1.2.4.tgz", + "integrity": "sha512-oVDbcR4zUC0ce82teubSm+x6ETixtKZBh/qbREIOcI3cULzDyb18Sr/Wcyx7NRQeQzOiHTNbZFF1UwPS2scyGA==", + "optional": true + }, + "@img/sharp-libvips-linux-s390x": { + "version": "1.2.4", + "resolved": "https://registry.npmjs.org/@img/sharp-libvips-linux-s390x/-/sharp-libvips-linux-s390x-1.2.4.tgz", + "integrity": "sha512-qmp9VrzgPgMoGZyPvrQHqk02uyjA0/QrTO26Tqk6l4ZV0MPWIW6LTkqOIov+J1yEu7MbFQaDpwdwJKhbJvuRxQ==", + "optional": true + }, + "@img/sharp-libvips-linux-x64": { + "version": "1.2.4", + "resolved": "https://registry.npmjs.org/@img/sharp-libvips-linux-x64/-/sharp-libvips-linux-x64-1.2.4.tgz", + "integrity": "sha512-tJxiiLsmHc9Ax1bz3oaOYBURTXGIRDODBqhveVHonrHJ9/+k89qbLl0bcJns+e4t4rvaNBxaEZsFtSfAdquPrw==", + "optional": true + }, + "@img/sharp-libvips-linuxmusl-arm64": { + "version": "1.2.4", + "resolved": "https://registry.npmjs.org/@img/sharp-libvips-linuxmusl-arm64/-/sharp-libvips-linuxmusl-arm64-1.2.4.tgz", + "integrity": "sha512-FVQHuwx1IIuNow9QAbYUzJ+En8KcVm9Lk5+uGUQJHaZmMECZmOlix9HnH7n1TRkXMS0pGxIJokIVB9SuqZGGXw==", + "optional": true + }, + "@img/sharp-libvips-linuxmusl-x64": { + "version": "1.2.4", + "resolved": "https://registry.npmjs.org/@img/sharp-libvips-linuxmusl-x64/-/sharp-libvips-linuxmusl-x64-1.2.4.tgz", + "integrity": "sha512-+LpyBk7L44ZIXwz/VYfglaX/okxezESc6UxDSoyo2Ks6Jxc4Y7sGjpgU9s4PMgqgjj1gZCylTieNamqA1MF7Dg==", + "optional": true + }, + "@img/sharp-linux-arm": { + "version": "0.34.5", + "resolved": "https://registry.npmjs.org/@img/sharp-linux-arm/-/sharp-linux-arm-0.34.5.tgz", + "integrity": "sha512-9dLqsvwtg1uuXBGZKsxem9595+ujv0sJ6Vi8wcTANSFpwV/GONat5eCkzQo/1O6zRIkh0m/8+5BjrRr7jDUSZw==", + "optional": true, + "requires": { + "@img/sharp-libvips-linux-arm": "1.2.4" + } + }, + "@img/sharp-linux-arm64": { + "version": "0.34.5", + "resolved": "https://registry.npmjs.org/@img/sharp-linux-arm64/-/sharp-linux-arm64-0.34.5.tgz", + "integrity": "sha512-bKQzaJRY/bkPOXyKx5EVup7qkaojECG6NLYswgktOZjaXecSAeCWiZwwiFf3/Y+O1HrauiE3FVsGxFg8c24rZg==", + "optional": true, + "requires": { + "@img/sharp-libvips-linux-arm64": "1.2.4" + } + }, + "@img/sharp-linux-ppc64": { + "version": "0.34.5", + "resolved": "https://registry.npmjs.org/@img/sharp-linux-ppc64/-/sharp-linux-ppc64-0.34.5.tgz", + "integrity": "sha512-7zznwNaqW6YtsfrGGDA6BRkISKAAE1Jo0QdpNYXNMHu2+0dTrPflTLNkpc8l7MUP5M16ZJcUvysVWWrMefZquA==", + "optional": true, + "requires": { + "@img/sharp-libvips-linux-ppc64": "1.2.4" + } + }, + "@img/sharp-linux-riscv64": { + "version": "0.34.5", + "resolved": "https://registry.npmjs.org/@img/sharp-linux-riscv64/-/sharp-linux-riscv64-0.34.5.tgz", + "integrity": "sha512-51gJuLPTKa7piYPaVs8GmByo7/U7/7TZOq+cnXJIHZKavIRHAP77e3N2HEl3dgiqdD/w0yUfiJnII77PuDDFdw==", + "optional": true, + "requires": { + "@img/sharp-libvips-linux-riscv64": "1.2.4" + } + }, + "@img/sharp-linux-s390x": { + "version": "0.34.5", + "resolved": "https://registry.npmjs.org/@img/sharp-linux-s390x/-/sharp-linux-s390x-0.34.5.tgz", + "integrity": "sha512-nQtCk0PdKfho3eC5MrbQoigJ2gd1CgddUMkabUj+rBevs8tZ2cULOx46E7oyX+04WGfABgIwmMC0VqieTiR4jg==", + "optional": true, + "requires": { + "@img/sharp-libvips-linux-s390x": "1.2.4" + } + }, + "@img/sharp-linux-x64": { + "version": "0.34.5", + "resolved": "https://registry.npmjs.org/@img/sharp-linux-x64/-/sharp-linux-x64-0.34.5.tgz", + "integrity": "sha512-MEzd8HPKxVxVenwAa+JRPwEC7QFjoPWuS5NZnBt6B3pu7EG2Ge0id1oLHZpPJdn3OQK+BQDiw9zStiHBTJQQQQ==", + "optional": true, + "requires": { + "@img/sharp-libvips-linux-x64": "1.2.4" + } + }, + "@img/sharp-linuxmusl-arm64": { + "version": "0.34.5", + "resolved": "https://registry.npmjs.org/@img/sharp-linuxmusl-arm64/-/sharp-linuxmusl-arm64-0.34.5.tgz", + "integrity": "sha512-fprJR6GtRsMt6Kyfq44IsChVZeGN97gTD331weR1ex1c1rypDEABN6Tm2xa1wE6lYb5DdEnk03NZPqA7Id21yg==", + "optional": true, + "requires": { + "@img/sharp-libvips-linuxmusl-arm64": "1.2.4" + } + }, + "@img/sharp-linuxmusl-x64": { + "version": "0.34.5", + "resolved": "https://registry.npmjs.org/@img/sharp-linuxmusl-x64/-/sharp-linuxmusl-x64-0.34.5.tgz", + "integrity": "sha512-Jg8wNT1MUzIvhBFxViqrEhWDGzqymo3sV7z7ZsaWbZNDLXRJZoRGrjulp60YYtV4wfY8VIKcWidjojlLcWrd8Q==", + "optional": true, + "requires": { + "@img/sharp-libvips-linuxmusl-x64": "1.2.4" + } + }, + "@img/sharp-wasm32": { + "version": "0.34.5", + "resolved": "https://registry.npmjs.org/@img/sharp-wasm32/-/sharp-wasm32-0.34.5.tgz", + "integrity": "sha512-OdWTEiVkY2PHwqkbBI8frFxQQFekHaSSkUIJkwzclWZe64O1X4UlUjqqqLaPbUpMOQk6FBu/HtlGXNblIs0huw==", + "optional": true, + "requires": { + "@emnapi/runtime": "^1.7.0" + } + }, + "@img/sharp-win32-arm64": { + "version": "0.34.5", + "resolved": "https://registry.npmjs.org/@img/sharp-win32-arm64/-/sharp-win32-arm64-0.34.5.tgz", + "integrity": "sha512-WQ3AgWCWYSb2yt+IG8mnC6Jdk9Whs7O0gxphblsLvdhSpSTtmu69ZG1Gkb6NuvxsNACwiPV6cNSZNzt0KPsw7g==", + "optional": true + }, + "@img/sharp-win32-ia32": { + "version": "0.34.5", + "resolved": "https://registry.npmjs.org/@img/sharp-win32-ia32/-/sharp-win32-ia32-0.34.5.tgz", + "integrity": "sha512-FV9m/7NmeCmSHDD5j4+4pNI8Cp3aW+JvLoXcTUo0IqyjSfAZJ8dIUmijx1qaJsIiU+Hosw6xM5KijAWRJCSgNg==", + "optional": true + }, + "@img/sharp-win32-x64": { + "version": "0.34.5", + "resolved": "https://registry.npmjs.org/@img/sharp-win32-x64/-/sharp-win32-x64-0.34.5.tgz", + "integrity": "sha512-+29YMsqY2/9eFEiW93eqWnuLcWcufowXewwSNIT6UwZdUUCrM3oFjMWH/Z6/TMmb4hlFenmfAVbpWeup2jryCw==", + "optional": true + }, + "@jridgewell/resolve-uri": { + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/@jridgewell/resolve-uri/-/resolve-uri-3.1.2.tgz", + "integrity": "sha512-bRISgCIjP20/tbWSPWMEi54QVPRZExkuD9lJL+UIxUKtwVJA8wW1Trb1jMs1RFXo1CBTNZ/5hpC9QvmKWdopKw==" + }, + "@jridgewell/sourcemap-codec": { + "version": "1.5.5", + "resolved": "https://registry.npmjs.org/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.5.5.tgz", + "integrity": "sha512-cYQ9310grqxueWbl+WuIUIaiUaDcj7WOq5fVhEljNVgRfOUhY9fy2zTvfoqWsnebh8Sl70VScFbICvJnLKB0Og==" + }, + "@jridgewell/trace-mapping": { + "version": "0.3.31", + "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.31.tgz", + "integrity": "sha512-zzNR+SdQSDJzc8joaeP8QQoCQr8NuYx2dIIytl1QeBEZHJ9uW6hebsrYgbz8hJwUQao3TWCMtmfV8Nu1twOLAw==", + "requires": { + "@jridgewell/resolve-uri": "^3.1.0", + "@jridgewell/sourcemap-codec": "^1.4.14" + } + }, + "@jscad/3mf-serializer": { + "version": "2.1.12", + "resolved": "https://registry.npmjs.org/@jscad/3mf-serializer/-/3mf-serializer-2.1.12.tgz", + "integrity": "sha512-+rxAIKIHCpaplupwwsdXtG1IdimPXFFB45nrjy6gdFHi36bEQW6y/RQD/ngenRiKnYSxu7/M0LatHcjve8z64A==", + "requires": { + "@jscad/array-utils": "2.1.4", + "@jscad/modeling": "2.12.3", + "fflate": "0.7.3", + "onml": "1.2.0" + } + }, + "@jscad/array-utils": { + "version": "2.1.4", + "resolved": "https://registry.npmjs.org/@jscad/array-utils/-/array-utils-2.1.4.tgz", + "integrity": "sha512-c31r4zSKsE+4Xfwk2V8monDA0hx5G89QGzaakWVUvuGNowYS9WSsYCwHiTIXodjR+HEnDu4okQ7k/whmP0Ne2g==" + }, + "@jscad/dxf-serializer": { + "version": "2.1.18", + "resolved": "https://registry.npmjs.org/@jscad/dxf-serializer/-/dxf-serializer-2.1.18.tgz", + "integrity": "sha512-T5Qe2jbEphcWAk7GaOY8PCMD4DPhTm6gWk/MPJCExphhnUwJqcU/1RiMb5hiD+N6hHzmlxD59I8QTjlp9LbLSA==", + "requires": { + "@jscad/array-utils": "2.1.4", + "@jscad/modeling": "2.12.3" + } + }, + "@jscad/io-utils": { + "version": "2.0.28", + "resolved": "https://registry.npmjs.org/@jscad/io-utils/-/io-utils-2.0.28.tgz", + "integrity": "sha512-spXh37wAgmwjKztoH/HANLgImcqRHX5+H/cRIxPfpqDIWvu7I5bRg2ZTwh25SYlKIzxPk4qX5Nu7Ax5+Kg+QXQ==" + }, + "@jscad/modeling": { + "version": "2.12.3", + "resolved": "https://registry.npmjs.org/@jscad/modeling/-/modeling-2.12.3.tgz", + "integrity": "sha512-DnAacXq3zhlYWIixGlFD7RMpgZAMuCaMZNQov0NaoFfs2GaBuTC5eqkqKcEVbhEerBmTllbjjF5IXjJMt9jcOA==" + }, + "@jscad/stl-serializer": { + "version": "2.1.18", + "resolved": "https://registry.npmjs.org/@jscad/stl-serializer/-/stl-serializer-2.1.18.tgz", + "integrity": "sha512-pz++TRjHI7jBPnnxQUi4B/uYUG3yCDsKlw8+xL2kumwjb+auc6Ng6Rnr/GqUTkgHrnGut08wg/8AekyWjvBwYg==", + "requires": { + "@jscad/array-utils": "2.1.4", + "@jscad/modeling": "2.12.3" + } + }, + "@jscadui/3mf-export": { + "version": "0.5.0", + "resolved": "https://registry.npmjs.org/@jscadui/3mf-export/-/3mf-export-0.5.0.tgz", + "integrity": "sha512-y5vZktqCjyi7wA38zqNlLIdZUIRZoOO9vCjLzwmL4bR0hk7B/Zm1IeffzJPFe1vFc0C1IEv3hm8caDv3doRk9g==" + }, + "@jsep-plugin/assignment": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/@jsep-plugin/assignment/-/assignment-1.3.0.tgz", + "integrity": "sha512-VVgV+CXrhbMI3aSusQyclHkenWSAm95WaiKrMxRFam3JSUiIaQjoMIw2sEs/OX4XifnqeQUN4DYbJjlA8EfktQ==", + "requires": {} + }, + "@jsep-plugin/regex": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/@jsep-plugin/regex/-/regex-1.0.4.tgz", + "integrity": "sha512-q7qL4Mgjs1vByCaTnDFcBnV9HS7GVPJX5vyVoCgZHNSC9rjwIlmbXG5sUuorR5ndfHAIlJ8pVStxvjXHbNvtUg==", + "requires": {} + }, + "@rollup/rollup-android-arm-eabi": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-android-arm-eabi/-/rollup-android-arm-eabi-4.40.1.tgz", + "integrity": "sha512-kxz0YeeCrRUHz3zyqvd7n+TVRlNyTifBsmnmNPtk3hQURUyG9eAB+usz6DAwagMusjx/zb3AjvDUvhFGDAexGw==", + "dev": true, + "optional": true + }, + "@rollup/rollup-android-arm64": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-android-arm64/-/rollup-android-arm64-4.40.1.tgz", + "integrity": "sha512-PPkxTOisoNC6TpnDKatjKkjRMsdaWIhyuMkA4UsBXT9WEZY4uHezBTjs6Vl4PbqQQeu6oION1w2voYZv9yquCw==", + "dev": true, + "optional": true + }, + "@rollup/rollup-darwin-arm64": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-darwin-arm64/-/rollup-darwin-arm64-4.40.1.tgz", + "integrity": "sha512-VWXGISWFY18v/0JyNUy4A46KCFCb9NVsH+1100XP31lud+TzlezBbz24CYzbnA4x6w4hx+NYCXDfnvDVO6lcAA==", + "dev": true, + "optional": true + }, + "@rollup/rollup-darwin-x64": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-darwin-x64/-/rollup-darwin-x64-4.40.1.tgz", + "integrity": "sha512-nIwkXafAI1/QCS7pxSpv/ZtFW6TXcNUEHAIA9EIyw5OzxJZQ1YDrX+CL6JAIQgZ33CInl1R6mHet9Y/UZTg2Bw==", + "dev": true, + "optional": true + }, + "@rollup/rollup-freebsd-arm64": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-freebsd-arm64/-/rollup-freebsd-arm64-4.40.1.tgz", + "integrity": "sha512-BdrLJ2mHTrIYdaS2I99mriyJfGGenSaP+UwGi1kB9BLOCu9SR8ZpbkmmalKIALnRw24kM7qCN0IOm6L0S44iWw==", + "dev": true, + "optional": true + }, + "@rollup/rollup-freebsd-x64": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-freebsd-x64/-/rollup-freebsd-x64-4.40.1.tgz", + "integrity": "sha512-VXeo/puqvCG8JBPNZXZf5Dqq7BzElNJzHRRw3vjBE27WujdzuOPecDPc/+1DcdcTptNBep3861jNq0mYkT8Z6Q==", + "dev": true, + "optional": true + }, + "@rollup/rollup-linux-arm-gnueabihf": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm-gnueabihf/-/rollup-linux-arm-gnueabihf-4.40.1.tgz", + "integrity": "sha512-ehSKrewwsESPt1TgSE/na9nIhWCosfGSFqv7vwEtjyAqZcvbGIg4JAcV7ZEh2tfj/IlfBeZjgOXm35iOOjadcg==", + "dev": true, + "optional": true + }, + "@rollup/rollup-linux-arm-musleabihf": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm-musleabihf/-/rollup-linux-arm-musleabihf-4.40.1.tgz", + "integrity": "sha512-m39iO/aaurh5FVIu/F4/Zsl8xppd76S4qoID8E+dSRQvTyZTOI2gVk3T4oqzfq1PtcvOfAVlwLMK3KRQMaR8lg==", + "dev": true, + "optional": true + }, + "@rollup/rollup-linux-arm64-gnu": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm64-gnu/-/rollup-linux-arm64-gnu-4.40.1.tgz", + "integrity": "sha512-Y+GHnGaku4aVLSgrT0uWe2o2Rq8te9hi+MwqGF9r9ORgXhmHK5Q71N757u0F8yU1OIwUIFy6YiJtKjtyktk5hg==", + "dev": true, + "optional": true + }, + "@rollup/rollup-linux-arm64-musl": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm64-musl/-/rollup-linux-arm64-musl-4.40.1.tgz", + "integrity": "sha512-jEwjn3jCA+tQGswK3aEWcD09/7M5wGwc6+flhva7dsQNRZZTe30vkalgIzV4tjkopsTS9Jd7Y1Bsj6a4lzz8gQ==", + "dev": true, + "optional": true + }, + "@rollup/rollup-linux-loongarch64-gnu": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-loongarch64-gnu/-/rollup-linux-loongarch64-gnu-4.40.1.tgz", + "integrity": "sha512-ySyWikVhNzv+BV/IDCsrraOAZ3UaC8SZB67FZlqVwXwnFhPihOso9rPOxzZbjp81suB1O2Topw+6Ug3JNegejQ==", + "dev": true, + "optional": true + }, + "@rollup/rollup-linux-powerpc64le-gnu": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-powerpc64le-gnu/-/rollup-linux-powerpc64le-gnu-4.40.1.tgz", + "integrity": "sha512-BvvA64QxZlh7WZWqDPPdt0GH4bznuL6uOO1pmgPnnv86rpUpc8ZxgZwcEgXvo02GRIZX1hQ0j0pAnhwkhwPqWg==", + "dev": true, + "optional": true + }, + "@rollup/rollup-linux-riscv64-gnu": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-riscv64-gnu/-/rollup-linux-riscv64-gnu-4.40.1.tgz", + "integrity": "sha512-EQSP+8+1VuSulm9RKSMKitTav89fKbHymTf25n5+Yr6gAPZxYWpj3DzAsQqoaHAk9YX2lwEyAf9S4W8F4l3VBQ==", + "dev": true, + "optional": true + }, + "@rollup/rollup-linux-riscv64-musl": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-riscv64-musl/-/rollup-linux-riscv64-musl-4.40.1.tgz", + "integrity": "sha512-n/vQ4xRZXKuIpqukkMXZt9RWdl+2zgGNx7Uda8NtmLJ06NL8jiHxUawbwC+hdSq1rrw/9CghCpEONor+l1e2gA==", + "dev": true, + "optional": true + }, + "@rollup/rollup-linux-s390x-gnu": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-s390x-gnu/-/rollup-linux-s390x-gnu-4.40.1.tgz", + "integrity": "sha512-h8d28xzYb98fMQKUz0w2fMc1XuGzLLjdyxVIbhbil4ELfk5/orZlSTpF/xdI9C8K0I8lCkq+1En2RJsawZekkg==", + "dev": true, + "optional": true + }, + "@rollup/rollup-linux-x64-gnu": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-x64-gnu/-/rollup-linux-x64-gnu-4.40.1.tgz", + "integrity": "sha512-XiK5z70PEFEFqcNj3/zRSz/qX4bp4QIraTy9QjwJAb/Z8GM7kVUsD0Uk8maIPeTyPCP03ChdI+VVmJriKYbRHQ==", + "dev": true, + "optional": true + }, + "@rollup/rollup-linux-x64-musl": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-x64-musl/-/rollup-linux-x64-musl-4.40.1.tgz", + "integrity": "sha512-2BRORitq5rQ4Da9blVovzNCMaUlyKrzMSvkVR0D4qPuOy/+pMCrh1d7o01RATwVy+6Fa1WBw+da7QPeLWU/1mQ==", + "dev": true, + "optional": true + }, + "@rollup/rollup-win32-arm64-msvc": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-arm64-msvc/-/rollup-win32-arm64-msvc-4.40.1.tgz", + "integrity": "sha512-b2bcNm9Kbde03H+q+Jjw9tSfhYkzrDUf2d5MAd1bOJuVplXvFhWz7tRtWvD8/ORZi7qSCy0idW6tf2HgxSXQSg==", + "dev": true, + "optional": true + }, + "@rollup/rollup-win32-ia32-msvc": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-ia32-msvc/-/rollup-win32-ia32-msvc-4.40.1.tgz", + "integrity": "sha512-DfcogW8N7Zg7llVEfpqWMZcaErKfsj9VvmfSyRjCyo4BI3wPEfrzTtJkZG6gKP/Z92wFm6rz2aDO7/JfiR/whA==", + "dev": true, + "optional": true + }, + "@rollup/rollup-win32-x64-msvc": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-x64-msvc/-/rollup-win32-x64-msvc-4.40.1.tgz", + "integrity": "sha512-ECyOuDeH3C1I8jH2MK1RtBJW+YPMvSfT0a5NN0nHfQYnDSJ6tUiZH3gzwVP5/Kfh/+Tt7tpWVF9LXNTnhTJ3kA==", + "dev": true, + "optional": true + }, + "@tweenjs/tween.js": { + "version": "23.1.3", + "resolved": "https://registry.npmjs.org/@tweenjs/tween.js/-/tween.js-23.1.3.tgz", + "integrity": "sha512-vJmvvwFxYuGnF2axRtPYocag6Clbb5YS7kLL+SO/TeVFzHqDIWrNKYtcsPMibjDx9O+bu+psAy9NKfWklassUA==", + "dev": true + }, + "@types/estree": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/@types/estree/-/estree-1.0.7.tgz", + "integrity": "sha512-w28IoSUCJpidD/TGviZwwMJckNESJZXFu7NBZ5YJ4mEUnNraUn9Pm8HSZm/jDF1pDWYKspWE7oVphigUPRakIQ==", + "dev": true + }, + "@types/ndarray": { + "version": "1.0.14", + "resolved": "https://registry.npmjs.org/@types/ndarray/-/ndarray-1.0.14.tgz", + "integrity": "sha512-oANmFZMnFQvb219SSBIhI1Ih/r4CvHDOzkWyJS/XRqkMrGH5/kaPSA1hQhdIBzouaE+5KpE/f5ylI9cujmckQg==" + }, + "@types/stats.js": { + "version": "0.17.3", + "resolved": "https://registry.npmjs.org/@types/stats.js/-/stats.js-0.17.3.tgz", + "integrity": "sha512-pXNfAD3KHOdif9EQXZ9deK82HVNaXP5ZIF5RP2QG6OQFNTaY2YIetfrE9t528vEreGQvEPRDDc8muaoYeK0SxQ==", + "dev": true + }, + "@types/three": { + "version": "0.182.0", + "resolved": "https://registry.npmjs.org/@types/three/-/three-0.182.0.tgz", + "integrity": "sha512-WByN9V3Sbwbe2OkWuSGyoqQO8Du6yhYaXtXLoA5FkKTUJorZ+yOHBZ35zUUPQXlAKABZmbYp5oAqpA4RBjtJ/Q==", + "dev": true, + "requires": { + "@dimforge/rapier3d-compat": "~0.12.0", + "@tweenjs/tween.js": "~23.1.3", + "@types/stats.js": "*", + "@types/webxr": ">=0.5.17", + "@webgpu/types": "*", + "fflate": "~0.8.2", + "meshoptimizer": "~0.22.0" + }, + "dependencies": { + "fflate": { + "version": "0.8.2", + "resolved": "https://registry.npmjs.org/fflate/-/fflate-0.8.2.tgz", + "integrity": "sha512-cPJU47OaAoCbg0pBvzsgpTPhmhqI5eJjh/JIu8tPj5q+T7iLvW/JAYUqmE7KOB4R1ZyEhzBaIQpQpardBF5z8A==", + "dev": true + } + } + }, + "@types/webxr": { + "version": "0.5.22", + "resolved": "https://registry.npmjs.org/@types/webxr/-/webxr-0.5.22.tgz", + "integrity": "sha512-Vr6Stjv5jPRqH690f5I5GLjVk8GSsoQSYJ2FVd/3jJF7KaqfwPi3ehfBS96mlQ2kPCwZaX6U0rG2+NGHBKkA/A==", + "dev": true + }, + "@webgpu/types": { + "version": "0.1.60", + "resolved": "https://registry.npmjs.org/@webgpu/types/-/types-0.1.60.tgz", + "integrity": "sha512-8B/tdfRFKdrnejqmvq95ogp8tf52oZ51p3f4QD5m5Paey/qlX4Rhhy5Y8tgFMi7Ms70HzcMMw3EQjH/jdhTwlA==", + "dev": true + }, + "bindings": { + "version": "1.5.0", + "resolved": "https://registry.npmjs.org/bindings/-/bindings-1.5.0.tgz", + "integrity": "sha512-p2q/t/mhvuOj/UeLlV6566GD/guowlr0hHxClI0W9m7MWYkL1F0hLo+0Aexs9HSPCtR1SXQ0TD3MMKrXZajbiQ==", + "optional": true, + "requires": { + "file-uri-to-path": "1.0.0" + } + }, + "commander": { + "version": "13.1.0", + "resolved": "https://registry.npmjs.org/commander/-/commander-13.1.0.tgz", + "integrity": "sha512-/rFeCpNJQbhSZjGVwO9RFV3xPqbnERS8MmIQzCtD/zl6gpJuV/bMLuN92oG3F7d8oDEHHRrujSXNUr8fpjntKw==" + }, + "convert-source-map": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/convert-source-map/-/convert-source-map-2.0.0.tgz", + "integrity": "sha512-Kvp459HrV2FEJ1CAsi1Ku+MY3kasH19TFykTz2xWmMeq6bk2NU3XXvfJ+Q61m0xktWwt+1HSYf3JZsTms3aRJg==" + }, + "core-js": { + "version": "3.47.0", + "resolved": "https://registry.npmjs.org/core-js/-/core-js-3.47.0.tgz", + "integrity": "sha512-c3Q2VVkGAUyupsjRnaNX6u8Dq2vAdzm9iuPj5FW0fRxzlxgq9Q39MDq10IvmQSpLgHQNyQzQmOo6bgGHmH3NNg==" + }, + "cwise-compiler": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/cwise-compiler/-/cwise-compiler-1.1.3.tgz", + "integrity": "sha512-WXlK/m+Di8DMMcCjcWr4i+XzcQra9eCdXIJrgh4TUgh0pIS/yJduLxS9JgefsHJ/YVLdgPtXm9r62W92MvanEQ==", + "requires": { + "uniq": "^1.0.0" + } + }, + "detect-libc": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/detect-libc/-/detect-libc-2.1.2.tgz", + "integrity": "sha512-Btj2BOOO83o3WyH59e8MgXsxEQVcarkUOpEYrubB0urwnN10yQ364rsiByU11nZlqWYZm05i/of7io4mzihBtQ==" + }, + "esbuild": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/esbuild/-/esbuild-0.25.3.tgz", + "integrity": "sha512-qKA6Pvai73+M2FtftpNKRxJ78GIjmFXFxd/1DVBqGo/qNhLSfv+G12n9pNoWdytJC8U00TrViOwpjT0zgqQS8Q==", + "dev": true, + "requires": { + "@esbuild/aix-ppc64": "0.25.3", + "@esbuild/android-arm": "0.25.3", + "@esbuild/android-arm64": "0.25.3", + "@esbuild/android-x64": "0.25.3", + "@esbuild/darwin-arm64": "0.25.3", + "@esbuild/darwin-x64": "0.25.3", + "@esbuild/freebsd-arm64": "0.25.3", + "@esbuild/freebsd-x64": "0.25.3", + "@esbuild/linux-arm": "0.25.3", + "@esbuild/linux-arm64": "0.25.3", + "@esbuild/linux-ia32": "0.25.3", + "@esbuild/linux-loong64": "0.25.3", + "@esbuild/linux-mips64el": "0.25.3", + "@esbuild/linux-ppc64": "0.25.3", + "@esbuild/linux-riscv64": "0.25.3", + "@esbuild/linux-s390x": "0.25.3", + "@esbuild/linux-x64": "0.25.3", + "@esbuild/netbsd-arm64": "0.25.3", + "@esbuild/netbsd-x64": "0.25.3", + "@esbuild/openbsd-arm64": "0.25.3", + "@esbuild/openbsd-x64": "0.25.3", + "@esbuild/sunos-x64": "0.25.3", + "@esbuild/win32-arm64": "0.25.3", + "@esbuild/win32-ia32": "0.25.3", + "@esbuild/win32-x64": "0.25.3" + } + }, + "esbuild-plugin-text-replace": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/esbuild-plugin-text-replace/-/esbuild-plugin-text-replace-1.3.0.tgz", + "integrity": "sha512-RWB/bbdP0xDHBOtA0st4CAE6UZtky76aCB7Shw5r350JY403lfvrj2UMkInUB346tMtFWXKWXNf4gqNM+WbXag==", + "requires": { + "ts-replace-all": "^1.0.0" + } + }, + "esbuild-wasm": { + "version": "0.25.12", + "resolved": "https://registry.npmjs.org/esbuild-wasm/-/esbuild-wasm-0.25.12.tgz", + "integrity": "sha512-rZqkjL3Y6FwLpSHzLnaEy8Ps6veCNo1kZa9EOfJvmWtBq5dJH4iVjfmOO6Mlkv9B0tt9WFPFmb/VxlgJOnueNg==" + }, + "fdir": { + "version": "6.4.4", + "resolved": "https://registry.npmjs.org/fdir/-/fdir-6.4.4.tgz", + "integrity": "sha512-1NZP+GK4GfuAv3PqKvxQRDMjdSRZjnkq7KfhlNrCNNlZ0ygQFpebfrnfnq/W7fpUnAv9aGWmY1zKx7FYL3gwhg==", + "dev": true, + "requires": {} + }, + "fflate": { + "version": "0.7.3", + "resolved": "https://registry.npmjs.org/fflate/-/fflate-0.7.3.tgz", + "integrity": "sha512-0Zz1jOzJWERhyhsimS54VTqOteCNwRtIlh8isdL0AXLo0g7xNTfTL7oWrkmCnPhZGocKIkWHBistBrrpoNH3aw==" + }, + "file-uri-to-path": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/file-uri-to-path/-/file-uri-to-path-1.0.0.tgz", + "integrity": "sha512-0Zt+s3L7Vf1biwWZ29aARiVYLx7iMGnEUl9x33fbB/j3jR81u/O2LbqK+Bm1CDSNDKVtJ/YjwY7TUd5SkeLQLw==", + "optional": true + }, + "fsevents": { + "version": "2.3.3", + "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.3.tgz", + "integrity": "sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw==", + "dev": true, + "optional": true + }, + "iota-array": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/iota-array/-/iota-array-1.0.0.tgz", + "integrity": "sha512-pZ2xT+LOHckCatGQ3DcG/a+QuEqvoxqkiL7tvE8nn3uuu+f6i1TtpB5/FtWFbxUuVr5PZCx8KskuGatbJDXOWA==" + }, + "is-buffer": { + "version": "1.1.6", + "resolved": "https://registry.npmjs.org/is-buffer/-/is-buffer-1.1.6.tgz", + "integrity": "sha512-NcdALwpXkTm5Zvvbk7owOUSvVvBKDgKP5/ewfXEznmQFfs4ZRmanOeKBTjRVjka3QFoN6XJ+9F3USqfHqTaU5w==" + }, + "jsep": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/jsep/-/jsep-1.4.0.tgz", + "integrity": "sha512-B7qPcEVE3NVkmSJbaYxvv4cHkVW7DQsZz13pUMrfS8z8Q/BuShN+gcTXrUlPiGqM2/t/EEaI030bpxMqY8gMlw==" + }, + "jsonpath-plus": { + "version": "10.1.0", + "resolved": "https://registry.npmjs.org/jsonpath-plus/-/jsonpath-plus-10.1.0.tgz", + "integrity": "sha512-gHfV1IYqH8uJHYVTs8BJX1XKy2/rR93+f8QQi0xhx95aCiXn1ettYAd5T+7FU6wfqyDoX/wy0pm/fL3jOKJ9Lg==", + "requires": { + "@jsep-plugin/assignment": "^1.2.1", + "@jsep-plugin/regex": "^1.0.3", + "jsep": "^1.3.9" + } + }, + "ktx-parse": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/ktx-parse/-/ktx-parse-1.1.0.tgz", + "integrity": "sha512-mKp3y+FaYgR7mXWAbyyzpa/r1zDWeaunH+INJO4fou3hb45XuNSwar+7llrRyvpMWafxSIi99RNFJ05MHedaJQ==" + }, + "manifold-3d": { + "version": "3.3.2", + "resolved": "https://registry.npmjs.org/manifold-3d/-/manifold-3d-3.3.2.tgz", + "integrity": "sha512-Xx+S7kkbqlZxSPfBKH5yVKDO6k/eW7JRvnG1dKCFO0D4zjifOV5GM18TR0sREDcbKAzglHZ5OoxxpZRkxg6U5A==", + "requires": { + "@gltf-transform/core": "^4.2.0", + "@gltf-transform/extensions": "^4.2.0", + "@gltf-transform/functions": "^4.2.0", + "@jridgewell/trace-mapping": "^0.3.31", + "@jscadui/3mf-export": "^0.5.0", + "commander": "^13.1.0", + "convert-source-map": "^2.0.0", + "esbuild-plugin-text-replace": "^1.3.0", + "esbuild-wasm": "^0.25.11", + "fflate": "^0.8.0" + }, + "dependencies": { + "fflate": { + "version": "0.8.2", + "resolved": "https://registry.npmjs.org/fflate/-/fflate-0.8.2.tgz", + "integrity": "sha512-cPJU47OaAoCbg0pBvzsgpTPhmhqI5eJjh/JIu8tPj5q+T7iLvW/JAYUqmE7KOB4R1ZyEhzBaIQpQpardBF5z8A==" + } + } + }, + "meshoptimizer": { + "version": "0.22.0", + "resolved": "https://registry.npmjs.org/meshoptimizer/-/meshoptimizer-0.22.0.tgz", + "integrity": "sha512-IebiK79sqIy+E4EgOr+CAw+Ke8hAspXKzBd0JdgEmPHiAwmvEj2S4h1rfvo+o/BnfEYd/jAOg5IeeIjzlzSnDg==", + "dev": true + }, + "nan": { + "version": "2.24.0", + "resolved": "https://registry.npmjs.org/nan/-/nan-2.24.0.tgz", + "integrity": "sha512-Vpf9qnVW1RaDkoNKFUvfxqAbtI8ncb8OJlqZ9wwpXzWPEsvsB1nvdUi6oYrHIkQ1Y/tMDnr1h4nczS0VB9Xykg==", + "optional": true + }, + "nanoid": { + "version": "3.3.11", + "resolved": "https://registry.npmjs.org/nanoid/-/nanoid-3.3.11.tgz", + "integrity": "sha512-N8SpfPUnUp1bK+PMYW8qSWdl9U+wwNWI4QKxOYDy9JAro3WMX7p2OeVRF9v+347pnakNevPmiHhNmZ2HbFA76w==", + "dev": true + }, + "ndarray": { + "version": "1.0.19", + "resolved": "https://registry.npmjs.org/ndarray/-/ndarray-1.0.19.tgz", + "integrity": "sha512-B4JHA4vdyZU30ELBw3g7/p9bZupyew5a7tX1Y/gGeF2hafrPaQZhgrGQfsvgfYbgdFZjYwuEcnaobeM/WMW+HQ==", + "requires": { + "iota-array": "^1.0.0", + "is-buffer": "^1.0.2" + } + }, + "ndarray-lanczos": { + "version": "0.3.0", + "resolved": "https://registry.npmjs.org/ndarray-lanczos/-/ndarray-lanczos-0.3.0.tgz", + "integrity": "sha512-5kBmmG3Zvyj77qxIAC4QFLKuYdDIBJwCG+DukT6jQHNa1Ft74/hPH1z5mbQXeHBt8yvGPBGVrr3wEOdJPYYZYg==", + "requires": { + "@types/ndarray": "^1.0.11", + "ndarray": "^1.0.19" + } + }, + "ndarray-ops": { + "version": "1.2.2", + "resolved": "https://registry.npmjs.org/ndarray-ops/-/ndarray-ops-1.2.2.tgz", + "integrity": "sha512-BppWAFRjMYF7N/r6Ie51q6D4fs0iiGmeXIACKY66fLpnwIui3Wc3CXiD/30mgLbDjPpSLrsqcp3Z62+IcHZsDw==", + "requires": { + "cwise-compiler": "^1.0.0" + } + }, + "ndarray-pixels": { + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/ndarray-pixels/-/ndarray-pixels-5.0.1.tgz", + "integrity": "sha512-IBtrpefpqlI8SPDCGjXk4v5NV5z7r3JSuCbfuEEXaM0vrOJtNGgYUa4C3Lt5H+qWdYF4BCPVFsnXhNC7QvZwkw==", + "requires": { + "@types/ndarray": "^1.0.14", + "ndarray": "^1.0.19", + "ndarray-ops": "^1.2.2", + "sharp": "^0.34.0" + } + }, + "onml": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/onml/-/onml-1.2.0.tgz", + "integrity": "sha512-olqYAg18XoHAhm7tK9DdBCOVdts70DGmMgCNLOWyqZokht2utgGSKBB4JHi6pBZpmioAhcYlxK+91L3tsrz+GA==", + "requires": { + "sax": "^1.2.1" + } + }, + "picocolors": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.1.1.tgz", + "integrity": "sha512-xceH2snhtb5M9liqDsmEw56le376mTZkEX/jEb/RxNFyegNul7eNslCXP9FDj/Lcu0X8KEyMceP2ntpaHrDEVA==", + "dev": true + }, + "picomatch": { + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.2.tgz", + "integrity": "sha512-M7BAV6Rlcy5u+m6oPhAPFgJTzAioX/6B0DxyvDlo9l8+T3nLKbrczg2WLUyzd45L8RqfUMyGPzekbMvX2Ldkwg==", + "dev": true + }, + "postcss": { + "version": "8.5.3", + "resolved": "https://registry.npmjs.org/postcss/-/postcss-8.5.3.tgz", + "integrity": "sha512-dle9A3yYxlBSrt8Fu+IpjGT8SY8hN0mlaA6GY8t0P5PjIOZemULz/E2Bnm/2dcUOena75OTNkHI76uZBNUUq3A==", + "dev": true, + "requires": { + "nanoid": "^3.3.8", + "picocolors": "^1.1.1", + "source-map-js": "^1.2.1" + } + }, + "property-graph": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/property-graph/-/property-graph-4.0.0.tgz", + "integrity": "sha512-I0hojAJfTbSCZy3y6xyK29eayxo14v1bj1VPiDkHjTdz33SV6RdfMz2AHnf4ai62Vng2mN5GkaKahkooBIo9gA==" + }, + "rollup": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/rollup/-/rollup-4.40.1.tgz", + "integrity": "sha512-C5VvvgCCyfyotVITIAv+4efVytl5F7wt+/I2i9q9GZcEXW9BP52YYOXC58igUi+LFZVHukErIIqQSWwv/M3WRw==", + "dev": true, + "requires": { + "@rollup/rollup-android-arm-eabi": "4.40.1", + "@rollup/rollup-android-arm64": "4.40.1", + "@rollup/rollup-darwin-arm64": "4.40.1", + "@rollup/rollup-darwin-x64": "4.40.1", + "@rollup/rollup-freebsd-arm64": "4.40.1", + "@rollup/rollup-freebsd-x64": "4.40.1", + "@rollup/rollup-linux-arm-gnueabihf": "4.40.1", + "@rollup/rollup-linux-arm-musleabihf": "4.40.1", + "@rollup/rollup-linux-arm64-gnu": "4.40.1", + "@rollup/rollup-linux-arm64-musl": "4.40.1", + "@rollup/rollup-linux-loongarch64-gnu": "4.40.1", + "@rollup/rollup-linux-powerpc64le-gnu": "4.40.1", + "@rollup/rollup-linux-riscv64-gnu": "4.40.1", + "@rollup/rollup-linux-riscv64-musl": "4.40.1", + "@rollup/rollup-linux-s390x-gnu": "4.40.1", + "@rollup/rollup-linux-x64-gnu": "4.40.1", + "@rollup/rollup-linux-x64-musl": "4.40.1", + "@rollup/rollup-win32-arm64-msvc": "4.40.1", + "@rollup/rollup-win32-ia32-msvc": "4.40.1", + "@rollup/rollup-win32-x64-msvc": "4.40.1", + "@types/estree": "1.0.7", + "fsevents": "~2.3.2" + } + }, + "rxjs": { + "version": "7.5.5", + "resolved": "https://registry.npmjs.org/rxjs/-/rxjs-7.5.5.tgz", + "integrity": "sha512-sy+H0pQofO95VDmFLzyaw9xNJU4KTRSwQIGM6+iG3SypAtCiLDzpeG8sJrNCWn2Up9km+KhkvTdbkrdy+yzZdw==", + "requires": { + "tslib": "^2.1.0" + } + }, + "sax": { + "version": "1.4.3", + "resolved": "https://registry.npmjs.org/sax/-/sax-1.4.3.tgz", + "integrity": "sha512-yqYn1JhPczigF94DMS+shiDMjDowYO6y9+wB/4WgO0Y19jWYk0lQ4tuG5KI7kj4FTp1wxPj5IFfcrz/s1c3jjQ==" + }, + "semver": { + "version": "7.7.3", + "resolved": "https://registry.npmjs.org/semver/-/semver-7.7.3.tgz", + "integrity": "sha512-SdsKMrI9TdgjdweUSR9MweHA4EJ8YxHn8DFaDisvhVlUOe4BF1tLD7GAj0lIqWVl+dPb/rExr0Btby5loQm20Q==" + }, + "sharp": { + "version": "0.34.5", + "resolved": "https://registry.npmjs.org/sharp/-/sharp-0.34.5.tgz", + "integrity": "sha512-Ou9I5Ft9WNcCbXrU9cMgPBcCK8LiwLqcbywW3t4oDV37n1pzpuNLsYiAV8eODnjbtQlSDwZ2cUEeQz4E54Hltg==", + "requires": { + "@img/colour": "^1.0.0", + "@img/sharp-darwin-arm64": "0.34.5", + "@img/sharp-darwin-x64": "0.34.5", + "@img/sharp-libvips-darwin-arm64": "1.2.4", + "@img/sharp-libvips-darwin-x64": "1.2.4", + "@img/sharp-libvips-linux-arm": "1.2.4", + "@img/sharp-libvips-linux-arm64": "1.2.4", + "@img/sharp-libvips-linux-ppc64": "1.2.4", + "@img/sharp-libvips-linux-riscv64": "1.2.4", + "@img/sharp-libvips-linux-s390x": "1.2.4", + "@img/sharp-libvips-linux-x64": "1.2.4", + "@img/sharp-libvips-linuxmusl-arm64": "1.2.4", + "@img/sharp-libvips-linuxmusl-x64": "1.2.4", + "@img/sharp-linux-arm": "0.34.5", + "@img/sharp-linux-arm64": "0.34.5", + "@img/sharp-linux-ppc64": "0.34.5", + "@img/sharp-linux-riscv64": "0.34.5", + "@img/sharp-linux-s390x": "0.34.5", + "@img/sharp-linux-x64": "0.34.5", + "@img/sharp-linuxmusl-arm64": "0.34.5", + "@img/sharp-linuxmusl-x64": "0.34.5", + "@img/sharp-wasm32": "0.34.5", + "@img/sharp-win32-arm64": "0.34.5", + "@img/sharp-win32-ia32": "0.34.5", + "@img/sharp-win32-x64": "0.34.5", + "detect-libc": "^2.1.2", + "semver": "^7.7.3" + } + }, + "source-map-js": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/source-map-js/-/source-map-js-1.2.1.tgz", + "integrity": "sha512-UXWMKhLOwVKb728IUtQPXxfYU+usdybtUrK/8uGE8CQMvrhOpwvzDBwj0QhSL7MQc7vIsISBG8VQ8+IDQxpfQA==", + "dev": true + }, + "three": { + "version": "0.182.0", + "resolved": "https://registry.npmjs.org/three/-/three-0.182.0.tgz", + "integrity": "sha512-GbHabT+Irv+ihI1/f5kIIsZ+Ef9Sl5A1Y7imvS5RQjWgtTPfPnZ43JmlYI7NtCRDK9zir20lQpfg8/9Yd02OvQ==" + }, + "tinyglobby": { + "version": "0.2.13", + "resolved": "https://registry.npmjs.org/tinyglobby/-/tinyglobby-0.2.13.tgz", + "integrity": "sha512-mEwzpUgrLySlveBwEVDMKk5B57bhLPYovRfPAXD5gA/98Opn0rCDj3GtLwFvCvH5RK9uPCExUROW5NjDwvqkxw==", + "dev": true, + "requires": { + "fdir": "^6.4.4", + "picomatch": "^4.0.2" + } + }, + "ts-replace-all": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/ts-replace-all/-/ts-replace-all-1.0.0.tgz", + "integrity": "sha512-6uBtdkw3jHXkPtx/e9xB/5vcngMm17CyJYsS2YZeQ+9FdRnt6Ev5g931Sg2p+dxbtMGoCm13m3ax/obicTZIkQ==", + "requires": { + "core-js": "^3.4.1" + } + }, + "tslib": { + "version": "2.8.1", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.8.1.tgz", + "integrity": "sha512-oJFu94HQb+KVduSUQL7wnpmqnfmLsOA/nAh6b6EH0wCEoK0/mPeXU6c3wKDV83MkOuHPRHtSXKKU99IBazS/2w==" + }, + "typescript": { + "version": "5.8.3", + "resolved": "https://registry.npmjs.org/typescript/-/typescript-5.8.3.tgz", + "integrity": "sha512-p1diW6TqL9L07nNxvRMM7hMMw4c5XOo/1ibL4aAIGmSAt9slTE1Xgw5KWuof2uTOvCg9BY7ZRi+GaF+7sfgPeQ==", + "dev": true + }, + "uniq": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/uniq/-/uniq-1.0.1.tgz", + "integrity": "sha512-Gw+zz50YNKPDKXs+9d+aKAjVwpjNwqzvNpLigIruT4HA9lMZNdMqs9x07kKHB/L9WRzqp4+DlTU5s4wG2esdoA==" + }, + "verb-nurbs-web": { + "version": "2.1.3", + "resolved": "https://registry.npmjs.org/verb-nurbs-web/-/verb-nurbs-web-2.1.3.tgz", + "integrity": "sha512-2PvI2bx7dn0r3kWtk+JuDIDZ+p7I5Piu8y6/ZNhUVpilOyHKK1nNzLHtgown+dFOmBnKnuAKIMh1xn/5kzrxZA==", + "requires": { + "webworker-threads": "^0.7.12" + } + }, + "vite": { + "version": "6.3.4", + "resolved": "https://registry.npmjs.org/vite/-/vite-6.3.4.tgz", + "integrity": "sha512-BiReIiMS2fyFqbqNT/Qqt4CVITDU9M9vE+DKcVAsB+ZV0wvTKd+3hMbkpxz1b+NmEDMegpVbisKiAZOnvO92Sw==", + "dev": true, + "requires": { + "esbuild": "^0.25.0", + "fdir": "^6.4.4", + "fsevents": "~2.3.3", + "picomatch": "^4.0.2", + "postcss": "^8.5.3", + "rollup": "^4.34.9", + "tinyglobby": "^0.2.13" + } + }, + "webworker-threads": { + "version": "0.7.17", + "resolved": "https://registry.npmjs.org/webworker-threads/-/webworker-threads-0.7.17.tgz", + "integrity": "sha512-Y2w2aXBbDLk9IzTEb9u+MsODC3s4YlGI7g4h0t+1OAwIO8yBI9rQL35ZYlyayiCuWu1dZMH/P7kGU8OwW7YsyA==", + "optional": true, + "requires": { + "bindings": "^1.3.0", + "nan": "^2.11.0" + } + } + } +} diff --git a/examples/vite/threejs/starter-template-full/package.json b/examples/vite/threejs/starter-template-full/package.json new file mode 100644 index 00000000..dbc79655 --- /dev/null +++ b/examples/vite/threejs/starter-template-full/package.json @@ -0,0 +1,19 @@ +{ + "name": "vite-typescript-starter", + "private": true, + "version": "0.0.0", + "type": "module", + "scripts": { + "dev": "vite", + "build": "tsc && vite build", + "preview": "vite preview" + }, + "dependencies": { + "@bitbybit-dev/threejs": "0.21.0" + }, + "devDependencies": { + "typescript": "~5.8.3", + "vite": "^6.3.2", + "@types/three": "0.182.0" + } +} diff --git a/examples/vite/threejs/starter-template-full/public/vite.svg b/examples/vite/threejs/starter-template-full/public/vite.svg new file mode 100644 index 00000000..e7b8dfb1 --- /dev/null +++ b/examples/vite/threejs/starter-template-full/public/vite.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/examples/vite/threejs/starter-template-full/src/main.ts b/examples/vite/threejs/starter-template-full/src/main.ts new file mode 100644 index 00000000..79fea060 --- /dev/null +++ b/examples/vite/threejs/starter-template-full/src/main.ts @@ -0,0 +1,575 @@ +import "./style.css"; // Basic styling +import { BitByBitBase, Inputs, initBitByBit, initThreeJS, type InitBitByBitOptions, type OrbitCameraController } from "@bitbybit-dev/threejs"; + +// Store the orbit camera controller globally so bitbybit can access it + +// --- 1. Main Application Entry Point --- +start(); + +async function start() { + // --- 1. Initialize Three.js Scene with Orbit Camera using the library helper --- + // This creates scene, renderer, lights, shadows, ground, and orbit camera in one call + const sceneOptions = new Inputs.ThreeJSScene.InitThreeJSDto(); + sceneOptions.canvasId = "three-canvas"; + sceneOptions.sceneSize = 200; + sceneOptions.enableShadows = true; + sceneOptions.enableGround = true; + sceneOptions.groundColor = "#333333"; + sceneOptions.groundCenter = [0, -75, 0]; + sceneOptions.orbitCameraOptions = new Inputs.ThreeJSCamera.OrbitCameraDto( + 120, // distance + 25, // pitch + 45 // yaw + ); + sceneOptions.orbitCameraOptions.inertiaFactor = 0.1; + sceneOptions.orbitCameraOptions.distanceSensitivity = 0.15; + + const { scene, startAnimationLoop } = initThreeJS(sceneOptions); + + // Start the animation loop (handles camera updates and rendering) + startAnimationLoop(); + + // Create an instance of BitByBitBase + const bitbybit = new BitByBitBase(); + + // --- 2. Configure and Initialize BitByBit --- + // Single options object for both workers and kernels + const options: InitBitByBitOptions = { + enableOCCT: true, + enableJSCAD: true, + enableManifold: true, + // loadFonts: ["roboto"], // Optional: specify fonts to load, or omit to skip font loading + }; + + // Initialize BitByBit in a single call - workers are created from CDN automatically! + await initBitByBit(scene, bitbybit, options); + + // --- 3. Create Geometry with Active Kernels --- + if (options.enableOCCT) { + await createOCCTGeometry(bitbybit, "#ff0000"); // Red + } + if (options.enableManifold) { + await createManifoldGeometry(bitbybit, "#00ff00"); // Green + } + if (options.enableJSCAD) { + await createJSCADGeometry(bitbybit, "#0000ff"); // Blue + } + + // --- 4. Create Drawing Examples (Lines, Points, Curves, etc.) --- + await createDrawingExamples(bitbybit); + + // --- 5. Create Textured OCCT Cube Example --- + if (options.enableOCCT) { + await createTexturedOCCTCube(bitbybit); + } +} + +// --- 6. Geometry Creation Functions (Examples) --- +async function createOCCTGeometry(bitbybit: BitByBitBase, color: string) { + console.log("Creating OCCT geometry..."); + const cubeOptions = new Inputs.OCCT.CubeDto(); + cubeOptions.size = 25; + cubeOptions.center = [0, 0, 0]; + + const cube = await bitbybit.occt.shapes.solid.createCube(cubeOptions); + + const filletOptions = + new Inputs.OCCT.FilletDto(); + filletOptions.shape = cube; + filletOptions.radius = 4; + const roundedCube = await bitbybit.occt.fillets.filletEdges(filletOptions); + + const drawOptions = new Inputs.Draw.DrawOcctShapeOptions(); + drawOptions.edgeWidth = 5; + drawOptions.faceColour = color; + drawOptions.drawVertices = true; + drawOptions.vertexSize = 0.5; + drawOptions.vertexColour = "#ffffff"; + await bitbybit.draw.drawAnyAsync({ + entity: roundedCube, + options: drawOptions, + }); + console.log("OCCT geometry created and drawn."); +} + +async function createManifoldGeometry(bitbybit: BitByBitBase, color: string) { + console.log("Creating Manifold geometry..."); + const sphereOptions = new Inputs.Manifold.SphereDto(); + sphereOptions.radius = 15; + const sphere = await bitbybit.manifold.manifold.shapes.sphere(sphereOptions); + + const cubeOptions = new Inputs.Manifold.CubeDto(); + cubeOptions.size = 25; + const cube = await bitbybit.manifold.manifold.shapes.cube(cubeOptions); + + const diffedShape = await bitbybit.manifold.manifold.booleans.differenceTwo({ + manifold1: cube, + manifold2: sphere, + }); + + const translationOptions = + new Inputs.Manifold.TranslateDto(); + translationOptions.manifold = diffedShape; + translationOptions.vector = [0, -40, 0]; // Position below OCCT + const movedShape = await bitbybit.manifold.manifold.transforms.translate( + translationOptions + ); + + const drawOptions = new Inputs.Draw.DrawManifoldOrCrossSectionOptions(); + drawOptions.faceColour = color; + await bitbybit.draw.drawAnyAsync({ + entity: movedShape, + options: drawOptions, + }); + console.log("Manifold geometry created and drawn."); +} + +async function createJSCADGeometry(bitbybit: BitByBitBase, color: string) { + console.log("Creating JSCAD geometry..."); + const geodesicSphereOptions = new Inputs.JSCAD.GeodesicSphereDto(); + geodesicSphereOptions.radius = 15; + geodesicSphereOptions.center = [0, 40, 0]; // Position above OCCT + const geodesicSphere = await bitbybit.jscad.shapes.geodesicSphere( + geodesicSphereOptions + ); + + // Example: Create another simple sphere for a boolean operation + const sphereOptions = new Inputs.JSCAD.SphereDto(); + sphereOptions.radius = 10; // Smaller sphere + sphereOptions.center = [5, 45, 0]; // Slightly offset + const simpleSphere = await bitbybit.jscad.shapes.sphere(sphereOptions); + + const unionOptions = new Inputs.JSCAD.BooleanTwoObjectsDto(); + unionOptions.first = geodesicSphere; + unionOptions.second = simpleSphere; + const unionShape = await bitbybit.jscad.booleans.unionTwo(unionOptions); + + const drawOptions = new Inputs.Draw.DrawBasicGeometryOptions(); + drawOptions.colours = color; // Note: 'colours' for JSCAD draw options + await bitbybit.draw.drawAnyAsync({ + entity: unionShape, + options: drawOptions, + }); + console.log("JSCAD geometry created and drawn."); +} + +async function createTexturedOCCTCube(bitbybit: BitByBitBase) { + console.log("Creating textured OCCT cube..."); + + // Create texture from URL + const textureOptions = new Inputs.Draw.GenericTextureDto(); + textureOptions.url = "https://cdn.polyhaven.com/asset_img/primary/worn_asphalt.png?height=760&quality=95"; + textureOptions.uScale = 0.05; + textureOptions.vScale = 0.05; + const texture = await bitbybit.draw.createTexture(textureOptions); + + // Create material with texture + const materialOptions = new Inputs.Draw.GenericPBRMaterialDto(); + materialOptions.baseColorTexture = texture; + materialOptions.baseColor = "#ffffff"; // White to show texture colors accurately + const material = await bitbybit.draw.createPBRMaterial(materialOptions); + + // Create OCCT cube + const cubeOptions = new Inputs.OCCT.CubeDto(); + cubeOptions.size = 20; + cubeOptions.center = [-50, 0, -50]; + const cube = await bitbybit.occt.shapes.solid.createCube(cubeOptions); + + // Draw cube with material + const drawOptions = new Inputs.Draw.DrawOcctShapeOptions(); + drawOptions.faceMaterial = material; + drawOptions.backFaceOpacity = 1; + await bitbybit.draw.drawAnyAsync({ + entity: cube, + options: drawOptions, + }); + + console.log("Textured OCCT cube created and drawn."); +} + +// --- 7. Drawing Examples Function --- +async function createDrawingExamples(bitbybit: BitByBitBase) { + console.log("Creating drawing examples..."); + + // Example 1: Draw a single point + const point = [60, 0, 0] as Inputs.Base.Point3; + const pointDrawOptions = new Inputs.Draw.DrawBasicGeometryOptions(); + pointDrawOptions.colours = "#ffff00"; // Yellow + pointDrawOptions.size = 2; + await bitbybit.draw.drawAnyAsync({ + entity: point, + options: pointDrawOptions, + }); + console.log("Single point drawn."); + + // Example 2: Draw multiple points + const points = [ + [60, 5, 0], + [60, 10, 0], + [60, 15, 0], + [60, 20, 0], + [60, 25, 0], + [60, 30, 0], + [60, 35, 0], + ] as Inputs.Base.Point3[]; + const pointsDrawOptions = new Inputs.Draw.DrawBasicGeometryOptions(); + pointsDrawOptions.colours = ["#ff00ff", "#ff0000", "#00ff00", "#0000ff"]; // Magenta + pointsDrawOptions.size = 1.5; + pointsDrawOptions.colorMapStrategy = Inputs.Base.colorMapStrategyEnum.repeatColors; + await bitbybit.draw.drawAnyAsync({ + entity: points, + options: pointsDrawOptions, + }); + console.log("Multiple points drawn."); + + // Example 3: Draw a single polyline + const polyline = { + points: [ + [70, -10, 0], + [70, 0, 10], + [80, 0, 10], + [80, -10, 0], + ], + } as Inputs.Base.Polyline3; + const polylineDrawOptions = new Inputs.Draw.DrawBasicGeometryOptions(); + polylineDrawOptions.colours = ["#00ffff"]; // Cyan + polylineDrawOptions.size = 3; + await bitbybit.draw.drawAnyAsync({ + entity: polyline, + options: polylineDrawOptions, + }); + console.log("Polyline drawn."); + + // Example 4: Draw multiple polylines with different colors + const polylines = [ + { + points: [ + [90, -10, 0], + [90, 0, 0], + [100, 0, 0], + ], + }, + { + points: [ + [90, -10, 5], + [90, 0, 5], + [100, 0, 5], + ], + }, + { + points: [ + [90, -10, 10], + [90, 0, 10], + [100, 0, 10], + ], + }, + ]; + const polylinesDrawOptions = new Inputs.Draw.DrawBasicGeometryOptions(); + polylinesDrawOptions.colours = ["#ff0000", "#00ff00", "#0000ff"]; // RGB + polylinesDrawOptions.size = 2; + await bitbybit.draw.drawAnyAsync({ + entity: polylines as Inputs.Base.Polyline3[], + options: polylinesDrawOptions, + }); + console.log("Multiple polylines drawn."); + + const segments = [ + [ + [60, -20, 0], + [70, -20, 0], + ], + [ + [65, -25, 0], + [65, -15, 0], + ], + [ + [60, -20, -5], + [70, -20, 5], + ], + ] as Inputs.Base.Segment3[]; + const segmentsDrawOptions = new Inputs.Draw.DrawBasicGeometryOptions(); + segmentsDrawOptions.colours = ["#ffff00", "#ff00ff", "#00ffff"]; // Yellow, Magenta, Cyan + segmentsDrawOptions.size = 2.5; + await bitbybit.draw.drawAnyAsync({ + entity: segments, + options: segmentsDrawOptions, + }); + console.log("Line segments drawn."); + + // Example 6: Draw a Verb NURBS curve + // Create a simple NURBS curve through control points + const controlPoints = [ + [-60, -10, 0], + [-50, 0, 5], + [-40, -5, 10], + [-30, 10, 5], + [-20, 0, 0], + ] as Inputs.Base.Point3[]; + + // Create a NURBS curve (degree 3) + const curve = bitbybit.verb.curve.createCurveByPoints({ + points: controlPoints, + degree: 3, + }); + + const curveDrawOptions = new Inputs.Draw.DrawBasicGeometryOptions(); + curveDrawOptions.colours = "#ff8800"; // Orange + curveDrawOptions.size = 3; + await bitbybit.draw.drawAnyAsync({ + entity: curve, + options: curveDrawOptions, + }); + console.log("Verb curve drawn."); + + // Example 7: Draw a Verb NURBS surface by lofting curves + // Create curves that will be lofted to form a surface + const curve1Points = [ + [-60, 20, -5], + [-50, 20, 0], + [-40, 20, -5], + ] as Inputs.Base.Point3[]; + + const curve2Points = [ + [-60, 30, 0], + [-50, 30, 5], + [-40, 30, 0], + ] as Inputs.Base.Point3[]; + + const curve3Points = [ + [-60, 40, -5], + [-50, 40, 0], + [-40, 40, -5], + ] as Inputs.Base.Point3[]; + + // Create the curves + const curve1 = bitbybit.verb.curve.createCurveByPoints({ + points: curve1Points, + degree: 2, + }); + + const curve2 = bitbybit.verb.curve.createCurveByPoints({ + points: curve2Points, + degree: 2, + }); + + const curve3 = bitbybit.verb.curve.createCurveByPoints({ + points: curve3Points, + degree: 2, + }); + + // Loft the curves to create a surface + const surface = bitbybit.verb.surface.createSurfaceByLoftingCurves({ + curves: [curve3, curve2, curve1], + degreeV: 2, + }); + + const surfaceDrawOptions = new Inputs.Draw.DrawBasicGeometryOptions(); + surfaceDrawOptions.colours = "#8800ff"; // Purple + surfaceDrawOptions.opacity = 0.8; + await bitbybit.draw.drawAnyAsync({ + entity: surface, + options: surfaceDrawOptions, + }); + console.log("Verb surface drawn."); + + // Example 8: Draw a 30x30x30 grid of points with alternating blue and white colors + // This tests GPU instancing performance with 27,000 points + console.log("Creating 30x30x30 point grid (27,000 points)..."); + const gridSize = 30; + const spacing = 1.5; + const gridOffset = [-150, 0, 0]; // Move grid away from other geometry + + const gridPoints: Inputs.Base.Point3[] = []; + const gridColors: string[] = []; + + for (let x = 0; x < gridSize; x++) { + for (let y = 0; y < gridSize; y++) { + for (let z = 0; z < gridSize; z++) { + gridPoints.push([ + gridOffset[0] + x * spacing, + gridOffset[1] + y * spacing, + gridOffset[2] + z * spacing + ]); + // Alternating blue and white based on checkerboard pattern + const isBlue = (x + y + z) % 2 === 0; + gridColors.push(isBlue ? "#0066ff" : "#ffffff"); + } + } + } + + const gridDrawOptions = new Inputs.Draw.DrawBasicGeometryOptions(); + gridDrawOptions.colours = gridColors; + gridDrawOptions.size = 0.4; + gridDrawOptions.colorMapStrategy = Inputs.Base.colorMapStrategyEnum.lastColorRemainder; + + console.time("Draw 27,000 points"); + await bitbybit.draw.drawAnyAsync({ + entity: gridPoints, + options: gridDrawOptions, + }); + console.timeEnd("Draw 27,000 points"); + console.log("30x30x30 point grid drawn with GPU instancing."); + + // Example 9: Draw a 30x30x30 grid of polylines with alternating colors + // Creates lines along X, Y, and Z axes forming a 3D grid + console.log("Creating 30x30x30 polyline grid..."); + const polylineGridSize = 30; + const polylineSpacing = 1.5; + const polylineGridOffset = [-150, -60, 0]; // Position below the point grid + + const gridPolylines: Inputs.Base.Polyline3[] = []; + const polylineColors: string[] = []; + + // Create lines along X axis (for each Y,Z position) + for (let y = 0; y < polylineGridSize; y++) { + for (let z = 0; z < polylineGridSize; z++) { + const startX = polylineGridOffset[0]; + const endX = polylineGridOffset[0] + (polylineGridSize - 1) * polylineSpacing; + const posY = polylineGridOffset[1] + y * polylineSpacing; + const posZ = polylineGridOffset[2] + z * polylineSpacing; + + gridPolylines.push({ + points: [ + [startX, posY, posZ], + [endX, posY, posZ] + ] + }); + // Alternating colors based on position + const isOrange = (y + z) % 2 === 0; + polylineColors.push(isOrange ? "#ff6600" : "#00ffcc"); + } + } + + // Create lines along Y axis (for each X,Z position) + for (let x = 0; x < polylineGridSize; x++) { + for (let z = 0; z < polylineGridSize; z++) { + const posX = polylineGridOffset[0] + x * polylineSpacing; + const startY = polylineGridOffset[1]; + const endY = polylineGridOffset[1] + (polylineGridSize - 1) * polylineSpacing; + const posZ = polylineGridOffset[2] + z * polylineSpacing; + + gridPolylines.push({ + points: [ + [posX, startY, posZ], + [posX, endY, posZ] + ] + }); + const isPurple = (x + z) % 2 === 0; + polylineColors.push(isPurple ? "#9933ff" : "#ffff00"); + } + } + + // Create lines along Z axis (for each X,Y position) + for (let x = 0; x < polylineGridSize; x++) { + for (let y = 0; y < polylineGridSize; y++) { + const posX = polylineGridOffset[0] + x * polylineSpacing; + const posY = polylineGridOffset[1] + y * polylineSpacing; + const startZ = polylineGridOffset[2]; + const endZ = polylineGridOffset[2] + (polylineGridSize - 1) * polylineSpacing; + + gridPolylines.push({ + points: [ + [posX, posY, startZ], + [posX, posY, endZ] + ] + }); + const isPink = (x + y) % 2 === 0; + polylineColors.push(isPink ? "#ff0099" : "#00ff66"); + } + } + + const polylineGridDrawOptions = new Inputs.Draw.DrawBasicGeometryOptions(); + polylineGridDrawOptions.colours = polylineColors; + polylineGridDrawOptions.size = 1; + polylineGridDrawOptions.colorMapStrategy = Inputs.Base.colorMapStrategyEnum.lastColorRemainder; + + console.log(`Drawing ${gridPolylines.length} polylines...`); + console.time("Draw polyline grid"); + await bitbybit.draw.drawAnyAsync({ + entity: gridPolylines, + options: polylineGridDrawOptions, + }); + console.timeEnd("Draw polyline grid"); + console.log("30x30x30 polyline grid drawn with per-polyline colors."); + + // --- Arrow Examples --- + // Example: Draw a single polyline with an arrow at the end + const arrowPolyline = { + points: [ + [-80, 0, 0], + [-80, 10, 5], + [-70, 15, 10], + [-60, 10, 5], + ], + } as Inputs.Base.Polyline3; + const arrowPolylineOptions = new Inputs.Draw.DrawBasicGeometryOptions(); + arrowPolylineOptions.colours = "#00ff88"; // Green + arrowPolylineOptions.size = 3; + arrowPolylineOptions.arrowSize = 3; // Arrow size + arrowPolylineOptions.arrowAngle = 25; // Arrow angle in degrees + await bitbybit.draw.drawAnyAsync({ + entity: arrowPolyline, + options: arrowPolylineOptions, + }); + console.log("Polyline with arrow drawn."); + + // Example: Draw multiple polylines with arrows (different sizes) + const arrowPolylines = [ + { + points: [ + [-80, -30, 0], + [-70, -25, 0], + [-60, -30, 0], + ], + }, + { + points: [ + [-80, -35, 0], + [-70, -30, 0], + [-60, -35, 0], + ], + }, + { + points: [ + [-80, -40, 0], + [-70, -35, 0], + [-60, -40, 0], + ], + }, + ] as Inputs.Base.Polyline3[]; + const arrowPolylinesOptions = new Inputs.Draw.DrawBasicGeometryOptions(); + arrowPolylinesOptions.colours = ["#ff0000", "#00ff00", "#0000ff"]; // RGB + arrowPolylinesOptions.size = 2; + arrowPolylinesOptions.arrowSize = 2.5; + arrowPolylinesOptions.arrowAngle = 30; + await bitbybit.draw.drawAnyAsync({ + entity: arrowPolylines, + options: arrowPolylinesOptions, + }); + console.log("Multiple polylines with arrows drawn."); + + // Example: Draw OCCT wire with edge arrows to show orientation + const wirePoints = [ + [-80, -60, 0], + [-70, -55, 5], + [-60, -60, 0], + [-50, -65, -5], + ] as Inputs.Base.Point3[]; + const wire = await bitbybit.occt.shapes.wire.createPolylineWire({ + points: wirePoints, + }); + const wireDrawOptions = new Inputs.Draw.DrawOcctShapeOptions(); + wireDrawOptions.edgeColour = "#ff8800"; // Orange edges + wireDrawOptions.edgeWidth = 3; + wireDrawOptions.drawEdges = true; + wireDrawOptions.drawFaces = false; + wireDrawOptions.edgeArrowSize = 3; // Arrow size on edges + wireDrawOptions.edgeArrowAngle = 25; // Arrow angle + await bitbybit.draw.drawAnyAsync({ + entity: wire, + options: wireDrawOptions, + }); + console.log("OCCT wire with edge orientation arrows drawn."); + + console.log("All drawing examples completed."); +} diff --git a/examples/vite/threejs/starter-template-full/src/style.css b/examples/vite/threejs/starter-template-full/src/style.css new file mode 100644 index 00000000..72e40599 --- /dev/null +++ b/examples/vite/threejs/starter-template-full/src/style.css @@ -0,0 +1,25 @@ +body { + margin: 0px; + overflow: hidden; +} + +a.logo { + position: absolute; + color: white; + vertical-align: middle; + bottom: 10px; + left: 10px; + font-family: 'Courier New', Courier, monospace; + text-decoration: none; + width: 100%; +} + +.logo { + margin-bottom: 20px; + text-align: center; +} + +.logo img { + width: 50px; + height: 50px; +} diff --git a/examples/vite/threejs/starter-template-full/src/vite-env.d.ts b/examples/vite/threejs/starter-template-full/src/vite-env.d.ts new file mode 100644 index 00000000..11f02fe2 --- /dev/null +++ b/examples/vite/threejs/starter-template-full/src/vite-env.d.ts @@ -0,0 +1 @@ +/// diff --git a/examples/vite/threejs/starter-template-full/tsconfig.json b/examples/vite/threejs/starter-template-full/tsconfig.json new file mode 100644 index 00000000..a22caba9 --- /dev/null +++ b/examples/vite/threejs/starter-template-full/tsconfig.json @@ -0,0 +1,25 @@ +{ + "compilerOptions": { + "target": "ES2020", + "useDefineForClassFields": true, + "module": "ESNext", + "lib": ["ES2020", "DOM", "DOM.Iterable"], + "skipLibCheck": true, + + /* Bundler mode */ + "moduleResolution": "bundler", + "allowImportingTsExtensions": true, + "verbatimModuleSyntax": true, + "moduleDetection": "force", + "noEmit": true, + + /* Linting */ + "strict": true, + "noUnusedLocals": true, + "noUnusedParameters": true, + "erasableSyntaxOnly": true, + "noFallthroughCasesInSwitch": true, + "noUncheckedSideEffectImports": true + }, + "include": ["src"] +} diff --git a/examples/vite/threejs/starter-template/src/main.ts b/examples/vite/threejs/starter-template/src/main.ts index bcc25122..838581cc 100644 --- a/examples/vite/threejs/starter-template/src/main.ts +++ b/examples/vite/threejs/starter-template/src/main.ts @@ -1,59 +1,28 @@ -import "./style.css"; // Basic styling -import { BitByBitBase, Inputs, initBitbybit, type InitBitbybitOptions, type OrbitCameraController } from "@bitbybit-dev/threejs"; -import { - Color, - HemisphereLight, - Scene, - WebGLRenderer, -} from "three"; +import "./style.css"; +import { BitByBitBase, Inputs, initBitByBit, initThreeJS, type InitBitByBitOptions } from "@bitbybit-dev/threejs"; -// Store the orbit camera controller globally so bitbybit can access it -let orbitCameraController: OrbitCameraController | null = null; -// --- 1. Main Application Entry Point --- start(); async function start() { - // Initialize basic Three.js scene - const { scene, renderer } = initThreeJS(); - - // Create an instance of BitByBitBase for Three.js + const sceneOptions = new Inputs.ThreeJSScene.InitThreeJSDto(); + sceneOptions.canvasId = "three-canvas"; + sceneOptions.orbitCameraOptions = new Inputs.ThreeJSCamera.OrbitCameraDto(); + sceneOptions.orbitCameraOptions.yaw = 45; + sceneOptions.orbitCameraOptions.pitch = 25; + sceneOptions.orbitCameraOptions.distance = 12.0; + const { scene, startAnimationLoop } = initThreeJS(sceneOptions); + startAnimationLoop(); const bitbybit = new BitByBitBase(); - // --- 2. Configure and Initialize BitByBit --- - // Single options object for both workers and kernels - const options: InitBitbybitOptions = { + const options: InitBitByBitOptions = { enableOCCT: true, enableJSCAD: true, enableManifold: true, - // loadFonts: ["roboto"], // Optional: specify fonts to load, or omit to skip font loading }; - // Initialize BitByBit in a single call - workers are created from CDN automatically! - await initBitbybit(scene, bitbybit, options); - - // --- 2.5. Setup BitByBit Orbit Camera --- - // Setup orbit camera controls using bitbybit library - const cameraOptions = new Inputs.ThreeJSCamera.OrbitCameraDto(); - cameraOptions.distance = 120; - cameraOptions.pitch = 25; - cameraOptions.yaw = 45; - cameraOptions.frameOnStart = false; - cameraOptions.inertiaFactor = 0.1; - cameraOptions.distanceSensitivity = 0.15; - cameraOptions.domElement = renderer.domElement; - orbitCameraController = bitbybit.three.camera.orbitCamera.create(cameraOptions); - - // Update the render loop to use the new camera - const animate = () => { - if (orbitCameraController) { - orbitCameraController.update(0.016); // ~60fps delta time - renderer.render(scene, orbitCameraController.camera); - } - }; - renderer.setAnimationLoop(animate); + await initBitByBit(scene, bitbybit, options); - // --- 3. Create Geometry with Active Kernels --- if (options.enableOCCT) { await createOCCTGeometry(bitbybit, "#ff0000"); // Red } @@ -64,200 +33,41 @@ async function start() { await createJSCADGeometry(bitbybit, "#0000ff"); // Blue } - // --- 4. Create Drawing Examples (Lines, Points, Curves, etc.) --- - await createDrawingExamples(bitbybit); - - // --- 5. Create Textured OCCT Cube Example --- - if (options.enableOCCT) { - await createTexturedOCCTCube(bitbybit); - } } -// --- 4. Three.js Scene Initialization --- -function initThreeJS() { - const domNode = document.getElementById("three-canvas") as HTMLCanvasElement; - - const scene = new Scene(); - scene.background = new Color(0x1a1c1f); // Set background color - - const light = new HemisphereLight(0xffffff, 0x444444, 2); // Adjusted intensity - scene.add(light); - - const renderer = new WebGLRenderer({ antialias: true, canvas: domNode }); - renderer.setSize(window.innerWidth, window.innerHeight); - // Set pixel ratio for sharper rendering (similar to BabylonJS hardware scaling level) - // Higher values = sharper but more GPU intensive. Use 1 for performance, devicePixelRatio for quality. - renderer.setPixelRatio(window.devicePixelRatio); - - const onWindowResize = () => { - if (orbitCameraController) { - orbitCameraController.camera.aspect = window.innerWidth / window.innerHeight; - orbitCameraController.camera.updateProjectionMatrix(); - } - renderer.setSize(window.innerWidth, window.innerHeight); - }; - window.addEventListener("resize", onWindowResize, false); - - return { scene, renderer }; // Return renderer for camera setup -} - -// // --- 5. Bitbybit Kernel Initialization Logic --- -// async function initWithKernels( -// scene: Scene, -// bitbybit: BitByBitBase, -// options: KernelOptions -// ): Promise<{ message: string; initializedKernels: string[] }> { -// let occtWorkerInstance: Worker | undefined; -// let jscadWorkerInstance: Worker | undefined; -// let manifoldWorkerInstance: Worker | undefined; - -// // 1. Conditionally create worker instances -// if (options.enableOCCT) { -// occtWorkerInstance = new Worker( -// new URL("./workers/occt.worker.ts", import.meta.url), -// { name: "OCC_WORKER", type: "module" } -// ); -// } -// if (options.enableJSCAD) { -// jscadWorkerInstance = new Worker( -// new URL("./workers/jscad.worker.ts", import.meta.url), -// { name: "JSCAD_WORKER", type: "module" } -// ); -// } -// if (options.enableManifold) { -// manifoldWorkerInstance = new Worker( -// new URL("./workers/manifold.worker.ts", import.meta.url), -// { name: "MANIFOLD_WORKER", type: "module" } -// ); -// } - -// // 2. Initialize Bitbybit -// await bitbybit.init( -// scene, -// occtWorkerInstance, -// jscadWorkerInstance, -// manifoldWorkerInstance -// ); - -// // 3. Collect promises for kernel initializations -// const initializationPromises: Promise[] = []; -// let anyKernelSelectedForInit = false; - -// if (options.enableOCCT) { -// anyKernelSelectedForInit = true; -// if (bitbybit.occtWorkerManager) { -// initializationPromises.push( -// firstValueFrom( -// bitbybit.occtWorkerManager.occWorkerState$.pipe( -// first((s) => s.state === OccStateEnum.initialised), -// map(() => "OCCT") -// ) -// ) -// ); -// } else { -// console.warn( -// "OCCT enabled in options, but occtWorkerManager not found after init." -// ); -// } -// } - -// if (options.enableJSCAD) { -// anyKernelSelectedForInit = true; -// if (bitbybit.jscadWorkerManager) { -// initializationPromises.push( -// firstValueFrom( -// bitbybit.jscadWorkerManager.jscadWorkerState$.pipe( -// first((s) => s.state === JscadStateEnum.initialised), -// map(() => "JSCAD") -// ) -// ) -// ); -// } else { -// console.warn( -// "JSCAD enabled in options, but jscadWorkerManager not found after init." -// ); -// } -// } - -// if (options.enableManifold) { -// anyKernelSelectedForInit = true; -// if (bitbybit.manifoldWorkerManager && bitbybit.manifoldWorkerManager.manifoldWorkerState$) { -// initializationPromises.push( -// firstValueFrom( -// bitbybit.manifoldWorkerManager.manifoldWorkerState$.pipe( -// first((s) => s.state === ManifoldStateEnum.initialised), -// map(() => "Manifold") -// ) -// ) -// ); -// } else { -// console.warn( -// "Manifold enabled in options, but manifoldWorkerManager not found after init." -// ); -// } -// } - -// // 4. Wait for selected & available kernels or handle no selection/availability -// if (!anyKernelSelectedForInit) { -// console.log("No kernels selected for initialization."); -// return { message: "No kernels selected for initialization.", initializedKernels: [] }; -// } - -// if (initializationPromises.length === 0) { -// // Kernels were selected, but none were awaitable (e.g., managers missing for all selected) -// console.log( -// "Kernels were selected, but none had managers available for awaiting initialization." -// ); -// return { -// message: "Selected kernels were not awaitable for initialization state.", -// initializedKernels: [], -// }; -// } - -// const initializedKernels = await Promise.all(initializationPromises); -// console.log("Kernels initialized:", initializedKernels.join(", ")); -// return { -// message: `Successfully initialized: ${initializedKernels.join(", ")}`, -// initializedKernels, -// }; -// } - -// --- 6. Geometry Creation Functions (Examples) --- async function createOCCTGeometry(bitbybit: BitByBitBase, color: string) { - console.log("Creating OCCT geometry..."); const cubeOptions = new Inputs.OCCT.CubeDto(); - cubeOptions.size = 25; - cubeOptions.center = [0, 0, 0]; + cubeOptions.size = 2.5; + cubeOptions.center = [0, 1.25, 0]; const cube = await bitbybit.occt.shapes.solid.createCube(cubeOptions); const filletOptions = new Inputs.OCCT.FilletDto(); filletOptions.shape = cube; - filletOptions.radius = 4; + filletOptions.radius = 0.4; const roundedCube = await bitbybit.occt.fillets.filletEdges(filletOptions); const drawOptions = new Inputs.Draw.DrawOcctShapeOptions(); - drawOptions.edgeWidth = 5; + drawOptions.edgeWidth = 0.5; drawOptions.faceColour = color; drawOptions.drawVertices = true; - drawOptions.vertexSize = 0.5; + drawOptions.vertexSize = 0.05; drawOptions.vertexColour = "#ffffff"; await bitbybit.draw.drawAnyAsync({ entity: roundedCube, options: drawOptions, }); - console.log("OCCT geometry created and drawn."); } async function createManifoldGeometry(bitbybit: BitByBitBase, color: string) { - console.log("Creating Manifold geometry..."); const sphereOptions = new Inputs.Manifold.SphereDto(); - sphereOptions.radius = 15; + sphereOptions.radius = 1.5; + sphereOptions.circularSegments = 32; const sphere = await bitbybit.manifold.manifold.shapes.sphere(sphereOptions); const cubeOptions = new Inputs.Manifold.CubeDto(); - cubeOptions.size = 25; + cubeOptions.size = 2.5; const cube = await bitbybit.manifold.manifold.shapes.cube(cubeOptions); const diffedShape = await bitbybit.manifold.manifold.booleans.differenceTwo({ @@ -268,7 +78,7 @@ async function createManifoldGeometry(bitbybit: BitByBitBase, color: string) { const translationOptions = new Inputs.Manifold.TranslateDto(); translationOptions.manifold = diffedShape; - translationOptions.vector = [0, -40, 0]; // Position below OCCT + translationOptions.vector = [0, 1.25, -4]; // Position below OCCT const movedShape = await bitbybit.manifold.manifold.transforms.translate( translationOptions ); @@ -279,22 +89,19 @@ async function createManifoldGeometry(bitbybit: BitByBitBase, color: string) { entity: movedShape, options: drawOptions, }); - console.log("Manifold geometry created and drawn."); } async function createJSCADGeometry(bitbybit: BitByBitBase, color: string) { - console.log("Creating JSCAD geometry..."); const geodesicSphereOptions = new Inputs.JSCAD.GeodesicSphereDto(); - geodesicSphereOptions.radius = 15; - geodesicSphereOptions.center = [0, 40, 0]; // Position above OCCT + geodesicSphereOptions.radius = 1.5; + geodesicSphereOptions.center = [0, 1.5, 4]; const geodesicSphere = await bitbybit.jscad.shapes.geodesicSphere( geodesicSphereOptions ); - // Example: Create another simple sphere for a boolean operation const sphereOptions = new Inputs.JSCAD.SphereDto(); - sphereOptions.radius = 10; // Smaller sphere - sphereOptions.center = [5, 45, 0]; // Slightly offset + sphereOptions.radius = 1; + sphereOptions.center = [0, 3, 4.5]; const simpleSphere = await bitbybit.jscad.shapes.sphere(sphereOptions); const unionOptions = new Inputs.JSCAD.BooleanTwoObjectsDto(); @@ -303,431 +110,10 @@ async function createJSCADGeometry(bitbybit: BitByBitBase, color: string) { const unionShape = await bitbybit.jscad.booleans.unionTwo(unionOptions); const drawOptions = new Inputs.Draw.DrawBasicGeometryOptions(); - drawOptions.colours = color; // Note: 'colours' for JSCAD draw options + drawOptions.colours = color; await bitbybit.draw.drawAnyAsync({ entity: unionShape, options: drawOptions, }); - console.log("JSCAD geometry created and drawn."); -} - -async function createTexturedOCCTCube(bitbybit: BitByBitBase) { - console.log("Creating textured OCCT cube..."); - - // Create texture from URL - const textureOptions = new Inputs.Draw.GenericTextureDto(); - textureOptions.url = "https://cdn.polyhaven.com/asset_img/primary/worn_asphalt.png?height=760&quality=95"; - textureOptions.uScale = 0.05; - textureOptions.vScale = 0.05; - const texture = await bitbybit.draw.createTexture(textureOptions); - - // Create material with texture - const materialOptions = new Inputs.Draw.GenericPBRMaterialDto(); - materialOptions.baseColorTexture = texture; - materialOptions.baseColor = "#ffffff"; // White to show texture colors accurately - const material = await bitbybit.draw.createPBRMaterial(materialOptions); - - // Create OCCT cube - const cubeOptions = new Inputs.OCCT.CubeDto(); - cubeOptions.size = 20; - cubeOptions.center = [-50, 0, -50]; - const cube = await bitbybit.occt.shapes.solid.createCube(cubeOptions); - - // Draw cube with material - const drawOptions = new Inputs.Draw.DrawOcctShapeOptions(); - drawOptions.faceMaterial = material; - drawOptions.backFaceOpacity = 1; - await bitbybit.draw.drawAnyAsync({ - entity: cube, - options: drawOptions, - }); - - console.log("Textured OCCT cube created and drawn."); } -// --- 7. Drawing Examples Function --- -async function createDrawingExamples(bitbybit: BitByBitBase) { - console.log("Creating drawing examples..."); - - // Example 1: Draw a single point - const point = [60, 0, 0] as Inputs.Base.Point3; - const pointDrawOptions = new Inputs.Draw.DrawBasicGeometryOptions(); - pointDrawOptions.colours = "#ffff00"; // Yellow - pointDrawOptions.size = 2; - await bitbybit.draw.drawAnyAsync({ - entity: point, - options: pointDrawOptions, - }); - console.log("Single point drawn."); - - // Example 2: Draw multiple points - const points = [ - [60, 5, 0], - [60, 10, 0], - [60, 15, 0], - [60, 20, 0], - [60, 25, 0], - [60, 30, 0], - [60, 35, 0], - ] as Inputs.Base.Point3[]; - const pointsDrawOptions = new Inputs.Draw.DrawBasicGeometryOptions(); - pointsDrawOptions.colours = ["#ff00ff", "#ff0000", "#00ff00", "#0000ff"]; // Magenta - pointsDrawOptions.size = 1.5; - pointsDrawOptions.colorMapStrategy = Inputs.Base.colorMapStrategyEnum.repeatColors; - await bitbybit.draw.drawAnyAsync({ - entity: points, - options: pointsDrawOptions, - }); - console.log("Multiple points drawn."); - - // Example 3: Draw a single polyline - const polyline = { - points: [ - [70, -10, 0], - [70, 0, 10], - [80, 0, 10], - [80, -10, 0], - ], - } as Inputs.Base.Polyline3; - const polylineDrawOptions = new Inputs.Draw.DrawBasicGeometryOptions(); - polylineDrawOptions.colours = ["#00ffff"]; // Cyan - polylineDrawOptions.size = 3; - await bitbybit.draw.drawAnyAsync({ - entity: polyline, - options: polylineDrawOptions, - }); - console.log("Polyline drawn."); - - // Example 4: Draw multiple polylines with different colors - const polylines = [ - { - points: [ - [90, -10, 0], - [90, 0, 0], - [100, 0, 0], - ], - }, - { - points: [ - [90, -10, 5], - [90, 0, 5], - [100, 0, 5], - ], - }, - { - points: [ - [90, -10, 10], - [90, 0, 10], - [100, 0, 10], - ], - }, - ]; - const polylinesDrawOptions = new Inputs.Draw.DrawBasicGeometryOptions(); - polylinesDrawOptions.colours = ["#ff0000", "#00ff00", "#0000ff"]; // RGB - polylinesDrawOptions.size = 2; - await bitbybit.draw.drawAnyAsync({ - entity: polylines as Inputs.Base.Polyline3[], - options: polylinesDrawOptions, - }); - console.log("Multiple polylines drawn."); - - const segments = [ - [ - [60, -20, 0], - [70, -20, 0], - ], - [ - [65, -25, 0], - [65, -15, 0], - ], - [ - [60, -20, -5], - [70, -20, 5], - ], - ] as Inputs.Base.Segment3[]; - const segmentsDrawOptions = new Inputs.Draw.DrawBasicGeometryOptions(); - segmentsDrawOptions.colours = ["#ffff00", "#ff00ff", "#00ffff"]; // Yellow, Magenta, Cyan - segmentsDrawOptions.size = 2.5; - await bitbybit.draw.drawAnyAsync({ - entity: segments, - options: segmentsDrawOptions, - }); - console.log("Line segments drawn."); - - // Example 6: Draw a Verb NURBS curve - // Create a simple NURBS curve through control points - const controlPoints = [ - [-60, -10, 0], - [-50, 0, 5], - [-40, -5, 10], - [-30, 10, 5], - [-20, 0, 0], - ] as Inputs.Base.Point3[]; - - // Create a NURBS curve (degree 3) - const curve = bitbybit.verb.curve.createCurveByPoints({ - points: controlPoints, - degree: 3, - }); - - const curveDrawOptions = new Inputs.Draw.DrawBasicGeometryOptions(); - curveDrawOptions.colours = "#ff8800"; // Orange - curveDrawOptions.size = 3; - await bitbybit.draw.drawAnyAsync({ - entity: curve, - options: curveDrawOptions, - }); - console.log("Verb curve drawn."); - - // Example 7: Draw a Verb NURBS surface by lofting curves - // Create curves that will be lofted to form a surface - const curve1Points = [ - [-60, 20, -5], - [-50, 20, 0], - [-40, 20, -5], - ] as Inputs.Base.Point3[]; - - const curve2Points = [ - [-60, 30, 0], - [-50, 30, 5], - [-40, 30, 0], - ] as Inputs.Base.Point3[]; - - const curve3Points = [ - [-60, 40, -5], - [-50, 40, 0], - [-40, 40, -5], - ] as Inputs.Base.Point3[]; - - // Create the curves - const curve1 = bitbybit.verb.curve.createCurveByPoints({ - points: curve1Points, - degree: 2, - }); - - const curve2 = bitbybit.verb.curve.createCurveByPoints({ - points: curve2Points, - degree: 2, - }); - - const curve3 = bitbybit.verb.curve.createCurveByPoints({ - points: curve3Points, - degree: 2, - }); - - // Loft the curves to create a surface - const surface = bitbybit.verb.surface.createSurfaceByLoftingCurves({ - curves: [curve3, curve2, curve1], - degreeV: 2, - }); - - const surfaceDrawOptions = new Inputs.Draw.DrawBasicGeometryOptions(); - surfaceDrawOptions.colours = "#8800ff"; // Purple - surfaceDrawOptions.opacity = 0.8; - await bitbybit.draw.drawAnyAsync({ - entity: surface, - options: surfaceDrawOptions, - }); - console.log("Verb surface drawn."); - - // Example 8: Draw a 30x30x30 grid of points with alternating blue and white colors - // This tests GPU instancing performance with 27,000 points - console.log("Creating 30x30x30 point grid (27,000 points)..."); - const gridSize = 30; - const spacing = 1.5; - const gridOffset = [-150, 0, 0]; // Move grid away from other geometry - - const gridPoints: Inputs.Base.Point3[] = []; - const gridColors: string[] = []; - - for (let x = 0; x < gridSize; x++) { - for (let y = 0; y < gridSize; y++) { - for (let z = 0; z < gridSize; z++) { - gridPoints.push([ - gridOffset[0] + x * spacing, - gridOffset[1] + y * spacing, - gridOffset[2] + z * spacing - ]); - // Alternating blue and white based on checkerboard pattern - const isBlue = (x + y + z) % 2 === 0; - gridColors.push(isBlue ? "#0066ff" : "#ffffff"); - } - } - } - - const gridDrawOptions = new Inputs.Draw.DrawBasicGeometryOptions(); - gridDrawOptions.colours = gridColors; - gridDrawOptions.size = 0.4; - gridDrawOptions.colorMapStrategy = Inputs.Base.colorMapStrategyEnum.lastColorRemainder; - - console.time("Draw 27,000 points"); - await bitbybit.draw.drawAnyAsync({ - entity: gridPoints, - options: gridDrawOptions, - }); - console.timeEnd("Draw 27,000 points"); - console.log("30x30x30 point grid drawn with GPU instancing."); - - // Example 9: Draw a 30x30x30 grid of polylines with alternating colors - // Creates lines along X, Y, and Z axes forming a 3D grid - console.log("Creating 30x30x30 polyline grid..."); - const polylineGridSize = 30; - const polylineSpacing = 1.5; - const polylineGridOffset = [-150, -60, 0]; // Position below the point grid - - const gridPolylines: Inputs.Base.Polyline3[] = []; - const polylineColors: string[] = []; - - // Create lines along X axis (for each Y,Z position) - for (let y = 0; y < polylineGridSize; y++) { - for (let z = 0; z < polylineGridSize; z++) { - const startX = polylineGridOffset[0]; - const endX = polylineGridOffset[0] + (polylineGridSize - 1) * polylineSpacing; - const posY = polylineGridOffset[1] + y * polylineSpacing; - const posZ = polylineGridOffset[2] + z * polylineSpacing; - - gridPolylines.push({ - points: [ - [startX, posY, posZ], - [endX, posY, posZ] - ] - }); - // Alternating colors based on position - const isOrange = (y + z) % 2 === 0; - polylineColors.push(isOrange ? "#ff6600" : "#00ffcc"); - } - } - - // Create lines along Y axis (for each X,Z position) - for (let x = 0; x < polylineGridSize; x++) { - for (let z = 0; z < polylineGridSize; z++) { - const posX = polylineGridOffset[0] + x * polylineSpacing; - const startY = polylineGridOffset[1]; - const endY = polylineGridOffset[1] + (polylineGridSize - 1) * polylineSpacing; - const posZ = polylineGridOffset[2] + z * polylineSpacing; - - gridPolylines.push({ - points: [ - [posX, startY, posZ], - [posX, endY, posZ] - ] - }); - const isPurple = (x + z) % 2 === 0; - polylineColors.push(isPurple ? "#9933ff" : "#ffff00"); - } - } - - // Create lines along Z axis (for each X,Y position) - for (let x = 0; x < polylineGridSize; x++) { - for (let y = 0; y < polylineGridSize; y++) { - const posX = polylineGridOffset[0] + x * polylineSpacing; - const posY = polylineGridOffset[1] + y * polylineSpacing; - const startZ = polylineGridOffset[2]; - const endZ = polylineGridOffset[2] + (polylineGridSize - 1) * polylineSpacing; - - gridPolylines.push({ - points: [ - [posX, posY, startZ], - [posX, posY, endZ] - ] - }); - const isPink = (x + y) % 2 === 0; - polylineColors.push(isPink ? "#ff0099" : "#00ff66"); - } - } - - const polylineGridDrawOptions = new Inputs.Draw.DrawBasicGeometryOptions(); - polylineGridDrawOptions.colours = polylineColors; - polylineGridDrawOptions.size = 1; - polylineGridDrawOptions.colorMapStrategy = Inputs.Base.colorMapStrategyEnum.lastColorRemainder; - - console.log(`Drawing ${gridPolylines.length} polylines...`); - console.time("Draw polyline grid"); - await bitbybit.draw.drawAnyAsync({ - entity: gridPolylines, - options: polylineGridDrawOptions, - }); - console.timeEnd("Draw polyline grid"); - console.log("30x30x30 polyline grid drawn with per-polyline colors."); - - // --- Arrow Examples --- - // Example: Draw a single polyline with an arrow at the end - const arrowPolyline = { - points: [ - [-80, 0, 0], - [-80, 10, 5], - [-70, 15, 10], - [-60, 10, 5], - ], - } as Inputs.Base.Polyline3; - const arrowPolylineOptions = new Inputs.Draw.DrawBasicGeometryOptions(); - arrowPolylineOptions.colours = "#00ff88"; // Green - arrowPolylineOptions.size = 3; - arrowPolylineOptions.arrowSize = 3; // Arrow size - arrowPolylineOptions.arrowAngle = 25; // Arrow angle in degrees - await bitbybit.draw.drawAnyAsync({ - entity: arrowPolyline, - options: arrowPolylineOptions, - }); - console.log("Polyline with arrow drawn."); - - // Example: Draw multiple polylines with arrows (different sizes) - const arrowPolylines = [ - { - points: [ - [-80, -30, 0], - [-70, -25, 0], - [-60, -30, 0], - ], - }, - { - points: [ - [-80, -35, 0], - [-70, -30, 0], - [-60, -35, 0], - ], - }, - { - points: [ - [-80, -40, 0], - [-70, -35, 0], - [-60, -40, 0], - ], - }, - ] as Inputs.Base.Polyline3[]; - const arrowPolylinesOptions = new Inputs.Draw.DrawBasicGeometryOptions(); - arrowPolylinesOptions.colours = ["#ff0000", "#00ff00", "#0000ff"]; // RGB - arrowPolylinesOptions.size = 2; - arrowPolylinesOptions.arrowSize = 2.5; - arrowPolylinesOptions.arrowAngle = 30; - await bitbybit.draw.drawAnyAsync({ - entity: arrowPolylines, - options: arrowPolylinesOptions, - }); - console.log("Multiple polylines with arrows drawn."); - - // Example: Draw OCCT wire with edge arrows to show orientation - const wirePoints = [ - [-80, -60, 0], - [-70, -55, 5], - [-60, -60, 0], - [-50, -65, -5], - ] as Inputs.Base.Point3[]; - const wire = await bitbybit.occt.shapes.wire.createPolylineWire({ - points: wirePoints, - }); - const wireDrawOptions = new Inputs.Draw.DrawOcctShapeOptions(); - wireDrawOptions.edgeColour = "#ff8800"; // Orange edges - wireDrawOptions.edgeWidth = 3; - wireDrawOptions.drawEdges = true; - wireDrawOptions.drawFaces = false; - wireDrawOptions.edgeArrowSize = 3; // Arrow size on edges - wireDrawOptions.edgeArrowAngle = 25; // Arrow angle - await bitbybit.draw.drawAnyAsync({ - entity: wire, - options: wireDrawOptions, - }); - console.log("OCCT wire with edge orientation arrows drawn."); - - console.log("All drawing examples completed."); -} diff --git a/examples/vite/threejs/starter-template/src/models/current.ts b/examples/vite/threejs/starter-template/src/models/current.ts deleted file mode 100644 index acec480e..00000000 --- a/examples/vite/threejs/starter-template/src/models/current.ts +++ /dev/null @@ -1,11 +0,0 @@ -import { DirectionalLight, Group, Mesh } from "three"; -import { GUI } from "lil-gui"; - -export type Current = { - group1: Group | undefined; - group2: Group | undefined; - dimensions: Group | undefined; - light1: DirectionalLight | undefined; - ground: Mesh | undefined; - gui: GUI | undefined; -}; diff --git a/examples/vite/threejs/starter-template/src/models/model.ts b/examples/vite/threejs/starter-template/src/models/model.ts deleted file mode 100644 index 5260fda4..00000000 --- a/examples/vite/threejs/starter-template/src/models/model.ts +++ /dev/null @@ -1,24 +0,0 @@ -export type Model = { - uHex: number; - vHex: number; - height: number; - ellipse1MinRad: number; - ellipse1MaxRad: number; - ellipse2MinRad: number; - ellipse2MaxRad: number; - ellipse2RotX: number; - ellipse2RotY: number; - ellipse3MinRad: number; - ellipse3MaxRad: number; - ellipse3YRot: number; - drawEdges: boolean; - drawFaces: boolean; - color1: string; - color2: string; - finalPrecision: number; - rotationEnabled: boolean; - downloadSTL?: () => void; - downloadStep?: () => void; - downloadGLB?: () => void; - update?: () => void; -}; diff --git a/examples/vite/threejs/starter-template/src/workers/jscad.worker.ts b/examples/vite/threejs/starter-template/src/workers/jscad.worker.ts deleted file mode 100644 index eeed36fd..00000000 --- a/examples/vite/threejs/starter-template/src/workers/jscad.worker.ts +++ /dev/null @@ -1,12 +0,0 @@ -import { - initializationComplete, - onMessageInput, -} from "@bitbybit-dev/jscad-worker"; - -import("@bitbybit-dev/jscad/jscad-generated").then((s) => { - initializationComplete(s.default()); -}); - -addEventListener("message", ({ data }) => { - onMessageInput(data, postMessage); -}); diff --git a/examples/vite/threejs/starter-template/src/workers/manifold.worker.ts b/examples/vite/threejs/starter-template/src/workers/manifold.worker.ts deleted file mode 100644 index 62d8eb14..00000000 --- a/examples/vite/threejs/starter-template/src/workers/manifold.worker.ts +++ /dev/null @@ -1,21 +0,0 @@ -import { - initializationComplete, - onMessageInput, -} from "@bitbybit-dev/manifold-worker"; -import Module from "manifold-3d"; - -const init = async () => { - const wasm = await Module({ - locateFile: () => { - return "https://cdn.jsdelivr.net/gh/bitbybit-dev/bitbybit-assets@0.21.0/wasm/manifold-3-3-2.wasm"; - }, - }); - wasm.setup(); - initializationComplete(wasm); -}; - -init(); - -addEventListener("message", ({ data }) => { - onMessageInput(data, postMessage); -}); diff --git a/examples/vite/threejs/starter-template/src/workers/occt.worker.ts b/examples/vite/threejs/starter-template/src/workers/occt.worker.ts deleted file mode 100644 index 492dfd44..00000000 --- a/examples/vite/threejs/starter-template/src/workers/occt.worker.ts +++ /dev/null @@ -1,14 +0,0 @@ -import initOpenCascade from "@bitbybit-dev/occt/bitbybit-dev-occt/cdn"; -import type { OpenCascadeInstance } from "@bitbybit-dev/occt/bitbybit-dev-occt/bitbybit-dev-occt.js"; -import { - initializationComplete, - onMessageInput, -} from "@bitbybit-dev/occt-worker"; - -initOpenCascade().then((occ: OpenCascadeInstance) => { - initializationComplete(occ, undefined); -}); - -addEventListener("message", ({ data }) => { - onMessageInput(data, postMessage); -}); diff --git a/packages/dev/babylonjs/lib/api/init-kernels.ts b/packages/dev/babylonjs/lib/api/init-kernels.ts index 02c3d8c0..10928896 100644 --- a/packages/dev/babylonjs/lib/api/init-kernels.ts +++ b/packages/dev/babylonjs/lib/api/init-kernels.ts @@ -11,7 +11,7 @@ import { /** * Options for initializing bitbybit with Babylon.js */ -export interface InitBitbybitOptions extends WorkerOptions { +export interface InitBitByBitOptions extends WorkerOptions { /** Pre-created worker instances. If not provided, workers will be created from CDN. */ workers?: WorkerInstances; /** Havok physics plugin instance (optional) */ @@ -35,12 +35,12 @@ export { type InitKernelsResult, type WorkerInstances, type WorkerOptions }; * * @example * ```typescript - * import { BitByBitBase, initBitbybit } from "@bitbybit-dev/babylonjs"; + * import { BitByBitBase, initBitByBit } from "@bitbybit-dev/babylonjs"; * * const scene = new BABYLON.Scene(engine); * const bitbybit = new BitByBitBase(); * - * await initBitbybit(scene, bitbybit, { + * await initBitByBit(scene, bitbybit, { * enableOCCT: true, * enableJSCAD: true, * enableManifold: false, @@ -50,10 +50,10 @@ export { type InitKernelsResult, type WorkerInstances, type WorkerOptions }; * // Now you can use bitbybit.occt, bitbybit.jscad, etc. * ``` */ -export async function initBitbybit( +export async function initBitByBit( scene: BABYLON.Scene, bitbybit: BitByBitBase, - options: InitBitbybitOptions + options: InitBitByBitOptions ): Promise { // Get or create workers const workers = getOrCreateWorkers(options); diff --git a/packages/dev/core/lib/api/init-kernels.ts b/packages/dev/core/lib/api/init-kernels.ts index 6e19c7c6..d12801a3 100644 --- a/packages/dev/core/lib/api/init-kernels.ts +++ b/packages/dev/core/lib/api/init-kernels.ts @@ -8,7 +8,7 @@ import { createWorkersFromCDN } from "./worker-utils"; /** * Options for initializing bitbybit */ -export interface InitBitbybitOptions extends WorkerOptions { +export interface InitBitByBitOptions extends WorkerOptions { /** Pre-created worker instances. If not provided, workers will be created from CDN. */ workers?: WorkerInstances; } @@ -126,7 +126,7 @@ export async function waitForKernelInitialization( * * @param options - Initialization options */ -export function getOrCreateWorkers(options: InitBitbybitOptions): WorkerInstances { +export function getOrCreateWorkers(options: InitBitByBitOptions): WorkerInstances { if (options.workers) { return options.workers; } diff --git a/packages/dev/playcanvas/lib/api/init-kernels.ts b/packages/dev/playcanvas/lib/api/init-kernels.ts index eab18a4e..b99df3df 100644 --- a/packages/dev/playcanvas/lib/api/init-kernels.ts +++ b/packages/dev/playcanvas/lib/api/init-kernels.ts @@ -11,7 +11,7 @@ import { /** * Options for initializing bitbybit with PlayCanvas */ -export interface InitBitbybitOptions extends WorkerOptions { +export interface InitBitByBitOptions extends WorkerOptions { /** Pre-created worker instances. If not provided, workers will be created from CDN. */ workers?: WorkerInstances; } @@ -34,13 +34,13 @@ export { type InitKernelsResult, type WorkerInstances, type WorkerOptions }; * * @example * ```typescript - * import { BitByBitBase, initBitbybit } from "@bitbybit-dev/playcanvas"; + * import { BitByBitBase, initBitByBit } from "@bitbybit-dev/playcanvas"; * * const app = new pc.Application(canvas); * const scene = app.root; * const bitbybit = new BitByBitBase(); * - * await initBitbybit(app, scene, bitbybit, { + * await initBitByBit(app, scene, bitbybit, { * enableOCCT: true, * enableJSCAD: true, * enableManifold: false, @@ -50,11 +50,11 @@ export { type InitKernelsResult, type WorkerInstances, type WorkerOptions }; * // Now you can use bitbybit.occt, bitbybit.jscad, etc. * ``` */ -export async function initBitbybit( +export async function initBitByBit( app: pc.AppBase, scene: pc.Entity, bitbybit: BitByBitBase, - options: InitBitbybitOptions + options: InitBitByBitOptions ): Promise { // Get or create workers const workers = getOrCreateWorkers(options); diff --git a/packages/dev/threejs/lib/api/bitbybit/threejs/index.ts b/packages/dev/threejs/lib/api/bitbybit/threejs/index.ts index c07f33a3..61520d9c 100644 --- a/packages/dev/threejs/lib/api/bitbybit/threejs/index.ts +++ b/packages/dev/threejs/lib/api/bitbybit/threejs/index.ts @@ -1,2 +1,3 @@ export * from "./camera"; export * from "./orbit-camera"; +export * from "./scene-helper"; diff --git a/packages/dev/threejs/lib/api/bitbybit/threejs/orbit-camera.ts b/packages/dev/threejs/lib/api/bitbybit/threejs/orbit-camera.ts index 86d7182e..2e1d48a5 100644 --- a/packages/dev/threejs/lib/api/bitbybit/threejs/orbit-camera.ts +++ b/packages/dev/threejs/lib/api/bitbybit/threejs/orbit-camera.ts @@ -691,3 +691,20 @@ export class ThreeJSOrbitCamera { }; } } + +/** + * Standalone function to create an orbit camera without requiring a BitByBit context. + * This is useful for the initThreeJS helper function. + * + * @param inputs Configuration options including scene and domElement + * @returns Orbit camera controller instance + */ +export function createOrbitCamera(inputs: Inputs.ThreeJSCamera.OrbitCameraDto & { scene: THREEJS.Scene; domElement?: HTMLElement }): OrbitCameraController { + // Create a minimal context for the orbit camera + const minimalContext = { + scene: inputs.scene + } as Context; + + const orbitCameraClass = new ThreeJSOrbitCamera(minimalContext); + return orbitCameraClass.create(inputs); +} diff --git a/packages/dev/threejs/lib/api/bitbybit/threejs/scene-helper.ts b/packages/dev/threejs/lib/api/bitbybit/threejs/scene-helper.ts new file mode 100644 index 00000000..a5e5bc62 --- /dev/null +++ b/packages/dev/threejs/lib/api/bitbybit/threejs/scene-helper.ts @@ -0,0 +1,213 @@ +import * as THREEJS from "three"; +import { ThreeJSScene, InitThreeJSResult } from "../../inputs/threejs-scene-inputs"; +import { OrbitCameraController } from "../../inputs/threejs-camera-inputs"; +import { createOrbitCamera } from "./orbit-camera"; + +/** + * Helper function to initialize a basic Three.js scene with lights, shadows, and optional ground plane. + * This provides a quick setup for common use cases while remaining fully customizable. + * + * @param inputs Configuration options for the scene + * @returns Object containing the scene, renderer, lights, ground, and dispose function + * + * @example + * ```typescript + * import { initThreeJS, ThreeJSScene } from "@bitbybit-dev/threejs"; + * + * // Basic usage with defaults + * const { scene, renderer } = initThreeJS(); + * + * // Custom configuration + * const options = new ThreeJSScene.InitThreeJSDto(); + * options.sceneSize = 500; + * options.enableGround = true; + * options.enableShadows = true; + * const { scene, renderer, directionalLight } = initThreeJS(options); + * ``` + */ +export function initThreeJS(inputs?: ThreeJSScene.InitThreeJSDto): InitThreeJSResult { + const config = inputs || new ThreeJSScene.InitThreeJSDto(); + + // Get or create canvas + let canvas: HTMLCanvasElement; + if (config.canvasId) { + const existingCanvas = document.getElementById(config.canvasId) as HTMLCanvasElement; + if (!existingCanvas) { + throw new Error(`Canvas with id "${config.canvasId}" not found`); + } + canvas = existingCanvas; + } else { + canvas = document.createElement("canvas"); + canvas.style.width = "100%"; + canvas.style.height = "100%"; + canvas.style.display = "block"; + document.body.appendChild(canvas); + } + + // Create scene + const scene = new THREEJS.Scene(); + scene.background = new THREEJS.Color(config.backgroundColor); + + // Calculate positions based on scene size + const lightHeight = config.sceneSize * 0.75; + const lightOffset = config.sceneSize * 0.5; + + // Create hemisphere light (ambient-like lighting from sky and ground) + const hemisphereLight = new THREEJS.HemisphereLight( + new THREEJS.Color(config.hemisphereLightSkyColor), + new THREEJS.Color(config.hemisphereLightGroundColor), + config.hemisphereLightIntensity + ); + hemisphereLight.position.set(0, lightHeight, 0); + scene.add(hemisphereLight); + + // Create directional light (sun-like light with shadows) + const directionalLight = new THREEJS.DirectionalLight( + new THREEJS.Color(config.directionalLightColor), + config.directionalLightIntensity + ); + directionalLight.position.set(lightOffset, lightHeight, lightOffset); + directionalLight.target.position.set(0, 0, 0); + scene.add(directionalLight); + scene.add(directionalLight.target); + + // Create renderer + const renderer = new THREEJS.WebGLRenderer({ + antialias: true, + canvas: canvas + }); + renderer.setSize(window.innerWidth, window.innerHeight); + renderer.setPixelRatio(window.devicePixelRatio); + + // Configure shadows + if (config.enableShadows) { + renderer.shadowMap.enabled = true; + // Use VSM for softer, more natural-looking shadows + renderer.shadowMap.type = THREEJS.VSMShadowMap; + + directionalLight.castShadow = true; + + // Configure shadow camera based on scene size + const shadowCameraSize = config.sceneSize * config.groundScaleFactor; + directionalLight.shadow.camera.left = -shadowCameraSize / 2; + directionalLight.shadow.camera.right = shadowCameraSize / 2; + directionalLight.shadow.camera.top = shadowCameraSize / 2; + directionalLight.shadow.camera.bottom = -shadowCameraSize / 2; + directionalLight.shadow.camera.near = 0.1; + directionalLight.shadow.camera.far = config.sceneSize * 3; + + directionalLight.shadow.mapSize.width = config.shadowMapSize; + directionalLight.shadow.mapSize.height = config.shadowMapSize; + + // VSM shadow map settings for soft shadows + // Radius controls the blur amount - higher values = softer shadows + directionalLight.shadow.radius = 4; + // Blur samples for VSM - more samples = smoother but slower + directionalLight.shadow.blurSamples = 8; + + // Compute shadow bias values based on scene size for optimal results + // VSM requires smaller bias values than PCF + const shadowCameraSizeComputed = config.sceneSize * config.groundScaleFactor; + directionalLight.shadow.bias = -0.0001 * (shadowCameraSizeComputed / 40); + directionalLight.shadow.normalBias = 0.01 * (shadowCameraSizeComputed / 40); + } + + // Create ground plane + let ground: THREEJS.Mesh | null = null; + if (config.enableGround) { + const groundSize = config.sceneSize * config.groundScaleFactor; + const groundGeometry = new THREEJS.PlaneGeometry(groundSize, groundSize); + const groundMaterial = new THREEJS.MeshStandardMaterial({ + color: new THREEJS.Color(config.groundColor), + roughness: 0.8, + metalness: 0.2, + transparent: config.groundOpacity < 1, + opacity: config.groundOpacity, + side: THREEJS.DoubleSide + }); + ground = new THREEJS.Mesh(groundGeometry, groundMaterial); + ground.rotation.x = -Math.PI / 2; // Rotate to be horizontal + ground.position.set( + config.groundCenter[0], + config.groundCenter[1], + config.groundCenter[2] + ); + ground.receiveShadow = config.enableShadows; + scene.add(ground); + } + + // Create orbit camera if enabled + let orbitCamera: OrbitCameraController | null = null; + if (config.enableOrbitCamera) { + const camOpts = config.orbitCameraOptions; + // Pass the DTO directly to createOrbitCamera, adding scene and domElement + orbitCamera = createOrbitCamera({ + ...camOpts, + scene, + domElement: renderer.domElement, + }); + } + + // Handle window resize + const onWindowResize = (): void => { + if (orbitCamera) { + orbitCamera.camera.aspect = window.innerWidth / window.innerHeight; + orbitCamera.camera.updateProjectionMatrix(); + } + renderer.setSize(window.innerWidth, window.innerHeight); + }; + window.addEventListener("resize", onWindowResize, false); + + // Start animation loop helper + const startAnimationLoop = (onRender?: (deltaTime: number) => void): void => { + const animate = (): void => { + const deltaTime = 0.016; // ~60fps + if (orbitCamera) { + orbitCamera.update(deltaTime); + renderer.render(scene, orbitCamera.camera); + } + if (onRender) { + onRender(deltaTime); + } + }; + renderer.setAnimationLoop(animate); + }; + + // Dispose function to clean up resources + const dispose = (): void => { + window.removeEventListener("resize", onWindowResize); + renderer.setAnimationLoop(null); + + if (orbitCamera) { + orbitCamera.destroy(); + } + + if (ground) { + ground.geometry.dispose(); + (ground.material as THREEJS.Material).dispose(); + scene.remove(ground); + } + + scene.remove(hemisphereLight); + scene.remove(directionalLight); + scene.remove(directionalLight.target); + + renderer.dispose(); + + // Remove canvas if we created it + if (!config.canvasId && canvas.parentNode) { + canvas.parentNode.removeChild(canvas); + } + }; + + return { + scene, + renderer, + hemisphereLight, + directionalLight, + ground, + orbitCamera, + startAnimationLoop, + dispose + }; +} diff --git a/packages/dev/threejs/lib/api/draw-helper.ts b/packages/dev/threejs/lib/api/draw-helper.ts index 7335196c..46c25c08 100644 --- a/packages/dev/threejs/lib/api/draw-helper.ts +++ b/packages/dev/threejs/lib/api/draw-helper.ts @@ -528,9 +528,15 @@ export class DrawHelper extends DrawHelperCore { group.clear(); const geometry = createMesh(); if (material) { - group.add(new THREEJS.Mesh(geometry, material)); + const mesh = new THREEJS.Mesh(geometry, material); + mesh.castShadow = true; + mesh.receiveShadow = true; + group.add(mesh); } else { - group.add(new THREEJS.Mesh(geometry)); + const mesh = new THREEJS.Mesh(geometry); + mesh.castShadow = true; + mesh.receiveShadow = true; + group.add(mesh); } } else { let scene = null; @@ -543,9 +549,15 @@ export class DrawHelper extends DrawHelperCore { scene.add(group); const geometry = createMesh(); if (material) { - group.add(new THREEJS.Mesh(geometry, material)); + const mesh = new THREEJS.Mesh(geometry, material); + mesh.castShadow = true; + mesh.receiveShadow = true; + group.add(mesh); } else { - group.add(new THREEJS.Mesh(geometry)); + const mesh = new THREEJS.Mesh(geometry); + mesh.castShadow = true; + mesh.receiveShadow = true; + group.add(mesh); } } if (hidden) { @@ -675,7 +687,10 @@ export class DrawHelper extends DrawHelperCore { const matrix4 = new THREEJS.Matrix4(); matrix4.fromArray(transforms); jscadMesh.clear(); - jscadMesh.add(new THREEJS.Mesh(geometry, material)); + const mesh = new THREEJS.Mesh(geometry, material); + mesh.castShadow = true; + mesh.receiveShadow = true; + jscadMesh.add(mesh); jscadMesh.applyMatrix4(matrix4); } @@ -1016,7 +1031,10 @@ export class DrawHelper extends DrawHelperCore { material = options.faceMaterial as THREEJS.MeshPhysicalMaterial; } - group.add(new THREEJS.Mesh(geometry, material)); + const mesh = new THREEJS.Mesh(geometry, material); + mesh.castShadow = true; + mesh.receiveShadow = true; + group.add(mesh); // Draw back faces with different color when two-sided rendering is enabled if (options.drawTwoSided !== false) { @@ -1221,6 +1239,8 @@ export class DrawHelper extends DrawHelperCore { group.name = this.generateEntityId("backFaceSurface"); const mesh = new THREEJS.Mesh(geometry, backMaterial); mesh.name = this.generateEntityId("backFaceSurfaceChild"); + mesh.castShadow = true; + mesh.receiveShadow = true; group.add(mesh); return group; diff --git a/packages/dev/threejs/lib/api/init-kernels.ts b/packages/dev/threejs/lib/api/init-kernels.ts index 1c286966..61d62a48 100644 --- a/packages/dev/threejs/lib/api/init-kernels.ts +++ b/packages/dev/threejs/lib/api/init-kernels.ts @@ -1,14 +1,14 @@ import { Scene } from "three"; import { BitByBitBase } from "./bitbybit-base"; import { - type InitBitbybitOptions, + type InitBitByBitOptions, type InitKernelsResult, getOrCreateWorkers, waitForKernelInitialization, } from "@bitbybit-dev/core"; // Re-export types from core for convenience -export { type InitBitbybitOptions, type InitKernelsResult } from "@bitbybit-dev/core"; +export { type InitBitByBitOptions, type InitKernelsResult } from "@bitbybit-dev/core"; /** * Initialize BitByBit with Three.js scene in a single call. @@ -24,12 +24,12 @@ export { type InitBitbybitOptions, type InitKernelsResult } from "@bitbybit-dev/ * * @example * ```typescript - * import { BitByBitBase, initBitbybit } from "@bitbybit-dev/threejs"; + * import { BitByBitBase, initBitByBit } from "@bitbybit-dev/threejs"; * * const scene = new Scene(); * const bitbybit = new BitByBitBase(); * - * await initBitbybit(scene, bitbybit, { + * await initBitByBit(scene, bitbybit, { * enableOCCT: true, * enableJSCAD: true, * enableManifold: false, @@ -39,10 +39,10 @@ export { type InitBitbybitOptions, type InitKernelsResult } from "@bitbybit-dev/ * // Now you can use bitbybit.occt, bitbybit.jscad, etc. * ``` */ -export async function initBitbybit( +export async function initBitByBit( scene: Scene, bitbybit: BitByBitBase, - options: InitBitbybitOptions + options: InitBitByBitOptions ): Promise { // Get or create workers const workers = getOrCreateWorkers(options); @@ -65,20 +65,20 @@ export async function initBitbybit( } /** - * @deprecated Use initBitbybit instead for simpler initialization. + * @deprecated Use initBitByBit instead for simpler initialization. * This function is kept for backward compatibility. */ export async function initKernels( scene: Scene, bitbybit: BitByBitBase, - options: InitBitbybitOptions, + options: InitBitByBitOptions, workers?: { occtWorker?: Worker; jscadWorker?: Worker; manifoldWorker?: Worker } ): Promise { - const mergedOptions: InitBitbybitOptions = { + const mergedOptions: InitBitByBitOptions = { ...options, workers: workers ?? options.workers, }; - const result = await initBitbybit(scene, bitbybit, mergedOptions); + const result = await initBitByBit(scene, bitbybit, mergedOptions); return { message: result.message, initializedKernels: result.initializedKernels, diff --git a/packages/dev/threejs/lib/api/inputs/index.ts b/packages/dev/threejs/lib/api/inputs/index.ts index a115bbbb..6fd6985a 100644 --- a/packages/dev/threejs/lib/api/inputs/index.ts +++ b/packages/dev/threejs/lib/api/inputs/index.ts @@ -1,4 +1,5 @@ export * from "./draw-inputs"; export * from "./base-inputs"; export * from "./threejs-camera-inputs"; +export * from "./threejs-scene-inputs"; export * from "@bitbybit-dev/core/lib/api/inputs/inputs"; \ No newline at end of file diff --git a/packages/dev/threejs/lib/api/inputs/inputs.ts b/packages/dev/threejs/lib/api/inputs/inputs.ts index 1e2f9c85..5288782c 100644 --- a/packages/dev/threejs/lib/api/inputs/inputs.ts +++ b/packages/dev/threejs/lib/api/inputs/inputs.ts @@ -1,3 +1,4 @@ export * from "./draw-inputs"; export * from "./threejs-camera-inputs"; +export * from "./threejs-scene-inputs"; export * from "@bitbybit-dev/core/lib/api/inputs"; diff --git a/packages/dev/threejs/lib/api/inputs/threejs-scene-inputs.test.ts b/packages/dev/threejs/lib/api/inputs/threejs-scene-inputs.test.ts new file mode 100644 index 00000000..1b9bd4ee --- /dev/null +++ b/packages/dev/threejs/lib/api/inputs/threejs-scene-inputs.test.ts @@ -0,0 +1,82 @@ +import { ThreeJSScene } from "./threejs-scene-inputs"; + +describe("ThreeJSScene DTO unit tests", () => { + describe("InitThreeJSDto", () => { + it("should set properties from constructor parameters", () => { + // Arrange + const canvasId = "my-canvas"; + const sceneSize = 500; + const backgroundColor = "#ff0000"; + const enableShadows = false; + const enableGround = false; + const groundCenter = [1, 2, 3] as [number, number, number]; + const groundScaleFactor = 3; + const groundColor = "#00ff00"; + const groundOpacity = 0.5; + const hemisphereLightSkyColor = "#0000ff"; + const hemisphereLightGroundColor = "#ff00ff"; + const hemisphereLightIntensity = 2; + const directionalLightColor = "#ffff00"; + const directionalLightIntensity = 3; + const shadowMapSize = 4096; + + // Act + const result = new ThreeJSScene.InitThreeJSDto( + canvasId, + sceneSize, + backgroundColor, + enableShadows, + enableGround, + groundCenter, + groundScaleFactor, + groundColor, + groundOpacity, + hemisphereLightSkyColor, + hemisphereLightGroundColor, + hemisphereLightIntensity, + directionalLightColor, + directionalLightIntensity, + shadowMapSize + ); + + // Assert + expect(result.canvasId).toBe("my-canvas"); + expect(result.sceneSize).toBe(500); + expect(result.backgroundColor).toBe("#ff0000"); + expect(result.enableShadows).toBe(false); + expect(result.enableGround).toBe(false); + expect(result.groundCenter).toEqual([1, 2, 3]); + expect(result.groundScaleFactor).toBe(3); + expect(result.groundColor).toBe("#00ff00"); + expect(result.groundOpacity).toBe(0.5); + expect(result.hemisphereLightSkyColor).toBe("#0000ff"); + expect(result.hemisphereLightGroundColor).toBe("#ff00ff"); + expect(result.hemisphereLightIntensity).toBe(2); + expect(result.directionalLightColor).toBe("#ffff00"); + expect(result.directionalLightIntensity).toBe(3); + expect(result.shadowMapSize).toBe(4096); + }); + + it("should have correct default values when no parameters are provided", () => { + // Arrange & Act + const result = new ThreeJSScene.InitThreeJSDto(); + + // Assert + expect(result.canvasId).toBeUndefined(); + expect(result.sceneSize).toBe(20); + expect(result.backgroundColor).toBe("#1a1c1f"); + expect(result.enableShadows).toBe(true); + expect(result.enableGround).toBe(true); + expect(result.groundCenter).toEqual([0, 0, 0]); + expect(result.groundScaleFactor).toBe(2); + expect(result.groundColor).toBe("#333333"); + expect(result.groundOpacity).toBe(1); + expect(result.hemisphereLightSkyColor).toBe("#ffffff"); + expect(result.hemisphereLightGroundColor).toBe("#444444"); + expect(result.hemisphereLightIntensity).toBe(1); + expect(result.directionalLightColor).toBe("#ffffff"); + expect(result.directionalLightIntensity).toBe(1.5); + expect(result.shadowMapSize).toBe(2048); + }); + }); +}); diff --git a/packages/dev/threejs/lib/api/inputs/threejs-scene-inputs.ts b/packages/dev/threejs/lib/api/inputs/threejs-scene-inputs.ts new file mode 100644 index 00000000..b1fd0cd1 --- /dev/null +++ b/packages/dev/threejs/lib/api/inputs/threejs-scene-inputs.ts @@ -0,0 +1,189 @@ +/* eslint-disable @typescript-eslint/no-namespace */ + +import * as THREEJS from "three"; +import { Base } from "./base-inputs"; +import { OrbitCameraController, ThreeJSCamera } from "./threejs-camera-inputs"; + +/** + * Result object returned by initThreeJS helper function. + */ +export interface InitThreeJSResult { + /** The ThreeJS scene */ + scene: THREEJS.Scene; + /** The WebGL renderer */ + renderer: THREEJS.WebGLRenderer; + /** The hemispheric light */ + hemisphereLight: THREEJS.HemisphereLight; + /** The directional light (for shadows) */ + directionalLight: THREEJS.DirectionalLight; + /** The ground mesh (if enabled) */ + ground: THREEJS.Mesh | null; + /** The orbit camera controller (if enabled) */ + orbitCamera: OrbitCameraController | null; + /** Start the animation loop with the orbit camera */ + startAnimationLoop: (onRender?: (deltaTime: number) => void) => void; + /** Cleanup function to remove resize listener and dispose resources */ + dispose: () => void; +} + +export namespace ThreeJSScene { + export class InitThreeJSDto { + constructor( + canvasId?: string, + sceneSize?: number, + backgroundColor?: string, + enableShadows?: boolean, + enableGround?: boolean, + groundCenter?: Base.Point3, + groundScaleFactor?: number, + groundColor?: string, + groundOpacity?: number, + hemisphereLightSkyColor?: string, + hemisphereLightGroundColor?: string, + hemisphereLightIntensity?: number, + directionalLightColor?: string, + directionalLightIntensity?: number, + shadowMapSize?: number + ) { + if (canvasId !== undefined) { this.canvasId = canvasId; } + if (sceneSize !== undefined) { this.sceneSize = sceneSize; } + if (backgroundColor !== undefined) { this.backgroundColor = backgroundColor; } + if (enableShadows !== undefined) { this.enableShadows = enableShadows; } + if (enableGround !== undefined) { this.enableGround = enableGround; } + if (groundCenter !== undefined) { this.groundCenter = groundCenter; } + if (groundScaleFactor !== undefined) { this.groundScaleFactor = groundScaleFactor; } + if (groundColor !== undefined) { this.groundColor = groundColor; } + if (groundOpacity !== undefined) { this.groundOpacity = groundOpacity; } + if (hemisphereLightSkyColor !== undefined) { this.hemisphereLightSkyColor = hemisphereLightSkyColor; } + if (hemisphereLightGroundColor !== undefined) { this.hemisphereLightGroundColor = hemisphereLightGroundColor; } + if (hemisphereLightIntensity !== undefined) { this.hemisphereLightIntensity = hemisphereLightIntensity; } + if (directionalLightColor !== undefined) { this.directionalLightColor = directionalLightColor; } + if (directionalLightIntensity !== undefined) { this.directionalLightIntensity = directionalLightIntensity; } + if (shadowMapSize !== undefined) { this.shadowMapSize = shadowMapSize; } + } + + /** + * The ID of the canvas element to render to. If not provided, a new canvas will be created and appended to document.body. + * @default undefined + */ + canvasId?: string; + + /** + * The size of the scene in world units. This determines ground size, light positions, and shadow bounds. + * @default 20 + * @minimum 1 + * @maximum Infinity + * @step 10 + */ + sceneSize = 20; + + /** + * Background color of the scene in hex format. + * @default "#1a1c1f" + */ + backgroundColor = "#1a1c1f"; + + /** + * Enable shadow mapping for realistic shadows. + * @default true + */ + enableShadows = true; + + /** + * Enable the ground plane. + * @default true + */ + enableGround = true; + + /** + * Center position of the ground plane [x, y, z]. + * @default [0, 0, 0] + */ + groundCenter: Base.Point3 = [0, 0, 0]; + + /** + * Scale factor for the ground size relative to scene size. Values greater than 1 make the ground larger than the scene size. + * @default 2 + * @minimum 0.5 + * @maximum 10 + * @step 0.5 + */ + groundScaleFactor = 2; + + /** + * Color of the ground plane in hex format. + * @default "#333333" + */ + groundColor = "#333333"; + + /** + * Opacity of the ground plane (0 = fully transparent, 1 = fully opaque). + * @default 1 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + groundOpacity = 1; + + /** + * Sky color for the hemisphere light (illumination from above). + * @default "#ffffff" + */ + hemisphereLightSkyColor = "#ffffff"; + + /** + * Ground color for the hemisphere light (illumination from below). + * @default "#444444" + */ + hemisphereLightGroundColor = "#444444"; + + /** + * Intensity of the hemisphere light. + * @default 1 + * @minimum 0 + * @maximum 10 + * @step 0.1 + */ + hemisphereLightIntensity = 1; + + /** + * Color of the directional light (sun light). + * @default "#ffffff" + */ + directionalLightColor = "#ffffff"; + + /** + * Intensity of the directional light. + * @default 1.5 + * @minimum 0 + * @maximum 10 + * @step 0.1 + */ + directionalLightIntensity = 1.5; + + /** + * Size of the shadow map in pixels (higher = sharper shadows but more GPU intensive). + * @default 2048 + * @minimum 256 + * @maximum 8192 + * @step 256 + */ + shadowMapSize = 2048; + + /** + * Enable automatic creation of an orbit camera controller. + * @default true + */ + enableOrbitCamera = true; + + /** + * Options for the orbit camera. Only used if enableOrbitCamera is true. + * Uses the same DTO as the standalone orbit camera creation. + */ + orbitCameraOptions: ThreeJSCamera.OrbitCameraDto = new ThreeJSCamera.OrbitCameraDto( + 10, // distance + 25, // pitch + 45 // yaw + ); + } +} From 9db8041d068a2d41d13a0d6cc8f41e3429edbbd0 Mon Sep 17 00:00:00 2001 From: Matas Ubarevicius Date: Mon, 12 Jan 2026 19:03:09 +0200 Subject: [PATCH 09/31] init methods for each game engine to provide convenience approach to scene, camera, shadow creation, etc. --- .../starter-template-full/index.html | 27 + .../starter-template-full/package-lock.json | 3409 +++++++++++++++++ .../starter-template-full/package.json | 19 + .../starter-template-full/public/vite.svg | 1 + .../starter-template-full/src/main.ts | 499 +++ .../starter-template-full/src/style.css | 31 + .../starter-template-full/src/vite-env.d.ts | 1 + .../starter-template-full/tsconfig.json | 25 + .../babylonjs/starter-template/src/main.ts | 709 +--- .../starter-template/src/models/current.ts | 11 - .../starter-template/src/models/model.ts | 24 - .../src/workers/jscad.worker.ts | 12 - .../src/workers/manifold.worker.ts | 21 - .../src/workers/occt.worker.ts | 14 - .../starter-template-full/index.html | 27 + .../starter-template-full/package-lock.json | 1380 +++++++ .../starter-template-full/package.json | 19 + .../starter-template-full/public/vite.svg | 1 + .../starter-template-full/src/main.ts | 568 +++ .../starter-template-full/src/style.css | 25 + .../starter-template-full/src/vite-env.d.ts | 1 + .../starter-template-full/tsconfig.json | 25 + .../playcanvas/starter-template/src/main.ts | 695 +--- .../starter-template/src/models/current.ts | 11 - .../starter-template/src/models/model.ts | 24 - .../src/workers/jscad.worker.ts | 12 - .../src/workers/manifold.worker.ts | 21 - .../src/workers/occt.worker.ts | 14 - .../vite/threejs/starter-template/src/main.ts | 5 +- .../lib/api/bitbybit/babylon/index.ts | 1 + .../lib/api/bitbybit/babylon/scene-helper.ts | 229 ++ .../dev/babylonjs/lib/api/bitbybit/index.ts | 1 + .../dev/babylonjs/lib/api/init-kernels.ts | 17 - .../api/inputs/babylon-scene-helper-inputs.ts | 187 + .../dev/babylonjs/lib/api/inputs/index.ts | 1 + .../dev/playcanvas/lib/api/bitbybit/index.ts | 4 +- .../lib/api/bitbybit/playcanvas/index.ts | 1 + .../api/bitbybit/playcanvas/orbit-camera.ts | 6 +- .../api/bitbybit/playcanvas/scene-helper.ts | 705 ++++ .../dev/playcanvas/lib/api/draw-helper.ts | 6 +- .../dev/playcanvas/lib/api/inputs/index.ts | 1 + .../api/inputs/playcanvas-camera-inputs.ts | 8 +- .../inputs/playcanvas-scene-helper-inputs.ts | 217 ++ .../lib/api/bitbybit/threejs/scene-helper.ts | 38 +- .../lib/api/inputs/threejs-camera-inputs.ts | 4 +- .../lib/api/inputs/threejs-scene-inputs.ts | 8 +- 46 files changed, 7515 insertions(+), 1550 deletions(-) create mode 100644 examples/vite/babylonjs/starter-template-full/index.html create mode 100644 examples/vite/babylonjs/starter-template-full/package-lock.json create mode 100644 examples/vite/babylonjs/starter-template-full/package.json create mode 100644 examples/vite/babylonjs/starter-template-full/public/vite.svg create mode 100644 examples/vite/babylonjs/starter-template-full/src/main.ts create mode 100644 examples/vite/babylonjs/starter-template-full/src/style.css create mode 100644 examples/vite/babylonjs/starter-template-full/src/vite-env.d.ts create mode 100644 examples/vite/babylonjs/starter-template-full/tsconfig.json delete mode 100644 examples/vite/babylonjs/starter-template/src/models/current.ts delete mode 100644 examples/vite/babylonjs/starter-template/src/models/model.ts delete mode 100644 examples/vite/babylonjs/starter-template/src/workers/jscad.worker.ts delete mode 100644 examples/vite/babylonjs/starter-template/src/workers/manifold.worker.ts delete mode 100644 examples/vite/babylonjs/starter-template/src/workers/occt.worker.ts create mode 100644 examples/vite/playcanvas/starter-template-full/index.html create mode 100644 examples/vite/playcanvas/starter-template-full/package-lock.json create mode 100644 examples/vite/playcanvas/starter-template-full/package.json create mode 100644 examples/vite/playcanvas/starter-template-full/public/vite.svg create mode 100644 examples/vite/playcanvas/starter-template-full/src/main.ts create mode 100644 examples/vite/playcanvas/starter-template-full/src/style.css create mode 100644 examples/vite/playcanvas/starter-template-full/src/vite-env.d.ts create mode 100644 examples/vite/playcanvas/starter-template-full/tsconfig.json delete mode 100644 examples/vite/playcanvas/starter-template/src/models/current.ts delete mode 100644 examples/vite/playcanvas/starter-template/src/models/model.ts delete mode 100644 examples/vite/playcanvas/starter-template/src/workers/jscad.worker.ts delete mode 100644 examples/vite/playcanvas/starter-template/src/workers/manifold.worker.ts delete mode 100644 examples/vite/playcanvas/starter-template/src/workers/occt.worker.ts create mode 100644 packages/dev/babylonjs/lib/api/bitbybit/babylon/scene-helper.ts create mode 100644 packages/dev/babylonjs/lib/api/inputs/babylon-scene-helper-inputs.ts create mode 100644 packages/dev/playcanvas/lib/api/bitbybit/playcanvas/scene-helper.ts create mode 100644 packages/dev/playcanvas/lib/api/inputs/playcanvas-scene-helper-inputs.ts diff --git a/examples/vite/babylonjs/starter-template-full/index.html b/examples/vite/babylonjs/starter-template-full/index.html new file mode 100644 index 00000000..49572de9 --- /dev/null +++ b/examples/vite/babylonjs/starter-template-full/index.html @@ -0,0 +1,27 @@ + + + + + + + Bitbybit & ThreeJS All Kernels Example + + + + + + + diff --git a/examples/vite/babylonjs/starter-template-full/package-lock.json b/examples/vite/babylonjs/starter-template-full/package-lock.json new file mode 100644 index 00000000..cd4d6afe --- /dev/null +++ b/examples/vite/babylonjs/starter-template-full/package-lock.json @@ -0,0 +1,3409 @@ +{ + "name": "vite-typescript-starter", + "version": "0.0.0", + "lockfileVersion": 2, + "requires": true, + "packages": { + "": { + "name": "vite-typescript-starter", + "version": "0.0.0", + "dependencies": { + "@bitbybit-dev/babylonjs": "0.21.0" + }, + "devDependencies": { + "@types/three": "0.182.0", + "typescript": "~5.8.3", + "vite": "^6.3.2" + } + }, + "node_modules/@babylonjs/core": { + "version": "8.44.1", + "resolved": "https://registry.npmjs.org/@babylonjs/core/-/core-8.44.1.tgz", + "integrity": "sha512-sF2WWK2d7lg18ESOCxUoRG4d1SzCWz42asjRjRGxZ8r3D7w9ZM3H2wftJIqwaZvD3zWr+wmCVKpQ6hWkboHIXw==", + "license": "Apache-2.0" + }, + "node_modules/@babylonjs/gui": { + "version": "8.44.1", + "resolved": "https://registry.npmjs.org/@babylonjs/gui/-/gui-8.44.1.tgz", + "integrity": "sha512-6STDK+Hr8GpY29YMLKnTVhEnWw1NKPrIpz+MqgWuoAAmmpiFtNCr0nnAnCj5fhgGf25L89jy51ogXyg3jfiuDA==", + "license": "Apache-2.0", + "peerDependencies": { + "@babylonjs/core": "^8.0.0" + } + }, + "node_modules/@babylonjs/havok": { + "version": "1.3.10", + "resolved": "https://registry.npmjs.org/@babylonjs/havok/-/havok-1.3.10.tgz", + "integrity": "sha512-ddF0LPBVmg+rmPaMmwTPA9FcHyUnrSsQqFoBbYbN51WMhEJQ+7gRFW3J5lML6lN9M/fbknh6bh1ZirZ2bU2B/w==", + "license": "MIT", + "dependencies": { + "@types/emscripten": "^1.39.6" + } + }, + "node_modules/@babylonjs/loaders": { + "version": "8.44.1", + "resolved": "https://registry.npmjs.org/@babylonjs/loaders/-/loaders-8.44.1.tgz", + "integrity": "sha512-h5rUGCwhdWv3Hq48DP8sy4/+3QUYjOprxu2i6zXKb69LHMnYE0tZ1xQHBJEOUF60hxA+TwhzdjC8bxInKoeojA==", + "license": "Apache-2.0", + "peerDependencies": { + "@babylonjs/core": "^8.0.0", + "babylonjs-gltf2interface": "^8.0.0" + } + }, + "node_modules/@babylonjs/materials": { + "version": "8.44.1", + "resolved": "https://registry.npmjs.org/@babylonjs/materials/-/materials-8.44.1.tgz", + "integrity": "sha512-FD0S/aA68oEjKCSNY5ydGkiHbsyo08KlhQ+6R8swtJhx5aq7ojWBt3P9KC78+wjZiCJW37176CIObcV8QcjMAQ==", + "license": "Apache-2.0", + "peerDependencies": { + "@babylonjs/core": "^8.6.0" + } + }, + "node_modules/@babylonjs/serializers": { + "version": "8.44.1", + "resolved": "https://registry.npmjs.org/@babylonjs/serializers/-/serializers-8.44.1.tgz", + "integrity": "sha512-3FRRdKpHr2qTkALHEvq0ih0P59iTINUFrGZWFUfO3Wu24UBSuTxY9Kq820dvUUWaRtWkXEnMSQbR+5glzcfqBw==", + "license": "Apache-2.0", + "peerDependencies": { + "@babylonjs/core": "^8.0.0", + "babylonjs-gltf2interface": "^8.0.0" + } + }, + "node_modules/@bitbybit-dev/babylonjs": { + "version": "0.21.0", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/babylonjs/-/babylonjs-0.21.0.tgz", + "integrity": "sha512-8aPJ+XTXzcnO4bXfmW34lTnVCzC6Hy6TMkh7/ziQSoUsjPp7e7LFHoBBfqCk09LdTLa85gb5x/f6WNAn306Odg==", + "license": "MIT", + "dependencies": { + "@babylonjs/core": "8.44.1", + "@babylonjs/gui": "8.44.1", + "@babylonjs/havok": "1.3.10", + "@babylonjs/loaders": "8.44.1", + "@babylonjs/materials": "8.44.1", + "@babylonjs/serializers": "8.44.1", + "@bitbybit-dev/core": "0.21.0", + "earcut": "2.2.3" + } + }, + "node_modules/@bitbybit-dev/base": { + "version": "0.21.0", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/base/-/base-0.21.0.tgz", + "integrity": "sha512-dNfsf2tu3/QUD1mvZzzTze8RwHyK2Jrt+Ary8EDKdNKMw+abtCpQYNerdrg0ZQPxvwu/OOQz6N1xCsCwsPkQJg==", + "license": "MIT" + }, + "node_modules/@bitbybit-dev/core": { + "version": "0.21.0", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/core/-/core-0.21.0.tgz", + "integrity": "sha512-IbeQ8ROreu0/RkkngUE+Eb19ecvqKOWhGefXvIqQmplxt3zEc0FI4Kw8wR3vYl2XMannuVt1xAIYtqqH0tjBzg==", + "license": "MIT", + "dependencies": { + "@bitbybit-dev/base": "0.21.0", + "@bitbybit-dev/jscad-worker": "0.21.0", + "@bitbybit-dev/manifold-worker": "0.21.0", + "@bitbybit-dev/occt-worker": "0.21.0", + "jsonpath-plus": "10.1.0", + "rxjs": "7.5.5", + "verb-nurbs-web": "2.1.3" + } + }, + "node_modules/@bitbybit-dev/jscad": { + "version": "0.21.0", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/jscad/-/jscad-0.21.0.tgz", + "integrity": "sha512-Q7eE2ILrJRstW4L1711aJZdpwPf1kuhZJqB+KLkkBLsneRsGsh82lBcCbVYAOMuF/q8Lnd4JHxPiIG/m+LYmPQ==", + "license": "MIT", + "dependencies": { + "@bitbybit-dev/base": "0.21.0", + "@jscad/3mf-serializer": "2.1.12", + "@jscad/dxf-serializer": "2.1.18", + "@jscad/io-utils": "2.0.28", + "@jscad/modeling": "2.12.3", + "@jscad/stl-serializer": "2.1.18" + } + }, + "node_modules/@bitbybit-dev/jscad-worker": { + "version": "0.21.0", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/jscad-worker/-/jscad-worker-0.21.0.tgz", + "integrity": "sha512-nIvd7GH5Gg51u6PmFXOADXVYTIvixTkNf0YapS1uix7D2JS9Mx10Z4wHAeRKzvJxUAAbEPPRFNkakE22HFGtLQ==", + "license": "MIT", + "dependencies": { + "@bitbybit-dev/jscad": "0.21.0", + "rxjs": "7.5.5" + } + }, + "node_modules/@bitbybit-dev/manifold": { + "version": "0.21.0", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/manifold/-/manifold-0.21.0.tgz", + "integrity": "sha512-DPpwK9ESB+auDeAbzXcfWRVEzWoMDkpkjc+/uwh+zuSiHSx92PSkzx1/LVTbQCsK+aOfOOy03HQCF5Bu2KQYtw==", + "license": "MIT", + "dependencies": { + "@bitbybit-dev/base": "0.21.0", + "manifold-3d": "3.3.2" + } + }, + "node_modules/@bitbybit-dev/manifold-worker": { + "version": "0.21.0", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/manifold-worker/-/manifold-worker-0.21.0.tgz", + "integrity": "sha512-6Cqv3BP+uI8mHKHI6Jx9TzCxRg1/kMHhCe18+B3KD/rTl9B5mnScCKRBnDansR3bH7aYZGnIw9PmiFnWLkQWEQ==", + "license": "MIT", + "dependencies": { + "@bitbybit-dev/manifold": "0.21.0", + "rxjs": "7.5.5" + } + }, + "node_modules/@bitbybit-dev/occt": { + "version": "0.21.0", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/occt/-/occt-0.21.0.tgz", + "integrity": "sha512-vPu3NmF1kBZMOkOdysolGfFxEEnwdHNGORoX3eWbMWT2JL/Tag5Q2CAc5jwa2VvZnS1nE/9x+DVlFQSo8LQnIg==", + "license": "MIT", + "dependencies": { + "@bitbybit-dev/base": "0.21.0" + } + }, + "node_modules/@bitbybit-dev/occt-worker": { + "version": "0.21.0", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/occt-worker/-/occt-worker-0.21.0.tgz", + "integrity": "sha512-xG1sgo6q/RdVA8AgG72wPe4qxcQlrO1V7/Ksn6MqIhZVTsJcm5RbVYlK+nziIWhvlMc1sKE0GNQFcPdALISLuQ==", + "license": "MIT", + "dependencies": { + "@bitbybit-dev/occt": "0.21.0", + "rxjs": "7.5.5" + } + }, + "node_modules/@dimforge/rapier3d-compat": { + "version": "0.12.0", + "resolved": "https://registry.npmjs.org/@dimforge/rapier3d-compat/-/rapier3d-compat-0.12.0.tgz", + "integrity": "sha512-uekIGetywIgopfD97oDL5PfeezkFpNhwlzlaEYNOA0N6ghdsOvh/HYjSMek5Q2O1PYvRSDFcqFVJl4r4ZBwOow==", + "dev": true, + "license": "Apache-2.0" + }, + "node_modules/@emnapi/runtime": { + "version": "1.8.1", + "resolved": "https://registry.npmjs.org/@emnapi/runtime/-/runtime-1.8.1.tgz", + "integrity": "sha512-mehfKSMWjjNol8659Z8KxEMrdSJDDot5SXMq00dM8BN4o+CLNXQ0xH2V7EchNHV4RmbZLmmPdEaXZc5H2FXmDg==", + "license": "MIT", + "optional": true, + "dependencies": { + "tslib": "^2.4.0" + } + }, + "node_modules/@esbuild/aix-ppc64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/aix-ppc64/-/aix-ppc64-0.25.3.tgz", + "integrity": "sha512-W8bFfPA8DowP8l//sxjJLSLkD8iEjMc7cBVyP+u4cEv9sM7mdUCkgsj+t0n/BWPFtv7WWCN5Yzj0N6FJNUUqBQ==", + "cpu": [ + "ppc64" + ], + "dev": true, + "optional": true, + "os": [ + "aix" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/android-arm": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/android-arm/-/android-arm-0.25.3.tgz", + "integrity": "sha512-PuwVXbnP87Tcff5I9ngV0lmiSu40xw1At6i3GsU77U7cjDDB4s0X2cyFuBiDa1SBk9DnvWwnGvVaGBqoFWPb7A==", + "cpu": [ + "arm" + ], + "dev": true, + "optional": true, + "os": [ + "android" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/android-arm64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/android-arm64/-/android-arm64-0.25.3.tgz", + "integrity": "sha512-XelR6MzjlZuBM4f5z2IQHK6LkK34Cvv6Rj2EntER3lwCBFdg6h2lKbtRjpTTsdEjD/WSe1q8UyPBXP1x3i/wYQ==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "android" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/android-x64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/android-x64/-/android-x64-0.25.3.tgz", + "integrity": "sha512-ogtTpYHT/g1GWS/zKM0cc/tIebFjm1F9Aw1boQ2Y0eUQ+J89d0jFY//s9ei9jVIlkYi8AfOjiixcLJSGNSOAdQ==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "android" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/darwin-arm64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/darwin-arm64/-/darwin-arm64-0.25.3.tgz", + "integrity": "sha512-eESK5yfPNTqpAmDfFWNsOhmIOaQA59tAcF/EfYvo5/QWQCzXn5iUSOnqt3ra3UdzBv073ykTtmeLJZGt3HhA+w==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/darwin-x64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/darwin-x64/-/darwin-x64-0.25.3.tgz", + "integrity": "sha512-Kd8glo7sIZtwOLcPbW0yLpKmBNWMANZhrC1r6K++uDR2zyzb6AeOYtI6udbtabmQpFaxJ8uduXMAo1gs5ozz8A==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/freebsd-arm64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/freebsd-arm64/-/freebsd-arm64-0.25.3.tgz", + "integrity": "sha512-EJiyS70BYybOBpJth3M0KLOus0n+RRMKTYzhYhFeMwp7e/RaajXvP+BWlmEXNk6uk+KAu46j/kaQzr6au+JcIw==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "freebsd" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/freebsd-x64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/freebsd-x64/-/freebsd-x64-0.25.3.tgz", + "integrity": "sha512-Q+wSjaLpGxYf7zC0kL0nDlhsfuFkoN+EXrx2KSB33RhinWzejOd6AvgmP5JbkgXKmjhmpfgKZq24pneodYqE8Q==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "freebsd" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-arm": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/linux-arm/-/linux-arm-0.25.3.tgz", + "integrity": "sha512-dUOVmAUzuHy2ZOKIHIKHCm58HKzFqd+puLaS424h6I85GlSDRZIA5ycBixb3mFgM0Jdh+ZOSB6KptX30DD8YOQ==", + "cpu": [ + "arm" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-arm64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/linux-arm64/-/linux-arm64-0.25.3.tgz", + "integrity": "sha512-xCUgnNYhRD5bb1C1nqrDV1PfkwgbswTTBRbAd8aH5PhYzikdf/ddtsYyMXFfGSsb/6t6QaPSzxtbfAZr9uox4A==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-ia32": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/linux-ia32/-/linux-ia32-0.25.3.tgz", + "integrity": "sha512-yplPOpczHOO4jTYKmuYuANI3WhvIPSVANGcNUeMlxH4twz/TeXuzEP41tGKNGWJjuMhotpGabeFYGAOU2ummBw==", + "cpu": [ + "ia32" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-loong64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/linux-loong64/-/linux-loong64-0.25.3.tgz", + "integrity": "sha512-P4BLP5/fjyihmXCELRGrLd793q/lBtKMQl8ARGpDxgzgIKJDRJ/u4r1A/HgpBpKpKZelGct2PGI4T+axcedf6g==", + "cpu": [ + "loong64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-mips64el": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/linux-mips64el/-/linux-mips64el-0.25.3.tgz", + "integrity": "sha512-eRAOV2ODpu6P5divMEMa26RRqb2yUoYsuQQOuFUexUoQndm4MdpXXDBbUoKIc0iPa4aCO7gIhtnYomkn2x+bag==", + "cpu": [ + "mips64el" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-ppc64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/linux-ppc64/-/linux-ppc64-0.25.3.tgz", + "integrity": "sha512-ZC4jV2p7VbzTlnl8nZKLcBkfzIf4Yad1SJM4ZMKYnJqZFD4rTI+pBG65u8ev4jk3/MPwY9DvGn50wi3uhdaghg==", + "cpu": [ + "ppc64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-riscv64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/linux-riscv64/-/linux-riscv64-0.25.3.tgz", + "integrity": "sha512-LDDODcFzNtECTrUUbVCs6j9/bDVqy7DDRsuIXJg6so+mFksgwG7ZVnTruYi5V+z3eE5y+BJZw7VvUadkbfg7QA==", + "cpu": [ + "riscv64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-s390x": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/linux-s390x/-/linux-s390x-0.25.3.tgz", + "integrity": "sha512-s+w/NOY2k0yC2p9SLen+ymflgcpRkvwwa02fqmAwhBRI3SC12uiS10edHHXlVWwfAagYSY5UpmT/zISXPMW3tQ==", + "cpu": [ + "s390x" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-x64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/linux-x64/-/linux-x64-0.25.3.tgz", + "integrity": "sha512-nQHDz4pXjSDC6UfOE1Fw9Q8d6GCAd9KdvMZpfVGWSJztYCarRgSDfOVBY5xwhQXseiyxapkiSJi/5/ja8mRFFA==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/netbsd-arm64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/netbsd-arm64/-/netbsd-arm64-0.25.3.tgz", + "integrity": "sha512-1QaLtOWq0mzK6tzzp0jRN3eccmN3hezey7mhLnzC6oNlJoUJz4nym5ZD7mDnS/LZQgkrhEbEiTn515lPeLpgWA==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "netbsd" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/netbsd-x64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/netbsd-x64/-/netbsd-x64-0.25.3.tgz", + "integrity": "sha512-i5Hm68HXHdgv8wkrt+10Bc50zM0/eonPb/a/OFVfB6Qvpiirco5gBA5bz7S2SHuU+Y4LWn/zehzNX14Sp4r27g==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "netbsd" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/openbsd-arm64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/openbsd-arm64/-/openbsd-arm64-0.25.3.tgz", + "integrity": "sha512-zGAVApJEYTbOC6H/3QBr2mq3upG/LBEXr85/pTtKiv2IXcgKV0RT0QA/hSXZqSvLEpXeIxah7LczB4lkiYhTAQ==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "openbsd" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/openbsd-x64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/openbsd-x64/-/openbsd-x64-0.25.3.tgz", + "integrity": "sha512-fpqctI45NnCIDKBH5AXQBsD0NDPbEFczK98hk/aa6HJxbl+UtLkJV2+Bvy5hLSLk3LHmqt0NTkKNso1A9y1a4w==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "openbsd" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/sunos-x64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/sunos-x64/-/sunos-x64-0.25.3.tgz", + "integrity": "sha512-ROJhm7d8bk9dMCUZjkS8fgzsPAZEjtRJqCAmVgB0gMrvG7hfmPmz9k1rwO4jSiblFjYmNvbECL9uhaPzONMfgA==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "sunos" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/win32-arm64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/win32-arm64/-/win32-arm64-0.25.3.tgz", + "integrity": "sha512-YWcow8peiHpNBiIXHwaswPnAXLsLVygFwCB3A7Bh5jRkIBFWHGmNQ48AlX4xDvQNoMZlPYzjVOQDYEzWCqufMQ==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/win32-ia32": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/win32-ia32/-/win32-ia32-0.25.3.tgz", + "integrity": "sha512-qspTZOIGoXVS4DpNqUYUs9UxVb04khS1Degaw/MnfMe7goQ3lTfQ13Vw4qY/Nj0979BGvMRpAYbs/BAxEvU8ew==", + "cpu": [ + "ia32" + ], + "dev": true, + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/win32-x64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/win32-x64/-/win32-x64-0.25.3.tgz", + "integrity": "sha512-ICgUR+kPimx0vvRzf+N/7L7tVSQeE3BYY+NhHRHXS1kBuPO7z2+7ea2HbhDyZdTephgvNvKrlDDKUexuCVBVvg==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@gltf-transform/core": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/@gltf-transform/core/-/core-4.3.0.tgz", + "integrity": "sha512-ZeaQfszGJ9LYwELszu45CuDQCsE26lJNNe36FVmN8xclaT6WDdCj7fwGpQXo0/l/YgAVAHX+uO7YNBW75/SRYw==", + "license": "MIT", + "dependencies": { + "property-graph": "^4.0.0" + }, + "funding": { + "url": "https://github.com/sponsors/donmccurdy" + } + }, + "node_modules/@gltf-transform/extensions": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/@gltf-transform/extensions/-/extensions-4.3.0.tgz", + "integrity": "sha512-XDAjQPYVMHa/VDpSbfCBwI+/1muwRJCaXhUpLgnUzAjn0D//PgvIAcbNm1EwBl3LIWBSwjDUCn2LiMAjp+aXVw==", + "license": "MIT", + "dependencies": { + "@gltf-transform/core": "^4.3.0", + "ktx-parse": "^1.0.1" + }, + "funding": { + "url": "https://github.com/sponsors/donmccurdy" + } + }, + "node_modules/@gltf-transform/functions": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/@gltf-transform/functions/-/functions-4.3.0.tgz", + "integrity": "sha512-FZggHVgt3DHOezgESBrf2vDzuD2FYQYaNT2sT/aP316SIwhuiIwby3z7rhV9joDvWqqUaPkf1UmkjlOaY9riSQ==", + "license": "MIT", + "dependencies": { + "@gltf-transform/core": "^4.3.0", + "@gltf-transform/extensions": "^4.3.0", + "ktx-parse": "^1.0.1", + "ndarray": "^1.0.19", + "ndarray-lanczos": "^0.3.0", + "ndarray-pixels": "^5.0.1" + }, + "funding": { + "url": "https://github.com/sponsors/donmccurdy" + } + }, + "node_modules/@img/colour": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/@img/colour/-/colour-1.0.0.tgz", + "integrity": "sha512-A5P/LfWGFSl6nsckYtjw9da+19jB8hkJ6ACTGcDfEJ0aE+l2n2El7dsVM7UVHZQ9s2lmYMWlrS21YLy2IR1LUw==", + "license": "MIT", + "engines": { + "node": ">=18" + } + }, + "node_modules/@img/sharp-darwin-arm64": { + "version": "0.34.5", + "resolved": "https://registry.npmjs.org/@img/sharp-darwin-arm64/-/sharp-darwin-arm64-0.34.5.tgz", + "integrity": "sha512-imtQ3WMJXbMY4fxb/Ndp6HBTNVtWCUI0WdobyheGf5+ad6xX8VIDO8u2xE4qc/fr08CKG/7dDseFtn6M6g/r3w==", + "cpu": [ + "arm64" + ], + "license": "Apache-2.0", + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": "^18.17.0 || ^20.3.0 || >=21.0.0" + }, + "funding": { + "url": "https://opencollective.com/libvips" + }, + "optionalDependencies": { + "@img/sharp-libvips-darwin-arm64": "1.2.4" + } + }, + "node_modules/@img/sharp-darwin-x64": { + "version": "0.34.5", + "resolved": "https://registry.npmjs.org/@img/sharp-darwin-x64/-/sharp-darwin-x64-0.34.5.tgz", + "integrity": "sha512-YNEFAF/4KQ/PeW0N+r+aVVsoIY0/qxxikF2SWdp+NRkmMB7y9LBZAVqQ4yhGCm/H3H270OSykqmQMKLBhBJDEw==", + "cpu": [ + "x64" + ], + "license": "Apache-2.0", + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": "^18.17.0 || ^20.3.0 || >=21.0.0" + }, + "funding": { + "url": "https://opencollective.com/libvips" + }, + "optionalDependencies": { + "@img/sharp-libvips-darwin-x64": "1.2.4" + } + }, + "node_modules/@img/sharp-libvips-darwin-arm64": { + "version": "1.2.4", + "resolved": "https://registry.npmjs.org/@img/sharp-libvips-darwin-arm64/-/sharp-libvips-darwin-arm64-1.2.4.tgz", + "integrity": "sha512-zqjjo7RatFfFoP0MkQ51jfuFZBnVE2pRiaydKJ1G/rHZvnsrHAOcQALIi9sA5co5xenQdTugCvtb1cuf78Vf4g==", + "cpu": [ + "arm64" + ], + "license": "LGPL-3.0-or-later", + "optional": true, + "os": [ + "darwin" + ], + "funding": { + "url": "https://opencollective.com/libvips" + } + }, + "node_modules/@img/sharp-libvips-darwin-x64": { + "version": "1.2.4", + "resolved": "https://registry.npmjs.org/@img/sharp-libvips-darwin-x64/-/sharp-libvips-darwin-x64-1.2.4.tgz", + "integrity": "sha512-1IOd5xfVhlGwX+zXv2N93k0yMONvUlANylbJw1eTah8K/Jtpi15KC+WSiaX/nBmbm2HxRM1gZ0nSdjSsrZbGKg==", + "cpu": [ + "x64" + ], + "license": "LGPL-3.0-or-later", + "optional": true, + "os": [ + "darwin" + ], + "funding": { + "url": "https://opencollective.com/libvips" + } + }, + "node_modules/@img/sharp-libvips-linux-arm": { + "version": "1.2.4", + "resolved": "https://registry.npmjs.org/@img/sharp-libvips-linux-arm/-/sharp-libvips-linux-arm-1.2.4.tgz", + "integrity": "sha512-bFI7xcKFELdiNCVov8e44Ia4u2byA+l3XtsAj+Q8tfCwO6BQ8iDojYdvoPMqsKDkuoOo+X6HZA0s0q11ANMQ8A==", + "cpu": [ + "arm" + ], + "license": "LGPL-3.0-or-later", + "optional": true, + "os": [ + "linux" + ], + "funding": { + "url": "https://opencollective.com/libvips" + } + }, + "node_modules/@img/sharp-libvips-linux-arm64": { + "version": "1.2.4", + "resolved": "https://registry.npmjs.org/@img/sharp-libvips-linux-arm64/-/sharp-libvips-linux-arm64-1.2.4.tgz", + "integrity": "sha512-excjX8DfsIcJ10x1Kzr4RcWe1edC9PquDRRPx3YVCvQv+U5p7Yin2s32ftzikXojb1PIFc/9Mt28/y+iRklkrw==", + "cpu": [ + "arm64" + ], + "license": "LGPL-3.0-or-later", + "optional": true, + "os": [ + "linux" + ], + "funding": { + "url": "https://opencollective.com/libvips" + } + }, + "node_modules/@img/sharp-libvips-linux-ppc64": { + "version": "1.2.4", + "resolved": "https://registry.npmjs.org/@img/sharp-libvips-linux-ppc64/-/sharp-libvips-linux-ppc64-1.2.4.tgz", + "integrity": "sha512-FMuvGijLDYG6lW+b/UvyilUWu5Ayu+3r2d1S8notiGCIyYU/76eig1UfMmkZ7vwgOrzKzlQbFSuQfgm7GYUPpA==", + "cpu": [ + "ppc64" + ], + "license": "LGPL-3.0-or-later", + "optional": true, + "os": [ + "linux" + ], + "funding": { + "url": "https://opencollective.com/libvips" + } + }, + "node_modules/@img/sharp-libvips-linux-riscv64": { + "version": "1.2.4", + "resolved": "https://registry.npmjs.org/@img/sharp-libvips-linux-riscv64/-/sharp-libvips-linux-riscv64-1.2.4.tgz", + "integrity": "sha512-oVDbcR4zUC0ce82teubSm+x6ETixtKZBh/qbREIOcI3cULzDyb18Sr/Wcyx7NRQeQzOiHTNbZFF1UwPS2scyGA==", + "cpu": [ + "riscv64" + ], + "license": "LGPL-3.0-or-later", + "optional": true, + "os": [ + "linux" + ], + "funding": { + "url": "https://opencollective.com/libvips" + } + }, + "node_modules/@img/sharp-libvips-linux-s390x": { + "version": "1.2.4", + "resolved": "https://registry.npmjs.org/@img/sharp-libvips-linux-s390x/-/sharp-libvips-linux-s390x-1.2.4.tgz", + "integrity": "sha512-qmp9VrzgPgMoGZyPvrQHqk02uyjA0/QrTO26Tqk6l4ZV0MPWIW6LTkqOIov+J1yEu7MbFQaDpwdwJKhbJvuRxQ==", + "cpu": [ + "s390x" + ], + "license": "LGPL-3.0-or-later", + "optional": true, + "os": [ + "linux" + ], + "funding": { + "url": "https://opencollective.com/libvips" + } + }, + "node_modules/@img/sharp-libvips-linux-x64": { + "version": "1.2.4", + "resolved": "https://registry.npmjs.org/@img/sharp-libvips-linux-x64/-/sharp-libvips-linux-x64-1.2.4.tgz", + "integrity": "sha512-tJxiiLsmHc9Ax1bz3oaOYBURTXGIRDODBqhveVHonrHJ9/+k89qbLl0bcJns+e4t4rvaNBxaEZsFtSfAdquPrw==", + "cpu": [ + "x64" + ], + "license": "LGPL-3.0-or-later", + "optional": true, + "os": [ + "linux" + ], + "funding": { + "url": "https://opencollective.com/libvips" + } + }, + "node_modules/@img/sharp-libvips-linuxmusl-arm64": { + "version": "1.2.4", + "resolved": "https://registry.npmjs.org/@img/sharp-libvips-linuxmusl-arm64/-/sharp-libvips-linuxmusl-arm64-1.2.4.tgz", + "integrity": "sha512-FVQHuwx1IIuNow9QAbYUzJ+En8KcVm9Lk5+uGUQJHaZmMECZmOlix9HnH7n1TRkXMS0pGxIJokIVB9SuqZGGXw==", + "cpu": [ + "arm64" + ], + "license": "LGPL-3.0-or-later", + "optional": true, + "os": [ + "linux" + ], + "funding": { + "url": "https://opencollective.com/libvips" + } + }, + "node_modules/@img/sharp-libvips-linuxmusl-x64": { + "version": "1.2.4", + "resolved": "https://registry.npmjs.org/@img/sharp-libvips-linuxmusl-x64/-/sharp-libvips-linuxmusl-x64-1.2.4.tgz", + "integrity": "sha512-+LpyBk7L44ZIXwz/VYfglaX/okxezESc6UxDSoyo2Ks6Jxc4Y7sGjpgU9s4PMgqgjj1gZCylTieNamqA1MF7Dg==", + "cpu": [ + "x64" + ], + "license": "LGPL-3.0-or-later", + "optional": true, + "os": [ + "linux" + ], + "funding": { + "url": "https://opencollective.com/libvips" + } + }, + "node_modules/@img/sharp-linux-arm": { + "version": "0.34.5", + "resolved": "https://registry.npmjs.org/@img/sharp-linux-arm/-/sharp-linux-arm-0.34.5.tgz", + "integrity": "sha512-9dLqsvwtg1uuXBGZKsxem9595+ujv0sJ6Vi8wcTANSFpwV/GONat5eCkzQo/1O6zRIkh0m/8+5BjrRr7jDUSZw==", + "cpu": [ + "arm" + ], + "license": "Apache-2.0", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": "^18.17.0 || ^20.3.0 || >=21.0.0" + }, + "funding": { + "url": "https://opencollective.com/libvips" + }, + "optionalDependencies": { + "@img/sharp-libvips-linux-arm": "1.2.4" + } + }, + "node_modules/@img/sharp-linux-arm64": { + "version": "0.34.5", + "resolved": "https://registry.npmjs.org/@img/sharp-linux-arm64/-/sharp-linux-arm64-0.34.5.tgz", + "integrity": "sha512-bKQzaJRY/bkPOXyKx5EVup7qkaojECG6NLYswgktOZjaXecSAeCWiZwwiFf3/Y+O1HrauiE3FVsGxFg8c24rZg==", + "cpu": [ + "arm64" + ], + "license": "Apache-2.0", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": "^18.17.0 || ^20.3.0 || >=21.0.0" + }, + "funding": { + "url": "https://opencollective.com/libvips" + }, + "optionalDependencies": { + "@img/sharp-libvips-linux-arm64": "1.2.4" + } + }, + "node_modules/@img/sharp-linux-ppc64": { + "version": "0.34.5", + "resolved": "https://registry.npmjs.org/@img/sharp-linux-ppc64/-/sharp-linux-ppc64-0.34.5.tgz", + "integrity": "sha512-7zznwNaqW6YtsfrGGDA6BRkISKAAE1Jo0QdpNYXNMHu2+0dTrPflTLNkpc8l7MUP5M16ZJcUvysVWWrMefZquA==", + "cpu": [ + "ppc64" + ], + "license": "Apache-2.0", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": "^18.17.0 || ^20.3.0 || >=21.0.0" + }, + "funding": { + "url": "https://opencollective.com/libvips" + }, + "optionalDependencies": { + "@img/sharp-libvips-linux-ppc64": "1.2.4" + } + }, + "node_modules/@img/sharp-linux-riscv64": { + "version": "0.34.5", + "resolved": "https://registry.npmjs.org/@img/sharp-linux-riscv64/-/sharp-linux-riscv64-0.34.5.tgz", + "integrity": "sha512-51gJuLPTKa7piYPaVs8GmByo7/U7/7TZOq+cnXJIHZKavIRHAP77e3N2HEl3dgiqdD/w0yUfiJnII77PuDDFdw==", + "cpu": [ + "riscv64" + ], + "license": "Apache-2.0", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": "^18.17.0 || ^20.3.0 || >=21.0.0" + }, + "funding": { + "url": "https://opencollective.com/libvips" + }, + "optionalDependencies": { + "@img/sharp-libvips-linux-riscv64": "1.2.4" + } + }, + "node_modules/@img/sharp-linux-s390x": { + "version": "0.34.5", + "resolved": "https://registry.npmjs.org/@img/sharp-linux-s390x/-/sharp-linux-s390x-0.34.5.tgz", + "integrity": "sha512-nQtCk0PdKfho3eC5MrbQoigJ2gd1CgddUMkabUj+rBevs8tZ2cULOx46E7oyX+04WGfABgIwmMC0VqieTiR4jg==", + "cpu": [ + "s390x" + ], + "license": "Apache-2.0", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": "^18.17.0 || ^20.3.0 || >=21.0.0" + }, + "funding": { + "url": "https://opencollective.com/libvips" + }, + "optionalDependencies": { + "@img/sharp-libvips-linux-s390x": "1.2.4" + } + }, + "node_modules/@img/sharp-linux-x64": { + "version": "0.34.5", + "resolved": "https://registry.npmjs.org/@img/sharp-linux-x64/-/sharp-linux-x64-0.34.5.tgz", + "integrity": "sha512-MEzd8HPKxVxVenwAa+JRPwEC7QFjoPWuS5NZnBt6B3pu7EG2Ge0id1oLHZpPJdn3OQK+BQDiw9zStiHBTJQQQQ==", + "cpu": [ + "x64" + ], + "license": "Apache-2.0", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": "^18.17.0 || ^20.3.0 || >=21.0.0" + }, + "funding": { + "url": "https://opencollective.com/libvips" + }, + "optionalDependencies": { + "@img/sharp-libvips-linux-x64": "1.2.4" + } + }, + "node_modules/@img/sharp-linuxmusl-arm64": { + "version": "0.34.5", + "resolved": "https://registry.npmjs.org/@img/sharp-linuxmusl-arm64/-/sharp-linuxmusl-arm64-0.34.5.tgz", + "integrity": "sha512-fprJR6GtRsMt6Kyfq44IsChVZeGN97gTD331weR1ex1c1rypDEABN6Tm2xa1wE6lYb5DdEnk03NZPqA7Id21yg==", + "cpu": [ + "arm64" + ], + "license": "Apache-2.0", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": "^18.17.0 || ^20.3.0 || >=21.0.0" + }, + "funding": { + "url": "https://opencollective.com/libvips" + }, + "optionalDependencies": { + "@img/sharp-libvips-linuxmusl-arm64": "1.2.4" + } + }, + "node_modules/@img/sharp-linuxmusl-x64": { + "version": "0.34.5", + "resolved": "https://registry.npmjs.org/@img/sharp-linuxmusl-x64/-/sharp-linuxmusl-x64-0.34.5.tgz", + "integrity": "sha512-Jg8wNT1MUzIvhBFxViqrEhWDGzqymo3sV7z7ZsaWbZNDLXRJZoRGrjulp60YYtV4wfY8VIKcWidjojlLcWrd8Q==", + "cpu": [ + "x64" + ], + "license": "Apache-2.0", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": "^18.17.0 || ^20.3.0 || >=21.0.0" + }, + "funding": { + "url": "https://opencollective.com/libvips" + }, + "optionalDependencies": { + "@img/sharp-libvips-linuxmusl-x64": "1.2.4" + } + }, + "node_modules/@img/sharp-wasm32": { + "version": "0.34.5", + "resolved": "https://registry.npmjs.org/@img/sharp-wasm32/-/sharp-wasm32-0.34.5.tgz", + "integrity": "sha512-OdWTEiVkY2PHwqkbBI8frFxQQFekHaSSkUIJkwzclWZe64O1X4UlUjqqqLaPbUpMOQk6FBu/HtlGXNblIs0huw==", + "cpu": [ + "wasm32" + ], + "license": "Apache-2.0 AND LGPL-3.0-or-later AND MIT", + "optional": true, + "dependencies": { + "@emnapi/runtime": "^1.7.0" + }, + "engines": { + "node": "^18.17.0 || ^20.3.0 || >=21.0.0" + }, + "funding": { + "url": "https://opencollective.com/libvips" + } + }, + "node_modules/@img/sharp-win32-arm64": { + "version": "0.34.5", + "resolved": "https://registry.npmjs.org/@img/sharp-win32-arm64/-/sharp-win32-arm64-0.34.5.tgz", + "integrity": "sha512-WQ3AgWCWYSb2yt+IG8mnC6Jdk9Whs7O0gxphblsLvdhSpSTtmu69ZG1Gkb6NuvxsNACwiPV6cNSZNzt0KPsw7g==", + "cpu": [ + "arm64" + ], + "license": "Apache-2.0 AND LGPL-3.0-or-later", + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": "^18.17.0 || ^20.3.0 || >=21.0.0" + }, + "funding": { + "url": "https://opencollective.com/libvips" + } + }, + "node_modules/@img/sharp-win32-ia32": { + "version": "0.34.5", + "resolved": "https://registry.npmjs.org/@img/sharp-win32-ia32/-/sharp-win32-ia32-0.34.5.tgz", + "integrity": "sha512-FV9m/7NmeCmSHDD5j4+4pNI8Cp3aW+JvLoXcTUo0IqyjSfAZJ8dIUmijx1qaJsIiU+Hosw6xM5KijAWRJCSgNg==", + "cpu": [ + "ia32" + ], + "license": "Apache-2.0 AND LGPL-3.0-or-later", + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": "^18.17.0 || ^20.3.0 || >=21.0.0" + }, + "funding": { + "url": "https://opencollective.com/libvips" + } + }, + "node_modules/@img/sharp-win32-x64": { + "version": "0.34.5", + "resolved": "https://registry.npmjs.org/@img/sharp-win32-x64/-/sharp-win32-x64-0.34.5.tgz", + "integrity": "sha512-+29YMsqY2/9eFEiW93eqWnuLcWcufowXewwSNIT6UwZdUUCrM3oFjMWH/Z6/TMmb4hlFenmfAVbpWeup2jryCw==", + "cpu": [ + "x64" + ], + "license": "Apache-2.0 AND LGPL-3.0-or-later", + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": "^18.17.0 || ^20.3.0 || >=21.0.0" + }, + "funding": { + "url": "https://opencollective.com/libvips" + } + }, + "node_modules/@jridgewell/resolve-uri": { + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/@jridgewell/resolve-uri/-/resolve-uri-3.1.2.tgz", + "integrity": "sha512-bRISgCIjP20/tbWSPWMEi54QVPRZExkuD9lJL+UIxUKtwVJA8wW1Trb1jMs1RFXo1CBTNZ/5hpC9QvmKWdopKw==", + "license": "MIT", + "engines": { + "node": ">=6.0.0" + } + }, + "node_modules/@jridgewell/sourcemap-codec": { + "version": "1.5.5", + "resolved": "https://registry.npmjs.org/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.5.5.tgz", + "integrity": "sha512-cYQ9310grqxueWbl+WuIUIaiUaDcj7WOq5fVhEljNVgRfOUhY9fy2zTvfoqWsnebh8Sl70VScFbICvJnLKB0Og==", + "license": "MIT" + }, + "node_modules/@jridgewell/trace-mapping": { + "version": "0.3.31", + "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.31.tgz", + "integrity": "sha512-zzNR+SdQSDJzc8joaeP8QQoCQr8NuYx2dIIytl1QeBEZHJ9uW6hebsrYgbz8hJwUQao3TWCMtmfV8Nu1twOLAw==", + "license": "MIT", + "dependencies": { + "@jridgewell/resolve-uri": "^3.1.0", + "@jridgewell/sourcemap-codec": "^1.4.14" + } + }, + "node_modules/@jscad/3mf-serializer": { + "version": "2.1.12", + "resolved": "https://registry.npmjs.org/@jscad/3mf-serializer/-/3mf-serializer-2.1.12.tgz", + "integrity": "sha512-+rxAIKIHCpaplupwwsdXtG1IdimPXFFB45nrjy6gdFHi36bEQW6y/RQD/ngenRiKnYSxu7/M0LatHcjve8z64A==", + "license": "MIT", + "dependencies": { + "@jscad/array-utils": "2.1.4", + "@jscad/modeling": "2.12.3", + "fflate": "0.7.3", + "onml": "1.2.0" + } + }, + "node_modules/@jscad/array-utils": { + "version": "2.1.4", + "resolved": "https://registry.npmjs.org/@jscad/array-utils/-/array-utils-2.1.4.tgz", + "integrity": "sha512-c31r4zSKsE+4Xfwk2V8monDA0hx5G89QGzaakWVUvuGNowYS9WSsYCwHiTIXodjR+HEnDu4okQ7k/whmP0Ne2g==", + "license": "MIT" + }, + "node_modules/@jscad/dxf-serializer": { + "version": "2.1.18", + "resolved": "https://registry.npmjs.org/@jscad/dxf-serializer/-/dxf-serializer-2.1.18.tgz", + "integrity": "sha512-T5Qe2jbEphcWAk7GaOY8PCMD4DPhTm6gWk/MPJCExphhnUwJqcU/1RiMb5hiD+N6hHzmlxD59I8QTjlp9LbLSA==", + "license": "MIT", + "dependencies": { + "@jscad/array-utils": "2.1.4", + "@jscad/modeling": "2.12.3" + } + }, + "node_modules/@jscad/io-utils": { + "version": "2.0.28", + "resolved": "https://registry.npmjs.org/@jscad/io-utils/-/io-utils-2.0.28.tgz", + "integrity": "sha512-spXh37wAgmwjKztoH/HANLgImcqRHX5+H/cRIxPfpqDIWvu7I5bRg2ZTwh25SYlKIzxPk4qX5Nu7Ax5+Kg+QXQ==", + "license": "MIT" + }, + "node_modules/@jscad/modeling": { + "version": "2.12.3", + "resolved": "https://registry.npmjs.org/@jscad/modeling/-/modeling-2.12.3.tgz", + "integrity": "sha512-DnAacXq3zhlYWIixGlFD7RMpgZAMuCaMZNQov0NaoFfs2GaBuTC5eqkqKcEVbhEerBmTllbjjF5IXjJMt9jcOA==", + "license": "MIT" + }, + "node_modules/@jscad/stl-serializer": { + "version": "2.1.18", + "resolved": "https://registry.npmjs.org/@jscad/stl-serializer/-/stl-serializer-2.1.18.tgz", + "integrity": "sha512-pz++TRjHI7jBPnnxQUi4B/uYUG3yCDsKlw8+xL2kumwjb+auc6Ng6Rnr/GqUTkgHrnGut08wg/8AekyWjvBwYg==", + "license": "MIT", + "dependencies": { + "@jscad/array-utils": "2.1.4", + "@jscad/modeling": "2.12.3" + } + }, + "node_modules/@jscadui/3mf-export": { + "version": "0.5.0", + "resolved": "https://registry.npmjs.org/@jscadui/3mf-export/-/3mf-export-0.5.0.tgz", + "integrity": "sha512-y5vZktqCjyi7wA38zqNlLIdZUIRZoOO9vCjLzwmL4bR0hk7B/Zm1IeffzJPFe1vFc0C1IEv3hm8caDv3doRk9g==", + "license": "MIT" + }, + "node_modules/@jsep-plugin/assignment": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/@jsep-plugin/assignment/-/assignment-1.3.0.tgz", + "integrity": "sha512-VVgV+CXrhbMI3aSusQyclHkenWSAm95WaiKrMxRFam3JSUiIaQjoMIw2sEs/OX4XifnqeQUN4DYbJjlA8EfktQ==", + "license": "MIT", + "engines": { + "node": ">= 10.16.0" + }, + "peerDependencies": { + "jsep": "^0.4.0||^1.0.0" + } + }, + "node_modules/@jsep-plugin/regex": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/@jsep-plugin/regex/-/regex-1.0.4.tgz", + "integrity": "sha512-q7qL4Mgjs1vByCaTnDFcBnV9HS7GVPJX5vyVoCgZHNSC9rjwIlmbXG5sUuorR5ndfHAIlJ8pVStxvjXHbNvtUg==", + "license": "MIT", + "engines": { + "node": ">= 10.16.0" + }, + "peerDependencies": { + "jsep": "^0.4.0||^1.0.0" + } + }, + "node_modules/@rollup/rollup-android-arm-eabi": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-android-arm-eabi/-/rollup-android-arm-eabi-4.40.1.tgz", + "integrity": "sha512-kxz0YeeCrRUHz3zyqvd7n+TVRlNyTifBsmnmNPtk3hQURUyG9eAB+usz6DAwagMusjx/zb3AjvDUvhFGDAexGw==", + "cpu": [ + "arm" + ], + "dev": true, + "optional": true, + "os": [ + "android" + ] + }, + "node_modules/@rollup/rollup-android-arm64": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-android-arm64/-/rollup-android-arm64-4.40.1.tgz", + "integrity": "sha512-PPkxTOisoNC6TpnDKatjKkjRMsdaWIhyuMkA4UsBXT9WEZY4uHezBTjs6Vl4PbqQQeu6oION1w2voYZv9yquCw==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "android" + ] + }, + "node_modules/@rollup/rollup-darwin-arm64": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-darwin-arm64/-/rollup-darwin-arm64-4.40.1.tgz", + "integrity": "sha512-VWXGISWFY18v/0JyNUy4A46KCFCb9NVsH+1100XP31lud+TzlezBbz24CYzbnA4x6w4hx+NYCXDfnvDVO6lcAA==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "darwin" + ] + }, + "node_modules/@rollup/rollup-darwin-x64": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-darwin-x64/-/rollup-darwin-x64-4.40.1.tgz", + "integrity": "sha512-nIwkXafAI1/QCS7pxSpv/ZtFW6TXcNUEHAIA9EIyw5OzxJZQ1YDrX+CL6JAIQgZ33CInl1R6mHet9Y/UZTg2Bw==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "darwin" + ] + }, + "node_modules/@rollup/rollup-freebsd-arm64": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-freebsd-arm64/-/rollup-freebsd-arm64-4.40.1.tgz", + "integrity": "sha512-BdrLJ2mHTrIYdaS2I99mriyJfGGenSaP+UwGi1kB9BLOCu9SR8ZpbkmmalKIALnRw24kM7qCN0IOm6L0S44iWw==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "freebsd" + ] + }, + "node_modules/@rollup/rollup-freebsd-x64": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-freebsd-x64/-/rollup-freebsd-x64-4.40.1.tgz", + "integrity": "sha512-VXeo/puqvCG8JBPNZXZf5Dqq7BzElNJzHRRw3vjBE27WujdzuOPecDPc/+1DcdcTptNBep3861jNq0mYkT8Z6Q==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "freebsd" + ] + }, + "node_modules/@rollup/rollup-linux-arm-gnueabihf": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm-gnueabihf/-/rollup-linux-arm-gnueabihf-4.40.1.tgz", + "integrity": "sha512-ehSKrewwsESPt1TgSE/na9nIhWCosfGSFqv7vwEtjyAqZcvbGIg4JAcV7ZEh2tfj/IlfBeZjgOXm35iOOjadcg==", + "cpu": [ + "arm" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/rollup-linux-arm-musleabihf": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm-musleabihf/-/rollup-linux-arm-musleabihf-4.40.1.tgz", + "integrity": "sha512-m39iO/aaurh5FVIu/F4/Zsl8xppd76S4qoID8E+dSRQvTyZTOI2gVk3T4oqzfq1PtcvOfAVlwLMK3KRQMaR8lg==", + "cpu": [ + "arm" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/rollup-linux-arm64-gnu": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm64-gnu/-/rollup-linux-arm64-gnu-4.40.1.tgz", + "integrity": "sha512-Y+GHnGaku4aVLSgrT0uWe2o2Rq8te9hi+MwqGF9r9ORgXhmHK5Q71N757u0F8yU1OIwUIFy6YiJtKjtyktk5hg==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/rollup-linux-arm64-musl": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm64-musl/-/rollup-linux-arm64-musl-4.40.1.tgz", + "integrity": "sha512-jEwjn3jCA+tQGswK3aEWcD09/7M5wGwc6+flhva7dsQNRZZTe30vkalgIzV4tjkopsTS9Jd7Y1Bsj6a4lzz8gQ==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/rollup-linux-loongarch64-gnu": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-loongarch64-gnu/-/rollup-linux-loongarch64-gnu-4.40.1.tgz", + "integrity": "sha512-ySyWikVhNzv+BV/IDCsrraOAZ3UaC8SZB67FZlqVwXwnFhPihOso9rPOxzZbjp81suB1O2Topw+6Ug3JNegejQ==", + "cpu": [ + "loong64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/rollup-linux-powerpc64le-gnu": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-powerpc64le-gnu/-/rollup-linux-powerpc64le-gnu-4.40.1.tgz", + "integrity": "sha512-BvvA64QxZlh7WZWqDPPdt0GH4bznuL6uOO1pmgPnnv86rpUpc8ZxgZwcEgXvo02GRIZX1hQ0j0pAnhwkhwPqWg==", + "cpu": [ + "ppc64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/rollup-linux-riscv64-gnu": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-riscv64-gnu/-/rollup-linux-riscv64-gnu-4.40.1.tgz", + "integrity": "sha512-EQSP+8+1VuSulm9RKSMKitTav89fKbHymTf25n5+Yr6gAPZxYWpj3DzAsQqoaHAk9YX2lwEyAf9S4W8F4l3VBQ==", + "cpu": [ + "riscv64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/rollup-linux-riscv64-musl": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-riscv64-musl/-/rollup-linux-riscv64-musl-4.40.1.tgz", + "integrity": "sha512-n/vQ4xRZXKuIpqukkMXZt9RWdl+2zgGNx7Uda8NtmLJ06NL8jiHxUawbwC+hdSq1rrw/9CghCpEONor+l1e2gA==", + "cpu": [ + "riscv64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/rollup-linux-s390x-gnu": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-s390x-gnu/-/rollup-linux-s390x-gnu-4.40.1.tgz", + "integrity": "sha512-h8d28xzYb98fMQKUz0w2fMc1XuGzLLjdyxVIbhbil4ELfk5/orZlSTpF/xdI9C8K0I8lCkq+1En2RJsawZekkg==", + "cpu": [ + "s390x" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/rollup-linux-x64-gnu": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-x64-gnu/-/rollup-linux-x64-gnu-4.40.1.tgz", + "integrity": "sha512-XiK5z70PEFEFqcNj3/zRSz/qX4bp4QIraTy9QjwJAb/Z8GM7kVUsD0Uk8maIPeTyPCP03ChdI+VVmJriKYbRHQ==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/rollup-linux-x64-musl": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-x64-musl/-/rollup-linux-x64-musl-4.40.1.tgz", + "integrity": "sha512-2BRORitq5rQ4Da9blVovzNCMaUlyKrzMSvkVR0D4qPuOy/+pMCrh1d7o01RATwVy+6Fa1WBw+da7QPeLWU/1mQ==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/rollup-win32-arm64-msvc": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-arm64-msvc/-/rollup-win32-arm64-msvc-4.40.1.tgz", + "integrity": "sha512-b2bcNm9Kbde03H+q+Jjw9tSfhYkzrDUf2d5MAd1bOJuVplXvFhWz7tRtWvD8/ORZi7qSCy0idW6tf2HgxSXQSg==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "win32" + ] + }, + "node_modules/@rollup/rollup-win32-ia32-msvc": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-ia32-msvc/-/rollup-win32-ia32-msvc-4.40.1.tgz", + "integrity": "sha512-DfcogW8N7Zg7llVEfpqWMZcaErKfsj9VvmfSyRjCyo4BI3wPEfrzTtJkZG6gKP/Z92wFm6rz2aDO7/JfiR/whA==", + "cpu": [ + "ia32" + ], + "dev": true, + "optional": true, + "os": [ + "win32" + ] + }, + "node_modules/@rollup/rollup-win32-x64-msvc": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-x64-msvc/-/rollup-win32-x64-msvc-4.40.1.tgz", + "integrity": "sha512-ECyOuDeH3C1I8jH2MK1RtBJW+YPMvSfT0a5NN0nHfQYnDSJ6tUiZH3gzwVP5/Kfh/+Tt7tpWVF9LXNTnhTJ3kA==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "win32" + ] + }, + "node_modules/@tweenjs/tween.js": { + "version": "23.1.3", + "resolved": "https://registry.npmjs.org/@tweenjs/tween.js/-/tween.js-23.1.3.tgz", + "integrity": "sha512-vJmvvwFxYuGnF2axRtPYocag6Clbb5YS7kLL+SO/TeVFzHqDIWrNKYtcsPMibjDx9O+bu+psAy9NKfWklassUA==", + "dev": true, + "license": "MIT" + }, + "node_modules/@types/emscripten": { + "version": "1.40.1", + "resolved": "https://registry.npmjs.org/@types/emscripten/-/emscripten-1.40.1.tgz", + "integrity": "sha512-sr53lnYkQNhjHNN0oJDdUm5564biioI5DuOpycufDVK7D3y+GR3oUswe2rlwY1nPNyusHbrJ9WoTyIHl4/Bpwg==", + "license": "MIT" + }, + "node_modules/@types/estree": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/@types/estree/-/estree-1.0.7.tgz", + "integrity": "sha512-w28IoSUCJpidD/TGviZwwMJckNESJZXFu7NBZ5YJ4mEUnNraUn9Pm8HSZm/jDF1pDWYKspWE7oVphigUPRakIQ==", + "dev": true + }, + "node_modules/@types/ndarray": { + "version": "1.0.14", + "resolved": "https://registry.npmjs.org/@types/ndarray/-/ndarray-1.0.14.tgz", + "integrity": "sha512-oANmFZMnFQvb219SSBIhI1Ih/r4CvHDOzkWyJS/XRqkMrGH5/kaPSA1hQhdIBzouaE+5KpE/f5ylI9cujmckQg==", + "license": "MIT" + }, + "node_modules/@types/stats.js": { + "version": "0.17.3", + "resolved": "https://registry.npmjs.org/@types/stats.js/-/stats.js-0.17.3.tgz", + "integrity": "sha512-pXNfAD3KHOdif9EQXZ9deK82HVNaXP5ZIF5RP2QG6OQFNTaY2YIetfrE9t528vEreGQvEPRDDc8muaoYeK0SxQ==", + "dev": true, + "license": "MIT" + }, + "node_modules/@types/three": { + "version": "0.182.0", + "resolved": "https://registry.npmjs.org/@types/three/-/three-0.182.0.tgz", + "integrity": "sha512-WByN9V3Sbwbe2OkWuSGyoqQO8Du6yhYaXtXLoA5FkKTUJorZ+yOHBZ35zUUPQXlAKABZmbYp5oAqpA4RBjtJ/Q==", + "dev": true, + "license": "MIT", + "dependencies": { + "@dimforge/rapier3d-compat": "~0.12.0", + "@tweenjs/tween.js": "~23.1.3", + "@types/stats.js": "*", + "@types/webxr": ">=0.5.17", + "@webgpu/types": "*", + "fflate": "~0.8.2", + "meshoptimizer": "~0.22.0" + } + }, + "node_modules/@types/three/node_modules/fflate": { + "version": "0.8.2", + "resolved": "https://registry.npmjs.org/fflate/-/fflate-0.8.2.tgz", + "integrity": "sha512-cPJU47OaAoCbg0pBvzsgpTPhmhqI5eJjh/JIu8tPj5q+T7iLvW/JAYUqmE7KOB4R1ZyEhzBaIQpQpardBF5z8A==", + "dev": true, + "license": "MIT" + }, + "node_modules/@types/webxr": { + "version": "0.5.22", + "resolved": "https://registry.npmjs.org/@types/webxr/-/webxr-0.5.22.tgz", + "integrity": "sha512-Vr6Stjv5jPRqH690f5I5GLjVk8GSsoQSYJ2FVd/3jJF7KaqfwPi3ehfBS96mlQ2kPCwZaX6U0rG2+NGHBKkA/A==", + "dev": true, + "license": "MIT" + }, + "node_modules/@webgpu/types": { + "version": "0.1.60", + "resolved": "https://registry.npmjs.org/@webgpu/types/-/types-0.1.60.tgz", + "integrity": "sha512-8B/tdfRFKdrnejqmvq95ogp8tf52oZ51p3f4QD5m5Paey/qlX4Rhhy5Y8tgFMi7Ms70HzcMMw3EQjH/jdhTwlA==", + "dev": true, + "license": "BSD-3-Clause" + }, + "node_modules/babylonjs-gltf2interface": { + "version": "8.44.1", + "resolved": "https://registry.npmjs.org/babylonjs-gltf2interface/-/babylonjs-gltf2interface-8.44.1.tgz", + "integrity": "sha512-+z0P0wms1FD5xuVpuRJ1qjvGAbPAWhEWGBWENRPD0Hbz6nd9cnL28/pjxgk39/QhlIuJKL9JZ0o8G0JgLHEnRQ==", + "license": "Apache-2.0", + "peer": true + }, + "node_modules/bindings": { + "version": "1.5.0", + "resolved": "https://registry.npmjs.org/bindings/-/bindings-1.5.0.tgz", + "integrity": "sha512-p2q/t/mhvuOj/UeLlV6566GD/guowlr0hHxClI0W9m7MWYkL1F0hLo+0Aexs9HSPCtR1SXQ0TD3MMKrXZajbiQ==", + "license": "MIT", + "optional": true, + "dependencies": { + "file-uri-to-path": "1.0.0" + } + }, + "node_modules/commander": { + "version": "13.1.0", + "resolved": "https://registry.npmjs.org/commander/-/commander-13.1.0.tgz", + "integrity": "sha512-/rFeCpNJQbhSZjGVwO9RFV3xPqbnERS8MmIQzCtD/zl6gpJuV/bMLuN92oG3F7d8oDEHHRrujSXNUr8fpjntKw==", + "license": "MIT", + "engines": { + "node": ">=18" + } + }, + "node_modules/convert-source-map": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/convert-source-map/-/convert-source-map-2.0.0.tgz", + "integrity": "sha512-Kvp459HrV2FEJ1CAsi1Ku+MY3kasH19TFykTz2xWmMeq6bk2NU3XXvfJ+Q61m0xktWwt+1HSYf3JZsTms3aRJg==", + "license": "MIT" + }, + "node_modules/core-js": { + "version": "3.47.0", + "resolved": "https://registry.npmjs.org/core-js/-/core-js-3.47.0.tgz", + "integrity": "sha512-c3Q2VVkGAUyupsjRnaNX6u8Dq2vAdzm9iuPj5FW0fRxzlxgq9Q39MDq10IvmQSpLgHQNyQzQmOo6bgGHmH3NNg==", + "hasInstallScript": true, + "license": "MIT", + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/core-js" + } + }, + "node_modules/cwise-compiler": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/cwise-compiler/-/cwise-compiler-1.1.3.tgz", + "integrity": "sha512-WXlK/m+Di8DMMcCjcWr4i+XzcQra9eCdXIJrgh4TUgh0pIS/yJduLxS9JgefsHJ/YVLdgPtXm9r62W92MvanEQ==", + "license": "MIT", + "dependencies": { + "uniq": "^1.0.0" + } + }, + "node_modules/detect-libc": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/detect-libc/-/detect-libc-2.1.2.tgz", + "integrity": "sha512-Btj2BOOO83o3WyH59e8MgXsxEQVcarkUOpEYrubB0urwnN10yQ364rsiByU11nZlqWYZm05i/of7io4mzihBtQ==", + "license": "Apache-2.0", + "engines": { + "node": ">=8" + } + }, + "node_modules/earcut": { + "version": "2.2.3", + "resolved": "https://registry.npmjs.org/earcut/-/earcut-2.2.3.tgz", + "integrity": "sha512-iRDI1QeCQIhMCZk48DRDMVgQSSBDmbzzNhnxIo+pwx3swkfjMh6vh0nWLq1NdvGHLKH6wIrAM3vQWeTj6qeoug==", + "license": "ISC" + }, + "node_modules/esbuild": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/esbuild/-/esbuild-0.25.3.tgz", + "integrity": "sha512-qKA6Pvai73+M2FtftpNKRxJ78GIjmFXFxd/1DVBqGo/qNhLSfv+G12n9pNoWdytJC8U00TrViOwpjT0zgqQS8Q==", + "dev": true, + "hasInstallScript": true, + "bin": { + "esbuild": "bin/esbuild" + }, + "engines": { + "node": ">=18" + }, + "optionalDependencies": { + "@esbuild/aix-ppc64": "0.25.3", + "@esbuild/android-arm": "0.25.3", + "@esbuild/android-arm64": "0.25.3", + "@esbuild/android-x64": "0.25.3", + "@esbuild/darwin-arm64": "0.25.3", + "@esbuild/darwin-x64": "0.25.3", + "@esbuild/freebsd-arm64": "0.25.3", + "@esbuild/freebsd-x64": "0.25.3", + "@esbuild/linux-arm": "0.25.3", + "@esbuild/linux-arm64": "0.25.3", + "@esbuild/linux-ia32": "0.25.3", + "@esbuild/linux-loong64": "0.25.3", + "@esbuild/linux-mips64el": "0.25.3", + "@esbuild/linux-ppc64": "0.25.3", + "@esbuild/linux-riscv64": "0.25.3", + "@esbuild/linux-s390x": "0.25.3", + "@esbuild/linux-x64": "0.25.3", + "@esbuild/netbsd-arm64": "0.25.3", + "@esbuild/netbsd-x64": "0.25.3", + "@esbuild/openbsd-arm64": "0.25.3", + "@esbuild/openbsd-x64": "0.25.3", + "@esbuild/sunos-x64": "0.25.3", + "@esbuild/win32-arm64": "0.25.3", + "@esbuild/win32-ia32": "0.25.3", + "@esbuild/win32-x64": "0.25.3" + } + }, + "node_modules/esbuild-plugin-text-replace": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/esbuild-plugin-text-replace/-/esbuild-plugin-text-replace-1.3.0.tgz", + "integrity": "sha512-RWB/bbdP0xDHBOtA0st4CAE6UZtky76aCB7Shw5r350JY403lfvrj2UMkInUB346tMtFWXKWXNf4gqNM+WbXag==", + "license": "BSD-2-Clause", + "dependencies": { + "ts-replace-all": "^1.0.0" + }, + "engines": { + "node": ">=10.1.0" + } + }, + "node_modules/esbuild-wasm": { + "version": "0.25.12", + "resolved": "https://registry.npmjs.org/esbuild-wasm/-/esbuild-wasm-0.25.12.tgz", + "integrity": "sha512-rZqkjL3Y6FwLpSHzLnaEy8Ps6veCNo1kZa9EOfJvmWtBq5dJH4iVjfmOO6Mlkv9B0tt9WFPFmb/VxlgJOnueNg==", + "license": "MIT", + "bin": { + "esbuild": "bin/esbuild" + }, + "engines": { + "node": ">=18" + } + }, + "node_modules/fdir": { + "version": "6.4.4", + "resolved": "https://registry.npmjs.org/fdir/-/fdir-6.4.4.tgz", + "integrity": "sha512-1NZP+GK4GfuAv3PqKvxQRDMjdSRZjnkq7KfhlNrCNNlZ0ygQFpebfrnfnq/W7fpUnAv9aGWmY1zKx7FYL3gwhg==", + "dev": true, + "peerDependencies": { + "picomatch": "^3 || ^4" + }, + "peerDependenciesMeta": { + "picomatch": { + "optional": true + } + } + }, + "node_modules/fflate": { + "version": "0.7.3", + "resolved": "https://registry.npmjs.org/fflate/-/fflate-0.7.3.tgz", + "integrity": "sha512-0Zz1jOzJWERhyhsimS54VTqOteCNwRtIlh8isdL0AXLo0g7xNTfTL7oWrkmCnPhZGocKIkWHBistBrrpoNH3aw==", + "license": "MIT" + }, + "node_modules/file-uri-to-path": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/file-uri-to-path/-/file-uri-to-path-1.0.0.tgz", + "integrity": "sha512-0Zt+s3L7Vf1biwWZ29aARiVYLx7iMGnEUl9x33fbB/j3jR81u/O2LbqK+Bm1CDSNDKVtJ/YjwY7TUd5SkeLQLw==", + "license": "MIT", + "optional": true + }, + "node_modules/fsevents": { + "version": "2.3.3", + "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.3.tgz", + "integrity": "sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw==", + "dev": true, + "hasInstallScript": true, + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": "^8.16.0 || ^10.6.0 || >=11.0.0" + } + }, + "node_modules/iota-array": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/iota-array/-/iota-array-1.0.0.tgz", + "integrity": "sha512-pZ2xT+LOHckCatGQ3DcG/a+QuEqvoxqkiL7tvE8nn3uuu+f6i1TtpB5/FtWFbxUuVr5PZCx8KskuGatbJDXOWA==", + "license": "MIT" + }, + "node_modules/is-buffer": { + "version": "1.1.6", + "resolved": "https://registry.npmjs.org/is-buffer/-/is-buffer-1.1.6.tgz", + "integrity": "sha512-NcdALwpXkTm5Zvvbk7owOUSvVvBKDgKP5/ewfXEznmQFfs4ZRmanOeKBTjRVjka3QFoN6XJ+9F3USqfHqTaU5w==", + "license": "MIT" + }, + "node_modules/jsep": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/jsep/-/jsep-1.4.0.tgz", + "integrity": "sha512-B7qPcEVE3NVkmSJbaYxvv4cHkVW7DQsZz13pUMrfS8z8Q/BuShN+gcTXrUlPiGqM2/t/EEaI030bpxMqY8gMlw==", + "license": "MIT", + "engines": { + "node": ">= 10.16.0" + } + }, + "node_modules/jsonpath-plus": { + "version": "10.1.0", + "resolved": "https://registry.npmjs.org/jsonpath-plus/-/jsonpath-plus-10.1.0.tgz", + "integrity": "sha512-gHfV1IYqH8uJHYVTs8BJX1XKy2/rR93+f8QQi0xhx95aCiXn1ettYAd5T+7FU6wfqyDoX/wy0pm/fL3jOKJ9Lg==", + "license": "MIT", + "dependencies": { + "@jsep-plugin/assignment": "^1.2.1", + "@jsep-plugin/regex": "^1.0.3", + "jsep": "^1.3.9" + }, + "bin": { + "jsonpath": "bin/jsonpath-cli.js", + "jsonpath-plus": "bin/jsonpath-cli.js" + }, + "engines": { + "node": ">=18.0.0" + } + }, + "node_modules/ktx-parse": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/ktx-parse/-/ktx-parse-1.1.0.tgz", + "integrity": "sha512-mKp3y+FaYgR7mXWAbyyzpa/r1zDWeaunH+INJO4fou3hb45XuNSwar+7llrRyvpMWafxSIi99RNFJ05MHedaJQ==", + "license": "MIT" + }, + "node_modules/manifold-3d": { + "version": "3.3.2", + "resolved": "https://registry.npmjs.org/manifold-3d/-/manifold-3d-3.3.2.tgz", + "integrity": "sha512-Xx+S7kkbqlZxSPfBKH5yVKDO6k/eW7JRvnG1dKCFO0D4zjifOV5GM18TR0sREDcbKAzglHZ5OoxxpZRkxg6U5A==", + "license": "Apache-2.0", + "dependencies": { + "@gltf-transform/core": "^4.2.0", + "@gltf-transform/extensions": "^4.2.0", + "@gltf-transform/functions": "^4.2.0", + "@jridgewell/trace-mapping": "^0.3.31", + "@jscadui/3mf-export": "^0.5.0", + "commander": "^13.1.0", + "convert-source-map": "^2.0.0", + "esbuild-plugin-text-replace": "^1.3.0", + "esbuild-wasm": "^0.25.11", + "fflate": "^0.8.0" + }, + "bin": { + "manifold-cad": "bin/manifold-cad" + } + }, + "node_modules/manifold-3d/node_modules/fflate": { + "version": "0.8.2", + "resolved": "https://registry.npmjs.org/fflate/-/fflate-0.8.2.tgz", + "integrity": "sha512-cPJU47OaAoCbg0pBvzsgpTPhmhqI5eJjh/JIu8tPj5q+T7iLvW/JAYUqmE7KOB4R1ZyEhzBaIQpQpardBF5z8A==", + "license": "MIT" + }, + "node_modules/meshoptimizer": { + "version": "0.22.0", + "resolved": "https://registry.npmjs.org/meshoptimizer/-/meshoptimizer-0.22.0.tgz", + "integrity": "sha512-IebiK79sqIy+E4EgOr+CAw+Ke8hAspXKzBd0JdgEmPHiAwmvEj2S4h1rfvo+o/BnfEYd/jAOg5IeeIjzlzSnDg==", + "dev": true + }, + "node_modules/nan": { + "version": "2.24.0", + "resolved": "https://registry.npmjs.org/nan/-/nan-2.24.0.tgz", + "integrity": "sha512-Vpf9qnVW1RaDkoNKFUvfxqAbtI8ncb8OJlqZ9wwpXzWPEsvsB1nvdUi6oYrHIkQ1Y/tMDnr1h4nczS0VB9Xykg==", + "license": "MIT", + "optional": true + }, + "node_modules/nanoid": { + "version": "3.3.11", + "resolved": "https://registry.npmjs.org/nanoid/-/nanoid-3.3.11.tgz", + "integrity": "sha512-N8SpfPUnUp1bK+PMYW8qSWdl9U+wwNWI4QKxOYDy9JAro3WMX7p2OeVRF9v+347pnakNevPmiHhNmZ2HbFA76w==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/ai" + } + ], + "bin": { + "nanoid": "bin/nanoid.cjs" + }, + "engines": { + "node": "^10 || ^12 || ^13.7 || ^14 || >=15.0.1" + } + }, + "node_modules/ndarray": { + "version": "1.0.19", + "resolved": "https://registry.npmjs.org/ndarray/-/ndarray-1.0.19.tgz", + "integrity": "sha512-B4JHA4vdyZU30ELBw3g7/p9bZupyew5a7tX1Y/gGeF2hafrPaQZhgrGQfsvgfYbgdFZjYwuEcnaobeM/WMW+HQ==", + "license": "MIT", + "dependencies": { + "iota-array": "^1.0.0", + "is-buffer": "^1.0.2" + } + }, + "node_modules/ndarray-lanczos": { + "version": "0.3.0", + "resolved": "https://registry.npmjs.org/ndarray-lanczos/-/ndarray-lanczos-0.3.0.tgz", + "integrity": "sha512-5kBmmG3Zvyj77qxIAC4QFLKuYdDIBJwCG+DukT6jQHNa1Ft74/hPH1z5mbQXeHBt8yvGPBGVrr3wEOdJPYYZYg==", + "license": "MIT", + "dependencies": { + "@types/ndarray": "^1.0.11", + "ndarray": "^1.0.19" + } + }, + "node_modules/ndarray-ops": { + "version": "1.2.2", + "resolved": "https://registry.npmjs.org/ndarray-ops/-/ndarray-ops-1.2.2.tgz", + "integrity": "sha512-BppWAFRjMYF7N/r6Ie51q6D4fs0iiGmeXIACKY66fLpnwIui3Wc3CXiD/30mgLbDjPpSLrsqcp3Z62+IcHZsDw==", + "license": "MIT", + "dependencies": { + "cwise-compiler": "^1.0.0" + } + }, + "node_modules/ndarray-pixels": { + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/ndarray-pixels/-/ndarray-pixels-5.0.1.tgz", + "integrity": "sha512-IBtrpefpqlI8SPDCGjXk4v5NV5z7r3JSuCbfuEEXaM0vrOJtNGgYUa4C3Lt5H+qWdYF4BCPVFsnXhNC7QvZwkw==", + "license": "MIT", + "dependencies": { + "@types/ndarray": "^1.0.14", + "ndarray": "^1.0.19", + "ndarray-ops": "^1.2.2", + "sharp": "^0.34.0" + } + }, + "node_modules/onml": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/onml/-/onml-1.2.0.tgz", + "integrity": "sha512-olqYAg18XoHAhm7tK9DdBCOVdts70DGmMgCNLOWyqZokht2utgGSKBB4JHi6pBZpmioAhcYlxK+91L3tsrz+GA==", + "license": "MIT", + "dependencies": { + "sax": "^1.2.1" + } + }, + "node_modules/picocolors": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.1.1.tgz", + "integrity": "sha512-xceH2snhtb5M9liqDsmEw56le376mTZkEX/jEb/RxNFyegNul7eNslCXP9FDj/Lcu0X8KEyMceP2ntpaHrDEVA==", + "dev": true + }, + "node_modules/picomatch": { + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.2.tgz", + "integrity": "sha512-M7BAV6Rlcy5u+m6oPhAPFgJTzAioX/6B0DxyvDlo9l8+T3nLKbrczg2WLUyzd45L8RqfUMyGPzekbMvX2Ldkwg==", + "dev": true, + "engines": { + "node": ">=12" + }, + "funding": { + "url": "https://github.com/sponsors/jonschlinkert" + } + }, + "node_modules/postcss": { + "version": "8.5.3", + "resolved": "https://registry.npmjs.org/postcss/-/postcss-8.5.3.tgz", + "integrity": "sha512-dle9A3yYxlBSrt8Fu+IpjGT8SY8hN0mlaA6GY8t0P5PjIOZemULz/E2Bnm/2dcUOena75OTNkHI76uZBNUUq3A==", + "dev": true, + "funding": [ + { + "type": "opencollective", + "url": "https://opencollective.com/postcss/" + }, + { + "type": "tidelift", + "url": "https://tidelift.com/funding/github/npm/postcss" + }, + { + "type": "github", + "url": "https://github.com/sponsors/ai" + } + ], + "dependencies": { + "nanoid": "^3.3.8", + "picocolors": "^1.1.1", + "source-map-js": "^1.2.1" + }, + "engines": { + "node": "^10 || ^12 || >=14" + } + }, + "node_modules/property-graph": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/property-graph/-/property-graph-4.0.0.tgz", + "integrity": "sha512-I0hojAJfTbSCZy3y6xyK29eayxo14v1bj1VPiDkHjTdz33SV6RdfMz2AHnf4ai62Vng2mN5GkaKahkooBIo9gA==", + "license": "MIT" + }, + "node_modules/rollup": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/rollup/-/rollup-4.40.1.tgz", + "integrity": "sha512-C5VvvgCCyfyotVITIAv+4efVytl5F7wt+/I2i9q9GZcEXW9BP52YYOXC58igUi+LFZVHukErIIqQSWwv/M3WRw==", + "dev": true, + "dependencies": { + "@types/estree": "1.0.7" + }, + "bin": { + "rollup": "dist/bin/rollup" + }, + "engines": { + "node": ">=18.0.0", + "npm": ">=8.0.0" + }, + "optionalDependencies": { + "@rollup/rollup-android-arm-eabi": "4.40.1", + "@rollup/rollup-android-arm64": "4.40.1", + "@rollup/rollup-darwin-arm64": "4.40.1", + "@rollup/rollup-darwin-x64": "4.40.1", + "@rollup/rollup-freebsd-arm64": "4.40.1", + "@rollup/rollup-freebsd-x64": "4.40.1", + "@rollup/rollup-linux-arm-gnueabihf": "4.40.1", + "@rollup/rollup-linux-arm-musleabihf": "4.40.1", + "@rollup/rollup-linux-arm64-gnu": "4.40.1", + "@rollup/rollup-linux-arm64-musl": "4.40.1", + "@rollup/rollup-linux-loongarch64-gnu": "4.40.1", + "@rollup/rollup-linux-powerpc64le-gnu": "4.40.1", + "@rollup/rollup-linux-riscv64-gnu": "4.40.1", + "@rollup/rollup-linux-riscv64-musl": "4.40.1", + "@rollup/rollup-linux-s390x-gnu": "4.40.1", + "@rollup/rollup-linux-x64-gnu": "4.40.1", + "@rollup/rollup-linux-x64-musl": "4.40.1", + "@rollup/rollup-win32-arm64-msvc": "4.40.1", + "@rollup/rollup-win32-ia32-msvc": "4.40.1", + "@rollup/rollup-win32-x64-msvc": "4.40.1", + "fsevents": "~2.3.2" + } + }, + "node_modules/rxjs": { + "version": "7.5.5", + "resolved": "https://registry.npmjs.org/rxjs/-/rxjs-7.5.5.tgz", + "integrity": "sha512-sy+H0pQofO95VDmFLzyaw9xNJU4KTRSwQIGM6+iG3SypAtCiLDzpeG8sJrNCWn2Up9km+KhkvTdbkrdy+yzZdw==", + "license": "Apache-2.0", + "dependencies": { + "tslib": "^2.1.0" + } + }, + "node_modules/sax": { + "version": "1.4.3", + "resolved": "https://registry.npmjs.org/sax/-/sax-1.4.3.tgz", + "integrity": "sha512-yqYn1JhPczigF94DMS+shiDMjDowYO6y9+wB/4WgO0Y19jWYk0lQ4tuG5KI7kj4FTp1wxPj5IFfcrz/s1c3jjQ==", + "license": "BlueOak-1.0.0" + }, + "node_modules/semver": { + "version": "7.7.3", + "resolved": "https://registry.npmjs.org/semver/-/semver-7.7.3.tgz", + "integrity": "sha512-SdsKMrI9TdgjdweUSR9MweHA4EJ8YxHn8DFaDisvhVlUOe4BF1tLD7GAj0lIqWVl+dPb/rExr0Btby5loQm20Q==", + "license": "ISC", + "bin": { + "semver": "bin/semver.js" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/sharp": { + "version": "0.34.5", + "resolved": "https://registry.npmjs.org/sharp/-/sharp-0.34.5.tgz", + "integrity": "sha512-Ou9I5Ft9WNcCbXrU9cMgPBcCK8LiwLqcbywW3t4oDV37n1pzpuNLsYiAV8eODnjbtQlSDwZ2cUEeQz4E54Hltg==", + "hasInstallScript": true, + "license": "Apache-2.0", + "dependencies": { + "@img/colour": "^1.0.0", + "detect-libc": "^2.1.2", + "semver": "^7.7.3" + }, + "engines": { + "node": "^18.17.0 || ^20.3.0 || >=21.0.0" + }, + "funding": { + "url": "https://opencollective.com/libvips" + }, + "optionalDependencies": { + "@img/sharp-darwin-arm64": "0.34.5", + "@img/sharp-darwin-x64": "0.34.5", + "@img/sharp-libvips-darwin-arm64": "1.2.4", + "@img/sharp-libvips-darwin-x64": "1.2.4", + "@img/sharp-libvips-linux-arm": "1.2.4", + "@img/sharp-libvips-linux-arm64": "1.2.4", + "@img/sharp-libvips-linux-ppc64": "1.2.4", + "@img/sharp-libvips-linux-riscv64": "1.2.4", + "@img/sharp-libvips-linux-s390x": "1.2.4", + "@img/sharp-libvips-linux-x64": "1.2.4", + "@img/sharp-libvips-linuxmusl-arm64": "1.2.4", + "@img/sharp-libvips-linuxmusl-x64": "1.2.4", + "@img/sharp-linux-arm": "0.34.5", + "@img/sharp-linux-arm64": "0.34.5", + "@img/sharp-linux-ppc64": "0.34.5", + "@img/sharp-linux-riscv64": "0.34.5", + "@img/sharp-linux-s390x": "0.34.5", + "@img/sharp-linux-x64": "0.34.5", + "@img/sharp-linuxmusl-arm64": "0.34.5", + "@img/sharp-linuxmusl-x64": "0.34.5", + "@img/sharp-wasm32": "0.34.5", + "@img/sharp-win32-arm64": "0.34.5", + "@img/sharp-win32-ia32": "0.34.5", + "@img/sharp-win32-x64": "0.34.5" + } + }, + "node_modules/source-map-js": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/source-map-js/-/source-map-js-1.2.1.tgz", + "integrity": "sha512-UXWMKhLOwVKb728IUtQPXxfYU+usdybtUrK/8uGE8CQMvrhOpwvzDBwj0QhSL7MQc7vIsISBG8VQ8+IDQxpfQA==", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/tinyglobby": { + "version": "0.2.13", + "resolved": "https://registry.npmjs.org/tinyglobby/-/tinyglobby-0.2.13.tgz", + "integrity": "sha512-mEwzpUgrLySlveBwEVDMKk5B57bhLPYovRfPAXD5gA/98Opn0rCDj3GtLwFvCvH5RK9uPCExUROW5NjDwvqkxw==", + "dev": true, + "dependencies": { + "fdir": "^6.4.4", + "picomatch": "^4.0.2" + }, + "engines": { + "node": ">=12.0.0" + }, + "funding": { + "url": "https://github.com/sponsors/SuperchupuDev" + } + }, + "node_modules/ts-replace-all": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/ts-replace-all/-/ts-replace-all-1.0.0.tgz", + "integrity": "sha512-6uBtdkw3jHXkPtx/e9xB/5vcngMm17CyJYsS2YZeQ+9FdRnt6Ev5g931Sg2p+dxbtMGoCm13m3ax/obicTZIkQ==", + "license": "MIT", + "dependencies": { + "core-js": "^3.4.1" + } + }, + "node_modules/tslib": { + "version": "2.8.1", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.8.1.tgz", + "integrity": "sha512-oJFu94HQb+KVduSUQL7wnpmqnfmLsOA/nAh6b6EH0wCEoK0/mPeXU6c3wKDV83MkOuHPRHtSXKKU99IBazS/2w==", + "license": "0BSD" + }, + "node_modules/typescript": { + "version": "5.8.3", + "resolved": "https://registry.npmjs.org/typescript/-/typescript-5.8.3.tgz", + "integrity": "sha512-p1diW6TqL9L07nNxvRMM7hMMw4c5XOo/1ibL4aAIGmSAt9slTE1Xgw5KWuof2uTOvCg9BY7ZRi+GaF+7sfgPeQ==", + "dev": true, + "bin": { + "tsc": "bin/tsc", + "tsserver": "bin/tsserver" + }, + "engines": { + "node": ">=14.17" + } + }, + "node_modules/uniq": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/uniq/-/uniq-1.0.1.tgz", + "integrity": "sha512-Gw+zz50YNKPDKXs+9d+aKAjVwpjNwqzvNpLigIruT4HA9lMZNdMqs9x07kKHB/L9WRzqp4+DlTU5s4wG2esdoA==", + "license": "MIT" + }, + "node_modules/verb-nurbs-web": { + "version": "2.1.3", + "resolved": "https://registry.npmjs.org/verb-nurbs-web/-/verb-nurbs-web-2.1.3.tgz", + "integrity": "sha512-2PvI2bx7dn0r3kWtk+JuDIDZ+p7I5Piu8y6/ZNhUVpilOyHKK1nNzLHtgown+dFOmBnKnuAKIMh1xn/5kzrxZA==", + "license": "MIT", + "optionalDependencies": { + "webworker-threads": "^0.7.12" + } + }, + "node_modules/vite": { + "version": "6.3.4", + "resolved": "https://registry.npmjs.org/vite/-/vite-6.3.4.tgz", + "integrity": "sha512-BiReIiMS2fyFqbqNT/Qqt4CVITDU9M9vE+DKcVAsB+ZV0wvTKd+3hMbkpxz1b+NmEDMegpVbisKiAZOnvO92Sw==", + "dev": true, + "dependencies": { + "esbuild": "^0.25.0", + "fdir": "^6.4.4", + "picomatch": "^4.0.2", + "postcss": "^8.5.3", + "rollup": "^4.34.9", + "tinyglobby": "^0.2.13" + }, + "bin": { + "vite": "bin/vite.js" + }, + "engines": { + "node": "^18.0.0 || ^20.0.0 || >=22.0.0" + }, + "funding": { + "url": "https://github.com/vitejs/vite?sponsor=1" + }, + "optionalDependencies": { + "fsevents": "~2.3.3" + }, + "peerDependencies": { + "@types/node": "^18.0.0 || ^20.0.0 || >=22.0.0", + "jiti": ">=1.21.0", + "less": "*", + "lightningcss": "^1.21.0", + "sass": "*", + "sass-embedded": "*", + "stylus": "*", + "sugarss": "*", + "terser": "^5.16.0", + "tsx": "^4.8.1", + "yaml": "^2.4.2" + }, + "peerDependenciesMeta": { + "@types/node": { + "optional": true + }, + "jiti": { + "optional": true + }, + "less": { + "optional": true + }, + "lightningcss": { + "optional": true + }, + "sass": { + "optional": true + }, + "sass-embedded": { + "optional": true + }, + "stylus": { + "optional": true + }, + "sugarss": { + "optional": true + }, + "terser": { + "optional": true + }, + "tsx": { + "optional": true + }, + "yaml": { + "optional": true + } + } + }, + "node_modules/webworker-threads": { + "version": "0.7.17", + "resolved": "https://registry.npmjs.org/webworker-threads/-/webworker-threads-0.7.17.tgz", + "integrity": "sha512-Y2w2aXBbDLk9IzTEb9u+MsODC3s4YlGI7g4h0t+1OAwIO8yBI9rQL35ZYlyayiCuWu1dZMH/P7kGU8OwW7YsyA==", + "hasInstallScript": true, + "license": "(MIT AND Apache-2.0)", + "optional": true, + "dependencies": { + "bindings": "^1.3.0", + "nan": "^2.11.0" + }, + "engines": { + "node": ">= 0.10.16" + } + } + }, + "dependencies": { + "@babylonjs/core": { + "version": "8.44.1", + "resolved": "https://registry.npmjs.org/@babylonjs/core/-/core-8.44.1.tgz", + "integrity": "sha512-sF2WWK2d7lg18ESOCxUoRG4d1SzCWz42asjRjRGxZ8r3D7w9ZM3H2wftJIqwaZvD3zWr+wmCVKpQ6hWkboHIXw==" + }, + "@babylonjs/gui": { + "version": "8.44.1", + "resolved": "https://registry.npmjs.org/@babylonjs/gui/-/gui-8.44.1.tgz", + "integrity": "sha512-6STDK+Hr8GpY29YMLKnTVhEnWw1NKPrIpz+MqgWuoAAmmpiFtNCr0nnAnCj5fhgGf25L89jy51ogXyg3jfiuDA==", + "requires": {} + }, + "@babylonjs/havok": { + "version": "1.3.10", + "resolved": "https://registry.npmjs.org/@babylonjs/havok/-/havok-1.3.10.tgz", + "integrity": "sha512-ddF0LPBVmg+rmPaMmwTPA9FcHyUnrSsQqFoBbYbN51WMhEJQ+7gRFW3J5lML6lN9M/fbknh6bh1ZirZ2bU2B/w==", + "requires": { + "@types/emscripten": "^1.39.6" + } + }, + "@babylonjs/loaders": { + "version": "8.44.1", + "resolved": "https://registry.npmjs.org/@babylonjs/loaders/-/loaders-8.44.1.tgz", + "integrity": "sha512-h5rUGCwhdWv3Hq48DP8sy4/+3QUYjOprxu2i6zXKb69LHMnYE0tZ1xQHBJEOUF60hxA+TwhzdjC8bxInKoeojA==", + "requires": {} + }, + "@babylonjs/materials": { + "version": "8.44.1", + "resolved": "https://registry.npmjs.org/@babylonjs/materials/-/materials-8.44.1.tgz", + "integrity": "sha512-FD0S/aA68oEjKCSNY5ydGkiHbsyo08KlhQ+6R8swtJhx5aq7ojWBt3P9KC78+wjZiCJW37176CIObcV8QcjMAQ==", + "requires": {} + }, + "@babylonjs/serializers": { + "version": "8.44.1", + "resolved": "https://registry.npmjs.org/@babylonjs/serializers/-/serializers-8.44.1.tgz", + "integrity": "sha512-3FRRdKpHr2qTkALHEvq0ih0P59iTINUFrGZWFUfO3Wu24UBSuTxY9Kq820dvUUWaRtWkXEnMSQbR+5glzcfqBw==", + "requires": {} + }, + "@bitbybit-dev/babylonjs": { + "version": "0.21.0", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/babylonjs/-/babylonjs-0.21.0.tgz", + "integrity": "sha512-8aPJ+XTXzcnO4bXfmW34lTnVCzC6Hy6TMkh7/ziQSoUsjPp7e7LFHoBBfqCk09LdTLa85gb5x/f6WNAn306Odg==", + "requires": { + "@babylonjs/core": "8.44.1", + "@babylonjs/gui": "8.44.1", + "@babylonjs/havok": "1.3.10", + "@babylonjs/loaders": "8.44.1", + "@babylonjs/materials": "8.44.1", + "@babylonjs/serializers": "8.44.1", + "@bitbybit-dev/core": "0.21.0", + "earcut": "2.2.3" + } + }, + "@bitbybit-dev/base": { + "version": "0.21.0", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/base/-/base-0.21.0.tgz", + "integrity": "sha512-dNfsf2tu3/QUD1mvZzzTze8RwHyK2Jrt+Ary8EDKdNKMw+abtCpQYNerdrg0ZQPxvwu/OOQz6N1xCsCwsPkQJg==" + }, + "@bitbybit-dev/core": { + "version": "0.21.0", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/core/-/core-0.21.0.tgz", + "integrity": "sha512-IbeQ8ROreu0/RkkngUE+Eb19ecvqKOWhGefXvIqQmplxt3zEc0FI4Kw8wR3vYl2XMannuVt1xAIYtqqH0tjBzg==", + "requires": { + "@bitbybit-dev/base": "0.21.0", + "@bitbybit-dev/jscad-worker": "0.21.0", + "@bitbybit-dev/manifold-worker": "0.21.0", + "@bitbybit-dev/occt-worker": "0.21.0", + "jsonpath-plus": "10.1.0", + "rxjs": "7.5.5", + "verb-nurbs-web": "2.1.3" + } + }, + "@bitbybit-dev/jscad": { + "version": "0.21.0", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/jscad/-/jscad-0.21.0.tgz", + "integrity": "sha512-Q7eE2ILrJRstW4L1711aJZdpwPf1kuhZJqB+KLkkBLsneRsGsh82lBcCbVYAOMuF/q8Lnd4JHxPiIG/m+LYmPQ==", + "requires": { + "@bitbybit-dev/base": "0.21.0", + "@jscad/3mf-serializer": "2.1.12", + "@jscad/dxf-serializer": "2.1.18", + "@jscad/io-utils": "2.0.28", + "@jscad/modeling": "2.12.3", + "@jscad/stl-serializer": "2.1.18" + } + }, + "@bitbybit-dev/jscad-worker": { + "version": "0.21.0", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/jscad-worker/-/jscad-worker-0.21.0.tgz", + "integrity": "sha512-nIvd7GH5Gg51u6PmFXOADXVYTIvixTkNf0YapS1uix7D2JS9Mx10Z4wHAeRKzvJxUAAbEPPRFNkakE22HFGtLQ==", + "requires": { + "@bitbybit-dev/jscad": "0.21.0", + "rxjs": "7.5.5" + } + }, + "@bitbybit-dev/manifold": { + "version": "0.21.0", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/manifold/-/manifold-0.21.0.tgz", + "integrity": "sha512-DPpwK9ESB+auDeAbzXcfWRVEzWoMDkpkjc+/uwh+zuSiHSx92PSkzx1/LVTbQCsK+aOfOOy03HQCF5Bu2KQYtw==", + "requires": { + "@bitbybit-dev/base": "0.21.0", + "manifold-3d": "3.3.2" + } + }, + "@bitbybit-dev/manifold-worker": { + "version": "0.21.0", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/manifold-worker/-/manifold-worker-0.21.0.tgz", + "integrity": "sha512-6Cqv3BP+uI8mHKHI6Jx9TzCxRg1/kMHhCe18+B3KD/rTl9B5mnScCKRBnDansR3bH7aYZGnIw9PmiFnWLkQWEQ==", + "requires": { + "@bitbybit-dev/manifold": "0.21.0", + "rxjs": "7.5.5" + } + }, + "@bitbybit-dev/occt": { + "version": "0.21.0", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/occt/-/occt-0.21.0.tgz", + "integrity": "sha512-vPu3NmF1kBZMOkOdysolGfFxEEnwdHNGORoX3eWbMWT2JL/Tag5Q2CAc5jwa2VvZnS1nE/9x+DVlFQSo8LQnIg==", + "requires": { + "@bitbybit-dev/base": "0.21.0" + } + }, + "@bitbybit-dev/occt-worker": { + "version": "0.21.0", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/occt-worker/-/occt-worker-0.21.0.tgz", + "integrity": "sha512-xG1sgo6q/RdVA8AgG72wPe4qxcQlrO1V7/Ksn6MqIhZVTsJcm5RbVYlK+nziIWhvlMc1sKE0GNQFcPdALISLuQ==", + "requires": { + "@bitbybit-dev/occt": "0.21.0", + "rxjs": "7.5.5" + } + }, + "@dimforge/rapier3d-compat": { + "version": "0.12.0", + "resolved": "https://registry.npmjs.org/@dimforge/rapier3d-compat/-/rapier3d-compat-0.12.0.tgz", + "integrity": "sha512-uekIGetywIgopfD97oDL5PfeezkFpNhwlzlaEYNOA0N6ghdsOvh/HYjSMek5Q2O1PYvRSDFcqFVJl4r4ZBwOow==", + "dev": true + }, + "@emnapi/runtime": { + "version": "1.8.1", + "resolved": "https://registry.npmjs.org/@emnapi/runtime/-/runtime-1.8.1.tgz", + "integrity": "sha512-mehfKSMWjjNol8659Z8KxEMrdSJDDot5SXMq00dM8BN4o+CLNXQ0xH2V7EchNHV4RmbZLmmPdEaXZc5H2FXmDg==", + "optional": true, + "requires": { + "tslib": "^2.4.0" + } + }, + "@esbuild/aix-ppc64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/aix-ppc64/-/aix-ppc64-0.25.3.tgz", + "integrity": "sha512-W8bFfPA8DowP8l//sxjJLSLkD8iEjMc7cBVyP+u4cEv9sM7mdUCkgsj+t0n/BWPFtv7WWCN5Yzj0N6FJNUUqBQ==", + "dev": true, + "optional": true + }, + "@esbuild/android-arm": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/android-arm/-/android-arm-0.25.3.tgz", + "integrity": "sha512-PuwVXbnP87Tcff5I9ngV0lmiSu40xw1At6i3GsU77U7cjDDB4s0X2cyFuBiDa1SBk9DnvWwnGvVaGBqoFWPb7A==", + "dev": true, + "optional": true + }, + "@esbuild/android-arm64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/android-arm64/-/android-arm64-0.25.3.tgz", + "integrity": "sha512-XelR6MzjlZuBM4f5z2IQHK6LkK34Cvv6Rj2EntER3lwCBFdg6h2lKbtRjpTTsdEjD/WSe1q8UyPBXP1x3i/wYQ==", + "dev": true, + "optional": true + }, + "@esbuild/android-x64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/android-x64/-/android-x64-0.25.3.tgz", + "integrity": "sha512-ogtTpYHT/g1GWS/zKM0cc/tIebFjm1F9Aw1boQ2Y0eUQ+J89d0jFY//s9ei9jVIlkYi8AfOjiixcLJSGNSOAdQ==", + "dev": true, + "optional": true + }, + "@esbuild/darwin-arm64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/darwin-arm64/-/darwin-arm64-0.25.3.tgz", + "integrity": "sha512-eESK5yfPNTqpAmDfFWNsOhmIOaQA59tAcF/EfYvo5/QWQCzXn5iUSOnqt3ra3UdzBv073ykTtmeLJZGt3HhA+w==", + "dev": true, + "optional": true + }, + "@esbuild/darwin-x64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/darwin-x64/-/darwin-x64-0.25.3.tgz", + "integrity": "sha512-Kd8glo7sIZtwOLcPbW0yLpKmBNWMANZhrC1r6K++uDR2zyzb6AeOYtI6udbtabmQpFaxJ8uduXMAo1gs5ozz8A==", + "dev": true, + "optional": true + }, + "@esbuild/freebsd-arm64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/freebsd-arm64/-/freebsd-arm64-0.25.3.tgz", + "integrity": "sha512-EJiyS70BYybOBpJth3M0KLOus0n+RRMKTYzhYhFeMwp7e/RaajXvP+BWlmEXNk6uk+KAu46j/kaQzr6au+JcIw==", + "dev": true, + "optional": true + }, + "@esbuild/freebsd-x64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/freebsd-x64/-/freebsd-x64-0.25.3.tgz", + "integrity": "sha512-Q+wSjaLpGxYf7zC0kL0nDlhsfuFkoN+EXrx2KSB33RhinWzejOd6AvgmP5JbkgXKmjhmpfgKZq24pneodYqE8Q==", + "dev": true, + "optional": true + }, + "@esbuild/linux-arm": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/linux-arm/-/linux-arm-0.25.3.tgz", + "integrity": "sha512-dUOVmAUzuHy2ZOKIHIKHCm58HKzFqd+puLaS424h6I85GlSDRZIA5ycBixb3mFgM0Jdh+ZOSB6KptX30DD8YOQ==", + "dev": true, + "optional": true + }, + "@esbuild/linux-arm64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/linux-arm64/-/linux-arm64-0.25.3.tgz", + "integrity": "sha512-xCUgnNYhRD5bb1C1nqrDV1PfkwgbswTTBRbAd8aH5PhYzikdf/ddtsYyMXFfGSsb/6t6QaPSzxtbfAZr9uox4A==", + "dev": true, + "optional": true + }, + "@esbuild/linux-ia32": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/linux-ia32/-/linux-ia32-0.25.3.tgz", + "integrity": "sha512-yplPOpczHOO4jTYKmuYuANI3WhvIPSVANGcNUeMlxH4twz/TeXuzEP41tGKNGWJjuMhotpGabeFYGAOU2ummBw==", + "dev": true, + "optional": true + }, + "@esbuild/linux-loong64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/linux-loong64/-/linux-loong64-0.25.3.tgz", + "integrity": "sha512-P4BLP5/fjyihmXCELRGrLd793q/lBtKMQl8ARGpDxgzgIKJDRJ/u4r1A/HgpBpKpKZelGct2PGI4T+axcedf6g==", + "dev": true, + "optional": true + }, + "@esbuild/linux-mips64el": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/linux-mips64el/-/linux-mips64el-0.25.3.tgz", + "integrity": "sha512-eRAOV2ODpu6P5divMEMa26RRqb2yUoYsuQQOuFUexUoQndm4MdpXXDBbUoKIc0iPa4aCO7gIhtnYomkn2x+bag==", + "dev": true, + "optional": true + }, + "@esbuild/linux-ppc64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/linux-ppc64/-/linux-ppc64-0.25.3.tgz", + "integrity": "sha512-ZC4jV2p7VbzTlnl8nZKLcBkfzIf4Yad1SJM4ZMKYnJqZFD4rTI+pBG65u8ev4jk3/MPwY9DvGn50wi3uhdaghg==", + "dev": true, + "optional": true + }, + "@esbuild/linux-riscv64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/linux-riscv64/-/linux-riscv64-0.25.3.tgz", + "integrity": "sha512-LDDODcFzNtECTrUUbVCs6j9/bDVqy7DDRsuIXJg6so+mFksgwG7ZVnTruYi5V+z3eE5y+BJZw7VvUadkbfg7QA==", + "dev": true, + "optional": true + }, + "@esbuild/linux-s390x": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/linux-s390x/-/linux-s390x-0.25.3.tgz", + "integrity": "sha512-s+w/NOY2k0yC2p9SLen+ymflgcpRkvwwa02fqmAwhBRI3SC12uiS10edHHXlVWwfAagYSY5UpmT/zISXPMW3tQ==", + "dev": true, + "optional": true + }, + "@esbuild/linux-x64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/linux-x64/-/linux-x64-0.25.3.tgz", + "integrity": "sha512-nQHDz4pXjSDC6UfOE1Fw9Q8d6GCAd9KdvMZpfVGWSJztYCarRgSDfOVBY5xwhQXseiyxapkiSJi/5/ja8mRFFA==", + "dev": true, + "optional": true + }, + "@esbuild/netbsd-arm64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/netbsd-arm64/-/netbsd-arm64-0.25.3.tgz", + "integrity": "sha512-1QaLtOWq0mzK6tzzp0jRN3eccmN3hezey7mhLnzC6oNlJoUJz4nym5ZD7mDnS/LZQgkrhEbEiTn515lPeLpgWA==", + "dev": true, + "optional": true + }, + "@esbuild/netbsd-x64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/netbsd-x64/-/netbsd-x64-0.25.3.tgz", + "integrity": "sha512-i5Hm68HXHdgv8wkrt+10Bc50zM0/eonPb/a/OFVfB6Qvpiirco5gBA5bz7S2SHuU+Y4LWn/zehzNX14Sp4r27g==", + "dev": true, + "optional": true + }, + "@esbuild/openbsd-arm64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/openbsd-arm64/-/openbsd-arm64-0.25.3.tgz", + "integrity": "sha512-zGAVApJEYTbOC6H/3QBr2mq3upG/LBEXr85/pTtKiv2IXcgKV0RT0QA/hSXZqSvLEpXeIxah7LczB4lkiYhTAQ==", + "dev": true, + "optional": true + }, + "@esbuild/openbsd-x64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/openbsd-x64/-/openbsd-x64-0.25.3.tgz", + "integrity": "sha512-fpqctI45NnCIDKBH5AXQBsD0NDPbEFczK98hk/aa6HJxbl+UtLkJV2+Bvy5hLSLk3LHmqt0NTkKNso1A9y1a4w==", + "dev": true, + "optional": true + }, + "@esbuild/sunos-x64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/sunos-x64/-/sunos-x64-0.25.3.tgz", + "integrity": "sha512-ROJhm7d8bk9dMCUZjkS8fgzsPAZEjtRJqCAmVgB0gMrvG7hfmPmz9k1rwO4jSiblFjYmNvbECL9uhaPzONMfgA==", + "dev": true, + "optional": true + }, + "@esbuild/win32-arm64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/win32-arm64/-/win32-arm64-0.25.3.tgz", + "integrity": "sha512-YWcow8peiHpNBiIXHwaswPnAXLsLVygFwCB3A7Bh5jRkIBFWHGmNQ48AlX4xDvQNoMZlPYzjVOQDYEzWCqufMQ==", + "dev": true, + "optional": true + }, + "@esbuild/win32-ia32": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/win32-ia32/-/win32-ia32-0.25.3.tgz", + "integrity": "sha512-qspTZOIGoXVS4DpNqUYUs9UxVb04khS1Degaw/MnfMe7goQ3lTfQ13Vw4qY/Nj0979BGvMRpAYbs/BAxEvU8ew==", + "dev": true, + "optional": true + }, + "@esbuild/win32-x64": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/@esbuild/win32-x64/-/win32-x64-0.25.3.tgz", + "integrity": "sha512-ICgUR+kPimx0vvRzf+N/7L7tVSQeE3BYY+NhHRHXS1kBuPO7z2+7ea2HbhDyZdTephgvNvKrlDDKUexuCVBVvg==", + "dev": true, + "optional": true + }, + "@gltf-transform/core": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/@gltf-transform/core/-/core-4.3.0.tgz", + "integrity": "sha512-ZeaQfszGJ9LYwELszu45CuDQCsE26lJNNe36FVmN8xclaT6WDdCj7fwGpQXo0/l/YgAVAHX+uO7YNBW75/SRYw==", + "requires": { + "property-graph": "^4.0.0" + } + }, + "@gltf-transform/extensions": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/@gltf-transform/extensions/-/extensions-4.3.0.tgz", + "integrity": "sha512-XDAjQPYVMHa/VDpSbfCBwI+/1muwRJCaXhUpLgnUzAjn0D//PgvIAcbNm1EwBl3LIWBSwjDUCn2LiMAjp+aXVw==", + "requires": { + "@gltf-transform/core": "^4.3.0", + "ktx-parse": "^1.0.1" + } + }, + "@gltf-transform/functions": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/@gltf-transform/functions/-/functions-4.3.0.tgz", + "integrity": "sha512-FZggHVgt3DHOezgESBrf2vDzuD2FYQYaNT2sT/aP316SIwhuiIwby3z7rhV9joDvWqqUaPkf1UmkjlOaY9riSQ==", + "requires": { + "@gltf-transform/core": "^4.3.0", + "@gltf-transform/extensions": "^4.3.0", + "ktx-parse": "^1.0.1", + "ndarray": "^1.0.19", + "ndarray-lanczos": "^0.3.0", + "ndarray-pixels": "^5.0.1" + } + }, + "@img/colour": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/@img/colour/-/colour-1.0.0.tgz", + "integrity": "sha512-A5P/LfWGFSl6nsckYtjw9da+19jB8hkJ6ACTGcDfEJ0aE+l2n2El7dsVM7UVHZQ9s2lmYMWlrS21YLy2IR1LUw==" + }, + "@img/sharp-darwin-arm64": { + "version": "0.34.5", + "resolved": "https://registry.npmjs.org/@img/sharp-darwin-arm64/-/sharp-darwin-arm64-0.34.5.tgz", + "integrity": "sha512-imtQ3WMJXbMY4fxb/Ndp6HBTNVtWCUI0WdobyheGf5+ad6xX8VIDO8u2xE4qc/fr08CKG/7dDseFtn6M6g/r3w==", + "optional": true, + "requires": { + "@img/sharp-libvips-darwin-arm64": "1.2.4" + } + }, + "@img/sharp-darwin-x64": { + "version": "0.34.5", + "resolved": "https://registry.npmjs.org/@img/sharp-darwin-x64/-/sharp-darwin-x64-0.34.5.tgz", + "integrity": "sha512-YNEFAF/4KQ/PeW0N+r+aVVsoIY0/qxxikF2SWdp+NRkmMB7y9LBZAVqQ4yhGCm/H3H270OSykqmQMKLBhBJDEw==", + "optional": true, + "requires": { + "@img/sharp-libvips-darwin-x64": "1.2.4" + } + }, + "@img/sharp-libvips-darwin-arm64": { + "version": "1.2.4", + "resolved": "https://registry.npmjs.org/@img/sharp-libvips-darwin-arm64/-/sharp-libvips-darwin-arm64-1.2.4.tgz", + "integrity": "sha512-zqjjo7RatFfFoP0MkQ51jfuFZBnVE2pRiaydKJ1G/rHZvnsrHAOcQALIi9sA5co5xenQdTugCvtb1cuf78Vf4g==", + "optional": true + }, + "@img/sharp-libvips-darwin-x64": { + "version": "1.2.4", + "resolved": "https://registry.npmjs.org/@img/sharp-libvips-darwin-x64/-/sharp-libvips-darwin-x64-1.2.4.tgz", + "integrity": "sha512-1IOd5xfVhlGwX+zXv2N93k0yMONvUlANylbJw1eTah8K/Jtpi15KC+WSiaX/nBmbm2HxRM1gZ0nSdjSsrZbGKg==", + "optional": true + }, + "@img/sharp-libvips-linux-arm": { + "version": "1.2.4", + "resolved": "https://registry.npmjs.org/@img/sharp-libvips-linux-arm/-/sharp-libvips-linux-arm-1.2.4.tgz", + "integrity": "sha512-bFI7xcKFELdiNCVov8e44Ia4u2byA+l3XtsAj+Q8tfCwO6BQ8iDojYdvoPMqsKDkuoOo+X6HZA0s0q11ANMQ8A==", + "optional": true + }, + "@img/sharp-libvips-linux-arm64": { + "version": "1.2.4", + "resolved": "https://registry.npmjs.org/@img/sharp-libvips-linux-arm64/-/sharp-libvips-linux-arm64-1.2.4.tgz", + "integrity": "sha512-excjX8DfsIcJ10x1Kzr4RcWe1edC9PquDRRPx3YVCvQv+U5p7Yin2s32ftzikXojb1PIFc/9Mt28/y+iRklkrw==", + "optional": true + }, + "@img/sharp-libvips-linux-ppc64": { + "version": "1.2.4", + "resolved": "https://registry.npmjs.org/@img/sharp-libvips-linux-ppc64/-/sharp-libvips-linux-ppc64-1.2.4.tgz", + "integrity": "sha512-FMuvGijLDYG6lW+b/UvyilUWu5Ayu+3r2d1S8notiGCIyYU/76eig1UfMmkZ7vwgOrzKzlQbFSuQfgm7GYUPpA==", + "optional": true + }, + "@img/sharp-libvips-linux-riscv64": { + "version": "1.2.4", + "resolved": "https://registry.npmjs.org/@img/sharp-libvips-linux-riscv64/-/sharp-libvips-linux-riscv64-1.2.4.tgz", + "integrity": "sha512-oVDbcR4zUC0ce82teubSm+x6ETixtKZBh/qbREIOcI3cULzDyb18Sr/Wcyx7NRQeQzOiHTNbZFF1UwPS2scyGA==", + "optional": true + }, + "@img/sharp-libvips-linux-s390x": { + "version": "1.2.4", + "resolved": "https://registry.npmjs.org/@img/sharp-libvips-linux-s390x/-/sharp-libvips-linux-s390x-1.2.4.tgz", + "integrity": "sha512-qmp9VrzgPgMoGZyPvrQHqk02uyjA0/QrTO26Tqk6l4ZV0MPWIW6LTkqOIov+J1yEu7MbFQaDpwdwJKhbJvuRxQ==", + "optional": true + }, + "@img/sharp-libvips-linux-x64": { + "version": "1.2.4", + "resolved": "https://registry.npmjs.org/@img/sharp-libvips-linux-x64/-/sharp-libvips-linux-x64-1.2.4.tgz", + "integrity": "sha512-tJxiiLsmHc9Ax1bz3oaOYBURTXGIRDODBqhveVHonrHJ9/+k89qbLl0bcJns+e4t4rvaNBxaEZsFtSfAdquPrw==", + "optional": true + }, + "@img/sharp-libvips-linuxmusl-arm64": { + "version": "1.2.4", + "resolved": "https://registry.npmjs.org/@img/sharp-libvips-linuxmusl-arm64/-/sharp-libvips-linuxmusl-arm64-1.2.4.tgz", + "integrity": "sha512-FVQHuwx1IIuNow9QAbYUzJ+En8KcVm9Lk5+uGUQJHaZmMECZmOlix9HnH7n1TRkXMS0pGxIJokIVB9SuqZGGXw==", + "optional": true + }, + "@img/sharp-libvips-linuxmusl-x64": { + "version": "1.2.4", + "resolved": "https://registry.npmjs.org/@img/sharp-libvips-linuxmusl-x64/-/sharp-libvips-linuxmusl-x64-1.2.4.tgz", + "integrity": "sha512-+LpyBk7L44ZIXwz/VYfglaX/okxezESc6UxDSoyo2Ks6Jxc4Y7sGjpgU9s4PMgqgjj1gZCylTieNamqA1MF7Dg==", + "optional": true + }, + "@img/sharp-linux-arm": { + "version": "0.34.5", + "resolved": "https://registry.npmjs.org/@img/sharp-linux-arm/-/sharp-linux-arm-0.34.5.tgz", + "integrity": "sha512-9dLqsvwtg1uuXBGZKsxem9595+ujv0sJ6Vi8wcTANSFpwV/GONat5eCkzQo/1O6zRIkh0m/8+5BjrRr7jDUSZw==", + "optional": true, + "requires": { + "@img/sharp-libvips-linux-arm": "1.2.4" + } + }, + "@img/sharp-linux-arm64": { + "version": "0.34.5", + "resolved": "https://registry.npmjs.org/@img/sharp-linux-arm64/-/sharp-linux-arm64-0.34.5.tgz", + "integrity": "sha512-bKQzaJRY/bkPOXyKx5EVup7qkaojECG6NLYswgktOZjaXecSAeCWiZwwiFf3/Y+O1HrauiE3FVsGxFg8c24rZg==", + "optional": true, + "requires": { + "@img/sharp-libvips-linux-arm64": "1.2.4" + } + }, + "@img/sharp-linux-ppc64": { + "version": "0.34.5", + "resolved": "https://registry.npmjs.org/@img/sharp-linux-ppc64/-/sharp-linux-ppc64-0.34.5.tgz", + "integrity": "sha512-7zznwNaqW6YtsfrGGDA6BRkISKAAE1Jo0QdpNYXNMHu2+0dTrPflTLNkpc8l7MUP5M16ZJcUvysVWWrMefZquA==", + "optional": true, + "requires": { + "@img/sharp-libvips-linux-ppc64": "1.2.4" + } + }, + "@img/sharp-linux-riscv64": { + "version": "0.34.5", + "resolved": "https://registry.npmjs.org/@img/sharp-linux-riscv64/-/sharp-linux-riscv64-0.34.5.tgz", + "integrity": "sha512-51gJuLPTKa7piYPaVs8GmByo7/U7/7TZOq+cnXJIHZKavIRHAP77e3N2HEl3dgiqdD/w0yUfiJnII77PuDDFdw==", + "optional": true, + "requires": { + "@img/sharp-libvips-linux-riscv64": "1.2.4" + } + }, + "@img/sharp-linux-s390x": { + "version": "0.34.5", + "resolved": "https://registry.npmjs.org/@img/sharp-linux-s390x/-/sharp-linux-s390x-0.34.5.tgz", + "integrity": "sha512-nQtCk0PdKfho3eC5MrbQoigJ2gd1CgddUMkabUj+rBevs8tZ2cULOx46E7oyX+04WGfABgIwmMC0VqieTiR4jg==", + "optional": true, + "requires": { + "@img/sharp-libvips-linux-s390x": "1.2.4" + } + }, + "@img/sharp-linux-x64": { + "version": "0.34.5", + "resolved": "https://registry.npmjs.org/@img/sharp-linux-x64/-/sharp-linux-x64-0.34.5.tgz", + "integrity": "sha512-MEzd8HPKxVxVenwAa+JRPwEC7QFjoPWuS5NZnBt6B3pu7EG2Ge0id1oLHZpPJdn3OQK+BQDiw9zStiHBTJQQQQ==", + "optional": true, + "requires": { + "@img/sharp-libvips-linux-x64": "1.2.4" + } + }, + "@img/sharp-linuxmusl-arm64": { + "version": "0.34.5", + "resolved": "https://registry.npmjs.org/@img/sharp-linuxmusl-arm64/-/sharp-linuxmusl-arm64-0.34.5.tgz", + "integrity": "sha512-fprJR6GtRsMt6Kyfq44IsChVZeGN97gTD331weR1ex1c1rypDEABN6Tm2xa1wE6lYb5DdEnk03NZPqA7Id21yg==", + "optional": true, + "requires": { + "@img/sharp-libvips-linuxmusl-arm64": "1.2.4" + } + }, + "@img/sharp-linuxmusl-x64": { + "version": "0.34.5", + "resolved": "https://registry.npmjs.org/@img/sharp-linuxmusl-x64/-/sharp-linuxmusl-x64-0.34.5.tgz", + "integrity": "sha512-Jg8wNT1MUzIvhBFxViqrEhWDGzqymo3sV7z7ZsaWbZNDLXRJZoRGrjulp60YYtV4wfY8VIKcWidjojlLcWrd8Q==", + "optional": true, + "requires": { + "@img/sharp-libvips-linuxmusl-x64": "1.2.4" + } + }, + "@img/sharp-wasm32": { + "version": "0.34.5", + "resolved": "https://registry.npmjs.org/@img/sharp-wasm32/-/sharp-wasm32-0.34.5.tgz", + "integrity": "sha512-OdWTEiVkY2PHwqkbBI8frFxQQFekHaSSkUIJkwzclWZe64O1X4UlUjqqqLaPbUpMOQk6FBu/HtlGXNblIs0huw==", + "optional": true, + "requires": { + "@emnapi/runtime": "^1.7.0" + } + }, + "@img/sharp-win32-arm64": { + "version": "0.34.5", + "resolved": "https://registry.npmjs.org/@img/sharp-win32-arm64/-/sharp-win32-arm64-0.34.5.tgz", + "integrity": "sha512-WQ3AgWCWYSb2yt+IG8mnC6Jdk9Whs7O0gxphblsLvdhSpSTtmu69ZG1Gkb6NuvxsNACwiPV6cNSZNzt0KPsw7g==", + "optional": true + }, + "@img/sharp-win32-ia32": { + "version": "0.34.5", + "resolved": "https://registry.npmjs.org/@img/sharp-win32-ia32/-/sharp-win32-ia32-0.34.5.tgz", + "integrity": "sha512-FV9m/7NmeCmSHDD5j4+4pNI8Cp3aW+JvLoXcTUo0IqyjSfAZJ8dIUmijx1qaJsIiU+Hosw6xM5KijAWRJCSgNg==", + "optional": true + }, + "@img/sharp-win32-x64": { + "version": "0.34.5", + "resolved": "https://registry.npmjs.org/@img/sharp-win32-x64/-/sharp-win32-x64-0.34.5.tgz", + "integrity": "sha512-+29YMsqY2/9eFEiW93eqWnuLcWcufowXewwSNIT6UwZdUUCrM3oFjMWH/Z6/TMmb4hlFenmfAVbpWeup2jryCw==", + "optional": true + }, + "@jridgewell/resolve-uri": { + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/@jridgewell/resolve-uri/-/resolve-uri-3.1.2.tgz", + "integrity": "sha512-bRISgCIjP20/tbWSPWMEi54QVPRZExkuD9lJL+UIxUKtwVJA8wW1Trb1jMs1RFXo1CBTNZ/5hpC9QvmKWdopKw==" + }, + "@jridgewell/sourcemap-codec": { + "version": "1.5.5", + "resolved": "https://registry.npmjs.org/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.5.5.tgz", + "integrity": "sha512-cYQ9310grqxueWbl+WuIUIaiUaDcj7WOq5fVhEljNVgRfOUhY9fy2zTvfoqWsnebh8Sl70VScFbICvJnLKB0Og==" + }, + "@jridgewell/trace-mapping": { + "version": "0.3.31", + "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.31.tgz", + "integrity": "sha512-zzNR+SdQSDJzc8joaeP8QQoCQr8NuYx2dIIytl1QeBEZHJ9uW6hebsrYgbz8hJwUQao3TWCMtmfV8Nu1twOLAw==", + "requires": { + "@jridgewell/resolve-uri": "^3.1.0", + "@jridgewell/sourcemap-codec": "^1.4.14" + } + }, + "@jscad/3mf-serializer": { + "version": "2.1.12", + "resolved": "https://registry.npmjs.org/@jscad/3mf-serializer/-/3mf-serializer-2.1.12.tgz", + "integrity": "sha512-+rxAIKIHCpaplupwwsdXtG1IdimPXFFB45nrjy6gdFHi36bEQW6y/RQD/ngenRiKnYSxu7/M0LatHcjve8z64A==", + "requires": { + "@jscad/array-utils": "2.1.4", + "@jscad/modeling": "2.12.3", + "fflate": "0.7.3", + "onml": "1.2.0" + } + }, + "@jscad/array-utils": { + "version": "2.1.4", + "resolved": "https://registry.npmjs.org/@jscad/array-utils/-/array-utils-2.1.4.tgz", + "integrity": "sha512-c31r4zSKsE+4Xfwk2V8monDA0hx5G89QGzaakWVUvuGNowYS9WSsYCwHiTIXodjR+HEnDu4okQ7k/whmP0Ne2g==" + }, + "@jscad/dxf-serializer": { + "version": "2.1.18", + "resolved": "https://registry.npmjs.org/@jscad/dxf-serializer/-/dxf-serializer-2.1.18.tgz", + "integrity": "sha512-T5Qe2jbEphcWAk7GaOY8PCMD4DPhTm6gWk/MPJCExphhnUwJqcU/1RiMb5hiD+N6hHzmlxD59I8QTjlp9LbLSA==", + "requires": { + "@jscad/array-utils": "2.1.4", + "@jscad/modeling": "2.12.3" + } + }, + "@jscad/io-utils": { + "version": "2.0.28", + "resolved": "https://registry.npmjs.org/@jscad/io-utils/-/io-utils-2.0.28.tgz", + "integrity": "sha512-spXh37wAgmwjKztoH/HANLgImcqRHX5+H/cRIxPfpqDIWvu7I5bRg2ZTwh25SYlKIzxPk4qX5Nu7Ax5+Kg+QXQ==" + }, + "@jscad/modeling": { + "version": "2.12.3", + "resolved": "https://registry.npmjs.org/@jscad/modeling/-/modeling-2.12.3.tgz", + "integrity": "sha512-DnAacXq3zhlYWIixGlFD7RMpgZAMuCaMZNQov0NaoFfs2GaBuTC5eqkqKcEVbhEerBmTllbjjF5IXjJMt9jcOA==" + }, + "@jscad/stl-serializer": { + "version": "2.1.18", + "resolved": "https://registry.npmjs.org/@jscad/stl-serializer/-/stl-serializer-2.1.18.tgz", + "integrity": "sha512-pz++TRjHI7jBPnnxQUi4B/uYUG3yCDsKlw8+xL2kumwjb+auc6Ng6Rnr/GqUTkgHrnGut08wg/8AekyWjvBwYg==", + "requires": { + "@jscad/array-utils": "2.1.4", + "@jscad/modeling": "2.12.3" + } + }, + "@jscadui/3mf-export": { + "version": "0.5.0", + "resolved": "https://registry.npmjs.org/@jscadui/3mf-export/-/3mf-export-0.5.0.tgz", + "integrity": "sha512-y5vZktqCjyi7wA38zqNlLIdZUIRZoOO9vCjLzwmL4bR0hk7B/Zm1IeffzJPFe1vFc0C1IEv3hm8caDv3doRk9g==" + }, + "@jsep-plugin/assignment": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/@jsep-plugin/assignment/-/assignment-1.3.0.tgz", + "integrity": "sha512-VVgV+CXrhbMI3aSusQyclHkenWSAm95WaiKrMxRFam3JSUiIaQjoMIw2sEs/OX4XifnqeQUN4DYbJjlA8EfktQ==", + "requires": {} + }, + "@jsep-plugin/regex": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/@jsep-plugin/regex/-/regex-1.0.4.tgz", + "integrity": "sha512-q7qL4Mgjs1vByCaTnDFcBnV9HS7GVPJX5vyVoCgZHNSC9rjwIlmbXG5sUuorR5ndfHAIlJ8pVStxvjXHbNvtUg==", + "requires": {} + }, + "@rollup/rollup-android-arm-eabi": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-android-arm-eabi/-/rollup-android-arm-eabi-4.40.1.tgz", + "integrity": "sha512-kxz0YeeCrRUHz3zyqvd7n+TVRlNyTifBsmnmNPtk3hQURUyG9eAB+usz6DAwagMusjx/zb3AjvDUvhFGDAexGw==", + "dev": true, + "optional": true + }, + "@rollup/rollup-android-arm64": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-android-arm64/-/rollup-android-arm64-4.40.1.tgz", + "integrity": "sha512-PPkxTOisoNC6TpnDKatjKkjRMsdaWIhyuMkA4UsBXT9WEZY4uHezBTjs6Vl4PbqQQeu6oION1w2voYZv9yquCw==", + "dev": true, + "optional": true + }, + "@rollup/rollup-darwin-arm64": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-darwin-arm64/-/rollup-darwin-arm64-4.40.1.tgz", + "integrity": "sha512-VWXGISWFY18v/0JyNUy4A46KCFCb9NVsH+1100XP31lud+TzlezBbz24CYzbnA4x6w4hx+NYCXDfnvDVO6lcAA==", + "dev": true, + "optional": true + }, + "@rollup/rollup-darwin-x64": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-darwin-x64/-/rollup-darwin-x64-4.40.1.tgz", + "integrity": "sha512-nIwkXafAI1/QCS7pxSpv/ZtFW6TXcNUEHAIA9EIyw5OzxJZQ1YDrX+CL6JAIQgZ33CInl1R6mHet9Y/UZTg2Bw==", + "dev": true, + "optional": true + }, + "@rollup/rollup-freebsd-arm64": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-freebsd-arm64/-/rollup-freebsd-arm64-4.40.1.tgz", + "integrity": "sha512-BdrLJ2mHTrIYdaS2I99mriyJfGGenSaP+UwGi1kB9BLOCu9SR8ZpbkmmalKIALnRw24kM7qCN0IOm6L0S44iWw==", + "dev": true, + "optional": true + }, + "@rollup/rollup-freebsd-x64": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-freebsd-x64/-/rollup-freebsd-x64-4.40.1.tgz", + "integrity": "sha512-VXeo/puqvCG8JBPNZXZf5Dqq7BzElNJzHRRw3vjBE27WujdzuOPecDPc/+1DcdcTptNBep3861jNq0mYkT8Z6Q==", + "dev": true, + "optional": true + }, + "@rollup/rollup-linux-arm-gnueabihf": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm-gnueabihf/-/rollup-linux-arm-gnueabihf-4.40.1.tgz", + "integrity": "sha512-ehSKrewwsESPt1TgSE/na9nIhWCosfGSFqv7vwEtjyAqZcvbGIg4JAcV7ZEh2tfj/IlfBeZjgOXm35iOOjadcg==", + "dev": true, + "optional": true + }, + "@rollup/rollup-linux-arm-musleabihf": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm-musleabihf/-/rollup-linux-arm-musleabihf-4.40.1.tgz", + "integrity": "sha512-m39iO/aaurh5FVIu/F4/Zsl8xppd76S4qoID8E+dSRQvTyZTOI2gVk3T4oqzfq1PtcvOfAVlwLMK3KRQMaR8lg==", + "dev": true, + "optional": true + }, + "@rollup/rollup-linux-arm64-gnu": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm64-gnu/-/rollup-linux-arm64-gnu-4.40.1.tgz", + "integrity": "sha512-Y+GHnGaku4aVLSgrT0uWe2o2Rq8te9hi+MwqGF9r9ORgXhmHK5Q71N757u0F8yU1OIwUIFy6YiJtKjtyktk5hg==", + "dev": true, + "optional": true + }, + "@rollup/rollup-linux-arm64-musl": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm64-musl/-/rollup-linux-arm64-musl-4.40.1.tgz", + "integrity": "sha512-jEwjn3jCA+tQGswK3aEWcD09/7M5wGwc6+flhva7dsQNRZZTe30vkalgIzV4tjkopsTS9Jd7Y1Bsj6a4lzz8gQ==", + "dev": true, + "optional": true + }, + "@rollup/rollup-linux-loongarch64-gnu": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-loongarch64-gnu/-/rollup-linux-loongarch64-gnu-4.40.1.tgz", + "integrity": "sha512-ySyWikVhNzv+BV/IDCsrraOAZ3UaC8SZB67FZlqVwXwnFhPihOso9rPOxzZbjp81suB1O2Topw+6Ug3JNegejQ==", + "dev": true, + "optional": true + }, + "@rollup/rollup-linux-powerpc64le-gnu": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-powerpc64le-gnu/-/rollup-linux-powerpc64le-gnu-4.40.1.tgz", + "integrity": "sha512-BvvA64QxZlh7WZWqDPPdt0GH4bznuL6uOO1pmgPnnv86rpUpc8ZxgZwcEgXvo02GRIZX1hQ0j0pAnhwkhwPqWg==", + "dev": true, + "optional": true + }, + "@rollup/rollup-linux-riscv64-gnu": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-riscv64-gnu/-/rollup-linux-riscv64-gnu-4.40.1.tgz", + "integrity": "sha512-EQSP+8+1VuSulm9RKSMKitTav89fKbHymTf25n5+Yr6gAPZxYWpj3DzAsQqoaHAk9YX2lwEyAf9S4W8F4l3VBQ==", + "dev": true, + "optional": true + }, + "@rollup/rollup-linux-riscv64-musl": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-riscv64-musl/-/rollup-linux-riscv64-musl-4.40.1.tgz", + "integrity": "sha512-n/vQ4xRZXKuIpqukkMXZt9RWdl+2zgGNx7Uda8NtmLJ06NL8jiHxUawbwC+hdSq1rrw/9CghCpEONor+l1e2gA==", + "dev": true, + "optional": true + }, + "@rollup/rollup-linux-s390x-gnu": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-s390x-gnu/-/rollup-linux-s390x-gnu-4.40.1.tgz", + "integrity": "sha512-h8d28xzYb98fMQKUz0w2fMc1XuGzLLjdyxVIbhbil4ELfk5/orZlSTpF/xdI9C8K0I8lCkq+1En2RJsawZekkg==", + "dev": true, + "optional": true + }, + "@rollup/rollup-linux-x64-gnu": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-x64-gnu/-/rollup-linux-x64-gnu-4.40.1.tgz", + "integrity": "sha512-XiK5z70PEFEFqcNj3/zRSz/qX4bp4QIraTy9QjwJAb/Z8GM7kVUsD0Uk8maIPeTyPCP03ChdI+VVmJriKYbRHQ==", + "dev": true, + "optional": true + }, + "@rollup/rollup-linux-x64-musl": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-x64-musl/-/rollup-linux-x64-musl-4.40.1.tgz", + "integrity": "sha512-2BRORitq5rQ4Da9blVovzNCMaUlyKrzMSvkVR0D4qPuOy/+pMCrh1d7o01RATwVy+6Fa1WBw+da7QPeLWU/1mQ==", + "dev": true, + "optional": true + }, + "@rollup/rollup-win32-arm64-msvc": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-arm64-msvc/-/rollup-win32-arm64-msvc-4.40.1.tgz", + "integrity": "sha512-b2bcNm9Kbde03H+q+Jjw9tSfhYkzrDUf2d5MAd1bOJuVplXvFhWz7tRtWvD8/ORZi7qSCy0idW6tf2HgxSXQSg==", + "dev": true, + "optional": true + }, + "@rollup/rollup-win32-ia32-msvc": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-ia32-msvc/-/rollup-win32-ia32-msvc-4.40.1.tgz", + "integrity": "sha512-DfcogW8N7Zg7llVEfpqWMZcaErKfsj9VvmfSyRjCyo4BI3wPEfrzTtJkZG6gKP/Z92wFm6rz2aDO7/JfiR/whA==", + "dev": true, + "optional": true + }, + "@rollup/rollup-win32-x64-msvc": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-x64-msvc/-/rollup-win32-x64-msvc-4.40.1.tgz", + "integrity": "sha512-ECyOuDeH3C1I8jH2MK1RtBJW+YPMvSfT0a5NN0nHfQYnDSJ6tUiZH3gzwVP5/Kfh/+Tt7tpWVF9LXNTnhTJ3kA==", + "dev": true, + "optional": true + }, + "@tweenjs/tween.js": { + "version": "23.1.3", + "resolved": "https://registry.npmjs.org/@tweenjs/tween.js/-/tween.js-23.1.3.tgz", + "integrity": "sha512-vJmvvwFxYuGnF2axRtPYocag6Clbb5YS7kLL+SO/TeVFzHqDIWrNKYtcsPMibjDx9O+bu+psAy9NKfWklassUA==", + "dev": true + }, + "@types/emscripten": { + "version": "1.40.1", + "resolved": "https://registry.npmjs.org/@types/emscripten/-/emscripten-1.40.1.tgz", + "integrity": "sha512-sr53lnYkQNhjHNN0oJDdUm5564biioI5DuOpycufDVK7D3y+GR3oUswe2rlwY1nPNyusHbrJ9WoTyIHl4/Bpwg==" + }, + "@types/estree": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/@types/estree/-/estree-1.0.7.tgz", + "integrity": "sha512-w28IoSUCJpidD/TGviZwwMJckNESJZXFu7NBZ5YJ4mEUnNraUn9Pm8HSZm/jDF1pDWYKspWE7oVphigUPRakIQ==", + "dev": true + }, + "@types/ndarray": { + "version": "1.0.14", + "resolved": "https://registry.npmjs.org/@types/ndarray/-/ndarray-1.0.14.tgz", + "integrity": "sha512-oANmFZMnFQvb219SSBIhI1Ih/r4CvHDOzkWyJS/XRqkMrGH5/kaPSA1hQhdIBzouaE+5KpE/f5ylI9cujmckQg==" + }, + "@types/stats.js": { + "version": "0.17.3", + "resolved": "https://registry.npmjs.org/@types/stats.js/-/stats.js-0.17.3.tgz", + "integrity": "sha512-pXNfAD3KHOdif9EQXZ9deK82HVNaXP5ZIF5RP2QG6OQFNTaY2YIetfrE9t528vEreGQvEPRDDc8muaoYeK0SxQ==", + "dev": true + }, + "@types/three": { + "version": "0.182.0", + "resolved": "https://registry.npmjs.org/@types/three/-/three-0.182.0.tgz", + "integrity": "sha512-WByN9V3Sbwbe2OkWuSGyoqQO8Du6yhYaXtXLoA5FkKTUJorZ+yOHBZ35zUUPQXlAKABZmbYp5oAqpA4RBjtJ/Q==", + "dev": true, + "requires": { + "@dimforge/rapier3d-compat": "~0.12.0", + "@tweenjs/tween.js": "~23.1.3", + "@types/stats.js": "*", + "@types/webxr": ">=0.5.17", + "@webgpu/types": "*", + "fflate": "~0.8.2", + "meshoptimizer": "~0.22.0" + }, + "dependencies": { + "fflate": { + "version": "0.8.2", + "resolved": "https://registry.npmjs.org/fflate/-/fflate-0.8.2.tgz", + "integrity": "sha512-cPJU47OaAoCbg0pBvzsgpTPhmhqI5eJjh/JIu8tPj5q+T7iLvW/JAYUqmE7KOB4R1ZyEhzBaIQpQpardBF5z8A==", + "dev": true + } + } + }, + "@types/webxr": { + "version": "0.5.22", + "resolved": "https://registry.npmjs.org/@types/webxr/-/webxr-0.5.22.tgz", + "integrity": "sha512-Vr6Stjv5jPRqH690f5I5GLjVk8GSsoQSYJ2FVd/3jJF7KaqfwPi3ehfBS96mlQ2kPCwZaX6U0rG2+NGHBKkA/A==", + "dev": true + }, + "@webgpu/types": { + "version": "0.1.60", + "resolved": "https://registry.npmjs.org/@webgpu/types/-/types-0.1.60.tgz", + "integrity": "sha512-8B/tdfRFKdrnejqmvq95ogp8tf52oZ51p3f4QD5m5Paey/qlX4Rhhy5Y8tgFMi7Ms70HzcMMw3EQjH/jdhTwlA==", + "dev": true + }, + "babylonjs-gltf2interface": { + "version": "8.44.1", + "resolved": "https://registry.npmjs.org/babylonjs-gltf2interface/-/babylonjs-gltf2interface-8.44.1.tgz", + "integrity": "sha512-+z0P0wms1FD5xuVpuRJ1qjvGAbPAWhEWGBWENRPD0Hbz6nd9cnL28/pjxgk39/QhlIuJKL9JZ0o8G0JgLHEnRQ==", + "peer": true + }, + "bindings": { + "version": "1.5.0", + "resolved": "https://registry.npmjs.org/bindings/-/bindings-1.5.0.tgz", + "integrity": "sha512-p2q/t/mhvuOj/UeLlV6566GD/guowlr0hHxClI0W9m7MWYkL1F0hLo+0Aexs9HSPCtR1SXQ0TD3MMKrXZajbiQ==", + "optional": true, + "requires": { + "file-uri-to-path": "1.0.0" + } + }, + "commander": { + "version": "13.1.0", + "resolved": "https://registry.npmjs.org/commander/-/commander-13.1.0.tgz", + "integrity": "sha512-/rFeCpNJQbhSZjGVwO9RFV3xPqbnERS8MmIQzCtD/zl6gpJuV/bMLuN92oG3F7d8oDEHHRrujSXNUr8fpjntKw==" + }, + "convert-source-map": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/convert-source-map/-/convert-source-map-2.0.0.tgz", + "integrity": "sha512-Kvp459HrV2FEJ1CAsi1Ku+MY3kasH19TFykTz2xWmMeq6bk2NU3XXvfJ+Q61m0xktWwt+1HSYf3JZsTms3aRJg==" + }, + "core-js": { + "version": "3.47.0", + "resolved": "https://registry.npmjs.org/core-js/-/core-js-3.47.0.tgz", + "integrity": "sha512-c3Q2VVkGAUyupsjRnaNX6u8Dq2vAdzm9iuPj5FW0fRxzlxgq9Q39MDq10IvmQSpLgHQNyQzQmOo6bgGHmH3NNg==" + }, + "cwise-compiler": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/cwise-compiler/-/cwise-compiler-1.1.3.tgz", + "integrity": "sha512-WXlK/m+Di8DMMcCjcWr4i+XzcQra9eCdXIJrgh4TUgh0pIS/yJduLxS9JgefsHJ/YVLdgPtXm9r62W92MvanEQ==", + "requires": { + "uniq": "^1.0.0" + } + }, + "detect-libc": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/detect-libc/-/detect-libc-2.1.2.tgz", + "integrity": "sha512-Btj2BOOO83o3WyH59e8MgXsxEQVcarkUOpEYrubB0urwnN10yQ364rsiByU11nZlqWYZm05i/of7io4mzihBtQ==" + }, + "earcut": { + "version": "2.2.3", + "resolved": "https://registry.npmjs.org/earcut/-/earcut-2.2.3.tgz", + "integrity": "sha512-iRDI1QeCQIhMCZk48DRDMVgQSSBDmbzzNhnxIo+pwx3swkfjMh6vh0nWLq1NdvGHLKH6wIrAM3vQWeTj6qeoug==" + }, + "esbuild": { + "version": "0.25.3", + "resolved": "https://registry.npmjs.org/esbuild/-/esbuild-0.25.3.tgz", + "integrity": "sha512-qKA6Pvai73+M2FtftpNKRxJ78GIjmFXFxd/1DVBqGo/qNhLSfv+G12n9pNoWdytJC8U00TrViOwpjT0zgqQS8Q==", + "dev": true, + "requires": { + "@esbuild/aix-ppc64": "0.25.3", + "@esbuild/android-arm": "0.25.3", + "@esbuild/android-arm64": "0.25.3", + "@esbuild/android-x64": "0.25.3", + "@esbuild/darwin-arm64": "0.25.3", + "@esbuild/darwin-x64": "0.25.3", + "@esbuild/freebsd-arm64": "0.25.3", + "@esbuild/freebsd-x64": "0.25.3", + "@esbuild/linux-arm": "0.25.3", + "@esbuild/linux-arm64": "0.25.3", + "@esbuild/linux-ia32": "0.25.3", + "@esbuild/linux-loong64": "0.25.3", + "@esbuild/linux-mips64el": "0.25.3", + "@esbuild/linux-ppc64": "0.25.3", + "@esbuild/linux-riscv64": "0.25.3", + "@esbuild/linux-s390x": "0.25.3", + "@esbuild/linux-x64": "0.25.3", + "@esbuild/netbsd-arm64": "0.25.3", + "@esbuild/netbsd-x64": "0.25.3", + "@esbuild/openbsd-arm64": "0.25.3", + "@esbuild/openbsd-x64": "0.25.3", + "@esbuild/sunos-x64": "0.25.3", + "@esbuild/win32-arm64": "0.25.3", + "@esbuild/win32-ia32": "0.25.3", + "@esbuild/win32-x64": "0.25.3" + } + }, + "esbuild-plugin-text-replace": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/esbuild-plugin-text-replace/-/esbuild-plugin-text-replace-1.3.0.tgz", + "integrity": "sha512-RWB/bbdP0xDHBOtA0st4CAE6UZtky76aCB7Shw5r350JY403lfvrj2UMkInUB346tMtFWXKWXNf4gqNM+WbXag==", + "requires": { + "ts-replace-all": "^1.0.0" + } + }, + "esbuild-wasm": { + "version": "0.25.12", + "resolved": "https://registry.npmjs.org/esbuild-wasm/-/esbuild-wasm-0.25.12.tgz", + "integrity": "sha512-rZqkjL3Y6FwLpSHzLnaEy8Ps6veCNo1kZa9EOfJvmWtBq5dJH4iVjfmOO6Mlkv9B0tt9WFPFmb/VxlgJOnueNg==" + }, + "fdir": { + "version": "6.4.4", + "resolved": "https://registry.npmjs.org/fdir/-/fdir-6.4.4.tgz", + "integrity": "sha512-1NZP+GK4GfuAv3PqKvxQRDMjdSRZjnkq7KfhlNrCNNlZ0ygQFpebfrnfnq/W7fpUnAv9aGWmY1zKx7FYL3gwhg==", + "dev": true, + "requires": {} + }, + "fflate": { + "version": "0.7.3", + "resolved": "https://registry.npmjs.org/fflate/-/fflate-0.7.3.tgz", + "integrity": "sha512-0Zz1jOzJWERhyhsimS54VTqOteCNwRtIlh8isdL0AXLo0g7xNTfTL7oWrkmCnPhZGocKIkWHBistBrrpoNH3aw==" + }, + "file-uri-to-path": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/file-uri-to-path/-/file-uri-to-path-1.0.0.tgz", + "integrity": "sha512-0Zt+s3L7Vf1biwWZ29aARiVYLx7iMGnEUl9x33fbB/j3jR81u/O2LbqK+Bm1CDSNDKVtJ/YjwY7TUd5SkeLQLw==", + "optional": true + }, + "fsevents": { + "version": "2.3.3", + "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.3.tgz", + "integrity": "sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw==", + "dev": true, + "optional": true + }, + "iota-array": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/iota-array/-/iota-array-1.0.0.tgz", + "integrity": "sha512-pZ2xT+LOHckCatGQ3DcG/a+QuEqvoxqkiL7tvE8nn3uuu+f6i1TtpB5/FtWFbxUuVr5PZCx8KskuGatbJDXOWA==" + }, + "is-buffer": { + "version": "1.1.6", + "resolved": "https://registry.npmjs.org/is-buffer/-/is-buffer-1.1.6.tgz", + "integrity": "sha512-NcdALwpXkTm5Zvvbk7owOUSvVvBKDgKP5/ewfXEznmQFfs4ZRmanOeKBTjRVjka3QFoN6XJ+9F3USqfHqTaU5w==" + }, + "jsep": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/jsep/-/jsep-1.4.0.tgz", + "integrity": "sha512-B7qPcEVE3NVkmSJbaYxvv4cHkVW7DQsZz13pUMrfS8z8Q/BuShN+gcTXrUlPiGqM2/t/EEaI030bpxMqY8gMlw==" + }, + "jsonpath-plus": { + "version": "10.1.0", + "resolved": "https://registry.npmjs.org/jsonpath-plus/-/jsonpath-plus-10.1.0.tgz", + "integrity": "sha512-gHfV1IYqH8uJHYVTs8BJX1XKy2/rR93+f8QQi0xhx95aCiXn1ettYAd5T+7FU6wfqyDoX/wy0pm/fL3jOKJ9Lg==", + "requires": { + "@jsep-plugin/assignment": "^1.2.1", + "@jsep-plugin/regex": "^1.0.3", + "jsep": "^1.3.9" + } + }, + "ktx-parse": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/ktx-parse/-/ktx-parse-1.1.0.tgz", + "integrity": "sha512-mKp3y+FaYgR7mXWAbyyzpa/r1zDWeaunH+INJO4fou3hb45XuNSwar+7llrRyvpMWafxSIi99RNFJ05MHedaJQ==" + }, + "manifold-3d": { + "version": "3.3.2", + "resolved": "https://registry.npmjs.org/manifold-3d/-/manifold-3d-3.3.2.tgz", + "integrity": "sha512-Xx+S7kkbqlZxSPfBKH5yVKDO6k/eW7JRvnG1dKCFO0D4zjifOV5GM18TR0sREDcbKAzglHZ5OoxxpZRkxg6U5A==", + "requires": { + "@gltf-transform/core": "^4.2.0", + "@gltf-transform/extensions": "^4.2.0", + "@gltf-transform/functions": "^4.2.0", + "@jridgewell/trace-mapping": "^0.3.31", + "@jscadui/3mf-export": "^0.5.0", + "commander": "^13.1.0", + "convert-source-map": "^2.0.0", + "esbuild-plugin-text-replace": "^1.3.0", + "esbuild-wasm": "^0.25.11", + "fflate": "^0.8.0" + }, + "dependencies": { + "fflate": { + "version": "0.8.2", + "resolved": "https://registry.npmjs.org/fflate/-/fflate-0.8.2.tgz", + "integrity": "sha512-cPJU47OaAoCbg0pBvzsgpTPhmhqI5eJjh/JIu8tPj5q+T7iLvW/JAYUqmE7KOB4R1ZyEhzBaIQpQpardBF5z8A==" + } + } + }, + "meshoptimizer": { + "version": "0.22.0", + "resolved": "https://registry.npmjs.org/meshoptimizer/-/meshoptimizer-0.22.0.tgz", + "integrity": "sha512-IebiK79sqIy+E4EgOr+CAw+Ke8hAspXKzBd0JdgEmPHiAwmvEj2S4h1rfvo+o/BnfEYd/jAOg5IeeIjzlzSnDg==", + "dev": true + }, + "nan": { + "version": "2.24.0", + "resolved": "https://registry.npmjs.org/nan/-/nan-2.24.0.tgz", + "integrity": "sha512-Vpf9qnVW1RaDkoNKFUvfxqAbtI8ncb8OJlqZ9wwpXzWPEsvsB1nvdUi6oYrHIkQ1Y/tMDnr1h4nczS0VB9Xykg==", + "optional": true + }, + "nanoid": { + "version": "3.3.11", + "resolved": "https://registry.npmjs.org/nanoid/-/nanoid-3.3.11.tgz", + "integrity": "sha512-N8SpfPUnUp1bK+PMYW8qSWdl9U+wwNWI4QKxOYDy9JAro3WMX7p2OeVRF9v+347pnakNevPmiHhNmZ2HbFA76w==", + "dev": true + }, + "ndarray": { + "version": "1.0.19", + "resolved": "https://registry.npmjs.org/ndarray/-/ndarray-1.0.19.tgz", + "integrity": "sha512-B4JHA4vdyZU30ELBw3g7/p9bZupyew5a7tX1Y/gGeF2hafrPaQZhgrGQfsvgfYbgdFZjYwuEcnaobeM/WMW+HQ==", + "requires": { + "iota-array": "^1.0.0", + "is-buffer": "^1.0.2" + } + }, + "ndarray-lanczos": { + "version": "0.3.0", + "resolved": "https://registry.npmjs.org/ndarray-lanczos/-/ndarray-lanczos-0.3.0.tgz", + "integrity": "sha512-5kBmmG3Zvyj77qxIAC4QFLKuYdDIBJwCG+DukT6jQHNa1Ft74/hPH1z5mbQXeHBt8yvGPBGVrr3wEOdJPYYZYg==", + "requires": { + "@types/ndarray": "^1.0.11", + "ndarray": "^1.0.19" + } + }, + "ndarray-ops": { + "version": "1.2.2", + "resolved": "https://registry.npmjs.org/ndarray-ops/-/ndarray-ops-1.2.2.tgz", + "integrity": "sha512-BppWAFRjMYF7N/r6Ie51q6D4fs0iiGmeXIACKY66fLpnwIui3Wc3CXiD/30mgLbDjPpSLrsqcp3Z62+IcHZsDw==", + "requires": { + "cwise-compiler": "^1.0.0" + } + }, + "ndarray-pixels": { + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/ndarray-pixels/-/ndarray-pixels-5.0.1.tgz", + "integrity": "sha512-IBtrpefpqlI8SPDCGjXk4v5NV5z7r3JSuCbfuEEXaM0vrOJtNGgYUa4C3Lt5H+qWdYF4BCPVFsnXhNC7QvZwkw==", + "requires": { + "@types/ndarray": "^1.0.14", + "ndarray": "^1.0.19", + "ndarray-ops": "^1.2.2", + "sharp": "^0.34.0" + } + }, + "onml": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/onml/-/onml-1.2.0.tgz", + "integrity": "sha512-olqYAg18XoHAhm7tK9DdBCOVdts70DGmMgCNLOWyqZokht2utgGSKBB4JHi6pBZpmioAhcYlxK+91L3tsrz+GA==", + "requires": { + "sax": "^1.2.1" + } + }, + "picocolors": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.1.1.tgz", + "integrity": "sha512-xceH2snhtb5M9liqDsmEw56le376mTZkEX/jEb/RxNFyegNul7eNslCXP9FDj/Lcu0X8KEyMceP2ntpaHrDEVA==", + "dev": true + }, + "picomatch": { + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.2.tgz", + "integrity": "sha512-M7BAV6Rlcy5u+m6oPhAPFgJTzAioX/6B0DxyvDlo9l8+T3nLKbrczg2WLUyzd45L8RqfUMyGPzekbMvX2Ldkwg==", + "dev": true + }, + "postcss": { + "version": "8.5.3", + "resolved": "https://registry.npmjs.org/postcss/-/postcss-8.5.3.tgz", + "integrity": "sha512-dle9A3yYxlBSrt8Fu+IpjGT8SY8hN0mlaA6GY8t0P5PjIOZemULz/E2Bnm/2dcUOena75OTNkHI76uZBNUUq3A==", + "dev": true, + "requires": { + "nanoid": "^3.3.8", + "picocolors": "^1.1.1", + "source-map-js": "^1.2.1" + } + }, + "property-graph": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/property-graph/-/property-graph-4.0.0.tgz", + "integrity": "sha512-I0hojAJfTbSCZy3y6xyK29eayxo14v1bj1VPiDkHjTdz33SV6RdfMz2AHnf4ai62Vng2mN5GkaKahkooBIo9gA==" + }, + "rollup": { + "version": "4.40.1", + "resolved": "https://registry.npmjs.org/rollup/-/rollup-4.40.1.tgz", + "integrity": "sha512-C5VvvgCCyfyotVITIAv+4efVytl5F7wt+/I2i9q9GZcEXW9BP52YYOXC58igUi+LFZVHukErIIqQSWwv/M3WRw==", + "dev": true, + "requires": { + "@rollup/rollup-android-arm-eabi": "4.40.1", + "@rollup/rollup-android-arm64": "4.40.1", + "@rollup/rollup-darwin-arm64": "4.40.1", + "@rollup/rollup-darwin-x64": "4.40.1", + "@rollup/rollup-freebsd-arm64": "4.40.1", + "@rollup/rollup-freebsd-x64": "4.40.1", + "@rollup/rollup-linux-arm-gnueabihf": "4.40.1", + "@rollup/rollup-linux-arm-musleabihf": "4.40.1", + "@rollup/rollup-linux-arm64-gnu": "4.40.1", + "@rollup/rollup-linux-arm64-musl": "4.40.1", + "@rollup/rollup-linux-loongarch64-gnu": "4.40.1", + "@rollup/rollup-linux-powerpc64le-gnu": "4.40.1", + "@rollup/rollup-linux-riscv64-gnu": "4.40.1", + "@rollup/rollup-linux-riscv64-musl": "4.40.1", + "@rollup/rollup-linux-s390x-gnu": "4.40.1", + "@rollup/rollup-linux-x64-gnu": "4.40.1", + "@rollup/rollup-linux-x64-musl": "4.40.1", + "@rollup/rollup-win32-arm64-msvc": "4.40.1", + "@rollup/rollup-win32-ia32-msvc": "4.40.1", + "@rollup/rollup-win32-x64-msvc": "4.40.1", + "@types/estree": "1.0.7", + "fsevents": "~2.3.2" + } + }, + "rxjs": { + "version": "7.5.5", + "resolved": "https://registry.npmjs.org/rxjs/-/rxjs-7.5.5.tgz", + "integrity": "sha512-sy+H0pQofO95VDmFLzyaw9xNJU4KTRSwQIGM6+iG3SypAtCiLDzpeG8sJrNCWn2Up9km+KhkvTdbkrdy+yzZdw==", + "requires": { + "tslib": "^2.1.0" + } + }, + "sax": { + "version": "1.4.3", + "resolved": "https://registry.npmjs.org/sax/-/sax-1.4.3.tgz", + "integrity": "sha512-yqYn1JhPczigF94DMS+shiDMjDowYO6y9+wB/4WgO0Y19jWYk0lQ4tuG5KI7kj4FTp1wxPj5IFfcrz/s1c3jjQ==" + }, + "semver": { + "version": "7.7.3", + "resolved": "https://registry.npmjs.org/semver/-/semver-7.7.3.tgz", + "integrity": "sha512-SdsKMrI9TdgjdweUSR9MweHA4EJ8YxHn8DFaDisvhVlUOe4BF1tLD7GAj0lIqWVl+dPb/rExr0Btby5loQm20Q==" + }, + "sharp": { + "version": "0.34.5", + "resolved": "https://registry.npmjs.org/sharp/-/sharp-0.34.5.tgz", + "integrity": "sha512-Ou9I5Ft9WNcCbXrU9cMgPBcCK8LiwLqcbywW3t4oDV37n1pzpuNLsYiAV8eODnjbtQlSDwZ2cUEeQz4E54Hltg==", + "requires": { + "@img/colour": "^1.0.0", + "@img/sharp-darwin-arm64": "0.34.5", + "@img/sharp-darwin-x64": "0.34.5", + "@img/sharp-libvips-darwin-arm64": "1.2.4", + "@img/sharp-libvips-darwin-x64": "1.2.4", + "@img/sharp-libvips-linux-arm": "1.2.4", + "@img/sharp-libvips-linux-arm64": "1.2.4", + "@img/sharp-libvips-linux-ppc64": "1.2.4", + "@img/sharp-libvips-linux-riscv64": "1.2.4", + "@img/sharp-libvips-linux-s390x": "1.2.4", + "@img/sharp-libvips-linux-x64": "1.2.4", + "@img/sharp-libvips-linuxmusl-arm64": "1.2.4", + "@img/sharp-libvips-linuxmusl-x64": "1.2.4", + "@img/sharp-linux-arm": "0.34.5", + "@img/sharp-linux-arm64": "0.34.5", + "@img/sharp-linux-ppc64": "0.34.5", + "@img/sharp-linux-riscv64": "0.34.5", + "@img/sharp-linux-s390x": "0.34.5", + "@img/sharp-linux-x64": "0.34.5", + "@img/sharp-linuxmusl-arm64": "0.34.5", + "@img/sharp-linuxmusl-x64": "0.34.5", + "@img/sharp-wasm32": "0.34.5", + "@img/sharp-win32-arm64": "0.34.5", + "@img/sharp-win32-ia32": "0.34.5", + "@img/sharp-win32-x64": "0.34.5", + "detect-libc": "^2.1.2", + "semver": "^7.7.3" + } + }, + "source-map-js": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/source-map-js/-/source-map-js-1.2.1.tgz", + "integrity": "sha512-UXWMKhLOwVKb728IUtQPXxfYU+usdybtUrK/8uGE8CQMvrhOpwvzDBwj0QhSL7MQc7vIsISBG8VQ8+IDQxpfQA==", + "dev": true + }, + "tinyglobby": { + "version": "0.2.13", + "resolved": "https://registry.npmjs.org/tinyglobby/-/tinyglobby-0.2.13.tgz", + "integrity": "sha512-mEwzpUgrLySlveBwEVDMKk5B57bhLPYovRfPAXD5gA/98Opn0rCDj3GtLwFvCvH5RK9uPCExUROW5NjDwvqkxw==", + "dev": true, + "requires": { + "fdir": "^6.4.4", + "picomatch": "^4.0.2" + } + }, + "ts-replace-all": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/ts-replace-all/-/ts-replace-all-1.0.0.tgz", + "integrity": "sha512-6uBtdkw3jHXkPtx/e9xB/5vcngMm17CyJYsS2YZeQ+9FdRnt6Ev5g931Sg2p+dxbtMGoCm13m3ax/obicTZIkQ==", + "requires": { + "core-js": "^3.4.1" + } + }, + "tslib": { + "version": "2.8.1", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.8.1.tgz", + "integrity": "sha512-oJFu94HQb+KVduSUQL7wnpmqnfmLsOA/nAh6b6EH0wCEoK0/mPeXU6c3wKDV83MkOuHPRHtSXKKU99IBazS/2w==" + }, + "typescript": { + "version": "5.8.3", + "resolved": "https://registry.npmjs.org/typescript/-/typescript-5.8.3.tgz", + "integrity": "sha512-p1diW6TqL9L07nNxvRMM7hMMw4c5XOo/1ibL4aAIGmSAt9slTE1Xgw5KWuof2uTOvCg9BY7ZRi+GaF+7sfgPeQ==", + "dev": true + }, + "uniq": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/uniq/-/uniq-1.0.1.tgz", + "integrity": "sha512-Gw+zz50YNKPDKXs+9d+aKAjVwpjNwqzvNpLigIruT4HA9lMZNdMqs9x07kKHB/L9WRzqp4+DlTU5s4wG2esdoA==" + }, + "verb-nurbs-web": { + "version": "2.1.3", + "resolved": "https://registry.npmjs.org/verb-nurbs-web/-/verb-nurbs-web-2.1.3.tgz", + "integrity": "sha512-2PvI2bx7dn0r3kWtk+JuDIDZ+p7I5Piu8y6/ZNhUVpilOyHKK1nNzLHtgown+dFOmBnKnuAKIMh1xn/5kzrxZA==", + "requires": { + "webworker-threads": "^0.7.12" + } + }, + "vite": { + "version": "6.3.4", + "resolved": "https://registry.npmjs.org/vite/-/vite-6.3.4.tgz", + "integrity": "sha512-BiReIiMS2fyFqbqNT/Qqt4CVITDU9M9vE+DKcVAsB+ZV0wvTKd+3hMbkpxz1b+NmEDMegpVbisKiAZOnvO92Sw==", + "dev": true, + "requires": { + "esbuild": "^0.25.0", + "fdir": "^6.4.4", + "fsevents": "~2.3.3", + "picomatch": "^4.0.2", + "postcss": "^8.5.3", + "rollup": "^4.34.9", + "tinyglobby": "^0.2.13" + } + }, + "webworker-threads": { + "version": "0.7.17", + "resolved": "https://registry.npmjs.org/webworker-threads/-/webworker-threads-0.7.17.tgz", + "integrity": "sha512-Y2w2aXBbDLk9IzTEb9u+MsODC3s4YlGI7g4h0t+1OAwIO8yBI9rQL35ZYlyayiCuWu1dZMH/P7kGU8OwW7YsyA==", + "optional": true, + "requires": { + "bindings": "^1.3.0", + "nan": "^2.11.0" + } + } + } +} diff --git a/examples/vite/babylonjs/starter-template-full/package.json b/examples/vite/babylonjs/starter-template-full/package.json new file mode 100644 index 00000000..a131f88b --- /dev/null +++ b/examples/vite/babylonjs/starter-template-full/package.json @@ -0,0 +1,19 @@ +{ + "name": "vite-typescript-starter", + "private": true, + "version": "0.0.0", + "type": "module", + "scripts": { + "dev": "vite", + "build": "tsc && vite build", + "preview": "vite preview" + }, + "dependencies": { + "@bitbybit-dev/babylonjs": "0.21.0" + }, + "devDependencies": { + "typescript": "~5.8.3", + "vite": "^6.3.2", + "@types/three": "0.182.0" + } +} diff --git a/examples/vite/babylonjs/starter-template-full/public/vite.svg b/examples/vite/babylonjs/starter-template-full/public/vite.svg new file mode 100644 index 00000000..e7b8dfb1 --- /dev/null +++ b/examples/vite/babylonjs/starter-template-full/public/vite.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/examples/vite/babylonjs/starter-template-full/src/main.ts b/examples/vite/babylonjs/starter-template-full/src/main.ts new file mode 100644 index 00000000..41aa4e5a --- /dev/null +++ b/examples/vite/babylonjs/starter-template-full/src/main.ts @@ -0,0 +1,499 @@ +import "./style.css"; +import { BitByBitBase, Inputs, initBitByBit, initBabylonJS, type InitBitByBitOptions } from "@bitbybit-dev/babylonjs"; + +start(); + +async function start() { + const babylonOptions = new Inputs.BabylonJSScene.InitBabylonJSDto(); + babylonOptions.canvasId = "babylon-canvas"; + babylonOptions.sceneSize = 200; + babylonOptions.enableShadows = true; + babylonOptions.enableGround = true; + babylonOptions.groundColor = "#333333"; + babylonOptions.groundCenter = [0, -75, 0]; + + const { scene, engine } = initBabylonJS(babylonOptions); + const bitbybit = new BitByBitBase(); + const options: InitBitByBitOptions = { + enableOCCT: true, + enableJSCAD: true, + enableManifold: true, + }; + + await initBitByBit(scene, bitbybit, options); + + if (options.enableOCCT) { + await createOCCTGeometry(bitbybit, "#ff0000"); // Red + } + if (options.enableManifold) { + await createManifoldGeometry(bitbybit, "#00ff00"); // Green + } + if (options.enableJSCAD) { + await createJSCADGeometry(bitbybit, "#0000ff"); // Blue + } + + await createDrawingExamples(bitbybit); + + if (options.enableOCCT) { + await createTexturedOCCTCube(bitbybit); + } + + engine.runRenderLoop(() => { + if (scene.activeCamera) { + scene.render(); + } + }); +} + +async function createOCCTGeometry(bitbybit: BitByBitBase, color: string) { + const cubeOptions = new Inputs.OCCT.CubeDto(); + cubeOptions.size = 25; + cubeOptions.center = [0, 0, 0]; + + const cube = await bitbybit.occt.shapes.solid.createCube(cubeOptions); + + const filletOptions = + new Inputs.OCCT.FilletDto(); + filletOptions.shape = cube; + filletOptions.radius = 4; + const roundedCube = await bitbybit.occt.fillets.filletEdges(filletOptions); + + const drawOptions = new Inputs.Draw.DrawOcctShapeOptions(); + drawOptions.faceColour = color; // Bitbybit handles color conversion + drawOptions.edgeWidth = 10; + drawOptions.drawVertices = true; + drawOptions.vertexSize = 0.5; + drawOptions.vertexColour = "#ffffff"; + await bitbybit.draw.drawAnyAsync({ + entity: roundedCube, + options: drawOptions, + }); +} + +async function createManifoldGeometry(bitbybit: BitByBitBase, color: string) { + const sphereOptions = new Inputs.Manifold.SphereDto(); + sphereOptions.radius = 15; + const sphere = await bitbybit.manifold.manifold.shapes.sphere(sphereOptions); + + const cubeOptions = new Inputs.Manifold.CubeDto(); + cubeOptions.size = 25; + const cube = await bitbybit.manifold.manifold.shapes.cube(cubeOptions); + + const diffedShape = await bitbybit.manifold.manifold.booleans.differenceTwo({ + manifold1: cube, + manifold2: sphere, + }); + + const translationOptions = + new Inputs.Manifold.TranslateDto(); + translationOptions.manifold = diffedShape; + translationOptions.vector = [0, -40, 0]; // Position below OCCT + const movedShape = await bitbybit.manifold.manifold.transforms.translate( + translationOptions + ); + + const drawOptions = new Inputs.Draw.DrawManifoldOrCrossSectionOptions(); + drawOptions.faceColour = color; + await bitbybit.draw.drawAnyAsync({ + entity: movedShape, + options: drawOptions, + }); +} + +async function createJSCADGeometry(bitbybit: BitByBitBase, color: string) { + const geodesicSphereOptions = new Inputs.JSCAD.GeodesicSphereDto(); + geodesicSphereOptions.radius = 15; + geodesicSphereOptions.center = [0, 40, 0]; // Position above OCCT + const geodesicSphere = await bitbybit.jscad.shapes.geodesicSphere( + geodesicSphereOptions + ); + + const sphereOptions = new Inputs.JSCAD.SphereDto(); + sphereOptions.radius = 10; + sphereOptions.center = [5, 45, 0]; + const simpleSphere = await bitbybit.jscad.shapes.sphere(sphereOptions); + + const unionOptions = new Inputs.JSCAD.BooleanTwoObjectsDto(); + unionOptions.first = geodesicSphere; + unionOptions.second = simpleSphere; + const unionShape = await bitbybit.jscad.booleans.unionTwo(unionOptions); + + const drawOptions = new Inputs.Draw.DrawBasicGeometryOptions(); + drawOptions.colours = color; // Note: 'colours' for JSCAD draw options + await bitbybit.draw.drawAnyAsync({ + entity: unionShape, + options: drawOptions, + }); +} + +async function createTexturedOCCTCube(bitbybit: BitByBitBase) { + const textureOptions = new Inputs.Draw.GenericTextureDto(); + textureOptions.url = "https://cdn.polyhaven.com/asset_img/primary/worn_asphalt.png?height=760&quality=95"; + textureOptions.uScale = 0.05; + textureOptions.vScale = 0.05; + const texture = await bitbybit.draw.createTexture(textureOptions); + + const materialOptions = new Inputs.Draw.GenericPBRMaterialDto(); + materialOptions.baseColorTexture = texture; + materialOptions.baseColor = "#ffffff"; // White to show texture colors accurately + const material = await bitbybit.draw.createPBRMaterial(materialOptions); + + const cubeOptions = new Inputs.OCCT.CubeDto(); + cubeOptions.size = 20; + cubeOptions.center = [-50, 0, -50]; + const cube = await bitbybit.occt.shapes.solid.createCube(cubeOptions); + + const drawOptions = new Inputs.Draw.DrawOcctShapeOptions(); + drawOptions.faceMaterial = material; + drawOptions.backFaceOpacity = 1; + drawOptions.edgeWidth = 10; + await bitbybit.draw.drawAnyAsync({ + entity: cube, + options: drawOptions, + }); +} + +async function createDrawingExamples(bitbybit: BitByBitBase) { + const point = [60, 0, 0] as Inputs.Base.Point3; + const pointDrawOptions = new Inputs.Draw.DrawBasicGeometryOptions(); + pointDrawOptions.colours = "#ffff00"; // Yellow + pointDrawOptions.size = 2; + await bitbybit.draw.drawAnyAsync({ + entity: point, + options: pointDrawOptions, + }); + console.log("Single point drawn."); + const points = [ + [60, 5, 0], + [60, 10, 0], + [60, 15, 0], + [60, 20, 0], + [60, 25, 0], + [60, 30, 0], + [60, 35, 0], + ] as Inputs.Base.Point3[]; + const pointsDrawOptions = new Inputs.Draw.DrawBasicGeometryOptions(); + pointsDrawOptions.colours = ["#ff00ff", "#ff0000", "#00ff00", "#0000ff"]; // Magenta + pointsDrawOptions.size = 1.5; + pointsDrawOptions.colorMapStrategy = Inputs.Base.colorMapStrategyEnum.repeatColors; + await bitbybit.draw.drawAnyAsync({ + entity: points, + options: pointsDrawOptions, + }); + + const polyline = { + points: [ + [70, -10, 0], + [70, 0, 10], + [80, 0, 10], + [80, -10, 0], + ], + } as Inputs.Base.Polyline3; + const polylineDrawOptions = new Inputs.Draw.DrawBasicGeometryOptions(); + polylineDrawOptions.colours = "#00ffff"; // Cyan + polylineDrawOptions.size = 10; + await bitbybit.draw.drawAnyAsync({ + entity: polyline, + options: polylineDrawOptions, + }); + + const polylines = [ + { + points: [ + [90, -10, 0], + [90, 0, 0], + [100, 0, 0], + ], + }, + { + points: [ + [90, -10, 5], + [90, 0, 5], + [100, 0, 5], + ], + }, + { + points: [ + [90, -10, 10], + [90, 0, 10], + [100, 0, 10], + ], + }, + ]; + const polylinesDrawOptions = new Inputs.Draw.DrawBasicGeometryOptions(); + polylinesDrawOptions.colours = ["#ff0000", "#00ff00", "#0000ff"]; // RGB + polylinesDrawOptions.size = 10; + await bitbybit.draw.drawAnyAsync({ + entity: polylines as Inputs.Base.Polyline3[], + options: polylinesDrawOptions, + }); + + const segments = [ + { + points: [ + [60, -20, 0], + [70, -20, 0], + ], + }, + { + points: [ + [65, -25, 0], + [65, -15, 0], + ], + }, + { + points: [ + [60, -20, -5], + [70, -20, 5], + ], + }, + ]; + const segmentsDrawOptions = new Inputs.Draw.DrawBasicGeometryOptions(); + segmentsDrawOptions.colours = ["#ffff00", "#ff00ff", "#00ffff"]; // Yellow, Magenta, Cyan + segmentsDrawOptions.size = 10; + await bitbybit.draw.drawAnyAsync({ + entity: segments as Inputs.Base.Polyline3[], + options: segmentsDrawOptions, + }); + + const controlPoints = [ + [-60, -10, 0], + [-50, 0, 5], + [-40, -5, 10], + [-30, 10, 5], + [-20, 0, 0], + ] as Inputs.Base.Point3[]; + + const curve = bitbybit.verb.curve.createCurveByPoints({ + points: controlPoints, + degree: 3, + }); + + const curveDrawOptions = new Inputs.Draw.DrawBasicGeometryOptions(); + curveDrawOptions.colours = "#ff8800"; // Orange + curveDrawOptions.size = 10; + await bitbybit.draw.drawAnyAsync({ + entity: curve, + options: curveDrawOptions, + }); + + const curve1Points = [ + [-60, 20, -5], + [-50, 20, 0], + [-40, 20, -5], + ] as Inputs.Base.Point3[]; + + const curve2Points = [ + [-60, 30, 0], + [-50, 30, 5], + [-40, 30, 0], + ] as Inputs.Base.Point3[]; + + const curve3Points = [ + [-60, 40, -5], + [-50, 40, 0], + [-40, 40, -5], + ] as Inputs.Base.Point3[]; + + const curve1 = bitbybit.verb.curve.createCurveByPoints({ + points: curve1Points, + degree: 2, + }); + const curve2 = bitbybit.verb.curve.createCurveByPoints({ + points: curve2Points, + degree: 2, + }); + const curve3 = bitbybit.verb.curve.createCurveByPoints({ + points: curve3Points, + degree: 2, + }); + + const surface = bitbybit.verb.surface.createSurfaceByLoftingCurves({ + curves: [curve3, curve2, curve1], + degreeV: 2, + }); + + const surfaceDrawOptions = new Inputs.Draw.DrawBasicGeometryOptions(); + surfaceDrawOptions.colours = "#8800ff"; // Purple + surfaceDrawOptions.opacity = 0.8; + await bitbybit.draw.drawAnyAsync({ + entity: surface, + options: surfaceDrawOptions, + }); + + const gridSize = 30; + const spacing = 1.5; + const gridOffset = [-150, 0, 0]; + + const gridPoints: Inputs.Base.Point3[] = []; + const gridColors: string[] = []; + + for (let x = 0; x < gridSize; x++) { + for (let y = 0; y < gridSize; y++) { + for (let z = 0; z < gridSize; z++) { + gridPoints.push([ + gridOffset[0] + x * spacing, + gridOffset[1] + y * spacing, + gridOffset[2] + z * spacing + ]); + const isBlue = (x + y + z) % 2 === 0; + gridColors.push(isBlue ? "#0066ff" : "#ffffff"); + } + } + } + + const gridDrawOptions = new Inputs.Draw.DrawBasicGeometryOptions(); + gridDrawOptions.colours = gridColors; + gridDrawOptions.size = 0.4; + gridDrawOptions.colorMapStrategy = Inputs.Base.colorMapStrategyEnum.lastColorRemainder; + + console.time("Draw 27,000 points"); + await bitbybit.draw.drawAnyAsync({ + entity: gridPoints, + options: gridDrawOptions, + }); + + const polylineGridSize = 30; + const polylineSpacing = 1.5; + const polylineGridOffset = [-150, -60, 0]; + + const gridPolylines: Inputs.Base.Polyline3[] = []; + const polylineColors: string[] = []; + + for (let y = 0; y < polylineGridSize; y++) { + for (let z = 0; z < polylineGridSize; z++) { + const startX = polylineGridOffset[0]; + const endX = polylineGridOffset[0] + (polylineGridSize - 1) * polylineSpacing; + const posY = polylineGridOffset[1] + y * polylineSpacing; + const posZ = polylineGridOffset[2] + z * polylineSpacing; + + gridPolylines.push({ + points: [ + [startX, posY, posZ], + [endX, posY, posZ] + ] + }); + const isOrange = (y + z) % 2 === 0; + polylineColors.push(isOrange ? "#ff6600" : "#00ffcc"); + } + } + + for (let x = 0; x < polylineGridSize; x++) { + for (let z = 0; z < polylineGridSize; z++) { + const posX = polylineGridOffset[0] + x * polylineSpacing; + const startY = polylineGridOffset[1]; + const endY = polylineGridOffset[1] + (polylineGridSize - 1) * polylineSpacing; + const posZ = polylineGridOffset[2] + z * polylineSpacing; + + gridPolylines.push({ + points: [ + [posX, startY, posZ], + [posX, endY, posZ] + ] + }); + const isPurple = (x + z) % 2 === 0; + polylineColors.push(isPurple ? "#9933ff" : "#ffff00"); + } + } + + for (let x = 0; x < polylineGridSize; x++) { + for (let y = 0; y < polylineGridSize; y++) { + const posX = polylineGridOffset[0] + x * polylineSpacing; + const posY = polylineGridOffset[1] + y * polylineSpacing; + const startZ = polylineGridOffset[2]; + const endZ = polylineGridOffset[2] + (polylineGridSize - 1) * polylineSpacing; + + gridPolylines.push({ + points: [ + [posX, posY, startZ], + [posX, posY, endZ] + ] + }); + const isPink = (x + y) % 2 === 0; + polylineColors.push(isPink ? "#ff0099" : "#00ff66"); + } + } + + const polylineGridDrawOptions = new Inputs.Draw.DrawBasicGeometryOptions(); + polylineGridDrawOptions.colours = polylineColors; + polylineGridDrawOptions.size = 3; + polylineGridDrawOptions.colorMapStrategy = Inputs.Base.colorMapStrategyEnum.lastColorRemainder; + + await bitbybit.draw.drawAnyAsync({ + entity: gridPolylines, + options: polylineGridDrawOptions, + }); + + const arrowPolyline = { + points: [ + [-80, 0, 0], + [-80, 10, 5], + [-70, 15, 10], + [-60, 10, 5], + ], + } as Inputs.Base.Polyline3; + const arrowPolylineOptions = new Inputs.Draw.DrawBasicGeometryOptions(); + arrowPolylineOptions.colours = "#00ff88"; + arrowPolylineOptions.size = 10; + arrowPolylineOptions.arrowSize = 3; + arrowPolylineOptions.arrowAngle = 25; + await bitbybit.draw.drawAnyAsync({ + entity: arrowPolyline, + options: arrowPolylineOptions, + }); + + const arrowPolylines = [ + { + points: [ + [-80, -30, 0], + [-70, -25, 0], + [-60, -30, 0], + ], + }, + { + points: [ + [-80, -35, 0], + [-70, -30, 0], + [-60, -35, 0], + ], + }, + { + points: [ + [-80, -40, 0], + [-70, -35, 0], + [-60, -40, 0], + ], + }, + ] as Inputs.Base.Polyline3[]; + const arrowPolylinesOptions = new Inputs.Draw.DrawBasicGeometryOptions(); + arrowPolylinesOptions.colours = ["#ff0000", "#00ff00", "#0000ff"]; // RGB + arrowPolylinesOptions.size = 8; + arrowPolylinesOptions.arrowSize = 2.5; + arrowPolylinesOptions.arrowAngle = 30; + await bitbybit.draw.drawAnyAsync({ + entity: arrowPolylines, + options: arrowPolylinesOptions, + }); + console.log("Multiple polylines with arrows drawn."); + + const wirePoints = [ + [-80, -60, 0], + [-70, -55, 5], + [-60, -60, 0], + [-50, -65, -5], + ] as Inputs.Base.Point3[]; + const wire = await bitbybit.occt.shapes.wire.createPolylineWire({ + points: wirePoints, + }); + const wireDrawOptions = new Inputs.Draw.DrawOcctShapeOptions(); + wireDrawOptions.edgeColour = "#ff8800"; + wireDrawOptions.edgeWidth = 10; + wireDrawOptions.drawEdges = true; + wireDrawOptions.drawFaces = false; + wireDrawOptions.edgeArrowSize = 3; + wireDrawOptions.edgeArrowAngle = 25; + await bitbybit.draw.drawAnyAsync({ + entity: wire, + options: wireDrawOptions, + }); +} diff --git a/examples/vite/babylonjs/starter-template-full/src/style.css b/examples/vite/babylonjs/starter-template-full/src/style.css new file mode 100644 index 00000000..681677f6 --- /dev/null +++ b/examples/vite/babylonjs/starter-template-full/src/style.css @@ -0,0 +1,31 @@ +body { + margin: 0px; + overflow: hidden; +} + +#babylon-canvas { + outline: none; + width: 100%; + height: 100vh; +} + +a.logo { + position: absolute; + color: white; + vertical-align: middle; + bottom: 10px; + left: 10px; + font-family: 'Courier New', Courier, monospace; + text-decoration: none; + width: 100%; +} + +.logo { + margin-bottom: 20px; + text-align: center; +} + +.logo img { + width: 50px; + height: 50px; +} diff --git a/examples/vite/babylonjs/starter-template-full/src/vite-env.d.ts b/examples/vite/babylonjs/starter-template-full/src/vite-env.d.ts new file mode 100644 index 00000000..11f02fe2 --- /dev/null +++ b/examples/vite/babylonjs/starter-template-full/src/vite-env.d.ts @@ -0,0 +1 @@ +/// diff --git a/examples/vite/babylonjs/starter-template-full/tsconfig.json b/examples/vite/babylonjs/starter-template-full/tsconfig.json new file mode 100644 index 00000000..a22caba9 --- /dev/null +++ b/examples/vite/babylonjs/starter-template-full/tsconfig.json @@ -0,0 +1,25 @@ +{ + "compilerOptions": { + "target": "ES2020", + "useDefineForClassFields": true, + "module": "ESNext", + "lib": ["ES2020", "DOM", "DOM.Iterable"], + "skipLibCheck": true, + + /* Bundler mode */ + "moduleResolution": "bundler", + "allowImportingTsExtensions": true, + "verbatimModuleSyntax": true, + "moduleDetection": "force", + "noEmit": true, + + /* Linting */ + "strict": true, + "noUnusedLocals": true, + "noUnusedParameters": true, + "erasableSyntaxOnly": true, + "noFallthroughCasesInSwitch": true, + "noUncheckedSideEffectImports": true + }, + "include": ["src"] +} diff --git a/examples/vite/babylonjs/starter-template/src/main.ts b/examples/vite/babylonjs/starter-template/src/main.ts index 218cc848..6f7e1c49 100644 --- a/examples/vite/babylonjs/starter-template/src/main.ts +++ b/examples/vite/babylonjs/starter-template/src/main.ts @@ -1,283 +1,76 @@ -import "./style.css"; // Basic styling -import { BitByBitBase, Inputs } from "@bitbybit-dev/babylonjs"; -import { OccStateEnum } from "@bitbybit-dev/occt-worker"; -import { JscadStateEnum } from "@bitbybit-dev/jscad-worker"; -import { ManifoldStateEnum } from "@bitbybit-dev/manifold-worker"; +import "./style.css"; +import { BitByBitBase, Inputs, initBitByBit, initBabylonJS, type InitBitByBitOptions } from "@bitbybit-dev/babylonjs"; -import { - Engine, - Scene, - ArcRotateCamera, - Vector3, - HemisphericLight, - DirectionalLight, - Color4, -} from "@babylonjs/core"; -import { first, firstValueFrom, map } from "rxjs"; - -// Define an interface for kernel options -interface KernelOptions { - enableOCCT: boolean; - enableJSCAD: boolean; - enableManifold: boolean; -} - -// --- 1. Main Application Entry Point --- start(); async function start() { - // Initialize basic Babylon.js scene - const { scene, engine } = initBabylonJS(); - // Create an instance of BitByBitBase for Babylon.js + const sceneOptions = new Inputs.BabylonJSScene.InitBabylonJSDto(); + sceneOptions.canvasId = "babylon-canvas"; + sceneOptions.sceneSize = 10; + sceneOptions.enableShadows = true; + sceneOptions.enableGround = true; + sceneOptions.groundColor = "#333333"; + + const { scene, engine } = initBabylonJS(sceneOptions); const bitbybit = new BitByBitBase(); - - // --- 2. Configure and Initialize Kernels --- - // Users can control which kernels are loaded - const kernelOptions: KernelOptions = { + const options: InitBitByBitOptions = { enableOCCT: true, enableJSCAD: true, enableManifold: true, }; - // Initialize Bitbybit with the selected kernels - await initWithKernels(scene, bitbybit, kernelOptions); - - // --- 3. Create Geometry with Active Kernels --- - if (kernelOptions.enableOCCT) { - await createOCCTGeometry(bitbybit, "#ff0000"); // Red - } - if (kernelOptions.enableManifold) { - await createManifoldGeometry(bitbybit, "#00ff00"); // Green - } - if (kernelOptions.enableJSCAD) { - await createJSCADGeometry(bitbybit, "#0000ff"); // Blue - } - // --- 4. Create Drawing Examples (Lines, Points, Curves, etc.) --- - await createDrawingExamples(bitbybit); - - // --- 5. Create Textured OCCT Cube Example --- - if (kernelOptions.enableOCCT) { - await createTexturedOCCTCube(bitbybit); - } - - // Start the Babylon.js render loop - engine.runRenderLoop(() => { - if (scene.activeCamera) { - // Ensure camera is ready - scene.render(); - } - }); -} + await initBitByBit(scene, bitbybit, options); -// --- 4. Babylon.js Scene Initialization --- -function initBabylonJS() { - const canvas = document.getElementById("babylon-canvas") as HTMLCanvasElement; - const engine = new Engine(canvas, true, { - preserveDrawingBuffer: true, - stencil: true, - }); - const scene = new Scene(engine); - scene.metadata = { shadowGenerators: [] }; // Important for Bitbybit till we have better implementation... - scene.clearColor = new Color4(0.1, 0.11, 0.12, 1); // Set background color - - const camera = new ArcRotateCamera( - "camera", - -Math.PI / 2, - Math.PI / 2.5, - 150, // Adjusted radius for typical scenes - new Vector3(0, 0, 0), - scene - ); - camera.attachControl(canvas, true); - camera.wheelPrecision = 5; // Control zoom speed - camera.zoomOnFactor = 1.2; - camera.angularSensibilityX = 1000; - camera.angularSensibilityY = 1000; - camera.panningSensibility = 100; - camera.lowerRadiusLimit = 10; - camera.upperRadiusLimit = 500; - - const light = new HemisphericLight("light", new Vector3(0, 1, 0), scene); - light.intensity = 0.7; - - // Add a directional light for better shadows and lighting - const directionalLight = new DirectionalLight( - "directionalLight", - new Vector3(-1, -2, -1), - scene - ); - directionalLight.intensity = 1; - - const onWindowResize = () => { - engine.resize(); - }; - window.addEventListener("resize", onWindowResize, false); - - return { scene, engine, camera }; -} - -// --- 5. Bitbybit Kernel Initialization Logic --- -async function initWithKernels( - scene: Scene, - bitbybit: BitByBitBase, - options: KernelOptions -): Promise<{ message: string; initializedKernels: string[] }> { - let occtWorkerInstance: Worker | undefined; - let jscadWorkerInstance: Worker | undefined; - let manifoldWorkerInstance: Worker | undefined; - - // 1. Conditionally create worker instances if (options.enableOCCT) { - occtWorkerInstance = new Worker( - new URL("./workers/occt.worker.ts", import.meta.url), - { name: "OCC_WORKER", type: "module" } - ); - } - if (options.enableJSCAD) { - jscadWorkerInstance = new Worker( - new URL("./workers/jscad.worker.ts", import.meta.url), - { name: "JSCAD_WORKER", type: "module" } - ); + await createOCCTGeometry(bitbybit, "#ff0000"); } if (options.enableManifold) { - manifoldWorkerInstance = new Worker( - new URL("./workers/manifold.worker.ts", import.meta.url), - { name: "MANIFOLD_WORKER", type: "module" } - ); - } - - // 2. Initialize Bitbybit - await bitbybit.init( - scene, - occtWorkerInstance, - jscadWorkerInstance, - manifoldWorkerInstance - ); - - // 3. Collect promises for kernel initializations - const initializationPromises: Promise[] = []; - let anyKernelSelectedForInit = false; - - if (options.enableOCCT) { - anyKernelSelectedForInit = true; - if (bitbybit.occtWorkerManager) { - initializationPromises.push( - firstValueFrom( - bitbybit.occtWorkerManager.occWorkerState$.pipe( - first((s) => s.state === OccStateEnum.initialised), - map(() => "OCCT") - ) - ) - ); - } else { - console.warn( - "OCCT enabled in options, but occtWorkerManager not found after init." - ); - } + await createManifoldGeometry(bitbybit, "#00ff00"); } - if (options.enableJSCAD) { - anyKernelSelectedForInit = true; - if (bitbybit.jscadWorkerManager) { - initializationPromises.push( - firstValueFrom( - bitbybit.jscadWorkerManager.jscadWorkerState$.pipe( - first((s) => s.state === JscadStateEnum.initialised), - map(() => "JSCAD") - ) - ) - ); - } else { - console.warn( - "JSCAD enabled in options, but jscadWorkerManager not found after init." - ); - } + await createJSCADGeometry(bitbybit, "#0000ff"); } - if (options.enableManifold) { - anyKernelSelectedForInit = true; - if (bitbybit.manifoldWorkerManager && bitbybit.manifoldWorkerManager.manifoldWorkerState$) { - initializationPromises.push( - firstValueFrom( - bitbybit.manifoldWorkerManager.manifoldWorkerState$.pipe( - first((s) => s.state === ManifoldStateEnum.initialised), - map(() => "Manifold") - ) - ) - ); - } else { - console.warn( - "Manifold enabled in options, but manifoldWorkerManager not found after init." - ); + engine.runRenderLoop(() => { + if (scene.activeCamera) { + scene.render(); } - } - - // 4. Wait for selected & available kernels or handle no selection/availability - if (!anyKernelSelectedForInit) { - console.log("No kernels selected for initialization."); - return { message: "No kernels selected for initialization.", initializedKernels: [] }; - } - - if (initializationPromises.length === 0) { - // Kernels were selected, but none were awaitable (e.g., managers missing for all selected) - console.log( - "Kernels were selected, but none had managers available for awaiting initialization." - ); - return { - message: "Selected kernels were not awaitable for initialization state.", - initializedKernels: [], - }; - } - - const initializedKernels = await Promise.all(initializationPromises); - console.log("Kernels initialized:", initializedKernels.join(", ")); - return { - message: `Successfully initialized: ${initializedKernels.join(", ")}`, - initializedKernels, - }; + }); } -// --- 6. Geometry Creation Functions (Examples) --- -// These functions are largely the same as the Three.js version, -// as Bitbybit's core geometry API is engine-agnostic. -// The drawing options might differ slightly if very specific engine features are used, -// but for basic drawing, drawAnyAsync handles it. - async function createOCCTGeometry(bitbybit: BitByBitBase, color: string) { - console.log("Creating OCCT geometry..."); const cubeOptions = new Inputs.OCCT.CubeDto(); - cubeOptions.size = 25; - cubeOptions.center = [0, 0, 0]; + cubeOptions.size = 2.5; + cubeOptions.center = [0, 1.25, 0]; const cube = await bitbybit.occt.shapes.solid.createCube(cubeOptions); const filletOptions = new Inputs.OCCT.FilletDto(); filletOptions.shape = cube; - filletOptions.radius = 4; + filletOptions.radius = 0.4; const roundedCube = await bitbybit.occt.fillets.filletEdges(filletOptions); const drawOptions = new Inputs.Draw.DrawOcctShapeOptions(); - drawOptions.faceColour = color; // Bitbybit handles color conversion - drawOptions.edgeWidth = 10; + drawOptions.edgeWidth = 0.5; + drawOptions.faceColour = color; drawOptions.drawVertices = true; - drawOptions.vertexSize = 0.5; + drawOptions.vertexSize = 0.05; drawOptions.vertexColour = "#ffffff"; await bitbybit.draw.drawAnyAsync({ entity: roundedCube, options: drawOptions, }); - console.log("OCCT geometry created and drawn."); } async function createManifoldGeometry(bitbybit: BitByBitBase, color: string) { - console.log("Creating Manifold geometry..."); const sphereOptions = new Inputs.Manifold.SphereDto(); - sphereOptions.radius = 15; + sphereOptions.radius = 1.5; + sphereOptions.circularSegments = 32; const sphere = await bitbybit.manifold.manifold.shapes.sphere(sphereOptions); const cubeOptions = new Inputs.Manifold.CubeDto(); - cubeOptions.size = 25; + cubeOptions.size = 2.5; const cube = await bitbybit.manifold.manifold.shapes.cube(cubeOptions); const diffedShape = await bitbybit.manifold.manifold.booleans.differenceTwo({ @@ -288,7 +81,7 @@ async function createManifoldGeometry(bitbybit: BitByBitBase, color: string) { const translationOptions = new Inputs.Manifold.TranslateDto(); translationOptions.manifold = diffedShape; - translationOptions.vector = [0, -40, 0]; // Position below OCCT + translationOptions.vector = [0, 1.25, -4]; // Position below OCCT const movedShape = await bitbybit.manifold.manifold.transforms.translate( translationOptions ); @@ -299,21 +92,19 @@ async function createManifoldGeometry(bitbybit: BitByBitBase, color: string) { entity: movedShape, options: drawOptions, }); - console.log("Manifold geometry created and drawn."); } async function createJSCADGeometry(bitbybit: BitByBitBase, color: string) { - console.log("Creating JSCAD geometry..."); const geodesicSphereOptions = new Inputs.JSCAD.GeodesicSphereDto(); - geodesicSphereOptions.radius = 15; - geodesicSphereOptions.center = [0, 40, 0]; // Position above OCCT + geodesicSphereOptions.radius = 1.5; + geodesicSphereOptions.center = [0, 1.5, 4]; const geodesicSphere = await bitbybit.jscad.shapes.geodesicSphere( geodesicSphereOptions ); const sphereOptions = new Inputs.JSCAD.SphereDto(); - sphereOptions.radius = 10; - sphereOptions.center = [5, 45, 0]; + sphereOptions.radius = 1; + sphereOptions.center = [0, 3, 4.5]; const simpleSphere = await bitbybit.jscad.shapes.sphere(sphereOptions); const unionOptions = new Inputs.JSCAD.BooleanTwoObjectsDto(); @@ -322,439 +113,9 @@ async function createJSCADGeometry(bitbybit: BitByBitBase, color: string) { const unionShape = await bitbybit.jscad.booleans.unionTwo(unionOptions); const drawOptions = new Inputs.Draw.DrawBasicGeometryOptions(); - drawOptions.colours = color; // Note: 'colours' for JSCAD draw options + drawOptions.colours = color; await bitbybit.draw.drawAnyAsync({ entity: unionShape, options: drawOptions, }); - console.log("JSCAD geometry created and drawn."); -} - -async function createTexturedOCCTCube(bitbybit: BitByBitBase) { - console.log("Creating textured OCCT cube..."); - - // Create texture from URL - const textureOptions = new Inputs.Draw.GenericTextureDto(); - textureOptions.url = "https://cdn.polyhaven.com/asset_img/primary/worn_asphalt.png?height=760&quality=95"; - textureOptions.uScale = 0.05; - textureOptions.vScale = 0.05; - const texture = await bitbybit.draw.createTexture(textureOptions); - - // Create material with texture - const materialOptions = new Inputs.Draw.GenericPBRMaterialDto(); - materialOptions.baseColorTexture = texture; - materialOptions.baseColor = "#ffffff"; // White to show texture colors accurately - const material = await bitbybit.draw.createPBRMaterial(materialOptions); - - // Create OCCT cube - const cubeOptions = new Inputs.OCCT.CubeDto(); - cubeOptions.size = 20; - cubeOptions.center = [-50, 0, -50]; - const cube = await bitbybit.occt.shapes.solid.createCube(cubeOptions); - - // Draw cube with material - const drawOptions = new Inputs.Draw.DrawOcctShapeOptions(); - drawOptions.faceMaterial = material; - drawOptions.backFaceOpacity = 1; - drawOptions.edgeWidth = 10; - await bitbybit.draw.drawAnyAsync({ - entity: cube, - options: drawOptions, - }); - - console.log("Textured OCCT cube created and drawn."); -} - -// --- 7. Drawing Examples Function --- -async function createDrawingExamples(bitbybit: BitByBitBase) { - console.log("Creating drawing examples..."); - - // Example 1: Draw a single point - const point = [60, 0, 0] as Inputs.Base.Point3; - const pointDrawOptions = new Inputs.Draw.DrawBasicGeometryOptions(); - pointDrawOptions.colours = "#ffff00"; // Yellow - pointDrawOptions.size = 2; - await bitbybit.draw.drawAnyAsync({ - entity: point, - options: pointDrawOptions, - }); - console.log("Single point drawn."); - - // Example 2: Draw multiple points - const points = [ - [60, 5, 0], - [60, 10, 0], - [60, 15, 0], - [60, 20, 0], - [60, 25, 0], - [60, 30, 0], - [60, 35, 0], - ] as Inputs.Base.Point3[]; - const pointsDrawOptions = new Inputs.Draw.DrawBasicGeometryOptions(); - pointsDrawOptions.colours = ["#ff00ff", "#ff0000", "#00ff00", "#0000ff"]; // Magenta - pointsDrawOptions.size = 1.5; - pointsDrawOptions.colorMapStrategy = Inputs.Base.colorMapStrategyEnum.repeatColors; - await bitbybit.draw.drawAnyAsync({ - entity: points, - options: pointsDrawOptions, - }); - console.log("Multiple points drawn."); - - // Example 3: Draw a single polyline - const polyline = { - points: [ - [70, -10, 0], - [70, 0, 10], - [80, 0, 10], - [80, -10, 0], - ], - } as Inputs.Base.Polyline3; - const polylineDrawOptions = new Inputs.Draw.DrawBasicGeometryOptions(); - polylineDrawOptions.colours = "#00ffff"; // Cyan - polylineDrawOptions.size = 10; - await bitbybit.draw.drawAnyAsync({ - entity: polyline, - options: polylineDrawOptions, - }); - console.log("Polyline drawn."); - - // Example 4: Draw multiple polylines with different colors - const polylines = [ - { - points: [ - [90, -10, 0], - [90, 0, 0], - [100, 0, 0], - ], - }, - { - points: [ - [90, -10, 5], - [90, 0, 5], - [100, 0, 5], - ], - }, - { - points: [ - [90, -10, 10], - [90, 0, 10], - [100, 0, 10], - ], - }, - ]; - const polylinesDrawOptions = new Inputs.Draw.DrawBasicGeometryOptions(); - polylinesDrawOptions.colours = ["#ff0000", "#00ff00", "#0000ff"]; // RGB - polylinesDrawOptions.size = 10; - await bitbybit.draw.drawAnyAsync({ - entity: polylines as Inputs.Base.Polyline3[], - options: polylinesDrawOptions, - }); - console.log("Multiple polylines drawn."); - - // Example 5: Draw line segments (polylines with 2 points each) - const segments = [ - { - points: [ - [60, -20, 0], - [70, -20, 0], - ], - }, - { - points: [ - [65, -25, 0], - [65, -15, 0], - ], - }, - { - points: [ - [60, -20, -5], - [70, -20, 5], - ], - }, - ]; - const segmentsDrawOptions = new Inputs.Draw.DrawBasicGeometryOptions(); - segmentsDrawOptions.colours = ["#ffff00", "#ff00ff", "#00ffff"]; // Yellow, Magenta, Cyan - segmentsDrawOptions.size = 10; - await bitbybit.draw.drawAnyAsync({ - entity: segments as Inputs.Base.Polyline3[], - options: segmentsDrawOptions, - }); - console.log("Line segments drawn."); - - // Example 6: Draw a Verb NURBS curve - // Create a simple NURBS curve through control points - const controlPoints = [ - [-60, -10, 0], - [-50, 0, 5], - [-40, -5, 10], - [-30, 10, 5], - [-20, 0, 0], - ] as Inputs.Base.Point3[]; - - // Create a NURBS curve (degree 3) - const curve = bitbybit.verb.curve.createCurveByPoints({ - points: controlPoints, - degree: 3, - }); - - const curveDrawOptions = new Inputs.Draw.DrawBasicGeometryOptions(); - curveDrawOptions.colours = "#ff8800"; // Orange - curveDrawOptions.size = 10; - await bitbybit.draw.drawAnyAsync({ - entity: curve, - options: curveDrawOptions, - }); - console.log("Verb curve drawn."); - - // Example 7: Draw a Verb NURBS surface by lofting curves - // Create curves that will be lofted to form a surface - const curve1Points = [ - [-60, 20, -5], - [-50, 20, 0], - [-40, 20, -5], - ] as Inputs.Base.Point3[]; - - const curve2Points = [ - [-60, 30, 0], - [-50, 30, 5], - [-40, 30, 0], - ] as Inputs.Base.Point3[]; - - const curve3Points = [ - [-60, 40, -5], - [-50, 40, 0], - [-40, 40, -5], - ] as Inputs.Base.Point3[]; - - // Create the curves - const curve1 = bitbybit.verb.curve.createCurveByPoints({ - points: curve1Points, - degree: 2, - }); - - const curve2 = bitbybit.verb.curve.createCurveByPoints({ - points: curve2Points, - degree: 2, - }); - - const curve3 = bitbybit.verb.curve.createCurveByPoints({ - points: curve3Points, - degree: 2, - }); - - // Loft the curves to create a surface - const surface = bitbybit.verb.surface.createSurfaceByLoftingCurves({ - curves: [curve3, curve2, curve1], - degreeV: 2, - }); - - const surfaceDrawOptions = new Inputs.Draw.DrawBasicGeometryOptions(); - surfaceDrawOptions.colours = "#8800ff"; // Purple - surfaceDrawOptions.opacity = 0.8; - await bitbybit.draw.drawAnyAsync({ - entity: surface, - options: surfaceDrawOptions, - }); - console.log("Verb surface drawn."); - - // Example 8: Draw a 30x30x30 grid of points with alternating blue and white colors - // This tests GPU instancing performance with 27,000 points - console.log("Creating 30x30x30 point grid (27,000 points)..."); - const gridSize = 30; - const spacing = 1.5; - const gridOffset = [-150, 0, 0]; // Move grid away from other geometry - - const gridPoints: Inputs.Base.Point3[] = []; - const gridColors: string[] = []; - - for (let x = 0; x < gridSize; x++) { - for (let y = 0; y < gridSize; y++) { - for (let z = 0; z < gridSize; z++) { - gridPoints.push([ - gridOffset[0] + x * spacing, - gridOffset[1] + y * spacing, - gridOffset[2] + z * spacing - ]); - // Alternating blue and white based on checkerboard pattern - const isBlue = (x + y + z) % 2 === 0; - gridColors.push(isBlue ? "#0066ff" : "#ffffff"); - } - } - } - - const gridDrawOptions = new Inputs.Draw.DrawBasicGeometryOptions(); - gridDrawOptions.colours = gridColors; - gridDrawOptions.size = 0.4; - gridDrawOptions.colorMapStrategy = Inputs.Base.colorMapStrategyEnum.lastColorRemainder; - - console.time("Draw 27,000 points"); - await bitbybit.draw.drawAnyAsync({ - entity: gridPoints, - options: gridDrawOptions, - }); - console.timeEnd("Draw 27,000 points"); - console.log("30x30x30 point grid drawn with GPU instancing."); - - // Example 9: Draw a 30x30x30 grid of polylines with alternating colors - // Creates lines along X, Y, and Z axes forming a 3D grid - console.log("Creating 30x30x30 polyline grid..."); - const polylineGridSize = 30; - const polylineSpacing = 1.5; - const polylineGridOffset = [-150, -60, 0]; // Position below the point grid - - const gridPolylines: Inputs.Base.Polyline3[] = []; - const polylineColors: string[] = []; - - // Create lines along X axis (for each Y,Z position) - for (let y = 0; y < polylineGridSize; y++) { - for (let z = 0; z < polylineGridSize; z++) { - const startX = polylineGridOffset[0]; - const endX = polylineGridOffset[0] + (polylineGridSize - 1) * polylineSpacing; - const posY = polylineGridOffset[1] + y * polylineSpacing; - const posZ = polylineGridOffset[2] + z * polylineSpacing; - - gridPolylines.push({ - points: [ - [startX, posY, posZ], - [endX, posY, posZ] - ] - }); - // Alternating colors based on position - const isOrange = (y + z) % 2 === 0; - polylineColors.push(isOrange ? "#ff6600" : "#00ffcc"); - } - } - - // Create lines along Y axis (for each X,Z position) - for (let x = 0; x < polylineGridSize; x++) { - for (let z = 0; z < polylineGridSize; z++) { - const posX = polylineGridOffset[0] + x * polylineSpacing; - const startY = polylineGridOffset[1]; - const endY = polylineGridOffset[1] + (polylineGridSize - 1) * polylineSpacing; - const posZ = polylineGridOffset[2] + z * polylineSpacing; - - gridPolylines.push({ - points: [ - [posX, startY, posZ], - [posX, endY, posZ] - ] - }); - const isPurple = (x + z) % 2 === 0; - polylineColors.push(isPurple ? "#9933ff" : "#ffff00"); - } - } - - // Create lines along Z axis (for each X,Y position) - for (let x = 0; x < polylineGridSize; x++) { - for (let y = 0; y < polylineGridSize; y++) { - const posX = polylineGridOffset[0] + x * polylineSpacing; - const posY = polylineGridOffset[1] + y * polylineSpacing; - const startZ = polylineGridOffset[2]; - const endZ = polylineGridOffset[2] + (polylineGridSize - 1) * polylineSpacing; - - gridPolylines.push({ - points: [ - [posX, posY, startZ], - [posX, posY, endZ] - ] - }); - const isPink = (x + y) % 2 === 0; - polylineColors.push(isPink ? "#ff0099" : "#00ff66"); - } - } - - const polylineGridDrawOptions = new Inputs.Draw.DrawBasicGeometryOptions(); - polylineGridDrawOptions.colours = polylineColors; - polylineGridDrawOptions.size = 3; - polylineGridDrawOptions.colorMapStrategy = Inputs.Base.colorMapStrategyEnum.lastColorRemainder; - - console.log(`Drawing ${gridPolylines.length} polylines...`); - console.time("Draw polyline grid"); - await bitbybit.draw.drawAnyAsync({ - entity: gridPolylines, - options: polylineGridDrawOptions, - }); - console.timeEnd("Draw polyline grid"); - console.log("30x30x30 polyline grid drawn with per-polyline colors."); - - // --- Arrow Examples --- - // Example: Draw a single polyline with an arrow at the end - const arrowPolyline = { - points: [ - [-80, 0, 0], - [-80, 10, 5], - [-70, 15, 10], - [-60, 10, 5], - ], - } as Inputs.Base.Polyline3; - const arrowPolylineOptions = new Inputs.Draw.DrawBasicGeometryOptions(); - arrowPolylineOptions.colours = "#00ff88"; // Green - arrowPolylineOptions.size = 10; - arrowPolylineOptions.arrowSize = 3; // Arrow size - arrowPolylineOptions.arrowAngle = 25; // Arrow angle in degrees - await bitbybit.draw.drawAnyAsync({ - entity: arrowPolyline, - options: arrowPolylineOptions, - }); - console.log("Polyline with arrow drawn."); - - // Example: Draw multiple polylines with arrows (different sizes) - const arrowPolylines = [ - { - points: [ - [-80, -30, 0], - [-70, -25, 0], - [-60, -30, 0], - ], - }, - { - points: [ - [-80, -35, 0], - [-70, -30, 0], - [-60, -35, 0], - ], - }, - { - points: [ - [-80, -40, 0], - [-70, -35, 0], - [-60, -40, 0], - ], - }, - ] as Inputs.Base.Polyline3[]; - const arrowPolylinesOptions = new Inputs.Draw.DrawBasicGeometryOptions(); - arrowPolylinesOptions.colours = ["#ff0000", "#00ff00", "#0000ff"]; // RGB - arrowPolylinesOptions.size = 8; - arrowPolylinesOptions.arrowSize = 2.5; - arrowPolylinesOptions.arrowAngle = 30; - await bitbybit.draw.drawAnyAsync({ - entity: arrowPolylines, - options: arrowPolylinesOptions, - }); - console.log("Multiple polylines with arrows drawn."); - - // Example: Draw OCCT wire with edge arrows to show orientation - const wirePoints = [ - [-80, -60, 0], - [-70, -55, 5], - [-60, -60, 0], - [-50, -65, -5], - ] as Inputs.Base.Point3[]; - const wire = await bitbybit.occt.shapes.wire.createPolylineWire({ - points: wirePoints, - }); - const wireDrawOptions = new Inputs.Draw.DrawOcctShapeOptions(); - wireDrawOptions.edgeColour = "#ff8800"; // Orange edges - wireDrawOptions.edgeWidth = 10; - wireDrawOptions.drawEdges = true; - wireDrawOptions.drawFaces = false; - wireDrawOptions.edgeArrowSize = 3; // Arrow size on edges - wireDrawOptions.edgeArrowAngle = 25; // Arrow angle - await bitbybit.draw.drawAnyAsync({ - entity: wire, - options: wireDrawOptions, - }); - console.log("OCCT wire with edge orientation arrows drawn."); - - console.log("All drawing examples completed."); -} +} \ No newline at end of file diff --git a/examples/vite/babylonjs/starter-template/src/models/current.ts b/examples/vite/babylonjs/starter-template/src/models/current.ts deleted file mode 100644 index acec480e..00000000 --- a/examples/vite/babylonjs/starter-template/src/models/current.ts +++ /dev/null @@ -1,11 +0,0 @@ -import { DirectionalLight, Group, Mesh } from "three"; -import { GUI } from "lil-gui"; - -export type Current = { - group1: Group | undefined; - group2: Group | undefined; - dimensions: Group | undefined; - light1: DirectionalLight | undefined; - ground: Mesh | undefined; - gui: GUI | undefined; -}; diff --git a/examples/vite/babylonjs/starter-template/src/models/model.ts b/examples/vite/babylonjs/starter-template/src/models/model.ts deleted file mode 100644 index 5260fda4..00000000 --- a/examples/vite/babylonjs/starter-template/src/models/model.ts +++ /dev/null @@ -1,24 +0,0 @@ -export type Model = { - uHex: number; - vHex: number; - height: number; - ellipse1MinRad: number; - ellipse1MaxRad: number; - ellipse2MinRad: number; - ellipse2MaxRad: number; - ellipse2RotX: number; - ellipse2RotY: number; - ellipse3MinRad: number; - ellipse3MaxRad: number; - ellipse3YRot: number; - drawEdges: boolean; - drawFaces: boolean; - color1: string; - color2: string; - finalPrecision: number; - rotationEnabled: boolean; - downloadSTL?: () => void; - downloadStep?: () => void; - downloadGLB?: () => void; - update?: () => void; -}; diff --git a/examples/vite/babylonjs/starter-template/src/workers/jscad.worker.ts b/examples/vite/babylonjs/starter-template/src/workers/jscad.worker.ts deleted file mode 100644 index eeed36fd..00000000 --- a/examples/vite/babylonjs/starter-template/src/workers/jscad.worker.ts +++ /dev/null @@ -1,12 +0,0 @@ -import { - initializationComplete, - onMessageInput, -} from "@bitbybit-dev/jscad-worker"; - -import("@bitbybit-dev/jscad/jscad-generated").then((s) => { - initializationComplete(s.default()); -}); - -addEventListener("message", ({ data }) => { - onMessageInput(data, postMessage); -}); diff --git a/examples/vite/babylonjs/starter-template/src/workers/manifold.worker.ts b/examples/vite/babylonjs/starter-template/src/workers/manifold.worker.ts deleted file mode 100644 index 09625fcb..00000000 --- a/examples/vite/babylonjs/starter-template/src/workers/manifold.worker.ts +++ /dev/null @@ -1,21 +0,0 @@ -import { - initializationComplete, - onMessageInput, -} from "@bitbybit-dev/manifold-worker"; -import Module from "manifold-3d"; - -const init = async () => { - const wasm = await Module({ - locateFile: () => { - return "https://cdn.jsdelivr.net/gh/bitbybit-dev/bitbybit-assets@0.21.0/wasm/manifold-3-3-2.wasm"; - }, - }); - wasm.setup(); - initializationComplete(wasm); -}; - -init(); - -addEventListener("message", ({ data }) => { - onMessageInput(data, postMessage); -}); diff --git a/examples/vite/babylonjs/starter-template/src/workers/occt.worker.ts b/examples/vite/babylonjs/starter-template/src/workers/occt.worker.ts deleted file mode 100644 index 492dfd44..00000000 --- a/examples/vite/babylonjs/starter-template/src/workers/occt.worker.ts +++ /dev/null @@ -1,14 +0,0 @@ -import initOpenCascade from "@bitbybit-dev/occt/bitbybit-dev-occt/cdn"; -import type { OpenCascadeInstance } from "@bitbybit-dev/occt/bitbybit-dev-occt/bitbybit-dev-occt.js"; -import { - initializationComplete, - onMessageInput, -} from "@bitbybit-dev/occt-worker"; - -initOpenCascade().then((occ: OpenCascadeInstance) => { - initializationComplete(occ, undefined); -}); - -addEventListener("message", ({ data }) => { - onMessageInput(data, postMessage); -}); diff --git a/examples/vite/playcanvas/starter-template-full/index.html b/examples/vite/playcanvas/starter-template-full/index.html new file mode 100644 index 00000000..d1095645 --- /dev/null +++ b/examples/vite/playcanvas/starter-template-full/index.html @@ -0,0 +1,27 @@ + + + + + + + Bitbybit & PlayCanvas All Kernels Example + + + + + + + diff --git a/examples/vite/playcanvas/starter-template-full/package-lock.json b/examples/vite/playcanvas/starter-template-full/package-lock.json new file mode 100644 index 00000000..e6c47df8 --- /dev/null +++ b/examples/vite/playcanvas/starter-template-full/package-lock.json @@ -0,0 +1,1380 @@ +{ + "name": "vite-playcanvas-starter", + "version": "0.0.0", + "lockfileVersion": 3, + "requires": true, + "packages": { + "": { + "name": "vite-playcanvas-starter", + "version": "0.0.0", + "dependencies": { + "@bitbybit-dev/playcanvas": "0.21.0", + "playcanvas": "2.14.4" + }, + "devDependencies": { + "typescript": "~5.8.3", + "vite": "^6.3.2" + } + }, + "node_modules/@bitbybit-dev/base": { + "version": "0.21.0", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/base/-/base-0.21.0.tgz", + "integrity": "sha512-dNfsf2tu3/QUD1mvZzzTze8RwHyK2Jrt+Ary8EDKdNKMw+abtCpQYNerdrg0ZQPxvwu/OOQz6N1xCsCwsPkQJg==", + "license": "MIT" + }, + "node_modules/@bitbybit-dev/core": { + "version": "0.21.0", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/core/-/core-0.21.0.tgz", + "integrity": "sha512-IbeQ8ROreu0/RkkngUE+Eb19ecvqKOWhGefXvIqQmplxt3zEc0FI4Kw8wR3vYl2XMannuVt1xAIYtqqH0tjBzg==", + "license": "MIT", + "dependencies": { + "@bitbybit-dev/base": "0.21.0", + "@bitbybit-dev/jscad-worker": "0.21.0", + "@bitbybit-dev/manifold-worker": "0.21.0", + "@bitbybit-dev/occt-worker": "0.21.0", + "jsonpath-plus": "10.1.0", + "rxjs": "7.5.5", + "verb-nurbs-web": "2.1.3" + } + }, + "node_modules/@bitbybit-dev/jscad": { + "version": "0.21.0", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/jscad/-/jscad-0.21.0.tgz", + "integrity": "sha512-Q7eE2ILrJRstW4L1711aJZdpwPf1kuhZJqB+KLkkBLsneRsGsh82lBcCbVYAOMuF/q8Lnd4JHxPiIG/m+LYmPQ==", + "license": "MIT", + "dependencies": { + "@bitbybit-dev/base": "0.21.0", + "@jscad/3mf-serializer": "2.1.12", + "@jscad/dxf-serializer": "2.1.18", + "@jscad/io-utils": "2.0.28", + "@jscad/modeling": "2.12.3", + "@jscad/stl-serializer": "2.1.18" + } + }, + "node_modules/@bitbybit-dev/jscad-worker": { + "version": "0.21.0", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/jscad-worker/-/jscad-worker-0.21.0.tgz", + "integrity": "sha512-nIvd7GH5Gg51u6PmFXOADXVYTIvixTkNf0YapS1uix7D2JS9Mx10Z4wHAeRKzvJxUAAbEPPRFNkakE22HFGtLQ==", + "license": "MIT", + "dependencies": { + "@bitbybit-dev/jscad": "0.21.0", + "rxjs": "7.5.5" + } + }, + "node_modules/@bitbybit-dev/manifold": { + "version": "0.21.0", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/manifold/-/manifold-0.21.0.tgz", + "integrity": "sha512-DPpwK9ESB+auDeAbzXcfWRVEzWoMDkpkjc+/uwh+zuSiHSx92PSkzx1/LVTbQCsK+aOfOOy03HQCF5Bu2KQYtw==", + "license": "MIT", + "dependencies": { + "@bitbybit-dev/base": "0.21.0", + "manifold-3d": "3.3.2" + } + }, + "node_modules/@bitbybit-dev/manifold-worker": { + "version": "0.21.0", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/manifold-worker/-/manifold-worker-0.21.0.tgz", + "integrity": "sha512-6Cqv3BP+uI8mHKHI6Jx9TzCxRg1/kMHhCe18+B3KD/rTl9B5mnScCKRBnDansR3bH7aYZGnIw9PmiFnWLkQWEQ==", + "license": "MIT", + "dependencies": { + "@bitbybit-dev/manifold": "0.21.0", + "rxjs": "7.5.5" + } + }, + "node_modules/@bitbybit-dev/occt": { + "version": "0.21.0", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/occt/-/occt-0.21.0.tgz", + "integrity": "sha512-vPu3NmF1kBZMOkOdysolGfFxEEnwdHNGORoX3eWbMWT2JL/Tag5Q2CAc5jwa2VvZnS1nE/9x+DVlFQSo8LQnIg==", + "license": "MIT", + "dependencies": { + "@bitbybit-dev/base": "0.21.0" + } + }, + "node_modules/@bitbybit-dev/occt-worker": { + "version": "0.21.0", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/occt-worker/-/occt-worker-0.21.0.tgz", + "integrity": "sha512-xG1sgo6q/RdVA8AgG72wPe4qxcQlrO1V7/Ksn6MqIhZVTsJcm5RbVYlK+nziIWhvlMc1sKE0GNQFcPdALISLuQ==", + "license": "MIT", + "dependencies": { + "@bitbybit-dev/occt": "0.21.0", + "rxjs": "7.5.5" + } + }, + "node_modules/@bitbybit-dev/playcanvas": { + "version": "0.21.0", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/playcanvas/-/playcanvas-0.21.0.tgz", + "integrity": "sha512-h9n4PAfh+ZUwT71FdDpx1zFOMsMjERL6UB6uY9NQ3bGROwF84RufvmGMxYYPLtkuqk1Es3Yj2LCD4DeV2kyyng==", + "license": "MIT", + "dependencies": { + "@bitbybit-dev/core": "0.21.0", + "playcanvas": "2.14.4" + } + }, + "node_modules/@esbuild/darwin-arm64": { + "version": "0.25.3", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@gltf-transform/core": { + "version": "4.2.1", + "license": "MIT", + "dependencies": { + "property-graph": "^3.0.0" + }, + "funding": { + "url": "https://github.com/sponsors/donmccurdy" + } + }, + "node_modules/@gltf-transform/extensions": { + "version": "4.2.1", + "license": "MIT", + "dependencies": { + "@gltf-transform/core": "^4.2.1", + "ktx-parse": "^1.0.1" + }, + "funding": { + "url": "https://github.com/sponsors/donmccurdy" + } + }, + "node_modules/@gltf-transform/functions": { + "version": "4.2.1", + "license": "MIT", + "dependencies": { + "@gltf-transform/core": "^4.2.1", + "@gltf-transform/extensions": "^4.2.1", + "ktx-parse": "^1.0.1", + "ndarray": "^1.0.19", + "ndarray-lanczos": "^0.3.0", + "ndarray-pixels": "^5.0.1" + }, + "funding": { + "url": "https://github.com/sponsors/donmccurdy" + } + }, + "node_modules/@img/colour": { + "version": "1.0.0", + "license": "MIT", + "engines": { + "node": ">=18" + } + }, + "node_modules/@img/sharp-darwin-arm64": { + "version": "0.34.5", + "cpu": [ + "arm64" + ], + "license": "Apache-2.0", + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": "^18.17.0 || ^20.3.0 || >=21.0.0" + }, + "funding": { + "url": "https://opencollective.com/libvips" + }, + "optionalDependencies": { + "@img/sharp-libvips-darwin-arm64": "1.2.4" + } + }, + "node_modules/@img/sharp-libvips-darwin-arm64": { + "version": "1.2.4", + "cpu": [ + "arm64" + ], + "license": "LGPL-3.0-or-later", + "optional": true, + "os": [ + "darwin" + ], + "funding": { + "url": "https://opencollective.com/libvips" + } + }, + "node_modules/@jridgewell/resolve-uri": { + "version": "3.1.2", + "license": "MIT", + "engines": { + "node": ">=6.0.0" + } + }, + "node_modules/@jridgewell/sourcemap-codec": { + "version": "1.5.5", + "license": "MIT" + }, + "node_modules/@jridgewell/trace-mapping": { + "version": "0.3.31", + "license": "MIT", + "dependencies": { + "@jridgewell/resolve-uri": "^3.1.0", + "@jridgewell/sourcemap-codec": "^1.4.14" + } + }, + "node_modules/@jscad/3mf-serializer": { + "version": "2.1.12", + "resolved": "https://registry.npmjs.org/@jscad/3mf-serializer/-/3mf-serializer-2.1.12.tgz", + "integrity": "sha512-+rxAIKIHCpaplupwwsdXtG1IdimPXFFB45nrjy6gdFHi36bEQW6y/RQD/ngenRiKnYSxu7/M0LatHcjve8z64A==", + "license": "MIT", + "dependencies": { + "@jscad/array-utils": "2.1.4", + "@jscad/modeling": "2.12.3", + "fflate": "0.7.3", + "onml": "1.2.0" + } + }, + "node_modules/@jscad/array-utils": { + "version": "2.1.4", + "resolved": "https://registry.npmjs.org/@jscad/array-utils/-/array-utils-2.1.4.tgz", + "integrity": "sha512-c31r4zSKsE+4Xfwk2V8monDA0hx5G89QGzaakWVUvuGNowYS9WSsYCwHiTIXodjR+HEnDu4okQ7k/whmP0Ne2g==", + "license": "MIT" + }, + "node_modules/@jscad/dxf-serializer": { + "version": "2.1.18", + "resolved": "https://registry.npmjs.org/@jscad/dxf-serializer/-/dxf-serializer-2.1.18.tgz", + "integrity": "sha512-T5Qe2jbEphcWAk7GaOY8PCMD4DPhTm6gWk/MPJCExphhnUwJqcU/1RiMb5hiD+N6hHzmlxD59I8QTjlp9LbLSA==", + "license": "MIT", + "dependencies": { + "@jscad/array-utils": "2.1.4", + "@jscad/modeling": "2.12.3" + } + }, + "node_modules/@jscad/io-utils": { + "version": "2.0.28", + "resolved": "https://registry.npmjs.org/@jscad/io-utils/-/io-utils-2.0.28.tgz", + "integrity": "sha512-spXh37wAgmwjKztoH/HANLgImcqRHX5+H/cRIxPfpqDIWvu7I5bRg2ZTwh25SYlKIzxPk4qX5Nu7Ax5+Kg+QXQ==", + "license": "MIT" + }, + "node_modules/@jscad/modeling": { + "version": "2.12.3", + "resolved": "https://registry.npmjs.org/@jscad/modeling/-/modeling-2.12.3.tgz", + "integrity": "sha512-DnAacXq3zhlYWIixGlFD7RMpgZAMuCaMZNQov0NaoFfs2GaBuTC5eqkqKcEVbhEerBmTllbjjF5IXjJMt9jcOA==", + "license": "MIT" + }, + "node_modules/@jscad/stl-serializer": { + "version": "2.1.18", + "resolved": "https://registry.npmjs.org/@jscad/stl-serializer/-/stl-serializer-2.1.18.tgz", + "integrity": "sha512-pz++TRjHI7jBPnnxQUi4B/uYUG3yCDsKlw8+xL2kumwjb+auc6Ng6Rnr/GqUTkgHrnGut08wg/8AekyWjvBwYg==", + "license": "MIT", + "dependencies": { + "@jscad/array-utils": "2.1.4", + "@jscad/modeling": "2.12.3" + } + }, + "node_modules/@jscadui/3mf-export": { + "version": "0.5.0", + "license": "MIT" + }, + "node_modules/@jsep-plugin/assignment": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/@jsep-plugin/assignment/-/assignment-1.3.0.tgz", + "integrity": "sha512-VVgV+CXrhbMI3aSusQyclHkenWSAm95WaiKrMxRFam3JSUiIaQjoMIw2sEs/OX4XifnqeQUN4DYbJjlA8EfktQ==", + "license": "MIT", + "engines": { + "node": ">= 10.16.0" + }, + "peerDependencies": { + "jsep": "^0.4.0||^1.0.0" + } + }, + "node_modules/@jsep-plugin/regex": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/@jsep-plugin/regex/-/regex-1.0.4.tgz", + "integrity": "sha512-q7qL4Mgjs1vByCaTnDFcBnV9HS7GVPJX5vyVoCgZHNSC9rjwIlmbXG5sUuorR5ndfHAIlJ8pVStxvjXHbNvtUg==", + "license": "MIT", + "engines": { + "node": ">= 10.16.0" + }, + "peerDependencies": { + "jsep": "^0.4.0||^1.0.0" + } + }, + "node_modules/@rollup/rollup-darwin-arm64": { + "version": "4.40.1", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "darwin" + ] + }, + "node_modules/@types/estree": { + "version": "1.0.7", + "dev": true, + "license": "MIT" + }, + "node_modules/@types/ndarray": { + "version": "1.0.14", + "license": "MIT" + }, + "node_modules/@types/webxr": { + "version": "0.5.24", + "resolved": "https://registry.npmjs.org/@types/webxr/-/webxr-0.5.24.tgz", + "integrity": "sha512-h8fgEd/DpoS9CBrjEQXR+dIDraopAEfu4wYVNY2tEPwk60stPWhvZMf4Foo5FakuQ7HFZoa8WceaWFervK2Ovg==", + "license": "MIT" + }, + "node_modules/@webgpu/types": { + "version": "0.1.68", + "resolved": "https://registry.npmjs.org/@webgpu/types/-/types-0.1.68.tgz", + "integrity": "sha512-3ab1B59Ojb6RwjOspYLsTpCzbNB3ZaamIAxBMmvnNkiDoLTZUOBXZ9p5nAYVEkQlDdf6qAZWi1pqj9+ypiqznA==", + "license": "BSD-3-Clause" + }, + "node_modules/base64-js": { + "version": "1.5.1", + "resolved": "https://registry.npmjs.org/base64-js/-/base64-js-1.5.1.tgz", + "integrity": "sha512-AKpaYlHn8t4SVbOHCy+b5+KKgvR4vrsD8vbvrbiQJps7fKDTkjkDry6ji0rUJjC0kzbNePLwzxq8iypo41qeWA==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "license": "MIT", + "optional": true + }, + "node_modules/bindings": { + "version": "1.5.0", + "resolved": "https://registry.npmjs.org/bindings/-/bindings-1.5.0.tgz", + "integrity": "sha512-p2q/t/mhvuOj/UeLlV6566GD/guowlr0hHxClI0W9m7MWYkL1F0hLo+0Aexs9HSPCtR1SXQ0TD3MMKrXZajbiQ==", + "license": "MIT", + "optional": true, + "dependencies": { + "file-uri-to-path": "1.0.0" + } + }, + "node_modules/bl": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/bl/-/bl-4.1.0.tgz", + "integrity": "sha512-1W07cM9gS6DcLperZfFSj+bWLtaPGSOHWhPiGzXmvVJbRLdG82sH/Kn8EtW1VqWVA54AKf2h5k5BbnIbwF3h6w==", + "license": "MIT", + "optional": true, + "dependencies": { + "buffer": "^5.5.0", + "inherits": "^2.0.4", + "readable-stream": "^3.4.0" + } + }, + "node_modules/buffer": { + "version": "5.7.1", + "resolved": "https://registry.npmjs.org/buffer/-/buffer-5.7.1.tgz", + "integrity": "sha512-EHcyIPBQ4BSGlvjB16k5KgAJ27CIsHY/2JBmCRReo48y9rQ3MaUzWX3KVlBa4U7MyX02HdVj0K7C3WaB3ju7FQ==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "license": "MIT", + "optional": true, + "dependencies": { + "base64-js": "^1.3.1", + "ieee754": "^1.1.13" + } + }, + "node_modules/canvas": { + "version": "3.2.0", + "resolved": "https://registry.npmjs.org/canvas/-/canvas-3.2.0.tgz", + "integrity": "sha512-jk0GxrLtUEmW/TmFsk2WghvgHe8B0pxGilqCL21y8lHkPUGa6FTsnCNtHPOzT8O3y+N+m3espawV80bbBlgfTA==", + "hasInstallScript": true, + "license": "MIT", + "optional": true, + "dependencies": { + "node-addon-api": "^7.0.0", + "prebuild-install": "^7.1.3" + }, + "engines": { + "node": "^18.12.0 || >= 20.9.0" + } + }, + "node_modules/chownr": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/chownr/-/chownr-1.1.4.tgz", + "integrity": "sha512-jJ0bqzaylmJtVnNgzTeSOs8DPavpbYgEr/b0YL8/2GO3xJEhInFmhKMUnEJQjZumK7KXGFhUy89PrsJWlakBVg==", + "license": "ISC", + "optional": true + }, + "node_modules/commander": { + "version": "13.1.0", + "license": "MIT", + "engines": { + "node": ">=18" + } + }, + "node_modules/convert-source-map": { + "version": "2.0.0", + "license": "MIT" + }, + "node_modules/core-js": { + "version": "3.47.0", + "hasInstallScript": true, + "license": "MIT", + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/core-js" + } + }, + "node_modules/cwise-compiler": { + "version": "1.1.3", + "license": "MIT", + "dependencies": { + "uniq": "^1.0.0" + } + }, + "node_modules/decompress-response": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/decompress-response/-/decompress-response-6.0.0.tgz", + "integrity": "sha512-aW35yZM6Bb/4oJlZncMH2LCoZtJXTRxES17vE3hoRiowU2kWHaJKFkSBDnDR+cm9J+9QhXmREyIfv0pji9ejCQ==", + "license": "MIT", + "optional": true, + "dependencies": { + "mimic-response": "^3.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/deep-extend": { + "version": "0.6.0", + "resolved": "https://registry.npmjs.org/deep-extend/-/deep-extend-0.6.0.tgz", + "integrity": "sha512-LOHxIOaPYdHlJRtCQfDIVZtfw/ufM8+rVj649RIHzcm/vGwQRXFt6OPqIFWsm2XEMrNIEtWR64sY1LEKD2vAOA==", + "license": "MIT", + "optional": true, + "engines": { + "node": ">=4.0.0" + } + }, + "node_modules/detect-libc": { + "version": "2.1.2", + "license": "Apache-2.0", + "engines": { + "node": ">=8" + } + }, + "node_modules/end-of-stream": { + "version": "1.4.5", + "resolved": "https://registry.npmjs.org/end-of-stream/-/end-of-stream-1.4.5.tgz", + "integrity": "sha512-ooEGc6HP26xXq/N+GCGOT0JKCLDGrq2bQUZrQ7gyrJiZANJ/8YDTxTpQBXGMn+WbIQXNVpyWymm7KYVICQnyOg==", + "license": "MIT", + "optional": true, + "dependencies": { + "once": "^1.4.0" + } + }, + "node_modules/esbuild": { + "version": "0.25.3", + "dev": true, + "hasInstallScript": true, + "license": "MIT", + "bin": { + "esbuild": "bin/esbuild" + }, + "engines": { + "node": ">=18" + }, + "optionalDependencies": { + "@esbuild/aix-ppc64": "0.25.3", + "@esbuild/android-arm": "0.25.3", + "@esbuild/android-arm64": "0.25.3", + "@esbuild/android-x64": "0.25.3", + "@esbuild/darwin-arm64": "0.25.3", + "@esbuild/darwin-x64": "0.25.3", + "@esbuild/freebsd-arm64": "0.25.3", + "@esbuild/freebsd-x64": "0.25.3", + "@esbuild/linux-arm": "0.25.3", + "@esbuild/linux-arm64": "0.25.3", + "@esbuild/linux-ia32": "0.25.3", + "@esbuild/linux-loong64": "0.25.3", + "@esbuild/linux-mips64el": "0.25.3", + "@esbuild/linux-ppc64": "0.25.3", + "@esbuild/linux-riscv64": "0.25.3", + "@esbuild/linux-s390x": "0.25.3", + "@esbuild/linux-x64": "0.25.3", + "@esbuild/netbsd-arm64": "0.25.3", + "@esbuild/netbsd-x64": "0.25.3", + "@esbuild/openbsd-arm64": "0.25.3", + "@esbuild/openbsd-x64": "0.25.3", + "@esbuild/sunos-x64": "0.25.3", + "@esbuild/win32-arm64": "0.25.3", + "@esbuild/win32-ia32": "0.25.3", + "@esbuild/win32-x64": "0.25.3" + } + }, + "node_modules/esbuild-plugin-text-replace": { + "version": "1.3.0", + "license": "bsd-2-clause", + "dependencies": { + "ts-replace-all": "^1.0.0" + }, + "engines": { + "node": ">=10.1.0" + } + }, + "node_modules/esbuild-wasm": { + "version": "0.25.12", + "license": "MIT", + "bin": { + "esbuild": "bin/esbuild" + }, + "engines": { + "node": ">=18" + } + }, + "node_modules/expand-template": { + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/expand-template/-/expand-template-2.0.3.tgz", + "integrity": "sha512-XYfuKMvj4O35f/pOXLObndIRvyQ+/+6AhODh+OKWj9S9498pHHn/IMszH+gt0fBCRWMNfk1ZSp5x3AifmnI2vg==", + "license": "(MIT OR WTFPL)", + "optional": true, + "engines": { + "node": ">=6" + } + }, + "node_modules/fdir": { + "version": "6.4.4", + "dev": true, + "license": "MIT", + "peerDependencies": { + "picomatch": "^3 || ^4" + }, + "peerDependenciesMeta": { + "picomatch": { + "optional": true + } + } + }, + "node_modules/fflate": { + "version": "0.7.3", + "resolved": "https://registry.npmjs.org/fflate/-/fflate-0.7.3.tgz", + "integrity": "sha512-0Zz1jOzJWERhyhsimS54VTqOteCNwRtIlh8isdL0AXLo0g7xNTfTL7oWrkmCnPhZGocKIkWHBistBrrpoNH3aw==", + "license": "MIT" + }, + "node_modules/file-uri-to-path": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/file-uri-to-path/-/file-uri-to-path-1.0.0.tgz", + "integrity": "sha512-0Zt+s3L7Vf1biwWZ29aARiVYLx7iMGnEUl9x33fbB/j3jR81u/O2LbqK+Bm1CDSNDKVtJ/YjwY7TUd5SkeLQLw==", + "license": "MIT", + "optional": true + }, + "node_modules/fs-constants": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/fs-constants/-/fs-constants-1.0.0.tgz", + "integrity": "sha512-y6OAwoSIf7FyjMIv94u+b5rdheZEjzR63GTyZJm5qh4Bi+2YgwLCcI/fPFZkL5PSixOt6ZNKm+w+Hfp/Bciwow==", + "license": "MIT", + "optional": true + }, + "node_modules/fsevents": { + "version": "2.3.3", + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": "^8.16.0 || ^10.6.0 || >=11.0.0" + } + }, + "node_modules/github-from-package": { + "version": "0.0.0", + "resolved": "https://registry.npmjs.org/github-from-package/-/github-from-package-0.0.0.tgz", + "integrity": "sha512-SyHy3T1v2NUXn29OsWdxmK6RwHD+vkj3v8en8AOBZ1wBQ/hCAQ5bAQTD02kW4W9tUp/3Qh6J8r9EvntiyCmOOw==", + "license": "MIT", + "optional": true + }, + "node_modules/ieee754": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/ieee754/-/ieee754-1.2.1.tgz", + "integrity": "sha512-dcyqhDvX1C46lXZcVqCpK+FtMRQVdIMN6/Df5js2zouUsqG7I6sFxitIC+7KYK29KdXOLHdu9zL4sFnoVQnqaA==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "license": "BSD-3-Clause", + "optional": true + }, + "node_modules/inherits": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz", + "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==", + "license": "ISC", + "optional": true + }, + "node_modules/ini": { + "version": "1.3.8", + "resolved": "https://registry.npmjs.org/ini/-/ini-1.3.8.tgz", + "integrity": "sha512-JV/yugV2uzW5iMRSiZAyDtQd+nxtUnjeLt0acNdw98kKLrvuRVyB80tsREOE7yvGVgalhZ6RNXCmEHkUKBKxew==", + "license": "ISC", + "optional": true + }, + "node_modules/iota-array": { + "version": "1.0.0", + "license": "MIT" + }, + "node_modules/is-buffer": { + "version": "1.1.6", + "license": "MIT" + }, + "node_modules/jsep": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/jsep/-/jsep-1.4.0.tgz", + "integrity": "sha512-B7qPcEVE3NVkmSJbaYxvv4cHkVW7DQsZz13pUMrfS8z8Q/BuShN+gcTXrUlPiGqM2/t/EEaI030bpxMqY8gMlw==", + "license": "MIT", + "engines": { + "node": ">= 10.16.0" + } + }, + "node_modules/jsonpath-plus": { + "version": "10.1.0", + "resolved": "https://registry.npmjs.org/jsonpath-plus/-/jsonpath-plus-10.1.0.tgz", + "integrity": "sha512-gHfV1IYqH8uJHYVTs8BJX1XKy2/rR93+f8QQi0xhx95aCiXn1ettYAd5T+7FU6wfqyDoX/wy0pm/fL3jOKJ9Lg==", + "license": "MIT", + "dependencies": { + "@jsep-plugin/assignment": "^1.2.1", + "@jsep-plugin/regex": "^1.0.3", + "jsep": "^1.3.9" + }, + "bin": { + "jsonpath": "bin/jsonpath-cli.js", + "jsonpath-plus": "bin/jsonpath-cli.js" + }, + "engines": { + "node": ">=18.0.0" + } + }, + "node_modules/ktx-parse": { + "version": "1.1.0", + "license": "MIT" + }, + "node_modules/manifold-3d": { + "version": "3.3.2", + "resolved": "https://registry.npmjs.org/manifold-3d/-/manifold-3d-3.3.2.tgz", + "integrity": "sha512-Xx+S7kkbqlZxSPfBKH5yVKDO6k/eW7JRvnG1dKCFO0D4zjifOV5GM18TR0sREDcbKAzglHZ5OoxxpZRkxg6U5A==", + "license": "Apache-2.0", + "dependencies": { + "@gltf-transform/core": "^4.2.0", + "@gltf-transform/extensions": "^4.2.0", + "@gltf-transform/functions": "^4.2.0", + "@jridgewell/trace-mapping": "^0.3.31", + "@jscadui/3mf-export": "^0.5.0", + "commander": "^13.1.0", + "convert-source-map": "^2.0.0", + "esbuild-plugin-text-replace": "^1.3.0", + "esbuild-wasm": "^0.25.11", + "fflate": "^0.8.0" + }, + "bin": { + "manifold-cad": "bin/manifold-cad" + } + }, + "node_modules/manifold-3d/node_modules/fflate": { + "version": "0.8.2", + "resolved": "https://registry.npmjs.org/fflate/-/fflate-0.8.2.tgz", + "integrity": "sha512-cPJU47OaAoCbg0pBvzsgpTPhmhqI5eJjh/JIu8tPj5q+T7iLvW/JAYUqmE7KOB4R1ZyEhzBaIQpQpardBF5z8A==", + "license": "MIT" + }, + "node_modules/mimic-response": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/mimic-response/-/mimic-response-3.1.0.tgz", + "integrity": "sha512-z0yWI+4FDrrweS8Zmt4Ej5HdJmky15+L2e6Wgn3+iK5fWzb6T3fhNFq2+MeTRb064c6Wr4N/wv0DzQTjNzHNGQ==", + "license": "MIT", + "optional": true, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/minimist": { + "version": "1.2.8", + "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.8.tgz", + "integrity": "sha512-2yyAR8qBkN3YuheJanUpWC5U3bb5osDywNB8RzDVlDwDHbocAJveqqj1u8+SVD7jkWT4yvsHCpWqqWqAxb0zCA==", + "license": "MIT", + "optional": true, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/mkdirp-classic": { + "version": "0.5.3", + "resolved": "https://registry.npmjs.org/mkdirp-classic/-/mkdirp-classic-0.5.3.tgz", + "integrity": "sha512-gKLcREMhtuZRwRAfqP3RFW+TK4JqApVBtOIftVgjuABpAtpxhPGaDcfvbhNvD0B8iD1oUr/txX35NjcaY6Ns/A==", + "license": "MIT", + "optional": true + }, + "node_modules/nan": { + "version": "2.24.0", + "resolved": "https://registry.npmjs.org/nan/-/nan-2.24.0.tgz", + "integrity": "sha512-Vpf9qnVW1RaDkoNKFUvfxqAbtI8ncb8OJlqZ9wwpXzWPEsvsB1nvdUi6oYrHIkQ1Y/tMDnr1h4nczS0VB9Xykg==", + "license": "MIT", + "optional": true + }, + "node_modules/nanoid": { + "version": "3.3.11", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/ai" + } + ], + "license": "MIT", + "bin": { + "nanoid": "bin/nanoid.cjs" + }, + "engines": { + "node": "^10 || ^12 || ^13.7 || ^14 || >=15.0.1" + } + }, + "node_modules/napi-build-utils": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/napi-build-utils/-/napi-build-utils-2.0.0.tgz", + "integrity": "sha512-GEbrYkbfF7MoNaoh2iGG84Mnf/WZfB0GdGEsM8wz7Expx/LlWf5U8t9nvJKXSp3qr5IsEbK04cBGhol/KwOsWA==", + "license": "MIT", + "optional": true + }, + "node_modules/ndarray": { + "version": "1.0.19", + "license": "MIT", + "dependencies": { + "iota-array": "^1.0.0", + "is-buffer": "^1.0.2" + } + }, + "node_modules/ndarray-lanczos": { + "version": "0.3.0", + "license": "MIT", + "dependencies": { + "@types/ndarray": "^1.0.11", + "ndarray": "^1.0.19" + } + }, + "node_modules/ndarray-ops": { + "version": "1.2.2", + "license": "MIT", + "dependencies": { + "cwise-compiler": "^1.0.0" + } + }, + "node_modules/ndarray-pixels": { + "version": "5.0.1", + "license": "MIT", + "dependencies": { + "@types/ndarray": "^1.0.14", + "ndarray": "^1.0.19", + "ndarray-ops": "^1.2.2", + "sharp": "^0.34.0" + } + }, + "node_modules/node-abi": { + "version": "3.85.0", + "resolved": "https://registry.npmjs.org/node-abi/-/node-abi-3.85.0.tgz", + "integrity": "sha512-zsFhmbkAzwhTft6nd3VxcG0cvJsT70rL+BIGHWVq5fi6MwGrHwzqKaxXE+Hl2GmnGItnDKPPkO5/LQqjVkIdFg==", + "license": "MIT", + "optional": true, + "dependencies": { + "semver": "^7.3.5" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/node-addon-api": { + "version": "7.1.1", + "resolved": "https://registry.npmjs.org/node-addon-api/-/node-addon-api-7.1.1.tgz", + "integrity": "sha512-5m3bsyrjFWE1xf7nz7YXdN4udnVtXK6/Yfgn5qnahL6bCkf2yKt4k3nuTKAtT4r3IG8JNR2ncsIMdZuAzJjHQQ==", + "license": "MIT", + "optional": true + }, + "node_modules/once": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", + "integrity": "sha512-lNaJgI+2Q5URQBkccEKHTQOPaXdUxnZZElQTZY0MFUAuaEqe1E+Nyvgdz/aIyNi6Z9MzO5dv1H8n58/GELp3+w==", + "license": "ISC", + "optional": true, + "dependencies": { + "wrappy": "1" + } + }, + "node_modules/onml": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/onml/-/onml-1.2.0.tgz", + "integrity": "sha512-olqYAg18XoHAhm7tK9DdBCOVdts70DGmMgCNLOWyqZokht2utgGSKBB4JHi6pBZpmioAhcYlxK+91L3tsrz+GA==", + "license": "MIT", + "dependencies": { + "sax": "^1.2.1" + } + }, + "node_modules/picocolors": { + "version": "1.1.1", + "dev": true, + "license": "ISC" + }, + "node_modules/picomatch": { + "version": "4.0.2", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=12" + }, + "funding": { + "url": "https://github.com/sponsors/jonschlinkert" + } + }, + "node_modules/playcanvas": { + "version": "2.14.4", + "license": "MIT", + "dependencies": { + "@types/webxr": "^0.5.24", + "@webgpu/types": "^0.1.66" + }, + "engines": { + "node": ">=18.0.0" + }, + "optionalDependencies": { + "canvas": "3.2.0" + } + }, + "node_modules/postcss": { + "version": "8.5.3", + "dev": true, + "funding": [ + { + "type": "opencollective", + "url": "https://opencollective.com/postcss/" + }, + { + "type": "tidelift", + "url": "https://tidelift.com/funding/github/npm/postcss" + }, + { + "type": "github", + "url": "https://github.com/sponsors/ai" + } + ], + "license": "MIT", + "dependencies": { + "nanoid": "^3.3.8", + "picocolors": "^1.1.1", + "source-map-js": "^1.2.1" + }, + "engines": { + "node": "^10 || ^12 || >=14" + } + }, + "node_modules/prebuild-install": { + "version": "7.1.3", + "resolved": "https://registry.npmjs.org/prebuild-install/-/prebuild-install-7.1.3.tgz", + "integrity": "sha512-8Mf2cbV7x1cXPUILADGI3wuhfqWvtiLA1iclTDbFRZkgRQS0NqsPZphna9V+HyTEadheuPmjaJMsbzKQFOzLug==", + "license": "MIT", + "optional": true, + "dependencies": { + "detect-libc": "^2.0.0", + "expand-template": "^2.0.3", + "github-from-package": "0.0.0", + "minimist": "^1.2.3", + "mkdirp-classic": "^0.5.3", + "napi-build-utils": "^2.0.0", + "node-abi": "^3.3.0", + "pump": "^3.0.0", + "rc": "^1.2.7", + "simple-get": "^4.0.0", + "tar-fs": "^2.0.0", + "tunnel-agent": "^0.6.0" + }, + "bin": { + "prebuild-install": "bin.js" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/property-graph": { + "version": "3.0.0", + "license": "MIT" + }, + "node_modules/pump": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/pump/-/pump-3.0.3.tgz", + "integrity": "sha512-todwxLMY7/heScKmntwQG8CXVkWUOdYxIvY2s0VWAAMh/nd8SoYiRaKjlr7+iCs984f2P8zvrfWcDDYVb73NfA==", + "license": "MIT", + "optional": true, + "dependencies": { + "end-of-stream": "^1.1.0", + "once": "^1.3.1" + } + }, + "node_modules/rc": { + "version": "1.2.8", + "resolved": "https://registry.npmjs.org/rc/-/rc-1.2.8.tgz", + "integrity": "sha512-y3bGgqKj3QBdxLbLkomlohkvsA8gdAiUQlSBJnBhfn+BPxg4bc62d8TcBW15wavDfgexCgccckhcZvywyQYPOw==", + "license": "(BSD-2-Clause OR MIT OR Apache-2.0)", + "optional": true, + "dependencies": { + "deep-extend": "^0.6.0", + "ini": "~1.3.0", + "minimist": "^1.2.0", + "strip-json-comments": "~2.0.1" + }, + "bin": { + "rc": "cli.js" + } + }, + "node_modules/readable-stream": { + "version": "3.6.2", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-3.6.2.tgz", + "integrity": "sha512-9u/sniCrY3D5WdsERHzHE4G2YCXqoG5FTHUiCC4SIbr6XcLZBY05ya9EKjYek9O5xOAwjGq+1JdGBAS7Q9ScoA==", + "license": "MIT", + "optional": true, + "dependencies": { + "inherits": "^2.0.3", + "string_decoder": "^1.1.1", + "util-deprecate": "^1.0.1" + }, + "engines": { + "node": ">= 6" + } + }, + "node_modules/rollup": { + "version": "4.40.1", + "dev": true, + "license": "MIT", + "dependencies": { + "@types/estree": "1.0.7" + }, + "bin": { + "rollup": "dist/bin/rollup" + }, + "engines": { + "node": ">=18.0.0", + "npm": ">=8.0.0" + }, + "optionalDependencies": { + "@rollup/rollup-android-arm-eabi": "4.40.1", + "@rollup/rollup-android-arm64": "4.40.1", + "@rollup/rollup-darwin-arm64": "4.40.1", + "@rollup/rollup-darwin-x64": "4.40.1", + "@rollup/rollup-freebsd-arm64": "4.40.1", + "@rollup/rollup-freebsd-x64": "4.40.1", + "@rollup/rollup-linux-arm-gnueabihf": "4.40.1", + "@rollup/rollup-linux-arm-musleabihf": "4.40.1", + "@rollup/rollup-linux-arm64-gnu": "4.40.1", + "@rollup/rollup-linux-arm64-musl": "4.40.1", + "@rollup/rollup-linux-loongarch64-gnu": "4.40.1", + "@rollup/rollup-linux-powerpc64le-gnu": "4.40.1", + "@rollup/rollup-linux-riscv64-gnu": "4.40.1", + "@rollup/rollup-linux-riscv64-musl": "4.40.1", + "@rollup/rollup-linux-s390x-gnu": "4.40.1", + "@rollup/rollup-linux-x64-gnu": "4.40.1", + "@rollup/rollup-linux-x64-musl": "4.40.1", + "@rollup/rollup-win32-arm64-msvc": "4.40.1", + "@rollup/rollup-win32-ia32-msvc": "4.40.1", + "@rollup/rollup-win32-x64-msvc": "4.40.1", + "fsevents": "~2.3.2" + } + }, + "node_modules/rxjs": { + "version": "7.5.5", + "resolved": "https://registry.npmjs.org/rxjs/-/rxjs-7.5.5.tgz", + "integrity": "sha512-sy+H0pQofO95VDmFLzyaw9xNJU4KTRSwQIGM6+iG3SypAtCiLDzpeG8sJrNCWn2Up9km+KhkvTdbkrdy+yzZdw==", + "license": "Apache-2.0", + "dependencies": { + "tslib": "^2.1.0" + } + }, + "node_modules/safe-buffer": { + "version": "5.2.1", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz", + "integrity": "sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "license": "MIT", + "optional": true + }, + "node_modules/sax": { + "version": "1.4.3", + "resolved": "https://registry.npmjs.org/sax/-/sax-1.4.3.tgz", + "integrity": "sha512-yqYn1JhPczigF94DMS+shiDMjDowYO6y9+wB/4WgO0Y19jWYk0lQ4tuG5KI7kj4FTp1wxPj5IFfcrz/s1c3jjQ==", + "license": "BlueOak-1.0.0" + }, + "node_modules/semver": { + "version": "7.7.3", + "license": "ISC", + "bin": { + "semver": "bin/semver.js" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/sharp": { + "version": "0.34.5", + "hasInstallScript": true, + "license": "Apache-2.0", + "dependencies": { + "@img/colour": "^1.0.0", + "detect-libc": "^2.1.2", + "semver": "^7.7.3" + }, + "engines": { + "node": "^18.17.0 || ^20.3.0 || >=21.0.0" + }, + "funding": { + "url": "https://opencollective.com/libvips" + }, + "optionalDependencies": { + "@img/sharp-darwin-arm64": "0.34.5", + "@img/sharp-darwin-x64": "0.34.5", + "@img/sharp-libvips-darwin-arm64": "1.2.4", + "@img/sharp-libvips-darwin-x64": "1.2.4", + "@img/sharp-libvips-linux-arm": "1.2.4", + "@img/sharp-libvips-linux-arm64": "1.2.4", + "@img/sharp-libvips-linux-ppc64": "1.2.4", + "@img/sharp-libvips-linux-riscv64": "1.2.4", + "@img/sharp-libvips-linux-s390x": "1.2.4", + "@img/sharp-libvips-linux-x64": "1.2.4", + "@img/sharp-libvips-linuxmusl-arm64": "1.2.4", + "@img/sharp-libvips-linuxmusl-x64": "1.2.4", + "@img/sharp-linux-arm": "0.34.5", + "@img/sharp-linux-arm64": "0.34.5", + "@img/sharp-linux-ppc64": "0.34.5", + "@img/sharp-linux-riscv64": "0.34.5", + "@img/sharp-linux-s390x": "0.34.5", + "@img/sharp-linux-x64": "0.34.5", + "@img/sharp-linuxmusl-arm64": "0.34.5", + "@img/sharp-linuxmusl-x64": "0.34.5", + "@img/sharp-wasm32": "0.34.5", + "@img/sharp-win32-arm64": "0.34.5", + "@img/sharp-win32-ia32": "0.34.5", + "@img/sharp-win32-x64": "0.34.5" + } + }, + "node_modules/simple-concat": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/simple-concat/-/simple-concat-1.0.1.tgz", + "integrity": "sha512-cSFtAPtRhljv69IK0hTVZQ+OfE9nePi/rtJmw5UjHeVyVroEqJXP1sFztKUy1qU+xvz3u/sfYJLa947b7nAN2Q==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "license": "MIT", + "optional": true + }, + "node_modules/simple-get": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/simple-get/-/simple-get-4.0.1.tgz", + "integrity": "sha512-brv7p5WgH0jmQJr1ZDDfKDOSeWWg+OVypG99A/5vYGPqJ6pxiaHLy8nxtFjBA7oMa01ebA9gfh1uMCFqOuXxvA==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "license": "MIT", + "optional": true, + "dependencies": { + "decompress-response": "^6.0.0", + "once": "^1.3.1", + "simple-concat": "^1.0.0" + } + }, + "node_modules/source-map-js": { + "version": "1.2.1", + "dev": true, + "license": "BSD-3-Clause", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/string_decoder": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.3.0.tgz", + "integrity": "sha512-hkRX8U1WjJFd8LsDJ2yQ/wWWxaopEsABU1XfkM8A+j0+85JAGppt16cr1Whg6KIbb4okU6Mql6BOj+uup/wKeA==", + "license": "MIT", + "optional": true, + "dependencies": { + "safe-buffer": "~5.2.0" + } + }, + "node_modules/strip-json-comments": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-2.0.1.tgz", + "integrity": "sha512-4gB8na07fecVVkOI6Rs4e7T6NOTki5EmL7TUduTs6bu3EdnSycntVJ4re8kgZA+wx9IueI2Y11bfbgwtzuE0KQ==", + "license": "MIT", + "optional": true, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/tar-fs": { + "version": "2.1.4", + "resolved": "https://registry.npmjs.org/tar-fs/-/tar-fs-2.1.4.tgz", + "integrity": "sha512-mDAjwmZdh7LTT6pNleZ05Yt65HC3E+NiQzl672vQG38jIrehtJk/J3mNwIg+vShQPcLF/LV7CMnDW6vjj6sfYQ==", + "license": "MIT", + "optional": true, + "dependencies": { + "chownr": "^1.1.1", + "mkdirp-classic": "^0.5.2", + "pump": "^3.0.0", + "tar-stream": "^2.1.4" + } + }, + "node_modules/tar-stream": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/tar-stream/-/tar-stream-2.2.0.tgz", + "integrity": "sha512-ujeqbceABgwMZxEJnk2HDY2DlnUZ+9oEcb1KzTVfYHio0UE6dG71n60d8D2I4qNvleWrrXpmjpt7vZeF1LnMZQ==", + "license": "MIT", + "optional": true, + "dependencies": { + "bl": "^4.0.3", + "end-of-stream": "^1.4.1", + "fs-constants": "^1.0.0", + "inherits": "^2.0.3", + "readable-stream": "^3.1.1" + }, + "engines": { + "node": ">=6" + } + }, + "node_modules/tinyglobby": { + "version": "0.2.13", + "dev": true, + "license": "MIT", + "dependencies": { + "fdir": "^6.4.4", + "picomatch": "^4.0.2" + }, + "engines": { + "node": ">=12.0.0" + }, + "funding": { + "url": "https://github.com/sponsors/SuperchupuDev" + } + }, + "node_modules/ts-replace-all": { + "version": "1.0.0", + "license": "MIT", + "dependencies": { + "core-js": "^3.4.1" + } + }, + "node_modules/tslib": { + "version": "2.8.1", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.8.1.tgz", + "integrity": "sha512-oJFu94HQb+KVduSUQL7wnpmqnfmLsOA/nAh6b6EH0wCEoK0/mPeXU6c3wKDV83MkOuHPRHtSXKKU99IBazS/2w==", + "license": "0BSD" + }, + "node_modules/tunnel-agent": { + "version": "0.6.0", + "resolved": "https://registry.npmjs.org/tunnel-agent/-/tunnel-agent-0.6.0.tgz", + "integrity": "sha512-McnNiV1l8RYeY8tBgEpuodCC1mLUdbSN+CYBL7kJsJNInOP8UjDDEwdk6Mw60vdLLrr5NHKZhMAOSrR2NZuQ+w==", + "license": "Apache-2.0", + "optional": true, + "dependencies": { + "safe-buffer": "^5.0.1" + }, + "engines": { + "node": "*" + } + }, + "node_modules/typescript": { + "version": "5.8.3", + "dev": true, + "license": "Apache-2.0", + "bin": { + "tsc": "bin/tsc", + "tsserver": "bin/tsserver" + }, + "engines": { + "node": ">=14.17" + } + }, + "node_modules/uniq": { + "version": "1.0.1", + "license": "MIT" + }, + "node_modules/util-deprecate": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz", + "integrity": "sha512-EPD5q1uXyFxJpCrLnCc1nHnq3gOa6DZBocAIiI2TaSCA7VCJ1UJDMagCzIkXNsUYfD1daK//LTEQ8xiIbrHtcw==", + "license": "MIT", + "optional": true + }, + "node_modules/verb-nurbs-web": { + "version": "2.1.3", + "resolved": "https://registry.npmjs.org/verb-nurbs-web/-/verb-nurbs-web-2.1.3.tgz", + "integrity": "sha512-2PvI2bx7dn0r3kWtk+JuDIDZ+p7I5Piu8y6/ZNhUVpilOyHKK1nNzLHtgown+dFOmBnKnuAKIMh1xn/5kzrxZA==", + "license": "MIT", + "optionalDependencies": { + "webworker-threads": "^0.7.12" + } + }, + "node_modules/vite": { + "version": "6.3.4", + "dev": true, + "license": "MIT", + "dependencies": { + "esbuild": "^0.25.0", + "fdir": "^6.4.4", + "picomatch": "^4.0.2", + "postcss": "^8.5.3", + "rollup": "^4.34.9", + "tinyglobby": "^0.2.13" + }, + "bin": { + "vite": "bin/vite.js" + }, + "engines": { + "node": "^18.0.0 || ^20.0.0 || >=22.0.0" + }, + "funding": { + "url": "https://github.com/vitejs/vite?sponsor=1" + }, + "optionalDependencies": { + "fsevents": "~2.3.3" + }, + "peerDependencies": { + "@types/node": "^18.0.0 || ^20.0.0 || >=22.0.0", + "jiti": ">=1.21.0", + "less": "*", + "lightningcss": "^1.21.0", + "sass": "*", + "sass-embedded": "*", + "stylus": "*", + "sugarss": "*", + "terser": "^5.16.0", + "tsx": "^4.8.1", + "yaml": "^2.4.2" + }, + "peerDependenciesMeta": { + "@types/node": { + "optional": true + }, + "jiti": { + "optional": true + }, + "less": { + "optional": true + }, + "lightningcss": { + "optional": true + }, + "sass": { + "optional": true + }, + "sass-embedded": { + "optional": true + }, + "stylus": { + "optional": true + }, + "sugarss": { + "optional": true + }, + "terser": { + "optional": true + }, + "tsx": { + "optional": true + }, + "yaml": { + "optional": true + } + } + }, + "node_modules/webworker-threads": { + "version": "0.7.17", + "resolved": "https://registry.npmjs.org/webworker-threads/-/webworker-threads-0.7.17.tgz", + "integrity": "sha512-Y2w2aXBbDLk9IzTEb9u+MsODC3s4YlGI7g4h0t+1OAwIO8yBI9rQL35ZYlyayiCuWu1dZMH/P7kGU8OwW7YsyA==", + "hasInstallScript": true, + "license": "(MIT AND Apache-2.0)", + "optional": true, + "dependencies": { + "bindings": "^1.3.0", + "nan": "^2.11.0" + }, + "engines": { + "node": ">= 0.10.16" + } + }, + "node_modules/wrappy": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", + "integrity": "sha512-l4Sp/DRseor9wL6EvV2+TuQn63dMkPjZ/sp9XkghTEbV9KlPS1xUsZ3u7/IQO4wxtcFB4bgpQPRcR3QCvezPcQ==", + "license": "ISC", + "optional": true + } + } +} diff --git a/examples/vite/playcanvas/starter-template-full/package.json b/examples/vite/playcanvas/starter-template-full/package.json new file mode 100644 index 00000000..a8420f15 --- /dev/null +++ b/examples/vite/playcanvas/starter-template-full/package.json @@ -0,0 +1,19 @@ +{ + "name": "vite-playcanvas-starter", + "private": true, + "version": "0.0.0", + "type": "module", + "scripts": { + "dev": "vite", + "build": "tsc && vite build", + "preview": "vite preview" + }, + "dependencies": { + "@bitbybit-dev/playcanvas": "0.21.0", + "playcanvas": "2.14.4" + }, + "devDependencies": { + "typescript": "~5.8.3", + "vite": "^6.3.2" + } +} diff --git a/examples/vite/playcanvas/starter-template-full/public/vite.svg b/examples/vite/playcanvas/starter-template-full/public/vite.svg new file mode 100644 index 00000000..e7b8dfb1 --- /dev/null +++ b/examples/vite/playcanvas/starter-template-full/public/vite.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/examples/vite/playcanvas/starter-template-full/src/main.ts b/examples/vite/playcanvas/starter-template-full/src/main.ts new file mode 100644 index 00000000..320e8a2f --- /dev/null +++ b/examples/vite/playcanvas/starter-template-full/src/main.ts @@ -0,0 +1,568 @@ +import "./style.css"; // Basic styling +import { BitByBitBase, Inputs, initBitByBit, initPlayCanvas, type InitBitByBitOptions } from "@bitbybit-dev/playcanvas"; + + +// --- 1. Main Application Entry Point --- +start(); + +async function start() { + const sceneOptions = new Inputs.PlayCanvasScene.InitPlayCanvasDto(); + sceneOptions.canvasId = "playcanvas-canvas"; + sceneOptions.sceneSize = 200; + sceneOptions.enableShadows = true; + sceneOptions.enableGround = true; + sceneOptions.groundColor = "#333333"; + sceneOptions.groundCenter = [0, -75, 0]; + sceneOptions.orbitCameraOptions = new Inputs.PlayCanvasCamera.OrbitCameraDto(); + sceneOptions.orbitCameraOptions.yaw = 45; + sceneOptions.orbitCameraOptions.pitch = 25; + sceneOptions.orbitCameraOptions.distance = 120; + sceneOptions.orbitCameraOptions.inertiaFactor = 0.2; + + const { scene, app } = initPlayCanvas(sceneOptions); + const bitbybit = new BitByBitBase(); + + const options: InitBitByBitOptions = { + enableOCCT: true, + enableJSCAD: true, + enableManifold: true, + }; + + await initBitByBit(app, scene, bitbybit, options); + + // --- 3. Create Geometry with Active Kernels --- + if (options.enableOCCT) { + await createOCCTGeometry(bitbybit, "#ff0000"); // Red + } + if (options.enableManifold) { + await createManifoldGeometry(bitbybit, "#00ff00"); // Green + } + if (options.enableJSCAD) { + await createJSCADGeometry(bitbybit, "#0000ff"); // Blue + } + + // --- 4. Create Drawing Examples (Lines, Points, Curves, etc.) --- + await createDrawingExamples(bitbybit); + + // --- 5. Create Textured OCCT Cube Example --- + if (options.enableOCCT) { + await createTexturedOCCTCube(bitbybit); + } +} + +// --- 6. Geometry Creation Functions (Examples) --- +async function createOCCTGeometry(bitbybit: BitByBitBase, color: string) { + console.log("Creating OCCT geometry..."); + const cubeOptions = new Inputs.OCCT.CubeDto(); + cubeOptions.size = 25; + cubeOptions.center = [0, 0, 0]; + + const cube = await bitbybit.occt.shapes.solid.createCube(cubeOptions); + + const filletOptions = + new Inputs.OCCT.FilletDto(); + filletOptions.shape = cube; + filletOptions.radius = 4; + const roundedCube = await bitbybit.occt.fillets.filletEdges(filletOptions); + + const drawOptions = new Inputs.Draw.DrawOcctShapeOptions(); + drawOptions.edgeWidth = 5; + drawOptions.faceColour = color; + drawOptions.drawVertices = true; + drawOptions.vertexSize = 0.5; + drawOptions.vertexColour = "#ffffff"; + await bitbybit.draw.drawAnyAsync({ + entity: roundedCube, + options: drawOptions, + }); + console.log("OCCT geometry created and drawn."); +} + +async function createManifoldGeometry(bitbybit: BitByBitBase, color: string) { + console.log("Creating Manifold geometry..."); + const sphereOptions = new Inputs.Manifold.SphereDto(); + sphereOptions.radius = 15; + const sphere = await bitbybit.manifold.manifold.shapes.sphere(sphereOptions); + + const cubeOptions = new Inputs.Manifold.CubeDto(); + cubeOptions.size = 25; + const cube = await bitbybit.manifold.manifold.shapes.cube(cubeOptions); + + const diffedShape = await bitbybit.manifold.manifold.booleans.differenceTwo({ + manifold1: cube, + manifold2: sphere, + }); + + const translationOptions = + new Inputs.Manifold.TranslateDto(); + translationOptions.manifold = diffedShape; + translationOptions.vector = [0, -40, 0]; // Position below OCCT + const movedShape = await bitbybit.manifold.manifold.transforms.translate( + translationOptions + ); + + const drawOptions = new Inputs.Draw.DrawManifoldOrCrossSectionOptions(); + drawOptions.faceColour = color; + await bitbybit.draw.drawAnyAsync({ + entity: movedShape, + options: drawOptions, + }); + console.log("Manifold geometry created and drawn."); +} + +async function createJSCADGeometry(bitbybit: BitByBitBase, color: string) { + console.log("Creating JSCAD geometry..."); + const geodesicSphereOptions = new Inputs.JSCAD.GeodesicSphereDto(); + geodesicSphereOptions.radius = 15; + geodesicSphereOptions.center = [0, 40, 0]; // Position above OCCT + const geodesicSphere = await bitbybit.jscad.shapes.geodesicSphere( + geodesicSphereOptions + ); + + // Example: Create another simple sphere for a boolean operation + const sphereOptions = new Inputs.JSCAD.SphereDto(); + sphereOptions.radius = 10; // Smaller sphere + sphereOptions.center = [5, 45, 0]; // Slightly offset + const simpleSphere = await bitbybit.jscad.shapes.sphere(sphereOptions); + + const unionOptions = new Inputs.JSCAD.BooleanTwoObjectsDto(); + unionOptions.first = geodesicSphere; + unionOptions.second = simpleSphere; + const unionShape = await bitbybit.jscad.booleans.unionTwo(unionOptions); + + const drawOptions = new Inputs.Draw.DrawBasicGeometryOptions(); + drawOptions.colours = color; // Note: 'colours' for JSCAD draw options + await bitbybit.draw.drawAnyAsync({ + entity: unionShape, + options: drawOptions, + }); + console.log("JSCAD geometry created and drawn."); +} + +async function createTexturedOCCTCube(bitbybit: BitByBitBase) { + console.log("Creating textured OCCT cube..."); + + // Create texture from URL + const textureOptions = new Inputs.Draw.GenericTextureDto(); + textureOptions.url = "https://cdn.polyhaven.com/asset_img/primary/worn_asphalt.png?height=760&quality=95"; + textureOptions.uScale = 0.05; + textureOptions.vScale = 0.05; + const texture = await bitbybit.draw.createTexture(textureOptions); + + // Create material with texture + const materialOptions = new Inputs.Draw.GenericPBRMaterialDto(); + materialOptions.baseColorTexture = texture; + materialOptions.baseColor = "#ffffff"; // White to show texture colors accurately + const material = await bitbybit.draw.createPBRMaterial(materialOptions); + + // Create OCCT cube + const cubeOptions = new Inputs.OCCT.CubeDto(); + cubeOptions.size = 20; + cubeOptions.center = [-50, 0, -50]; + const cube = await bitbybit.occt.shapes.solid.createCube(cubeOptions); + + // Draw cube with material + const drawOptions = new Inputs.Draw.DrawOcctShapeOptions(); + drawOptions.faceMaterial = material; + drawOptions.backFaceOpacity = 1; + await bitbybit.draw.drawAnyAsync({ + entity: cube, + options: drawOptions, + }); + + console.log("Textured OCCT cube created and drawn."); +} + +// --- 7. Drawing Examples Function --- +async function createDrawingExamples(bitbybit: BitByBitBase) { + console.log("Creating drawing examples..."); + + // Example 1: Draw a single point + const point = [60, 0, 0] as Inputs.Base.Point3; + const pointDrawOptions = new Inputs.Draw.DrawBasicGeometryOptions(); + pointDrawOptions.colours = "#ffff00"; // Yellow + pointDrawOptions.size = 2; + await bitbybit.draw.drawAnyAsync({ + entity: point, + options: pointDrawOptions, + }); + console.log("Single point drawn."); + + // Example 2: Draw multiple points + const points = [ + [60, 5, 0], + [60, 10, 0], + [60, 15, 0], + [60, 20, 0], + [60, 25, 0], + [60, 30, 0], + [60, 35, 0], + ] as Inputs.Base.Point3[]; + const pointsDrawOptions = new Inputs.Draw.DrawBasicGeometryOptions(); + pointsDrawOptions.colours = ["#ff00ff", "#ff0000", "#00ff00", "#0000ff"]; // Magenta + pointsDrawOptions.size = 1.5; + pointsDrawOptions.colorMapStrategy = Inputs.Base.colorMapStrategyEnum.repeatColors; + await bitbybit.draw.drawAnyAsync({ + entity: points, + options: pointsDrawOptions, + }); + console.log("Multiple points drawn."); + + // Example 3: Draw a single polyline + const polyline = { + points: [ + [70, -10, 0], + [70, 0, 10], + [80, 0, 10], + [80, -10, 0], + ], + } as Inputs.Base.Polyline3; + const polylineDrawOptions = new Inputs.Draw.DrawBasicGeometryOptions(); + polylineDrawOptions.colours = "#00ffff"; // Cyan + polylineDrawOptions.size = 3; + await bitbybit.draw.drawAnyAsync({ + entity: polyline, + options: polylineDrawOptions, + }); + console.log("Polyline drawn."); + + // Example 4: Draw multiple polylines with different colors + const polylines = [ + { + points: [ + [90, -10, 0], + [90, 0, 0], + [100, 0, 0], + ], + }, + { + points: [ + [90, -10, 5], + [90, 0, 5], + [100, 0, 5], + ], + }, + { + points: [ + [90, -10, 10], + [90, 0, 10], + [100, 0, 10], + ], + }, + ]; + const polylinesDrawOptions = new Inputs.Draw.DrawBasicGeometryOptions(); + polylinesDrawOptions.colours = ["#ff0000", "#00ff00", "#0000ff"]; // RGB + polylinesDrawOptions.size = 2; + await bitbybit.draw.drawAnyAsync({ + entity: polylines as Inputs.Base.Polyline3[], + options: polylinesDrawOptions, + }); + console.log("Multiple polylines drawn."); + + // Example 5: Draw line segments (polylines with 2 points each) + const segments = [ + { + points: [ + [60, -20, 0], + [70, -20, 0], + ], + }, + { + points: [ + [65, -25, 0], + [65, -15, 0], + ], + }, + { + points: [ + [60, -20, -5], + [70, -20, 5], + ], + }, + ]; + const segmentsDrawOptions = new Inputs.Draw.DrawBasicGeometryOptions(); + segmentsDrawOptions.colours = ["#ffff00", "#ff00ff", "#00ffff"]; // Yellow, Magenta, Cyan + segmentsDrawOptions.size = 2.5; + await bitbybit.draw.drawAnyAsync({ + entity: segments as Inputs.Base.Polyline3[], + options: segmentsDrawOptions, + }); + console.log("Line segments drawn."); + + // Example 6: Draw a Verb NURBS curve + // Create a simple NURBS curve through control points + const controlPoints = [ + [-60, -10, 0], + [-50, 0, 5], + [-40, -5, 10], + [-30, 10, 5], + [-20, 0, 0], + ] as Inputs.Base.Point3[]; + + // Create a NURBS curve (degree 3) + const curve = bitbybit.verb.curve.createCurveByPoints({ + points: controlPoints, + degree: 3, + }); + + const curveDrawOptions = new Inputs.Draw.DrawBasicGeometryOptions(); + curveDrawOptions.colours = "#ff8800"; // Orange + curveDrawOptions.size = 3; + await bitbybit.draw.drawAnyAsync({ + entity: curve, + options: curveDrawOptions, + }); + console.log("Verb curve drawn."); + + // Example 7: Draw a Verb NURBS surface by lofting curves + // Create curves that will be lofted to form a surface + const curve1Points = [ + [-60, 20, -5], + [-50, 20, 0], + [-40, 20, -5], + ] as Inputs.Base.Point3[]; + + const curve2Points = [ + [-60, 30, 0], + [-50, 30, 5], + [-40, 30, 0], + ] as Inputs.Base.Point3[]; + + const curve3Points = [ + [-60, 40, -5], + [-50, 40, 0], + [-40, 40, -5], + ] as Inputs.Base.Point3[]; + + // Create the curves + const curve1 = bitbybit.verb.curve.createCurveByPoints({ + points: curve1Points, + degree: 2, + }); + + const curve2 = bitbybit.verb.curve.createCurveByPoints({ + points: curve2Points, + degree: 2, + }); + + const curve3 = bitbybit.verb.curve.createCurveByPoints({ + points: curve3Points, + degree: 2, + }); + + // Loft the curves to create a surface + const surface = bitbybit.verb.surface.createSurfaceByLoftingCurves({ + curves: [curve3, curve2, curve1], + degreeV: 2, + }); + + const surfaceDrawOptions = new Inputs.Draw.DrawBasicGeometryOptions(); + surfaceDrawOptions.colours = "#8800ff"; // Purple + surfaceDrawOptions.opacity = 0.8; + await bitbybit.draw.drawAnyAsync({ + entity: surface, + options: surfaceDrawOptions, + }); + console.log("Verb surface drawn."); + + // Example 8: Draw a 30x30x30 grid of points with alternating blue and white colors + // This tests GPU instancing performance with 27,000 points + console.log("Creating 30x30x30 point grid (27,000 points)..."); + const gridSize = 30; + const spacing = 1.5; + const gridOffset = [-150, 0, 0]; // Move grid away from other geometry + + const gridPoints: Inputs.Base.Point3[] = []; + const gridColors: string[] = []; + + for (let x = 0; x < gridSize; x++) { + for (let y = 0; y < gridSize; y++) { + for (let z = 0; z < gridSize; z++) { + gridPoints.push([ + gridOffset[0] + x * spacing, + gridOffset[1] + y * spacing, + gridOffset[2] + z * spacing + ]); + // Alternating blue and white based on checkerboard pattern + const isBlue = (x + y + z) % 2 === 0; + gridColors.push(isBlue ? "#0066ff" : "#ffffff"); + } + } + } + + const gridDrawOptions = new Inputs.Draw.DrawBasicGeometryOptions(); + gridDrawOptions.colours = gridColors; + gridDrawOptions.size = 0.4; + gridDrawOptions.colorMapStrategy = Inputs.Base.colorMapStrategyEnum.lastColorRemainder; + + console.time("Draw 27,000 points"); + await bitbybit.draw.drawAnyAsync({ + entity: gridPoints, + options: gridDrawOptions, + }); + console.timeEnd("Draw 27,000 points"); + console.log("30x30x30 point grid drawn with GPU instancing."); + + // Example 9: Draw a 30x30x30 grid of polylines with alternating colors + // Creates lines along X, Y, and Z axes forming a 3D grid + console.log("Creating 30x30x30 polyline grid..."); + const polylineGridSize = 30; + const polylineSpacing = 1.5; + const polylineGridOffset = [-150, -60, 0]; // Position below the point grid + + const gridPolylines: Inputs.Base.Polyline3[] = []; + const polylineColors: string[] = []; + + // Create lines along X axis (for each Y,Z position) + for (let y = 0; y < polylineGridSize; y++) { + for (let z = 0; z < polylineGridSize; z++) { + const startX = polylineGridOffset[0]; + const endX = polylineGridOffset[0] + (polylineGridSize - 1) * polylineSpacing; + const posY = polylineGridOffset[1] + y * polylineSpacing; + const posZ = polylineGridOffset[2] + z * polylineSpacing; + + gridPolylines.push({ + points: [ + [startX, posY, posZ], + [endX, posY, posZ] + ] + }); + // Alternating colors based on position + const isOrange = (y + z) % 2 === 0; + polylineColors.push(isOrange ? "#ff6600" : "#00ffcc"); + } + } + + // Create lines along Y axis (for each X,Z position) + for (let x = 0; x < polylineGridSize; x++) { + for (let z = 0; z < polylineGridSize; z++) { + const posX = polylineGridOffset[0] + x * polylineSpacing; + const startY = polylineGridOffset[1]; + const endY = polylineGridOffset[1] + (polylineGridSize - 1) * polylineSpacing; + const posZ = polylineGridOffset[2] + z * polylineSpacing; + + gridPolylines.push({ + points: [ + [posX, startY, posZ], + [posX, endY, posZ] + ] + }); + const isPurple = (x + z) % 2 === 0; + polylineColors.push(isPurple ? "#9933ff" : "#ffff00"); + } + } + + // Create lines along Z axis (for each X,Y position) + for (let x = 0; x < polylineGridSize; x++) { + for (let y = 0; y < polylineGridSize; y++) { + const posX = polylineGridOffset[0] + x * polylineSpacing; + const posY = polylineGridOffset[1] + y * polylineSpacing; + const startZ = polylineGridOffset[2]; + const endZ = polylineGridOffset[2] + (polylineGridSize - 1) * polylineSpacing; + + gridPolylines.push({ + points: [ + [posX, posY, startZ], + [posX, posY, endZ] + ] + }); + const isPink = (x + y) % 2 === 0; + polylineColors.push(isPink ? "#ff0099" : "#00ff66"); + } + } + + const polylineGridDrawOptions = new Inputs.Draw.DrawBasicGeometryOptions(); + polylineGridDrawOptions.colours = polylineColors; + polylineGridDrawOptions.size = 1; + polylineGridDrawOptions.colorMapStrategy = Inputs.Base.colorMapStrategyEnum.lastColorRemainder; + + console.log(`Drawing ${gridPolylines.length} polylines...`); + console.time("Draw polyline grid"); + await bitbybit.draw.drawAnyAsync({ + entity: gridPolylines, + options: polylineGridDrawOptions, + }); + console.timeEnd("Draw polyline grid"); + console.log("30x30x30 polyline grid drawn with per-polyline colors."); + + // --- Arrow Examples --- + // Example: Draw a single polyline with an arrow at the end + const arrowPolyline = { + points: [ + [-80, 0, 0], + [-80, 10, 5], + [-70, 15, 10], + [-60, 10, 5], + ], + } as Inputs.Base.Polyline3; + const arrowPolylineOptions = new Inputs.Draw.DrawBasicGeometryOptions(); + arrowPolylineOptions.colours = "#00ff88"; // Green + arrowPolylineOptions.size = 3; + arrowPolylineOptions.arrowSize = 3; // Arrow size + arrowPolylineOptions.arrowAngle = 25; // Arrow angle in degrees + await bitbybit.draw.drawAnyAsync({ + entity: arrowPolyline, + options: arrowPolylineOptions, + }); + console.log("Polyline with arrow drawn."); + + // Example: Draw multiple polylines with arrows (different sizes) + const arrowPolylines = [ + { + points: [ + [-80, -30, 0], + [-70, -25, 0], + [-60, -30, 0], + ], + }, + { + points: [ + [-80, -35, 0], + [-70, -30, 0], + [-60, -35, 0], + ], + }, + { + points: [ + [-80, -40, 0], + [-70, -35, 0], + [-60, -40, 0], + ], + }, + ] as Inputs.Base.Polyline3[]; + const arrowPolylinesOptions = new Inputs.Draw.DrawBasicGeometryOptions(); + arrowPolylinesOptions.colours = ["#ff0000", "#00ff00", "#0000ff"]; // RGB + arrowPolylinesOptions.size = 2; + arrowPolylinesOptions.arrowSize = 2.5; + arrowPolylinesOptions.arrowAngle = 30; + await bitbybit.draw.drawAnyAsync({ + entity: arrowPolylines, + options: arrowPolylinesOptions, + }); + console.log("Multiple polylines with arrows drawn."); + + // Example: Draw OCCT wire with edge arrows to show orientation + const wirePoints = [ + [-80, -60, 0], + [-70, -55, 5], + [-60, -60, 0], + [-50, -65, -5], + ] as Inputs.Base.Point3[]; + const wire = await bitbybit.occt.shapes.wire.createPolylineWire({ + points: wirePoints, + }); + const wireDrawOptions = new Inputs.Draw.DrawOcctShapeOptions(); + wireDrawOptions.edgeColour = "#ff8800"; // Orange edges + wireDrawOptions.edgeWidth = 3; + wireDrawOptions.drawEdges = true; + wireDrawOptions.drawFaces = false; + wireDrawOptions.edgeArrowSize = 3; // Arrow size on edges + wireDrawOptions.edgeArrowAngle = 25; // Arrow angle + await bitbybit.draw.drawAnyAsync({ + entity: wire, + options: wireDrawOptions, + }); + console.log("OCCT wire with edge orientation arrows drawn."); + + console.log("All drawing examples completed."); +} diff --git a/examples/vite/playcanvas/starter-template-full/src/style.css b/examples/vite/playcanvas/starter-template-full/src/style.css new file mode 100644 index 00000000..72e40599 --- /dev/null +++ b/examples/vite/playcanvas/starter-template-full/src/style.css @@ -0,0 +1,25 @@ +body { + margin: 0px; + overflow: hidden; +} + +a.logo { + position: absolute; + color: white; + vertical-align: middle; + bottom: 10px; + left: 10px; + font-family: 'Courier New', Courier, monospace; + text-decoration: none; + width: 100%; +} + +.logo { + margin-bottom: 20px; + text-align: center; +} + +.logo img { + width: 50px; + height: 50px; +} diff --git a/examples/vite/playcanvas/starter-template-full/src/vite-env.d.ts b/examples/vite/playcanvas/starter-template-full/src/vite-env.d.ts new file mode 100644 index 00000000..11f02fe2 --- /dev/null +++ b/examples/vite/playcanvas/starter-template-full/src/vite-env.d.ts @@ -0,0 +1 @@ +/// diff --git a/examples/vite/playcanvas/starter-template-full/tsconfig.json b/examples/vite/playcanvas/starter-template-full/tsconfig.json new file mode 100644 index 00000000..a22caba9 --- /dev/null +++ b/examples/vite/playcanvas/starter-template-full/tsconfig.json @@ -0,0 +1,25 @@ +{ + "compilerOptions": { + "target": "ES2020", + "useDefineForClassFields": true, + "module": "ESNext", + "lib": ["ES2020", "DOM", "DOM.Iterable"], + "skipLibCheck": true, + + /* Bundler mode */ + "moduleResolution": "bundler", + "allowImportingTsExtensions": true, + "verbatimModuleSyntax": true, + "moduleDetection": "force", + "noEmit": true, + + /* Linting */ + "strict": true, + "noUnusedLocals": true, + "noUnusedParameters": true, + "erasableSyntaxOnly": true, + "noFallthroughCasesInSwitch": true, + "noUncheckedSideEffectImports": true + }, + "include": ["src"] +} diff --git a/examples/vite/playcanvas/starter-template/src/main.ts b/examples/vite/playcanvas/starter-template/src/main.ts index df4f4ded..83186ca6 100644 --- a/examples/vite/playcanvas/starter-template/src/main.ts +++ b/examples/vite/playcanvas/starter-template/src/main.ts @@ -1,283 +1,69 @@ -import "./style.css"; // Basic styling -import { BitByBitBase, Inputs } from "@bitbybit-dev/playcanvas"; -import { OccStateEnum } from "@bitbybit-dev/occt-worker"; -import { JscadStateEnum } from "@bitbybit-dev/jscad-worker"; -import { ManifoldStateEnum } from "@bitbybit-dev/manifold-worker"; +import "./style.css"; +import { BitByBitBase, Inputs, initBitByBit, initPlayCanvas, type InitBitByBitOptions } from "@bitbybit-dev/playcanvas"; -import { first, firstValueFrom, map } from "rxjs"; -import { Application, Color, Entity, FILLMODE_FILL_WINDOW, Mouse, RESOLUTION_AUTO, TouchDevice } from "playcanvas"; -// Define an interface for kernel options -interface KernelOptions { - enableOCCT: boolean; - enableJSCAD: boolean; - enableManifold: boolean; -} - -// --- 1. Main Application Entry Point --- start(); async function start() { - // Initialize basic PlayCanvas scene - const { app, scene, camera } = initPlayCanvas(); - - // Create an instance of BitByBitBase for PlayCanvas + const sceneOptions = new Inputs.PlayCanvasScene.InitPlayCanvasDto(); + sceneOptions.canvasId = "playcanvas-canvas"; + sceneOptions.sceneSize = 10; + const { scene, app } = initPlayCanvas(sceneOptions); const bitbybit = new BitByBitBase(); - // --- 2. Configure and Initialize Kernels --- - // Users can control which kernels are loaded - const kernelOptions: KernelOptions = { + const options: InitBitByBitOptions = { enableOCCT: true, enableJSCAD: true, enableManifold: true, }; - // Initialize Bitbybit with the selected kernels - await initWithKernels(app, scene, bitbybit, kernelOptions); - - // Setup orbit camera controls using bitbybit library - const cameraOptions = new Inputs.PlayCanvasCamera.OrbitCameraDto(); - cameraOptions.distance = 125; - cameraOptions.pitch = -24; - cameraOptions.yaw = 27; - cameraOptions.frameOnStart = false; - cameraOptions.inertiaFactor = 0.2; - cameraOptions.distanceSensitivity = 0.3; - cameraOptions.focusEntity = camera; - bitbybit.playcanvas.camera.orbitCamera.create(cameraOptions); - - // --- 3. Create Geometry with Active Kernels --- - if (kernelOptions.enableOCCT) { - await createOCCTGeometry(bitbybit, "#ff0000"); // Red - } - if (kernelOptions.enableManifold) { - await createManifoldGeometry(bitbybit, "#00ff00"); // Green - } - if (kernelOptions.enableJSCAD) { - await createJSCADGeometry(bitbybit, "#0000ff"); // Blue - } - // --- 4. Create Drawing Examples (Lines, Points, Curves, etc.) --- - await createDrawingExamples(bitbybit); - - // --- 5. Create Textured OCCT Cube Example --- - if (kernelOptions.enableOCCT) { - await createTexturedOCCTCube(bitbybit); - } -} + await initBitByBit(app, scene, bitbybit, options); -// --- 4. PlayCanvas Scene Initialization --- -function initPlayCanvas() { - const canvas = document.getElementById("playcanvas-canvas") as HTMLCanvasElement; - - // Create a PlayCanvas application - const app = new Application(canvas, { - graphicsDeviceOptions: { - antialias: true, - alpha: false, - }, - mouse: new Mouse(canvas), - touch: new TouchDevice(canvas), - }); - - // Fill the window and automatically change resolution to be the same as the canvas size - app.setCanvasFillMode(FILLMODE_FILL_WINDOW); - app.setCanvasResolution(RESOLUTION_AUTO); - - // Ensure canvas is resized when window changes size - window.addEventListener("resize", () => app.resizeCanvas()); - - // Create root scene entity - const scene = new Entity("scene"); - app.root.addChild(scene); - - // Create camera entity - const camera = new Entity("camera"); - camera.addComponent("camera", { - clearColor: new Color(0x1a / 255, 0x1c / 255, 0x1f / 255, 1), - fov: 70, - nearClip: 0.1, - farClip: 1000, - }); - scene.addChild(camera); - - // Create directional light - const light = new Entity("directionalLight"); - light.addComponent("light", { - type: "directional", - color: new Color(1, 1, 1), - intensity: 1, - }); - light.setEulerAngles(45, 30, 0); - scene.addChild(light); - - // Create ambient/hemisphere-like lighting - app.scene.ambientLight = new Color(0.4, 0.4, 0.4); - - // Start the application update loop - app.start(); - - return { app, scene, camera }; -} - -// --- 5. Bitbybit Kernel Initialization Logic --- -async function initWithKernels( - app: pc.AppBase, - scene: pc.Entity, - bitbybit: BitByBitBase, - options: KernelOptions -): Promise<{ message: string; initializedKernels: string[] }> { - let occtWorkerInstance: Worker | undefined; - let jscadWorkerInstance: Worker | undefined; - let manifoldWorkerInstance: Worker | undefined; - - // 1. Conditionally create worker instances if (options.enableOCCT) { - occtWorkerInstance = new Worker( - new URL("./workers/occt.worker.ts", import.meta.url), - { name: "OCC_WORKER", type: "module" } - ); - } - if (options.enableJSCAD) { - jscadWorkerInstance = new Worker( - new URL("./workers/jscad.worker.ts", import.meta.url), - { name: "JSCAD_WORKER", type: "module" } - ); + await createOCCTGeometry(bitbybit, "#ff0000"); // Red } if (options.enableManifold) { - manifoldWorkerInstance = new Worker( - new URL("./workers/manifold.worker.ts", import.meta.url), - { name: "MANIFOLD_WORKER", type: "module" } - ); - } - - // 2. Initialize Bitbybit with PlayCanvas app and scene - bitbybit.init( - app, - scene, - occtWorkerInstance, - jscadWorkerInstance, - manifoldWorkerInstance - ); - - // 3. Collect promises for kernel initializations - const initializationPromises: Promise[] = []; - let anyKernelSelectedForInit = false; - - if (options.enableOCCT) { - anyKernelSelectedForInit = true; - if (bitbybit.occtWorkerManager) { - initializationPromises.push( - firstValueFrom( - bitbybit.occtWorkerManager.occWorkerState$.pipe( - first((s) => s.state === OccStateEnum.initialised), - map(() => "OCCT") - ) - ) - ); - } else { - console.warn( - "OCCT enabled in options, but occtWorkerManager not found after init." - ); - } + await createManifoldGeometry(bitbybit, "#00ff00"); // Green } - if (options.enableJSCAD) { - anyKernelSelectedForInit = true; - if (bitbybit.jscadWorkerManager) { - initializationPromises.push( - firstValueFrom( - bitbybit.jscadWorkerManager.jscadWorkerState$.pipe( - first((s) => s.state === JscadStateEnum.initialised), - map(() => "JSCAD") - ) - ) - ); - } else { - console.warn( - "JSCAD enabled in options, but jscadWorkerManager not found after init." - ); - } - } - - if (options.enableManifold) { - anyKernelSelectedForInit = true; - if (bitbybit.manifoldWorkerManager && bitbybit.manifoldWorkerManager.manifoldWorkerState$) { - initializationPromises.push( - firstValueFrom( - bitbybit.manifoldWorkerManager.manifoldWorkerState$.pipe( - first((s) => s.state === ManifoldStateEnum.initialised), - map(() => "Manifold") - ) - ) - ); - } else { - console.warn( - "Manifold enabled in options, but manifoldWorkerManager not found after init." - ); - } - } - - // 4. Wait for selected & available kernels or handle no selection/availability - if (!anyKernelSelectedForInit) { - console.log("No kernels selected for initialization."); - return { message: "No kernels selected for initialization.", initializedKernels: [] }; - } - - if (initializationPromises.length === 0) { - // Kernels were selected, but none were awaitable (e.g., managers missing for all selected) - console.log( - "Kernels were selected, but none had managers available for awaiting initialization." - ); - return { - message: "Selected kernels were not awaitable for initialization state.", - initializedKernels: [], - }; + await createJSCADGeometry(bitbybit, "#0000ff"); // Blue } - const initializedKernels = await Promise.all(initializationPromises); - console.log("Kernels initialized:", initializedKernels.join(", ")); - return { - message: `Successfully initialized: ${initializedKernels.join(", ")}`, - initializedKernels, - }; } -// --- 6. Geometry Creation Functions (Examples) --- async function createOCCTGeometry(bitbybit: BitByBitBase, color: string) { - console.log("Creating OCCT geometry..."); const cubeOptions = new Inputs.OCCT.CubeDto(); - cubeOptions.size = 25; - cubeOptions.center = [0, 0, 0]; + cubeOptions.size = 2.5; + cubeOptions.center = [0, 1.25, 0]; const cube = await bitbybit.occt.shapes.solid.createCube(cubeOptions); const filletOptions = new Inputs.OCCT.FilletDto(); filletOptions.shape = cube; - filletOptions.radius = 4; + filletOptions.radius = 0.4; const roundedCube = await bitbybit.occt.fillets.filletEdges(filletOptions); const drawOptions = new Inputs.Draw.DrawOcctShapeOptions(); - drawOptions.edgeWidth = 5; + drawOptions.edgeWidth = 0.5; drawOptions.faceColour = color; drawOptions.drawVertices = true; - drawOptions.vertexSize = 0.5; + drawOptions.vertexSize = 0.05; drawOptions.vertexColour = "#ffffff"; await bitbybit.draw.drawAnyAsync({ entity: roundedCube, options: drawOptions, }); - console.log("OCCT geometry created and drawn."); } async function createManifoldGeometry(bitbybit: BitByBitBase, color: string) { - console.log("Creating Manifold geometry..."); const sphereOptions = new Inputs.Manifold.SphereDto(); - sphereOptions.radius = 15; + sphereOptions.radius = 1.5; + sphereOptions.circularSegments = 32; const sphere = await bitbybit.manifold.manifold.shapes.sphere(sphereOptions); const cubeOptions = new Inputs.Manifold.CubeDto(); - cubeOptions.size = 25; + cubeOptions.size = 2.5; const cube = await bitbybit.manifold.manifold.shapes.cube(cubeOptions); const diffedShape = await bitbybit.manifold.manifold.booleans.differenceTwo({ @@ -288,7 +74,7 @@ async function createManifoldGeometry(bitbybit: BitByBitBase, color: string) { const translationOptions = new Inputs.Manifold.TranslateDto(); translationOptions.manifold = diffedShape; - translationOptions.vector = [0, -40, 0]; // Position below OCCT + translationOptions.vector = [0, 1.25, -4]; // Position below OCCT const movedShape = await bitbybit.manifold.manifold.transforms.translate( translationOptions ); @@ -299,22 +85,19 @@ async function createManifoldGeometry(bitbybit: BitByBitBase, color: string) { entity: movedShape, options: drawOptions, }); - console.log("Manifold geometry created and drawn."); } async function createJSCADGeometry(bitbybit: BitByBitBase, color: string) { - console.log("Creating JSCAD geometry..."); const geodesicSphereOptions = new Inputs.JSCAD.GeodesicSphereDto(); - geodesicSphereOptions.radius = 15; - geodesicSphereOptions.center = [0, 40, 0]; // Position above OCCT + geodesicSphereOptions.radius = 1.5; + geodesicSphereOptions.center = [0, 1.5, 4]; const geodesicSphere = await bitbybit.jscad.shapes.geodesicSphere( geodesicSphereOptions ); - // Example: Create another simple sphere for a boolean operation const sphereOptions = new Inputs.JSCAD.SphereDto(); - sphereOptions.radius = 10; // Smaller sphere - sphereOptions.center = [5, 45, 0]; // Slightly offset + sphereOptions.radius = 1; + sphereOptions.center = [0, 3, 4.5]; const simpleSphere = await bitbybit.jscad.shapes.sphere(sphereOptions); const unionOptions = new Inputs.JSCAD.BooleanTwoObjectsDto(); @@ -323,438 +106,10 @@ async function createJSCADGeometry(bitbybit: BitByBitBase, color: string) { const unionShape = await bitbybit.jscad.booleans.unionTwo(unionOptions); const drawOptions = new Inputs.Draw.DrawBasicGeometryOptions(); - drawOptions.colours = color; // Note: 'colours' for JSCAD draw options + drawOptions.colours = color; await bitbybit.draw.drawAnyAsync({ entity: unionShape, options: drawOptions, }); - console.log("JSCAD geometry created and drawn."); } -async function createTexturedOCCTCube(bitbybit: BitByBitBase) { - console.log("Creating textured OCCT cube..."); - - // Create texture from URL - const textureOptions = new Inputs.Draw.GenericTextureDto(); - textureOptions.url = "https://cdn.polyhaven.com/asset_img/primary/worn_asphalt.png?height=760&quality=95"; - textureOptions.uScale = 0.05; - textureOptions.vScale = 0.05; - const texture = await bitbybit.draw.createTexture(textureOptions); - - // Create material with texture - const materialOptions = new Inputs.Draw.GenericPBRMaterialDto(); - materialOptions.baseColorTexture = texture; - materialOptions.baseColor = "#ffffff"; // White to show texture colors accurately - const material = await bitbybit.draw.createPBRMaterial(materialOptions); - - // Create OCCT cube - const cubeOptions = new Inputs.OCCT.CubeDto(); - cubeOptions.size = 20; - cubeOptions.center = [-50, 0, -50]; - const cube = await bitbybit.occt.shapes.solid.createCube(cubeOptions); - - // Draw cube with material - const drawOptions = new Inputs.Draw.DrawOcctShapeOptions(); - drawOptions.faceMaterial = material; - drawOptions.backFaceOpacity = 1; - await bitbybit.draw.drawAnyAsync({ - entity: cube, - options: drawOptions, - }); - - console.log("Textured OCCT cube created and drawn."); -} - -// --- 7. Drawing Examples Function --- -async function createDrawingExamples(bitbybit: BitByBitBase) { - console.log("Creating drawing examples..."); - - // Example 1: Draw a single point - const point = [60, 0, 0] as Inputs.Base.Point3; - const pointDrawOptions = new Inputs.Draw.DrawBasicGeometryOptions(); - pointDrawOptions.colours = "#ffff00"; // Yellow - pointDrawOptions.size = 2; - await bitbybit.draw.drawAnyAsync({ - entity: point, - options: pointDrawOptions, - }); - console.log("Single point drawn."); - - // Example 2: Draw multiple points - const points = [ - [60, 5, 0], - [60, 10, 0], - [60, 15, 0], - [60, 20, 0], - [60, 25, 0], - [60, 30, 0], - [60, 35, 0], - ] as Inputs.Base.Point3[]; - const pointsDrawOptions = new Inputs.Draw.DrawBasicGeometryOptions(); - pointsDrawOptions.colours = ["#ff00ff", "#ff0000", "#00ff00", "#0000ff"]; // Magenta - pointsDrawOptions.size = 1.5; - pointsDrawOptions.colorMapStrategy = Inputs.Base.colorMapStrategyEnum.repeatColors; - await bitbybit.draw.drawAnyAsync({ - entity: points, - options: pointsDrawOptions, - }); - console.log("Multiple points drawn."); - - // Example 3: Draw a single polyline - const polyline = { - points: [ - [70, -10, 0], - [70, 0, 10], - [80, 0, 10], - [80, -10, 0], - ], - } as Inputs.Base.Polyline3; - const polylineDrawOptions = new Inputs.Draw.DrawBasicGeometryOptions(); - polylineDrawOptions.colours = "#00ffff"; // Cyan - polylineDrawOptions.size = 3; - await bitbybit.draw.drawAnyAsync({ - entity: polyline, - options: polylineDrawOptions, - }); - console.log("Polyline drawn."); - - // Example 4: Draw multiple polylines with different colors - const polylines = [ - { - points: [ - [90, -10, 0], - [90, 0, 0], - [100, 0, 0], - ], - }, - { - points: [ - [90, -10, 5], - [90, 0, 5], - [100, 0, 5], - ], - }, - { - points: [ - [90, -10, 10], - [90, 0, 10], - [100, 0, 10], - ], - }, - ]; - const polylinesDrawOptions = new Inputs.Draw.DrawBasicGeometryOptions(); - polylinesDrawOptions.colours = ["#ff0000", "#00ff00", "#0000ff"]; // RGB - polylinesDrawOptions.size = 2; - await bitbybit.draw.drawAnyAsync({ - entity: polylines as Inputs.Base.Polyline3[], - options: polylinesDrawOptions, - }); - console.log("Multiple polylines drawn."); - - // Example 5: Draw line segments (polylines with 2 points each) - const segments = [ - { - points: [ - [60, -20, 0], - [70, -20, 0], - ], - }, - { - points: [ - [65, -25, 0], - [65, -15, 0], - ], - }, - { - points: [ - [60, -20, -5], - [70, -20, 5], - ], - }, - ]; - const segmentsDrawOptions = new Inputs.Draw.DrawBasicGeometryOptions(); - segmentsDrawOptions.colours = ["#ffff00", "#ff00ff", "#00ffff"]; // Yellow, Magenta, Cyan - segmentsDrawOptions.size = 2.5; - await bitbybit.draw.drawAnyAsync({ - entity: segments as Inputs.Base.Polyline3[], - options: segmentsDrawOptions, - }); - console.log("Line segments drawn."); - - // Example 6: Draw a Verb NURBS curve - // Create a simple NURBS curve through control points - const controlPoints = [ - [-60, -10, 0], - [-50, 0, 5], - [-40, -5, 10], - [-30, 10, 5], - [-20, 0, 0], - ] as Inputs.Base.Point3[]; - - // Create a NURBS curve (degree 3) - const curve = bitbybit.verb.curve.createCurveByPoints({ - points: controlPoints, - degree: 3, - }); - - const curveDrawOptions = new Inputs.Draw.DrawBasicGeometryOptions(); - curveDrawOptions.colours = "#ff8800"; // Orange - curveDrawOptions.size = 3; - await bitbybit.draw.drawAnyAsync({ - entity: curve, - options: curveDrawOptions, - }); - console.log("Verb curve drawn."); - - // Example 7: Draw a Verb NURBS surface by lofting curves - // Create curves that will be lofted to form a surface - const curve1Points = [ - [-60, 20, -5], - [-50, 20, 0], - [-40, 20, -5], - ] as Inputs.Base.Point3[]; - - const curve2Points = [ - [-60, 30, 0], - [-50, 30, 5], - [-40, 30, 0], - ] as Inputs.Base.Point3[]; - - const curve3Points = [ - [-60, 40, -5], - [-50, 40, 0], - [-40, 40, -5], - ] as Inputs.Base.Point3[]; - - // Create the curves - const curve1 = bitbybit.verb.curve.createCurveByPoints({ - points: curve1Points, - degree: 2, - }); - - const curve2 = bitbybit.verb.curve.createCurveByPoints({ - points: curve2Points, - degree: 2, - }); - - const curve3 = bitbybit.verb.curve.createCurveByPoints({ - points: curve3Points, - degree: 2, - }); - - // Loft the curves to create a surface - const surface = bitbybit.verb.surface.createSurfaceByLoftingCurves({ - curves: [curve3, curve2, curve1], - degreeV: 2, - }); - - const surfaceDrawOptions = new Inputs.Draw.DrawBasicGeometryOptions(); - surfaceDrawOptions.colours = "#8800ff"; // Purple - surfaceDrawOptions.opacity = 0.8; - await bitbybit.draw.drawAnyAsync({ - entity: surface, - options: surfaceDrawOptions, - }); - console.log("Verb surface drawn."); - - // Example 8: Draw a 30x30x30 grid of points with alternating blue and white colors - // This tests GPU instancing performance with 27,000 points - console.log("Creating 30x30x30 point grid (27,000 points)..."); - const gridSize = 30; - const spacing = 1.5; - const gridOffset = [-150, 0, 0]; // Move grid away from other geometry - - const gridPoints: Inputs.Base.Point3[] = []; - const gridColors: string[] = []; - - for (let x = 0; x < gridSize; x++) { - for (let y = 0; y < gridSize; y++) { - for (let z = 0; z < gridSize; z++) { - gridPoints.push([ - gridOffset[0] + x * spacing, - gridOffset[1] + y * spacing, - gridOffset[2] + z * spacing - ]); - // Alternating blue and white based on checkerboard pattern - const isBlue = (x + y + z) % 2 === 0; - gridColors.push(isBlue ? "#0066ff" : "#ffffff"); - } - } - } - - const gridDrawOptions = new Inputs.Draw.DrawBasicGeometryOptions(); - gridDrawOptions.colours = gridColors; - gridDrawOptions.size = 0.4; - gridDrawOptions.colorMapStrategy = Inputs.Base.colorMapStrategyEnum.lastColorRemainder; - - console.time("Draw 27,000 points"); - await bitbybit.draw.drawAnyAsync({ - entity: gridPoints, - options: gridDrawOptions, - }); - console.timeEnd("Draw 27,000 points"); - console.log("30x30x30 point grid drawn with GPU instancing."); - - // Example 9: Draw a 30x30x30 grid of polylines with alternating colors - // Creates lines along X, Y, and Z axes forming a 3D grid - console.log("Creating 30x30x30 polyline grid..."); - const polylineGridSize = 30; - const polylineSpacing = 1.5; - const polylineGridOffset = [-150, -60, 0]; // Position below the point grid - - const gridPolylines: Inputs.Base.Polyline3[] = []; - const polylineColors: string[] = []; - - // Create lines along X axis (for each Y,Z position) - for (let y = 0; y < polylineGridSize; y++) { - for (let z = 0; z < polylineGridSize; z++) { - const startX = polylineGridOffset[0]; - const endX = polylineGridOffset[0] + (polylineGridSize - 1) * polylineSpacing; - const posY = polylineGridOffset[1] + y * polylineSpacing; - const posZ = polylineGridOffset[2] + z * polylineSpacing; - - gridPolylines.push({ - points: [ - [startX, posY, posZ], - [endX, posY, posZ] - ] - }); - // Alternating colors based on position - const isOrange = (y + z) % 2 === 0; - polylineColors.push(isOrange ? "#ff6600" : "#00ffcc"); - } - } - - // Create lines along Y axis (for each X,Z position) - for (let x = 0; x < polylineGridSize; x++) { - for (let z = 0; z < polylineGridSize; z++) { - const posX = polylineGridOffset[0] + x * polylineSpacing; - const startY = polylineGridOffset[1]; - const endY = polylineGridOffset[1] + (polylineGridSize - 1) * polylineSpacing; - const posZ = polylineGridOffset[2] + z * polylineSpacing; - - gridPolylines.push({ - points: [ - [posX, startY, posZ], - [posX, endY, posZ] - ] - }); - const isPurple = (x + z) % 2 === 0; - polylineColors.push(isPurple ? "#9933ff" : "#ffff00"); - } - } - - // Create lines along Z axis (for each X,Y position) - for (let x = 0; x < polylineGridSize; x++) { - for (let y = 0; y < polylineGridSize; y++) { - const posX = polylineGridOffset[0] + x * polylineSpacing; - const posY = polylineGridOffset[1] + y * polylineSpacing; - const startZ = polylineGridOffset[2]; - const endZ = polylineGridOffset[2] + (polylineGridSize - 1) * polylineSpacing; - - gridPolylines.push({ - points: [ - [posX, posY, startZ], - [posX, posY, endZ] - ] - }); - const isPink = (x + y) % 2 === 0; - polylineColors.push(isPink ? "#ff0099" : "#00ff66"); - } - } - - const polylineGridDrawOptions = new Inputs.Draw.DrawBasicGeometryOptions(); - polylineGridDrawOptions.colours = polylineColors; - polylineGridDrawOptions.size = 1; - polylineGridDrawOptions.colorMapStrategy = Inputs.Base.colorMapStrategyEnum.lastColorRemainder; - - console.log(`Drawing ${gridPolylines.length} polylines...`); - console.time("Draw polyline grid"); - await bitbybit.draw.drawAnyAsync({ - entity: gridPolylines, - options: polylineGridDrawOptions, - }); - console.timeEnd("Draw polyline grid"); - console.log("30x30x30 polyline grid drawn with per-polyline colors."); - - // --- Arrow Examples --- - // Example: Draw a single polyline with an arrow at the end - const arrowPolyline = { - points: [ - [-80, 0, 0], - [-80, 10, 5], - [-70, 15, 10], - [-60, 10, 5], - ], - } as Inputs.Base.Polyline3; - const arrowPolylineOptions = new Inputs.Draw.DrawBasicGeometryOptions(); - arrowPolylineOptions.colours = "#00ff88"; // Green - arrowPolylineOptions.size = 3; - arrowPolylineOptions.arrowSize = 3; // Arrow size - arrowPolylineOptions.arrowAngle = 25; // Arrow angle in degrees - await bitbybit.draw.drawAnyAsync({ - entity: arrowPolyline, - options: arrowPolylineOptions, - }); - console.log("Polyline with arrow drawn."); - - // Example: Draw multiple polylines with arrows (different sizes) - const arrowPolylines = [ - { - points: [ - [-80, -30, 0], - [-70, -25, 0], - [-60, -30, 0], - ], - }, - { - points: [ - [-80, -35, 0], - [-70, -30, 0], - [-60, -35, 0], - ], - }, - { - points: [ - [-80, -40, 0], - [-70, -35, 0], - [-60, -40, 0], - ], - }, - ] as Inputs.Base.Polyline3[]; - const arrowPolylinesOptions = new Inputs.Draw.DrawBasicGeometryOptions(); - arrowPolylinesOptions.colours = ["#ff0000", "#00ff00", "#0000ff"]; // RGB - arrowPolylinesOptions.size = 2; - arrowPolylinesOptions.arrowSize = 2.5; - arrowPolylinesOptions.arrowAngle = 30; - await bitbybit.draw.drawAnyAsync({ - entity: arrowPolylines, - options: arrowPolylinesOptions, - }); - console.log("Multiple polylines with arrows drawn."); - - // Example: Draw OCCT wire with edge arrows to show orientation - const wirePoints = [ - [-80, -60, 0], - [-70, -55, 5], - [-60, -60, 0], - [-50, -65, -5], - ] as Inputs.Base.Point3[]; - const wire = await bitbybit.occt.shapes.wire.createPolylineWire({ - points: wirePoints, - }); - const wireDrawOptions = new Inputs.Draw.DrawOcctShapeOptions(); - wireDrawOptions.edgeColour = "#ff8800"; // Orange edges - wireDrawOptions.edgeWidth = 3; - wireDrawOptions.drawEdges = true; - wireDrawOptions.drawFaces = false; - wireDrawOptions.edgeArrowSize = 3; // Arrow size on edges - wireDrawOptions.edgeArrowAngle = 25; // Arrow angle - await bitbybit.draw.drawAnyAsync({ - entity: wire, - options: wireDrawOptions, - }); - console.log("OCCT wire with edge orientation arrows drawn."); - - console.log("All drawing examples completed."); -} diff --git a/examples/vite/playcanvas/starter-template/src/models/current.ts b/examples/vite/playcanvas/starter-template/src/models/current.ts deleted file mode 100644 index 3195e34d..00000000 --- a/examples/vite/playcanvas/starter-template/src/models/current.ts +++ /dev/null @@ -1,11 +0,0 @@ -import * as pc from "playcanvas"; -import { GUI } from "lil-gui"; - -export type Current = { - group1: pc.Entity | undefined; - group2: pc.Entity | undefined; - dimensions: pc.Entity | undefined; - light1: pc.Entity | undefined; - ground: pc.Entity | undefined; - gui: GUI | undefined; -}; diff --git a/examples/vite/playcanvas/starter-template/src/models/model.ts b/examples/vite/playcanvas/starter-template/src/models/model.ts deleted file mode 100644 index 5260fda4..00000000 --- a/examples/vite/playcanvas/starter-template/src/models/model.ts +++ /dev/null @@ -1,24 +0,0 @@ -export type Model = { - uHex: number; - vHex: number; - height: number; - ellipse1MinRad: number; - ellipse1MaxRad: number; - ellipse2MinRad: number; - ellipse2MaxRad: number; - ellipse2RotX: number; - ellipse2RotY: number; - ellipse3MinRad: number; - ellipse3MaxRad: number; - ellipse3YRot: number; - drawEdges: boolean; - drawFaces: boolean; - color1: string; - color2: string; - finalPrecision: number; - rotationEnabled: boolean; - downloadSTL?: () => void; - downloadStep?: () => void; - downloadGLB?: () => void; - update?: () => void; -}; diff --git a/examples/vite/playcanvas/starter-template/src/workers/jscad.worker.ts b/examples/vite/playcanvas/starter-template/src/workers/jscad.worker.ts deleted file mode 100644 index eeed36fd..00000000 --- a/examples/vite/playcanvas/starter-template/src/workers/jscad.worker.ts +++ /dev/null @@ -1,12 +0,0 @@ -import { - initializationComplete, - onMessageInput, -} from "@bitbybit-dev/jscad-worker"; - -import("@bitbybit-dev/jscad/jscad-generated").then((s) => { - initializationComplete(s.default()); -}); - -addEventListener("message", ({ data }) => { - onMessageInput(data, postMessage); -}); diff --git a/examples/vite/playcanvas/starter-template/src/workers/manifold.worker.ts b/examples/vite/playcanvas/starter-template/src/workers/manifold.worker.ts deleted file mode 100644 index 09625fcb..00000000 --- a/examples/vite/playcanvas/starter-template/src/workers/manifold.worker.ts +++ /dev/null @@ -1,21 +0,0 @@ -import { - initializationComplete, - onMessageInput, -} from "@bitbybit-dev/manifold-worker"; -import Module from "manifold-3d"; - -const init = async () => { - const wasm = await Module({ - locateFile: () => { - return "https://cdn.jsdelivr.net/gh/bitbybit-dev/bitbybit-assets@0.21.0/wasm/manifold-3-3-2.wasm"; - }, - }); - wasm.setup(); - initializationComplete(wasm); -}; - -init(); - -addEventListener("message", ({ data }) => { - onMessageInput(data, postMessage); -}); diff --git a/examples/vite/playcanvas/starter-template/src/workers/occt.worker.ts b/examples/vite/playcanvas/starter-template/src/workers/occt.worker.ts deleted file mode 100644 index 492dfd44..00000000 --- a/examples/vite/playcanvas/starter-template/src/workers/occt.worker.ts +++ /dev/null @@ -1,14 +0,0 @@ -import initOpenCascade from "@bitbybit-dev/occt/bitbybit-dev-occt/cdn"; -import type { OpenCascadeInstance } from "@bitbybit-dev/occt/bitbybit-dev-occt/bitbybit-dev-occt.js"; -import { - initializationComplete, - onMessageInput, -} from "@bitbybit-dev/occt-worker"; - -initOpenCascade().then((occ: OpenCascadeInstance) => { - initializationComplete(occ, undefined); -}); - -addEventListener("message", ({ data }) => { - onMessageInput(data, postMessage); -}); diff --git a/examples/vite/threejs/starter-template/src/main.ts b/examples/vite/threejs/starter-template/src/main.ts index 838581cc..6b5172b4 100644 --- a/examples/vite/threejs/starter-template/src/main.ts +++ b/examples/vite/threejs/starter-template/src/main.ts @@ -7,10 +7,7 @@ start(); async function start() { const sceneOptions = new Inputs.ThreeJSScene.InitThreeJSDto(); sceneOptions.canvasId = "three-canvas"; - sceneOptions.orbitCameraOptions = new Inputs.ThreeJSCamera.OrbitCameraDto(); - sceneOptions.orbitCameraOptions.yaw = 45; - sceneOptions.orbitCameraOptions.pitch = 25; - sceneOptions.orbitCameraOptions.distance = 12.0; + sceneOptions.sceneSize = 10; const { scene, startAnimationLoop } = initThreeJS(sceneOptions); startAnimationLoop(); const bitbybit = new BitByBitBase(); diff --git a/packages/dev/babylonjs/lib/api/bitbybit/babylon/index.ts b/packages/dev/babylonjs/lib/api/bitbybit/babylon/index.ts index e7d7e6f7..403f6847 100644 --- a/packages/dev/babylonjs/lib/api/bitbybit/babylon/index.ts +++ b/packages/dev/babylonjs/lib/api/bitbybit/babylon/index.ts @@ -10,3 +10,4 @@ export * from "./ray"; export * from "./scene"; export * from "./engine"; export * from "./transforms"; +export * from "./scene-helper"; diff --git a/packages/dev/babylonjs/lib/api/bitbybit/babylon/scene-helper.ts b/packages/dev/babylonjs/lib/api/bitbybit/babylon/scene-helper.ts new file mode 100644 index 00000000..8fb2e720 --- /dev/null +++ b/packages/dev/babylonjs/lib/api/bitbybit/babylon/scene-helper.ts @@ -0,0 +1,229 @@ +import * as BABYLON from "@babylonjs/core"; +import { BabylonJSScene, InitBabylonJSResult } from "../../inputs/babylon-scene-helper-inputs"; +import { BabylonCamera } from "../../inputs/babylon-camera-inputs"; + +/** + * Helper function to initialize a basic BabylonJS scene with lights, shadows, and optional ground plane. + * This provides a quick setup for common use cases while remaining fully customizable. + * + * @param inputs Configuration options for the scene + * @returns Object containing the scene, engine, lights, ground, and dispose function + * + * @example + * import { initBabylonJS, BabylonJSScene } from "@bitbybit-dev/babylonjs"; + * + * // Basic usage with defaults + * const { scene, engine } = initBabylonJS(); + * + * // Custom configuration + * const options = new BabylonJSScene.InitBabylonJSDto(); + * options.sceneSize = 500; + * options.enableGround = true; + * options.enableShadows = true; + * const { scene, engine, directionalLight } = initBabylonJS(options); + */ +export function initBabylonJS(inputs?: BabylonJSScene.InitBabylonJSDto): InitBabylonJSResult { + const config = inputs || new BabylonJSScene.InitBabylonJSDto(); + + // Get or create canvas + let canvas: HTMLCanvasElement; + if (config.canvasId) { + const existingCanvas = document.getElementById(config.canvasId) as HTMLCanvasElement; + if (!existingCanvas) { + throw new Error(`Canvas with id "${config.canvasId}" not found`); + } + canvas = existingCanvas; + } else { + canvas = document.createElement("canvas"); + canvas.style.width = "100%"; + canvas.style.height = "100%"; + canvas.style.display = "block"; + document.body.appendChild(canvas); + } + + // Create engine + const engine = new BABYLON.Engine(canvas, true, { + preserveDrawingBuffer: true, + stencil: true, + }); + engine.setHardwareScalingLevel(0.5); + // Create scene + const scene = new BABYLON.Scene(engine); + scene.metadata = { shadowGenerators: [] }; // Important for Bitbybit integration + + // Parse background color + const bgColor = BABYLON.Color3.FromHexString(config.backgroundColor); + scene.clearColor = new BABYLON.Color4(bgColor.r, bgColor.g, bgColor.b, 1); + + // Calculate positions based on scene size + const lightHeight = config.sceneSize * 0.75; + const lightOffset = config.sceneSize * 0.5; + + // Create hemispheric light (ambient-like lighting from sky and ground) + const hemisphericLight = new BABYLON.HemisphericLight( + "hemisphericLight", + new BABYLON.Vector3(0, lightHeight, 0), + scene + ); + hemisphericLight.diffuse = BABYLON.Color3.FromHexString(config.hemisphereLightSkyColor); + hemisphericLight.groundColor = BABYLON.Color3.FromHexString(config.hemisphereLightGroundColor); + hemisphericLight.intensity = config.hemisphereLightIntensity; + + // Create directional light (sun-like light with shadows) + const directionalLight = new BABYLON.DirectionalLight( + "directionalLight", + new BABYLON.Vector3(-lightOffset, -lightHeight, -lightOffset).normalize(), + scene + ); + directionalLight.diffuse = BABYLON.Color3.FromHexString(config.directionalLightColor); + directionalLight.intensity = config.directionalLightIntensity; + directionalLight.position = new BABYLON.Vector3(lightOffset, lightHeight, lightOffset); + + // Configure shadows + if (config.enableShadows) { + const shadowGenerator = new BABYLON.ShadowGenerator(config.shadowMapSize, directionalLight); + shadowGenerator.useBlurExponentialShadowMap = true; + shadowGenerator.blurKernel = 32; + shadowGenerator.darkness = 0.3; + + // Store shadow generator in scene metadata for Bitbybit integration + scene.metadata.shadowGenerators.push(shadowGenerator); + } + + // Create ground plane + let ground: BABYLON.Mesh | null = null; + if (config.enableGround) { + const groundSize = config.sceneSize * config.groundScaleFactor; + ground = BABYLON.MeshBuilder.CreateGround("ground", { + width: groundSize, + height: groundSize + }, scene); + + ground.position = new BABYLON.Vector3( + config.groundCenter[0], + config.groundCenter[1], + config.groundCenter[2] + ); + + const groundMaterial = new BABYLON.StandardMaterial("groundMaterial", scene); + groundMaterial.diffuseColor = BABYLON.Color3.FromHexString(config.groundColor); + groundMaterial.alpha = config.groundOpacity; + groundMaterial.backFaceCulling = false; + ground.material = groundMaterial; + ground.receiveShadows = config.enableShadows; + } + + // Create arc rotate camera if enabled + let arcRotateCamera: BABYLON.ArcRotateCamera | null = null; + if (config.enableArcRotateCamera) { + // Use provided camera options or create new DTO with defaults as single source of truth + const camOpts = config.arcRotateCameraOptions ?? new BabylonCamera.ArcRotateCameraDto(); + + // Compute scene-aware overrides for values that should scale with scene size + // Reference scene size of 20 units is used as baseline for sensitivity calculations + const referenceSize = 20; + const sizeRatio = config.sceneSize / referenceSize; + + // Only override these values if user didn't provide custom camera options + const userProvidedCameraOptions = config.arcRotateCameraOptions !== undefined; + const effectiveRadius = userProvidedCameraOptions ? camOpts.radius : config.sceneSize * Math.sqrt(2); + const effectiveLowerRadiusLimit = userProvidedCameraOptions && camOpts.lowerRadiusLimit !== undefined ? camOpts.lowerRadiusLimit : config.sceneSize * 0.1; + const effectiveUpperRadiusLimit = userProvidedCameraOptions && camOpts.upperRadiusLimit !== undefined ? camOpts.upperRadiusLimit : config.sceneSize * 10; + const effectivePanningSensibility = userProvidedCameraOptions ? camOpts.panningSensibility : camOpts.panningSensibility / sizeRatio; + const effectiveWheelPrecision = userProvidedCameraOptions ? camOpts.wheelPrecision : Math.max(0.1, camOpts.wheelPrecision / sizeRatio); + const effectiveMaxZ = userProvidedCameraOptions && camOpts.maxZ !== undefined ? camOpts.maxZ : config.sceneSize * 50; + + const target = new BABYLON.Vector3(camOpts.target[0], camOpts.target[1], camOpts.target[2]); + const alphaRad = BABYLON.Tools.ToRadians(camOpts.alpha); + const betaRad = BABYLON.Tools.ToRadians(camOpts.beta); + + arcRotateCamera = new BABYLON.ArcRotateCamera( + "arcRotateCamera", + alphaRad, + betaRad, + effectiveRadius, + target, + scene + ); + + // Apply all settings from DTO, with scene-aware overrides where applicable + arcRotateCamera.angularSensibilityX = camOpts.angularSensibilityX; + arcRotateCamera.angularSensibilityY = camOpts.angularSensibilityY; + arcRotateCamera.lowerRadiusLimit = effectiveLowerRadiusLimit; + arcRotateCamera.upperRadiusLimit = effectiveUpperRadiusLimit; + arcRotateCamera.panningSensibility = effectivePanningSensibility; + arcRotateCamera.wheelPrecision = effectiveWheelPrecision; + arcRotateCamera.maxZ = effectiveMaxZ; + arcRotateCamera.minZ = 0.1; + + // Apply beta limits from DTO + arcRotateCamera.lowerBetaLimit = BABYLON.Tools.ToRadians(camOpts.lowerBetaLimit); + arcRotateCamera.upperBetaLimit = BABYLON.Tools.ToRadians(camOpts.upperBetaLimit); + + // Apply optional alpha limits only if user provided them + if (userProvidedCameraOptions && camOpts.lowerAlphaLimit !== undefined) { + arcRotateCamera.lowerAlphaLimit = BABYLON.Tools.ToRadians(camOpts.lowerAlphaLimit); + } + if (userProvidedCameraOptions && camOpts.upperAlphaLimit !== undefined) { + arcRotateCamera.upperAlphaLimit = BABYLON.Tools.ToRadians(camOpts.upperAlphaLimit); + } + + arcRotateCamera.attachControl(canvas, true); + } + + // Handle window resize + const onWindowResize = (): void => { + engine.resize(); + }; + + window.addEventListener("resize", onWindowResize, false); + + // Start render loop helper + const startRenderLoop = (onRender?: () => void): void => { + engine.runRenderLoop(() => { + if (scene.activeCamera) { + scene.render(); + if (onRender) { + onRender(); + } + } + }); + }; + + // Dispose function to clean up resources + const dispose = (): void => { + window.removeEventListener("resize", onWindowResize); + engine.stopRenderLoop(); + + if (ground) { + ground.material?.dispose(); + ground.dispose(); + } + + hemisphericLight.dispose(); + directionalLight.dispose(); + + if (arcRotateCamera) { + arcRotateCamera.dispose(); + } + + scene.dispose(); + engine.dispose(); + + // Remove canvas if we created it + if (!config.canvasId && canvas.parentNode) { + canvas.parentNode.removeChild(canvas); + } + }; + + return { + scene, + engine, + hemisphericLight, + directionalLight, + ground, + arcRotateCamera, + startRenderLoop, + dispose + }; +} diff --git a/packages/dev/babylonjs/lib/api/bitbybit/index.ts b/packages/dev/babylonjs/lib/api/bitbybit/index.ts index 79973ab8..9e85ad4d 100644 --- a/packages/dev/babylonjs/lib/api/bitbybit/index.ts +++ b/packages/dev/babylonjs/lib/api/bitbybit/index.ts @@ -1,2 +1,3 @@ export * from "./babylon"; +export * from "./babylon/index"; export * from "./draw"; \ No newline at end of file diff --git a/packages/dev/babylonjs/lib/api/init-kernels.ts b/packages/dev/babylonjs/lib/api/init-kernels.ts index 10928896..6c24c0f4 100644 --- a/packages/dev/babylonjs/lib/api/init-kernels.ts +++ b/packages/dev/babylonjs/lib/api/init-kernels.ts @@ -32,23 +32,6 @@ export { type InitKernelsResult, type WorkerInstances, type WorkerOptions }; * @param bitbybit - BitByBitBase instance * @param options - Initialization options including which kernels to enable * @returns Promise with initialization result and the bitbybit instance - * - * @example - * ```typescript - * import { BitByBitBase, initBitByBit } from "@bitbybit-dev/babylonjs"; - * - * const scene = new BABYLON.Scene(engine); - * const bitbybit = new BitByBitBase(); - * - * await initBitByBit(scene, bitbybit, { - * enableOCCT: true, - * enableJSCAD: true, - * enableManifold: false, - * loadFonts: ["roboto"], // Optional: specify fonts, or omit to skip loading - * }); - * - * // Now you can use bitbybit.occt, bitbybit.jscad, etc. - * ``` */ export async function initBitByBit( scene: BABYLON.Scene, diff --git a/packages/dev/babylonjs/lib/api/inputs/babylon-scene-helper-inputs.ts b/packages/dev/babylonjs/lib/api/inputs/babylon-scene-helper-inputs.ts new file mode 100644 index 00000000..f2e786b2 --- /dev/null +++ b/packages/dev/babylonjs/lib/api/inputs/babylon-scene-helper-inputs.ts @@ -0,0 +1,187 @@ +/* eslint-disable @typescript-eslint/no-namespace */ + +import * as BABYLON from "@babylonjs/core"; +import { Base } from "./base-inputs"; +import { BabylonCamera } from "./babylon-camera-inputs"; + +/** + * Result object returned by initBabylonJS helper function. + */ +export interface InitBabylonJSResult { + /** The BabylonJS scene */ + scene: BABYLON.Scene; + /** The BabylonJS engine */ + engine: BABYLON.Engine; + /** The hemispheric light */ + hemisphericLight: BABYLON.HemisphericLight; + /** The directional light (for shadows) */ + directionalLight: BABYLON.DirectionalLight; + /** The ground mesh (if enabled) */ + ground: BABYLON.Mesh | null; + /** The arc rotate camera (if enabled) */ + arcRotateCamera: BABYLON.ArcRotateCamera | null; + /** Start the render loop */ + startRenderLoop: (onRender?: () => void) => void; + /** Cleanup function to remove resize listener and dispose resources */ + dispose: () => void; +} + +export namespace BabylonJSScene { + export class InitBabylonJSDto { + constructor( + canvasId?: string, + sceneSize?: number, + backgroundColor?: string, + enableShadows?: boolean, + enableGround?: boolean, + groundCenter?: Base.Point3, + groundScaleFactor?: number, + groundColor?: string, + groundOpacity?: number, + hemisphereLightSkyColor?: string, + hemisphereLightGroundColor?: string, + hemisphereLightIntensity?: number, + directionalLightColor?: string, + directionalLightIntensity?: number, + shadowMapSize?: number + ) { + if (canvasId !== undefined) { this.canvasId = canvasId; } + if (sceneSize !== undefined) { this.sceneSize = sceneSize; } + if (backgroundColor !== undefined) { this.backgroundColor = backgroundColor; } + if (enableShadows !== undefined) { this.enableShadows = enableShadows; } + if (enableGround !== undefined) { this.enableGround = enableGround; } + if (groundCenter !== undefined) { this.groundCenter = groundCenter; } + if (groundScaleFactor !== undefined) { this.groundScaleFactor = groundScaleFactor; } + if (groundColor !== undefined) { this.groundColor = groundColor; } + if (groundOpacity !== undefined) { this.groundOpacity = groundOpacity; } + if (hemisphereLightSkyColor !== undefined) { this.hemisphereLightSkyColor = hemisphereLightSkyColor; } + if (hemisphereLightGroundColor !== undefined) { this.hemisphereLightGroundColor = hemisphereLightGroundColor; } + if (hemisphereLightIntensity !== undefined) { this.hemisphereLightIntensity = hemisphereLightIntensity; } + if (directionalLightColor !== undefined) { this.directionalLightColor = directionalLightColor; } + if (directionalLightIntensity !== undefined) { this.directionalLightIntensity = directionalLightIntensity; } + if (shadowMapSize !== undefined) { this.shadowMapSize = shadowMapSize; } + } + + /** + * The ID of the canvas element to render to. If not provided, a new canvas will be created and appended to document.body. + * @default undefined + */ + canvasId?: string; + + /** + * The size of the scene in world units. This determines ground size, light positions, and shadow bounds. + * @default 20 + * @minimum 1 + * @maximum Infinity + * @step 10 + */ + sceneSize = 20; + + /** + * Background color of the scene in hex format. + * @default "#1a1c1f" + */ + backgroundColor = "#1a1c1f"; + + /** + * Enable shadow mapping for realistic shadows. + * @default true + */ + enableShadows = true; + + /** + * Enable the ground plane. + * @default true + */ + enableGround = true; + + /** + * Center position of the ground plane [x, y, z]. + * @default [0, 0, 0] + */ + groundCenter: Base.Point3 = [0, 0, 0]; + + /** + * Scale factor for the ground size relative to scene size. Values greater than 1 make the ground larger than the scene size. + * @default 2 + * @minimum 0.5 + * @maximum 10 + * @step 0.5 + */ + groundScaleFactor = 2; + + /** + * Color of the ground plane in hex format. + * @default "#333333" + */ + groundColor = "#333333"; + + /** + * Opacity of the ground plane (0 = fully transparent, 1 = fully opaque). + * @default 1 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + groundOpacity = 1; + + /** + * Sky color for the hemisphere light (illumination from above). + * @default "#ffffff" + */ + hemisphereLightSkyColor = "#ffffff"; + + /** + * Ground color for the hemisphere light (illumination from below). + * @default "#444444" + */ + hemisphereLightGroundColor = "#444444"; + + /** + * Intensity of the hemisphere light. + * @default 1 + * @minimum 0 + * @maximum 10 + * @step 0.1 + */ + hemisphereLightIntensity = 1; + + /** + * Color of the directional light (sun light). + * @default "#ffffff" + */ + directionalLightColor = "#ffffff"; + + /** + * Intensity of the directional light. + * @default 1.5 + * @minimum 0 + * @maximum 10 + * @step 0.1 + */ + directionalLightIntensity = 1.5; + + /** + * Size of the shadow map in pixels (higher = sharper shadows but more GPU intensive). + * @default 2048 + * @minimum 256 + * @maximum 8192 + * @step 256 + */ + shadowMapSize = 2048; + + /** + * Enable automatic creation of an arc rotate camera. + * @default true + */ + enableArcRotateCamera = true; + + /** + * Options for the arc rotate camera. Only used if enableArcRotateCamera is true. + * If not provided, scene-aware defaults will be computed based on sceneSize. + * Uses the same DTO as the standalone arc rotate camera creation. + * @optional true + */ + arcRotateCameraOptions?: BabylonCamera.ArcRotateCameraDto; + } +} diff --git a/packages/dev/babylonjs/lib/api/inputs/index.ts b/packages/dev/babylonjs/lib/api/inputs/index.ts index 35ac58d9..46a56f2f 100644 --- a/packages/dev/babylonjs/lib/api/inputs/index.ts +++ b/packages/dev/babylonjs/lib/api/inputs/index.ts @@ -13,6 +13,7 @@ export * from "./babylon-tools-inputs"; export * from "./babylon-mesh-builder"; export * from "./babylon-gizmo-inputs"; export * from "./babylon-webxr"; +export * from "./babylon-scene-helper-inputs"; export * from "./scene-inputs"; export * from "./node-inputs"; export * from "./draw-inputs"; diff --git a/packages/dev/playcanvas/lib/api/bitbybit/index.ts b/packages/dev/playcanvas/lib/api/bitbybit/index.ts index 74add6b8..6801a039 100644 --- a/packages/dev/playcanvas/lib/api/bitbybit/index.ts +++ b/packages/dev/playcanvas/lib/api/bitbybit/index.ts @@ -1 +1,3 @@ -export * from "./draw"; \ No newline at end of file +export * from "./draw"; +export * from "./playcanvas"; +export * from "./playcanvas/index"; \ No newline at end of file diff --git a/packages/dev/playcanvas/lib/api/bitbybit/playcanvas/index.ts b/packages/dev/playcanvas/lib/api/bitbybit/playcanvas/index.ts index c07f33a3..61520d9c 100644 --- a/packages/dev/playcanvas/lib/api/bitbybit/playcanvas/index.ts +++ b/packages/dev/playcanvas/lib/api/bitbybit/playcanvas/index.ts @@ -1,2 +1,3 @@ export * from "./camera"; export * from "./orbit-camera"; +export * from "./scene-helper"; diff --git a/packages/dev/playcanvas/lib/api/bitbybit/playcanvas/orbit-camera.ts b/packages/dev/playcanvas/lib/api/bitbybit/playcanvas/orbit-camera.ts index 6411ee70..14eadfa0 100644 --- a/packages/dev/playcanvas/lib/api/bitbybit/playcanvas/orbit-camera.ts +++ b/packages/dev/playcanvas/lib/api/bitbybit/playcanvas/orbit-camera.ts @@ -248,7 +248,7 @@ export class PlayCanvasOrbitCamera { const updatePosition = (): void => { const quatYaw = new pc.Quat().setFromEulerAngles(0, state._yaw, 0); - const quatPitch = new pc.Quat().setFromEulerAngles(state._pitch, 0, 0); + const quatPitch = new pc.Quat().setFromEulerAngles(-state._pitch, 0, 0); const finalQuat = new pc.Quat(); finalQuat.mul2(quatYaw, quatPitch); @@ -449,7 +449,7 @@ export class PlayCanvasOrbitCamera { const onMouseMove = (event: pc.MouseEvent): void => { if (lookButtonDown) { - orbitCamera.pitch -= event.dy * options.orbitSensitivity; + orbitCamera.pitch += event.dy * options.orbitSensitivity; orbitCamera.yaw -= event.dx * options.orbitSensitivity; } else if (panButtonDown) { pan(event); @@ -537,7 +537,7 @@ export class PlayCanvasOrbitCamera { if (touches.length === 1) { const touchPoint = touches[0]; - orbitCamera.pitch -= (touchPoint.y - lastTouchPoint.y) * options.orbitSensitivity; + orbitCamera.pitch += (touchPoint.y - lastTouchPoint.y) * options.orbitSensitivity; orbitCamera.yaw -= (touchPoint.x - lastTouchPoint.x) * options.orbitSensitivity; lastTouchPoint.set(touchPoint.x, touchPoint.y); } else if (touches.length === 2) { diff --git a/packages/dev/playcanvas/lib/api/bitbybit/playcanvas/scene-helper.ts b/packages/dev/playcanvas/lib/api/bitbybit/playcanvas/scene-helper.ts new file mode 100644 index 00000000..1fd875b9 --- /dev/null +++ b/packages/dev/playcanvas/lib/api/bitbybit/playcanvas/scene-helper.ts @@ -0,0 +1,705 @@ +import * as pc from "playcanvas"; +import { PlayCanvasScene, InitPlayCanvasResult, PlayCanvasOrbitCameraInstance, PlayCanvasInputHandler, PlayCanvasOrbitCameraController } from "../../inputs/playcanvas-scene-helper-inputs"; +import { PlayCanvasCamera } from "../../inputs/playcanvas-camera-inputs"; + +/** + * Helper function to initialize a basic PlayCanvas scene with lights, shadows, and optional ground plane. + * This provides a quick setup for common use cases while remaining fully customizable. + * + * @param inputs Configuration options for the scene + * @returns Object containing the app, scene, lights, ground, and dispose function + * + * @example + * ```typescript + * import { initPlayCanvas, PlayCanvasScene } from "@bitbybit-dev/playcanvas"; + * + * // Basic usage with defaults + * const { app, scene } = initPlayCanvas(); + * + * // Custom configuration + * const options = new PlayCanvasScene.InitPlayCanvasDto(); + * options.sceneSize = 500; + * options.enableGround = true; + * options.enableShadows = true; + * const { app, scene, directionalLight } = initPlayCanvas(options); + * ``` + */ +export function initPlayCanvas(inputs?: PlayCanvasScene.InitPlayCanvasDto): InitPlayCanvasResult { + const config = inputs || new PlayCanvasScene.InitPlayCanvasDto(); + + // Get or create canvas + let canvas: HTMLCanvasElement; + if (config.canvasId) { + const existingCanvas = document.getElementById(config.canvasId) as HTMLCanvasElement; + if (!existingCanvas) { + throw new Error(`Canvas with id "${config.canvasId}" not found`); + } + canvas = existingCanvas; + } else { + canvas = document.createElement("canvas"); + canvas.style.width = "100%"; + canvas.style.height = "100%"; + canvas.style.display = "block"; + document.body.appendChild(canvas); + } + + // Create PlayCanvas application + const app = new pc.Application(canvas, { + graphicsDeviceOptions: { + antialias: true, + alpha: false, + }, + mouse: new pc.Mouse(canvas), + touch: new pc.TouchDevice(canvas), + }); + + // Fill the window and automatically change resolution to be the same as the canvas size + app.setCanvasFillMode(pc.FILLMODE_FILL_WINDOW); + app.setCanvasResolution(pc.RESOLUTION_AUTO); + + // Set pixel ratio for sharper rendering on high-DPI displays + app.graphicsDevice.maxPixelRatio = window.devicePixelRatio; + + // Create root scene entity + const scene = new pc.Entity("scene"); + app.root.addChild(scene); + + // Parse background color and set camera clear color later + const bgColor = hexToRgb(config.backgroundColor); + + // Calculate positions based on scene size + const lightHeight = config.sceneSize * 0.75; + const lightOffset = config.sceneSize * 0.5; + + // Set ambient light + const ambientColor = hexToRgb(config.ambientLightColor); + app.scene.ambientLight = new pc.Color( + ambientColor.r * config.ambientLightIntensity, + ambientColor.g * config.ambientLightIntensity, + ambientColor.b * config.ambientLightIntensity + ); + + // Create directional light + const directionalLight = new pc.Entity("directionalLight"); + const lightColor = hexToRgb(config.directionalLightColor); + + // Scale bias values with scene size for consistent shadow quality + // Smaller scenes need smaller bias, larger scenes need larger bias + const scaledShadowBias = 0.005 * config.sceneSize; + const scaledNormalOffsetBias = 0.01 * config.sceneSize; + + directionalLight.addComponent("light", { + type: "directional", + color: new pc.Color(lightColor.r, lightColor.g, lightColor.b), + intensity: config.directionalLightIntensity, + castShadows: config.enableShadows, + shadowResolution: config.shadowMapSize, + // Shadow distance tightly bounds the scene for maximum effective resolution + shadowDistance: config.sceneSize * 3, + // Bias values scaled proportionally to scene size + shadowBias: scaledShadowBias, + normalOffsetBias: scaledNormalOffsetBias, + numCascades: 4, + cascadeDistribution: 0.5, + }); + directionalLight.setPosition(lightOffset, lightHeight, lightOffset); + directionalLight.setEulerAngles(45, 30, 0); + scene.addChild(directionalLight); + + // Create ground plane + let ground: pc.Entity | null = null; + if (config.enableGround) { + const groundSize = config.sceneSize * config.groundScaleFactor; + ground = new pc.Entity("ground"); + ground.addComponent("render", { + type: "plane", + }); + ground.setLocalScale(groundSize, 1, groundSize); + ground.setPosition( + config.groundCenter[0], + config.groundCenter[1], + config.groundCenter[2] + ); + + // Create ground material + const groundMaterial = new pc.StandardMaterial(); + const groundColor = hexToRgb(config.groundColor); + groundMaterial.diffuse = new pc.Color(groundColor.r, groundColor.g, groundColor.b); + groundMaterial.opacity = config.groundOpacity; + if (config.groundOpacity < 1) { + groundMaterial.blendType = pc.BLEND_NORMAL; + } + groundMaterial.update(); + + const meshInstances = ground.render?.meshInstances; + if (meshInstances) { + for (const mi of meshInstances) { + mi.material = groundMaterial; + } + } + + scene.addChild(ground); + } + + // Create orbit camera if enabled + let orbitCamera: PlayCanvasOrbitCameraController | null = null; + if (config.enableOrbitCamera) { + // Use provided camera options or create new DTO with defaults as single source of truth + const camOpts = config.orbitCameraOptions ?? new PlayCanvasCamera.OrbitCameraDto(); + + // Compute scene-aware overrides for values that should scale with scene size + // Reference scene size of 20 units is used as baseline for sensitivity calculations + const referenceSize = 20; + const sizeRatio = config.sceneSize / referenceSize; + + // Only override these values if user didn't provide custom camera options + const userProvidedCameraOptions = config.orbitCameraOptions !== undefined; + const effectiveDistance = userProvidedCameraOptions ? camOpts.distance : config.sceneSize * Math.sqrt(2); + const effectiveDistanceMin = userProvidedCameraOptions ? camOpts.distanceMin : config.sceneSize * 0.05; + const effectiveDistanceMax = userProvidedCameraOptions ? camOpts.distanceMax : config.sceneSize * 10; + const effectiveDistanceSensitivity = userProvidedCameraOptions ? camOpts.distanceSensitivity : camOpts.distanceSensitivity * sizeRatio; + + // Create camera entity + const cameraEntity = new pc.Entity("OrbitCamera"); + cameraEntity.addComponent("camera", { + clearColor: new pc.Color(bgColor.r, bgColor.g, bgColor.b, 1), + fov: 70, + nearClip: 0.1, + farClip: config.sceneSize * 50, + }); + scene.addChild(cameraEntity); + + // Create orbit camera controller using DTO defaults with scene-aware overrides + orbitCamera = createOrbitCameraController(app, cameraEntity, { + autoRender: camOpts.autoRender, + distanceMax: effectiveDistanceMax, + distanceMin: effectiveDistanceMin, + pitchAngleMax: camOpts.pitchAngleMax, + pitchAngleMin: camOpts.pitchAngleMin, + inertiaFactor: camOpts.inertiaFactor, + focusEntity: camOpts.focusEntity || null, + frameOnStart: camOpts.frameOnStart, + pivotPoint: camOpts.pivotPoint, + distance: effectiveDistance, + pitch: camOpts.pitch, + yaw: camOpts.yaw, + orbitSensitivity: camOpts.orbitSensitivity, + distanceSensitivity: effectiveDistanceSensitivity, + }); + } + + // Handle window resize + const onWindowResize = (): void => { + app.resizeCanvas(); + }; + window.addEventListener("resize", onWindowResize, false); + + // Start the application + app.start(); + + // Dispose function to clean up resources + const dispose = (): void => { + window.removeEventListener("resize", onWindowResize); + + if (orbitCamera) { + orbitCamera.destroy(); + } + + if (ground) { + const meshInstances = ground.render?.meshInstances; + if (meshInstances) { + for (const mi of meshInstances) { + mi.material?.destroy(); + } + } + ground.destroy(); + } + + directionalLight.destroy(); + scene.destroy(); + + app.destroy(); + + // Remove canvas if we created it + if (!config.canvasId && canvas.parentNode) { + canvas.parentNode.removeChild(canvas); + } + }; + + return { + app, + scene, + directionalLight, + ground, + orbitCamera, + dispose + }; +} + +/** + * Parse hex color to RGB values (0-1 range) + */ +function hexToRgb(hex: string): { r: number; g: number; b: number } { + const result = /^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i.exec(hex); + if (result) { + return { + r: parseInt(result[1], 16) / 255, + g: parseInt(result[2], 16) / 255, + b: parseInt(result[3], 16) / 255 + }; + } + return { r: 0.1, g: 0.1, b: 0.1 }; +} + +interface OrbitCameraConfig { + autoRender: boolean; + distanceMax: number; + distanceMin: number; + pitchAngleMax: number; + pitchAngleMin: number; + inertiaFactor: number; + focusEntity: pc.Entity | null; + frameOnStart: boolean; + pivotPoint: [number, number, number]; + distance: number; + pitch: number; + yaw: number; + orbitSensitivity: number; + distanceSensitivity: number; +} + +interface OrbitCameraState { + _modelsAabb: pc.BoundingBox; + _pivotPoint: pc.Vec3; + _targetPivotPoint: pc.Vec3; + _lastFramePivotPoint: pc.Vec3; + _yaw: number; + _pitch: number; + _distance: number; + _targetYaw: number; + _targetPitch: number; + _targetDistance: number; + _autoRenderDefault: boolean; +} + +function createOrbitCameraController( + app: pc.Application, + cameraEntity: pc.Entity, + config: OrbitCameraConfig +): PlayCanvasOrbitCameraController { + const orbitCamera = createOrbitCameraInstance(cameraEntity, config); + + // Set initial position + const pivotVec = new pc.Vec3(config.pivotPoint[0], config.pivotPoint[1], config.pivotPoint[2]); + orbitCamera.pivotPoint = pivotVec; + orbitCamera.distance = config.distance; + orbitCamera.pitch = config.pitch; + orbitCamera.yaw = config.yaw; + + // Setup mouse input + const mouseInput = createMouseInput(app, cameraEntity, orbitCamera, { + orbitSensitivity: config.orbitSensitivity, + distanceSensitivity: config.distanceSensitivity + }); + + // Setup touch input + const touchInput = createTouchInput(app, cameraEntity, orbitCamera, { + orbitSensitivity: config.orbitSensitivity, + distanceSensitivity: config.distanceSensitivity + }); + + // Register update function + const updateFn = (dt: number): void => { + orbitCamera.update(dt); + }; + app.on("update", updateFn); + + // Focus on entity if provided + if (config.focusEntity && config.frameOnStart) { + orbitCamera.focus(config.focusEntity); + } + + return { + orbitCamera, + cameraEntity, + mouseInput, + touchInput, + update: updateFn, + destroy: (): void => { + app.off("update", updateFn); + mouseInput?.destroy(); + touchInput?.destroy(); + } + }; +} + +function createOrbitCameraInstance(entity: pc.Entity, config: OrbitCameraConfig): PlayCanvasOrbitCameraInstance { + const state: OrbitCameraState = { + _modelsAabb: new pc.BoundingBox(), + _pivotPoint: new pc.Vec3(), + _targetPivotPoint: new pc.Vec3(), + _lastFramePivotPoint: new pc.Vec3(), + _yaw: 0, + _pitch: 0, + _distance: 0, + _targetYaw: 0, + _targetPitch: 0, + _targetDistance: 0, + _autoRenderDefault: true + }; + + const distanceBetween = new pc.Vec3(); + + const clampDistance = (distance: number): number => { + return Math.max(config.distanceMin, Math.min(config.distanceMax, distance)); + }; + + const clampPitchAngle = (pitch: number): number => { + return Math.max(config.pitchAngleMin, Math.min(config.pitchAngleMax, pitch)); + }; + + const calcYaw = (quat: pc.Quat): number => { + const transformedForward = new pc.Vec3(); + quat.transformVector(pc.Vec3.FORWARD, transformedForward); + return Math.atan2(-transformedForward.x, -transformedForward.z) * pc.math.RAD_TO_DEG; + }; + + const calcPitch = (quat: pc.Quat, yaw: number): number => { + const quatWithoutYaw = new pc.Quat(); + const yawOffset = new pc.Quat(); + yawOffset.setFromEulerAngles(0, -yaw, 0); + quatWithoutYaw.mul2(yawOffset, quat); + + const transformedForward = new pc.Vec3(); + quatWithoutYaw.transformVector(pc.Vec3.FORWARD, transformedForward); + + return Math.atan2(transformedForward.y, -transformedForward.z) * pc.math.RAD_TO_DEG; + }; + + const updatePosition = (): void => { + const quatYaw = new pc.Quat().setFromEulerAngles(0, state._yaw, 0); + const quatPitch = new pc.Quat().setFromEulerAngles(-state._pitch, 0, 0); + + const finalQuat = new pc.Quat(); + finalQuat.mul2(quatYaw, quatPitch); + + const offsetPos = new pc.Vec3(0, 0, state._distance); + finalQuat.transformVector(offsetPos, offsetPos); + + entity.setPosition( + state._pivotPoint.x + offsetPos.x, + state._pivotPoint.y + offsetPos.y, + state._pivotPoint.z + offsetPos.z + ); + entity.setRotation(finalQuat); + }; + + const removeInertia = (): void => { + state._yaw = state._targetYaw; + state._pitch = state._targetPitch; + state._distance = state._targetDistance; + state._pivotPoint.copy(state._targetPivotPoint); + }; + + const buildAabb = (entityToBuild: pc.Entity | pc.GraphNode, modelsAdded: number): number => { + let count = modelsAdded; + if (entityToBuild instanceof pc.Entity && entityToBuild.model) { + const mi = entityToBuild.model.meshInstances; + for (let i = 0; i < mi.length; i++) { + if (mi[i].visible) { + if (count === 0) { + state._modelsAabb.copy(mi[i].aabb); + } else { + state._modelsAabb.add(mi[i].aabb); + } + count += 1; + } + } + } + + const children = entityToBuild.children; + for (let i = 0; i < children.length; i++) { + count = buildAabb(children[i], count); + } + + return count; + }; + + return { + autoRender: config.autoRender, + distanceMax: config.distanceMax, + distanceMin: config.distanceMin, + pitchAngleMax: config.pitchAngleMax, + pitchAngleMin: config.pitchAngleMin, + inertiaFactor: config.inertiaFactor, + focusEntity: config.focusEntity, + frameOnStart: config.frameOnStart, + + get distance(): number { + return state._targetDistance; + }, + set distance(value: number) { + state._targetDistance = clampDistance(value); + }, + + get pitch(): number { + return state._targetPitch; + }, + set pitch(value: number) { + state._targetPitch = clampPitchAngle(value); + }, + + get yaw(): number { + return state._targetYaw; + }, + set yaw(value: number) { + state._targetYaw = value; + const diff = state._targetYaw - state._yaw; + const reminder = diff % 360; + if (reminder > 180) { + state._yaw += 360; + } else if (reminder < -180) { + state._yaw -= 360; + } + }, + + get pivotPoint(): pc.Vec3 { + return state._targetPivotPoint; + }, + set pivotPoint(value: pc.Vec3) { + state._targetPivotPoint.copy(value); + }, + + focus(focusEntity: pc.Entity): void { + buildAabb(focusEntity, 0); + const halfExtents = state._modelsAabb.halfExtents; + let distance = Math.max(halfExtents.x, Math.max(halfExtents.y, halfExtents.z)); + const camera = entity.camera; + if (camera) { + distance = distance / Math.tan(0.5 * camera.fov * camera.aspectRatio * pc.math.DEG_TO_RAD); + } + distance = distance * 2; + this.distance = distance; + removeInertia(); + state._pivotPoint.copy(state._modelsAabb.center); + }, + + resetAndLookAtPoint(resetPoint: pc.Vec3, lookAtPoint: pc.Vec3): void { + this.pivotPoint.copy(lookAtPoint); + entity.setPosition(resetPoint); + entity.lookAt(lookAtPoint); + + distanceBetween.sub2(lookAtPoint, resetPoint); + this.distance = distanceBetween.length(); + this.pivotPoint.copy(lookAtPoint); + + const cameraQuat = entity.getRotation(); + this.yaw = calcYaw(cameraQuat); + this.pitch = calcPitch(cameraQuat, this.yaw); + + removeInertia(); + updatePosition(); + }, + + resetAndLookAtEntity(resetPoint: pc.Vec3, targetEntity: pc.Entity): void { + buildAabb(targetEntity, 0); + this.resetAndLookAtPoint(resetPoint, state._modelsAabb.center); + }, + + reset(yaw: number, pitch: number, distance: number): void { + this.pitch = pitch; + this.yaw = yaw; + this.distance = distance; + removeInertia(); + updatePosition(); + }, + + update(dt: number): void { + const t = config.inertiaFactor === 0 ? 1 : Math.min(dt / config.inertiaFactor, 1); + state._distance = pc.math.lerp(state._distance, state._targetDistance, t); + state._yaw = pc.math.lerp(state._yaw, state._targetYaw, t); + state._pitch = pc.math.lerp(state._pitch, state._targetPitch, t); + state._pivotPoint.lerp(state._pivotPoint, state._targetPivotPoint, t); + + updatePosition(); + } + }; +} + +function createMouseInput( + app: pc.Application, + entity: pc.Entity, + orbitCamera: PlayCanvasOrbitCameraInstance, + options: { orbitSensitivity: number; distanceSensitivity: number } +): PlayCanvasInputHandler | null { + if (!app.mouse) return null; + + const mouse = app.mouse; + let lookButtonDown = false; + let panButtonDown = false; + const lastPoint = new pc.Vec2(); + + const fromWorldPoint = new pc.Vec3(); + const toWorldPoint = new pc.Vec3(); + const worldDiff = new pc.Vec3(); + + const pan = (screenPoint: { x: number; y: number }): void => { + const camera = entity.camera; + if (!camera) return; + + const distance = orbitCamera.distance; + camera.screenToWorld(screenPoint.x, screenPoint.y, distance, fromWorldPoint); + camera.screenToWorld(lastPoint.x, lastPoint.y, distance, toWorldPoint); + worldDiff.sub2(toWorldPoint, fromWorldPoint); + orbitCamera.pivotPoint.add(worldDiff); + }; + + const onMouseDown = (event: pc.MouseEvent): void => { + switch (event.button) { + case pc.MOUSEBUTTON_LEFT: + lookButtonDown = true; + break; + case pc.MOUSEBUTTON_MIDDLE: + case pc.MOUSEBUTTON_RIGHT: + panButtonDown = true; + break; + } + }; + + const onMouseUp = (event: pc.MouseEvent): void => { + switch (event.button) { + case pc.MOUSEBUTTON_LEFT: + lookButtonDown = false; + break; + case pc.MOUSEBUTTON_MIDDLE: + case pc.MOUSEBUTTON_RIGHT: + panButtonDown = false; + break; + } + }; + + const onMouseMove = (event: pc.MouseEvent): void => { + if (lookButtonDown) { + orbitCamera.pitch += event.dy * options.orbitSensitivity; + orbitCamera.yaw -= event.dx * options.orbitSensitivity; + } else if (panButtonDown) { + pan(event); + } + lastPoint.set(event.x, event.y); + }; + + const onMouseWheel = (event: pc.MouseEvent): void => { + orbitCamera.distance += event.wheelDelta * options.distanceSensitivity * (orbitCamera.distance * 0.1); + event.event.preventDefault(); + }; + + const onMouseOut = (): void => { + lookButtonDown = false; + panButtonDown = false; + }; + + mouse.on(pc.EVENT_MOUSEDOWN, onMouseDown); + mouse.on(pc.EVENT_MOUSEUP, onMouseUp); + mouse.on(pc.EVENT_MOUSEMOVE, onMouseMove); + mouse.on(pc.EVENT_MOUSEWHEEL, onMouseWheel); + window.addEventListener("mouseout", onMouseOut, false); + mouse.disableContextMenu(); + + return { + destroy: (): void => { + mouse.off(pc.EVENT_MOUSEDOWN, onMouseDown); + mouse.off(pc.EVENT_MOUSEUP, onMouseUp); + mouse.off(pc.EVENT_MOUSEMOVE, onMouseMove); + mouse.off(pc.EVENT_MOUSEWHEEL, onMouseWheel); + window.removeEventListener("mouseout", onMouseOut); + } + }; +} + +function createTouchInput( + app: pc.Application, + entity: pc.Entity, + orbitCamera: PlayCanvasOrbitCameraInstance, + options: { orbitSensitivity: number; distanceSensitivity: number } +): PlayCanvasInputHandler | null { + if (!app.touch) return null; + + const touch = app.touch; + const lastTouchPoint = new pc.Vec2(); + const lastPinchMidPoint = new pc.Vec2(); + let lastPinchDistance = 0; + + const fromWorldPoint = new pc.Vec3(); + const toWorldPoint = new pc.Vec3(); + const worldDiff = new pc.Vec3(); + const pinchMidPoint = new pc.Vec2(); + + const getPinchDistance = (pointA: { x: number; y: number }, pointB: { x: number; y: number }): number => { + const dx = pointA.x - pointB.x; + const dy = pointA.y - pointB.y; + return Math.sqrt((dx * dx) + (dy * dy)); + }; + + const calcMidPoint = (pointA: { x: number; y: number }, pointB: { x: number; y: number }, result: pc.Vec2): void => { + result.set(pointB.x - pointA.x, pointB.y - pointA.y); + result.mulScalar(0.5); + result.x += pointA.x; + result.y += pointA.y; + }; + + const pan = (midPoint: pc.Vec2): void => { + const camera = entity.camera; + if (!camera) return; + + const distance = orbitCamera.distance; + camera.screenToWorld(midPoint.x, midPoint.y, distance, fromWorldPoint); + camera.screenToWorld(lastPinchMidPoint.x, lastPinchMidPoint.y, distance, toWorldPoint); + worldDiff.sub2(toWorldPoint, fromWorldPoint); + orbitCamera.pivotPoint.add(worldDiff); + }; + + const onTouchStartEndCancel = (event: pc.TouchEvent): void => { + const touches = event.touches; + if (touches.length === 1) { + lastTouchPoint.set(touches[0].x, touches[0].y); + } else if (touches.length === 2) { + lastPinchDistance = getPinchDistance(touches[0], touches[1]); + calcMidPoint(touches[0], touches[1], lastPinchMidPoint); + } + }; + + const onTouchMove = (event: pc.TouchEvent): void => { + const touches = event.touches; + + if (touches.length === 1) { + const touchPoint = touches[0]; + orbitCamera.pitch += (touchPoint.y - lastTouchPoint.y) * options.orbitSensitivity; + orbitCamera.yaw -= (touchPoint.x - lastTouchPoint.x) * options.orbitSensitivity; + lastTouchPoint.set(touchPoint.x, touchPoint.y); + } else if (touches.length === 2) { + const currentPinchDistance = getPinchDistance(touches[0], touches[1]); + const diffInPinchDistance = currentPinchDistance - lastPinchDistance; + lastPinchDistance = currentPinchDistance; + + orbitCamera.distance += (diffInPinchDistance * options.distanceSensitivity * 0.1) * (orbitCamera.distance * 0.1); + + calcMidPoint(touches[0], touches[1], pinchMidPoint); + pan(pinchMidPoint); + lastPinchMidPoint.copy(pinchMidPoint); + } + }; + + touch.on(pc.EVENT_TOUCHSTART, onTouchStartEndCancel); + touch.on(pc.EVENT_TOUCHEND, onTouchStartEndCancel); + touch.on(pc.EVENT_TOUCHCANCEL, onTouchStartEndCancel); + touch.on(pc.EVENT_TOUCHMOVE, onTouchMove); + + return { + destroy: (): void => { + touch.off(pc.EVENT_TOUCHSTART, onTouchStartEndCancel); + touch.off(pc.EVENT_TOUCHEND, onTouchStartEndCancel); + touch.off(pc.EVENT_TOUCHCANCEL, onTouchStartEndCancel); + touch.off(pc.EVENT_TOUCHMOVE, onTouchMove); + } + }; +} diff --git a/packages/dev/playcanvas/lib/api/draw-helper.ts b/packages/dev/playcanvas/lib/api/draw-helper.ts index 8a3a142c..9dba2ba6 100644 --- a/packages/dev/playcanvas/lib/api/draw-helper.ts +++ b/packages/dev/playcanvas/lib/api/draw-helper.ts @@ -1030,7 +1030,8 @@ export class DrawHelper extends DrawHelperCore { const meshInstance = new pc.MeshInstance(mesh, mat); const lineEntity = new pc.Entity(this.generateEntityId("lines")); lineEntity.addComponent("render", { - meshInstances: [meshInstance] + meshInstances: [meshInstance], + castShadows: false }); return lineEntity; } @@ -1146,7 +1147,8 @@ export class DrawHelper extends DrawHelperCore { const meshInstance = new pc.MeshInstance(mesh, mat); const lineEntity = new pc.Entity(this.generateEntityId("lines")); lineEntity.addComponent("render", { - meshInstances: [meshInstance] + meshInstances: [meshInstance], + castShadows: false }); return lineEntity; } diff --git a/packages/dev/playcanvas/lib/api/inputs/index.ts b/packages/dev/playcanvas/lib/api/inputs/index.ts index 7a31a712..47f5f756 100644 --- a/packages/dev/playcanvas/lib/api/inputs/index.ts +++ b/packages/dev/playcanvas/lib/api/inputs/index.ts @@ -1,4 +1,5 @@ export * from "./playcanvas-camera-inputs"; +export * from "./playcanvas-scene-helper-inputs"; export * from "./draw-inputs"; export * from "./base-inputs"; export * from "@bitbybit-dev/core/lib/api/inputs/inputs"; \ No newline at end of file diff --git a/packages/dev/playcanvas/lib/api/inputs/playcanvas-camera-inputs.ts b/packages/dev/playcanvas/lib/api/inputs/playcanvas-camera-inputs.ts index d5918525..e1542522 100644 --- a/packages/dev/playcanvas/lib/api/inputs/playcanvas-camera-inputs.ts +++ b/packages/dev/playcanvas/lib/api/inputs/playcanvas-camera-inputs.ts @@ -102,20 +102,20 @@ export namespace PlayCanvasCamera { orbitSensitivity = 0.3; /** * Mouse zoom sensitivity (how much the camera zooms with mouse wheel) - * @default 0.15 + * @default 0.5 * @minimum 0 * @maximum 10 * @step 0.01 */ - distanceSensitivity = 0.15; + distanceSensitivity = 0.5; /** * Inertia factor for smooth camera movement (0 = no inertia, 1 = maximum inertia) - * @default 0 + * @default 0.1 * @minimum 0 * @maximum 1 * @step 0.1 */ - inertiaFactor = 0; + inertiaFactor = 0.1; /** * Whether the camera should automatically render the scene * @default true diff --git a/packages/dev/playcanvas/lib/api/inputs/playcanvas-scene-helper-inputs.ts b/packages/dev/playcanvas/lib/api/inputs/playcanvas-scene-helper-inputs.ts new file mode 100644 index 00000000..18d670b7 --- /dev/null +++ b/packages/dev/playcanvas/lib/api/inputs/playcanvas-scene-helper-inputs.ts @@ -0,0 +1,217 @@ +/* eslint-disable @typescript-eslint/no-namespace */ + +import * as pc from "playcanvas"; +import { Base } from "./base-inputs"; +import { PlayCanvasCamera } from "./playcanvas-camera-inputs"; + +/** + * Interface for orbit camera internal state and methods (PlayCanvas). + */ +export interface PlayCanvasOrbitCameraInstance { + autoRender: boolean; + distanceMax: number; + distanceMin: number; + pitchAngleMax: number; + pitchAngleMin: number; + inertiaFactor: number; + focusEntity: pc.Entity | null; + frameOnStart: boolean; + distance: number; + pitch: number; + yaw: number; + pivotPoint: pc.Vec3; + focus(focusEntity: pc.Entity): void; + resetAndLookAtPoint(resetPoint: pc.Vec3, lookAtPoint: pc.Vec3): void; + resetAndLookAtEntity(resetPoint: pc.Vec3, entity: pc.Entity): void; + reset(yaw: number, pitch: number, distance: number): void; + update(dt: number): void; +} + +/** + * Interface for input handlers (mouse, touch). + */ +export interface PlayCanvasInputHandler { + destroy(): void; +} + +/** + * Orbit camera controller returned by create method. + */ +export interface PlayCanvasOrbitCameraController { + orbitCamera: PlayCanvasOrbitCameraInstance; + cameraEntity: pc.Entity; + mouseInput: PlayCanvasInputHandler | null; + touchInput: PlayCanvasInputHandler | null; + update: (dt: number) => void; + destroy: () => void; +} + +/** + * Result object returned by initPlayCanvas helper function. + */ +export interface InitPlayCanvasResult { + /** The PlayCanvas application */ + app: pc.Application; + /** The root scene entity */ + scene: pc.Entity; + /** The directional light entity */ + directionalLight: pc.Entity; + /** The ground entity (if enabled) */ + ground: pc.Entity | null; + /** The orbit camera controller (if enabled) */ + orbitCamera: PlayCanvasOrbitCameraController | null; + /** Cleanup function to dispose resources */ + dispose: () => void; +} + +export namespace PlayCanvasScene { + export class InitPlayCanvasDto { + constructor( + canvasId?: string, + sceneSize?: number, + backgroundColor?: string, + enableShadows?: boolean, + enableGround?: boolean, + groundCenter?: Base.Point3, + groundScaleFactor?: number, + groundColor?: string, + groundOpacity?: number, + ambientLightColor?: string, + ambientLightIntensity?: number, + directionalLightColor?: string, + directionalLightIntensity?: number, + shadowMapSize?: number + ) { + if (canvasId !== undefined) { this.canvasId = canvasId; } + if (sceneSize !== undefined) { this.sceneSize = sceneSize; } + if (backgroundColor !== undefined) { this.backgroundColor = backgroundColor; } + if (enableShadows !== undefined) { this.enableShadows = enableShadows; } + if (enableGround !== undefined) { this.enableGround = enableGround; } + if (groundCenter !== undefined) { this.groundCenter = groundCenter; } + if (groundScaleFactor !== undefined) { this.groundScaleFactor = groundScaleFactor; } + if (groundColor !== undefined) { this.groundColor = groundColor; } + if (groundOpacity !== undefined) { this.groundOpacity = groundOpacity; } + if (ambientLightColor !== undefined) { this.ambientLightColor = ambientLightColor; } + if (ambientLightIntensity !== undefined) { this.ambientLightIntensity = ambientLightIntensity; } + if (directionalLightColor !== undefined) { this.directionalLightColor = directionalLightColor; } + if (directionalLightIntensity !== undefined) { this.directionalLightIntensity = directionalLightIntensity; } + if (shadowMapSize !== undefined) { this.shadowMapSize = shadowMapSize; } + } + + /** + * The ID of the canvas element to render to. If not provided, a new canvas will be created and appended to document.body. + * @default undefined + */ + canvasId?: string; + + /** + * The size of the scene in world units. This determines ground size, light positions, and shadow bounds. + * @default 20 + * @minimum 1 + * @maximum Infinity + * @step 10 + */ + sceneSize = 20; + + /** + * Background color of the scene in hex format. + * @default "#1a1c1f" + */ + backgroundColor = "#1a1c1f"; + + /** + * Enable shadow mapping for realistic shadows. + * @default true + */ + enableShadows = true; + + /** + * Enable the ground plane. + * @default true + */ + enableGround = true; + + /** + * Center position of the ground plane [x, y, z]. + * @default [0, 0, 0] + */ + groundCenter: Base.Point3 = [0, 0, 0]; + + /** + * Scale factor for the ground size relative to scene size. Values greater than 1 make the ground larger than the scene size. + * @default 2 + * @minimum 0.5 + * @maximum 10 + * @step 0.5 + */ + groundScaleFactor = 2; + + /** + * Color of the ground plane in hex format. + * @default "#333333" + */ + groundColor = "#333333"; + + /** + * Opacity of the ground plane (0 = fully transparent, 1 = fully opaque). + * @default 1 + * @minimum 0 + * @maximum 1 + * @step 0.1 + */ + groundOpacity = 1; + + /** + * Ambient light color. PlayCanvas uses ambient light instead of hemisphere light. + * @default "#888888" + */ + ambientLightColor = "#888888"; + + /** + * Intensity factor for ambient light (applied to RGB values). + * @default 1 + * @minimum 0 + * @maximum 10 + * @step 0.1 + */ + ambientLightIntensity = 1; + + /** + * Color of the directional light (sun light). + * @default "#ffffff" + */ + directionalLightColor = "#ffffff"; + + /** + * Intensity of the directional light. + * @default 1.5 + * @minimum 0 + * @maximum 10 + * @step 0.1 + */ + directionalLightIntensity = 1.5; + + /** + * Size of the shadow map in pixels (higher = sharper shadows but more GPU intensive). + * @default 2048 + * @minimum 256 + * @maximum 8192 + * @step 256 + */ + shadowMapSize = 2048; + + /** + * Enable automatic creation of an orbit camera controller. + * @default true + */ + enableOrbitCamera = true; + + /** + * Options for the orbit camera. Only used if enableOrbitCamera is true. + * If not provided, scene-aware defaults will be computed based on sceneSize. + * Uses the same DTO as the standalone orbit camera creation. + * @optional true + */ + orbitCameraOptions?: PlayCanvasCamera.OrbitCameraDto; + } +} diff --git a/packages/dev/threejs/lib/api/bitbybit/threejs/scene-helper.ts b/packages/dev/threejs/lib/api/bitbybit/threejs/scene-helper.ts index a5e5bc62..2c457862 100644 --- a/packages/dev/threejs/lib/api/bitbybit/threejs/scene-helper.ts +++ b/packages/dev/threejs/lib/api/bitbybit/threejs/scene-helper.ts @@ -1,6 +1,6 @@ import * as THREEJS from "three"; import { ThreeJSScene, InitThreeJSResult } from "../../inputs/threejs-scene-inputs"; -import { OrbitCameraController } from "../../inputs/threejs-camera-inputs"; +import { OrbitCameraController, ThreeJSCamera } from "../../inputs/threejs-camera-inputs"; import { createOrbitCamera } from "./orbit-camera"; /** @@ -139,10 +139,40 @@ export function initThreeJS(inputs?: ThreeJSScene.InitThreeJSDto): InitThreeJSRe // Create orbit camera if enabled let orbitCamera: OrbitCameraController | null = null; if (config.enableOrbitCamera) { - const camOpts = config.orbitCameraOptions; - // Pass the DTO directly to createOrbitCamera, adding scene and domElement + // Use provided camera options or create new DTO with defaults as single source of truth + const camOpts = config.orbitCameraOptions ?? new ThreeJSCamera.OrbitCameraDto(); + + // Compute scene-aware overrides for values that should scale with scene size + // Reference scene size of 20 units is used as baseline for sensitivity calculations + const referenceSize = 20; + const sizeRatio = config.sceneSize / referenceSize; + + // Only override these values if user didn't provide custom camera options + const userProvidedCameraOptions = config.orbitCameraOptions !== undefined; + const effectiveDistance = userProvidedCameraOptions ? camOpts.distance : config.sceneSize * Math.sqrt(2); + const effectiveDistanceMin = userProvidedCameraOptions ? camOpts.distanceMin : config.sceneSize * 0.05; + const effectiveDistanceMax = userProvidedCameraOptions ? camOpts.distanceMax : config.sceneSize * 10; + const effectiveDistanceSensitivity = userProvidedCameraOptions ? camOpts.distanceSensitivity : camOpts.distanceSensitivity * sizeRatio; + const effectivePanSensitivity = userProvidedCameraOptions ? camOpts.panSensitivity : camOpts.panSensitivity * sizeRatio; + + // Create orbit camera using DTO defaults with scene-aware overrides orbitCamera = createOrbitCamera({ - ...camOpts, + pivotPoint: camOpts.pivotPoint, + distance: effectiveDistance, + pitch: camOpts.pitch, + yaw: camOpts.yaw, + distanceMin: effectiveDistanceMin, + distanceMax: effectiveDistanceMax, + pitchAngleMin: camOpts.pitchAngleMin, + pitchAngleMax: camOpts.pitchAngleMax, + orbitSensitivity: camOpts.orbitSensitivity, + distanceSensitivity: effectiveDistanceSensitivity, + panSensitivity: effectivePanSensitivity, + inertiaFactor: camOpts.inertiaFactor, + autoRender: camOpts.autoRender, + frameOnStart: camOpts.frameOnStart, + enableDamping: camOpts.enableDamping, + dampingFactor: camOpts.dampingFactor, scene, domElement: renderer.domElement, }); diff --git a/packages/dev/threejs/lib/api/inputs/threejs-camera-inputs.ts b/packages/dev/threejs/lib/api/inputs/threejs-camera-inputs.ts index ef441bfa..5c2607cb 100644 --- a/packages/dev/threejs/lib/api/inputs/threejs-camera-inputs.ts +++ b/packages/dev/threejs/lib/api/inputs/threejs-camera-inputs.ts @@ -173,12 +173,12 @@ export namespace ThreeJSCamera { panSensitivity = 1; /** * Inertia factor for smooth camera movement (0 = no inertia, 1 = maximum inertia) - * @default 0 + * @default 0.1 * @minimum 0 * @maximum 1 * @step 0.1 */ - inertiaFactor = 0; + inertiaFactor = 0.1; /** * Whether the camera should trigger automatic rendering on changes * @default true diff --git a/packages/dev/threejs/lib/api/inputs/threejs-scene-inputs.ts b/packages/dev/threejs/lib/api/inputs/threejs-scene-inputs.ts index b1fd0cd1..f46be5bb 100644 --- a/packages/dev/threejs/lib/api/inputs/threejs-scene-inputs.ts +++ b/packages/dev/threejs/lib/api/inputs/threejs-scene-inputs.ts @@ -178,12 +178,10 @@ export namespace ThreeJSScene { /** * Options for the orbit camera. Only used if enableOrbitCamera is true. + * If not provided, scene-aware defaults will be computed based on sceneSize. * Uses the same DTO as the standalone orbit camera creation. + * @optional true */ - orbitCameraOptions: ThreeJSCamera.OrbitCameraDto = new ThreeJSCamera.OrbitCameraDto( - 10, // distance - 25, // pitch - 45 // yaw - ); + orbitCameraOptions?: ThreeJSCamera.OrbitCameraDto; } } From 0d4184980ddb9aa887f95a39a5267fdd932e2d54 Mon Sep 17 00:00:00 2001 From: Matas Ubarevicius Date: Tue, 13 Jan 2026 08:07:50 +0200 Subject: [PATCH 10/31] working unit tests for scene-helpers --- .../api/bitbybit/babylon/scene-helper.test.ts | 792 +++ .../lib/api/inputs/draw-inputs.test.ts | 2 +- packages/dev/babylonjs/package-lock.json | 4660 +++++++---------- packages/dev/babylonjs/package.json | 25 +- .../lib/api/__mocks__/playcanvas.mock.ts | 3 + .../bitbybit/playcanvas/scene-helper.test.ts | 772 +++ .../inputs/playcanvas-camera-inputs.test.ts | 6 +- packages/dev/playcanvas/package-lock.json | 4660 +++++++---------- packages/dev/playcanvas/package.json | 27 +- .../api/bitbybit/threejs/scene-helper.test.ts | 876 ++++ .../api/inputs/threejs-camera-inputs.test.ts | 2 +- packages/dev/threejs/package-lock.json | 4660 +++++++---------- packages/dev/threejs/package.json | 27 +- 13 files changed, 8051 insertions(+), 8461 deletions(-) create mode 100644 packages/dev/babylonjs/lib/api/bitbybit/babylon/scene-helper.test.ts create mode 100644 packages/dev/playcanvas/lib/api/bitbybit/playcanvas/scene-helper.test.ts create mode 100644 packages/dev/threejs/lib/api/bitbybit/threejs/scene-helper.test.ts diff --git a/packages/dev/babylonjs/lib/api/bitbybit/babylon/scene-helper.test.ts b/packages/dev/babylonjs/lib/api/bitbybit/babylon/scene-helper.test.ts new file mode 100644 index 00000000..488c08a9 --- /dev/null +++ b/packages/dev/babylonjs/lib/api/bitbybit/babylon/scene-helper.test.ts @@ -0,0 +1,792 @@ +/** + * @jest-environment jsdom + */ +/* eslint-disable @typescript-eslint/no-unused-vars */ +/* eslint-disable @typescript-eslint/no-empty-function */ +import { initBabylonJS } from "./scene-helper"; +import { BabylonJSScene } from "../../inputs/babylon-scene-helper-inputs"; +import { BabylonCamera } from "../../inputs/babylon-camera-inputs"; + +// Type definitions for mock objects +interface MockVector3Type { + x: number; + y: number; + z: number; + set(x: number, y: number, z: number): void; +} + +interface MockColor3Type { + r: number; + g: number; + b: number; +} + +interface MockColor4Type { + r: number; + g: number; + b: number; + a: number; +} + +interface MockMeshType { + name: string; + position: MockVector3Type; + receiveShadows: boolean; + material: object | null; + _groundWidth?: number; + _groundHeight?: number; +} + +// Mock BabylonJS core module +jest.mock("@babylonjs/core", () => { + const actualMock = jest.requireActual("../../__mocks__/babylonjs.mock"); + + class MockEngine { + _canvas: HTMLCanvasElement; + _renderLoop: (() => void) | null = null; + + constructor(canvas: HTMLCanvasElement, _antialias?: boolean, _options?: object) { + this._canvas = canvas; + } + + setHardwareScalingLevel(_level: number) { /* mock */ } + + resize() { /* mock */ } + + runRenderLoop(callback: () => void) { + this._renderLoop = callback; + } + + stopRenderLoop() { + this._renderLoop = null; + } + + dispose() { /* mock */ } + } + + class MockBabylonScene { + _meshes: MockMeshType[] = []; + metadata: { shadowGenerators: MockShadowGenerator[] } = { shadowGenerators: [] }; + clearColor: MockColor4Type | null = null; + activeCamera: MockArcRotateCamera | null = null; + + dispose() { /* mock */ } + render() { /* mock */ } + } + + class MockHemisphericLight { + name: string; + direction: MockVector3Type; + diffuse: MockColor3Type; + groundColor: MockColor3Type; + intensity = 1; + + constructor(name: string, direction: MockVector3Type, _scene: MockBabylonScene) { + this.name = name; + this.direction = direction; + this.diffuse = new actualMock.MockColor3(1, 1, 1); + this.groundColor = new actualMock.MockColor3(0.5, 0.5, 0.5); + } + + dispose() { /* mock */ } + } + + class MockDirectionalLight { + name: string; + direction: MockVector3Type; + position: MockVector3Type; + diffuse: MockColor3Type; + intensity = 1; + + constructor(name: string, direction: MockVector3Type, _scene: MockBabylonScene) { + this.name = name; + this.direction = direction; + this.position = new actualMock.MockVector3(); + this.diffuse = new actualMock.MockColor3(1, 1, 1); + } + + dispose() { /* mock */ } + } + + class MockShadowGenerator { + useBlurExponentialShadowMap = false; + blurKernel = 0; + darkness = 0; + + constructor(_mapSize: number, _light: MockDirectionalLight) { /* mock */ } + } + + class MockArcRotateCamera { + name: string; + alpha: number; + beta: number; + radius: number; + target: MockVector3Type; + angularSensibilityX = 1000; + angularSensibilityY = 1000; + lowerRadiusLimit: number | null = null; + upperRadiusLimit: number | null = null; + panningSensibility = 1000; + wheelPrecision = 3; + maxZ = 10000; + minZ = 0.1; + lowerBetaLimit: number | null = null; + upperBetaLimit: number | null = null; + lowerAlphaLimit: number | null = null; + upperAlphaLimit: number | null = null; + + constructor( + name: string, + alpha: number, + beta: number, + radius: number, + target: MockVector3Type, + scene: MockBabylonScene + ) { + this.name = name; + this.alpha = alpha; + this.beta = beta; + this.radius = radius; + this.target = target; + scene.activeCamera = this; + } + + attachControl(_canvas: HTMLCanvasElement, _noPreventDefault?: boolean) { /* mock */ } + dispose() { /* mock */ } + } + + const MockMeshBuilder = { + CreateGround: (name: string, options: { width: number; height: number }, _scene: MockBabylonScene) => { + const mesh = new actualMock.MockMesh(name, null) as MockMeshType; + mesh._groundWidth = options.width; + mesh._groundHeight = options.height; + mesh.receiveShadows = false; + return mesh; + } + }; + + const MockTools = { + ToRadians: (degrees: number) => degrees * (Math.PI / 180) + }; + + return { + Engine: MockEngine, + Scene: MockBabylonScene, + Vector3: actualMock.MockVector3, + Color3: actualMock.MockColor3, + Color4: actualMock.MockColor4, + HemisphericLight: MockHemisphericLight, + DirectionalLight: MockDirectionalLight, + ShadowGenerator: MockShadowGenerator, + ArcRotateCamera: MockArcRotateCamera, + MeshBuilder: MockMeshBuilder, + StandardMaterial: actualMock.MockStandardMaterial, + Tools: MockTools, + }; +}); + +describe("initBabylonJS unit tests", () => { + let mockCanvas: HTMLCanvasElement; + + beforeEach(() => { + // Create a mock canvas element + mockCanvas = document.createElement("canvas"); + mockCanvas.id = "test-canvas"; + document.body.appendChild(mockCanvas); + + // Mock window properties + Object.defineProperty(window, "innerWidth", { value: 1920, writable: true }); + Object.defineProperty(window, "innerHeight", { value: 1080, writable: true }); + }); + + afterEach(() => { + // Clean up DOM + if (mockCanvas && mockCanvas.parentNode) { + mockCanvas.parentNode.removeChild(mockCanvas); + } + // Clean up any canvases created by tests + document.querySelectorAll("canvas").forEach(canvas => { + if (canvas.parentNode) { + canvas.parentNode.removeChild(canvas); + } + }); + jest.clearAllMocks(); + }); + + describe("initialization with defaults", () => { + it("should create scene with default configuration", () => { + // Arrange & Act + const result = initBabylonJS(); + + // Assert + expect(result.scene).toBeDefined(); + expect(result.engine).toBeDefined(); + expect(result.hemisphericLight).toBeDefined(); + expect(result.directionalLight).toBeDefined(); + expect(result.ground).toBeDefined(); + expect(typeof result.startRenderLoop).toBe("function"); + expect(typeof result.dispose).toBe("function"); + + // Cleanup + result.dispose(); + }); + + it("should set scene metadata with empty shadowGenerators array when shadows disabled", () => { + // Arrange + const config = new BabylonJSScene.InitBabylonJSDto(); + config.canvasId = "test-canvas"; + config.enableShadows = false; + + // Act + const result = initBabylonJS(config); + + // Assert + expect(result.scene.metadata).toBeDefined(); + expect(result.scene.metadata.shadowGenerators).toEqual([]); + + // Cleanup + result.dispose(); + }); + + it("should create hemispheric light with correct name", () => { + // Arrange & Act + const result = initBabylonJS(); + + // Assert + expect(result.hemisphericLight.name).toBe("hemisphericLight"); + + // Cleanup + result.dispose(); + }); + + it("should create directional light with correct name", () => { + // Arrange & Act + const result = initBabylonJS(); + + // Assert + expect(result.directionalLight.name).toBe("directionalLight"); + + // Cleanup + result.dispose(); + }); + }); + + describe("canvas handling", () => { + it("should use existing canvas when canvasId is provided", () => { + // Arrange + const config = new BabylonJSScene.InitBabylonJSDto(); + config.canvasId = "test-canvas"; + + // Act + const result = initBabylonJS(config); + + // Assert - engine should be created with the existing canvas + expect(result.engine).toBeDefined(); + + // Cleanup + result.dispose(); + }); + + it("should throw error when canvas with provided id is not found", () => { + // Arrange + const config = new BabylonJSScene.InitBabylonJSDto(); + config.canvasId = "nonexistent-canvas"; + + // Act & Assert + expect(() => initBabylonJS(config)).toThrow("Canvas with id \"nonexistent-canvas\" not found"); + }); + + it("should create new canvas when canvasId is not provided", () => { + // Arrange & Act + const result = initBabylonJS(); + + // Assert - a new canvas should have been created + expect(result.engine).toBeDefined(); + + // Cleanup + result.dispose(); + }); + }); + + describe("shadow configuration", () => { + it("should add shadow generator to scene metadata when shadows are enabled", () => { + // Arrange + const config = new BabylonJSScene.InitBabylonJSDto(); + config.canvasId = "test-canvas"; + config.enableShadows = true; + + // Act + const result = initBabylonJS(config); + + // Assert + expect(result.scene.metadata.shadowGenerators.length).toBe(1); + + // Cleanup + result.dispose(); + }); + + it("should not add shadow generator when shadows are disabled", () => { + // Arrange + const config = new BabylonJSScene.InitBabylonJSDto(); + config.canvasId = "test-canvas"; + config.enableShadows = false; + + // Act + const result = initBabylonJS(config); + + // Assert + expect(result.scene.metadata.shadowGenerators.length).toBe(0); + + // Cleanup + result.dispose(); + }); + + it("should configure shadow generator with blur settings when enabled", () => { + // Arrange + const config = new BabylonJSScene.InitBabylonJSDto(); + config.canvasId = "test-canvas"; + config.enableShadows = true; + + // Act + const result = initBabylonJS(config); + + // Assert + const shadowGenerator = result.scene.metadata.shadowGenerators[0]; + expect(shadowGenerator.useBlurExponentialShadowMap).toBe(true); + expect(shadowGenerator.blurKernel).toBe(32); + expect(shadowGenerator.darkness).toBe(0.3); + + // Cleanup + result.dispose(); + }); + }); + + describe("ground plane configuration", () => { + it("should create ground plane when enableGround is true", () => { + // Arrange + const config = new BabylonJSScene.InitBabylonJSDto(); + config.canvasId = "test-canvas"; + config.enableGround = true; + + // Act + const result = initBabylonJS(config); + + // Assert + expect(result.ground).not.toBeNull(); + expect(result.ground?.name).toBe("ground"); + + // Cleanup + result.dispose(); + }); + + it("should not create ground plane when enableGround is false", () => { + // Arrange + const config = new BabylonJSScene.InitBabylonJSDto(); + config.canvasId = "test-canvas"; + config.enableGround = false; + + // Act + const result = initBabylonJS(config); + + // Assert + expect(result.ground).toBeNull(); + + // Cleanup + result.dispose(); + }); + + it("should position ground at specified center", () => { + // Arrange + const config = new BabylonJSScene.InitBabylonJSDto(); + config.canvasId = "test-canvas"; + config.enableGround = true; + config.groundCenter = [5, -2, 10]; + + // Act + const result = initBabylonJS(config); + + // Assert + expect(result.ground?.position.x).toBe(5); + expect(result.ground?.position.y).toBe(-2); + expect(result.ground?.position.z).toBe(10); + + // Cleanup + result.dispose(); + }); + + it("should create ground with correct size based on sceneSize and groundScaleFactor", () => { + // Arrange + const config = new BabylonJSScene.InitBabylonJSDto(); + config.canvasId = "test-canvas"; + config.sceneSize = 50; + config.groundScaleFactor = 3; + config.enableGround = true; + + // Act + const result = initBabylonJS(config); + + // Assert + const expectedSize = config.sceneSize * config.groundScaleFactor; // 150 + expect((result.ground as unknown as MockMeshType)._groundWidth).toBe(expectedSize); + expect((result.ground as unknown as MockMeshType)._groundHeight).toBe(expectedSize); + + // Cleanup + result.dispose(); + }); + + it("should set ground material with correct color", () => { + // Arrange + const config = new BabylonJSScene.InitBabylonJSDto(); + config.canvasId = "test-canvas"; + config.enableGround = true; + config.groundColor = "#ff0000"; + + // Act + const result = initBabylonJS(config); + + // Assert + const material = result.ground?.material; + expect(material).toBeDefined(); + expect(material?.name).toBe("groundMaterial"); + + // Cleanup + result.dispose(); + }); + + it("should set ground material opacity from config", () => { + // Arrange + const config = new BabylonJSScene.InitBabylonJSDto(); + config.canvasId = "test-canvas"; + config.enableGround = true; + config.groundOpacity = 0.5; + + // Act + const result = initBabylonJS(config); + + // Assert + const material = result.ground?.material; + expect(material?.alpha).toBe(0.5); + + // Cleanup + result.dispose(); + }); + + it("should set ground to receive shadows when shadows are enabled", () => { + // Arrange + const config = new BabylonJSScene.InitBabylonJSDto(); + config.canvasId = "test-canvas"; + config.enableGround = true; + config.enableShadows = true; + + // Act + const result = initBabylonJS(config); + + // Assert + expect((result.ground as unknown as MockMeshType).receiveShadows).toBe(true); + + // Cleanup + result.dispose(); + }); + }); + + describe("arc rotate camera configuration", () => { + it("should create arc rotate camera when enableArcRotateCamera is true", () => { + // Arrange + const config = new BabylonJSScene.InitBabylonJSDto(); + config.canvasId = "test-canvas"; + config.enableArcRotateCamera = true; + + // Act + const result = initBabylonJS(config); + + // Assert + expect(result.arcRotateCamera).not.toBeNull(); + expect(result.arcRotateCamera?.name).toBe("arcRotateCamera"); + + // Cleanup + result.dispose(); + }); + + it("should not create arc rotate camera when enableArcRotateCamera is false", () => { + // Arrange + const config = new BabylonJSScene.InitBabylonJSDto(); + config.canvasId = "test-canvas"; + config.enableArcRotateCamera = false; + + // Act + const result = initBabylonJS(config); + + // Assert + expect(result.arcRotateCamera).toBeNull(); + + // Cleanup + result.dispose(); + }); + + it("should set camera radius based on scene size when no custom options provided", () => { + // Arrange + const config = new BabylonJSScene.InitBabylonJSDto(); + config.canvasId = "test-canvas"; + config.sceneSize = 50; + config.enableArcRotateCamera = true; + + // Act + const result = initBabylonJS(config); + + // Assert + const expectedRadius = config.sceneSize * Math.sqrt(2); + expect(result.arcRotateCamera?.radius).toBeCloseTo(expectedRadius, 5); + + // Cleanup + result.dispose(); + }); + + it("should use custom camera options when provided", () => { + // Arrange + const config = new BabylonJSScene.InitBabylonJSDto(); + config.canvasId = "test-canvas"; + config.enableArcRotateCamera = true; + config.arcRotateCameraOptions = new BabylonCamera.ArcRotateCameraDto(); + config.arcRotateCameraOptions.radius = 100; + config.arcRotateCameraOptions.alpha = 90; + config.arcRotateCameraOptions.beta = 60; + + // Act + const result = initBabylonJS(config); + + // Assert + expect(result.arcRotateCamera?.radius).toBe(100); + // Alpha and beta are converted to radians + expect(result.arcRotateCamera?.alpha).toBeCloseTo(Math.PI / 2, 5); // 90 degrees + expect(result.arcRotateCamera?.beta).toBeCloseTo(Math.PI / 3, 5); // 60 degrees + + // Cleanup + result.dispose(); + }); + + it("should set camera limits based on scene size", () => { + // Arrange + const config = new BabylonJSScene.InitBabylonJSDto(); + config.canvasId = "test-canvas"; + config.sceneSize = 50; + config.enableArcRotateCamera = true; + + // Act + const result = initBabylonJS(config); + + // Assert + expect(result.arcRotateCamera?.lowerRadiusLimit).toBeCloseTo(config.sceneSize * 0.1, 5); + expect(result.arcRotateCamera?.upperRadiusLimit).toBeCloseTo(config.sceneSize * 10, 5); + expect(result.arcRotateCamera?.maxZ).toBeCloseTo(config.sceneSize * 50, 5); + + // Cleanup + result.dispose(); + }); + }); + + describe("scene size scaling", () => { + it("should position lights based on scene size", () => { + // Arrange + const config = new BabylonJSScene.InitBabylonJSDto(); + config.canvasId = "test-canvas"; + config.sceneSize = 100; + + // Act + const result = initBabylonJS(config); + + // Assert + const expectedHeight = config.sceneSize * 0.75; // 75 + const expectedOffset = config.sceneSize * 0.5; // 50 + expect(result.directionalLight.position.x).toBeCloseTo(expectedOffset, 5); + expect(result.directionalLight.position.y).toBeCloseTo(expectedHeight, 5); + expect(result.directionalLight.position.z).toBeCloseTo(expectedOffset, 5); + + // Cleanup + result.dispose(); + }); + }); + + describe("light intensity configuration", () => { + it("should apply hemisphere light intensity from config", () => { + // Arrange + const config = new BabylonJSScene.InitBabylonJSDto(); + config.canvasId = "test-canvas"; + config.hemisphereLightIntensity = 2.5; + + // Act + const result = initBabylonJS(config); + + // Assert + expect(result.hemisphericLight.intensity).toBe(2.5); + + // Cleanup + result.dispose(); + }); + + it("should apply directional light intensity from config", () => { + // Arrange + const config = new BabylonJSScene.InitBabylonJSDto(); + config.canvasId = "test-canvas"; + config.directionalLightIntensity = 3.0; + + // Act + const result = initBabylonJS(config); + + // Assert + expect(result.directionalLight.intensity).toBe(3.0); + + // Cleanup + result.dispose(); + }); + }); + + describe("dispose method", () => { + it("should remove window resize event listener on dispose", () => { + // Arrange + const removeEventListenerSpy = jest.spyOn(window, "removeEventListener"); + const result = initBabylonJS(); + + // Act + result.dispose(); + + // Assert + expect(removeEventListenerSpy).toHaveBeenCalledWith("resize", expect.any(Function)); + + // Cleanup + removeEventListenerSpy.mockRestore(); + }); + + it("should dispose hemispheric light on cleanup", () => { + // Arrange + const result = initBabylonJS(); + const disposeSpy = jest.spyOn(result.hemisphericLight, "dispose"); + + // Act + result.dispose(); + + // Assert + expect(disposeSpy).toHaveBeenCalled(); + }); + + it("should dispose directional light on cleanup", () => { + // Arrange + const result = initBabylonJS(); + const disposeSpy = jest.spyOn(result.directionalLight, "dispose"); + + // Act + result.dispose(); + + // Assert + expect(disposeSpy).toHaveBeenCalled(); + }); + + it("should dispose scene on cleanup", () => { + // Arrange + const result = initBabylonJS(); + const disposeSpy = jest.spyOn(result.scene, "dispose"); + + // Act + result.dispose(); + + // Assert + expect(disposeSpy).toHaveBeenCalled(); + }); + + it("should dispose engine on cleanup", () => { + // Arrange + const result = initBabylonJS(); + const disposeSpy = jest.spyOn(result.engine, "dispose"); + + // Act + result.dispose(); + + // Assert + expect(disposeSpy).toHaveBeenCalled(); + }); + + it("should dispose arc rotate camera when enabled", () => { + // Arrange + const config = new BabylonJSScene.InitBabylonJSDto(); + config.enableArcRotateCamera = true; + const result = initBabylonJS(config); + expect(result.arcRotateCamera).not.toBeNull(); + const disposeSpy = jest.spyOn(result.arcRotateCamera as NonNullable, "dispose"); + + // Act + result.dispose(); + + // Assert + expect(disposeSpy).toHaveBeenCalled(); + }); + + it("should remove created canvas from DOM on dispose", () => { + // Arrange - no canvasId means a new canvas is created + const result = initBabylonJS(); + const canvasCount = document.querySelectorAll("canvas").length; + + // Act + result.dispose(); + + // Assert - there should be one less canvas (only the mock test canvas remains) + const newCanvasCount = document.querySelectorAll("canvas").length; + expect(newCanvasCount).toBeLessThan(canvasCount); + }); + + it("should not remove canvas from DOM when canvasId was provided", () => { + // Arrange + const config = new BabylonJSScene.InitBabylonJSDto(); + config.canvasId = "test-canvas"; + const result = initBabylonJS(config); + + // Act + result.dispose(); + + // Assert - canvas should still be in DOM + expect(mockCanvas.parentNode).toBe(document.body); + }); + }); + + describe("startRenderLoop method", () => { + it("should start engine render loop", () => { + // Arrange + const result = initBabylonJS(); + const runRenderLoopSpy = jest.spyOn(result.engine, "runRenderLoop"); + + // Act + result.startRenderLoop(); + + // Assert + expect(runRenderLoopSpy).toHaveBeenCalledWith(expect.any(Function)); + + // Cleanup + result.dispose(); + }); + + it("should call onRender callback when provided", () => { + // Arrange + const config = new BabylonJSScene.InitBabylonJSDto(); + config.canvasId = "test-canvas"; + config.enableArcRotateCamera = true; // Need active camera for render + const result = initBabylonJS(config); + const onRenderMock = jest.fn(); + let renderCallback: (() => void) | null = null; + + jest.spyOn(result.engine, "runRenderLoop").mockImplementation((callback) => { + renderCallback = callback; + }); + + // Act + result.startRenderLoop(onRenderMock); + // Simulate one frame + if (renderCallback) { + renderCallback(); + } + + // Assert + expect(onRenderMock).toHaveBeenCalled(); + + // Cleanup + result.dispose(); + }); + }); +}); diff --git a/packages/dev/babylonjs/lib/api/inputs/draw-inputs.test.ts b/packages/dev/babylonjs/lib/api/inputs/draw-inputs.test.ts index 3a9315f7..ce657e7e 100644 --- a/packages/dev/babylonjs/lib/api/inputs/draw-inputs.test.ts +++ b/packages/dev/babylonjs/lib/api/inputs/draw-inputs.test.ts @@ -248,7 +248,7 @@ describe("Draw DTO unit tests", () => { // Assert expect(result.colours).toBe("#ff0000"); expect(result.colorMapStrategy).toBe(Base.colorMapStrategyEnum.lastColorRemainder); - expect(result.size).toBe(1); + expect(result.size).toBe(0.1); expect(result.opacity).toBe(1); expect(result.updatable).toBe(false); expect(result.hidden).toBe(false); diff --git a/packages/dev/babylonjs/package-lock.json b/packages/dev/babylonjs/package-lock.json index 4c7e33d0..b0514808 100644 --- a/packages/dev/babylonjs/package-lock.json +++ b/packages/dev/babylonjs/package-lock.json @@ -26,6 +26,7 @@ "@types/jest": "29.0.0", "babel-jest": "29.0.0", "jest": "29.4.1", + "jest-environment-jsdom": "^30.2.0", "jest-html-reporters": "3.0.11", "mvdir": "1.0.21", "sass": "1.57.1", @@ -35,13 +36,37 @@ "typescript": "4.8.2" } }, + "node_modules/@asamuzakjp/css-color": { + "version": "3.2.0", + "resolved": "https://registry.npmjs.org/@asamuzakjp/css-color/-/css-color-3.2.0.tgz", + "integrity": "sha512-K1A6z8tS3XsmCMM86xoWdn7Fkdn9m6RSVtocUrJYIwZnFVkng/PvkEoWtOWmP+Scc6saYWHWZYbndEEXxl24jw==", + "dev": true, + "license": "MIT", + "dependencies": { + "@csstools/css-calc": "^2.1.3", + "@csstools/css-color-parser": "^3.0.9", + "@csstools/css-parser-algorithms": "^3.0.4", + "@csstools/css-tokenizer": "^3.0.3", + "lru-cache": "^10.4.3" + } + }, + "node_modules/@asamuzakjp/css-color/node_modules/lru-cache": { + "version": "10.4.3", + "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-10.4.3.tgz", + "integrity": "sha512-JNAzZcXrCt42VGLuYz0zfAzDfAvJWW6AfYlDBQyDV5DClI2m5sAmK+OIO7s59XfsRsWHp02jAJrRadPRGTt6SQ==", + "dev": true, + "license": "ISC" + }, "node_modules/@babel/code-frame": { - "version": "7.18.6", - "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.18.6.tgz", - "integrity": "sha512-TDCmlK5eOvH+eH7cdAFlNXeVJqWIQ7gW9tY1GJIpUtFb6CmjVyq2VM3u71bOyR8CRihcCgMUYoDNyLXao3+70Q==", + "version": "7.28.6", + "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.28.6.tgz", + "integrity": "sha512-JYgintcMjRiCvS8mMECzaEn+m3PfoQiyqukOMCCVQtoJGYJw8j/8LBJEiqkHLkfwCcs74E3pbAUFNg7d9VNJ+Q==", "dev": true, + "license": "MIT", "dependencies": { - "@babel/highlight": "^7.18.6" + "@babel/helper-validator-identifier": "^7.28.5", + "js-tokens": "^4.0.0", + "picocolors": "^1.1.1" }, "engines": { "node": ">=6.9.0" @@ -393,10 +418,11 @@ } }, "node_modules/@babel/helper-validator-identifier": { - "version": "7.19.1", - "resolved": "https://registry.npmjs.org/@babel/helper-validator-identifier/-/helper-validator-identifier-7.19.1.tgz", - "integrity": "sha512-awrNfaMtnHUr653GgGEs++LlAvW6w+DcPrOliSMXWCKo597CwL5Acf/wWdNkf/tfEQE3mjkeD1YOVZOUV/od1w==", + "version": "7.28.5", + "resolved": "https://registry.npmjs.org/@babel/helper-validator-identifier/-/helper-validator-identifier-7.28.5.tgz", + "integrity": "sha512-qSs4ifwzKJSV39ucNjsvc6WVHs6b7S03sOh2OcHF9UHfVPqWWALUsNUVzhSBiItjRZoLHx7nIarVjqKVusUZ1Q==", "dev": true, + "license": "MIT", "engines": { "node": ">=6.9.0" } @@ -439,20 +465,6 @@ "node": ">=6.9.0" } }, - "node_modules/@babel/highlight": { - "version": "7.18.6", - "resolved": "https://registry.npmjs.org/@babel/highlight/-/highlight-7.18.6.tgz", - "integrity": "sha512-u7stbOuYjaPezCuLj29hNW1v64M2Md2qupEKP1fHc7WdOA3DgLh37suiSrZYY7haUB7iBeQZ9P1uiRF359do3g==", - "dev": true, - "dependencies": { - "@babel/helper-validator-identifier": "^7.18.6", - "chalk": "^2.0.0", - "js-tokens": "^4.0.0" - }, - "engines": { - "node": ">=6.9.0" - } - }, "node_modules/@babel/parser": { "version": "7.21.2", "resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.21.2.tgz", @@ -1866,6 +1878,121 @@ "@jridgewell/sourcemap-codec": "^1.4.10" } }, + "node_modules/@csstools/color-helpers": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/@csstools/color-helpers/-/color-helpers-5.1.0.tgz", + "integrity": "sha512-S11EXWJyy0Mz5SYvRmY8nJYTFFd1LCNV+7cXyAgQtOOuzb4EsgfqDufL+9esx72/eLhsRdGZwaldu/h+E4t4BA==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/csstools" + }, + { + "type": "opencollective", + "url": "https://opencollective.com/csstools" + } + ], + "license": "MIT-0", + "engines": { + "node": ">=18" + } + }, + "node_modules/@csstools/css-calc": { + "version": "2.1.4", + "resolved": "https://registry.npmjs.org/@csstools/css-calc/-/css-calc-2.1.4.tgz", + "integrity": "sha512-3N8oaj+0juUw/1H3YwmDDJXCgTB1gKU6Hc/bB502u9zR0q2vd786XJH9QfrKIEgFlZmhZiq6epXl4rHqhzsIgQ==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/csstools" + }, + { + "type": "opencollective", + "url": "https://opencollective.com/csstools" + } + ], + "license": "MIT", + "engines": { + "node": ">=18" + }, + "peerDependencies": { + "@csstools/css-parser-algorithms": "^3.0.5", + "@csstools/css-tokenizer": "^3.0.4" + } + }, + "node_modules/@csstools/css-color-parser": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/@csstools/css-color-parser/-/css-color-parser-3.1.0.tgz", + "integrity": "sha512-nbtKwh3a6xNVIp/VRuXV64yTKnb1IjTAEEh3irzS+HkKjAOYLTGNb9pmVNntZ8iVBHcWDA2Dof0QtPgFI1BaTA==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/csstools" + }, + { + "type": "opencollective", + "url": "https://opencollective.com/csstools" + } + ], + "license": "MIT", + "dependencies": { + "@csstools/color-helpers": "^5.1.0", + "@csstools/css-calc": "^2.1.4" + }, + "engines": { + "node": ">=18" + }, + "peerDependencies": { + "@csstools/css-parser-algorithms": "^3.0.5", + "@csstools/css-tokenizer": "^3.0.4" + } + }, + "node_modules/@csstools/css-parser-algorithms": { + "version": "3.0.5", + "resolved": "https://registry.npmjs.org/@csstools/css-parser-algorithms/-/css-parser-algorithms-3.0.5.tgz", + "integrity": "sha512-DaDeUkXZKjdGhgYaHNJTV9pV7Y9B3b644jCLs9Upc3VeNGg6LWARAT6O+Q+/COo+2gg/bM5rhpMAtf70WqfBdQ==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/csstools" + }, + { + "type": "opencollective", + "url": "https://opencollective.com/csstools" + } + ], + "license": "MIT", + "engines": { + "node": ">=18" + }, + "peerDependencies": { + "@csstools/css-tokenizer": "^3.0.4" + } + }, + "node_modules/@csstools/css-tokenizer": { + "version": "3.0.4", + "resolved": "https://registry.npmjs.org/@csstools/css-tokenizer/-/css-tokenizer-3.0.4.tgz", + "integrity": "sha512-Vd/9EVDiu6PPJt9yAh6roZP6El1xHrdvIVGjyBsHR0RYwNHgL7FJPyIIW4fANJNG6FtyZfvlRPpFI4ZM/lubvw==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/csstools" + }, + { + "type": "opencollective", + "url": "https://opencollective.com/csstools" + } + ], + "license": "MIT", + "engines": { + "node": ">=18" + } + }, "node_modules/@emnapi/runtime": { "version": "1.8.1", "resolved": "https://registry.npmjs.org/@emnapi/runtime/-/runtime-1.8.1.tgz", @@ -2425,76 +2552,6 @@ "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, - "node_modules/@jest/console/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/@jest/console/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" - } - }, - "node_modules/@jest/console/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/@jest/console/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "node_modules/@jest/console/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/@jest/console/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, "node_modules/@jest/core": { "version": "29.4.3", "resolved": "https://registry.npmjs.org/@jest/core/-/core-29.4.3.tgz", @@ -2542,119 +2599,281 @@ } } }, - "node_modules/@jest/core/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "node_modules/@jest/environment": { + "version": "29.4.3", + "resolved": "https://registry.npmjs.org/@jest/environment/-/environment-29.4.3.tgz", + "integrity": "sha512-dq5S6408IxIa+lr54zeqce+QgI+CJT4nmmA+1yzFgtcsGK8c/EyiUb9XQOgz3BMKrRDfKseeOaxj2eO8LlD3lA==", "dev": true, "dependencies": { - "color-convert": "^2.0.1" + "@jest/fake-timers": "^29.4.3", + "@jest/types": "^29.4.3", + "@types/node": "*", + "jest-mock": "^29.4.3" }, "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, - "node_modules/@jest/core/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "node_modules/@jest/environment-jsdom-abstract": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/environment-jsdom-abstract/-/environment-jsdom-abstract-30.2.0.tgz", + "integrity": "sha512-kazxw2L9IPuZpQ0mEt9lu9Z98SqR74xcagANmMBU16X0lS23yPc0+S6hGLUz8kVRlomZEs/5S/Zlpqwf5yu6OQ==", "dev": true, + "license": "MIT", "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" + "@jest/environment": "30.2.0", + "@jest/fake-timers": "30.2.0", + "@jest/types": "30.2.0", + "@types/jsdom": "^21.1.7", + "@types/node": "*", + "jest-mock": "30.2.0", + "jest-util": "30.2.0" }, "engines": { - "node": ">=10" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" + "peerDependencies": { + "canvas": "^3.0.0", + "jsdom": "*" + }, + "peerDependenciesMeta": { + "canvas": { + "optional": true + } } }, - "node_modules/@jest/core/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "node_modules/@jest/environment-jsdom-abstract/node_modules/@jest/environment": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/environment/-/environment-30.2.0.tgz", + "integrity": "sha512-/QPTL7OBJQ5ac09UDRa3EQes4gt1FTEG/8jZ/4v5IVzx+Cv7dLxlVIvfvSVRiiX2drWyXeBjkMSR8hvOWSog5g==", "dev": true, + "license": "MIT", "dependencies": { - "color-name": "~1.1.4" + "@jest/fake-timers": "30.2.0", + "@jest/types": "30.2.0", + "@types/node": "*", + "jest-mock": "30.2.0" }, "engines": { - "node": ">=7.0.0" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/@jest/core/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "node_modules/@jest/core/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "node_modules/@jest/environment-jsdom-abstract/node_modules/@jest/fake-timers": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/fake-timers/-/fake-timers-30.2.0.tgz", + "integrity": "sha512-HI3tRLjRxAbBy0VO8dqqm7Hb2mIa8d5bg/NJkyQcOk7V118ObQML8RC5luTF/Zsg4474a+gDvhce7eTnP4GhYw==", "dev": true, + "license": "MIT", + "dependencies": { + "@jest/types": "30.2.0", + "@sinonjs/fake-timers": "^13.0.0", + "@types/node": "*", + "jest-message-util": "30.2.0", + "jest-mock": "30.2.0", + "jest-util": "30.2.0" + }, "engines": { - "node": ">=8" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/@jest/core/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "node_modules/@jest/environment-jsdom-abstract/node_modules/@jest/schemas": { + "version": "30.0.5", + "resolved": "https://registry.npmjs.org/@jest/schemas/-/schemas-30.0.5.tgz", + "integrity": "sha512-DmdYgtezMkh3cpU8/1uyXakv3tJRcmcXxBOcO0tbaozPwpmh4YMsnWrQm9ZmZMfa5ocbxzbFk6O4bDPEc/iAnA==", "dev": true, + "license": "MIT", "dependencies": { - "has-flag": "^4.0.0" + "@sinclair/typebox": "^0.34.0" }, "engines": { - "node": ">=8" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/@jest/environment": { - "version": "29.4.3", - "resolved": "https://registry.npmjs.org/@jest/environment/-/environment-29.4.3.tgz", - "integrity": "sha512-dq5S6408IxIa+lr54zeqce+QgI+CJT4nmmA+1yzFgtcsGK8c/EyiUb9XQOgz3BMKrRDfKseeOaxj2eO8LlD3lA==", + "node_modules/@jest/environment-jsdom-abstract/node_modules/@jest/types": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/types/-/types-30.2.0.tgz", + "integrity": "sha512-H9xg1/sfVvyfU7o3zMfBEjQ1gcsdeTMgqHoYdN79tuLqfTtuu7WckRA1R5whDwOzxaZAeMKTYWqP+WCAi0CHsg==", "dev": true, + "license": "MIT", "dependencies": { - "@jest/fake-timers": "^29.4.3", - "@jest/types": "^29.4.3", + "@jest/pattern": "30.0.1", + "@jest/schemas": "30.0.5", + "@types/istanbul-lib-coverage": "^2.0.6", + "@types/istanbul-reports": "^3.0.4", "@types/node": "*", - "jest-mock": "^29.4.3" + "@types/yargs": "^17.0.33", + "chalk": "^4.1.2" }, "engines": { - "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/@jest/expect": { - "version": "29.4.3", - "resolved": "https://registry.npmjs.org/@jest/expect/-/expect-29.4.3.tgz", - "integrity": "sha512-iktRU/YsxEtumI9zsPctYUk7ptpC+AVLLk1Ax3AsA4g1C+8OOnKDkIQBDHtD5hA/+VtgMd5AWI5gNlcAlt2vxQ==", + "node_modules/@jest/environment-jsdom-abstract/node_modules/@sinclair/typebox": { + "version": "0.34.47", + "resolved": "https://registry.npmjs.org/@sinclair/typebox/-/typebox-0.34.47.tgz", + "integrity": "sha512-ZGIBQ+XDvO5JQku9wmwtabcVTHJsgSWAHYtVuM9pBNNR5E88v6Jcj/llpmsjivig5X8A8HHOb4/mbEKPS5EvAw==", + "dev": true, + "license": "MIT" + }, + "node_modules/@jest/environment-jsdom-abstract/node_modules/@sinonjs/commons": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/@sinonjs/commons/-/commons-3.0.1.tgz", + "integrity": "sha512-K3mCHKQ9sVh8o1C9cxkwxaOmXoAMlDxC1mYyHrjqOWEcBjYr76t96zL2zlj5dUGZ3HSw240X1qgH3Mjf1yJWpQ==", "dev": true, + "license": "BSD-3-Clause", "dependencies": { - "expect": "^29.4.3", - "jest-snapshot": "^29.4.3" - }, - "engines": { - "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + "type-detect": "4.0.8" } }, - "node_modules/@jest/expect-utils": { - "version": "29.4.3", - "resolved": "https://registry.npmjs.org/@jest/expect-utils/-/expect-utils-29.4.3.tgz", - "integrity": "sha512-/6JWbkxHOP8EoS8jeeTd9dTfc9Uawi+43oLKHfp6zzux3U2hqOOVnV3ai4RpDYHOccL6g+5nrxpoc8DmJxtXVQ==", + "node_modules/@jest/environment-jsdom-abstract/node_modules/@sinonjs/fake-timers": { + "version": "13.0.5", + "resolved": "https://registry.npmjs.org/@sinonjs/fake-timers/-/fake-timers-13.0.5.tgz", + "integrity": "sha512-36/hTbH2uaWuGVERyC6da9YwGWnzUZXuPro/F2LfsdOsLnCojz/iSH8MxUt/FD2S5XBSVPhmArFUXcpCQ2Hkiw==", "dev": true, + "license": "BSD-3-Clause", "dependencies": { - "jest-get-type": "^29.4.3" - }, - "engines": { - "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + "@sinonjs/commons": "^3.0.1" } }, - "node_modules/@jest/fake-timers": { - "version": "29.4.3", - "resolved": "https://registry.npmjs.org/@jest/fake-timers/-/fake-timers-29.4.3.tgz", + "node_modules/@jest/environment-jsdom-abstract/node_modules/ci-info": { + "version": "4.3.1", + "resolved": "https://registry.npmjs.org/ci-info/-/ci-info-4.3.1.tgz", + "integrity": "sha512-Wdy2Igu8OcBpI2pZePZ5oWjPC38tmDVx5WKUXKwlLYkA0ozo85sLsLvkBbBn/sZaSCMFOGZJ14fvW9t5/d7kdA==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/sibiraj-s" + } + ], + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "node_modules/@jest/environment-jsdom-abstract/node_modules/jest-message-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-message-util/-/jest-message-util-30.2.0.tgz", + "integrity": "sha512-y4DKFLZ2y6DxTWD4cDe07RglV88ZiNEdlRfGtqahfbIjfsw1nMCPx49Uev4IA/hWn3sDKyAnSPwoYSsAEdcimw==", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/code-frame": "^7.27.1", + "@jest/types": "30.2.0", + "@types/stack-utils": "^2.0.3", + "chalk": "^4.1.2", + "graceful-fs": "^4.2.11", + "micromatch": "^4.0.8", + "pretty-format": "30.2.0", + "slash": "^3.0.0", + "stack-utils": "^2.0.6" + }, + "engines": { + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" + } + }, + "node_modules/@jest/environment-jsdom-abstract/node_modules/jest-mock": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-mock/-/jest-mock-30.2.0.tgz", + "integrity": "sha512-JNNNl2rj4b5ICpmAcq+WbLH83XswjPbjH4T7yvGzfAGCPh1rw+xVNbtk+FnRslvt9lkCcdn9i1oAoKUuFsOxRw==", + "dev": true, + "license": "MIT", + "dependencies": { + "@jest/types": "30.2.0", + "@types/node": "*", + "jest-util": "30.2.0" + }, + "engines": { + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" + } + }, + "node_modules/@jest/environment-jsdom-abstract/node_modules/jest-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-30.2.0.tgz", + "integrity": "sha512-QKNsM0o3Xe6ISQU869e+DhG+4CK/48aHYdJZGlFQVTjnbvgpcKyxpzk29fGiO7i/J8VENZ+d2iGnSsvmuHywlA==", + "dev": true, + "license": "MIT", + "dependencies": { + "@jest/types": "30.2.0", + "@types/node": "*", + "chalk": "^4.1.2", + "ci-info": "^4.2.0", + "graceful-fs": "^4.2.11", + "picomatch": "^4.0.2" + }, + "engines": { + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" + } + }, + "node_modules/@jest/environment-jsdom-abstract/node_modules/picomatch": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.3.tgz", + "integrity": "sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=12" + }, + "funding": { + "url": "https://github.com/sponsors/jonschlinkert" + } + }, + "node_modules/@jest/environment-jsdom-abstract/node_modules/pretty-format": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/pretty-format/-/pretty-format-30.2.0.tgz", + "integrity": "sha512-9uBdv/B4EefsuAL+pWqueZyZS2Ba+LxfFeQ9DN14HU4bN8bhaxKdkpjpB6fs9+pSjIBu+FXQHImEg8j/Lw0+vA==", + "dev": true, + "license": "MIT", + "dependencies": { + "@jest/schemas": "30.0.5", + "ansi-styles": "^5.2.0", + "react-is": "^18.3.1" + }, + "engines": { + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" + } + }, + "node_modules/@jest/environment-jsdom-abstract/node_modules/pretty-format/node_modules/ansi-styles": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-5.2.0.tgz", + "integrity": "sha512-Cxwpt2SfTzTtXcfOlzGEee8O+c+MmUgGrNiBcXnuWxuFJHe6a5Hz7qwhwe5OgaSYI0IJvkLqWX1ASG+cJOkEiA==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/@jest/expect": { + "version": "29.4.3", + "resolved": "https://registry.npmjs.org/@jest/expect/-/expect-29.4.3.tgz", + "integrity": "sha512-iktRU/YsxEtumI9zsPctYUk7ptpC+AVLLk1Ax3AsA4g1C+8OOnKDkIQBDHtD5hA/+VtgMd5AWI5gNlcAlt2vxQ==", + "dev": true, + "dependencies": { + "expect": "^29.4.3", + "jest-snapshot": "^29.4.3" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/@jest/expect-utils": { + "version": "29.4.3", + "resolved": "https://registry.npmjs.org/@jest/expect-utils/-/expect-utils-29.4.3.tgz", + "integrity": "sha512-/6JWbkxHOP8EoS8jeeTd9dTfc9Uawi+43oLKHfp6zzux3U2hqOOVnV3ai4RpDYHOccL6g+5nrxpoc8DmJxtXVQ==", + "dev": true, + "dependencies": { + "jest-get-type": "^29.4.3" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/@jest/fake-timers": { + "version": "29.4.3", + "resolved": "https://registry.npmjs.org/@jest/fake-timers/-/fake-timers-29.4.3.tgz", "integrity": "sha512-4Hote2MGcCTWSD2gwl0dwbCpBRHhE6olYEuTj8FMowdg3oQWNKr2YuxenPQYZ7+PfqPY1k98wKDU4Z+Hvd4Tiw==", "dev": true, "dependencies": { @@ -2684,6 +2903,30 @@ "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, + "node_modules/@jest/pattern": { + "version": "30.0.1", + "resolved": "https://registry.npmjs.org/@jest/pattern/-/pattern-30.0.1.tgz", + "integrity": "sha512-gWp7NfQW27LaBQz3TITS8L7ZCQ0TLvtmI//4OwlQRx4rnWxcPNIYjxZpDcN4+UlGxgm3jS5QPz8IPTCkb59wZA==", + "dev": true, + "license": "MIT", + "dependencies": { + "@types/node": "*", + "jest-regex-util": "30.0.1" + }, + "engines": { + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" + } + }, + "node_modules/@jest/pattern/node_modules/jest-regex-util": { + "version": "30.0.1", + "resolved": "https://registry.npmjs.org/jest-regex-util/-/jest-regex-util-30.0.1.tgz", + "integrity": "sha512-jHEQgBXAgc+Gh4g0p3bCevgRCVRkB4VB70zhoAE48gxeSr1hfUOsM/C2WoJgVL7Eyg//hudYENbm3Ne+/dRVVA==", + "dev": true, + "license": "MIT", + "engines": { + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" + } + }, "node_modules/@jest/reporters": { "version": "29.4.3", "resolved": "https://registry.npmjs.org/@jest/reporters/-/reporters-29.4.3.tgz", @@ -2727,76 +2970,6 @@ } } }, - "node_modules/@jest/reporters/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/@jest/reporters/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" - } - }, - "node_modules/@jest/reporters/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/@jest/reporters/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "node_modules/@jest/reporters/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/@jest/reporters/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, "node_modules/@jest/schemas": { "version": "29.4.3", "resolved": "https://registry.npmjs.org/@jest/schemas/-/schemas-29.4.3.tgz", @@ -2879,82 +3052,12 @@ "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, - "node_modules/@jest/transform/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/@jest/transform/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" - } - }, - "node_modules/@jest/transform/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/@jest/transform/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, "node_modules/@jest/transform/node_modules/convert-source-map": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/convert-source-map/-/convert-source-map-2.0.0.tgz", "integrity": "sha512-Kvp459HrV2FEJ1CAsi1Ku+MY3kasH19TFykTz2xWmMeq6bk2NU3XXvfJ+Q61m0xktWwt+1HSYf3JZsTms3aRJg==", "dev": true }, - "node_modules/@jest/transform/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/@jest/transform/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, "node_modules/@jest/types": { "version": "29.4.3", "resolved": "https://registry.npmjs.org/@jest/types/-/types-29.4.3.tgz", @@ -2972,88 +3075,18 @@ "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, - "node_modules/@jest/types/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "node_modules/@jridgewell/gen-mapping": { + "version": "0.3.2", + "resolved": "https://registry.npmjs.org/@jridgewell/gen-mapping/-/gen-mapping-0.3.2.tgz", + "integrity": "sha512-mh65xKQAzI6iBcFzwv28KVWSmCkdRBWoOh+bYQGW3+6OZvbbN3TqMGo5hqYxQniRcH9F2VZIoJCm4pa3BPDK/A==", "dev": true, "dependencies": { - "color-convert": "^2.0.1" + "@jridgewell/set-array": "^1.0.1", + "@jridgewell/sourcemap-codec": "^1.4.10", + "@jridgewell/trace-mapping": "^0.3.9" }, "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/@jest/types/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" - } - }, - "node_modules/@jest/types/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/@jest/types/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "node_modules/@jest/types/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/@jest/types/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/@jridgewell/gen-mapping": { - "version": "0.3.2", - "resolved": "https://registry.npmjs.org/@jridgewell/gen-mapping/-/gen-mapping-0.3.2.tgz", - "integrity": "sha512-mh65xKQAzI6iBcFzwv28KVWSmCkdRBWoOh+bYQGW3+6OZvbbN3TqMGo5hqYxQniRcH9F2VZIoJCm4pa3BPDK/A==", - "dev": true, - "dependencies": { - "@jridgewell/set-array": "^1.0.1", - "@jridgewell/sourcemap-codec": "^1.4.10", - "@jridgewell/trace-mapping": "^0.3.9" - }, - "engines": { - "node": ">=6.0.0" + "node": ">=6.0.0" } }, "node_modules/@jridgewell/resolve-uri": { @@ -3250,21 +3283,6 @@ "yarn": ">=1" } }, - "node_modules/@testing-library/jest-dom/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, "node_modules/@testing-library/jest-dom/node_modules/chalk": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/chalk/-/chalk-3.0.0.tgz", @@ -3278,45 +3296,6 @@ "node": ">=8" } }, - "node_modules/@testing-library/jest-dom/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/@testing-library/jest-dom/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "node_modules/@testing-library/jest-dom/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/@testing-library/jest-dom/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, "node_modules/@tsconfig/node10": { "version": "1.0.9", "resolved": "https://registry.npmjs.org/@tsconfig/node10/-/node10-1.0.9.tgz", @@ -3397,10 +3376,11 @@ } }, "node_modules/@types/istanbul-lib-coverage": { - "version": "2.0.4", - "resolved": "https://registry.npmjs.org/@types/istanbul-lib-coverage/-/istanbul-lib-coverage-2.0.4.tgz", - "integrity": "sha512-z/QT1XN4K4KYuslS23k62yDIDLwLFkzxOuMplDtObz0+y7VqJCaO2o+SPwHCvLFZh7xazvvoor2tA/hPz9ee7g==", - "dev": true + "version": "2.0.6", + "resolved": "https://registry.npmjs.org/@types/istanbul-lib-coverage/-/istanbul-lib-coverage-2.0.6.tgz", + "integrity": "sha512-2QF/t/auWm0lsy8XtKVPG19v3sSOQlJe/YHZgfjb/KBBHOGSV+J2q/S671rcq9uTBrLAXmZpqJiaQbMT+zNU1w==", + "dev": true, + "license": "MIT" }, "node_modules/@types/istanbul-lib-report": { "version": "3.0.0", @@ -3412,10 +3392,11 @@ } }, "node_modules/@types/istanbul-reports": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/@types/istanbul-reports/-/istanbul-reports-3.0.1.tgz", - "integrity": "sha512-c3mAZEuK0lvBp8tmuL74XRKn1+y2dcwOUpH7x4WrF6gk1GIgiluDRgMYQtw2OFcBvAJWlt6ASU3tSqxp0Uu0Aw==", + "version": "3.0.4", + "resolved": "https://registry.npmjs.org/@types/istanbul-reports/-/istanbul-reports-3.0.4.tgz", + "integrity": "sha512-pk2B1NWalF9toCRu6gjBzR69syFjP4Od8WRAX+0mmf9lAjCRicLOWc+ZrxZHx/0XRjotgkF9t6iaMJ+aXcOdZQ==", "dev": true, + "license": "MIT", "dependencies": { "@types/istanbul-lib-report": "*" } @@ -3430,6 +3411,18 @@ "pretty-format": "^29.0.0" } }, + "node_modules/@types/jsdom": { + "version": "21.1.7", + "resolved": "https://registry.npmjs.org/@types/jsdom/-/jsdom-21.1.7.tgz", + "integrity": "sha512-yOriVnggzrnQ3a9OKOCxaVuSug3w3/SbOj5i7VwXWZEyUNl3bLF9V3MfxGbZKuwqJOQyRfqXyROBB1CoZLFWzA==", + "dev": true, + "license": "MIT", + "dependencies": { + "@types/node": "*", + "@types/tough-cookie": "*", + "parse5": "^7.0.0" + } + }, "node_modules/@types/ndarray": { "version": "1.0.14", "resolved": "https://registry.npmjs.org/@types/ndarray/-/ndarray-1.0.14.tgz", @@ -3449,10 +3442,11 @@ "dev": true }, "node_modules/@types/stack-utils": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/@types/stack-utils/-/stack-utils-2.0.1.tgz", - "integrity": "sha512-Hl219/BT5fLAaz6NDkSuhzasy49dwQS/DSdu4MdggFB8zcXv7vflBI3xp7FEmkmdDkBUI2bPUNeMttp2knYdxw==", - "dev": true + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/@types/stack-utils/-/stack-utils-2.0.3.tgz", + "integrity": "sha512-9aEbYZ3TbYMznPdcdr3SmIrLXwC/AKZXQeCf9Pgao5CKb8CyHuEX5jzWPTkvregvhRJHcpRO6BFoGW9ycaOkYw==", + "dev": true, + "license": "MIT" }, "node_modules/@types/testing-library__jest-dom": { "version": "5.14.5", @@ -3463,11 +3457,19 @@ "@types/jest": "*" } }, + "node_modules/@types/tough-cookie": { + "version": "4.0.5", + "resolved": "https://registry.npmjs.org/@types/tough-cookie/-/tough-cookie-4.0.5.tgz", + "integrity": "sha512-/Ad8+nIOV7Rl++6f1BdKxFSMgmoqEoYbHRpPcx3JEfv8VRsQe9Z4mCXeJBzxs7mbHY/XOZZuXlRNfhpVPbs6ZA==", + "dev": true, + "license": "MIT" + }, "node_modules/@types/yargs": { - "version": "17.0.22", - "resolved": "https://registry.npmjs.org/@types/yargs/-/yargs-17.0.22.tgz", - "integrity": "sha512-pet5WJ9U8yPVRhkwuEIp5ktAeAqRZOq4UdAyWLWzxbtpyXnzbtLdKiXAjJzi/KLmPGS9wk86lUFWZFN6sISo4g==", + "version": "17.0.35", + "resolved": "https://registry.npmjs.org/@types/yargs/-/yargs-17.0.35.tgz", + "integrity": "sha512-qUHkeCyQFxMXg79wQfTtfndEC+N9ZZg76HJftDJp+qH2tV7Gj4OJi7l+PiWwJ+pWtW8GwSmqsDj/oymhrTWXjg==", "dev": true, + "license": "MIT", "dependencies": { "@types/yargs-parser": "*" } @@ -3499,6 +3501,16 @@ "node": ">=0.4.0" } }, + "node_modules/agent-base": { + "version": "7.1.4", + "resolved": "https://registry.npmjs.org/agent-base/-/agent-base-7.1.4.tgz", + "integrity": "sha512-MnA+YT8fwfJPgBx3m60MNqakm30XOkyIoH1y6huTQvC0PwZG7ki8NacLBcrPbNoo8vEZy7Jpuk7+jMO+CUovTQ==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">= 14" + } + }, "node_modules/ansi-escapes": { "version": "4.3.2", "resolved": "https://registry.npmjs.org/ansi-escapes/-/ansi-escapes-4.3.2.tgz", @@ -3524,15 +3536,19 @@ } }, "node_modules/ansi-styles": { - "version": "3.2.1", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz", - "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", "dev": true, + "license": "MIT", "dependencies": { - "color-convert": "^1.9.0" + "color-convert": "^2.0.1" }, "engines": { - "node": ">=4" + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" } }, "node_modules/anymatch": { @@ -3618,76 +3634,6 @@ "@babel/core": "^7.8.0" } }, - "node_modules/babel-jest/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/babel-jest/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" - } - }, - "node_modules/babel-jest/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/babel-jest/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "node_modules/babel-jest/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/babel-jest/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, "node_modules/babel-plugin-istanbul": { "version": "6.1.1", "resolved": "https://registry.npmjs.org/babel-plugin-istanbul/-/babel-plugin-istanbul-6.1.1.tgz", @@ -3940,17 +3886,20 @@ ] }, "node_modules/chalk": { - "version": "2.4.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.2.tgz", - "integrity": "sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==", + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", "dev": true, + "license": "MIT", "dependencies": { - "ansi-styles": "^3.2.1", - "escape-string-regexp": "^1.0.5", - "supports-color": "^5.3.0" + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" }, "engines": { - "node": ">=4" + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" } }, "node_modules/char-regex": { @@ -4041,19 +3990,24 @@ "dev": true }, "node_modules/color-convert": { - "version": "1.9.3", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-1.9.3.tgz", - "integrity": "sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg==", + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", "dev": true, + "license": "MIT", "dependencies": { - "color-name": "1.1.3" + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" } }, "node_modules/color-name": { - "version": "1.1.3", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.3.tgz", - "integrity": "sha512-72fSenhMw2HZMTVHeCA9KCmpEIbzWiQsjN+BHcBbS9vr1mtt+vJjPdksIBNUmKAW8TFUDPJK5SUU3QhE9NEXDw==", - "dev": true + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", + "dev": true, + "license": "MIT" }, "node_modules/commander": { "version": "13.1.0", @@ -4157,6 +4111,20 @@ "node": ">=0.10.0" } }, + "node_modules/cssstyle": { + "version": "4.6.0", + "resolved": "https://registry.npmjs.org/cssstyle/-/cssstyle-4.6.0.tgz", + "integrity": "sha512-2z+rWdzbbSZv6/rhtvzvqeZQHrBaqgogqt85sqFNbabZOuFbCVFb8kPeEtZjiKkbrm395irpNKiYeFeLiQnFPg==", + "dev": true, + "license": "MIT", + "dependencies": { + "@asamuzakjp/css-color": "^3.2.0", + "rrweb-cssom": "^0.8.0" + }, + "engines": { + "node": ">=18" + } + }, "node_modules/cwise-compiler": { "version": "1.1.3", "resolved": "https://registry.npmjs.org/cwise-compiler/-/cwise-compiler-1.1.3.tgz", @@ -4166,6 +4134,20 @@ "uniq": "^1.0.0" } }, + "node_modules/data-urls": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/data-urls/-/data-urls-5.0.0.tgz", + "integrity": "sha512-ZYP5VBHshaDAiVZxjbRVcFJpc+4xGgT0bK3vzy1HLN8jTO975HEbuYzZJcHoQEY5K1a0z8YayJkyVETa08eNTg==", + "dev": true, + "license": "MIT", + "dependencies": { + "whatwg-mimetype": "^4.0.0", + "whatwg-url": "^14.0.0" + }, + "engines": { + "node": ">=18" + } + }, "node_modules/debug": { "version": "4.3.4", "resolved": "https://registry.npmjs.org/debug/-/debug-4.3.4.tgz", @@ -4183,8 +4165,15 @@ } } }, - "node_modules/decode-uri-component": { - "version": "0.2.2", + "node_modules/decimal.js": { + "version": "10.6.0", + "resolved": "https://registry.npmjs.org/decimal.js/-/decimal.js-10.6.0.tgz", + "integrity": "sha512-YpgQiITW3JXGntzdUmyUR1V812Hn8T1YVXhCu+wO3OpS4eU9l4YdD3qjyiKdV6mvV29zapkMeD390UVEf2lkUg==", + "dev": true, + "license": "MIT" + }, + "node_modules/decode-uri-component": { + "version": "0.2.2", "resolved": "https://registry.npmjs.org/decode-uri-component/-/decode-uri-component-0.2.2.tgz", "integrity": "sha512-FqUYQ+8o158GyGTrMFJms9qh3CqTKvAqgqsTnkLI8sKu0028orqBhxNMFkFen0zGyg6epACD32pjVk58ngIErQ==", "dev": true, @@ -4297,6 +4286,19 @@ "once": "^1.4.0" } }, + "node_modules/entities": { + "version": "6.0.1", + "resolved": "https://registry.npmjs.org/entities/-/entities-6.0.1.tgz", + "integrity": "sha512-aN97NXWF6AWBTahfVOIrB/NShkzi5H7F9r1s9mD3cDj4Ko5f2qhhVoYMibXF7GlLveb/D2ioWay8lxI97Ven3g==", + "dev": true, + "license": "BSD-2-Clause", + "engines": { + "node": ">=0.12" + }, + "funding": { + "url": "https://github.com/fb55/entities?sponsor=1" + } + }, "node_modules/error-ex": { "version": "1.3.2", "resolved": "https://registry.npmjs.org/error-ex/-/error-ex-1.3.2.tgz", @@ -4339,15 +4341,6 @@ "node": ">=6" } }, - "node_modules/escape-string-regexp": { - "version": "1.0.5", - "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz", - "integrity": "sha512-vbRorB5FUQWvla16U8R/qgaFIya2qGzwDrNmCZuYKrbdSUMG6I1ZCGQRefkRVhuOkIGVne7BQ35DSfo1qvJqFg==", - "dev": true, - "engines": { - "node": ">=0.8.0" - } - }, "node_modules/esprima": { "version": "4.0.1", "resolved": "https://registry.npmjs.org/esprima/-/esprima-4.0.1.tgz", @@ -4626,10 +4619,11 @@ } }, "node_modules/graceful-fs": { - "version": "4.2.10", - "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.10.tgz", - "integrity": "sha512-9ByhssR2fPVsNZj478qUUbKfmL0+t5BDVyjShtyZZLiK7ZDAArFFfopyOTj0M05wE2tJPisA4iTnnXl2YoPvOA==", - "dev": true + "version": "4.2.11", + "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.11.tgz", + "integrity": "sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ==", + "dev": true, + "license": "ISC" }, "node_modules/has": { "version": "1.0.3", @@ -4644,12 +4638,26 @@ } }, "node_modules/has-flag": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-3.0.0.tgz", - "integrity": "sha512-sKJf1+ceQBr4SMkvQnBDNDtf4TXpVhVGateu0t918bl30FnbE2m4vNLX+VWe/dpjlb+HugGYzW7uQXH98HPEYw==", + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", "dev": true, + "license": "MIT", "engines": { - "node": ">=4" + "node": ">=8" + } + }, + "node_modules/html-encoding-sniffer": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/html-encoding-sniffer/-/html-encoding-sniffer-4.0.0.tgz", + "integrity": "sha512-Y22oTqIU4uuPgEemfz7NDJz6OeKf12Lsu+QC+s3BVpda64lTiMYCyGwg5ki4vFxkMwQdeZDl2adZoqUgdFuTgQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "whatwg-encoding": "^3.1.1" + }, + "engines": { + "node": ">=18" } }, "node_modules/html-escaper": { @@ -4658,6 +4666,34 @@ "integrity": "sha512-H2iMtd0I4Mt5eYiapRdIDjp+XzelXQ0tFE4JS7YFwFevXXMmOp9myNrUvCg0D6ws8iqkRPBfKHgbwig1SmlLfg==", "dev": true }, + "node_modules/http-proxy-agent": { + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/http-proxy-agent/-/http-proxy-agent-7.0.2.tgz", + "integrity": "sha512-T1gkAiYYDWYx3V5Bmyu7HcfcvL7mUrTWiM6yOfa3PIphViJ/gFPbvidQ+veqSOHci/PxBcDabeUNCzpOODJZig==", + "dev": true, + "license": "MIT", + "dependencies": { + "agent-base": "^7.1.0", + "debug": "^4.3.4" + }, + "engines": { + "node": ">= 14" + } + }, + "node_modules/https-proxy-agent": { + "version": "7.0.6", + "resolved": "https://registry.npmjs.org/https-proxy-agent/-/https-proxy-agent-7.0.6.tgz", + "integrity": "sha512-vK9P5/iUfdl95AI+JVyUuIcVtd4ofvtrOr3HNtM2yxC9bnMbEdp3x01OhQNnjb8IJYi38VlTE3mBXwcfvywuSw==", + "dev": true, + "license": "MIT", + "dependencies": { + "agent-base": "^7.1.2", + "debug": "4" + }, + "engines": { + "node": ">= 14" + } + }, "node_modules/human-signals": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/human-signals/-/human-signals-2.1.0.tgz", @@ -4667,6 +4703,19 @@ "node": ">=10.17.0" } }, + "node_modules/iconv-lite": { + "version": "0.6.3", + "resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.6.3.tgz", + "integrity": "sha512-4fCk79wshMdzMp2rH06qWrJE4iolqLhCUH+OiuIgU++RB0+94NlDL81atO7GX55uUKueo0txHNtvEyI6D7WdMw==", + "dev": true, + "license": "MIT", + "dependencies": { + "safer-buffer": ">= 2.1.2 < 3.0.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, "node_modules/immutable": { "version": "4.2.4", "resolved": "https://registry.npmjs.org/immutable/-/immutable-4.2.4.tgz", @@ -4842,6 +4891,13 @@ "node": ">=0.12.0" } }, + "node_modules/is-potential-custom-element-name": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/is-potential-custom-element-name/-/is-potential-custom-element-name-1.0.1.tgz", + "integrity": "sha512-bCYeRA2rVibKZd+s2625gGnGF/t7DSqDs4dP7CrLA1m7jKWz6pps0LpYLJN8Q64HtmPKJ1hrN3nzPNKFEKOUiQ==", + "dev": true, + "license": "MIT" + }, "node_modules/is-stream": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/is-stream/-/is-stream-2.0.1.tgz", @@ -4911,27 +4967,6 @@ "node": ">=8" } }, - "node_modules/istanbul-lib-report/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/istanbul-lib-report/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, "node_modules/istanbul-lib-source-maps": { "version": "4.0.1", "resolved": "https://registry.npmjs.org/istanbul-lib-source-maps/-/istanbul-lib-source-maps-4.0.1.tgz", @@ -5037,76 +5072,6 @@ "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, - "node_modules/jest-circus/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/jest-circus/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" - } - }, - "node_modules/jest-circus/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/jest-circus/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "node_modules/jest-circus/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/jest-circus/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, "node_modules/jest-cli": { "version": "29.4.3", "resolved": "https://registry.npmjs.org/jest-cli/-/jest-cli-29.4.3.tgz", @@ -5141,76 +5106,6 @@ } } }, - "node_modules/jest-cli/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/jest-cli/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" - } - }, - "node_modules/jest-cli/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/jest-cli/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "node_modules/jest-cli/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/jest-cli/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, "node_modules/jest-config": { "version": "29.4.3", "resolved": "https://registry.npmjs.org/jest-config/-/jest-config-29.4.3.tgz", @@ -5256,21 +5151,6 @@ } } }, - "node_modules/jest-config/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, "node_modules/jest-config/node_modules/babel-jest": { "version": "29.4.3", "resolved": "https://registry.npmjs.org/babel-jest/-/babel-jest-29.4.3.tgz", @@ -5292,242 +5172,276 @@ "@babel/core": "^7.8.0" } }, - "node_modules/jest-config/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "node_modules/jest-diff": { + "version": "29.4.3", + "resolved": "https://registry.npmjs.org/jest-diff/-/jest-diff-29.4.3.tgz", + "integrity": "sha512-YB+ocenx7FZ3T5O9lMVMeLYV4265socJKtkwgk/6YUz/VsEzYDkiMuMhWzZmxm3wDRQvayJu/PjkjjSkjoHsCA==", "dev": true, "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" + "chalk": "^4.0.0", + "diff-sequences": "^29.4.3", + "jest-get-type": "^29.4.3", + "pretty-format": "^29.4.3" }, "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, - "node_modules/jest-config/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "node_modules/jest-docblock": { + "version": "29.4.3", + "resolved": "https://registry.npmjs.org/jest-docblock/-/jest-docblock-29.4.3.tgz", + "integrity": "sha512-fzdTftThczeSD9nZ3fzA/4KkHtnmllawWrXO69vtI+L9WjEIuXWs4AmyME7lN5hU7dB0sHhuPfcKofRsUb/2Fg==", "dev": true, "dependencies": { - "color-name": "~1.1.4" + "detect-newline": "^3.0.0" }, "engines": { - "node": ">=7.0.0" + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, - "node_modules/jest-config/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "node_modules/jest-config/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/jest-config/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/jest-diff": { + "node_modules/jest-each": { "version": "29.4.3", - "resolved": "https://registry.npmjs.org/jest-diff/-/jest-diff-29.4.3.tgz", - "integrity": "sha512-YB+ocenx7FZ3T5O9lMVMeLYV4265socJKtkwgk/6YUz/VsEzYDkiMuMhWzZmxm3wDRQvayJu/PjkjjSkjoHsCA==", + "resolved": "https://registry.npmjs.org/jest-each/-/jest-each-29.4.3.tgz", + "integrity": "sha512-1ElHNAnKcbJb/b+L+7j0/w7bDvljw4gTv1wL9fYOczeJrbTbkMGQ5iQPFJ3eFQH19VPTx1IyfePdqSpePKss7Q==", "dev": true, "dependencies": { + "@jest/types": "^29.4.3", "chalk": "^4.0.0", - "diff-sequences": "^29.4.3", "jest-get-type": "^29.4.3", + "jest-util": "^29.4.3", "pretty-format": "^29.4.3" }, "engines": { "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, - "node_modules/jest-diff/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "node_modules/jest-environment-jsdom": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-environment-jsdom/-/jest-environment-jsdom-30.2.0.tgz", + "integrity": "sha512-zbBTiqr2Vl78pKp/laGBREYzbZx9ZtqPjOK4++lL4BNDhxRnahg51HtoDrk9/VjIy9IthNEWdKVd7H5bqBhiWQ==", "dev": true, + "license": "MIT", "dependencies": { - "color-convert": "^2.0.1" + "@jest/environment": "30.2.0", + "@jest/environment-jsdom-abstract": "30.2.0", + "@types/jsdom": "^21.1.7", + "@types/node": "*", + "jsdom": "^26.1.0" }, "engines": { - "node": ">=8" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" + "peerDependencies": { + "canvas": "^3.0.0" + }, + "peerDependenciesMeta": { + "canvas": { + "optional": true + } } }, - "node_modules/jest-diff/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "node_modules/jest-environment-jsdom/node_modules/@jest/environment": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/environment/-/environment-30.2.0.tgz", + "integrity": "sha512-/QPTL7OBJQ5ac09UDRa3EQes4gt1FTEG/8jZ/4v5IVzx+Cv7dLxlVIvfvSVRiiX2drWyXeBjkMSR8hvOWSog5g==", "dev": true, + "license": "MIT", "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" + "@jest/fake-timers": "30.2.0", + "@jest/types": "30.2.0", + "@types/node": "*", + "jest-mock": "30.2.0" }, "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/jest-diff/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "node_modules/jest-environment-jsdom/node_modules/@jest/fake-timers": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/fake-timers/-/fake-timers-30.2.0.tgz", + "integrity": "sha512-HI3tRLjRxAbBy0VO8dqqm7Hb2mIa8d5bg/NJkyQcOk7V118ObQML8RC5luTF/Zsg4474a+gDvhce7eTnP4GhYw==", "dev": true, + "license": "MIT", "dependencies": { - "color-name": "~1.1.4" + "@jest/types": "30.2.0", + "@sinonjs/fake-timers": "^13.0.0", + "@types/node": "*", + "jest-message-util": "30.2.0", + "jest-mock": "30.2.0", + "jest-util": "30.2.0" }, "engines": { - "node": ">=7.0.0" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/jest-diff/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "node_modules/jest-diff/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "node_modules/jest-environment-jsdom/node_modules/@jest/schemas": { + "version": "30.0.5", + "resolved": "https://registry.npmjs.org/@jest/schemas/-/schemas-30.0.5.tgz", + "integrity": "sha512-DmdYgtezMkh3cpU8/1uyXakv3tJRcmcXxBOcO0tbaozPwpmh4YMsnWrQm9ZmZMfa5ocbxzbFk6O4bDPEc/iAnA==", "dev": true, + "license": "MIT", + "dependencies": { + "@sinclair/typebox": "^0.34.0" + }, "engines": { - "node": ">=8" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/jest-diff/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "node_modules/jest-environment-jsdom/node_modules/@jest/types": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/types/-/types-30.2.0.tgz", + "integrity": "sha512-H9xg1/sfVvyfU7o3zMfBEjQ1gcsdeTMgqHoYdN79tuLqfTtuu7WckRA1R5whDwOzxaZAeMKTYWqP+WCAi0CHsg==", "dev": true, + "license": "MIT", "dependencies": { - "has-flag": "^4.0.0" + "@jest/pattern": "30.0.1", + "@jest/schemas": "30.0.5", + "@types/istanbul-lib-coverage": "^2.0.6", + "@types/istanbul-reports": "^3.0.4", + "@types/node": "*", + "@types/yargs": "^17.0.33", + "chalk": "^4.1.2" }, "engines": { - "node": ">=8" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/jest-docblock": { - "version": "29.4.3", - "resolved": "https://registry.npmjs.org/jest-docblock/-/jest-docblock-29.4.3.tgz", - "integrity": "sha512-fzdTftThczeSD9nZ3fzA/4KkHtnmllawWrXO69vtI+L9WjEIuXWs4AmyME7lN5hU7dB0sHhuPfcKofRsUb/2Fg==", + "node_modules/jest-environment-jsdom/node_modules/@sinclair/typebox": { + "version": "0.34.47", + "resolved": "https://registry.npmjs.org/@sinclair/typebox/-/typebox-0.34.47.tgz", + "integrity": "sha512-ZGIBQ+XDvO5JQku9wmwtabcVTHJsgSWAHYtVuM9pBNNR5E88v6Jcj/llpmsjivig5X8A8HHOb4/mbEKPS5EvAw==", + "dev": true, + "license": "MIT" + }, + "node_modules/jest-environment-jsdom/node_modules/@sinonjs/commons": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/@sinonjs/commons/-/commons-3.0.1.tgz", + "integrity": "sha512-K3mCHKQ9sVh8o1C9cxkwxaOmXoAMlDxC1mYyHrjqOWEcBjYr76t96zL2zlj5dUGZ3HSw240X1qgH3Mjf1yJWpQ==", "dev": true, + "license": "BSD-3-Clause", "dependencies": { - "detect-newline": "^3.0.0" - }, - "engines": { - "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + "type-detect": "4.0.8" } }, - "node_modules/jest-each": { - "version": "29.4.3", - "resolved": "https://registry.npmjs.org/jest-each/-/jest-each-29.4.3.tgz", - "integrity": "sha512-1ElHNAnKcbJb/b+L+7j0/w7bDvljw4gTv1wL9fYOczeJrbTbkMGQ5iQPFJ3eFQH19VPTx1IyfePdqSpePKss7Q==", + "node_modules/jest-environment-jsdom/node_modules/@sinonjs/fake-timers": { + "version": "13.0.5", + "resolved": "https://registry.npmjs.org/@sinonjs/fake-timers/-/fake-timers-13.0.5.tgz", + "integrity": "sha512-36/hTbH2uaWuGVERyC6da9YwGWnzUZXuPro/F2LfsdOsLnCojz/iSH8MxUt/FD2S5XBSVPhmArFUXcpCQ2Hkiw==", "dev": true, + "license": "BSD-3-Clause", "dependencies": { - "@jest/types": "^29.4.3", - "chalk": "^4.0.0", - "jest-get-type": "^29.4.3", - "jest-util": "^29.4.3", - "pretty-format": "^29.4.3" - }, - "engines": { - "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + "@sinonjs/commons": "^3.0.1" } }, - "node_modules/jest-each/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "node_modules/jest-environment-jsdom/node_modules/ansi-styles": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-5.2.0.tgz", + "integrity": "sha512-Cxwpt2SfTzTtXcfOlzGEee8O+c+MmUgGrNiBcXnuWxuFJHe6a5Hz7qwhwe5OgaSYI0IJvkLqWX1ASG+cJOkEiA==", "dev": true, - "dependencies": { - "color-convert": "^2.0.1" - }, + "license": "MIT", "engines": { - "node": ">=8" + "node": ">=10" }, "funding": { "url": "https://github.com/chalk/ansi-styles?sponsor=1" } }, - "node_modules/jest-each/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "node_modules/jest-environment-jsdom/node_modules/ci-info": { + "version": "4.3.1", + "resolved": "https://registry.npmjs.org/ci-info/-/ci-info-4.3.1.tgz", + "integrity": "sha512-Wdy2Igu8OcBpI2pZePZ5oWjPC38tmDVx5WKUXKwlLYkA0ozo85sLsLvkBbBn/sZaSCMFOGZJ14fvW9t5/d7kdA==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/sibiraj-s" + } + ], + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "node_modules/jest-environment-jsdom/node_modules/jest-message-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-message-util/-/jest-message-util-30.2.0.tgz", + "integrity": "sha512-y4DKFLZ2y6DxTWD4cDe07RglV88ZiNEdlRfGtqahfbIjfsw1nMCPx49Uev4IA/hWn3sDKyAnSPwoYSsAEdcimw==", "dev": true, + "license": "MIT", "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" + "@babel/code-frame": "^7.27.1", + "@jest/types": "30.2.0", + "@types/stack-utils": "^2.0.3", + "chalk": "^4.1.2", + "graceful-fs": "^4.2.11", + "micromatch": "^4.0.8", + "pretty-format": "30.2.0", + "slash": "^3.0.0", + "stack-utils": "^2.0.6" }, "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/jest-each/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "node_modules/jest-environment-jsdom/node_modules/jest-mock": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-mock/-/jest-mock-30.2.0.tgz", + "integrity": "sha512-JNNNl2rj4b5ICpmAcq+WbLH83XswjPbjH4T7yvGzfAGCPh1rw+xVNbtk+FnRslvt9lkCcdn9i1oAoKUuFsOxRw==", "dev": true, + "license": "MIT", "dependencies": { - "color-name": "~1.1.4" + "@jest/types": "30.2.0", + "@types/node": "*", + "jest-util": "30.2.0" }, "engines": { - "node": ">=7.0.0" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/jest-each/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true + "node_modules/jest-environment-jsdom/node_modules/jest-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-30.2.0.tgz", + "integrity": "sha512-QKNsM0o3Xe6ISQU869e+DhG+4CK/48aHYdJZGlFQVTjnbvgpcKyxpzk29fGiO7i/J8VENZ+d2iGnSsvmuHywlA==", + "dev": true, + "license": "MIT", + "dependencies": { + "@jest/types": "30.2.0", + "@types/node": "*", + "chalk": "^4.1.2", + "ci-info": "^4.2.0", + "graceful-fs": "^4.2.11", + "picomatch": "^4.0.2" + }, + "engines": { + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" + } }, - "node_modules/jest-each/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "node_modules/jest-environment-jsdom/node_modules/picomatch": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.3.tgz", + "integrity": "sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==", "dev": true, + "license": "MIT", "engines": { - "node": ">=8" + "node": ">=12" + }, + "funding": { + "url": "https://github.com/sponsors/jonschlinkert" } }, - "node_modules/jest-each/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "node_modules/jest-environment-jsdom/node_modules/pretty-format": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/pretty-format/-/pretty-format-30.2.0.tgz", + "integrity": "sha512-9uBdv/B4EefsuAL+pWqueZyZS2Ba+LxfFeQ9DN14HU4bN8bhaxKdkpjpB6fs9+pSjIBu+FXQHImEg8j/Lw0+vA==", "dev": true, + "license": "MIT", "dependencies": { - "has-flag": "^4.0.0" + "@jest/schemas": "30.0.5", + "ansi-styles": "^5.2.0", + "react-is": "^18.3.1" }, "engines": { - "node": ">=8" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, "node_modules/jest-environment-node": { @@ -5620,76 +5534,6 @@ "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, - "node_modules/jest-matcher-utils/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/jest-matcher-utils/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" - } - }, - "node_modules/jest-matcher-utils/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/jest-matcher-utils/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "node_modules/jest-matcher-utils/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/jest-matcher-utils/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, "node_modules/jest-message-util": { "version": "29.4.3", "resolved": "https://registry.npmjs.org/jest-message-util/-/jest-message-util-29.4.3.tgz", @@ -5710,88 +5554,18 @@ "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, - "node_modules/jest-message-util/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "node_modules/jest-mock": { + "version": "29.4.3", + "resolved": "https://registry.npmjs.org/jest-mock/-/jest-mock-29.4.3.tgz", + "integrity": "sha512-LjFgMg+xed9BdkPMyIJh+r3KeHt1klXPJYBULXVVAkbTaaKjPX1o1uVCAZADMEp/kOxGTwy/Ot8XbvgItOrHEg==", "dev": true, "dependencies": { - "color-convert": "^2.0.1" + "@jest/types": "^29.4.3", + "@types/node": "*", + "jest-util": "^29.4.3" }, "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/jest-message-util/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" - } - }, - "node_modules/jest-message-util/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/jest-message-util/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "node_modules/jest-message-util/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/jest-message-util/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/jest-mock": { - "version": "29.4.3", - "resolved": "https://registry.npmjs.org/jest-mock/-/jest-mock-29.4.3.tgz", - "integrity": "sha512-LjFgMg+xed9BdkPMyIJh+r3KeHt1klXPJYBULXVVAkbTaaKjPX1o1uVCAZADMEp/kOxGTwy/Ot8XbvgItOrHEg==", - "dev": true, - "dependencies": { - "@jest/types": "^29.4.3", - "@types/node": "*", - "jest-util": "^29.4.3" - }, - "engines": { - "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, "node_modules/jest-pnp-resolver": { @@ -5853,64 +5627,6 @@ "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, - "node_modules/jest-resolve/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/jest-resolve/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" - } - }, - "node_modules/jest-resolve/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/jest-resolve/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "node_modules/jest-resolve/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true, - "engines": { - "node": ">=8" - } - }, "node_modules/jest-resolve/node_modules/resolve": { "version": "1.22.1", "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.22.1.tgz", @@ -5928,18 +5644,6 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/jest-resolve/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, "node_modules/jest-runner": { "version": "29.4.3", "resolved": "https://registry.npmjs.org/jest-runner/-/jest-runner-29.4.3.tgz", @@ -5972,76 +5676,6 @@ "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, - "node_modules/jest-runner/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/jest-runner/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" - } - }, - "node_modules/jest-runner/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/jest-runner/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "node_modules/jest-runner/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/jest-runner/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, "node_modules/jest-runtime": { "version": "29.4.3", "resolved": "https://registry.npmjs.org/jest-runtime/-/jest-runtime-29.4.3.tgz", @@ -6075,76 +5709,6 @@ "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, - "node_modules/jest-runtime/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/jest-runtime/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" - } - }, - "node_modules/jest-runtime/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/jest-runtime/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "node_modules/jest-runtime/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/jest-runtime/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, "node_modules/jest-snapshot": { "version": "29.4.3", "resolved": "https://registry.npmjs.org/jest-snapshot/-/jest-snapshot-29.4.3.tgz", @@ -6180,64 +5744,6 @@ "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, - "node_modules/jest-snapshot/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/jest-snapshot/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" - } - }, - "node_modules/jest-snapshot/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/jest-snapshot/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "node_modules/jest-snapshot/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true, - "engines": { - "node": ">=8" - } - }, "node_modules/jest-snapshot/node_modules/lru-cache": { "version": "6.0.0", "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-6.0.0.tgz", @@ -6247,315 +5753,93 @@ "yallist": "^4.0.0" }, "engines": { - "node": ">=10" - } - }, - "node_modules/jest-snapshot/node_modules/semver": { - "version": "7.3.8", - "resolved": "https://registry.npmjs.org/semver/-/semver-7.3.8.tgz", - "integrity": "sha512-NB1ctGL5rlHrPJtFDVIVzTyQylMLu9N9VICA6HSFJo8MCGVTMW6gfpicwKmmK/dAjTOrqu5l63JJOpDSrAis3A==", - "dev": true, - "dependencies": { - "lru-cache": "^6.0.0" - }, - "bin": { - "semver": "bin/semver.js" - }, - "engines": { - "node": ">=10" - } - }, - "node_modules/jest-snapshot/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/jest-snapshot/node_modules/yallist": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz", - "integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==", - "dev": true - }, - "node_modules/jest-util": { - "version": "29.4.3", - "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-29.4.3.tgz", - "integrity": "sha512-ToSGORAz4SSSoqxDSylWX8JzkOQR7zoBtNRsA7e+1WUX5F8jrOwaNpuh1YfJHJKDHXLHmObv5eOjejUd+/Ws+Q==", - "dev": true, - "dependencies": { - "@jest/types": "^29.4.3", - "@types/node": "*", - "chalk": "^4.0.0", - "ci-info": "^3.2.0", - "graceful-fs": "^4.2.9", - "picomatch": "^2.2.3" - }, - "engines": { - "node": "^14.15.0 || ^16.10.0 || >=18.0.0" - } - }, - "node_modules/jest-util/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/jest-util/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" - } - }, - "node_modules/jest-util/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/jest-util/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "node_modules/jest-util/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/jest-util/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/jest-validate": { - "version": "29.4.3", - "resolved": "https://registry.npmjs.org/jest-validate/-/jest-validate-29.4.3.tgz", - "integrity": "sha512-J3u5v7aPQoXPzaar6GndAVhdQcZr/3osWSgTeKg5v574I9ybX/dTyH0AJFb5XgXIB7faVhf+rS7t4p3lL9qFaw==", - "dev": true, - "dependencies": { - "@jest/types": "^29.4.3", - "camelcase": "^6.2.0", - "chalk": "^4.0.0", - "jest-get-type": "^29.4.3", - "leven": "^3.1.0", - "pretty-format": "^29.4.3" - }, - "engines": { - "node": "^14.15.0 || ^16.10.0 || >=18.0.0" - } - }, - "node_modules/jest-validate/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/jest-validate/node_modules/camelcase": { - "version": "6.3.0", - "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-6.3.0.tgz", - "integrity": "sha512-Gmy6FhYlCY7uOElZUSbxo2UCDH8owEk996gkbrpsgGtrJLM3J7jGxl9Ic7Qwwj4ivOE5AWZWRMecDdF7hqGjFA==", - "dev": true, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/jest-validate/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" - } - }, - "node_modules/jest-validate/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/jest-validate/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "node_modules/jest-validate/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true, - "engines": { - "node": ">=8" + "node": ">=10" } }, - "node_modules/jest-validate/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "node_modules/jest-snapshot/node_modules/semver": { + "version": "7.3.8", + "resolved": "https://registry.npmjs.org/semver/-/semver-7.3.8.tgz", + "integrity": "sha512-NB1ctGL5rlHrPJtFDVIVzTyQylMLu9N9VICA6HSFJo8MCGVTMW6gfpicwKmmK/dAjTOrqu5l63JJOpDSrAis3A==", "dev": true, "dependencies": { - "has-flag": "^4.0.0" + "lru-cache": "^6.0.0" + }, + "bin": { + "semver": "bin/semver.js" }, "engines": { - "node": ">=8" + "node": ">=10" } }, - "node_modules/jest-watcher": { + "node_modules/jest-snapshot/node_modules/yallist": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz", + "integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==", + "dev": true + }, + "node_modules/jest-util": { "version": "29.4.3", - "resolved": "https://registry.npmjs.org/jest-watcher/-/jest-watcher-29.4.3.tgz", - "integrity": "sha512-zwlXH3DN3iksoIZNk73etl1HzKyi5FuQdYLnkQKm5BW4n8HpoG59xSwpVdFrnh60iRRaRBGw0gcymIxjJENPcA==", + "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-29.4.3.tgz", + "integrity": "sha512-ToSGORAz4SSSoqxDSylWX8JzkOQR7zoBtNRsA7e+1WUX5F8jrOwaNpuh1YfJHJKDHXLHmObv5eOjejUd+/Ws+Q==", "dev": true, "dependencies": { - "@jest/test-result": "^29.4.3", "@jest/types": "^29.4.3", "@types/node": "*", - "ansi-escapes": "^4.2.1", "chalk": "^4.0.0", - "emittery": "^0.13.1", - "jest-util": "^29.4.3", - "string-length": "^4.0.1" + "ci-info": "^3.2.0", + "graceful-fs": "^4.2.9", + "picomatch": "^2.2.3" }, "engines": { "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, - "node_modules/jest-watcher/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "node_modules/jest-validate": { + "version": "29.4.3", + "resolved": "https://registry.npmjs.org/jest-validate/-/jest-validate-29.4.3.tgz", + "integrity": "sha512-J3u5v7aPQoXPzaar6GndAVhdQcZr/3osWSgTeKg5v574I9ybX/dTyH0AJFb5XgXIB7faVhf+rS7t4p3lL9qFaw==", "dev": true, "dependencies": { - "color-convert": "^2.0.1" + "@jest/types": "^29.4.3", + "camelcase": "^6.2.0", + "chalk": "^4.0.0", + "jest-get-type": "^29.4.3", + "leven": "^3.1.0", + "pretty-format": "^29.4.3" }, "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, - "node_modules/jest-watcher/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "node_modules/jest-validate/node_modules/camelcase": { + "version": "6.3.0", + "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-6.3.0.tgz", + "integrity": "sha512-Gmy6FhYlCY7uOElZUSbxo2UCDH8owEk996gkbrpsgGtrJLM3J7jGxl9Ic7Qwwj4ivOE5AWZWRMecDdF7hqGjFA==", "dev": true, - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, "engines": { "node": ">=10" }, "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" - } - }, - "node_modules/jest-watcher/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/jest-watcher/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "node_modules/jest-watcher/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true, - "engines": { - "node": ">=8" + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/jest-watcher/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "node_modules/jest-watcher": { + "version": "29.4.3", + "resolved": "https://registry.npmjs.org/jest-watcher/-/jest-watcher-29.4.3.tgz", + "integrity": "sha512-zwlXH3DN3iksoIZNk73etl1HzKyi5FuQdYLnkQKm5BW4n8HpoG59xSwpVdFrnh60iRRaRBGw0gcymIxjJENPcA==", "dev": true, "dependencies": { - "has-flag": "^4.0.0" + "@jest/test-result": "^29.4.3", + "@jest/types": "^29.4.3", + "@types/node": "*", + "ansi-escapes": "^4.2.1", + "chalk": "^4.0.0", + "emittery": "^0.13.1", + "jest-util": "^29.4.3", + "string-length": "^4.0.1" }, "engines": { - "node": ">=8" + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, "node_modules/jest-worker": { @@ -6573,15 +5857,6 @@ "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, - "node_modules/jest-worker/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true, - "engines": { - "node": ">=8" - } - }, "node_modules/jest-worker/node_modules/supports-color": { "version": "8.1.1", "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-8.1.1.tgz", @@ -6601,7 +5876,8 @@ "version": "4.0.0", "resolved": "https://registry.npmjs.org/js-tokens/-/js-tokens-4.0.0.tgz", "integrity": "sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/js-yaml": { "version": "3.14.1", @@ -6616,6 +5892,46 @@ "js-yaml": "bin/js-yaml.js" } }, + "node_modules/jsdom": { + "version": "26.1.0", + "resolved": "https://registry.npmjs.org/jsdom/-/jsdom-26.1.0.tgz", + "integrity": "sha512-Cvc9WUhxSMEo4McES3P7oK3QaXldCfNWp7pl2NNeiIFlCoLr3kfq9kb1fxftiwk1FLV7CvpvDfonxtzUDeSOPg==", + "dev": true, + "license": "MIT", + "dependencies": { + "cssstyle": "^4.2.1", + "data-urls": "^5.0.0", + "decimal.js": "^10.5.0", + "html-encoding-sniffer": "^4.0.0", + "http-proxy-agent": "^7.0.2", + "https-proxy-agent": "^7.0.6", + "is-potential-custom-element-name": "^1.0.1", + "nwsapi": "^2.2.16", + "parse5": "^7.2.1", + "rrweb-cssom": "^0.8.0", + "saxes": "^6.0.0", + "symbol-tree": "^3.2.4", + "tough-cookie": "^5.1.1", + "w3c-xmlserializer": "^5.0.0", + "webidl-conversions": "^7.0.0", + "whatwg-encoding": "^3.1.1", + "whatwg-mimetype": "^4.0.0", + "whatwg-url": "^14.1.1", + "ws": "^8.18.0", + "xml-name-validator": "^5.0.0" + }, + "engines": { + "node": ">=18" + }, + "peerDependencies": { + "canvas": "^3.0.0" + }, + "peerDependenciesMeta": { + "canvas": { + "optional": true + } + } + }, "node_modules/jsep": { "version": "1.3.9", "resolved": "https://registry.npmjs.org/jsep/-/jsep-1.3.9.tgz", @@ -6990,6 +6306,13 @@ "node": ">=8" } }, + "node_modules/nwsapi": { + "version": "2.2.23", + "resolved": "https://registry.npmjs.org/nwsapi/-/nwsapi-2.2.23.tgz", + "integrity": "sha512-7wfH4sLbt4M0gCDzGE6vzQBo0bfTKjU7Sfpqy/7gs1qBfYz2vEJH6vXcBKpO3+6Yu1telwd0t9HpyOoLEQQbIQ==", + "dev": true, + "license": "MIT" + }, "node_modules/once": { "version": "1.4.0", "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", @@ -7119,6 +6442,19 @@ "url": "https://github.com/sponsors/sindresorhus" } }, + "node_modules/parse5": { + "version": "7.3.0", + "resolved": "https://registry.npmjs.org/parse5/-/parse5-7.3.0.tgz", + "integrity": "sha512-IInvU7fabl34qmi9gY8XOVxhYyMyuH2xUNpb2q8/Y+7552KlejkRvqvD19nMoUW/uQGGbqNpA6Tufu5FL5BZgw==", + "dev": true, + "license": "MIT", + "dependencies": { + "entities": "^6.0.0" + }, + "funding": { + "url": "https://github.com/inikulin/parse5?sponsor=1" + } + }, "node_modules/path-exists": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-4.0.0.tgz", @@ -7153,10 +6489,11 @@ "dev": true }, "node_modules/picocolors": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.0.0.tgz", - "integrity": "sha512-1fygroTLlHu66zi26VoTDv8yRgm0Fccecssto+MhsZ0D/DGW2sm8E8AjW7NU5VVTRt5GxbeZ5qBuJr+HyLYkjQ==", - "dev": true + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.1.1.tgz", + "integrity": "sha512-xceH2snhtb5M9liqDsmEw56le376mTZkEX/jEb/RxNFyegNul7eNslCXP9FDj/Lcu0X8KEyMceP2ntpaHrDEVA==", + "dev": true, + "license": "ISC" }, "node_modules/picomatch": { "version": "2.3.1", @@ -7247,6 +6584,16 @@ "once": "^1.3.1" } }, + "node_modules/punycode": { + "version": "2.3.1", + "resolved": "https://registry.npmjs.org/punycode/-/punycode-2.3.1.tgz", + "integrity": "sha512-vYt7UD1U9Wg6138shLtLOvdAu+8DsC/ilFtEVHcH+wydcSpNE20AfSOduf6MkRFahL5FY7X1oU7nKVZFtfq8Fg==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=6" + } + }, "node_modules/queue-microtask": { "version": "1.2.3", "resolved": "https://registry.npmjs.org/queue-microtask/-/queue-microtask-1.2.3.tgz", @@ -7269,10 +6616,11 @@ "license": "MIT" }, "node_modules/react-is": { - "version": "18.2.0", - "resolved": "https://registry.npmjs.org/react-is/-/react-is-18.2.0.tgz", - "integrity": "sha512-xWGDIW6x921xtzPkhiULtthJHoJvBbF3q26fzloPCK0hsvxtPVelvftw3zjbHWSkR2km9Z+4uxbDDK/6Zw9B8w==", - "dev": true + "version": "18.3.1", + "resolved": "https://registry.npmjs.org/react-is/-/react-is-18.3.1.tgz", + "integrity": "sha512-/LLMVyas0ljjAtoYiPqYiL8VWXzUUdThrmU5+n20DZv+a+ClRoevUzw5JxU+Ieh5/c87ytoTBV9G1FiKfNJdmg==", + "dev": true, + "license": "MIT" }, "node_modules/readdirp": { "version": "3.6.0", @@ -7445,6 +6793,13 @@ "node": ">=0.10.0" } }, + "node_modules/rrweb-cssom": { + "version": "0.8.0", + "resolved": "https://registry.npmjs.org/rrweb-cssom/-/rrweb-cssom-0.8.0.tgz", + "integrity": "sha512-guoltQEx+9aMf2gDZ0s62EcV8lsXR+0w8915TC3ITdn2YueuNjdAYh/levpU9nFaoChh9RUS5ZdQMrKfVEN9tw==", + "dev": true, + "license": "MIT" + }, "node_modules/run-parallel": { "version": "1.2.0", "resolved": "https://registry.npmjs.org/run-parallel/-/run-parallel-1.2.0.tgz", @@ -7478,6 +6833,13 @@ "tslib": "^2.1.0" } }, + "node_modules/safer-buffer": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz", + "integrity": "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==", + "dev": true, + "license": "MIT" + }, "node_modules/sass": { "version": "1.57.1", "resolved": "https://registry.npmjs.org/sass/-/sass-1.57.1.tgz", @@ -7501,6 +6863,19 @@ "integrity": "sha512-yqYn1JhPczigF94DMS+shiDMjDowYO6y9+wB/4WgO0Y19jWYk0lQ4tuG5KI7kj4FTp1wxPj5IFfcrz/s1c3jjQ==", "license": "BlueOak-1.0.0" }, + "node_modules/saxes": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/saxes/-/saxes-6.0.0.tgz", + "integrity": "sha512-xAg7SOnEhrm5zI3puOOKyy1OMcMlIJZYNJY7xLBwSze0UjhPLnWfj2GF2EpT0jmzaJKIWKHLsaSSajf35bcYnA==", + "dev": true, + "license": "ISC", + "dependencies": { + "xmlchars": "^2.2.0" + }, + "engines": { + "node": ">=v12.22.7" + } + }, "node_modules/semver": { "version": "6.3.0", "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.0.tgz", @@ -7939,15 +7314,16 @@ } }, "node_modules/supports-color": { - "version": "5.5.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.5.0.tgz", - "integrity": "sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==", + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", "dev": true, + "license": "MIT", "dependencies": { - "has-flag": "^3.0.0" + "has-flag": "^4.0.0" }, "engines": { - "node": ">=4" + "node": ">=8" } }, "node_modules/supports-preserve-symlinks-flag": { @@ -7962,6 +7338,13 @@ "url": "https://github.com/sponsors/ljharb" } }, + "node_modules/symbol-tree": { + "version": "3.2.4", + "resolved": "https://registry.npmjs.org/symbol-tree/-/symbol-tree-3.2.4.tgz", + "integrity": "sha512-9QNk5KwDF+Bvz+PyObkmSYjI5ksVUYtjW7AU22r2NKcfLJcXp96hkDWU3+XndOsUb+AQ9QhfzfCT2O+CNWT5Tw==", + "dev": true, + "license": "MIT" + }, "node_modules/test-exclude": { "version": "6.0.0", "resolved": "https://registry.npmjs.org/test-exclude/-/test-exclude-6.0.0.tgz", @@ -7976,6 +7359,26 @@ "node": ">=8" } }, + "node_modules/tldts": { + "version": "6.1.86", + "resolved": "https://registry.npmjs.org/tldts/-/tldts-6.1.86.tgz", + "integrity": "sha512-WMi/OQ2axVTf/ykqCQgXiIct+mSQDFdH2fkwhPwgEwvJ1kSzZRiinb0zF2Xb8u4+OqPChmyI6MEu4EezNJz+FQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "tldts-core": "^6.1.86" + }, + "bin": { + "tldts": "bin/cli.js" + } + }, + "node_modules/tldts-core": { + "version": "6.1.86", + "resolved": "https://registry.npmjs.org/tldts-core/-/tldts-core-6.1.86.tgz", + "integrity": "sha512-Je6p7pkk+KMzMv2XXKmAE3McmolOQFdxkKw0R8EYNr7sELW46JqnNeTX8ybPiQgvg1ymCoF8LXs5fzFaZvJPTA==", + "dev": true, + "license": "MIT" + }, "node_modules/tmpl": { "version": "1.0.5", "resolved": "https://registry.npmjs.org/tmpl/-/tmpl-1.0.5.tgz", @@ -8004,6 +7407,32 @@ "node": ">=8.0" } }, + "node_modules/tough-cookie": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/tough-cookie/-/tough-cookie-5.1.2.tgz", + "integrity": "sha512-FVDYdxtnj0G6Qm/DhNPSb8Ju59ULcup3tuJxkFb5K8Bv2pUXILbf0xZWU8PX8Ov19OXljbUyveOFwRMwkXzO+A==", + "dev": true, + "license": "BSD-3-Clause", + "dependencies": { + "tldts": "^6.1.32" + }, + "engines": { + "node": ">=16" + } + }, + "node_modules/tr46": { + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/tr46/-/tr46-5.1.1.tgz", + "integrity": "sha512-hdF5ZgjTqgAntKkklYw0R03MG2x/bSzTtkxmIRw/sTNV8YXsCJ1tfLAX23lhxhHJlEf3CRCOCGGWw3vI3GaSPw==", + "dev": true, + "license": "MIT", + "dependencies": { + "punycode": "^2.3.1" + }, + "engines": { + "node": ">=18" + } + }, "node_modules/ts-jest": { "version": "29.0.0", "resolved": "https://registry.npmjs.org/ts-jest/-/ts-jest-29.0.0.tgz", @@ -8281,6 +7710,19 @@ "webworker-threads": "^0.7.12" } }, + "node_modules/w3c-xmlserializer": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/w3c-xmlserializer/-/w3c-xmlserializer-5.0.0.tgz", + "integrity": "sha512-o8qghlI8NZHU1lLPrpi2+Uq7abh4GGPpYANlalzWxyWteJOCsr/P+oPBA49TOLu5FTZO4d3F9MnWJfiMo4BkmA==", + "dev": true, + "license": "MIT", + "dependencies": { + "xml-name-validator": "^5.0.0" + }, + "engines": { + "node": ">=18" + } + }, "node_modules/walker": { "version": "1.0.8", "resolved": "https://registry.npmjs.org/walker/-/walker-1.0.8.tgz", @@ -8290,18 +7732,66 @@ "makeerror": "1.0.12" } }, - "node_modules/webworker-threads": { - "version": "0.7.17", - "resolved": "https://registry.npmjs.org/webworker-threads/-/webworker-threads-0.7.17.tgz", - "integrity": "sha512-Y2w2aXBbDLk9IzTEb9u+MsODC3s4YlGI7g4h0t+1OAwIO8yBI9rQL35ZYlyayiCuWu1dZMH/P7kGU8OwW7YsyA==", - "hasInstallScript": true, - "optional": true, + "node_modules/webidl-conversions": { + "version": "7.0.0", + "resolved": "https://registry.npmjs.org/webidl-conversions/-/webidl-conversions-7.0.0.tgz", + "integrity": "sha512-VwddBukDzu71offAQR975unBIGqfKZpM+8ZX6ySk8nYhVoo5CYaZyzt3YBvYtRtO+aoGlqxPg/B87NGVZ/fu6g==", + "dev": true, + "license": "BSD-2-Clause", + "engines": { + "node": ">=12" + } + }, + "node_modules/webworker-threads": { + "version": "0.7.17", + "resolved": "https://registry.npmjs.org/webworker-threads/-/webworker-threads-0.7.17.tgz", + "integrity": "sha512-Y2w2aXBbDLk9IzTEb9u+MsODC3s4YlGI7g4h0t+1OAwIO8yBI9rQL35ZYlyayiCuWu1dZMH/P7kGU8OwW7YsyA==", + "hasInstallScript": true, + "optional": true, + "dependencies": { + "bindings": "^1.3.0", + "nan": "^2.11.0" + }, + "engines": { + "node": ">= 0.10.16" + } + }, + "node_modules/whatwg-encoding": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/whatwg-encoding/-/whatwg-encoding-3.1.1.tgz", + "integrity": "sha512-6qN4hJdMwfYBtE3YBTTHhoeuUrDBPZmbQaxWAqSALV/MeEnR5z1xd8UKud2RAkFoPkmB+hli1TZSnyi84xz1vQ==", + "deprecated": "Use @exodus/bytes instead for a more spec-conformant and faster implementation", + "dev": true, + "license": "MIT", + "dependencies": { + "iconv-lite": "0.6.3" + }, + "engines": { + "node": ">=18" + } + }, + "node_modules/whatwg-mimetype": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/whatwg-mimetype/-/whatwg-mimetype-4.0.0.tgz", + "integrity": "sha512-QaKxh0eNIi2mE9p2vEdzfagOKHCcj1pJ56EEHGQOVxp8r9/iszLUUV7v89x9O1p/T+NlTM5W7jW6+cz4Fq1YVg==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=18" + } + }, + "node_modules/whatwg-url": { + "version": "14.2.0", + "resolved": "https://registry.npmjs.org/whatwg-url/-/whatwg-url-14.2.0.tgz", + "integrity": "sha512-De72GdQZzNTUBBChsXueQUnPKDkg/5A5zp7pFDuQAj5UFoENpiACU0wlCvzpAGnTkj++ihpKwKyYewn/XNUbKw==", + "dev": true, + "license": "MIT", "dependencies": { - "bindings": "^1.3.0", - "nan": "^2.11.0" + "tr46": "^5.1.0", + "webidl-conversions": "^7.0.0" }, "engines": { - "node": ">= 0.10.16" + "node": ">=18" } }, "node_modules/which": { @@ -8336,39 +7826,6 @@ "url": "https://github.com/chalk/wrap-ansi?sponsor=1" } }, - "node_modules/wrap-ansi/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/wrap-ansi/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/wrap-ansi/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, "node_modules/wrappy": { "version": "1.0.2", "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", @@ -8388,6 +7845,45 @@ "node": "^12.13.0 || ^14.15.0 || >=16.0.0" } }, + "node_modules/ws": { + "version": "8.19.0", + "resolved": "https://registry.npmjs.org/ws/-/ws-8.19.0.tgz", + "integrity": "sha512-blAT2mjOEIi0ZzruJfIhb3nps74PRWTCz1IjglWEEpQl5XS/UNama6u2/rjFkDDouqr4L67ry+1aGIALViWjDg==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=10.0.0" + }, + "peerDependencies": { + "bufferutil": "^4.0.1", + "utf-8-validate": ">=5.0.2" + }, + "peerDependenciesMeta": { + "bufferutil": { + "optional": true + }, + "utf-8-validate": { + "optional": true + } + } + }, + "node_modules/xml-name-validator": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/xml-name-validator/-/xml-name-validator-5.0.0.tgz", + "integrity": "sha512-EvGK8EJ3DhaHfbRlETOWAS5pO9MZITeauHKJyb8wyajUfQUenkIg2MvLDTZ4T/TgIcm3HU0TFBgWWboAZ30UHg==", + "dev": true, + "license": "Apache-2.0", + "engines": { + "node": ">=18" + } + }, + "node_modules/xmlchars": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/xmlchars/-/xmlchars-2.2.0.tgz", + "integrity": "sha512-JZnDKK8B0RCDw84FNdDAIpZK+JuJw+s7Lz8nksI7SIuU3UXJJslUthsi+uWBUYOwPFwW7W7PRLRfUKpxjtjFCw==", + "dev": true, + "license": "MIT" + }, "node_modules/y18n": { "version": "5.0.8", "resolved": "https://registry.npmjs.org/y18n/-/y18n-5.0.8.tgz", @@ -8453,13 +7949,36 @@ } }, "dependencies": { + "@asamuzakjp/css-color": { + "version": "3.2.0", + "resolved": "https://registry.npmjs.org/@asamuzakjp/css-color/-/css-color-3.2.0.tgz", + "integrity": "sha512-K1A6z8tS3XsmCMM86xoWdn7Fkdn9m6RSVtocUrJYIwZnFVkng/PvkEoWtOWmP+Scc6saYWHWZYbndEEXxl24jw==", + "dev": true, + "requires": { + "@csstools/css-calc": "^2.1.3", + "@csstools/css-color-parser": "^3.0.9", + "@csstools/css-parser-algorithms": "^3.0.4", + "@csstools/css-tokenizer": "^3.0.3", + "lru-cache": "^10.4.3" + }, + "dependencies": { + "lru-cache": { + "version": "10.4.3", + "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-10.4.3.tgz", + "integrity": "sha512-JNAzZcXrCt42VGLuYz0zfAzDfAvJWW6AfYlDBQyDV5DClI2m5sAmK+OIO7s59XfsRsWHp02jAJrRadPRGTt6SQ==", + "dev": true + } + } + }, "@babel/code-frame": { - "version": "7.18.6", - "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.18.6.tgz", - "integrity": "sha512-TDCmlK5eOvH+eH7cdAFlNXeVJqWIQ7gW9tY1GJIpUtFb6CmjVyq2VM3u71bOyR8CRihcCgMUYoDNyLXao3+70Q==", + "version": "7.28.6", + "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.28.6.tgz", + "integrity": "sha512-JYgintcMjRiCvS8mMECzaEn+m3PfoQiyqukOMCCVQtoJGYJw8j/8LBJEiqkHLkfwCcs74E3pbAUFNg7d9VNJ+Q==", "dev": true, "requires": { - "@babel/highlight": "^7.18.6" + "@babel/helper-validator-identifier": "^7.28.5", + "js-tokens": "^4.0.0", + "picocolors": "^1.1.1" } }, "@babel/compat-data": { @@ -8720,9 +8239,9 @@ "dev": true }, "@babel/helper-validator-identifier": { - "version": "7.19.1", - "resolved": "https://registry.npmjs.org/@babel/helper-validator-identifier/-/helper-validator-identifier-7.19.1.tgz", - "integrity": "sha512-awrNfaMtnHUr653GgGEs++LlAvW6w+DcPrOliSMXWCKo597CwL5Acf/wWdNkf/tfEQE3mjkeD1YOVZOUV/od1w==", + "version": "7.28.5", + "resolved": "https://registry.npmjs.org/@babel/helper-validator-identifier/-/helper-validator-identifier-7.28.5.tgz", + "integrity": "sha512-qSs4ifwzKJSV39ucNjsvc6WVHs6b7S03sOh2OcHF9UHfVPqWWALUsNUVzhSBiItjRZoLHx7nIarVjqKVusUZ1Q==", "dev": true }, "@babel/helper-validator-option": { @@ -8754,17 +8273,6 @@ "@babel/types": "^7.21.0" } }, - "@babel/highlight": { - "version": "7.18.6", - "resolved": "https://registry.npmjs.org/@babel/highlight/-/highlight-7.18.6.tgz", - "integrity": "sha512-u7stbOuYjaPezCuLj29hNW1v64M2Md2qupEKP1fHc7WdOA3DgLh37suiSrZYY7haUB7iBeQZ9P1uiRF359do3g==", - "dev": true, - "requires": { - "@babel/helper-validator-identifier": "^7.18.6", - "chalk": "^2.0.0", - "js-tokens": "^4.0.0" - } - }, "@babel/parser": { "version": "7.21.2", "resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.21.2.tgz", @@ -9749,6 +9257,42 @@ } } }, + "@csstools/color-helpers": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/@csstools/color-helpers/-/color-helpers-5.1.0.tgz", + "integrity": "sha512-S11EXWJyy0Mz5SYvRmY8nJYTFFd1LCNV+7cXyAgQtOOuzb4EsgfqDufL+9esx72/eLhsRdGZwaldu/h+E4t4BA==", + "dev": true + }, + "@csstools/css-calc": { + "version": "2.1.4", + "resolved": "https://registry.npmjs.org/@csstools/css-calc/-/css-calc-2.1.4.tgz", + "integrity": "sha512-3N8oaj+0juUw/1H3YwmDDJXCgTB1gKU6Hc/bB502u9zR0q2vd786XJH9QfrKIEgFlZmhZiq6epXl4rHqhzsIgQ==", + "dev": true, + "requires": {} + }, + "@csstools/css-color-parser": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/@csstools/css-color-parser/-/css-color-parser-3.1.0.tgz", + "integrity": "sha512-nbtKwh3a6xNVIp/VRuXV64yTKnb1IjTAEEh3irzS+HkKjAOYLTGNb9pmVNntZ8iVBHcWDA2Dof0QtPgFI1BaTA==", + "dev": true, + "requires": { + "@csstools/color-helpers": "^5.1.0", + "@csstools/css-calc": "^2.1.4" + } + }, + "@csstools/css-parser-algorithms": { + "version": "3.0.5", + "resolved": "https://registry.npmjs.org/@csstools/css-parser-algorithms/-/css-parser-algorithms-3.0.5.tgz", + "integrity": "sha512-DaDeUkXZKjdGhgYaHNJTV9pV7Y9B3b644jCLs9Upc3VeNGg6LWARAT6O+Q+/COo+2gg/bM5rhpMAtf70WqfBdQ==", + "dev": true, + "requires": {} + }, + "@csstools/css-tokenizer": { + "version": "3.0.4", + "resolved": "https://registry.npmjs.org/@csstools/css-tokenizer/-/css-tokenizer-3.0.4.tgz", + "integrity": "sha512-Vd/9EVDiu6PPJt9yAh6roZP6El1xHrdvIVGjyBsHR0RYwNHgL7FJPyIIW4fANJNG6FtyZfvlRPpFI4ZM/lubvw==", + "dev": true + }, "@emnapi/runtime": { "version": "1.8.1", "resolved": "https://registry.npmjs.org/@emnapi/runtime/-/runtime-1.8.1.tgz", @@ -10001,57 +9545,6 @@ "jest-message-util": "^29.4.3", "jest-util": "^29.4.3", "slash": "^3.0.0" - }, - "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, - "chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - } - }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true - }, - "supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "requires": { - "has-flag": "^4.0.0" - } - } } }, "@jest/core": { @@ -10088,71 +9581,184 @@ "pretty-format": "^29.4.3", "slash": "^3.0.0", "strip-ansi": "^6.0.0" + } + }, + "@jest/environment": { + "version": "29.4.3", + "resolved": "https://registry.npmjs.org/@jest/environment/-/environment-29.4.3.tgz", + "integrity": "sha512-dq5S6408IxIa+lr54zeqce+QgI+CJT4nmmA+1yzFgtcsGK8c/EyiUb9XQOgz3BMKrRDfKseeOaxj2eO8LlD3lA==", + "dev": true, + "requires": { + "@jest/fake-timers": "^29.4.3", + "@jest/types": "^29.4.3", + "@types/node": "*", + "jest-mock": "^29.4.3" + } + }, + "@jest/environment-jsdom-abstract": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/environment-jsdom-abstract/-/environment-jsdom-abstract-30.2.0.tgz", + "integrity": "sha512-kazxw2L9IPuZpQ0mEt9lu9Z98SqR74xcagANmMBU16X0lS23yPc0+S6hGLUz8kVRlomZEs/5S/Zlpqwf5yu6OQ==", + "dev": true, + "requires": { + "@jest/environment": "30.2.0", + "@jest/fake-timers": "30.2.0", + "@jest/types": "30.2.0", + "@types/jsdom": "^21.1.7", + "@types/node": "*", + "jest-mock": "30.2.0", + "jest-util": "30.2.0" }, "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "@jest/environment": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/environment/-/environment-30.2.0.tgz", + "integrity": "sha512-/QPTL7OBJQ5ac09UDRa3EQes4gt1FTEG/8jZ/4v5IVzx+Cv7dLxlVIvfvSVRiiX2drWyXeBjkMSR8hvOWSog5g==", "dev": true, "requires": { - "color-convert": "^2.0.1" + "@jest/fake-timers": "30.2.0", + "@jest/types": "30.2.0", + "@types/node": "*", + "jest-mock": "30.2.0" } }, - "chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "@jest/fake-timers": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/fake-timers/-/fake-timers-30.2.0.tgz", + "integrity": "sha512-HI3tRLjRxAbBy0VO8dqqm7Hb2mIa8d5bg/NJkyQcOk7V118ObQML8RC5luTF/Zsg4474a+gDvhce7eTnP4GhYw==", "dev": true, "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" + "@jest/types": "30.2.0", + "@sinonjs/fake-timers": "^13.0.0", + "@types/node": "*", + "jest-message-util": "30.2.0", + "jest-mock": "30.2.0", + "jest-util": "30.2.0" } }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "@jest/schemas": { + "version": "30.0.5", + "resolved": "https://registry.npmjs.org/@jest/schemas/-/schemas-30.0.5.tgz", + "integrity": "sha512-DmdYgtezMkh3cpU8/1uyXakv3tJRcmcXxBOcO0tbaozPwpmh4YMsnWrQm9ZmZMfa5ocbxzbFk6O4bDPEc/iAnA==", "dev": true, "requires": { - "color-name": "~1.1.4" + "@sinclair/typebox": "^0.34.0" } }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", + "@jest/types": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/types/-/types-30.2.0.tgz", + "integrity": "sha512-H9xg1/sfVvyfU7o3zMfBEjQ1gcsdeTMgqHoYdN79tuLqfTtuu7WckRA1R5whDwOzxaZAeMKTYWqP+WCAi0CHsg==", + "dev": true, + "requires": { + "@jest/pattern": "30.0.1", + "@jest/schemas": "30.0.5", + "@types/istanbul-lib-coverage": "^2.0.6", + "@types/istanbul-reports": "^3.0.4", + "@types/node": "*", + "@types/yargs": "^17.0.33", + "chalk": "^4.1.2" + } + }, + "@sinclair/typebox": { + "version": "0.34.47", + "resolved": "https://registry.npmjs.org/@sinclair/typebox/-/typebox-0.34.47.tgz", + "integrity": "sha512-ZGIBQ+XDvO5JQku9wmwtabcVTHJsgSWAHYtVuM9pBNNR5E88v6Jcj/llpmsjivig5X8A8HHOb4/mbEKPS5EvAw==", "dev": true }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "@sinonjs/commons": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/@sinonjs/commons/-/commons-3.0.1.tgz", + "integrity": "sha512-K3mCHKQ9sVh8o1C9cxkwxaOmXoAMlDxC1mYyHrjqOWEcBjYr76t96zL2zlj5dUGZ3HSw240X1qgH3Mjf1yJWpQ==", + "dev": true, + "requires": { + "type-detect": "4.0.8" + } + }, + "@sinonjs/fake-timers": { + "version": "13.0.5", + "resolved": "https://registry.npmjs.org/@sinonjs/fake-timers/-/fake-timers-13.0.5.tgz", + "integrity": "sha512-36/hTbH2uaWuGVERyC6da9YwGWnzUZXuPro/F2LfsdOsLnCojz/iSH8MxUt/FD2S5XBSVPhmArFUXcpCQ2Hkiw==", + "dev": true, + "requires": { + "@sinonjs/commons": "^3.0.1" + } + }, + "ci-info": { + "version": "4.3.1", + "resolved": "https://registry.npmjs.org/ci-info/-/ci-info-4.3.1.tgz", + "integrity": "sha512-Wdy2Igu8OcBpI2pZePZ5oWjPC38tmDVx5WKUXKwlLYkA0ozo85sLsLvkBbBn/sZaSCMFOGZJ14fvW9t5/d7kdA==", "dev": true }, - "supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "jest-message-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-message-util/-/jest-message-util-30.2.0.tgz", + "integrity": "sha512-y4DKFLZ2y6DxTWD4cDe07RglV88ZiNEdlRfGtqahfbIjfsw1nMCPx49Uev4IA/hWn3sDKyAnSPwoYSsAEdcimw==", "dev": true, "requires": { - "has-flag": "^4.0.0" + "@babel/code-frame": "^7.27.1", + "@jest/types": "30.2.0", + "@types/stack-utils": "^2.0.3", + "chalk": "^4.1.2", + "graceful-fs": "^4.2.11", + "micromatch": "^4.0.8", + "pretty-format": "30.2.0", + "slash": "^3.0.0", + "stack-utils": "^2.0.6" + } + }, + "jest-mock": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-mock/-/jest-mock-30.2.0.tgz", + "integrity": "sha512-JNNNl2rj4b5ICpmAcq+WbLH83XswjPbjH4T7yvGzfAGCPh1rw+xVNbtk+FnRslvt9lkCcdn9i1oAoKUuFsOxRw==", + "dev": true, + "requires": { + "@jest/types": "30.2.0", + "@types/node": "*", + "jest-util": "30.2.0" + } + }, + "jest-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-30.2.0.tgz", + "integrity": "sha512-QKNsM0o3Xe6ISQU869e+DhG+4CK/48aHYdJZGlFQVTjnbvgpcKyxpzk29fGiO7i/J8VENZ+d2iGnSsvmuHywlA==", + "dev": true, + "requires": { + "@jest/types": "30.2.0", + "@types/node": "*", + "chalk": "^4.1.2", + "ci-info": "^4.2.0", + "graceful-fs": "^4.2.11", + "picomatch": "^4.0.2" + } + }, + "picomatch": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.3.tgz", + "integrity": "sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==", + "dev": true + }, + "pretty-format": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/pretty-format/-/pretty-format-30.2.0.tgz", + "integrity": "sha512-9uBdv/B4EefsuAL+pWqueZyZS2Ba+LxfFeQ9DN14HU4bN8bhaxKdkpjpB6fs9+pSjIBu+FXQHImEg8j/Lw0+vA==", + "dev": true, + "requires": { + "@jest/schemas": "30.0.5", + "ansi-styles": "^5.2.0", + "react-is": "^18.3.1" + }, + "dependencies": { + "ansi-styles": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-5.2.0.tgz", + "integrity": "sha512-Cxwpt2SfTzTtXcfOlzGEee8O+c+MmUgGrNiBcXnuWxuFJHe6a5Hz7qwhwe5OgaSYI0IJvkLqWX1ASG+cJOkEiA==", + "dev": true + } } } } }, - "@jest/environment": { - "version": "29.4.3", - "resolved": "https://registry.npmjs.org/@jest/environment/-/environment-29.4.3.tgz", - "integrity": "sha512-dq5S6408IxIa+lr54zeqce+QgI+CJT4nmmA+1yzFgtcsGK8c/EyiUb9XQOgz3BMKrRDfKseeOaxj2eO8LlD3lA==", - "dev": true, - "requires": { - "@jest/fake-timers": "^29.4.3", - "@jest/types": "^29.4.3", - "@types/node": "*", - "jest-mock": "^29.4.3" - } - }, "@jest/expect": { "version": "29.4.3", "resolved": "https://registry.npmjs.org/@jest/expect/-/expect-29.4.3.tgz", @@ -10198,6 +9804,24 @@ "jest-mock": "^29.4.3" } }, + "@jest/pattern": { + "version": "30.0.1", + "resolved": "https://registry.npmjs.org/@jest/pattern/-/pattern-30.0.1.tgz", + "integrity": "sha512-gWp7NfQW27LaBQz3TITS8L7ZCQ0TLvtmI//4OwlQRx4rnWxcPNIYjxZpDcN4+UlGxgm3jS5QPz8IPTCkb59wZA==", + "dev": true, + "requires": { + "@types/node": "*", + "jest-regex-util": "30.0.1" + }, + "dependencies": { + "jest-regex-util": { + "version": "30.0.1", + "resolved": "https://registry.npmjs.org/jest-regex-util/-/jest-regex-util-30.0.1.tgz", + "integrity": "sha512-jHEQgBXAgc+Gh4g0p3bCevgRCVRkB4VB70zhoAE48gxeSr1hfUOsM/C2WoJgVL7Eyg//hudYENbm3Ne+/dRVVA==", + "dev": true + } + } + }, "@jest/reporters": { "version": "29.4.3", "resolved": "https://registry.npmjs.org/@jest/reporters/-/reporters-29.4.3.tgz", @@ -10228,57 +9852,6 @@ "string-length": "^4.0.1", "strip-ansi": "^6.0.0", "v8-to-istanbul": "^9.0.1" - }, - "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, - "chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - } - }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true - }, - "supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "requires": { - "has-flag": "^4.0.0" - } - } } }, "@jest/schemas": { @@ -10344,64 +9917,15 @@ "jest-util": "^29.4.3", "micromatch": "^4.0.4", "pirates": "^4.0.4", - "slash": "^3.0.0", - "write-file-atomic": "^4.0.2" - }, - "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, - "chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - } - }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, + "slash": "^3.0.0", + "write-file-atomic": "^4.0.2" + }, + "dependencies": { "convert-source-map": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/convert-source-map/-/convert-source-map-2.0.0.tgz", "integrity": "sha512-Kvp459HrV2FEJ1CAsi1Ku+MY3kasH19TFykTz2xWmMeq6bk2NU3XXvfJ+Q61m0xktWwt+1HSYf3JZsTms3aRJg==", "dev": true - }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true - }, - "supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "requires": { - "has-flag": "^4.0.0" - } } } }, @@ -10417,57 +9941,6 @@ "@types/node": "*", "@types/yargs": "^17.0.8", "chalk": "^4.0.0" - }, - "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, - "chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - } - }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true - }, - "supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "requires": { - "has-flag": "^4.0.0" - } - } } }, "@jridgewell/gen-mapping": { @@ -10634,15 +10107,6 @@ "redent": "^3.0.0" }, "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, "chalk": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/chalk/-/chalk-3.0.0.tgz", @@ -10652,36 +10116,6 @@ "ansi-styles": "^4.1.0", "supports-color": "^7.1.0" } - }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true - }, - "supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "requires": { - "has-flag": "^4.0.0" - } } } }, @@ -10765,9 +10199,9 @@ } }, "@types/istanbul-lib-coverage": { - "version": "2.0.4", - "resolved": "https://registry.npmjs.org/@types/istanbul-lib-coverage/-/istanbul-lib-coverage-2.0.4.tgz", - "integrity": "sha512-z/QT1XN4K4KYuslS23k62yDIDLwLFkzxOuMplDtObz0+y7VqJCaO2o+SPwHCvLFZh7xazvvoor2tA/hPz9ee7g==", + "version": "2.0.6", + "resolved": "https://registry.npmjs.org/@types/istanbul-lib-coverage/-/istanbul-lib-coverage-2.0.6.tgz", + "integrity": "sha512-2QF/t/auWm0lsy8XtKVPG19v3sSOQlJe/YHZgfjb/KBBHOGSV+J2q/S671rcq9uTBrLAXmZpqJiaQbMT+zNU1w==", "dev": true }, "@types/istanbul-lib-report": { @@ -10780,9 +10214,9 @@ } }, "@types/istanbul-reports": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/@types/istanbul-reports/-/istanbul-reports-3.0.1.tgz", - "integrity": "sha512-c3mAZEuK0lvBp8tmuL74XRKn1+y2dcwOUpH7x4WrF6gk1GIgiluDRgMYQtw2OFcBvAJWlt6ASU3tSqxp0Uu0Aw==", + "version": "3.0.4", + "resolved": "https://registry.npmjs.org/@types/istanbul-reports/-/istanbul-reports-3.0.4.tgz", + "integrity": "sha512-pk2B1NWalF9toCRu6gjBzR69syFjP4Od8WRAX+0mmf9lAjCRicLOWc+ZrxZHx/0XRjotgkF9t6iaMJ+aXcOdZQ==", "dev": true, "requires": { "@types/istanbul-lib-report": "*" @@ -10798,6 +10232,17 @@ "pretty-format": "^29.0.0" } }, + "@types/jsdom": { + "version": "21.1.7", + "resolved": "https://registry.npmjs.org/@types/jsdom/-/jsdom-21.1.7.tgz", + "integrity": "sha512-yOriVnggzrnQ3a9OKOCxaVuSug3w3/SbOj5i7VwXWZEyUNl3bLF9V3MfxGbZKuwqJOQyRfqXyROBB1CoZLFWzA==", + "dev": true, + "requires": { + "@types/node": "*", + "@types/tough-cookie": "*", + "parse5": "^7.0.0" + } + }, "@types/ndarray": { "version": "1.0.14", "resolved": "https://registry.npmjs.org/@types/ndarray/-/ndarray-1.0.14.tgz", @@ -10816,9 +10261,9 @@ "dev": true }, "@types/stack-utils": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/@types/stack-utils/-/stack-utils-2.0.1.tgz", - "integrity": "sha512-Hl219/BT5fLAaz6NDkSuhzasy49dwQS/DSdu4MdggFB8zcXv7vflBI3xp7FEmkmdDkBUI2bPUNeMttp2knYdxw==", + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/@types/stack-utils/-/stack-utils-2.0.3.tgz", + "integrity": "sha512-9aEbYZ3TbYMznPdcdr3SmIrLXwC/AKZXQeCf9Pgao5CKb8CyHuEX5jzWPTkvregvhRJHcpRO6BFoGW9ycaOkYw==", "dev": true }, "@types/testing-library__jest-dom": { @@ -10830,10 +10275,16 @@ "@types/jest": "*" } }, + "@types/tough-cookie": { + "version": "4.0.5", + "resolved": "https://registry.npmjs.org/@types/tough-cookie/-/tough-cookie-4.0.5.tgz", + "integrity": "sha512-/Ad8+nIOV7Rl++6f1BdKxFSMgmoqEoYbHRpPcx3JEfv8VRsQe9Z4mCXeJBzxs7mbHY/XOZZuXlRNfhpVPbs6ZA==", + "dev": true + }, "@types/yargs": { - "version": "17.0.22", - "resolved": "https://registry.npmjs.org/@types/yargs/-/yargs-17.0.22.tgz", - "integrity": "sha512-pet5WJ9U8yPVRhkwuEIp5ktAeAqRZOq4UdAyWLWzxbtpyXnzbtLdKiXAjJzi/KLmPGS9wk86lUFWZFN6sISo4g==", + "version": "17.0.35", + "resolved": "https://registry.npmjs.org/@types/yargs/-/yargs-17.0.35.tgz", + "integrity": "sha512-qUHkeCyQFxMXg79wQfTtfndEC+N9ZZg76HJftDJp+qH2tV7Gj4OJi7l+PiWwJ+pWtW8GwSmqsDj/oymhrTWXjg==", "dev": true, "requires": { "@types/yargs-parser": "*" @@ -10857,6 +10308,12 @@ "integrity": "sha512-k+iyHEuPgSw6SbuDpGQM+06HQUa04DZ3o+F6CSzXMvvI5KMvnaEqXe+YVe555R9nn6GPt404fos4wcgpw12SDA==", "dev": true }, + "agent-base": { + "version": "7.1.4", + "resolved": "https://registry.npmjs.org/agent-base/-/agent-base-7.1.4.tgz", + "integrity": "sha512-MnA+YT8fwfJPgBx3m60MNqakm30XOkyIoH1y6huTQvC0PwZG7ki8NacLBcrPbNoo8vEZy7Jpuk7+jMO+CUovTQ==", + "dev": true + }, "ansi-escapes": { "version": "4.3.2", "resolved": "https://registry.npmjs.org/ansi-escapes/-/ansi-escapes-4.3.2.tgz", @@ -10873,12 +10330,12 @@ "dev": true }, "ansi-styles": { - "version": "3.2.1", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz", - "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", "dev": true, "requires": { - "color-convert": "^1.9.0" + "color-convert": "^2.0.1" } }, "anymatch": { @@ -10941,57 +10398,6 @@ "chalk": "^4.0.0", "graceful-fs": "^4.2.9", "slash": "^3.0.0" - }, - "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, - "chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - } - }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true - }, - "supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "requires": { - "has-flag": "^4.0.0" - } - } } }, "babel-plugin-istanbul": { @@ -11180,14 +10586,13 @@ "dev": true }, "chalk": { - "version": "2.4.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.2.tgz", - "integrity": "sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==", + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", "dev": true, "requires": { - "ansi-styles": "^3.2.1", - "escape-string-regexp": "^1.0.5", - "supports-color": "^5.3.0" + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" } }, "char-regex": { @@ -11248,18 +10653,18 @@ "dev": true }, "color-convert": { - "version": "1.9.3", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-1.9.3.tgz", - "integrity": "sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg==", + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", "dev": true, "requires": { - "color-name": "1.1.3" + "color-name": "~1.1.4" } }, "color-name": { - "version": "1.1.3", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.3.tgz", - "integrity": "sha512-72fSenhMw2HZMTVHeCA9KCmpEIbzWiQsjN+BHcBbS9vr1mtt+vJjPdksIBNUmKAW8TFUDPJK5SUU3QhE9NEXDw==", + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", "dev": true }, "commander": { @@ -11341,6 +10746,16 @@ "integrity": "sha512-YUifsXXuknHlUsmlgyY0PKzgPOr7/FjCePfHNt0jxm83wHZi44VDMQ7/fGNkjY3/jV1MC+1CmZbaHzugyeRtpg==", "dev": true }, + "cssstyle": { + "version": "4.6.0", + "resolved": "https://registry.npmjs.org/cssstyle/-/cssstyle-4.6.0.tgz", + "integrity": "sha512-2z+rWdzbbSZv6/rhtvzvqeZQHrBaqgogqt85sqFNbabZOuFbCVFb8kPeEtZjiKkbrm395irpNKiYeFeLiQnFPg==", + "dev": true, + "requires": { + "@asamuzakjp/css-color": "^3.2.0", + "rrweb-cssom": "^0.8.0" + } + }, "cwise-compiler": { "version": "1.1.3", "resolved": "https://registry.npmjs.org/cwise-compiler/-/cwise-compiler-1.1.3.tgz", @@ -11349,6 +10764,16 @@ "uniq": "^1.0.0" } }, + "data-urls": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/data-urls/-/data-urls-5.0.0.tgz", + "integrity": "sha512-ZYP5VBHshaDAiVZxjbRVcFJpc+4xGgT0bK3vzy1HLN8jTO975HEbuYzZJcHoQEY5K1a0z8YayJkyVETa08eNTg==", + "dev": true, + "requires": { + "whatwg-mimetype": "^4.0.0", + "whatwg-url": "^14.0.0" + } + }, "debug": { "version": "4.3.4", "resolved": "https://registry.npmjs.org/debug/-/debug-4.3.4.tgz", @@ -11358,6 +10783,12 @@ "ms": "2.1.2" } }, + "decimal.js": { + "version": "10.6.0", + "resolved": "https://registry.npmjs.org/decimal.js/-/decimal.js-10.6.0.tgz", + "integrity": "sha512-YpgQiITW3JXGntzdUmyUR1V812Hn8T1YVXhCu+wO3OpS4eU9l4YdD3qjyiKdV6mvV29zapkMeD390UVEf2lkUg==", + "dev": true + }, "decode-uri-component": { "version": "0.2.2", "resolved": "https://registry.npmjs.org/decode-uri-component/-/decode-uri-component-0.2.2.tgz", @@ -11443,6 +10874,12 @@ "once": "^1.4.0" } }, + "entities": { + "version": "6.0.1", + "resolved": "https://registry.npmjs.org/entities/-/entities-6.0.1.tgz", + "integrity": "sha512-aN97NXWF6AWBTahfVOIrB/NShkzi5H7F9r1s9mD3cDj4Ko5f2qhhVoYMibXF7GlLveb/D2ioWay8lxI97Ven3g==", + "dev": true + }, "error-ex": { "version": "1.3.2", "resolved": "https://registry.npmjs.org/error-ex/-/error-ex-1.3.2.tgz", @@ -11471,12 +10908,6 @@ "integrity": "sha512-k0er2gUkLf8O0zKJiAhmkTnJlTvINGv7ygDNPbeIsX/TJjGJZHuh9B2UxbsaEkmlEo9MfhrSzmhIlhRlI2GXnw==", "dev": true }, - "escape-string-regexp": { - "version": "1.0.5", - "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz", - "integrity": "sha512-vbRorB5FUQWvla16U8R/qgaFIya2qGzwDrNmCZuYKrbdSUMG6I1ZCGQRefkRVhuOkIGVne7BQ35DSfo1qvJqFg==", - "dev": true - }, "esprima": { "version": "4.0.1", "resolved": "https://registry.npmjs.org/esprima/-/esprima-4.0.1.tgz", @@ -11683,9 +11114,9 @@ "dev": true }, "graceful-fs": { - "version": "4.2.10", - "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.10.tgz", - "integrity": "sha512-9ByhssR2fPVsNZj478qUUbKfmL0+t5BDVyjShtyZZLiK7ZDAArFFfopyOTj0M05wE2tJPisA4iTnnXl2YoPvOA==", + "version": "4.2.11", + "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.11.tgz", + "integrity": "sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ==", "dev": true }, "has": { @@ -11698,23 +11129,61 @@ } }, "has-flag": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-3.0.0.tgz", - "integrity": "sha512-sKJf1+ceQBr4SMkvQnBDNDtf4TXpVhVGateu0t918bl30FnbE2m4vNLX+VWe/dpjlb+HugGYzW7uQXH98HPEYw==", + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", "dev": true }, + "html-encoding-sniffer": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/html-encoding-sniffer/-/html-encoding-sniffer-4.0.0.tgz", + "integrity": "sha512-Y22oTqIU4uuPgEemfz7NDJz6OeKf12Lsu+QC+s3BVpda64lTiMYCyGwg5ki4vFxkMwQdeZDl2adZoqUgdFuTgQ==", + "dev": true, + "requires": { + "whatwg-encoding": "^3.1.1" + } + }, "html-escaper": { "version": "2.0.2", "resolved": "https://registry.npmjs.org/html-escaper/-/html-escaper-2.0.2.tgz", "integrity": "sha512-H2iMtd0I4Mt5eYiapRdIDjp+XzelXQ0tFE4JS7YFwFevXXMmOp9myNrUvCg0D6ws8iqkRPBfKHgbwig1SmlLfg==", "dev": true }, + "http-proxy-agent": { + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/http-proxy-agent/-/http-proxy-agent-7.0.2.tgz", + "integrity": "sha512-T1gkAiYYDWYx3V5Bmyu7HcfcvL7mUrTWiM6yOfa3PIphViJ/gFPbvidQ+veqSOHci/PxBcDabeUNCzpOODJZig==", + "dev": true, + "requires": { + "agent-base": "^7.1.0", + "debug": "^4.3.4" + } + }, + "https-proxy-agent": { + "version": "7.0.6", + "resolved": "https://registry.npmjs.org/https-proxy-agent/-/https-proxy-agent-7.0.6.tgz", + "integrity": "sha512-vK9P5/iUfdl95AI+JVyUuIcVtd4ofvtrOr3HNtM2yxC9bnMbEdp3x01OhQNnjb8IJYi38VlTE3mBXwcfvywuSw==", + "dev": true, + "requires": { + "agent-base": "^7.1.2", + "debug": "4" + } + }, "human-signals": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/human-signals/-/human-signals-2.1.0.tgz", "integrity": "sha512-B4FFZ6q/T2jhhksgkbEW3HBvWIfDW85snkQgawt07S7J5QXTk6BkNV+0yAeZrM5QpMAdYlocGoljn0sJ/WQkFw==", "dev": true }, + "iconv-lite": { + "version": "0.6.3", + "resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.6.3.tgz", + "integrity": "sha512-4fCk79wshMdzMp2rH06qWrJE4iolqLhCUH+OiuIgU++RB0+94NlDL81atO7GX55uUKueo0txHNtvEyI6D7WdMw==", + "dev": true, + "requires": { + "safer-buffer": ">= 2.1.2 < 3.0.0" + } + }, "immutable": { "version": "4.2.4", "resolved": "https://registry.npmjs.org/immutable/-/immutable-4.2.4.tgz", @@ -11838,6 +11307,12 @@ "integrity": "sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==", "dev": true }, + "is-potential-custom-element-name": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/is-potential-custom-element-name/-/is-potential-custom-element-name-1.0.1.tgz", + "integrity": "sha512-bCYeRA2rVibKZd+s2625gGnGF/t7DSqDs4dP7CrLA1m7jKWz6pps0LpYLJN8Q64HtmPKJ1hrN3nzPNKFEKOUiQ==", + "dev": true + }, "is-stream": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/is-stream/-/is-stream-2.0.1.tgz", @@ -11887,23 +11362,6 @@ "istanbul-lib-coverage": "^3.0.0", "make-dir": "^3.0.0", "supports-color": "^7.1.0" - }, - "dependencies": { - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true - }, - "supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "requires": { - "has-flag": "^4.0.0" - } - } } }, "istanbul-lib-source-maps": { @@ -11982,128 +11440,26 @@ "pretty-format": "^29.4.3", "slash": "^3.0.0", "stack-utils": "^2.0.3" - }, - "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, - "chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - } - }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true - }, - "supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "requires": { - "has-flag": "^4.0.0" - } - } } }, "jest-cli": { "version": "29.4.3", - "resolved": "https://registry.npmjs.org/jest-cli/-/jest-cli-29.4.3.tgz", - "integrity": "sha512-PiiAPuFNfWWolCE6t3ZrDXQc6OsAuM3/tVW0u27UWc1KE+n/HSn5dSE6B2juqN7WP+PP0jAcnKtGmI4u8GMYCg==", - "dev": true, - "requires": { - "@jest/core": "^29.4.3", - "@jest/test-result": "^29.4.3", - "@jest/types": "^29.4.3", - "chalk": "^4.0.0", - "exit": "^0.1.2", - "graceful-fs": "^4.2.9", - "import-local": "^3.0.2", - "jest-config": "^29.4.3", - "jest-util": "^29.4.3", - "jest-validate": "^29.4.3", - "prompts": "^2.0.1", - "yargs": "^17.3.1" - }, - "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, - "chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - } - }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true - }, - "supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "requires": { - "has-flag": "^4.0.0" - } - } + "resolved": "https://registry.npmjs.org/jest-cli/-/jest-cli-29.4.3.tgz", + "integrity": "sha512-PiiAPuFNfWWolCE6t3ZrDXQc6OsAuM3/tVW0u27UWc1KE+n/HSn5dSE6B2juqN7WP+PP0jAcnKtGmI4u8GMYCg==", + "dev": true, + "requires": { + "@jest/core": "^29.4.3", + "@jest/test-result": "^29.4.3", + "@jest/types": "^29.4.3", + "chalk": "^4.0.0", + "exit": "^0.1.2", + "graceful-fs": "^4.2.9", + "import-local": "^3.0.2", + "jest-config": "^29.4.3", + "jest-util": "^29.4.3", + "jest-validate": "^29.4.3", + "prompts": "^2.0.1", + "yargs": "^17.3.1" } }, "jest-config": { @@ -12136,15 +11492,6 @@ "strip-json-comments": "^3.1.1" }, "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, "babel-jest": { "version": "29.4.3", "resolved": "https://registry.npmjs.org/babel-jest/-/babel-jest-29.4.3.tgz", @@ -12159,46 +11506,6 @@ "graceful-fs": "^4.2.9", "slash": "^3.0.0" } - }, - "chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - } - }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true - }, - "supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "requires": { - "has-flag": "^4.0.0" - } } } }, @@ -12212,57 +11519,6 @@ "diff-sequences": "^29.4.3", "jest-get-type": "^29.4.3", "pretty-format": "^29.4.3" - }, - "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, - "chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - } - }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true - }, - "supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "requires": { - "has-flag": "^4.0.0" - } - } } }, "jest-docblock": { @@ -12285,55 +11541,164 @@ "jest-get-type": "^29.4.3", "jest-util": "^29.4.3", "pretty-format": "^29.4.3" + } + }, + "jest-environment-jsdom": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-environment-jsdom/-/jest-environment-jsdom-30.2.0.tgz", + "integrity": "sha512-zbBTiqr2Vl78pKp/laGBREYzbZx9ZtqPjOK4++lL4BNDhxRnahg51HtoDrk9/VjIy9IthNEWdKVd7H5bqBhiWQ==", + "dev": true, + "requires": { + "@jest/environment": "30.2.0", + "@jest/environment-jsdom-abstract": "30.2.0", + "@types/jsdom": "^21.1.7", + "@types/node": "*", + "jsdom": "^26.1.0" }, "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "@jest/environment": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/environment/-/environment-30.2.0.tgz", + "integrity": "sha512-/QPTL7OBJQ5ac09UDRa3EQes4gt1FTEG/8jZ/4v5IVzx+Cv7dLxlVIvfvSVRiiX2drWyXeBjkMSR8hvOWSog5g==", "dev": true, "requires": { - "color-convert": "^2.0.1" + "@jest/fake-timers": "30.2.0", + "@jest/types": "30.2.0", + "@types/node": "*", + "jest-mock": "30.2.0" } }, - "chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "@jest/fake-timers": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/fake-timers/-/fake-timers-30.2.0.tgz", + "integrity": "sha512-HI3tRLjRxAbBy0VO8dqqm7Hb2mIa8d5bg/NJkyQcOk7V118ObQML8RC5luTF/Zsg4474a+gDvhce7eTnP4GhYw==", "dev": true, "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" + "@jest/types": "30.2.0", + "@sinonjs/fake-timers": "^13.0.0", + "@types/node": "*", + "jest-message-util": "30.2.0", + "jest-mock": "30.2.0", + "jest-util": "30.2.0" } }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "@jest/schemas": { + "version": "30.0.5", + "resolved": "https://registry.npmjs.org/@jest/schemas/-/schemas-30.0.5.tgz", + "integrity": "sha512-DmdYgtezMkh3cpU8/1uyXakv3tJRcmcXxBOcO0tbaozPwpmh4YMsnWrQm9ZmZMfa5ocbxzbFk6O4bDPEc/iAnA==", + "dev": true, + "requires": { + "@sinclair/typebox": "^0.34.0" + } + }, + "@jest/types": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/types/-/types-30.2.0.tgz", + "integrity": "sha512-H9xg1/sfVvyfU7o3zMfBEjQ1gcsdeTMgqHoYdN79tuLqfTtuu7WckRA1R5whDwOzxaZAeMKTYWqP+WCAi0CHsg==", "dev": true, "requires": { - "color-name": "~1.1.4" + "@jest/pattern": "30.0.1", + "@jest/schemas": "30.0.5", + "@types/istanbul-lib-coverage": "^2.0.6", + "@types/istanbul-reports": "^3.0.4", + "@types/node": "*", + "@types/yargs": "^17.0.33", + "chalk": "^4.1.2" } }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", + "@sinclair/typebox": { + "version": "0.34.47", + "resolved": "https://registry.npmjs.org/@sinclair/typebox/-/typebox-0.34.47.tgz", + "integrity": "sha512-ZGIBQ+XDvO5JQku9wmwtabcVTHJsgSWAHYtVuM9pBNNR5E88v6Jcj/llpmsjivig5X8A8HHOb4/mbEKPS5EvAw==", "dev": true }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "@sinonjs/commons": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/@sinonjs/commons/-/commons-3.0.1.tgz", + "integrity": "sha512-K3mCHKQ9sVh8o1C9cxkwxaOmXoAMlDxC1mYyHrjqOWEcBjYr76t96zL2zlj5dUGZ3HSw240X1qgH3Mjf1yJWpQ==", + "dev": true, + "requires": { + "type-detect": "4.0.8" + } + }, + "@sinonjs/fake-timers": { + "version": "13.0.5", + "resolved": "https://registry.npmjs.org/@sinonjs/fake-timers/-/fake-timers-13.0.5.tgz", + "integrity": "sha512-36/hTbH2uaWuGVERyC6da9YwGWnzUZXuPro/F2LfsdOsLnCojz/iSH8MxUt/FD2S5XBSVPhmArFUXcpCQ2Hkiw==", + "dev": true, + "requires": { + "@sinonjs/commons": "^3.0.1" + } + }, + "ansi-styles": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-5.2.0.tgz", + "integrity": "sha512-Cxwpt2SfTzTtXcfOlzGEee8O+c+MmUgGrNiBcXnuWxuFJHe6a5Hz7qwhwe5OgaSYI0IJvkLqWX1ASG+cJOkEiA==", "dev": true }, - "supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "ci-info": { + "version": "4.3.1", + "resolved": "https://registry.npmjs.org/ci-info/-/ci-info-4.3.1.tgz", + "integrity": "sha512-Wdy2Igu8OcBpI2pZePZ5oWjPC38tmDVx5WKUXKwlLYkA0ozo85sLsLvkBbBn/sZaSCMFOGZJ14fvW9t5/d7kdA==", + "dev": true + }, + "jest-message-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-message-util/-/jest-message-util-30.2.0.tgz", + "integrity": "sha512-y4DKFLZ2y6DxTWD4cDe07RglV88ZiNEdlRfGtqahfbIjfsw1nMCPx49Uev4IA/hWn3sDKyAnSPwoYSsAEdcimw==", "dev": true, "requires": { - "has-flag": "^4.0.0" + "@babel/code-frame": "^7.27.1", + "@jest/types": "30.2.0", + "@types/stack-utils": "^2.0.3", + "chalk": "^4.1.2", + "graceful-fs": "^4.2.11", + "micromatch": "^4.0.8", + "pretty-format": "30.2.0", + "slash": "^3.0.0", + "stack-utils": "^2.0.6" + } + }, + "jest-mock": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-mock/-/jest-mock-30.2.0.tgz", + "integrity": "sha512-JNNNl2rj4b5ICpmAcq+WbLH83XswjPbjH4T7yvGzfAGCPh1rw+xVNbtk+FnRslvt9lkCcdn9i1oAoKUuFsOxRw==", + "dev": true, + "requires": { + "@jest/types": "30.2.0", + "@types/node": "*", + "jest-util": "30.2.0" + } + }, + "jest-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-30.2.0.tgz", + "integrity": "sha512-QKNsM0o3Xe6ISQU869e+DhG+4CK/48aHYdJZGlFQVTjnbvgpcKyxpzk29fGiO7i/J8VENZ+d2iGnSsvmuHywlA==", + "dev": true, + "requires": { + "@jest/types": "30.2.0", + "@types/node": "*", + "chalk": "^4.1.2", + "ci-info": "^4.2.0", + "graceful-fs": "^4.2.11", + "picomatch": "^4.0.2" + } + }, + "picomatch": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.3.tgz", + "integrity": "sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==", + "dev": true + }, + "pretty-format": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/pretty-format/-/pretty-format-30.2.0.tgz", + "integrity": "sha512-9uBdv/B4EefsuAL+pWqueZyZS2Ba+LxfFeQ9DN14HU4bN8bhaxKdkpjpB6fs9+pSjIBu+FXQHImEg8j/Lw0+vA==", + "dev": true, + "requires": { + "@jest/schemas": "30.0.5", + "ansi-styles": "^5.2.0", + "react-is": "^18.3.1" } } } @@ -12409,57 +11774,6 @@ "jest-diff": "^29.4.3", "jest-get-type": "^29.4.3", "pretty-format": "^29.4.3" - }, - "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, - "chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - } - }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true - }, - "supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "requires": { - "has-flag": "^4.0.0" - } - } } }, "jest-message-util": { @@ -12477,57 +11791,6 @@ "pretty-format": "^29.4.3", "slash": "^3.0.0", "stack-utils": "^2.0.3" - }, - "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, - "chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - } - }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true - }, - "supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "requires": { - "has-flag": "^4.0.0" - } - } } }, "jest-mock": { @@ -12571,46 +11834,6 @@ "slash": "^3.0.0" }, "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, - "chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - } - }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true - }, "resolve": { "version": "1.22.1", "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.22.1.tgz", @@ -12621,15 +11844,6 @@ "path-parse": "^1.0.7", "supports-preserve-symlinks-flag": "^1.0.0" } - }, - "supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "requires": { - "has-flag": "^4.0.0" - } } } }, @@ -12652,75 +11866,24 @@ "@jest/console": "^29.4.3", "@jest/environment": "^29.4.3", "@jest/test-result": "^29.4.3", - "@jest/transform": "^29.4.3", - "@jest/types": "^29.4.3", - "@types/node": "*", - "chalk": "^4.0.0", - "emittery": "^0.13.1", - "graceful-fs": "^4.2.9", - "jest-docblock": "^29.4.3", - "jest-environment-node": "^29.4.3", - "jest-haste-map": "^29.4.3", - "jest-leak-detector": "^29.4.3", - "jest-message-util": "^29.4.3", - "jest-resolve": "^29.4.3", - "jest-runtime": "^29.4.3", - "jest-util": "^29.4.3", - "jest-watcher": "^29.4.3", - "jest-worker": "^29.4.3", - "p-limit": "^3.1.0", - "source-map-support": "0.5.13" - }, - "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, - "chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - } - }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true - }, - "supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "requires": { - "has-flag": "^4.0.0" - } - } + "@jest/transform": "^29.4.3", + "@jest/types": "^29.4.3", + "@types/node": "*", + "chalk": "^4.0.0", + "emittery": "^0.13.1", + "graceful-fs": "^4.2.9", + "jest-docblock": "^29.4.3", + "jest-environment-node": "^29.4.3", + "jest-haste-map": "^29.4.3", + "jest-leak-detector": "^29.4.3", + "jest-message-util": "^29.4.3", + "jest-resolve": "^29.4.3", + "jest-runtime": "^29.4.3", + "jest-util": "^29.4.3", + "jest-watcher": "^29.4.3", + "jest-worker": "^29.4.3", + "p-limit": "^3.1.0", + "source-map-support": "0.5.13" } }, "jest-runtime": { @@ -12751,57 +11914,6 @@ "jest-util": "^29.4.3", "slash": "^3.0.0", "strip-bom": "^4.0.0" - }, - "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, - "chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - } - }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true - }, - "supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "requires": { - "has-flag": "^4.0.0" - } - } } }, "jest-snapshot": { @@ -12836,46 +11948,6 @@ "semver": "^7.3.5" }, "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, - "chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - } - }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true - }, "lru-cache": { "version": "6.0.0", "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-6.0.0.tgz", @@ -12894,15 +11966,6 @@ "lru-cache": "^6.0.0" } }, - "supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "requires": { - "has-flag": "^4.0.0" - } - }, "yallist": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz", @@ -12923,57 +11986,6 @@ "ci-info": "^3.2.0", "graceful-fs": "^4.2.9", "picomatch": "^2.2.3" - }, - "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, - "chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - } - }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true - }, - "supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "requires": { - "has-flag": "^4.0.0" - } - } } }, "jest-validate": { @@ -12990,60 +12002,11 @@ "pretty-format": "^29.4.3" }, "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, "camelcase": { "version": "6.3.0", "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-6.3.0.tgz", "integrity": "sha512-Gmy6FhYlCY7uOElZUSbxo2UCDH8owEk996gkbrpsgGtrJLM3J7jGxl9Ic7Qwwj4ivOE5AWZWRMecDdF7hqGjFA==", "dev": true - }, - "chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - } - }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true - }, - "supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "requires": { - "has-flag": "^4.0.0" - } } } }, @@ -13061,57 +12024,6 @@ "emittery": "^0.13.1", "jest-util": "^29.4.3", "string-length": "^4.0.1" - }, - "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, - "chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - } - }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true - }, - "supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "requires": { - "has-flag": "^4.0.0" - } - } } }, "jest-worker": { @@ -13126,12 +12038,6 @@ "supports-color": "^8.0.0" }, "dependencies": { - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true - }, "supports-color": { "version": "8.1.1", "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-8.1.1.tgz", @@ -13159,6 +12065,34 @@ "esprima": "^4.0.0" } }, + "jsdom": { + "version": "26.1.0", + "resolved": "https://registry.npmjs.org/jsdom/-/jsdom-26.1.0.tgz", + "integrity": "sha512-Cvc9WUhxSMEo4McES3P7oK3QaXldCfNWp7pl2NNeiIFlCoLr3kfq9kb1fxftiwk1FLV7CvpvDfonxtzUDeSOPg==", + "dev": true, + "requires": { + "cssstyle": "^4.2.1", + "data-urls": "^5.0.0", + "decimal.js": "^10.5.0", + "html-encoding-sniffer": "^4.0.0", + "http-proxy-agent": "^7.0.2", + "https-proxy-agent": "^7.0.6", + "is-potential-custom-element-name": "^1.0.1", + "nwsapi": "^2.2.16", + "parse5": "^7.2.1", + "rrweb-cssom": "^0.8.0", + "saxes": "^6.0.0", + "symbol-tree": "^3.2.4", + "tough-cookie": "^5.1.1", + "w3c-xmlserializer": "^5.0.0", + "webidl-conversions": "^7.0.0", + "whatwg-encoding": "^3.1.1", + "whatwg-mimetype": "^4.0.0", + "whatwg-url": "^14.1.1", + "ws": "^8.18.0", + "xml-name-validator": "^5.0.0" + } + }, "jsep": { "version": "1.3.9", "resolved": "https://registry.npmjs.org/jsep/-/jsep-1.3.9.tgz", @@ -13457,6 +12391,12 @@ "path-key": "^3.0.0" } }, + "nwsapi": { + "version": "2.2.23", + "resolved": "https://registry.npmjs.org/nwsapi/-/nwsapi-2.2.23.tgz", + "integrity": "sha512-7wfH4sLbt4M0gCDzGE6vzQBo0bfTKjU7Sfpqy/7gs1qBfYz2vEJH6vXcBKpO3+6Yu1telwd0t9HpyOoLEQQbIQ==", + "dev": true + }, "once": { "version": "1.4.0", "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", @@ -13547,6 +12487,15 @@ "lines-and-columns": "^1.1.6" } }, + "parse5": { + "version": "7.3.0", + "resolved": "https://registry.npmjs.org/parse5/-/parse5-7.3.0.tgz", + "integrity": "sha512-IInvU7fabl34qmi9gY8XOVxhYyMyuH2xUNpb2q8/Y+7552KlejkRvqvD19nMoUW/uQGGbqNpA6Tufu5FL5BZgw==", + "dev": true, + "requires": { + "entities": "^6.0.0" + } + }, "path-exists": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-4.0.0.tgz", @@ -13572,9 +12521,9 @@ "dev": true }, "picocolors": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.0.0.tgz", - "integrity": "sha512-1fygroTLlHu66zi26VoTDv8yRgm0Fccecssto+MhsZ0D/DGW2sm8E8AjW7NU5VVTRt5GxbeZ5qBuJr+HyLYkjQ==", + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.1.1.tgz", + "integrity": "sha512-xceH2snhtb5M9liqDsmEw56le376mTZkEX/jEb/RxNFyegNul7eNslCXP9FDj/Lcu0X8KEyMceP2ntpaHrDEVA==", "dev": true }, "picomatch": { @@ -13642,6 +12591,12 @@ "once": "^1.3.1" } }, + "punycode": { + "version": "2.3.1", + "resolved": "https://registry.npmjs.org/punycode/-/punycode-2.3.1.tgz", + "integrity": "sha512-vYt7UD1U9Wg6138shLtLOvdAu+8DsC/ilFtEVHcH+wydcSpNE20AfSOduf6MkRFahL5FY7X1oU7nKVZFtfq8Fg==", + "dev": true + }, "queue-microtask": { "version": "1.2.3", "resolved": "https://registry.npmjs.org/queue-microtask/-/queue-microtask-1.2.3.tgz", @@ -13649,9 +12604,9 @@ "dev": true }, "react-is": { - "version": "18.2.0", - "resolved": "https://registry.npmjs.org/react-is/-/react-is-18.2.0.tgz", - "integrity": "sha512-xWGDIW6x921xtzPkhiULtthJHoJvBbF3q26fzloPCK0hsvxtPVelvftw3zjbHWSkR2km9Z+4uxbDDK/6Zw9B8w==", + "version": "18.3.1", + "resolved": "https://registry.npmjs.org/react-is/-/react-is-18.3.1.tgz", + "integrity": "sha512-/LLMVyas0ljjAtoYiPqYiL8VWXzUUdThrmU5+n20DZv+a+ClRoevUzw5JxU+Ieh5/c87ytoTBV9G1FiKfNJdmg==", "dev": true }, "readdirp": { @@ -13786,6 +12741,12 @@ "integrity": "sha512-g6QUff04oZpHs0eG5p83rFLhHeV00ug/Yf9nZM6fLeUrPguBTkTQOdpAWWspMh55TZfVQDPaN3NQJfbVRAxdIw==", "dev": true }, + "rrweb-cssom": { + "version": "0.8.0", + "resolved": "https://registry.npmjs.org/rrweb-cssom/-/rrweb-cssom-0.8.0.tgz", + "integrity": "sha512-guoltQEx+9aMf2gDZ0s62EcV8lsXR+0w8915TC3ITdn2YueuNjdAYh/levpU9nFaoChh9RUS5ZdQMrKfVEN9tw==", + "dev": true + }, "run-parallel": { "version": "1.2.0", "resolved": "https://registry.npmjs.org/run-parallel/-/run-parallel-1.2.0.tgz", @@ -13803,6 +12764,12 @@ "tslib": "^2.1.0" } }, + "safer-buffer": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz", + "integrity": "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==", + "dev": true + }, "sass": { "version": "1.57.1", "resolved": "https://registry.npmjs.org/sass/-/sass-1.57.1.tgz", @@ -13819,6 +12786,15 @@ "resolved": "https://registry.npmjs.org/sax/-/sax-1.4.3.tgz", "integrity": "sha512-yqYn1JhPczigF94DMS+shiDMjDowYO6y9+wB/4WgO0Y19jWYk0lQ4tuG5KI7kj4FTp1wxPj5IFfcrz/s1c3jjQ==" }, + "saxes": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/saxes/-/saxes-6.0.0.tgz", + "integrity": "sha512-xAg7SOnEhrm5zI3puOOKyy1OMcMlIJZYNJY7xLBwSze0UjhPLnWfj2GF2EpT0jmzaJKIWKHLsaSSajf35bcYnA==", + "dev": true, + "requires": { + "xmlchars": "^2.2.0" + } + }, "semver": { "version": "6.3.0", "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.0.tgz", @@ -14138,12 +13114,12 @@ "dev": true }, "supports-color": { - "version": "5.5.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.5.0.tgz", - "integrity": "sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==", + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", "dev": true, "requires": { - "has-flag": "^3.0.0" + "has-flag": "^4.0.0" } }, "supports-preserve-symlinks-flag": { @@ -14152,6 +13128,12 @@ "integrity": "sha512-ot0WnXS9fgdkgIcePe6RHNk1WA8+muPa6cSjeR3V8K27q9BB1rTE3R1p7Hv0z1ZyAc8s6Vvv8DIyWf681MAt0w==", "dev": true }, + "symbol-tree": { + "version": "3.2.4", + "resolved": "https://registry.npmjs.org/symbol-tree/-/symbol-tree-3.2.4.tgz", + "integrity": "sha512-9QNk5KwDF+Bvz+PyObkmSYjI5ksVUYtjW7AU22r2NKcfLJcXp96hkDWU3+XndOsUb+AQ9QhfzfCT2O+CNWT5Tw==", + "dev": true + }, "test-exclude": { "version": "6.0.0", "resolved": "https://registry.npmjs.org/test-exclude/-/test-exclude-6.0.0.tgz", @@ -14163,6 +13145,21 @@ "minimatch": "^3.0.4" } }, + "tldts": { + "version": "6.1.86", + "resolved": "https://registry.npmjs.org/tldts/-/tldts-6.1.86.tgz", + "integrity": "sha512-WMi/OQ2axVTf/ykqCQgXiIct+mSQDFdH2fkwhPwgEwvJ1kSzZRiinb0zF2Xb8u4+OqPChmyI6MEu4EezNJz+FQ==", + "dev": true, + "requires": { + "tldts-core": "^6.1.86" + } + }, + "tldts-core": { + "version": "6.1.86", + "resolved": "https://registry.npmjs.org/tldts-core/-/tldts-core-6.1.86.tgz", + "integrity": "sha512-Je6p7pkk+KMzMv2XXKmAE3McmolOQFdxkKw0R8EYNr7sELW46JqnNeTX8ybPiQgvg1ymCoF8LXs5fzFaZvJPTA==", + "dev": true + }, "tmpl": { "version": "1.0.5", "resolved": "https://registry.npmjs.org/tmpl/-/tmpl-1.0.5.tgz", @@ -14184,6 +13181,24 @@ "is-number": "^7.0.0" } }, + "tough-cookie": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/tough-cookie/-/tough-cookie-5.1.2.tgz", + "integrity": "sha512-FVDYdxtnj0G6Qm/DhNPSb8Ju59ULcup3tuJxkFb5K8Bv2pUXILbf0xZWU8PX8Ov19OXljbUyveOFwRMwkXzO+A==", + "dev": true, + "requires": { + "tldts": "^6.1.32" + } + }, + "tr46": { + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/tr46/-/tr46-5.1.1.tgz", + "integrity": "sha512-hdF5ZgjTqgAntKkklYw0R03MG2x/bSzTtkxmIRw/sTNV8YXsCJ1tfLAX23lhxhHJlEf3CRCOCGGWw3vI3GaSPw==", + "dev": true, + "requires": { + "punycode": "^2.3.1" + } + }, "ts-jest": { "version": "29.0.0", "resolved": "https://registry.npmjs.org/ts-jest/-/ts-jest-29.0.0.tgz", @@ -14352,6 +13367,15 @@ "webworker-threads": "^0.7.12" } }, + "w3c-xmlserializer": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/w3c-xmlserializer/-/w3c-xmlserializer-5.0.0.tgz", + "integrity": "sha512-o8qghlI8NZHU1lLPrpi2+Uq7abh4GGPpYANlalzWxyWteJOCsr/P+oPBA49TOLu5FTZO4d3F9MnWJfiMo4BkmA==", + "dev": true, + "requires": { + "xml-name-validator": "^5.0.0" + } + }, "walker": { "version": "1.0.8", "resolved": "https://registry.npmjs.org/walker/-/walker-1.0.8.tgz", @@ -14361,6 +13385,12 @@ "makeerror": "1.0.12" } }, + "webidl-conversions": { + "version": "7.0.0", + "resolved": "https://registry.npmjs.org/webidl-conversions/-/webidl-conversions-7.0.0.tgz", + "integrity": "sha512-VwddBukDzu71offAQR975unBIGqfKZpM+8ZX6ySk8nYhVoo5CYaZyzt3YBvYtRtO+aoGlqxPg/B87NGVZ/fu6g==", + "dev": true + }, "webworker-threads": { "version": "0.7.17", "resolved": "https://registry.npmjs.org/webworker-threads/-/webworker-threads-0.7.17.tgz", @@ -14371,6 +13401,31 @@ "nan": "^2.11.0" } }, + "whatwg-encoding": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/whatwg-encoding/-/whatwg-encoding-3.1.1.tgz", + "integrity": "sha512-6qN4hJdMwfYBtE3YBTTHhoeuUrDBPZmbQaxWAqSALV/MeEnR5z1xd8UKud2RAkFoPkmB+hli1TZSnyi84xz1vQ==", + "dev": true, + "requires": { + "iconv-lite": "0.6.3" + } + }, + "whatwg-mimetype": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/whatwg-mimetype/-/whatwg-mimetype-4.0.0.tgz", + "integrity": "sha512-QaKxh0eNIi2mE9p2vEdzfagOKHCcj1pJ56EEHGQOVxp8r9/iszLUUV7v89x9O1p/T+NlTM5W7jW6+cz4Fq1YVg==", + "dev": true + }, + "whatwg-url": { + "version": "14.2.0", + "resolved": "https://registry.npmjs.org/whatwg-url/-/whatwg-url-14.2.0.tgz", + "integrity": "sha512-De72GdQZzNTUBBChsXueQUnPKDkg/5A5zp7pFDuQAj5UFoENpiACU0wlCvzpAGnTkj++ihpKwKyYewn/XNUbKw==", + "dev": true, + "requires": { + "tr46": "^5.1.0", + "webidl-conversions": "^7.0.0" + } + }, "which": { "version": "2.0.2", "resolved": "https://registry.npmjs.org/which/-/which-2.0.2.tgz", @@ -14389,32 +13444,6 @@ "ansi-styles": "^4.0.0", "string-width": "^4.1.0", "strip-ansi": "^6.0.0" - }, - "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - } } }, "wrappy": { @@ -14433,6 +13462,25 @@ "signal-exit": "^3.0.7" } }, + "ws": { + "version": "8.19.0", + "resolved": "https://registry.npmjs.org/ws/-/ws-8.19.0.tgz", + "integrity": "sha512-blAT2mjOEIi0ZzruJfIhb3nps74PRWTCz1IjglWEEpQl5XS/UNama6u2/rjFkDDouqr4L67ry+1aGIALViWjDg==", + "dev": true, + "requires": {} + }, + "xml-name-validator": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/xml-name-validator/-/xml-name-validator-5.0.0.tgz", + "integrity": "sha512-EvGK8EJ3DhaHfbRlETOWAS5pO9MZITeauHKJyb8wyajUfQUenkIg2MvLDTZ4T/TgIcm3HU0TFBgWWboAZ30UHg==", + "dev": true + }, + "xmlchars": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/xmlchars/-/xmlchars-2.2.0.tgz", + "integrity": "sha512-JZnDKK8B0RCDw84FNdDAIpZK+JuJw+s7Lz8nksI7SIuU3UXJJslUthsi+uWBUYOwPFwW7W7PRLRfUKpxjtjFCw==", + "dev": true + }, "y18n": { "version": "5.0.8", "resolved": "https://registry.npmjs.org/y18n/-/y18n-5.0.8.tgz", diff --git a/packages/dev/babylonjs/package.json b/packages/dev/babylonjs/package.json index 338c4a06..0dc7dc0a 100644 --- a/packages/dev/babylonjs/package.json +++ b/packages/dev/babylonjs/package.json @@ -56,28 +56,29 @@ "dependencies": { "@babylonjs/core": "8.44.1", "@babylonjs/gui": "8.44.1", + "@babylonjs/havok": "1.3.10", "@babylonjs/loaders": "8.44.1", "@babylonjs/materials": "8.44.1", "@babylonjs/serializers": "8.44.1", - "@babylonjs/havok": "1.3.10", "@bitbybit-dev/core": "0.21.0", "earcut": "2.2.3" }, "devDependencies": { - "shx":"0.4.0", - "sass": "1.57.1", - "@testing-library/jest-dom": "5.14.1", - "mvdir": "1.0.21", - "jest": "29.4.1", - "ts-node": "10.9.1", - "ts-jest": "29.0.0", - "typescript": "4.8.2", - "@types/jest": "29.0.0", - "babel-jest": "29.0.0", "@babel/core": "7.16.0", "@babel/preset-env": "7.16.0", "@babel/preset-typescript": "7.16.0", - "jest-html-reporters": "3.0.11" + "@testing-library/jest-dom": "5.14.1", + "@types/jest": "29.0.0", + "babel-jest": "29.0.0", + "jest": "29.4.1", + "jest-environment-jsdom": "^30.2.0", + "jest-html-reporters": "3.0.11", + "mvdir": "1.0.21", + "sass": "1.57.1", + "shx": "0.4.0", + "ts-jest": "29.0.0", + "ts-node": "10.9.1", + "typescript": "4.8.2" }, "jest": { "preset": "ts-jest", diff --git a/packages/dev/playcanvas/lib/api/__mocks__/playcanvas.mock.ts b/packages/dev/playcanvas/lib/api/__mocks__/playcanvas.mock.ts index 38e4e4b7..5735f804 100644 --- a/packages/dev/playcanvas/lib/api/__mocks__/playcanvas.mock.ts +++ b/packages/dev/playcanvas/lib/api/__mocks__/playcanvas.mock.ts @@ -210,6 +210,9 @@ export class MockEntity { setLocalRotation(quat: MockQuat) { this.setRotation(quat); } + setEulerAngles(x: number, y: number, z: number) { + this._rotation.setFromEulerAngles(x, y, z); + } lookAt(target: MockVec3) { } findByName() { return null; } findOne() { return null; } diff --git a/packages/dev/playcanvas/lib/api/bitbybit/playcanvas/scene-helper.test.ts b/packages/dev/playcanvas/lib/api/bitbybit/playcanvas/scene-helper.test.ts new file mode 100644 index 00000000..506d58cd --- /dev/null +++ b/packages/dev/playcanvas/lib/api/bitbybit/playcanvas/scene-helper.test.ts @@ -0,0 +1,772 @@ +/** + * @jest-environment jsdom + */ +/* eslint-disable @typescript-eslint/no-unused-vars */ +/* eslint-disable @typescript-eslint/no-empty-function */ +import { initPlayCanvas } from "./scene-helper"; +import { PlayCanvasScene } from "../../inputs/playcanvas-scene-helper-inputs"; +import { PlayCanvasCamera } from "../../inputs/playcanvas-camera-inputs"; + +// Type definitions for mock objects +interface MockEntityType { + name: string; + children: MockEntityType[]; + addChild(entity: MockEntityType): void; + destroy(): void; + light?: MockLightComponentType; +} + +interface MockColorType { + r: number; + g: number; + b: number; +} + +interface MockAppType { + _canvas: HTMLCanvasElement | null; + _started: boolean; + _updateCallbacks: ((dt: number) => void)[]; +} + +interface MockLightComponentType { + intensity: number; + castShadows: boolean; + shadowResolution: number; +} + +// Mock PlayCanvas module +jest.mock("playcanvas", () => { + const actualMock = jest.requireActual("../../__mocks__/playcanvas.mock"); + + class MockGraphicsDevice { + maxPixelRatio = 1; + vram = { vb: 0, ib: 0, tex: 0, total: 0 }; + createVertexBufferImpl = jest.fn(() => ({})); + createIndexBufferImpl = jest.fn(() => ({})); + } + + class MockApplication { + root: MockEntityType; + mouse = new actualMock.MockMouse(); + touch = new actualMock.MockTouch(); + graphicsDevice = new MockGraphicsDevice(); + scene = { + ambientLight: new actualMock.MockColor(0.1, 0.1, 0.1), + }; + _canvas: HTMLCanvasElement | null = null; + _started = false; + _updateCallbacks: ((dt: number) => void)[] = []; + + constructor(canvas: HTMLCanvasElement, _options?: object) { + this.root = new actualMock.MockEntity("root"); + this._canvas = canvas; + } + + setCanvasFillMode(_mode: number) { /* mock */ } + setCanvasResolution(_mode: number) { /* mock */ } + resizeCanvas() { /* mock */ } + start() { this._started = true; } + destroy() { this._started = false; } + on(event: string, callback: (dt: number) => void) { + if (event === "update") { + this._updateCallbacks.push(callback); + } + } + off(event: string, callback: (dt: number) => void) { + if (event === "update") { + const idx = this._updateCallbacks.indexOf(callback); + if (idx > -1) { + this._updateCallbacks.splice(idx, 1); + } + } + } + } + + class MockStandardMaterial { + diffuse: MockColorType; + opacity = 1; + blendType = 0; + + constructor() { + this.diffuse = new actualMock.MockColor(1, 1, 1); + } + + update() { /* mock */ } + destroy() { /* mock */ } + } + + class MockMouse { + on = jest.fn(); + off = jest.fn(); + disableContextMenu = jest.fn(); + } + + class MockTouchDevice { + on = jest.fn(); + off = jest.fn(); + } + + return { + Application: MockApplication, + Entity: actualMock.MockEntity, + Vec2: actualMock.MockVec2, + Vec3: actualMock.MockVec3, + Quat: actualMock.MockQuat, + Color: actualMock.MockColor, + BoundingBox: actualMock.MockBoundingBox, + StandardMaterial: MockStandardMaterial, + Mouse: MockMouse, + TouchDevice: MockTouchDevice, + FILLMODE_FILL_WINDOW: 0, + RESOLUTION_AUTO: 0, + BLEND_NORMAL: 1, + MOUSEBUTTON_LEFT: 0, + MOUSEBUTTON_MIDDLE: 1, + MOUSEBUTTON_RIGHT: 2, + EVENT_MOUSEDOWN: "mousedown", + EVENT_MOUSEUP: "mouseup", + EVENT_MOUSEMOVE: "mousemove", + EVENT_MOUSEWHEEL: "mousewheel", + EVENT_TOUCHSTART: "touchstart", + EVENT_TOUCHEND: "touchend", + EVENT_TOUCHMOVE: "touchmove", + EVENT_TOUCHCANCEL: "touchcancel", + math: { + lerp: (a: number, b: number, t: number) => a + (b - a) * t, + clamp: (value: number, min: number, max: number) => Math.min(Math.max(value, min), max), + RAD_TO_DEG: 180 / Math.PI, + DEG_TO_RAD: Math.PI / 180, + }, + }; +}); + +describe("initPlayCanvas unit tests", () => { + let mockCanvas: HTMLCanvasElement; + + beforeEach(() => { + // Create a mock canvas element + mockCanvas = document.createElement("canvas"); + mockCanvas.id = "test-canvas"; + document.body.appendChild(mockCanvas); + + // Mock window properties + Object.defineProperty(window, "innerWidth", { value: 1920, writable: true }); + Object.defineProperty(window, "innerHeight", { value: 1080, writable: true }); + Object.defineProperty(window, "devicePixelRatio", { value: 1, writable: true }); + }); + + afterEach(() => { + // Clean up DOM + if (mockCanvas && mockCanvas.parentNode) { + mockCanvas.parentNode.removeChild(mockCanvas); + } + // Clean up any canvases created by tests + document.querySelectorAll("canvas").forEach(canvas => { + if (canvas.parentNode) { + canvas.parentNode.removeChild(canvas); + } + }); + jest.clearAllMocks(); + }); + + describe("initialization with defaults", () => { + it("should create scene with default configuration", () => { + // Arrange & Act + const result = initPlayCanvas(); + + // Assert + expect(result.app).toBeDefined(); + expect(result.scene).toBeDefined(); + expect(result.directionalLight).toBeDefined(); + expect(result.ground).toBeDefined(); + expect(typeof result.dispose).toBe("function"); + + // Cleanup + result.dispose(); + }); + + it("should create root scene entity with correct name", () => { + // Arrange & Act + const result = initPlayCanvas(); + + // Assert + expect(result.scene.name).toBe("scene"); + + // Cleanup + result.dispose(); + }); + + it("should create directional light entity with correct name", () => { + // Arrange & Act + const result = initPlayCanvas(); + + // Assert + expect(result.directionalLight.name).toBe("directionalLight"); + + // Cleanup + result.dispose(); + }); + + it("should start the application", () => { + // Arrange & Act + const result = initPlayCanvas(); + + // Assert + expect((result.app as unknown as MockAppType)._started).toBe(true); + + // Cleanup + result.dispose(); + }); + }); + + describe("canvas handling", () => { + it("should use existing canvas when canvasId is provided", () => { + // Arrange + const config = new PlayCanvasScene.InitPlayCanvasDto(); + config.canvasId = "test-canvas"; + + // Act + const result = initPlayCanvas(config); + + // Assert + expect((result.app as unknown as MockAppType)._canvas).toBe(mockCanvas); + + // Cleanup + result.dispose(); + }); + + it("should throw error when canvas with provided id is not found", () => { + // Arrange + const config = new PlayCanvasScene.InitPlayCanvasDto(); + config.canvasId = "nonexistent-canvas"; + + // Act & Assert + expect(() => initPlayCanvas(config)).toThrow("Canvas with id \"nonexistent-canvas\" not found"); + }); + + it("should create new canvas when canvasId is not provided", () => { + // Arrange & Act + const result = initPlayCanvas(); + + // Assert - canvas should be created and different from test canvas + expect((result.app as unknown as MockAppType)._canvas).not.toBe(mockCanvas); + + // Cleanup + result.dispose(); + }); + }); + + describe("ground plane configuration", () => { + it("should create ground plane when enableGround is true", () => { + // Arrange + const config = new PlayCanvasScene.InitPlayCanvasDto(); + config.canvasId = "test-canvas"; + config.enableGround = true; + + // Act + const result = initPlayCanvas(config); + + // Assert + expect(result.ground).not.toBeNull(); + expect(result.ground?.name).toBe("ground"); + + // Cleanup + result.dispose(); + }); + + it("should not create ground plane when enableGround is false", () => { + // Arrange + const config = new PlayCanvasScene.InitPlayCanvasDto(); + config.canvasId = "test-canvas"; + config.enableGround = false; + + // Act + const result = initPlayCanvas(config); + + // Assert + expect(result.ground).toBeNull(); + + // Cleanup + result.dispose(); + }); + + it("should position ground at specified center", () => { + // Arrange + const config = new PlayCanvasScene.InitPlayCanvasDto(); + config.canvasId = "test-canvas"; + config.enableGround = true; + config.groundCenter = [5, -2, 10]; + + // Act + const result = initPlayCanvas(config); + + // Assert + const position = result.ground?.getPosition(); + expect(position?.x).toBe(5); + expect(position?.y).toBe(-2); + expect(position?.z).toBe(10); + + // Cleanup + result.dispose(); + }); + + it("should scale ground based on sceneSize and groundScaleFactor", () => { + // Arrange + const config = new PlayCanvasScene.InitPlayCanvasDto(); + config.canvasId = "test-canvas"; + config.sceneSize = 50; + config.groundScaleFactor = 3; + config.enableGround = true; + + // Act + const result = initPlayCanvas(config); + + // Assert + const expectedSize = config.sceneSize * config.groundScaleFactor; // 150 + const scale = result.ground?.getLocalScale(); + expect(scale?.x).toBe(expectedSize); + expect(scale?.z).toBe(expectedSize); + + // Cleanup + result.dispose(); + }); + }); + + describe("orbit camera configuration", () => { + it("should create orbit camera when enableOrbitCamera is true", () => { + // Arrange + const config = new PlayCanvasScene.InitPlayCanvasDto(); + config.canvasId = "test-canvas"; + config.enableOrbitCamera = true; + + // Act + const result = initPlayCanvas(config); + + // Assert + expect(result.orbitCamera).not.toBeNull(); + expect(result.orbitCamera?.cameraEntity).toBeDefined(); + expect(result.orbitCamera?.orbitCamera).toBeDefined(); + + // Cleanup + result.dispose(); + }); + + it("should not create orbit camera when enableOrbitCamera is false", () => { + // Arrange + const config = new PlayCanvasScene.InitPlayCanvasDto(); + config.canvasId = "test-canvas"; + config.enableOrbitCamera = false; + + // Act + const result = initPlayCanvas(config); + + // Assert + expect(result.orbitCamera).toBeNull(); + + // Cleanup + result.dispose(); + }); + + it("should set camera distance based on scene size when no custom options provided", () => { + // Arrange + const config = new PlayCanvasScene.InitPlayCanvasDto(); + config.canvasId = "test-canvas"; + config.sceneSize = 50; + config.enableOrbitCamera = true; + + // Act + const result = initPlayCanvas(config); + + // Assert + const expectedDistance = config.sceneSize * Math.sqrt(2); + expect(result.orbitCamera?.orbitCamera.distance).toBeCloseTo(expectedDistance, 5); + + // Cleanup + result.dispose(); + }); + + it("should use custom camera options when provided", () => { + // Arrange + const config = new PlayCanvasScene.InitPlayCanvasDto(); + config.canvasId = "test-canvas"; + config.enableOrbitCamera = true; + config.orbitCameraOptions = new PlayCanvasCamera.OrbitCameraDto(); + config.orbitCameraOptions.distance = 100; + config.orbitCameraOptions.pitch = 45; + config.orbitCameraOptions.yaw = 90; + + // Act + const result = initPlayCanvas(config); + + // Assert + expect(result.orbitCamera?.orbitCamera.distance).toBe(100); + expect(result.orbitCamera?.orbitCamera.pitch).toBe(45); + expect(result.orbitCamera?.orbitCamera.yaw).toBe(90); + + // Cleanup + result.dispose(); + }); + + it("should set camera limits based on scene size", () => { + // Arrange + const config = new PlayCanvasScene.InitPlayCanvasDto(); + config.canvasId = "test-canvas"; + config.sceneSize = 50; + config.enableOrbitCamera = true; + + // Act + const result = initPlayCanvas(config); + + // Assert + expect(result.orbitCamera?.orbitCamera.distanceMin).toBeCloseTo(config.sceneSize * 0.05, 5); + expect(result.orbitCamera?.orbitCamera.distanceMax).toBeCloseTo(config.sceneSize * 10, 5); + + // Cleanup + result.dispose(); + }); + + it("should create camera entity with name OrbitCamera", () => { + // Arrange + const config = new PlayCanvasScene.InitPlayCanvasDto(); + config.canvasId = "test-canvas"; + config.enableOrbitCamera = true; + + // Act + const result = initPlayCanvas(config); + + // Assert + expect(result.orbitCamera?.cameraEntity.name).toBe("OrbitCamera"); + + // Cleanup + result.dispose(); + }); + }); + + describe("scene size scaling", () => { + it("should position directional light based on scene size", () => { + // Arrange + const config = new PlayCanvasScene.InitPlayCanvasDto(); + config.canvasId = "test-canvas"; + config.sceneSize = 100; + + // Act + const result = initPlayCanvas(config); + + // Assert + const expectedHeight = config.sceneSize * 0.75; // 75 + const expectedOffset = config.sceneSize * 0.5; // 50 + const lightPosition = result.directionalLight.getPosition(); + expect(lightPosition.x).toBeCloseTo(expectedOffset, 5); + expect(lightPosition.y).toBeCloseTo(expectedHeight, 5); + expect(lightPosition.z).toBeCloseTo(expectedOffset, 5); + + // Cleanup + result.dispose(); + }); + + it("should set ambient light color based on config", () => { + // Arrange + const config = new PlayCanvasScene.InitPlayCanvasDto(); + config.canvasId = "test-canvas"; + config.ambientLightColor = "#ffffff"; + config.ambientLightIntensity = 0.5; + + // Act + const result = initPlayCanvas(config); + + // Assert + const ambientLight = result.app.scene.ambientLight; + expect(ambientLight).toBeDefined(); + // Ambient light values should be RGB * intensity + expect(ambientLight.r).toBeCloseTo(0.5, 2); + expect(ambientLight.g).toBeCloseTo(0.5, 2); + expect(ambientLight.b).toBeCloseTo(0.5, 2); + + // Cleanup + result.dispose(); + }); + }); + + describe("light configuration", () => { + it("should apply directional light intensity from config", () => { + // Arrange + const config = new PlayCanvasScene.InitPlayCanvasDto(); + config.canvasId = "test-canvas"; + config.directionalLightIntensity = 2.5; + + // Act + const result = initPlayCanvas(config); + + // Assert + const lightComponent = (result.directionalLight as unknown as MockEntityType).light; + expect(lightComponent?.intensity).toBe(2.5); + + // Cleanup + result.dispose(); + }); + + it("should enable shadows on directional light when enableShadows is true", () => { + // Arrange + const config = new PlayCanvasScene.InitPlayCanvasDto(); + config.canvasId = "test-canvas"; + config.enableShadows = true; + + // Act + const result = initPlayCanvas(config); + + // Assert + const lightComponent = (result.directionalLight as unknown as MockEntityType).light; + expect(lightComponent?.castShadows).toBe(true); + + // Cleanup + result.dispose(); + }); + + it("should disable shadows on directional light when enableShadows is false", () => { + // Arrange + const config = new PlayCanvasScene.InitPlayCanvasDto(); + config.canvasId = "test-canvas"; + config.enableShadows = false; + + // Act + const result = initPlayCanvas(config); + + // Assert + const lightComponent = (result.directionalLight as unknown as MockEntityType).light; + expect(lightComponent?.castShadows).toBe(false); + + // Cleanup + result.dispose(); + }); + + it("should set shadow map size from config", () => { + // Arrange + const config = new PlayCanvasScene.InitPlayCanvasDto(); + config.canvasId = "test-canvas"; + config.shadowMapSize = 4096; + config.enableShadows = true; + + // Act + const result = initPlayCanvas(config); + + // Assert + const lightComponent = (result.directionalLight as unknown as MockEntityType).light; + expect(lightComponent?.shadowResolution).toBe(4096); + + // Cleanup + result.dispose(); + }); + }); + + describe("dispose method", () => { + it("should remove window resize event listener on dispose", () => { + // Arrange + const removeEventListenerSpy = jest.spyOn(window, "removeEventListener"); + const result = initPlayCanvas(); + + // Act + result.dispose(); + + // Assert + expect(removeEventListenerSpy).toHaveBeenCalledWith("resize", expect.any(Function)); + + // Cleanup + removeEventListenerSpy.mockRestore(); + }); + + it("should destroy directional light on cleanup", () => { + // Arrange + const result = initPlayCanvas(); + const destroySpy = jest.spyOn(result.directionalLight, "destroy"); + + // Act + result.dispose(); + + // Assert + expect(destroySpy).toHaveBeenCalled(); + }); + + it("should destroy scene entity on cleanup", () => { + // Arrange + const result = initPlayCanvas(); + const destroySpy = jest.spyOn(result.scene, "destroy"); + + // Act + result.dispose(); + + // Assert + expect(destroySpy).toHaveBeenCalled(); + }); + + it("should destroy app on cleanup", () => { + // Arrange + const result = initPlayCanvas(); + const destroySpy = jest.spyOn(result.app, "destroy"); + + // Act + result.dispose(); + + // Assert + expect(destroySpy).toHaveBeenCalled(); + }); + + it("should destroy orbit camera controller when enabled", () => { + // Arrange + const config = new PlayCanvasScene.InitPlayCanvasDto(); + config.enableOrbitCamera = true; + const result = initPlayCanvas(config); + expect(result.orbitCamera).not.toBeNull(); + const destroySpy = jest.spyOn(result.orbitCamera as NonNullable, "destroy"); + + // Act + result.dispose(); + + // Assert + expect(destroySpy).toHaveBeenCalled(); + }); + + it("should destroy ground when enabled", () => { + // Arrange + const config = new PlayCanvasScene.InitPlayCanvasDto(); + config.enableGround = true; + const result = initPlayCanvas(config); + expect(result.ground).not.toBeNull(); + const destroySpy = jest.spyOn(result.ground as NonNullable, "destroy"); + + // Act + result.dispose(); + + // Assert + expect(destroySpy).toHaveBeenCalled(); + }); + + it("should remove created canvas from DOM on dispose", () => { + // Arrange - no canvasId means a new canvas is created + const result = initPlayCanvas(); + const canvasCount = document.querySelectorAll("canvas").length; + + // Act + result.dispose(); + + // Assert - there should be one less canvas (only the mock test canvas remains) + const newCanvasCount = document.querySelectorAll("canvas").length; + expect(newCanvasCount).toBeLessThan(canvasCount); + }); + + it("should not remove canvas from DOM when canvasId was provided", () => { + // Arrange + const config = new PlayCanvasScene.InitPlayCanvasDto(); + config.canvasId = "test-canvas"; + const result = initPlayCanvas(config); + + // Act + result.dispose(); + + // Assert - canvas should still be in DOM + expect(mockCanvas.parentNode).toBe(document.body); + }); + }); + + describe("hexToRgb helper function", () => { + it("should parse valid hex colors correctly", () => { + // Arrange + const config = new PlayCanvasScene.InitPlayCanvasDto(); + config.canvasId = "test-canvas"; + config.backgroundColor = "#ff0000"; // Pure red + + // Act + const result = initPlayCanvas(config); + + // Assert - the background color should be parsed and applied + expect(result.app).toBeDefined(); + + // Cleanup + result.dispose(); + }); + + it("should handle lowercase hex colors", () => { + // Arrange + const config = new PlayCanvasScene.InitPlayCanvasDto(); + config.canvasId = "test-canvas"; + config.groundColor = "#00ff00"; // Pure green + + // Act + const result = initPlayCanvas(config); + + // Assert + expect(result.ground).toBeDefined(); + + // Cleanup + result.dispose(); + }); + }); + + describe("orbit camera controller functionality", () => { + it("should register update callback on app", () => { + // Arrange + const config = new PlayCanvasScene.InitPlayCanvasDto(); + config.canvasId = "test-canvas"; + config.enableOrbitCamera = true; + + // Act + const result = initPlayCanvas(config); + + // Assert + expect((result.app as unknown as MockAppType)._updateCallbacks.length).toBeGreaterThan(0); + + // Cleanup + result.dispose(); + }); + + it("should unregister update callback on destroy", () => { + // Arrange + const config = new PlayCanvasScene.InitPlayCanvasDto(); + config.canvasId = "test-canvas"; + config.enableOrbitCamera = true; + const result = initPlayCanvas(config); + const initialCallbackCount = (result.app as unknown as MockAppType)._updateCallbacks.length; + + // Act + result.orbitCamera?.destroy(); + + // Assert + expect((result.app as unknown as MockAppType)._updateCallbacks.length).toBeLessThan(initialCallbackCount); + + // Cleanup + result.dispose(); + }); + + it("should have mouse and touch input handlers", () => { + // Arrange + const config = new PlayCanvasScene.InitPlayCanvasDto(); + config.canvasId = "test-canvas"; + config.enableOrbitCamera = true; + + // Act + const result = initPlayCanvas(config); + + // Assert + expect(result.orbitCamera?.mouseInput).toBeDefined(); + expect(result.orbitCamera?.touchInput).toBeDefined(); + + // Cleanup + result.dispose(); + }); + + it("should have update function", () => { + // Arrange + const config = new PlayCanvasScene.InitPlayCanvasDto(); + config.canvasId = "test-canvas"; + config.enableOrbitCamera = true; + + // Act + const result = initPlayCanvas(config); + + // Assert + expect(typeof result.orbitCamera?.update).toBe("function"); + + // Cleanup + result.dispose(); + }); + }); +}); diff --git a/packages/dev/playcanvas/lib/api/inputs/playcanvas-camera-inputs.test.ts b/packages/dev/playcanvas/lib/api/inputs/playcanvas-camera-inputs.test.ts index 0fca54d3..c21cd775 100644 --- a/packages/dev/playcanvas/lib/api/inputs/playcanvas-camera-inputs.test.ts +++ b/packages/dev/playcanvas/lib/api/inputs/playcanvas-camera-inputs.test.ts @@ -16,8 +16,8 @@ describe("PlayCanvasCamera inputs unit tests", () => { expect(dto.pitchAngleMin).toBe(-90); expect(dto.pitchAngleMax).toBe(90); expect(dto.orbitSensitivity).toBe(0.3); - expect(dto.distanceSensitivity).toBe(0.15); - expect(dto.inertiaFactor).toBe(0); + expect(dto.distanceSensitivity).toBe(0.5); + expect(dto.inertiaFactor).toBe(0.1); expect(dto.autoRender).toBe(true); expect(dto.frameOnStart).toBe(true); expect(dto.focusEntity).toBeUndefined(); @@ -71,7 +71,7 @@ describe("PlayCanvasCamera inputs unit tests", () => { it("should create OrbitCameraDto with custom orbitSensitivity when provided", () => { const dto = new PlayCanvasCamera.OrbitCameraDto(undefined, undefined, undefined, undefined, undefined, undefined, undefined, 0.5); expect(dto.orbitSensitivity).toBe(0.5); - expect(dto.distanceSensitivity).toBe(0.15); + expect(dto.distanceSensitivity).toBe(0.5); }); it("should create OrbitCameraDto with custom distanceSensitivity when provided", () => { diff --git a/packages/dev/playcanvas/package-lock.json b/packages/dev/playcanvas/package-lock.json index 7f5d3e27..c94c4a4d 100644 --- a/packages/dev/playcanvas/package-lock.json +++ b/packages/dev/playcanvas/package-lock.json @@ -20,6 +20,7 @@ "@types/jest": "29.0.0", "babel-jest": "29.0.0", "jest": "29.4.1", + "jest-environment-jsdom": "^30.2.0", "jest-html-reporters": "3.0.11", "mvdir": "1.0.21", "sass": "1.57.1", @@ -29,13 +30,37 @@ "typescript": "4.8.2" } }, + "node_modules/@asamuzakjp/css-color": { + "version": "3.2.0", + "resolved": "https://registry.npmjs.org/@asamuzakjp/css-color/-/css-color-3.2.0.tgz", + "integrity": "sha512-K1A6z8tS3XsmCMM86xoWdn7Fkdn9m6RSVtocUrJYIwZnFVkng/PvkEoWtOWmP+Scc6saYWHWZYbndEEXxl24jw==", + "dev": true, + "license": "MIT", + "dependencies": { + "@csstools/css-calc": "^2.1.3", + "@csstools/css-color-parser": "^3.0.9", + "@csstools/css-parser-algorithms": "^3.0.4", + "@csstools/css-tokenizer": "^3.0.3", + "lru-cache": "^10.4.3" + } + }, + "node_modules/@asamuzakjp/css-color/node_modules/lru-cache": { + "version": "10.4.3", + "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-10.4.3.tgz", + "integrity": "sha512-JNAzZcXrCt42VGLuYz0zfAzDfAvJWW6AfYlDBQyDV5DClI2m5sAmK+OIO7s59XfsRsWHp02jAJrRadPRGTt6SQ==", + "dev": true, + "license": "ISC" + }, "node_modules/@babel/code-frame": { - "version": "7.18.6", - "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.18.6.tgz", - "integrity": "sha512-TDCmlK5eOvH+eH7cdAFlNXeVJqWIQ7gW9tY1GJIpUtFb6CmjVyq2VM3u71bOyR8CRihcCgMUYoDNyLXao3+70Q==", + "version": "7.28.6", + "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.28.6.tgz", + "integrity": "sha512-JYgintcMjRiCvS8mMECzaEn+m3PfoQiyqukOMCCVQtoJGYJw8j/8LBJEiqkHLkfwCcs74E3pbAUFNg7d9VNJ+Q==", "dev": true, + "license": "MIT", "dependencies": { - "@babel/highlight": "^7.18.6" + "@babel/helper-validator-identifier": "^7.28.5", + "js-tokens": "^4.0.0", + "picocolors": "^1.1.1" }, "engines": { "node": ">=6.9.0" @@ -387,10 +412,11 @@ } }, "node_modules/@babel/helper-validator-identifier": { - "version": "7.19.1", - "resolved": "https://registry.npmjs.org/@babel/helper-validator-identifier/-/helper-validator-identifier-7.19.1.tgz", - "integrity": "sha512-awrNfaMtnHUr653GgGEs++LlAvW6w+DcPrOliSMXWCKo597CwL5Acf/wWdNkf/tfEQE3mjkeD1YOVZOUV/od1w==", + "version": "7.28.5", + "resolved": "https://registry.npmjs.org/@babel/helper-validator-identifier/-/helper-validator-identifier-7.28.5.tgz", + "integrity": "sha512-qSs4ifwzKJSV39ucNjsvc6WVHs6b7S03sOh2OcHF9UHfVPqWWALUsNUVzhSBiItjRZoLHx7nIarVjqKVusUZ1Q==", "dev": true, + "license": "MIT", "engines": { "node": ">=6.9.0" } @@ -433,20 +459,6 @@ "node": ">=6.9.0" } }, - "node_modules/@babel/highlight": { - "version": "7.18.6", - "resolved": "https://registry.npmjs.org/@babel/highlight/-/highlight-7.18.6.tgz", - "integrity": "sha512-u7stbOuYjaPezCuLj29hNW1v64M2Md2qupEKP1fHc7WdOA3DgLh37suiSrZYY7haUB7iBeQZ9P1uiRF359do3g==", - "dev": true, - "dependencies": { - "@babel/helper-validator-identifier": "^7.18.6", - "chalk": "^2.0.0", - "js-tokens": "^4.0.0" - }, - "engines": { - "node": ">=6.9.0" - } - }, "node_modules/@babel/parser": { "version": "7.21.2", "resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.21.2.tgz", @@ -1808,6 +1820,121 @@ "@jridgewell/sourcemap-codec": "^1.4.10" } }, + "node_modules/@csstools/color-helpers": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/@csstools/color-helpers/-/color-helpers-5.1.0.tgz", + "integrity": "sha512-S11EXWJyy0Mz5SYvRmY8nJYTFFd1LCNV+7cXyAgQtOOuzb4EsgfqDufL+9esx72/eLhsRdGZwaldu/h+E4t4BA==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/csstools" + }, + { + "type": "opencollective", + "url": "https://opencollective.com/csstools" + } + ], + "license": "MIT-0", + "engines": { + "node": ">=18" + } + }, + "node_modules/@csstools/css-calc": { + "version": "2.1.4", + "resolved": "https://registry.npmjs.org/@csstools/css-calc/-/css-calc-2.1.4.tgz", + "integrity": "sha512-3N8oaj+0juUw/1H3YwmDDJXCgTB1gKU6Hc/bB502u9zR0q2vd786XJH9QfrKIEgFlZmhZiq6epXl4rHqhzsIgQ==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/csstools" + }, + { + "type": "opencollective", + "url": "https://opencollective.com/csstools" + } + ], + "license": "MIT", + "engines": { + "node": ">=18" + }, + "peerDependencies": { + "@csstools/css-parser-algorithms": "^3.0.5", + "@csstools/css-tokenizer": "^3.0.4" + } + }, + "node_modules/@csstools/css-color-parser": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/@csstools/css-color-parser/-/css-color-parser-3.1.0.tgz", + "integrity": "sha512-nbtKwh3a6xNVIp/VRuXV64yTKnb1IjTAEEh3irzS+HkKjAOYLTGNb9pmVNntZ8iVBHcWDA2Dof0QtPgFI1BaTA==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/csstools" + }, + { + "type": "opencollective", + "url": "https://opencollective.com/csstools" + } + ], + "license": "MIT", + "dependencies": { + "@csstools/color-helpers": "^5.1.0", + "@csstools/css-calc": "^2.1.4" + }, + "engines": { + "node": ">=18" + }, + "peerDependencies": { + "@csstools/css-parser-algorithms": "^3.0.5", + "@csstools/css-tokenizer": "^3.0.4" + } + }, + "node_modules/@csstools/css-parser-algorithms": { + "version": "3.0.5", + "resolved": "https://registry.npmjs.org/@csstools/css-parser-algorithms/-/css-parser-algorithms-3.0.5.tgz", + "integrity": "sha512-DaDeUkXZKjdGhgYaHNJTV9pV7Y9B3b644jCLs9Upc3VeNGg6LWARAT6O+Q+/COo+2gg/bM5rhpMAtf70WqfBdQ==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/csstools" + }, + { + "type": "opencollective", + "url": "https://opencollective.com/csstools" + } + ], + "license": "MIT", + "engines": { + "node": ">=18" + }, + "peerDependencies": { + "@csstools/css-tokenizer": "^3.0.4" + } + }, + "node_modules/@csstools/css-tokenizer": { + "version": "3.0.4", + "resolved": "https://registry.npmjs.org/@csstools/css-tokenizer/-/css-tokenizer-3.0.4.tgz", + "integrity": "sha512-Vd/9EVDiu6PPJt9yAh6roZP6El1xHrdvIVGjyBsHR0RYwNHgL7FJPyIIW4fANJNG6FtyZfvlRPpFI4ZM/lubvw==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/csstools" + }, + { + "type": "opencollective", + "url": "https://opencollective.com/csstools" + } + ], + "license": "MIT", + "engines": { + "node": ">=18" + } + }, "node_modules/@emnapi/runtime": { "version": "1.8.1", "resolved": "https://registry.npmjs.org/@emnapi/runtime/-/runtime-1.8.1.tgz", @@ -2367,76 +2494,6 @@ "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, - "node_modules/@jest/console/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/@jest/console/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" - } - }, - "node_modules/@jest/console/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/@jest/console/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "node_modules/@jest/console/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/@jest/console/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, "node_modules/@jest/core": { "version": "29.4.3", "resolved": "https://registry.npmjs.org/@jest/core/-/core-29.4.3.tgz", @@ -2484,119 +2541,281 @@ } } }, - "node_modules/@jest/core/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "node_modules/@jest/environment": { + "version": "29.4.3", + "resolved": "https://registry.npmjs.org/@jest/environment/-/environment-29.4.3.tgz", + "integrity": "sha512-dq5S6408IxIa+lr54zeqce+QgI+CJT4nmmA+1yzFgtcsGK8c/EyiUb9XQOgz3BMKrRDfKseeOaxj2eO8LlD3lA==", "dev": true, "dependencies": { - "color-convert": "^2.0.1" + "@jest/fake-timers": "^29.4.3", + "@jest/types": "^29.4.3", + "@types/node": "*", + "jest-mock": "^29.4.3" }, "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, - "node_modules/@jest/core/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "node_modules/@jest/environment-jsdom-abstract": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/environment-jsdom-abstract/-/environment-jsdom-abstract-30.2.0.tgz", + "integrity": "sha512-kazxw2L9IPuZpQ0mEt9lu9Z98SqR74xcagANmMBU16X0lS23yPc0+S6hGLUz8kVRlomZEs/5S/Zlpqwf5yu6OQ==", "dev": true, + "license": "MIT", "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" + "@jest/environment": "30.2.0", + "@jest/fake-timers": "30.2.0", + "@jest/types": "30.2.0", + "@types/jsdom": "^21.1.7", + "@types/node": "*", + "jest-mock": "30.2.0", + "jest-util": "30.2.0" }, "engines": { - "node": ">=10" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" + "peerDependencies": { + "canvas": "^3.0.0", + "jsdom": "*" + }, + "peerDependenciesMeta": { + "canvas": { + "optional": true + } } }, - "node_modules/@jest/core/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "node_modules/@jest/environment-jsdom-abstract/node_modules/@jest/environment": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/environment/-/environment-30.2.0.tgz", + "integrity": "sha512-/QPTL7OBJQ5ac09UDRa3EQes4gt1FTEG/8jZ/4v5IVzx+Cv7dLxlVIvfvSVRiiX2drWyXeBjkMSR8hvOWSog5g==", "dev": true, + "license": "MIT", "dependencies": { - "color-name": "~1.1.4" + "@jest/fake-timers": "30.2.0", + "@jest/types": "30.2.0", + "@types/node": "*", + "jest-mock": "30.2.0" }, "engines": { - "node": ">=7.0.0" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/@jest/core/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "node_modules/@jest/core/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "node_modules/@jest/environment-jsdom-abstract/node_modules/@jest/fake-timers": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/fake-timers/-/fake-timers-30.2.0.tgz", + "integrity": "sha512-HI3tRLjRxAbBy0VO8dqqm7Hb2mIa8d5bg/NJkyQcOk7V118ObQML8RC5luTF/Zsg4474a+gDvhce7eTnP4GhYw==", "dev": true, + "license": "MIT", + "dependencies": { + "@jest/types": "30.2.0", + "@sinonjs/fake-timers": "^13.0.0", + "@types/node": "*", + "jest-message-util": "30.2.0", + "jest-mock": "30.2.0", + "jest-util": "30.2.0" + }, "engines": { - "node": ">=8" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/@jest/core/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "node_modules/@jest/environment-jsdom-abstract/node_modules/@jest/schemas": { + "version": "30.0.5", + "resolved": "https://registry.npmjs.org/@jest/schemas/-/schemas-30.0.5.tgz", + "integrity": "sha512-DmdYgtezMkh3cpU8/1uyXakv3tJRcmcXxBOcO0tbaozPwpmh4YMsnWrQm9ZmZMfa5ocbxzbFk6O4bDPEc/iAnA==", "dev": true, + "license": "MIT", "dependencies": { - "has-flag": "^4.0.0" + "@sinclair/typebox": "^0.34.0" }, "engines": { - "node": ">=8" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/@jest/environment": { - "version": "29.4.3", - "resolved": "https://registry.npmjs.org/@jest/environment/-/environment-29.4.3.tgz", - "integrity": "sha512-dq5S6408IxIa+lr54zeqce+QgI+CJT4nmmA+1yzFgtcsGK8c/EyiUb9XQOgz3BMKrRDfKseeOaxj2eO8LlD3lA==", + "node_modules/@jest/environment-jsdom-abstract/node_modules/@jest/types": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/types/-/types-30.2.0.tgz", + "integrity": "sha512-H9xg1/sfVvyfU7o3zMfBEjQ1gcsdeTMgqHoYdN79tuLqfTtuu7WckRA1R5whDwOzxaZAeMKTYWqP+WCAi0CHsg==", "dev": true, + "license": "MIT", "dependencies": { - "@jest/fake-timers": "^29.4.3", - "@jest/types": "^29.4.3", + "@jest/pattern": "30.0.1", + "@jest/schemas": "30.0.5", + "@types/istanbul-lib-coverage": "^2.0.6", + "@types/istanbul-reports": "^3.0.4", "@types/node": "*", - "jest-mock": "^29.4.3" + "@types/yargs": "^17.0.33", + "chalk": "^4.1.2" }, "engines": { - "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/@jest/expect": { - "version": "29.4.3", - "resolved": "https://registry.npmjs.org/@jest/expect/-/expect-29.4.3.tgz", - "integrity": "sha512-iktRU/YsxEtumI9zsPctYUk7ptpC+AVLLk1Ax3AsA4g1C+8OOnKDkIQBDHtD5hA/+VtgMd5AWI5gNlcAlt2vxQ==", + "node_modules/@jest/environment-jsdom-abstract/node_modules/@sinclair/typebox": { + "version": "0.34.47", + "resolved": "https://registry.npmjs.org/@sinclair/typebox/-/typebox-0.34.47.tgz", + "integrity": "sha512-ZGIBQ+XDvO5JQku9wmwtabcVTHJsgSWAHYtVuM9pBNNR5E88v6Jcj/llpmsjivig5X8A8HHOb4/mbEKPS5EvAw==", + "dev": true, + "license": "MIT" + }, + "node_modules/@jest/environment-jsdom-abstract/node_modules/@sinonjs/commons": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/@sinonjs/commons/-/commons-3.0.1.tgz", + "integrity": "sha512-K3mCHKQ9sVh8o1C9cxkwxaOmXoAMlDxC1mYyHrjqOWEcBjYr76t96zL2zlj5dUGZ3HSw240X1qgH3Mjf1yJWpQ==", "dev": true, + "license": "BSD-3-Clause", "dependencies": { - "expect": "^29.4.3", - "jest-snapshot": "^29.4.3" - }, - "engines": { - "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + "type-detect": "4.0.8" } }, - "node_modules/@jest/expect-utils": { - "version": "29.4.3", - "resolved": "https://registry.npmjs.org/@jest/expect-utils/-/expect-utils-29.4.3.tgz", - "integrity": "sha512-/6JWbkxHOP8EoS8jeeTd9dTfc9Uawi+43oLKHfp6zzux3U2hqOOVnV3ai4RpDYHOccL6g+5nrxpoc8DmJxtXVQ==", + "node_modules/@jest/environment-jsdom-abstract/node_modules/@sinonjs/fake-timers": { + "version": "13.0.5", + "resolved": "https://registry.npmjs.org/@sinonjs/fake-timers/-/fake-timers-13.0.5.tgz", + "integrity": "sha512-36/hTbH2uaWuGVERyC6da9YwGWnzUZXuPro/F2LfsdOsLnCojz/iSH8MxUt/FD2S5XBSVPhmArFUXcpCQ2Hkiw==", "dev": true, + "license": "BSD-3-Clause", "dependencies": { - "jest-get-type": "^29.4.3" - }, - "engines": { - "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + "@sinonjs/commons": "^3.0.1" } }, - "node_modules/@jest/fake-timers": { - "version": "29.4.3", - "resolved": "https://registry.npmjs.org/@jest/fake-timers/-/fake-timers-29.4.3.tgz", + "node_modules/@jest/environment-jsdom-abstract/node_modules/ci-info": { + "version": "4.3.1", + "resolved": "https://registry.npmjs.org/ci-info/-/ci-info-4.3.1.tgz", + "integrity": "sha512-Wdy2Igu8OcBpI2pZePZ5oWjPC38tmDVx5WKUXKwlLYkA0ozo85sLsLvkBbBn/sZaSCMFOGZJ14fvW9t5/d7kdA==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/sibiraj-s" + } + ], + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "node_modules/@jest/environment-jsdom-abstract/node_modules/jest-message-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-message-util/-/jest-message-util-30.2.0.tgz", + "integrity": "sha512-y4DKFLZ2y6DxTWD4cDe07RglV88ZiNEdlRfGtqahfbIjfsw1nMCPx49Uev4IA/hWn3sDKyAnSPwoYSsAEdcimw==", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/code-frame": "^7.27.1", + "@jest/types": "30.2.0", + "@types/stack-utils": "^2.0.3", + "chalk": "^4.1.2", + "graceful-fs": "^4.2.11", + "micromatch": "^4.0.8", + "pretty-format": "30.2.0", + "slash": "^3.0.0", + "stack-utils": "^2.0.6" + }, + "engines": { + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" + } + }, + "node_modules/@jest/environment-jsdom-abstract/node_modules/jest-mock": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-mock/-/jest-mock-30.2.0.tgz", + "integrity": "sha512-JNNNl2rj4b5ICpmAcq+WbLH83XswjPbjH4T7yvGzfAGCPh1rw+xVNbtk+FnRslvt9lkCcdn9i1oAoKUuFsOxRw==", + "dev": true, + "license": "MIT", + "dependencies": { + "@jest/types": "30.2.0", + "@types/node": "*", + "jest-util": "30.2.0" + }, + "engines": { + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" + } + }, + "node_modules/@jest/environment-jsdom-abstract/node_modules/jest-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-30.2.0.tgz", + "integrity": "sha512-QKNsM0o3Xe6ISQU869e+DhG+4CK/48aHYdJZGlFQVTjnbvgpcKyxpzk29fGiO7i/J8VENZ+d2iGnSsvmuHywlA==", + "dev": true, + "license": "MIT", + "dependencies": { + "@jest/types": "30.2.0", + "@types/node": "*", + "chalk": "^4.1.2", + "ci-info": "^4.2.0", + "graceful-fs": "^4.2.11", + "picomatch": "^4.0.2" + }, + "engines": { + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" + } + }, + "node_modules/@jest/environment-jsdom-abstract/node_modules/picomatch": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.3.tgz", + "integrity": "sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=12" + }, + "funding": { + "url": "https://github.com/sponsors/jonschlinkert" + } + }, + "node_modules/@jest/environment-jsdom-abstract/node_modules/pretty-format": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/pretty-format/-/pretty-format-30.2.0.tgz", + "integrity": "sha512-9uBdv/B4EefsuAL+pWqueZyZS2Ba+LxfFeQ9DN14HU4bN8bhaxKdkpjpB6fs9+pSjIBu+FXQHImEg8j/Lw0+vA==", + "dev": true, + "license": "MIT", + "dependencies": { + "@jest/schemas": "30.0.5", + "ansi-styles": "^5.2.0", + "react-is": "^18.3.1" + }, + "engines": { + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" + } + }, + "node_modules/@jest/environment-jsdom-abstract/node_modules/pretty-format/node_modules/ansi-styles": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-5.2.0.tgz", + "integrity": "sha512-Cxwpt2SfTzTtXcfOlzGEee8O+c+MmUgGrNiBcXnuWxuFJHe6a5Hz7qwhwe5OgaSYI0IJvkLqWX1ASG+cJOkEiA==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/@jest/expect": { + "version": "29.4.3", + "resolved": "https://registry.npmjs.org/@jest/expect/-/expect-29.4.3.tgz", + "integrity": "sha512-iktRU/YsxEtumI9zsPctYUk7ptpC+AVLLk1Ax3AsA4g1C+8OOnKDkIQBDHtD5hA/+VtgMd5AWI5gNlcAlt2vxQ==", + "dev": true, + "dependencies": { + "expect": "^29.4.3", + "jest-snapshot": "^29.4.3" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/@jest/expect-utils": { + "version": "29.4.3", + "resolved": "https://registry.npmjs.org/@jest/expect-utils/-/expect-utils-29.4.3.tgz", + "integrity": "sha512-/6JWbkxHOP8EoS8jeeTd9dTfc9Uawi+43oLKHfp6zzux3U2hqOOVnV3ai4RpDYHOccL6g+5nrxpoc8DmJxtXVQ==", + "dev": true, + "dependencies": { + "jest-get-type": "^29.4.3" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/@jest/fake-timers": { + "version": "29.4.3", + "resolved": "https://registry.npmjs.org/@jest/fake-timers/-/fake-timers-29.4.3.tgz", "integrity": "sha512-4Hote2MGcCTWSD2gwl0dwbCpBRHhE6olYEuTj8FMowdg3oQWNKr2YuxenPQYZ7+PfqPY1k98wKDU4Z+Hvd4Tiw==", "dev": true, "dependencies": { @@ -2626,6 +2845,30 @@ "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, + "node_modules/@jest/pattern": { + "version": "30.0.1", + "resolved": "https://registry.npmjs.org/@jest/pattern/-/pattern-30.0.1.tgz", + "integrity": "sha512-gWp7NfQW27LaBQz3TITS8L7ZCQ0TLvtmI//4OwlQRx4rnWxcPNIYjxZpDcN4+UlGxgm3jS5QPz8IPTCkb59wZA==", + "dev": true, + "license": "MIT", + "dependencies": { + "@types/node": "*", + "jest-regex-util": "30.0.1" + }, + "engines": { + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" + } + }, + "node_modules/@jest/pattern/node_modules/jest-regex-util": { + "version": "30.0.1", + "resolved": "https://registry.npmjs.org/jest-regex-util/-/jest-regex-util-30.0.1.tgz", + "integrity": "sha512-jHEQgBXAgc+Gh4g0p3bCevgRCVRkB4VB70zhoAE48gxeSr1hfUOsM/C2WoJgVL7Eyg//hudYENbm3Ne+/dRVVA==", + "dev": true, + "license": "MIT", + "engines": { + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" + } + }, "node_modules/@jest/reporters": { "version": "29.4.3", "resolved": "https://registry.npmjs.org/@jest/reporters/-/reporters-29.4.3.tgz", @@ -2669,76 +2912,6 @@ } } }, - "node_modules/@jest/reporters/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/@jest/reporters/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" - } - }, - "node_modules/@jest/reporters/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/@jest/reporters/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "node_modules/@jest/reporters/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/@jest/reporters/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, "node_modules/@jest/schemas": { "version": "29.4.3", "resolved": "https://registry.npmjs.org/@jest/schemas/-/schemas-29.4.3.tgz", @@ -2821,82 +2994,12 @@ "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, - "node_modules/@jest/transform/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/@jest/transform/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" - } - }, - "node_modules/@jest/transform/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/@jest/transform/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, "node_modules/@jest/transform/node_modules/convert-source-map": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/convert-source-map/-/convert-source-map-2.0.0.tgz", "integrity": "sha512-Kvp459HrV2FEJ1CAsi1Ku+MY3kasH19TFykTz2xWmMeq6bk2NU3XXvfJ+Q61m0xktWwt+1HSYf3JZsTms3aRJg==", "dev": true }, - "node_modules/@jest/transform/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/@jest/transform/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, "node_modules/@jest/types": { "version": "29.4.3", "resolved": "https://registry.npmjs.org/@jest/types/-/types-29.4.3.tgz", @@ -2914,88 +3017,18 @@ "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, - "node_modules/@jest/types/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "node_modules/@jridgewell/gen-mapping": { + "version": "0.3.2", + "resolved": "https://registry.npmjs.org/@jridgewell/gen-mapping/-/gen-mapping-0.3.2.tgz", + "integrity": "sha512-mh65xKQAzI6iBcFzwv28KVWSmCkdRBWoOh+bYQGW3+6OZvbbN3TqMGo5hqYxQniRcH9F2VZIoJCm4pa3BPDK/A==", "dev": true, "dependencies": { - "color-convert": "^2.0.1" + "@jridgewell/set-array": "^1.0.1", + "@jridgewell/sourcemap-codec": "^1.4.10", + "@jridgewell/trace-mapping": "^0.3.9" }, "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/@jest/types/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" - } - }, - "node_modules/@jest/types/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/@jest/types/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "node_modules/@jest/types/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/@jest/types/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/@jridgewell/gen-mapping": { - "version": "0.3.2", - "resolved": "https://registry.npmjs.org/@jridgewell/gen-mapping/-/gen-mapping-0.3.2.tgz", - "integrity": "sha512-mh65xKQAzI6iBcFzwv28KVWSmCkdRBWoOh+bYQGW3+6OZvbbN3TqMGo5hqYxQniRcH9F2VZIoJCm4pa3BPDK/A==", - "dev": true, - "dependencies": { - "@jridgewell/set-array": "^1.0.1", - "@jridgewell/sourcemap-codec": "^1.4.10", - "@jridgewell/trace-mapping": "^0.3.9" - }, - "engines": { - "node": ">=6.0.0" + "node": ">=6.0.0" } }, "node_modules/@jridgewell/resolve-uri": { @@ -3192,21 +3225,6 @@ "yarn": ">=1" } }, - "node_modules/@testing-library/jest-dom/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, "node_modules/@testing-library/jest-dom/node_modules/chalk": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/chalk/-/chalk-3.0.0.tgz", @@ -3220,45 +3238,6 @@ "node": ">=8" } }, - "node_modules/@testing-library/jest-dom/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/@testing-library/jest-dom/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "node_modules/@testing-library/jest-dom/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/@testing-library/jest-dom/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, "node_modules/@tsconfig/node10": { "version": "1.0.9", "resolved": "https://registry.npmjs.org/@tsconfig/node10/-/node10-1.0.9.tgz", @@ -3334,10 +3313,11 @@ } }, "node_modules/@types/istanbul-lib-coverage": { - "version": "2.0.4", - "resolved": "https://registry.npmjs.org/@types/istanbul-lib-coverage/-/istanbul-lib-coverage-2.0.4.tgz", - "integrity": "sha512-z/QT1XN4K4KYuslS23k62yDIDLwLFkzxOuMplDtObz0+y7VqJCaO2o+SPwHCvLFZh7xazvvoor2tA/hPz9ee7g==", - "dev": true + "version": "2.0.6", + "resolved": "https://registry.npmjs.org/@types/istanbul-lib-coverage/-/istanbul-lib-coverage-2.0.6.tgz", + "integrity": "sha512-2QF/t/auWm0lsy8XtKVPG19v3sSOQlJe/YHZgfjb/KBBHOGSV+J2q/S671rcq9uTBrLAXmZpqJiaQbMT+zNU1w==", + "dev": true, + "license": "MIT" }, "node_modules/@types/istanbul-lib-report": { "version": "3.0.0", @@ -3349,10 +3329,11 @@ } }, "node_modules/@types/istanbul-reports": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/@types/istanbul-reports/-/istanbul-reports-3.0.1.tgz", - "integrity": "sha512-c3mAZEuK0lvBp8tmuL74XRKn1+y2dcwOUpH7x4WrF6gk1GIgiluDRgMYQtw2OFcBvAJWlt6ASU3tSqxp0Uu0Aw==", + "version": "3.0.4", + "resolved": "https://registry.npmjs.org/@types/istanbul-reports/-/istanbul-reports-3.0.4.tgz", + "integrity": "sha512-pk2B1NWalF9toCRu6gjBzR69syFjP4Od8WRAX+0mmf9lAjCRicLOWc+ZrxZHx/0XRjotgkF9t6iaMJ+aXcOdZQ==", "dev": true, + "license": "MIT", "dependencies": { "@types/istanbul-lib-report": "*" } @@ -3367,6 +3348,18 @@ "pretty-format": "^29.0.0" } }, + "node_modules/@types/jsdom": { + "version": "21.1.7", + "resolved": "https://registry.npmjs.org/@types/jsdom/-/jsdom-21.1.7.tgz", + "integrity": "sha512-yOriVnggzrnQ3a9OKOCxaVuSug3w3/SbOj5i7VwXWZEyUNl3bLF9V3MfxGbZKuwqJOQyRfqXyROBB1CoZLFWzA==", + "dev": true, + "license": "MIT", + "dependencies": { + "@types/node": "*", + "@types/tough-cookie": "*", + "parse5": "^7.0.0" + } + }, "node_modules/@types/ndarray": { "version": "1.0.14", "resolved": "https://registry.npmjs.org/@types/ndarray/-/ndarray-1.0.14.tgz", @@ -3386,10 +3379,11 @@ "dev": true }, "node_modules/@types/stack-utils": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/@types/stack-utils/-/stack-utils-2.0.1.tgz", - "integrity": "sha512-Hl219/BT5fLAaz6NDkSuhzasy49dwQS/DSdu4MdggFB8zcXv7vflBI3xp7FEmkmdDkBUI2bPUNeMttp2knYdxw==", - "dev": true + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/@types/stack-utils/-/stack-utils-2.0.3.tgz", + "integrity": "sha512-9aEbYZ3TbYMznPdcdr3SmIrLXwC/AKZXQeCf9Pgao5CKb8CyHuEX5jzWPTkvregvhRJHcpRO6BFoGW9ycaOkYw==", + "dev": true, + "license": "MIT" }, "node_modules/@types/testing-library__jest-dom": { "version": "5.14.5", @@ -3400,6 +3394,13 @@ "@types/jest": "*" } }, + "node_modules/@types/tough-cookie": { + "version": "4.0.5", + "resolved": "https://registry.npmjs.org/@types/tough-cookie/-/tough-cookie-4.0.5.tgz", + "integrity": "sha512-/Ad8+nIOV7Rl++6f1BdKxFSMgmoqEoYbHRpPcx3JEfv8VRsQe9Z4mCXeJBzxs7mbHY/XOZZuXlRNfhpVPbs6ZA==", + "dev": true, + "license": "MIT" + }, "node_modules/@types/webxr": { "version": "0.5.24", "resolved": "https://registry.npmjs.org/@types/webxr/-/webxr-0.5.24.tgz", @@ -3407,10 +3408,11 @@ "license": "MIT" }, "node_modules/@types/yargs": { - "version": "17.0.22", - "resolved": "https://registry.npmjs.org/@types/yargs/-/yargs-17.0.22.tgz", - "integrity": "sha512-pet5WJ9U8yPVRhkwuEIp5ktAeAqRZOq4UdAyWLWzxbtpyXnzbtLdKiXAjJzi/KLmPGS9wk86lUFWZFN6sISo4g==", + "version": "17.0.35", + "resolved": "https://registry.npmjs.org/@types/yargs/-/yargs-17.0.35.tgz", + "integrity": "sha512-qUHkeCyQFxMXg79wQfTtfndEC+N9ZZg76HJftDJp+qH2tV7Gj4OJi7l+PiWwJ+pWtW8GwSmqsDj/oymhrTWXjg==", "dev": true, + "license": "MIT", "dependencies": { "@types/yargs-parser": "*" } @@ -3448,6 +3450,16 @@ "node": ">=0.4.0" } }, + "node_modules/agent-base": { + "version": "7.1.4", + "resolved": "https://registry.npmjs.org/agent-base/-/agent-base-7.1.4.tgz", + "integrity": "sha512-MnA+YT8fwfJPgBx3m60MNqakm30XOkyIoH1y6huTQvC0PwZG7ki8NacLBcrPbNoo8vEZy7Jpuk7+jMO+CUovTQ==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">= 14" + } + }, "node_modules/ansi-escapes": { "version": "4.3.2", "resolved": "https://registry.npmjs.org/ansi-escapes/-/ansi-escapes-4.3.2.tgz", @@ -3473,15 +3485,19 @@ } }, "node_modules/ansi-styles": { - "version": "3.2.1", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz", - "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", "dev": true, + "license": "MIT", "dependencies": { - "color-convert": "^1.9.0" + "color-convert": "^2.0.1" }, "engines": { - "node": ">=4" + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" } }, "node_modules/anymatch": { @@ -3567,76 +3583,6 @@ "@babel/core": "^7.8.0" } }, - "node_modules/babel-jest/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/babel-jest/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" - } - }, - "node_modules/babel-jest/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/babel-jest/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "node_modules/babel-jest/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/babel-jest/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, "node_modules/babel-plugin-istanbul": { "version": "6.1.1", "resolved": "https://registry.npmjs.org/babel-plugin-istanbul/-/babel-plugin-istanbul-6.1.1.tgz", @@ -3956,17 +3902,20 @@ } }, "node_modules/chalk": { - "version": "2.4.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.2.tgz", - "integrity": "sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==", + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", "dev": true, + "license": "MIT", "dependencies": { - "ansi-styles": "^3.2.1", - "escape-string-regexp": "^1.0.5", - "supports-color": "^5.3.0" + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" }, "engines": { - "node": ">=4" + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" } }, "node_modules/char-regex": { @@ -4064,19 +4013,24 @@ "dev": true }, "node_modules/color-convert": { - "version": "1.9.3", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-1.9.3.tgz", - "integrity": "sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg==", + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", "dev": true, + "license": "MIT", "dependencies": { - "color-name": "1.1.3" + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" } }, "node_modules/color-name": { - "version": "1.1.3", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.3.tgz", - "integrity": "sha512-72fSenhMw2HZMTVHeCA9KCmpEIbzWiQsjN+BHcBbS9vr1mtt+vJjPdksIBNUmKAW8TFUDPJK5SUU3QhE9NEXDw==", - "dev": true + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", + "dev": true, + "license": "MIT" }, "node_modules/commander": { "version": "13.1.0", @@ -4180,6 +4134,20 @@ "node": ">=0.10.0" } }, + "node_modules/cssstyle": { + "version": "4.6.0", + "resolved": "https://registry.npmjs.org/cssstyle/-/cssstyle-4.6.0.tgz", + "integrity": "sha512-2z+rWdzbbSZv6/rhtvzvqeZQHrBaqgogqt85sqFNbabZOuFbCVFb8kPeEtZjiKkbrm395irpNKiYeFeLiQnFPg==", + "dev": true, + "license": "MIT", + "dependencies": { + "@asamuzakjp/css-color": "^3.2.0", + "rrweb-cssom": "^0.8.0" + }, + "engines": { + "node": ">=18" + } + }, "node_modules/cwise-compiler": { "version": "1.1.3", "resolved": "https://registry.npmjs.org/cwise-compiler/-/cwise-compiler-1.1.3.tgz", @@ -4189,6 +4157,20 @@ "uniq": "^1.0.0" } }, + "node_modules/data-urls": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/data-urls/-/data-urls-5.0.0.tgz", + "integrity": "sha512-ZYP5VBHshaDAiVZxjbRVcFJpc+4xGgT0bK3vzy1HLN8jTO975HEbuYzZJcHoQEY5K1a0z8YayJkyVETa08eNTg==", + "dev": true, + "license": "MIT", + "dependencies": { + "whatwg-mimetype": "^4.0.0", + "whatwg-url": "^14.0.0" + }, + "engines": { + "node": ">=18" + } + }, "node_modules/debug": { "version": "4.3.4", "resolved": "https://registry.npmjs.org/debug/-/debug-4.3.4.tgz", @@ -4206,8 +4188,15 @@ } } }, - "node_modules/decode-uri-component": { - "version": "0.2.2", + "node_modules/decimal.js": { + "version": "10.6.0", + "resolved": "https://registry.npmjs.org/decimal.js/-/decimal.js-10.6.0.tgz", + "integrity": "sha512-YpgQiITW3JXGntzdUmyUR1V812Hn8T1YVXhCu+wO3OpS4eU9l4YdD3qjyiKdV6mvV29zapkMeD390UVEf2lkUg==", + "dev": true, + "license": "MIT" + }, + "node_modules/decode-uri-component": { + "version": "0.2.2", "resolved": "https://registry.npmjs.org/decode-uri-component/-/decode-uri-component-0.2.2.tgz", "integrity": "sha512-FqUYQ+8o158GyGTrMFJms9qh3CqTKvAqgqsTnkLI8sKu0028orqBhxNMFkFen0zGyg6epACD32pjVk58ngIErQ==", "dev": true, @@ -4341,6 +4330,19 @@ "once": "^1.4.0" } }, + "node_modules/entities": { + "version": "6.0.1", + "resolved": "https://registry.npmjs.org/entities/-/entities-6.0.1.tgz", + "integrity": "sha512-aN97NXWF6AWBTahfVOIrB/NShkzi5H7F9r1s9mD3cDj4Ko5f2qhhVoYMibXF7GlLveb/D2ioWay8lxI97Ven3g==", + "dev": true, + "license": "BSD-2-Clause", + "engines": { + "node": ">=0.12" + }, + "funding": { + "url": "https://github.com/fb55/entities?sponsor=1" + } + }, "node_modules/error-ex": { "version": "1.3.2", "resolved": "https://registry.npmjs.org/error-ex/-/error-ex-1.3.2.tgz", @@ -4383,15 +4385,6 @@ "node": ">=6" } }, - "node_modules/escape-string-regexp": { - "version": "1.0.5", - "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz", - "integrity": "sha512-vbRorB5FUQWvla16U8R/qgaFIya2qGzwDrNmCZuYKrbdSUMG6I1ZCGQRefkRVhuOkIGVne7BQ35DSfo1qvJqFg==", - "dev": true, - "engines": { - "node": ">=0.8.0" - } - }, "node_modules/esprima": { "version": "4.0.1", "resolved": "https://registry.npmjs.org/esprima/-/esprima-4.0.1.tgz", @@ -4694,10 +4687,11 @@ } }, "node_modules/graceful-fs": { - "version": "4.2.10", - "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.10.tgz", - "integrity": "sha512-9ByhssR2fPVsNZj478qUUbKfmL0+t5BDVyjShtyZZLiK7ZDAArFFfopyOTj0M05wE2tJPisA4iTnnXl2YoPvOA==", - "dev": true + "version": "4.2.11", + "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.11.tgz", + "integrity": "sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ==", + "dev": true, + "license": "ISC" }, "node_modules/has": { "version": "1.0.3", @@ -4712,12 +4706,26 @@ } }, "node_modules/has-flag": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-3.0.0.tgz", - "integrity": "sha512-sKJf1+ceQBr4SMkvQnBDNDtf4TXpVhVGateu0t918bl30FnbE2m4vNLX+VWe/dpjlb+HugGYzW7uQXH98HPEYw==", + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", "dev": true, + "license": "MIT", "engines": { - "node": ">=4" + "node": ">=8" + } + }, + "node_modules/html-encoding-sniffer": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/html-encoding-sniffer/-/html-encoding-sniffer-4.0.0.tgz", + "integrity": "sha512-Y22oTqIU4uuPgEemfz7NDJz6OeKf12Lsu+QC+s3BVpda64lTiMYCyGwg5ki4vFxkMwQdeZDl2adZoqUgdFuTgQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "whatwg-encoding": "^3.1.1" + }, + "engines": { + "node": ">=18" } }, "node_modules/html-escaper": { @@ -4726,6 +4734,34 @@ "integrity": "sha512-H2iMtd0I4Mt5eYiapRdIDjp+XzelXQ0tFE4JS7YFwFevXXMmOp9myNrUvCg0D6ws8iqkRPBfKHgbwig1SmlLfg==", "dev": true }, + "node_modules/http-proxy-agent": { + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/http-proxy-agent/-/http-proxy-agent-7.0.2.tgz", + "integrity": "sha512-T1gkAiYYDWYx3V5Bmyu7HcfcvL7mUrTWiM6yOfa3PIphViJ/gFPbvidQ+veqSOHci/PxBcDabeUNCzpOODJZig==", + "dev": true, + "license": "MIT", + "dependencies": { + "agent-base": "^7.1.0", + "debug": "^4.3.4" + }, + "engines": { + "node": ">= 14" + } + }, + "node_modules/https-proxy-agent": { + "version": "7.0.6", + "resolved": "https://registry.npmjs.org/https-proxy-agent/-/https-proxy-agent-7.0.6.tgz", + "integrity": "sha512-vK9P5/iUfdl95AI+JVyUuIcVtd4ofvtrOr3HNtM2yxC9bnMbEdp3x01OhQNnjb8IJYi38VlTE3mBXwcfvywuSw==", + "dev": true, + "license": "MIT", + "dependencies": { + "agent-base": "^7.1.2", + "debug": "4" + }, + "engines": { + "node": ">= 14" + } + }, "node_modules/human-signals": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/human-signals/-/human-signals-2.1.0.tgz", @@ -4735,6 +4771,19 @@ "node": ">=10.17.0" } }, + "node_modules/iconv-lite": { + "version": "0.6.3", + "resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.6.3.tgz", + "integrity": "sha512-4fCk79wshMdzMp2rH06qWrJE4iolqLhCUH+OiuIgU++RB0+94NlDL81atO7GX55uUKueo0txHNtvEyI6D7WdMw==", + "dev": true, + "license": "MIT", + "dependencies": { + "safer-buffer": ">= 2.1.2 < 3.0.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, "node_modules/ieee754": { "version": "1.2.1", "resolved": "https://registry.npmjs.org/ieee754/-/ieee754-1.2.1.tgz", @@ -4938,6 +4987,13 @@ "node": ">=0.12.0" } }, + "node_modules/is-potential-custom-element-name": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/is-potential-custom-element-name/-/is-potential-custom-element-name-1.0.1.tgz", + "integrity": "sha512-bCYeRA2rVibKZd+s2625gGnGF/t7DSqDs4dP7CrLA1m7jKWz6pps0LpYLJN8Q64HtmPKJ1hrN3nzPNKFEKOUiQ==", + "dev": true, + "license": "MIT" + }, "node_modules/is-stream": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/is-stream/-/is-stream-2.0.1.tgz", @@ -5007,27 +5063,6 @@ "node": ">=8" } }, - "node_modules/istanbul-lib-report/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/istanbul-lib-report/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, "node_modules/istanbul-lib-source-maps": { "version": "4.0.1", "resolved": "https://registry.npmjs.org/istanbul-lib-source-maps/-/istanbul-lib-source-maps-4.0.1.tgz", @@ -5133,76 +5168,6 @@ "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, - "node_modules/jest-circus/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/jest-circus/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" - } - }, - "node_modules/jest-circus/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/jest-circus/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "node_modules/jest-circus/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/jest-circus/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, "node_modules/jest-cli": { "version": "29.4.3", "resolved": "https://registry.npmjs.org/jest-cli/-/jest-cli-29.4.3.tgz", @@ -5237,76 +5202,6 @@ } } }, - "node_modules/jest-cli/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/jest-cli/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" - } - }, - "node_modules/jest-cli/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/jest-cli/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "node_modules/jest-cli/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/jest-cli/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, "node_modules/jest-config": { "version": "29.4.3", "resolved": "https://registry.npmjs.org/jest-config/-/jest-config-29.4.3.tgz", @@ -5352,21 +5247,6 @@ } } }, - "node_modules/jest-config/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, "node_modules/jest-config/node_modules/babel-jest": { "version": "29.4.3", "resolved": "https://registry.npmjs.org/babel-jest/-/babel-jest-29.4.3.tgz", @@ -5388,242 +5268,276 @@ "@babel/core": "^7.8.0" } }, - "node_modules/jest-config/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "node_modules/jest-diff": { + "version": "29.4.3", + "resolved": "https://registry.npmjs.org/jest-diff/-/jest-diff-29.4.3.tgz", + "integrity": "sha512-YB+ocenx7FZ3T5O9lMVMeLYV4265socJKtkwgk/6YUz/VsEzYDkiMuMhWzZmxm3wDRQvayJu/PjkjjSkjoHsCA==", "dev": true, "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" + "chalk": "^4.0.0", + "diff-sequences": "^29.4.3", + "jest-get-type": "^29.4.3", + "pretty-format": "^29.4.3" }, "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, - "node_modules/jest-config/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "node_modules/jest-docblock": { + "version": "29.4.3", + "resolved": "https://registry.npmjs.org/jest-docblock/-/jest-docblock-29.4.3.tgz", + "integrity": "sha512-fzdTftThczeSD9nZ3fzA/4KkHtnmllawWrXO69vtI+L9WjEIuXWs4AmyME7lN5hU7dB0sHhuPfcKofRsUb/2Fg==", "dev": true, "dependencies": { - "color-name": "~1.1.4" + "detect-newline": "^3.0.0" }, "engines": { - "node": ">=7.0.0" + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, - "node_modules/jest-config/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "node_modules/jest-config/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/jest-config/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/jest-diff": { + "node_modules/jest-each": { "version": "29.4.3", - "resolved": "https://registry.npmjs.org/jest-diff/-/jest-diff-29.4.3.tgz", - "integrity": "sha512-YB+ocenx7FZ3T5O9lMVMeLYV4265socJKtkwgk/6YUz/VsEzYDkiMuMhWzZmxm3wDRQvayJu/PjkjjSkjoHsCA==", + "resolved": "https://registry.npmjs.org/jest-each/-/jest-each-29.4.3.tgz", + "integrity": "sha512-1ElHNAnKcbJb/b+L+7j0/w7bDvljw4gTv1wL9fYOczeJrbTbkMGQ5iQPFJ3eFQH19VPTx1IyfePdqSpePKss7Q==", "dev": true, "dependencies": { + "@jest/types": "^29.4.3", "chalk": "^4.0.0", - "diff-sequences": "^29.4.3", "jest-get-type": "^29.4.3", + "jest-util": "^29.4.3", "pretty-format": "^29.4.3" }, "engines": { "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, - "node_modules/jest-diff/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "node_modules/jest-environment-jsdom": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-environment-jsdom/-/jest-environment-jsdom-30.2.0.tgz", + "integrity": "sha512-zbBTiqr2Vl78pKp/laGBREYzbZx9ZtqPjOK4++lL4BNDhxRnahg51HtoDrk9/VjIy9IthNEWdKVd7H5bqBhiWQ==", "dev": true, + "license": "MIT", "dependencies": { - "color-convert": "^2.0.1" + "@jest/environment": "30.2.0", + "@jest/environment-jsdom-abstract": "30.2.0", + "@types/jsdom": "^21.1.7", + "@types/node": "*", + "jsdom": "^26.1.0" }, "engines": { - "node": ">=8" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" + "peerDependencies": { + "canvas": "^3.0.0" + }, + "peerDependenciesMeta": { + "canvas": { + "optional": true + } } }, - "node_modules/jest-diff/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "node_modules/jest-environment-jsdom/node_modules/@jest/environment": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/environment/-/environment-30.2.0.tgz", + "integrity": "sha512-/QPTL7OBJQ5ac09UDRa3EQes4gt1FTEG/8jZ/4v5IVzx+Cv7dLxlVIvfvSVRiiX2drWyXeBjkMSR8hvOWSog5g==", "dev": true, + "license": "MIT", "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" + "@jest/fake-timers": "30.2.0", + "@jest/types": "30.2.0", + "@types/node": "*", + "jest-mock": "30.2.0" }, "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/jest-diff/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "node_modules/jest-environment-jsdom/node_modules/@jest/fake-timers": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/fake-timers/-/fake-timers-30.2.0.tgz", + "integrity": "sha512-HI3tRLjRxAbBy0VO8dqqm7Hb2mIa8d5bg/NJkyQcOk7V118ObQML8RC5luTF/Zsg4474a+gDvhce7eTnP4GhYw==", "dev": true, + "license": "MIT", "dependencies": { - "color-name": "~1.1.4" + "@jest/types": "30.2.0", + "@sinonjs/fake-timers": "^13.0.0", + "@types/node": "*", + "jest-message-util": "30.2.0", + "jest-mock": "30.2.0", + "jest-util": "30.2.0" }, "engines": { - "node": ">=7.0.0" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/jest-diff/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "node_modules/jest-diff/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "node_modules/jest-environment-jsdom/node_modules/@jest/schemas": { + "version": "30.0.5", + "resolved": "https://registry.npmjs.org/@jest/schemas/-/schemas-30.0.5.tgz", + "integrity": "sha512-DmdYgtezMkh3cpU8/1uyXakv3tJRcmcXxBOcO0tbaozPwpmh4YMsnWrQm9ZmZMfa5ocbxzbFk6O4bDPEc/iAnA==", "dev": true, + "license": "MIT", + "dependencies": { + "@sinclair/typebox": "^0.34.0" + }, "engines": { - "node": ">=8" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/jest-diff/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "node_modules/jest-environment-jsdom/node_modules/@jest/types": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/types/-/types-30.2.0.tgz", + "integrity": "sha512-H9xg1/sfVvyfU7o3zMfBEjQ1gcsdeTMgqHoYdN79tuLqfTtuu7WckRA1R5whDwOzxaZAeMKTYWqP+WCAi0CHsg==", "dev": true, + "license": "MIT", "dependencies": { - "has-flag": "^4.0.0" + "@jest/pattern": "30.0.1", + "@jest/schemas": "30.0.5", + "@types/istanbul-lib-coverage": "^2.0.6", + "@types/istanbul-reports": "^3.0.4", + "@types/node": "*", + "@types/yargs": "^17.0.33", + "chalk": "^4.1.2" }, "engines": { - "node": ">=8" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/jest-docblock": { - "version": "29.4.3", - "resolved": "https://registry.npmjs.org/jest-docblock/-/jest-docblock-29.4.3.tgz", - "integrity": "sha512-fzdTftThczeSD9nZ3fzA/4KkHtnmllawWrXO69vtI+L9WjEIuXWs4AmyME7lN5hU7dB0sHhuPfcKofRsUb/2Fg==", + "node_modules/jest-environment-jsdom/node_modules/@sinclair/typebox": { + "version": "0.34.47", + "resolved": "https://registry.npmjs.org/@sinclair/typebox/-/typebox-0.34.47.tgz", + "integrity": "sha512-ZGIBQ+XDvO5JQku9wmwtabcVTHJsgSWAHYtVuM9pBNNR5E88v6Jcj/llpmsjivig5X8A8HHOb4/mbEKPS5EvAw==", + "dev": true, + "license": "MIT" + }, + "node_modules/jest-environment-jsdom/node_modules/@sinonjs/commons": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/@sinonjs/commons/-/commons-3.0.1.tgz", + "integrity": "sha512-K3mCHKQ9sVh8o1C9cxkwxaOmXoAMlDxC1mYyHrjqOWEcBjYr76t96zL2zlj5dUGZ3HSw240X1qgH3Mjf1yJWpQ==", "dev": true, + "license": "BSD-3-Clause", "dependencies": { - "detect-newline": "^3.0.0" - }, - "engines": { - "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + "type-detect": "4.0.8" } }, - "node_modules/jest-each": { - "version": "29.4.3", - "resolved": "https://registry.npmjs.org/jest-each/-/jest-each-29.4.3.tgz", - "integrity": "sha512-1ElHNAnKcbJb/b+L+7j0/w7bDvljw4gTv1wL9fYOczeJrbTbkMGQ5iQPFJ3eFQH19VPTx1IyfePdqSpePKss7Q==", + "node_modules/jest-environment-jsdom/node_modules/@sinonjs/fake-timers": { + "version": "13.0.5", + "resolved": "https://registry.npmjs.org/@sinonjs/fake-timers/-/fake-timers-13.0.5.tgz", + "integrity": "sha512-36/hTbH2uaWuGVERyC6da9YwGWnzUZXuPro/F2LfsdOsLnCojz/iSH8MxUt/FD2S5XBSVPhmArFUXcpCQ2Hkiw==", "dev": true, + "license": "BSD-3-Clause", "dependencies": { - "@jest/types": "^29.4.3", - "chalk": "^4.0.0", - "jest-get-type": "^29.4.3", - "jest-util": "^29.4.3", - "pretty-format": "^29.4.3" - }, - "engines": { - "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + "@sinonjs/commons": "^3.0.1" } }, - "node_modules/jest-each/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "node_modules/jest-environment-jsdom/node_modules/ansi-styles": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-5.2.0.tgz", + "integrity": "sha512-Cxwpt2SfTzTtXcfOlzGEee8O+c+MmUgGrNiBcXnuWxuFJHe6a5Hz7qwhwe5OgaSYI0IJvkLqWX1ASG+cJOkEiA==", "dev": true, - "dependencies": { - "color-convert": "^2.0.1" - }, + "license": "MIT", "engines": { - "node": ">=8" + "node": ">=10" }, "funding": { "url": "https://github.com/chalk/ansi-styles?sponsor=1" } }, - "node_modules/jest-each/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "node_modules/jest-environment-jsdom/node_modules/ci-info": { + "version": "4.3.1", + "resolved": "https://registry.npmjs.org/ci-info/-/ci-info-4.3.1.tgz", + "integrity": "sha512-Wdy2Igu8OcBpI2pZePZ5oWjPC38tmDVx5WKUXKwlLYkA0ozo85sLsLvkBbBn/sZaSCMFOGZJ14fvW9t5/d7kdA==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/sibiraj-s" + } + ], + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "node_modules/jest-environment-jsdom/node_modules/jest-message-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-message-util/-/jest-message-util-30.2.0.tgz", + "integrity": "sha512-y4DKFLZ2y6DxTWD4cDe07RglV88ZiNEdlRfGtqahfbIjfsw1nMCPx49Uev4IA/hWn3sDKyAnSPwoYSsAEdcimw==", "dev": true, + "license": "MIT", "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" + "@babel/code-frame": "^7.27.1", + "@jest/types": "30.2.0", + "@types/stack-utils": "^2.0.3", + "chalk": "^4.1.2", + "graceful-fs": "^4.2.11", + "micromatch": "^4.0.8", + "pretty-format": "30.2.0", + "slash": "^3.0.0", + "stack-utils": "^2.0.6" }, "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/jest-each/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "node_modules/jest-environment-jsdom/node_modules/jest-mock": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-mock/-/jest-mock-30.2.0.tgz", + "integrity": "sha512-JNNNl2rj4b5ICpmAcq+WbLH83XswjPbjH4T7yvGzfAGCPh1rw+xVNbtk+FnRslvt9lkCcdn9i1oAoKUuFsOxRw==", "dev": true, + "license": "MIT", "dependencies": { - "color-name": "~1.1.4" + "@jest/types": "30.2.0", + "@types/node": "*", + "jest-util": "30.2.0" }, "engines": { - "node": ">=7.0.0" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/jest-each/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true + "node_modules/jest-environment-jsdom/node_modules/jest-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-30.2.0.tgz", + "integrity": "sha512-QKNsM0o3Xe6ISQU869e+DhG+4CK/48aHYdJZGlFQVTjnbvgpcKyxpzk29fGiO7i/J8VENZ+d2iGnSsvmuHywlA==", + "dev": true, + "license": "MIT", + "dependencies": { + "@jest/types": "30.2.0", + "@types/node": "*", + "chalk": "^4.1.2", + "ci-info": "^4.2.0", + "graceful-fs": "^4.2.11", + "picomatch": "^4.0.2" + }, + "engines": { + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" + } }, - "node_modules/jest-each/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "node_modules/jest-environment-jsdom/node_modules/picomatch": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.3.tgz", + "integrity": "sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==", "dev": true, + "license": "MIT", "engines": { - "node": ">=8" + "node": ">=12" + }, + "funding": { + "url": "https://github.com/sponsors/jonschlinkert" } }, - "node_modules/jest-each/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "node_modules/jest-environment-jsdom/node_modules/pretty-format": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/pretty-format/-/pretty-format-30.2.0.tgz", + "integrity": "sha512-9uBdv/B4EefsuAL+pWqueZyZS2Ba+LxfFeQ9DN14HU4bN8bhaxKdkpjpB6fs9+pSjIBu+FXQHImEg8j/Lw0+vA==", "dev": true, + "license": "MIT", "dependencies": { - "has-flag": "^4.0.0" + "@jest/schemas": "30.0.5", + "ansi-styles": "^5.2.0", + "react-is": "^18.3.1" }, "engines": { - "node": ">=8" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, "node_modules/jest-environment-node": { @@ -5716,76 +5630,6 @@ "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, - "node_modules/jest-matcher-utils/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/jest-matcher-utils/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" - } - }, - "node_modules/jest-matcher-utils/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/jest-matcher-utils/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "node_modules/jest-matcher-utils/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/jest-matcher-utils/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, "node_modules/jest-message-util": { "version": "29.4.3", "resolved": "https://registry.npmjs.org/jest-message-util/-/jest-message-util-29.4.3.tgz", @@ -5806,88 +5650,18 @@ "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, - "node_modules/jest-message-util/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "node_modules/jest-mock": { + "version": "29.4.3", + "resolved": "https://registry.npmjs.org/jest-mock/-/jest-mock-29.4.3.tgz", + "integrity": "sha512-LjFgMg+xed9BdkPMyIJh+r3KeHt1klXPJYBULXVVAkbTaaKjPX1o1uVCAZADMEp/kOxGTwy/Ot8XbvgItOrHEg==", "dev": true, "dependencies": { - "color-convert": "^2.0.1" + "@jest/types": "^29.4.3", + "@types/node": "*", + "jest-util": "^29.4.3" }, "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/jest-message-util/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" - } - }, - "node_modules/jest-message-util/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/jest-message-util/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "node_modules/jest-message-util/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/jest-message-util/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/jest-mock": { - "version": "29.4.3", - "resolved": "https://registry.npmjs.org/jest-mock/-/jest-mock-29.4.3.tgz", - "integrity": "sha512-LjFgMg+xed9BdkPMyIJh+r3KeHt1klXPJYBULXVVAkbTaaKjPX1o1uVCAZADMEp/kOxGTwy/Ot8XbvgItOrHEg==", - "dev": true, - "dependencies": { - "@jest/types": "^29.4.3", - "@types/node": "*", - "jest-util": "^29.4.3" - }, - "engines": { - "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, "node_modules/jest-pnp-resolver": { @@ -5949,64 +5723,6 @@ "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, - "node_modules/jest-resolve/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/jest-resolve/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" - } - }, - "node_modules/jest-resolve/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/jest-resolve/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "node_modules/jest-resolve/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true, - "engines": { - "node": ">=8" - } - }, "node_modules/jest-resolve/node_modules/resolve": { "version": "1.22.1", "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.22.1.tgz", @@ -6024,18 +5740,6 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/jest-resolve/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, "node_modules/jest-runner": { "version": "29.4.3", "resolved": "https://registry.npmjs.org/jest-runner/-/jest-runner-29.4.3.tgz", @@ -6068,76 +5772,6 @@ "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, - "node_modules/jest-runner/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/jest-runner/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" - } - }, - "node_modules/jest-runner/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/jest-runner/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "node_modules/jest-runner/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/jest-runner/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, "node_modules/jest-runtime": { "version": "29.4.3", "resolved": "https://registry.npmjs.org/jest-runtime/-/jest-runtime-29.4.3.tgz", @@ -6171,76 +5805,6 @@ "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, - "node_modules/jest-runtime/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/jest-runtime/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" - } - }, - "node_modules/jest-runtime/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/jest-runtime/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "node_modules/jest-runtime/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/jest-runtime/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, "node_modules/jest-snapshot": { "version": "29.4.3", "resolved": "https://registry.npmjs.org/jest-snapshot/-/jest-snapshot-29.4.3.tgz", @@ -6276,64 +5840,6 @@ "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, - "node_modules/jest-snapshot/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/jest-snapshot/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" - } - }, - "node_modules/jest-snapshot/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/jest-snapshot/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "node_modules/jest-snapshot/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true, - "engines": { - "node": ">=8" - } - }, "node_modules/jest-snapshot/node_modules/lru-cache": { "version": "6.0.0", "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-6.0.0.tgz", @@ -6343,315 +5849,93 @@ "yallist": "^4.0.0" }, "engines": { - "node": ">=10" - } - }, - "node_modules/jest-snapshot/node_modules/semver": { - "version": "7.3.8", - "resolved": "https://registry.npmjs.org/semver/-/semver-7.3.8.tgz", - "integrity": "sha512-NB1ctGL5rlHrPJtFDVIVzTyQylMLu9N9VICA6HSFJo8MCGVTMW6gfpicwKmmK/dAjTOrqu5l63JJOpDSrAis3A==", - "dev": true, - "dependencies": { - "lru-cache": "^6.0.0" - }, - "bin": { - "semver": "bin/semver.js" - }, - "engines": { - "node": ">=10" - } - }, - "node_modules/jest-snapshot/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/jest-snapshot/node_modules/yallist": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz", - "integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==", - "dev": true - }, - "node_modules/jest-util": { - "version": "29.4.3", - "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-29.4.3.tgz", - "integrity": "sha512-ToSGORAz4SSSoqxDSylWX8JzkOQR7zoBtNRsA7e+1WUX5F8jrOwaNpuh1YfJHJKDHXLHmObv5eOjejUd+/Ws+Q==", - "dev": true, - "dependencies": { - "@jest/types": "^29.4.3", - "@types/node": "*", - "chalk": "^4.0.0", - "ci-info": "^3.2.0", - "graceful-fs": "^4.2.9", - "picomatch": "^2.2.3" - }, - "engines": { - "node": "^14.15.0 || ^16.10.0 || >=18.0.0" - } - }, - "node_modules/jest-util/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/jest-util/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" - } - }, - "node_modules/jest-util/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/jest-util/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "node_modules/jest-util/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/jest-util/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/jest-validate": { - "version": "29.4.3", - "resolved": "https://registry.npmjs.org/jest-validate/-/jest-validate-29.4.3.tgz", - "integrity": "sha512-J3u5v7aPQoXPzaar6GndAVhdQcZr/3osWSgTeKg5v574I9ybX/dTyH0AJFb5XgXIB7faVhf+rS7t4p3lL9qFaw==", - "dev": true, - "dependencies": { - "@jest/types": "^29.4.3", - "camelcase": "^6.2.0", - "chalk": "^4.0.0", - "jest-get-type": "^29.4.3", - "leven": "^3.1.0", - "pretty-format": "^29.4.3" - }, - "engines": { - "node": "^14.15.0 || ^16.10.0 || >=18.0.0" - } - }, - "node_modules/jest-validate/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/jest-validate/node_modules/camelcase": { - "version": "6.3.0", - "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-6.3.0.tgz", - "integrity": "sha512-Gmy6FhYlCY7uOElZUSbxo2UCDH8owEk996gkbrpsgGtrJLM3J7jGxl9Ic7Qwwj4ivOE5AWZWRMecDdF7hqGjFA==", - "dev": true, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/jest-validate/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" - } - }, - "node_modules/jest-validate/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/jest-validate/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "node_modules/jest-validate/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true, - "engines": { - "node": ">=8" + "node": ">=10" } }, - "node_modules/jest-validate/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "node_modules/jest-snapshot/node_modules/semver": { + "version": "7.3.8", + "resolved": "https://registry.npmjs.org/semver/-/semver-7.3.8.tgz", + "integrity": "sha512-NB1ctGL5rlHrPJtFDVIVzTyQylMLu9N9VICA6HSFJo8MCGVTMW6gfpicwKmmK/dAjTOrqu5l63JJOpDSrAis3A==", "dev": true, "dependencies": { - "has-flag": "^4.0.0" + "lru-cache": "^6.0.0" + }, + "bin": { + "semver": "bin/semver.js" }, "engines": { - "node": ">=8" + "node": ">=10" } }, - "node_modules/jest-watcher": { + "node_modules/jest-snapshot/node_modules/yallist": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz", + "integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==", + "dev": true + }, + "node_modules/jest-util": { "version": "29.4.3", - "resolved": "https://registry.npmjs.org/jest-watcher/-/jest-watcher-29.4.3.tgz", - "integrity": "sha512-zwlXH3DN3iksoIZNk73etl1HzKyi5FuQdYLnkQKm5BW4n8HpoG59xSwpVdFrnh60iRRaRBGw0gcymIxjJENPcA==", + "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-29.4.3.tgz", + "integrity": "sha512-ToSGORAz4SSSoqxDSylWX8JzkOQR7zoBtNRsA7e+1WUX5F8jrOwaNpuh1YfJHJKDHXLHmObv5eOjejUd+/Ws+Q==", "dev": true, "dependencies": { - "@jest/test-result": "^29.4.3", "@jest/types": "^29.4.3", "@types/node": "*", - "ansi-escapes": "^4.2.1", "chalk": "^4.0.0", - "emittery": "^0.13.1", - "jest-util": "^29.4.3", - "string-length": "^4.0.1" + "ci-info": "^3.2.0", + "graceful-fs": "^4.2.9", + "picomatch": "^2.2.3" }, "engines": { "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, - "node_modules/jest-watcher/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "node_modules/jest-validate": { + "version": "29.4.3", + "resolved": "https://registry.npmjs.org/jest-validate/-/jest-validate-29.4.3.tgz", + "integrity": "sha512-J3u5v7aPQoXPzaar6GndAVhdQcZr/3osWSgTeKg5v574I9ybX/dTyH0AJFb5XgXIB7faVhf+rS7t4p3lL9qFaw==", "dev": true, "dependencies": { - "color-convert": "^2.0.1" + "@jest/types": "^29.4.3", + "camelcase": "^6.2.0", + "chalk": "^4.0.0", + "jest-get-type": "^29.4.3", + "leven": "^3.1.0", + "pretty-format": "^29.4.3" }, "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, - "node_modules/jest-watcher/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "node_modules/jest-validate/node_modules/camelcase": { + "version": "6.3.0", + "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-6.3.0.tgz", + "integrity": "sha512-Gmy6FhYlCY7uOElZUSbxo2UCDH8owEk996gkbrpsgGtrJLM3J7jGxl9Ic7Qwwj4ivOE5AWZWRMecDdF7hqGjFA==", "dev": true, - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, "engines": { "node": ">=10" }, "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" - } - }, - "node_modules/jest-watcher/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/jest-watcher/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "node_modules/jest-watcher/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true, - "engines": { - "node": ">=8" + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/jest-watcher/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "node_modules/jest-watcher": { + "version": "29.4.3", + "resolved": "https://registry.npmjs.org/jest-watcher/-/jest-watcher-29.4.3.tgz", + "integrity": "sha512-zwlXH3DN3iksoIZNk73etl1HzKyi5FuQdYLnkQKm5BW4n8HpoG59xSwpVdFrnh60iRRaRBGw0gcymIxjJENPcA==", "dev": true, "dependencies": { - "has-flag": "^4.0.0" + "@jest/test-result": "^29.4.3", + "@jest/types": "^29.4.3", + "@types/node": "*", + "ansi-escapes": "^4.2.1", + "chalk": "^4.0.0", + "emittery": "^0.13.1", + "jest-util": "^29.4.3", + "string-length": "^4.0.1" }, "engines": { - "node": ">=8" + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, "node_modules/jest-worker": { @@ -6669,15 +5953,6 @@ "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, - "node_modules/jest-worker/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true, - "engines": { - "node": ">=8" - } - }, "node_modules/jest-worker/node_modules/supports-color": { "version": "8.1.1", "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-8.1.1.tgz", @@ -6697,7 +5972,8 @@ "version": "4.0.0", "resolved": "https://registry.npmjs.org/js-tokens/-/js-tokens-4.0.0.tgz", "integrity": "sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/js-yaml": { "version": "3.14.1", @@ -6712,6 +5988,46 @@ "js-yaml": "bin/js-yaml.js" } }, + "node_modules/jsdom": { + "version": "26.1.0", + "resolved": "https://registry.npmjs.org/jsdom/-/jsdom-26.1.0.tgz", + "integrity": "sha512-Cvc9WUhxSMEo4McES3P7oK3QaXldCfNWp7pl2NNeiIFlCoLr3kfq9kb1fxftiwk1FLV7CvpvDfonxtzUDeSOPg==", + "dev": true, + "license": "MIT", + "dependencies": { + "cssstyle": "^4.2.1", + "data-urls": "^5.0.0", + "decimal.js": "^10.5.0", + "html-encoding-sniffer": "^4.0.0", + "http-proxy-agent": "^7.0.2", + "https-proxy-agent": "^7.0.6", + "is-potential-custom-element-name": "^1.0.1", + "nwsapi": "^2.2.16", + "parse5": "^7.2.1", + "rrweb-cssom": "^0.8.0", + "saxes": "^6.0.0", + "symbol-tree": "^3.2.4", + "tough-cookie": "^5.1.1", + "w3c-xmlserializer": "^5.0.0", + "webidl-conversions": "^7.0.0", + "whatwg-encoding": "^3.1.1", + "whatwg-mimetype": "^4.0.0", + "whatwg-url": "^14.1.1", + "ws": "^8.18.0", + "xml-name-validator": "^5.0.0" + }, + "engines": { + "node": ">=18" + }, + "peerDependencies": { + "canvas": "^3.0.0" + }, + "peerDependenciesMeta": { + "canvas": { + "optional": true + } + } + }, "node_modules/jsep": { "version": "1.3.9", "resolved": "https://registry.npmjs.org/jsep/-/jsep-1.3.9.tgz", @@ -7146,6 +6462,13 @@ "node": ">=8" } }, + "node_modules/nwsapi": { + "version": "2.2.23", + "resolved": "https://registry.npmjs.org/nwsapi/-/nwsapi-2.2.23.tgz", + "integrity": "sha512-7wfH4sLbt4M0gCDzGE6vzQBo0bfTKjU7Sfpqy/7gs1qBfYz2vEJH6vXcBKpO3+6Yu1telwd0t9HpyOoLEQQbIQ==", + "dev": true, + "license": "MIT" + }, "node_modules/once": { "version": "1.4.0", "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", @@ -7275,6 +6598,19 @@ "url": "https://github.com/sponsors/sindresorhus" } }, + "node_modules/parse5": { + "version": "7.3.0", + "resolved": "https://registry.npmjs.org/parse5/-/parse5-7.3.0.tgz", + "integrity": "sha512-IInvU7fabl34qmi9gY8XOVxhYyMyuH2xUNpb2q8/Y+7552KlejkRvqvD19nMoUW/uQGGbqNpA6Tufu5FL5BZgw==", + "dev": true, + "license": "MIT", + "dependencies": { + "entities": "^6.0.0" + }, + "funding": { + "url": "https://github.com/inikulin/parse5?sponsor=1" + } + }, "node_modules/path-exists": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-4.0.0.tgz", @@ -7309,10 +6645,11 @@ "dev": true }, "node_modules/picocolors": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.0.0.tgz", - "integrity": "sha512-1fygroTLlHu66zi26VoTDv8yRgm0Fccecssto+MhsZ0D/DGW2sm8E8AjW7NU5VVTRt5GxbeZ5qBuJr+HyLYkjQ==", - "dev": true + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.1.1.tgz", + "integrity": "sha512-xceH2snhtb5M9liqDsmEw56le376mTZkEX/jEb/RxNFyegNul7eNslCXP9FDj/Lcu0X8KEyMceP2ntpaHrDEVA==", + "dev": true, + "license": "ISC" }, "node_modules/picomatch": { "version": "2.3.1", @@ -7446,6 +6783,16 @@ "once": "^1.3.1" } }, + "node_modules/punycode": { + "version": "2.3.1", + "resolved": "https://registry.npmjs.org/punycode/-/punycode-2.3.1.tgz", + "integrity": "sha512-vYt7UD1U9Wg6138shLtLOvdAu+8DsC/ilFtEVHcH+wydcSpNE20AfSOduf6MkRFahL5FY7X1oU7nKVZFtfq8Fg==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=6" + } + }, "node_modules/queue-microtask": { "version": "1.2.3", "resolved": "https://registry.npmjs.org/queue-microtask/-/queue-microtask-1.2.3.tgz", @@ -7494,10 +6841,11 @@ } }, "node_modules/react-is": { - "version": "18.2.0", - "resolved": "https://registry.npmjs.org/react-is/-/react-is-18.2.0.tgz", - "integrity": "sha512-xWGDIW6x921xtzPkhiULtthJHoJvBbF3q26fzloPCK0hsvxtPVelvftw3zjbHWSkR2km9Z+4uxbDDK/6Zw9B8w==", - "dev": true + "version": "18.3.1", + "resolved": "https://registry.npmjs.org/react-is/-/react-is-18.3.1.tgz", + "integrity": "sha512-/LLMVyas0ljjAtoYiPqYiL8VWXzUUdThrmU5+n20DZv+a+ClRoevUzw5JxU+Ieh5/c87ytoTBV9G1FiKfNJdmg==", + "dev": true, + "license": "MIT" }, "node_modules/readable-stream": { "version": "3.6.2", @@ -7685,6 +7033,13 @@ "node": ">=0.10.0" } }, + "node_modules/rrweb-cssom": { + "version": "0.8.0", + "resolved": "https://registry.npmjs.org/rrweb-cssom/-/rrweb-cssom-0.8.0.tgz", + "integrity": "sha512-guoltQEx+9aMf2gDZ0s62EcV8lsXR+0w8915TC3ITdn2YueuNjdAYh/levpU9nFaoChh9RUS5ZdQMrKfVEN9tw==", + "dev": true, + "license": "MIT" + }, "node_modules/run-parallel": { "version": "1.2.0", "resolved": "https://registry.npmjs.org/run-parallel/-/run-parallel-1.2.0.tgz", @@ -7739,6 +7094,13 @@ "license": "MIT", "optional": true }, + "node_modules/safer-buffer": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz", + "integrity": "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==", + "dev": true, + "license": "MIT" + }, "node_modules/sass": { "version": "1.57.1", "resolved": "https://registry.npmjs.org/sass/-/sass-1.57.1.tgz", @@ -7762,6 +7124,19 @@ "integrity": "sha512-yqYn1JhPczigF94DMS+shiDMjDowYO6y9+wB/4WgO0Y19jWYk0lQ4tuG5KI7kj4FTp1wxPj5IFfcrz/s1c3jjQ==", "license": "BlueOak-1.0.0" }, + "node_modules/saxes": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/saxes/-/saxes-6.0.0.tgz", + "integrity": "sha512-xAg7SOnEhrm5zI3puOOKyy1OMcMlIJZYNJY7xLBwSze0UjhPLnWfj2GF2EpT0jmzaJKIWKHLsaSSajf35bcYnA==", + "dev": true, + "license": "ISC", + "dependencies": { + "xmlchars": "^2.2.0" + }, + "engines": { + "node": ">=v12.22.7" + } + }, "node_modules/semver": { "version": "6.3.0", "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.0.tgz", @@ -8257,15 +7632,16 @@ } }, "node_modules/supports-color": { - "version": "5.5.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.5.0.tgz", - "integrity": "sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==", + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", "dev": true, + "license": "MIT", "dependencies": { - "has-flag": "^3.0.0" + "has-flag": "^4.0.0" }, "engines": { - "node": ">=4" + "node": ">=8" } }, "node_modules/supports-preserve-symlinks-flag": { @@ -8280,6 +7656,13 @@ "url": "https://github.com/sponsors/ljharb" } }, + "node_modules/symbol-tree": { + "version": "3.2.4", + "resolved": "https://registry.npmjs.org/symbol-tree/-/symbol-tree-3.2.4.tgz", + "integrity": "sha512-9QNk5KwDF+Bvz+PyObkmSYjI5ksVUYtjW7AU22r2NKcfLJcXp96hkDWU3+XndOsUb+AQ9QhfzfCT2O+CNWT5Tw==", + "dev": true, + "license": "MIT" + }, "node_modules/tar-fs": { "version": "2.1.4", "resolved": "https://registry.npmjs.org/tar-fs/-/tar-fs-2.1.4.tgz", @@ -8324,6 +7707,26 @@ "node": ">=8" } }, + "node_modules/tldts": { + "version": "6.1.86", + "resolved": "https://registry.npmjs.org/tldts/-/tldts-6.1.86.tgz", + "integrity": "sha512-WMi/OQ2axVTf/ykqCQgXiIct+mSQDFdH2fkwhPwgEwvJ1kSzZRiinb0zF2Xb8u4+OqPChmyI6MEu4EezNJz+FQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "tldts-core": "^6.1.86" + }, + "bin": { + "tldts": "bin/cli.js" + } + }, + "node_modules/tldts-core": { + "version": "6.1.86", + "resolved": "https://registry.npmjs.org/tldts-core/-/tldts-core-6.1.86.tgz", + "integrity": "sha512-Je6p7pkk+KMzMv2XXKmAE3McmolOQFdxkKw0R8EYNr7sELW46JqnNeTX8ybPiQgvg1ymCoF8LXs5fzFaZvJPTA==", + "dev": true, + "license": "MIT" + }, "node_modules/tmpl": { "version": "1.0.5", "resolved": "https://registry.npmjs.org/tmpl/-/tmpl-1.0.5.tgz", @@ -8352,6 +7755,32 @@ "node": ">=8.0" } }, + "node_modules/tough-cookie": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/tough-cookie/-/tough-cookie-5.1.2.tgz", + "integrity": "sha512-FVDYdxtnj0G6Qm/DhNPSb8Ju59ULcup3tuJxkFb5K8Bv2pUXILbf0xZWU8PX8Ov19OXljbUyveOFwRMwkXzO+A==", + "dev": true, + "license": "BSD-3-Clause", + "dependencies": { + "tldts": "^6.1.32" + }, + "engines": { + "node": ">=16" + } + }, + "node_modules/tr46": { + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/tr46/-/tr46-5.1.1.tgz", + "integrity": "sha512-hdF5ZgjTqgAntKkklYw0R03MG2x/bSzTtkxmIRw/sTNV8YXsCJ1tfLAX23lhxhHJlEf3CRCOCGGWw3vI3GaSPw==", + "dev": true, + "license": "MIT", + "dependencies": { + "punycode": "^2.3.1" + }, + "engines": { + "node": ">=18" + } + }, "node_modules/ts-jest": { "version": "29.0.0", "resolved": "https://registry.npmjs.org/ts-jest/-/ts-jest-29.0.0.tgz", @@ -8649,6 +8078,19 @@ "webworker-threads": "^0.7.12" } }, + "node_modules/w3c-xmlserializer": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/w3c-xmlserializer/-/w3c-xmlserializer-5.0.0.tgz", + "integrity": "sha512-o8qghlI8NZHU1lLPrpi2+Uq7abh4GGPpYANlalzWxyWteJOCsr/P+oPBA49TOLu5FTZO4d3F9MnWJfiMo4BkmA==", + "dev": true, + "license": "MIT", + "dependencies": { + "xml-name-validator": "^5.0.0" + }, + "engines": { + "node": ">=18" + } + }, "node_modules/walker": { "version": "1.0.8", "resolved": "https://registry.npmjs.org/walker/-/walker-1.0.8.tgz", @@ -8658,18 +8100,66 @@ "makeerror": "1.0.12" } }, - "node_modules/webworker-threads": { - "version": "0.7.17", - "resolved": "https://registry.npmjs.org/webworker-threads/-/webworker-threads-0.7.17.tgz", - "integrity": "sha512-Y2w2aXBbDLk9IzTEb9u+MsODC3s4YlGI7g4h0t+1OAwIO8yBI9rQL35ZYlyayiCuWu1dZMH/P7kGU8OwW7YsyA==", - "hasInstallScript": true, - "optional": true, + "node_modules/webidl-conversions": { + "version": "7.0.0", + "resolved": "https://registry.npmjs.org/webidl-conversions/-/webidl-conversions-7.0.0.tgz", + "integrity": "sha512-VwddBukDzu71offAQR975unBIGqfKZpM+8ZX6ySk8nYhVoo5CYaZyzt3YBvYtRtO+aoGlqxPg/B87NGVZ/fu6g==", + "dev": true, + "license": "BSD-2-Clause", + "engines": { + "node": ">=12" + } + }, + "node_modules/webworker-threads": { + "version": "0.7.17", + "resolved": "https://registry.npmjs.org/webworker-threads/-/webworker-threads-0.7.17.tgz", + "integrity": "sha512-Y2w2aXBbDLk9IzTEb9u+MsODC3s4YlGI7g4h0t+1OAwIO8yBI9rQL35ZYlyayiCuWu1dZMH/P7kGU8OwW7YsyA==", + "hasInstallScript": true, + "optional": true, + "dependencies": { + "bindings": "^1.3.0", + "nan": "^2.11.0" + }, + "engines": { + "node": ">= 0.10.16" + } + }, + "node_modules/whatwg-encoding": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/whatwg-encoding/-/whatwg-encoding-3.1.1.tgz", + "integrity": "sha512-6qN4hJdMwfYBtE3YBTTHhoeuUrDBPZmbQaxWAqSALV/MeEnR5z1xd8UKud2RAkFoPkmB+hli1TZSnyi84xz1vQ==", + "deprecated": "Use @exodus/bytes instead for a more spec-conformant and faster implementation", + "dev": true, + "license": "MIT", + "dependencies": { + "iconv-lite": "0.6.3" + }, + "engines": { + "node": ">=18" + } + }, + "node_modules/whatwg-mimetype": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/whatwg-mimetype/-/whatwg-mimetype-4.0.0.tgz", + "integrity": "sha512-QaKxh0eNIi2mE9p2vEdzfagOKHCcj1pJ56EEHGQOVxp8r9/iszLUUV7v89x9O1p/T+NlTM5W7jW6+cz4Fq1YVg==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=18" + } + }, + "node_modules/whatwg-url": { + "version": "14.2.0", + "resolved": "https://registry.npmjs.org/whatwg-url/-/whatwg-url-14.2.0.tgz", + "integrity": "sha512-De72GdQZzNTUBBChsXueQUnPKDkg/5A5zp7pFDuQAj5UFoENpiACU0wlCvzpAGnTkj++ihpKwKyYewn/XNUbKw==", + "dev": true, + "license": "MIT", "dependencies": { - "bindings": "^1.3.0", - "nan": "^2.11.0" + "tr46": "^5.1.0", + "webidl-conversions": "^7.0.0" }, "engines": { - "node": ">= 0.10.16" + "node": ">=18" } }, "node_modules/which": { @@ -8704,39 +8194,6 @@ "url": "https://github.com/chalk/wrap-ansi?sponsor=1" } }, - "node_modules/wrap-ansi/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/wrap-ansi/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/wrap-ansi/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, "node_modules/wrappy": { "version": "1.0.2", "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", @@ -8756,6 +8213,45 @@ "node": "^12.13.0 || ^14.15.0 || >=16.0.0" } }, + "node_modules/ws": { + "version": "8.19.0", + "resolved": "https://registry.npmjs.org/ws/-/ws-8.19.0.tgz", + "integrity": "sha512-blAT2mjOEIi0ZzruJfIhb3nps74PRWTCz1IjglWEEpQl5XS/UNama6u2/rjFkDDouqr4L67ry+1aGIALViWjDg==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=10.0.0" + }, + "peerDependencies": { + "bufferutil": "^4.0.1", + "utf-8-validate": ">=5.0.2" + }, + "peerDependenciesMeta": { + "bufferutil": { + "optional": true + }, + "utf-8-validate": { + "optional": true + } + } + }, + "node_modules/xml-name-validator": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/xml-name-validator/-/xml-name-validator-5.0.0.tgz", + "integrity": "sha512-EvGK8EJ3DhaHfbRlETOWAS5pO9MZITeauHKJyb8wyajUfQUenkIg2MvLDTZ4T/TgIcm3HU0TFBgWWboAZ30UHg==", + "dev": true, + "license": "Apache-2.0", + "engines": { + "node": ">=18" + } + }, + "node_modules/xmlchars": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/xmlchars/-/xmlchars-2.2.0.tgz", + "integrity": "sha512-JZnDKK8B0RCDw84FNdDAIpZK+JuJw+s7Lz8nksI7SIuU3UXJJslUthsi+uWBUYOwPFwW7W7PRLRfUKpxjtjFCw==", + "dev": true, + "license": "MIT" + }, "node_modules/y18n": { "version": "5.0.8", "resolved": "https://registry.npmjs.org/y18n/-/y18n-5.0.8.tgz", @@ -8821,13 +8317,36 @@ } }, "dependencies": { + "@asamuzakjp/css-color": { + "version": "3.2.0", + "resolved": "https://registry.npmjs.org/@asamuzakjp/css-color/-/css-color-3.2.0.tgz", + "integrity": "sha512-K1A6z8tS3XsmCMM86xoWdn7Fkdn9m6RSVtocUrJYIwZnFVkng/PvkEoWtOWmP+Scc6saYWHWZYbndEEXxl24jw==", + "dev": true, + "requires": { + "@csstools/css-calc": "^2.1.3", + "@csstools/css-color-parser": "^3.0.9", + "@csstools/css-parser-algorithms": "^3.0.4", + "@csstools/css-tokenizer": "^3.0.3", + "lru-cache": "^10.4.3" + }, + "dependencies": { + "lru-cache": { + "version": "10.4.3", + "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-10.4.3.tgz", + "integrity": "sha512-JNAzZcXrCt42VGLuYz0zfAzDfAvJWW6AfYlDBQyDV5DClI2m5sAmK+OIO7s59XfsRsWHp02jAJrRadPRGTt6SQ==", + "dev": true + } + } + }, "@babel/code-frame": { - "version": "7.18.6", - "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.18.6.tgz", - "integrity": "sha512-TDCmlK5eOvH+eH7cdAFlNXeVJqWIQ7gW9tY1GJIpUtFb6CmjVyq2VM3u71bOyR8CRihcCgMUYoDNyLXao3+70Q==", + "version": "7.28.6", + "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.28.6.tgz", + "integrity": "sha512-JYgintcMjRiCvS8mMECzaEn+m3PfoQiyqukOMCCVQtoJGYJw8j/8LBJEiqkHLkfwCcs74E3pbAUFNg7d9VNJ+Q==", "dev": true, "requires": { - "@babel/highlight": "^7.18.6" + "@babel/helper-validator-identifier": "^7.28.5", + "js-tokens": "^4.0.0", + "picocolors": "^1.1.1" } }, "@babel/compat-data": { @@ -9088,9 +8607,9 @@ "dev": true }, "@babel/helper-validator-identifier": { - "version": "7.19.1", - "resolved": "https://registry.npmjs.org/@babel/helper-validator-identifier/-/helper-validator-identifier-7.19.1.tgz", - "integrity": "sha512-awrNfaMtnHUr653GgGEs++LlAvW6w+DcPrOliSMXWCKo597CwL5Acf/wWdNkf/tfEQE3mjkeD1YOVZOUV/od1w==", + "version": "7.28.5", + "resolved": "https://registry.npmjs.org/@babel/helper-validator-identifier/-/helper-validator-identifier-7.28.5.tgz", + "integrity": "sha512-qSs4ifwzKJSV39ucNjsvc6WVHs6b7S03sOh2OcHF9UHfVPqWWALUsNUVzhSBiItjRZoLHx7nIarVjqKVusUZ1Q==", "dev": true }, "@babel/helper-validator-option": { @@ -9122,17 +8641,6 @@ "@babel/types": "^7.21.0" } }, - "@babel/highlight": { - "version": "7.18.6", - "resolved": "https://registry.npmjs.org/@babel/highlight/-/highlight-7.18.6.tgz", - "integrity": "sha512-u7stbOuYjaPezCuLj29hNW1v64M2Md2qupEKP1fHc7WdOA3DgLh37suiSrZYY7haUB7iBeQZ9P1uiRF359do3g==", - "dev": true, - "requires": { - "@babel/helper-validator-identifier": "^7.18.6", - "chalk": "^2.0.0", - "js-tokens": "^4.0.0" - } - }, "@babel/parser": { "version": "7.21.2", "resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.21.2.tgz", @@ -10080,6 +9588,42 @@ } } }, + "@csstools/color-helpers": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/@csstools/color-helpers/-/color-helpers-5.1.0.tgz", + "integrity": "sha512-S11EXWJyy0Mz5SYvRmY8nJYTFFd1LCNV+7cXyAgQtOOuzb4EsgfqDufL+9esx72/eLhsRdGZwaldu/h+E4t4BA==", + "dev": true + }, + "@csstools/css-calc": { + "version": "2.1.4", + "resolved": "https://registry.npmjs.org/@csstools/css-calc/-/css-calc-2.1.4.tgz", + "integrity": "sha512-3N8oaj+0juUw/1H3YwmDDJXCgTB1gKU6Hc/bB502u9zR0q2vd786XJH9QfrKIEgFlZmhZiq6epXl4rHqhzsIgQ==", + "dev": true, + "requires": {} + }, + "@csstools/css-color-parser": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/@csstools/css-color-parser/-/css-color-parser-3.1.0.tgz", + "integrity": "sha512-nbtKwh3a6xNVIp/VRuXV64yTKnb1IjTAEEh3irzS+HkKjAOYLTGNb9pmVNntZ8iVBHcWDA2Dof0QtPgFI1BaTA==", + "dev": true, + "requires": { + "@csstools/color-helpers": "^5.1.0", + "@csstools/css-calc": "^2.1.4" + } + }, + "@csstools/css-parser-algorithms": { + "version": "3.0.5", + "resolved": "https://registry.npmjs.org/@csstools/css-parser-algorithms/-/css-parser-algorithms-3.0.5.tgz", + "integrity": "sha512-DaDeUkXZKjdGhgYaHNJTV9pV7Y9B3b644jCLs9Upc3VeNGg6LWARAT6O+Q+/COo+2gg/bM5rhpMAtf70WqfBdQ==", + "dev": true, + "requires": {} + }, + "@csstools/css-tokenizer": { + "version": "3.0.4", + "resolved": "https://registry.npmjs.org/@csstools/css-tokenizer/-/css-tokenizer-3.0.4.tgz", + "integrity": "sha512-Vd/9EVDiu6PPJt9yAh6roZP6El1xHrdvIVGjyBsHR0RYwNHgL7FJPyIIW4fANJNG6FtyZfvlRPpFI4ZM/lubvw==", + "dev": true + }, "@emnapi/runtime": { "version": "1.8.1", "resolved": "https://registry.npmjs.org/@emnapi/runtime/-/runtime-1.8.1.tgz", @@ -10332,57 +9876,6 @@ "jest-message-util": "^29.4.3", "jest-util": "^29.4.3", "slash": "^3.0.0" - }, - "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, - "chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - } - }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true - }, - "supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "requires": { - "has-flag": "^4.0.0" - } - } } }, "@jest/core": { @@ -10419,71 +9912,184 @@ "pretty-format": "^29.4.3", "slash": "^3.0.0", "strip-ansi": "^6.0.0" + } + }, + "@jest/environment": { + "version": "29.4.3", + "resolved": "https://registry.npmjs.org/@jest/environment/-/environment-29.4.3.tgz", + "integrity": "sha512-dq5S6408IxIa+lr54zeqce+QgI+CJT4nmmA+1yzFgtcsGK8c/EyiUb9XQOgz3BMKrRDfKseeOaxj2eO8LlD3lA==", + "dev": true, + "requires": { + "@jest/fake-timers": "^29.4.3", + "@jest/types": "^29.4.3", + "@types/node": "*", + "jest-mock": "^29.4.3" + } + }, + "@jest/environment-jsdom-abstract": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/environment-jsdom-abstract/-/environment-jsdom-abstract-30.2.0.tgz", + "integrity": "sha512-kazxw2L9IPuZpQ0mEt9lu9Z98SqR74xcagANmMBU16X0lS23yPc0+S6hGLUz8kVRlomZEs/5S/Zlpqwf5yu6OQ==", + "dev": true, + "requires": { + "@jest/environment": "30.2.0", + "@jest/fake-timers": "30.2.0", + "@jest/types": "30.2.0", + "@types/jsdom": "^21.1.7", + "@types/node": "*", + "jest-mock": "30.2.0", + "jest-util": "30.2.0" }, "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "@jest/environment": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/environment/-/environment-30.2.0.tgz", + "integrity": "sha512-/QPTL7OBJQ5ac09UDRa3EQes4gt1FTEG/8jZ/4v5IVzx+Cv7dLxlVIvfvSVRiiX2drWyXeBjkMSR8hvOWSog5g==", "dev": true, "requires": { - "color-convert": "^2.0.1" + "@jest/fake-timers": "30.2.0", + "@jest/types": "30.2.0", + "@types/node": "*", + "jest-mock": "30.2.0" } }, - "chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "@jest/fake-timers": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/fake-timers/-/fake-timers-30.2.0.tgz", + "integrity": "sha512-HI3tRLjRxAbBy0VO8dqqm7Hb2mIa8d5bg/NJkyQcOk7V118ObQML8RC5luTF/Zsg4474a+gDvhce7eTnP4GhYw==", "dev": true, "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" + "@jest/types": "30.2.0", + "@sinonjs/fake-timers": "^13.0.0", + "@types/node": "*", + "jest-message-util": "30.2.0", + "jest-mock": "30.2.0", + "jest-util": "30.2.0" } }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "@jest/schemas": { + "version": "30.0.5", + "resolved": "https://registry.npmjs.org/@jest/schemas/-/schemas-30.0.5.tgz", + "integrity": "sha512-DmdYgtezMkh3cpU8/1uyXakv3tJRcmcXxBOcO0tbaozPwpmh4YMsnWrQm9ZmZMfa5ocbxzbFk6O4bDPEc/iAnA==", "dev": true, "requires": { - "color-name": "~1.1.4" + "@sinclair/typebox": "^0.34.0" } }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", + "@jest/types": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/types/-/types-30.2.0.tgz", + "integrity": "sha512-H9xg1/sfVvyfU7o3zMfBEjQ1gcsdeTMgqHoYdN79tuLqfTtuu7WckRA1R5whDwOzxaZAeMKTYWqP+WCAi0CHsg==", + "dev": true, + "requires": { + "@jest/pattern": "30.0.1", + "@jest/schemas": "30.0.5", + "@types/istanbul-lib-coverage": "^2.0.6", + "@types/istanbul-reports": "^3.0.4", + "@types/node": "*", + "@types/yargs": "^17.0.33", + "chalk": "^4.1.2" + } + }, + "@sinclair/typebox": { + "version": "0.34.47", + "resolved": "https://registry.npmjs.org/@sinclair/typebox/-/typebox-0.34.47.tgz", + "integrity": "sha512-ZGIBQ+XDvO5JQku9wmwtabcVTHJsgSWAHYtVuM9pBNNR5E88v6Jcj/llpmsjivig5X8A8HHOb4/mbEKPS5EvAw==", "dev": true }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "@sinonjs/commons": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/@sinonjs/commons/-/commons-3.0.1.tgz", + "integrity": "sha512-K3mCHKQ9sVh8o1C9cxkwxaOmXoAMlDxC1mYyHrjqOWEcBjYr76t96zL2zlj5dUGZ3HSw240X1qgH3Mjf1yJWpQ==", + "dev": true, + "requires": { + "type-detect": "4.0.8" + } + }, + "@sinonjs/fake-timers": { + "version": "13.0.5", + "resolved": "https://registry.npmjs.org/@sinonjs/fake-timers/-/fake-timers-13.0.5.tgz", + "integrity": "sha512-36/hTbH2uaWuGVERyC6da9YwGWnzUZXuPro/F2LfsdOsLnCojz/iSH8MxUt/FD2S5XBSVPhmArFUXcpCQ2Hkiw==", + "dev": true, + "requires": { + "@sinonjs/commons": "^3.0.1" + } + }, + "ci-info": { + "version": "4.3.1", + "resolved": "https://registry.npmjs.org/ci-info/-/ci-info-4.3.1.tgz", + "integrity": "sha512-Wdy2Igu8OcBpI2pZePZ5oWjPC38tmDVx5WKUXKwlLYkA0ozo85sLsLvkBbBn/sZaSCMFOGZJ14fvW9t5/d7kdA==", "dev": true }, - "supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "jest-message-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-message-util/-/jest-message-util-30.2.0.tgz", + "integrity": "sha512-y4DKFLZ2y6DxTWD4cDe07RglV88ZiNEdlRfGtqahfbIjfsw1nMCPx49Uev4IA/hWn3sDKyAnSPwoYSsAEdcimw==", "dev": true, "requires": { - "has-flag": "^4.0.0" + "@babel/code-frame": "^7.27.1", + "@jest/types": "30.2.0", + "@types/stack-utils": "^2.0.3", + "chalk": "^4.1.2", + "graceful-fs": "^4.2.11", + "micromatch": "^4.0.8", + "pretty-format": "30.2.0", + "slash": "^3.0.0", + "stack-utils": "^2.0.6" + } + }, + "jest-mock": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-mock/-/jest-mock-30.2.0.tgz", + "integrity": "sha512-JNNNl2rj4b5ICpmAcq+WbLH83XswjPbjH4T7yvGzfAGCPh1rw+xVNbtk+FnRslvt9lkCcdn9i1oAoKUuFsOxRw==", + "dev": true, + "requires": { + "@jest/types": "30.2.0", + "@types/node": "*", + "jest-util": "30.2.0" + } + }, + "jest-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-30.2.0.tgz", + "integrity": "sha512-QKNsM0o3Xe6ISQU869e+DhG+4CK/48aHYdJZGlFQVTjnbvgpcKyxpzk29fGiO7i/J8VENZ+d2iGnSsvmuHywlA==", + "dev": true, + "requires": { + "@jest/types": "30.2.0", + "@types/node": "*", + "chalk": "^4.1.2", + "ci-info": "^4.2.0", + "graceful-fs": "^4.2.11", + "picomatch": "^4.0.2" + } + }, + "picomatch": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.3.tgz", + "integrity": "sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==", + "dev": true + }, + "pretty-format": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/pretty-format/-/pretty-format-30.2.0.tgz", + "integrity": "sha512-9uBdv/B4EefsuAL+pWqueZyZS2Ba+LxfFeQ9DN14HU4bN8bhaxKdkpjpB6fs9+pSjIBu+FXQHImEg8j/Lw0+vA==", + "dev": true, + "requires": { + "@jest/schemas": "30.0.5", + "ansi-styles": "^5.2.0", + "react-is": "^18.3.1" + }, + "dependencies": { + "ansi-styles": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-5.2.0.tgz", + "integrity": "sha512-Cxwpt2SfTzTtXcfOlzGEee8O+c+MmUgGrNiBcXnuWxuFJHe6a5Hz7qwhwe5OgaSYI0IJvkLqWX1ASG+cJOkEiA==", + "dev": true + } } } } }, - "@jest/environment": { - "version": "29.4.3", - "resolved": "https://registry.npmjs.org/@jest/environment/-/environment-29.4.3.tgz", - "integrity": "sha512-dq5S6408IxIa+lr54zeqce+QgI+CJT4nmmA+1yzFgtcsGK8c/EyiUb9XQOgz3BMKrRDfKseeOaxj2eO8LlD3lA==", - "dev": true, - "requires": { - "@jest/fake-timers": "^29.4.3", - "@jest/types": "^29.4.3", - "@types/node": "*", - "jest-mock": "^29.4.3" - } - }, "@jest/expect": { "version": "29.4.3", "resolved": "https://registry.npmjs.org/@jest/expect/-/expect-29.4.3.tgz", @@ -10529,6 +10135,24 @@ "jest-mock": "^29.4.3" } }, + "@jest/pattern": { + "version": "30.0.1", + "resolved": "https://registry.npmjs.org/@jest/pattern/-/pattern-30.0.1.tgz", + "integrity": "sha512-gWp7NfQW27LaBQz3TITS8L7ZCQ0TLvtmI//4OwlQRx4rnWxcPNIYjxZpDcN4+UlGxgm3jS5QPz8IPTCkb59wZA==", + "dev": true, + "requires": { + "@types/node": "*", + "jest-regex-util": "30.0.1" + }, + "dependencies": { + "jest-regex-util": { + "version": "30.0.1", + "resolved": "https://registry.npmjs.org/jest-regex-util/-/jest-regex-util-30.0.1.tgz", + "integrity": "sha512-jHEQgBXAgc+Gh4g0p3bCevgRCVRkB4VB70zhoAE48gxeSr1hfUOsM/C2WoJgVL7Eyg//hudYENbm3Ne+/dRVVA==", + "dev": true + } + } + }, "@jest/reporters": { "version": "29.4.3", "resolved": "https://registry.npmjs.org/@jest/reporters/-/reporters-29.4.3.tgz", @@ -10559,57 +10183,6 @@ "string-length": "^4.0.1", "strip-ansi": "^6.0.0", "v8-to-istanbul": "^9.0.1" - }, - "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, - "chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - } - }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true - }, - "supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "requires": { - "has-flag": "^4.0.0" - } - } } }, "@jest/schemas": { @@ -10675,64 +10248,15 @@ "jest-util": "^29.4.3", "micromatch": "^4.0.4", "pirates": "^4.0.4", - "slash": "^3.0.0", - "write-file-atomic": "^4.0.2" - }, - "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, - "chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - } - }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, + "slash": "^3.0.0", + "write-file-atomic": "^4.0.2" + }, + "dependencies": { "convert-source-map": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/convert-source-map/-/convert-source-map-2.0.0.tgz", "integrity": "sha512-Kvp459HrV2FEJ1CAsi1Ku+MY3kasH19TFykTz2xWmMeq6bk2NU3XXvfJ+Q61m0xktWwt+1HSYf3JZsTms3aRJg==", "dev": true - }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true - }, - "supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "requires": { - "has-flag": "^4.0.0" - } } } }, @@ -10748,57 +10272,6 @@ "@types/node": "*", "@types/yargs": "^17.0.8", "chalk": "^4.0.0" - }, - "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, - "chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - } - }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true - }, - "supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "requires": { - "has-flag": "^4.0.0" - } - } } }, "@jridgewell/gen-mapping": { @@ -10965,15 +10438,6 @@ "redent": "^3.0.0" }, "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, "chalk": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/chalk/-/chalk-3.0.0.tgz", @@ -10983,36 +10447,6 @@ "ansi-styles": "^4.1.0", "supports-color": "^7.1.0" } - }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true - }, - "supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "requires": { - "has-flag": "^4.0.0" - } } } }, @@ -11091,9 +10525,9 @@ } }, "@types/istanbul-lib-coverage": { - "version": "2.0.4", - "resolved": "https://registry.npmjs.org/@types/istanbul-lib-coverage/-/istanbul-lib-coverage-2.0.4.tgz", - "integrity": "sha512-z/QT1XN4K4KYuslS23k62yDIDLwLFkzxOuMplDtObz0+y7VqJCaO2o+SPwHCvLFZh7xazvvoor2tA/hPz9ee7g==", + "version": "2.0.6", + "resolved": "https://registry.npmjs.org/@types/istanbul-lib-coverage/-/istanbul-lib-coverage-2.0.6.tgz", + "integrity": "sha512-2QF/t/auWm0lsy8XtKVPG19v3sSOQlJe/YHZgfjb/KBBHOGSV+J2q/S671rcq9uTBrLAXmZpqJiaQbMT+zNU1w==", "dev": true }, "@types/istanbul-lib-report": { @@ -11106,9 +10540,9 @@ } }, "@types/istanbul-reports": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/@types/istanbul-reports/-/istanbul-reports-3.0.1.tgz", - "integrity": "sha512-c3mAZEuK0lvBp8tmuL74XRKn1+y2dcwOUpH7x4WrF6gk1GIgiluDRgMYQtw2OFcBvAJWlt6ASU3tSqxp0Uu0Aw==", + "version": "3.0.4", + "resolved": "https://registry.npmjs.org/@types/istanbul-reports/-/istanbul-reports-3.0.4.tgz", + "integrity": "sha512-pk2B1NWalF9toCRu6gjBzR69syFjP4Od8WRAX+0mmf9lAjCRicLOWc+ZrxZHx/0XRjotgkF9t6iaMJ+aXcOdZQ==", "dev": true, "requires": { "@types/istanbul-lib-report": "*" @@ -11124,6 +10558,17 @@ "pretty-format": "^29.0.0" } }, + "@types/jsdom": { + "version": "21.1.7", + "resolved": "https://registry.npmjs.org/@types/jsdom/-/jsdom-21.1.7.tgz", + "integrity": "sha512-yOriVnggzrnQ3a9OKOCxaVuSug3w3/SbOj5i7VwXWZEyUNl3bLF9V3MfxGbZKuwqJOQyRfqXyROBB1CoZLFWzA==", + "dev": true, + "requires": { + "@types/node": "*", + "@types/tough-cookie": "*", + "parse5": "^7.0.0" + } + }, "@types/ndarray": { "version": "1.0.14", "resolved": "https://registry.npmjs.org/@types/ndarray/-/ndarray-1.0.14.tgz", @@ -11142,9 +10587,9 @@ "dev": true }, "@types/stack-utils": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/@types/stack-utils/-/stack-utils-2.0.1.tgz", - "integrity": "sha512-Hl219/BT5fLAaz6NDkSuhzasy49dwQS/DSdu4MdggFB8zcXv7vflBI3xp7FEmkmdDkBUI2bPUNeMttp2knYdxw==", + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/@types/stack-utils/-/stack-utils-2.0.3.tgz", + "integrity": "sha512-9aEbYZ3TbYMznPdcdr3SmIrLXwC/AKZXQeCf9Pgao5CKb8CyHuEX5jzWPTkvregvhRJHcpRO6BFoGW9ycaOkYw==", "dev": true }, "@types/testing-library__jest-dom": { @@ -11156,15 +10601,21 @@ "@types/jest": "*" } }, + "@types/tough-cookie": { + "version": "4.0.5", + "resolved": "https://registry.npmjs.org/@types/tough-cookie/-/tough-cookie-4.0.5.tgz", + "integrity": "sha512-/Ad8+nIOV7Rl++6f1BdKxFSMgmoqEoYbHRpPcx3JEfv8VRsQe9Z4mCXeJBzxs7mbHY/XOZZuXlRNfhpVPbs6ZA==", + "dev": true + }, "@types/webxr": { "version": "0.5.24", "resolved": "https://registry.npmjs.org/@types/webxr/-/webxr-0.5.24.tgz", "integrity": "sha512-h8fgEd/DpoS9CBrjEQXR+dIDraopAEfu4wYVNY2tEPwk60stPWhvZMf4Foo5FakuQ7HFZoa8WceaWFervK2Ovg==" }, "@types/yargs": { - "version": "17.0.22", - "resolved": "https://registry.npmjs.org/@types/yargs/-/yargs-17.0.22.tgz", - "integrity": "sha512-pet5WJ9U8yPVRhkwuEIp5ktAeAqRZOq4UdAyWLWzxbtpyXnzbtLdKiXAjJzi/KLmPGS9wk86lUFWZFN6sISo4g==", + "version": "17.0.35", + "resolved": "https://registry.npmjs.org/@types/yargs/-/yargs-17.0.35.tgz", + "integrity": "sha512-qUHkeCyQFxMXg79wQfTtfndEC+N9ZZg76HJftDJp+qH2tV7Gj4OJi7l+PiWwJ+pWtW8GwSmqsDj/oymhrTWXjg==", "dev": true, "requires": { "@types/yargs-parser": "*" @@ -11193,6 +10644,12 @@ "integrity": "sha512-k+iyHEuPgSw6SbuDpGQM+06HQUa04DZ3o+F6CSzXMvvI5KMvnaEqXe+YVe555R9nn6GPt404fos4wcgpw12SDA==", "dev": true }, + "agent-base": { + "version": "7.1.4", + "resolved": "https://registry.npmjs.org/agent-base/-/agent-base-7.1.4.tgz", + "integrity": "sha512-MnA+YT8fwfJPgBx3m60MNqakm30XOkyIoH1y6huTQvC0PwZG7ki8NacLBcrPbNoo8vEZy7Jpuk7+jMO+CUovTQ==", + "dev": true + }, "ansi-escapes": { "version": "4.3.2", "resolved": "https://registry.npmjs.org/ansi-escapes/-/ansi-escapes-4.3.2.tgz", @@ -11209,12 +10666,12 @@ "dev": true }, "ansi-styles": { - "version": "3.2.1", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz", - "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", "dev": true, "requires": { - "color-convert": "^1.9.0" + "color-convert": "^2.0.1" } }, "anymatch": { @@ -11277,57 +10734,6 @@ "chalk": "^4.0.0", "graceful-fs": "^4.2.9", "slash": "^3.0.0" - }, - "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, - "chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - } - }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true - }, - "supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "requires": { - "has-flag": "^4.0.0" - } - } } }, "babel-plugin-istanbul": { @@ -11547,14 +10953,13 @@ } }, "chalk": { - "version": "2.4.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.2.tgz", - "integrity": "sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==", + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", "dev": true, "requires": { - "ansi-styles": "^3.2.1", - "escape-string-regexp": "^1.0.5", - "supports-color": "^5.3.0" + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" } }, "char-regex": { @@ -11621,18 +11026,18 @@ "dev": true }, "color-convert": { - "version": "1.9.3", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-1.9.3.tgz", - "integrity": "sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg==", + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", "dev": true, "requires": { - "color-name": "1.1.3" + "color-name": "~1.1.4" } }, "color-name": { - "version": "1.1.3", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.3.tgz", - "integrity": "sha512-72fSenhMw2HZMTVHeCA9KCmpEIbzWiQsjN+BHcBbS9vr1mtt+vJjPdksIBNUmKAW8TFUDPJK5SUU3QhE9NEXDw==", + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", "dev": true }, "commander": { @@ -11714,6 +11119,16 @@ "integrity": "sha512-YUifsXXuknHlUsmlgyY0PKzgPOr7/FjCePfHNt0jxm83wHZi44VDMQ7/fGNkjY3/jV1MC+1CmZbaHzugyeRtpg==", "dev": true }, + "cssstyle": { + "version": "4.6.0", + "resolved": "https://registry.npmjs.org/cssstyle/-/cssstyle-4.6.0.tgz", + "integrity": "sha512-2z+rWdzbbSZv6/rhtvzvqeZQHrBaqgogqt85sqFNbabZOuFbCVFb8kPeEtZjiKkbrm395irpNKiYeFeLiQnFPg==", + "dev": true, + "requires": { + "@asamuzakjp/css-color": "^3.2.0", + "rrweb-cssom": "^0.8.0" + } + }, "cwise-compiler": { "version": "1.1.3", "resolved": "https://registry.npmjs.org/cwise-compiler/-/cwise-compiler-1.1.3.tgz", @@ -11722,6 +11137,16 @@ "uniq": "^1.0.0" } }, + "data-urls": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/data-urls/-/data-urls-5.0.0.tgz", + "integrity": "sha512-ZYP5VBHshaDAiVZxjbRVcFJpc+4xGgT0bK3vzy1HLN8jTO975HEbuYzZJcHoQEY5K1a0z8YayJkyVETa08eNTg==", + "dev": true, + "requires": { + "whatwg-mimetype": "^4.0.0", + "whatwg-url": "^14.0.0" + } + }, "debug": { "version": "4.3.4", "resolved": "https://registry.npmjs.org/debug/-/debug-4.3.4.tgz", @@ -11731,6 +11156,12 @@ "ms": "2.1.2" } }, + "decimal.js": { + "version": "10.6.0", + "resolved": "https://registry.npmjs.org/decimal.js/-/decimal.js-10.6.0.tgz", + "integrity": "sha512-YpgQiITW3JXGntzdUmyUR1V812Hn8T1YVXhCu+wO3OpS4eU9l4YdD3qjyiKdV6mvV29zapkMeD390UVEf2lkUg==", + "dev": true + }, "decode-uri-component": { "version": "0.2.2", "resolved": "https://registry.npmjs.org/decode-uri-component/-/decode-uri-component-0.2.2.tgz", @@ -11826,6 +11257,12 @@ "once": "^1.4.0" } }, + "entities": { + "version": "6.0.1", + "resolved": "https://registry.npmjs.org/entities/-/entities-6.0.1.tgz", + "integrity": "sha512-aN97NXWF6AWBTahfVOIrB/NShkzi5H7F9r1s9mD3cDj4Ko5f2qhhVoYMibXF7GlLveb/D2ioWay8lxI97Ven3g==", + "dev": true + }, "error-ex": { "version": "1.3.2", "resolved": "https://registry.npmjs.org/error-ex/-/error-ex-1.3.2.tgz", @@ -11854,12 +11291,6 @@ "integrity": "sha512-k0er2gUkLf8O0zKJiAhmkTnJlTvINGv7ygDNPbeIsX/TJjGJZHuh9B2UxbsaEkmlEo9MfhrSzmhIlhRlI2GXnw==", "dev": true }, - "escape-string-regexp": { - "version": "1.0.5", - "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz", - "integrity": "sha512-vbRorB5FUQWvla16U8R/qgaFIya2qGzwDrNmCZuYKrbdSUMG6I1ZCGQRefkRVhuOkIGVne7BQ35DSfo1qvJqFg==", - "dev": true - }, "esprima": { "version": "4.0.1", "resolved": "https://registry.npmjs.org/esprima/-/esprima-4.0.1.tgz", @@ -12084,9 +11515,9 @@ "dev": true }, "graceful-fs": { - "version": "4.2.10", - "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.10.tgz", - "integrity": "sha512-9ByhssR2fPVsNZj478qUUbKfmL0+t5BDVyjShtyZZLiK7ZDAArFFfopyOTj0M05wE2tJPisA4iTnnXl2YoPvOA==", + "version": "4.2.11", + "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.11.tgz", + "integrity": "sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ==", "dev": true }, "has": { @@ -12099,23 +11530,61 @@ } }, "has-flag": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-3.0.0.tgz", - "integrity": "sha512-sKJf1+ceQBr4SMkvQnBDNDtf4TXpVhVGateu0t918bl30FnbE2m4vNLX+VWe/dpjlb+HugGYzW7uQXH98HPEYw==", + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", "dev": true }, + "html-encoding-sniffer": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/html-encoding-sniffer/-/html-encoding-sniffer-4.0.0.tgz", + "integrity": "sha512-Y22oTqIU4uuPgEemfz7NDJz6OeKf12Lsu+QC+s3BVpda64lTiMYCyGwg5ki4vFxkMwQdeZDl2adZoqUgdFuTgQ==", + "dev": true, + "requires": { + "whatwg-encoding": "^3.1.1" + } + }, "html-escaper": { "version": "2.0.2", "resolved": "https://registry.npmjs.org/html-escaper/-/html-escaper-2.0.2.tgz", "integrity": "sha512-H2iMtd0I4Mt5eYiapRdIDjp+XzelXQ0tFE4JS7YFwFevXXMmOp9myNrUvCg0D6ws8iqkRPBfKHgbwig1SmlLfg==", "dev": true }, + "http-proxy-agent": { + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/http-proxy-agent/-/http-proxy-agent-7.0.2.tgz", + "integrity": "sha512-T1gkAiYYDWYx3V5Bmyu7HcfcvL7mUrTWiM6yOfa3PIphViJ/gFPbvidQ+veqSOHci/PxBcDabeUNCzpOODJZig==", + "dev": true, + "requires": { + "agent-base": "^7.1.0", + "debug": "^4.3.4" + } + }, + "https-proxy-agent": { + "version": "7.0.6", + "resolved": "https://registry.npmjs.org/https-proxy-agent/-/https-proxy-agent-7.0.6.tgz", + "integrity": "sha512-vK9P5/iUfdl95AI+JVyUuIcVtd4ofvtrOr3HNtM2yxC9bnMbEdp3x01OhQNnjb8IJYi38VlTE3mBXwcfvywuSw==", + "dev": true, + "requires": { + "agent-base": "^7.1.2", + "debug": "4" + } + }, "human-signals": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/human-signals/-/human-signals-2.1.0.tgz", "integrity": "sha512-B4FFZ6q/T2jhhksgkbEW3HBvWIfDW85snkQgawt07S7J5QXTk6BkNV+0yAeZrM5QpMAdYlocGoljn0sJ/WQkFw==", "dev": true }, + "iconv-lite": { + "version": "0.6.3", + "resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.6.3.tgz", + "integrity": "sha512-4fCk79wshMdzMp2rH06qWrJE4iolqLhCUH+OiuIgU++RB0+94NlDL81atO7GX55uUKueo0txHNtvEyI6D7WdMw==", + "dev": true, + "requires": { + "safer-buffer": ">= 2.1.2 < 3.0.0" + } + }, "ieee754": { "version": "1.2.1", "resolved": "https://registry.npmjs.org/ieee754/-/ieee754-1.2.1.tgz", @@ -12251,6 +11720,12 @@ "integrity": "sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==", "dev": true }, + "is-potential-custom-element-name": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/is-potential-custom-element-name/-/is-potential-custom-element-name-1.0.1.tgz", + "integrity": "sha512-bCYeRA2rVibKZd+s2625gGnGF/t7DSqDs4dP7CrLA1m7jKWz6pps0LpYLJN8Q64HtmPKJ1hrN3nzPNKFEKOUiQ==", + "dev": true + }, "is-stream": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/is-stream/-/is-stream-2.0.1.tgz", @@ -12300,23 +11775,6 @@ "istanbul-lib-coverage": "^3.0.0", "make-dir": "^3.0.0", "supports-color": "^7.1.0" - }, - "dependencies": { - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true - }, - "supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "requires": { - "has-flag": "^4.0.0" - } - } } }, "istanbul-lib-source-maps": { @@ -12395,128 +11853,26 @@ "pretty-format": "^29.4.3", "slash": "^3.0.0", "stack-utils": "^2.0.3" - }, - "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, - "chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - } - }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true - }, - "supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "requires": { - "has-flag": "^4.0.0" - } - } } }, "jest-cli": { "version": "29.4.3", - "resolved": "https://registry.npmjs.org/jest-cli/-/jest-cli-29.4.3.tgz", - "integrity": "sha512-PiiAPuFNfWWolCE6t3ZrDXQc6OsAuM3/tVW0u27UWc1KE+n/HSn5dSE6B2juqN7WP+PP0jAcnKtGmI4u8GMYCg==", - "dev": true, - "requires": { - "@jest/core": "^29.4.3", - "@jest/test-result": "^29.4.3", - "@jest/types": "^29.4.3", - "chalk": "^4.0.0", - "exit": "^0.1.2", - "graceful-fs": "^4.2.9", - "import-local": "^3.0.2", - "jest-config": "^29.4.3", - "jest-util": "^29.4.3", - "jest-validate": "^29.4.3", - "prompts": "^2.0.1", - "yargs": "^17.3.1" - }, - "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, - "chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - } - }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true - }, - "supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "requires": { - "has-flag": "^4.0.0" - } - } + "resolved": "https://registry.npmjs.org/jest-cli/-/jest-cli-29.4.3.tgz", + "integrity": "sha512-PiiAPuFNfWWolCE6t3ZrDXQc6OsAuM3/tVW0u27UWc1KE+n/HSn5dSE6B2juqN7WP+PP0jAcnKtGmI4u8GMYCg==", + "dev": true, + "requires": { + "@jest/core": "^29.4.3", + "@jest/test-result": "^29.4.3", + "@jest/types": "^29.4.3", + "chalk": "^4.0.0", + "exit": "^0.1.2", + "graceful-fs": "^4.2.9", + "import-local": "^3.0.2", + "jest-config": "^29.4.3", + "jest-util": "^29.4.3", + "jest-validate": "^29.4.3", + "prompts": "^2.0.1", + "yargs": "^17.3.1" } }, "jest-config": { @@ -12549,15 +11905,6 @@ "strip-json-comments": "^3.1.1" }, "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, "babel-jest": { "version": "29.4.3", "resolved": "https://registry.npmjs.org/babel-jest/-/babel-jest-29.4.3.tgz", @@ -12572,46 +11919,6 @@ "graceful-fs": "^4.2.9", "slash": "^3.0.0" } - }, - "chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - } - }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true - }, - "supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "requires": { - "has-flag": "^4.0.0" - } } } }, @@ -12625,57 +11932,6 @@ "diff-sequences": "^29.4.3", "jest-get-type": "^29.4.3", "pretty-format": "^29.4.3" - }, - "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, - "chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - } - }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true - }, - "supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "requires": { - "has-flag": "^4.0.0" - } - } } }, "jest-docblock": { @@ -12698,55 +11954,164 @@ "jest-get-type": "^29.4.3", "jest-util": "^29.4.3", "pretty-format": "^29.4.3" + } + }, + "jest-environment-jsdom": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-environment-jsdom/-/jest-environment-jsdom-30.2.0.tgz", + "integrity": "sha512-zbBTiqr2Vl78pKp/laGBREYzbZx9ZtqPjOK4++lL4BNDhxRnahg51HtoDrk9/VjIy9IthNEWdKVd7H5bqBhiWQ==", + "dev": true, + "requires": { + "@jest/environment": "30.2.0", + "@jest/environment-jsdom-abstract": "30.2.0", + "@types/jsdom": "^21.1.7", + "@types/node": "*", + "jsdom": "^26.1.0" }, "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "@jest/environment": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/environment/-/environment-30.2.0.tgz", + "integrity": "sha512-/QPTL7OBJQ5ac09UDRa3EQes4gt1FTEG/8jZ/4v5IVzx+Cv7dLxlVIvfvSVRiiX2drWyXeBjkMSR8hvOWSog5g==", "dev": true, "requires": { - "color-convert": "^2.0.1" + "@jest/fake-timers": "30.2.0", + "@jest/types": "30.2.0", + "@types/node": "*", + "jest-mock": "30.2.0" } }, - "chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "@jest/fake-timers": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/fake-timers/-/fake-timers-30.2.0.tgz", + "integrity": "sha512-HI3tRLjRxAbBy0VO8dqqm7Hb2mIa8d5bg/NJkyQcOk7V118ObQML8RC5luTF/Zsg4474a+gDvhce7eTnP4GhYw==", "dev": true, "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" + "@jest/types": "30.2.0", + "@sinonjs/fake-timers": "^13.0.0", + "@types/node": "*", + "jest-message-util": "30.2.0", + "jest-mock": "30.2.0", + "jest-util": "30.2.0" } }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "@jest/schemas": { + "version": "30.0.5", + "resolved": "https://registry.npmjs.org/@jest/schemas/-/schemas-30.0.5.tgz", + "integrity": "sha512-DmdYgtezMkh3cpU8/1uyXakv3tJRcmcXxBOcO0tbaozPwpmh4YMsnWrQm9ZmZMfa5ocbxzbFk6O4bDPEc/iAnA==", + "dev": true, + "requires": { + "@sinclair/typebox": "^0.34.0" + } + }, + "@jest/types": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/types/-/types-30.2.0.tgz", + "integrity": "sha512-H9xg1/sfVvyfU7o3zMfBEjQ1gcsdeTMgqHoYdN79tuLqfTtuu7WckRA1R5whDwOzxaZAeMKTYWqP+WCAi0CHsg==", "dev": true, "requires": { - "color-name": "~1.1.4" + "@jest/pattern": "30.0.1", + "@jest/schemas": "30.0.5", + "@types/istanbul-lib-coverage": "^2.0.6", + "@types/istanbul-reports": "^3.0.4", + "@types/node": "*", + "@types/yargs": "^17.0.33", + "chalk": "^4.1.2" } }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", + "@sinclair/typebox": { + "version": "0.34.47", + "resolved": "https://registry.npmjs.org/@sinclair/typebox/-/typebox-0.34.47.tgz", + "integrity": "sha512-ZGIBQ+XDvO5JQku9wmwtabcVTHJsgSWAHYtVuM9pBNNR5E88v6Jcj/llpmsjivig5X8A8HHOb4/mbEKPS5EvAw==", "dev": true }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "@sinonjs/commons": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/@sinonjs/commons/-/commons-3.0.1.tgz", + "integrity": "sha512-K3mCHKQ9sVh8o1C9cxkwxaOmXoAMlDxC1mYyHrjqOWEcBjYr76t96zL2zlj5dUGZ3HSw240X1qgH3Mjf1yJWpQ==", + "dev": true, + "requires": { + "type-detect": "4.0.8" + } + }, + "@sinonjs/fake-timers": { + "version": "13.0.5", + "resolved": "https://registry.npmjs.org/@sinonjs/fake-timers/-/fake-timers-13.0.5.tgz", + "integrity": "sha512-36/hTbH2uaWuGVERyC6da9YwGWnzUZXuPro/F2LfsdOsLnCojz/iSH8MxUt/FD2S5XBSVPhmArFUXcpCQ2Hkiw==", + "dev": true, + "requires": { + "@sinonjs/commons": "^3.0.1" + } + }, + "ansi-styles": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-5.2.0.tgz", + "integrity": "sha512-Cxwpt2SfTzTtXcfOlzGEee8O+c+MmUgGrNiBcXnuWxuFJHe6a5Hz7qwhwe5OgaSYI0IJvkLqWX1ASG+cJOkEiA==", "dev": true }, - "supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "ci-info": { + "version": "4.3.1", + "resolved": "https://registry.npmjs.org/ci-info/-/ci-info-4.3.1.tgz", + "integrity": "sha512-Wdy2Igu8OcBpI2pZePZ5oWjPC38tmDVx5WKUXKwlLYkA0ozo85sLsLvkBbBn/sZaSCMFOGZJ14fvW9t5/d7kdA==", + "dev": true + }, + "jest-message-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-message-util/-/jest-message-util-30.2.0.tgz", + "integrity": "sha512-y4DKFLZ2y6DxTWD4cDe07RglV88ZiNEdlRfGtqahfbIjfsw1nMCPx49Uev4IA/hWn3sDKyAnSPwoYSsAEdcimw==", "dev": true, "requires": { - "has-flag": "^4.0.0" + "@babel/code-frame": "^7.27.1", + "@jest/types": "30.2.0", + "@types/stack-utils": "^2.0.3", + "chalk": "^4.1.2", + "graceful-fs": "^4.2.11", + "micromatch": "^4.0.8", + "pretty-format": "30.2.0", + "slash": "^3.0.0", + "stack-utils": "^2.0.6" + } + }, + "jest-mock": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-mock/-/jest-mock-30.2.0.tgz", + "integrity": "sha512-JNNNl2rj4b5ICpmAcq+WbLH83XswjPbjH4T7yvGzfAGCPh1rw+xVNbtk+FnRslvt9lkCcdn9i1oAoKUuFsOxRw==", + "dev": true, + "requires": { + "@jest/types": "30.2.0", + "@types/node": "*", + "jest-util": "30.2.0" + } + }, + "jest-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-30.2.0.tgz", + "integrity": "sha512-QKNsM0o3Xe6ISQU869e+DhG+4CK/48aHYdJZGlFQVTjnbvgpcKyxpzk29fGiO7i/J8VENZ+d2iGnSsvmuHywlA==", + "dev": true, + "requires": { + "@jest/types": "30.2.0", + "@types/node": "*", + "chalk": "^4.1.2", + "ci-info": "^4.2.0", + "graceful-fs": "^4.2.11", + "picomatch": "^4.0.2" + } + }, + "picomatch": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.3.tgz", + "integrity": "sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==", + "dev": true + }, + "pretty-format": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/pretty-format/-/pretty-format-30.2.0.tgz", + "integrity": "sha512-9uBdv/B4EefsuAL+pWqueZyZS2Ba+LxfFeQ9DN14HU4bN8bhaxKdkpjpB6fs9+pSjIBu+FXQHImEg8j/Lw0+vA==", + "dev": true, + "requires": { + "@jest/schemas": "30.0.5", + "ansi-styles": "^5.2.0", + "react-is": "^18.3.1" } } } @@ -12822,57 +12187,6 @@ "jest-diff": "^29.4.3", "jest-get-type": "^29.4.3", "pretty-format": "^29.4.3" - }, - "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, - "chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - } - }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true - }, - "supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "requires": { - "has-flag": "^4.0.0" - } - } } }, "jest-message-util": { @@ -12890,57 +12204,6 @@ "pretty-format": "^29.4.3", "slash": "^3.0.0", "stack-utils": "^2.0.3" - }, - "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, - "chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - } - }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true - }, - "supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "requires": { - "has-flag": "^4.0.0" - } - } } }, "jest-mock": { @@ -12984,46 +12247,6 @@ "slash": "^3.0.0" }, "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, - "chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - } - }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true - }, "resolve": { "version": "1.22.1", "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.22.1.tgz", @@ -13034,15 +12257,6 @@ "path-parse": "^1.0.7", "supports-preserve-symlinks-flag": "^1.0.0" } - }, - "supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "requires": { - "has-flag": "^4.0.0" - } } } }, @@ -13065,75 +12279,24 @@ "@jest/console": "^29.4.3", "@jest/environment": "^29.4.3", "@jest/test-result": "^29.4.3", - "@jest/transform": "^29.4.3", - "@jest/types": "^29.4.3", - "@types/node": "*", - "chalk": "^4.0.0", - "emittery": "^0.13.1", - "graceful-fs": "^4.2.9", - "jest-docblock": "^29.4.3", - "jest-environment-node": "^29.4.3", - "jest-haste-map": "^29.4.3", - "jest-leak-detector": "^29.4.3", - "jest-message-util": "^29.4.3", - "jest-resolve": "^29.4.3", - "jest-runtime": "^29.4.3", - "jest-util": "^29.4.3", - "jest-watcher": "^29.4.3", - "jest-worker": "^29.4.3", - "p-limit": "^3.1.0", - "source-map-support": "0.5.13" - }, - "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, - "chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - } - }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true - }, - "supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "requires": { - "has-flag": "^4.0.0" - } - } + "@jest/transform": "^29.4.3", + "@jest/types": "^29.4.3", + "@types/node": "*", + "chalk": "^4.0.0", + "emittery": "^0.13.1", + "graceful-fs": "^4.2.9", + "jest-docblock": "^29.4.3", + "jest-environment-node": "^29.4.3", + "jest-haste-map": "^29.4.3", + "jest-leak-detector": "^29.4.3", + "jest-message-util": "^29.4.3", + "jest-resolve": "^29.4.3", + "jest-runtime": "^29.4.3", + "jest-util": "^29.4.3", + "jest-watcher": "^29.4.3", + "jest-worker": "^29.4.3", + "p-limit": "^3.1.0", + "source-map-support": "0.5.13" } }, "jest-runtime": { @@ -13164,57 +12327,6 @@ "jest-util": "^29.4.3", "slash": "^3.0.0", "strip-bom": "^4.0.0" - }, - "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, - "chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - } - }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true - }, - "supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "requires": { - "has-flag": "^4.0.0" - } - } } }, "jest-snapshot": { @@ -13249,46 +12361,6 @@ "semver": "^7.3.5" }, "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, - "chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - } - }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true - }, "lru-cache": { "version": "6.0.0", "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-6.0.0.tgz", @@ -13307,15 +12379,6 @@ "lru-cache": "^6.0.0" } }, - "supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "requires": { - "has-flag": "^4.0.0" - } - }, "yallist": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz", @@ -13336,57 +12399,6 @@ "ci-info": "^3.2.0", "graceful-fs": "^4.2.9", "picomatch": "^2.2.3" - }, - "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, - "chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - } - }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true - }, - "supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "requires": { - "has-flag": "^4.0.0" - } - } } }, "jest-validate": { @@ -13403,60 +12415,11 @@ "pretty-format": "^29.4.3" }, "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, "camelcase": { "version": "6.3.0", "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-6.3.0.tgz", "integrity": "sha512-Gmy6FhYlCY7uOElZUSbxo2UCDH8owEk996gkbrpsgGtrJLM3J7jGxl9Ic7Qwwj4ivOE5AWZWRMecDdF7hqGjFA==", "dev": true - }, - "chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - } - }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true - }, - "supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "requires": { - "has-flag": "^4.0.0" - } } } }, @@ -13474,57 +12437,6 @@ "emittery": "^0.13.1", "jest-util": "^29.4.3", "string-length": "^4.0.1" - }, - "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, - "chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - } - }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true - }, - "supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "requires": { - "has-flag": "^4.0.0" - } - } } }, "jest-worker": { @@ -13539,12 +12451,6 @@ "supports-color": "^8.0.0" }, "dependencies": { - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true - }, "supports-color": { "version": "8.1.1", "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-8.1.1.tgz", @@ -13572,6 +12478,34 @@ "esprima": "^4.0.0" } }, + "jsdom": { + "version": "26.1.0", + "resolved": "https://registry.npmjs.org/jsdom/-/jsdom-26.1.0.tgz", + "integrity": "sha512-Cvc9WUhxSMEo4McES3P7oK3QaXldCfNWp7pl2NNeiIFlCoLr3kfq9kb1fxftiwk1FLV7CvpvDfonxtzUDeSOPg==", + "dev": true, + "requires": { + "cssstyle": "^4.2.1", + "data-urls": "^5.0.0", + "decimal.js": "^10.5.0", + "html-encoding-sniffer": "^4.0.0", + "http-proxy-agent": "^7.0.2", + "https-proxy-agent": "^7.0.6", + "is-potential-custom-element-name": "^1.0.1", + "nwsapi": "^2.2.16", + "parse5": "^7.2.1", + "rrweb-cssom": "^0.8.0", + "saxes": "^6.0.0", + "symbol-tree": "^3.2.4", + "tough-cookie": "^5.1.1", + "w3c-xmlserializer": "^5.0.0", + "webidl-conversions": "^7.0.0", + "whatwg-encoding": "^3.1.1", + "whatwg-mimetype": "^4.0.0", + "whatwg-url": "^14.1.1", + "ws": "^8.18.0", + "xml-name-validator": "^5.0.0" + } + }, "jsep": { "version": "1.3.9", "resolved": "https://registry.npmjs.org/jsep/-/jsep-1.3.9.tgz", @@ -13911,6 +12845,12 @@ "path-key": "^3.0.0" } }, + "nwsapi": { + "version": "2.2.23", + "resolved": "https://registry.npmjs.org/nwsapi/-/nwsapi-2.2.23.tgz", + "integrity": "sha512-7wfH4sLbt4M0gCDzGE6vzQBo0bfTKjU7Sfpqy/7gs1qBfYz2vEJH6vXcBKpO3+6Yu1telwd0t9HpyOoLEQQbIQ==", + "dev": true + }, "once": { "version": "1.4.0", "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", @@ -14001,6 +12941,15 @@ "lines-and-columns": "^1.1.6" } }, + "parse5": { + "version": "7.3.0", + "resolved": "https://registry.npmjs.org/parse5/-/parse5-7.3.0.tgz", + "integrity": "sha512-IInvU7fabl34qmi9gY8XOVxhYyMyuH2xUNpb2q8/Y+7552KlejkRvqvD19nMoUW/uQGGbqNpA6Tufu5FL5BZgw==", + "dev": true, + "requires": { + "entities": "^6.0.0" + } + }, "path-exists": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-4.0.0.tgz", @@ -14026,9 +12975,9 @@ "dev": true }, "picocolors": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.0.0.tgz", - "integrity": "sha512-1fygroTLlHu66zi26VoTDv8yRgm0Fccecssto+MhsZ0D/DGW2sm8E8AjW7NU5VVTRt5GxbeZ5qBuJr+HyLYkjQ==", + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.1.1.tgz", + "integrity": "sha512-xceH2snhtb5M9liqDsmEw56le376mTZkEX/jEb/RxNFyegNul7eNslCXP9FDj/Lcu0X8KEyMceP2ntpaHrDEVA==", "dev": true }, "picomatch": { @@ -14126,6 +13075,12 @@ "once": "^1.3.1" } }, + "punycode": { + "version": "2.3.1", + "resolved": "https://registry.npmjs.org/punycode/-/punycode-2.3.1.tgz", + "integrity": "sha512-vYt7UD1U9Wg6138shLtLOvdAu+8DsC/ilFtEVHcH+wydcSpNE20AfSOduf6MkRFahL5FY7X1oU7nKVZFtfq8Fg==", + "dev": true + }, "queue-microtask": { "version": "1.2.3", "resolved": "https://registry.npmjs.org/queue-microtask/-/queue-microtask-1.2.3.tgz", @@ -14153,9 +13108,9 @@ } }, "react-is": { - "version": "18.2.0", - "resolved": "https://registry.npmjs.org/react-is/-/react-is-18.2.0.tgz", - "integrity": "sha512-xWGDIW6x921xtzPkhiULtthJHoJvBbF3q26fzloPCK0hsvxtPVelvftw3zjbHWSkR2km9Z+4uxbDDK/6Zw9B8w==", + "version": "18.3.1", + "resolved": "https://registry.npmjs.org/react-is/-/react-is-18.3.1.tgz", + "integrity": "sha512-/LLMVyas0ljjAtoYiPqYiL8VWXzUUdThrmU5+n20DZv+a+ClRoevUzw5JxU+Ieh5/c87ytoTBV9G1FiKfNJdmg==", "dev": true }, "readable-stream": { @@ -14301,6 +13256,12 @@ "integrity": "sha512-g6QUff04oZpHs0eG5p83rFLhHeV00ug/Yf9nZM6fLeUrPguBTkTQOdpAWWspMh55TZfVQDPaN3NQJfbVRAxdIw==", "dev": true }, + "rrweb-cssom": { + "version": "0.8.0", + "resolved": "https://registry.npmjs.org/rrweb-cssom/-/rrweb-cssom-0.8.0.tgz", + "integrity": "sha512-guoltQEx+9aMf2gDZ0s62EcV8lsXR+0w8915TC3ITdn2YueuNjdAYh/levpU9nFaoChh9RUS5ZdQMrKfVEN9tw==", + "dev": true + }, "run-parallel": { "version": "1.2.0", "resolved": "https://registry.npmjs.org/run-parallel/-/run-parallel-1.2.0.tgz", @@ -14324,6 +13285,12 @@ "integrity": "sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==", "optional": true }, + "safer-buffer": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz", + "integrity": "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==", + "dev": true + }, "sass": { "version": "1.57.1", "resolved": "https://registry.npmjs.org/sass/-/sass-1.57.1.tgz", @@ -14340,6 +13307,15 @@ "resolved": "https://registry.npmjs.org/sax/-/sax-1.4.3.tgz", "integrity": "sha512-yqYn1JhPczigF94DMS+shiDMjDowYO6y9+wB/4WgO0Y19jWYk0lQ4tuG5KI7kj4FTp1wxPj5IFfcrz/s1c3jjQ==" }, + "saxes": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/saxes/-/saxes-6.0.0.tgz", + "integrity": "sha512-xAg7SOnEhrm5zI3puOOKyy1OMcMlIJZYNJY7xLBwSze0UjhPLnWfj2GF2EpT0jmzaJKIWKHLsaSSajf35bcYnA==", + "dev": true, + "requires": { + "xmlchars": "^2.2.0" + } + }, "semver": { "version": "6.3.0", "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.0.tgz", @@ -14685,12 +13661,12 @@ "dev": true }, "supports-color": { - "version": "5.5.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.5.0.tgz", - "integrity": "sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==", + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", "dev": true, "requires": { - "has-flag": "^3.0.0" + "has-flag": "^4.0.0" } }, "supports-preserve-symlinks-flag": { @@ -14699,6 +13675,12 @@ "integrity": "sha512-ot0WnXS9fgdkgIcePe6RHNk1WA8+muPa6cSjeR3V8K27q9BB1rTE3R1p7Hv0z1ZyAc8s6Vvv8DIyWf681MAt0w==", "dev": true }, + "symbol-tree": { + "version": "3.2.4", + "resolved": "https://registry.npmjs.org/symbol-tree/-/symbol-tree-3.2.4.tgz", + "integrity": "sha512-9QNk5KwDF+Bvz+PyObkmSYjI5ksVUYtjW7AU22r2NKcfLJcXp96hkDWU3+XndOsUb+AQ9QhfzfCT2O+CNWT5Tw==", + "dev": true + }, "tar-fs": { "version": "2.1.4", "resolved": "https://registry.npmjs.org/tar-fs/-/tar-fs-2.1.4.tgz", @@ -14735,6 +13717,21 @@ "minimatch": "^3.0.4" } }, + "tldts": { + "version": "6.1.86", + "resolved": "https://registry.npmjs.org/tldts/-/tldts-6.1.86.tgz", + "integrity": "sha512-WMi/OQ2axVTf/ykqCQgXiIct+mSQDFdH2fkwhPwgEwvJ1kSzZRiinb0zF2Xb8u4+OqPChmyI6MEu4EezNJz+FQ==", + "dev": true, + "requires": { + "tldts-core": "^6.1.86" + } + }, + "tldts-core": { + "version": "6.1.86", + "resolved": "https://registry.npmjs.org/tldts-core/-/tldts-core-6.1.86.tgz", + "integrity": "sha512-Je6p7pkk+KMzMv2XXKmAE3McmolOQFdxkKw0R8EYNr7sELW46JqnNeTX8ybPiQgvg1ymCoF8LXs5fzFaZvJPTA==", + "dev": true + }, "tmpl": { "version": "1.0.5", "resolved": "https://registry.npmjs.org/tmpl/-/tmpl-1.0.5.tgz", @@ -14756,6 +13753,24 @@ "is-number": "^7.0.0" } }, + "tough-cookie": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/tough-cookie/-/tough-cookie-5.1.2.tgz", + "integrity": "sha512-FVDYdxtnj0G6Qm/DhNPSb8Ju59ULcup3tuJxkFb5K8Bv2pUXILbf0xZWU8PX8Ov19OXljbUyveOFwRMwkXzO+A==", + "dev": true, + "requires": { + "tldts": "^6.1.32" + } + }, + "tr46": { + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/tr46/-/tr46-5.1.1.tgz", + "integrity": "sha512-hdF5ZgjTqgAntKkklYw0R03MG2x/bSzTtkxmIRw/sTNV8YXsCJ1tfLAX23lhxhHJlEf3CRCOCGGWw3vI3GaSPw==", + "dev": true, + "requires": { + "punycode": "^2.3.1" + } + }, "ts-jest": { "version": "29.0.0", "resolved": "https://registry.npmjs.org/ts-jest/-/ts-jest-29.0.0.tgz", @@ -14939,6 +13954,15 @@ "webworker-threads": "^0.7.12" } }, + "w3c-xmlserializer": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/w3c-xmlserializer/-/w3c-xmlserializer-5.0.0.tgz", + "integrity": "sha512-o8qghlI8NZHU1lLPrpi2+Uq7abh4GGPpYANlalzWxyWteJOCsr/P+oPBA49TOLu5FTZO4d3F9MnWJfiMo4BkmA==", + "dev": true, + "requires": { + "xml-name-validator": "^5.0.0" + } + }, "walker": { "version": "1.0.8", "resolved": "https://registry.npmjs.org/walker/-/walker-1.0.8.tgz", @@ -14948,6 +13972,12 @@ "makeerror": "1.0.12" } }, + "webidl-conversions": { + "version": "7.0.0", + "resolved": "https://registry.npmjs.org/webidl-conversions/-/webidl-conversions-7.0.0.tgz", + "integrity": "sha512-VwddBukDzu71offAQR975unBIGqfKZpM+8ZX6ySk8nYhVoo5CYaZyzt3YBvYtRtO+aoGlqxPg/B87NGVZ/fu6g==", + "dev": true + }, "webworker-threads": { "version": "0.7.17", "resolved": "https://registry.npmjs.org/webworker-threads/-/webworker-threads-0.7.17.tgz", @@ -14958,6 +13988,31 @@ "nan": "^2.11.0" } }, + "whatwg-encoding": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/whatwg-encoding/-/whatwg-encoding-3.1.1.tgz", + "integrity": "sha512-6qN4hJdMwfYBtE3YBTTHhoeuUrDBPZmbQaxWAqSALV/MeEnR5z1xd8UKud2RAkFoPkmB+hli1TZSnyi84xz1vQ==", + "dev": true, + "requires": { + "iconv-lite": "0.6.3" + } + }, + "whatwg-mimetype": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/whatwg-mimetype/-/whatwg-mimetype-4.0.0.tgz", + "integrity": "sha512-QaKxh0eNIi2mE9p2vEdzfagOKHCcj1pJ56EEHGQOVxp8r9/iszLUUV7v89x9O1p/T+NlTM5W7jW6+cz4Fq1YVg==", + "dev": true + }, + "whatwg-url": { + "version": "14.2.0", + "resolved": "https://registry.npmjs.org/whatwg-url/-/whatwg-url-14.2.0.tgz", + "integrity": "sha512-De72GdQZzNTUBBChsXueQUnPKDkg/5A5zp7pFDuQAj5UFoENpiACU0wlCvzpAGnTkj++ihpKwKyYewn/XNUbKw==", + "dev": true, + "requires": { + "tr46": "^5.1.0", + "webidl-conversions": "^7.0.0" + } + }, "which": { "version": "2.0.2", "resolved": "https://registry.npmjs.org/which/-/which-2.0.2.tgz", @@ -14976,32 +14031,6 @@ "ansi-styles": "^4.0.0", "string-width": "^4.1.0", "strip-ansi": "^6.0.0" - }, - "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - } } }, "wrappy": { @@ -15020,6 +14049,25 @@ "signal-exit": "^3.0.7" } }, + "ws": { + "version": "8.19.0", + "resolved": "https://registry.npmjs.org/ws/-/ws-8.19.0.tgz", + "integrity": "sha512-blAT2mjOEIi0ZzruJfIhb3nps74PRWTCz1IjglWEEpQl5XS/UNama6u2/rjFkDDouqr4L67ry+1aGIALViWjDg==", + "dev": true, + "requires": {} + }, + "xml-name-validator": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/xml-name-validator/-/xml-name-validator-5.0.0.tgz", + "integrity": "sha512-EvGK8EJ3DhaHfbRlETOWAS5pO9MZITeauHKJyb8wyajUfQUenkIg2MvLDTZ4T/TgIcm3HU0TFBgWWboAZ30UHg==", + "dev": true + }, + "xmlchars": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/xmlchars/-/xmlchars-2.2.0.tgz", + "integrity": "sha512-JZnDKK8B0RCDw84FNdDAIpZK+JuJw+s7Lz8nksI7SIuU3UXJJslUthsi+uWBUYOwPFwW7W7PRLRfUKpxjtjFCw==", + "dev": true + }, "y18n": { "version": "5.0.8", "resolved": "https://registry.npmjs.org/y18n/-/y18n-5.0.8.tgz", diff --git a/packages/dev/playcanvas/package.json b/packages/dev/playcanvas/package.json index 1830e1f3..a1394e53 100644 --- a/packages/dev/playcanvas/package.json +++ b/packages/dev/playcanvas/package.json @@ -54,24 +54,25 @@ "types": "./index.d.ts", "type": "module", "dependencies": { - "playcanvas": "2.14.4", - "@bitbybit-dev/core": "0.21.0" + "@bitbybit-dev/core": "0.21.0", + "playcanvas": "2.14.4" }, "devDependencies": { - "shx":"0.4.0", - "sass": "1.57.1", - "@testing-library/jest-dom": "5.14.1", - "mvdir": "1.0.21", - "jest": "29.4.1", - "ts-node": "10.9.1", - "ts-jest": "29.0.0", - "typescript": "4.8.2", - "@types/jest": "29.0.0", - "babel-jest": "29.0.0", "@babel/core": "7.16.0", "@babel/preset-env": "7.16.0", "@babel/preset-typescript": "7.16.0", - "jest-html-reporters": "3.0.11" + "@testing-library/jest-dom": "5.14.1", + "@types/jest": "29.0.0", + "babel-jest": "29.0.0", + "jest": "29.4.1", + "jest-environment-jsdom": "^30.2.0", + "jest-html-reporters": "3.0.11", + "mvdir": "1.0.21", + "sass": "1.57.1", + "shx": "0.4.0", + "ts-jest": "29.0.0", + "ts-node": "10.9.1", + "typescript": "4.8.2" }, "jest": { "preset": "ts-jest", diff --git a/packages/dev/threejs/lib/api/bitbybit/threejs/scene-helper.test.ts b/packages/dev/threejs/lib/api/bitbybit/threejs/scene-helper.test.ts new file mode 100644 index 00000000..d107df80 --- /dev/null +++ b/packages/dev/threejs/lib/api/bitbybit/threejs/scene-helper.test.ts @@ -0,0 +1,876 @@ +/** + * @jest-environment jsdom + */ +/* eslint-disable @typescript-eslint/no-unused-vars */ +/* eslint-disable @typescript-eslint/no-empty-function */ +import { ThreeJSScene } from "../../inputs/threejs-scene-inputs"; + +// Helper function to parse hex color +function hexToRgb(hex: string): { r: number; g: number; b: number } { + if (hex.length === 4) { + hex = "#" + hex[1] + hex[1] + hex[2] + hex[2] + hex[3] + hex[3]; + } + const result = /^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i.exec(hex); + if (!result) { + return { r: 0, g: 0, b: 0 }; + } + return { + r: parseInt(result[1], 16) / 255, + g: parseInt(result[2], 16) / 255, + b: parseInt(result[3], 16) / 255 + }; +} + +// Mock orbit camera result - defined before jest.mock +const mockOrbitCameraResult = { + camera: { aspect: 1, updateProjectionMatrix: jest.fn() }, + orbitCamera: { distance: 10, pitch: 0, yaw: 0, pivotPoint: { x: 0, y: 0, z: 0 } }, + mouseInput: { destroy: jest.fn() }, + touchInput: { destroy: jest.fn() }, + keyboardInput: { destroy: jest.fn() }, + update: jest.fn(), + destroy: jest.fn(), +}; + +// Mock three module - factory function creates classes inline +jest.mock("three", () => { + // Define mock classes inside the factory + class MockColor { + r: number; + g: number; + b: number; + + constructor(color?: string | number) { + if (typeof color === "string") { + // Parse hex color + const hex = color; + const result = /^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i.exec(hex); + if (result) { + this.r = parseInt(result[1], 16) / 255; + this.g = parseInt(result[2], 16) / 255; + this.b = parseInt(result[3], 16) / 255; + } else { + this.r = 0; + this.g = 0; + this.b = 0; + } + } else { + this.r = 0; + this.g = 0; + this.b = 0; + } + } + } + + class MockVector3 { + x: number; + y: number; + z: number; + + constructor(x = 0, y = 0, z = 0) { + this.x = x; + this.y = y; + this.z = z; + } + + set(x: number, y: number, z: number) { + this.x = x; + this.y = y; + this.z = z; + return this; + } + } + + class MockScene { + background: MockColor | null = null; + children: object[] = []; + + add(obj: object) { + this.children.push(obj); + } + + remove(obj: object) { + const idx = this.children.indexOf(obj); + if (idx > -1) { + this.children.splice(idx, 1); + } + } + } + + class MockHemisphereLight { + color: MockColor; + groundColor: MockColor; + intensity: number; + position = new MockVector3(); + + constructor(skyColor?: MockColor, groundColor?: MockColor, intensity?: number) { + this.color = skyColor || new MockColor(); + this.groundColor = groundColor || new MockColor(); + this.intensity = intensity || 1; + } + } + + class MockDirectionalLight { + color: MockColor; + intensity: number; + position = new MockVector3(); + castShadow = false; + target = { position: new MockVector3() }; + shadow = { + camera: { left: 0, right: 0, top: 0, bottom: 0, near: 0.1, far: 100 }, + mapSize: { width: 1024, height: 1024 }, + radius: 1, + blurSamples: 1, + bias: 0, + normalBias: 0, + }; + + constructor(color?: MockColor, intensity?: number) { + this.color = color || new MockColor(); + this.intensity = intensity || 1; + } + } + + class MockPlaneGeometry { + parameters = { width: 10, height: 10 }; + + constructor(width: number, height: number) { + this.parameters.width = width; + this.parameters.height = height; + } + + dispose() {} + } + + class MockMaterial { + color: MockColor = new MockColor(); + opacity = 1; + transparent = false; + side = 0; + roughness = 0.5; + metalness = 0.5; + + constructor(options?: object) { + if (options) { + Object.assign(this, options); + } + } + + dispose() {} + } + + class MockMesh { + geometry: MockPlaneGeometry; + material: MockMaterial; + rotation = { x: 0, y: 0, z: 0 }; + position = new MockVector3(); + receiveShadow = false; + + constructor(geometry: MockPlaneGeometry, material: MockMaterial) { + this.geometry = geometry; + this.material = material; + } + } + + class MockWebGLRenderer { + domElement: HTMLCanvasElement | null = null; + shadowMap = { enabled: false, type: 0 }; + _animationLoop: ((time: number) => void) | null = null; + + constructor(options: { antialias?: boolean; canvas?: HTMLCanvasElement }) { + // Canvas will be provided via options in the actual code + this.domElement = options.canvas || null; + } + + setSize(width: number, height: number) {} + setPixelRatio(ratio: number) {} + setAnimationLoop(callback: ((time: number) => void) | null) { + this._animationLoop = callback; + } + render(scene: MockScene, camera: object) {} + dispose() {} + } + + return { + Scene: MockScene, + Color: MockColor, + Vector3: MockVector3, + HemisphereLight: MockHemisphereLight, + DirectionalLight: MockDirectionalLight, + WebGLRenderer: MockWebGLRenderer, + PlaneGeometry: MockPlaneGeometry, + MeshStandardMaterial: MockMaterial, + Mesh: MockMesh, + VSMShadowMap: 2, + DoubleSide: 2, + }; +}); + +// Mock the orbit-camera module +jest.mock("./orbit-camera", () => ({ + createOrbitCamera: jest.fn().mockReturnValue({ + camera: { aspect: 1, updateProjectionMatrix: jest.fn() }, + orbitCamera: { distance: 10, pitch: 0, yaw: 0, pivotPoint: { x: 0, y: 0, z: 0 } }, + mouseInput: { destroy: jest.fn() }, + touchInput: { destroy: jest.fn() }, + keyboardInput: { destroy: jest.fn() }, + update: jest.fn(), + destroy: jest.fn(), + }), +})); + +// Import after mocks are defined +import { initThreeJS } from "./scene-helper"; + +describe("initThreeJS unit tests", () => { + let mockCanvas: HTMLCanvasElement; + + beforeEach(() => { + // Create a mock canvas element + mockCanvas = document.createElement("canvas"); + mockCanvas.id = "test-canvas"; + document.body.appendChild(mockCanvas); + + // Mock window properties + Object.defineProperty(window, "innerWidth", { value: 1920, writable: true }); + Object.defineProperty(window, "innerHeight", { value: 1080, writable: true }); + Object.defineProperty(window, "devicePixelRatio", { value: 1, writable: true }); + }); + + afterEach(() => { + // Clean up DOM + if (mockCanvas && mockCanvas.parentNode) { + mockCanvas.parentNode.removeChild(mockCanvas); + } + // Clean up any canvases created by tests + document.querySelectorAll("canvas").forEach(canvas => { + if (canvas.parentNode) { + canvas.parentNode.removeChild(canvas); + } + }); + jest.clearAllMocks(); + }); + + describe("initialization with defaults", () => { + it("should create scene with default configuration", () => { + // Arrange & Act + const result = initThreeJS(); + + // Assert + expect(result.scene).toBeDefined(); + expect(result.renderer).toBeDefined(); + expect(result.hemisphereLight).toBeDefined(); + expect(result.directionalLight).toBeDefined(); + expect(result.ground).toBeDefined(); + expect(typeof result.startAnimationLoop).toBe("function"); + expect(typeof result.dispose).toBe("function"); + + // Cleanup + result.dispose(); + }); + + it("should set default background color to #1a1c1f", () => { + // Arrange & Act + const result = initThreeJS(); + const expectedColor = hexToRgb("#1a1c1f"); + + // Assert + expect(result.scene.background).toBeDefined(); + const background = result.scene.background as { r: number; g: number; b: number }; + expect(Math.abs(background.r - expectedColor.r)).toBeLessThan(0.01); + expect(Math.abs(background.g - expectedColor.g)).toBeLessThan(0.01); + expect(Math.abs(background.b - expectedColor.b)).toBeLessThan(0.01); + + // Cleanup + result.dispose(); + }); + + it("should create hemisphere light with default settings", () => { + // Arrange + const defaultDto = new ThreeJSScene.InitThreeJSDto(); + + // Act + const result = initThreeJS(); + + // Assert + expect(result.hemisphereLight.intensity).toBe(defaultDto.hemisphereLightIntensity); + const expectedHeight = defaultDto.sceneSize * 0.75; + expect(result.hemisphereLight.position.y).toBeCloseTo(expectedHeight, 5); + + // Cleanup + result.dispose(); + }); + + it("should create directional light with default settings", () => { + // Arrange + const defaultDto = new ThreeJSScene.InitThreeJSDto(); + + // Act + const result = initThreeJS(); + + // Assert + expect(result.directionalLight.intensity).toBe(defaultDto.directionalLightIntensity); + const expectedOffset = defaultDto.sceneSize * 0.5; + const expectedHeight = defaultDto.sceneSize * 0.75; + expect(result.directionalLight.position.x).toBeCloseTo(expectedOffset, 5); + expect(result.directionalLight.position.y).toBeCloseTo(expectedHeight, 5); + expect(result.directionalLight.position.z).toBeCloseTo(expectedOffset, 5); + + // Cleanup + result.dispose(); + }); + }); + + describe("canvas handling", () => { + it("should use existing canvas when canvasId is provided", () => { + // Arrange + const config = new ThreeJSScene.InitThreeJSDto(); + config.canvasId = "test-canvas"; + + // Act + const result = initThreeJS(config); + + // Assert + expect(result.renderer.domElement).toBe(mockCanvas); + + // Cleanup + result.dispose(); + }); + + it("should throw error when canvas with provided id is not found", () => { + // Arrange + const config = new ThreeJSScene.InitThreeJSDto(); + config.canvasId = "nonexistent-canvas"; + + // Act & Assert + expect(() => initThreeJS(config)).toThrow("Canvas with id \"nonexistent-canvas\" not found"); + }); + + it("should create new canvas when canvasId is not provided", () => { + // Arrange & Act + const result = initThreeJS(); + + // Assert - canvas should be appended to document.body + expect(result.renderer.domElement).not.toBe(mockCanvas); + expect(result.renderer.domElement.style.width).toBe("100%"); + expect(result.renderer.domElement.style.height).toBe("100%"); + expect(result.renderer.domElement.style.display).toBe("block"); + + // Cleanup + result.dispose(); + }); + }); + + describe("shadow configuration", () => { + it("should enable shadows when enableShadows is true", () => { + // Arrange + const config = new ThreeJSScene.InitThreeJSDto(); + config.canvasId = "test-canvas"; + config.enableShadows = true; + + // Act + const result = initThreeJS(config); + + // Assert + expect(result.renderer.shadowMap.enabled).toBe(true); + expect(result.renderer.shadowMap.type).toBe(2); // VSMShadowMap + expect(result.directionalLight.castShadow).toBe(true); + + // Cleanup + result.dispose(); + }); + + it("should not enable shadows when enableShadows is false", () => { + // Arrange + const config = new ThreeJSScene.InitThreeJSDto(); + config.canvasId = "test-canvas"; + config.enableShadows = false; + + // Act + const result = initThreeJS(config); + + // Assert + expect(result.renderer.shadowMap.enabled).toBe(false); + expect(result.directionalLight.castShadow).toBe(false); + + // Cleanup + result.dispose(); + }); + + it("should configure shadow camera based on scene size", () => { + // Arrange + const config = new ThreeJSScene.InitThreeJSDto(); + config.canvasId = "test-canvas"; + config.sceneSize = 50; + config.groundScaleFactor = 2; + config.enableShadows = true; + + // Act + const result = initThreeJS(config); + + // Assert + const shadowCameraSize = config.sceneSize * config.groundScaleFactor; + expect(result.directionalLight.shadow.camera.left).toBe(-shadowCameraSize / 2); + expect(result.directionalLight.shadow.camera.right).toBe(shadowCameraSize / 2); + expect(result.directionalLight.shadow.camera.top).toBe(shadowCameraSize / 2); + expect(result.directionalLight.shadow.camera.bottom).toBe(-shadowCameraSize / 2); + expect(result.directionalLight.shadow.camera.far).toBe(config.sceneSize * 3); + + // Cleanup + result.dispose(); + }); + + it("should set shadow map size from config", () => { + // Arrange + const config = new ThreeJSScene.InitThreeJSDto(); + config.canvasId = "test-canvas"; + config.shadowMapSize = 4096; + config.enableShadows = true; + + // Act + const result = initThreeJS(config); + + // Assert + expect(result.directionalLight.shadow.mapSize.width).toBe(4096); + expect(result.directionalLight.shadow.mapSize.height).toBe(4096); + + // Cleanup + result.dispose(); + }); + }); + + describe("ground plane configuration", () => { + it("should create ground plane when enableGround is true", () => { + // Arrange + const config = new ThreeJSScene.InitThreeJSDto(); + config.canvasId = "test-canvas"; + config.enableGround = true; + + // Act + const result = initThreeJS(config); + + // Assert + expect(result.ground).toBeDefined(); + expect(result.ground).not.toBeNull(); + + // Cleanup + result.dispose(); + }); + + it("should not create ground plane when enableGround is false", () => { + // Arrange + const config = new ThreeJSScene.InitThreeJSDto(); + config.canvasId = "test-canvas"; + config.enableGround = false; + + // Act + const result = initThreeJS(config); + + // Assert + expect(result.ground).toBeNull(); + + // Cleanup + result.dispose(); + }); + + it("should position ground at specified center", () => { + // Arrange + const config = new ThreeJSScene.InitThreeJSDto(); + config.canvasId = "test-canvas"; + config.enableGround = true; + config.groundCenter = [5, -2, 10]; + + // Act + const result = initThreeJS(config); + + // Assert + expect(result.ground?.position.x).toBe(5); + expect(result.ground?.position.y).toBe(-2); + expect(result.ground?.position.z).toBe(10); + + // Cleanup + result.dispose(); + }); + + it("should rotate ground to be horizontal", () => { + // Arrange + const config = new ThreeJSScene.InitThreeJSDto(); + config.canvasId = "test-canvas"; + config.enableGround = true; + + // Act + const result = initThreeJS(config); + + // Assert + expect(result.ground?.rotation.x).toBeCloseTo(-Math.PI / 2, 5); + + // Cleanup + result.dispose(); + }); + + it("should apply ground color from config", () => { + // Arrange + const config = new ThreeJSScene.InitThreeJSDto(); + config.canvasId = "test-canvas"; + config.enableGround = true; + config.groundColor = "#ff0000"; + + // Act + const result = initThreeJS(config); + + // Assert + const material = result.ground?.material as unknown as { color: { r: number; g: number; b: number } }; + const expectedColor = hexToRgb("#ff0000"); + expect(Math.abs(material.color.r - expectedColor.r)).toBeLessThan(0.01); + expect(Math.abs(material.color.g - expectedColor.g)).toBeLessThan(0.01); + expect(Math.abs(material.color.b - expectedColor.b)).toBeLessThan(0.01); + + // Cleanup + result.dispose(); + }); + + it("should set ground opacity from config", () => { + // Arrange + const config = new ThreeJSScene.InitThreeJSDto(); + config.canvasId = "test-canvas"; + config.enableGround = true; + config.groundOpacity = 0.5; + + // Act + const result = initThreeJS(config); + + // Assert + const material = result.ground?.material as { transparent: boolean; opacity: number }; + expect(material.transparent).toBe(true); + expect(material.opacity).toBe(0.5); + + // Cleanup + result.dispose(); + }); + + it("should set ground to receive shadows when shadows are enabled", () => { + // Arrange + const config = new ThreeJSScene.InitThreeJSDto(); + config.canvasId = "test-canvas"; + config.enableGround = true; + config.enableShadows = true; + + // Act + const result = initThreeJS(config); + + // Assert + expect(result.ground?.receiveShadow).toBe(true); + + // Cleanup + result.dispose(); + }); + }); + + describe("orbit camera configuration", () => { + it("should create orbit camera when enableOrbitCamera is true", () => { + // Arrange + const config = new ThreeJSScene.InitThreeJSDto(); + config.canvasId = "test-canvas"; + config.enableOrbitCamera = true; + + // Act + const result = initThreeJS(config); + + // Assert + expect(result.orbitCamera).not.toBeNull(); + expect(result.orbitCamera?.camera).toBeDefined(); + + // Cleanup + result.dispose(); + }); + + it("should not create orbit camera when enableOrbitCamera is false", () => { + // Arrange + const config = new ThreeJSScene.InitThreeJSDto(); + config.canvasId = "test-canvas"; + config.enableOrbitCamera = false; + + // Act + const result = initThreeJS(config); + + // Assert + expect(result.orbitCamera).toBeNull(); + + // Cleanup + result.dispose(); + }); + }); + + describe("scene size scaling", () => { + it("should scale light positions based on scene size", () => { + // Arrange + const config = new ThreeJSScene.InitThreeJSDto(); + config.canvasId = "test-canvas"; + config.sceneSize = 100; + + // Act + const result = initThreeJS(config); + + // Assert + const expectedHeight = config.sceneSize * 0.75; // 75 + const expectedOffset = config.sceneSize * 0.5; // 50 + expect(result.hemisphereLight.position.y).toBeCloseTo(expectedHeight, 5); + expect(result.directionalLight.position.x).toBeCloseTo(expectedOffset, 5); + expect(result.directionalLight.position.y).toBeCloseTo(expectedHeight, 5); + expect(result.directionalLight.position.z).toBeCloseTo(expectedOffset, 5); + + // Cleanup + result.dispose(); + }); + + it("should scale ground size based on scene size and groundScaleFactor", () => { + // Arrange + const config = new ThreeJSScene.InitThreeJSDto(); + config.canvasId = "test-canvas"; + config.sceneSize = 50; + config.groundScaleFactor = 3; + config.enableGround = true; + + // Act + const result = initThreeJS(config); + + // Assert + const geometry = result.ground?.geometry as unknown as { parameters: { width: number; height: number } }; + const expectedSize = config.sceneSize * config.groundScaleFactor; // 150 + expect(geometry.parameters.width).toBe(expectedSize); + expect(geometry.parameters.height).toBe(expectedSize); + + // Cleanup + result.dispose(); + }); + }); + + describe("light color configuration", () => { + it("should apply hemisphere light sky color from config", () => { + // Arrange + const config = new ThreeJSScene.InitThreeJSDto(); + config.canvasId = "test-canvas"; + config.hemisphereLightSkyColor = "#00ff00"; + + // Act + const result = initThreeJS(config); + + // Assert + const expectedColor = hexToRgb("#00ff00"); + expect(result.hemisphereLight.color.r).toBeCloseTo(expectedColor.r, 2); + expect(result.hemisphereLight.color.g).toBeCloseTo(expectedColor.g, 2); + expect(result.hemisphereLight.color.b).toBeCloseTo(expectedColor.b, 2); + + // Cleanup + result.dispose(); + }); + + it("should apply hemisphere light ground color from config", () => { + // Arrange + const config = new ThreeJSScene.InitThreeJSDto(); + config.canvasId = "test-canvas"; + config.hemisphereLightGroundColor = "#0000ff"; + + // Act + const result = initThreeJS(config); + + // Assert + const expectedColor = hexToRgb("#0000ff"); + expect(result.hemisphereLight.groundColor.r).toBeCloseTo(expectedColor.r, 2); + expect(result.hemisphereLight.groundColor.g).toBeCloseTo(expectedColor.g, 2); + expect(result.hemisphereLight.groundColor.b).toBeCloseTo(expectedColor.b, 2); + + // Cleanup + result.dispose(); + }); + + it("should apply directional light color from config", () => { + // Arrange + const config = new ThreeJSScene.InitThreeJSDto(); + config.canvasId = "test-canvas"; + config.directionalLightColor = "#ffff00"; + + // Act + const result = initThreeJS(config); + + // Assert + const expectedColor = hexToRgb("#ffff00"); + expect(result.directionalLight.color.r).toBeCloseTo(expectedColor.r, 2); + expect(result.directionalLight.color.g).toBeCloseTo(expectedColor.g, 2); + expect(result.directionalLight.color.b).toBeCloseTo(expectedColor.b, 2); + + // Cleanup + result.dispose(); + }); + + it("should apply light intensities from config", () => { + // Arrange + const config = new ThreeJSScene.InitThreeJSDto(); + config.canvasId = "test-canvas"; + config.hemisphereLightIntensity = 2.5; + config.directionalLightIntensity = 3.0; + + // Act + const result = initThreeJS(config); + + // Assert + expect(result.hemisphereLight.intensity).toBe(2.5); + expect(result.directionalLight.intensity).toBe(3.0); + + // Cleanup + result.dispose(); + }); + }); + + describe("dispose method", () => { + it("should remove window resize event listener on dispose", () => { + // Arrange + const removeEventListenerSpy = jest.spyOn(window, "removeEventListener"); + const result = initThreeJS(); + + // Act + result.dispose(); + + // Assert + expect(removeEventListenerSpy).toHaveBeenCalledWith("resize", expect.any(Function)); + + // Cleanup + removeEventListenerSpy.mockRestore(); + }); + + it("should stop animation loop on dispose", () => { + // Arrange + const result = initThreeJS(); + const setAnimationLoopSpy = jest.spyOn(result.renderer, "setAnimationLoop"); + + // Act + result.dispose(); + + // Assert + expect(setAnimationLoopSpy).toHaveBeenCalledWith(null); + }); + + it("should dispose renderer on cleanup", () => { + // Arrange + const result = initThreeJS(); + const disposeSpy = jest.spyOn(result.renderer, "dispose"); + + // Act + result.dispose(); + + // Assert + expect(disposeSpy).toHaveBeenCalled(); + }); + + it("should dispose ground geometry and material on cleanup", () => { + // Arrange + const config = new ThreeJSScene.InitThreeJSDto(); + config.enableGround = true; + const result = initThreeJS(config); + const ground = result.ground as { geometry: { dispose: () => void }; material: { dispose: () => void } }; + const geometryDisposeSpy = jest.spyOn(ground.geometry, "dispose"); + const materialDisposeSpy = jest.spyOn(ground.material, "dispose"); + + // Act + result.dispose(); + + // Assert + expect(geometryDisposeSpy).toHaveBeenCalled(); + expect(materialDisposeSpy).toHaveBeenCalled(); + }); + + it("should remove lights from scene on dispose", () => { + // Arrange + const result = initThreeJS(); + const sceneRemoveSpy = jest.spyOn(result.scene, "remove"); + + // Act + result.dispose(); + + // Assert + expect(sceneRemoveSpy).toHaveBeenCalledWith(result.hemisphereLight); + expect(sceneRemoveSpy).toHaveBeenCalledWith(result.directionalLight); + expect(sceneRemoveSpy).toHaveBeenCalledWith(result.directionalLight.target); + }); + + it("should destroy orbit camera on dispose when enabled", () => { + // Arrange + const config = new ThreeJSScene.InitThreeJSDto(); + config.enableOrbitCamera = true; + const result = initThreeJS(config); + + // Act + result.dispose(); + + // Assert + expect(result.orbitCamera?.destroy).toHaveBeenCalled(); + }); + + it("should remove created canvas from DOM on dispose", () => { + // Arrange - no canvasId means a new canvas is created + const result = initThreeJS(); + const canvas = result.renderer.domElement; + expect(canvas.parentNode).toBe(document.body); + + // Act + result.dispose(); + + // Assert + expect(canvas.parentNode).toBeNull(); + }); + + it("should not remove canvas from DOM when canvasId was provided", () => { + // Arrange + const config = new ThreeJSScene.InitThreeJSDto(); + config.canvasId = "test-canvas"; + const result = initThreeJS(config); + + // Act + result.dispose(); + + // Assert - canvas should still be in DOM + expect(mockCanvas.parentNode).toBe(document.body); + }); + }); + + describe("startAnimationLoop method", () => { + it("should set animation loop on renderer", () => { + // Arrange + const result = initThreeJS(); + const setAnimationLoopSpy = jest.spyOn(result.renderer, "setAnimationLoop"); + + // Act + result.startAnimationLoop(); + + // Assert + expect(setAnimationLoopSpy).toHaveBeenCalledWith(expect.any(Function)); + + // Cleanup + result.dispose(); + }); + + it("should call onRender callback when provided", () => { + // Arrange + const result = initThreeJS(); + const onRenderMock = jest.fn(); + let animateCallback: ((time: number, frame?: XRFrame) => void) | null = null; + + jest.spyOn(result.renderer, "setAnimationLoop").mockImplementation((callback) => { + animateCallback = callback; + }); + + // Act + result.startAnimationLoop(onRenderMock); + // Simulate one frame + if (animateCallback) { + (animateCallback as (time: number) => void)(0); + } + + // Assert + expect(onRenderMock).toHaveBeenCalledWith(expect.any(Number)); + + // Cleanup + result.dispose(); + }); + }); +}); diff --git a/packages/dev/threejs/lib/api/inputs/threejs-camera-inputs.test.ts b/packages/dev/threejs/lib/api/inputs/threejs-camera-inputs.test.ts index 2ba03534..199bb011 100644 --- a/packages/dev/threejs/lib/api/inputs/threejs-camera-inputs.test.ts +++ b/packages/dev/threejs/lib/api/inputs/threejs-camera-inputs.test.ts @@ -73,7 +73,7 @@ describe("ThreeJSCamera DTO unit tests", () => { expect(result.orbitSensitivity).toBe(0.3); expect(result.distanceSensitivity).toBe(0.15); expect(result.panSensitivity).toBe(1); - expect(result.inertiaFactor).toBe(0); + expect(result.inertiaFactor).toBe(0.1); expect(result.autoRender).toBe(true); expect(result.frameOnStart).toBe(true); expect(result.enableDamping).toBe(true); diff --git a/packages/dev/threejs/package-lock.json b/packages/dev/threejs/package-lock.json index cc9ffacc..1e0b3ca8 100644 --- a/packages/dev/threejs/package-lock.json +++ b/packages/dev/threejs/package-lock.json @@ -21,6 +21,7 @@ "@types/three": "0.182.0", "babel-jest": "29.0.0", "jest": "29.4.1", + "jest-environment-jsdom": "^30.2.0", "jest-html-reporters": "3.0.11", "mvdir": "1.0.21", "sass": "1.57.1", @@ -30,13 +31,37 @@ "typescript": "4.8.2" } }, + "node_modules/@asamuzakjp/css-color": { + "version": "3.2.0", + "resolved": "https://registry.npmjs.org/@asamuzakjp/css-color/-/css-color-3.2.0.tgz", + "integrity": "sha512-K1A6z8tS3XsmCMM86xoWdn7Fkdn9m6RSVtocUrJYIwZnFVkng/PvkEoWtOWmP+Scc6saYWHWZYbndEEXxl24jw==", + "dev": true, + "license": "MIT", + "dependencies": { + "@csstools/css-calc": "^2.1.3", + "@csstools/css-color-parser": "^3.0.9", + "@csstools/css-parser-algorithms": "^3.0.4", + "@csstools/css-tokenizer": "^3.0.3", + "lru-cache": "^10.4.3" + } + }, + "node_modules/@asamuzakjp/css-color/node_modules/lru-cache": { + "version": "10.4.3", + "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-10.4.3.tgz", + "integrity": "sha512-JNAzZcXrCt42VGLuYz0zfAzDfAvJWW6AfYlDBQyDV5DClI2m5sAmK+OIO7s59XfsRsWHp02jAJrRadPRGTt6SQ==", + "dev": true, + "license": "ISC" + }, "node_modules/@babel/code-frame": { - "version": "7.18.6", - "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.18.6.tgz", - "integrity": "sha512-TDCmlK5eOvH+eH7cdAFlNXeVJqWIQ7gW9tY1GJIpUtFb6CmjVyq2VM3u71bOyR8CRihcCgMUYoDNyLXao3+70Q==", + "version": "7.28.6", + "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.28.6.tgz", + "integrity": "sha512-JYgintcMjRiCvS8mMECzaEn+m3PfoQiyqukOMCCVQtoJGYJw8j/8LBJEiqkHLkfwCcs74E3pbAUFNg7d9VNJ+Q==", "dev": true, + "license": "MIT", "dependencies": { - "@babel/highlight": "^7.18.6" + "@babel/helper-validator-identifier": "^7.28.5", + "js-tokens": "^4.0.0", + "picocolors": "^1.1.1" }, "engines": { "node": ">=6.9.0" @@ -388,10 +413,11 @@ } }, "node_modules/@babel/helper-validator-identifier": { - "version": "7.19.1", - "resolved": "https://registry.npmjs.org/@babel/helper-validator-identifier/-/helper-validator-identifier-7.19.1.tgz", - "integrity": "sha512-awrNfaMtnHUr653GgGEs++LlAvW6w+DcPrOliSMXWCKo597CwL5Acf/wWdNkf/tfEQE3mjkeD1YOVZOUV/od1w==", + "version": "7.28.5", + "resolved": "https://registry.npmjs.org/@babel/helper-validator-identifier/-/helper-validator-identifier-7.28.5.tgz", + "integrity": "sha512-qSs4ifwzKJSV39ucNjsvc6WVHs6b7S03sOh2OcHF9UHfVPqWWALUsNUVzhSBiItjRZoLHx7nIarVjqKVusUZ1Q==", "dev": true, + "license": "MIT", "engines": { "node": ">=6.9.0" } @@ -434,20 +460,6 @@ "node": ">=6.9.0" } }, - "node_modules/@babel/highlight": { - "version": "7.18.6", - "resolved": "https://registry.npmjs.org/@babel/highlight/-/highlight-7.18.6.tgz", - "integrity": "sha512-u7stbOuYjaPezCuLj29hNW1v64M2Md2qupEKP1fHc7WdOA3DgLh37suiSrZYY7haUB7iBeQZ9P1uiRF359do3g==", - "dev": true, - "dependencies": { - "@babel/helper-validator-identifier": "^7.18.6", - "chalk": "^2.0.0", - "js-tokens": "^4.0.0" - }, - "engines": { - "node": ">=6.9.0" - } - }, "node_modules/@babel/parser": { "version": "7.21.2", "resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.21.2.tgz", @@ -1809,6 +1821,121 @@ "@jridgewell/sourcemap-codec": "^1.4.10" } }, + "node_modules/@csstools/color-helpers": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/@csstools/color-helpers/-/color-helpers-5.1.0.tgz", + "integrity": "sha512-S11EXWJyy0Mz5SYvRmY8nJYTFFd1LCNV+7cXyAgQtOOuzb4EsgfqDufL+9esx72/eLhsRdGZwaldu/h+E4t4BA==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/csstools" + }, + { + "type": "opencollective", + "url": "https://opencollective.com/csstools" + } + ], + "license": "MIT-0", + "engines": { + "node": ">=18" + } + }, + "node_modules/@csstools/css-calc": { + "version": "2.1.4", + "resolved": "https://registry.npmjs.org/@csstools/css-calc/-/css-calc-2.1.4.tgz", + "integrity": "sha512-3N8oaj+0juUw/1H3YwmDDJXCgTB1gKU6Hc/bB502u9zR0q2vd786XJH9QfrKIEgFlZmhZiq6epXl4rHqhzsIgQ==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/csstools" + }, + { + "type": "opencollective", + "url": "https://opencollective.com/csstools" + } + ], + "license": "MIT", + "engines": { + "node": ">=18" + }, + "peerDependencies": { + "@csstools/css-parser-algorithms": "^3.0.5", + "@csstools/css-tokenizer": "^3.0.4" + } + }, + "node_modules/@csstools/css-color-parser": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/@csstools/css-color-parser/-/css-color-parser-3.1.0.tgz", + "integrity": "sha512-nbtKwh3a6xNVIp/VRuXV64yTKnb1IjTAEEh3irzS+HkKjAOYLTGNb9pmVNntZ8iVBHcWDA2Dof0QtPgFI1BaTA==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/csstools" + }, + { + "type": "opencollective", + "url": "https://opencollective.com/csstools" + } + ], + "license": "MIT", + "dependencies": { + "@csstools/color-helpers": "^5.1.0", + "@csstools/css-calc": "^2.1.4" + }, + "engines": { + "node": ">=18" + }, + "peerDependencies": { + "@csstools/css-parser-algorithms": "^3.0.5", + "@csstools/css-tokenizer": "^3.0.4" + } + }, + "node_modules/@csstools/css-parser-algorithms": { + "version": "3.0.5", + "resolved": "https://registry.npmjs.org/@csstools/css-parser-algorithms/-/css-parser-algorithms-3.0.5.tgz", + "integrity": "sha512-DaDeUkXZKjdGhgYaHNJTV9pV7Y9B3b644jCLs9Upc3VeNGg6LWARAT6O+Q+/COo+2gg/bM5rhpMAtf70WqfBdQ==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/csstools" + }, + { + "type": "opencollective", + "url": "https://opencollective.com/csstools" + } + ], + "license": "MIT", + "engines": { + "node": ">=18" + }, + "peerDependencies": { + "@csstools/css-tokenizer": "^3.0.4" + } + }, + "node_modules/@csstools/css-tokenizer": { + "version": "3.0.4", + "resolved": "https://registry.npmjs.org/@csstools/css-tokenizer/-/css-tokenizer-3.0.4.tgz", + "integrity": "sha512-Vd/9EVDiu6PPJt9yAh6roZP6El1xHrdvIVGjyBsHR0RYwNHgL7FJPyIIW4fANJNG6FtyZfvlRPpFI4ZM/lubvw==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/csstools" + }, + { + "type": "opencollective", + "url": "https://opencollective.com/csstools" + } + ], + "license": "MIT", + "engines": { + "node": ">=18" + } + }, "node_modules/@dimforge/rapier3d-compat": { "version": "0.12.0", "resolved": "https://registry.npmjs.org/@dimforge/rapier3d-compat/-/rapier3d-compat-0.12.0.tgz", @@ -2374,76 +2501,6 @@ "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, - "node_modules/@jest/console/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/@jest/console/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" - } - }, - "node_modules/@jest/console/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/@jest/console/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "node_modules/@jest/console/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/@jest/console/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, "node_modules/@jest/core": { "version": "29.4.3", "resolved": "https://registry.npmjs.org/@jest/core/-/core-29.4.3.tgz", @@ -2491,119 +2548,281 @@ } } }, - "node_modules/@jest/core/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "node_modules/@jest/environment": { + "version": "29.4.3", + "resolved": "https://registry.npmjs.org/@jest/environment/-/environment-29.4.3.tgz", + "integrity": "sha512-dq5S6408IxIa+lr54zeqce+QgI+CJT4nmmA+1yzFgtcsGK8c/EyiUb9XQOgz3BMKrRDfKseeOaxj2eO8LlD3lA==", "dev": true, "dependencies": { - "color-convert": "^2.0.1" + "@jest/fake-timers": "^29.4.3", + "@jest/types": "^29.4.3", + "@types/node": "*", + "jest-mock": "^29.4.3" }, "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, - "node_modules/@jest/core/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "node_modules/@jest/environment-jsdom-abstract": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/environment-jsdom-abstract/-/environment-jsdom-abstract-30.2.0.tgz", + "integrity": "sha512-kazxw2L9IPuZpQ0mEt9lu9Z98SqR74xcagANmMBU16X0lS23yPc0+S6hGLUz8kVRlomZEs/5S/Zlpqwf5yu6OQ==", "dev": true, + "license": "MIT", "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" + "@jest/environment": "30.2.0", + "@jest/fake-timers": "30.2.0", + "@jest/types": "30.2.0", + "@types/jsdom": "^21.1.7", + "@types/node": "*", + "jest-mock": "30.2.0", + "jest-util": "30.2.0" }, "engines": { - "node": ">=10" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" + "peerDependencies": { + "canvas": "^3.0.0", + "jsdom": "*" + }, + "peerDependenciesMeta": { + "canvas": { + "optional": true + } } }, - "node_modules/@jest/core/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "node_modules/@jest/environment-jsdom-abstract/node_modules/@jest/environment": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/environment/-/environment-30.2.0.tgz", + "integrity": "sha512-/QPTL7OBJQ5ac09UDRa3EQes4gt1FTEG/8jZ/4v5IVzx+Cv7dLxlVIvfvSVRiiX2drWyXeBjkMSR8hvOWSog5g==", "dev": true, + "license": "MIT", "dependencies": { - "color-name": "~1.1.4" + "@jest/fake-timers": "30.2.0", + "@jest/types": "30.2.0", + "@types/node": "*", + "jest-mock": "30.2.0" }, "engines": { - "node": ">=7.0.0" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/@jest/core/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "node_modules/@jest/core/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "node_modules/@jest/environment-jsdom-abstract/node_modules/@jest/fake-timers": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/fake-timers/-/fake-timers-30.2.0.tgz", + "integrity": "sha512-HI3tRLjRxAbBy0VO8dqqm7Hb2mIa8d5bg/NJkyQcOk7V118ObQML8RC5luTF/Zsg4474a+gDvhce7eTnP4GhYw==", "dev": true, + "license": "MIT", + "dependencies": { + "@jest/types": "30.2.0", + "@sinonjs/fake-timers": "^13.0.0", + "@types/node": "*", + "jest-message-util": "30.2.0", + "jest-mock": "30.2.0", + "jest-util": "30.2.0" + }, "engines": { - "node": ">=8" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/@jest/core/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "node_modules/@jest/environment-jsdom-abstract/node_modules/@jest/schemas": { + "version": "30.0.5", + "resolved": "https://registry.npmjs.org/@jest/schemas/-/schemas-30.0.5.tgz", + "integrity": "sha512-DmdYgtezMkh3cpU8/1uyXakv3tJRcmcXxBOcO0tbaozPwpmh4YMsnWrQm9ZmZMfa5ocbxzbFk6O4bDPEc/iAnA==", "dev": true, + "license": "MIT", "dependencies": { - "has-flag": "^4.0.0" + "@sinclair/typebox": "^0.34.0" }, "engines": { - "node": ">=8" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/@jest/environment": { - "version": "29.4.3", - "resolved": "https://registry.npmjs.org/@jest/environment/-/environment-29.4.3.tgz", - "integrity": "sha512-dq5S6408IxIa+lr54zeqce+QgI+CJT4nmmA+1yzFgtcsGK8c/EyiUb9XQOgz3BMKrRDfKseeOaxj2eO8LlD3lA==", + "node_modules/@jest/environment-jsdom-abstract/node_modules/@jest/types": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/types/-/types-30.2.0.tgz", + "integrity": "sha512-H9xg1/sfVvyfU7o3zMfBEjQ1gcsdeTMgqHoYdN79tuLqfTtuu7WckRA1R5whDwOzxaZAeMKTYWqP+WCAi0CHsg==", "dev": true, + "license": "MIT", "dependencies": { - "@jest/fake-timers": "^29.4.3", - "@jest/types": "^29.4.3", + "@jest/pattern": "30.0.1", + "@jest/schemas": "30.0.5", + "@types/istanbul-lib-coverage": "^2.0.6", + "@types/istanbul-reports": "^3.0.4", "@types/node": "*", - "jest-mock": "^29.4.3" + "@types/yargs": "^17.0.33", + "chalk": "^4.1.2" }, "engines": { - "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/@jest/expect": { - "version": "29.4.3", - "resolved": "https://registry.npmjs.org/@jest/expect/-/expect-29.4.3.tgz", - "integrity": "sha512-iktRU/YsxEtumI9zsPctYUk7ptpC+AVLLk1Ax3AsA4g1C+8OOnKDkIQBDHtD5hA/+VtgMd5AWI5gNlcAlt2vxQ==", + "node_modules/@jest/environment-jsdom-abstract/node_modules/@sinclair/typebox": { + "version": "0.34.47", + "resolved": "https://registry.npmjs.org/@sinclair/typebox/-/typebox-0.34.47.tgz", + "integrity": "sha512-ZGIBQ+XDvO5JQku9wmwtabcVTHJsgSWAHYtVuM9pBNNR5E88v6Jcj/llpmsjivig5X8A8HHOb4/mbEKPS5EvAw==", + "dev": true, + "license": "MIT" + }, + "node_modules/@jest/environment-jsdom-abstract/node_modules/@sinonjs/commons": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/@sinonjs/commons/-/commons-3.0.1.tgz", + "integrity": "sha512-K3mCHKQ9sVh8o1C9cxkwxaOmXoAMlDxC1mYyHrjqOWEcBjYr76t96zL2zlj5dUGZ3HSw240X1qgH3Mjf1yJWpQ==", "dev": true, + "license": "BSD-3-Clause", "dependencies": { - "expect": "^29.4.3", - "jest-snapshot": "^29.4.3" - }, - "engines": { - "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + "type-detect": "4.0.8" } }, - "node_modules/@jest/expect-utils": { - "version": "29.4.3", - "resolved": "https://registry.npmjs.org/@jest/expect-utils/-/expect-utils-29.4.3.tgz", - "integrity": "sha512-/6JWbkxHOP8EoS8jeeTd9dTfc9Uawi+43oLKHfp6zzux3U2hqOOVnV3ai4RpDYHOccL6g+5nrxpoc8DmJxtXVQ==", + "node_modules/@jest/environment-jsdom-abstract/node_modules/@sinonjs/fake-timers": { + "version": "13.0.5", + "resolved": "https://registry.npmjs.org/@sinonjs/fake-timers/-/fake-timers-13.0.5.tgz", + "integrity": "sha512-36/hTbH2uaWuGVERyC6da9YwGWnzUZXuPro/F2LfsdOsLnCojz/iSH8MxUt/FD2S5XBSVPhmArFUXcpCQ2Hkiw==", "dev": true, + "license": "BSD-3-Clause", "dependencies": { - "jest-get-type": "^29.4.3" - }, - "engines": { - "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + "@sinonjs/commons": "^3.0.1" } }, - "node_modules/@jest/fake-timers": { - "version": "29.4.3", - "resolved": "https://registry.npmjs.org/@jest/fake-timers/-/fake-timers-29.4.3.tgz", + "node_modules/@jest/environment-jsdom-abstract/node_modules/ci-info": { + "version": "4.3.1", + "resolved": "https://registry.npmjs.org/ci-info/-/ci-info-4.3.1.tgz", + "integrity": "sha512-Wdy2Igu8OcBpI2pZePZ5oWjPC38tmDVx5WKUXKwlLYkA0ozo85sLsLvkBbBn/sZaSCMFOGZJ14fvW9t5/d7kdA==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/sibiraj-s" + } + ], + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "node_modules/@jest/environment-jsdom-abstract/node_modules/jest-message-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-message-util/-/jest-message-util-30.2.0.tgz", + "integrity": "sha512-y4DKFLZ2y6DxTWD4cDe07RglV88ZiNEdlRfGtqahfbIjfsw1nMCPx49Uev4IA/hWn3sDKyAnSPwoYSsAEdcimw==", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/code-frame": "^7.27.1", + "@jest/types": "30.2.0", + "@types/stack-utils": "^2.0.3", + "chalk": "^4.1.2", + "graceful-fs": "^4.2.11", + "micromatch": "^4.0.8", + "pretty-format": "30.2.0", + "slash": "^3.0.0", + "stack-utils": "^2.0.6" + }, + "engines": { + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" + } + }, + "node_modules/@jest/environment-jsdom-abstract/node_modules/jest-mock": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-mock/-/jest-mock-30.2.0.tgz", + "integrity": "sha512-JNNNl2rj4b5ICpmAcq+WbLH83XswjPbjH4T7yvGzfAGCPh1rw+xVNbtk+FnRslvt9lkCcdn9i1oAoKUuFsOxRw==", + "dev": true, + "license": "MIT", + "dependencies": { + "@jest/types": "30.2.0", + "@types/node": "*", + "jest-util": "30.2.0" + }, + "engines": { + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" + } + }, + "node_modules/@jest/environment-jsdom-abstract/node_modules/jest-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-30.2.0.tgz", + "integrity": "sha512-QKNsM0o3Xe6ISQU869e+DhG+4CK/48aHYdJZGlFQVTjnbvgpcKyxpzk29fGiO7i/J8VENZ+d2iGnSsvmuHywlA==", + "dev": true, + "license": "MIT", + "dependencies": { + "@jest/types": "30.2.0", + "@types/node": "*", + "chalk": "^4.1.2", + "ci-info": "^4.2.0", + "graceful-fs": "^4.2.11", + "picomatch": "^4.0.2" + }, + "engines": { + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" + } + }, + "node_modules/@jest/environment-jsdom-abstract/node_modules/picomatch": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.3.tgz", + "integrity": "sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=12" + }, + "funding": { + "url": "https://github.com/sponsors/jonschlinkert" + } + }, + "node_modules/@jest/environment-jsdom-abstract/node_modules/pretty-format": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/pretty-format/-/pretty-format-30.2.0.tgz", + "integrity": "sha512-9uBdv/B4EefsuAL+pWqueZyZS2Ba+LxfFeQ9DN14HU4bN8bhaxKdkpjpB6fs9+pSjIBu+FXQHImEg8j/Lw0+vA==", + "dev": true, + "license": "MIT", + "dependencies": { + "@jest/schemas": "30.0.5", + "ansi-styles": "^5.2.0", + "react-is": "^18.3.1" + }, + "engines": { + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" + } + }, + "node_modules/@jest/environment-jsdom-abstract/node_modules/pretty-format/node_modules/ansi-styles": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-5.2.0.tgz", + "integrity": "sha512-Cxwpt2SfTzTtXcfOlzGEee8O+c+MmUgGrNiBcXnuWxuFJHe6a5Hz7qwhwe5OgaSYI0IJvkLqWX1ASG+cJOkEiA==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/@jest/expect": { + "version": "29.4.3", + "resolved": "https://registry.npmjs.org/@jest/expect/-/expect-29.4.3.tgz", + "integrity": "sha512-iktRU/YsxEtumI9zsPctYUk7ptpC+AVLLk1Ax3AsA4g1C+8OOnKDkIQBDHtD5hA/+VtgMd5AWI5gNlcAlt2vxQ==", + "dev": true, + "dependencies": { + "expect": "^29.4.3", + "jest-snapshot": "^29.4.3" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/@jest/expect-utils": { + "version": "29.4.3", + "resolved": "https://registry.npmjs.org/@jest/expect-utils/-/expect-utils-29.4.3.tgz", + "integrity": "sha512-/6JWbkxHOP8EoS8jeeTd9dTfc9Uawi+43oLKHfp6zzux3U2hqOOVnV3ai4RpDYHOccL6g+5nrxpoc8DmJxtXVQ==", + "dev": true, + "dependencies": { + "jest-get-type": "^29.4.3" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/@jest/fake-timers": { + "version": "29.4.3", + "resolved": "https://registry.npmjs.org/@jest/fake-timers/-/fake-timers-29.4.3.tgz", "integrity": "sha512-4Hote2MGcCTWSD2gwl0dwbCpBRHhE6olYEuTj8FMowdg3oQWNKr2YuxenPQYZ7+PfqPY1k98wKDU4Z+Hvd4Tiw==", "dev": true, "dependencies": { @@ -2633,6 +2852,30 @@ "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, + "node_modules/@jest/pattern": { + "version": "30.0.1", + "resolved": "https://registry.npmjs.org/@jest/pattern/-/pattern-30.0.1.tgz", + "integrity": "sha512-gWp7NfQW27LaBQz3TITS8L7ZCQ0TLvtmI//4OwlQRx4rnWxcPNIYjxZpDcN4+UlGxgm3jS5QPz8IPTCkb59wZA==", + "dev": true, + "license": "MIT", + "dependencies": { + "@types/node": "*", + "jest-regex-util": "30.0.1" + }, + "engines": { + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" + } + }, + "node_modules/@jest/pattern/node_modules/jest-regex-util": { + "version": "30.0.1", + "resolved": "https://registry.npmjs.org/jest-regex-util/-/jest-regex-util-30.0.1.tgz", + "integrity": "sha512-jHEQgBXAgc+Gh4g0p3bCevgRCVRkB4VB70zhoAE48gxeSr1hfUOsM/C2WoJgVL7Eyg//hudYENbm3Ne+/dRVVA==", + "dev": true, + "license": "MIT", + "engines": { + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" + } + }, "node_modules/@jest/reporters": { "version": "29.4.3", "resolved": "https://registry.npmjs.org/@jest/reporters/-/reporters-29.4.3.tgz", @@ -2676,76 +2919,6 @@ } } }, - "node_modules/@jest/reporters/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/@jest/reporters/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" - } - }, - "node_modules/@jest/reporters/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/@jest/reporters/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "node_modules/@jest/reporters/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/@jest/reporters/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, "node_modules/@jest/schemas": { "version": "29.4.3", "resolved": "https://registry.npmjs.org/@jest/schemas/-/schemas-29.4.3.tgz", @@ -2828,82 +3001,12 @@ "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, - "node_modules/@jest/transform/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/@jest/transform/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" - } - }, - "node_modules/@jest/transform/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/@jest/transform/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, "node_modules/@jest/transform/node_modules/convert-source-map": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/convert-source-map/-/convert-source-map-2.0.0.tgz", "integrity": "sha512-Kvp459HrV2FEJ1CAsi1Ku+MY3kasH19TFykTz2xWmMeq6bk2NU3XXvfJ+Q61m0xktWwt+1HSYf3JZsTms3aRJg==", "dev": true }, - "node_modules/@jest/transform/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/@jest/transform/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, "node_modules/@jest/types": { "version": "29.4.3", "resolved": "https://registry.npmjs.org/@jest/types/-/types-29.4.3.tgz", @@ -2921,88 +3024,18 @@ "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, - "node_modules/@jest/types/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "node_modules/@jridgewell/gen-mapping": { + "version": "0.3.2", + "resolved": "https://registry.npmjs.org/@jridgewell/gen-mapping/-/gen-mapping-0.3.2.tgz", + "integrity": "sha512-mh65xKQAzI6iBcFzwv28KVWSmCkdRBWoOh+bYQGW3+6OZvbbN3TqMGo5hqYxQniRcH9F2VZIoJCm4pa3BPDK/A==", "dev": true, "dependencies": { - "color-convert": "^2.0.1" + "@jridgewell/set-array": "^1.0.1", + "@jridgewell/sourcemap-codec": "^1.4.10", + "@jridgewell/trace-mapping": "^0.3.9" }, "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/@jest/types/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" - } - }, - "node_modules/@jest/types/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/@jest/types/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "node_modules/@jest/types/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/@jest/types/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/@jridgewell/gen-mapping": { - "version": "0.3.2", - "resolved": "https://registry.npmjs.org/@jridgewell/gen-mapping/-/gen-mapping-0.3.2.tgz", - "integrity": "sha512-mh65xKQAzI6iBcFzwv28KVWSmCkdRBWoOh+bYQGW3+6OZvbbN3TqMGo5hqYxQniRcH9F2VZIoJCm4pa3BPDK/A==", - "dev": true, - "dependencies": { - "@jridgewell/set-array": "^1.0.1", - "@jridgewell/sourcemap-codec": "^1.4.10", - "@jridgewell/trace-mapping": "^0.3.9" - }, - "engines": { - "node": ">=6.0.0" + "node": ">=6.0.0" } }, "node_modules/@jridgewell/resolve-uri": { @@ -3199,21 +3232,6 @@ "yarn": ">=1" } }, - "node_modules/@testing-library/jest-dom/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, "node_modules/@testing-library/jest-dom/node_modules/chalk": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/chalk/-/chalk-3.0.0.tgz", @@ -3227,45 +3245,6 @@ "node": ">=8" } }, - "node_modules/@testing-library/jest-dom/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/@testing-library/jest-dom/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "node_modules/@testing-library/jest-dom/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/@testing-library/jest-dom/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, "node_modules/@tsconfig/node10": { "version": "1.0.9", "resolved": "https://registry.npmjs.org/@tsconfig/node10/-/node10-1.0.9.tgz", @@ -3347,10 +3326,11 @@ } }, "node_modules/@types/istanbul-lib-coverage": { - "version": "2.0.4", - "resolved": "https://registry.npmjs.org/@types/istanbul-lib-coverage/-/istanbul-lib-coverage-2.0.4.tgz", - "integrity": "sha512-z/QT1XN4K4KYuslS23k62yDIDLwLFkzxOuMplDtObz0+y7VqJCaO2o+SPwHCvLFZh7xazvvoor2tA/hPz9ee7g==", - "dev": true + "version": "2.0.6", + "resolved": "https://registry.npmjs.org/@types/istanbul-lib-coverage/-/istanbul-lib-coverage-2.0.6.tgz", + "integrity": "sha512-2QF/t/auWm0lsy8XtKVPG19v3sSOQlJe/YHZgfjb/KBBHOGSV+J2q/S671rcq9uTBrLAXmZpqJiaQbMT+zNU1w==", + "dev": true, + "license": "MIT" }, "node_modules/@types/istanbul-lib-report": { "version": "3.0.0", @@ -3362,10 +3342,11 @@ } }, "node_modules/@types/istanbul-reports": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/@types/istanbul-reports/-/istanbul-reports-3.0.1.tgz", - "integrity": "sha512-c3mAZEuK0lvBp8tmuL74XRKn1+y2dcwOUpH7x4WrF6gk1GIgiluDRgMYQtw2OFcBvAJWlt6ASU3tSqxp0Uu0Aw==", + "version": "3.0.4", + "resolved": "https://registry.npmjs.org/@types/istanbul-reports/-/istanbul-reports-3.0.4.tgz", + "integrity": "sha512-pk2B1NWalF9toCRu6gjBzR69syFjP4Od8WRAX+0mmf9lAjCRicLOWc+ZrxZHx/0XRjotgkF9t6iaMJ+aXcOdZQ==", "dev": true, + "license": "MIT", "dependencies": { "@types/istanbul-lib-report": "*" } @@ -3380,6 +3361,18 @@ "pretty-format": "^29.0.0" } }, + "node_modules/@types/jsdom": { + "version": "21.1.7", + "resolved": "https://registry.npmjs.org/@types/jsdom/-/jsdom-21.1.7.tgz", + "integrity": "sha512-yOriVnggzrnQ3a9OKOCxaVuSug3w3/SbOj5i7VwXWZEyUNl3bLF9V3MfxGbZKuwqJOQyRfqXyROBB1CoZLFWzA==", + "dev": true, + "license": "MIT", + "dependencies": { + "@types/node": "*", + "@types/tough-cookie": "*", + "parse5": "^7.0.0" + } + }, "node_modules/@types/ndarray": { "version": "1.0.14", "resolved": "https://registry.npmjs.org/@types/ndarray/-/ndarray-1.0.14.tgz", @@ -3399,10 +3392,11 @@ "dev": true }, "node_modules/@types/stack-utils": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/@types/stack-utils/-/stack-utils-2.0.1.tgz", - "integrity": "sha512-Hl219/BT5fLAaz6NDkSuhzasy49dwQS/DSdu4MdggFB8zcXv7vflBI3xp7FEmkmdDkBUI2bPUNeMttp2knYdxw==", - "dev": true + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/@types/stack-utils/-/stack-utils-2.0.3.tgz", + "integrity": "sha512-9aEbYZ3TbYMznPdcdr3SmIrLXwC/AKZXQeCf9Pgao5CKb8CyHuEX5jzWPTkvregvhRJHcpRO6BFoGW9ycaOkYw==", + "dev": true, + "license": "MIT" }, "node_modules/@types/stats.js": { "version": "0.17.3", @@ -3441,6 +3435,13 @@ "integrity": "sha512-cPJU47OaAoCbg0pBvzsgpTPhmhqI5eJjh/JIu8tPj5q+T7iLvW/JAYUqmE7KOB4R1ZyEhzBaIQpQpardBF5z8A==", "dev": true }, + "node_modules/@types/tough-cookie": { + "version": "4.0.5", + "resolved": "https://registry.npmjs.org/@types/tough-cookie/-/tough-cookie-4.0.5.tgz", + "integrity": "sha512-/Ad8+nIOV7Rl++6f1BdKxFSMgmoqEoYbHRpPcx3JEfv8VRsQe9Z4mCXeJBzxs7mbHY/XOZZuXlRNfhpVPbs6ZA==", + "dev": true, + "license": "MIT" + }, "node_modules/@types/webxr": { "version": "0.5.20", "resolved": "https://registry.npmjs.org/@types/webxr/-/webxr-0.5.20.tgz", @@ -3448,10 +3449,11 @@ "dev": true }, "node_modules/@types/yargs": { - "version": "17.0.22", - "resolved": "https://registry.npmjs.org/@types/yargs/-/yargs-17.0.22.tgz", - "integrity": "sha512-pet5WJ9U8yPVRhkwuEIp5ktAeAqRZOq4UdAyWLWzxbtpyXnzbtLdKiXAjJzi/KLmPGS9wk86lUFWZFN6sISo4g==", + "version": "17.0.35", + "resolved": "https://registry.npmjs.org/@types/yargs/-/yargs-17.0.35.tgz", + "integrity": "sha512-qUHkeCyQFxMXg79wQfTtfndEC+N9ZZg76HJftDJp+qH2tV7Gj4OJi7l+PiWwJ+pWtW8GwSmqsDj/oymhrTWXjg==", "dev": true, + "license": "MIT", "dependencies": { "@types/yargs-parser": "*" } @@ -3489,6 +3491,16 @@ "node": ">=0.4.0" } }, + "node_modules/agent-base": { + "version": "7.1.4", + "resolved": "https://registry.npmjs.org/agent-base/-/agent-base-7.1.4.tgz", + "integrity": "sha512-MnA+YT8fwfJPgBx3m60MNqakm30XOkyIoH1y6huTQvC0PwZG7ki8NacLBcrPbNoo8vEZy7Jpuk7+jMO+CUovTQ==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">= 14" + } + }, "node_modules/ansi-escapes": { "version": "4.3.2", "resolved": "https://registry.npmjs.org/ansi-escapes/-/ansi-escapes-4.3.2.tgz", @@ -3514,15 +3526,19 @@ } }, "node_modules/ansi-styles": { - "version": "3.2.1", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz", - "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", "dev": true, + "license": "MIT", "dependencies": { - "color-convert": "^1.9.0" + "color-convert": "^2.0.1" }, "engines": { - "node": ">=4" + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" } }, "node_modules/anymatch": { @@ -3608,76 +3624,6 @@ "@babel/core": "^7.8.0" } }, - "node_modules/babel-jest/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/babel-jest/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" - } - }, - "node_modules/babel-jest/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/babel-jest/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "node_modules/babel-jest/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/babel-jest/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, "node_modules/babel-plugin-istanbul": { "version": "6.1.1", "resolved": "https://registry.npmjs.org/babel-plugin-istanbul/-/babel-plugin-istanbul-6.1.1.tgz", @@ -3924,17 +3870,20 @@ ] }, "node_modules/chalk": { - "version": "2.4.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.2.tgz", - "integrity": "sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==", + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", "dev": true, + "license": "MIT", "dependencies": { - "ansi-styles": "^3.2.1", - "escape-string-regexp": "^1.0.5", - "supports-color": "^5.3.0" + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" }, "engines": { - "node": ">=4" + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" } }, "node_modules/char-regex": { @@ -4025,19 +3974,24 @@ "dev": true }, "node_modules/color-convert": { - "version": "1.9.3", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-1.9.3.tgz", - "integrity": "sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg==", + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", "dev": true, + "license": "MIT", "dependencies": { - "color-name": "1.1.3" + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" } }, "node_modules/color-name": { - "version": "1.1.3", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.3.tgz", - "integrity": "sha512-72fSenhMw2HZMTVHeCA9KCmpEIbzWiQsjN+BHcBbS9vr1mtt+vJjPdksIBNUmKAW8TFUDPJK5SUU3QhE9NEXDw==", - "dev": true + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", + "dev": true, + "license": "MIT" }, "node_modules/commander": { "version": "13.1.0", @@ -4141,6 +4095,20 @@ "node": ">=0.10.0" } }, + "node_modules/cssstyle": { + "version": "4.6.0", + "resolved": "https://registry.npmjs.org/cssstyle/-/cssstyle-4.6.0.tgz", + "integrity": "sha512-2z+rWdzbbSZv6/rhtvzvqeZQHrBaqgogqt85sqFNbabZOuFbCVFb8kPeEtZjiKkbrm395irpNKiYeFeLiQnFPg==", + "dev": true, + "license": "MIT", + "dependencies": { + "@asamuzakjp/css-color": "^3.2.0", + "rrweb-cssom": "^0.8.0" + }, + "engines": { + "node": ">=18" + } + }, "node_modules/cwise-compiler": { "version": "1.1.3", "resolved": "https://registry.npmjs.org/cwise-compiler/-/cwise-compiler-1.1.3.tgz", @@ -4150,6 +4118,20 @@ "uniq": "^1.0.0" } }, + "node_modules/data-urls": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/data-urls/-/data-urls-5.0.0.tgz", + "integrity": "sha512-ZYP5VBHshaDAiVZxjbRVcFJpc+4xGgT0bK3vzy1HLN8jTO975HEbuYzZJcHoQEY5K1a0z8YayJkyVETa08eNTg==", + "dev": true, + "license": "MIT", + "dependencies": { + "whatwg-mimetype": "^4.0.0", + "whatwg-url": "^14.0.0" + }, + "engines": { + "node": ">=18" + } + }, "node_modules/debug": { "version": "4.3.4", "resolved": "https://registry.npmjs.org/debug/-/debug-4.3.4.tgz", @@ -4167,8 +4149,15 @@ } } }, - "node_modules/decode-uri-component": { - "version": "0.2.2", + "node_modules/decimal.js": { + "version": "10.6.0", + "resolved": "https://registry.npmjs.org/decimal.js/-/decimal.js-10.6.0.tgz", + "integrity": "sha512-YpgQiITW3JXGntzdUmyUR1V812Hn8T1YVXhCu+wO3OpS4eU9l4YdD3qjyiKdV6mvV29zapkMeD390UVEf2lkUg==", + "dev": true, + "license": "MIT" + }, + "node_modules/decode-uri-component": { + "version": "0.2.2", "resolved": "https://registry.npmjs.org/decode-uri-component/-/decode-uri-component-0.2.2.tgz", "integrity": "sha512-FqUYQ+8o158GyGTrMFJms9qh3CqTKvAqgqsTnkLI8sKu0028orqBhxNMFkFen0zGyg6epACD32pjVk58ngIErQ==", "dev": true, @@ -4276,6 +4265,19 @@ "once": "^1.4.0" } }, + "node_modules/entities": { + "version": "6.0.1", + "resolved": "https://registry.npmjs.org/entities/-/entities-6.0.1.tgz", + "integrity": "sha512-aN97NXWF6AWBTahfVOIrB/NShkzi5H7F9r1s9mD3cDj4Ko5f2qhhVoYMibXF7GlLveb/D2ioWay8lxI97Ven3g==", + "dev": true, + "license": "BSD-2-Clause", + "engines": { + "node": ">=0.12" + }, + "funding": { + "url": "https://github.com/fb55/entities?sponsor=1" + } + }, "node_modules/error-ex": { "version": "1.3.2", "resolved": "https://registry.npmjs.org/error-ex/-/error-ex-1.3.2.tgz", @@ -4318,15 +4320,6 @@ "node": ">=6" } }, - "node_modules/escape-string-regexp": { - "version": "1.0.5", - "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz", - "integrity": "sha512-vbRorB5FUQWvla16U8R/qgaFIya2qGzwDrNmCZuYKrbdSUMG6I1ZCGQRefkRVhuOkIGVne7BQ35DSfo1qvJqFg==", - "dev": true, - "engines": { - "node": ">=0.8.0" - } - }, "node_modules/esprima": { "version": "4.0.1", "resolved": "https://registry.npmjs.org/esprima/-/esprima-4.0.1.tgz", @@ -4605,10 +4598,11 @@ } }, "node_modules/graceful-fs": { - "version": "4.2.10", - "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.10.tgz", - "integrity": "sha512-9ByhssR2fPVsNZj478qUUbKfmL0+t5BDVyjShtyZZLiK7ZDAArFFfopyOTj0M05wE2tJPisA4iTnnXl2YoPvOA==", - "dev": true + "version": "4.2.11", + "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.11.tgz", + "integrity": "sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ==", + "dev": true, + "license": "ISC" }, "node_modules/has": { "version": "1.0.3", @@ -4623,12 +4617,26 @@ } }, "node_modules/has-flag": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-3.0.0.tgz", - "integrity": "sha512-sKJf1+ceQBr4SMkvQnBDNDtf4TXpVhVGateu0t918bl30FnbE2m4vNLX+VWe/dpjlb+HugGYzW7uQXH98HPEYw==", + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", "dev": true, + "license": "MIT", "engines": { - "node": ">=4" + "node": ">=8" + } + }, + "node_modules/html-encoding-sniffer": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/html-encoding-sniffer/-/html-encoding-sniffer-4.0.0.tgz", + "integrity": "sha512-Y22oTqIU4uuPgEemfz7NDJz6OeKf12Lsu+QC+s3BVpda64lTiMYCyGwg5ki4vFxkMwQdeZDl2adZoqUgdFuTgQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "whatwg-encoding": "^3.1.1" + }, + "engines": { + "node": ">=18" } }, "node_modules/html-escaper": { @@ -4637,6 +4645,34 @@ "integrity": "sha512-H2iMtd0I4Mt5eYiapRdIDjp+XzelXQ0tFE4JS7YFwFevXXMmOp9myNrUvCg0D6ws8iqkRPBfKHgbwig1SmlLfg==", "dev": true }, + "node_modules/http-proxy-agent": { + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/http-proxy-agent/-/http-proxy-agent-7.0.2.tgz", + "integrity": "sha512-T1gkAiYYDWYx3V5Bmyu7HcfcvL7mUrTWiM6yOfa3PIphViJ/gFPbvidQ+veqSOHci/PxBcDabeUNCzpOODJZig==", + "dev": true, + "license": "MIT", + "dependencies": { + "agent-base": "^7.1.0", + "debug": "^4.3.4" + }, + "engines": { + "node": ">= 14" + } + }, + "node_modules/https-proxy-agent": { + "version": "7.0.6", + "resolved": "https://registry.npmjs.org/https-proxy-agent/-/https-proxy-agent-7.0.6.tgz", + "integrity": "sha512-vK9P5/iUfdl95AI+JVyUuIcVtd4ofvtrOr3HNtM2yxC9bnMbEdp3x01OhQNnjb8IJYi38VlTE3mBXwcfvywuSw==", + "dev": true, + "license": "MIT", + "dependencies": { + "agent-base": "^7.1.2", + "debug": "4" + }, + "engines": { + "node": ">= 14" + } + }, "node_modules/human-signals": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/human-signals/-/human-signals-2.1.0.tgz", @@ -4646,6 +4682,19 @@ "node": ">=10.17.0" } }, + "node_modules/iconv-lite": { + "version": "0.6.3", + "resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.6.3.tgz", + "integrity": "sha512-4fCk79wshMdzMp2rH06qWrJE4iolqLhCUH+OiuIgU++RB0+94NlDL81atO7GX55uUKueo0txHNtvEyI6D7WdMw==", + "dev": true, + "license": "MIT", + "dependencies": { + "safer-buffer": ">= 2.1.2 < 3.0.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, "node_modules/immutable": { "version": "4.2.4", "resolved": "https://registry.npmjs.org/immutable/-/immutable-4.2.4.tgz", @@ -4821,6 +4870,13 @@ "node": ">=0.12.0" } }, + "node_modules/is-potential-custom-element-name": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/is-potential-custom-element-name/-/is-potential-custom-element-name-1.0.1.tgz", + "integrity": "sha512-bCYeRA2rVibKZd+s2625gGnGF/t7DSqDs4dP7CrLA1m7jKWz6pps0LpYLJN8Q64HtmPKJ1hrN3nzPNKFEKOUiQ==", + "dev": true, + "license": "MIT" + }, "node_modules/is-stream": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/is-stream/-/is-stream-2.0.1.tgz", @@ -4890,27 +4946,6 @@ "node": ">=8" } }, - "node_modules/istanbul-lib-report/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/istanbul-lib-report/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, "node_modules/istanbul-lib-source-maps": { "version": "4.0.1", "resolved": "https://registry.npmjs.org/istanbul-lib-source-maps/-/istanbul-lib-source-maps-4.0.1.tgz", @@ -5016,76 +5051,6 @@ "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, - "node_modules/jest-circus/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/jest-circus/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" - } - }, - "node_modules/jest-circus/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/jest-circus/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "node_modules/jest-circus/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/jest-circus/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, "node_modules/jest-cli": { "version": "29.4.3", "resolved": "https://registry.npmjs.org/jest-cli/-/jest-cli-29.4.3.tgz", @@ -5120,76 +5085,6 @@ } } }, - "node_modules/jest-cli/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/jest-cli/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" - } - }, - "node_modules/jest-cli/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/jest-cli/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "node_modules/jest-cli/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/jest-cli/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, "node_modules/jest-config": { "version": "29.4.3", "resolved": "https://registry.npmjs.org/jest-config/-/jest-config-29.4.3.tgz", @@ -5235,21 +5130,6 @@ } } }, - "node_modules/jest-config/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, "node_modules/jest-config/node_modules/babel-jest": { "version": "29.4.3", "resolved": "https://registry.npmjs.org/babel-jest/-/babel-jest-29.4.3.tgz", @@ -5271,242 +5151,276 @@ "@babel/core": "^7.8.0" } }, - "node_modules/jest-config/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "node_modules/jest-diff": { + "version": "29.4.3", + "resolved": "https://registry.npmjs.org/jest-diff/-/jest-diff-29.4.3.tgz", + "integrity": "sha512-YB+ocenx7FZ3T5O9lMVMeLYV4265socJKtkwgk/6YUz/VsEzYDkiMuMhWzZmxm3wDRQvayJu/PjkjjSkjoHsCA==", "dev": true, "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" + "chalk": "^4.0.0", + "diff-sequences": "^29.4.3", + "jest-get-type": "^29.4.3", + "pretty-format": "^29.4.3" }, "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, - "node_modules/jest-config/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "node_modules/jest-docblock": { + "version": "29.4.3", + "resolved": "https://registry.npmjs.org/jest-docblock/-/jest-docblock-29.4.3.tgz", + "integrity": "sha512-fzdTftThczeSD9nZ3fzA/4KkHtnmllawWrXO69vtI+L9WjEIuXWs4AmyME7lN5hU7dB0sHhuPfcKofRsUb/2Fg==", "dev": true, "dependencies": { - "color-name": "~1.1.4" + "detect-newline": "^3.0.0" }, "engines": { - "node": ">=7.0.0" + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, - "node_modules/jest-config/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "node_modules/jest-config/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/jest-config/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/jest-diff": { + "node_modules/jest-each": { "version": "29.4.3", - "resolved": "https://registry.npmjs.org/jest-diff/-/jest-diff-29.4.3.tgz", - "integrity": "sha512-YB+ocenx7FZ3T5O9lMVMeLYV4265socJKtkwgk/6YUz/VsEzYDkiMuMhWzZmxm3wDRQvayJu/PjkjjSkjoHsCA==", + "resolved": "https://registry.npmjs.org/jest-each/-/jest-each-29.4.3.tgz", + "integrity": "sha512-1ElHNAnKcbJb/b+L+7j0/w7bDvljw4gTv1wL9fYOczeJrbTbkMGQ5iQPFJ3eFQH19VPTx1IyfePdqSpePKss7Q==", "dev": true, "dependencies": { + "@jest/types": "^29.4.3", "chalk": "^4.0.0", - "diff-sequences": "^29.4.3", "jest-get-type": "^29.4.3", + "jest-util": "^29.4.3", "pretty-format": "^29.4.3" }, "engines": { "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, - "node_modules/jest-diff/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "node_modules/jest-environment-jsdom": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-environment-jsdom/-/jest-environment-jsdom-30.2.0.tgz", + "integrity": "sha512-zbBTiqr2Vl78pKp/laGBREYzbZx9ZtqPjOK4++lL4BNDhxRnahg51HtoDrk9/VjIy9IthNEWdKVd7H5bqBhiWQ==", "dev": true, + "license": "MIT", "dependencies": { - "color-convert": "^2.0.1" + "@jest/environment": "30.2.0", + "@jest/environment-jsdom-abstract": "30.2.0", + "@types/jsdom": "^21.1.7", + "@types/node": "*", + "jsdom": "^26.1.0" }, "engines": { - "node": ">=8" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" + "peerDependencies": { + "canvas": "^3.0.0" + }, + "peerDependenciesMeta": { + "canvas": { + "optional": true + } } }, - "node_modules/jest-diff/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "node_modules/jest-environment-jsdom/node_modules/@jest/environment": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/environment/-/environment-30.2.0.tgz", + "integrity": "sha512-/QPTL7OBJQ5ac09UDRa3EQes4gt1FTEG/8jZ/4v5IVzx+Cv7dLxlVIvfvSVRiiX2drWyXeBjkMSR8hvOWSog5g==", "dev": true, + "license": "MIT", "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" + "@jest/fake-timers": "30.2.0", + "@jest/types": "30.2.0", + "@types/node": "*", + "jest-mock": "30.2.0" }, "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/jest-diff/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "node_modules/jest-environment-jsdom/node_modules/@jest/fake-timers": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/fake-timers/-/fake-timers-30.2.0.tgz", + "integrity": "sha512-HI3tRLjRxAbBy0VO8dqqm7Hb2mIa8d5bg/NJkyQcOk7V118ObQML8RC5luTF/Zsg4474a+gDvhce7eTnP4GhYw==", "dev": true, + "license": "MIT", "dependencies": { - "color-name": "~1.1.4" + "@jest/types": "30.2.0", + "@sinonjs/fake-timers": "^13.0.0", + "@types/node": "*", + "jest-message-util": "30.2.0", + "jest-mock": "30.2.0", + "jest-util": "30.2.0" }, "engines": { - "node": ">=7.0.0" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/jest-diff/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "node_modules/jest-diff/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "node_modules/jest-environment-jsdom/node_modules/@jest/schemas": { + "version": "30.0.5", + "resolved": "https://registry.npmjs.org/@jest/schemas/-/schemas-30.0.5.tgz", + "integrity": "sha512-DmdYgtezMkh3cpU8/1uyXakv3tJRcmcXxBOcO0tbaozPwpmh4YMsnWrQm9ZmZMfa5ocbxzbFk6O4bDPEc/iAnA==", "dev": true, + "license": "MIT", + "dependencies": { + "@sinclair/typebox": "^0.34.0" + }, "engines": { - "node": ">=8" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/jest-diff/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "node_modules/jest-environment-jsdom/node_modules/@jest/types": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/types/-/types-30.2.0.tgz", + "integrity": "sha512-H9xg1/sfVvyfU7o3zMfBEjQ1gcsdeTMgqHoYdN79tuLqfTtuu7WckRA1R5whDwOzxaZAeMKTYWqP+WCAi0CHsg==", "dev": true, + "license": "MIT", "dependencies": { - "has-flag": "^4.0.0" + "@jest/pattern": "30.0.1", + "@jest/schemas": "30.0.5", + "@types/istanbul-lib-coverage": "^2.0.6", + "@types/istanbul-reports": "^3.0.4", + "@types/node": "*", + "@types/yargs": "^17.0.33", + "chalk": "^4.1.2" }, "engines": { - "node": ">=8" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/jest-docblock": { - "version": "29.4.3", - "resolved": "https://registry.npmjs.org/jest-docblock/-/jest-docblock-29.4.3.tgz", - "integrity": "sha512-fzdTftThczeSD9nZ3fzA/4KkHtnmllawWrXO69vtI+L9WjEIuXWs4AmyME7lN5hU7dB0sHhuPfcKofRsUb/2Fg==", + "node_modules/jest-environment-jsdom/node_modules/@sinclair/typebox": { + "version": "0.34.47", + "resolved": "https://registry.npmjs.org/@sinclair/typebox/-/typebox-0.34.47.tgz", + "integrity": "sha512-ZGIBQ+XDvO5JQku9wmwtabcVTHJsgSWAHYtVuM9pBNNR5E88v6Jcj/llpmsjivig5X8A8HHOb4/mbEKPS5EvAw==", + "dev": true, + "license": "MIT" + }, + "node_modules/jest-environment-jsdom/node_modules/@sinonjs/commons": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/@sinonjs/commons/-/commons-3.0.1.tgz", + "integrity": "sha512-K3mCHKQ9sVh8o1C9cxkwxaOmXoAMlDxC1mYyHrjqOWEcBjYr76t96zL2zlj5dUGZ3HSw240X1qgH3Mjf1yJWpQ==", "dev": true, + "license": "BSD-3-Clause", "dependencies": { - "detect-newline": "^3.0.0" - }, - "engines": { - "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + "type-detect": "4.0.8" } }, - "node_modules/jest-each": { - "version": "29.4.3", - "resolved": "https://registry.npmjs.org/jest-each/-/jest-each-29.4.3.tgz", - "integrity": "sha512-1ElHNAnKcbJb/b+L+7j0/w7bDvljw4gTv1wL9fYOczeJrbTbkMGQ5iQPFJ3eFQH19VPTx1IyfePdqSpePKss7Q==", + "node_modules/jest-environment-jsdom/node_modules/@sinonjs/fake-timers": { + "version": "13.0.5", + "resolved": "https://registry.npmjs.org/@sinonjs/fake-timers/-/fake-timers-13.0.5.tgz", + "integrity": "sha512-36/hTbH2uaWuGVERyC6da9YwGWnzUZXuPro/F2LfsdOsLnCojz/iSH8MxUt/FD2S5XBSVPhmArFUXcpCQ2Hkiw==", "dev": true, + "license": "BSD-3-Clause", "dependencies": { - "@jest/types": "^29.4.3", - "chalk": "^4.0.0", - "jest-get-type": "^29.4.3", - "jest-util": "^29.4.3", - "pretty-format": "^29.4.3" - }, - "engines": { - "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + "@sinonjs/commons": "^3.0.1" } }, - "node_modules/jest-each/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "node_modules/jest-environment-jsdom/node_modules/ansi-styles": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-5.2.0.tgz", + "integrity": "sha512-Cxwpt2SfTzTtXcfOlzGEee8O+c+MmUgGrNiBcXnuWxuFJHe6a5Hz7qwhwe5OgaSYI0IJvkLqWX1ASG+cJOkEiA==", "dev": true, - "dependencies": { - "color-convert": "^2.0.1" - }, + "license": "MIT", "engines": { - "node": ">=8" + "node": ">=10" }, "funding": { "url": "https://github.com/chalk/ansi-styles?sponsor=1" } }, - "node_modules/jest-each/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "node_modules/jest-environment-jsdom/node_modules/ci-info": { + "version": "4.3.1", + "resolved": "https://registry.npmjs.org/ci-info/-/ci-info-4.3.1.tgz", + "integrity": "sha512-Wdy2Igu8OcBpI2pZePZ5oWjPC38tmDVx5WKUXKwlLYkA0ozo85sLsLvkBbBn/sZaSCMFOGZJ14fvW9t5/d7kdA==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/sibiraj-s" + } + ], + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "node_modules/jest-environment-jsdom/node_modules/jest-message-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-message-util/-/jest-message-util-30.2.0.tgz", + "integrity": "sha512-y4DKFLZ2y6DxTWD4cDe07RglV88ZiNEdlRfGtqahfbIjfsw1nMCPx49Uev4IA/hWn3sDKyAnSPwoYSsAEdcimw==", "dev": true, + "license": "MIT", "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" + "@babel/code-frame": "^7.27.1", + "@jest/types": "30.2.0", + "@types/stack-utils": "^2.0.3", + "chalk": "^4.1.2", + "graceful-fs": "^4.2.11", + "micromatch": "^4.0.8", + "pretty-format": "30.2.0", + "slash": "^3.0.0", + "stack-utils": "^2.0.6" }, "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/jest-each/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "node_modules/jest-environment-jsdom/node_modules/jest-mock": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-mock/-/jest-mock-30.2.0.tgz", + "integrity": "sha512-JNNNl2rj4b5ICpmAcq+WbLH83XswjPbjH4T7yvGzfAGCPh1rw+xVNbtk+FnRslvt9lkCcdn9i1oAoKUuFsOxRw==", "dev": true, + "license": "MIT", "dependencies": { - "color-name": "~1.1.4" + "@jest/types": "30.2.0", + "@types/node": "*", + "jest-util": "30.2.0" }, "engines": { - "node": ">=7.0.0" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, - "node_modules/jest-each/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true + "node_modules/jest-environment-jsdom/node_modules/jest-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-30.2.0.tgz", + "integrity": "sha512-QKNsM0o3Xe6ISQU869e+DhG+4CK/48aHYdJZGlFQVTjnbvgpcKyxpzk29fGiO7i/J8VENZ+d2iGnSsvmuHywlA==", + "dev": true, + "license": "MIT", + "dependencies": { + "@jest/types": "30.2.0", + "@types/node": "*", + "chalk": "^4.1.2", + "ci-info": "^4.2.0", + "graceful-fs": "^4.2.11", + "picomatch": "^4.0.2" + }, + "engines": { + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" + } }, - "node_modules/jest-each/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "node_modules/jest-environment-jsdom/node_modules/picomatch": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.3.tgz", + "integrity": "sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==", "dev": true, + "license": "MIT", "engines": { - "node": ">=8" + "node": ">=12" + }, + "funding": { + "url": "https://github.com/sponsors/jonschlinkert" } }, - "node_modules/jest-each/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "node_modules/jest-environment-jsdom/node_modules/pretty-format": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/pretty-format/-/pretty-format-30.2.0.tgz", + "integrity": "sha512-9uBdv/B4EefsuAL+pWqueZyZS2Ba+LxfFeQ9DN14HU4bN8bhaxKdkpjpB6fs9+pSjIBu+FXQHImEg8j/Lw0+vA==", "dev": true, + "license": "MIT", "dependencies": { - "has-flag": "^4.0.0" + "@jest/schemas": "30.0.5", + "ansi-styles": "^5.2.0", + "react-is": "^18.3.1" }, "engines": { - "node": ">=8" + "node": "^18.14.0 || ^20.0.0 || ^22.0.0 || >=24.0.0" } }, "node_modules/jest-environment-node": { @@ -5599,76 +5513,6 @@ "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, - "node_modules/jest-matcher-utils/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/jest-matcher-utils/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" - } - }, - "node_modules/jest-matcher-utils/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/jest-matcher-utils/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "node_modules/jest-matcher-utils/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/jest-matcher-utils/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, "node_modules/jest-message-util": { "version": "29.4.3", "resolved": "https://registry.npmjs.org/jest-message-util/-/jest-message-util-29.4.3.tgz", @@ -5689,88 +5533,18 @@ "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, - "node_modules/jest-message-util/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "node_modules/jest-mock": { + "version": "29.4.3", + "resolved": "https://registry.npmjs.org/jest-mock/-/jest-mock-29.4.3.tgz", + "integrity": "sha512-LjFgMg+xed9BdkPMyIJh+r3KeHt1klXPJYBULXVVAkbTaaKjPX1o1uVCAZADMEp/kOxGTwy/Ot8XbvgItOrHEg==", "dev": true, "dependencies": { - "color-convert": "^2.0.1" + "@jest/types": "^29.4.3", + "@types/node": "*", + "jest-util": "^29.4.3" }, "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/jest-message-util/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" - } - }, - "node_modules/jest-message-util/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/jest-message-util/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "node_modules/jest-message-util/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/jest-message-util/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/jest-mock": { - "version": "29.4.3", - "resolved": "https://registry.npmjs.org/jest-mock/-/jest-mock-29.4.3.tgz", - "integrity": "sha512-LjFgMg+xed9BdkPMyIJh+r3KeHt1klXPJYBULXVVAkbTaaKjPX1o1uVCAZADMEp/kOxGTwy/Ot8XbvgItOrHEg==", - "dev": true, - "dependencies": { - "@jest/types": "^29.4.3", - "@types/node": "*", - "jest-util": "^29.4.3" - }, - "engines": { - "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, "node_modules/jest-pnp-resolver": { @@ -5832,64 +5606,6 @@ "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, - "node_modules/jest-resolve/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/jest-resolve/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" - } - }, - "node_modules/jest-resolve/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/jest-resolve/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "node_modules/jest-resolve/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true, - "engines": { - "node": ">=8" - } - }, "node_modules/jest-resolve/node_modules/resolve": { "version": "1.22.1", "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.22.1.tgz", @@ -5907,18 +5623,6 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/jest-resolve/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, "node_modules/jest-runner": { "version": "29.4.3", "resolved": "https://registry.npmjs.org/jest-runner/-/jest-runner-29.4.3.tgz", @@ -5951,76 +5655,6 @@ "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, - "node_modules/jest-runner/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/jest-runner/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" - } - }, - "node_modules/jest-runner/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/jest-runner/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "node_modules/jest-runner/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/jest-runner/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, "node_modules/jest-runtime": { "version": "29.4.3", "resolved": "https://registry.npmjs.org/jest-runtime/-/jest-runtime-29.4.3.tgz", @@ -6054,76 +5688,6 @@ "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, - "node_modules/jest-runtime/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/jest-runtime/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" - } - }, - "node_modules/jest-runtime/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/jest-runtime/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "node_modules/jest-runtime/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/jest-runtime/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, "node_modules/jest-snapshot": { "version": "29.4.3", "resolved": "https://registry.npmjs.org/jest-snapshot/-/jest-snapshot-29.4.3.tgz", @@ -6159,64 +5723,6 @@ "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, - "node_modules/jest-snapshot/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/jest-snapshot/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" - } - }, - "node_modules/jest-snapshot/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/jest-snapshot/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "node_modules/jest-snapshot/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true, - "engines": { - "node": ">=8" - } - }, "node_modules/jest-snapshot/node_modules/lru-cache": { "version": "6.0.0", "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-6.0.0.tgz", @@ -6226,315 +5732,93 @@ "yallist": "^4.0.0" }, "engines": { - "node": ">=10" - } - }, - "node_modules/jest-snapshot/node_modules/semver": { - "version": "7.3.8", - "resolved": "https://registry.npmjs.org/semver/-/semver-7.3.8.tgz", - "integrity": "sha512-NB1ctGL5rlHrPJtFDVIVzTyQylMLu9N9VICA6HSFJo8MCGVTMW6gfpicwKmmK/dAjTOrqu5l63JJOpDSrAis3A==", - "dev": true, - "dependencies": { - "lru-cache": "^6.0.0" - }, - "bin": { - "semver": "bin/semver.js" - }, - "engines": { - "node": ">=10" - } - }, - "node_modules/jest-snapshot/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/jest-snapshot/node_modules/yallist": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz", - "integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==", - "dev": true - }, - "node_modules/jest-util": { - "version": "29.4.3", - "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-29.4.3.tgz", - "integrity": "sha512-ToSGORAz4SSSoqxDSylWX8JzkOQR7zoBtNRsA7e+1WUX5F8jrOwaNpuh1YfJHJKDHXLHmObv5eOjejUd+/Ws+Q==", - "dev": true, - "dependencies": { - "@jest/types": "^29.4.3", - "@types/node": "*", - "chalk": "^4.0.0", - "ci-info": "^3.2.0", - "graceful-fs": "^4.2.9", - "picomatch": "^2.2.3" - }, - "engines": { - "node": "^14.15.0 || ^16.10.0 || >=18.0.0" - } - }, - "node_modules/jest-util/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/jest-util/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" - } - }, - "node_modules/jest-util/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/jest-util/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "node_modules/jest-util/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/jest-util/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/jest-validate": { - "version": "29.4.3", - "resolved": "https://registry.npmjs.org/jest-validate/-/jest-validate-29.4.3.tgz", - "integrity": "sha512-J3u5v7aPQoXPzaar6GndAVhdQcZr/3osWSgTeKg5v574I9ybX/dTyH0AJFb5XgXIB7faVhf+rS7t4p3lL9qFaw==", - "dev": true, - "dependencies": { - "@jest/types": "^29.4.3", - "camelcase": "^6.2.0", - "chalk": "^4.0.0", - "jest-get-type": "^29.4.3", - "leven": "^3.1.0", - "pretty-format": "^29.4.3" - }, - "engines": { - "node": "^14.15.0 || ^16.10.0 || >=18.0.0" - } - }, - "node_modules/jest-validate/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/jest-validate/node_modules/camelcase": { - "version": "6.3.0", - "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-6.3.0.tgz", - "integrity": "sha512-Gmy6FhYlCY7uOElZUSbxo2UCDH8owEk996gkbrpsgGtrJLM3J7jGxl9Ic7Qwwj4ivOE5AWZWRMecDdF7hqGjFA==", - "dev": true, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/jest-validate/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" - } - }, - "node_modules/jest-validate/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/jest-validate/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "node_modules/jest-validate/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true, - "engines": { - "node": ">=8" + "node": ">=10" } }, - "node_modules/jest-validate/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "node_modules/jest-snapshot/node_modules/semver": { + "version": "7.3.8", + "resolved": "https://registry.npmjs.org/semver/-/semver-7.3.8.tgz", + "integrity": "sha512-NB1ctGL5rlHrPJtFDVIVzTyQylMLu9N9VICA6HSFJo8MCGVTMW6gfpicwKmmK/dAjTOrqu5l63JJOpDSrAis3A==", "dev": true, "dependencies": { - "has-flag": "^4.0.0" + "lru-cache": "^6.0.0" + }, + "bin": { + "semver": "bin/semver.js" }, "engines": { - "node": ">=8" + "node": ">=10" } }, - "node_modules/jest-watcher": { + "node_modules/jest-snapshot/node_modules/yallist": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz", + "integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==", + "dev": true + }, + "node_modules/jest-util": { "version": "29.4.3", - "resolved": "https://registry.npmjs.org/jest-watcher/-/jest-watcher-29.4.3.tgz", - "integrity": "sha512-zwlXH3DN3iksoIZNk73etl1HzKyi5FuQdYLnkQKm5BW4n8HpoG59xSwpVdFrnh60iRRaRBGw0gcymIxjJENPcA==", + "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-29.4.3.tgz", + "integrity": "sha512-ToSGORAz4SSSoqxDSylWX8JzkOQR7zoBtNRsA7e+1WUX5F8jrOwaNpuh1YfJHJKDHXLHmObv5eOjejUd+/Ws+Q==", "dev": true, "dependencies": { - "@jest/test-result": "^29.4.3", "@jest/types": "^29.4.3", "@types/node": "*", - "ansi-escapes": "^4.2.1", "chalk": "^4.0.0", - "emittery": "^0.13.1", - "jest-util": "^29.4.3", - "string-length": "^4.0.1" + "ci-info": "^3.2.0", + "graceful-fs": "^4.2.9", + "picomatch": "^2.2.3" }, "engines": { "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, - "node_modules/jest-watcher/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "node_modules/jest-validate": { + "version": "29.4.3", + "resolved": "https://registry.npmjs.org/jest-validate/-/jest-validate-29.4.3.tgz", + "integrity": "sha512-J3u5v7aPQoXPzaar6GndAVhdQcZr/3osWSgTeKg5v574I9ybX/dTyH0AJFb5XgXIB7faVhf+rS7t4p3lL9qFaw==", "dev": true, "dependencies": { - "color-convert": "^2.0.1" + "@jest/types": "^29.4.3", + "camelcase": "^6.2.0", + "chalk": "^4.0.0", + "jest-get-type": "^29.4.3", + "leven": "^3.1.0", + "pretty-format": "^29.4.3" }, "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, - "node_modules/jest-watcher/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "node_modules/jest-validate/node_modules/camelcase": { + "version": "6.3.0", + "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-6.3.0.tgz", + "integrity": "sha512-Gmy6FhYlCY7uOElZUSbxo2UCDH8owEk996gkbrpsgGtrJLM3J7jGxl9Ic7Qwwj4ivOE5AWZWRMecDdF7hqGjFA==", "dev": true, - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, "engines": { "node": ">=10" }, "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" - } - }, - "node_modules/jest-watcher/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/jest-watcher/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "node_modules/jest-watcher/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true, - "engines": { - "node": ">=8" + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/jest-watcher/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "node_modules/jest-watcher": { + "version": "29.4.3", + "resolved": "https://registry.npmjs.org/jest-watcher/-/jest-watcher-29.4.3.tgz", + "integrity": "sha512-zwlXH3DN3iksoIZNk73etl1HzKyi5FuQdYLnkQKm5BW4n8HpoG59xSwpVdFrnh60iRRaRBGw0gcymIxjJENPcA==", "dev": true, "dependencies": { - "has-flag": "^4.0.0" + "@jest/test-result": "^29.4.3", + "@jest/types": "^29.4.3", + "@types/node": "*", + "ansi-escapes": "^4.2.1", + "chalk": "^4.0.0", + "emittery": "^0.13.1", + "jest-util": "^29.4.3", + "string-length": "^4.0.1" }, "engines": { - "node": ">=8" + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, "node_modules/jest-worker": { @@ -6552,15 +5836,6 @@ "node": "^14.15.0 || ^16.10.0 || >=18.0.0" } }, - "node_modules/jest-worker/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true, - "engines": { - "node": ">=8" - } - }, "node_modules/jest-worker/node_modules/supports-color": { "version": "8.1.1", "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-8.1.1.tgz", @@ -6580,7 +5855,8 @@ "version": "4.0.0", "resolved": "https://registry.npmjs.org/js-tokens/-/js-tokens-4.0.0.tgz", "integrity": "sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/js-yaml": { "version": "3.14.1", @@ -6595,6 +5871,46 @@ "js-yaml": "bin/js-yaml.js" } }, + "node_modules/jsdom": { + "version": "26.1.0", + "resolved": "https://registry.npmjs.org/jsdom/-/jsdom-26.1.0.tgz", + "integrity": "sha512-Cvc9WUhxSMEo4McES3P7oK3QaXldCfNWp7pl2NNeiIFlCoLr3kfq9kb1fxftiwk1FLV7CvpvDfonxtzUDeSOPg==", + "dev": true, + "license": "MIT", + "dependencies": { + "cssstyle": "^4.2.1", + "data-urls": "^5.0.0", + "decimal.js": "^10.5.0", + "html-encoding-sniffer": "^4.0.0", + "http-proxy-agent": "^7.0.2", + "https-proxy-agent": "^7.0.6", + "is-potential-custom-element-name": "^1.0.1", + "nwsapi": "^2.2.16", + "parse5": "^7.2.1", + "rrweb-cssom": "^0.8.0", + "saxes": "^6.0.0", + "symbol-tree": "^3.2.4", + "tough-cookie": "^5.1.1", + "w3c-xmlserializer": "^5.0.0", + "webidl-conversions": "^7.0.0", + "whatwg-encoding": "^3.1.1", + "whatwg-mimetype": "^4.0.0", + "whatwg-url": "^14.1.1", + "ws": "^8.18.0", + "xml-name-validator": "^5.0.0" + }, + "engines": { + "node": ">=18" + }, + "peerDependencies": { + "canvas": "^3.0.0" + }, + "peerDependenciesMeta": { + "canvas": { + "optional": true + } + } + }, "node_modules/jsep": { "version": "1.3.9", "resolved": "https://registry.npmjs.org/jsep/-/jsep-1.3.9.tgz", @@ -6975,6 +6291,13 @@ "node": ">=8" } }, + "node_modules/nwsapi": { + "version": "2.2.23", + "resolved": "https://registry.npmjs.org/nwsapi/-/nwsapi-2.2.23.tgz", + "integrity": "sha512-7wfH4sLbt4M0gCDzGE6vzQBo0bfTKjU7Sfpqy/7gs1qBfYz2vEJH6vXcBKpO3+6Yu1telwd0t9HpyOoLEQQbIQ==", + "dev": true, + "license": "MIT" + }, "node_modules/once": { "version": "1.4.0", "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", @@ -7104,6 +6427,19 @@ "url": "https://github.com/sponsors/sindresorhus" } }, + "node_modules/parse5": { + "version": "7.3.0", + "resolved": "https://registry.npmjs.org/parse5/-/parse5-7.3.0.tgz", + "integrity": "sha512-IInvU7fabl34qmi9gY8XOVxhYyMyuH2xUNpb2q8/Y+7552KlejkRvqvD19nMoUW/uQGGbqNpA6Tufu5FL5BZgw==", + "dev": true, + "license": "MIT", + "dependencies": { + "entities": "^6.0.0" + }, + "funding": { + "url": "https://github.com/inikulin/parse5?sponsor=1" + } + }, "node_modules/path-exists": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-4.0.0.tgz", @@ -7138,10 +6474,11 @@ "dev": true }, "node_modules/picocolors": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.0.0.tgz", - "integrity": "sha512-1fygroTLlHu66zi26VoTDv8yRgm0Fccecssto+MhsZ0D/DGW2sm8E8AjW7NU5VVTRt5GxbeZ5qBuJr+HyLYkjQ==", - "dev": true + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.1.1.tgz", + "integrity": "sha512-xceH2snhtb5M9liqDsmEw56le376mTZkEX/jEb/RxNFyegNul7eNslCXP9FDj/Lcu0X8KEyMceP2ntpaHrDEVA==", + "dev": true, + "license": "ISC" }, "node_modules/picomatch": { "version": "2.3.1", @@ -7232,6 +6569,16 @@ "once": "^1.3.1" } }, + "node_modules/punycode": { + "version": "2.3.1", + "resolved": "https://registry.npmjs.org/punycode/-/punycode-2.3.1.tgz", + "integrity": "sha512-vYt7UD1U9Wg6138shLtLOvdAu+8DsC/ilFtEVHcH+wydcSpNE20AfSOduf6MkRFahL5FY7X1oU7nKVZFtfq8Fg==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=6" + } + }, "node_modules/queue-microtask": { "version": "1.2.3", "resolved": "https://registry.npmjs.org/queue-microtask/-/queue-microtask-1.2.3.tgz", @@ -7254,10 +6601,11 @@ "license": "MIT" }, "node_modules/react-is": { - "version": "18.2.0", - "resolved": "https://registry.npmjs.org/react-is/-/react-is-18.2.0.tgz", - "integrity": "sha512-xWGDIW6x921xtzPkhiULtthJHoJvBbF3q26fzloPCK0hsvxtPVelvftw3zjbHWSkR2km9Z+4uxbDDK/6Zw9B8w==", - "dev": true + "version": "18.3.1", + "resolved": "https://registry.npmjs.org/react-is/-/react-is-18.3.1.tgz", + "integrity": "sha512-/LLMVyas0ljjAtoYiPqYiL8VWXzUUdThrmU5+n20DZv+a+ClRoevUzw5JxU+Ieh5/c87ytoTBV9G1FiKfNJdmg==", + "dev": true, + "license": "MIT" }, "node_modules/readdirp": { "version": "3.6.0", @@ -7430,6 +6778,13 @@ "node": ">=0.10.0" } }, + "node_modules/rrweb-cssom": { + "version": "0.8.0", + "resolved": "https://registry.npmjs.org/rrweb-cssom/-/rrweb-cssom-0.8.0.tgz", + "integrity": "sha512-guoltQEx+9aMf2gDZ0s62EcV8lsXR+0w8915TC3ITdn2YueuNjdAYh/levpU9nFaoChh9RUS5ZdQMrKfVEN9tw==", + "dev": true, + "license": "MIT" + }, "node_modules/run-parallel": { "version": "1.2.0", "resolved": "https://registry.npmjs.org/run-parallel/-/run-parallel-1.2.0.tgz", @@ -7463,6 +6818,13 @@ "tslib": "^2.1.0" } }, + "node_modules/safer-buffer": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz", + "integrity": "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==", + "dev": true, + "license": "MIT" + }, "node_modules/sass": { "version": "1.57.1", "resolved": "https://registry.npmjs.org/sass/-/sass-1.57.1.tgz", @@ -7486,6 +6848,19 @@ "integrity": "sha512-yqYn1JhPczigF94DMS+shiDMjDowYO6y9+wB/4WgO0Y19jWYk0lQ4tuG5KI7kj4FTp1wxPj5IFfcrz/s1c3jjQ==", "license": "BlueOak-1.0.0" }, + "node_modules/saxes": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/saxes/-/saxes-6.0.0.tgz", + "integrity": "sha512-xAg7SOnEhrm5zI3puOOKyy1OMcMlIJZYNJY7xLBwSze0UjhPLnWfj2GF2EpT0jmzaJKIWKHLsaSSajf35bcYnA==", + "dev": true, + "license": "ISC", + "dependencies": { + "xmlchars": "^2.2.0" + }, + "engines": { + "node": ">=v12.22.7" + } + }, "node_modules/semver": { "version": "6.3.0", "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.0.tgz", @@ -7924,15 +7299,16 @@ } }, "node_modules/supports-color": { - "version": "5.5.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.5.0.tgz", - "integrity": "sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==", + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", "dev": true, + "license": "MIT", "dependencies": { - "has-flag": "^3.0.0" + "has-flag": "^4.0.0" }, "engines": { - "node": ">=4" + "node": ">=8" } }, "node_modules/supports-preserve-symlinks-flag": { @@ -7947,6 +7323,13 @@ "url": "https://github.com/sponsors/ljharb" } }, + "node_modules/symbol-tree": { + "version": "3.2.4", + "resolved": "https://registry.npmjs.org/symbol-tree/-/symbol-tree-3.2.4.tgz", + "integrity": "sha512-9QNk5KwDF+Bvz+PyObkmSYjI5ksVUYtjW7AU22r2NKcfLJcXp96hkDWU3+XndOsUb+AQ9QhfzfCT2O+CNWT5Tw==", + "dev": true, + "license": "MIT" + }, "node_modules/test-exclude": { "version": "6.0.0", "resolved": "https://registry.npmjs.org/test-exclude/-/test-exclude-6.0.0.tgz", @@ -7967,6 +7350,26 @@ "integrity": "sha512-GbHabT+Irv+ihI1/f5kIIsZ+Ef9Sl5A1Y7imvS5RQjWgtTPfPnZ43JmlYI7NtCRDK9zir20lQpfg8/9Yd02OvQ==", "license": "MIT" }, + "node_modules/tldts": { + "version": "6.1.86", + "resolved": "https://registry.npmjs.org/tldts/-/tldts-6.1.86.tgz", + "integrity": "sha512-WMi/OQ2axVTf/ykqCQgXiIct+mSQDFdH2fkwhPwgEwvJ1kSzZRiinb0zF2Xb8u4+OqPChmyI6MEu4EezNJz+FQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "tldts-core": "^6.1.86" + }, + "bin": { + "tldts": "bin/cli.js" + } + }, + "node_modules/tldts-core": { + "version": "6.1.86", + "resolved": "https://registry.npmjs.org/tldts-core/-/tldts-core-6.1.86.tgz", + "integrity": "sha512-Je6p7pkk+KMzMv2XXKmAE3McmolOQFdxkKw0R8EYNr7sELW46JqnNeTX8ybPiQgvg1ymCoF8LXs5fzFaZvJPTA==", + "dev": true, + "license": "MIT" + }, "node_modules/tmpl": { "version": "1.0.5", "resolved": "https://registry.npmjs.org/tmpl/-/tmpl-1.0.5.tgz", @@ -7995,6 +7398,32 @@ "node": ">=8.0" } }, + "node_modules/tough-cookie": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/tough-cookie/-/tough-cookie-5.1.2.tgz", + "integrity": "sha512-FVDYdxtnj0G6Qm/DhNPSb8Ju59ULcup3tuJxkFb5K8Bv2pUXILbf0xZWU8PX8Ov19OXljbUyveOFwRMwkXzO+A==", + "dev": true, + "license": "BSD-3-Clause", + "dependencies": { + "tldts": "^6.1.32" + }, + "engines": { + "node": ">=16" + } + }, + "node_modules/tr46": { + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/tr46/-/tr46-5.1.1.tgz", + "integrity": "sha512-hdF5ZgjTqgAntKkklYw0R03MG2x/bSzTtkxmIRw/sTNV8YXsCJ1tfLAX23lhxhHJlEf3CRCOCGGWw3vI3GaSPw==", + "dev": true, + "license": "MIT", + "dependencies": { + "punycode": "^2.3.1" + }, + "engines": { + "node": ">=18" + } + }, "node_modules/ts-jest": { "version": "29.0.0", "resolved": "https://registry.npmjs.org/ts-jest/-/ts-jest-29.0.0.tgz", @@ -8272,6 +7701,19 @@ "webworker-threads": "^0.7.12" } }, + "node_modules/w3c-xmlserializer": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/w3c-xmlserializer/-/w3c-xmlserializer-5.0.0.tgz", + "integrity": "sha512-o8qghlI8NZHU1lLPrpi2+Uq7abh4GGPpYANlalzWxyWteJOCsr/P+oPBA49TOLu5FTZO4d3F9MnWJfiMo4BkmA==", + "dev": true, + "license": "MIT", + "dependencies": { + "xml-name-validator": "^5.0.0" + }, + "engines": { + "node": ">=18" + } + }, "node_modules/walker": { "version": "1.0.8", "resolved": "https://registry.npmjs.org/walker/-/walker-1.0.8.tgz", @@ -8281,18 +7723,66 @@ "makeerror": "1.0.12" } }, - "node_modules/webworker-threads": { - "version": "0.7.17", - "resolved": "https://registry.npmjs.org/webworker-threads/-/webworker-threads-0.7.17.tgz", - "integrity": "sha512-Y2w2aXBbDLk9IzTEb9u+MsODC3s4YlGI7g4h0t+1OAwIO8yBI9rQL35ZYlyayiCuWu1dZMH/P7kGU8OwW7YsyA==", - "hasInstallScript": true, - "optional": true, + "node_modules/webidl-conversions": { + "version": "7.0.0", + "resolved": "https://registry.npmjs.org/webidl-conversions/-/webidl-conversions-7.0.0.tgz", + "integrity": "sha512-VwddBukDzu71offAQR975unBIGqfKZpM+8ZX6ySk8nYhVoo5CYaZyzt3YBvYtRtO+aoGlqxPg/B87NGVZ/fu6g==", + "dev": true, + "license": "BSD-2-Clause", + "engines": { + "node": ">=12" + } + }, + "node_modules/webworker-threads": { + "version": "0.7.17", + "resolved": "https://registry.npmjs.org/webworker-threads/-/webworker-threads-0.7.17.tgz", + "integrity": "sha512-Y2w2aXBbDLk9IzTEb9u+MsODC3s4YlGI7g4h0t+1OAwIO8yBI9rQL35ZYlyayiCuWu1dZMH/P7kGU8OwW7YsyA==", + "hasInstallScript": true, + "optional": true, + "dependencies": { + "bindings": "^1.3.0", + "nan": "^2.11.0" + }, + "engines": { + "node": ">= 0.10.16" + } + }, + "node_modules/whatwg-encoding": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/whatwg-encoding/-/whatwg-encoding-3.1.1.tgz", + "integrity": "sha512-6qN4hJdMwfYBtE3YBTTHhoeuUrDBPZmbQaxWAqSALV/MeEnR5z1xd8UKud2RAkFoPkmB+hli1TZSnyi84xz1vQ==", + "deprecated": "Use @exodus/bytes instead for a more spec-conformant and faster implementation", + "dev": true, + "license": "MIT", + "dependencies": { + "iconv-lite": "0.6.3" + }, + "engines": { + "node": ">=18" + } + }, + "node_modules/whatwg-mimetype": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/whatwg-mimetype/-/whatwg-mimetype-4.0.0.tgz", + "integrity": "sha512-QaKxh0eNIi2mE9p2vEdzfagOKHCcj1pJ56EEHGQOVxp8r9/iszLUUV7v89x9O1p/T+NlTM5W7jW6+cz4Fq1YVg==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=18" + } + }, + "node_modules/whatwg-url": { + "version": "14.2.0", + "resolved": "https://registry.npmjs.org/whatwg-url/-/whatwg-url-14.2.0.tgz", + "integrity": "sha512-De72GdQZzNTUBBChsXueQUnPKDkg/5A5zp7pFDuQAj5UFoENpiACU0wlCvzpAGnTkj++ihpKwKyYewn/XNUbKw==", + "dev": true, + "license": "MIT", "dependencies": { - "bindings": "^1.3.0", - "nan": "^2.11.0" + "tr46": "^5.1.0", + "webidl-conversions": "^7.0.0" }, "engines": { - "node": ">= 0.10.16" + "node": ">=18" } }, "node_modules/which": { @@ -8327,39 +7817,6 @@ "url": "https://github.com/chalk/wrap-ansi?sponsor=1" } }, - "node_modules/wrap-ansi/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/wrap-ansi/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/wrap-ansi/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, "node_modules/wrappy": { "version": "1.0.2", "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", @@ -8379,6 +7836,45 @@ "node": "^12.13.0 || ^14.15.0 || >=16.0.0" } }, + "node_modules/ws": { + "version": "8.19.0", + "resolved": "https://registry.npmjs.org/ws/-/ws-8.19.0.tgz", + "integrity": "sha512-blAT2mjOEIi0ZzruJfIhb3nps74PRWTCz1IjglWEEpQl5XS/UNama6u2/rjFkDDouqr4L67ry+1aGIALViWjDg==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=10.0.0" + }, + "peerDependencies": { + "bufferutil": "^4.0.1", + "utf-8-validate": ">=5.0.2" + }, + "peerDependenciesMeta": { + "bufferutil": { + "optional": true + }, + "utf-8-validate": { + "optional": true + } + } + }, + "node_modules/xml-name-validator": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/xml-name-validator/-/xml-name-validator-5.0.0.tgz", + "integrity": "sha512-EvGK8EJ3DhaHfbRlETOWAS5pO9MZITeauHKJyb8wyajUfQUenkIg2MvLDTZ4T/TgIcm3HU0TFBgWWboAZ30UHg==", + "dev": true, + "license": "Apache-2.0", + "engines": { + "node": ">=18" + } + }, + "node_modules/xmlchars": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/xmlchars/-/xmlchars-2.2.0.tgz", + "integrity": "sha512-JZnDKK8B0RCDw84FNdDAIpZK+JuJw+s7Lz8nksI7SIuU3UXJJslUthsi+uWBUYOwPFwW7W7PRLRfUKpxjtjFCw==", + "dev": true, + "license": "MIT" + }, "node_modules/y18n": { "version": "5.0.8", "resolved": "https://registry.npmjs.org/y18n/-/y18n-5.0.8.tgz", @@ -8444,13 +7940,36 @@ } }, "dependencies": { + "@asamuzakjp/css-color": { + "version": "3.2.0", + "resolved": "https://registry.npmjs.org/@asamuzakjp/css-color/-/css-color-3.2.0.tgz", + "integrity": "sha512-K1A6z8tS3XsmCMM86xoWdn7Fkdn9m6RSVtocUrJYIwZnFVkng/PvkEoWtOWmP+Scc6saYWHWZYbndEEXxl24jw==", + "dev": true, + "requires": { + "@csstools/css-calc": "^2.1.3", + "@csstools/css-color-parser": "^3.0.9", + "@csstools/css-parser-algorithms": "^3.0.4", + "@csstools/css-tokenizer": "^3.0.3", + "lru-cache": "^10.4.3" + }, + "dependencies": { + "lru-cache": { + "version": "10.4.3", + "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-10.4.3.tgz", + "integrity": "sha512-JNAzZcXrCt42VGLuYz0zfAzDfAvJWW6AfYlDBQyDV5DClI2m5sAmK+OIO7s59XfsRsWHp02jAJrRadPRGTt6SQ==", + "dev": true + } + } + }, "@babel/code-frame": { - "version": "7.18.6", - "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.18.6.tgz", - "integrity": "sha512-TDCmlK5eOvH+eH7cdAFlNXeVJqWIQ7gW9tY1GJIpUtFb6CmjVyq2VM3u71bOyR8CRihcCgMUYoDNyLXao3+70Q==", + "version": "7.28.6", + "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.28.6.tgz", + "integrity": "sha512-JYgintcMjRiCvS8mMECzaEn+m3PfoQiyqukOMCCVQtoJGYJw8j/8LBJEiqkHLkfwCcs74E3pbAUFNg7d9VNJ+Q==", "dev": true, "requires": { - "@babel/highlight": "^7.18.6" + "@babel/helper-validator-identifier": "^7.28.5", + "js-tokens": "^4.0.0", + "picocolors": "^1.1.1" } }, "@babel/compat-data": { @@ -8711,9 +8230,9 @@ "dev": true }, "@babel/helper-validator-identifier": { - "version": "7.19.1", - "resolved": "https://registry.npmjs.org/@babel/helper-validator-identifier/-/helper-validator-identifier-7.19.1.tgz", - "integrity": "sha512-awrNfaMtnHUr653GgGEs++LlAvW6w+DcPrOliSMXWCKo597CwL5Acf/wWdNkf/tfEQE3mjkeD1YOVZOUV/od1w==", + "version": "7.28.5", + "resolved": "https://registry.npmjs.org/@babel/helper-validator-identifier/-/helper-validator-identifier-7.28.5.tgz", + "integrity": "sha512-qSs4ifwzKJSV39ucNjsvc6WVHs6b7S03sOh2OcHF9UHfVPqWWALUsNUVzhSBiItjRZoLHx7nIarVjqKVusUZ1Q==", "dev": true }, "@babel/helper-validator-option": { @@ -8745,17 +8264,6 @@ "@babel/types": "^7.21.0" } }, - "@babel/highlight": { - "version": "7.18.6", - "resolved": "https://registry.npmjs.org/@babel/highlight/-/highlight-7.18.6.tgz", - "integrity": "sha512-u7stbOuYjaPezCuLj29hNW1v64M2Md2qupEKP1fHc7WdOA3DgLh37suiSrZYY7haUB7iBeQZ9P1uiRF359do3g==", - "dev": true, - "requires": { - "@babel/helper-validator-identifier": "^7.18.6", - "chalk": "^2.0.0", - "js-tokens": "^4.0.0" - } - }, "@babel/parser": { "version": "7.21.2", "resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.21.2.tgz", @@ -9703,6 +9211,42 @@ } } }, + "@csstools/color-helpers": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/@csstools/color-helpers/-/color-helpers-5.1.0.tgz", + "integrity": "sha512-S11EXWJyy0Mz5SYvRmY8nJYTFFd1LCNV+7cXyAgQtOOuzb4EsgfqDufL+9esx72/eLhsRdGZwaldu/h+E4t4BA==", + "dev": true + }, + "@csstools/css-calc": { + "version": "2.1.4", + "resolved": "https://registry.npmjs.org/@csstools/css-calc/-/css-calc-2.1.4.tgz", + "integrity": "sha512-3N8oaj+0juUw/1H3YwmDDJXCgTB1gKU6Hc/bB502u9zR0q2vd786XJH9QfrKIEgFlZmhZiq6epXl4rHqhzsIgQ==", + "dev": true, + "requires": {} + }, + "@csstools/css-color-parser": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/@csstools/css-color-parser/-/css-color-parser-3.1.0.tgz", + "integrity": "sha512-nbtKwh3a6xNVIp/VRuXV64yTKnb1IjTAEEh3irzS+HkKjAOYLTGNb9pmVNntZ8iVBHcWDA2Dof0QtPgFI1BaTA==", + "dev": true, + "requires": { + "@csstools/color-helpers": "^5.1.0", + "@csstools/css-calc": "^2.1.4" + } + }, + "@csstools/css-parser-algorithms": { + "version": "3.0.5", + "resolved": "https://registry.npmjs.org/@csstools/css-parser-algorithms/-/css-parser-algorithms-3.0.5.tgz", + "integrity": "sha512-DaDeUkXZKjdGhgYaHNJTV9pV7Y9B3b644jCLs9Upc3VeNGg6LWARAT6O+Q+/COo+2gg/bM5rhpMAtf70WqfBdQ==", + "dev": true, + "requires": {} + }, + "@csstools/css-tokenizer": { + "version": "3.0.4", + "resolved": "https://registry.npmjs.org/@csstools/css-tokenizer/-/css-tokenizer-3.0.4.tgz", + "integrity": "sha512-Vd/9EVDiu6PPJt9yAh6roZP6El1xHrdvIVGjyBsHR0RYwNHgL7FJPyIIW4fANJNG6FtyZfvlRPpFI4ZM/lubvw==", + "dev": true + }, "@dimforge/rapier3d-compat": { "version": "0.12.0", "resolved": "https://registry.npmjs.org/@dimforge/rapier3d-compat/-/rapier3d-compat-0.12.0.tgz", @@ -9961,57 +9505,6 @@ "jest-message-util": "^29.4.3", "jest-util": "^29.4.3", "slash": "^3.0.0" - }, - "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, - "chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - } - }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true - }, - "supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "requires": { - "has-flag": "^4.0.0" - } - } } }, "@jest/core": { @@ -10048,71 +9541,184 @@ "pretty-format": "^29.4.3", "slash": "^3.0.0", "strip-ansi": "^6.0.0" + } + }, + "@jest/environment": { + "version": "29.4.3", + "resolved": "https://registry.npmjs.org/@jest/environment/-/environment-29.4.3.tgz", + "integrity": "sha512-dq5S6408IxIa+lr54zeqce+QgI+CJT4nmmA+1yzFgtcsGK8c/EyiUb9XQOgz3BMKrRDfKseeOaxj2eO8LlD3lA==", + "dev": true, + "requires": { + "@jest/fake-timers": "^29.4.3", + "@jest/types": "^29.4.3", + "@types/node": "*", + "jest-mock": "^29.4.3" + } + }, + "@jest/environment-jsdom-abstract": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/environment-jsdom-abstract/-/environment-jsdom-abstract-30.2.0.tgz", + "integrity": "sha512-kazxw2L9IPuZpQ0mEt9lu9Z98SqR74xcagANmMBU16X0lS23yPc0+S6hGLUz8kVRlomZEs/5S/Zlpqwf5yu6OQ==", + "dev": true, + "requires": { + "@jest/environment": "30.2.0", + "@jest/fake-timers": "30.2.0", + "@jest/types": "30.2.0", + "@types/jsdom": "^21.1.7", + "@types/node": "*", + "jest-mock": "30.2.0", + "jest-util": "30.2.0" }, "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "@jest/environment": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/environment/-/environment-30.2.0.tgz", + "integrity": "sha512-/QPTL7OBJQ5ac09UDRa3EQes4gt1FTEG/8jZ/4v5IVzx+Cv7dLxlVIvfvSVRiiX2drWyXeBjkMSR8hvOWSog5g==", "dev": true, "requires": { - "color-convert": "^2.0.1" + "@jest/fake-timers": "30.2.0", + "@jest/types": "30.2.0", + "@types/node": "*", + "jest-mock": "30.2.0" } }, - "chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "@jest/fake-timers": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/fake-timers/-/fake-timers-30.2.0.tgz", + "integrity": "sha512-HI3tRLjRxAbBy0VO8dqqm7Hb2mIa8d5bg/NJkyQcOk7V118ObQML8RC5luTF/Zsg4474a+gDvhce7eTnP4GhYw==", "dev": true, "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" + "@jest/types": "30.2.0", + "@sinonjs/fake-timers": "^13.0.0", + "@types/node": "*", + "jest-message-util": "30.2.0", + "jest-mock": "30.2.0", + "jest-util": "30.2.0" } }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "@jest/schemas": { + "version": "30.0.5", + "resolved": "https://registry.npmjs.org/@jest/schemas/-/schemas-30.0.5.tgz", + "integrity": "sha512-DmdYgtezMkh3cpU8/1uyXakv3tJRcmcXxBOcO0tbaozPwpmh4YMsnWrQm9ZmZMfa5ocbxzbFk6O4bDPEc/iAnA==", "dev": true, "requires": { - "color-name": "~1.1.4" + "@sinclair/typebox": "^0.34.0" } }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", + "@jest/types": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/types/-/types-30.2.0.tgz", + "integrity": "sha512-H9xg1/sfVvyfU7o3zMfBEjQ1gcsdeTMgqHoYdN79tuLqfTtuu7WckRA1R5whDwOzxaZAeMKTYWqP+WCAi0CHsg==", + "dev": true, + "requires": { + "@jest/pattern": "30.0.1", + "@jest/schemas": "30.0.5", + "@types/istanbul-lib-coverage": "^2.0.6", + "@types/istanbul-reports": "^3.0.4", + "@types/node": "*", + "@types/yargs": "^17.0.33", + "chalk": "^4.1.2" + } + }, + "@sinclair/typebox": { + "version": "0.34.47", + "resolved": "https://registry.npmjs.org/@sinclair/typebox/-/typebox-0.34.47.tgz", + "integrity": "sha512-ZGIBQ+XDvO5JQku9wmwtabcVTHJsgSWAHYtVuM9pBNNR5E88v6Jcj/llpmsjivig5X8A8HHOb4/mbEKPS5EvAw==", "dev": true }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "@sinonjs/commons": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/@sinonjs/commons/-/commons-3.0.1.tgz", + "integrity": "sha512-K3mCHKQ9sVh8o1C9cxkwxaOmXoAMlDxC1mYyHrjqOWEcBjYr76t96zL2zlj5dUGZ3HSw240X1qgH3Mjf1yJWpQ==", + "dev": true, + "requires": { + "type-detect": "4.0.8" + } + }, + "@sinonjs/fake-timers": { + "version": "13.0.5", + "resolved": "https://registry.npmjs.org/@sinonjs/fake-timers/-/fake-timers-13.0.5.tgz", + "integrity": "sha512-36/hTbH2uaWuGVERyC6da9YwGWnzUZXuPro/F2LfsdOsLnCojz/iSH8MxUt/FD2S5XBSVPhmArFUXcpCQ2Hkiw==", + "dev": true, + "requires": { + "@sinonjs/commons": "^3.0.1" + } + }, + "ci-info": { + "version": "4.3.1", + "resolved": "https://registry.npmjs.org/ci-info/-/ci-info-4.3.1.tgz", + "integrity": "sha512-Wdy2Igu8OcBpI2pZePZ5oWjPC38tmDVx5WKUXKwlLYkA0ozo85sLsLvkBbBn/sZaSCMFOGZJ14fvW9t5/d7kdA==", "dev": true }, - "supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "jest-message-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-message-util/-/jest-message-util-30.2.0.tgz", + "integrity": "sha512-y4DKFLZ2y6DxTWD4cDe07RglV88ZiNEdlRfGtqahfbIjfsw1nMCPx49Uev4IA/hWn3sDKyAnSPwoYSsAEdcimw==", "dev": true, "requires": { - "has-flag": "^4.0.0" + "@babel/code-frame": "^7.27.1", + "@jest/types": "30.2.0", + "@types/stack-utils": "^2.0.3", + "chalk": "^4.1.2", + "graceful-fs": "^4.2.11", + "micromatch": "^4.0.8", + "pretty-format": "30.2.0", + "slash": "^3.0.0", + "stack-utils": "^2.0.6" + } + }, + "jest-mock": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-mock/-/jest-mock-30.2.0.tgz", + "integrity": "sha512-JNNNl2rj4b5ICpmAcq+WbLH83XswjPbjH4T7yvGzfAGCPh1rw+xVNbtk+FnRslvt9lkCcdn9i1oAoKUuFsOxRw==", + "dev": true, + "requires": { + "@jest/types": "30.2.0", + "@types/node": "*", + "jest-util": "30.2.0" + } + }, + "jest-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-30.2.0.tgz", + "integrity": "sha512-QKNsM0o3Xe6ISQU869e+DhG+4CK/48aHYdJZGlFQVTjnbvgpcKyxpzk29fGiO7i/J8VENZ+d2iGnSsvmuHywlA==", + "dev": true, + "requires": { + "@jest/types": "30.2.0", + "@types/node": "*", + "chalk": "^4.1.2", + "ci-info": "^4.2.0", + "graceful-fs": "^4.2.11", + "picomatch": "^4.0.2" + } + }, + "picomatch": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.3.tgz", + "integrity": "sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==", + "dev": true + }, + "pretty-format": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/pretty-format/-/pretty-format-30.2.0.tgz", + "integrity": "sha512-9uBdv/B4EefsuAL+pWqueZyZS2Ba+LxfFeQ9DN14HU4bN8bhaxKdkpjpB6fs9+pSjIBu+FXQHImEg8j/Lw0+vA==", + "dev": true, + "requires": { + "@jest/schemas": "30.0.5", + "ansi-styles": "^5.2.0", + "react-is": "^18.3.1" + }, + "dependencies": { + "ansi-styles": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-5.2.0.tgz", + "integrity": "sha512-Cxwpt2SfTzTtXcfOlzGEee8O+c+MmUgGrNiBcXnuWxuFJHe6a5Hz7qwhwe5OgaSYI0IJvkLqWX1ASG+cJOkEiA==", + "dev": true + } } } } }, - "@jest/environment": { - "version": "29.4.3", - "resolved": "https://registry.npmjs.org/@jest/environment/-/environment-29.4.3.tgz", - "integrity": "sha512-dq5S6408IxIa+lr54zeqce+QgI+CJT4nmmA+1yzFgtcsGK8c/EyiUb9XQOgz3BMKrRDfKseeOaxj2eO8LlD3lA==", - "dev": true, - "requires": { - "@jest/fake-timers": "^29.4.3", - "@jest/types": "^29.4.3", - "@types/node": "*", - "jest-mock": "^29.4.3" - } - }, "@jest/expect": { "version": "29.4.3", "resolved": "https://registry.npmjs.org/@jest/expect/-/expect-29.4.3.tgz", @@ -10158,6 +9764,24 @@ "jest-mock": "^29.4.3" } }, + "@jest/pattern": { + "version": "30.0.1", + "resolved": "https://registry.npmjs.org/@jest/pattern/-/pattern-30.0.1.tgz", + "integrity": "sha512-gWp7NfQW27LaBQz3TITS8L7ZCQ0TLvtmI//4OwlQRx4rnWxcPNIYjxZpDcN4+UlGxgm3jS5QPz8IPTCkb59wZA==", + "dev": true, + "requires": { + "@types/node": "*", + "jest-regex-util": "30.0.1" + }, + "dependencies": { + "jest-regex-util": { + "version": "30.0.1", + "resolved": "https://registry.npmjs.org/jest-regex-util/-/jest-regex-util-30.0.1.tgz", + "integrity": "sha512-jHEQgBXAgc+Gh4g0p3bCevgRCVRkB4VB70zhoAE48gxeSr1hfUOsM/C2WoJgVL7Eyg//hudYENbm3Ne+/dRVVA==", + "dev": true + } + } + }, "@jest/reporters": { "version": "29.4.3", "resolved": "https://registry.npmjs.org/@jest/reporters/-/reporters-29.4.3.tgz", @@ -10188,57 +9812,6 @@ "string-length": "^4.0.1", "strip-ansi": "^6.0.0", "v8-to-istanbul": "^9.0.1" - }, - "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, - "chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - } - }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true - }, - "supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "requires": { - "has-flag": "^4.0.0" - } - } } }, "@jest/schemas": { @@ -10304,64 +9877,15 @@ "jest-util": "^29.4.3", "micromatch": "^4.0.4", "pirates": "^4.0.4", - "slash": "^3.0.0", - "write-file-atomic": "^4.0.2" - }, - "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, - "chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - } - }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, + "slash": "^3.0.0", + "write-file-atomic": "^4.0.2" + }, + "dependencies": { "convert-source-map": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/convert-source-map/-/convert-source-map-2.0.0.tgz", "integrity": "sha512-Kvp459HrV2FEJ1CAsi1Ku+MY3kasH19TFykTz2xWmMeq6bk2NU3XXvfJ+Q61m0xktWwt+1HSYf3JZsTms3aRJg==", "dev": true - }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true - }, - "supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "requires": { - "has-flag": "^4.0.0" - } } } }, @@ -10377,57 +9901,6 @@ "@types/node": "*", "@types/yargs": "^17.0.8", "chalk": "^4.0.0" - }, - "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, - "chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - } - }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true - }, - "supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "requires": { - "has-flag": "^4.0.0" - } - } } }, "@jridgewell/gen-mapping": { @@ -10594,15 +10067,6 @@ "redent": "^3.0.0" }, "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, "chalk": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/chalk/-/chalk-3.0.0.tgz", @@ -10612,36 +10076,6 @@ "ansi-styles": "^4.1.0", "supports-color": "^7.1.0" } - }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true - }, - "supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "requires": { - "has-flag": "^4.0.0" - } } } }, @@ -10726,9 +10160,9 @@ } }, "@types/istanbul-lib-coverage": { - "version": "2.0.4", - "resolved": "https://registry.npmjs.org/@types/istanbul-lib-coverage/-/istanbul-lib-coverage-2.0.4.tgz", - "integrity": "sha512-z/QT1XN4K4KYuslS23k62yDIDLwLFkzxOuMplDtObz0+y7VqJCaO2o+SPwHCvLFZh7xazvvoor2tA/hPz9ee7g==", + "version": "2.0.6", + "resolved": "https://registry.npmjs.org/@types/istanbul-lib-coverage/-/istanbul-lib-coverage-2.0.6.tgz", + "integrity": "sha512-2QF/t/auWm0lsy8XtKVPG19v3sSOQlJe/YHZgfjb/KBBHOGSV+J2q/S671rcq9uTBrLAXmZpqJiaQbMT+zNU1w==", "dev": true }, "@types/istanbul-lib-report": { @@ -10741,9 +10175,9 @@ } }, "@types/istanbul-reports": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/@types/istanbul-reports/-/istanbul-reports-3.0.1.tgz", - "integrity": "sha512-c3mAZEuK0lvBp8tmuL74XRKn1+y2dcwOUpH7x4WrF6gk1GIgiluDRgMYQtw2OFcBvAJWlt6ASU3tSqxp0Uu0Aw==", + "version": "3.0.4", + "resolved": "https://registry.npmjs.org/@types/istanbul-reports/-/istanbul-reports-3.0.4.tgz", + "integrity": "sha512-pk2B1NWalF9toCRu6gjBzR69syFjP4Od8WRAX+0mmf9lAjCRicLOWc+ZrxZHx/0XRjotgkF9t6iaMJ+aXcOdZQ==", "dev": true, "requires": { "@types/istanbul-lib-report": "*" @@ -10759,6 +10193,17 @@ "pretty-format": "^29.0.0" } }, + "@types/jsdom": { + "version": "21.1.7", + "resolved": "https://registry.npmjs.org/@types/jsdom/-/jsdom-21.1.7.tgz", + "integrity": "sha512-yOriVnggzrnQ3a9OKOCxaVuSug3w3/SbOj5i7VwXWZEyUNl3bLF9V3MfxGbZKuwqJOQyRfqXyROBB1CoZLFWzA==", + "dev": true, + "requires": { + "@types/node": "*", + "@types/tough-cookie": "*", + "parse5": "^7.0.0" + } + }, "@types/ndarray": { "version": "1.0.14", "resolved": "https://registry.npmjs.org/@types/ndarray/-/ndarray-1.0.14.tgz", @@ -10777,9 +10222,9 @@ "dev": true }, "@types/stack-utils": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/@types/stack-utils/-/stack-utils-2.0.1.tgz", - "integrity": "sha512-Hl219/BT5fLAaz6NDkSuhzasy49dwQS/DSdu4MdggFB8zcXv7vflBI3xp7FEmkmdDkBUI2bPUNeMttp2knYdxw==", + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/@types/stack-utils/-/stack-utils-2.0.3.tgz", + "integrity": "sha512-9aEbYZ3TbYMznPdcdr3SmIrLXwC/AKZXQeCf9Pgao5CKb8CyHuEX5jzWPTkvregvhRJHcpRO6BFoGW9ycaOkYw==", "dev": true }, "@types/stats.js": { @@ -10820,6 +10265,12 @@ } } }, + "@types/tough-cookie": { + "version": "4.0.5", + "resolved": "https://registry.npmjs.org/@types/tough-cookie/-/tough-cookie-4.0.5.tgz", + "integrity": "sha512-/Ad8+nIOV7Rl++6f1BdKxFSMgmoqEoYbHRpPcx3JEfv8VRsQe9Z4mCXeJBzxs7mbHY/XOZZuXlRNfhpVPbs6ZA==", + "dev": true + }, "@types/webxr": { "version": "0.5.20", "resolved": "https://registry.npmjs.org/@types/webxr/-/webxr-0.5.20.tgz", @@ -10827,9 +10278,9 @@ "dev": true }, "@types/yargs": { - "version": "17.0.22", - "resolved": "https://registry.npmjs.org/@types/yargs/-/yargs-17.0.22.tgz", - "integrity": "sha512-pet5WJ9U8yPVRhkwuEIp5ktAeAqRZOq4UdAyWLWzxbtpyXnzbtLdKiXAjJzi/KLmPGS9wk86lUFWZFN6sISo4g==", + "version": "17.0.35", + "resolved": "https://registry.npmjs.org/@types/yargs/-/yargs-17.0.35.tgz", + "integrity": "sha512-qUHkeCyQFxMXg79wQfTtfndEC+N9ZZg76HJftDJp+qH2tV7Gj4OJi7l+PiWwJ+pWtW8GwSmqsDj/oymhrTWXjg==", "dev": true, "requires": { "@types/yargs-parser": "*" @@ -10859,6 +10310,12 @@ "integrity": "sha512-k+iyHEuPgSw6SbuDpGQM+06HQUa04DZ3o+F6CSzXMvvI5KMvnaEqXe+YVe555R9nn6GPt404fos4wcgpw12SDA==", "dev": true }, + "agent-base": { + "version": "7.1.4", + "resolved": "https://registry.npmjs.org/agent-base/-/agent-base-7.1.4.tgz", + "integrity": "sha512-MnA+YT8fwfJPgBx3m60MNqakm30XOkyIoH1y6huTQvC0PwZG7ki8NacLBcrPbNoo8vEZy7Jpuk7+jMO+CUovTQ==", + "dev": true + }, "ansi-escapes": { "version": "4.3.2", "resolved": "https://registry.npmjs.org/ansi-escapes/-/ansi-escapes-4.3.2.tgz", @@ -10875,12 +10332,12 @@ "dev": true }, "ansi-styles": { - "version": "3.2.1", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz", - "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", "dev": true, "requires": { - "color-convert": "^1.9.0" + "color-convert": "^2.0.1" } }, "anymatch": { @@ -10943,57 +10400,6 @@ "chalk": "^4.0.0", "graceful-fs": "^4.2.9", "slash": "^3.0.0" - }, - "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, - "chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - } - }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true - }, - "supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "requires": { - "has-flag": "^4.0.0" - } - } } }, "babel-plugin-istanbul": { @@ -11176,14 +10582,13 @@ "dev": true }, "chalk": { - "version": "2.4.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.2.tgz", - "integrity": "sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==", + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", "dev": true, "requires": { - "ansi-styles": "^3.2.1", - "escape-string-regexp": "^1.0.5", - "supports-color": "^5.3.0" + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" } }, "char-regex": { @@ -11244,18 +10649,18 @@ "dev": true }, "color-convert": { - "version": "1.9.3", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-1.9.3.tgz", - "integrity": "sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg==", + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", "dev": true, "requires": { - "color-name": "1.1.3" + "color-name": "~1.1.4" } }, "color-name": { - "version": "1.1.3", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.3.tgz", - "integrity": "sha512-72fSenhMw2HZMTVHeCA9KCmpEIbzWiQsjN+BHcBbS9vr1mtt+vJjPdksIBNUmKAW8TFUDPJK5SUU3QhE9NEXDw==", + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", "dev": true }, "commander": { @@ -11337,6 +10742,16 @@ "integrity": "sha512-YUifsXXuknHlUsmlgyY0PKzgPOr7/FjCePfHNt0jxm83wHZi44VDMQ7/fGNkjY3/jV1MC+1CmZbaHzugyeRtpg==", "dev": true }, + "cssstyle": { + "version": "4.6.0", + "resolved": "https://registry.npmjs.org/cssstyle/-/cssstyle-4.6.0.tgz", + "integrity": "sha512-2z+rWdzbbSZv6/rhtvzvqeZQHrBaqgogqt85sqFNbabZOuFbCVFb8kPeEtZjiKkbrm395irpNKiYeFeLiQnFPg==", + "dev": true, + "requires": { + "@asamuzakjp/css-color": "^3.2.0", + "rrweb-cssom": "^0.8.0" + } + }, "cwise-compiler": { "version": "1.1.3", "resolved": "https://registry.npmjs.org/cwise-compiler/-/cwise-compiler-1.1.3.tgz", @@ -11345,6 +10760,16 @@ "uniq": "^1.0.0" } }, + "data-urls": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/data-urls/-/data-urls-5.0.0.tgz", + "integrity": "sha512-ZYP5VBHshaDAiVZxjbRVcFJpc+4xGgT0bK3vzy1HLN8jTO975HEbuYzZJcHoQEY5K1a0z8YayJkyVETa08eNTg==", + "dev": true, + "requires": { + "whatwg-mimetype": "^4.0.0", + "whatwg-url": "^14.0.0" + } + }, "debug": { "version": "4.3.4", "resolved": "https://registry.npmjs.org/debug/-/debug-4.3.4.tgz", @@ -11354,6 +10779,12 @@ "ms": "2.1.2" } }, + "decimal.js": { + "version": "10.6.0", + "resolved": "https://registry.npmjs.org/decimal.js/-/decimal.js-10.6.0.tgz", + "integrity": "sha512-YpgQiITW3JXGntzdUmyUR1V812Hn8T1YVXhCu+wO3OpS4eU9l4YdD3qjyiKdV6mvV29zapkMeD390UVEf2lkUg==", + "dev": true + }, "decode-uri-component": { "version": "0.2.2", "resolved": "https://registry.npmjs.org/decode-uri-component/-/decode-uri-component-0.2.2.tgz", @@ -11434,6 +10865,12 @@ "once": "^1.4.0" } }, + "entities": { + "version": "6.0.1", + "resolved": "https://registry.npmjs.org/entities/-/entities-6.0.1.tgz", + "integrity": "sha512-aN97NXWF6AWBTahfVOIrB/NShkzi5H7F9r1s9mD3cDj4Ko5f2qhhVoYMibXF7GlLveb/D2ioWay8lxI97Ven3g==", + "dev": true + }, "error-ex": { "version": "1.3.2", "resolved": "https://registry.npmjs.org/error-ex/-/error-ex-1.3.2.tgz", @@ -11462,12 +10899,6 @@ "integrity": "sha512-k0er2gUkLf8O0zKJiAhmkTnJlTvINGv7ygDNPbeIsX/TJjGJZHuh9B2UxbsaEkmlEo9MfhrSzmhIlhRlI2GXnw==", "dev": true }, - "escape-string-regexp": { - "version": "1.0.5", - "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz", - "integrity": "sha512-vbRorB5FUQWvla16U8R/qgaFIya2qGzwDrNmCZuYKrbdSUMG6I1ZCGQRefkRVhuOkIGVne7BQ35DSfo1qvJqFg==", - "dev": true - }, "esprima": { "version": "4.0.1", "resolved": "https://registry.npmjs.org/esprima/-/esprima-4.0.1.tgz", @@ -11674,9 +11105,9 @@ "dev": true }, "graceful-fs": { - "version": "4.2.10", - "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.10.tgz", - "integrity": "sha512-9ByhssR2fPVsNZj478qUUbKfmL0+t5BDVyjShtyZZLiK7ZDAArFFfopyOTj0M05wE2tJPisA4iTnnXl2YoPvOA==", + "version": "4.2.11", + "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.11.tgz", + "integrity": "sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ==", "dev": true }, "has": { @@ -11689,23 +11120,61 @@ } }, "has-flag": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-3.0.0.tgz", - "integrity": "sha512-sKJf1+ceQBr4SMkvQnBDNDtf4TXpVhVGateu0t918bl30FnbE2m4vNLX+VWe/dpjlb+HugGYzW7uQXH98HPEYw==", + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", "dev": true }, + "html-encoding-sniffer": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/html-encoding-sniffer/-/html-encoding-sniffer-4.0.0.tgz", + "integrity": "sha512-Y22oTqIU4uuPgEemfz7NDJz6OeKf12Lsu+QC+s3BVpda64lTiMYCyGwg5ki4vFxkMwQdeZDl2adZoqUgdFuTgQ==", + "dev": true, + "requires": { + "whatwg-encoding": "^3.1.1" + } + }, "html-escaper": { "version": "2.0.2", "resolved": "https://registry.npmjs.org/html-escaper/-/html-escaper-2.0.2.tgz", "integrity": "sha512-H2iMtd0I4Mt5eYiapRdIDjp+XzelXQ0tFE4JS7YFwFevXXMmOp9myNrUvCg0D6ws8iqkRPBfKHgbwig1SmlLfg==", "dev": true }, + "http-proxy-agent": { + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/http-proxy-agent/-/http-proxy-agent-7.0.2.tgz", + "integrity": "sha512-T1gkAiYYDWYx3V5Bmyu7HcfcvL7mUrTWiM6yOfa3PIphViJ/gFPbvidQ+veqSOHci/PxBcDabeUNCzpOODJZig==", + "dev": true, + "requires": { + "agent-base": "^7.1.0", + "debug": "^4.3.4" + } + }, + "https-proxy-agent": { + "version": "7.0.6", + "resolved": "https://registry.npmjs.org/https-proxy-agent/-/https-proxy-agent-7.0.6.tgz", + "integrity": "sha512-vK9P5/iUfdl95AI+JVyUuIcVtd4ofvtrOr3HNtM2yxC9bnMbEdp3x01OhQNnjb8IJYi38VlTE3mBXwcfvywuSw==", + "dev": true, + "requires": { + "agent-base": "^7.1.2", + "debug": "4" + } + }, "human-signals": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/human-signals/-/human-signals-2.1.0.tgz", "integrity": "sha512-B4FFZ6q/T2jhhksgkbEW3HBvWIfDW85snkQgawt07S7J5QXTk6BkNV+0yAeZrM5QpMAdYlocGoljn0sJ/WQkFw==", "dev": true }, + "iconv-lite": { + "version": "0.6.3", + "resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.6.3.tgz", + "integrity": "sha512-4fCk79wshMdzMp2rH06qWrJE4iolqLhCUH+OiuIgU++RB0+94NlDL81atO7GX55uUKueo0txHNtvEyI6D7WdMw==", + "dev": true, + "requires": { + "safer-buffer": ">= 2.1.2 < 3.0.0" + } + }, "immutable": { "version": "4.2.4", "resolved": "https://registry.npmjs.org/immutable/-/immutable-4.2.4.tgz", @@ -11829,6 +11298,12 @@ "integrity": "sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==", "dev": true }, + "is-potential-custom-element-name": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/is-potential-custom-element-name/-/is-potential-custom-element-name-1.0.1.tgz", + "integrity": "sha512-bCYeRA2rVibKZd+s2625gGnGF/t7DSqDs4dP7CrLA1m7jKWz6pps0LpYLJN8Q64HtmPKJ1hrN3nzPNKFEKOUiQ==", + "dev": true + }, "is-stream": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/is-stream/-/is-stream-2.0.1.tgz", @@ -11878,23 +11353,6 @@ "istanbul-lib-coverage": "^3.0.0", "make-dir": "^3.0.0", "supports-color": "^7.1.0" - }, - "dependencies": { - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true - }, - "supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "requires": { - "has-flag": "^4.0.0" - } - } } }, "istanbul-lib-source-maps": { @@ -11973,128 +11431,26 @@ "pretty-format": "^29.4.3", "slash": "^3.0.0", "stack-utils": "^2.0.3" - }, - "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, - "chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - } - }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true - }, - "supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "requires": { - "has-flag": "^4.0.0" - } - } } }, "jest-cli": { "version": "29.4.3", - "resolved": "https://registry.npmjs.org/jest-cli/-/jest-cli-29.4.3.tgz", - "integrity": "sha512-PiiAPuFNfWWolCE6t3ZrDXQc6OsAuM3/tVW0u27UWc1KE+n/HSn5dSE6B2juqN7WP+PP0jAcnKtGmI4u8GMYCg==", - "dev": true, - "requires": { - "@jest/core": "^29.4.3", - "@jest/test-result": "^29.4.3", - "@jest/types": "^29.4.3", - "chalk": "^4.0.0", - "exit": "^0.1.2", - "graceful-fs": "^4.2.9", - "import-local": "^3.0.2", - "jest-config": "^29.4.3", - "jest-util": "^29.4.3", - "jest-validate": "^29.4.3", - "prompts": "^2.0.1", - "yargs": "^17.3.1" - }, - "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, - "chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - } - }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true - }, - "supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "requires": { - "has-flag": "^4.0.0" - } - } + "resolved": "https://registry.npmjs.org/jest-cli/-/jest-cli-29.4.3.tgz", + "integrity": "sha512-PiiAPuFNfWWolCE6t3ZrDXQc6OsAuM3/tVW0u27UWc1KE+n/HSn5dSE6B2juqN7WP+PP0jAcnKtGmI4u8GMYCg==", + "dev": true, + "requires": { + "@jest/core": "^29.4.3", + "@jest/test-result": "^29.4.3", + "@jest/types": "^29.4.3", + "chalk": "^4.0.0", + "exit": "^0.1.2", + "graceful-fs": "^4.2.9", + "import-local": "^3.0.2", + "jest-config": "^29.4.3", + "jest-util": "^29.4.3", + "jest-validate": "^29.4.3", + "prompts": "^2.0.1", + "yargs": "^17.3.1" } }, "jest-config": { @@ -12127,15 +11483,6 @@ "strip-json-comments": "^3.1.1" }, "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, "babel-jest": { "version": "29.4.3", "resolved": "https://registry.npmjs.org/babel-jest/-/babel-jest-29.4.3.tgz", @@ -12150,46 +11497,6 @@ "graceful-fs": "^4.2.9", "slash": "^3.0.0" } - }, - "chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - } - }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true - }, - "supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "requires": { - "has-flag": "^4.0.0" - } } } }, @@ -12203,57 +11510,6 @@ "diff-sequences": "^29.4.3", "jest-get-type": "^29.4.3", "pretty-format": "^29.4.3" - }, - "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, - "chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - } - }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true - }, - "supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "requires": { - "has-flag": "^4.0.0" - } - } } }, "jest-docblock": { @@ -12276,55 +11532,164 @@ "jest-get-type": "^29.4.3", "jest-util": "^29.4.3", "pretty-format": "^29.4.3" + } + }, + "jest-environment-jsdom": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-environment-jsdom/-/jest-environment-jsdom-30.2.0.tgz", + "integrity": "sha512-zbBTiqr2Vl78pKp/laGBREYzbZx9ZtqPjOK4++lL4BNDhxRnahg51HtoDrk9/VjIy9IthNEWdKVd7H5bqBhiWQ==", + "dev": true, + "requires": { + "@jest/environment": "30.2.0", + "@jest/environment-jsdom-abstract": "30.2.0", + "@types/jsdom": "^21.1.7", + "@types/node": "*", + "jsdom": "^26.1.0" }, "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "@jest/environment": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/environment/-/environment-30.2.0.tgz", + "integrity": "sha512-/QPTL7OBJQ5ac09UDRa3EQes4gt1FTEG/8jZ/4v5IVzx+Cv7dLxlVIvfvSVRiiX2drWyXeBjkMSR8hvOWSog5g==", "dev": true, "requires": { - "color-convert": "^2.0.1" + "@jest/fake-timers": "30.2.0", + "@jest/types": "30.2.0", + "@types/node": "*", + "jest-mock": "30.2.0" } }, - "chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "@jest/fake-timers": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/fake-timers/-/fake-timers-30.2.0.tgz", + "integrity": "sha512-HI3tRLjRxAbBy0VO8dqqm7Hb2mIa8d5bg/NJkyQcOk7V118ObQML8RC5luTF/Zsg4474a+gDvhce7eTnP4GhYw==", "dev": true, "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" + "@jest/types": "30.2.0", + "@sinonjs/fake-timers": "^13.0.0", + "@types/node": "*", + "jest-message-util": "30.2.0", + "jest-mock": "30.2.0", + "jest-util": "30.2.0" } }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "@jest/schemas": { + "version": "30.0.5", + "resolved": "https://registry.npmjs.org/@jest/schemas/-/schemas-30.0.5.tgz", + "integrity": "sha512-DmdYgtezMkh3cpU8/1uyXakv3tJRcmcXxBOcO0tbaozPwpmh4YMsnWrQm9ZmZMfa5ocbxzbFk6O4bDPEc/iAnA==", + "dev": true, + "requires": { + "@sinclair/typebox": "^0.34.0" + } + }, + "@jest/types": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/@jest/types/-/types-30.2.0.tgz", + "integrity": "sha512-H9xg1/sfVvyfU7o3zMfBEjQ1gcsdeTMgqHoYdN79tuLqfTtuu7WckRA1R5whDwOzxaZAeMKTYWqP+WCAi0CHsg==", "dev": true, "requires": { - "color-name": "~1.1.4" + "@jest/pattern": "30.0.1", + "@jest/schemas": "30.0.5", + "@types/istanbul-lib-coverage": "^2.0.6", + "@types/istanbul-reports": "^3.0.4", + "@types/node": "*", + "@types/yargs": "^17.0.33", + "chalk": "^4.1.2" } }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", + "@sinclair/typebox": { + "version": "0.34.47", + "resolved": "https://registry.npmjs.org/@sinclair/typebox/-/typebox-0.34.47.tgz", + "integrity": "sha512-ZGIBQ+XDvO5JQku9wmwtabcVTHJsgSWAHYtVuM9pBNNR5E88v6Jcj/llpmsjivig5X8A8HHOb4/mbEKPS5EvAw==", "dev": true }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "@sinonjs/commons": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/@sinonjs/commons/-/commons-3.0.1.tgz", + "integrity": "sha512-K3mCHKQ9sVh8o1C9cxkwxaOmXoAMlDxC1mYyHrjqOWEcBjYr76t96zL2zlj5dUGZ3HSw240X1qgH3Mjf1yJWpQ==", + "dev": true, + "requires": { + "type-detect": "4.0.8" + } + }, + "@sinonjs/fake-timers": { + "version": "13.0.5", + "resolved": "https://registry.npmjs.org/@sinonjs/fake-timers/-/fake-timers-13.0.5.tgz", + "integrity": "sha512-36/hTbH2uaWuGVERyC6da9YwGWnzUZXuPro/F2LfsdOsLnCojz/iSH8MxUt/FD2S5XBSVPhmArFUXcpCQ2Hkiw==", + "dev": true, + "requires": { + "@sinonjs/commons": "^3.0.1" + } + }, + "ansi-styles": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-5.2.0.tgz", + "integrity": "sha512-Cxwpt2SfTzTtXcfOlzGEee8O+c+MmUgGrNiBcXnuWxuFJHe6a5Hz7qwhwe5OgaSYI0IJvkLqWX1ASG+cJOkEiA==", "dev": true }, - "supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "ci-info": { + "version": "4.3.1", + "resolved": "https://registry.npmjs.org/ci-info/-/ci-info-4.3.1.tgz", + "integrity": "sha512-Wdy2Igu8OcBpI2pZePZ5oWjPC38tmDVx5WKUXKwlLYkA0ozo85sLsLvkBbBn/sZaSCMFOGZJ14fvW9t5/d7kdA==", + "dev": true + }, + "jest-message-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-message-util/-/jest-message-util-30.2.0.tgz", + "integrity": "sha512-y4DKFLZ2y6DxTWD4cDe07RglV88ZiNEdlRfGtqahfbIjfsw1nMCPx49Uev4IA/hWn3sDKyAnSPwoYSsAEdcimw==", "dev": true, "requires": { - "has-flag": "^4.0.0" + "@babel/code-frame": "^7.27.1", + "@jest/types": "30.2.0", + "@types/stack-utils": "^2.0.3", + "chalk": "^4.1.2", + "graceful-fs": "^4.2.11", + "micromatch": "^4.0.8", + "pretty-format": "30.2.0", + "slash": "^3.0.0", + "stack-utils": "^2.0.6" + } + }, + "jest-mock": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-mock/-/jest-mock-30.2.0.tgz", + "integrity": "sha512-JNNNl2rj4b5ICpmAcq+WbLH83XswjPbjH4T7yvGzfAGCPh1rw+xVNbtk+FnRslvt9lkCcdn9i1oAoKUuFsOxRw==", + "dev": true, + "requires": { + "@jest/types": "30.2.0", + "@types/node": "*", + "jest-util": "30.2.0" + } + }, + "jest-util": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-30.2.0.tgz", + "integrity": "sha512-QKNsM0o3Xe6ISQU869e+DhG+4CK/48aHYdJZGlFQVTjnbvgpcKyxpzk29fGiO7i/J8VENZ+d2iGnSsvmuHywlA==", + "dev": true, + "requires": { + "@jest/types": "30.2.0", + "@types/node": "*", + "chalk": "^4.1.2", + "ci-info": "^4.2.0", + "graceful-fs": "^4.2.11", + "picomatch": "^4.0.2" + } + }, + "picomatch": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.3.tgz", + "integrity": "sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==", + "dev": true + }, + "pretty-format": { + "version": "30.2.0", + "resolved": "https://registry.npmjs.org/pretty-format/-/pretty-format-30.2.0.tgz", + "integrity": "sha512-9uBdv/B4EefsuAL+pWqueZyZS2Ba+LxfFeQ9DN14HU4bN8bhaxKdkpjpB6fs9+pSjIBu+FXQHImEg8j/Lw0+vA==", + "dev": true, + "requires": { + "@jest/schemas": "30.0.5", + "ansi-styles": "^5.2.0", + "react-is": "^18.3.1" } } } @@ -12400,57 +11765,6 @@ "jest-diff": "^29.4.3", "jest-get-type": "^29.4.3", "pretty-format": "^29.4.3" - }, - "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, - "chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - } - }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true - }, - "supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "requires": { - "has-flag": "^4.0.0" - } - } } }, "jest-message-util": { @@ -12468,57 +11782,6 @@ "pretty-format": "^29.4.3", "slash": "^3.0.0", "stack-utils": "^2.0.3" - }, - "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, - "chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - } - }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true - }, - "supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "requires": { - "has-flag": "^4.0.0" - } - } } }, "jest-mock": { @@ -12562,46 +11825,6 @@ "slash": "^3.0.0" }, "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, - "chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - } - }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true - }, "resolve": { "version": "1.22.1", "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.22.1.tgz", @@ -12612,15 +11835,6 @@ "path-parse": "^1.0.7", "supports-preserve-symlinks-flag": "^1.0.0" } - }, - "supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "requires": { - "has-flag": "^4.0.0" - } } } }, @@ -12643,75 +11857,24 @@ "@jest/console": "^29.4.3", "@jest/environment": "^29.4.3", "@jest/test-result": "^29.4.3", - "@jest/transform": "^29.4.3", - "@jest/types": "^29.4.3", - "@types/node": "*", - "chalk": "^4.0.0", - "emittery": "^0.13.1", - "graceful-fs": "^4.2.9", - "jest-docblock": "^29.4.3", - "jest-environment-node": "^29.4.3", - "jest-haste-map": "^29.4.3", - "jest-leak-detector": "^29.4.3", - "jest-message-util": "^29.4.3", - "jest-resolve": "^29.4.3", - "jest-runtime": "^29.4.3", - "jest-util": "^29.4.3", - "jest-watcher": "^29.4.3", - "jest-worker": "^29.4.3", - "p-limit": "^3.1.0", - "source-map-support": "0.5.13" - }, - "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, - "chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - } - }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true - }, - "supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "requires": { - "has-flag": "^4.0.0" - } - } + "@jest/transform": "^29.4.3", + "@jest/types": "^29.4.3", + "@types/node": "*", + "chalk": "^4.0.0", + "emittery": "^0.13.1", + "graceful-fs": "^4.2.9", + "jest-docblock": "^29.4.3", + "jest-environment-node": "^29.4.3", + "jest-haste-map": "^29.4.3", + "jest-leak-detector": "^29.4.3", + "jest-message-util": "^29.4.3", + "jest-resolve": "^29.4.3", + "jest-runtime": "^29.4.3", + "jest-util": "^29.4.3", + "jest-watcher": "^29.4.3", + "jest-worker": "^29.4.3", + "p-limit": "^3.1.0", + "source-map-support": "0.5.13" } }, "jest-runtime": { @@ -12742,57 +11905,6 @@ "jest-util": "^29.4.3", "slash": "^3.0.0", "strip-bom": "^4.0.0" - }, - "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, - "chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - } - }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true - }, - "supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "requires": { - "has-flag": "^4.0.0" - } - } } }, "jest-snapshot": { @@ -12827,46 +11939,6 @@ "semver": "^7.3.5" }, "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, - "chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - } - }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true - }, "lru-cache": { "version": "6.0.0", "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-6.0.0.tgz", @@ -12885,15 +11957,6 @@ "lru-cache": "^6.0.0" } }, - "supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "requires": { - "has-flag": "^4.0.0" - } - }, "yallist": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz", @@ -12914,57 +11977,6 @@ "ci-info": "^3.2.0", "graceful-fs": "^4.2.9", "picomatch": "^2.2.3" - }, - "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, - "chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - } - }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true - }, - "supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "requires": { - "has-flag": "^4.0.0" - } - } } }, "jest-validate": { @@ -12981,60 +11993,11 @@ "pretty-format": "^29.4.3" }, "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, "camelcase": { "version": "6.3.0", "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-6.3.0.tgz", "integrity": "sha512-Gmy6FhYlCY7uOElZUSbxo2UCDH8owEk996gkbrpsgGtrJLM3J7jGxl9Ic7Qwwj4ivOE5AWZWRMecDdF7hqGjFA==", "dev": true - }, - "chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - } - }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true - }, - "supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "requires": { - "has-flag": "^4.0.0" - } } } }, @@ -13052,57 +12015,6 @@ "emittery": "^0.13.1", "jest-util": "^29.4.3", "string-length": "^4.0.1" - }, - "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, - "chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - } - }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true - }, - "supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "requires": { - "has-flag": "^4.0.0" - } - } } }, "jest-worker": { @@ -13117,12 +12029,6 @@ "supports-color": "^8.0.0" }, "dependencies": { - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true - }, "supports-color": { "version": "8.1.1", "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-8.1.1.tgz", @@ -13150,6 +12056,34 @@ "esprima": "^4.0.0" } }, + "jsdom": { + "version": "26.1.0", + "resolved": "https://registry.npmjs.org/jsdom/-/jsdom-26.1.0.tgz", + "integrity": "sha512-Cvc9WUhxSMEo4McES3P7oK3QaXldCfNWp7pl2NNeiIFlCoLr3kfq9kb1fxftiwk1FLV7CvpvDfonxtzUDeSOPg==", + "dev": true, + "requires": { + "cssstyle": "^4.2.1", + "data-urls": "^5.0.0", + "decimal.js": "^10.5.0", + "html-encoding-sniffer": "^4.0.0", + "http-proxy-agent": "^7.0.2", + "https-proxy-agent": "^7.0.6", + "is-potential-custom-element-name": "^1.0.1", + "nwsapi": "^2.2.16", + "parse5": "^7.2.1", + "rrweb-cssom": "^0.8.0", + "saxes": "^6.0.0", + "symbol-tree": "^3.2.4", + "tough-cookie": "^5.1.1", + "w3c-xmlserializer": "^5.0.0", + "webidl-conversions": "^7.0.0", + "whatwg-encoding": "^3.1.1", + "whatwg-mimetype": "^4.0.0", + "whatwg-url": "^14.1.1", + "ws": "^8.18.0", + "xml-name-validator": "^5.0.0" + } + }, "jsep": { "version": "1.3.9", "resolved": "https://registry.npmjs.org/jsep/-/jsep-1.3.9.tgz", @@ -13454,6 +12388,12 @@ "path-key": "^3.0.0" } }, + "nwsapi": { + "version": "2.2.23", + "resolved": "https://registry.npmjs.org/nwsapi/-/nwsapi-2.2.23.tgz", + "integrity": "sha512-7wfH4sLbt4M0gCDzGE6vzQBo0bfTKjU7Sfpqy/7gs1qBfYz2vEJH6vXcBKpO3+6Yu1telwd0t9HpyOoLEQQbIQ==", + "dev": true + }, "once": { "version": "1.4.0", "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", @@ -13544,6 +12484,15 @@ "lines-and-columns": "^1.1.6" } }, + "parse5": { + "version": "7.3.0", + "resolved": "https://registry.npmjs.org/parse5/-/parse5-7.3.0.tgz", + "integrity": "sha512-IInvU7fabl34qmi9gY8XOVxhYyMyuH2xUNpb2q8/Y+7552KlejkRvqvD19nMoUW/uQGGbqNpA6Tufu5FL5BZgw==", + "dev": true, + "requires": { + "entities": "^6.0.0" + } + }, "path-exists": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-4.0.0.tgz", @@ -13569,9 +12518,9 @@ "dev": true }, "picocolors": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.0.0.tgz", - "integrity": "sha512-1fygroTLlHu66zi26VoTDv8yRgm0Fccecssto+MhsZ0D/DGW2sm8E8AjW7NU5VVTRt5GxbeZ5qBuJr+HyLYkjQ==", + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.1.1.tgz", + "integrity": "sha512-xceH2snhtb5M9liqDsmEw56le376mTZkEX/jEb/RxNFyegNul7eNslCXP9FDj/Lcu0X8KEyMceP2ntpaHrDEVA==", "dev": true }, "picomatch": { @@ -13639,6 +12588,12 @@ "once": "^1.3.1" } }, + "punycode": { + "version": "2.3.1", + "resolved": "https://registry.npmjs.org/punycode/-/punycode-2.3.1.tgz", + "integrity": "sha512-vYt7UD1U9Wg6138shLtLOvdAu+8DsC/ilFtEVHcH+wydcSpNE20AfSOduf6MkRFahL5FY7X1oU7nKVZFtfq8Fg==", + "dev": true + }, "queue-microtask": { "version": "1.2.3", "resolved": "https://registry.npmjs.org/queue-microtask/-/queue-microtask-1.2.3.tgz", @@ -13646,9 +12601,9 @@ "dev": true }, "react-is": { - "version": "18.2.0", - "resolved": "https://registry.npmjs.org/react-is/-/react-is-18.2.0.tgz", - "integrity": "sha512-xWGDIW6x921xtzPkhiULtthJHoJvBbF3q26fzloPCK0hsvxtPVelvftw3zjbHWSkR2km9Z+4uxbDDK/6Zw9B8w==", + "version": "18.3.1", + "resolved": "https://registry.npmjs.org/react-is/-/react-is-18.3.1.tgz", + "integrity": "sha512-/LLMVyas0ljjAtoYiPqYiL8VWXzUUdThrmU5+n20DZv+a+ClRoevUzw5JxU+Ieh5/c87ytoTBV9G1FiKfNJdmg==", "dev": true }, "readdirp": { @@ -13783,6 +12738,12 @@ "integrity": "sha512-g6QUff04oZpHs0eG5p83rFLhHeV00ug/Yf9nZM6fLeUrPguBTkTQOdpAWWspMh55TZfVQDPaN3NQJfbVRAxdIw==", "dev": true }, + "rrweb-cssom": { + "version": "0.8.0", + "resolved": "https://registry.npmjs.org/rrweb-cssom/-/rrweb-cssom-0.8.0.tgz", + "integrity": "sha512-guoltQEx+9aMf2gDZ0s62EcV8lsXR+0w8915TC3ITdn2YueuNjdAYh/levpU9nFaoChh9RUS5ZdQMrKfVEN9tw==", + "dev": true + }, "run-parallel": { "version": "1.2.0", "resolved": "https://registry.npmjs.org/run-parallel/-/run-parallel-1.2.0.tgz", @@ -13800,6 +12761,12 @@ "tslib": "^2.1.0" } }, + "safer-buffer": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz", + "integrity": "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==", + "dev": true + }, "sass": { "version": "1.57.1", "resolved": "https://registry.npmjs.org/sass/-/sass-1.57.1.tgz", @@ -13816,6 +12783,15 @@ "resolved": "https://registry.npmjs.org/sax/-/sax-1.4.3.tgz", "integrity": "sha512-yqYn1JhPczigF94DMS+shiDMjDowYO6y9+wB/4WgO0Y19jWYk0lQ4tuG5KI7kj4FTp1wxPj5IFfcrz/s1c3jjQ==" }, + "saxes": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/saxes/-/saxes-6.0.0.tgz", + "integrity": "sha512-xAg7SOnEhrm5zI3puOOKyy1OMcMlIJZYNJY7xLBwSze0UjhPLnWfj2GF2EpT0jmzaJKIWKHLsaSSajf35bcYnA==", + "dev": true, + "requires": { + "xmlchars": "^2.2.0" + } + }, "semver": { "version": "6.3.0", "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.0.tgz", @@ -14135,12 +13111,12 @@ "dev": true }, "supports-color": { - "version": "5.5.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.5.0.tgz", - "integrity": "sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==", + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", "dev": true, "requires": { - "has-flag": "^3.0.0" + "has-flag": "^4.0.0" } }, "supports-preserve-symlinks-flag": { @@ -14149,6 +13125,12 @@ "integrity": "sha512-ot0WnXS9fgdkgIcePe6RHNk1WA8+muPa6cSjeR3V8K27q9BB1rTE3R1p7Hv0z1ZyAc8s6Vvv8DIyWf681MAt0w==", "dev": true }, + "symbol-tree": { + "version": "3.2.4", + "resolved": "https://registry.npmjs.org/symbol-tree/-/symbol-tree-3.2.4.tgz", + "integrity": "sha512-9QNk5KwDF+Bvz+PyObkmSYjI5ksVUYtjW7AU22r2NKcfLJcXp96hkDWU3+XndOsUb+AQ9QhfzfCT2O+CNWT5Tw==", + "dev": true + }, "test-exclude": { "version": "6.0.0", "resolved": "https://registry.npmjs.org/test-exclude/-/test-exclude-6.0.0.tgz", @@ -14165,6 +13147,21 @@ "resolved": "https://registry.npmjs.org/three/-/three-0.182.0.tgz", "integrity": "sha512-GbHabT+Irv+ihI1/f5kIIsZ+Ef9Sl5A1Y7imvS5RQjWgtTPfPnZ43JmlYI7NtCRDK9zir20lQpfg8/9Yd02OvQ==" }, + "tldts": { + "version": "6.1.86", + "resolved": "https://registry.npmjs.org/tldts/-/tldts-6.1.86.tgz", + "integrity": "sha512-WMi/OQ2axVTf/ykqCQgXiIct+mSQDFdH2fkwhPwgEwvJ1kSzZRiinb0zF2Xb8u4+OqPChmyI6MEu4EezNJz+FQ==", + "dev": true, + "requires": { + "tldts-core": "^6.1.86" + } + }, + "tldts-core": { + "version": "6.1.86", + "resolved": "https://registry.npmjs.org/tldts-core/-/tldts-core-6.1.86.tgz", + "integrity": "sha512-Je6p7pkk+KMzMv2XXKmAE3McmolOQFdxkKw0R8EYNr7sELW46JqnNeTX8ybPiQgvg1ymCoF8LXs5fzFaZvJPTA==", + "dev": true + }, "tmpl": { "version": "1.0.5", "resolved": "https://registry.npmjs.org/tmpl/-/tmpl-1.0.5.tgz", @@ -14186,6 +13183,24 @@ "is-number": "^7.0.0" } }, + "tough-cookie": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/tough-cookie/-/tough-cookie-5.1.2.tgz", + "integrity": "sha512-FVDYdxtnj0G6Qm/DhNPSb8Ju59ULcup3tuJxkFb5K8Bv2pUXILbf0xZWU8PX8Ov19OXljbUyveOFwRMwkXzO+A==", + "dev": true, + "requires": { + "tldts": "^6.1.32" + } + }, + "tr46": { + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/tr46/-/tr46-5.1.1.tgz", + "integrity": "sha512-hdF5ZgjTqgAntKkklYw0R03MG2x/bSzTtkxmIRw/sTNV8YXsCJ1tfLAX23lhxhHJlEf3CRCOCGGWw3vI3GaSPw==", + "dev": true, + "requires": { + "punycode": "^2.3.1" + } + }, "ts-jest": { "version": "29.0.0", "resolved": "https://registry.npmjs.org/ts-jest/-/ts-jest-29.0.0.tgz", @@ -14354,6 +13369,15 @@ "webworker-threads": "^0.7.12" } }, + "w3c-xmlserializer": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/w3c-xmlserializer/-/w3c-xmlserializer-5.0.0.tgz", + "integrity": "sha512-o8qghlI8NZHU1lLPrpi2+Uq7abh4GGPpYANlalzWxyWteJOCsr/P+oPBA49TOLu5FTZO4d3F9MnWJfiMo4BkmA==", + "dev": true, + "requires": { + "xml-name-validator": "^5.0.0" + } + }, "walker": { "version": "1.0.8", "resolved": "https://registry.npmjs.org/walker/-/walker-1.0.8.tgz", @@ -14363,6 +13387,12 @@ "makeerror": "1.0.12" } }, + "webidl-conversions": { + "version": "7.0.0", + "resolved": "https://registry.npmjs.org/webidl-conversions/-/webidl-conversions-7.0.0.tgz", + "integrity": "sha512-VwddBukDzu71offAQR975unBIGqfKZpM+8ZX6ySk8nYhVoo5CYaZyzt3YBvYtRtO+aoGlqxPg/B87NGVZ/fu6g==", + "dev": true + }, "webworker-threads": { "version": "0.7.17", "resolved": "https://registry.npmjs.org/webworker-threads/-/webworker-threads-0.7.17.tgz", @@ -14373,6 +13403,31 @@ "nan": "^2.11.0" } }, + "whatwg-encoding": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/whatwg-encoding/-/whatwg-encoding-3.1.1.tgz", + "integrity": "sha512-6qN4hJdMwfYBtE3YBTTHhoeuUrDBPZmbQaxWAqSALV/MeEnR5z1xd8UKud2RAkFoPkmB+hli1TZSnyi84xz1vQ==", + "dev": true, + "requires": { + "iconv-lite": "0.6.3" + } + }, + "whatwg-mimetype": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/whatwg-mimetype/-/whatwg-mimetype-4.0.0.tgz", + "integrity": "sha512-QaKxh0eNIi2mE9p2vEdzfagOKHCcj1pJ56EEHGQOVxp8r9/iszLUUV7v89x9O1p/T+NlTM5W7jW6+cz4Fq1YVg==", + "dev": true + }, + "whatwg-url": { + "version": "14.2.0", + "resolved": "https://registry.npmjs.org/whatwg-url/-/whatwg-url-14.2.0.tgz", + "integrity": "sha512-De72GdQZzNTUBBChsXueQUnPKDkg/5A5zp7pFDuQAj5UFoENpiACU0wlCvzpAGnTkj++ihpKwKyYewn/XNUbKw==", + "dev": true, + "requires": { + "tr46": "^5.1.0", + "webidl-conversions": "^7.0.0" + } + }, "which": { "version": "2.0.2", "resolved": "https://registry.npmjs.org/which/-/which-2.0.2.tgz", @@ -14391,32 +13446,6 @@ "ansi-styles": "^4.0.0", "string-width": "^4.1.0", "strip-ansi": "^6.0.0" - }, - "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - } } }, "wrappy": { @@ -14435,6 +13464,25 @@ "signal-exit": "^3.0.7" } }, + "ws": { + "version": "8.19.0", + "resolved": "https://registry.npmjs.org/ws/-/ws-8.19.0.tgz", + "integrity": "sha512-blAT2mjOEIi0ZzruJfIhb3nps74PRWTCz1IjglWEEpQl5XS/UNama6u2/rjFkDDouqr4L67ry+1aGIALViWjDg==", + "dev": true, + "requires": {} + }, + "xml-name-validator": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/xml-name-validator/-/xml-name-validator-5.0.0.tgz", + "integrity": "sha512-EvGK8EJ3DhaHfbRlETOWAS5pO9MZITeauHKJyb8wyajUfQUenkIg2MvLDTZ4T/TgIcm3HU0TFBgWWboAZ30UHg==", + "dev": true + }, + "xmlchars": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/xmlchars/-/xmlchars-2.2.0.tgz", + "integrity": "sha512-JZnDKK8B0RCDw84FNdDAIpZK+JuJw+s7Lz8nksI7SIuU3UXJJslUthsi+uWBUYOwPFwW7W7PRLRfUKpxjtjFCw==", + "dev": true + }, "y18n": { "version": "5.0.8", "resolved": "https://registry.npmjs.org/y18n/-/y18n-5.0.8.tgz", diff --git a/packages/dev/threejs/package.json b/packages/dev/threejs/package.json index fc89e109..c124db4b 100644 --- a/packages/dev/threejs/package.json +++ b/packages/dev/threejs/package.json @@ -54,25 +54,26 @@ "types": "./index.d.ts", "type": "module", "dependencies": { - "three": "0.182.0", - "@bitbybit-dev/core": "0.21.0" + "@bitbybit-dev/core": "0.21.0", + "three": "0.182.0" }, "devDependencies": { - "shx":"0.4.0", - "sass": "1.57.1", + "@babel/core": "7.16.0", + "@babel/preset-env": "7.16.0", + "@babel/preset-typescript": "7.16.0", "@testing-library/jest-dom": "5.14.1", - "mvdir": "1.0.21", - "jest": "29.4.1", - "ts-node": "10.9.1", - "ts-jest": "29.0.0", - "typescript": "4.8.2", "@types/jest": "29.0.0", "@types/three": "0.182.0", "babel-jest": "29.0.0", - "@babel/core": "7.16.0", - "@babel/preset-env": "7.16.0", - "@babel/preset-typescript": "7.16.0", - "jest-html-reporters": "3.0.11" + "jest": "29.4.1", + "jest-environment-jsdom": "^30.2.0", + "jest-html-reporters": "3.0.11", + "mvdir": "1.0.21", + "sass": "1.57.1", + "shx": "0.4.0", + "ts-jest": "29.0.0", + "ts-node": "10.9.1", + "typescript": "4.8.2" }, "jest": { "preset": "ts-jest", From 1b68849ba3c64842ea6d285d12766ef2cfdc03f1 Mon Sep 17 00:00:00 2001 From: Matas Ubarevicius Date: Tue, 13 Jan 2026 08:24:40 +0200 Subject: [PATCH 11/31] refactored unit tests, moved mocks to common mocks folder --- .../lib/api/__mocks__/babylonjs.mock.ts | 156 ++++++++++++ .../api/bitbybit/babylon/scene-helper.test.ts | 181 +------------ .../lib/api/__mocks__/playcanvas.mock.ts | 122 +++++++++ .../bitbybit/playcanvas/scene-helper.test.ts | 136 +--------- .../threejs/lib/api/__mocks__/threejs.mock.ts | 240 ++++++++++++++++++ .../api/bitbybit/threejs/scene-helper.test.ts | 219 +--------------- 6 files changed, 535 insertions(+), 519 deletions(-) create mode 100644 packages/dev/threejs/lib/api/__mocks__/threejs.mock.ts diff --git a/packages/dev/babylonjs/lib/api/__mocks__/babylonjs.mock.ts b/packages/dev/babylonjs/lib/api/__mocks__/babylonjs.mock.ts index e27c16f7..99d36bf7 100644 --- a/packages/dev/babylonjs/lib/api/__mocks__/babylonjs.mock.ts +++ b/packages/dev/babylonjs/lib/api/__mocks__/babylonjs.mock.ts @@ -525,3 +525,159 @@ export function createBabylonJSMock() { } }; } + +// Scene helper specific mock classes +export class MockEngine { + _canvas: HTMLCanvasElement; + _renderLoop: (() => void) | null = null; + + constructor(canvas: HTMLCanvasElement, _antialias?: boolean, _options?: object) { + this._canvas = canvas; + } + + setHardwareScalingLevel(_level: number) { /* mock */ } + resize() { /* mock */ } + + runRenderLoop(callback: () => void) { + this._renderLoop = callback; + } + + stopRenderLoop() { + this._renderLoop = null; + } + + dispose() { /* mock */ } +} + +export class MockBabylonScene { + _meshes: MockMesh[] = []; + metadata: { shadowGenerators: MockShadowGenerator[] } = { shadowGenerators: [] }; + clearColor: MockColor4 | null = null; + activeCamera: MockArcRotateCamera | null = null; + + dispose() { /* mock */ } + render() { /* mock */ } +} + +export class MockHemisphericLight { + name: string; + direction: MockVector3; + diffuse: MockColor3; + groundColor: MockColor3; + intensity = 1; + + constructor(name: string, direction: MockVector3, _scene: MockBabylonScene) { + this.name = name; + this.direction = direction; + this.diffuse = new MockColor3(1, 1, 1); + this.groundColor = new MockColor3(0.5, 0.5, 0.5); + } + + dispose() { /* mock */ } +} + +export class MockDirectionalLight { + name: string; + direction: MockVector3; + position: MockVector3; + diffuse: MockColor3; + intensity = 1; + + constructor(name: string, direction: MockVector3, _scene: MockBabylonScene) { + this.name = name; + this.direction = direction; + this.position = new MockVector3(); + this.diffuse = new MockColor3(1, 1, 1); + } + + dispose() { /* mock */ } +} + +export class MockShadowGenerator { + useBlurExponentialShadowMap = false; + blurKernel = 0; + darkness = 0; + + constructor(_mapSize: number, _light: MockDirectionalLight) { /* mock */ } +} + +export class MockArcRotateCamera { + name: string; + alpha: number; + beta: number; + radius: number; + target: MockVector3; + angularSensibilityX = 1000; + angularSensibilityY = 1000; + lowerRadiusLimit: number | null = null; + upperRadiusLimit: number | null = null; + panningSensibility = 1000; + wheelPrecision = 3; + maxZ = 10000; + minZ = 0.1; + lowerBetaLimit: number | null = null; + upperBetaLimit: number | null = null; + lowerAlphaLimit: number | null = null; + upperAlphaLimit: number | null = null; + + constructor( + name: string, + alpha: number, + beta: number, + radius: number, + target: MockVector3, + scene: MockBabylonScene + ) { + this.name = name; + this.alpha = alpha; + this.beta = beta; + this.radius = radius; + this.target = target; + scene.activeCamera = this; + } + + attachControl(_canvas: HTMLCanvasElement, _noPreventDefault?: boolean) { /* mock */ } + dispose() { /* mock */ } +} + +export const MockTools = { + ToRadians: (degrees: number) => degrees * (Math.PI / 180) +}; + +// Type definitions for test assertions +export interface MockMeshType { + name: string; + position: MockVector3; + receiveShadows: boolean; + material: object | null; + _groundWidth?: number; + _groundHeight?: number; +} + +/** + * Create scene helper mock for jest.mock("@babylonjs/core") + */ +export function createSceneHelperMock() { + return { + Engine: MockEngine, + Scene: MockBabylonScene, + Vector3: MockVector3, + Color3: MockColor3, + Color4: MockColor4, + HemisphericLight: MockHemisphericLight, + DirectionalLight: MockDirectionalLight, + ShadowGenerator: MockShadowGenerator, + ArcRotateCamera: MockArcRotateCamera, + MeshBuilder: { + CreateGround: (name: string, options: { width: number; height: number }, _scene: MockBabylonScene) => { + const mesh = new MockMesh(name, null) as unknown as MockMeshType; + mesh._groundWidth = options.width; + mesh._groundHeight = options.height; + mesh.receiveShadows = false; + return mesh; + } + }, + StandardMaterial: MockStandardMaterial, + Tools: MockTools, + }; +} diff --git a/packages/dev/babylonjs/lib/api/bitbybit/babylon/scene-helper.test.ts b/packages/dev/babylonjs/lib/api/bitbybit/babylon/scene-helper.test.ts index 488c08a9..495ac04a 100644 --- a/packages/dev/babylonjs/lib/api/bitbybit/babylon/scene-helper.test.ts +++ b/packages/dev/babylonjs/lib/api/bitbybit/babylon/scene-helper.test.ts @@ -1,188 +1,15 @@ /** * @jest-environment jsdom */ -/* eslint-disable @typescript-eslint/no-unused-vars */ -/* eslint-disable @typescript-eslint/no-empty-function */ import { initBabylonJS } from "./scene-helper"; import { BabylonJSScene } from "../../inputs/babylon-scene-helper-inputs"; import { BabylonCamera } from "../../inputs/babylon-camera-inputs"; +import { MockMeshType } from "../../__mocks__/babylonjs.mock"; -// Type definitions for mock objects -interface MockVector3Type { - x: number; - y: number; - z: number; - set(x: number, y: number, z: number): void; -} - -interface MockColor3Type { - r: number; - g: number; - b: number; -} - -interface MockColor4Type { - r: number; - g: number; - b: number; - a: number; -} - -interface MockMeshType { - name: string; - position: MockVector3Type; - receiveShadows: boolean; - material: object | null; - _groundWidth?: number; - _groundHeight?: number; -} - -// Mock BabylonJS core module +// Mock BabylonJS core module using centralized mocks jest.mock("@babylonjs/core", () => { - const actualMock = jest.requireActual("../../__mocks__/babylonjs.mock"); - - class MockEngine { - _canvas: HTMLCanvasElement; - _renderLoop: (() => void) | null = null; - - constructor(canvas: HTMLCanvasElement, _antialias?: boolean, _options?: object) { - this._canvas = canvas; - } - - setHardwareScalingLevel(_level: number) { /* mock */ } - - resize() { /* mock */ } - - runRenderLoop(callback: () => void) { - this._renderLoop = callback; - } - - stopRenderLoop() { - this._renderLoop = null; - } - - dispose() { /* mock */ } - } - - class MockBabylonScene { - _meshes: MockMeshType[] = []; - metadata: { shadowGenerators: MockShadowGenerator[] } = { shadowGenerators: [] }; - clearColor: MockColor4Type | null = null; - activeCamera: MockArcRotateCamera | null = null; - - dispose() { /* mock */ } - render() { /* mock */ } - } - - class MockHemisphericLight { - name: string; - direction: MockVector3Type; - diffuse: MockColor3Type; - groundColor: MockColor3Type; - intensity = 1; - - constructor(name: string, direction: MockVector3Type, _scene: MockBabylonScene) { - this.name = name; - this.direction = direction; - this.diffuse = new actualMock.MockColor3(1, 1, 1); - this.groundColor = new actualMock.MockColor3(0.5, 0.5, 0.5); - } - - dispose() { /* mock */ } - } - - class MockDirectionalLight { - name: string; - direction: MockVector3Type; - position: MockVector3Type; - diffuse: MockColor3Type; - intensity = 1; - - constructor(name: string, direction: MockVector3Type, _scene: MockBabylonScene) { - this.name = name; - this.direction = direction; - this.position = new actualMock.MockVector3(); - this.diffuse = new actualMock.MockColor3(1, 1, 1); - } - - dispose() { /* mock */ } - } - - class MockShadowGenerator { - useBlurExponentialShadowMap = false; - blurKernel = 0; - darkness = 0; - - constructor(_mapSize: number, _light: MockDirectionalLight) { /* mock */ } - } - - class MockArcRotateCamera { - name: string; - alpha: number; - beta: number; - radius: number; - target: MockVector3Type; - angularSensibilityX = 1000; - angularSensibilityY = 1000; - lowerRadiusLimit: number | null = null; - upperRadiusLimit: number | null = null; - panningSensibility = 1000; - wheelPrecision = 3; - maxZ = 10000; - minZ = 0.1; - lowerBetaLimit: number | null = null; - upperBetaLimit: number | null = null; - lowerAlphaLimit: number | null = null; - upperAlphaLimit: number | null = null; - - constructor( - name: string, - alpha: number, - beta: number, - radius: number, - target: MockVector3Type, - scene: MockBabylonScene - ) { - this.name = name; - this.alpha = alpha; - this.beta = beta; - this.radius = radius; - this.target = target; - scene.activeCamera = this; - } - - attachControl(_canvas: HTMLCanvasElement, _noPreventDefault?: boolean) { /* mock */ } - dispose() { /* mock */ } - } - - const MockMeshBuilder = { - CreateGround: (name: string, options: { width: number; height: number }, _scene: MockBabylonScene) => { - const mesh = new actualMock.MockMesh(name, null) as MockMeshType; - mesh._groundWidth = options.width; - mesh._groundHeight = options.height; - mesh.receiveShadows = false; - return mesh; - } - }; - - const MockTools = { - ToRadians: (degrees: number) => degrees * (Math.PI / 180) - }; - - return { - Engine: MockEngine, - Scene: MockBabylonScene, - Vector3: actualMock.MockVector3, - Color3: actualMock.MockColor3, - Color4: actualMock.MockColor4, - HemisphericLight: MockHemisphericLight, - DirectionalLight: MockDirectionalLight, - ShadowGenerator: MockShadowGenerator, - ArcRotateCamera: MockArcRotateCamera, - MeshBuilder: MockMeshBuilder, - StandardMaterial: actualMock.MockStandardMaterial, - Tools: MockTools, - }; + const { createSceneHelperMock } = jest.requireActual("../../__mocks__/babylonjs.mock"); + return createSceneHelperMock(); }); describe("initBabylonJS unit tests", () => { diff --git a/packages/dev/playcanvas/lib/api/__mocks__/playcanvas.mock.ts b/packages/dev/playcanvas/lib/api/__mocks__/playcanvas.mock.ts index 5735f804..a9a1e196 100644 --- a/packages/dev/playcanvas/lib/api/__mocks__/playcanvas.mock.ts +++ b/packages/dev/playcanvas/lib/api/__mocks__/playcanvas.mock.ts @@ -290,6 +290,128 @@ export class MockApp { } } +// Scene helper specific mock classes +export class MockGraphicsDevice { + maxPixelRatio = 1; + vram = { vb: 0, ib: 0, tex: 0, total: 0 }; + createVertexBufferImpl = jest.fn(() => ({})); + createIndexBufferImpl = jest.fn(() => ({})); +} + +export class MockLightComponent { + intensity = 1; + castShadows = false; + shadowResolution = 1024; +} + +export class MockApplication { + root: MockEntity; + mouse = new MockMouse(); + touch = new MockTouch(); + graphicsDevice = new MockGraphicsDevice(); + scene = { + ambientLight: new MockColor(0.1, 0.1, 0.1), + }; + _canvas: HTMLCanvasElement | null = null; + _started = false; + _updateCallbacks: ((dt: number) => void)[] = []; + + constructor(canvas: HTMLCanvasElement, _options?: object) { + this.root = new MockEntity("root"); + this._canvas = canvas; + } + + setCanvasFillMode(_mode: number) { /* mock */ } + setCanvasResolution(_mode: number) { /* mock */ } + resizeCanvas() { /* mock */ } + start() { this._started = true; } + destroy() { this._started = false; } + on(event: string, callback: (dt: number) => void) { + if (event === "update") { + this._updateCallbacks.push(callback); + } + } + off(event: string, callback: (dt: number) => void) { + if (event === "update") { + const idx = this._updateCallbacks.indexOf(callback); + if (idx > -1) { + this._updateCallbacks.splice(idx, 1); + } + } + } +} + +export class MockStandardMaterial { + diffuse: MockColor; + opacity = 1; + blendType = 0; + + constructor() { + this.diffuse = new MockColor(1, 1, 1); + } + + update() { /* mock */ } + destroy() { /* mock */ } +} + +export class MockTouchDevice { + on = jest.fn(); + off = jest.fn(); +} + +// Type definitions for test assertions +export interface MockEntityType { + name: string; + children: MockEntityType[]; + addChild(entity: MockEntityType): void; + destroy(): void; + light?: MockLightComponent; +} + +export interface MockAppType { + _canvas: HTMLCanvasElement | null; + _started: boolean; + _updateCallbacks: ((dt: number) => void)[]; +} + +/** + * Create scene helper mock for jest.mock("playcanvas") + */ +export function createSceneHelperMock() { + return { + Application: MockApplication, + Entity: MockEntity, + Vec2: MockVec2, + Vec3: MockVec3, + Quat: MockQuat, + Color: MockColor, + BoundingBox: MockBoundingBox, + StandardMaterial: MockStandardMaterial, + Mouse: MockMouse, + TouchDevice: MockTouchDevice, + FILLMODE_FILL_WINDOW: 0, + RESOLUTION_AUTO: 0, + BLEND_NORMAL: 1, + MOUSEBUTTON_LEFT: 0, + MOUSEBUTTON_MIDDLE: 1, + MOUSEBUTTON_RIGHT: 2, + EVENT_MOUSEDOWN: "mousedown", + EVENT_MOUSEUP: "mouseup", + EVENT_MOUSEMOVE: "mousemove", + EVENT_MOUSEWHEEL: "mousewheel", + EVENT_TOUCHSTART: "touchstart", + EVENT_TOUCHEND: "touchend", + EVENT_TOUCHMOVE: "touchmove", + EVENT_TOUCHCANCEL: "touchcancel", + math: { + lerp: (a: number, b: number, t: number) => a + (b - a) * t, + clamp: (value: number, min: number, max: number) => Math.min(Math.max(value, min), max), + RAD_TO_DEG: 180 / Math.PI, + DEG_TO_RAD: Math.PI / 180, + }, + }; +} + /** * Creates a mock node with scene for mesh instances */ diff --git a/packages/dev/playcanvas/lib/api/bitbybit/playcanvas/scene-helper.test.ts b/packages/dev/playcanvas/lib/api/bitbybit/playcanvas/scene-helper.test.ts index 506d58cd..5a78bef0 100644 --- a/packages/dev/playcanvas/lib/api/bitbybit/playcanvas/scene-helper.test.ts +++ b/packages/dev/playcanvas/lib/api/bitbybit/playcanvas/scene-helper.test.ts @@ -1,143 +1,15 @@ /** * @jest-environment jsdom */ -/* eslint-disable @typescript-eslint/no-unused-vars */ -/* eslint-disable @typescript-eslint/no-empty-function */ import { initPlayCanvas } from "./scene-helper"; import { PlayCanvasScene } from "../../inputs/playcanvas-scene-helper-inputs"; import { PlayCanvasCamera } from "../../inputs/playcanvas-camera-inputs"; +import { MockEntityType, MockAppType } from "../../__mocks__/playcanvas.mock"; -// Type definitions for mock objects -interface MockEntityType { - name: string; - children: MockEntityType[]; - addChild(entity: MockEntityType): void; - destroy(): void; - light?: MockLightComponentType; -} - -interface MockColorType { - r: number; - g: number; - b: number; -} - -interface MockAppType { - _canvas: HTMLCanvasElement | null; - _started: boolean; - _updateCallbacks: ((dt: number) => void)[]; -} - -interface MockLightComponentType { - intensity: number; - castShadows: boolean; - shadowResolution: number; -} - -// Mock PlayCanvas module +// Mock PlayCanvas module using centralized mocks jest.mock("playcanvas", () => { - const actualMock = jest.requireActual("../../__mocks__/playcanvas.mock"); - - class MockGraphicsDevice { - maxPixelRatio = 1; - vram = { vb: 0, ib: 0, tex: 0, total: 0 }; - createVertexBufferImpl = jest.fn(() => ({})); - createIndexBufferImpl = jest.fn(() => ({})); - } - - class MockApplication { - root: MockEntityType; - mouse = new actualMock.MockMouse(); - touch = new actualMock.MockTouch(); - graphicsDevice = new MockGraphicsDevice(); - scene = { - ambientLight: new actualMock.MockColor(0.1, 0.1, 0.1), - }; - _canvas: HTMLCanvasElement | null = null; - _started = false; - _updateCallbacks: ((dt: number) => void)[] = []; - - constructor(canvas: HTMLCanvasElement, _options?: object) { - this.root = new actualMock.MockEntity("root"); - this._canvas = canvas; - } - - setCanvasFillMode(_mode: number) { /* mock */ } - setCanvasResolution(_mode: number) { /* mock */ } - resizeCanvas() { /* mock */ } - start() { this._started = true; } - destroy() { this._started = false; } - on(event: string, callback: (dt: number) => void) { - if (event === "update") { - this._updateCallbacks.push(callback); - } - } - off(event: string, callback: (dt: number) => void) { - if (event === "update") { - const idx = this._updateCallbacks.indexOf(callback); - if (idx > -1) { - this._updateCallbacks.splice(idx, 1); - } - } - } - } - - class MockStandardMaterial { - diffuse: MockColorType; - opacity = 1; - blendType = 0; - - constructor() { - this.diffuse = new actualMock.MockColor(1, 1, 1); - } - - update() { /* mock */ } - destroy() { /* mock */ } - } - - class MockMouse { - on = jest.fn(); - off = jest.fn(); - disableContextMenu = jest.fn(); - } - - class MockTouchDevice { - on = jest.fn(); - off = jest.fn(); - } - - return { - Application: MockApplication, - Entity: actualMock.MockEntity, - Vec2: actualMock.MockVec2, - Vec3: actualMock.MockVec3, - Quat: actualMock.MockQuat, - Color: actualMock.MockColor, - BoundingBox: actualMock.MockBoundingBox, - StandardMaterial: MockStandardMaterial, - Mouse: MockMouse, - TouchDevice: MockTouchDevice, - FILLMODE_FILL_WINDOW: 0, - RESOLUTION_AUTO: 0, - BLEND_NORMAL: 1, - MOUSEBUTTON_LEFT: 0, - MOUSEBUTTON_MIDDLE: 1, - MOUSEBUTTON_RIGHT: 2, - EVENT_MOUSEDOWN: "mousedown", - EVENT_MOUSEUP: "mouseup", - EVENT_MOUSEMOVE: "mousemove", - EVENT_MOUSEWHEEL: "mousewheel", - EVENT_TOUCHSTART: "touchstart", - EVENT_TOUCHEND: "touchend", - EVENT_TOUCHMOVE: "touchmove", - EVENT_TOUCHCANCEL: "touchcancel", - math: { - lerp: (a: number, b: number, t: number) => a + (b - a) * t, - clamp: (value: number, min: number, max: number) => Math.min(Math.max(value, min), max), - RAD_TO_DEG: 180 / Math.PI, - DEG_TO_RAD: Math.PI / 180, - }, - }; + const { createSceneHelperMock } = jest.requireActual("../../__mocks__/playcanvas.mock"); + return createSceneHelperMock(); }); describe("initPlayCanvas unit tests", () => { diff --git a/packages/dev/threejs/lib/api/__mocks__/threejs.mock.ts b/packages/dev/threejs/lib/api/__mocks__/threejs.mock.ts new file mode 100644 index 00000000..3f198ac3 --- /dev/null +++ b/packages/dev/threejs/lib/api/__mocks__/threejs.mock.ts @@ -0,0 +1,240 @@ +/* eslint-disable @typescript-eslint/no-unused-vars */ +/* eslint-disable @typescript-eslint/no-empty-function */ + +/** + * Centralized Three.js mocks for testing + * This file contains all reusable mock classes for Three.js types + */ + +// Helper function to parse hex color +function hexToRgb(hex: string): { r: number; g: number; b: number } { + if (hex.length === 4) { + hex = "#" + hex[1] + hex[1] + hex[2] + hex[2] + hex[3] + hex[3]; + } + const result = /^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i.exec(hex); + if (!result) { + return { r: 0, g: 0, b: 0 }; + } + return { + r: parseInt(result[1], 16) / 255, + g: parseInt(result[2], 16) / 255, + b: parseInt(result[3], 16) / 255 + }; +} + +export class MockColor { + r: number; + g: number; + b: number; + + constructor(color?: string | number) { + if (typeof color === "string") { + const rgb = hexToRgb(color); + this.r = rgb.r; + this.g = rgb.g; + this.b = rgb.b; + } else { + this.r = 0; + this.g = 0; + this.b = 0; + } + } + + set(r: number, g: number, b: number) { + this.r = r; + this.g = g; + this.b = b; + return this; + } + + clone() { + const c = new MockColor(); + c.r = this.r; + c.g = this.g; + c.b = this.b; + return c; + } +} + +export class MockVector3 { + x: number; + y: number; + z: number; + + constructor(x = 0, y = 0, z = 0) { + this.x = x; + this.y = y; + this.z = z; + } + + set(x: number, y: number, z: number) { + this.x = x; + this.y = y; + this.z = z; + return this; + } + + clone() { + return new MockVector3(this.x, this.y, this.z); + } + + copy(v: MockVector3) { + this.x = v.x; + this.y = v.y; + this.z = v.z; + return this; + } +} + +export class MockScene { + background: MockColor | null = null; + children: object[] = []; + + add(obj: object) { + this.children.push(obj); + } + + remove(obj: object) { + const idx = this.children.indexOf(obj); + if (idx > -1) { + this.children.splice(idx, 1); + } + } +} + +export class MockHemisphereLight { + color: MockColor; + groundColor: MockColor; + intensity: number; + position = new MockVector3(); + + constructor(skyColor?: MockColor, groundColor?: MockColor, intensity?: number) { + this.color = skyColor || new MockColor(); + this.groundColor = groundColor || new MockColor(); + this.intensity = intensity || 1; + } +} + +export class MockDirectionalLight { + color: MockColor; + intensity: number; + position = new MockVector3(); + castShadow = false; + target = { position: new MockVector3() }; + shadow = { + camera: { left: 0, right: 0, top: 0, bottom: 0, near: 0.1, far: 100 }, + mapSize: { width: 1024, height: 1024 }, + radius: 1, + blurSamples: 1, + bias: 0, + normalBias: 0, + }; + + constructor(color?: MockColor, intensity?: number) { + this.color = color || new MockColor(); + this.intensity = intensity || 1; + } +} + +export class MockPlaneGeometry { + parameters = { width: 10, height: 10 }; + + constructor(width: number, height: number) { + this.parameters.width = width; + this.parameters.height = height; + } + + dispose() { /* mock */ } +} + +export class MockMaterial { + color: MockColor = new MockColor(); + opacity = 1; + transparent = false; + side = 0; + roughness = 0.5; + metalness = 0.5; + + constructor(options?: object) { + if (options) { + Object.assign(this, options); + } + } + + dispose() { /* mock */ } +} + +export class MockMesh { + geometry: MockPlaneGeometry; + material: MockMaterial; + rotation = { x: 0, y: 0, z: 0 }; + position = new MockVector3(); + receiveShadow = false; + + constructor(geometry: MockPlaneGeometry, material: MockMaterial) { + this.geometry = geometry; + this.material = material; + } +} + +export class MockWebGLRenderer { + domElement: HTMLCanvasElement | null = null; + shadowMap = { enabled: false, type: 0 }; + _animationLoop: ((time: number) => void) | null = null; + + constructor(options: { antialias?: boolean; canvas?: HTMLCanvasElement }) { + this.domElement = options.canvas || null; + } + + setSize(_width: number, _height: number) { /* mock */ } + setPixelRatio(_ratio: number) { /* mock */ } + setAnimationLoop(callback: ((time: number) => void) | null) { + this._animationLoop = callback; + } + render(_scene: MockScene, _camera: object) { /* mock */ } + dispose() { /* mock */ } +} + +// Constants +export const VSMShadowMap = 2; +export const DoubleSide = 2; + +/** + * Create Three.js module mock for jest.mock() + */ +export function createThreeJSMock() { + return { + Scene: MockScene, + Color: MockColor, + Vector3: MockVector3, + HemisphereLight: MockHemisphereLight, + DirectionalLight: MockDirectionalLight, + WebGLRenderer: MockWebGLRenderer, + PlaneGeometry: MockPlaneGeometry, + MeshStandardMaterial: MockMaterial, + Mesh: MockMesh, + VSMShadowMap, + DoubleSide, + }; +} + +/** + * Create mock orbit camera result for testing + */ +export function createMockOrbitCameraResult() { + return { + camera: { aspect: 1, updateProjectionMatrix: jest.fn() }, + orbitCamera: { distance: 10, pitch: 0, yaw: 0, pivotPoint: { x: 0, y: 0, z: 0 } }, + mouseInput: { destroy: jest.fn() }, + touchInput: { destroy: jest.fn() }, + keyboardInput: { destroy: jest.fn() }, + update: jest.fn(), + destroy: jest.fn(), + }; +} + +// Type definitions for test assertions +export interface MockMeshType { + geometry: { parameters: { width: number; height: number } }; + material: { color: { r: number; g: number; b: number } }; +} diff --git a/packages/dev/threejs/lib/api/bitbybit/threejs/scene-helper.test.ts b/packages/dev/threejs/lib/api/bitbybit/threejs/scene-helper.test.ts index d107df80..261f8054 100644 --- a/packages/dev/threejs/lib/api/bitbybit/threejs/scene-helper.test.ts +++ b/packages/dev/threejs/lib/api/bitbybit/threejs/scene-helper.test.ts @@ -2,223 +2,22 @@ * @jest-environment jsdom */ /* eslint-disable @typescript-eslint/no-unused-vars */ -/* eslint-disable @typescript-eslint/no-empty-function */ import { ThreeJSScene } from "../../inputs/threejs-scene-inputs"; - -// Helper function to parse hex color -function hexToRgb(hex: string): { r: number; g: number; b: number } { - if (hex.length === 4) { - hex = "#" + hex[1] + hex[1] + hex[2] + hex[2] + hex[3] + hex[3]; - } - const result = /^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i.exec(hex); - if (!result) { - return { r: 0, g: 0, b: 0 }; - } - return { - r: parseInt(result[1], 16) / 255, - g: parseInt(result[2], 16) / 255, - b: parseInt(result[3], 16) / 255 - }; -} - -// Mock orbit camera result - defined before jest.mock -const mockOrbitCameraResult = { - camera: { aspect: 1, updateProjectionMatrix: jest.fn() }, - orbitCamera: { distance: 10, pitch: 0, yaw: 0, pivotPoint: { x: 0, y: 0, z: 0 } }, - mouseInput: { destroy: jest.fn() }, - touchInput: { destroy: jest.fn() }, - keyboardInput: { destroy: jest.fn() }, - update: jest.fn(), - destroy: jest.fn(), -}; - -// Mock three module - factory function creates classes inline +import { hexToRgb } from "../../__mocks__/test-helpers"; +// Mock three module using centralized mocks jest.mock("three", () => { - // Define mock classes inside the factory - class MockColor { - r: number; - g: number; - b: number; - - constructor(color?: string | number) { - if (typeof color === "string") { - // Parse hex color - const hex = color; - const result = /^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i.exec(hex); - if (result) { - this.r = parseInt(result[1], 16) / 255; - this.g = parseInt(result[2], 16) / 255; - this.b = parseInt(result[3], 16) / 255; - } else { - this.r = 0; - this.g = 0; - this.b = 0; - } - } else { - this.r = 0; - this.g = 0; - this.b = 0; - } - } - } - - class MockVector3 { - x: number; - y: number; - z: number; - - constructor(x = 0, y = 0, z = 0) { - this.x = x; - this.y = y; - this.z = z; - } - - set(x: number, y: number, z: number) { - this.x = x; - this.y = y; - this.z = z; - return this; - } - } - - class MockScene { - background: MockColor | null = null; - children: object[] = []; - - add(obj: object) { - this.children.push(obj); - } - - remove(obj: object) { - const idx = this.children.indexOf(obj); - if (idx > -1) { - this.children.splice(idx, 1); - } - } - } - - class MockHemisphereLight { - color: MockColor; - groundColor: MockColor; - intensity: number; - position = new MockVector3(); - - constructor(skyColor?: MockColor, groundColor?: MockColor, intensity?: number) { - this.color = skyColor || new MockColor(); - this.groundColor = groundColor || new MockColor(); - this.intensity = intensity || 1; - } - } - - class MockDirectionalLight { - color: MockColor; - intensity: number; - position = new MockVector3(); - castShadow = false; - target = { position: new MockVector3() }; - shadow = { - camera: { left: 0, right: 0, top: 0, bottom: 0, near: 0.1, far: 100 }, - mapSize: { width: 1024, height: 1024 }, - radius: 1, - blurSamples: 1, - bias: 0, - normalBias: 0, - }; - - constructor(color?: MockColor, intensity?: number) { - this.color = color || new MockColor(); - this.intensity = intensity || 1; - } - } - - class MockPlaneGeometry { - parameters = { width: 10, height: 10 }; - - constructor(width: number, height: number) { - this.parameters.width = width; - this.parameters.height = height; - } - - dispose() {} - } - - class MockMaterial { - color: MockColor = new MockColor(); - opacity = 1; - transparent = false; - side = 0; - roughness = 0.5; - metalness = 0.5; - - constructor(options?: object) { - if (options) { - Object.assign(this, options); - } - } - - dispose() {} - } - - class MockMesh { - geometry: MockPlaneGeometry; - material: MockMaterial; - rotation = { x: 0, y: 0, z: 0 }; - position = new MockVector3(); - receiveShadow = false; - - constructor(geometry: MockPlaneGeometry, material: MockMaterial) { - this.geometry = geometry; - this.material = material; - } - } - - class MockWebGLRenderer { - domElement: HTMLCanvasElement | null = null; - shadowMap = { enabled: false, type: 0 }; - _animationLoop: ((time: number) => void) | null = null; - - constructor(options: { antialias?: boolean; canvas?: HTMLCanvasElement }) { - // Canvas will be provided via options in the actual code - this.domElement = options.canvas || null; - } - - setSize(width: number, height: number) {} - setPixelRatio(ratio: number) {} - setAnimationLoop(callback: ((time: number) => void) | null) { - this._animationLoop = callback; - } - render(scene: MockScene, camera: object) {} - dispose() {} - } + const { createThreeJSMock } = jest.requireActual("../../__mocks__/threejs.mock"); + return createThreeJSMock(); +}); +// Mock the orbit-camera module using centralized mock factory +jest.mock("./orbit-camera", () => { + const { createMockOrbitCameraResult } = jest.requireActual("../../__mocks__/threejs.mock"); return { - Scene: MockScene, - Color: MockColor, - Vector3: MockVector3, - HemisphereLight: MockHemisphereLight, - DirectionalLight: MockDirectionalLight, - WebGLRenderer: MockWebGLRenderer, - PlaneGeometry: MockPlaneGeometry, - MeshStandardMaterial: MockMaterial, - Mesh: MockMesh, - VSMShadowMap: 2, - DoubleSide: 2, + createOrbitCamera: jest.fn().mockReturnValue(createMockOrbitCameraResult()), }; }); -// Mock the orbit-camera module -jest.mock("./orbit-camera", () => ({ - createOrbitCamera: jest.fn().mockReturnValue({ - camera: { aspect: 1, updateProjectionMatrix: jest.fn() }, - orbitCamera: { distance: 10, pitch: 0, yaw: 0, pivotPoint: { x: 0, y: 0, z: 0 } }, - mouseInput: { destroy: jest.fn() }, - touchInput: { destroy: jest.fn() }, - keyboardInput: { destroy: jest.fn() }, - update: jest.fn(), - destroy: jest.fn(), - }), -})); - // Import after mocks are defined import { initThreeJS } from "./scene-helper"; From 2f2e7fce31751d29d957b12bfc1174394e28aff5 Mon Sep 17 00:00:00 2001 From: Matas Ubarevicius Date: Tue, 13 Jan 2026 11:22:19 +0200 Subject: [PATCH 12/31] New npm package @bitbybit-dev/create-app. CLI tool to scaffold Bit By Bit Developers 3D/CAD projects with your favorite game engine. --- .../vite/threejs/starter-template/src/main.ts | 1 + packages/dev/core/package.json | 2 +- packages/dev/create-app/.gitignore | 22 + packages/dev/create-app/LICENSE | 21 + packages/dev/create-app/README.md | 97 ++ packages/dev/create-app/package-lock.json | 1017 +++++++++++++++++ packages/dev/create-app/package.json | 69 ++ packages/dev/create-app/src/index.ts | 322 ++++++ .../vite/babylonjs/typescript/index.html | 27 + .../vite/babylonjs/typescript/package.json | 18 + .../vite/babylonjs/typescript/public/vite.svg | 1 + .../vite/babylonjs/typescript/src/main.ts | 121 ++ .../vite/babylonjs/typescript/src/style.css | 31 + .../babylonjs/typescript/src/vite-env.d.ts | 1 + .../vite/babylonjs/typescript/tsconfig.json | 25 + .../vite/playcanvas/typescript/index.html | 27 + .../vite/playcanvas/typescript/package.json | 19 + .../playcanvas/typescript/public/vite.svg | 1 + .../vite/playcanvas/typescript/src/main.ts | 114 ++ .../vite/playcanvas/typescript/src/style.css | 25 + .../playcanvas/typescript/src/vite-env.d.ts | 1 + .../vite/playcanvas/typescript/tsconfig.json | 25 + .../vite/threejs/typescript/index.html | 27 + .../vite/threejs/typescript/package.json | 19 + .../vite/threejs/typescript/public/vite.svg | 1 + .../vite/threejs/typescript/src/main.ts | 115 ++ .../vite/threejs/typescript/src/style.css | 25 + .../vite/threejs/typescript/src/vite-env.d.ts | 1 + .../vite/threejs/typescript/tsconfig.json | 25 + packages/dev/create-app/tsconfig.json | 20 + packages/dev/tmp/test-app/index.html | 27 + packages/dev/tmp/test-app/package.json | 19 + packages/dev/tmp/test-app/public/vite.svg | 1 + packages/dev/tmp/test-app/src/main.ts | 114 ++ packages/dev/tmp/test-app/src/style.css | 25 + packages/dev/tmp/test-app/src/vite-env.d.ts | 1 + packages/dev/tmp/test-app/tsconfig.json | 25 + 37 files changed, 2431 insertions(+), 1 deletion(-) create mode 100644 packages/dev/create-app/.gitignore create mode 100644 packages/dev/create-app/LICENSE create mode 100644 packages/dev/create-app/README.md create mode 100644 packages/dev/create-app/package-lock.json create mode 100644 packages/dev/create-app/package.json create mode 100644 packages/dev/create-app/src/index.ts create mode 100644 packages/dev/create-app/templates/vite/babylonjs/typescript/index.html create mode 100644 packages/dev/create-app/templates/vite/babylonjs/typescript/package.json create mode 100644 packages/dev/create-app/templates/vite/babylonjs/typescript/public/vite.svg create mode 100644 packages/dev/create-app/templates/vite/babylonjs/typescript/src/main.ts create mode 100644 packages/dev/create-app/templates/vite/babylonjs/typescript/src/style.css create mode 100644 packages/dev/create-app/templates/vite/babylonjs/typescript/src/vite-env.d.ts create mode 100644 packages/dev/create-app/templates/vite/babylonjs/typescript/tsconfig.json create mode 100644 packages/dev/create-app/templates/vite/playcanvas/typescript/index.html create mode 100644 packages/dev/create-app/templates/vite/playcanvas/typescript/package.json create mode 100644 packages/dev/create-app/templates/vite/playcanvas/typescript/public/vite.svg create mode 100644 packages/dev/create-app/templates/vite/playcanvas/typescript/src/main.ts create mode 100644 packages/dev/create-app/templates/vite/playcanvas/typescript/src/style.css create mode 100644 packages/dev/create-app/templates/vite/playcanvas/typescript/src/vite-env.d.ts create mode 100644 packages/dev/create-app/templates/vite/playcanvas/typescript/tsconfig.json create mode 100644 packages/dev/create-app/templates/vite/threejs/typescript/index.html create mode 100644 packages/dev/create-app/templates/vite/threejs/typescript/package.json create mode 100644 packages/dev/create-app/templates/vite/threejs/typescript/public/vite.svg create mode 100644 packages/dev/create-app/templates/vite/threejs/typescript/src/main.ts create mode 100644 packages/dev/create-app/templates/vite/threejs/typescript/src/style.css create mode 100644 packages/dev/create-app/templates/vite/threejs/typescript/src/vite-env.d.ts create mode 100644 packages/dev/create-app/templates/vite/threejs/typescript/tsconfig.json create mode 100644 packages/dev/create-app/tsconfig.json create mode 100644 packages/dev/tmp/test-app/index.html create mode 100644 packages/dev/tmp/test-app/package.json create mode 100644 packages/dev/tmp/test-app/public/vite.svg create mode 100644 packages/dev/tmp/test-app/src/main.ts create mode 100644 packages/dev/tmp/test-app/src/style.css create mode 100644 packages/dev/tmp/test-app/src/vite-env.d.ts create mode 100644 packages/dev/tmp/test-app/tsconfig.json diff --git a/examples/vite/threejs/starter-template/src/main.ts b/examples/vite/threejs/starter-template/src/main.ts index 6b5172b4..36ce6893 100644 --- a/examples/vite/threejs/starter-template/src/main.ts +++ b/examples/vite/threejs/starter-template/src/main.ts @@ -51,6 +51,7 @@ async function createOCCTGeometry(bitbybit: BitByBitBase, color: string) { drawOptions.drawVertices = true; drawOptions.vertexSize = 0.05; drawOptions.vertexColour = "#ffffff"; + await bitbybit.draw.drawAnyAsync({ entity: roundedCube, options: drawOptions, diff --git a/packages/dev/core/package.json b/packages/dev/core/package.json index 8bb6ffea..85fb7b99 100644 --- a/packages/dev/core/package.json +++ b/packages/dev/core/package.json @@ -58,7 +58,7 @@ "@bitbybit-dev/occt-worker": "0.21.0", "@bitbybit-dev/manifold-worker": "0.21.0", "@bitbybit-dev/jscad-worker": "0.21.0", - "jsonpath-plus": "10.1.0", + "jsonpath-plus": "10.3.0", "verb-nurbs-web": "2.1.3", "rxjs": "7.5.5" }, diff --git a/packages/dev/create-app/.gitignore b/packages/dev/create-app/.gitignore new file mode 100644 index 00000000..b0ec6910 --- /dev/null +++ b/packages/dev/create-app/.gitignore @@ -0,0 +1,22 @@ +# Dependencies +node_modules/ + +# Build output +dist/ + +# IDE +.idea/ +.vscode/ +*.swp +*.swo + +# OS +.DS_Store +Thumbs.db + +# Logs +*.log +npm-debug.log* + +# Coverage +coverage/ diff --git a/packages/dev/create-app/LICENSE b/packages/dev/create-app/LICENSE new file mode 100644 index 00000000..1752870b --- /dev/null +++ b/packages/dev/create-app/LICENSE @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2024 Bit By Bit Developers + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/packages/dev/create-app/README.md b/packages/dev/create-app/README.md new file mode 100644 index 00000000..829d412c --- /dev/null +++ b/packages/dev/create-app/README.md @@ -0,0 +1,97 @@ +# @bitbybit-dev/create-app + +🚀 **CLI tool to scaffold Bit By Bit Developers 3D/CAD projects with your favorite game engine** + +Create stunning 3D/CAD applications with ease using our powerful geometry kernels: OCCT (OpenCascade), JSCAD, and Manifold. + +## Quick Start + +### Using npm init (Recommended) + +```bash +npm init @bitbybit-dev/app my-project +``` + +### Using npx + +```bash +npx @bitbybit-dev/create-app my-project +``` + +## Usage + +### Interactive Mode + +Simply run the command without options to enter interactive mode: + +```bash +npm init @bitbybit-dev/app my-project +``` + +You'll be prompted to select: +- 🎮 **Game Engine**: Three.js, Babylon.js, or PlayCanvas + +### CLI Options + +```bash +npm init @bitbybit-dev/app my-project --engine threejs +``` + +Available engines: +- `threejs` - Three.js: Lightweight and flexible 3D library +- `babylonjs` - Babylon.js: Powerful and feature-rich game engine +- `playcanvas` - PlayCanvas: Fast and lightweight WebGL game engine + +## What You Get + +Each scaffolded project includes: + +- ⚡ **Vite** - Lightning fast build tool +- 📘 **TypeScript** - Type-safe development +- 🎨 **Bitbybit** - All geometry kernels pre-configured: + - **OCCT** (OpenCascade) - Professional CAD kernel + - **JSCAD** - Programmatic solid modeling + - **Manifold** - Fast mesh boolean operations +- 🎮 **Your chosen 3D engine** - Three.js, Babylon.js, or PlayCanvas + +## After Scaffolding + +Navigate to your project and start developing: + +```bash +cd my-project +npm install +npm run dev +``` + +## Project Structure + +``` +my-project/ +├── index.html +├── package.json +├── tsconfig.json +├── public/ +│ └── vite.svg +└── src/ + ├── main.ts + ├── style.css + └── vite-env.d.ts +``` + +## Links + +- 🌐 **Website**: [https://bitbybit.dev](https://bitbybit.dev) +- 📚 **Documentation**: [https://bitbybit.dev/docs](https://bitbybit.dev/docs) +- 💬 **Discord Community**: [https://discord.gg/GSe3VMe](https://discord.gg/GSe3VMe) +- 🐛 **Issues**: [https://github.com/bitbybit-dev/bitbybit/issues](https://github.com/bitbybit-dev/bitbybit/issues) + +## Support Us + +⭐ **The best way to support Bit By Bit Developers is with a Silver or Gold plan subscription!** + +[Subscribe Now](https://bitbybit.dev/auth/pick-plan) + +## License + +MIT © [Bit By Bit Developers](https://bitbybit.dev) diff --git a/packages/dev/create-app/package-lock.json b/packages/dev/create-app/package-lock.json new file mode 100644 index 00000000..8ef2105a --- /dev/null +++ b/packages/dev/create-app/package-lock.json @@ -0,0 +1,1017 @@ +{ + "name": "@bitbybit-dev/create-app", + "version": "0.21.0", + "lockfileVersion": 3, + "requires": true, + "packages": { + "": { + "name": "@bitbybit-dev/create-app", + "version": "0.21.0", + "license": "MIT", + "dependencies": { + "chalk": "^5.3.0", + "commander": "^12.1.0", + "fs-extra": "^11.2.0", + "gradient-string": "^3.0.0", + "inquirer": "^9.3.7", + "ora": "^8.1.1" + }, + "bin": { + "create-app": "dist/index.js", + "create-bitbybit-app": "dist/index.js" + }, + "devDependencies": { + "@types/fs-extra": "^11.0.4", + "@types/gradient-string": "^1.1.6", + "@types/inquirer": "^9.0.7", + "@types/node": "^22.10.2", + "typescript": "~5.8.3" + }, + "engines": { + "node": ">=18.0.0" + } + }, + "node_modules/@inquirer/external-editor": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/@inquirer/external-editor/-/external-editor-1.0.3.tgz", + "integrity": "sha512-RWbSrDiYmO4LbejWY7ttpxczuwQyZLBUyygsA9Nsv95hpzUWwnNTVQmAq3xuh7vNwCp07UTmE5i11XAEExx4RA==", + "license": "MIT", + "dependencies": { + "chardet": "^2.1.1", + "iconv-lite": "^0.7.0" + }, + "engines": { + "node": ">=18" + }, + "peerDependencies": { + "@types/node": ">=18" + }, + "peerDependenciesMeta": { + "@types/node": { + "optional": true + } + } + }, + "node_modules/@inquirer/figures": { + "version": "1.0.15", + "resolved": "https://registry.npmjs.org/@inquirer/figures/-/figures-1.0.15.tgz", + "integrity": "sha512-t2IEY+unGHOzAaVM5Xx6DEWKeXlDDcNPeDyUpsRc6CUhBfU3VQOEl+Vssh7VNp1dR8MdUJBWhuObjXCsVpjN5g==", + "license": "MIT", + "engines": { + "node": ">=18" + } + }, + "node_modules/@types/fs-extra": { + "version": "11.0.4", + "resolved": "https://registry.npmjs.org/@types/fs-extra/-/fs-extra-11.0.4.tgz", + "integrity": "sha512-yTbItCNreRooED33qjunPthRcSjERP1r4MqCZc7wv0u2sUkzTFp45tgUfS5+r7FrZPdmCCNflLhVSP/o+SemsQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "@types/jsonfile": "*", + "@types/node": "*" + } + }, + "node_modules/@types/gradient-string": { + "version": "1.1.6", + "resolved": "https://registry.npmjs.org/@types/gradient-string/-/gradient-string-1.1.6.tgz", + "integrity": "sha512-LkaYxluY4G5wR1M4AKQUal2q61Di1yVVCw42ImFTuaIoQVgmV0WP1xUaLB8zwb47mp82vWTpePI9JmrjEnJ7nQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "@types/tinycolor2": "*" + } + }, + "node_modules/@types/inquirer": { + "version": "9.0.9", + "resolved": "https://registry.npmjs.org/@types/inquirer/-/inquirer-9.0.9.tgz", + "integrity": "sha512-/mWx5136gts2Z2e5izdoRCo46lPp5TMs9R15GTSsgg/XnZyxDWVqoVU3R9lWnccKpqwsJLvRoxbCjoJtZB7DSw==", + "dev": true, + "license": "MIT", + "dependencies": { + "@types/through": "*", + "rxjs": "^7.2.0" + } + }, + "node_modules/@types/jsonfile": { + "version": "6.1.4", + "resolved": "https://registry.npmjs.org/@types/jsonfile/-/jsonfile-6.1.4.tgz", + "integrity": "sha512-D5qGUYwjvnNNextdU59/+fI+spnwtTFmyQP0h+PfIOSkNfpU6AOICUOkm4i0OnSk+NyjdPJrxCDro0sJsWlRpQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "@types/node": "*" + } + }, + "node_modules/@types/node": { + "version": "22.19.5", + "resolved": "https://registry.npmjs.org/@types/node/-/node-22.19.5.tgz", + "integrity": "sha512-HfF8+mYcHPcPypui3w3mvzuIErlNOh2OAG+BCeBZCEwyiD5ls2SiCwEyT47OELtf7M3nHxBdu0FsmzdKxkN52Q==", + "devOptional": true, + "license": "MIT", + "dependencies": { + "undici-types": "~6.21.0" + } + }, + "node_modules/@types/through": { + "version": "0.0.33", + "resolved": "https://registry.npmjs.org/@types/through/-/through-0.0.33.tgz", + "integrity": "sha512-HsJ+z3QuETzP3cswwtzt2vEIiHBk/dCcHGhbmG5X3ecnwFD/lPrMpliGXxSCg03L9AhrdwA4Oz/qfspkDW+xGQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "@types/node": "*" + } + }, + "node_modules/@types/tinycolor2": { + "version": "1.4.6", + "resolved": "https://registry.npmjs.org/@types/tinycolor2/-/tinycolor2-1.4.6.tgz", + "integrity": "sha512-iEN8J0BoMnsWBqjVbWH/c0G0Hh7O21lpR2/+PrvAVgWdzL7eexIFm4JN/Wn10PTcmNdtS6U67r499mlWMXOxNw==", + "license": "MIT" + }, + "node_modules/ansi-escapes": { + "version": "4.3.2", + "resolved": "https://registry.npmjs.org/ansi-escapes/-/ansi-escapes-4.3.2.tgz", + "integrity": "sha512-gKXj5ALrKWQLsYG9jlTRmR/xKluxHV+Z9QEwNIgCfM1/uwPMCuzVVnh5mwTd+OuBZcwSIMbqssNWRm1lE51QaQ==", + "license": "MIT", + "dependencies": { + "type-fest": "^0.21.3" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/ansi-regex": { + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.1.tgz", + "integrity": "sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==", + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "license": "MIT", + "dependencies": { + "color-convert": "^2.0.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/base64-js": { + "version": "1.5.1", + "resolved": "https://registry.npmjs.org/base64-js/-/base64-js-1.5.1.tgz", + "integrity": "sha512-AKpaYlHn8t4SVbOHCy+b5+KKgvR4vrsD8vbvrbiQJps7fKDTkjkDry6ji0rUJjC0kzbNePLwzxq8iypo41qeWA==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "license": "MIT" + }, + "node_modules/bl": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/bl/-/bl-4.1.0.tgz", + "integrity": "sha512-1W07cM9gS6DcLperZfFSj+bWLtaPGSOHWhPiGzXmvVJbRLdG82sH/Kn8EtW1VqWVA54AKf2h5k5BbnIbwF3h6w==", + "license": "MIT", + "dependencies": { + "buffer": "^5.5.0", + "inherits": "^2.0.4", + "readable-stream": "^3.4.0" + } + }, + "node_modules/buffer": { + "version": "5.7.1", + "resolved": "https://registry.npmjs.org/buffer/-/buffer-5.7.1.tgz", + "integrity": "sha512-EHcyIPBQ4BSGlvjB16k5KgAJ27CIsHY/2JBmCRReo48y9rQ3MaUzWX3KVlBa4U7MyX02HdVj0K7C3WaB3ju7FQ==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "license": "MIT", + "dependencies": { + "base64-js": "^1.3.1", + "ieee754": "^1.1.13" + } + }, + "node_modules/chalk": { + "version": "5.6.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-5.6.2.tgz", + "integrity": "sha512-7NzBL0rN6fMUW+f7A6Io4h40qQlG+xGmtMxfbnH/K7TAtt8JQWVQK+6g0UXKMeVJoyV5EkkNsErQ8pVD3bLHbA==", + "license": "MIT", + "engines": { + "node": "^12.17.0 || ^14.13 || >=16.0.0" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" + } + }, + "node_modules/chardet": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/chardet/-/chardet-2.1.1.tgz", + "integrity": "sha512-PsezH1rqdV9VvyNhxxOW32/d75r01NY7TQCmOqomRo15ZSOKbpTFVsfjghxo6JloQUCGnH4k1LGu0R4yCLlWQQ==", + "license": "MIT" + }, + "node_modules/cli-cursor": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/cli-cursor/-/cli-cursor-5.0.0.tgz", + "integrity": "sha512-aCj4O5wKyszjMmDT4tZj93kxyydN/K5zPWSCe6/0AV/AA1pqe5ZBIw0a2ZfPQV7lL5/yb5HsUreJ6UFAF1tEQw==", + "license": "MIT", + "dependencies": { + "restore-cursor": "^5.0.0" + }, + "engines": { + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/cli-spinners": { + "version": "2.9.2", + "resolved": "https://registry.npmjs.org/cli-spinners/-/cli-spinners-2.9.2.tgz", + "integrity": "sha512-ywqV+5MmyL4E7ybXgKys4DugZbX0FC6LnwrhjuykIjnK9k8OQacQ7axGKnjDXWNhns0xot3bZI5h55H8yo9cJg==", + "license": "MIT", + "engines": { + "node": ">=6" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/cli-width": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/cli-width/-/cli-width-4.1.0.tgz", + "integrity": "sha512-ouuZd4/dm2Sw5Gmqy6bGyNNNe1qt9RpmxveLSO7KcgsTnU7RXfsw+/bukWGo1abgBiMAic068rclZsO4IWmmxQ==", + "license": "ISC", + "engines": { + "node": ">= 12" + } + }, + "node_modules/clone": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/clone/-/clone-1.0.4.tgz", + "integrity": "sha512-JQHZ2QMW6l3aH/j6xCqQThY/9OH4D/9ls34cgkUBiEeocRTU04tHfKPBsUK1PqZCUQM7GiA0IIXJSuXHI64Kbg==", + "license": "MIT", + "engines": { + "node": ">=0.8" + } + }, + "node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "license": "MIT", + "dependencies": { + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", + "license": "MIT" + }, + "node_modules/commander": { + "version": "12.1.0", + "resolved": "https://registry.npmjs.org/commander/-/commander-12.1.0.tgz", + "integrity": "sha512-Vw8qHK3bZM9y/P10u3Vib8o/DdkvA2OtPtZvD871QKjy74Wj1WSKFILMPRPSdUSx5RFK1arlJzEtA4PkFgnbuA==", + "license": "MIT", + "engines": { + "node": ">=18" + } + }, + "node_modules/defaults": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/defaults/-/defaults-1.0.4.tgz", + "integrity": "sha512-eFuaLoy/Rxalv2kr+lqMlUnrDWV+3j4pljOIJgLIhI058IQfWJ7vXhyEIHu+HtC738klGALYxOKDO0bQP3tg8A==", + "license": "MIT", + "dependencies": { + "clone": "^1.0.2" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/emoji-regex": { + "version": "8.0.0", + "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-8.0.0.tgz", + "integrity": "sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A==", + "license": "MIT" + }, + "node_modules/fs-extra": { + "version": "11.3.3", + "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-11.3.3.tgz", + "integrity": "sha512-VWSRii4t0AFm6ixFFmLLx1t7wS1gh+ckoa84aOeapGum0h+EZd1EhEumSB+ZdDLnEPuucsVB9oB7cxJHap6Afg==", + "license": "MIT", + "dependencies": { + "graceful-fs": "^4.2.0", + "jsonfile": "^6.0.1", + "universalify": "^2.0.0" + }, + "engines": { + "node": ">=14.14" + } + }, + "node_modules/get-east-asian-width": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/get-east-asian-width/-/get-east-asian-width-1.4.0.tgz", + "integrity": "sha512-QZjmEOC+IT1uk6Rx0sX22V6uHWVwbdbxf1faPqJ1QhLdGgsRGCZoyaQBm/piRdJy/D2um6hM1UP7ZEeQ4EkP+Q==", + "license": "MIT", + "engines": { + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/graceful-fs": { + "version": "4.2.11", + "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.11.tgz", + "integrity": "sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ==", + "license": "ISC" + }, + "node_modules/gradient-string": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/gradient-string/-/gradient-string-3.0.0.tgz", + "integrity": "sha512-frdKI4Qi8Ihp4C6wZNB565de/THpIaw3DjP5ku87M+N9rNSGmPTjfkq61SdRXB7eCaL8O1hkKDvf6CDMtOzIAg==", + "license": "MIT", + "dependencies": { + "chalk": "^5.3.0", + "tinygradient": "^1.1.5" + }, + "engines": { + "node": ">=14" + } + }, + "node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "node_modules/iconv-lite": { + "version": "0.7.2", + "resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.7.2.tgz", + "integrity": "sha512-im9DjEDQ55s9fL4EYzOAv0yMqmMBSZp6G0VvFyTMPKWxiSBHUj9NW/qqLmXUwXrrM7AvqSlTCfvqRb0cM8yYqw==", + "license": "MIT", + "dependencies": { + "safer-buffer": ">= 2.1.2 < 3.0.0" + }, + "engines": { + "node": ">=0.10.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/express" + } + }, + "node_modules/ieee754": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/ieee754/-/ieee754-1.2.1.tgz", + "integrity": "sha512-dcyqhDvX1C46lXZcVqCpK+FtMRQVdIMN6/Df5js2zouUsqG7I6sFxitIC+7KYK29KdXOLHdu9zL4sFnoVQnqaA==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "license": "BSD-3-Clause" + }, + "node_modules/inherits": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz", + "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==", + "license": "ISC" + }, + "node_modules/inquirer": { + "version": "9.3.8", + "resolved": "https://registry.npmjs.org/inquirer/-/inquirer-9.3.8.tgz", + "integrity": "sha512-pFGGdaHrmRKMh4WoDDSowddgjT1Vkl90atobmTeSmcPGdYiwikch/m/Ef5wRaiamHejtw0cUUMMerzDUXCci2w==", + "license": "MIT", + "dependencies": { + "@inquirer/external-editor": "^1.0.2", + "@inquirer/figures": "^1.0.3", + "ansi-escapes": "^4.3.2", + "cli-width": "^4.1.0", + "mute-stream": "1.0.0", + "ora": "^5.4.1", + "run-async": "^3.0.0", + "rxjs": "^7.8.1", + "string-width": "^4.2.3", + "strip-ansi": "^6.0.1", + "wrap-ansi": "^6.2.0", + "yoctocolors-cjs": "^2.1.2" + }, + "engines": { + "node": ">=18" + } + }, + "node_modules/inquirer/node_modules/chalk": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "license": "MIT", + "dependencies": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" + } + }, + "node_modules/inquirer/node_modules/cli-cursor": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/cli-cursor/-/cli-cursor-3.1.0.tgz", + "integrity": "sha512-I/zHAwsKf9FqGoXM4WWRACob9+SNukZTd94DWF57E4toouRulbCxcUh6RKUEOQlYTHJnzkPMySvPNaaSLNfLZw==", + "license": "MIT", + "dependencies": { + "restore-cursor": "^3.1.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/inquirer/node_modules/is-interactive": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/is-interactive/-/is-interactive-1.0.0.tgz", + "integrity": "sha512-2HvIEKRoqS62guEC+qBjpvRubdX910WCMuJTZ+I9yvqKU2/12eSL549HMwtabb4oupdj2sMP50k+XJfB/8JE6w==", + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "node_modules/inquirer/node_modules/is-unicode-supported": { + "version": "0.1.0", + "resolved": "https://registry.npmjs.org/is-unicode-supported/-/is-unicode-supported-0.1.0.tgz", + "integrity": "sha512-knxG2q4UC3u8stRGyAVJCOdxFmv5DZiRcdlIaAQXAbSfJya+OhopNotLQrstBhququ4ZpuKbDc/8S6mgXgPFPw==", + "license": "MIT", + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/inquirer/node_modules/log-symbols": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/log-symbols/-/log-symbols-4.1.0.tgz", + "integrity": "sha512-8XPvpAA8uyhfteu8pIvQxpJZ7SYYdpUivZpGy6sFsBuKRY/7rQGavedeB8aK+Zkyq6upMFVL/9AW6vOYzfRyLg==", + "license": "MIT", + "dependencies": { + "chalk": "^4.1.0", + "is-unicode-supported": "^0.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/inquirer/node_modules/onetime": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/onetime/-/onetime-5.1.2.tgz", + "integrity": "sha512-kbpaSSGJTWdAY5KPVeMOKXSrPtr8C8C7wodJbcsd51jRnmD+GZu8Y0VoU6Dm5Z4vWr0Ig/1NKuWRKf7j5aaYSg==", + "license": "MIT", + "dependencies": { + "mimic-fn": "^2.1.0" + }, + "engines": { + "node": ">=6" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/inquirer/node_modules/ora": { + "version": "5.4.1", + "resolved": "https://registry.npmjs.org/ora/-/ora-5.4.1.tgz", + "integrity": "sha512-5b6Y85tPxZZ7QytO+BQzysW31HJku27cRIlkbAXaNx+BdcVi+LlRFmVXzeF6a7JCwJpyw5c4b+YSVImQIrBpuQ==", + "license": "MIT", + "dependencies": { + "bl": "^4.1.0", + "chalk": "^4.1.0", + "cli-cursor": "^3.1.0", + "cli-spinners": "^2.5.0", + "is-interactive": "^1.0.0", + "is-unicode-supported": "^0.1.0", + "log-symbols": "^4.1.0", + "strip-ansi": "^6.0.0", + "wcwidth": "^1.0.1" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/inquirer/node_modules/restore-cursor": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/restore-cursor/-/restore-cursor-3.1.0.tgz", + "integrity": "sha512-l+sSefzHpj5qimhFSE5a8nufZYAM3sBSVMAPtYkmC+4EH2anSGaEMXSD0izRQbu9nfyQ9y5JrVmp7E8oZrUjvA==", + "license": "MIT", + "dependencies": { + "onetime": "^5.1.0", + "signal-exit": "^3.0.2" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/inquirer/node_modules/signal-exit": { + "version": "3.0.7", + "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-3.0.7.tgz", + "integrity": "sha512-wnD2ZE+l+SPC/uoS0vXeE9L1+0wuaMqKlfz9AMUo38JsyLSBWSFcHR1Rri62LZc12vLr1gb3jl7iwQhgwpAbGQ==", + "license": "ISC" + }, + "node_modules/is-fullwidth-code-point": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz", + "integrity": "sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==", + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "node_modules/is-interactive": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/is-interactive/-/is-interactive-2.0.0.tgz", + "integrity": "sha512-qP1vozQRI+BMOPcjFzrjXuQvdak2pHNUMZoeG2eRbiSqyvbEf/wQtEOTOX1guk6E3t36RkaqiSt8A/6YElNxLQ==", + "license": "MIT", + "engines": { + "node": ">=12" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/is-unicode-supported": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/is-unicode-supported/-/is-unicode-supported-2.1.0.tgz", + "integrity": "sha512-mE00Gnza5EEB3Ds0HfMyllZzbBrmLOX3vfWoj9A9PEnTfratQ/BcaJOuMhnkhjXvb2+FkY3VuHqtAGpTPmglFQ==", + "license": "MIT", + "engines": { + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/jsonfile": { + "version": "6.2.0", + "resolved": "https://registry.npmjs.org/jsonfile/-/jsonfile-6.2.0.tgz", + "integrity": "sha512-FGuPw30AdOIUTRMC2OMRtQV+jkVj2cfPqSeWXv1NEAJ1qZ5zb1X6z1mFhbfOB/iy3ssJCD+3KuZ8r8C3uVFlAg==", + "license": "MIT", + "dependencies": { + "universalify": "^2.0.0" + }, + "optionalDependencies": { + "graceful-fs": "^4.1.6" + } + }, + "node_modules/log-symbols": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/log-symbols/-/log-symbols-6.0.0.tgz", + "integrity": "sha512-i24m8rpwhmPIS4zscNzK6MSEhk0DUWa/8iYQWxhffV8jkI4Phvs3F+quL5xvS0gdQR0FyTCMMH33Y78dDTzzIw==", + "license": "MIT", + "dependencies": { + "chalk": "^5.3.0", + "is-unicode-supported": "^1.3.0" + }, + "engines": { + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/log-symbols/node_modules/is-unicode-supported": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/is-unicode-supported/-/is-unicode-supported-1.3.0.tgz", + "integrity": "sha512-43r2mRvz+8JRIKnWJ+3j8JtjRKZ6GmjzfaE/qiBJnikNnYv/6bagRJ1kUhNk8R5EX/GkobD+r+sfxCPJsiKBLQ==", + "license": "MIT", + "engines": { + "node": ">=12" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/mimic-fn": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/mimic-fn/-/mimic-fn-2.1.0.tgz", + "integrity": "sha512-OqbOk5oEQeAZ8WXWydlu9HJjz9WVdEIvamMCcXmuqUYjTknH/sqsWvhQ3vgwKFRR1HpjvNBKQ37nbJgYzGqGcg==", + "license": "MIT", + "engines": { + "node": ">=6" + } + }, + "node_modules/mimic-function": { + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/mimic-function/-/mimic-function-5.0.1.tgz", + "integrity": "sha512-VP79XUPxV2CigYP3jWwAUFSku2aKqBH7uTAapFWCBqutsbmDo96KY5o8uh6U+/YSIn5OxJnXp73beVkpqMIGhA==", + "license": "MIT", + "engines": { + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/mute-stream": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/mute-stream/-/mute-stream-1.0.0.tgz", + "integrity": "sha512-avsJQhyd+680gKXyG/sQc0nXaC6rBkPOfyHYcFb9+hdkqQkR9bdnkJ0AMZhke0oesPqIO+mFFJ+IdBc7mst4IA==", + "license": "ISC", + "engines": { + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" + } + }, + "node_modules/onetime": { + "version": "7.0.0", + "resolved": "https://registry.npmjs.org/onetime/-/onetime-7.0.0.tgz", + "integrity": "sha512-VXJjc87FScF88uafS3JllDgvAm+c/Slfz06lorj2uAY34rlUu0Nt+v8wreiImcrgAjjIHp1rXpTDlLOGw29WwQ==", + "license": "MIT", + "dependencies": { + "mimic-function": "^5.0.0" + }, + "engines": { + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/ora": { + "version": "8.2.0", + "resolved": "https://registry.npmjs.org/ora/-/ora-8.2.0.tgz", + "integrity": "sha512-weP+BZ8MVNnlCm8c0Qdc1WSWq4Qn7I+9CJGm7Qali6g44e/PUzbjNqJX5NJ9ljlNMosfJvg1fKEGILklK9cwnw==", + "license": "MIT", + "dependencies": { + "chalk": "^5.3.0", + "cli-cursor": "^5.0.0", + "cli-spinners": "^2.9.2", + "is-interactive": "^2.0.0", + "is-unicode-supported": "^2.0.0", + "log-symbols": "^6.0.0", + "stdin-discarder": "^0.2.2", + "string-width": "^7.2.0", + "strip-ansi": "^7.1.0" + }, + "engines": { + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/ora/node_modules/ansi-regex": { + "version": "6.2.2", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-6.2.2.tgz", + "integrity": "sha512-Bq3SmSpyFHaWjPk8If9yc6svM8c56dB5BAtW4Qbw5jHTwwXXcTLoRMkpDJp6VL0XzlWaCHTXrkFURMYmD0sLqg==", + "license": "MIT", + "engines": { + "node": ">=12" + }, + "funding": { + "url": "https://github.com/chalk/ansi-regex?sponsor=1" + } + }, + "node_modules/ora/node_modules/emoji-regex": { + "version": "10.6.0", + "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-10.6.0.tgz", + "integrity": "sha512-toUI84YS5YmxW219erniWD0CIVOo46xGKColeNQRgOzDorgBi1v4D71/OFzgD9GO2UGKIv1C3Sp8DAn0+j5w7A==", + "license": "MIT" + }, + "node_modules/ora/node_modules/string-width": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-7.2.0.tgz", + "integrity": "sha512-tsaTIkKW9b4N+AEj+SVA+WhJzV7/zMhcSu78mLKWSk7cXMOSHsBKFWUs0fWwq8QyK3MgJBQRX6Gbi4kYbdvGkQ==", + "license": "MIT", + "dependencies": { + "emoji-regex": "^10.3.0", + "get-east-asian-width": "^1.0.0", + "strip-ansi": "^7.1.0" + }, + "engines": { + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/ora/node_modules/strip-ansi": { + "version": "7.1.2", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-7.1.2.tgz", + "integrity": "sha512-gmBGslpoQJtgnMAvOVqGZpEz9dyoKTCzy2nfz/n8aIFhN/jCE/rCmcxabB6jOOHV+0WNnylOxaxBQPSvcWklhA==", + "license": "MIT", + "dependencies": { + "ansi-regex": "^6.0.1" + }, + "engines": { + "node": ">=12" + }, + "funding": { + "url": "https://github.com/chalk/strip-ansi?sponsor=1" + } + }, + "node_modules/readable-stream": { + "version": "3.6.2", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-3.6.2.tgz", + "integrity": "sha512-9u/sniCrY3D5WdsERHzHE4G2YCXqoG5FTHUiCC4SIbr6XcLZBY05ya9EKjYek9O5xOAwjGq+1JdGBAS7Q9ScoA==", + "license": "MIT", + "dependencies": { + "inherits": "^2.0.3", + "string_decoder": "^1.1.1", + "util-deprecate": "^1.0.1" + }, + "engines": { + "node": ">= 6" + } + }, + "node_modules/restore-cursor": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/restore-cursor/-/restore-cursor-5.1.0.tgz", + "integrity": "sha512-oMA2dcrw6u0YfxJQXm342bFKX/E4sG9rbTzO9ptUcR/e8A33cHuvStiYOwH7fszkZlZ1z/ta9AAoPk2F4qIOHA==", + "license": "MIT", + "dependencies": { + "onetime": "^7.0.0", + "signal-exit": "^4.1.0" + }, + "engines": { + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/run-async": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/run-async/-/run-async-3.0.0.tgz", + "integrity": "sha512-540WwVDOMxA6dN6We19EcT9sc3hkXPw5mzRNGM3FkdN/vtE9NFvj5lFAPNwUDmJjXidm3v7TC1cTE7t17Ulm1Q==", + "license": "MIT", + "engines": { + "node": ">=0.12.0" + } + }, + "node_modules/rxjs": { + "version": "7.8.2", + "resolved": "https://registry.npmjs.org/rxjs/-/rxjs-7.8.2.tgz", + "integrity": "sha512-dhKf903U/PQZY6boNNtAGdWbG85WAbjT/1xYoZIC7FAY0yWapOBQVsVrDl58W86//e1VpMNBtRV4MaXfdMySFA==", + "license": "Apache-2.0", + "dependencies": { + "tslib": "^2.1.0" + } + }, + "node_modules/safe-buffer": { + "version": "5.2.1", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz", + "integrity": "sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "license": "MIT" + }, + "node_modules/safer-buffer": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz", + "integrity": "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==", + "license": "MIT" + }, + "node_modules/signal-exit": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-4.1.0.tgz", + "integrity": "sha512-bzyZ1e88w9O1iNJbKnOlvYTrWPDl46O1bG0D3XInv+9tkPrxrN8jUUTiFlDkkmKWgn1M6CfIA13SuGqOa9Korw==", + "license": "ISC", + "engines": { + "node": ">=14" + }, + "funding": { + "url": "https://github.com/sponsors/isaacs" + } + }, + "node_modules/stdin-discarder": { + "version": "0.2.2", + "resolved": "https://registry.npmjs.org/stdin-discarder/-/stdin-discarder-0.2.2.tgz", + "integrity": "sha512-UhDfHmA92YAlNnCfhmq0VeNL5bDbiZGg7sZ2IvPsXubGkiNa9EC+tUTsjBRsYUAz87btI6/1wf4XoVvQ3uRnmQ==", + "license": "MIT", + "engines": { + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/string_decoder": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.3.0.tgz", + "integrity": "sha512-hkRX8U1WjJFd8LsDJ2yQ/wWWxaopEsABU1XfkM8A+j0+85JAGppt16cr1Whg6KIbb4okU6Mql6BOj+uup/wKeA==", + "license": "MIT", + "dependencies": { + "safe-buffer": "~5.2.0" + } + }, + "node_modules/string-width": { + "version": "4.2.3", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz", + "integrity": "sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==", + "license": "MIT", + "dependencies": { + "emoji-regex": "^8.0.0", + "is-fullwidth-code-point": "^3.0.0", + "strip-ansi": "^6.0.1" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/strip-ansi": { + "version": "6.0.1", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.1.tgz", + "integrity": "sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==", + "license": "MIT", + "dependencies": { + "ansi-regex": "^5.0.1" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/supports-color": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "license": "MIT", + "dependencies": { + "has-flag": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/tinycolor2": { + "version": "1.6.0", + "resolved": "https://registry.npmjs.org/tinycolor2/-/tinycolor2-1.6.0.tgz", + "integrity": "sha512-XPaBkWQJdsf3pLKJV9p4qN/S+fm2Oj8AIPo1BTUhg5oxkvm9+SVEGFdhyOz7tTdUTfvxMiAs4sp6/eZO2Ew+pw==", + "license": "MIT" + }, + "node_modules/tinygradient": { + "version": "1.1.5", + "resolved": "https://registry.npmjs.org/tinygradient/-/tinygradient-1.1.5.tgz", + "integrity": "sha512-8nIfc2vgQ4TeLnk2lFj4tRLvvJwEfQuabdsmvDdQPT0xlk9TaNtpGd6nNRxXoK6vQhN6RSzj+Cnp5tTQmpxmbw==", + "license": "MIT", + "dependencies": { + "@types/tinycolor2": "^1.4.0", + "tinycolor2": "^1.0.0" + } + }, + "node_modules/tslib": { + "version": "2.8.1", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.8.1.tgz", + "integrity": "sha512-oJFu94HQb+KVduSUQL7wnpmqnfmLsOA/nAh6b6EH0wCEoK0/mPeXU6c3wKDV83MkOuHPRHtSXKKU99IBazS/2w==", + "license": "0BSD" + }, + "node_modules/type-fest": { + "version": "0.21.3", + "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.21.3.tgz", + "integrity": "sha512-t0rzBq87m3fVcduHDUFhKmyyX+9eo6WQjZvf51Ea/M0Q7+T374Jp1aUiyUl0GKxp8M/OETVHSDvmkyPgvX+X2w==", + "license": "(MIT OR CC0-1.0)", + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/typescript": { + "version": "5.8.3", + "resolved": "https://registry.npmjs.org/typescript/-/typescript-5.8.3.tgz", + "integrity": "sha512-p1diW6TqL9L07nNxvRMM7hMMw4c5XOo/1ibL4aAIGmSAt9slTE1Xgw5KWuof2uTOvCg9BY7ZRi+GaF+7sfgPeQ==", + "dev": true, + "license": "Apache-2.0", + "bin": { + "tsc": "bin/tsc", + "tsserver": "bin/tsserver" + }, + "engines": { + "node": ">=14.17" + } + }, + "node_modules/undici-types": { + "version": "6.21.0", + "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-6.21.0.tgz", + "integrity": "sha512-iwDZqg0QAGrg9Rav5H4n0M64c3mkR59cJ6wQp+7C4nI0gsmExaedaYLNO44eT4AtBBwjbTiGPMlt2Md0T9H9JQ==", + "devOptional": true, + "license": "MIT" + }, + "node_modules/universalify": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/universalify/-/universalify-2.0.1.tgz", + "integrity": "sha512-gptHNQghINnc/vTGIk0SOFGFNXw7JVrlRUtConJRlvaw6DuX0wO5Jeko9sWrMBhh+PsYAZ7oXAiOnf/UKogyiw==", + "license": "MIT", + "engines": { + "node": ">= 10.0.0" + } + }, + "node_modules/util-deprecate": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz", + "integrity": "sha512-EPD5q1uXyFxJpCrLnCc1nHnq3gOa6DZBocAIiI2TaSCA7VCJ1UJDMagCzIkXNsUYfD1daK//LTEQ8xiIbrHtcw==", + "license": "MIT" + }, + "node_modules/wcwidth": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/wcwidth/-/wcwidth-1.0.1.tgz", + "integrity": "sha512-XHPEwS0q6TaxcvG85+8EYkbiCux2XtWG2mkc47Ng2A77BQu9+DqIOJldST4HgPkuea7dvKSj5VgX3P1d4rW8Tg==", + "license": "MIT", + "dependencies": { + "defaults": "^1.0.3" + } + }, + "node_modules/wrap-ansi": { + "version": "6.2.0", + "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-6.2.0.tgz", + "integrity": "sha512-r6lPcBGxZXlIcymEu7InxDMhdW0KDxpLgoFLcguasxCaJ/SOIZwINatK9KY/tf+ZrlywOKU0UDj3ATXUBfxJXA==", + "license": "MIT", + "dependencies": { + "ansi-styles": "^4.0.0", + "string-width": "^4.1.0", + "strip-ansi": "^6.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/yoctocolors-cjs": { + "version": "2.1.3", + "resolved": "https://registry.npmjs.org/yoctocolors-cjs/-/yoctocolors-cjs-2.1.3.tgz", + "integrity": "sha512-U/PBtDf35ff0D8X8D0jfdzHYEPFxAI7jJlxZXwCSez5M3190m+QobIfh+sWDWSHMCWWJN2AWamkegn6vr6YBTw==", + "license": "MIT", + "engines": { + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + } + } +} diff --git a/packages/dev/create-app/package.json b/packages/dev/create-app/package.json new file mode 100644 index 00000000..6bd333c5 --- /dev/null +++ b/packages/dev/create-app/package.json @@ -0,0 +1,69 @@ +{ + "name": "@bitbybit-dev/create-app", + "version": "0.21.0", + "description": "CLI tool to scaffold Bit By Bit Developers 3D/CAD projects with your favorite game engine", + "type": "module", + "bin": { + "create-bitbybit-app": "./dist/index.js", + "@bitbybit-dev/create-app": "./dist/index.js" + }, + "main": "./dist/index.js", + "files": [ + "dist", + "templates" + ], + "repository": { + "type": "git", + "url": "https://github.com/bitbybit-dev/bitbybit" + }, + "keywords": [ + "Bit By Bit Developers", + "bitbybit", + "bitbybit.dev", + "Geometry", + "CAD", + "3D", + "JSCAD", + "OCCT", + "OpenCascade", + "Creative coding", + "ThreeJS", + "Three.js", + "BabylonJS", + "Babylon.js", + "PlayCanvas", + "Vite", + "scaffolding", + "cli", + "create-app" + ], + "author": "Bit By Bit Developers (https://bitbybit.dev)", + "license": "MIT", + "bugs": { + "url": "https://github.com/bitbybit-dev/bitbybit/issues" + }, + "homepage": "https://bitbybit.dev", + "scripts": { + "build": "tsc", + "dev": "tsc --watch", + "prepublishOnly": "npm run build" + }, + "dependencies": { + "chalk": "^5.3.0", + "commander": "^12.1.0", + "fs-extra": "^11.2.0", + "gradient-string": "^3.0.0", + "inquirer": "^9.3.7", + "ora": "^8.1.1" + }, + "devDependencies": { + "@types/fs-extra": "^11.0.4", + "@types/gradient-string": "^1.1.6", + "@types/inquirer": "^9.0.7", + "@types/node": "^22.10.2", + "typescript": "~5.8.3" + }, + "engines": { + "node": ">=18.0.0" + } +} diff --git a/packages/dev/create-app/src/index.ts b/packages/dev/create-app/src/index.ts new file mode 100644 index 00000000..720a2f8d --- /dev/null +++ b/packages/dev/create-app/src/index.ts @@ -0,0 +1,322 @@ +#!/usr/bin/env node + +import { Command } from "commander"; +import inquirer from "inquirer"; +import chalk from "chalk"; +import gradient from "gradient-string"; +import ora from "ora"; +import fs from "fs-extra"; +import path from "path"; +import { fileURLToPath } from "url"; + +const __filename = fileURLToPath(import.meta.url); +const __dirname = path.dirname(__filename); + +// Simplified, cleaner ASCII logo +const BITBYBIT_LOGO = ` +╭──────────────────────────────────────────────────────────────────────╮ +│ │ +│ ░█▀▄░▀█▀░▀█▀░█▀▄░█░█░█▀▄░▀█▀░▀█▀░░░░░█▀▄░█▀▀░█░█ │ +│ ░█▀▄░░█░░░█░░█▀▄░░█░░█▀▄░░█░░░█░░░░░░█░█░█▀▀░▀▄▀ │ +│ ░▀▀░░▀▀▀░░▀░░▀▀░░░▀░░▀▀░░▀▀▀░░▀░░░▀░░▀▀░░▀▀▀░░▀░ │ +│ │ +│ 3D CAD Development on the Web │ +╰──────────────────────────────────────────────────────────────────────╯ +`; + +interface ProjectOptions { + projectName: string; + engine: "threejs" | "babylonjs" | "playcanvas"; + bundler: "vite"; + language: "typescript"; +} + +type EngineType = "threejs" | "babylonjs" | "playcanvas"; +type BundlerType = "vite"; +type LanguageType = "typescript"; + +const ENGINE_DISPLAY_NAMES: Record = { + "threejs": "Three.js", + "babylonjs": "Babylon.js", + "playcanvas": "PlayCanvas" +}; + +const ENGINE_DESCRIPTIONS: Record = { + "threejs": "Lightweight and flexible 3D library", + "babylonjs": "Powerful and feature-rich game engine", + "playcanvas": "Fast and lightweight WebGL game engine" +}; + +const ENGINE_COLORS: Record string> = { + "threejs": chalk.hex("#049EF4"), // Three.js blue + "babylonjs": chalk.hex("#E0684B"), // Babylon.js red/orange + "playcanvas": chalk.hex("#FF6600") // PlayCanvas orange +}; + +async function displayWelcome(): Promise { + console.clear(); + // Create a beautiful gold gradient for the logo + const goldGradient = gradient(["#F0CEBB", "#fff6f3", "#d6b39f", "#F0CEBB"]); + + console.log(goldGradient(BITBYBIT_LOGO)); + console.log(); + console.log(chalk.gray("─".repeat(72))); + console.log(); + console.log(chalk.white.bold(" Welcome to the Bit By Bit Developers Project Scaffolder! 🚀")); + console.log(); + console.log(chalk.gray(" Create stunning 3D/CAD applications using our powerful")); + console.log(chalk.gray(" geometry kernels: OCCT (OpenCascade), JSCAD, and Manifold.")); + console.log(); + console.log(chalk.gray("─".repeat(72))); + console.log(); + console.log(chalk.cyan(" 🌐 Website: ") + chalk.underline.cyan("https://bitbybit.dev")); + console.log(chalk.yellow(" ⭐ Subscribe: ") + chalk.underline.yellow("https://bitbybit.dev/auth/pick-plan")); + console.log(chalk.gray(" Best way to support us is Silver or Gold plan subscription!")); + console.log(); + console.log(chalk.gray("─".repeat(72))); + console.log(); +} + +async function promptProjectOptions(projectNameArg?: string): Promise { + interface PromptAnswers { + projectName?: string; + engine: EngineType; + } + + let answers: PromptAnswers; + + // Only ask for project name if not provided as argument + if (!projectNameArg) { + answers = await inquirer.prompt([ + { + type: "input", + name: "projectName", + message: chalk.cyan("📁 What is your project name?"), + default: "my-bitbybit-app", + validate: (input: string) => { + if (!input.trim()) { + return "Project name is required"; + } + if (!/^[a-z0-9-_]+$/i.test(input)) { + return "Project name can only contain letters, numbers, hyphens, and underscores"; + } + return true; + } + }, + { + type: "list", + name: "engine", + message: chalk.cyan("🎮 Which 3D engine would you like to use?"), + choices: [ + { + name: `${ENGINE_COLORS["threejs"]("● Three.js")} ${chalk.gray("- Lightweight and popular 3D library")}`, + value: "threejs", + short: "Three.js" + }, + { + name: `${ENGINE_COLORS["babylonjs"]("● Babylon.js")} ${chalk.gray("- Powerful and feature-rich game engine")}`, + value: "babylonjs", + short: "Babylon.js" + }, + { + name: `${ENGINE_COLORS["playcanvas"]("● PlayCanvas")} ${chalk.gray("- Fast and lightweight WebGL game engine")}`, + value: "playcanvas", + short: "PlayCanvas" + } + ], + default: "threejs" + } + ]); + } else { + answers = await inquirer.prompt([ + { + type: "list", + name: "engine", + message: chalk.cyan("🎮 Which 3D engine would you like to use?"), + choices: [ + { + name: `${ENGINE_COLORS["threejs"]("● Three.js")} ${chalk.gray("- Lightweight and flexible 3D library")}`, + value: "threejs", + short: "Three.js" + }, + { + name: `${ENGINE_COLORS["babylonjs"]("● Babylon.js")} ${chalk.gray("- Powerful and feature-rich game engine")}`, + value: "babylonjs", + short: "Babylon.js" + }, + { + name: `${ENGINE_COLORS["playcanvas"]("● PlayCanvas")} ${chalk.gray("- Fast and lightweight WebGL game engine")}`, + value: "playcanvas", + short: "PlayCanvas" + } + ], + default: "threejs" + } + ]); + } + + return { + projectName: projectNameArg || answers.projectName!, + engine: answers.engine, + bundler: "vite", + language: "typescript" + }; +} + +async function createProject(options: ProjectOptions): Promise { + const { projectName, engine, bundler, language } = options; + const targetDir = path.resolve(process.cwd(), projectName); + + console.log(); + console.log(chalk.gray("─".repeat(72))); + console.log(); + console.log(chalk.white.bold(" 📋 Project Configuration:")); + console.log(); + console.log(` ${chalk.gray("Project:")} ${chalk.white.bold(projectName)}`); + console.log(` ${chalk.gray("Engine:")} ${ENGINE_COLORS[engine](ENGINE_DISPLAY_NAMES[engine])}`); + console.log(` ${chalk.gray("Bundler:")} ${chalk.magenta("Vite")}`); + console.log(` ${chalk.gray("Language:")} ${chalk.blue("TypeScript")}`); + console.log(); + console.log(chalk.gray("─".repeat(72))); + console.log(); + + // Check if directory exists + if (fs.existsSync(targetDir)) { + const { overwrite } = await inquirer.prompt([ + { + type: "confirm", + name: "overwrite", + message: chalk.yellow(`⚠️ Directory "${projectName}" already exists. Do you want to overwrite it?`), + default: false + } + ]); + + if (!overwrite) { + console.log(chalk.red("\n ✖ Project creation cancelled.\n")); + process.exit(0); + } + + const spinner = ora("Removing existing directory...").start(); + await fs.remove(targetDir); + spinner.succeed("Existing directory removed"); + } + + // Create project directory + const spinner = ora({ + text: "Creating project structure...", + color: "cyan" + }).start(); + + try { + // Copy template files + const templateDir = path.join(__dirname, "..", "templates", bundler, engine, language); + + if (!fs.existsSync(templateDir)) { + spinner.fail("Template not found"); + console.error(chalk.red(`\n ✖ Template for ${bundler}/${engine}/${language} not found.`)); + console.error(chalk.gray(` Looking in: ${templateDir}`)); + process.exit(1); + } + + await fs.copy(templateDir, targetDir); + spinner.succeed("Project structure created"); + + // Update package.json with project name + const packageJsonPath = path.join(targetDir, "package.json"); + if (fs.existsSync(packageJsonPath)) { + const packageJson = await fs.readJson(packageJsonPath); + packageJson.name = projectName; + await fs.writeJson(packageJsonPath, packageJson, { spaces: 2 }); + } + + // Success message + console.log(); + console.log(chalk.gray("─".repeat(72))); + console.log(); + console.log(chalk.gray(" Home: ") + chalk.underline.cyan("https://bitbybit.dev")); + console.log(chalk.gray(" Learn: ") + chalk.underline.cyan("https://learn.bitbybit.dev")); + console.log(chalk.gray(" Blog: ") + chalk.underline.cyan("https://learn.bitbybit.dev/blog")); + console.log(chalk.gray(" Documentation: ") + chalk.underline.cyan("https://docs.bitbybit.dev")); + console.log(chalk.gray(" Community: ") + chalk.underline.cyan("https://discord.gg/GSe3VMe")); + console.log(chalk.gray(" GitHub: ") + chalk.underline.cyan("https://github.com/bitbybit-dev/bitbybit")); + console.log(chalk.gray(" LinkedIn: ") + chalk.underline.cyan("https://www.linkedin.com/company/bitbybit-dev/")); + console.log(chalk.gray(" X: ") + chalk.underline.cyan("https://x.com/bitbybit_dev")); + console.log(chalk.gray(" YouTube: ") + chalk.underline.cyan("https://www.youtube.com/@bitbybitdev")); + console.log(chalk.gray(" Facebook: ") + chalk.underline.cyan("https://www.facebook.com/bitbybitdev")); + console.log(); + console.log(chalk.green.bold(" ✔ Project created successfully! 🎉")); + console.log(); + console.log(chalk.white(" Next steps:")); + console.log(); + console.log(chalk.gray(" 1. Navigate to your project:")); + console.log(chalk.cyan(` cd ${projectName}`)); + console.log(); + console.log(chalk.gray(" 2. Install dependencies:")); + console.log(chalk.cyan(" npm install")); + console.log(); + console.log(chalk.gray(" 3. Start the development server:")); + console.log(chalk.cyan(" npm run dev")); + console.log(); + console.log(chalk.gray("─".repeat(72))); + console.log(); + console.log(chalk.yellow.bold(" ⭐ Support Bit By Bit Developers with a Silver or Gold subscription:")); + console.log(chalk.yellow.italic(" https://bitbybit.dev/auth/pick-plan")); + console.log(); + console.log(chalk.gray("─".repeat(72))); + console.log(); + console.log(chalk.white(" Happy coding! 💻✨")); + console.log(); + + } catch (error) { + spinner.fail("Failed to create project"); + console.error(chalk.red("\n ✖ Error creating project:"), error); + process.exit(1); + } +} + +async function main(): Promise { + const program = new Command(); + + program + .name("@bitbybit-dev/create-app") + .description("Scaffold a new Bit By Bit Developers 3D/CAD project") + .version("0.21.0") + .argument("[project-name]", "Name of the project to create") + .option("-e, --engine ", "Game engine to use (threejs, babylonjs, playcanvas)") + .action(async (projectName: string | undefined, cmdOptions: { engine?: string }) => { + await displayWelcome(); + + let options: ProjectOptions; + + // If engine is provided via CLI, validate it + if (cmdOptions.engine) { + const validEngines = ["threejs", "babylonjs", "playcanvas"]; + if (!validEngines.includes(cmdOptions.engine)) { + console.error(chalk.red(`\n ✖ Invalid engine: ${cmdOptions.engine}`)); + console.error(chalk.gray(` Valid options: ${validEngines.join(", ")}`)); + process.exit(1); + } + } + + // If both project name and engine are provided, skip prompts + if (projectName && cmdOptions.engine) { + options = { + projectName, + engine: cmdOptions.engine as EngineType, + bundler: "vite", + language: "typescript" + }; + } else { + options = await promptProjectOptions(projectName); + } + + await createProject(options); + }); + + await program.parseAsync(process.argv); +} + +main().catch((error) => { + console.error(chalk.red("\n ✖ Unexpected error:"), error); + process.exit(1); +}); diff --git a/packages/dev/create-app/templates/vite/babylonjs/typescript/index.html b/packages/dev/create-app/templates/vite/babylonjs/typescript/index.html new file mode 100644 index 00000000..a7ebf93b --- /dev/null +++ b/packages/dev/create-app/templates/vite/babylonjs/typescript/index.html @@ -0,0 +1,27 @@ + + + + + + + Bitbybit & Babylon.js Project + + + + + + + diff --git a/packages/dev/create-app/templates/vite/babylonjs/typescript/package.json b/packages/dev/create-app/templates/vite/babylonjs/typescript/package.json new file mode 100644 index 00000000..26d22948 --- /dev/null +++ b/packages/dev/create-app/templates/vite/babylonjs/typescript/package.json @@ -0,0 +1,18 @@ +{ + "name": "bitbybit-babylonjs-app", + "private": true, + "version": "0.0.0", + "type": "module", + "scripts": { + "dev": "vite", + "build": "tsc && vite build", + "preview": "vite preview" + }, + "dependencies": { + "@bitbybit-dev/babylonjs": "0.21.0" + }, + "devDependencies": { + "typescript": "~5.8.3", + "vite": "^6.3.2" + } +} diff --git a/packages/dev/create-app/templates/vite/babylonjs/typescript/public/vite.svg b/packages/dev/create-app/templates/vite/babylonjs/typescript/public/vite.svg new file mode 100644 index 00000000..6a410991 --- /dev/null +++ b/packages/dev/create-app/templates/vite/babylonjs/typescript/public/vite.svg @@ -0,0 +1 @@ + diff --git a/packages/dev/create-app/templates/vite/babylonjs/typescript/src/main.ts b/packages/dev/create-app/templates/vite/babylonjs/typescript/src/main.ts new file mode 100644 index 00000000..b43df7a3 --- /dev/null +++ b/packages/dev/create-app/templates/vite/babylonjs/typescript/src/main.ts @@ -0,0 +1,121 @@ +import "./style.css"; +import { BitByBitBase, Inputs, initBitByBit, initBabylonJS, type InitBitByBitOptions } from "@bitbybit-dev/babylonjs"; + +start(); + +async function start() { + const sceneOptions = new Inputs.BabylonJSScene.InitBabylonJSDto(); + sceneOptions.canvasId = "babylon-canvas"; + sceneOptions.sceneSize = 10; + sceneOptions.enableShadows = true; + sceneOptions.enableGround = true; + sceneOptions.groundColor = "#333333"; + + const { scene, engine } = initBabylonJS(sceneOptions); + const bitbybit = new BitByBitBase(); + const options: InitBitByBitOptions = { + enableOCCT: true, + enableJSCAD: true, + enableManifold: true, + }; + + await initBitByBit(scene, bitbybit, options); + + if (options.enableOCCT) { + await createOCCTGeometry(bitbybit, "#ff0000"); + } + if (options.enableManifold) { + await createManifoldGeometry(bitbybit, "#00ff00"); + } + if (options.enableJSCAD) { + await createJSCADGeometry(bitbybit, "#0000ff"); + } + + engine.runRenderLoop(() => { + if (scene.activeCamera) { + scene.render(); + } + }); +} + +async function createOCCTGeometry(bitbybit: BitByBitBase, color: string) { + const cubeOptions = new Inputs.OCCT.CubeDto(); + cubeOptions.size = 2.5; + cubeOptions.center = [0, 1.25, 0]; + + const cube = await bitbybit.occt.shapes.solid.createCube(cubeOptions); + + const filletOptions = + new Inputs.OCCT.FilletDto(); + filletOptions.shape = cube; + filletOptions.radius = 0.4; + const roundedCube = await bitbybit.occt.fillets.filletEdges(filletOptions); + + const drawOptions = new Inputs.Draw.DrawOcctShapeOptions(); + drawOptions.edgeWidth = 0.5; + drawOptions.faceColour = color; + drawOptions.drawVertices = true; + drawOptions.vertexSize = 0.05; + drawOptions.vertexColour = "#ffffff"; + await bitbybit.draw.drawAnyAsync({ + entity: roundedCube, + options: drawOptions, + }); +} + +async function createManifoldGeometry(bitbybit: BitByBitBase, color: string) { + const sphereOptions = new Inputs.Manifold.SphereDto(); + sphereOptions.radius = 1.5; + sphereOptions.circularSegments = 32; + const sphere = await bitbybit.manifold.manifold.shapes.sphere(sphereOptions); + + const cubeOptions = new Inputs.Manifold.CubeDto(); + cubeOptions.size = 2.5; + const cube = await bitbybit.manifold.manifold.shapes.cube(cubeOptions); + + const diffedShape = await bitbybit.manifold.manifold.booleans.differenceTwo({ + manifold1: cube, + manifold2: sphere, + }); + + const translationOptions = + new Inputs.Manifold.TranslateDto(); + translationOptions.manifold = diffedShape; + translationOptions.vector = [0, 1.25, -4]; // Position below OCCT + const movedShape = await bitbybit.manifold.manifold.transforms.translate( + translationOptions + ); + + const drawOptions = new Inputs.Draw.DrawManifoldOrCrossSectionOptions(); + drawOptions.faceColour = color; + await bitbybit.draw.drawAnyAsync({ + entity: movedShape, + options: drawOptions, + }); +} + +async function createJSCADGeometry(bitbybit: BitByBitBase, color: string) { + const geodesicSphereOptions = new Inputs.JSCAD.GeodesicSphereDto(); + geodesicSphereOptions.radius = 1.5; + geodesicSphereOptions.center = [0, 1.5, 4]; + const geodesicSphere = await bitbybit.jscad.shapes.geodesicSphere( + geodesicSphereOptions + ); + + const sphereOptions = new Inputs.JSCAD.SphereDto(); + sphereOptions.radius = 1; + sphereOptions.center = [0, 3, 4.5]; + const simpleSphere = await bitbybit.jscad.shapes.sphere(sphereOptions); + + const unionOptions = new Inputs.JSCAD.BooleanTwoObjectsDto(); + unionOptions.first = geodesicSphere; + unionOptions.second = simpleSphere; + const unionShape = await bitbybit.jscad.booleans.unionTwo(unionOptions); + + const drawOptions = new Inputs.Draw.DrawBasicGeometryOptions(); + drawOptions.colours = color; + await bitbybit.draw.drawAnyAsync({ + entity: unionShape, + options: drawOptions, + }); +} diff --git a/packages/dev/create-app/templates/vite/babylonjs/typescript/src/style.css b/packages/dev/create-app/templates/vite/babylonjs/typescript/src/style.css new file mode 100644 index 00000000..681677f6 --- /dev/null +++ b/packages/dev/create-app/templates/vite/babylonjs/typescript/src/style.css @@ -0,0 +1,31 @@ +body { + margin: 0px; + overflow: hidden; +} + +#babylon-canvas { + outline: none; + width: 100%; + height: 100vh; +} + +a.logo { + position: absolute; + color: white; + vertical-align: middle; + bottom: 10px; + left: 10px; + font-family: 'Courier New', Courier, monospace; + text-decoration: none; + width: 100%; +} + +.logo { + margin-bottom: 20px; + text-align: center; +} + +.logo img { + width: 50px; + height: 50px; +} diff --git a/packages/dev/create-app/templates/vite/babylonjs/typescript/src/vite-env.d.ts b/packages/dev/create-app/templates/vite/babylonjs/typescript/src/vite-env.d.ts new file mode 100644 index 00000000..11f02fe2 --- /dev/null +++ b/packages/dev/create-app/templates/vite/babylonjs/typescript/src/vite-env.d.ts @@ -0,0 +1 @@ +/// diff --git a/packages/dev/create-app/templates/vite/babylonjs/typescript/tsconfig.json b/packages/dev/create-app/templates/vite/babylonjs/typescript/tsconfig.json new file mode 100644 index 00000000..a22caba9 --- /dev/null +++ b/packages/dev/create-app/templates/vite/babylonjs/typescript/tsconfig.json @@ -0,0 +1,25 @@ +{ + "compilerOptions": { + "target": "ES2020", + "useDefineForClassFields": true, + "module": "ESNext", + "lib": ["ES2020", "DOM", "DOM.Iterable"], + "skipLibCheck": true, + + /* Bundler mode */ + "moduleResolution": "bundler", + "allowImportingTsExtensions": true, + "verbatimModuleSyntax": true, + "moduleDetection": "force", + "noEmit": true, + + /* Linting */ + "strict": true, + "noUnusedLocals": true, + "noUnusedParameters": true, + "erasableSyntaxOnly": true, + "noFallthroughCasesInSwitch": true, + "noUncheckedSideEffectImports": true + }, + "include": ["src"] +} diff --git a/packages/dev/create-app/templates/vite/playcanvas/typescript/index.html b/packages/dev/create-app/templates/vite/playcanvas/typescript/index.html new file mode 100644 index 00000000..253a4ed3 --- /dev/null +++ b/packages/dev/create-app/templates/vite/playcanvas/typescript/index.html @@ -0,0 +1,27 @@ + + + + + + + Bitbybit & PlayCanvas Project + + + + + + + diff --git a/packages/dev/create-app/templates/vite/playcanvas/typescript/package.json b/packages/dev/create-app/templates/vite/playcanvas/typescript/package.json new file mode 100644 index 00000000..659893b5 --- /dev/null +++ b/packages/dev/create-app/templates/vite/playcanvas/typescript/package.json @@ -0,0 +1,19 @@ +{ + "name": "bitbybit-playcanvas-app", + "private": true, + "version": "0.0.0", + "type": "module", + "scripts": { + "dev": "vite", + "build": "tsc && vite build", + "preview": "vite preview" + }, + "dependencies": { + "@bitbybit-dev/playcanvas": "0.21.0", + "playcanvas": "2.14.4" + }, + "devDependencies": { + "typescript": "~5.8.3", + "vite": "^6.3.2" + } +} diff --git a/packages/dev/create-app/templates/vite/playcanvas/typescript/public/vite.svg b/packages/dev/create-app/templates/vite/playcanvas/typescript/public/vite.svg new file mode 100644 index 00000000..6a410991 --- /dev/null +++ b/packages/dev/create-app/templates/vite/playcanvas/typescript/public/vite.svg @@ -0,0 +1 @@ + diff --git a/packages/dev/create-app/templates/vite/playcanvas/typescript/src/main.ts b/packages/dev/create-app/templates/vite/playcanvas/typescript/src/main.ts new file mode 100644 index 00000000..f74ec559 --- /dev/null +++ b/packages/dev/create-app/templates/vite/playcanvas/typescript/src/main.ts @@ -0,0 +1,114 @@ +import "./style.css"; +import { BitByBitBase, Inputs, initBitByBit, initPlayCanvas, type InitBitByBitOptions } from "@bitbybit-dev/playcanvas"; + + +start(); + +async function start() { + const sceneOptions = new Inputs.PlayCanvasScene.InitPlayCanvasDto(); + sceneOptions.canvasId = "playcanvas-canvas"; + sceneOptions.sceneSize = 10; + const { scene, app } = initPlayCanvas(sceneOptions); + const bitbybit = new BitByBitBase(); + + const options: InitBitByBitOptions = { + enableOCCT: true, + enableJSCAD: true, + enableManifold: true, + }; + + await initBitByBit(app, scene, bitbybit, options); + + if (options.enableOCCT) { + await createOCCTGeometry(bitbybit, "#ff0000"); // Red + } + if (options.enableManifold) { + await createManifoldGeometry(bitbybit, "#00ff00"); // Green + } + if (options.enableJSCAD) { + await createJSCADGeometry(bitbybit, "#0000ff"); // Blue + } + +} + +async function createOCCTGeometry(bitbybit: BitByBitBase, color: string) { + const cubeOptions = new Inputs.OCCT.CubeDto(); + cubeOptions.size = 2.5; + cubeOptions.center = [0, 1.25, 0]; + + const cube = await bitbybit.occt.shapes.solid.createCube(cubeOptions); + + const filletOptions = + new Inputs.OCCT.FilletDto(); + filletOptions.shape = cube; + filletOptions.radius = 0.4; + const roundedCube = await bitbybit.occt.fillets.filletEdges(filletOptions); + + const drawOptions = new Inputs.Draw.DrawOcctShapeOptions(); + drawOptions.edgeWidth = 0.5; + drawOptions.faceColour = color; + drawOptions.drawVertices = true; + drawOptions.vertexSize = 0.05; + drawOptions.vertexColour = "#ffffff"; + await bitbybit.draw.drawAnyAsync({ + entity: roundedCube, + options: drawOptions, + }); +} + +async function createManifoldGeometry(bitbybit: BitByBitBase, color: string) { + const sphereOptions = new Inputs.Manifold.SphereDto(); + sphereOptions.radius = 1.5; + sphereOptions.circularSegments = 32; + const sphere = await bitbybit.manifold.manifold.shapes.sphere(sphereOptions); + + const cubeOptions = new Inputs.Manifold.CubeDto(); + cubeOptions.size = 2.5; + const cube = await bitbybit.manifold.manifold.shapes.cube(cubeOptions); + + const diffedShape = await bitbybit.manifold.manifold.booleans.differenceTwo({ + manifold1: cube, + manifold2: sphere, + }); + + const translationOptions = + new Inputs.Manifold.TranslateDto(); + translationOptions.manifold = diffedShape; + translationOptions.vector = [0, 1.25, -4]; // Position below OCCT + const movedShape = await bitbybit.manifold.manifold.transforms.translate( + translationOptions + ); + + const drawOptions = new Inputs.Draw.DrawManifoldOrCrossSectionOptions(); + drawOptions.faceColour = color; + await bitbybit.draw.drawAnyAsync({ + entity: movedShape, + options: drawOptions, + }); +} + +async function createJSCADGeometry(bitbybit: BitByBitBase, color: string) { + const geodesicSphereOptions = new Inputs.JSCAD.GeodesicSphereDto(); + geodesicSphereOptions.radius = 1.5; + geodesicSphereOptions.center = [0, 1.5, 4]; + const geodesicSphere = await bitbybit.jscad.shapes.geodesicSphere( + geodesicSphereOptions + ); + + const sphereOptions = new Inputs.JSCAD.SphereDto(); + sphereOptions.radius = 1; + sphereOptions.center = [0, 3, 4.5]; + const simpleSphere = await bitbybit.jscad.shapes.sphere(sphereOptions); + + const unionOptions = new Inputs.JSCAD.BooleanTwoObjectsDto(); + unionOptions.first = geodesicSphere; + unionOptions.second = simpleSphere; + const unionShape = await bitbybit.jscad.booleans.unionTwo(unionOptions); + + const drawOptions = new Inputs.Draw.DrawBasicGeometryOptions(); + drawOptions.colours = color; + await bitbybit.draw.drawAnyAsync({ + entity: unionShape, + options: drawOptions, + }); +} diff --git a/packages/dev/create-app/templates/vite/playcanvas/typescript/src/style.css b/packages/dev/create-app/templates/vite/playcanvas/typescript/src/style.css new file mode 100644 index 00000000..72e40599 --- /dev/null +++ b/packages/dev/create-app/templates/vite/playcanvas/typescript/src/style.css @@ -0,0 +1,25 @@ +body { + margin: 0px; + overflow: hidden; +} + +a.logo { + position: absolute; + color: white; + vertical-align: middle; + bottom: 10px; + left: 10px; + font-family: 'Courier New', Courier, monospace; + text-decoration: none; + width: 100%; +} + +.logo { + margin-bottom: 20px; + text-align: center; +} + +.logo img { + width: 50px; + height: 50px; +} diff --git a/packages/dev/create-app/templates/vite/playcanvas/typescript/src/vite-env.d.ts b/packages/dev/create-app/templates/vite/playcanvas/typescript/src/vite-env.d.ts new file mode 100644 index 00000000..11f02fe2 --- /dev/null +++ b/packages/dev/create-app/templates/vite/playcanvas/typescript/src/vite-env.d.ts @@ -0,0 +1 @@ +/// diff --git a/packages/dev/create-app/templates/vite/playcanvas/typescript/tsconfig.json b/packages/dev/create-app/templates/vite/playcanvas/typescript/tsconfig.json new file mode 100644 index 00000000..a22caba9 --- /dev/null +++ b/packages/dev/create-app/templates/vite/playcanvas/typescript/tsconfig.json @@ -0,0 +1,25 @@ +{ + "compilerOptions": { + "target": "ES2020", + "useDefineForClassFields": true, + "module": "ESNext", + "lib": ["ES2020", "DOM", "DOM.Iterable"], + "skipLibCheck": true, + + /* Bundler mode */ + "moduleResolution": "bundler", + "allowImportingTsExtensions": true, + "verbatimModuleSyntax": true, + "moduleDetection": "force", + "noEmit": true, + + /* Linting */ + "strict": true, + "noUnusedLocals": true, + "noUnusedParameters": true, + "erasableSyntaxOnly": true, + "noFallthroughCasesInSwitch": true, + "noUncheckedSideEffectImports": true + }, + "include": ["src"] +} diff --git a/packages/dev/create-app/templates/vite/threejs/typescript/index.html b/packages/dev/create-app/templates/vite/threejs/typescript/index.html new file mode 100644 index 00000000..af0cb7ac --- /dev/null +++ b/packages/dev/create-app/templates/vite/threejs/typescript/index.html @@ -0,0 +1,27 @@ + + + + + + + Bitbybit & Three.js Project + + + + + + + diff --git a/packages/dev/create-app/templates/vite/threejs/typescript/package.json b/packages/dev/create-app/templates/vite/threejs/typescript/package.json new file mode 100644 index 00000000..615358cc --- /dev/null +++ b/packages/dev/create-app/templates/vite/threejs/typescript/package.json @@ -0,0 +1,19 @@ +{ + "name": "bitbybit-threejs-app", + "private": true, + "version": "0.0.0", + "type": "module", + "scripts": { + "dev": "vite", + "build": "tsc && vite build", + "preview": "vite preview" + }, + "dependencies": { + "@bitbybit-dev/threejs": "0.21.0" + }, + "devDependencies": { + "typescript": "~5.8.3", + "vite": "^6.3.2", + "@types/three": "0.182.0" + } +} diff --git a/packages/dev/create-app/templates/vite/threejs/typescript/public/vite.svg b/packages/dev/create-app/templates/vite/threejs/typescript/public/vite.svg new file mode 100644 index 00000000..6a410991 --- /dev/null +++ b/packages/dev/create-app/templates/vite/threejs/typescript/public/vite.svg @@ -0,0 +1 @@ + diff --git a/packages/dev/create-app/templates/vite/threejs/typescript/src/main.ts b/packages/dev/create-app/templates/vite/threejs/typescript/src/main.ts new file mode 100644 index 00000000..c15e156c --- /dev/null +++ b/packages/dev/create-app/templates/vite/threejs/typescript/src/main.ts @@ -0,0 +1,115 @@ +import "./style.css"; +import { BitByBitBase, Inputs, initBitByBit, initThreeJS, type InitBitByBitOptions } from "@bitbybit-dev/threejs"; + + +start(); + +async function start() { + const sceneOptions = new Inputs.ThreeJSScene.InitThreeJSDto(); + sceneOptions.canvasId = "three-canvas"; + sceneOptions.sceneSize = 10; + const { scene, startAnimationLoop } = initThreeJS(sceneOptions); + startAnimationLoop(); + const bitbybit = new BitByBitBase(); + + const options: InitBitByBitOptions = { + enableOCCT: true, + enableJSCAD: true, + enableManifold: true, + }; + + await initBitByBit(scene, bitbybit, options); + + if (options.enableOCCT) { + await createOCCTGeometry(bitbybit, "#ff0000"); // Red + } + if (options.enableManifold) { + await createManifoldGeometry(bitbybit, "#00ff00"); // Green + } + if (options.enableJSCAD) { + await createJSCADGeometry(bitbybit, "#0000ff"); // Blue + } + +} + +async function createOCCTGeometry(bitbybit: BitByBitBase, color: string) { + const cubeOptions = new Inputs.OCCT.CubeDto(); + cubeOptions.size = 2.5; + cubeOptions.center = [0, 1.25, 0]; + + const cube = await bitbybit.occt.shapes.solid.createCube(cubeOptions); + + const filletOptions = + new Inputs.OCCT.FilletDto(); + filletOptions.shape = cube; + filletOptions.radius = 0.4; + const roundedCube = await bitbybit.occt.fillets.filletEdges(filletOptions); + + const drawOptions = new Inputs.Draw.DrawOcctShapeOptions(); + drawOptions.edgeWidth = 0.5; + drawOptions.faceColour = color; + drawOptions.drawVertices = true; + drawOptions.vertexSize = 0.05; + drawOptions.vertexColour = "#ffffff"; + await bitbybit.draw.drawAnyAsync({ + entity: roundedCube, + options: drawOptions, + }); +} + +async function createManifoldGeometry(bitbybit: BitByBitBase, color: string) { + const sphereOptions = new Inputs.Manifold.SphereDto(); + sphereOptions.radius = 1.5; + sphereOptions.circularSegments = 32; + const sphere = await bitbybit.manifold.manifold.shapes.sphere(sphereOptions); + + const cubeOptions = new Inputs.Manifold.CubeDto(); + cubeOptions.size = 2.5; + const cube = await bitbybit.manifold.manifold.shapes.cube(cubeOptions); + + const diffedShape = await bitbybit.manifold.manifold.booleans.differenceTwo({ + manifold1: cube, + manifold2: sphere, + }); + + const translationOptions = + new Inputs.Manifold.TranslateDto(); + translationOptions.manifold = diffedShape; + translationOptions.vector = [0, 1.25, -4]; // Position below OCCT + const movedShape = await bitbybit.manifold.manifold.transforms.translate( + translationOptions + ); + + const drawOptions = new Inputs.Draw.DrawManifoldOrCrossSectionOptions(); + drawOptions.faceColour = color; + await bitbybit.draw.drawAnyAsync({ + entity: movedShape, + options: drawOptions, + }); +} + +async function createJSCADGeometry(bitbybit: BitByBitBase, color: string) { + const geodesicSphereOptions = new Inputs.JSCAD.GeodesicSphereDto(); + geodesicSphereOptions.radius = 1.5; + geodesicSphereOptions.center = [0, 1.5, 4]; + const geodesicSphere = await bitbybit.jscad.shapes.geodesicSphere( + geodesicSphereOptions + ); + + const sphereOptions = new Inputs.JSCAD.SphereDto(); + sphereOptions.radius = 1; + sphereOptions.center = [0, 3, 4.5]; + const simpleSphere = await bitbybit.jscad.shapes.sphere(sphereOptions); + + const unionOptions = new Inputs.JSCAD.BooleanTwoObjectsDto(); + unionOptions.first = geodesicSphere; + unionOptions.second = simpleSphere; + const unionShape = await bitbybit.jscad.booleans.unionTwo(unionOptions); + + const drawOptions = new Inputs.Draw.DrawBasicGeometryOptions(); + drawOptions.colours = color; + await bitbybit.draw.drawAnyAsync({ + entity: unionShape, + options: drawOptions, + }); +} diff --git a/packages/dev/create-app/templates/vite/threejs/typescript/src/style.css b/packages/dev/create-app/templates/vite/threejs/typescript/src/style.css new file mode 100644 index 00000000..72e40599 --- /dev/null +++ b/packages/dev/create-app/templates/vite/threejs/typescript/src/style.css @@ -0,0 +1,25 @@ +body { + margin: 0px; + overflow: hidden; +} + +a.logo { + position: absolute; + color: white; + vertical-align: middle; + bottom: 10px; + left: 10px; + font-family: 'Courier New', Courier, monospace; + text-decoration: none; + width: 100%; +} + +.logo { + margin-bottom: 20px; + text-align: center; +} + +.logo img { + width: 50px; + height: 50px; +} diff --git a/packages/dev/create-app/templates/vite/threejs/typescript/src/vite-env.d.ts b/packages/dev/create-app/templates/vite/threejs/typescript/src/vite-env.d.ts new file mode 100644 index 00000000..11f02fe2 --- /dev/null +++ b/packages/dev/create-app/templates/vite/threejs/typescript/src/vite-env.d.ts @@ -0,0 +1 @@ +/// diff --git a/packages/dev/create-app/templates/vite/threejs/typescript/tsconfig.json b/packages/dev/create-app/templates/vite/threejs/typescript/tsconfig.json new file mode 100644 index 00000000..a22caba9 --- /dev/null +++ b/packages/dev/create-app/templates/vite/threejs/typescript/tsconfig.json @@ -0,0 +1,25 @@ +{ + "compilerOptions": { + "target": "ES2020", + "useDefineForClassFields": true, + "module": "ESNext", + "lib": ["ES2020", "DOM", "DOM.Iterable"], + "skipLibCheck": true, + + /* Bundler mode */ + "moduleResolution": "bundler", + "allowImportingTsExtensions": true, + "verbatimModuleSyntax": true, + "moduleDetection": "force", + "noEmit": true, + + /* Linting */ + "strict": true, + "noUnusedLocals": true, + "noUnusedParameters": true, + "erasableSyntaxOnly": true, + "noFallthroughCasesInSwitch": true, + "noUncheckedSideEffectImports": true + }, + "include": ["src"] +} diff --git a/packages/dev/create-app/tsconfig.json b/packages/dev/create-app/tsconfig.json new file mode 100644 index 00000000..7bc67782 --- /dev/null +++ b/packages/dev/create-app/tsconfig.json @@ -0,0 +1,20 @@ +{ + "compilerOptions": { + "target": "ES2022", + "module": "NodeNext", + "moduleResolution": "NodeNext", + "lib": ["ES2022"], + "outDir": "./dist", + "rootDir": "./src", + "strict": true, + "esModuleInterop": true, + "skipLibCheck": true, + "forceConsistentCasingInFileNames": true, + "resolveJsonModule": true, + "declaration": true, + "declarationMap": true, + "sourceMap": true + }, + "include": ["src/**/*"], + "exclude": ["node_modules", "dist", "templates"] +} diff --git a/packages/dev/tmp/test-app/index.html b/packages/dev/tmp/test-app/index.html new file mode 100644 index 00000000..253a4ed3 --- /dev/null +++ b/packages/dev/tmp/test-app/index.html @@ -0,0 +1,27 @@ + + + + + + + Bitbybit & PlayCanvas Project + + + + + + + diff --git a/packages/dev/tmp/test-app/package.json b/packages/dev/tmp/test-app/package.json new file mode 100644 index 00000000..6120f3c9 --- /dev/null +++ b/packages/dev/tmp/test-app/package.json @@ -0,0 +1,19 @@ +{ + "name": "test-app", + "private": true, + "version": "0.0.0", + "type": "module", + "scripts": { + "dev": "vite", + "build": "tsc && vite build", + "preview": "vite preview" + }, + "dependencies": { + "@bitbybit-dev/playcanvas": "0.21.0", + "playcanvas": "2.14.4" + }, + "devDependencies": { + "typescript": "~5.8.3", + "vite": "^6.3.2" + } +} diff --git a/packages/dev/tmp/test-app/public/vite.svg b/packages/dev/tmp/test-app/public/vite.svg new file mode 100644 index 00000000..6a410991 --- /dev/null +++ b/packages/dev/tmp/test-app/public/vite.svg @@ -0,0 +1 @@ + diff --git a/packages/dev/tmp/test-app/src/main.ts b/packages/dev/tmp/test-app/src/main.ts new file mode 100644 index 00000000..f74ec559 --- /dev/null +++ b/packages/dev/tmp/test-app/src/main.ts @@ -0,0 +1,114 @@ +import "./style.css"; +import { BitByBitBase, Inputs, initBitByBit, initPlayCanvas, type InitBitByBitOptions } from "@bitbybit-dev/playcanvas"; + + +start(); + +async function start() { + const sceneOptions = new Inputs.PlayCanvasScene.InitPlayCanvasDto(); + sceneOptions.canvasId = "playcanvas-canvas"; + sceneOptions.sceneSize = 10; + const { scene, app } = initPlayCanvas(sceneOptions); + const bitbybit = new BitByBitBase(); + + const options: InitBitByBitOptions = { + enableOCCT: true, + enableJSCAD: true, + enableManifold: true, + }; + + await initBitByBit(app, scene, bitbybit, options); + + if (options.enableOCCT) { + await createOCCTGeometry(bitbybit, "#ff0000"); // Red + } + if (options.enableManifold) { + await createManifoldGeometry(bitbybit, "#00ff00"); // Green + } + if (options.enableJSCAD) { + await createJSCADGeometry(bitbybit, "#0000ff"); // Blue + } + +} + +async function createOCCTGeometry(bitbybit: BitByBitBase, color: string) { + const cubeOptions = new Inputs.OCCT.CubeDto(); + cubeOptions.size = 2.5; + cubeOptions.center = [0, 1.25, 0]; + + const cube = await bitbybit.occt.shapes.solid.createCube(cubeOptions); + + const filletOptions = + new Inputs.OCCT.FilletDto(); + filletOptions.shape = cube; + filletOptions.radius = 0.4; + const roundedCube = await bitbybit.occt.fillets.filletEdges(filletOptions); + + const drawOptions = new Inputs.Draw.DrawOcctShapeOptions(); + drawOptions.edgeWidth = 0.5; + drawOptions.faceColour = color; + drawOptions.drawVertices = true; + drawOptions.vertexSize = 0.05; + drawOptions.vertexColour = "#ffffff"; + await bitbybit.draw.drawAnyAsync({ + entity: roundedCube, + options: drawOptions, + }); +} + +async function createManifoldGeometry(bitbybit: BitByBitBase, color: string) { + const sphereOptions = new Inputs.Manifold.SphereDto(); + sphereOptions.radius = 1.5; + sphereOptions.circularSegments = 32; + const sphere = await bitbybit.manifold.manifold.shapes.sphere(sphereOptions); + + const cubeOptions = new Inputs.Manifold.CubeDto(); + cubeOptions.size = 2.5; + const cube = await bitbybit.manifold.manifold.shapes.cube(cubeOptions); + + const diffedShape = await bitbybit.manifold.manifold.booleans.differenceTwo({ + manifold1: cube, + manifold2: sphere, + }); + + const translationOptions = + new Inputs.Manifold.TranslateDto(); + translationOptions.manifold = diffedShape; + translationOptions.vector = [0, 1.25, -4]; // Position below OCCT + const movedShape = await bitbybit.manifold.manifold.transforms.translate( + translationOptions + ); + + const drawOptions = new Inputs.Draw.DrawManifoldOrCrossSectionOptions(); + drawOptions.faceColour = color; + await bitbybit.draw.drawAnyAsync({ + entity: movedShape, + options: drawOptions, + }); +} + +async function createJSCADGeometry(bitbybit: BitByBitBase, color: string) { + const geodesicSphereOptions = new Inputs.JSCAD.GeodesicSphereDto(); + geodesicSphereOptions.radius = 1.5; + geodesicSphereOptions.center = [0, 1.5, 4]; + const geodesicSphere = await bitbybit.jscad.shapes.geodesicSphere( + geodesicSphereOptions + ); + + const sphereOptions = new Inputs.JSCAD.SphereDto(); + sphereOptions.radius = 1; + sphereOptions.center = [0, 3, 4.5]; + const simpleSphere = await bitbybit.jscad.shapes.sphere(sphereOptions); + + const unionOptions = new Inputs.JSCAD.BooleanTwoObjectsDto(); + unionOptions.first = geodesicSphere; + unionOptions.second = simpleSphere; + const unionShape = await bitbybit.jscad.booleans.unionTwo(unionOptions); + + const drawOptions = new Inputs.Draw.DrawBasicGeometryOptions(); + drawOptions.colours = color; + await bitbybit.draw.drawAnyAsync({ + entity: unionShape, + options: drawOptions, + }); +} diff --git a/packages/dev/tmp/test-app/src/style.css b/packages/dev/tmp/test-app/src/style.css new file mode 100644 index 00000000..72e40599 --- /dev/null +++ b/packages/dev/tmp/test-app/src/style.css @@ -0,0 +1,25 @@ +body { + margin: 0px; + overflow: hidden; +} + +a.logo { + position: absolute; + color: white; + vertical-align: middle; + bottom: 10px; + left: 10px; + font-family: 'Courier New', Courier, monospace; + text-decoration: none; + width: 100%; +} + +.logo { + margin-bottom: 20px; + text-align: center; +} + +.logo img { + width: 50px; + height: 50px; +} diff --git a/packages/dev/tmp/test-app/src/vite-env.d.ts b/packages/dev/tmp/test-app/src/vite-env.d.ts new file mode 100644 index 00000000..11f02fe2 --- /dev/null +++ b/packages/dev/tmp/test-app/src/vite-env.d.ts @@ -0,0 +1 @@ +/// diff --git a/packages/dev/tmp/test-app/tsconfig.json b/packages/dev/tmp/test-app/tsconfig.json new file mode 100644 index 00000000..a22caba9 --- /dev/null +++ b/packages/dev/tmp/test-app/tsconfig.json @@ -0,0 +1,25 @@ +{ + "compilerOptions": { + "target": "ES2020", + "useDefineForClassFields": true, + "module": "ESNext", + "lib": ["ES2020", "DOM", "DOM.Iterable"], + "skipLibCheck": true, + + /* Bundler mode */ + "moduleResolution": "bundler", + "allowImportingTsExtensions": true, + "verbatimModuleSyntax": true, + "moduleDetection": "force", + "noEmit": true, + + /* Linting */ + "strict": true, + "noUnusedLocals": true, + "noUnusedParameters": true, + "erasableSyntaxOnly": true, + "noFallthroughCasesInSwitch": true, + "noUncheckedSideEffectImports": true + }, + "include": ["src"] +} From ee1587552958a9e813b8420254ab3caedeb4d70d Mon Sep 17 00:00:00 2001 From: Matas Ubarevicius Date: Tue, 13 Jan 2026 12:54:18 +0200 Subject: [PATCH 13/31] removed tmp accidentally commited --- .../threejs/lite/threejs-logo/index.html | 1 - packages/dev/tmp/test-app/index.html | 27 ----- packages/dev/tmp/test-app/package.json | 19 --- packages/dev/tmp/test-app/public/vite.svg | 1 - packages/dev/tmp/test-app/src/main.ts | 114 ------------------ packages/dev/tmp/test-app/src/style.css | 25 ---- packages/dev/tmp/test-app/src/vite-env.d.ts | 1 - packages/dev/tmp/test-app/tsconfig.json | 25 ---- 8 files changed, 213 deletions(-) delete mode 100644 packages/dev/tmp/test-app/index.html delete mode 100644 packages/dev/tmp/test-app/package.json delete mode 100644 packages/dev/tmp/test-app/public/vite.svg delete mode 100644 packages/dev/tmp/test-app/src/main.ts delete mode 100644 packages/dev/tmp/test-app/src/style.css delete mode 100644 packages/dev/tmp/test-app/src/vite-env.d.ts delete mode 100644 packages/dev/tmp/test-app/tsconfig.json diff --git a/examples/runner/threejs/lite/threejs-logo/index.html b/examples/runner/threejs/lite/threejs-logo/index.html index b7b0be60..f2e44617 100644 --- a/examples/runner/threejs/lite/threejs-logo/index.html +++ b/examples/runner/threejs/lite/threejs-logo/index.html @@ -44,7 +44,6 @@ - - diff --git a/packages/dev/tmp/test-app/package.json b/packages/dev/tmp/test-app/package.json deleted file mode 100644 index 6120f3c9..00000000 --- a/packages/dev/tmp/test-app/package.json +++ /dev/null @@ -1,19 +0,0 @@ -{ - "name": "test-app", - "private": true, - "version": "0.0.0", - "type": "module", - "scripts": { - "dev": "vite", - "build": "tsc && vite build", - "preview": "vite preview" - }, - "dependencies": { - "@bitbybit-dev/playcanvas": "0.21.0", - "playcanvas": "2.14.4" - }, - "devDependencies": { - "typescript": "~5.8.3", - "vite": "^6.3.2" - } -} diff --git a/packages/dev/tmp/test-app/public/vite.svg b/packages/dev/tmp/test-app/public/vite.svg deleted file mode 100644 index 6a410991..00000000 --- a/packages/dev/tmp/test-app/public/vite.svg +++ /dev/null @@ -1 +0,0 @@ - diff --git a/packages/dev/tmp/test-app/src/main.ts b/packages/dev/tmp/test-app/src/main.ts deleted file mode 100644 index f74ec559..00000000 --- a/packages/dev/tmp/test-app/src/main.ts +++ /dev/null @@ -1,114 +0,0 @@ -import "./style.css"; -import { BitByBitBase, Inputs, initBitByBit, initPlayCanvas, type InitBitByBitOptions } from "@bitbybit-dev/playcanvas"; - - -start(); - -async function start() { - const sceneOptions = new Inputs.PlayCanvasScene.InitPlayCanvasDto(); - sceneOptions.canvasId = "playcanvas-canvas"; - sceneOptions.sceneSize = 10; - const { scene, app } = initPlayCanvas(sceneOptions); - const bitbybit = new BitByBitBase(); - - const options: InitBitByBitOptions = { - enableOCCT: true, - enableJSCAD: true, - enableManifold: true, - }; - - await initBitByBit(app, scene, bitbybit, options); - - if (options.enableOCCT) { - await createOCCTGeometry(bitbybit, "#ff0000"); // Red - } - if (options.enableManifold) { - await createManifoldGeometry(bitbybit, "#00ff00"); // Green - } - if (options.enableJSCAD) { - await createJSCADGeometry(bitbybit, "#0000ff"); // Blue - } - -} - -async function createOCCTGeometry(bitbybit: BitByBitBase, color: string) { - const cubeOptions = new Inputs.OCCT.CubeDto(); - cubeOptions.size = 2.5; - cubeOptions.center = [0, 1.25, 0]; - - const cube = await bitbybit.occt.shapes.solid.createCube(cubeOptions); - - const filletOptions = - new Inputs.OCCT.FilletDto(); - filletOptions.shape = cube; - filletOptions.radius = 0.4; - const roundedCube = await bitbybit.occt.fillets.filletEdges(filletOptions); - - const drawOptions = new Inputs.Draw.DrawOcctShapeOptions(); - drawOptions.edgeWidth = 0.5; - drawOptions.faceColour = color; - drawOptions.drawVertices = true; - drawOptions.vertexSize = 0.05; - drawOptions.vertexColour = "#ffffff"; - await bitbybit.draw.drawAnyAsync({ - entity: roundedCube, - options: drawOptions, - }); -} - -async function createManifoldGeometry(bitbybit: BitByBitBase, color: string) { - const sphereOptions = new Inputs.Manifold.SphereDto(); - sphereOptions.radius = 1.5; - sphereOptions.circularSegments = 32; - const sphere = await bitbybit.manifold.manifold.shapes.sphere(sphereOptions); - - const cubeOptions = new Inputs.Manifold.CubeDto(); - cubeOptions.size = 2.5; - const cube = await bitbybit.manifold.manifold.shapes.cube(cubeOptions); - - const diffedShape = await bitbybit.manifold.manifold.booleans.differenceTwo({ - manifold1: cube, - manifold2: sphere, - }); - - const translationOptions = - new Inputs.Manifold.TranslateDto(); - translationOptions.manifold = diffedShape; - translationOptions.vector = [0, 1.25, -4]; // Position below OCCT - const movedShape = await bitbybit.manifold.manifold.transforms.translate( - translationOptions - ); - - const drawOptions = new Inputs.Draw.DrawManifoldOrCrossSectionOptions(); - drawOptions.faceColour = color; - await bitbybit.draw.drawAnyAsync({ - entity: movedShape, - options: drawOptions, - }); -} - -async function createJSCADGeometry(bitbybit: BitByBitBase, color: string) { - const geodesicSphereOptions = new Inputs.JSCAD.GeodesicSphereDto(); - geodesicSphereOptions.radius = 1.5; - geodesicSphereOptions.center = [0, 1.5, 4]; - const geodesicSphere = await bitbybit.jscad.shapes.geodesicSphere( - geodesicSphereOptions - ); - - const sphereOptions = new Inputs.JSCAD.SphereDto(); - sphereOptions.radius = 1; - sphereOptions.center = [0, 3, 4.5]; - const simpleSphere = await bitbybit.jscad.shapes.sphere(sphereOptions); - - const unionOptions = new Inputs.JSCAD.BooleanTwoObjectsDto(); - unionOptions.first = geodesicSphere; - unionOptions.second = simpleSphere; - const unionShape = await bitbybit.jscad.booleans.unionTwo(unionOptions); - - const drawOptions = new Inputs.Draw.DrawBasicGeometryOptions(); - drawOptions.colours = color; - await bitbybit.draw.drawAnyAsync({ - entity: unionShape, - options: drawOptions, - }); -} diff --git a/packages/dev/tmp/test-app/src/style.css b/packages/dev/tmp/test-app/src/style.css deleted file mode 100644 index 72e40599..00000000 --- a/packages/dev/tmp/test-app/src/style.css +++ /dev/null @@ -1,25 +0,0 @@ -body { - margin: 0px; - overflow: hidden; -} - -a.logo { - position: absolute; - color: white; - vertical-align: middle; - bottom: 10px; - left: 10px; - font-family: 'Courier New', Courier, monospace; - text-decoration: none; - width: 100%; -} - -.logo { - margin-bottom: 20px; - text-align: center; -} - -.logo img { - width: 50px; - height: 50px; -} diff --git a/packages/dev/tmp/test-app/src/vite-env.d.ts b/packages/dev/tmp/test-app/src/vite-env.d.ts deleted file mode 100644 index 11f02fe2..00000000 --- a/packages/dev/tmp/test-app/src/vite-env.d.ts +++ /dev/null @@ -1 +0,0 @@ -/// diff --git a/packages/dev/tmp/test-app/tsconfig.json b/packages/dev/tmp/test-app/tsconfig.json deleted file mode 100644 index a22caba9..00000000 --- a/packages/dev/tmp/test-app/tsconfig.json +++ /dev/null @@ -1,25 +0,0 @@ -{ - "compilerOptions": { - "target": "ES2020", - "useDefineForClassFields": true, - "module": "ESNext", - "lib": ["ES2020", "DOM", "DOM.Iterable"], - "skipLibCheck": true, - - /* Bundler mode */ - "moduleResolution": "bundler", - "allowImportingTsExtensions": true, - "verbatimModuleSyntax": true, - "moduleDetection": "force", - "noEmit": true, - - /* Linting */ - "strict": true, - "noUnusedLocals": true, - "noUnusedParameters": true, - "erasableSyntaxOnly": true, - "noFallthroughCasesInSwitch": true, - "noUncheckedSideEffectImports": true - }, - "include": ["src"] -} From 12e7856b7031f90f7bb1ea71b4cf43d149e1bc07 Mon Sep 17 00:00:00 2001 From: Matas Ubarevicius Date: Tue, 13 Jan 2026 13:27:38 +0200 Subject: [PATCH 14/31] refactored to use 'new' for options in some runner examples --- .../runner/threejs/full/simple/index.html | 29 ++- .../threejs/lite/threejs-logo/index.html | 211 +++++++++--------- 2 files changed, 131 insertions(+), 109 deletions(-) diff --git a/examples/runner/threejs/full/simple/index.html b/examples/runner/threejs/full/simple/index.html index 7ca9a316..d8462030 100644 --- a/examples/runner/threejs/full/simple/index.html +++ b/examples/runner/threejs/full/simple/index.html @@ -46,13 +46,28 @@ const curvePts = [[[-10, 0, -10], [0, 3, -10], [10, -1, -10], [20, 2, -10]], [[-10, -5, 0], [0, -3, 0], [10, 1, 0], [20, -2, 0]], [[-10, 0, 10], [0, 3, 10], [10, -1, 10], [20, 2, 10]]]; const wirePromises = curvePts.map((pts) => { - return bitbybit.occt.shapes.wire.interpolatePoints({ points: pts, periodic: false, tolerance: 1e-7 }); + const interpolateDto = new Bit.Inputs.OCCT.InterpolationDto(); + interpolateDto.points = pts; + interpolateDto.periodic = false; + interpolateDto.tolerance = 1e-7; + return bitbybit.occt.shapes.wire.interpolatePoints(interpolateDto); }); const wires = await Promise.all(wirePromises); - const loft = await bitbybit.occt.operations.loft({ shapes: wires, makeSolid: false }); - const translated = await bitbybit.occt.transforms.translate({ shape: loft, translation: [0, 10, 0] }); - const faces = await bitbybit.occt.shapes.face.getFaces({ shape: translated }); + + const loftDto = new Bit.Inputs.OCCT.LoftDto(); + loftDto.shapes = wires; + loftDto.makeSolid = false; + const loft = await bitbybit.occt.operations.loft(loftDto); + + const translateDto = new Bit.Inputs.OCCT.TranslateDto(); + translateDto.shape = loft; + translateDto.translation = [0, 10, 0]; + const translated = await bitbybit.occt.transforms.translate(translateDto); + + const getFacesDto = new Bit.Inputs.OCCT.ShapeDto(); + getFacesDto.shape = translated; + const faces = await bitbybit.occt.shapes.face.getFaces(getFacesDto); const subdivideOptions = new Bit.Inputs.OCCT.FaceSubdivideToRectangleHolesDto(faces[0]); subdivideOptions.nrRectanglesU = model.vRec; @@ -65,7 +80,11 @@ subdivideOptions.offsetFromBorderV = 0.01; const withHoles = await bitbybit.occt.shapes.face.subdivideToRectangleHoles(subdivideOptions); - const finalShape = await bitbybit.occt.operations.makeThickSolidSimple({ shape: withHoles[0], offset: 0.5 }); + + const thickSolidDto = new Bit.Inputs.OCCT.ThisckSolidSimpleDto(); + thickSolidDto.shape = withHoles[0]; + thickSolidDto.offset = 0.5; + const finalShape = await bitbybit.occt.operations.makeThickSolidSimple(thickSolidDto); const options = new Bit.Inputs.Draw.DrawOcctShapeOptions(); options.precision = 0.02; diff --git a/examples/runner/threejs/lite/threejs-logo/index.html b/examples/runner/threejs/lite/threejs-logo/index.html index f2e44617..ad812faf 100644 --- a/examples/runner/threejs/lite/threejs-logo/index.html +++ b/examples/runner/threejs/lite/threejs-logo/index.html @@ -137,24 +137,24 @@ const downloadStep = async () => { if (bitbybit && finalShape) { - await bitbybit.occt.io.saveShapeSTEP({ - shape: finalShape, - fileName: 'threejs.stp', - adjustYtoZ: true, - tryDownload: true - }); + const saveStepDto = new Bit.Inputs.OCCT.SaveStepDto(); + saveStepDto.shape = finalShape; + saveStepDto.fileName = 'threejs.stp'; + saveStepDto.adjustYtoZ = true; + saveStepDto.tryDownload = true; + await bitbybit.occt.io.saveShapeSTEP(saveStepDto); } } const downloadSTL = async () => { if (bitbybit && finalShape) { - await bitbybit.occt.io.saveShapeStl({ - shape: finalShape, - fileName: 'threejs.stl', - precision: 0.01, - adjustYtoZ: true, - tryDownload: true - }); + const saveStlDto = new Bit.Inputs.OCCT.SaveStlDto(); + saveStlDto.shape = finalShape; + saveStlDto.fileName = 'threejs.stl'; + saveStlDto.precision = 0.01; + saveStlDto.adjustYtoZ = true; + saveStlDto.tryDownload = true; + await bitbybit.occt.io.saveShapeStl(saveStlDto); } } @@ -184,94 +184,96 @@ const createShape = async () => { if (shapesToClean.length > 0) { - await bitbybit.occt.deleteShapes({ shapes: shapesToClean }); + const deleteShapesDto = new Bit.Inputs.OCCT.ShapesDto(); + deleteShapesDto.shapes = shapesToClean; + await bitbybit.occt.deleteShapes(deleteShapesDto); shapesToClean = []; } - const triangleFrame1 = await bitbybit.occt.shapes.wire.createNGonWire({ - nrCorners: 3, - radius: 9, - center: [0, 0, 0], - direction: [0, 1, 0] - }); + const ngonWireDto1 = new Bit.Inputs.OCCT.NGonWireDto(); + ngonWireDto1.nrCorners = 3; + ngonWireDto1.radius = 9; + ngonWireDto1.center = [0, 0, 0]; + ngonWireDto1.direction = [0, 1, 0]; + const triangleFrame1 = await bitbybit.occt.shapes.wire.createNGonWire(ngonWireDto1); - const triangleFrame2 = await bitbybit.occt.shapes.wire.createNGonWire({ - nrCorners: 3, - radius: 6, - center: [0, 0, 0], - direction: [0, 1, 0] - }); + const ngonWireDto2 = new Bit.Inputs.OCCT.NGonWireDto(); + ngonWireDto2.nrCorners = 3; + ngonWireDto2.radius = 6; + ngonWireDto2.center = [0, 0, 0]; + ngonWireDto2.direction = [0, 1, 0]; + const triangleFrame2 = await bitbybit.occt.shapes.wire.createNGonWire(ngonWireDto2); const shape1 = await createTriangle1(model.heightBase, model.scale1, model.heightMid1); const shape2 = await createTriangle1(model.heightBase, model.scale2, model.heightMid2); shapesToClean.push(shape1, shape2); - const shape2Rot = await bitbybit.occt.transforms.rotate({ - shape: shape2, - angle: 180, - axis: [0, 1, 0], - }); + const rotateDto1 = new Bit.Inputs.OCCT.RotateDto(); + rotateDto1.shape = shape2; + rotateDto1.angle = 180; + rotateDto1.axis = [0, 1, 0]; + const shape2Rot = await bitbybit.occt.transforms.rotate(rotateDto1); shapesToClean.push(shape2Rot); - const points1 = await bitbybit.occt.shapes.wire.divideWireByEqualDistanceToPoints({ - shape: triangleFrame1, - nrOfDivisions: 9, - removeStartPoint: true, - removeEndPoint: false, - }); + const divideDto1 = new Bit.Inputs.OCCT.DivideDto(); + divideDto1.shape = triangleFrame1; + divideDto1.nrOfDivisions = 9; + divideDto1.removeStartPoint = true; + divideDto1.removeEndPoint = false; + const points1 = await bitbybit.occt.shapes.wire.divideWireByEqualDistanceToPoints(divideDto1); points1.push([0, 0, 0]); - const points2 = await bitbybit.occt.shapes.wire.divideWireByEqualDistanceToPoints({ - shape: triangleFrame2, - nrOfDivisions: 6, - removeStartPoint: true, - removeEndPoint: false, - }); - - const triangles1 = await bitbybit.occt.transforms.translateShapes({ - shapes: points1.map(() => shape1), - translations: points1 - }); + const divideDto2 = new Bit.Inputs.OCCT.DivideDto(); + divideDto2.shape = triangleFrame2; + divideDto2.nrOfDivisions = 6; + divideDto2.removeStartPoint = true; + divideDto2.removeEndPoint = false; + const points2 = await bitbybit.occt.shapes.wire.divideWireByEqualDistanceToPoints(divideDto2); + + const translateShapesDto1 = new Bit.Inputs.OCCT.TranslateShapesDto(); + translateShapesDto1.shapes = points1.map(() => shape1); + translateShapesDto1.translations = points1; + const triangles1 = await bitbybit.occt.transforms.translateShapes(translateShapesDto1); shapesToClean.push(...triangles1); - const triangles2 = await bitbybit.occt.transforms.translateShapes({ - shapes: points2.map(() => shape2Rot), - translations: points2 - }); + const translateShapesDto2 = new Bit.Inputs.OCCT.TranslateShapesDto(); + translateShapesDto2.shapes = points2.map(() => shape2Rot); + translateShapesDto2.translations = points2; + const triangles2 = await bitbybit.occt.transforms.translateShapes(translateShapesDto2); shapesToClean.push(...triangles2); - const triangleBase = await bitbybit.occt.shapes.wire.createNGonWire({ - nrCorners: 3, - radius: 12, - center: [0, -model.heightBase, 0], - direction: [0, 1, 0] - }); + const ngonWireDto3 = new Bit.Inputs.OCCT.NGonWireDto(); + ngonWireDto3.nrCorners = 3; + ngonWireDto3.radius = 12; + ngonWireDto3.center = [0, -model.heightBase, 0]; + ngonWireDto3.direction = [0, 1, 0]; + const triangleBase = await bitbybit.occt.shapes.wire.createNGonWire(ngonWireDto3); shapesToClean.push(triangleBase); - const extrusion = await bitbybit.occt.operations.extrude({ - shape: triangleBase, - direction: [0, model.heightBase * 2, 0] - }); + const extrudeDto = new Bit.Inputs.OCCT.ExtrudeDto(); + extrudeDto.shape = triangleBase; + extrudeDto.direction = [0, model.heightBase * 2, 0]; + const extrusion = await bitbybit.occt.operations.extrude(extrudeDto); shapesToClean.push(extrusion); - const shell = await bitbybit.occt.shapes.shell.sewFaces({ - shapes: [extrusion, ...triangles1, ...triangles2], - tolerance: 1e-7 - }); + const sewDto = new Bit.Inputs.OCCT.SewDto(); + sewDto.shapes = [extrusion, ...triangles1, ...triangles2]; + sewDto.tolerance = 1e-7; + const shell = await bitbybit.occt.shapes.shell.sewFaces(sewDto); shapesToClean.push(shell); - finalShape = await bitbybit.occt.shapes.solid.fromClosedShell({ - shape: shell, - }); + const shapeDto = new Bit.Inputs.OCCT.ShapeDto(); + shapeDto.shape = shell; + finalShape = await bitbybit.occt.shapes.solid.fromClosedShell(shapeDto); shapesToClean.push(finalShape); - const solidRot = await bitbybit.occt.transforms.rotate({ - shape: finalShape, - angle: 15, - axis: [0, 1, 0], - }); + const rotateDto2 = new Bit.Inputs.OCCT.RotateDto(); + rotateDto2.shape = finalShape; + rotateDto2.angle = 15; + rotateDto2.axis = [0, 1, 0]; + const solidRot = await bitbybit.occt.transforms.rotate(rotateDto2); shapesToClean.push(solidRot); const options = new Bit.Inputs.Draw.DrawOcctShapeOptions(); @@ -312,44 +314,45 @@ useScale = 0.0001; } const midScale = (1 - useScale) / 2 + useScale; - const triangleBaseOne = await bitbybit.occt.shapes.wire.createNGonWire({ - nrCorners: 3, - radius: 3, - center: [0, heightBase, 0], - direction: [0, 1, 0] - }); + + const ngonBaseOneDto = new Bit.Inputs.OCCT.NGonWireDto(); + ngonBaseOneDto.nrCorners = 3; + ngonBaseOneDto.radius = 3; + ngonBaseOneDto.center = [0, heightBase, 0]; + ngonBaseOneDto.direction = [0, 1, 0]; + const triangleBaseOne = await bitbybit.occt.shapes.wire.createNGonWire(ngonBaseOneDto); shapesToClean.push(triangleBaseOne); - const triangleMidOne = await bitbybit.occt.shapes.wire.createNGonWire({ - nrCorners: 3, - radius: 3 * midScale, - center: [0, heightMid, 0], - direction: [0, 1, 0] - }); + const ngonMidOneDto = new Bit.Inputs.OCCT.NGonWireDto(); + ngonMidOneDto.nrCorners = 3; + ngonMidOneDto.radius = 3 * midScale; + ngonMidOneDto.center = [0, heightMid, 0]; + ngonMidOneDto.direction = [0, 1, 0]; + const triangleMidOne = await bitbybit.occt.shapes.wire.createNGonWire(ngonMidOneDto); shapesToClean.push(triangleMidOne); - const triangleCoreOne = await bitbybit.occt.shapes.wire.createNGonWire({ - nrCorners: 3, - radius: 3 * useScale, - center: [0, 0, 0], - direction: [0, 1, 0] - }); + const ngonCoreOneDto = new Bit.Inputs.OCCT.NGonWireDto(); + ngonCoreOneDto.nrCorners = 3; + ngonCoreOneDto.radius = 3 * useScale; + ngonCoreOneDto.center = [0, 0, 0]; + ngonCoreOneDto.direction = [0, 1, 0]; + const triangleCoreOne = await bitbybit.occt.shapes.wire.createNGonWire(ngonCoreOneDto); shapesToClean.push(triangleCoreOne); - const triangleBaseDown = await bitbybit.occt.shapes.wire.createNGonWire({ - nrCorners: 3, - radius: 3, - center: [0, -heightBase, 0], - direction: [0, 1, 0] - }); + const ngonBaseDownDto = new Bit.Inputs.OCCT.NGonWireDto(); + ngonBaseDownDto.nrCorners = 3; + ngonBaseDownDto.radius = 3; + ngonBaseDownDto.center = [0, -heightBase, 0]; + ngonBaseDownDto.direction = [0, 1, 0]; + const triangleBaseDown = await bitbybit.occt.shapes.wire.createNGonWire(ngonBaseDownDto); shapesToClean.push(triangleBaseDown); - const triangleMidDown = await bitbybit.occt.shapes.wire.createNGonWire({ - nrCorners: 3, - radius: 3 * midScale, - center: [0, -heightMid, 0], - direction: [0, 1, 0] - }); + const ngonMidDownDto = new Bit.Inputs.OCCT.NGonWireDto(); + ngonMidDownDto.nrCorners = 3; + ngonMidDownDto.radius = 3 * midScale; + ngonMidDownDto.center = [0, -heightMid, 0]; + ngonMidDownDto.direction = [0, 1, 0]; + const triangleMidDown = await bitbybit.occt.shapes.wire.createNGonWire(ngonMidDownDto); shapesToClean.push(triangleMidDown); const loftOptions = new Bit.Inputs.OCCT.LoftAdvancedDto(); From b3512273058776cc79e9b4cc46ecd72fd49d09d4 Mon Sep 17 00:00:00 2001 From: Matas Ubarevicius Date: Tue, 13 Jan 2026 15:19:07 +0200 Subject: [PATCH 15/31] Fixed csv parsing to escape \n --- packages/dev/core/lib/api/bitbybit/csv.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/packages/dev/core/lib/api/bitbybit/csv.ts b/packages/dev/core/lib/api/bitbybit/csv.ts index 59c7f331..33f377d2 100644 --- a/packages/dev/core/lib/api/bitbybit/csv.ts +++ b/packages/dev/core/lib/api/bitbybit/csv.ts @@ -18,7 +18,9 @@ export class CSVBitByBit { // Convert literal escape sequences to actual characters const rowSeparator = this.convertEscapeSequences(inputs.rowSeparator || "\n"); const columnSeparator = this.convertEscapeSequences(inputs.columnSeparator || ","); - const lines = inputs.csv.split(rowSeparator); + // Also convert escape sequences in the CSV data itself (e.g., literal "\n" to actual newline) + const csvData = this.convertEscapeSequences(inputs.csv); + const lines = csvData.split(rowSeparator); const result: string[][] = []; for (let i = 0; i < lines.length; i++) { From 514192bc804bcffb4824a0aab18125e21c21761d Mon Sep 17 00:00:00 2001 From: Matas Ubarevicius Date: Tue, 13 Jan 2026 20:33:34 +0200 Subject: [PATCH 16/31] llms.txt --- docs/static/llms.txt | 197 +++++++++++++++++++++++++++++++++++++++++ docs/static/robots.txt | 8 ++ llms.txt | 182 +++++++++++++++++++++++++++++++++++++ 3 files changed, 387 insertions(+) create mode 100644 docs/static/llms.txt create mode 100644 docs/static/robots.txt create mode 100644 llms.txt diff --git a/docs/static/llms.txt b/docs/static/llms.txt new file mode 100644 index 00000000..520bd641 --- /dev/null +++ b/docs/static/llms.txt @@ -0,0 +1,197 @@ +# Bitbybit Documentation + +> Learn how to use the Bitbybit 3D creative coding platform—from visual programming to TypeScript APIs and NPM package integration. Build parametric 3D models, product configurators, and CAD applications directly in the browser. + +This is the official documentation site for Bitbybit. The platform enables designers and developers to create 3D geometry using visual programming or TypeScript code, with integration for BabylonJS, Three.js, and PlayCanvas game engines. + +## Quick Links + +- Main Platform: https://bitbybit.dev +- TypeScript API Reference: https://docs.bitbybit.dev +- GitHub Repository: https://github.com/bitbybit-dev/bitbybit + +## Getting Started + +- Welcome Guide: https://learn.bitbybit.dev/learn/intro +- Platform Overview: https://learn.bitbybit.dev/learn/getting-started/overview +- Open Source Approach: https://learn.bitbybit.dev/learn/open-source-approach + +## NPM Packages + +Integration guides for embedding Bitbybit in your web applications. + +### Quick Start + +```bash +npx @bitbybit-dev/create-app my-project +``` + +Choose your game engine (BabylonJS, Three.js, or PlayCanvas) and start coding immediately. + +### Overview + +- Introduction: https://learn.bitbybit.dev/learn/npm-packages/intro +- Engine Agnostic Core: https://learn.bitbybit.dev/learn/npm-packages/game-engine-agnostic + +### Game Engine Integration + +- Three.js Integration: https://learn.bitbybit.dev/learn/npm-packages/threejs +- BabylonJS Integration: https://learn.bitbybit.dev/learn/npm-packages/babylonjs +- PlayCanvas Integration: https://learn.bitbybit.dev/learn/npm-packages/playcanvas + +### All NPM Packages + +Game Engine Packages: +- @bitbybit-dev/babylonjs - BabylonJS visualization and drawing +- @bitbybit-dev/threejs - Three.js visualization and drawing +- @bitbybit-dev/playcanvas - PlayCanvas visualization and drawing + +Core Packages: +- @bitbybit-dev/core - Combined CAD kernel features +- @bitbybit-dev/base - Base algorithms (vector math, transformations) + +CAD Kernel Packages (Main Thread): +- @bitbybit-dev/occt - OpenCascade for industrial B-rep CAD +- @bitbybit-dev/jscad - JSCAD for CSG modeling +- @bitbybit-dev/manifold - Manifold for fast mesh booleans + +Web Worker Packages (Non-blocking, Recommended): +- @bitbybit-dev/occt-worker - OpenCascade via web worker +- @bitbybit-dev/jscad-worker - JSCAD via web worker +- @bitbybit-dev/manifold-worker - Manifold via web worker + +## Runners + +Script runners for executing Bitbybit scripts in your applications: + +- Runners Overview: https://learn.bitbybit.dev/learn/runners +- BabylonJS Full Runner: https://learn.bitbybit.dev/learn/runners/engines/babylonjs/full-runner +- Three.js Full Runner: https://learn.bitbybit.dev/learn/runners/engines/threejs/full-runner +- PlayCanvas Full Runner: https://learn.bitbybit.dev/learn/runners/engines/playcanvas/full-runner + +## Code Editor + +TypeScript programming guides: + +- Code Introduction: https://learn.bitbybit.dev/learn/code/intro + +## 3D Bits (Shopify App) + +Add 3D product configurators to Shopify stores: + +- 3D Bits Introduction: https://learn.bitbybit.dev/learn/3d-bits/intro +- Shopify App: https://apps.shopify.com/3d-bits-1 + +## AI Integration + +Using AI assistants with Bitbybit for enhanced coding workflows. + +### Documentation + +- AI Introduction: https://learn.bitbybit.dev/learn/using-ai-with-bitbybit/intro +- Context7 MCP Integration: https://learn.bitbybit.dev/learn/using-ai-with-bitbybit/mcp/context-7 + +### AI Context Files (v0.21.0) + +Attach these files to your AI coding assistant for Bitbybit API knowledge. + +#### Beginner Context (Monaco Editor) + +For online TypeScript editor at bitbybit.dev: +- Full Context (116k tokens): https://app.bitbybit.dev/assets/ai-prompt-context/v0.21.0/bitbybit-babylon-monaco-ai-context-v0.21.0.md + +#### BabylonJS Context + +- Full (116k tokens): https://app.bitbybit.dev/assets/ai-prompt-context/v0.21.0/bitbybit-babylon-ai-context-v0.21.0.md +- Lite (114k tokens): https://app.bitbybit.dev/assets/ai-prompt-context/v0.21.0/bitbybit-babylon-no-comment-min-ai-v0.21.0.txt + +#### Three.js Context + +- Full (95k tokens): https://app.bitbybit.dev/assets/ai-prompt-context/v0.21.0/bitbybit-three-ai-context-v0.21.0.md +- Lite (82k tokens): https://app.bitbybit.dev/assets/ai-prompt-context/v0.21.0/bitbybit-three-no-comment-min-ai-v0.21.0.txt + +#### PlayCanvas Context + +- Full (94k tokens): https://app.bitbybit.dev/assets/ai-prompt-context/v0.21.0/bitbybit-playcanvas-ai-context-v0.21.0.md +- Lite (82k tokens): https://app.bitbybit.dev/assets/ai-prompt-context/v0.21.0/bitbybit-playcanvas-no-comment-min-ai-v0.21.0.txt + +### MCP Server + +Context7 MCP provides live AI context with always up-to-date documentation: + +- Context7 Library: https://context7.com/bitbybit-dev/bitbybit + +VS Code MCP Setup: +```json +{ + "servers": [ + { + "command": "npx", + "args": ["-y", "@upstash/context7-mcp@latest"], + "env": { + "DEFAULT_MINIMUM_TOKENS": "10000" + } + } + ] +} +``` + +## GitHub & Contributing + +- Main Repository: https://github.com/bitbybit-dev/bitbybit +- Contributing Guide: https://learn.bitbybit.dev/learn/github +- Unit Testing Guide: https://learn.bitbybit.dev/learn/github/unit-tests +- Live Test Coverage: https://learn.bitbybit.dev/learn/github/live-unit-test-coverage + +## Blog + +Latest updates, tutorials, and announcements: + +- Blog: https://learn.bitbybit.dev/blog +- PlayCanvas Support Announcement: https://learn.bitbybit.dev/blog/playcanvas-support + +## Security + +- Hosting & CDN: https://learn.bitbybit.dev/learn/hosting-and-cdn + +## Community + +- Discord: https://discord.gg/GSe3VMe +- YouTube: https://www.youtube.com/@bitbybitdev +- LinkedIn: https://www.linkedin.com/company/bitbybit-dev +- X/Twitter: https://x.com/bitbybit_dev + +## Key Concepts + +### Geometry Kernels + +Bitbybit supports multiple CAD kernels: + +- **OpenCascade (OCCT)**: Industrial-grade B-rep kernel for precise CAD operations, boolean operations, fillets, chamfers, STEP export +- **JSCAD**: JavaScript-based CSG modeling for simple shapes +- **Manifold**: Fast mesh boolean operations for real-time applications + +### Game Engines + +Visualization and rendering: + +- **BabylonJS**: Full-featured WebGL engine with PBR, physics, audio +- **Three.js**: Lightweight, popular 3D library with vast ecosystem +- **PlayCanvas**: Professional engine with online collaborative editor + +### Editors + +- **Monaco (TypeScript)**: Full IntelliSense, professional coding +- **Rete**: Node-based visual programming +- **Blockly**: Block-based visual programming for beginners + +### Web Workers + +All geometry kernels have web worker variants (-worker packages) for non-blocking UI: +- Asynchronous operations that don't freeze the browser +- Recommended for production applications +- Same API as main thread packages + +## Optional + +- Main site llms.txt: https://bitbybit.dev/llms.txt diff --git a/docs/static/robots.txt b/docs/static/robots.txt new file mode 100644 index 00000000..eef3bf1c --- /dev/null +++ b/docs/static/robots.txt @@ -0,0 +1,8 @@ +User-agent: * +Allow: / + +Sitemap: https://learn.bitbybit.dev/sitemap.xml + +# LLM Context +# For AI assistants and language models +llms.txt: https://learn.bitbybit.dev/llms.txt diff --git a/llms.txt b/llms.txt new file mode 100644 index 00000000..f6f1b73f --- /dev/null +++ b/llms.txt @@ -0,0 +1,182 @@ +# Bitbybit Monorepo + +> Open-source 3D CAD algorithms and NPM packages for web-based parametric modeling and visualization. Build once, run anywhere—no installation required. + +This monorepo contains the open-source core of Bitbybit platform, including multiple NPM packages for integrating 3D CAD capabilities into web applications using BabylonJS, Three.js, or PlayCanvas game engines. + +## Repository + +- GitHub: https://github.com/bitbybit-dev/bitbybit +- License: MIT + +## Documentation + +- Learn Bitbybit: https://learn.bitbybit.dev +- TypeScript API Reference: https://docs.bitbybit.dev +- Main Platform: https://bitbybit.dev + +## Quick Start + +```bash +npx @bitbybit-dev/create-app my-project +``` + +Choose your game engine and start coding immediately. + +## NPM Packages + +### Game Engine Integrations + +| Package | Description | NPM | +|---------|-------------|-----| +| @bitbybit-dev/babylonjs | BabylonJS visualization and drawing | https://www.npmjs.com/package/@bitbybit-dev/babylonjs | +| @bitbybit-dev/threejs | Three.js visualization and drawing | https://www.npmjs.com/package/@bitbybit-dev/threejs | +| @bitbybit-dev/playcanvas | PlayCanvas visualization and drawing | https://www.npmjs.com/package/@bitbybit-dev/playcanvas | + +### Core Packages + +| Package | Description | NPM | +|---------|-------------|-----| +| @bitbybit-dev/core | Combined CAD kernel features | https://www.npmjs.com/package/@bitbybit-dev/core | +| @bitbybit-dev/base | Base algorithms (vector math, transforms) | https://www.npmjs.com/package/@bitbybit-dev/base | + +### CAD Kernel Packages (Main Thread) + +| Package | Description | NPM | +|---------|-------------|-----| +| @bitbybit-dev/occt | OpenCascade B-rep CAD wrapper | https://www.npmjs.com/package/@bitbybit-dev/occt | +| @bitbybit-dev/jscad | JSCAD CSG modeling wrapper | https://www.npmjs.com/package/@bitbybit-dev/jscad | +| @bitbybit-dev/manifold | Manifold mesh booleans wrapper | https://www.npmjs.com/package/@bitbybit-dev/manifold | + +### Web Worker Packages (Non-blocking, Recommended) + +These packages run geometry computations in web workers for non-blocking UI. Same API as main thread packages, but all operations are asynchronous. + +| Package | Description | NPM | +|---------|-------------|-----| +| @bitbybit-dev/occt-worker | OpenCascade via web worker | https://www.npmjs.com/package/@bitbybit-dev/occt-worker | +| @bitbybit-dev/jscad-worker | JSCAD via web worker | https://www.npmjs.com/package/@bitbybit-dev/jscad-worker | +| @bitbybit-dev/manifold-worker | Manifold via web worker | https://www.npmjs.com/package/@bitbybit-dev/manifold-worker | + +## Package Structure + +``` +packages/ +└── dev/ + ├── babylonjs/ # BabylonJS integration + ├── threejs/ # Three.js integration + ├── playcanvas/ # PlayCanvas integration + ├── core/ # Core combining all kernels + ├── base/ # Base algorithms + ├── occt/ # OpenCascade wrapper + ├── occt-worker/ # OCCT web worker + ├── jscad/ # JSCAD wrapper + ├── jscad-worker/ # JSCAD web worker + ├── manifold/ # Manifold wrapper + ├── manifold-worker/ # Manifold web worker + └── create-app/ # Project scaffolding CLI +``` + +## AI Context + +For AI coding assistants, use these resources to get comprehensive Bitbybit API knowledge. + +### AI Prompt Context Files (v0.21.0) + +#### Beginner Context (Monaco Editor) +For online TypeScript editor at bitbybit.dev: +- Full Context (116k tokens): https://app.bitbybit.dev/assets/ai-prompt-context/v0.21.0/bitbybit-babylon-monaco-ai-context-v0.21.0.md + +#### BabylonJS Context +- Full (116k tokens): https://app.bitbybit.dev/assets/ai-prompt-context/v0.21.0/bitbybit-babylon-ai-context-v0.21.0.md +- Lite (114k tokens): https://app.bitbybit.dev/assets/ai-prompt-context/v0.21.0/bitbybit-babylon-no-comment-min-ai-v0.21.0.txt + +#### Three.js Context +- Full (95k tokens): https://app.bitbybit.dev/assets/ai-prompt-context/v0.21.0/bitbybit-three-ai-context-v0.21.0.md +- Lite (82k tokens): https://app.bitbybit.dev/assets/ai-prompt-context/v0.21.0/bitbybit-three-no-comment-min-ai-v0.21.0.txt + +#### PlayCanvas Context +- Full (94k tokens): https://app.bitbybit.dev/assets/ai-prompt-context/v0.21.0/bitbybit-playcanvas-ai-context-v0.21.0.md +- Lite (82k tokens): https://app.bitbybit.dev/assets/ai-prompt-context/v0.21.0/bitbybit-playcanvas-no-comment-min-ai-v0.21.0.txt + +### Context7 MCP (Recommended) + +Live AI context with always up-to-date documentation. Works with Claude, Gemini, Grok. + +Add to your `.vscode/mcp.json`: + +```json +{ + "servers": [ + { + "command": "npx", + "args": ["-y", "@upstash/context7-mcp@latest"], + "env": { + "DEFAULT_MINIMUM_TOKENS": "10000" + } + } + ] +} +``` + +- Context7 Library: https://context7.com/bitbybit-dev/bitbybit +- Integration Guide: https://learn.bitbybit.dev/learn/using-ai-with-bitbybit/mcp/context-7 + +## Integration Guides + +- Three.js: https://learn.bitbybit.dev/learn/npm-packages/threejs +- BabylonJS: https://learn.bitbybit.dev/learn/npm-packages/babylonjs +- PlayCanvas: https://learn.bitbybit.dev/learn/npm-packages/playcanvas +- Engine Agnostic: https://learn.bitbybit.dev/learn/npm-packages/game-engine-agnostic + +## Geometry Kernels + +### OpenCascade (OCCT) +Industrial-grade B-rep kernel: +- Boundary representation for exact geometry +- Boolean operations (union, difference, intersection) +- Fillets, chamfers, shell, offset operations +- STEP/IGES import/export +- Sweeps, lofts, pipes, revolutions + +### JSCAD +JavaScript-based CSG modeling: +- Constructive solid geometry operations +- Lightweight for simple shapes +- STL export for 3D printing + +### Manifold +Fast mesh boolean operations: +- Optimized for real-time operations +- GPU-accelerated +- Ideal for interactive applications + +## Example Applications + +- Laptop Holder: https://github.com/bitbybit-dev/app-examples/tree/main/angular/laptop-holder +- Cup Configurator: https://github.com/bitbybit-dev/app-examples/tree/main/react/cup +- Live Demos: https://app-store.bitbybit.dev + +## Contributing + +- Contributing Guide: CONTRIBUTING.md +- Code of Conduct: CODE_OF_CONDUCT.md +- Unit Testing Guide: UNIT_TESTING_GUIDE.md + +## Community + +- Discord: https://discord.gg/GSe3VMe +- YouTube: https://www.youtube.com/@bitbybitdev + +## Support the Project + +Your contributions allow this project to exist: + +- Silver/Gold Plans: https://bitbybit.dev/auth/pick-plan +- 3D Bits Shopify App: https://apps.shopify.com/3d-bits-1 +- Crafts Shop: https://crafts.bitbybit.dev + +## Related llms.txt Files + +- Main Platform: https://bitbybit.dev/llms.txt +- Documentation: https://learn.bitbybit.dev/llms.txt From 789d24577f2ba9f3be5a85fa7dd1a5d04e5b7561 Mon Sep 17 00:00:00 2001 From: Matas Ubarevicius Date: Tue, 13 Jan 2026 20:46:18 +0200 Subject: [PATCH 17/31] renamed txt to md files for ai prompts --- docs/static/llms.txt | 6 +++--- llms.txt | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/docs/static/llms.txt b/docs/static/llms.txt index 520bd641..434692e4 100644 --- a/docs/static/llms.txt +++ b/docs/static/llms.txt @@ -103,17 +103,17 @@ For online TypeScript editor at bitbybit.dev: #### BabylonJS Context - Full (116k tokens): https://app.bitbybit.dev/assets/ai-prompt-context/v0.21.0/bitbybit-babylon-ai-context-v0.21.0.md -- Lite (114k tokens): https://app.bitbybit.dev/assets/ai-prompt-context/v0.21.0/bitbybit-babylon-no-comment-min-ai-v0.21.0.txt +- Lite (114k tokens): https://app.bitbybit.dev/assets/ai-prompt-context/v0.21.0/bitbybit-babylon-no-comment-min-ai-v0.21.0.md #### Three.js Context - Full (95k tokens): https://app.bitbybit.dev/assets/ai-prompt-context/v0.21.0/bitbybit-three-ai-context-v0.21.0.md -- Lite (82k tokens): https://app.bitbybit.dev/assets/ai-prompt-context/v0.21.0/bitbybit-three-no-comment-min-ai-v0.21.0.txt +- Lite (82k tokens): https://app.bitbybit.dev/assets/ai-prompt-context/v0.21.0/bitbybit-three-no-comment-min-ai-v0.21.0.md #### PlayCanvas Context - Full (94k tokens): https://app.bitbybit.dev/assets/ai-prompt-context/v0.21.0/bitbybit-playcanvas-ai-context-v0.21.0.md -- Lite (82k tokens): https://app.bitbybit.dev/assets/ai-prompt-context/v0.21.0/bitbybit-playcanvas-no-comment-min-ai-v0.21.0.txt +- Lite (82k tokens): https://app.bitbybit.dev/assets/ai-prompt-context/v0.21.0/bitbybit-playcanvas-no-comment-min-ai-v0.21.0.md ### MCP Server diff --git a/llms.txt b/llms.txt index f6f1b73f..2a8584d4 100644 --- a/llms.txt +++ b/llms.txt @@ -89,15 +89,15 @@ For online TypeScript editor at bitbybit.dev: #### BabylonJS Context - Full (116k tokens): https://app.bitbybit.dev/assets/ai-prompt-context/v0.21.0/bitbybit-babylon-ai-context-v0.21.0.md -- Lite (114k tokens): https://app.bitbybit.dev/assets/ai-prompt-context/v0.21.0/bitbybit-babylon-no-comment-min-ai-v0.21.0.txt +- Lite (114k tokens): https://app.bitbybit.dev/assets/ai-prompt-context/v0.21.0/bitbybit-babylon-no-comment-min-ai-v0.21.0.md #### Three.js Context - Full (95k tokens): https://app.bitbybit.dev/assets/ai-prompt-context/v0.21.0/bitbybit-three-ai-context-v0.21.0.md -- Lite (82k tokens): https://app.bitbybit.dev/assets/ai-prompt-context/v0.21.0/bitbybit-three-no-comment-min-ai-v0.21.0.txt +- Lite (82k tokens): https://app.bitbybit.dev/assets/ai-prompt-context/v0.21.0/bitbybit-three-no-comment-min-ai-v0.21.0.md #### PlayCanvas Context - Full (94k tokens): https://app.bitbybit.dev/assets/ai-prompt-context/v0.21.0/bitbybit-playcanvas-ai-context-v0.21.0.md -- Lite (82k tokens): https://app.bitbybit.dev/assets/ai-prompt-context/v0.21.0/bitbybit-playcanvas-no-comment-min-ai-v0.21.0.txt +- Lite (82k tokens): https://app.bitbybit.dev/assets/ai-prompt-context/v0.21.0/bitbybit-playcanvas-no-comment-min-ai-v0.21.0.md ### Context7 MCP (Recommended) From 5b1958ef75ef04ce4825018563a1237b292acaf7 Mon Sep 17 00:00:00 2001 From: Matas Ubarevicius Date: Wed, 14 Jan 2026 08:04:33 +0200 Subject: [PATCH 18/31] v0.21.1 --- .../2024-11-08-updated-bitbybit-runners.md | 2 +- .../theme-app-extensions/bitbybit-viewer.md | 2 +- .../tutorials/bitbybit-viewer/settings.md | 2 +- .../getting-started/common-settings.md | 4 +- .../product-customizable-text.mdx | 2 +- .../product-laptop-holder.mdx | 2 +- .../videos-tutorials/product-palm-table.mdx | 2 +- .../common/base/color/color-usage-examples.md | 6 +- .../base/point/point-hex-grid-example.md | 6 +- .../base/point/point-spiral-examples.md | 6 +- .../common/base/text/text-usage-examples.md | 6 +- .../base/vector/vector-usage-examples.md | 6 +- docs/learn/code/common/draw/examples.mdx | 6 +- .../code/common/occt/booleans/operations.mdx | 18 +- .../occt/dimensions/angular-dimension.md | 12 +- .../occt/dimensions/linear-dimension.md | 12 +- .../common/occt/dimensions/pin-with-label.md | 12 +- .../occt/fillets/chamfer-circular-edges.mdx | 6 +- .../common/occt/fillets/chamfers-intro.mdx | 6 +- .../chamfers-var-radius-on-spec-edges.mdx | 6 +- .../common/occt/fillets/fillet-3d-wires.mdx | 6 +- .../common/occt/fillets/fillets-intro.mdx | 6 +- .../fillets/fillets-on-2d-wire-corners.mdx | 6 +- .../occt/fillets/fillets-on-2d-wires.mdx | 6 +- .../fillets-var-radius-on-spec-edges.mdx | 6 +- .../io/dxf-file-format-for-2d-drawings.md | 6 +- .../modeling/festive-decor/frost-flower.md | 6 +- .../festive-decor/frozen-snowflake.md | 6 +- .../occt/modeling/festive-decor/gem-star.md | 6 +- .../modeling/festive-decor/star-ornament.md | 18 +- .../modeling/festive-decor/tree-decoration.md | 2 +- .../occt/modeling/festive-decor/tree.md | 6 +- .../festive-decor/twisted-polygon-ornament.md | 6 +- .../hollow-shapes/hexagon-hive-flat.md | 6 +- .../modeling/hollow-shapes/hexagon-hive.md | 6 +- .../hollow-shapes/hexagon-holes-on-face.md | 6 +- .../hollow-shapes/rectangle-holes-on-face.md | 6 +- .../modeling/hollow-shapes/simple-hole.md | 18 +- .../hollow-shapes/simple-hollow-grids.md | 6 +- .../modeling/parametric-art/simple-flower.md | 8 +- .../common/occt/operations/advanced-loft.md | 6 +- .../code/common/occt/operations/extrusions.md | 12 +- .../occt/operations/offset-operations.md | 24 +- .../occt/operations/rotated-extrusions.md | 12 +- .../common/occt/operations/simple-loft.md | 6 +- .../common/occt/operations/thick-solids.md | 6 +- .../occt/operations/wire-offset-multiple.md | 6 +- .../shapes/compound/compounded-drawing.md | 6 +- .../code/common/occt/shapes/compound/intro.md | 18 +- .../occt/shapes/edge/edge-constraints.md | 30 +- .../common/occt/shapes/edge/edge-indexes.mdx | 6 +- .../occt/shapes/edge/edge-primitives.md | 48 +- .../occt/shapes/face/face-basic-primitives.md | 6 +- .../occt/shapes/face/face-from-points.md | 6 +- .../common/occt/shapes/face/face-from-wire.md | 6 +- .../occt/shapes/face/face-hex-grid-pattern.md | 6 +- .../common/occt/shapes/shells/intro-shells.md | 12 +- .../common/occt/shapes/solids/intro-solids.md | 6 +- .../shapes/solids/volume-and-surface-area.md | 6 +- .../occt/shapes/wire/wire-basic-primitives.md | 6 +- .../occt/shapes/wire/wire-bezier-weights.md | 6 +- .../occt/shapes/wire/wire-from-edges.md | 6 +- .../wire/wire-hexagons-advanced-pattern.md | 6 +- .../occt/shapes/wire/wire-hexagons-in-grid.md | 6 +- .../occt/shapes/wire/wire-shape-primitives.md | 24 +- .../occt/shapes/wire/wire-via-points.md | 6 +- .../basics/assets/local/gltf.mdx | 6 +- .../basics/assets/local/step.mdx | 6 +- .../getting-started/blockly/hello-world.mdx | 4 +- .../blockly/parametric-cube.mdx | 2 +- .../getting-started/rete/hello-world.mdx | 6 +- .../getting-started/rete/parametric-cube.mdx | 4 +- .../typescript/hello-world.mdx | 4 +- .../typescript/how-to-code-in-monaco.md | 2 +- .../typescript/parametric-cube.mdx | 2 +- .../viewer-editor/basics/getting-started.md | 2 +- .../viewer-editor/basics/overview.md | 2 +- .../babylonjs/start-with-babylon-js.md | 2 +- .../playcanvas/start-with-playcanvas.md | 2 +- .../threejs/start-with-three-js.md | 2 +- docs/learn/runners/intro-blockly.mdx | 4 +- docs/learn/runners/intro-rete.mdx | 2 +- docs/learn/runners/intro-typescript.mdx | 2 +- .../live-examples/configurable-cad-part.mdx | 2 +- .../live-examples/static-3d-model-script.mdx | 4 +- .../runners/table-configurator-blockly.mdx | 4 +- .../learn/runners/table-configurator-rete.mdx | 2 +- .../runners/table-configurator-typescript.mdx | 2 +- docs/static/llms.txt | 16 +- .../babylonjs/laptop-holder/package-lock.json | 276 ++++---- .../babylonjs/laptop-holder/package.json | 2 +- .../angular/threejs/simple/package-lock.json | 184 +++--- examples/angular/threejs/simple/package.json | 2 +- .../vite-basic-example/package-lock.json | 103 +-- .../threejs/vite-basic-example/package.json | 2 +- .../src/workers/manifold.worker.ts | 2 +- .../nextjs/babylonjs/simple/package-lock.json | 149 +++-- examples/nextjs/babylonjs/simple/package.json | 2 +- examples/node/basic/package-lock.json | 16 +- examples/node/basic/package.json | 2 +- examples/node/express-app/package-lock.json | 187 +++--- examples/node/express-app/package.json | 2 +- .../nuxt/babylonjs/basic/package-lock.json | 149 +++-- examples/nuxt/babylonjs/basic/package.json | 2 +- examples/package.json | 10 +- .../react/babylonjs/cup/package-lock.json | 276 ++++---- examples/react/babylonjs/cup/package.json | 2 +- .../babylonjs/laptop-holder/package-lock.json | 276 ++++---- .../babylonjs/laptop-holder/package.json | 2 +- examples/react/threejs/vase/package-lock.json | 103 +-- examples/react/threejs/vase/package.json | 2 +- .../babylon/full/inline-include/index.html | 2 +- .../full/simple-all-kernels/index.html | 2 +- .../playcanvas/full/inline-include/index.html | 2 +- .../threejs/full/inline-include/index.html | 2 +- .../hex-house-concept/package-lock.json | 291 ++++---- .../babylonjs/hex-house-concept/package.json | 2 +- .../src/workers/manifold.worker.ts | 2 +- .../babylonjs/hex-shell/package-lock.json | 291 ++++---- .../vite/babylonjs/hex-shell/package.json | 2 +- .../hex-shell/src/workers/manifold.worker.ts | 2 +- .../starter-template-full/package-lock.json | 291 ++++---- .../starter-template-full/package.json | 2 +- .../starter-template/package-lock.json | 291 ++++---- .../babylonjs/starter-template/package.json | 2 +- .../hex-house-concept/package-lock.json | 229 +++---- .../playcanvas/hex-house-concept/package.json | 2 +- .../src/workers/manifold.worker.ts | 2 +- .../playcanvas/hex-shell/package-lock.json | 231 +++---- .../vite/playcanvas/hex-shell/package.json | 4 +- .../hex-shell/src/workers/manifold.worker.ts | 2 +- .../starter-template-full/package-lock.json | 623 ++++++++++++++++-- .../starter-template-full/package.json | 4 +- .../starter-template/package-lock.json | 623 ++++++++++++++++-- .../playcanvas/starter-template/package.json | 4 +- examples/vite/threejs/cup/package-lock.json | 103 +-- examples/vite/threejs/cup/package.json | 2 +- .../cup/src/workers/manifold.worker.ts | 2 +- .../hex-house-concept/package-lock.json | 199 +++--- .../threejs/hex-house-concept/package.json | 2 +- .../src/workers/manifold.worker.ts | 2 +- .../vite/threejs/hex-shell/package-lock.json | 199 +++--- examples/vite/threejs/hex-shell/package.json | 2 +- .../hex-shell/src/workers/manifold.worker.ts | 2 +- .../starter-template-full/package-lock.json | 199 +++--- .../starter-template-full/package.json | 2 +- .../starter-template/package-lock.json | 199 +++--- .../threejs/starter-template/package.json | 2 +- examples/webpack/threejs/package-lock.json | 103 +-- examples/webpack/threejs/package.json | 2 +- .../threejs/src/html/cup-three/index.html | 2 +- .../threejs/src/html/homepage/index.html | 2 +- .../src/html/manifold-sliced-mesh/index.html | 2 +- .../threejs/src/html/patterns/index.html | 2 +- examples/webpack/threejs/webpack.config.js | 2 +- llms.txt | 16 +- package.json | 2 +- packages/dev/babylonjs/package-lock.json | 299 +++++---- packages/dev/babylonjs/package.json | 14 +- .../dev/base/lib/api/GlobalCDNProvider.ts | 2 +- packages/dev/base/package-lock.json | 4 +- packages/dev/base/package.json | 2 +- packages/dev/core/package-lock.json | 203 +++--- packages/dev/core/package.json | 10 +- packages/dev/create-app/package.json | 2 +- packages/dev/create-app/src/index.ts | 2 +- .../vite/babylonjs/typescript/package.json | 2 +- .../vite/playcanvas/typescript/package.json | 4 +- .../vite/threejs/typescript/package.json | 2 +- packages/dev/jscad-worker/package-lock.json | 34 +- packages/dev/jscad-worker/package.json | 4 +- packages/dev/jscad/package-lock.json | 18 +- packages/dev/jscad/package.json | 4 +- .../dev/manifold-worker/package-lock.json | 34 +- packages/dev/manifold-worker/package.json | 4 +- packages/dev/manifold/package-lock.json | 18 +- packages/dev/manifold/package.json | 4 +- packages/dev/occt-worker/package-lock.json | 34 +- packages/dev/occt-worker/package.json | 4 +- packages/dev/occt/package-lock.json | 18 +- packages/dev/occt/package.json | 4 +- packages/dev/playcanvas/package-lock.json | 243 +++---- packages/dev/playcanvas/package.json | 6 +- packages/dev/threejs/package-lock.json | 229 +++---- packages/dev/threejs/package.json | 4 +- 185 files changed, 4314 insertions(+), 3239 deletions(-) diff --git a/docs/blog/2024-11-08-updated-bitbybit-runners.md b/docs/blog/2024-11-08-updated-bitbybit-runners.md index 3c47dcda..598a0e49 100644 --- a/docs/blog/2024-11-08-updated-bitbybit-runners.md +++ b/docs/blog/2024-11-08-updated-bitbybit-runners.md @@ -155,7 +155,7 @@ For production applications requiring maximum reliability and control, consider ``` -**Note:** You should replace `` with an actual version number (e.g., `0.21.0`). You can find all the official versions of Bitbybit.dev here: +**Note:** You should replace `` with an actual version number (e.g., `0.21.1`). You can find all the official versions of Bitbybit.dev here: ➡️ **[Bitbybit.dev GitHub Releases](https://github.com/bitbybit-dev/bitbybit/releases)** ### Examples of the Runners diff --git a/docs/learn/3d-bits/theme-app-extensions/bitbybit-viewer.md b/docs/learn/3d-bits/theme-app-extensions/bitbybit-viewer.md index 67c7d367..f1374152 100644 --- a/docs/learn/3d-bits/theme-app-extensions/bitbybit-viewer.md +++ b/docs/learn/3d-bits/theme-app-extensions/bitbybit-viewer.md @@ -110,7 +110,7 @@ Save your JSON configurator as a file, upload it to Shopify CDN as a file. Copy While our Viewer Editor is the recommended way to create and manage the Scene Config JSON, you can also edit the JSON directly using any text editor. For a better editing experience with features like syntax highlighting and autocompletion (intellisense), we provide a JSON schema. -* **JSON Schema:** You can find the schema [here](https://app-store.bitbybit.dev/files/ecommerce/viewer-editor/viewer-scene-schema-v0.21.0.json). (Note: This schema link points to version `0.21.0`. The schema may be updated in the future, so ensure you refer to the latest version compatible with your "3D Bits" app version.) +* **JSON Schema:** You can find the schema [here](https://app-store.bitbybit.dev/files/ecommerce/viewer-editor/viewer-scene-schema-v0.21.1.json). (Note: This schema link points to version `0.21.1`. The schema may be updated in the future, so ensure you refer to the latest version compatible with your "3D Bits" app version.) Many modern code editors (like VS Code) can use this schema to provide validation and autocompletion as you edit the JSON. ## Video Tutorial: BITBYBIT VIEWER Block Setup diff --git a/docs/learn/3d-bits/tutorials/bitbybit-viewer/settings.md b/docs/learn/3d-bits/tutorials/bitbybit-viewer/settings.md index 8e973a47..b9e2b9cc 100644 --- a/docs/learn/3d-bits/tutorials/bitbybit-viewer/settings.md +++ b/docs/learn/3d-bits/tutorials/bitbybit-viewer/settings.md @@ -203,7 +203,7 @@ The system automatically detects if you're providing a URL (starting with `http: - For complex configurations, use a URL to an external JSON file - it keeps your theme settings cleaner and makes updates easier - Use the Viewer Editor to generate valid configurations - Test your scene configuration thoroughly before going live -- The scene configuration follows a [JSON schema](https://app-store.bitbybit.dev/files/ecommerce/viewer-editor/viewer-scene-schema-v0.21.0.json) that defines all available options +- The scene configuration follows a [JSON schema](https://app-store.bitbybit.dev/files/ecommerce/viewer-editor/viewer-scene-schema-v0.21.1.json) that defines all available options ::: --- diff --git a/docs/learn/3d-bits/tutorials/getting-started/common-settings.md b/docs/learn/3d-bits/tutorials/getting-started/common-settings.md index 0391a967..25998ab7 100644 --- a/docs/learn/3d-bits/tutorials/getting-started/common-settings.md +++ b/docs/learn/3d-bits/tutorials/getting-started/common-settings.md @@ -121,7 +121,7 @@ These settings are specific to RUNNER and APPS blocks: ### Runner CDN Link **Available in:** VIEWER, RUNNER -**Default:** `https://cdn.jsdelivr.net/gh/bitbybit-dev/bitbybit-assets@0.21.0/runner/bitbybit-runner-babylonjs.js` +**Default:** `https://cdn.jsdelivr.net/gh/bitbybit-dev/bitbybit-assets@0.21.1/runner/bitbybit-runner-babylonjs.js` Specifies which version of the Bitbybit runner library to use. The runner is the core engine that loads and renders 3D content in your browser. @@ -173,7 +173,7 @@ The URL follows this pattern: https://cdn.jsdelivr.net/gh/bitbybit-dev/bitbybit-assets@{VERSION}/runner/bitbybit-runner-babylonjs.js ``` -Replace `{VERSION}` with the desired version number (e.g., `0.21.0`). +Replace `{VERSION}` with the desired version number (e.g., `0.21.1`). **Self-Hosting on Shopify CDN:** diff --git a/docs/learn/3d-bits/tutorials/videos-tutorials/product-customizable-text.mdx b/docs/learn/3d-bits/tutorials/videos-tutorials/product-customizable-text.mdx index f434f318..939d7880 100644 --- a/docs/learn/3d-bits/tutorials/videos-tutorials/product-customizable-text.mdx +++ b/docs/learn/3d-bits/tutorials/videos-tutorials/product-customizable-text.mdx @@ -153,7 +153,7 @@ To save you time, here is the embedded Bitbybit Rete script used in this tutoria diff --git a/docs/learn/3d-bits/tutorials/videos-tutorials/product-laptop-holder.mdx b/docs/learn/3d-bits/tutorials/videos-tutorials/product-laptop-holder.mdx index 93013b72..2d95288a 100644 --- a/docs/learn/3d-bits/tutorials/videos-tutorials/product-laptop-holder.mdx +++ b/docs/learn/3d-bits/tutorials/videos-tutorials/product-laptop-holder.mdx @@ -63,7 +63,7 @@ To save you time and provide a starting point, here is the embedded Bitbybit Typ {\n\n laptops.forEach(laptop => {\n laptop.center = [0, laptop.height / 2 + laptopLiftedHeight, 0] as Bit.Inputs.Base.Point3;\n });\n\n let laptopFillets = [];\n let totalDistance = 0;\n let previousLaptopLength = 0;\n\n laptops.forEach(async (laptop, index) => {\n totalDistance += distanceBetweenLaptops + laptop.length / 2 + previousLaptopLength / 2;\n previousLaptopLength = laptop.length;\n laptop.center[2] = totalDistance;\n const laptopBaseModel = await bitbybit.occt.shapes.solid.createBox({\n width: laptop.width,\n length: laptop.length,\n height: laptop.height,\n center: laptop.center\n });\n const laptopFillet = await bitbybit.occt.fillets.filletEdges({ shape: laptopBaseModel, indexes: undefined, radius: 0.2 });\n laptopFillets.push(laptopFillet);\n\n const laptopVisModel = await bitbybit.occt.shapes.solid.createBox({\n width: laptop.width,\n length: laptop.length - 0.01,\n height: laptop.height,\n center: laptop.center\n });\n const laptopVisFillet = await bitbybit.occt.fillets.filletEdges({ shape: laptopVisModel, indexes: undefined, radius: 0.2 });\n laptopFillets.push(laptopFillet);\n\n const di = new Bit.Inputs.Draw.DrawOcctShapeOptions();\n\n di.faceOpacity = 0.2;\n di.edgeWidth = 5;\n di.edgeOpacity = 0.6;\n di.edgeColour = whiteColor;\n di.faceColour = whiteColor;\n const laptopFilletMesh = await bitbybit.draw.drawAnyAsync({ entity: laptopVisFillet, options: di });\n laptopsFilletsMesh.push(laptopFilletMesh);\n })\n\n const polygonWire = await bitbybit.occt.shapes.wire.createPolygonWire({\n points: controlPoints\n });\n const extrusion = await bitbybit.occt.operations.extrude({\n shape: polygonWire, direction: [0, 0, totalDistance += distanceBetweenLaptops + previousLaptopLength / 2]\n });\n const laptopStandFillet = await bitbybit.occt.fillets.filletEdges({ shape: extrusion, indexes: undefined, radius: 1 });\n const laptopStandThick = await bitbybit.occt.operations.makeThickSolidSimple({ shape: laptopStandFillet, offset: -0.5 });\n\n laptopStand = await bitbybit.occt.booleans.difference({ shape: laptopStandThick, shapes: laptopFillets, keepEdges: false });\n const li = new Bit.Inputs.OCCT.DrawShapeDto(laptopStand);\n li.faceOpacity = 1;\n if (flipColor) {\n li.faceColour = \"#0000ff\";\n li.edgeColour = whiteColor;\n } else {\n li.faceColour = holderColor;\n li.edgeColour = whiteColor;\n }\n li.edgeWidth = 5;\n laptopStandMesh = await bitbybit.draw.drawAnyAsync({ entity: laptopStand, options: li });\n const laptopsMeshes = await Promise.all(laptopsFilletsMesh);\n return [laptopStandMesh, ...laptopsMeshes];\n }\n\n const meshes = await renderLaptops(laptops);\n return { meshes };\n}\n\nclass Laptop {\n width: number;\n length: number;\n height: number;\n center?: Bit.Inputs.Base.Point3;\n}\n\nBit.setBitbybitRunnerResult(start());","version":"0.21.0","type":"typescript"}} + script={{"script":"Bit.mockBitbybitRunnerInputs({\n \"Laptop Type\": \"MacBook Pro 16\",\n \"Number Laptops\": \"3\",\n \"Color\": \"Black\",\n});\nconst inputs = Bit.getBitbybitRunnerInputs();\n\nconst laptops: Laptop[] = []\n\nlet laptop: Laptop;\n\nswitch (inputs[\"Laptop Type\"]) {\n case \"MacBook Pro 16\":\n laptop = {\n length: 1.63,\n width: 35.8,\n height: 24.6\n };\n break;\n case \"MacBook Pro 14\":\n laptop = {\n length: 1.57,\n width: 31.3,\n height: 22.2\n }\n break;\n case \"MacBook Air\":\n laptop = {\n length: 1.2,\n width: 30.5,\n height: 21.6\n }\n break;\n default:\n break;\n}\n\nlet flipColor = false;\nswitch (inputs[\"Color\"]) {\n case \"Blue\":\n flipColor = true;\n break;\n default:\n break;\n}\n\nconsole.log(\"laptop \", laptop);\n\nconst nrLaptops = +inputs[\"Number Laptops\"];\n\nfor (let i = 0; i < nrLaptops; i++) {\n laptops.push({ ...laptop });\n}\n\nconst whiteColor = \"#ffffff\";\nconst holderColor = \"#333333\";\n\nconst laptopLiftedHeight = 3;\nconst distanceBetweenLaptops = 1.7;\nconst exportSTEP = false;\n\nbitbybit.babylon.scene.backgroundColour({ colour: \"#bbbbbb\" });\n\nconst pointLightConf = new Bit.Inputs.BabylonScene.PointLightDto();\npointLightConf.position = [-15, 20, -5];\npointLightConf.intensity = 8000;\npointLightConf.diffuse = \"#3333ff\";\npointLightConf.radius = 0;\nbitbybit.babylon.scene.drawPointLight(pointLightConf);\n\nconst controlPoints = [\n [-12.5, 0, 0],\n [-8, 13, 0],\n [-4, 11, 0],\n [-2, 6, 0],\n [2, 6, 0],\n [4, 14, 0],\n [8, 17, 0],\n [12.5, 0, 0]\n] as Bit.Inputs.Base.Point3[];\n\nlet laptopStand;\nlet laptopStandMesh;\n\nconst laptopsFilletsMesh = [];\n\nasync function start() {\n const ground = await bitbybit.occt.shapes.face.createCircleFace({ center: [0, 0, 0], direction: [0, 1, 0], radius: 75, });\n const groundOptions = new Bit.Inputs.Draw.DrawOcctShapeOptions();\n groundOptions.faceColour = whiteColor;\n groundOptions.drawEdges = false;\n await bitbybit.draw.drawAnyAsync({ entity: ground, options: groundOptions });\n\n const renderLaptops = async (laptops) => {\n\n laptops.forEach(laptop => {\n laptop.center = [0, laptop.height / 2 + laptopLiftedHeight, 0] as Bit.Inputs.Base.Point3;\n });\n\n let laptopFillets = [];\n let totalDistance = 0;\n let previousLaptopLength = 0;\n\n laptops.forEach(async (laptop, index) => {\n totalDistance += distanceBetweenLaptops + laptop.length / 2 + previousLaptopLength / 2;\n previousLaptopLength = laptop.length;\n laptop.center[2] = totalDistance;\n const laptopBaseModel = await bitbybit.occt.shapes.solid.createBox({\n width: laptop.width,\n length: laptop.length,\n height: laptop.height,\n center: laptop.center\n });\n const laptopFillet = await bitbybit.occt.fillets.filletEdges({ shape: laptopBaseModel, indexes: undefined, radius: 0.2 });\n laptopFillets.push(laptopFillet);\n\n const laptopVisModel = await bitbybit.occt.shapes.solid.createBox({\n width: laptop.width,\n length: laptop.length - 0.01,\n height: laptop.height,\n center: laptop.center\n });\n const laptopVisFillet = await bitbybit.occt.fillets.filletEdges({ shape: laptopVisModel, indexes: undefined, radius: 0.2 });\n laptopFillets.push(laptopFillet);\n\n const di = new Bit.Inputs.Draw.DrawOcctShapeOptions();\n\n di.faceOpacity = 0.2;\n di.edgeWidth = 5;\n di.edgeOpacity = 0.6;\n di.edgeColour = whiteColor;\n di.faceColour = whiteColor;\n const laptopFilletMesh = await bitbybit.draw.drawAnyAsync({ entity: laptopVisFillet, options: di });\n laptopsFilletsMesh.push(laptopFilletMesh);\n })\n\n const polygonWire = await bitbybit.occt.shapes.wire.createPolygonWire({\n points: controlPoints\n });\n const extrusion = await bitbybit.occt.operations.extrude({\n shape: polygonWire, direction: [0, 0, totalDistance += distanceBetweenLaptops + previousLaptopLength / 2]\n });\n const laptopStandFillet = await bitbybit.occt.fillets.filletEdges({ shape: extrusion, indexes: undefined, radius: 1 });\n const laptopStandThick = await bitbybit.occt.operations.makeThickSolidSimple({ shape: laptopStandFillet, offset: -0.5 });\n\n laptopStand = await bitbybit.occt.booleans.difference({ shape: laptopStandThick, shapes: laptopFillets, keepEdges: false });\n const li = new Bit.Inputs.OCCT.DrawShapeDto(laptopStand);\n li.faceOpacity = 1;\n if (flipColor) {\n li.faceColour = \"#0000ff\";\n li.edgeColour = whiteColor;\n } else {\n li.faceColour = holderColor;\n li.edgeColour = whiteColor;\n }\n li.edgeWidth = 5;\n laptopStandMesh = await bitbybit.draw.drawAnyAsync({ entity: laptopStand, options: li });\n const laptopsMeshes = await Promise.all(laptopsFilletsMesh);\n return [laptopStandMesh, ...laptopsMeshes];\n }\n\n const meshes = await renderLaptops(laptops);\n return { meshes };\n}\n\nclass Laptop {\n width: number;\n length: number;\n height: number;\n center?: Bit.Inputs.Base.Point3;\n}\n\nBit.setBitbybitRunnerResult(start());","version":"0.21.1","type":"typescript"}} title="Bitbybit Rete Editor - 3D Laptop Holder" description="3D Laptop holder configurator" /> diff --git a/docs/learn/3d-bits/tutorials/videos-tutorials/product-palm-table.mdx b/docs/learn/3d-bits/tutorials/videos-tutorials/product-palm-table.mdx index b102aaa3..f6ac7d3f 100644 --- a/docs/learn/3d-bits/tutorials/videos-tutorials/product-palm-table.mdx +++ b/docs/learn/3d-bits/tutorials/videos-tutorials/product-palm-table.mdx @@ -157,7 +157,7 @@ To save you time, here is the embedded Rete script used in this tutorial for the diff --git a/docs/learn/code/common/base/color/color-usage-examples.md b/docs/learn/code/common/base/color/color-usage-examples.md index 0dcde0d1..c1c3d340 100644 --- a/docs/learn/code/common/base/color/color-usage-examples.md +++ b/docs/learn/code/common/base/color/color-usage-examples.md @@ -48,21 +48,21 @@ Click through the tabs below to see the implementation. You can interact with th colorParamfaceColoredgeColorcolorParam0faceColorcolorParam255colorParam0255edgeColor#0000ff6000TRUE0.01TRUEfaceColorTRUEedgeColor10","version":"0.21.0","type":"blockly"}} + script={{"script":"colorParamfaceColoredgeColorcolorParam0faceColorcolorParam255colorParam0255edgeColor#0000ff6000TRUE0.01TRUEfaceColorTRUEedgeColor10","version":"0.21.1","type":"blockly"}} title="Color Usage Example" /> {\n\n const colorParam = 55;\n const rgbToHexOptions = new Bit.Inputs.Color.RGBMinMaxDto();\n rgbToHexOptions.r = colorParam;\n rgbToHexOptions.b = colorParam;\n const faceColor = bitbybit.color.rgbToHex(rgbToHexOptions);\n\n // This might look strange as you could just assign the string to edgeColor directly, \n // but this identity function is nice to have in visual prgramming editors - check Rete & Blockly\n // examples\n \n const edgeColor = bitbybit.color.hexColor({ color: \"#ff0000\" });\n\n const cubeOptions = new Bit.Inputs.OCCT.CubeDto();\n cubeOptions.size = 6;\n const cube = await bitbybit.occt.shapes.solid.createCube(cubeOptions);\n\n const drawOpt = new Bit.Inputs.Draw.DrawOcctShapeSimpleOptions();\n drawOpt.faceColour = faceColor;\n drawOpt.edgeColour = edgeColor;\n drawOpt.edgeWidth = 10;\n bitbybit.draw.drawAnyAsync({ entity: cube, options: drawOpt });\n}\n\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"const start = async () => {\n\n const colorParam = 55;\n const rgbToHexOptions = new Bit.Inputs.Color.RGBMinMaxDto();\n rgbToHexOptions.r = colorParam;\n rgbToHexOptions.b = colorParam;\n const faceColor = bitbybit.color.rgbToHex(rgbToHexOptions);\n\n // This might look strange as you could just assign the string to edgeColor directly, \n // but this identity function is nice to have in visual prgramming editors - check Rete & Blockly\n // examples\n \n const edgeColor = bitbybit.color.hexColor({ color: \"#ff0000\" });\n\n const cubeOptions = new Bit.Inputs.OCCT.CubeDto();\n cubeOptions.size = 6;\n const cube = await bitbybit.occt.shapes.solid.createCube(cubeOptions);\n\n const drawOpt = new Bit.Inputs.Draw.DrawOcctShapeSimpleOptions();\n drawOpt.faceColour = faceColor;\n drawOpt.edgeColour = edgeColor;\n drawOpt.edgeWidth = 10;\n bitbybit.draw.drawAnyAsync({ entity: cube, options: drawOpt });\n}\n\nstart();","version":"0.21.1","type":"typescript"}} title="Color Usage Example" /> diff --git a/docs/learn/code/common/base/point/point-hex-grid-example.md b/docs/learn/code/common/base/point/point-hex-grid-example.md index d804f410..7a88d8e6 100644 --- a/docs/learn/code/common/base/point/point-hex-grid-example.md +++ b/docs/learn/code/common/base/point/point-hex-grid-example.md @@ -55,21 +55,21 @@ Click through the tabs below to see the implementation. Each example will genera hexagonspointshexCornershexPolylinesihexagons20101010FALSEFALSEFALSEFALSEFALSETRUEFALSEpointshexagonscentershexCornershexagonshexagonshexPolylinesihexCornersINSERTLASThexPolylinesiTRUEpointshexPolylines","version":"0.21.0","type":"blockly"}} + script={{"script":"hexagonspointshexCornershexPolylinesihexagons20101010FALSEFALSEFALSEFALSEFALSETRUEFALSEpointshexagonscentershexCornershexagonshexagonshexPolylinesihexCornersINSERTLASThexPolylinesiTRUEpointshexPolylines","version":"0.21.1","type":"blockly"}} title="Point Hex Grid Example" /> {\n\n // 1. Configure the hexagonal grid options\n const hexOptions = new Bit.Inputs.Point.HexGridScaledToFitDto();\n // Set options different from defaults. \n // TypeScript IntelliSense (e.g., typing \"hexOptions.\") will show all available parameters.\n hexOptions.width = 20;\n hexOptions.height = 10;\n hexOptions.nrHexagonsInWidth = 10;\n hexOptions.nrHexagonsInHeight = 10;\n hexOptions.centerGrid = true; // Center the entire grid at the world origin [0,0,0]\n // Example: hexOptions.flatTop = true; // To get flat-topped hexagons\n // Example: hexOptions.pointsOnGround = true; // To project to XZ plane if original is XY\n\n // 2. Generate the hex grid data\n // This function returns an object like: \n // { centers: Point3[], hexagons: Point3[][], shortestDistEdge, longestDistEdge, maxFilletRadius }\n const hexResult = bitbybit.point.hexGridScaledToFit(hexOptions);\n\n // 3. Create polylines for each hexagon's outline\n // hexResult.hexagons is a list of lists (e.g., [[v1,v2..v6 for hex1], [v1,v2..v6 for hex2], ...])\n // We .map() over this list to create a Polyline object for each hexagon.\n const polylines = hexResult.hexagons.map(singleHexagonCornerPoints => {\n const polylineOptions = new Bit.Inputs.Polyline.PolylineCreateDto();\n polylineOptions.points = singleHexagonCornerPoints; // The 6 corner points\n polylineOptions.isClosed = true; // Ensure the polyline forms a closed loop\n return bitbybit.polyline.create(polylineOptions);\n }) as Bit.Inputs.Base.Polyline3[]; // Type assertion: the result is an array of Polyline3 objects\n\n // 4. Draw the center points of the hexagons\n // hexResult.centers is a list of 3D points: [[cx1,cy1,cz1], [cx2,cy2,cz2], ...]\n bitbybit.draw.drawAnyAsync({ entity: hexResult.centers });\n\n // 5. Draw the polylines representing the hexagon outlines\n bitbybit.draw.drawAnyAsync({ entity: polylines });\n\n}\n\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"const start = () => {\n\n // 1. Configure the hexagonal grid options\n const hexOptions = new Bit.Inputs.Point.HexGridScaledToFitDto();\n // Set options different from defaults. \n // TypeScript IntelliSense (e.g., typing \"hexOptions.\") will show all available parameters.\n hexOptions.width = 20;\n hexOptions.height = 10;\n hexOptions.nrHexagonsInWidth = 10;\n hexOptions.nrHexagonsInHeight = 10;\n hexOptions.centerGrid = true; // Center the entire grid at the world origin [0,0,0]\n // Example: hexOptions.flatTop = true; // To get flat-topped hexagons\n // Example: hexOptions.pointsOnGround = true; // To project to XZ plane if original is XY\n\n // 2. Generate the hex grid data\n // This function returns an object like: \n // { centers: Point3[], hexagons: Point3[][], shortestDistEdge, longestDistEdge, maxFilletRadius }\n const hexResult = bitbybit.point.hexGridScaledToFit(hexOptions);\n\n // 3. Create polylines for each hexagon's outline\n // hexResult.hexagons is a list of lists (e.g., [[v1,v2..v6 for hex1], [v1,v2..v6 for hex2], ...])\n // We .map() over this list to create a Polyline object for each hexagon.\n const polylines = hexResult.hexagons.map(singleHexagonCornerPoints => {\n const polylineOptions = new Bit.Inputs.Polyline.PolylineCreateDto();\n polylineOptions.points = singleHexagonCornerPoints; // The 6 corner points\n polylineOptions.isClosed = true; // Ensure the polyline forms a closed loop\n return bitbybit.polyline.create(polylineOptions);\n }) as Bit.Inputs.Base.Polyline3[]; // Type assertion: the result is an array of Polyline3 objects\n\n // 4. Draw the center points of the hexagons\n // hexResult.centers is a list of 3D points: [[cx1,cy1,cz1], [cx2,cy2,cz2], ...]\n bitbybit.draw.drawAnyAsync({ entity: hexResult.centers });\n\n // 5. Draw the polylines representing the hexagon outlines\n bitbybit.draw.drawAnyAsync({ entity: polylines });\n\n}\n\nstart();","version":"0.21.1","type":"typescript"}} title="Point Hex Grid Example" /> diff --git a/docs/learn/code/common/base/point/point-spiral-examples.md b/docs/learn/code/common/base/point/point-spiral-examples.md index 20ce680d..889d272d 100644 --- a/docs/learn/code/common/base/point/point-spiral-examples.md +++ b/docs/learn/code/common/base/point/point-spiral-examples.md @@ -45,21 +45,21 @@ Click through the tabs below to see the implementation. Each example will genera 0.9300361","version":"0.21.0","type":"blockly"}} + script={{"script":"0.9300361","version":"0.21.1","type":"blockly"}} title="Point Spiral Example" /> {\n\n // 1. Configure the spiral parameters\n const spiralOptions = new Bit.Inputs.Point.SpiralDto();\n spiralOptions.numberPoints = 300;\n spiralOptions.radius = 6; // Overall extent of the spiral; default is 1\n spiralOptions.widening = 3; // Controls how tight the spiral is; default is 10\n spiralOptions.phi = 0.9; // Constant influencing the spiral pattern; default relates to Golden Angle\n spiralOptions.factor = 1; // General scaling factor; default is 1\n\n // 2. Generate the list of points forming the spiral\n // The bitbybit.point.spiral() function returns an array of 3D points.\n const points = bitbybit.point.spiral(spiralOptions);\n\n // 3. Draw the generated points in the scene\n // The drawAnyAsync function can take an array of points and will render them.\n bitbybit.draw.drawAnyAsync({ entity: points });\n\n}\n\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"const start = () => {\n\n // 1. Configure the spiral parameters\n const spiralOptions = new Bit.Inputs.Point.SpiralDto();\n spiralOptions.numberPoints = 300;\n spiralOptions.radius = 6; // Overall extent of the spiral; default is 1\n spiralOptions.widening = 3; // Controls how tight the spiral is; default is 10\n spiralOptions.phi = 0.9; // Constant influencing the spiral pattern; default relates to Golden Angle\n spiralOptions.factor = 1; // General scaling factor; default is 1\n\n // 2. Generate the list of points forming the spiral\n // The bitbybit.point.spiral() function returns an array of 3D points.\n const points = bitbybit.point.spiral(spiralOptions);\n\n // 3. Draw the generated points in the scene\n // The drawAnyAsync function can take an array of points and will render them.\n bitbybit.draw.drawAnyAsync({ entity: points });\n\n}\n\nstart();","version":"0.21.1","type":"typescript"}} title="Point Spiral Example" /> diff --git a/docs/learn/code/common/base/text/text-usage-examples.md b/docs/learn/code/common/base/text/text-usage-examples.md index 1cb4fbdf..1a2cd610 100644 --- a/docs/learn/code/common/base/text/text-usage-examples.md +++ b/docs/learn/code/common/base/text/text-usage-examples.md @@ -53,21 +53,21 @@ Click through the tabs below to see the implementation. Each example will create namewordwordListnameJohnwordawesomewordListnamewordHi {0}, you are {1}!wordList'Roboto''Regular'20.2180000010'centerMiddle'","version":"0.21.0","type":"blockly"}} + script={{"script":"namewordwordListnameJohnwordawesomewordListnamewordHi {0}, you are {1}!wordList'Roboto''Regular'20.2180000010'centerMiddle'","version":"0.21.1","type":"blockly"}} title="Text Formatting And 3D Fonts" /> {\n const name = \"John\";\n const word = \"awesome\";\n\n const formatOpt = new Bit.Inputs.Text.TextFormatDto();\n formatOpt.text = \"Hi {0}, you are {1}!\";\n formatOpt.values = [name, word];\n const formattedText = bitbybit.text.format(formatOpt);\n\n const text3dOptions = new Bit.Advanced.Text3D.Text3DDto();\n text3dOptions.text = formattedText;\n text3dOptions.rotation = 180;\n text3dOptions.fontSize = 2;\n const text3d = await bitbybit.advanced.text3d.create(text3dOptions);\n bitbybit.draw.drawAnyAsync({ entity: text3d });\n}\n\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"const start = async () => {\n const name = \"John\";\n const word = \"awesome\";\n\n const formatOpt = new Bit.Inputs.Text.TextFormatDto();\n formatOpt.text = \"Hi {0}, you are {1}!\";\n formatOpt.values = [name, word];\n const formattedText = bitbybit.text.format(formatOpt);\n\n const text3dOptions = new Bit.Advanced.Text3D.Text3DDto();\n text3dOptions.text = formattedText;\n text3dOptions.rotation = 180;\n text3dOptions.fontSize = 2;\n const text3d = await bitbybit.advanced.text3d.create(text3dOptions);\n bitbybit.draw.drawAnyAsync({ entity: text3d });\n}\n\nstart();","version":"0.21.1","type":"typescript"}} title="Text Formatting And 3D Fonts" /> diff --git a/docs/learn/code/common/base/vector/vector-usage-examples.md b/docs/learn/code/common/base/vector/vector-usage-examples.md index 6a8072c8..23b6b303 100644 --- a/docs/learn/code/common/base/vector/vector-usage-examples.md +++ b/docs/learn/code/common/base/vector/vector-usage-examples.md @@ -60,21 +60,21 @@ Click through the tabs below to see the implementation in Rete, Blockly, and Typ spanItemsspanEaseItemsvectorsj40040010100.450.50.5FALSE#ffffff#ffffffspanItems0.205spanEaseItemsspanItems05'easeInSine'FALSEvectorsj1spanItems1INSERTLASTvectorsGETFROM_STARTspanItemsjGETFROM_STARTspanEaseItemsj0vectorsvectors","version":"0.21.0","type":"blockly"}} + script={{"script":"spanItemsspanEaseItemsvectorsj40040010100.450.50.5FALSE#ffffff#ffffffspanItems0.205spanEaseItemsspanItems05'easeInSine'FALSEvectorsj1spanItems1INSERTLASTvectorsGETFROM_STARTspanItemsjGETFROM_STARTspanEaseItemsj0vectorsvectors","version":"0.21.1","type":"blockly"}} title="Vector Span & Ease In Combination" /> {\n\n const spanOptions = new Bit.Inputs.Vector.SpanDto();\n spanOptions.step = 0.2;\n spanOptions.min = 0;\n spanOptions.max = 5;\n const spanItems = bitbybit.vector.span(spanOptions);\n\n const spanEaseOptions = new Bit.Inputs.Vector.SpanEaseItemsDto();\n spanEaseOptions.ease = Bit.Inputs.Math.easeEnum.easeInSine;\n spanEaseOptions.min = 0;\n spanEaseOptions.max = 5;\n spanEaseOptions.nrItems = spanItems.length;\n const spanEaseItems = bitbybit.vector.spanEaseItems(spanEaseOptions);\n\n const vectors = spanItems.map((s, index) => [s, spanEaseItems[index], 0]) as Bit.Inputs.Base.Vector3[];\n\n bitbybit.draw.drawGridMesh(new Bit.Inputs.Draw.SceneDrawGridMeshDto());\n bitbybit.draw.drawAnyAsync({ entity: vectors });\n\n}\n\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"const start = () => {\n\n const spanOptions = new Bit.Inputs.Vector.SpanDto();\n spanOptions.step = 0.2;\n spanOptions.min = 0;\n spanOptions.max = 5;\n const spanItems = bitbybit.vector.span(spanOptions);\n\n const spanEaseOptions = new Bit.Inputs.Vector.SpanEaseItemsDto();\n spanEaseOptions.ease = Bit.Inputs.Math.easeEnum.easeInSine;\n spanEaseOptions.min = 0;\n spanEaseOptions.max = 5;\n spanEaseOptions.nrItems = spanItems.length;\n const spanEaseItems = bitbybit.vector.spanEaseItems(spanEaseOptions);\n\n const vectors = spanItems.map((s, index) => [s, spanEaseItems[index], 0]) as Bit.Inputs.Base.Vector3[];\n\n bitbybit.draw.drawGridMesh(new Bit.Inputs.Draw.SceneDrawGridMeshDto());\n bitbybit.draw.drawAnyAsync({ entity: vectors });\n\n}\n\nstart();","version":"0.21.1","type":"typescript"}} title="Vector Span & Ease In Combination" /> diff --git a/docs/learn/code/common/draw/examples.mdx b/docs/learn/code/common/draw/examples.mdx index a803d9d9..d221a38e 100644 --- a/docs/learn/code/common/draw/examples.mdx +++ b/docs/learn/code/common/draw/examples.mdx @@ -28,7 +28,7 @@ The primary component for custom drawing is typically found under the path: **Rete Example: Filleted Cube with Custom Drawing Options** @@ -44,7 +44,7 @@ The primary block for custom drawing is typically found under: 5000TRUE111#ff6600#000099#cc33cc20.3TRUETRUETRUE0.01FALSE0.06#ff00ffFALSE0.06#0000ff","version":"0.21.0","type":"blockly"}} + script={{"script":"5000TRUE111#ff6600#000099#cc33cc20.3TRUETRUETRUE0.01FALSE0.06#ff00ffFALSE0.06#0000ff","version":"0.21.1","type":"blockly"}} title="Blockly Drawing Example" description="Draws simple filletted cube geometry." /> @@ -55,7 +55,7 @@ Finally, we achieve the same result using TypeScript. The code follows a similar {\n\n const cubeOptions = new Bit.Inputs.OCCT.CubeDto();\n cubeOptions.size = 5;\n const cube = await bitbybit.occt.shapes.solid.createCube(cubeOptions);\n const filletOptions = new Bit.Inputs.OCCT.FilletDto()\n filletOptions.shape = cube;\n filletOptions.radius = 1;\n const roundedCube = await bitbybit.occt.fillets.filletEdges(filletOptions);\n\n const drawOcctOptions = new Bit.Inputs.Draw.DrawOcctShapeOptions();\n drawOcctOptions.faceColour = \"#0000ff\";\n drawOcctOptions.edgeColour = \"#ff5555\";\n drawOcctOptions.drawVertices = true;\n drawOcctOptions.vertexSize = 0.3;\n // The rest of options remain default (initialized inside the instance)\n const drawnMesh = await bitbybit.draw.drawAnyAsync({ entity: roundedCube, options: drawOcctOptions })\n // drawnMesh is BABYLONJS Mesh if BabylonJS engine is used. In Three.JS it turns into Group.\n return drawnMesh;\n \n}\n\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"const start = async () => {\n\n const cubeOptions = new Bit.Inputs.OCCT.CubeDto();\n cubeOptions.size = 5;\n const cube = await bitbybit.occt.shapes.solid.createCube(cubeOptions);\n const filletOptions = new Bit.Inputs.OCCT.FilletDto()\n filletOptions.shape = cube;\n filletOptions.radius = 1;\n const roundedCube = await bitbybit.occt.fillets.filletEdges(filletOptions);\n\n const drawOcctOptions = new Bit.Inputs.Draw.DrawOcctShapeOptions();\n drawOcctOptions.faceColour = \"#0000ff\";\n drawOcctOptions.edgeColour = \"#ff5555\";\n drawOcctOptions.drawVertices = true;\n drawOcctOptions.vertexSize = 0.3;\n // The rest of options remain default (initialized inside the instance)\n const drawnMesh = await bitbybit.draw.drawAnyAsync({ entity: roundedCube, options: drawOcctOptions })\n // drawnMesh is BABYLONJS Mesh if BabylonJS engine is used. In Three.JS it turns into Group.\n return drawnMesh;\n \n}\n\nstart();","version":"0.21.1","type":"typescript"}} title="TypeScript Drawing Example" description="Draws simple filletted cube geometry." /> \ No newline at end of file diff --git a/docs/learn/code/common/occt/booleans/operations.mdx b/docs/learn/code/common/occt/booleans/operations.mdx index 323788d1..64a0d994 100644 --- a/docs/learn/code/common/occt/booleans/operations.mdx +++ b/docs/learn/code/common/occt/booleans/operations.mdx @@ -49,21 +49,21 @@ The following scripts demonstrate creating three solids (a box, a cylinder, and **TypeScript Example: Union of Solids** {\n const boxOpt = new Bit.Inputs.OCCT.BoxDto();\n boxOpt.width = 5;\n boxOpt.length = 8;\n boxOpt.height = 5;\n const box = await bitbybit.occt.shapes.solid.createBox(boxOpt);\n\n\n const cylinderOpt = new Bit.Inputs.OCCT.CylinderDto();\n cylinderOpt.radius = 3;\n cylinderOpt.height = 7;\n cylinderOpt.center = [3, 0, 3];\n const cylinder = await bitbybit.occt.shapes.solid.createCylinder(cylinderOpt);\n\n\n const sphereOpt = new Bit.Inputs.OCCT.SphereDto();\n sphereOpt.radius = 3;\n sphereOpt.center = [-1.5, 1.5, -5];\n const sphere = await bitbybit.occt.shapes.solid.createSphere(sphereOpt);\n\n const union = await bitbybit.occt.booleans.union({\n shapes: [box, cylinder, sphere],\n keepEdges: false\n })\n\n bitbybit.draw.drawAnyAsync({\n entity: union\n });\n}\n\nstart();\n","version":"0.21.0","type":"typescript"}} + script={{"script":"const start = async () => {\n const boxOpt = new Bit.Inputs.OCCT.BoxDto();\n boxOpt.width = 5;\n boxOpt.length = 8;\n boxOpt.height = 5;\n const box = await bitbybit.occt.shapes.solid.createBox(boxOpt);\n\n\n const cylinderOpt = new Bit.Inputs.OCCT.CylinderDto();\n cylinderOpt.radius = 3;\n cylinderOpt.height = 7;\n cylinderOpt.center = [3, 0, 3];\n const cylinder = await bitbybit.occt.shapes.solid.createCylinder(cylinderOpt);\n\n\n const sphereOpt = new Bit.Inputs.OCCT.SphereDto();\n sphereOpt.radius = 3;\n sphereOpt.center = [-1.5, 1.5, -5];\n const sphere = await bitbybit.occt.shapes.solid.createSphere(sphereOpt);\n\n const union = await bitbybit.occt.booleans.union({\n shapes: [box, cylinder, sphere],\n keepEdges: false\n })\n\n bitbybit.draw.drawAnyAsync({\n entity: union\n });\n}\n\nstart();\n","version":"0.21.1","type":"typescript"}} title="Union Three Solids" /> **Blockly Example: Union of Solids** boxspherecylinderbox585000sphere3-1.51.5-5cylinder37303010boxcylindersphereFALSE","version":"0.21.0","type":"blockly"}} + script={{"script":"boxspherecylinderbox585000sphere3-1.51.5-5cylinder37303010boxcylindersphereFALSE","version":"0.21.1","type":"blockly"}} title="Union Three Solids" /> **Rete Example: Union of Solids** @@ -94,21 +94,21 @@ These scripts demonstrate creating a box, cylinder, and sphere, then subtracting **TypeScript Example: Difference of Solids** {\n const boxOpt = new Bit.Inputs.OCCT.BoxDto();\n boxOpt.width = 5;\n boxOpt.length = 8;\n boxOpt.height = 5;\n const box = await bitbybit.occt.shapes.solid.createBox(boxOpt);\n\n\n const cylinderOpt = new Bit.Inputs.OCCT.CylinderDto();\n cylinderOpt.radius = 3;\n cylinderOpt.height = 7;\n cylinderOpt.center = [3, 0, 3];\n const cylinder = await bitbybit.occt.shapes.solid.createCylinder(cylinderOpt);\n\n\n const sphereOpt = new Bit.Inputs.OCCT.SphereDto();\n sphereOpt.radius = 3;\n sphereOpt.center = [-1.5, 1.5, -5];\n const sphere = await bitbybit.occt.shapes.solid.createSphere(sphereOpt);\n\n const diff = await bitbybit.occt.booleans.difference({\n shape: box,\n shapes: [cylinder, sphere],\n keepEdges: false\n })\n\n bitbybit.draw.drawAnyAsync({\n entity: diff\n });\n}\n\nstart();\n","version":"0.21.0","type":"typescript"}} + script={{"script":"const start = async () => {\n const boxOpt = new Bit.Inputs.OCCT.BoxDto();\n boxOpt.width = 5;\n boxOpt.length = 8;\n boxOpt.height = 5;\n const box = await bitbybit.occt.shapes.solid.createBox(boxOpt);\n\n\n const cylinderOpt = new Bit.Inputs.OCCT.CylinderDto();\n cylinderOpt.radius = 3;\n cylinderOpt.height = 7;\n cylinderOpt.center = [3, 0, 3];\n const cylinder = await bitbybit.occt.shapes.solid.createCylinder(cylinderOpt);\n\n\n const sphereOpt = new Bit.Inputs.OCCT.SphereDto();\n sphereOpt.radius = 3;\n sphereOpt.center = [-1.5, 1.5, -5];\n const sphere = await bitbybit.occt.shapes.solid.createSphere(sphereOpt);\n\n const diff = await bitbybit.occt.booleans.difference({\n shape: box,\n shapes: [cylinder, sphere],\n keepEdges: false\n })\n\n bitbybit.draw.drawAnyAsync({\n entity: diff\n });\n}\n\nstart();\n","version":"0.21.1","type":"typescript"}} title="Difference of Solids" /> **Blockly Example: Difference of Solids** boxspherecylinderbox585000sphere3-1.51.5-5cylinder37303010boxcylindersphereFALSE","version":"0.21.0","type":"blockly"}} + script={{"script":"boxspherecylinderbox585000sphere3-1.51.5-5cylinder37303010boxcylindersphereFALSE","version":"0.21.1","type":"blockly"}} title="Difference of Solids" /> **Rete Example: Difference of Solids** @@ -138,21 +138,21 @@ These scripts create a box, cylinder, and sphere, and then compute their common **TypeScript Example: Intersection of Solids** {\n const boxOpt = new Bit.Inputs.OCCT.BoxDto();\n boxOpt.width = 5;\n boxOpt.length = 8;\n boxOpt.height = 5;\n const box = await bitbybit.occt.shapes.solid.createBox(boxOpt);\n\n\n const cylinderOpt = new Bit.Inputs.OCCT.CylinderDto();\n cylinderOpt.radius = 3;\n cylinderOpt.height = 7;\n cylinderOpt.center = [3, 0, 3];\n const cylinder = await bitbybit.occt.shapes.solid.createCylinder(cylinderOpt);\n\n\n const sphereOpt = new Bit.Inputs.OCCT.SphereDto();\n sphereOpt.radius = 3;\n sphereOpt.center = [-1.5, 1.5, -5];\n const sphere = await bitbybit.occt.shapes.solid.createSphere(sphereOpt);\n\n const diff = await bitbybit.occt.booleans.intersection({\n shapes: [box, cylinder, sphere],\n keepEdges: false\n })\n\n bitbybit.draw.drawAnyAsync({\n entity: diff\n });\n}\n\nstart();\n","version":"0.21.0","type":"typescript"}} + script={{"script":"const start = async () => {\n const boxOpt = new Bit.Inputs.OCCT.BoxDto();\n boxOpt.width = 5;\n boxOpt.length = 8;\n boxOpt.height = 5;\n const box = await bitbybit.occt.shapes.solid.createBox(boxOpt);\n\n\n const cylinderOpt = new Bit.Inputs.OCCT.CylinderDto();\n cylinderOpt.radius = 3;\n cylinderOpt.height = 7;\n cylinderOpt.center = [3, 0, 3];\n const cylinder = await bitbybit.occt.shapes.solid.createCylinder(cylinderOpt);\n\n\n const sphereOpt = new Bit.Inputs.OCCT.SphereDto();\n sphereOpt.radius = 3;\n sphereOpt.center = [-1.5, 1.5, -5];\n const sphere = await bitbybit.occt.shapes.solid.createSphere(sphereOpt);\n\n const diff = await bitbybit.occt.booleans.intersection({\n shapes: [box, cylinder, sphere],\n keepEdges: false\n })\n\n bitbybit.draw.drawAnyAsync({\n entity: diff\n });\n}\n\nstart();\n","version":"0.21.1","type":"typescript"}} title="Intersection of Solids" /> **Blockly Example: Intersection of Solids** boxspherecylinderbox585000sphere3-1.51.5-5cylinder37303010boxcylindersphereFALSE","version":"0.21.0","type":"blockly"}} + script={{"script":"boxspherecylinderbox585000sphere3-1.51.5-5cylinder37303010boxcylindersphereFALSE","version":"0.21.1","type":"blockly"}} title="Intersection of Solids" /> **Rete Example: Intersection of Solids** diff --git a/docs/learn/code/common/occt/dimensions/angular-dimension.md b/docs/learn/code/common/occt/dimensions/angular-dimension.md index 7e96fcb2..b421993a 100644 --- a/docs/learn/code/common/occt/dimensions/angular-dimension.md +++ b/docs/learn/code/common/occt/dimensions/angular-dimension.md @@ -32,21 +32,21 @@ Angular dimensions measure the angle between two direction vectors and display t direction1direction2centerdirection1100direction2011center000direction1direction2center20.30.11deg0.30.4FALSE","version":"0.21.0","type":"blockly"}} + script={{"script":"direction1direction2centerdirection1100direction2011center000direction1direction2center20.30.11deg0.30.4FALSE","version":"0.21.1","type":"blockly"}} title="Simple angular dimension between two directions" /> {\n // Define two direction vectors to measure angle between\n const direction1: Vector3 = [1, 0, 0]; // X-axis direction\n const direction2: Vector3 = [0, 1, 1]; // Direction at 45deg from Y and Z\n const center: Point3 = [0, 0, 0]; // Origin point\n\n // Create an angular dimension between the directions\n const dimensionOptions = new SimpleAngularDimensionDto();\n dimensionOptions.direction1 = direction1;\n dimensionOptions.direction2 = direction2;\n dimensionOptions.center = center;\n dimensionOptions.radius = 2;\n dimensionOptions.offsetFromCenter = 0.3;\n dimensionOptions.extraSize = 0.1;\n dimensionOptions.decimalPlaces = 1;\n dimensionOptions.labelSuffix = \"deg\";\n dimensionOptions.labelSize = 0.3;\n dimensionOptions.labelOffset = 0.4;\n dimensionOptions.radians = false;\n\n // Create and draw the dimension\n const dimension = await bitbybit.occt.dimensions.simpleAngularDimension(dimensionOptions);\n bitbybit.draw.drawAnyAsync({ entity: dimension });\n}\n\n// Execute the function\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"// Import the required DTO for angular dimensions\nconst { SimpleAngularDimensionDto } = Bit.Inputs.OCCT;\ntype Point3 = Bit.Inputs.Base.Point3;\ntype Vector3 = Bit.Inputs.Base.Vector3;\n\n// Define the main function\nconst start = async () => {\n // Define two direction vectors to measure angle between\n const direction1: Vector3 = [1, 0, 0]; // X-axis direction\n const direction2: Vector3 = [0, 1, 1]; // Direction at 45deg from Y and Z\n const center: Point3 = [0, 0, 0]; // Origin point\n\n // Create an angular dimension between the directions\n const dimensionOptions = new SimpleAngularDimensionDto();\n dimensionOptions.direction1 = direction1;\n dimensionOptions.direction2 = direction2;\n dimensionOptions.center = center;\n dimensionOptions.radius = 2;\n dimensionOptions.offsetFromCenter = 0.3;\n dimensionOptions.extraSize = 0.1;\n dimensionOptions.decimalPlaces = 1;\n dimensionOptions.labelSuffix = \"deg\";\n dimensionOptions.labelSize = 0.3;\n dimensionOptions.labelOffset = 0.4;\n dimensionOptions.radians = false;\n\n // Create and draw the dimension\n const dimension = await bitbybit.occt.dimensions.simpleAngularDimension(dimensionOptions);\n bitbybit.draw.drawAnyAsync({ entity: dimension });\n}\n\n// Execute the function\nstart();","version":"0.21.1","type":"typescript"}} title="Simple angular dimension between two directions" /> @@ -62,21 +62,21 @@ Angular dimensions are particularly useful for complex 3D geometry like cones, w conerotatedConeconeEdgetranslatedEdgestartPointendPointdirection1cone52.75360000010rotatedConecone010-90coneEdgerotatedCone2translatedEdgeconeEdge-100startPointtranslatedEdgeendPointtranslatedEdgedirection1endPointstartPointrotatedConedirection1-100startPoint7202(deg)0.40.6FALSE","version":"0.21.0","type":"blockly"}} + script={{"script":"conerotatedConeconeEdgetranslatedEdgestartPointendPointdirection1cone52.75360000010rotatedConecone010-90coneEdgerotatedCone2translatedEdgeconeEdge-100startPointtranslatedEdgeendPointtranslatedEdgedirection1endPointstartPointrotatedConedirection1-100startPoint7202(deg)0.40.6FALSE","version":"0.21.1","type":"blockly"}} title="Cone with apex angle measurement" /> {\n // Create a cone with specific dimensions\n const coneOptions = new ConeDto();\n coneOptions.radius1 = 5;\n coneOptions.radius2 = 2.7; // Variable radius for apex angle\n coneOptions.height = 5;\n coneOptions.angle = 360;\n coneOptions.center = [0, 0, 0];\n coneOptions.direction = [0, 1, 0];\n const cone = await solid.createCone(coneOptions);\n\n // Rotate the cone -90 degrees around Y axis for better visualization\n const rotatedCone = await transforms.rotate({\n shape: cone,\n axis: [0, 1, 0],\n angle: -90\n });\n\n // Draw the rotated cone\n bitbybit.draw.drawAnyAsync({ entity: rotatedCone });\n\n // Get edge 2 from the cone (this is a generatrix line)\n const coneEdge = await edge.getEdge({ shape: rotatedCone, index: 2 });\n\n // Translate the edge to position it for measurement\n const translatedEdge = await transforms.translate({\n shape: coneEdge,\n translation: [-1, 0, 0]\n });\n\n // Get start and end points from the translated edge\n const startPoint = await edge.startPointOnEdge({ shape: translatedEdge });\n const endPoint = await edge.endPointOnEdge({ shape: translatedEdge });\n\n // Calculate direction vector from start to end point\n const direction1 = bitbybit.vector.sub({ first: endPoint, second: startPoint }) as Vector3;\n\n // Create angular dimension to measure apex angle\n const dimensionOptions = new SimpleAngularDimensionDto();\n dimensionOptions.direction1 = direction1;\n dimensionOptions.direction2 = [-1, 0, 0]; // Reference direction\n dimensionOptions.center = startPoint; // Apex point\n dimensionOptions.radius = 7;\n dimensionOptions.offsetFromCenter = 2;\n dimensionOptions.extraSize = 0;\n dimensionOptions.decimalPlaces = 2;\n dimensionOptions.labelSuffix = \"(deg)\";\n dimensionOptions.labelSize = 0.4;\n dimensionOptions.labelOffset = 0.6;\n dimensionOptions.radians = false;\n\n // Create and draw the angular dimension\n const dimension = await dimensions.simpleAngularDimension(dimensionOptions);\n bitbybit.draw.drawAnyAsync({ entity: dimension });\n}\n\n// Execute the function\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"// Import required DTOs for creating shapes and dimensions\nconst { ConeDto, SimpleAngularDimensionDto } = Bit.Inputs.OCCT;\n// Import types for type safety\ntype TopoDSSolidPointer = Bit.Inputs.OCCT.TopoDSSolidPointer;\ntype TopoDSEdgePointer = Bit.Inputs.OCCT.TopoDSEdgePointer;\ntype Point3 = Bit.Inputs.Base.Point3;\ntype Vector3 = Bit.Inputs.Base.Vector3;\n\n// Get access to OCCT modules\nconst { shapes, dimensions, transforms } = bitbybit.occt;\nconst { solid, edge } = shapes;\n\n// Define the main function to create a cone with angular dimension\nconst start = async () => {\n // Create a cone with specific dimensions\n const coneOptions = new ConeDto();\n coneOptions.radius1 = 5;\n coneOptions.radius2 = 2.7; // Variable radius for apex angle\n coneOptions.height = 5;\n coneOptions.angle = 360;\n coneOptions.center = [0, 0, 0];\n coneOptions.direction = [0, 1, 0];\n const cone = await solid.createCone(coneOptions);\n\n // Rotate the cone -90 degrees around Y axis for better visualization\n const rotatedCone = await transforms.rotate({\n shape: cone,\n axis: [0, 1, 0],\n angle: -90\n });\n\n // Draw the rotated cone\n bitbybit.draw.drawAnyAsync({ entity: rotatedCone });\n\n // Get edge 2 from the cone (this is a generatrix line)\n const coneEdge = await edge.getEdge({ shape: rotatedCone, index: 2 });\n\n // Translate the edge to position it for measurement\n const translatedEdge = await transforms.translate({\n shape: coneEdge,\n translation: [-1, 0, 0]\n });\n\n // Get start and end points from the translated edge\n const startPoint = await edge.startPointOnEdge({ shape: translatedEdge });\n const endPoint = await edge.endPointOnEdge({ shape: translatedEdge });\n\n // Calculate direction vector from start to end point\n const direction1 = bitbybit.vector.sub({ first: endPoint, second: startPoint }) as Vector3;\n\n // Create angular dimension to measure apex angle\n const dimensionOptions = new SimpleAngularDimensionDto();\n dimensionOptions.direction1 = direction1;\n dimensionOptions.direction2 = [-1, 0, 0]; // Reference direction\n dimensionOptions.center = startPoint; // Apex point\n dimensionOptions.radius = 7;\n dimensionOptions.offsetFromCenter = 2;\n dimensionOptions.extraSize = 0;\n dimensionOptions.decimalPlaces = 2;\n dimensionOptions.labelSuffix = \"(deg)\";\n dimensionOptions.labelSize = 0.4;\n dimensionOptions.labelOffset = 0.6;\n dimensionOptions.radians = false;\n\n // Create and draw the angular dimension\n const dimension = await dimensions.simpleAngularDimension(dimensionOptions);\n bitbybit.draw.drawAnyAsync({ entity: dimension });\n}\n\n// Execute the function\nstart();","version":"0.21.1","type":"typescript"}} title="Cone with apex angle measurement" /> diff --git a/docs/learn/code/common/occt/dimensions/linear-dimension.md b/docs/learn/code/common/occt/dimensions/linear-dimension.md index 9f432405..4c737a28 100644 --- a/docs/learn/code/common/occt/dimensions/linear-dimension.md +++ b/docs/learn/code/common/occt/dimensions/linear-dimension.md @@ -26,21 +26,21 @@ Linear dimensions measure straight-line distances between two points and display point1point2point1-500point2500point1point2point1point20100.30.21cm0.40.80","version":"0.21.0","type":"blockly"}} + script={{"script":"point1point2point1-500point2500point1point2point1point20100.30.21cm0.40.80","version":"0.21.1","type":"blockly"}} title="Simple linear dimension between two points" /> {\n // Define two points to measure between\n const startPoint: Point3 = [-5, 0, 0];\n const endPoint: Point3 = [5, 0, 0];\n\n // Draw the points for reference\n bitbybit.draw.drawAnyAsync({ entity: startPoint });\n bitbybit.draw.drawAnyAsync({ entity: endPoint });\n\n // Create a linear dimension between the points\n const dimensionOptions = new SimpleLinearLengthDimensionDto();\n dimensionOptions.start = startPoint;\n dimensionOptions.end = endPoint;\n dimensionOptions.direction = [0, 1, 0]; // Offset in Y direction\n dimensionOptions.offsetFromPoints = 0.3;\n dimensionOptions.crossingSize = 0.2;\n dimensionOptions.decimalPlaces = 1;\n dimensionOptions.labelSuffix = \"cm\";\n dimensionOptions.labelSize = 0.4;\n dimensionOptions.labelOffset = 0.8;\n dimensionOptions.labelRotation = 0;\n\n // Create and draw the dimension\n const dimension = await bitbybit.occt.dimensions.simpleLinearLengthDimension(dimensionOptions);\n bitbybit.draw.drawAnyAsync({ entity: dimension });\n}\n\n// Execute the function\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"// Import the required DTO for linear dimensions\nconst { SimpleLinearLengthDimensionDto } = Bit.Inputs.OCCT;\ntype Point3 = Bit.Inputs.Base.Point3;\n\n// Define the main function\nconst start = async () => {\n // Define two points to measure between\n const startPoint: Point3 = [-5, 0, 0];\n const endPoint: Point3 = [5, 0, 0];\n\n // Draw the points for reference\n bitbybit.draw.drawAnyAsync({ entity: startPoint });\n bitbybit.draw.drawAnyAsync({ entity: endPoint });\n\n // Create a linear dimension between the points\n const dimensionOptions = new SimpleLinearLengthDimensionDto();\n dimensionOptions.start = startPoint;\n dimensionOptions.end = endPoint;\n dimensionOptions.direction = [0, 1, 0]; // Offset in Y direction\n dimensionOptions.offsetFromPoints = 0.3;\n dimensionOptions.crossingSize = 0.2;\n dimensionOptions.decimalPlaces = 1;\n dimensionOptions.labelSuffix = \"cm\";\n dimensionOptions.labelSize = 0.4;\n dimensionOptions.labelOffset = 0.8;\n dimensionOptions.labelRotation = 0;\n\n // Create and draw the dimension\n const dimension = await bitbybit.occt.dimensions.simpleLinearLengthDimension(dimensionOptions);\n bitbybit.draw.drawAnyAsync({ entity: dimension });\n}\n\n// Execute the function\nstart();","version":"0.21.1","type":"typescript"}} title="Simple linear dimension between two points" /> @@ -51,21 +51,21 @@ Linear dimensions update automatically when geometry changes, keeping your docum widthlengthheightboxfirstEdgesecondEdgethirdEdgewidth13.2length9.1height5.3boxwidthlengthheight000TRUEfirstEdgebox1secondEdgebox8thirdEdgebox11firstEdgefirstEdge-2000.20.22(cm)0.51180secondEdgesecondEdge2000.20.22(cm)0.51180thirdEdgethirdEdge00-20.20.22(cm)0.51180box","version":"0.21.0","type":"blockly"}} + script={{"script":"widthlengthheightboxfirstEdgesecondEdgethirdEdgewidth13.2length9.1height5.3boxwidthlengthheight000TRUEfirstEdgebox1secondEdgebox8thirdEdgebox11firstEdgefirstEdge-2000.20.22(cm)0.51180secondEdgesecondEdge2000.20.22(cm)0.51180thirdEdgethirdEdge00-20.20.22(cm)0.51180box","version":"0.21.1","type":"blockly"}} title="Linear dimensions applied on box" /> {\n // Create a box with specific dimensions\n const boxOptions = new BoxDto();\n boxOptions.width = 13.2;\n boxOptions.length = 9.1;\n boxOptions.height = 5.3;\n boxOptions.center = [0, 0, 0];\n boxOptions.originOnCenter = true;\n const box = await solid.createBox(boxOptions);\n\n // Draw the box first\n bitbybit.draw.drawAnyAsync({ entity: box });\n\n // Get all edges from the box for dimension measurements\n const edges = await edge.getEdges({ shape: box });\n\n // Create width dimension (measuring edge 0)\n const widthEdge = edges[0];\n const widthStartPoint = await edge.startPointOnEdge({ shape: widthEdge });\n const widthEndPoint = await edge.endPointOnEdge({ shape: widthEdge });\n\n const widthDimensionOptions = new SimpleLinearLengthDimensionDto();\n widthDimensionOptions.start = widthStartPoint;\n widthDimensionOptions.end = widthEndPoint;\n widthDimensionOptions.direction = [-2, 0, 0]; // Offset to the left\n widthDimensionOptions.offsetFromPoints = 0.2;\n widthDimensionOptions.crossingSize = 0.2;\n widthDimensionOptions.decimalPlaces = 2;\n widthDimensionOptions.labelSuffix = \"(cm)\";\n widthDimensionOptions.labelSize = 0.5;\n widthDimensionOptions.labelOffset = 1;\n widthDimensionOptions.labelRotation = 180;\n \n const widthDimension = await dimensions.simpleLinearLengthDimension(widthDimensionOptions);\n bitbybit.draw.drawAnyAsync({ entity: widthDimension });\n\n // Create height dimension (measuring edge 10)\n const heightEdge = edges[10];\n const heightStartPoint = await edge.startPointOnEdge({ shape: heightEdge });\n const heightEndPoint = await edge.endPointOnEdge({ shape: heightEdge });\n\n const heightDimensionOptions = new SimpleLinearLengthDimensionDto();\n heightDimensionOptions.start = heightStartPoint;\n heightDimensionOptions.end = heightEndPoint;\n heightDimensionOptions.direction = [0, 0, -2]; // Offset toward the back\n heightDimensionOptions.offsetFromPoints = 0.2;\n heightDimensionOptions.crossingSize = 0.2;\n heightDimensionOptions.decimalPlaces = 2;\n heightDimensionOptions.labelSuffix = \"(cm)\";\n heightDimensionOptions.labelSize = 0.5;\n heightDimensionOptions.labelOffset = 1;\n heightDimensionOptions.labelRotation = 180;\n \n const heightDimension = await dimensions.simpleLinearLengthDimension(heightDimensionOptions);\n bitbybit.draw.drawAnyAsync({ entity: heightDimension });\n\n // Create depth dimension (measuring edge 7)\n const depthEdge = edges[7];\n const depthStartPoint = await edge.endPointOnEdge({ shape: depthEdge });\n const depthEndPoint = await edge.startPointOnEdge({ shape: depthEdge });\n\n const depthDimensionOptions = new SimpleLinearLengthDimensionDto();\n depthDimensionOptions.start = depthStartPoint;\n depthDimensionOptions.end = depthEndPoint;\n depthDimensionOptions.direction = [2, 0, 0]; // Offset to the right\n depthDimensionOptions.offsetFromPoints = 0.2;\n depthDimensionOptions.crossingSize = 0.2;\n depthDimensionOptions.decimalPlaces = 2;\n depthDimensionOptions.labelSuffix = \"(cm)\";\n depthDimensionOptions.labelSize = 0.5;\n depthDimensionOptions.labelOffset = 1;\n depthDimensionOptions.labelRotation = 180;\n \n const depthDimension = await dimensions.simpleLinearLengthDimension(depthDimensionOptions);\n bitbybit.draw.drawAnyAsync({ entity: depthDimension });\n}\n\n// Execute the function\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"// Import required DTOs for creating shapes and dimensions\nconst { BoxDto, SimpleLinearLengthDimensionDto } = Bit.Inputs.OCCT;\n// Import types for type safety\ntype TopoDSSolidPointer = Bit.Inputs.OCCT.TopoDSSolidPointer;\ntype TopoDSEdgePointer = Bit.Inputs.OCCT.TopoDSEdgePointer;\n\n// Get access to OCCT modules\nconst { shapes, dimensions } = bitbybit.occt;\nconst { solid, edge } = shapes;\n\n// Define the main function to create a box with linear dimensions\nconst start = async () => {\n // Create a box with specific dimensions\n const boxOptions = new BoxDto();\n boxOptions.width = 13.2;\n boxOptions.length = 9.1;\n boxOptions.height = 5.3;\n boxOptions.center = [0, 0, 0];\n boxOptions.originOnCenter = true;\n const box = await solid.createBox(boxOptions);\n\n // Draw the box first\n bitbybit.draw.drawAnyAsync({ entity: box });\n\n // Get all edges from the box for dimension measurements\n const edges = await edge.getEdges({ shape: box });\n\n // Create width dimension (measuring edge 0)\n const widthEdge = edges[0];\n const widthStartPoint = await edge.startPointOnEdge({ shape: widthEdge });\n const widthEndPoint = await edge.endPointOnEdge({ shape: widthEdge });\n\n const widthDimensionOptions = new SimpleLinearLengthDimensionDto();\n widthDimensionOptions.start = widthStartPoint;\n widthDimensionOptions.end = widthEndPoint;\n widthDimensionOptions.direction = [-2, 0, 0]; // Offset to the left\n widthDimensionOptions.offsetFromPoints = 0.2;\n widthDimensionOptions.crossingSize = 0.2;\n widthDimensionOptions.decimalPlaces = 2;\n widthDimensionOptions.labelSuffix = \"(cm)\";\n widthDimensionOptions.labelSize = 0.5;\n widthDimensionOptions.labelOffset = 1;\n widthDimensionOptions.labelRotation = 180;\n \n const widthDimension = await dimensions.simpleLinearLengthDimension(widthDimensionOptions);\n bitbybit.draw.drawAnyAsync({ entity: widthDimension });\n\n // Create height dimension (measuring edge 10)\n const heightEdge = edges[10];\n const heightStartPoint = await edge.startPointOnEdge({ shape: heightEdge });\n const heightEndPoint = await edge.endPointOnEdge({ shape: heightEdge });\n\n const heightDimensionOptions = new SimpleLinearLengthDimensionDto();\n heightDimensionOptions.start = heightStartPoint;\n heightDimensionOptions.end = heightEndPoint;\n heightDimensionOptions.direction = [0, 0, -2]; // Offset toward the back\n heightDimensionOptions.offsetFromPoints = 0.2;\n heightDimensionOptions.crossingSize = 0.2;\n heightDimensionOptions.decimalPlaces = 2;\n heightDimensionOptions.labelSuffix = \"(cm)\";\n heightDimensionOptions.labelSize = 0.5;\n heightDimensionOptions.labelOffset = 1;\n heightDimensionOptions.labelRotation = 180;\n \n const heightDimension = await dimensions.simpleLinearLengthDimension(heightDimensionOptions);\n bitbybit.draw.drawAnyAsync({ entity: heightDimension });\n\n // Create depth dimension (measuring edge 7)\n const depthEdge = edges[7];\n const depthStartPoint = await edge.endPointOnEdge({ shape: depthEdge });\n const depthEndPoint = await edge.startPointOnEdge({ shape: depthEdge });\n\n const depthDimensionOptions = new SimpleLinearLengthDimensionDto();\n depthDimensionOptions.start = depthStartPoint;\n depthDimensionOptions.end = depthEndPoint;\n depthDimensionOptions.direction = [2, 0, 0]; // Offset to the right\n depthDimensionOptions.offsetFromPoints = 0.2;\n depthDimensionOptions.crossingSize = 0.2;\n depthDimensionOptions.decimalPlaces = 2;\n depthDimensionOptions.labelSuffix = \"(cm)\";\n depthDimensionOptions.labelSize = 0.5;\n depthDimensionOptions.labelOffset = 1;\n depthDimensionOptions.labelRotation = 180;\n \n const depthDimension = await dimensions.simpleLinearLengthDimension(depthDimensionOptions);\n bitbybit.draw.drawAnyAsync({ entity: depthDimension });\n}\n\n// Execute the function\nstart();","version":"0.21.1","type":"typescript"}} title="Linear dimensions applied on box" /> diff --git a/docs/learn/code/common/occt/dimensions/pin-with-label.md b/docs/learn/code/common/occt/dimensions/pin-with-label.md index 1408556f..2284c273 100644 --- a/docs/learn/code/common/occt/dimensions/pin-with-label.md +++ b/docs/learn/code/common/occt/dimensions/pin-with-label.md @@ -39,21 +39,21 @@ The most basic use case is creating a pin with static text to mark important poi 0003211000Important Point0.30.4","version":"0.21.0","type":"blockly"}} + script={{"script":"0003211000Important Point0.30.4","version":"0.21.1","type":"blockly"}} title="Simple pin with static label" /> {\n // Define points for the pin\n const startPoint: Point3 = [0, 0, 0];\n const endPoint: Point3 = [3, 2, 1];\n const direction: Vector3 = [1, 0, 0];\n\n // Create pin with label options\n const pinOptions = new PinWithLabelDto();\n pinOptions.startPoint = startPoint;\n pinOptions.endPoint = endPoint;\n pinOptions.direction = direction;\n pinOptions.offsetFromStart = 0;\n pinOptions.label = \"Important Point\";\n pinOptions.labelOffset = 0.3;\n pinOptions.labelSize = 0.4;\n\n // Create and draw the pin\n const pin = await bitbybit.occt.dimensions.pinWithLabel(pinOptions);\n bitbybit.draw.drawAnyAsync({ entity: pin });\n}\n\n// Execute the function\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"// Import the required DTO for pin with label\nconst { PinWithLabelDto } = Bit.Inputs.OCCT;\ntype Point3 = Bit.Inputs.Base.Point3;\ntype Vector3 = Bit.Inputs.Base.Vector3;\n\n// Define the main function\nconst start = async () => {\n // Define points for the pin\n const startPoint: Point3 = [0, 0, 0];\n const endPoint: Point3 = [3, 2, 1];\n const direction: Vector3 = [1, 0, 0];\n\n // Create pin with label options\n const pinOptions = new PinWithLabelDto();\n pinOptions.startPoint = startPoint;\n pinOptions.endPoint = endPoint;\n pinOptions.direction = direction;\n pinOptions.offsetFromStart = 0;\n pinOptions.label = \"Important Point\";\n pinOptions.labelOffset = 0.3;\n pinOptions.labelSize = 0.4;\n\n // Create and draw the pin\n const pin = await bitbybit.occt.dimensions.pinWithLabel(pinOptions);\n bitbybit.draw.drawAnyAsync({ entity: pin });\n}\n\n// Execute the function\nstart();","version":"0.21.1","type":"typescript"}} title="Simple pin with static label" /> @@ -74,21 +74,21 @@ A more practical application combines pin labels with calculated geometric prope radiusspherevolumeradius2.5sphereradius000volumesphere00radius43ADDradius21000Vol: {0} m3volume20.30.4sphere","version":"0.21.0","type":"blockly"}} + script={{"script":"radiusspherevolumeradius2.5sphereradius000volumesphere00radius43ADDradius21000Vol: {0} m3volume20.30.4sphere","version":"0.21.1","type":"blockly"}} title="Sphere with volume pin label" /> {\n // Parametric radius value\n const radius = 2.5;\n\n // Create a sphere\n const sphereOptions = new SphereDto();\n sphereOptions.radius = radius;\n sphereOptions.center = [0, 0, 0] as Point3;\n\n const sphere = await solid.createSphere(sphereOptions);\n\n // Calculate sphere volume\n const volume = await solid.getSolidVolume({ shape: sphere });\n const roundedVolume = math.roundToDecimals({ number: volume, decimalPlaces: 2 });\n\n // Format volume as text with units\n const volumeText = text.format({\n text: \"Vol: {0} m3\",\n values: [text.toString({ item: roundedVolume })]\n });\n\n // Create pin with calculated volume label\n const pinOptions = new PinWithLabelDto();\n pinOptions.startPoint = [0, 0, radius] as Point3; // Start at top of sphere\n pinOptions.endPoint = [4, 3, radius + 2] as Point3; // Position for visibility\n pinOptions.direction = [1, 0, 0] as Vector3;\n pinOptions.offsetFromStart = 0;\n pinOptions.label = volumeText;\n pinOptions.labelOffset = 0.3;\n pinOptions.labelSize = 0.4;\n\n // Create and draw the pin\n const pin = await dimensions.pinWithLabel(pinOptions);\n \n // Draw both sphere and pin\n bitbybit.draw.drawAnyAsync({ entity: sphere });\n bitbybit.draw.drawAnyAsync({ entity: pin });\n}\n\n// Execute the function\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"// Import required DTOs and types\nconst { SphereDto, PinWithLabelDto } = Bit.Inputs.OCCT;\ntype Point3 = Bit.Inputs.Base.Point3;\ntype Vector3 = Bit.Inputs.Base.Vector3;\n\n// Get access to OCCT modules\nconst { solid } = bitbybit.occt.shapes;\nconst { dimensions } = bitbybit.occt;\nconst { math, text } = bitbybit;\n\n// Define the main function\nconst start = async () => {\n // Parametric radius value\n const radius = 2.5;\n\n // Create a sphere\n const sphereOptions = new SphereDto();\n sphereOptions.radius = radius;\n sphereOptions.center = [0, 0, 0] as Point3;\n\n const sphere = await solid.createSphere(sphereOptions);\n\n // Calculate sphere volume\n const volume = await solid.getSolidVolume({ shape: sphere });\n const roundedVolume = math.roundToDecimals({ number: volume, decimalPlaces: 2 });\n\n // Format volume as text with units\n const volumeText = text.format({\n text: \"Vol: {0} m3\",\n values: [text.toString({ item: roundedVolume })]\n });\n\n // Create pin with calculated volume label\n const pinOptions = new PinWithLabelDto();\n pinOptions.startPoint = [0, 0, radius] as Point3; // Start at top of sphere\n pinOptions.endPoint = [4, 3, radius + 2] as Point3; // Position for visibility\n pinOptions.direction = [1, 0, 0] as Vector3;\n pinOptions.offsetFromStart = 0;\n pinOptions.label = volumeText;\n pinOptions.labelOffset = 0.3;\n pinOptions.labelSize = 0.4;\n\n // Create and draw the pin\n const pin = await dimensions.pinWithLabel(pinOptions);\n \n // Draw both sphere and pin\n bitbybit.draw.drawAnyAsync({ entity: sphere });\n bitbybit.draw.drawAnyAsync({ entity: pin });\n}\n\n// Execute the function\nstart();","version":"0.21.1","type":"typescript"}} title="Sphere with volume pin label" /> diff --git a/docs/learn/code/common/occt/fillets/chamfer-circular-edges.mdx b/docs/learn/code/common/occt/fillets/chamfer-circular-edges.mdx index 6182ce33..d600e3b2 100644 --- a/docs/learn/code/common/occt/fillets/chamfer-circular-edges.mdx +++ b/docs/learn/code/common/occt/fillets/chamfer-circular-edges.mdx @@ -25,21 +25,21 @@ The examples below demonstrate creating a box with a cylindrical hole through it **TypeScript Example: Chamfer Circular Edge of a Hole** {\n\n const boxOpt = new Bit.Inputs.OCCT.BoxDto();\n boxOpt.width = 5;\n boxOpt.length = 8;\n boxOpt.height = 10;\n const box = await bitbybit.occt.shapes.solid.createBox(boxOpt);\n const cylinderOpt = new Bit.Inputs.OCCT.CylinderDto();\n cylinderOpt.direction = [1, 0, 0];\n cylinderOpt.center = [-5, 0, 0];\n cylinderOpt.radius = 2;\n cylinderOpt.height = 10;\n\n const cylinder = await bitbybit.occt.shapes.solid.createCylinder(cylinderOpt)\n\n const difference = await bitbybit.occt.booleans.difference({\n shape: box,\n shapes: [cylinder],\n keepEdges: false\n });\n\n const chamfered = await bitbybit.occt.fillets.chamferEdges({\n shape: difference,\n distance: 0.4\n })\n\n bitbybit.draw.drawAnyAsync({\n entity: chamfered,\n });\n}\n\nstart();\n","version":"0.21.0","type":"typescript"}} + script={{"script":"const start = async () => {\n\n const boxOpt = new Bit.Inputs.OCCT.BoxDto();\n boxOpt.width = 5;\n boxOpt.length = 8;\n boxOpt.height = 10;\n const box = await bitbybit.occt.shapes.solid.createBox(boxOpt);\n const cylinderOpt = new Bit.Inputs.OCCT.CylinderDto();\n cylinderOpt.direction = [1, 0, 0];\n cylinderOpt.center = [-5, 0, 0];\n cylinderOpt.radius = 2;\n cylinderOpt.height = 10;\n\n const cylinder = await bitbybit.occt.shapes.solid.createCylinder(cylinderOpt)\n\n const difference = await bitbybit.occt.booleans.difference({\n shape: box,\n shapes: [cylinder],\n keepEdges: false\n });\n\n const chamfered = await bitbybit.occt.fillets.chamferEdges({\n shape: difference,\n distance: 0.4\n })\n\n bitbybit.draw.drawAnyAsync({\n entity: chamfered,\n });\n}\n\nstart();\n","version":"0.21.1","type":"typescript"}} title="Chamfer Circular Edge" /> **Blockly Example: Chamfer Circular Edge of a Hole** differenceSoliddifferenceSolid5810000210-500100FALSEdifferenceSolid0.4","version":"0.21.0","type":"blockly"}} + script={{"script":"differenceSoliddifferenceSolid5810000210-500100FALSEdifferenceSolid0.4","version":"0.21.1","type":"blockly"}} title="Chamfer Circular Edge" /> **Rete Example: Chamfer Circular Edge of a Hole** diff --git a/docs/learn/code/common/occt/fillets/chamfers-intro.mdx b/docs/learn/code/common/occt/fillets/chamfers-intro.mdx index 65ad5241..bbec8c40 100644 --- a/docs/learn/code/common/occt/fillets/chamfers-intro.mdx +++ b/docs/learn/code/common/occt/fillets/chamfers-intro.mdx @@ -48,21 +48,21 @@ The following examples in TypeScript, Rete, and Blockly demonstrate creating a s **TypeScript Example: Chamfer All Edges of a Solid** {\n\n const boxOpt = new Bit.Inputs.OCCT.BoxDto();\n boxOpt.width = 5;\n boxOpt.length = 8;\n boxOpt.height = 10;\n const box = await bitbybit.occt.shapes.solid.createBox(boxOpt);\n\n const chamfered = await bitbybit.occt.fillets.chamferEdges({\n shape: box,\n distance: 1,\n })\n\n bitbybit.draw.drawAnyAsync({\n entity: chamfered,\n });\n}\n\nstart();\n","version":"0.21.0","type":"typescript"}} + script={{"script":"const start = async () => {\n\n const boxOpt = new Bit.Inputs.OCCT.BoxDto();\n boxOpt.width = 5;\n boxOpt.length = 8;\n boxOpt.height = 10;\n const box = await bitbybit.occt.shapes.solid.createBox(boxOpt);\n\n const chamfered = await bitbybit.occt.fillets.chamferEdges({\n shape: box,\n distance: 1,\n })\n\n bitbybit.draw.drawAnyAsync({\n entity: chamfered,\n });\n}\n\nstart();\n","version":"0.21.1","type":"typescript"}} title="Chamfer All Edges of Solid" /> **Blockly Example: Chamfer All Edges of a Solid** 58100001","version":"0.21.0","type":"blockly"}} + script={{"script":"58100001","version":"0.21.1","type":"blockly"}} title="Chamfer All Edges of Solid" /> **Rete Example: Chamfer All Edges of a Solid** diff --git a/docs/learn/code/common/occt/fillets/chamfers-var-radius-on-spec-edges.mdx b/docs/learn/code/common/occt/fillets/chamfers-var-radius-on-spec-edges.mdx index cfd1a191..1e36d0eb 100644 --- a/docs/learn/code/common/occt/fillets/chamfers-var-radius-on-spec-edges.mdx +++ b/docs/learn/code/common/occt/fillets/chamfers-var-radius-on-spec-edges.mdx @@ -28,21 +28,21 @@ The examples below demonstrate creating a solid box and then applying chamfers w **TypeScript Example: Chamfer Specific Edges with Variable Distances** {\n\n const boxOpt = new Bit.Inputs.OCCT.BoxDto();\n boxOpt.width = 5;\n boxOpt.length = 8;\n boxOpt.height = 10;\n const box = await bitbybit.occt.shapes.solid.createBox(boxOpt);\n\n const chamfered = await bitbybit.occt.fillets.chamferEdges({\n shape: box,\n distanceList: [0.2, 1.2, 2],\n indexes: [1, 2, 3]\n })\n\n bitbybit.draw.drawAnyAsync({\n entity: chamfered,\n });\n}\n\nstart();\n","version":"0.21.0","type":"typescript"}} + script={{"script":"const start = async () => {\n\n const boxOpt = new Bit.Inputs.OCCT.BoxDto();\n boxOpt.width = 5;\n boxOpt.length = 8;\n boxOpt.height = 10;\n const box = await bitbybit.occt.shapes.solid.createBox(boxOpt);\n\n const chamfered = await bitbybit.occt.fillets.chamferEdges({\n shape: box,\n distanceList: [0.2, 1.2, 2],\n indexes: [1, 2, 3]\n })\n\n bitbybit.draw.drawAnyAsync({\n entity: chamfered,\n });\n}\n\nstart();\n","version":"0.21.1","type":"typescript"}} title="Chamfer Specific Edges of Solid" /> **Blockly Example: Chamfer Specific Edges with Variable Distances** 58100000.10.31.22123","version":"0.21.0","type":"blockly"}} + script={{"script":"58100000.10.31.22123","version":"0.21.1","type":"blockly"}} title="Chamfer Specific Edges of Solid" /> **Rete Example: Chamfer Specific Edges with Variable Distances** diff --git a/docs/learn/code/common/occt/fillets/fillet-3d-wires.mdx b/docs/learn/code/common/occt/fillets/fillet-3d-wires.mdx index 63c8ba93..c9028752 100644 --- a/docs/learn/code/common/occt/fillets/fillet-3d-wires.mdx +++ b/docs/learn/code/common/occt/fillets/fillet-3d-wires.mdx @@ -55,21 +55,21 @@ In these examples, we first construct a 3D star-shaped wire. Then, we apply diff **TypeScript Example: Fillet Specific Corners of a 3D Wire** {\n\n const repeatOpt = new Bit.Inputs.Lists.MultiplyItemDto([innerFillet, outerFillet], nrRays);\n const radiusList = bitbybit.lists.repeat(repeatOpt).flat();\n const spanOptions = new Bit.Inputs.Vector.SpanDto(1, 1, nrRays * 2);\n const indexes = bitbybit.vector.span(spanOptions);\n\n const starOptions = new Bit.Inputs.OCCT.StarDto(outerStarRadius, innerStarRadius, nrRays, [0, 0, 0], [0, 1, 0], 4, false);\n const star = await bitbybit.occt.shapes.wire.createStarWire(starOptions);\n\n const filletOptions = new Bit.Inputs.OCCT.Fillet3DWireDto(star, undefined, [0, 1, 0], radiusList, indexes);\n const starFillet = await bitbybit.occt.fillets.fillet3DWire(filletOptions);\n\n const startFilletTranslated1 = await bitbybit.occt.transforms.translate({ shape: starFillet, translation: [0, 5, 0] })\n const startFilletTranslated2 = await bitbybit.occt.transforms.translate({ shape: starFillet, translation: [0, 10, 0] })\n\n\n const starFace = await bitbybit.occt.shapes.face.createFaceFromWire({ shape: startFilletTranslated2, planar: false });\n const starThick = await bitbybit.occt.operations.makeThickSolidSimple({ shape: starFace, offset: -1 });\n const starThickFillet = await bitbybit.occt.fillets.filletEdges({ shape: starThick, radius: 0.3 });\n\n const drawOptions = new Bit.Inputs.Draw.DrawOcctShapeOptions();\n drawOptions.edgeWidth = 15;\n bitbybit.draw.drawAnyAsync({ entity: star, options: drawOptions });\n bitbybit.draw.drawAnyAsync({ entity: startFilletTranslated1, options: drawOptions });\n drawOptions.faceColour = \"#5555ff\";\n drawOptions.edgeColour = \"#000000\";\n drawOptions.edgeWidth = 2;\n drawOptions.precision = 0.005;\n bitbybit.draw.drawAnyAsync({ entity: starThickFillet, options: drawOptions });\n\n const gridOptions = new Bit.Inputs.Draw.SceneDrawGridMeshDto();\n bitbybit.draw.drawGridMesh(gridOptions);\n const skyboxOptions = new Bit.Inputs.BabylonScene.SkyboxDto();\n skyboxOptions.skybox = Bit.Inputs.Base.skyboxEnum.clearSky;\n bitbybit.babylon.scene.enableSkybox(skyboxOptions);\n}\n\nstart();\n","version":"0.21.0","type":"typescript"}} + script={{"script":"const nrRays = 7;\nconst outerStarRadius = 10;\nconst innerStarRadius = 4;\nconst outerFillet = 0.6;\nconst innerFillet = 1.7;\n\nconst start = async () => {\n\n const repeatOpt = new Bit.Inputs.Lists.MultiplyItemDto([innerFillet, outerFillet], nrRays);\n const radiusList = bitbybit.lists.repeat(repeatOpt).flat();\n const spanOptions = new Bit.Inputs.Vector.SpanDto(1, 1, nrRays * 2);\n const indexes = bitbybit.vector.span(spanOptions);\n\n const starOptions = new Bit.Inputs.OCCT.StarDto(outerStarRadius, innerStarRadius, nrRays, [0, 0, 0], [0, 1, 0], 4, false);\n const star = await bitbybit.occt.shapes.wire.createStarWire(starOptions);\n\n const filletOptions = new Bit.Inputs.OCCT.Fillet3DWireDto(star, undefined, [0, 1, 0], radiusList, indexes);\n const starFillet = await bitbybit.occt.fillets.fillet3DWire(filletOptions);\n\n const startFilletTranslated1 = await bitbybit.occt.transforms.translate({ shape: starFillet, translation: [0, 5, 0] })\n const startFilletTranslated2 = await bitbybit.occt.transforms.translate({ shape: starFillet, translation: [0, 10, 0] })\n\n\n const starFace = await bitbybit.occt.shapes.face.createFaceFromWire({ shape: startFilletTranslated2, planar: false });\n const starThick = await bitbybit.occt.operations.makeThickSolidSimple({ shape: starFace, offset: -1 });\n const starThickFillet = await bitbybit.occt.fillets.filletEdges({ shape: starThick, radius: 0.3 });\n\n const drawOptions = new Bit.Inputs.Draw.DrawOcctShapeOptions();\n drawOptions.edgeWidth = 15;\n bitbybit.draw.drawAnyAsync({ entity: star, options: drawOptions });\n bitbybit.draw.drawAnyAsync({ entity: startFilletTranslated1, options: drawOptions });\n drawOptions.faceColour = \"#5555ff\";\n drawOptions.edgeColour = \"#000000\";\n drawOptions.edgeWidth = 2;\n drawOptions.precision = 0.005;\n bitbybit.draw.drawAnyAsync({ entity: starThickFillet, options: drawOptions });\n\n const gridOptions = new Bit.Inputs.Draw.SceneDrawGridMeshDto();\n bitbybit.draw.drawGridMesh(gridOptions);\n const skyboxOptions = new Bit.Inputs.BabylonScene.SkyboxDto();\n skyboxOptions.skybox = Bit.Inputs.Base.skyboxEnum.clearSky;\n bitbybit.babylon.scene.enableSkybox(skyboxOptions);\n}\n\nstart();\n","version":"0.21.1","type":"typescript"}} title="Fillet 3D Wire Specific Corners" /> **Blockly Example: Fillet Specific Corners of a 3D Wire** nrRaysinnerFilletRadiusouterRadiusFilletfilletIndexesradiusLististarPromisestarFilletPromisenrRays7innerFilletRadius1.7outerRadiusFillet0.6filletIndexes11MULTIPLYnrRays2'clearSky'10000.10.7radiusListi1MULTIPLYnrRays21EQi20INSERTLASTradiusListouterRadiusFilletINSERTLASTradiusListinnerFilletRadiusstarPromise000010nrRays1044FALSEstarFilletPromisestarPromiseradiusListfilletIndexes010starPromise0.01FALSE#ff0000TRUE#ffffff15starFilletPromise0500.01FALSE#ff0000TRUE#ffffff15starFilletPromise0100FALSE-10.30.005TRUE#3333ffTRUE#000000240040010100.450.50.5FALSE#ffffff#ffffff","version":"0.21.0","type":"blockly"}} + script={{"script":"nrRaysinnerFilletRadiusouterRadiusFilletfilletIndexesradiusLististarPromisestarFilletPromisenrRays7innerFilletRadius1.7outerRadiusFillet0.6filletIndexes11MULTIPLYnrRays2'clearSky'10000.10.7radiusListi1MULTIPLYnrRays21EQi20INSERTLASTradiusListouterRadiusFilletINSERTLASTradiusListinnerFilletRadiusstarPromise000010nrRays1044FALSEstarFilletPromisestarPromiseradiusListfilletIndexes010starPromise0.01FALSE#ff0000TRUE#ffffff15starFilletPromise0500.01FALSE#ff0000TRUE#ffffff15starFilletPromise0100FALSE-10.30.005TRUE#3333ffTRUE#000000240040010100.450.50.5FALSE#ffffff#ffffff","version":"0.21.1","type":"blockly"}} title="Fillet 3D Wire Specific Corners" /> **Rete Example: Fillet Specific Corners of a 3D Wire** diff --git a/docs/learn/code/common/occt/fillets/fillets-intro.mdx b/docs/learn/code/common/occt/fillets/fillets-intro.mdx index 935b73e4..0447867b 100644 --- a/docs/learn/code/common/occt/fillets/fillets-intro.mdx +++ b/docs/learn/code/common/occt/fillets/fillets-intro.mdx @@ -43,21 +43,21 @@ The following examples in TypeScript, Rete, and Blockly demonstrate creating a s **TypeScript Example: Fillet All Edges of a Solid** {\n\n const boxOpt = new Bit.Inputs.OCCT.BoxDto();\n boxOpt.width = 5;\n boxOpt.length = 8;\n boxOpt.height = 10;\n const box = await bitbybit.occt.shapes.solid.createBox(boxOpt);\n\n const filleted = await bitbybit.occt.fillets.filletEdges({\n shape: box,\n radius: 1,\n })\n\n bitbybit.draw.drawAnyAsync({\n entity: filleted,\n });\n}\n\nstart();\n","version":"0.21.0","type":"typescript"}} + script={{"script":"const start = async () => {\n\n const boxOpt = new Bit.Inputs.OCCT.BoxDto();\n boxOpt.width = 5;\n boxOpt.length = 8;\n boxOpt.height = 10;\n const box = await bitbybit.occt.shapes.solid.createBox(boxOpt);\n\n const filleted = await bitbybit.occt.fillets.filletEdges({\n shape: box,\n radius: 1,\n })\n\n bitbybit.draw.drawAnyAsync({\n entity: filleted,\n });\n}\n\nstart();\n","version":"0.21.1","type":"typescript"}} title="Fillet Solid" /> **Blockly Example: Fillet All Edges of a Solid** 58100001","version":"0.21.0","type":"blockly"}} + script={{"script":"58100001","version":"0.21.1","type":"blockly"}} title="Fillet Solid" /> **Rete Example: Fillet All Edges of a Solid** diff --git a/docs/learn/code/common/occt/fillets/fillets-on-2d-wire-corners.mdx b/docs/learn/code/common/occt/fillets/fillets-on-2d-wire-corners.mdx index da8546ea..bd7e4a96 100644 --- a/docs/learn/code/common/occt/fillets/fillets-on-2d-wire-corners.mdx +++ b/docs/learn/code/common/occt/fillets/fillets-on-2d-wire-corners.mdx @@ -30,21 +30,21 @@ The examples below demonstrate creating a 2D wire and then applying fillets with **TypeScript Example: Fillet Specific Corners of a Wire with Variable Radii** {\n const squareOpt = new Bit.Inputs.OCCT.SquareDto();\n const square = await bitbybit.occt.shapes.wire.createSquareWire(squareOpt);\n const squareFillet = await bitbybit.occt.fillets.fillet2d({\n shape: square,\n radiusList: [0.1, 0.3],\n indexes: [1, 3]\n });\n\n bitbybit.draw.drawAnyAsync({\n entity: squareFillet\n });\n}\n\nstart();\n","version":"0.21.0","type":"typescript"}} + script={{"script":"const start = async () => {\n const squareOpt = new Bit.Inputs.OCCT.SquareDto();\n const square = await bitbybit.occt.shapes.wire.createSquareWire(squareOpt);\n const squareFillet = await bitbybit.occt.fillets.fillet2d({\n shape: square,\n radiusList: [0.1, 0.3],\n indexes: [1, 3]\n });\n\n bitbybit.draw.drawAnyAsync({\n entity: squareFillet\n });\n}\n\nstart();\n","version":"0.21.1","type":"typescript"}} title="Fillet Specific Corners of Wire" /> **Blockly Example: Fillet Specific Corners of a Wire with Variable Radii** 10000100.10.313","version":"0.21.0","type":"blockly"}} + script={{"script":"10000100.10.313","version":"0.21.1","type":"blockly"}} title="Fillet Specific Corners of Wire" /> **Rete Example: Fillet Specific Corners of a Wire with Variable Radii** diff --git a/docs/learn/code/common/occt/fillets/fillets-on-2d-wires.mdx b/docs/learn/code/common/occt/fillets/fillets-on-2d-wires.mdx index eb75e3d2..d0a94a04 100644 --- a/docs/learn/code/common/occt/fillets/fillets-on-2d-wires.mdx +++ b/docs/learn/code/common/occt/fillets/fillets-on-2d-wires.mdx @@ -29,21 +29,21 @@ The examples below demonstrate how to create a simple 2D wire (e.g., a polyline **TypeScript Example: Fillet All Corners of a Wire** {\n const squareOpt = new Bit.Inputs.OCCT.SquareDto();\n const square = await bitbybit.occt.shapes.wire.createSquareWire(squareOpt);\n const squareFillet = await bitbybit.occt.fillets.fillet2d({\n shape: square,\n radius: 0.25\n });\n\n bitbybit.draw.drawAnyAsync({\n entity: squareFillet\n });\n}\n\nstart();\n","version":"0.21.0","type":"typescript"}} + script={{"script":"const start = async () => {\n const squareOpt = new Bit.Inputs.OCCT.SquareDto();\n const square = await bitbybit.occt.shapes.wire.createSquareWire(squareOpt);\n const squareFillet = await bitbybit.occt.fillets.fillet2d({\n shape: square,\n radius: 0.25\n });\n\n bitbybit.draw.drawAnyAsync({\n entity: squareFillet\n });\n}\n\nstart();\n","version":"0.21.1","type":"typescript"}} title="Fillet All Corners of Wire" /> **Blockly Example: Fillet All Corners of a Wire** 10000100.24","version":"0.21.0","type":"blockly"}} + script={{"script":"10000100.24","version":"0.21.1","type":"blockly"}} title="Fillet All Corners of Wire" /> **Rete Example: Fillet All Corners of a Wire** diff --git a/docs/learn/code/common/occt/fillets/fillets-var-radius-on-spec-edges.mdx b/docs/learn/code/common/occt/fillets/fillets-var-radius-on-spec-edges.mdx index 282bc92c..37a05b9b 100644 --- a/docs/learn/code/common/occt/fillets/fillets-var-radius-on-spec-edges.mdx +++ b/docs/learn/code/common/occt/fillets/fillets-var-radius-on-spec-edges.mdx @@ -31,7 +31,7 @@ The examples below demonstrate creating a solid box and then applying fillets wi **TypeScript Example: Fillet Specific Edges with Variable Radii** {\n\n const boxOpt = new Bit.Inputs.OCCT.BoxDto();\n boxOpt.width = 5;\n boxOpt.length = 8;\n boxOpt.height = 10;\n const box = await bitbybit.occt.shapes.solid.createBox(boxOpt);\n\n const filleted = await bitbybit.occt.fillets.filletEdges({\n shape: box,\n radiusList: [1, 2, 0.3],\n indexes: [1, 2, 3]\n })\n\n bitbybit.draw.drawAnyAsync({\n entity: filleted,\n });\n}\n\nstart();\n","version":"0.21.0","type":"typescript"}} + script={{"script":"const start = async () => {\n\n const boxOpt = new Bit.Inputs.OCCT.BoxDto();\n boxOpt.width = 5;\n boxOpt.length = 8;\n boxOpt.height = 10;\n const box = await bitbybit.occt.shapes.solid.createBox(boxOpt);\n\n const filleted = await bitbybit.occt.fillets.filletEdges({\n shape: box,\n radiusList: [1, 2, 0.3],\n indexes: [1, 2, 3]\n })\n\n bitbybit.draw.drawAnyAsync({\n entity: filleted,\n });\n}\n\nstart();\n","version":"0.21.1","type":"typescript"}} title="Variable Fillet Radius On Spec Edges" /> @@ -39,7 +39,7 @@ The examples below demonstrate creating a solid box and then applying fillets wi **Blockly Example: Fillet Specific Edges with Variable Radii** 5810000120.3123","version":"0.21.0","type":"blockly"}} + script={{"script":"5810000120.3123","version":"0.21.1","type":"blockly"}} title="Variable Fillet Radius On Spec Edges" /> @@ -47,7 +47,7 @@ The examples below demonstrate creating a solid box and then applying fillets wi **Rete Example: Fillet Specific Edges with Variable Radii** diff --git a/docs/learn/code/common/occt/io/dxf-file-format-for-2d-drawings.md b/docs/learn/code/common/occt/io/dxf-file-format-for-2d-drawings.md index 17364a1e..074a01f3 100644 --- a/docs/learn/code/common/occt/io/dxf-file-format-for-2d-drawings.md +++ b/docs/learn/code/common/occt/io/dxf-file-format-for-2d-drawings.md @@ -36,21 +36,21 @@ It's worth noting that while DXF is an extensive format with numerous entity typ fontUrlorangeColorpurpleColorgreenColortext1text1Compoundtext1WiresfilletedWireswirefilletedWiretext1Compound2dxfPaths1dxfLayer1text2text2Compoundtext2Wirestext2Compound2dxfPaths2dxfLayer2hexagonshexagonsCompounddxfPaths3dxfLayer3allLayersdxfFilefontUrlhttps://cdn.jsdelivr.net/gh/bitbybit-dev/bitbybit-assets@latest/fonts/Tektur/Tektur-Bold.ttforangeColor#ffa200purpleColor#cc80ffgreenColor#80ff00text1DXF @ bitbybit.devfontUrl1.50180002.5010centerMiddletext1Compoundtext1compoundtext1Wirestext1CompoundfilletedWireswiretext1WiresfilletedWirewire0.05INSERTLASTfilletedWiresfilletedWiretext1Compound2filletedWiresdxfPaths1text1Compound20.10.12dxfLayer1dxfPaths1BitbybitorangeColortext2CAD PowerfontUrl1018000-2010centerMiddletext2Compoundtext2compoundtext2Wirestext2Compoundtext2Compound2text2WiresdxfPaths2text2Compound20.10.12dxfLayer2dxfPaths2CAD PowerpurpleColorhexagons1524010TRUE[0.8,0.3][0.8,0.3][true, true, false]hexagonsCompoundhexagonsdxfPaths3hexagonsCompound0.10.12dxfLayer3dxfPaths3Hexagons#002afaallLayersdxfLayer1dxfLayer2dxfLayer3dxfFileallLayersbitbybit-dev.dxfTRUEfilletedWires0.01FALSETRUEorangeColor5text2Wires0.01FALSETRUEpurpleColor3hexagonsCompound0.01FALSETRUEgreenColor3","version":"0.21.0","type":"blockly"}} + script={{"script":"fontUrlorangeColorpurpleColorgreenColortext1text1Compoundtext1WiresfilletedWireswirefilletedWiretext1Compound2dxfPaths1dxfLayer1text2text2Compoundtext2Wirestext2Compound2dxfPaths2dxfLayer2hexagonshexagonsCompounddxfPaths3dxfLayer3allLayersdxfFilefontUrlhttps://cdn.jsdelivr.net/gh/bitbybit-dev/bitbybit-assets@latest/fonts/Tektur/Tektur-Bold.ttforangeColor#ffa200purpleColor#cc80ffgreenColor#80ff00text1DXF @ bitbybit.devfontUrl1.50180002.5010centerMiddletext1Compoundtext1compoundtext1Wirestext1CompoundfilletedWireswiretext1WiresfilletedWirewire0.05INSERTLASTfilletedWiresfilletedWiretext1Compound2filletedWiresdxfPaths1text1Compound20.10.12dxfLayer1dxfPaths1BitbybitorangeColortext2CAD PowerfontUrl1018000-2010centerMiddletext2Compoundtext2compoundtext2Wirestext2Compoundtext2Compound2text2WiresdxfPaths2text2Compound20.10.12dxfLayer2dxfPaths2CAD PowerpurpleColorhexagons1524010TRUE[0.8,0.3][0.8,0.3][true, true, false]hexagonsCompoundhexagonsdxfPaths3hexagonsCompound0.10.12dxfLayer3dxfPaths3Hexagons#002afaallLayersdxfLayer1dxfLayer2dxfLayer3dxfFileallLayersbitbybit-dev.dxfTRUEfilletedWires0.01FALSETRUEorangeColor5text2Wires0.01FALSETRUEpurpleColor3hexagonsCompound0.01FALSETRUEgreenColor3","version":"0.21.1","type":"blockly"}} title="DXF Export with Layers" /> {\n // Font URL for text creation\n const fontUrl = \"https://cdn.jsdelivr.net/gh/bitbybit-dev/bitbybit-assets@latest/fonts/Tektur/Tektur-Bold.ttf\";\n\n // Define colors\n const orangeColor = \"#ffa200\";\n const purpleColor = \"#cc80ff\";\n const blueColor = \"#80ff00\";\n\n // Create first text: \"DXF @ bitbybit.dev\" at z=2.5\n const text1Options = new Text3DUrlDto();\n text1Options.text = \"DXF @ bitbybit.dev\";\n text1Options.fontUrl = fontUrl;\n text1Options.fontSize = 1.5;\n text1Options.height = 0;\n text1Options.rotation = 180;\n text1Options.origin = [0, 0, 2.5] as Point3;\n text1Options.direction = [0, 1, 0] as Vector3;\n\n const text1 = await bitbybit.advanced.text3d.createWithUrl(text1Options);\n const text1Compound = text1.compound;\n\n // Get wires from the first text\n const text1Wires: TopoDSWirePointer[] = await bitbybit.occt.shapes.wire.getWires({ shape: text1Compound });\n\n // Apply fillet to each wire\n const filletedWires: TopoDSWirePointer[] = [];\n for (const wire of text1Wires) {\n const filletOptions = new FilletDto();\n filletOptions.shape = wire;\n filletOptions.radius = 0.05;\n\n const filletedWire = await bitbybit.occt.fillets.fillet2d(filletOptions);\n filletedWires.push(filletedWire);\n }\n\n // Create compound from filleted wires\n const text1Compound2 = await bitbybit.occt.shapes.compound.makeCompound({ shapes: filletedWires });\n\n // Convert first text to DXF paths\n const dxfPaths1Options = new ShapeToDxfPathsDto();\n dxfPaths1Options.shape = text1Compound2;\n dxfPaths1Options.angularDeflection = 0.1;\n dxfPaths1Options.curvatureDeflection = 0.1;\n dxfPaths1Options.minimumOfPoints = 2;\n\n const dxfPaths1 = await bitbybit.occt.io.shapeToDxfPaths(dxfPaths1Options);\n\n // Create layer for first text\n const dxfLayer1Options = new DxfPathsWithLayerDto();\n dxfLayer1Options.paths = dxfPaths1;\n dxfLayer1Options.layer = \"Bitbybit\";\n dxfLayer1Options.color = orangeColor;\n\n const dxfLayer1 = await bitbybit.occt.io.dxfPathsWithLayer(dxfLayer1Options);\n\n // Create second text: \"CAD Power\" at z=-2\n const text2Options = new Text3DUrlDto();\n text2Options.text = \"CAD Power\";\n text2Options.fontUrl = fontUrl;\n text2Options.fontSize = 1;\n text2Options.height = 0;\n text2Options.rotation = 180;\n text2Options.origin = [0, 0, -2] as Point3;\n text2Options.direction = [0, 1, 0] as Vector3;\n\n const text2 = await bitbybit.advanced.text3d.createWithUrl(text2Options);\n const text2Compound = text2.compound;\n\n // Get wires from the second text\n const text2Wires: TopoDSWirePointer[] = await bitbybit.occt.shapes.wire.getWires({ shape: text2Compound });\n\n // Create compound from text2 wires (no fillet for second text)\n const text2Compound2 = await bitbybit.occt.shapes.compound.makeCompound({ shapes: text2Wires });\n\n // Convert second text to DXF paths\n const dxfPaths2Options = new ShapeToDxfPathsDto();\n dxfPaths2Options.shape = text2Compound2;\n dxfPaths2Options.angularDeflection = 0.1;\n dxfPaths2Options.curvatureDeflection = 0.1;\n dxfPaths2Options.minimumOfPoints = 2;\n\n const dxfPaths2 = await bitbybit.occt.io.shapeToDxfPaths(dxfPaths2Options);\n\n // Create layer for second text\n const dxfLayer2Options = new DxfPathsWithLayerDto();\n dxfLayer2Options.paths = dxfPaths2;\n dxfLayer2Options.layer = \"CAD Power\";\n dxfLayer2Options.color = purpleColor;\n\n const dxfLayer2 = await bitbybit.occt.io.dxfPathsWithLayer(dxfLayer2Options);\n\n // Create hexagonal grid\n const hexagonsOptions = new HexagonsInGridDto();\n hexagonsOptions.width = 15;\n hexagonsOptions.height = 2;\n hexagonsOptions.nrHexagonsInWidth = 40;\n hexagonsOptions.nrHexagonsInHeight = 10;\n hexagonsOptions.flatTop = true;\n hexagonsOptions.extendTop = false;\n hexagonsOptions.extendBottom = false;\n hexagonsOptions.extendLeft = false;\n hexagonsOptions.extendRight = false;\n hexagonsOptions.scalePatternWidth = [0.8, 0.3];\n hexagonsOptions.scalePatternHeight = [0.8, 0.3];\n hexagonsOptions.inclusionPattern = [true, true, false];\n\n const hexagons = await bitbybit.occt.shapes.wire.hexagonsInGrid(hexagonsOptions);\n\n // Create compound from hexagons\n const hexagonsCompound = await bitbybit.occt.shapes.compound.makeCompound({ shapes: hexagons });\n\n // Convert hexagons to DXF paths\n const dxfPaths3Options = new ShapeToDxfPathsDto();\n dxfPaths3Options.shape = hexagonsCompound;\n dxfPaths3Options.angularDeflection = 0.1;\n dxfPaths3Options.curvatureDeflection = 0.1;\n dxfPaths3Options.minimumOfPoints = 2;\n\n const dxfPaths3 = await bitbybit.occt.io.shapeToDxfPaths(dxfPaths3Options);\n\n // Create layer for hexagons\n const dxfLayer3Options = new DxfPathsWithLayerDto();\n dxfLayer3Options.paths = dxfPaths3;\n dxfLayer3Options.layer = \"Hexagons\";\n dxfLayer3Options.color = \"#002afa\";\n\n const dxfLayer3 = await bitbybit.occt.io.dxfPathsWithLayer(dxfLayer3Options);\n\n // Combine all layers\n const allLayers = [dxfLayer1, dxfLayer2, dxfLayer3];\n\n // Create DXF file\n const dxfCreateOptions = new DxfPathsPartsListDto();\n dxfCreateOptions.pathsParts = allLayers;\n dxfCreateOptions.fileName = \"bitbybit-dev.dxf\";\n dxfCreateOptions.tryDownload = true;\n\n await bitbybit.occt.io.dxfCreate(dxfCreateOptions);\n\n // Draw the shapes for visualization\n const drawOptions1 = new Bit.Inputs.Draw.DrawOcctShapeSimpleOptions();\n drawOptions1.precision = 0.01;\n drawOptions1.drawFaces = false;\n drawOptions1.drawEdges = true;\n drawOptions1.edgeColour = orangeColor;\n drawOptions1.edgeWidth = 5;\n\n bitbybit.draw.drawAnyAsync({ entity: filletedWires, options: drawOptions1 });\n\n const drawOptions2 = new Bit.Inputs.Draw.DrawOcctShapeSimpleOptions();\n drawOptions2.precision = 0.01;\n drawOptions2.drawFaces = false;\n drawOptions2.drawEdges = true;\n drawOptions2.edgeColour = purpleColor;\n drawOptions2.edgeWidth = 3;\n\n bitbybit.draw.drawAnyAsync({ entity: text2Wires, options: drawOptions2 });\n\n // Draw the shapes for visualization\n const drawOptions3 = new Bit.Inputs.Draw.DrawOcctShapeSimpleOptions();\n drawOptions3.precision = 0.01;\n drawOptions3.drawFaces = false;\n drawOptions3.drawEdges = true;\n drawOptions3.edgeColour = blueColor;\n drawOptions3.edgeWidth = 2;\n\n bitbybit.draw.drawAnyAsync({ entity: hexagonsCompound, options: drawOptions3 });\n}\n\n// Execute the function\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"const { Text3DUrlDto } = Bit.Advanced.Text3D;\nconst { ShapeToDxfPathsDto, DxfPathsWithLayerDto, DxfPathsPartsListDto } = Bit.Inputs.OCCT;\nconst { FilletDto } = Bit.Inputs.OCCT;\nconst { HexagonsInGridDto } = Bit.Inputs.OCCT;\n\n// Import required types\ntype TopoDSWirePointer = Bit.Inputs.OCCT.TopoDSWirePointer;\ntype TopoDSShapePointer = Bit.Inputs.OCCT.TopoDSShapePointer;\ntype Point3 = Bit.Inputs.Base.Point3;\ntype Vector3 = Bit.Inputs.Base.Vector3;\n\n// Define the main function\nconst start = async () => {\n // Font URL for text creation\n const fontUrl = \"https://cdn.jsdelivr.net/gh/bitbybit-dev/bitbybit-assets@latest/fonts/Tektur/Tektur-Bold.ttf\";\n\n // Define colors\n const orangeColor = \"#ffa200\";\n const purpleColor = \"#cc80ff\";\n const blueColor = \"#80ff00\";\n\n // Create first text: \"DXF @ bitbybit.dev\" at z=2.5\n const text1Options = new Text3DUrlDto();\n text1Options.text = \"DXF @ bitbybit.dev\";\n text1Options.fontUrl = fontUrl;\n text1Options.fontSize = 1.5;\n text1Options.height = 0;\n text1Options.rotation = 180;\n text1Options.origin = [0, 0, 2.5] as Point3;\n text1Options.direction = [0, 1, 0] as Vector3;\n\n const text1 = await bitbybit.advanced.text3d.createWithUrl(text1Options);\n const text1Compound = text1.compound;\n\n // Get wires from the first text\n const text1Wires: TopoDSWirePointer[] = await bitbybit.occt.shapes.wire.getWires({ shape: text1Compound });\n\n // Apply fillet to each wire\n const filletedWires: TopoDSWirePointer[] = [];\n for (const wire of text1Wires) {\n const filletOptions = new FilletDto();\n filletOptions.shape = wire;\n filletOptions.radius = 0.05;\n\n const filletedWire = await bitbybit.occt.fillets.fillet2d(filletOptions);\n filletedWires.push(filletedWire);\n }\n\n // Create compound from filleted wires\n const text1Compound2 = await bitbybit.occt.shapes.compound.makeCompound({ shapes: filletedWires });\n\n // Convert first text to DXF paths\n const dxfPaths1Options = new ShapeToDxfPathsDto();\n dxfPaths1Options.shape = text1Compound2;\n dxfPaths1Options.angularDeflection = 0.1;\n dxfPaths1Options.curvatureDeflection = 0.1;\n dxfPaths1Options.minimumOfPoints = 2;\n\n const dxfPaths1 = await bitbybit.occt.io.shapeToDxfPaths(dxfPaths1Options);\n\n // Create layer for first text\n const dxfLayer1Options = new DxfPathsWithLayerDto();\n dxfLayer1Options.paths = dxfPaths1;\n dxfLayer1Options.layer = \"Bitbybit\";\n dxfLayer1Options.color = orangeColor;\n\n const dxfLayer1 = await bitbybit.occt.io.dxfPathsWithLayer(dxfLayer1Options);\n\n // Create second text: \"CAD Power\" at z=-2\n const text2Options = new Text3DUrlDto();\n text2Options.text = \"CAD Power\";\n text2Options.fontUrl = fontUrl;\n text2Options.fontSize = 1;\n text2Options.height = 0;\n text2Options.rotation = 180;\n text2Options.origin = [0, 0, -2] as Point3;\n text2Options.direction = [0, 1, 0] as Vector3;\n\n const text2 = await bitbybit.advanced.text3d.createWithUrl(text2Options);\n const text2Compound = text2.compound;\n\n // Get wires from the second text\n const text2Wires: TopoDSWirePointer[] = await bitbybit.occt.shapes.wire.getWires({ shape: text2Compound });\n\n // Create compound from text2 wires (no fillet for second text)\n const text2Compound2 = await bitbybit.occt.shapes.compound.makeCompound({ shapes: text2Wires });\n\n // Convert second text to DXF paths\n const dxfPaths2Options = new ShapeToDxfPathsDto();\n dxfPaths2Options.shape = text2Compound2;\n dxfPaths2Options.angularDeflection = 0.1;\n dxfPaths2Options.curvatureDeflection = 0.1;\n dxfPaths2Options.minimumOfPoints = 2;\n\n const dxfPaths2 = await bitbybit.occt.io.shapeToDxfPaths(dxfPaths2Options);\n\n // Create layer for second text\n const dxfLayer2Options = new DxfPathsWithLayerDto();\n dxfLayer2Options.paths = dxfPaths2;\n dxfLayer2Options.layer = \"CAD Power\";\n dxfLayer2Options.color = purpleColor;\n\n const dxfLayer2 = await bitbybit.occt.io.dxfPathsWithLayer(dxfLayer2Options);\n\n // Create hexagonal grid\n const hexagonsOptions = new HexagonsInGridDto();\n hexagonsOptions.width = 15;\n hexagonsOptions.height = 2;\n hexagonsOptions.nrHexagonsInWidth = 40;\n hexagonsOptions.nrHexagonsInHeight = 10;\n hexagonsOptions.flatTop = true;\n hexagonsOptions.extendTop = false;\n hexagonsOptions.extendBottom = false;\n hexagonsOptions.extendLeft = false;\n hexagonsOptions.extendRight = false;\n hexagonsOptions.scalePatternWidth = [0.8, 0.3];\n hexagonsOptions.scalePatternHeight = [0.8, 0.3];\n hexagonsOptions.inclusionPattern = [true, true, false];\n\n const hexagons = await bitbybit.occt.shapes.wire.hexagonsInGrid(hexagonsOptions);\n\n // Create compound from hexagons\n const hexagonsCompound = await bitbybit.occt.shapes.compound.makeCompound({ shapes: hexagons });\n\n // Convert hexagons to DXF paths\n const dxfPaths3Options = new ShapeToDxfPathsDto();\n dxfPaths3Options.shape = hexagonsCompound;\n dxfPaths3Options.angularDeflection = 0.1;\n dxfPaths3Options.curvatureDeflection = 0.1;\n dxfPaths3Options.minimumOfPoints = 2;\n\n const dxfPaths3 = await bitbybit.occt.io.shapeToDxfPaths(dxfPaths3Options);\n\n // Create layer for hexagons\n const dxfLayer3Options = new DxfPathsWithLayerDto();\n dxfLayer3Options.paths = dxfPaths3;\n dxfLayer3Options.layer = \"Hexagons\";\n dxfLayer3Options.color = \"#002afa\";\n\n const dxfLayer3 = await bitbybit.occt.io.dxfPathsWithLayer(dxfLayer3Options);\n\n // Combine all layers\n const allLayers = [dxfLayer1, dxfLayer2, dxfLayer3];\n\n // Create DXF file\n const dxfCreateOptions = new DxfPathsPartsListDto();\n dxfCreateOptions.pathsParts = allLayers;\n dxfCreateOptions.fileName = \"bitbybit-dev.dxf\";\n dxfCreateOptions.tryDownload = true;\n\n await bitbybit.occt.io.dxfCreate(dxfCreateOptions);\n\n // Draw the shapes for visualization\n const drawOptions1 = new Bit.Inputs.Draw.DrawOcctShapeSimpleOptions();\n drawOptions1.precision = 0.01;\n drawOptions1.drawFaces = false;\n drawOptions1.drawEdges = true;\n drawOptions1.edgeColour = orangeColor;\n drawOptions1.edgeWidth = 5;\n\n bitbybit.draw.drawAnyAsync({ entity: filletedWires, options: drawOptions1 });\n\n const drawOptions2 = new Bit.Inputs.Draw.DrawOcctShapeSimpleOptions();\n drawOptions2.precision = 0.01;\n drawOptions2.drawFaces = false;\n drawOptions2.drawEdges = true;\n drawOptions2.edgeColour = purpleColor;\n drawOptions2.edgeWidth = 3;\n\n bitbybit.draw.drawAnyAsync({ entity: text2Wires, options: drawOptions2 });\n\n // Draw the shapes for visualization\n const drawOptions3 = new Bit.Inputs.Draw.DrawOcctShapeSimpleOptions();\n drawOptions3.precision = 0.01;\n drawOptions3.drawFaces = false;\n drawOptions3.drawEdges = true;\n drawOptions3.edgeColour = blueColor;\n drawOptions3.edgeWidth = 2;\n\n bitbybit.draw.drawAnyAsync({ entity: hexagonsCompound, options: drawOptions3 });\n}\n\n// Execute the function\nstart();","version":"0.21.1","type":"typescript"}} title="DXF Export with Layers" /> diff --git a/docs/learn/code/common/occt/modeling/festive-decor/frost-flower.md b/docs/learn/code/common/occt/modeling/festive-decor/frost-flower.md index 342fdd9b..4cff6536 100644 --- a/docs/learn/code/common/occt/modeling/festive-decor/frost-flower.md +++ b/docs/learn/code/common/occt/modeling/festive-decor/frost-flower.md @@ -34,21 +34,21 @@ The algorithm: sizebranchWirecombinedWireouterWireinnerWirehollowFacesnowflakesize0.8branchWire0000.3MULTIPLY1.5size0-0.2MULTIPLY2.5size00.4MULTIPLY3.5size00MULTIPLY4size0FALSE0.00001combinedWirebranchWirebranchWire001180outerWirecombinedWire0.40.1innerWirecombinedWire0.20.1hollowFaceouterWireinnerWireTRUEsnowflakehollowFacehollowFace00130hollowFace00160hollowFace00190hollowFace001120hollowFace001150FALSEsnowflake000.20.01Ice Material#aed6f1#5dade20.10.31FALSE2FALSE#ffffff2","version":"0.21.0","type":"blockly"}} + script={{"script":"sizebranchWirecombinedWireouterWireinnerWirehollowFacesnowflakesize0.8branchWire0000.3MULTIPLY1.5size0-0.2MULTIPLY2.5size00.4MULTIPLY3.5size00MULTIPLY4size0FALSE0.00001combinedWirebranchWirebranchWire001180outerWirecombinedWire0.40.1innerWirecombinedWire0.20.1hollowFaceouterWireinnerWireTRUEsnowflakehollowFacehollowFace00130hollowFace00160hollowFace00190hollowFace001120hollowFace001150FALSEsnowflake000.20.01Ice Material#aed6f1#5dade20.10.31FALSE2FALSE#ffffff2","version":"0.21.1","type":"blockly"}} title="Star ornament with hanging hole" /> {\n const size = 0.8;\n\n const branchPoints: Point3[] = [\n [0, 0, 0],\n [0.3, 1.5 * size, 0],\n [-0.2, 2.5 * size, 0],\n [0.4, 3.5 * size, 0],\n [0, 4 * size, 0],\n ];\n\n const interpolation = new InterpolationDto();\n interpolation.points = branchPoints;\n interpolation.periodic = false;\n interpolation.tolerance = 0.00001;\n const branchWire = await wire.interpolatePoints(interpolation);\n\n const rotate180 = new RotateDto();\n rotate180.shape = branchWire;\n rotate180.axis = [0, 0, 1];\n rotate180.angle = 180;\n const branchWireRotated = await transforms.rotate(rotate180);\n\n const combine = new ShapesDto();\n combine.shapes = [branchWire, branchWireRotated];\n const combinedWire = await wire.combineEdgesAndWiresIntoAWire(combine);\n\n const offsetOuter = new OffsetDto();\n offsetOuter.shape = combinedWire;\n offsetOuter.distance = 0.4;\n offsetOuter.tolerance = 0.1;\n const outerWire = (await operations.offset(offsetOuter)) as unknown as TopoDSWirePointer;\n\n const offsetInner = new OffsetDto();\n offsetInner.shape = combinedWire;\n offsetInner.distance = 0.2;\n offsetInner.tolerance = 0.1;\n const innerWireRaw = (await operations.offset(offsetInner)) as unknown as TopoDSWirePointer;\n\n const reverse = new ShapeDto();\n reverse.shape = innerWireRaw;\n const innerWire = await wire.reversedWire(reverse);\n\n const faceFromWires = new FaceFromWiresDto();\n faceFromWires.shapes = [outerWire, innerWire];\n faceFromWires.planar = true;\n const hollowFace = await face.createFaceFromWires(faceFromWires);\n\n const angles = [0, 30, 60, 90, 120, 150];\n const rotatedFaces: TopoDSShapePointer[] = [];\n\n for (const angle of angles) {\n if (angle === 0) {\n rotatedFaces.push(hollowFace);\n continue;\n }\n const rotate = new RotateDto();\n rotate.shape = hollowFace;\n rotate.axis = [0, 0, 1];\n rotate.angle = angle;\n rotatedFaces.push(await transforms.rotate(rotate));\n }\n\n const union = new UnionDto();\n union.shapes = rotatedFaces;\n union.keepEdges = false;\n const snowflakeFace = await booleans.union(union);\n\n const extrude = new ExtrudeDto();\n extrude.shape = snowflakeFace;\n extrude.direction = [0, 0, 0.2];\n const snowflakeSolid = await operations.extrude(extrude);\n\n const materialOptions = new PBRMetallicRoughnessDto();\n materialOptions.name = 'Ice Material';\n materialOptions.baseColor = '#aed6f1';\n materialOptions.emissiveColor = '#5dade2';\n materialOptions.metallic = 0.1;\n materialOptions.roughness = 0.3;\n materialOptions.alpha = 1;\n materialOptions.backFaceCulling = false;\n materialOptions.zOffset = 2;\n const material = bitbybit.babylon.material.pbrMetallicRoughness.create(materialOptions);\n\n const drawOptions = new DrawOcctShapeOptions();\n drawOptions.precision = 0.01;\n drawOptions.drawEdges = false;\n drawOptions.edgeColour = '#ffffff';\n drawOptions.edgeWidth = 2;\n drawOptions.faceMaterial = material;\n\n const starMesh = await bitbybit.draw.drawAnyAsync({\n entity: snowflakeSolid,\n options: drawOptions,\n });\n\n const options = new ZoomOnDto();\n options.meshes = [starMesh];\n bitbybit.advanced.navigation.zoomOn(options);\n};\n\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"const { InterpolationDto, RotateDto, ShapesDto, OffsetDto, FaceFromWiresDto, ExtrudeDto, UnionDto, ShapeDto } = Bit.Inputs.OCCT;\nconst { PBRMetallicRoughnessDto } = Bit.Inputs.BabylonMaterial;\nconst { DrawOcctShapeOptions } = Bit.Inputs.Draw;\nconst { ZoomOnDto } = Bit.Advanced.Navigation;\n\ntype Point3 = Bit.Inputs.Base.Point3;\ntype TopoDSWirePointer = Bit.Inputs.OCCT.TopoDSWirePointer;\ntype TopoDSFacePointer = Bit.Inputs.OCCT.TopoDSFacePointer;\ntype TopoDSShapePointer = Bit.Inputs.OCCT.TopoDSShapePointer;\n\nconst { wire, face } = bitbybit.occt.shapes;\nconst { operations, transforms, booleans } = bitbybit.occt;\n\nconst start = async () => {\n const size = 0.8;\n\n const branchPoints: Point3[] = [\n [0, 0, 0],\n [0.3, 1.5 * size, 0],\n [-0.2, 2.5 * size, 0],\n [0.4, 3.5 * size, 0],\n [0, 4 * size, 0],\n ];\n\n const interpolation = new InterpolationDto();\n interpolation.points = branchPoints;\n interpolation.periodic = false;\n interpolation.tolerance = 0.00001;\n const branchWire = await wire.interpolatePoints(interpolation);\n\n const rotate180 = new RotateDto();\n rotate180.shape = branchWire;\n rotate180.axis = [0, 0, 1];\n rotate180.angle = 180;\n const branchWireRotated = await transforms.rotate(rotate180);\n\n const combine = new ShapesDto();\n combine.shapes = [branchWire, branchWireRotated];\n const combinedWire = await wire.combineEdgesAndWiresIntoAWire(combine);\n\n const offsetOuter = new OffsetDto();\n offsetOuter.shape = combinedWire;\n offsetOuter.distance = 0.4;\n offsetOuter.tolerance = 0.1;\n const outerWire = (await operations.offset(offsetOuter)) as unknown as TopoDSWirePointer;\n\n const offsetInner = new OffsetDto();\n offsetInner.shape = combinedWire;\n offsetInner.distance = 0.2;\n offsetInner.tolerance = 0.1;\n const innerWireRaw = (await operations.offset(offsetInner)) as unknown as TopoDSWirePointer;\n\n const reverse = new ShapeDto();\n reverse.shape = innerWireRaw;\n const innerWire = await wire.reversedWire(reverse);\n\n const faceFromWires = new FaceFromWiresDto();\n faceFromWires.shapes = [outerWire, innerWire];\n faceFromWires.planar = true;\n const hollowFace = await face.createFaceFromWires(faceFromWires);\n\n const angles = [0, 30, 60, 90, 120, 150];\n const rotatedFaces: TopoDSShapePointer[] = [];\n\n for (const angle of angles) {\n if (angle === 0) {\n rotatedFaces.push(hollowFace);\n continue;\n }\n const rotate = new RotateDto();\n rotate.shape = hollowFace;\n rotate.axis = [0, 0, 1];\n rotate.angle = angle;\n rotatedFaces.push(await transforms.rotate(rotate));\n }\n\n const union = new UnionDto();\n union.shapes = rotatedFaces;\n union.keepEdges = false;\n const snowflakeFace = await booleans.union(union);\n\n const extrude = new ExtrudeDto();\n extrude.shape = snowflakeFace;\n extrude.direction = [0, 0, 0.2];\n const snowflakeSolid = await operations.extrude(extrude);\n\n const materialOptions = new PBRMetallicRoughnessDto();\n materialOptions.name = 'Ice Material';\n materialOptions.baseColor = '#aed6f1';\n materialOptions.emissiveColor = '#5dade2';\n materialOptions.metallic = 0.1;\n materialOptions.roughness = 0.3;\n materialOptions.alpha = 1;\n materialOptions.backFaceCulling = false;\n materialOptions.zOffset = 2;\n const material = bitbybit.babylon.material.pbrMetallicRoughness.create(materialOptions);\n\n const drawOptions = new DrawOcctShapeOptions();\n drawOptions.precision = 0.01;\n drawOptions.drawEdges = false;\n drawOptions.edgeColour = '#ffffff';\n drawOptions.edgeWidth = 2;\n drawOptions.faceMaterial = material;\n\n const starMesh = await bitbybit.draw.drawAnyAsync({\n entity: snowflakeSolid,\n options: drawOptions,\n });\n\n const options = new ZoomOnDto();\n options.meshes = [starMesh];\n bitbybit.advanced.navigation.zoomOn(options);\n};\n\nstart();","version":"0.21.1","type":"typescript"}} title="Star ornament with hanging hole" /> diff --git a/docs/learn/code/common/occt/modeling/festive-decor/frozen-snowflake.md b/docs/learn/code/common/occt/modeling/festive-decor/frozen-snowflake.md index 3fc6fe4c..999f9829 100644 --- a/docs/learn/code/common/occt/modeling/festive-decor/frozen-snowflake.md +++ b/docs/learn/code/common/occt/modeling/festive-decor/frozen-snowflake.md @@ -33,21 +33,21 @@ The algorithm: nrZigZagsinnerHex1outerHex1zigzag1zigzag1ScaledinnerHex2outerHex2zigzag2zigzag2Scaledloft1loft2loft2Translatedloft3faces1everySecondMaineverySecondEnd1faces2everySecondEnd2faces3facesListForExtrusioncurrentFaceallExtrudedFacesextrudedFaceallExtrudedFaces2currentFace2compound1compound2'city'10000.10.7TRUEnrZigZags5innerHex100.2001063outerHex100.2001063.7zigzag1innerHex1outerHex1nrZigZagsFALSEFALSETRUEzigzag1Scaledzigzag13innerHex200001062outerHex200001062.5zigzag2innerHex2outerHex2nrZigZagsFALSEFALSETRUEzigzag2Scaledzigzag26loft1zigzag2zigzag1zigzag1Scaledzigzag2ScaledFALSEFALSEFALSETRUE10FALSE31e-7approxCentripetalloft2zigzag2Scaledzigzag1ScaledFALSEFALSEFALSETRUE10FALSE31e-7approxCentripetalloft2Translatedloft200.30loft3zigzag2zigzag1FALSEFALSEFALSETRUE10FALSE31e-7approxCentripetalfaces1loft1everySecondMainfaces121TRUEeverySecondEnd1loft2Translatedfaces2everySecondEnd120TRUEeverySecondEnd2loft3faces3everySecondEnd220TRUEfacesListForExtrusioncurrentFacefaces2INSERTLASTfacesListForExtrusioncurrentFacecurrentFacefaces3INSERTLASTfacesListForExtrusioncurrentFaceallExtrudedFacescurrentFacefacesListForExtrusionextrudedFacecurrentFace00.30INSERTLASTallExtrudedFacesextrudedFaceallExtrudedFaces2currentFace2everySecondMainextrudedFacecurrentFace200.30INSERTLASTallExtrudedFaces2extrudedFacecompound1allExtrudedFaces2compound2allExtrudedFacescompound10.01Material 1#94b4ff#0000000.80.21FALSE2FALSE#ffffff4compound20.01Material 2#33ffc2#0000000.80.21FALSE0FALSE#ffffff2","version":"0.21.0","type":"blockly"}} + script={{"script":"nrZigZagsinnerHex1outerHex1zigzag1zigzag1ScaledinnerHex2outerHex2zigzag2zigzag2Scaledloft1loft2loft2Translatedloft3faces1everySecondMaineverySecondEnd1faces2everySecondEnd2faces3facesListForExtrusioncurrentFaceallExtrudedFacesextrudedFaceallExtrudedFaces2currentFace2compound1compound2'city'10000.10.7TRUEnrZigZags5innerHex100.2001063outerHex100.2001063.7zigzag1innerHex1outerHex1nrZigZagsFALSEFALSETRUEzigzag1Scaledzigzag13innerHex200001062outerHex200001062.5zigzag2innerHex2outerHex2nrZigZagsFALSEFALSETRUEzigzag2Scaledzigzag26loft1zigzag2zigzag1zigzag1Scaledzigzag2ScaledFALSEFALSEFALSETRUE10FALSE31e-7approxCentripetalloft2zigzag2Scaledzigzag1ScaledFALSEFALSEFALSETRUE10FALSE31e-7approxCentripetalloft2Translatedloft200.30loft3zigzag2zigzag1FALSEFALSEFALSETRUE10FALSE31e-7approxCentripetalfaces1loft1everySecondMainfaces121TRUEeverySecondEnd1loft2Translatedfaces2everySecondEnd120TRUEeverySecondEnd2loft3faces3everySecondEnd220TRUEfacesListForExtrusioncurrentFacefaces2INSERTLASTfacesListForExtrusioncurrentFacecurrentFacefaces3INSERTLASTfacesListForExtrusioncurrentFaceallExtrudedFacescurrentFacefacesListForExtrusionextrudedFacecurrentFace00.30INSERTLASTallExtrudedFacesextrudedFaceallExtrudedFaces2currentFace2everySecondMainextrudedFacecurrentFace200.30INSERTLASTallExtrudedFaces2extrudedFacecompound1allExtrudedFaces2compound2allExtrudedFacescompound10.01Material 1#94b4ff#0000000.80.21FALSE2FALSE#ffffff4compound20.01Material 2#33ffc2#0000000.80.21FALSE0FALSE#ffffff2","version":"0.21.1","type":"blockly"}} title="Frozen Snowflake" /> {\n const skyboxOpt = new SkyboxDto();\n skyboxOpt.skybox = skyboxEnum.city;\n skyboxOpt.hideSkybox = true;\n bitbybit.babylon.scene.enableSkybox(skyboxOpt);\n\n const nrZigZags = 5;\n\n // Create first set of hexagon wires\n const innerHex1Dto = new NGonWireDto();\n innerHex1Dto.center = [0, 0.2, 0];\n innerHex1Dto.direction = [0, 1, 0];\n innerHex1Dto.nrCorners = 6;\n innerHex1Dto.radius = 3;\n const innerHex1 = await wire.createNGonWire(innerHex1Dto);\n\n const outerHex1Dto = new NGonWireDto();\n outerHex1Dto.center = [0, 0.2, 0];\n outerHex1Dto.direction = [0, 1, 0];\n outerHex1Dto.nrCorners = 6;\n outerHex1Dto.radius = 3.7;\n const outerHex1 = await wire.createNGonWire(outerHex1Dto);\n\n const innerHex2Dto = new NGonWireDto();\n innerHex2Dto.center = [0, 0, 0];\n innerHex2Dto.direction = [0, 1, 0];\n innerHex2Dto.nrCorners = 6;\n innerHex2Dto.radius = 2;\n const innerHex2 = await wire.createNGonWire(innerHex2Dto);\n\n const outerHex2Dto = new NGonWireDto();\n outerHex2Dto.center = [0, 0, 0];\n outerHex2Dto.direction = [0, 1, 0];\n outerHex2Dto.nrCorners = 6;\n outerHex2Dto.radius = 2.5;\n const outerHex2 = await wire.createNGonWire(outerHex2Dto);\n\n // Create zigzag wires between hexagons\n const zigzag1Dto = new ZigZagBetweenTwoWiresDto();\n zigzag1Dto.wire1 = innerHex1;\n zigzag1Dto.wire2 = outerHex1;\n zigzag1Dto.nrZigZags = nrZigZags;\n zigzag1Dto.inverse = false;\n zigzag1Dto.divideByEqualDistance = false;\n zigzag1Dto.zigZagsPerEdge = true;\n const zigzag1 = await wire.createZigZagBetweenTwoWires(zigzag1Dto);\n\n const scale1Dto = new ScaleDto();\n scale1Dto.shape = zigzag1;\n scale1Dto.factor = 3;\n const zigzag1Scaled = await transforms.scale(scale1Dto);\n\n const zigzag2Dto = new ZigZagBetweenTwoWiresDto();\n zigzag2Dto.wire1 = innerHex2;\n zigzag2Dto.wire2 = outerHex2;\n zigzag2Dto.nrZigZags = nrZigZags;\n zigzag2Dto.inverse = false;\n zigzag2Dto.divideByEqualDistance = false;\n zigzag2Dto.zigZagsPerEdge = true;\n const zigzag2 = await wire.createZigZagBetweenTwoWires(zigzag2Dto);\n\n const scale2Dto = new ScaleDto();\n scale2Dto.shape = zigzag2;\n scale2Dto.factor = 6;\n const zigzag2Scaled = await transforms.scale(scale2Dto);\n\n // Create loft surfaces\n const loft1Dto = new LoftAdvancedDto();\n loft1Dto.shapes = [zigzag2, zigzag1, zigzag1Scaled, zigzag2Scaled];\n loft1Dto.makeSolid = false;\n loft1Dto.closed = false;\n loft1Dto.periodic = false;\n loft1Dto.straight = true;\n loft1Dto.nrPeriodicSections = 10;\n loft1Dto.useSmoothing = false;\n loft1Dto.maxUDegree = 3;\n loft1Dto.tolerance = 1e-7;\n loft1Dto.parType = approxParametrizationTypeEnum.approxCentripetal;\n const loft1 = await operations.loftAdvanced(loft1Dto);\n\n const loft2Dto = new LoftAdvancedDto();\n loft2Dto.shapes = [zigzag2Scaled, zigzag1Scaled];\n loft2Dto.makeSolid = false;\n loft2Dto.closed = false;\n loft2Dto.periodic = false;\n loft2Dto.straight = true;\n loft2Dto.nrPeriodicSections = 10;\n loft2Dto.useSmoothing = false;\n loft2Dto.maxUDegree = 3;\n loft2Dto.tolerance = 1e-7;\n loft1Dto.parType = approxParametrizationTypeEnum.approxCentripetal;\n const loft2 = await operations.loftAdvanced(loft2Dto);\n\n const translateDto = new TranslateDto();\n translateDto.shape = loft2;\n translateDto.translation = [0, 0.3, 0];\n const loft2Translated = await transforms.translate(translateDto);\n\n const loft3Dto = new LoftAdvancedDto();\n loft3Dto.shapes = [zigzag2, zigzag1];\n loft3Dto.makeSolid = false;\n loft3Dto.closed = false;\n loft3Dto.periodic = false;\n loft3Dto.straight = true;\n loft3Dto.nrPeriodicSections = 10;\n loft3Dto.useSmoothing = false;\n loft3Dto.maxUDegree = 3;\n loft3Dto.tolerance = 1e-7;\n loft1Dto.parType = approxParametrizationTypeEnum.approxCentripetal;\n const loft3 = await operations.loftAdvanced(loft3Dto);\n\n // Extract and filter faces\n const faces1All = await face.getFaces({ shape: loft1 });\n const everySecondMain = bitbybit.lists.getNthItem({\n list: faces1All,\n nth: 2,\n offset: 1,\n clone: true\n });\n\n const faces2All = await face.getFaces({ shape: loft2Translated });\n const everySecondEnd1 = bitbybit.lists.getNthItem({\n list: faces2All,\n nth: 2,\n offset: 0,\n clone: true\n });\n\n const faces3All = await face.getFaces({ shape: loft3 });\n const everySecondEnd2 = bitbybit.lists.getNthItem({\n list: faces3All,\n nth: 2,\n offset: 0,\n clone: true\n });\n\n // Combine faces for extrusion\n const facesForExtrusion: TopoDSFacePointer[] = [\n ...everySecondEnd1,\n ...everySecondEnd2\n ];\n\n // Extrude all faces\n const extrudedFaces: TopoDSShapePointer[] = [];\n for (const faceToExtrude of facesForExtrusion) {\n const extrudeDto = new ExtrudeDto();\n extrudeDto.shape = faceToExtrude;\n extrudeDto.direction = [0, 0.3, 0];\n const extruded = await operations.extrude(extrudeDto);\n extrudedFaces.push(extruded);\n }\n\n const extrudedFacesMain: TopoDSShapePointer[] = [];\n for (const faceToExtrude of everySecondMain) {\n const extrudeDto = new ExtrudeDto();\n extrudeDto.shape = faceToExtrude;\n extrudeDto.direction = [0, 0.3, 0];\n const extruded = await operations.extrude(extrudeDto);\n extrudedFacesMain.push(extruded);\n }\n\n // Create compounds\n const compoundDto1 = new ShapesDto();\n compoundDto1.shapes = extrudedFacesMain;\n const compound1 = await compound.makeCompound(compoundDto1);\n\n const compoundDto2 = new ShapesDto();\n compoundDto2.shapes = extrudedFaces;\n const compound2 = await compound.makeCompound(compoundDto2);\n\n // Create materials\n const material1Dto = new PBRMetallicRoughnessDto();\n material1Dto.name = 'Material 1';\n material1Dto.baseColor = '#94b4ff';\n material1Dto.emissiveColor = '#000000';\n material1Dto.metallic = 0.8;\n material1Dto.roughness = 0.2;\n material1Dto.alpha = 1;\n material1Dto.backFaceCulling = false;\n material1Dto.zOffset = 2;\n const material1 = bitbybit.babylon.material.pbrMetallicRoughness.create(material1Dto);\n\n const material2Dto = new PBRMetallicRoughnessDto();\n material2Dto.name = 'Material 2';\n material2Dto.baseColor = '#33ffc2';\n material2Dto.emissiveColor = '#000000';\n material2Dto.metallic = 0.8;\n material2Dto.roughness = 0.2;\n material2Dto.alpha = 1;\n material2Dto.backFaceCulling = false;\n material2Dto.zOffset = 0;\n const material2 = bitbybit.babylon.material.pbrMetallicRoughness.create(material2Dto);\n\n // Draw the compounds\n const drawOptions1 = new DrawOcctShapeOptions();\n drawOptions1.precision = 0.01;\n drawOptions1.faceMaterial = material1;\n drawOptions1.drawEdges = false;\n drawOptions1.edgeColour = '#ffffff';\n drawOptions1.edgeWidth = 4;\n\n await bitbybit.draw.drawAnyAsync({\n entity: compound1,\n options: drawOptions1\n });\n\n const drawOptions2 = new DrawOcctShapeOptions();\n drawOptions2.precision = 0.01;\n drawOptions2.faceMaterial = material2;\n drawOptions2.drawEdges = false;\n drawOptions2.edgeColour = '#ffffff';\n drawOptions2.edgeWidth = 2;\n\n const drawnMesh = await bitbybit.draw.drawAnyAsync({\n entity: compound2,\n options: drawOptions2\n });\n\n const zoomOnOptions = new ZoomOnDto();\n zoomOnOptions.offset = -0.1;\n zoomOnOptions.meshes = [drawnMesh];\n bitbybit.advanced.navigation.zoomOn(zoomOnOptions);\n};\n\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"const { NGonWireDto, ZigZagBetweenTwoWiresDto, ShapesDto, ExtrudeDto, approxParametrizationTypeEnum } = Bit.Inputs.OCCT;\nconst { LoftAdvancedDto } = Bit.Inputs.OCCT;\nconst { TranslateDto, ScaleDto } = Bit.Inputs.OCCT;\nconst { PBRMetallicRoughnessDto } = Bit.Inputs.BabylonMaterial;\nconst { DrawOcctShapeOptions } = Bit.Inputs.Draw;\nconst { SkyboxDto } = Bit.Inputs.BabylonScene;\nconst { skyboxEnum } = Bit.Inputs.Base;\nconst { ZoomOnDto } = Bit.Advanced.Navigation;\n\ntype Point3 = Bit.Inputs.Base.Point3;\ntype TopoDSWirePointer = Bit.Inputs.OCCT.TopoDSWirePointer;\ntype TopoDSFacePointer = Bit.Inputs.OCCT.TopoDSFacePointer;\ntype TopoDSShapePointer = Bit.Inputs.OCCT.TopoDSShapePointer;\n\nconst { wire, face, compound } = bitbybit.occt.shapes;\nconst { operations, transforms } = bitbybit.occt;\n\nconst start = async () => {\n const skyboxOpt = new SkyboxDto();\n skyboxOpt.skybox = skyboxEnum.city;\n skyboxOpt.hideSkybox = true;\n bitbybit.babylon.scene.enableSkybox(skyboxOpt);\n\n const nrZigZags = 5;\n\n // Create first set of hexagon wires\n const innerHex1Dto = new NGonWireDto();\n innerHex1Dto.center = [0, 0.2, 0];\n innerHex1Dto.direction = [0, 1, 0];\n innerHex1Dto.nrCorners = 6;\n innerHex1Dto.radius = 3;\n const innerHex1 = await wire.createNGonWire(innerHex1Dto);\n\n const outerHex1Dto = new NGonWireDto();\n outerHex1Dto.center = [0, 0.2, 0];\n outerHex1Dto.direction = [0, 1, 0];\n outerHex1Dto.nrCorners = 6;\n outerHex1Dto.radius = 3.7;\n const outerHex1 = await wire.createNGonWire(outerHex1Dto);\n\n const innerHex2Dto = new NGonWireDto();\n innerHex2Dto.center = [0, 0, 0];\n innerHex2Dto.direction = [0, 1, 0];\n innerHex2Dto.nrCorners = 6;\n innerHex2Dto.radius = 2;\n const innerHex2 = await wire.createNGonWire(innerHex2Dto);\n\n const outerHex2Dto = new NGonWireDto();\n outerHex2Dto.center = [0, 0, 0];\n outerHex2Dto.direction = [0, 1, 0];\n outerHex2Dto.nrCorners = 6;\n outerHex2Dto.radius = 2.5;\n const outerHex2 = await wire.createNGonWire(outerHex2Dto);\n\n // Create zigzag wires between hexagons\n const zigzag1Dto = new ZigZagBetweenTwoWiresDto();\n zigzag1Dto.wire1 = innerHex1;\n zigzag1Dto.wire2 = outerHex1;\n zigzag1Dto.nrZigZags = nrZigZags;\n zigzag1Dto.inverse = false;\n zigzag1Dto.divideByEqualDistance = false;\n zigzag1Dto.zigZagsPerEdge = true;\n const zigzag1 = await wire.createZigZagBetweenTwoWires(zigzag1Dto);\n\n const scale1Dto = new ScaleDto();\n scale1Dto.shape = zigzag1;\n scale1Dto.factor = 3;\n const zigzag1Scaled = await transforms.scale(scale1Dto);\n\n const zigzag2Dto = new ZigZagBetweenTwoWiresDto();\n zigzag2Dto.wire1 = innerHex2;\n zigzag2Dto.wire2 = outerHex2;\n zigzag2Dto.nrZigZags = nrZigZags;\n zigzag2Dto.inverse = false;\n zigzag2Dto.divideByEqualDistance = false;\n zigzag2Dto.zigZagsPerEdge = true;\n const zigzag2 = await wire.createZigZagBetweenTwoWires(zigzag2Dto);\n\n const scale2Dto = new ScaleDto();\n scale2Dto.shape = zigzag2;\n scale2Dto.factor = 6;\n const zigzag2Scaled = await transforms.scale(scale2Dto);\n\n // Create loft surfaces\n const loft1Dto = new LoftAdvancedDto();\n loft1Dto.shapes = [zigzag2, zigzag1, zigzag1Scaled, zigzag2Scaled];\n loft1Dto.makeSolid = false;\n loft1Dto.closed = false;\n loft1Dto.periodic = false;\n loft1Dto.straight = true;\n loft1Dto.nrPeriodicSections = 10;\n loft1Dto.useSmoothing = false;\n loft1Dto.maxUDegree = 3;\n loft1Dto.tolerance = 1e-7;\n loft1Dto.parType = approxParametrizationTypeEnum.approxCentripetal;\n const loft1 = await operations.loftAdvanced(loft1Dto);\n\n const loft2Dto = new LoftAdvancedDto();\n loft2Dto.shapes = [zigzag2Scaled, zigzag1Scaled];\n loft2Dto.makeSolid = false;\n loft2Dto.closed = false;\n loft2Dto.periodic = false;\n loft2Dto.straight = true;\n loft2Dto.nrPeriodicSections = 10;\n loft2Dto.useSmoothing = false;\n loft2Dto.maxUDegree = 3;\n loft2Dto.tolerance = 1e-7;\n loft1Dto.parType = approxParametrizationTypeEnum.approxCentripetal;\n const loft2 = await operations.loftAdvanced(loft2Dto);\n\n const translateDto = new TranslateDto();\n translateDto.shape = loft2;\n translateDto.translation = [0, 0.3, 0];\n const loft2Translated = await transforms.translate(translateDto);\n\n const loft3Dto = new LoftAdvancedDto();\n loft3Dto.shapes = [zigzag2, zigzag1];\n loft3Dto.makeSolid = false;\n loft3Dto.closed = false;\n loft3Dto.periodic = false;\n loft3Dto.straight = true;\n loft3Dto.nrPeriodicSections = 10;\n loft3Dto.useSmoothing = false;\n loft3Dto.maxUDegree = 3;\n loft3Dto.tolerance = 1e-7;\n loft1Dto.parType = approxParametrizationTypeEnum.approxCentripetal;\n const loft3 = await operations.loftAdvanced(loft3Dto);\n\n // Extract and filter faces\n const faces1All = await face.getFaces({ shape: loft1 });\n const everySecondMain = bitbybit.lists.getNthItem({\n list: faces1All,\n nth: 2,\n offset: 1,\n clone: true\n });\n\n const faces2All = await face.getFaces({ shape: loft2Translated });\n const everySecondEnd1 = bitbybit.lists.getNthItem({\n list: faces2All,\n nth: 2,\n offset: 0,\n clone: true\n });\n\n const faces3All = await face.getFaces({ shape: loft3 });\n const everySecondEnd2 = bitbybit.lists.getNthItem({\n list: faces3All,\n nth: 2,\n offset: 0,\n clone: true\n });\n\n // Combine faces for extrusion\n const facesForExtrusion: TopoDSFacePointer[] = [\n ...everySecondEnd1,\n ...everySecondEnd2\n ];\n\n // Extrude all faces\n const extrudedFaces: TopoDSShapePointer[] = [];\n for (const faceToExtrude of facesForExtrusion) {\n const extrudeDto = new ExtrudeDto();\n extrudeDto.shape = faceToExtrude;\n extrudeDto.direction = [0, 0.3, 0];\n const extruded = await operations.extrude(extrudeDto);\n extrudedFaces.push(extruded);\n }\n\n const extrudedFacesMain: TopoDSShapePointer[] = [];\n for (const faceToExtrude of everySecondMain) {\n const extrudeDto = new ExtrudeDto();\n extrudeDto.shape = faceToExtrude;\n extrudeDto.direction = [0, 0.3, 0];\n const extruded = await operations.extrude(extrudeDto);\n extrudedFacesMain.push(extruded);\n }\n\n // Create compounds\n const compoundDto1 = new ShapesDto();\n compoundDto1.shapes = extrudedFacesMain;\n const compound1 = await compound.makeCompound(compoundDto1);\n\n const compoundDto2 = new ShapesDto();\n compoundDto2.shapes = extrudedFaces;\n const compound2 = await compound.makeCompound(compoundDto2);\n\n // Create materials\n const material1Dto = new PBRMetallicRoughnessDto();\n material1Dto.name = 'Material 1';\n material1Dto.baseColor = '#94b4ff';\n material1Dto.emissiveColor = '#000000';\n material1Dto.metallic = 0.8;\n material1Dto.roughness = 0.2;\n material1Dto.alpha = 1;\n material1Dto.backFaceCulling = false;\n material1Dto.zOffset = 2;\n const material1 = bitbybit.babylon.material.pbrMetallicRoughness.create(material1Dto);\n\n const material2Dto = new PBRMetallicRoughnessDto();\n material2Dto.name = 'Material 2';\n material2Dto.baseColor = '#33ffc2';\n material2Dto.emissiveColor = '#000000';\n material2Dto.metallic = 0.8;\n material2Dto.roughness = 0.2;\n material2Dto.alpha = 1;\n material2Dto.backFaceCulling = false;\n material2Dto.zOffset = 0;\n const material2 = bitbybit.babylon.material.pbrMetallicRoughness.create(material2Dto);\n\n // Draw the compounds\n const drawOptions1 = new DrawOcctShapeOptions();\n drawOptions1.precision = 0.01;\n drawOptions1.faceMaterial = material1;\n drawOptions1.drawEdges = false;\n drawOptions1.edgeColour = '#ffffff';\n drawOptions1.edgeWidth = 4;\n\n await bitbybit.draw.drawAnyAsync({\n entity: compound1,\n options: drawOptions1\n });\n\n const drawOptions2 = new DrawOcctShapeOptions();\n drawOptions2.precision = 0.01;\n drawOptions2.faceMaterial = material2;\n drawOptions2.drawEdges = false;\n drawOptions2.edgeColour = '#ffffff';\n drawOptions2.edgeWidth = 2;\n\n const drawnMesh = await bitbybit.draw.drawAnyAsync({\n entity: compound2,\n options: drawOptions2\n });\n\n const zoomOnOptions = new ZoomOnDto();\n zoomOnOptions.offset = -0.1;\n zoomOnOptions.meshes = [drawnMesh];\n bitbybit.advanced.navigation.zoomOn(zoomOnOptions);\n};\n\nstart();","version":"0.21.1","type":"typescript"}} title="Star ornament with hanging hole" /> diff --git a/docs/learn/code/common/occt/modeling/festive-decor/gem-star.md b/docs/learn/code/common/occt/modeling/festive-decor/gem-star.md index 6a757971..b4b8f4be 100644 --- a/docs/learn/code/common/occt/modeling/festive-decor/gem-star.md +++ b/docs/learn/code/common/occt/modeling/festive-decor/gem-star.md @@ -22,21 +22,21 @@ Create a gem-like star decoration by lofting a star-shaped wire profile to a sin raysouterRadiusinnerRadiusDivisorheightinnerRadiusstarWiretopPointloftShapemirroredShapeshapeListsewnShellsolidShapedrawnMesh'city'10000.10.7TRUErays5outerRadius4.5innerRadiusDivisor3.2height0.7innerRadiusDIVIDEouterRadiusinnerRadiusDivisorstarWire000010raysouterRadiusinnerRadiusFALSEtopPoint0height0loftShapestarWiretopPointFALSEFALSEFALSEFALSE10FALSE31e-7approxCentripetalmirroredShapeloftShape000010shapeListloftShapemirroredShapesewnShellshapeList1e-7solidShapesewnShelldrawnMeshsolidShape0.01Custom Material#4dffb2#0000000.80.31FALSE2TRUE#ffffff2drawnMeshTRUE0.8-0.3TRUE","version":"0.21.0","type":"blockly"}} +script={{"script":"raysouterRadiusinnerRadiusDivisorheightinnerRadiusstarWiretopPointloftShapemirroredShapeshapeListsewnShellsolidShapedrawnMesh'city'10000.10.7TRUErays5outerRadius4.5innerRadiusDivisor3.2height0.7innerRadiusDIVIDEouterRadiusinnerRadiusDivisorstarWire000010raysouterRadiusinnerRadiusFALSEtopPoint0height0loftShapestarWiretopPointFALSEFALSEFALSEFALSE10FALSE31e-7approxCentripetalmirroredShapeloftShape000010shapeListloftShapemirroredShapesewnShellshapeList1e-7solidShapesewnShelldrawnMeshsolidShape0.01Custom Material#4dffb2#0000000.80.31FALSE2TRUE#ffffff2drawnMeshTRUE0.8-0.3TRUE","version":"0.21.1","type":"blockly"}} title="Gem star decoration" /> {\n const skyboxOpt = new SkyboxDto();\n skyboxOpt.skybox = skyboxEnum.city;\n skyboxOpt.hideSkybox = true;\n bitbybit.babylon.scene.enableSkybox(skyboxOpt);\n\n // 1. Variables\n const rays = 5;\n const outerRadius = 4.5;\n const innerRadiusDivisor = 3.2;\n const height = 0.7;\n const innerRadius = outerRadius / innerRadiusDivisor;\n\n // 2. Create Star Wire\n const starDto = new StarDto();\n starDto.center = [0, 0, 0];\n starDto.direction = [0, 1, 0];\n starDto.numRays = rays;\n starDto.outerRadius = outerRadius;\n starDto.innerRadius = innerRadius;\n starDto.half = false;\n const starWire = await wire.createStarWire(starDto);\n\n // 3. Loft to Top Point\n const loftDto = new LoftAdvancedDto();\n loftDto.shapes = [starWire];\n loftDto.startVertex = [0, height, 0];\n loftDto.makeSolid = false;\n loftDto.closed = false;\n loftDto.periodic = false;\n loftDto.straight = false;\n loftDto.nrPeriodicSections = 10;\n loftDto.useSmoothing = false;\n loftDto.maxUDegree = 3;\n loftDto.tolerance = 1e-7;\n loftDto.parType = approxParametrizationTypeEnum.approxCentripetal;\n const loftShape = await operations.loftAdvanced(loftDto);\n\n // 4. Mirror to create bottom half\n const mirrorDto = new MirrorAlongNormalDto();\n mirrorDto.shape = loftShape;\n mirrorDto.origin = [0, 0, 0];\n mirrorDto.normal = [0, 1, 0];\n const mirroredShape = await transforms.mirrorAlongNormal(mirrorDto);\n\n // 5. Sew Faces into a Shell\n const sewDto = new SewDto();\n sewDto.shapes = [loftShape, mirroredShape];\n sewDto.tolerance = 1e-7;\n const sewnShell = await shell.sewFaces(sewDto);\n\n // 6. Create Solid from Shell\n const solidDto = new ShapeDto();\n solidDto.shape = sewnShell;\n const solidShape = await solid.fromClosedShell(solidDto);\n\n // 7. Visualization\n const materialOptions = new PBRMetallicRoughnessDto();\n materialOptions.name = 'Custom Material';\n materialOptions.baseColor = '#4dffb2';\n materialOptions.emissiveColor = '#000000';\n materialOptions.metallic = 0.8;\n materialOptions.roughness = 0.3;\n materialOptions.alpha = 1;\n materialOptions.backFaceCulling = false;\n materialOptions.zOffset = 2;\n const material = bitbybit.babylon.material.pbrMetallicRoughness.create(materialOptions);\n\n const drawOptions = new DrawOcctShapeOptions();\n drawOptions.precision = 0.01;\n drawOptions.drawEdges = true;\n drawOptions.edgeColour = '#ffffff';\n drawOptions.edgeWidth = 2;\n drawOptions.faceMaterial = material;\n\n const drawnMesh = await bitbybit.draw.drawAnyAsync({\n entity: solidShape,\n options: drawOptions,\n });\n\n const zoomDto = new ZoomOnDto();\n zoomDto.meshes = [drawnMesh];\n zoomDto.includeChildren = true;\n zoomDto.animationSpeed = 0.8;\n zoomDto.offset = -0.3;\n zoomDto.doNotUpdateMaxZ = true;\n bitbybit.advanced.navigation.zoomOn(zoomDto);\n};\n\nstart();","version":"0.21.0","type":"typescript"}} +script={{"script":"const { StarDto, LoftAdvancedDto, MirrorAlongNormalDto, SewDto, ShapeDto } = Bit.Inputs.OCCT;\nconst { PBRMetallicRoughnessDto } = Bit.Inputs.BabylonMaterial;\nconst { SkyboxDto } = Bit.Inputs.BabylonScene;\nconst { DrawOcctShapeOptions } = Bit.Inputs.Draw;\nconst { ZoomOnDto } = Bit.Advanced.Navigation;\nconst { skyboxEnum } = Bit.Inputs.Base;\nconst { approxParametrizationTypeEnum } = Bit.Inputs.OCCT;\ntype TopoDSShapePointer = Bit.Inputs.OCCT.TopoDSShapePointer;\n\nconst { wire, shell, solid } = bitbybit.occt.shapes;\nconst { operations, transforms } = bitbybit.occt;\n\nconst start = async () => {\n const skyboxOpt = new SkyboxDto();\n skyboxOpt.skybox = skyboxEnum.city;\n skyboxOpt.hideSkybox = true;\n bitbybit.babylon.scene.enableSkybox(skyboxOpt);\n\n // 1. Variables\n const rays = 5;\n const outerRadius = 4.5;\n const innerRadiusDivisor = 3.2;\n const height = 0.7;\n const innerRadius = outerRadius / innerRadiusDivisor;\n\n // 2. Create Star Wire\n const starDto = new StarDto();\n starDto.center = [0, 0, 0];\n starDto.direction = [0, 1, 0];\n starDto.numRays = rays;\n starDto.outerRadius = outerRadius;\n starDto.innerRadius = innerRadius;\n starDto.half = false;\n const starWire = await wire.createStarWire(starDto);\n\n // 3. Loft to Top Point\n const loftDto = new LoftAdvancedDto();\n loftDto.shapes = [starWire];\n loftDto.startVertex = [0, height, 0];\n loftDto.makeSolid = false;\n loftDto.closed = false;\n loftDto.periodic = false;\n loftDto.straight = false;\n loftDto.nrPeriodicSections = 10;\n loftDto.useSmoothing = false;\n loftDto.maxUDegree = 3;\n loftDto.tolerance = 1e-7;\n loftDto.parType = approxParametrizationTypeEnum.approxCentripetal;\n const loftShape = await operations.loftAdvanced(loftDto);\n\n // 4. Mirror to create bottom half\n const mirrorDto = new MirrorAlongNormalDto();\n mirrorDto.shape = loftShape;\n mirrorDto.origin = [0, 0, 0];\n mirrorDto.normal = [0, 1, 0];\n const mirroredShape = await transforms.mirrorAlongNormal(mirrorDto);\n\n // 5. Sew Faces into a Shell\n const sewDto = new SewDto();\n sewDto.shapes = [loftShape, mirroredShape];\n sewDto.tolerance = 1e-7;\n const sewnShell = await shell.sewFaces(sewDto);\n\n // 6. Create Solid from Shell\n const solidDto = new ShapeDto();\n solidDto.shape = sewnShell;\n const solidShape = await solid.fromClosedShell(solidDto);\n\n // 7. Visualization\n const materialOptions = new PBRMetallicRoughnessDto();\n materialOptions.name = 'Custom Material';\n materialOptions.baseColor = '#4dffb2';\n materialOptions.emissiveColor = '#000000';\n materialOptions.metallic = 0.8;\n materialOptions.roughness = 0.3;\n materialOptions.alpha = 1;\n materialOptions.backFaceCulling = false;\n materialOptions.zOffset = 2;\n const material = bitbybit.babylon.material.pbrMetallicRoughness.create(materialOptions);\n\n const drawOptions = new DrawOcctShapeOptions();\n drawOptions.precision = 0.01;\n drawOptions.drawEdges = true;\n drawOptions.edgeColour = '#ffffff';\n drawOptions.edgeWidth = 2;\n drawOptions.faceMaterial = material;\n\n const drawnMesh = await bitbybit.draw.drawAnyAsync({\n entity: solidShape,\n options: drawOptions,\n });\n\n const zoomDto = new ZoomOnDto();\n zoomDto.meshes = [drawnMesh];\n zoomDto.includeChildren = true;\n zoomDto.animationSpeed = 0.8;\n zoomDto.offset = -0.3;\n zoomDto.doNotUpdateMaxZ = true;\n bitbybit.advanced.navigation.zoomOn(zoomDto);\n};\n\nstart();","version":"0.21.1","type":"typescript"}} title="Gem star decoration" /> diff --git a/docs/learn/code/common/occt/modeling/festive-decor/star-ornament.md b/docs/learn/code/common/occt/modeling/festive-decor/star-ornament.md index f16e89c0..9572b1a5 100644 --- a/docs/learn/code/common/occt/modeling/festive-decor/star-ornament.md +++ b/docs/learn/code/common/occt/modeling/festive-decor/star-ornament.md @@ -28,21 +28,21 @@ Our star begins as a simple 2D wire created using the `createStarWire` function. 552000010FALSE0.3TRUE0100.150.001TRUE#0000001Star Material#ffffff#00ffcc0.80.991FALSE2","version":"0.21.0","type":"blockly"}} + script={{"script":"552000010FALSE0.3TRUE0100.150.001TRUE#0000001Star Material#ffffff#00ffcc0.80.991FALSE2","version":"0.21.1","type":"blockly"}} title="Star ornament" /> {\n // Create PBR material with emissive glow\n const materialOptions = new PBRMetallicRoughnessDto();\n materialOptions.name = \"Star Material\";\n materialOptions.baseColor = \"#ffffff\";\n materialOptions.emissiveColor = \"#00ffcc\";\n materialOptions.metallic = 0.8;\n materialOptions.roughness = 0.99;\n materialOptions.alpha = 1;\n materialOptions.backFaceCulling = false;\n materialOptions.zOffset = 2;\n const material = bitbybit.babylon.material.pbrMetallicRoughness.create(materialOptions);\n\n // Create the star wire with 5 points\n const starOptions = new StarDto();\n starOptions.numRays = 5;\n starOptions.outerRadius = 5;\n starOptions.innerRadius = 2;\n starOptions.center = [0, 0, 0];\n starOptions.direction = [0, 1, 0];\n starOptions.half = false;\n const starWire = await wire.createStarWire(starOptions);\n\n // Apply 2D fillet to round the star's corners\n const fillet2dOptions = new FilletDto();\n fillet2dOptions.shape = starWire;\n fillet2dOptions.radius = 0.3;\n const filletedWire = await fillets.fillet2d(fillet2dOptions);\n\n // Create a face from the filleted wire\n const faceOptions = new FaceFromWireDto();\n faceOptions.shape = filletedWire;\n faceOptions.planar = true;\n const starFace = await face.createFaceFromWire(faceOptions);\n\n // Extrude the face to create a 3D solid\n const extrudeOptions = new ExtrudeDto();\n extrudeOptions.shape = starFace;\n extrudeOptions.direction = [0, 1, 0];\n const starSolid = await operations.extrude(extrudeOptions);\n\n // Apply 3D fillet to smooth all edges\n const fillet3dOptions = new FilletDto();\n fillet3dOptions.shape = starSolid;\n fillet3dOptions.radius = 0.15;\n const finalStar = await fillets.filletEdges(fillet3dOptions);\n\n // Draw with custom material and edge styling\n const drawOptions = new Bit.Inputs.Draw.DrawOcctShapeOptions();\n drawOptions.precision = 0.001;\n drawOptions.drawEdges = true;\n drawOptions.edgeColour = \"#000000\";\n drawOptions.edgeWidth = 1;\n drawOptions.faceMaterial = material;\n\n bitbybit.draw.drawAnyAsync({\n entity: finalStar,\n options: drawOptions\n });\n}\n\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"const { StarDto, FilletDto, FaceFromWireDto, ExtrudeDto } = Bit.Inputs.OCCT;\nconst { PBRMetallicRoughnessDto } = Bit.Inputs.BabylonMaterial;\n\ntype TopoDSWirePointer = Bit.Inputs.OCCT.TopoDSWirePointer;\ntype TopoDSFacePointer = Bit.Inputs.OCCT.TopoDSFacePointer;\ntype TopoDSSolidPointer = Bit.Inputs.OCCT.TopoDSSolidPointer;\n\nconst { wire, face } = bitbybit.occt.shapes;\nconst { fillets, operations } = bitbybit.occt;\n\nconst start = async () => {\n // Create PBR material with emissive glow\n const materialOptions = new PBRMetallicRoughnessDto();\n materialOptions.name = \"Star Material\";\n materialOptions.baseColor = \"#ffffff\";\n materialOptions.emissiveColor = \"#00ffcc\";\n materialOptions.metallic = 0.8;\n materialOptions.roughness = 0.99;\n materialOptions.alpha = 1;\n materialOptions.backFaceCulling = false;\n materialOptions.zOffset = 2;\n const material = bitbybit.babylon.material.pbrMetallicRoughness.create(materialOptions);\n\n // Create the star wire with 5 points\n const starOptions = new StarDto();\n starOptions.numRays = 5;\n starOptions.outerRadius = 5;\n starOptions.innerRadius = 2;\n starOptions.center = [0, 0, 0];\n starOptions.direction = [0, 1, 0];\n starOptions.half = false;\n const starWire = await wire.createStarWire(starOptions);\n\n // Apply 2D fillet to round the star's corners\n const fillet2dOptions = new FilletDto();\n fillet2dOptions.shape = starWire;\n fillet2dOptions.radius = 0.3;\n const filletedWire = await fillets.fillet2d(fillet2dOptions);\n\n // Create a face from the filleted wire\n const faceOptions = new FaceFromWireDto();\n faceOptions.shape = filletedWire;\n faceOptions.planar = true;\n const starFace = await face.createFaceFromWire(faceOptions);\n\n // Extrude the face to create a 3D solid\n const extrudeOptions = new ExtrudeDto();\n extrudeOptions.shape = starFace;\n extrudeOptions.direction = [0, 1, 0];\n const starSolid = await operations.extrude(extrudeOptions);\n\n // Apply 3D fillet to smooth all edges\n const fillet3dOptions = new FilletDto();\n fillet3dOptions.shape = starSolid;\n fillet3dOptions.radius = 0.15;\n const finalStar = await fillets.filletEdges(fillet3dOptions);\n\n // Draw with custom material and edge styling\n const drawOptions = new Bit.Inputs.Draw.DrawOcctShapeOptions();\n drawOptions.precision = 0.001;\n drawOptions.drawEdges = true;\n drawOptions.edgeColour = \"#000000\";\n drawOptions.edgeWidth = 1;\n drawOptions.faceMaterial = material;\n\n bitbybit.draw.drawAnyAsync({\n entity: finalStar,\n options: drawOptions\n });\n}\n\nstart();","version":"0.21.1","type":"typescript"}} title="Star ornament" /> @@ -75,21 +75,21 @@ The cylinder is positioned at the top of the star (at the outer radius on the Z- outerRadiusouterRadius5.10000105outerRadiusDIVIDEouterRadius3FALSE0.3TRUE010DIVIDEouterRadius2000100.220.150.001Star Material#ffffff#00ffcc0.80.991FALSE2TRUE#0000001","version":"0.21.0","type":"blockly"}} + script={{"script":"outerRadiusouterRadius5.10000105outerRadiusDIVIDEouterRadius3FALSE0.3TRUE010DIVIDEouterRadius2000100.220.150.001Star Material#ffffff#00ffcc0.80.991FALSE2TRUE#0000001","version":"0.21.1","type":"blockly"}} title="Star ornament with hanging hole" /> {\n // Define outer radius as a variable (like the slider in Rete)\n const outerRadius = 5.1;\n const innerRadius = outerRadius / 3;\n\n // Create PBR material with emissive glow\n const materialOptions = new PBRMetallicRoughnessDto();\n materialOptions.name = \"Star Material\";\n materialOptions.baseColor = \"#ffffff\";\n materialOptions.emissiveColor = \"#00ffcc\";\n materialOptions.metallic = 0.8;\n materialOptions.roughness = 0.99;\n materialOptions.alpha = 1;\n materialOptions.backFaceCulling = false;\n materialOptions.zOffset = 2;\n const material = bitbybit.babylon.material.pbrMetallicRoughness.create(materialOptions);\n\n // Create the star wire with 5 points\n const starOptions = new StarDto();\n starOptions.numRays = 5;\n starOptions.outerRadius = outerRadius;\n starOptions.innerRadius = innerRadius;\n starOptions.center = [0, 0, 0];\n starOptions.direction = [0, 1, 0];\n starOptions.half = false;\n const starWire = await wire.createStarWire(starOptions);\n\n // Apply 2D fillet to round the star's corners\n const fillet2dOptions = new FilletDto();\n fillet2dOptions.shape = starWire;\n fillet2dOptions.radius = 0.3;\n const filletedWire = await fillets.fillet2d(fillet2dOptions);\n\n // Create a face from the filleted wire\n const faceOptions = new FaceFromWireDto();\n faceOptions.shape = filletedWire;\n faceOptions.planar = true;\n const starFace = await face.createFaceFromWire(faceOptions);\n\n // Extrude the face to create a 3D solid\n const extrudeOptions = new ExtrudeDto();\n extrudeOptions.shape = starFace;\n extrudeOptions.direction = [0, 1, 0];\n const starSolid = await operations.extrude(extrudeOptions);\n\n // Create cylinder for the hanging hole\n const cylinderOptions = new CylinderDto();\n cylinderOptions.center = [outerRadius / 2, 0, 0]; // Position based on outer radius\n cylinderOptions.direction = [0, 1, 0];\n cylinderOptions.radius = 0.2;\n cylinderOptions.height = 2;\n const holeCylinder = await solid.createCylinder(cylinderOptions);\n\n // Boolean difference to cut the hole (before filleting edges)\n const diffOptions = new DifferenceDto();\n diffOptions.shape = starSolid;\n diffOptions.shapes = [holeCylinder];\n diffOptions.keepEdges = false;\n const starWithHole = await booleans.difference(diffOptions);\n\n // Apply 3D fillet to smooth all edges (after boolean)\n const fillet3dOptions = new FilletDto();\n fillet3dOptions.shape = starWithHole;\n fillet3dOptions.radius = 0.15;\n const finalStar = await fillets.filletEdges(fillet3dOptions);\n\n // Draw with custom material and edge styling\n const drawOptions = new Bit.Inputs.Draw.DrawOcctShapeOptions();\n drawOptions.precision = 0.001;\n drawOptions.drawEdges = true;\n drawOptions.edgeColour = \"#000000\";\n drawOptions.edgeWidth = 1;\n drawOptions.faceMaterial = material;\n\n bitbybit.draw.drawAnyAsync({\n entity: finalStar,\n options: drawOptions\n });\n}\n\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"const { StarDto, FilletDto, FaceFromWireDto, ExtrudeDto, CylinderDto, DifferenceDto } = Bit.Inputs.OCCT;\nconst { PBRMetallicRoughnessDto } = Bit.Inputs.BabylonMaterial;\n\ntype TopoDSWirePointer = Bit.Inputs.OCCT.TopoDSWirePointer;\ntype TopoDSFacePointer = Bit.Inputs.OCCT.TopoDSFacePointer;\ntype TopoDSShapePointer = Bit.Inputs.OCCT.TopoDSShapePointer;\n\nconst { wire, face, solid } = bitbybit.occt.shapes;\nconst { fillets, operations, booleans } = bitbybit.occt;\n\nconst start = async () => {\n // Define outer radius as a variable (like the slider in Rete)\n const outerRadius = 5.1;\n const innerRadius = outerRadius / 3;\n\n // Create PBR material with emissive glow\n const materialOptions = new PBRMetallicRoughnessDto();\n materialOptions.name = \"Star Material\";\n materialOptions.baseColor = \"#ffffff\";\n materialOptions.emissiveColor = \"#00ffcc\";\n materialOptions.metallic = 0.8;\n materialOptions.roughness = 0.99;\n materialOptions.alpha = 1;\n materialOptions.backFaceCulling = false;\n materialOptions.zOffset = 2;\n const material = bitbybit.babylon.material.pbrMetallicRoughness.create(materialOptions);\n\n // Create the star wire with 5 points\n const starOptions = new StarDto();\n starOptions.numRays = 5;\n starOptions.outerRadius = outerRadius;\n starOptions.innerRadius = innerRadius;\n starOptions.center = [0, 0, 0];\n starOptions.direction = [0, 1, 0];\n starOptions.half = false;\n const starWire = await wire.createStarWire(starOptions);\n\n // Apply 2D fillet to round the star's corners\n const fillet2dOptions = new FilletDto();\n fillet2dOptions.shape = starWire;\n fillet2dOptions.radius = 0.3;\n const filletedWire = await fillets.fillet2d(fillet2dOptions);\n\n // Create a face from the filleted wire\n const faceOptions = new FaceFromWireDto();\n faceOptions.shape = filletedWire;\n faceOptions.planar = true;\n const starFace = await face.createFaceFromWire(faceOptions);\n\n // Extrude the face to create a 3D solid\n const extrudeOptions = new ExtrudeDto();\n extrudeOptions.shape = starFace;\n extrudeOptions.direction = [0, 1, 0];\n const starSolid = await operations.extrude(extrudeOptions);\n\n // Create cylinder for the hanging hole\n const cylinderOptions = new CylinderDto();\n cylinderOptions.center = [outerRadius / 2, 0, 0]; // Position based on outer radius\n cylinderOptions.direction = [0, 1, 0];\n cylinderOptions.radius = 0.2;\n cylinderOptions.height = 2;\n const holeCylinder = await solid.createCylinder(cylinderOptions);\n\n // Boolean difference to cut the hole (before filleting edges)\n const diffOptions = new DifferenceDto();\n diffOptions.shape = starSolid;\n diffOptions.shapes = [holeCylinder];\n diffOptions.keepEdges = false;\n const starWithHole = await booleans.difference(diffOptions);\n\n // Apply 3D fillet to smooth all edges (after boolean)\n const fillet3dOptions = new FilletDto();\n fillet3dOptions.shape = starWithHole;\n fillet3dOptions.radius = 0.15;\n const finalStar = await fillets.filletEdges(fillet3dOptions);\n\n // Draw with custom material and edge styling\n const drawOptions = new Bit.Inputs.Draw.DrawOcctShapeOptions();\n drawOptions.precision = 0.001;\n drawOptions.drawEdges = true;\n drawOptions.edgeColour = \"#000000\";\n drawOptions.edgeWidth = 1;\n drawOptions.faceMaterial = material;\n\n bitbybit.draw.drawAnyAsync({\n entity: finalStar,\n options: drawOptions\n });\n}\n\nstart();","version":"0.21.1","type":"typescript"}} title="Star ornament with hanging hole" /> @@ -117,21 +117,21 @@ Now that we have our star ornament ready, let's export it as an STL file for 3D outerRadiusfinalStarouterRadius5.1finalStar0000105outerRadiusDIVIDEouterRadius3FALSE0.3TRUE010DIVIDEouterRadius2000100.220.15finalStar0.001Star Material#ffffff#00ffcc0.80.991FALSE2TRUE#0000001finalStarstar.stl0.001FALSETRUE","version":"0.21.0","type":"blockly"}} + script={{"script":"outerRadiusfinalStarouterRadius5.1finalStar0000105outerRadiusDIVIDEouterRadius3FALSE0.3TRUE010DIVIDEouterRadius2000100.220.15finalStar0.001Star Material#ffffff#00ffcc0.80.991FALSE2TRUE#0000001finalStarstar.stl0.001FALSETRUE","version":"0.21.1","type":"blockly"}} title="Star ornament with STL export" /> {\n // Define outer radius as a variable (like the slider in Rete)\n const outerRadius = 5.1;\n const innerRadius = outerRadius / 3;\n\n // Create PBR material with emissive glow\n const materialOptions = new PBRMetallicRoughnessDto();\n materialOptions.name = \"Star Material\";\n materialOptions.baseColor = \"#ffffff\";\n materialOptions.emissiveColor = \"#00ffcc\";\n materialOptions.metallic = 0.8;\n materialOptions.roughness = 0.99;\n materialOptions.alpha = 1;\n materialOptions.backFaceCulling = false;\n materialOptions.zOffset = 2;\n const material = bitbybit.babylon.material.pbrMetallicRoughness.create(materialOptions);\n\n // Create the star wire with 5 points\n const starOptions = new StarDto();\n starOptions.numRays = 5;\n starOptions.outerRadius = outerRadius;\n starOptions.innerRadius = innerRadius;\n starOptions.center = [0, 0, 0];\n starOptions.direction = [0, 1, 0];\n starOptions.half = false;\n const starWire = await wire.createStarWire(starOptions);\n\n // Apply 2D fillet to round the star's corners\n const fillet2dOptions = new FilletDto();\n fillet2dOptions.shape = starWire;\n fillet2dOptions.radius = 0.3;\n const filletedWire = await fillets.fillet2d(fillet2dOptions);\n\n // Create a face from the filleted wire\n const faceOptions = new FaceFromWireDto();\n faceOptions.shape = filletedWire;\n faceOptions.planar = true;\n const starFace = await face.createFaceFromWire(faceOptions);\n\n // Extrude the face to create a 3D solid\n const extrudeOptions = new ExtrudeDto();\n extrudeOptions.shape = starFace;\n extrudeOptions.direction = [0, 1, 0];\n const starSolid = await operations.extrude(extrudeOptions);\n\n // Create cylinder for the hanging hole\n const cylinderOptions = new CylinderDto();\n cylinderOptions.center = [outerRadius / 2, 0, 0]; // Position based on outer radius\n cylinderOptions.direction = [0, 1, 0];\n cylinderOptions.radius = 0.2;\n cylinderOptions.height = 2;\n const holeCylinder = await solid.createCylinder(cylinderOptions);\n\n // Boolean difference to cut the hole (before filleting edges)\n const diffOptions = new DifferenceDto();\n diffOptions.shape = starSolid;\n diffOptions.shapes = [holeCylinder];\n diffOptions.keepEdges = false;\n const starWithHole = await booleans.difference(diffOptions);\n\n // Apply 3D fillet to smooth all edges (after boolean)\n const fillet3dOptions = new FilletDto();\n fillet3dOptions.shape = starWithHole;\n fillet3dOptions.radius = 0.15;\n const finalStar = await fillets.filletEdges(fillet3dOptions);\n\n // Draw with custom material and edge styling\n const drawOptions = new Bit.Inputs.Draw.DrawOcctShapeOptions();\n drawOptions.precision = 0.001;\n drawOptions.drawEdges = true;\n drawOptions.edgeColour = \"#000000\";\n drawOptions.edgeWidth = 1;\n drawOptions.faceMaterial = material;\n\n bitbybit.draw.drawAnyAsync({\n entity: finalStar,\n options: drawOptions\n });\n\n // Export to STL for 3D printing\n const stlOptions = new SaveStlDto();\n stlOptions.shape = finalStar;\n stlOptions.fileName = \"star.stl\";\n stlOptions.precision = 0.001;\n stlOptions.adjustYtoZ = false;\n stlOptions.tryDownload = true;\n stlOptions.binary = true;\n await io.saveShapeStl(stlOptions);\n}\n\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"const { StarDto, FilletDto, FaceFromWireDto, ExtrudeDto, CylinderDto, DifferenceDto } = Bit.Inputs.OCCT;\nconst { PBRMetallicRoughnessDto } = Bit.Inputs.BabylonMaterial;\nconst { SaveStlDto } = Bit.Inputs.OCCT;\n\ntype TopoDSWirePointer = Bit.Inputs.OCCT.TopoDSWirePointer;\ntype TopoDSFacePointer = Bit.Inputs.OCCT.TopoDSFacePointer;\ntype TopoDSShapePointer = Bit.Inputs.OCCT.TopoDSShapePointer;\n\nconst { wire, face, solid } = bitbybit.occt.shapes;\nconst { fillets, operations, booleans, io } = bitbybit.occt;\n\nconst start = async () => {\n // Define outer radius as a variable (like the slider in Rete)\n const outerRadius = 5.1;\n const innerRadius = outerRadius / 3;\n\n // Create PBR material with emissive glow\n const materialOptions = new PBRMetallicRoughnessDto();\n materialOptions.name = \"Star Material\";\n materialOptions.baseColor = \"#ffffff\";\n materialOptions.emissiveColor = \"#00ffcc\";\n materialOptions.metallic = 0.8;\n materialOptions.roughness = 0.99;\n materialOptions.alpha = 1;\n materialOptions.backFaceCulling = false;\n materialOptions.zOffset = 2;\n const material = bitbybit.babylon.material.pbrMetallicRoughness.create(materialOptions);\n\n // Create the star wire with 5 points\n const starOptions = new StarDto();\n starOptions.numRays = 5;\n starOptions.outerRadius = outerRadius;\n starOptions.innerRadius = innerRadius;\n starOptions.center = [0, 0, 0];\n starOptions.direction = [0, 1, 0];\n starOptions.half = false;\n const starWire = await wire.createStarWire(starOptions);\n\n // Apply 2D fillet to round the star's corners\n const fillet2dOptions = new FilletDto();\n fillet2dOptions.shape = starWire;\n fillet2dOptions.radius = 0.3;\n const filletedWire = await fillets.fillet2d(fillet2dOptions);\n\n // Create a face from the filleted wire\n const faceOptions = new FaceFromWireDto();\n faceOptions.shape = filletedWire;\n faceOptions.planar = true;\n const starFace = await face.createFaceFromWire(faceOptions);\n\n // Extrude the face to create a 3D solid\n const extrudeOptions = new ExtrudeDto();\n extrudeOptions.shape = starFace;\n extrudeOptions.direction = [0, 1, 0];\n const starSolid = await operations.extrude(extrudeOptions);\n\n // Create cylinder for the hanging hole\n const cylinderOptions = new CylinderDto();\n cylinderOptions.center = [outerRadius / 2, 0, 0]; // Position based on outer radius\n cylinderOptions.direction = [0, 1, 0];\n cylinderOptions.radius = 0.2;\n cylinderOptions.height = 2;\n const holeCylinder = await solid.createCylinder(cylinderOptions);\n\n // Boolean difference to cut the hole (before filleting edges)\n const diffOptions = new DifferenceDto();\n diffOptions.shape = starSolid;\n diffOptions.shapes = [holeCylinder];\n diffOptions.keepEdges = false;\n const starWithHole = await booleans.difference(diffOptions);\n\n // Apply 3D fillet to smooth all edges (after boolean)\n const fillet3dOptions = new FilletDto();\n fillet3dOptions.shape = starWithHole;\n fillet3dOptions.radius = 0.15;\n const finalStar = await fillets.filletEdges(fillet3dOptions);\n\n // Draw with custom material and edge styling\n const drawOptions = new Bit.Inputs.Draw.DrawOcctShapeOptions();\n drawOptions.precision = 0.001;\n drawOptions.drawEdges = true;\n drawOptions.edgeColour = \"#000000\";\n drawOptions.edgeWidth = 1;\n drawOptions.faceMaterial = material;\n\n bitbybit.draw.drawAnyAsync({\n entity: finalStar,\n options: drawOptions\n });\n\n // Export to STL for 3D printing\n const stlOptions = new SaveStlDto();\n stlOptions.shape = finalStar;\n stlOptions.fileName = \"star.stl\";\n stlOptions.precision = 0.001;\n stlOptions.adjustYtoZ = false;\n stlOptions.tryDownload = true;\n stlOptions.binary = true;\n await io.saveShapeStl(stlOptions);\n}\n\nstart();","version":"0.21.1","type":"typescript"}} title="Star ornament with STL export" /> diff --git a/docs/learn/code/common/occt/modeling/festive-decor/tree-decoration.md b/docs/learn/code/common/occt/modeling/festive-decor/tree-decoration.md index 63d178a0..a246213d 100644 --- a/docs/learn/code/common/occt/modeling/festive-decor/tree-decoration.md +++ b/docs/learn/code/common/occt/modeling/festive-decor/tree-decoration.md @@ -81,7 +81,7 @@ All controls use observable listeners to trigger geometry regeneration when valu {\\n // ADD YOUR CODE HERE\\n if (inputs === true) {\\n window.open(\\\"https://bitbybit.dev/app/bitbybit/KtIymkYFZ8Qty9h8mhew/Y7NQIgaXLy0dqffnc825?editor=rete\\\", '_blank').focus();\\n }\\n return inputs;\\n}\"}},\"inputs\":{\"inputs\":{\"connections\":[{\"node\":\"fbe1705ff510913a\",\"output\":\"isA\",\"data\":{}}]},\"exec\":{\"connections\":[{\"node\":\"fbe1705ff510913a\",\"output\":\"execA\",\"data\":{}},{\"node\":\"fbe1705ff510913a\",\"output\":\"execB\",\"data\":{}}]}},\"position\":[1749.7763306366996,10636.786904135595]},\"af7350efdb0b85b3\":{\"id\":\"af7350efdb0b85b3\",\"name\":\"bitbybit.babylon.gui.control.createControlObservableSelector\",\"customName\":\"control observable selector\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"selector\":\"onPointerUpObservable\"},\"inputs\":{},\"position\":[686.4715121547069,8508.681235887017]},\"f2e18ffd18566787\":{\"id\":\"f2e18ffd18566787\",\"name\":\"bitbybit.flow.babylon.observableListener\",\"customName\":\"babylon observable listener\",\"data\":{},\"inputs\":{\"object\":{\"connections\":[{\"node\":\"22b0aaced3db29ad\",\"output\":\"result\",\"data\":{}}]},\"observableSelector\":{\"connections\":[{\"node\":\"af7350efdb0b85b3\",\"output\":\"result\",\"data\":{}}]}},\"position\":[1453.070365919411,8258.538315404885]},\"70259fc69f3db105\":{\"id\":\"70259fc69f3db105\",\"name\":\"bitbybit.flow.time.delay\",\"customName\":\"delay\",\"data\":{\"timeout\":0},\"inputs\":{\"exec\":{\"connections\":[{\"node\":\"f2e18ffd18566787\",\"output\":\"exec\",\"data\":{}}]}},\"position\":[1987.6045976314351,8437.042718662588]},\"291c95f88aae5725\":{\"id\":\"291c95f88aae5725\",\"name\":\"bitbybit.flow.logic.flipFlop\",\"customName\":\"flip flop\",\"data\":{},\"inputs\":{\"exec\":{\"connections\":[{\"node\":\"70259fc69f3db105\",\"output\":\"exec\",\"data\":{}},{\"node\":\"f2e18ffd18566787\",\"output\":\"exec\",\"data\":{}}]}},\"position\":[2323.4070267726706,8288.053843144928]},\"ac5f02670de06852\":{\"id\":\"ac5f02670de06852\",\"name\":\"bitbybit.code.typeScriptEditor\",\"customName\":\"typescript editor\",\"async\":true,\"drawable\":true,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":true},\"code\":{\"code\":\"// DO NOT REMOVE THIS FUNCTION\\nconst startac5f02670de06852 = async (inputs: any, index: number) => {\\n // ADD YOUR CODE HERE\\n if (inputs === true) {\\n window.open(\\\"https://bitbybit.dev/auth/sign-up\\\", '_blank').focus();\\n }\\n return inputs;\\n}\"}},\"inputs\":{\"inputs\":{\"connections\":[{\"node\":\"291c95f88aae5725\",\"output\":\"isA\",\"data\":{}}]},\"exec\":{\"connections\":[{\"node\":\"291c95f88aae5725\",\"output\":\"execA\",\"data\":{}},{\"node\":\"291c95f88aae5725\",\"output\":\"execB\",\"data\":{}}]}},\"position\":[2681.990286952205,8287.587249893892]},\"b5af9279ffdd84e5\":{\"id\":\"b5af9279ffdd84e5\",\"name\":\"bitbybit.babylon.scene.enableSkybox\",\"customName\":\"enable skybox\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"skybox\":\"city\",\"size\":1000,\"blur\":0.5,\"environmentIntensity\":0.7,\"hideSkybox\":false},\"inputs\":{},\"position\":[2884.1306675480555,-186.0490873535386]},\"9dca219fedacecca\":{\"id\":\"9dca219fedacecca\",\"name\":\"bitbybit.flow.babylon.observableListener\",\"customName\":\"babylon observable listener\",\"data\":{},\"inputs\":{\"observableSelector\":{\"connections\":[{\"node\":\"f1f8cf3eadfa0ebb\",\"output\":\"result\",\"data\":{}}]},\"object\":{\"connections\":[{\"node\":\"71fbc1ccee37d577\",\"output\":\"result\",\"data\":{}}]}},\"position\":[385.9268891419183,10329.874563653837]},\"bb201b1ec9f17a1e\":{\"id\":\"bb201b1ec9f17a1e\",\"name\":\"bitbybit.flow.babylon.observableListener\",\"customName\":\"babylon observable listener\",\"data\":{},\"inputs\":{\"observableSelector\":{\"connections\":[{\"node\":\"f1f8cf3eadfa0ebb\",\"output\":\"result\",\"data\":{}}]},\"object\":{\"connections\":[{\"node\":\"fc36f702c3f8146e\",\"output\":\"result\",\"data\":{}}]}},\"position\":[394.16500271911553,10076.96114156523]},\"4a5d1c196a0b447e\":{\"id\":\"4a5d1c196a0b447e\",\"name\":\"bitbybit.flow.time.delay\",\"customName\":\"delay\",\"data\":{\"timeout\":0},\"inputs\":{\"exec\":{\"connections\":[{\"node\":\"9dca219fedacecca\",\"output\":\"exec\",\"data\":{}}]}},\"position\":[936.4095297912264,10457.862715124222]},\"4fd171db189ad173\":{\"id\":\"4fd171db189ad173\",\"name\":\"bitbybit.flow.logic.flipFlop\",\"customName\":\"flip flop\",\"data\":{},\"inputs\":{\"exec\":{\"connections\":[{\"node\":\"9dca219fedacecca\",\"output\":\"exec\",\"data\":{}},{\"node\":\"4a5d1c196a0b447e\",\"output\":\"exec\",\"data\":{}}]}},\"position\":[1273.654131279585,10355.281487174021]},\"94b6dd1354940df2\":{\"id\":\"94b6dd1354940df2\",\"name\":\"bitbybit.flow.time.delay\",\"customName\":\"delay\",\"data\":{\"timeout\":0},\"inputs\":{\"exec\":{\"connections\":[{\"node\":\"bb201b1ec9f17a1e\",\"output\":\"exec\",\"data\":{}}]}},\"position\":[926.4956949832613,10212.522265939324]},\"27eac850201a9701\":{\"id\":\"27eac850201a9701\",\"name\":\"bitbybit.flow.logic.flipFlop\",\"customName\":\"flip flop\",\"data\":{},\"inputs\":{\"exec\":{\"connections\":[{\"node\":\"bb201b1ec9f17a1e\",\"output\":\"exec\",\"data\":{}},{\"node\":\"94b6dd1354940df2\",\"output\":\"exec\",\"data\":{}}]}},\"position\":[1272.0778730255988,10103.055278248028]},\"9190095ec9cfd394\":{\"id\":\"9190095ec9cfd394\",\"name\":\"bitbybit.logic.valueGate\",\"customName\":\"value gate\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"boolean\":false},\"inputs\":{\"value\":{\"connections\":[{\"node\":\"73ee3cd6670755bb\",\"output\":\"result\",\"data\":{}}]},\"boolean\":{\"connections\":[{\"node\":\"27eac850201a9701\",\"output\":\"isA\",\"data\":{}}]},\"exec\":{\"connections\":[{\"node\":\"27eac850201a9701\",\"output\":\"execA\",\"data\":{}},{\"node\":\"27eac850201a9701\",\"output\":\"execB\",\"data\":{}}]}},\"position\":[2098.7596218076405,9630.876889007699]},\"73ee3cd6670755bb\":{\"id\":\"73ee3cd6670755bb\",\"name\":\"bitbybit.text.create\",\"customName\":\"create\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"text\":\"bitbybit-toy.step\"},\"inputs\":{},\"position\":[1701.8222304032442,9540.575618331815]},\"f9a87606405961ae\":{\"id\":\"f9a87606405961ae\",\"name\":\"bitbybit.text.create\",\"customName\":\"create\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"text\":\"bitbybit-toy.stl\"},\"inputs\":{},\"position\":[1934.0481177357838,10057.705993169464]},\"f8db44954a566616\":{\"id\":\"f8db44954a566616\",\"name\":\"bitbybit.logic.valueGate\",\"customName\":\"value gate\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"boolean\":false},\"inputs\":{\"value\":{\"connections\":[{\"node\":\"f9a87606405961ae\",\"output\":\"result\",\"data\":{}}]},\"boolean\":{\"connections\":[{\"node\":\"4fd171db189ad173\",\"output\":\"isA\",\"data\":{}}]},\"exec\":{\"connections\":[{\"node\":\"4fd171db189ad173\",\"output\":\"execA\",\"data\":{}},{\"node\":\"4fd171db189ad173\",\"output\":\"execB\",\"data\":{}}]}},\"position\":[2360.5651787274305,10179.991268481712]},\"7ae3f1f373ab7ce8\":{\"id\":\"7ae3f1f373ab7ce8\",\"name\":\"bitbybit.occt.io.saveShapeSTEPAndReturn\",\"customName\":\"save shape step and return\",\"async\":true,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"fileName\":\"\",\"adjustYtoZ\":true,\"fromRightHanded\":false,\"tryDownload\":true},\"inputs\":{\"shape\":{\"connections\":[{\"node\":\"ff3a5dfe26c1203f\",\"output\":\"result\",\"data\":{}}]},\"fileName\":{\"connections\":[{\"node\":\"9190095ec9cfd394\",\"output\":\"result\",\"data\":{}}]},\"exec\":{\"connections\":[{\"node\":\"9190095ec9cfd394\",\"output\":\"exec\",\"data\":{}}]}},\"position\":[4105.580503617983,9860.933809645778]},\"b358af77da1782cf\":{\"id\":\"b358af77da1782cf\",\"name\":\"bitbybit.occt.io.saveShapeStl\",\"customName\":\"save shape stl\",\"async\":true,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"fileName\":\"shape.stl\",\"precision\":0.01,\"adjustYtoZ\":true,\"tryDownload\":true,\"binary\":true},\"inputs\":{\"fileName\":{\"connections\":[{\"node\":\"f8db44954a566616\",\"output\":\"result\",\"data\":{}}]},\"exec\":{\"connections\":[{\"node\":\"f8db44954a566616\",\"output\":\"exec\",\"data\":{}}]},\"shape\":{\"connections\":[{\"node\":\"ff3a5dfe26c1203f\",\"output\":\"result\",\"data\":{}}]}},\"position\":[4097.343815578738,10313.986149668373]},\"feef4ec0e40282e7\":{\"id\":\"feef4ec0e40282e7\",\"name\":\"bitbybit.math.number\",\"customName\":\"number\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"number\":0.5},\"inputs\":{},\"position\":[2389.4392361815517,2241.565476619029]},\"03303a3d3cb2a6b5\":{\"id\":\"03303a3d3cb2a6b5\",\"name\":\"bitbybit.json.parse\",\"customName\":\"parse\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"text\":\"[true,false,true,true]\"},\"inputs\":{},\"position\":[2389.302212365796,2597.6283579746796]},\"f39c312f7e1e1bef\":{\"id\":\"f39c312f7e1e1bef\",\"name\":\"bitbybit.flow.babylon.observableListener\",\"customName\":\"babylon observable listener\",\"data\":{},\"inputs\":{\"observableSelector\":{\"connections\":[{\"node\":\"19dd5abb3a2ed30a\",\"output\":\"result\",\"data\":{}}]},\"object\":{\"connections\":[{\"node\":\"dda72ba4bc855075\",\"output\":\"result\",\"data\":{}}]}},\"position\":[634.3045048773648,6411.35023828563]},\"19dd5abb3a2ed30a\":{\"id\":\"19dd5abb3a2ed30a\",\"name\":\"bitbybit.babylon.gui.slider.createSliderObservableSelector\",\"customName\":\"slider observable selector\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"selector\":\"onValueChangedObservable\"},\"inputs\":{},\"position\":[119.33402358269528,6252.634270289916]},\"3f3e9efb919889cb\":{\"id\":\"3f3e9efb919889cb\",\"name\":\"bitbybit.flow.babylon.observableListener\",\"customName\":\"babylon observable listener\",\"data\":{},\"inputs\":{\"observableSelector\":{\"connections\":[{\"node\":\"19dd5abb3a2ed30a\",\"output\":\"result\",\"data\":{}}]},\"object\":{\"connections\":[{\"node\":\"eb164cb9f2c3d0b2\",\"output\":\"result\",\"data\":{}}]}},\"position\":[626.2393558517689,6035.026931379336]},\"b85e303f418ea094\":{\"id\":\"b85e303f418ea094\",\"name\":\"bitbybit.flow.babylon.getEventDataFromObservedResult\",\"customName\":\"get event data\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false}},\"inputs\":{\"json\":{\"connections\":[{\"node\":\"3f3e9efb919889cb\",\"output\":\"result\",\"data\":{}}]},\"exec\":{\"connections\":[{\"node\":\"3f3e9efb919889cb\",\"output\":\"exec\",\"data\":{}}]}},\"position\":[1213.8284182083087,6031.8004190176025]},\"0ae184887b347212\":{\"id\":\"0ae184887b347212\",\"name\":\"bitbybit.flow.babylon.getEventDataFromObservedResult\",\"customName\":\"get event data\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false}},\"inputs\":{\"exec\":{\"connections\":[{\"node\":\"f39c312f7e1e1bef\",\"output\":\"exec\",\"data\":{}}]},\"json\":{\"connections\":[{\"node\":\"f39c312f7e1e1bef\",\"output\":\"result\",\"data\":{}}]}},\"position\":[1212.113699374194,6401.279001431719]},\"ffecd6164df0c288\":{\"id\":\"ffecd6164df0c288\",\"name\":\"bitbybit.logic.firstDefinedValueGate\",\"customName\":\"first defined value gate\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false}},\"inputs\":{\"value1\":{\"connections\":[{\"node\":\"b85e303f418ea094\",\"output\":\"result\",\"data\":{}}]},\"value2\":{\"connections\":[{\"node\":\"6e51a85f13ab5259\",\"output\":\"result\",\"data\":{}}]},\"exec\":{\"connections\":[{\"node\":\"b85e303f418ea094\",\"output\":\"exec\",\"data\":{}}]}},\"position\":[1795.1547936226411,6012.662361553964]},\"d90e74b18631a7e7\":{\"id\":\"d90e74b18631a7e7\",\"name\":\"bitbybit.logic.firstDefinedValueGate\",\"customName\":\"first defined value gate\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false}},\"inputs\":{\"exec\":{\"connections\":[{\"node\":\"0ae184887b347212\",\"output\":\"exec\",\"data\":{}}]},\"value2\":{\"connections\":[{\"node\":\"dc27ec58598933e4\",\"output\":\"result\",\"data\":{}}]},\"value1\":{\"connections\":[{\"node\":\"0ae184887b347212\",\"output\":\"result\",\"data\":{}}]}},\"position\":[1827.0393870782336,6490.834733956343]},\"9ed742a672a607ce\":{\"id\":\"9ed742a672a607ce\",\"name\":\"bitbybit.lists.createList\",\"customName\":\"create list\",\"data\":{},\"inputs\":{\"listElements\":{\"connections\":[{\"node\":\"ffecd6164df0c288\",\"output\":\"result\",\"data\":{}}]},\"exec\":{\"connections\":[{\"node\":\"ffecd6164df0c288\",\"output\":\"exec\",\"data\":{}}]}},\"position\":[2408.212815313349,6050.3207511429555]},\"48046af83dbc9299\":{\"id\":\"48046af83dbc9299\",\"name\":\"bitbybit.lists.createList\",\"customName\":\"create list\",\"data\":{},\"inputs\":{\"listElements\":{\"connections\":[{\"node\":\"d90e74b18631a7e7\",\"output\":\"result\",\"data\":{}}]},\"exec\":{\"connections\":[{\"node\":\"d90e74b18631a7e7\",\"output\":\"exec\",\"data\":{}}]}},\"position\":[2407.3069815807094,6523.841211518347]},\"46f99a9e9cfc9152\":{\"id\":\"46f99a9e9cfc9152\",\"name\":\"bitbybit.text.format\",\"customName\":\"format\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"text\":\"Number Of Rays - {0}\",\"values\":[\"World\"]},\"inputs\":{\"values\":{\"connections\":[{\"node\":\"9ed742a672a607ce\",\"output\":\"list\",\"data\":{}}]},\"exec\":{\"connections\":[{\"node\":\"9ed742a672a607ce\",\"output\":\"exec\",\"data\":{}}]}},\"position\":[2774.3846965928947,5974.2361780617475]},\"ced830dd20fb5b02\":{\"id\":\"ced830dd20fb5b02\",\"name\":\"bitbybit.text.format\",\"customName\":\"format\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"text\":\"Vertical Divsions - {0}\",\"values\":[\"World\"]},\"inputs\":{\"exec\":{\"connections\":[{\"node\":\"48046af83dbc9299\",\"output\":\"exec\",\"data\":{}}]},\"values\":{\"connections\":[{\"node\":\"48046af83dbc9299\",\"output\":\"list\",\"data\":{}}]}},\"position\":[2794.9763891153702,6450.397669292677]},\"af2cb4893a5bc1cb\":{\"id\":\"af2cb4893a5bc1cb\",\"name\":\"bitbybit.babylon.gui.textBlock.setText\",\"customName\":\"set text\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"text\":\"\"},\"inputs\":{\"text\":{\"connections\":[{\"node\":\"46f99a9e9cfc9152\",\"output\":\"result\",\"data\":{}}]},\"exec\":{\"connections\":[{\"node\":\"46f99a9e9cfc9152\",\"output\":\"exec\",\"data\":{}}]},\"textBlock\":{\"connections\":[{\"node\":\"f80263a3d6977ea4\",\"output\":\"result\",\"data\":{}}]}},\"position\":[3408.9286383465733,6175.853417797766]},\"bb5fa4b16d910cb5\":{\"id\":\"bb5fa4b16d910cb5\",\"name\":\"bitbybit.babylon.gui.textBlock.setText\",\"customName\":\"set text\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"text\":\"\"},\"inputs\":{\"textBlock\":{\"connections\":[{\"node\":\"a3006cf7f5041ef6\",\"output\":\"result\",\"data\":{}}]},\"text\":{\"connections\":[{\"node\":\"ced830dd20fb5b02\",\"output\":\"result\",\"data\":{}}]},\"exec\":{\"connections\":[{\"node\":\"ced830dd20fb5b02\",\"output\":\"exec\",\"data\":{}}]}},\"position\":[3443.5303027369487,6538.552534619226]},\"8ecfa2d91d973882\":{\"id\":\"8ecfa2d91d973882\",\"name\":\"bitbybit.babylon.gui.control.createControlObservableSelector\",\"customName\":\"control observable selector\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"selector\":\"onPointerUpObservable\"},\"inputs\":{},\"position\":[112.53197228874697,7216.911800887681]},\"8478c18af95701d2\":{\"id\":\"8478c18af95701d2\",\"name\":\"bitbybit.flow.babylon.observableListener\",\"customName\":\"babylon observable listener\",\"data\":{},\"inputs\":{\"observableSelector\":{\"connections\":[{\"node\":\"8ecfa2d91d973882\",\"output\":\"result\",\"data\":{}}]},\"object\":{\"connections\":[{\"node\":\"dda72ba4bc855075\",\"output\":\"result\",\"data\":{}}]}},\"position\":[666.0061734678349,7042.204203322666]},\"fa5a486b0621317a\":{\"id\":\"fa5a486b0621317a\",\"name\":\"bitbybit.flow.babylon.observableListener\",\"customName\":\"babylon observable listener\",\"data\":{},\"inputs\":{\"observableSelector\":{\"connections\":[{\"node\":\"8ecfa2d91d973882\",\"output\":\"result\",\"data\":{}}]},\"object\":{\"connections\":[{\"node\":\"eb164cb9f2c3d0b2\",\"output\":\"result\",\"data\":{}}]}},\"position\":[667.4427756519425,6826.609623951564]},\"7299a501c8e860c5\":{\"id\":\"7299a501c8e860c5\",\"name\":\"bitbybit.lists.passThrough\",\"customName\":\"pass through\",\"data\":{},\"inputs\":{\"exec\":{\"connections\":[{\"node\":\"fa5a486b0621317a\",\"output\":\"exec\",\"data\":{}},{\"node\":\"8478c18af95701d2\",\"output\":\"exec\",\"data\":{}}]}},\"position\":[6778.4019145441225,6945.999036012015]},\"68fc3da5a920f715\":{\"id\":\"68fc3da5a920f715\",\"name\":\"bitbybit.babylon.scene.adjustActiveArcRotateCamera\",\"customName\":\"adjust active arc rotate camera\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"position\":[10,10,10],\"lookAt\":[0,0,0],\"lowerBetaLimit\":1,\"upperBetaLimit\":179,\"angularSensibilityX\":1000,\"angularSensibilityY\":1000,\"maxZ\":1000,\"panningSensibility\":1000,\"wheelPrecision\":3},\"inputs\":{\"position\":{\"connections\":[{\"node\":\"2c23a73974610198\",\"output\":\"result\",\"data\":{}}]},\"lookAt\":{\"connections\":[{\"node\":\"4b908f56b3ed505c\",\"output\":\"result\",\"data\":{}}]}},\"position\":[2457.6836534900826,-2687.8751308577216]},\"2c23a73974610198\":{\"id\":\"2c23a73974610198\",\"name\":\"bitbybit.vector.vectorXYZ\",\"customName\":\"vector xyz\",\"async\":false,\"drawable\":true,\"data\":{\"genericNodeData\":{\"hide\":true,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"x\":30,\"y\":25,\"z\":0},\"inputs\":{},\"position\":[2028.1960653764377,-2763.197379436671]},\"4b908f56b3ed505c\":{\"id\":\"4b908f56b3ed505c\",\"name\":\"bitbybit.vector.vectorXYZ\",\"customName\":\"vector xyz\",\"async\":false,\"drawable\":true,\"data\":{\"genericNodeData\":{\"hide\":true,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"x\":0,\"y\":4,\"z\":0},\"inputs\":{},\"position\":[2033.62438677469,-2317.355175655833]}}}","version":"0.21.0","type":"rete"}} + script={{"script":"{\"id\":\"rete-v2-json\",\"nodes\":{\"4534540d6856552d\":{\"id\":\"4534540d6856552d\",\"name\":\"bitbybit.occt.shapes.wire.createStarWire\",\"customName\":\"star wire\",\"async\":true,\"drawable\":true,\"data\":{\"genericNodeData\":{\"hide\":true,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"center\":[0,0,0],\"direction\":[0,1,0],\"numRays\":12,\"outerRadius\":20,\"innerRadius\":12,\"offsetOuterEdges\":0,\"half\":false},\"inputs\":{\"numRays\":{\"connections\":[{\"node\":\"ffecd6164df0c288\",\"output\":\"result\",\"data\":{}}]}},\"position\":[29.498322548778063,508.0780203076317]},\"b983a207fda22099\":{\"id\":\"b983a207fda22099\",\"name\":\"bitbybit.occt.transforms.translate\",\"customName\":\"translate\",\"async\":true,\"drawable\":true,\"data\":{\"genericNodeData\":{\"hide\":true,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"translation\":[0,0,0]},\"inputs\":{\"translation\":{\"connections\":[{\"node\":\"76bf07ac6376dd9d\",\"output\":\"result\",\"data\":{}}]},\"shape\":{\"connections\":[{\"node\":\"892079e9447f3eae\",\"output\":\"result\",\"data\":{}}]}},\"position\":[1421.0202335352003,1035.739426279123]},\"76bf07ac6376dd9d\":{\"id\":\"76bf07ac6376dd9d\",\"name\":\"bitbybit.vector.vectorXYZ\",\"customName\":\"vector xyz\",\"async\":false,\"drawable\":true,\"data\":{\"genericNodeData\":{\"hide\":true,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"x\":0,\"y\":20,\"z\":0},\"inputs\":{},\"position\":[4.113044262054515,1088.1382664289113]},\"892079e9447f3eae\":{\"id\":\"892079e9447f3eae\",\"name\":\"bitbybit.occt.transforms.scale\",\"customName\":\"scale\",\"async\":true,\"drawable\":true,\"data\":{\"genericNodeData\":{\"hide\":true,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"factor\":0.15},\"inputs\":{\"shape\":{\"connections\":[{\"node\":\"4534540d6856552d\",\"output\":\"result\",\"data\":{}}]}},\"position\":[1039.174244697755,869.9580356533191]},\"11549f1b45ea9b19\":{\"id\":\"11549f1b45ea9b19\",\"name\":\"bitbybit.occt.transforms.translate\",\"customName\":\"translate\",\"async\":true,\"drawable\":true,\"data\":{\"genericNodeData\":{\"hide\":true,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"translation\":[0,0,0]},\"inputs\":{\"translation\":{\"connections\":[{\"node\":\"ed8b1944898e2ce1\",\"output\":\"result\",\"data\":{}}]},\"shape\":{\"connections\":[{\"node\":\"cb6929579b17268b\",\"output\":\"result\",\"data\":{}}]}},\"position\":[843.9071289289463,1724.0141995434674]},\"ed8b1944898e2ce1\":{\"id\":\"ed8b1944898e2ce1\",\"name\":\"bitbybit.vector.vectorXYZ\",\"customName\":\"vector xyz\",\"async\":false,\"drawable\":true,\"data\":{\"genericNodeData\":{\"hide\":true,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"x\":0,\"y\":-5,\"z\":0},\"inputs\":{},\"position\":[407.2814628248683,1768.0222128529601]},\"c7bdc15abbc2ba7d\":{\"id\":\"c7bdc15abbc2ba7d\",\"name\":\"bitbybit.occt.operations.loft\",\"customName\":\"loft\",\"async\":true,\"drawable\":true,\"data\":{\"genericNodeData\":{\"hide\":true,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"makeSolid\":false},\"inputs\":{\"shapes\":{\"connections\":[{\"node\":\"875673f0ab1bb510\",\"output\":\"list\",\"data\":{}}]}},\"position\":[2071.471395598051,848.4908460058068]},\"875673f0ab1bb510\":{\"id\":\"875673f0ab1bb510\",\"name\":\"bitbybit.lists.createList\",\"customName\":\"create list\",\"data\":{},\"inputs\":{\"listElements\":{\"connections\":[{\"node\":\"47f69e3aabe06071\",\"output\":\"result\",\"data\":{}},{\"node\":\"b983a207fda22099\",\"output\":\"result\",\"data\":{}},{\"node\":\"4534540d6856552d\",\"output\":\"result\",\"data\":{}}]}},\"position\":[1782.785359527408,889.106870548469]},\"47f69e3aabe06071\":{\"id\":\"47f69e3aabe06071\",\"name\":\"bitbybit.occt.transforms.translate\",\"customName\":\"translate\",\"async\":true,\"drawable\":true,\"data\":{\"genericNodeData\":{\"hide\":true,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"translation\":[0,0,0]},\"inputs\":{\"translation\":{\"connections\":[{\"node\":\"a15b2d55874ba400\",\"output\":\"result\",\"data\":{}}]},\"shape\":{\"connections\":[{\"node\":\"f360184ff5aba2df\",\"output\":\"result\",\"data\":{}}]}},\"position\":[1245.2288399130869,247.04605010960086]},\"f360184ff5aba2df\":{\"id\":\"f360184ff5aba2df\",\"name\":\"bitbybit.occt.transforms.scale\",\"customName\":\"scale\",\"async\":true,\"drawable\":true,\"data\":{\"genericNodeData\":{\"hide\":true,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"factor\":0.25},\"inputs\":{\"shape\":{\"connections\":[{\"node\":\"4534540d6856552d\",\"output\":\"result\",\"data\":{}}]}},\"position\":[793.2018829015179,318.06376415603927]},\"a15b2d55874ba400\":{\"id\":\"a15b2d55874ba400\",\"name\":\"bitbybit.vector.vectorXYZ\",\"customName\":\"vector xyz\",\"async\":false,\"drawable\":true,\"data\":{\"genericNodeData\":{\"hide\":true,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"x\":0,\"y\":30,\"z\":0},\"inputs\":{},\"position\":[794.3690505014016,-54.119980109301466]},\"16e58d428c0abb1e\":{\"id\":\"16e58d428c0abb1e\",\"name\":\"bitbybit.babylon.scene.drawDirectionalLight\",\"customName\":\"draw directional light\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"direction\":[-100,-100,-100],\"intensity\":3,\"diffuse\":\"#ffffff\",\"specular\":\"#ffffff\",\"shadowGeneratorMapSize\":1024,\"enableShadows\":true,\"shadowDarkness\":0,\"shadowUsePercentageCloserFiltering\":true,\"shadowContactHardeningLightSizeUVRatio\":0.2,\"shadowBias\":0.0001,\"shadowNormalBias\":0.002,\"shadowMaxZ\":1000,\"shadowMinZ\":0},\"inputs\":{\"direction\":{\"connections\":[{\"node\":\"fa96ae89f95b4b18\",\"output\":\"result\",\"data\":{}}]}},\"position\":[2410.2001319497786,-1854.3247886875574]},\"cb6929579b17268b\":{\"id\":\"cb6929579b17268b\",\"name\":\"bitbybit.occt.transforms.scale\",\"customName\":\"scale\",\"async\":true,\"drawable\":true,\"data\":{\"genericNodeData\":{\"hide\":true,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"factor\":0.3},\"inputs\":{\"shape\":{\"connections\":[{\"node\":\"4534540d6856552d\",\"output\":\"result\",\"data\":{}}]}},\"position\":[457.0402990348086,1405.480031322518]},\"e9b4d2a7926e953f\":{\"id\":\"e9b4d2a7926e953f\",\"name\":\"bitbybit.occt.operations.loftAdvanced\",\"customName\":\"loft advanced\",\"async\":true,\"drawable\":true,\"data\":{\"genericNodeData\":{\"hide\":true,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"makeSolid\":false,\"closed\":false,\"periodic\":false,\"straight\":false,\"nrPeriodicSections\":10,\"useSmoothing\":false,\"maxUDegree\":3,\"tolerance\":1e-7,\"parType\":\"approxCentripetal\"},\"inputs\":{\"shapes\":{\"connections\":[{\"node\":\"570ca0cbda09cb78\",\"output\":\"list\",\"data\":{}}]},\"startVertex\":{\"connections\":[{\"node\":\"294942bd7a13ef3b\",\"output\":\"result\",\"data\":{}}]}},\"position\":[1793.6009797350105,1402.1120964226682]},\"570ca0cbda09cb78\":{\"id\":\"570ca0cbda09cb78\",\"name\":\"bitbybit.lists.createList\",\"customName\":\"create list\",\"data\":{},\"inputs\":{\"listElements\":{\"connections\":[{\"node\":\"11549f1b45ea9b19\",\"output\":\"result\",\"data\":{}},{\"node\":\"4534540d6856552d\",\"output\":\"result\",\"data\":{}}]}},\"position\":[1321.0103546184212,1396.929370018355]},\"294942bd7a13ef3b\":{\"id\":\"294942bd7a13ef3b\",\"name\":\"bitbybit.vector.vectorXYZ\",\"customName\":\"vector xyz\",\"async\":false,\"drawable\":true,\"data\":{\"genericNodeData\":{\"hide\":true,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"x\":0,\"y\":-10,\"z\":0},\"inputs\":{},\"position\":[1348.5723772315805,1760.5007306049315]},\"14ff0cda52cd7ce0\":{\"id\":\"14ff0cda52cd7ce0\",\"name\":\"bitbybit.occt.shapes.face.createFaceFromWire\",\"customName\":\"face from wire\",\"async\":true,\"drawable\":true,\"data\":{\"genericNodeData\":{\"hide\":true,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"planar\":true},\"inputs\":{\"shape\":{\"connections\":[{\"node\":\"47f69e3aabe06071\",\"output\":\"result\",\"data\":{}}]}},\"position\":[1836.8581524949377,110.6324723551911]},\"a153773318fd229a\":{\"id\":\"a153773318fd229a\",\"name\":\"bitbybit.lists.createList\",\"customName\":\"create list\",\"data\":{},\"inputs\":{\"listElements\":{\"connections\":[{\"node\":\"fda5ede008aae952\",\"output\":\"result\",\"data\":{}},{\"node\":\"e5331e883d23938e\",\"output\":\"result\",\"data\":{}},{\"node\":\"3bc9cf346fc8ef2a\",\"output\":\"result\",\"data\":{}},{\"node\":\"5a762f02bed474cd\",\"output\":\"result\",\"data\":{}},{\"node\":\"e9b4d2a7926e953f\",\"output\":\"result\",\"data\":{}},{\"node\":\"ed8dca56f5a8e402\",\"output\":\"result\",\"data\":{}},{\"node\":\"14ff0cda52cd7ce0\",\"output\":\"result\",\"data\":{}}]}},\"position\":[7499.583074067741,153.2312211535806]},\"ec6a4cb0d7105988\":{\"id\":\"ec6a4cb0d7105988\",\"name\":\"bitbybit.occt.shapes.shell.sewFaces\",\"customName\":\"sew faces\",\"async\":true,\"drawable\":true,\"data\":{\"genericNodeData\":{\"hide\":true,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"tolerance\":1e-7},\"inputs\":{\"shapes\":{\"connections\":[{\"node\":\"a153773318fd229a\",\"output\":\"list\",\"data\":{}}]}},\"position\":[7778.252945194093,116.96317643777269]},\"d533f9b2b358e932\":{\"id\":\"d533f9b2b358e932\",\"name\":\"bitbybit.occt.shapes.solid.fromClosedShell\",\"customName\":\"from closed shell\",\"async\":true,\"drawable\":true,\"data\":{\"genericNodeData\":{\"hide\":true,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false}},\"inputs\":{\"shape\":{\"connections\":[{\"node\":\"ec6a4cb0d7105988\",\"output\":\"result\",\"data\":{}}]}},\"position\":[8740.894126518644,641.4684856178552]},\"65118a904f1bcadd\":{\"id\":\"65118a904f1bcadd\",\"name\":\"bitbybit.draw.drawAnyAsync\",\"customName\":\"draw any async\",\"async\":true,\"drawable\":true,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false}},\"inputs\":{\"options\":{\"connections\":[{\"node\":\"9d5759bf6abda9ea\",\"output\":\"result\",\"data\":{}}]},\"entity\":{\"connections\":[{\"node\":\"ff3a5dfe26c1203f\",\"output\":\"result\",\"data\":{}}]},\"exec\":{\"connections\":[{\"node\":\"7299a501c8e860c5\",\"output\":\"exec\",\"data\":{}}]}},\"position\":[10417.684603457687,1646.8416215802954]},\"9d5759bf6abda9ea\":{\"id\":\"9d5759bf6abda9ea\",\"name\":\"bitbybit.draw.optionsOcctShape\",\"customName\":\"options occt shape\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"faceOpacity\":1,\"edgeOpacity\":1,\"edgeColour\":\"#005e99\",\"faceColour\":\"#ffffff\",\"vertexColour\":\"#ff00ff\",\"edgeWidth\":1,\"vertexSize\":0.03,\"drawEdges\":true,\"drawFaces\":true,\"drawVertices\":false,\"precision\":0.005,\"drawEdgeIndexes\":false,\"edgeIndexHeight\":0.06,\"edgeIndexColour\":\"#ff00ff\",\"drawFaceIndexes\":false,\"faceIndexHeight\":0.06,\"faceIndexColour\":\"#0000ff\"},\"inputs\":{\"faceMaterial\":{\"connections\":[{\"node\":\"9cd68061ec4fd9e0\",\"output\":\"result\",\"data\":{}}]}},\"position\":[9991.876413478969,2364.565814067178]},\"825b687b6334e027\":{\"id\":\"825b687b6334e027\",\"name\":\"bitbybit.occt.shapes.face.getFaces\",\"customName\":\"get faces\",\"async\":true,\"drawable\":true,\"data\":{\"genericNodeData\":{\"hide\":true,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false}},\"inputs\":{\"shape\":{\"connections\":[{\"node\":\"c7bdc15abbc2ba7d\",\"output\":\"result\",\"data\":{}}]}},\"position\":[2383.6709076575817,1519.6762847896136]},\"74d09b8bdb4c5048\":{\"id\":\"74d09b8bdb4c5048\",\"name\":\"bitbybit.occt.shapes.face.subdivideToRectangleHoles\",\"customName\":\"subdivide to rectangle holes\",\"async\":true,\"drawable\":true,\"data\":{\"genericNodeData\":{\"hide\":true,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"nrRectanglesU\":1,\"nrRectanglesV\":1,\"holesToFaces\":true,\"offsetFromBorderU\":0,\"offsetFromBorderV\":0.02},\"inputs\":{\"shape\":{\"connections\":[{\"node\":\"db2f29c28fce9a44\",\"output\":\"result\",\"data\":{}}]},\"scalePatternV\":{\"connections\":[{\"node\":\"6f4928a56906774a\",\"output\":\"list\",\"data\":{}}]},\"inclusionPattern\":{\"connections\":[{\"node\":\"03303a3d3cb2a6b5\",\"output\":\"result\",\"data\":{}}]},\"nrRectanglesV\":{\"connections\":[{\"node\":\"d90e74b18631a7e7\",\"output\":\"result\",\"data\":{}}]}},\"position\":[3092.608348037154,1633.6879372044598]},\"db2f29c28fce9a44\":{\"id\":\"db2f29c28fce9a44\",\"name\":\"bitbybit.lists.flatten\",\"customName\":\"flatten\",\"data\":{\"nrLevels\":1},\"inputs\":{\"list\":{\"connections\":[{\"node\":\"825b687b6334e027\",\"output\":\"result\",\"data\":{}}]}},\"position\":[2676.745386245579,1557.1555615832751]},\"ed8dca56f5a8e402\":{\"id\":\"ed8dca56f5a8e402\",\"name\":\"bitbybit.occt.shapes.shell.sewFaces\",\"customName\":\"sew faces\",\"async\":true,\"drawable\":true,\"data\":{\"genericNodeData\":{\"hide\":true,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"tolerance\":1e-7},\"inputs\":{\"shapes\":{\"connections\":[{\"node\":\"f3620701c3c1ae55\",\"output\":\"list\",\"data\":{}}]}},\"position\":[4717.860180433169,974.4537366731146]},\"f3620701c3c1ae55\":{\"id\":\"f3620701c3c1ae55\",\"name\":\"bitbybit.lists.createList\",\"customName\":\"create list\",\"data\":{},\"inputs\":{\"listElements\":{\"connections\":[{\"node\":\"7ea739c655493f9b\",\"output\":\"result\",\"data\":{}}]}},\"position\":[4391.51664332526,1126.3749180224165]},\"5a31954b0015e697\":{\"id\":\"5a31954b0015e697\",\"name\":\"bitbybit.lists.getItem\",\"customName\":\"get item\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"index\":0,\"clone\":true},\"inputs\":{\"list\":{\"connections\":[{\"node\":\"74d09b8bdb4c5048\",\"output\":\"result\",\"data\":{}}]}},\"position\":[3583.928722911858,1609.7248549515402]},\"198a03b80b487592\":{\"id\":\"198a03b80b487592\",\"name\":\"bitbybit.math.number\",\"customName\":\"number\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"number\":0.75},\"inputs\":{},\"position\":[2390.350829226262,1944.6338134400619]},\"6f4928a56906774a\":{\"id\":\"6f4928a56906774a\",\"name\":\"bitbybit.lists.createList\",\"customName\":\"create list\",\"data\":{},\"inputs\":{\"listElements\":{\"connections\":[{\"node\":\"198a03b80b487592\",\"output\":\"result\",\"data\":{}},{\"node\":\"feef4ec0e40282e7\",\"output\":\"result\",\"data\":{}}]}},\"position\":[2699.5900851326587,1981.4990347629055]},\"b14378ceb8bf7fc5\":{\"id\":\"b14378ceb8bf7fc5\",\"name\":\"bitbybit.occt.transforms.scale3d\",\"customName\":\"scale 3d\",\"async\":true,\"drawable\":true,\"data\":{\"genericNodeData\":{\"hide\":true,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"scale\":[1,1,1],\"center\":[0,0,0]},\"inputs\":{\"center\":{\"connections\":[{\"node\":\"719d567df8fbd349\",\"output\":\"result\",\"data\":{}}]},\"scale\":{\"connections\":[{\"node\":\"efb0980b63aa8487\",\"output\":\"result\",\"data\":{}}]},\"shape\":{\"connections\":[{\"node\":\"a385c2492e4ef6f1\",\"output\":\"result\",\"data\":{}}]}},\"position\":[4341.167538667826,2759.8646823683453]},\"719d567df8fbd349\":{\"id\":\"719d567df8fbd349\",\"name\":\"bitbybit.vector.vectorXYZ\",\"customName\":\"vector xyz\",\"async\":false,\"drawable\":true,\"data\":{\"genericNodeData\":{\"hide\":true,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"x\":0,\"y\":0,\"z\":0},\"inputs\":{},\"position\":[3112.9806205260847,3674.4933141041506]},\"efb0980b63aa8487\":{\"id\":\"efb0980b63aa8487\",\"name\":\"bitbybit.vector.vectorXYZ\",\"customName\":\"vector xyz\",\"async\":false,\"drawable\":true,\"data\":{\"genericNodeData\":{\"hide\":true,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"x\":2,\"y\":1,\"z\":2},\"inputs\":{\"x\":{\"connections\":[{\"node\":\"80d8c2210e2c8ada\",\"output\":\"result\",\"data\":{}}]},\"z\":{\"connections\":[{\"node\":\"80d8c2210e2c8ada\",\"output\":\"result\",\"data\":{}}]}},\"position\":[3116.886056928245,2953.518975707273]},\"e5331e883d23938e\":{\"id\":\"e5331e883d23938e\",\"name\":\"bitbybit.occt.transforms.scale3d\",\"customName\":\"scale 3d\",\"async\":true,\"drawable\":true,\"data\":{\"genericNodeData\":{\"hide\":true,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"scale\":[1,1,1],\"center\":[0,0,0]},\"inputs\":{\"scale\":{\"connections\":[{\"node\":\"efb0980b63aa8487\",\"output\":\"result\",\"data\":{}}]},\"center\":{\"connections\":[{\"node\":\"719d567df8fbd349\",\"output\":\"result\",\"data\":{}}]},\"shape\":{\"connections\":[{\"node\":\"5a31954b0015e697\",\"output\":\"result\",\"data\":{}}]}},\"position\":[4356.028359232859,1903.9072650668625]},\"0a8bd4a673a282d0\":{\"id\":\"0a8bd4a673a282d0\",\"name\":\"bitbybit.lists.createList\",\"customName\":\"create list\",\"data\":{},\"inputs\":{\"listElements\":{\"connections\":[{\"node\":\"b6dab3ff34eb97a4\",\"output\":\"list\",\"data\":{}},{\"node\":\"a2a0a302a67ae9ff\",\"output\":\"list\",\"data\":{}}]}},\"position\":[5446.717449196535,2603.210206102196]},\"b6dab3ff34eb97a4\":{\"id\":\"b6dab3ff34eb97a4\",\"name\":\"bitbybit.lists.createList\",\"customName\":\"create list\",\"data\":{},\"inputs\":{\"listElements\":{\"connections\":[{\"node\":\"dd44e69c6aba7a0d\",\"output\":\"result\",\"data\":{}}]}},\"position\":[5014.862418857628,2443.6518849559025]},\"a2a0a302a67ae9ff\":{\"id\":\"a2a0a302a67ae9ff\",\"name\":\"bitbybit.lists.createList\",\"customName\":\"create list\",\"data\":{},\"inputs\":{\"listElements\":{\"connections\":[{\"node\":\"f9fb91cec187f7f0\",\"output\":\"result\",\"data\":{}}]}},\"position\":[5008.316988126108,2795.910343024419]},\"82d90ff3973291d4\":{\"id\":\"82d90ff3973291d4\",\"name\":\"bitbybit.lists.flipLists\",\"customName\":\"flip lists\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"clone\":true},\"inputs\":{\"list\":{\"connections\":[{\"node\":\"0a8bd4a673a282d0\",\"output\":\"list\",\"data\":{}}]}},\"position\":[5738.875610128508,2566.2260951248236]},\"9df5fcaa8f7c02cc\":{\"id\":\"9df5fcaa8f7c02cc\",\"name\":\"bitbybit.lists.flatten\",\"customName\":\"flatten\",\"data\":{\"nrLevels\":1},\"inputs\":{\"list\":{\"connections\":[{\"node\":\"82d90ff3973291d4\",\"output\":\"result\",\"data\":{}}]}},\"position\":[6058.59415221766,2603.0978039381016]},\"5a762f02bed474cd\":{\"id\":\"5a762f02bed474cd\",\"name\":\"bitbybit.occt.operations.loft\",\"customName\":\"loft\",\"async\":true,\"drawable\":true,\"data\":{\"genericNodeData\":{\"hide\":true,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"makeSolid\":false},\"inputs\":{\"shapes\":{\"connections\":[{\"node\":\"9df5fcaa8f7c02cc\",\"output\":\"result\",\"data\":{}}]}},\"position\":[6404.947065733184,2560.232098026223]},\"80d8c2210e2c8ada\":{\"id\":\"80d8c2210e2c8ada\",\"name\":\"bitbybit.math.number\",\"customName\":\"number\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"number\":1.2},\"inputs\":{},\"position\":[2535.8992541451094,3162.3018861132055]},\"fa96ae89f95b4b18\":{\"id\":\"fa96ae89f95b4b18\",\"name\":\"bitbybit.vector.vectorXYZ\",\"customName\":\"vector xyz\",\"async\":false,\"drawable\":true,\"data\":{\"genericNodeData\":{\"hide\":true,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"x\":-100,\"y\":-100,\"z\":-100},\"inputs\":{},\"position\":[1862.3555027829957,-1849.8844786271547]},\"9cd68061ec4fd9e0\":{\"id\":\"9cd68061ec4fd9e0\",\"name\":\"bitbybit.babylon.material.pbrMetallicRoughness.create\",\"customName\":\"pbr metallic roughness\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"name\":\"Custom Material\",\"baseColor\":\"#94c2ff\",\"emissiveColor\":\"#3b77b0\",\"metallic\":0.8,\"roughness\":0.29,\"alpha\":1,\"backFaceCulling\":false,\"zOffset\":2},\"inputs\":{},\"position\":[9605.741806654112,2831.949431044085]},\"3901011d12c76eef\":{\"id\":\"3901011d12c76eef\",\"name\":\"bitbybit.occt.transforms.scale3d\",\"customName\":\"scale 3d\",\"async\":true,\"drawable\":true,\"data\":{\"genericNodeData\":{\"hide\":true,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"scale\":[1,1,1],\"center\":[0,0,0]},\"inputs\":{\"shape\":{\"connections\":[{\"node\":\"47f69e3aabe06071\",\"output\":\"result\",\"data\":{}}]},\"scale\":{\"connections\":[{\"node\":\"efb0980b63aa8487\",\"output\":\"result\",\"data\":{}}]},\"center\":{\"connections\":[{\"node\":\"719d567df8fbd349\",\"output\":\"result\",\"data\":{}}]}},\"position\":[4364.581071106104,1476.346832014063]},\"3bc9cf346fc8ef2a\":{\"id\":\"3bc9cf346fc8ef2a\",\"name\":\"bitbybit.occt.transforms.scale3d\",\"customName\":\"scale 3d\",\"async\":true,\"drawable\":true,\"data\":{\"genericNodeData\":{\"hide\":true,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"scale\":[1,1,1],\"center\":[0,0,0]},\"inputs\":{\"shape\":{\"connections\":[{\"node\":\"e9b4d2a7926e953f\",\"output\":\"result\",\"data\":{}}]},\"center\":{\"connections\":[{\"node\":\"719d567df8fbd349\",\"output\":\"result\",\"data\":{}}]},\"scale\":{\"connections\":[{\"node\":\"43f2efdf3003002e\",\"output\":\"result\",\"data\":{}}]}},\"position\":[4345.11797828289,3210.3573065763057]},\"b313faa82fc7f582\":{\"id\":\"b313faa82fc7f582\",\"name\":\"bitbybit.lists.createList\",\"customName\":\"create list\",\"data\":{},\"inputs\":{\"listElements\":{\"connections\":[{\"node\":\"3901011d12c76eef\",\"output\":\"result\",\"data\":{}}]}},\"position\":[4860.068544678273,1517.2274588686575]},\"fda5ede008aae952\":{\"id\":\"fda5ede008aae952\",\"name\":\"bitbybit.occt.operations.loftAdvanced\",\"customName\":\"loft advanced\",\"async\":true,\"drawable\":true,\"data\":{\"genericNodeData\":{\"hide\":true,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"makeSolid\":false,\"closed\":false,\"periodic\":false,\"straight\":false,\"nrPeriodicSections\":10,\"useSmoothing\":false,\"maxUDegree\":3,\"tolerance\":1e-7,\"parType\":\"approxCentripetal\"},\"inputs\":{\"shapes\":{\"connections\":[{\"node\":\"b313faa82fc7f582\",\"output\":\"list\",\"data\":{}}]},\"startVertex\":{\"connections\":[{\"node\":\"cbacaf56751f477c\",\"output\":\"result\",\"data\":{}}]}},\"position\":[5327.662487993239,1465.5007248302118]},\"cbacaf56751f477c\":{\"id\":\"cbacaf56751f477c\",\"name\":\"bitbybit.vector.vectorXYZ\",\"customName\":\"vector xyz\",\"async\":false,\"drawable\":true,\"data\":{\"genericNodeData\":{\"hide\":true,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"x\":0,\"y\":32,\"z\":0},\"inputs\":{},\"position\":[4910.618536230501,1875.6153539025163]},\"43f2efdf3003002e\":{\"id\":\"43f2efdf3003002e\",\"name\":\"bitbybit.vector.vectorXYZ\",\"customName\":\"vector xyz\",\"async\":false,\"drawable\":true,\"data\":{\"genericNodeData\":{\"hide\":true,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"x\":2,\"y\":1,\"z\":2},\"inputs\":{\"x\":{\"connections\":[{\"node\":\"80d8c2210e2c8ada\",\"output\":\"result\",\"data\":{}}]},\"y\":{\"connections\":[{\"node\":\"80d8c2210e2c8ada\",\"output\":\"result\",\"data\":{}}]},\"z\":{\"connections\":[{\"node\":\"80d8c2210e2c8ada\",\"output\":\"result\",\"data\":{}}]}},\"position\":[3110.961471038728,3310.5951164909416]},\"7ea739c655493f9b\":{\"id\":\"7ea739c655493f9b\",\"name\":\"bitbybit.occt.shapes.face.reversedFace\",\"customName\":\"reversed face\",\"async\":true,\"drawable\":true,\"data\":{\"genericNodeData\":{\"hide\":true,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false}},\"inputs\":{\"shape\":{\"connections\":[{\"node\":\"5a31954b0015e697\",\"output\":\"result\",\"data\":{}}]}},\"position\":[4008.2380004947863,1087.5384630463477]},\"ff3a5dfe26c1203f\":{\"id\":\"ff3a5dfe26c1203f\",\"name\":\"bitbybit.occt.transforms.scale\",\"customName\":\"scale\",\"async\":true,\"drawable\":true,\"data\":{\"genericNodeData\":{\"hide\":true,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"factor\":0.5},\"inputs\":{\"shape\":{\"connections\":[{\"node\":\"d533f9b2b358e932\",\"output\":\"result\",\"data\":{}}]}},\"position\":[9189.222022342807,640.7663938760614]},\"36d87d3e5dda7cfb\":{\"id\":\"36d87d3e5dda7cfb\",\"name\":\"bitbybit.babylon.scene.drawDirectionalLight\",\"customName\":\"draw directional light\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"direction\":[-100,-100,-100],\"intensity\":3,\"diffuse\":\"#0084ff\",\"specular\":\"#ffffff\",\"shadowGeneratorMapSize\":1024,\"enableShadows\":true,\"shadowDarkness\":0,\"shadowUsePercentageCloserFiltering\":true,\"shadowContactHardeningLightSizeUVRatio\":0.2,\"shadowBias\":0.0001,\"shadowNormalBias\":0.002,\"shadowMaxZ\":1000,\"shadowMinZ\":0},\"inputs\":{\"direction\":{\"connections\":[{\"node\":\"9c598c3fd358e209\",\"output\":\"result\",\"data\":{}}]}},\"position\":[2410.492548455645,-1108.187459661422]},\"9c598c3fd358e209\":{\"id\":\"9c598c3fd358e209\",\"name\":\"bitbybit.vector.vectorXYZ\",\"customName\":\"vector xyz\",\"async\":false,\"drawable\":true,\"data\":{\"genericNodeData\":{\"hide\":true,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"x\":-100,\"y\":50,\"z\":-100},\"inputs\":{},\"position\":[1866.1241234045078,-1104.6216865423542]},\"dd44e69c6aba7a0d\":{\"id\":\"dd44e69c6aba7a0d\",\"name\":\"bitbybit.occt.shapes.wire.getWires\",\"customName\":\"get wires\",\"async\":true,\"drawable\":true,\"data\":{\"genericNodeData\":{\"hide\":true,\"oneOnOne\":false,\"flatten\":1,\"forceExecution\":false}},\"inputs\":{\"shape\":{\"connections\":[{\"node\":\"a385c2492e4ef6f1\",\"output\":\"result\",\"data\":{}}]}},\"position\":[4354.892794420823,2367.2120176828043]},\"f9fb91cec187f7f0\":{\"id\":\"f9fb91cec187f7f0\",\"name\":\"bitbybit.occt.shapes.wire.getWires\",\"customName\":\"get wires\",\"async\":true,\"drawable\":true,\"data\":{\"genericNodeData\":{\"hide\":true,\"oneOnOne\":false,\"flatten\":1,\"forceExecution\":false}},\"inputs\":{\"shape\":{\"connections\":[{\"node\":\"b14378ceb8bf7fc5\",\"output\":\"result\",\"data\":{}}]}},\"position\":[4682.071021905679,2782.246685007575]},\"ca83297771d11aa5\":{\"id\":\"ca83297771d11aa5\",\"name\":\"bitbybit.lists.removeItemAtIndex\",\"customName\":\"remove item at index\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"index\":0,\"clone\":true},\"inputs\":{\"list\":{\"connections\":[{\"node\":\"74d09b8bdb4c5048\",\"output\":\"result\",\"data\":{}}]}},\"position\":[3558.8739387013798,1967.9824675636294]},\"a385c2492e4ef6f1\":{\"id\":\"a385c2492e4ef6f1\",\"name\":\"bitbybit.lists.flatten\",\"customName\":\"flatten\",\"data\":{\"nrLevels\":1},\"inputs\":{\"list\":{\"connections\":[{\"node\":\"ca83297771d11aa5\",\"output\":\"result\",\"data\":{}}]}},\"position\":[4016.6293284317,2616.607395641203]},\"42f74d68d23d3247\":{\"id\":\"42f74d68d23d3247\",\"name\":\"bitbybit.babylon.scene.fog\",\"customName\":\"fog\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"mode\":\"linear\",\"color\":\"#c9c9c9\",\"density\":0.1,\"start\":35,\"end\":100},\"inputs\":{\"color\":{\"connections\":[{\"node\":\"7b75db43179570c8\",\"output\":\"result\",\"data\":{}}]}},\"position\":[2442.8735698720834,-42.14590401627983]},\"7b75db43179570c8\":{\"id\":\"7b75db43179570c8\",\"name\":\"bitbybit.color.hexColor\",\"customName\":\"hex color\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"color\":\"#8397aa\"},\"inputs\":{},\"position\":[2098.232163729327,-306.933632265146]},\"8f5c08c8c98f4eb6\":{\"id\":\"8f5c08c8c98f4eb6\",\"name\":\"bitbybit.babylon.gui.advancedDynamicTexture.createFullScreenUI\",\"customName\":\"full screen ui\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"name\":\"fullscreen\",\"foreground\":true,\"adaptiveScaling\":false},\"inputs\":{},\"position\":[-1056.7184739683328,2836.232260686571]},\"62013821226fbd05\":{\"id\":\"62013821226fbd05\",\"name\":\"bitbybit.babylon.gui.container.addControls\",\"customName\":\"add controls\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"clearControlsFirst\":true},\"inputs\":{\"controls\":{\"connections\":[{\"node\":\"5d70cbf01bf83e55\",\"output\":\"list\",\"data\":{}}]},\"container\":{\"connections\":[{\"node\":\"8f5c08c8c98f4eb6\",\"output\":\"result\",\"data\":{}}]}},\"position\":[1051.4522897911515,2825.729196003556]},\"5d70cbf01bf83e55\":{\"id\":\"5d70cbf01bf83e55\",\"name\":\"bitbybit.lists.createList\",\"customName\":\"create list\",\"data\":{},\"inputs\":{\"listElements\":{\"connections\":[{\"node\":\"d7157cf9080bd8c5\",\"output\":\"result\",\"data\":{}}]}},\"position\":[779.1858107406395,3260.0028960769355]},\"6ea6f5c19d2c3679\":{\"id\":\"6ea6f5c19d2c3679\",\"name\":\"bitbybit.babylon.gui.stackPanel.createStackPanel\",\"customName\":\"stack panel\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"name\":\"stackPanel\",\"isVertical\":true,\"spacing\":25,\"color\":\"#00000000\",\"background\":\"#00000000\"},\"inputs\":{\"width\":{\"connections\":[{\"node\":\"1c3567b107487ab7\",\"output\":\"result\",\"data\":{}}]},\"height\":{\"connections\":[{\"node\":\"2cfa0a89722e88ad\",\"output\":\"result\",\"data\":{}}]}},\"position\":[-644.7439786868175,3305.091365601621]},\"1c3567b107487ab7\":{\"id\":\"1c3567b107487ab7\",\"name\":\"bitbybit.text.create\",\"customName\":\"create\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"text\":\"740px\"},\"inputs\":{},\"position\":[-1005.9218465842323,3360.972335833377]},\"2cfa0a89722e88ad\":{\"id\":\"2cfa0a89722e88ad\",\"name\":\"bitbybit.text.create\",\"customName\":\"create\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"text\":\"850px\"},\"inputs\":{},\"position\":[-1015.568499809784,3636.3340536899586]},\"7256842476045eb7\":{\"id\":\"7256842476045eb7\",\"name\":\"bitbybit.babylon.gui.control.changeControlAlignment\",\"customName\":\"change control alignment\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"horizontalAlignment\":\"left\",\"verticalAlignment\":\"bottom\"},\"inputs\":{\"control\":{\"connections\":[{\"node\":\"6ea6f5c19d2c3679\",\"output\":\"result\",\"data\":{}}]}},\"position\":[-55.86693666910121,3469.4026625427564]},\"d7157cf9080bd8c5\":{\"id\":\"d7157cf9080bd8c5\",\"name\":\"bitbybit.babylon.gui.control.changeControlPadding\",\"customName\":\"change control padding\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false}},\"inputs\":{\"control\":{\"connections\":[{\"node\":\"7256842476045eb7\",\"output\":\"result\",\"data\":{}}]},\"paddingLeft\":{\"connections\":[{\"node\":\"2e27ec0382325605\",\"output\":\"result\",\"data\":{}}]},\"paddingRight\":{\"connections\":[{\"node\":\"2e27ec0382325605\",\"output\":\"result\",\"data\":{}}]},\"paddingTop\":{\"connections\":[{\"node\":\"2e27ec0382325605\",\"output\":\"result\",\"data\":{}}]},\"paddingBottom\":{\"connections\":[{\"node\":\"2e27ec0382325605\",\"output\":\"result\",\"data\":{}}]}},\"position\":[374.0302769524635,3524.3010854904096]},\"2e27ec0382325605\":{\"id\":\"2e27ec0382325605\",\"name\":\"bitbybit.text.create\",\"customName\":\"create\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"text\":\"35px\"},\"inputs\":{},\"position\":[38.94193286015155,3917.4311588521]},\"bbd88144625e447e\":{\"id\":\"bbd88144625e447e\",\"name\":\"bitbybit.babylon.gui.container.addControls\",\"customName\":\"add controls\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"clearControlsFirst\":true},\"inputs\":{\"container\":{\"connections\":[{\"node\":\"d7157cf9080bd8c5\",\"output\":\"result\",\"data\":{}}]},\"controls\":{\"connections\":[{\"node\":\"688df756a4d3edd8\",\"output\":\"list\",\"data\":{}}]}},\"position\":[1117.0240712398745,3999.2649441995045]},\"688df756a4d3edd8\":{\"id\":\"688df756a4d3edd8\",\"name\":\"bitbybit.lists.createList\",\"customName\":\"create list\",\"data\":{},\"inputs\":{\"listElements\":{\"connections\":[{\"node\":\"a67fb013d25c1008\",\"output\":\"result\",\"data\":{}}]}},\"position\":[808.172430927605,4141.539962993023]},\"a67fb013d25c1008\":{\"id\":\"a67fb013d25c1008\",\"name\":\"bitbybit.babylon.gui.control.changeControlPadding\",\"customName\":\"change control padding\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false}},\"inputs\":{\"paddingLeft\":{\"connections\":[{\"node\":\"2e27ec0382325605\",\"output\":\"result\",\"data\":{}}]},\"paddingRight\":{\"connections\":[{\"node\":\"2e27ec0382325605\",\"output\":\"result\",\"data\":{}}]},\"paddingTop\":{\"connections\":[{\"node\":\"2e27ec0382325605\",\"output\":\"result\",\"data\":{}}]},\"paddingBottom\":{\"connections\":[{\"node\":\"2e27ec0382325605\",\"output\":\"result\",\"data\":{}}]},\"control\":{\"connections\":[{\"node\":\"8019c3f4a93360fc\",\"output\":\"result\",\"data\":{}}]}},\"position\":[381.53080329328145,4124.938450095269]},\"8019c3f4a93360fc\":{\"id\":\"8019c3f4a93360fc\",\"name\":\"bitbybit.babylon.gui.stackPanel.createStackPanel\",\"customName\":\"stack panel\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"name\":\"stackPanel\",\"isVertical\":true,\"spacing\":32,\"color\":\"#00000000\",\"background\":\"#00000055\"},\"inputs\":{\"width\":{\"connections\":[{\"node\":\"c7771b05bfece223\",\"output\":\"result\",\"data\":{}}]},\"height\":{\"connections\":[{\"node\":\"c7771b05bfece223\",\"output\":\"result\",\"data\":{}}]}},\"position\":[-634.5679617178588,4122.829976185915]},\"c7771b05bfece223\":{\"id\":\"c7771b05bfece223\",\"name\":\"bitbybit.math.number\",\"customName\":\"number\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"number\":1},\"inputs\":{},\"position\":[-1030.5012301905765,4255.332320202711]},\"3cdac0a2da52d477\":{\"id\":\"3cdac0a2da52d477\",\"name\":\"bitbybit.babylon.gui.textBlock.createTextBlock\",\"customName\":\"text block\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"name\":\"textBlockName\",\"text\":\"❄️❄️❄️🎄 TOY 🎄❄️❄️❄️\",\"color\":\"#f0cebb\",\"fontSize\":43},\"inputs\":{\"color\":{\"connections\":[{\"node\":\"14ea460327313f84\",\"output\":\"result\",\"data\":{}}]},\"height\":{\"connections\":[{\"node\":\"8fdac6b820e66385\",\"output\":\"result\",\"data\":{}}]}},\"position\":[-853.8406515994363,5107.457479372801]},\"4c68d9ac771b698a\":{\"id\":\"4c68d9ac771b698a\",\"name\":\"bitbybit.babylon.gui.container.addControls\",\"customName\":\"add controls\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"clearControlsFirst\":true},\"inputs\":{\"container\":{\"connections\":[{\"node\":\"a67fb013d25c1008\",\"output\":\"result\",\"data\":{}}]},\"controls\":{\"connections\":[{\"node\":\"40ad5c91b680fe5b\",\"output\":\"list\",\"data\":{}}]}},\"position\":[1081.1735221113568,4989.645601752394]},\"40ad5c91b680fe5b\":{\"id\":\"40ad5c91b680fe5b\",\"name\":\"bitbybit.lists.createList\",\"customName\":\"create list\",\"data\":{},\"inputs\":{\"listElements\":{\"connections\":[{\"node\":\"3cdac0a2da52d477\",\"output\":\"result\",\"data\":{}},{\"node\":\"eb164cb9f2c3d0b2\",\"output\":\"result\",\"data\":{}},{\"node\":\"f80263a3d6977ea4\",\"output\":\"result\",\"data\":{}},{\"node\":\"dda72ba4bc855075\",\"output\":\"result\",\"data\":{}},{\"node\":\"a3006cf7f5041ef6\",\"output\":\"result\",\"data\":{}},{\"node\":\"22b0aaced3db29ad\",\"output\":\"result\",\"data\":{}},{\"node\":\"9de26dfa0b6980e6\",\"output\":\"result\",\"data\":{}}]}},\"position\":[131.27159201850196,6807.45958474214]},\"14ea460327313f84\":{\"id\":\"14ea460327313f84\",\"name\":\"bitbybit.color.hexColor\",\"customName\":\"hex color\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"color\":\"#75a3ff\"},\"inputs\":{},\"position\":[-2524.347102647334,9183.15923769915]},\"be55efccc9dd82ed\":{\"id\":\"be55efccc9dd82ed\",\"name\":\"bitbybit.babylon.gui.control.changeControlPadding\",\"customName\":\"change control padding\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false}},\"inputs\":{\"control\":{\"connections\":[{\"node\":\"3cdac0a2da52d477\",\"output\":\"result\",\"data\":{}}]},\"paddingTop\":{\"connections\":[{\"node\":\"96b4e817c4c14f20\",\"output\":\"result\",\"data\":{}}]},\"paddingBottom\":{\"connections\":[{\"node\":\"f6b793e8e89edda0\",\"output\":\"result\",\"data\":{}}]}},\"position\":[310.06370891276634,5361.812652019315]},\"96b4e817c4c14f20\":{\"id\":\"96b4e817c4c14f20\",\"name\":\"bitbybit.text.create\",\"customName\":\"create\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"text\":\"25px\"},\"inputs\":{},\"position\":[-216.81270824516469,5476.663754188035]},\"8fdac6b820e66385\":{\"id\":\"8fdac6b820e66385\",\"name\":\"bitbybit.text.create\",\"customName\":\"create\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"text\":\"105px\"},\"inputs\":{},\"position\":[-1181.045524940636,5460.547434196808]},\"eb164cb9f2c3d0b2\":{\"id\":\"eb164cb9f2c3d0b2\",\"name\":\"bitbybit.babylon.gui.slider.createSlider\",\"customName\":\"slider\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"name\":\"rays\",\"minimum\":3,\"maximum\":12,\"value\":6,\"step\":1,\"isVertical\":false,\"color\":\"#f0cebb\",\"background\":\"black\",\"displayThumb\":true},\"inputs\":{\"value\":{\"connections\":[{\"node\":\"6e51a85f13ab5259\",\"output\":\"result\",\"data\":{}}]},\"color\":{\"connections\":[{\"node\":\"14ea460327313f84\",\"output\":\"result\",\"data\":{}}]}},\"position\":[-821.5978737310934,5908.02843885303]},\"6e51a85f13ab5259\":{\"id\":\"6e51a85f13ab5259\",\"name\":\"bitbybit.math.numberSlider\",\"customName\":\"number slider\",\"data\":{\"options\":{\"min\":3,\"max\":12,\"step\":1,\"width\":350,\"updateOnDrag\":false},\"number\":5},\"inputs\":{},\"position\":[-1455.2743568834462,6056.45799565296]},\"f80263a3d6977ea4\":{\"id\":\"f80263a3d6977ea4\",\"name\":\"bitbybit.babylon.gui.textBlock.createTextBlock\",\"customName\":\"text block\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"name\":\"textBlockName\",\"text\":\"Number Of Rays\",\"color\":\"#f0cebb\",\"fontSize\":32},\"inputs\":{\"color\":{\"connections\":[{\"node\":\"14ea460327313f84\",\"output\":\"result\",\"data\":{}}]}},\"position\":[-853.88650164059,6570.290388610167]},\"dda72ba4bc855075\":{\"id\":\"dda72ba4bc855075\",\"name\":\"bitbybit.babylon.gui.slider.createSlider\",\"customName\":\"slider\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"name\":\"verticalOpeningsSlider\",\"minimum\":1,\"maximum\":25,\"value\":6,\"step\":1,\"isVertical\":false,\"color\":\"#f0cebb\",\"background\":\"black\",\"displayThumb\":true},\"inputs\":{\"value\":{\"connections\":[{\"node\":\"dc27ec58598933e4\",\"output\":\"result\",\"data\":{}}]},\"color\":{\"connections\":[{\"node\":\"14ea460327313f84\",\"output\":\"result\",\"data\":{}}]}},\"position\":[-831.8855421151479,7040.183968957487]},\"dc27ec58598933e4\":{\"id\":\"dc27ec58598933e4\",\"name\":\"bitbybit.math.numberSlider\",\"customName\":\"number slider\",\"data\":{\"options\":{\"min\":1,\"max\":25,\"step\":1,\"width\":350,\"updateOnDrag\":false},\"number\":5},\"inputs\":{},\"position\":[-1548.5643926124947,7215.153436337072]},\"a3006cf7f5041ef6\":{\"id\":\"a3006cf7f5041ef6\",\"name\":\"bitbybit.babylon.gui.textBlock.createTextBlock\",\"customName\":\"text block\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"name\":\"textBlockName\",\"text\":\"Vertical Divisions\",\"color\":\"#f0cebb\",\"fontSize\":32},\"inputs\":{\"color\":{\"connections\":[{\"node\":\"14ea460327313f84\",\"output\":\"result\",\"data\":{}}]}},\"position\":[-829.5105024166364,7718.522342332688]},\"22b0aaced3db29ad\":{\"id\":\"22b0aaced3db29ad\",\"name\":\"bitbybit.babylon.gui.button.createSimpleButton\",\"customName\":\"simple button\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"name\":\"buttonName\",\"label\":\"S I G N U P F O R M O R E !\",\"color\":\"white\",\"background\":\"#f0cebb\",\"fontSize\":32},\"inputs\":{\"background\":{\"connections\":[{\"node\":\"14ea460327313f84\",\"output\":\"result\",\"data\":{}}]},\"height\":{\"connections\":[{\"node\":\"b5ab513337ea1f9c\",\"output\":\"result\",\"data\":{}}]}},\"position\":[-846.86829904502,8223.84317108378]},\"b5ab513337ea1f9c\":{\"id\":\"b5ab513337ea1f9c\",\"name\":\"bitbybit.text.create\",\"customName\":\"create\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"text\":\"95px\"},\"inputs\":{},\"position\":[-1211.515140544501,8409.866247193688]},\"3d74af9c8a8b1dd3\":{\"id\":\"3d74af9c8a8b1dd3\",\"name\":\"bitbybit.babylon.gui.control.changeControlPadding\",\"customName\":\"change control padding\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false}},\"inputs\":{\"control\":{\"connections\":[{\"node\":\"22b0aaced3db29ad\",\"output\":\"result\",\"data\":{}}]},\"paddingLeft\":{\"connections\":[{\"node\":\"f49f0b323ff33034\",\"output\":\"result\",\"data\":{}}]},\"paddingRight\":{\"connections\":[{\"node\":\"f49f0b323ff33034\",\"output\":\"result\",\"data\":{}}]}},\"position\":[147.85415967299022,8465.334888215139]},\"f49f0b323ff33034\":{\"id\":\"f49f0b323ff33034\",\"name\":\"bitbybit.text.create\",\"customName\":\"create\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"text\":\"32px\"},\"inputs\":{},\"position\":[-351.90583473376483,8527.624810198047]},\"9de26dfa0b6980e6\":{\"id\":\"9de26dfa0b6980e6\",\"name\":\"bitbybit.babylon.gui.stackPanel.createStackPanel\",\"customName\":\"stack panel\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"name\":\"actions\",\"isVertical\":false,\"spacing\":20,\"color\":\"#00000000\",\"background\":\"#00000055\"},\"inputs\":{\"height\":{\"connections\":[{\"node\":\"94be48fa3d341e2f\",\"output\":\"result\",\"data\":{}}]}},\"position\":[-860.4566955224043,8845.655587065246]},\"94be48fa3d341e2f\":{\"id\":\"94be48fa3d341e2f\",\"name\":\"bitbybit.text.create\",\"customName\":\"create\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"text\":\"150px\"},\"inputs\":{},\"position\":[-1243.8502616502608,8996.109487316298]},\"386aa0fba070069e\":{\"id\":\"386aa0fba070069e\",\"name\":\"bitbybit.lists.createList\",\"customName\":\"create list\",\"data\":{},\"inputs\":{\"listElements\":{\"connections\":[{\"node\":\"fc36f702c3f8146e\",\"output\":\"result\",\"data\":{}},{\"node\":\"71fbc1ccee37d577\",\"output\":\"result\",\"data\":{}},{\"node\":\"dfd5ec0585a0e37f\",\"output\":\"result\",\"data\":{}}]}},\"position\":[86.09946070310812,9675.048597360192]},\"fc36f702c3f8146e\":{\"id\":\"fc36f702c3f8146e\",\"name\":\"bitbybit.babylon.gui.button.createSimpleButton\",\"customName\":\"simple button\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"name\":\"getStep\",\"label\":\"Get STEP\",\"color\":\"white\",\"background\":\"black\",\"fontSize\":24},\"inputs\":{\"width\":{\"connections\":[{\"node\":\"9627abcea218d31f\",\"output\":\"result\",\"data\":{}}]},\"height\":{\"connections\":[{\"node\":\"5189291d4a0b99c3\",\"output\":\"result\",\"data\":{}}]},\"color\":{\"connections\":[{\"node\":\"14ea460327313f84\",\"output\":\"result\",\"data\":{}}]}},\"position\":[-906.5263779292032,9503.72186483339]},\"9627abcea218d31f\":{\"id\":\"9627abcea218d31f\",\"name\":\"bitbybit.text.create\",\"customName\":\"create\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"text\":\"186px\"},\"inputs\":{},\"position\":[-1280.2041644956794,9443.521680268339]},\"5189291d4a0b99c3\":{\"id\":\"5189291d4a0b99c3\",\"name\":\"bitbybit.math.number\",\"customName\":\"number\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"number\":0.5},\"inputs\":{},\"position\":[-1336.124164455853,9763.964706483723]},\"b42caf22b316e228\":{\"id\":\"b42caf22b316e228\",\"name\":\"bitbybit.babylon.gui.container.addControls\",\"customName\":\"add controls\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"clearControlsFirst\":true},\"inputs\":{\"controls\":{\"connections\":[{\"node\":\"386aa0fba070069e\",\"output\":\"list\",\"data\":{}}]},\"container\":{\"connections\":[{\"node\":\"9de5622b3e543a8a\",\"output\":\"result\",\"data\":{}}]}},\"position\":[1052.8239083530739,9110.88729112261]},\"27161889f007dc04\":{\"id\":\"27161889f007dc04\",\"name\":\"bitbybit.babylon.gui.control.changeControlAlignment\",\"customName\":\"change control alignment\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"horizontalAlignment\":\"center\",\"verticalAlignment\":\"center\"},\"inputs\":{\"control\":{\"connections\":[{\"node\":\"9de26dfa0b6980e6\",\"output\":\"result\",\"data\":{}}]}},\"position\":[-269.69695321588506,8927.379602739795]},\"71fbc1ccee37d577\":{\"id\":\"71fbc1ccee37d577\",\"name\":\"bitbybit.babylon.gui.button.createSimpleButton\",\"customName\":\"simple button\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"name\":\"getStl\",\"label\":\"Get STL\",\"color\":\"white\",\"background\":\"black\",\"fontSize\":24},\"inputs\":{\"width\":{\"connections\":[{\"node\":\"9627abcea218d31f\",\"output\":\"result\",\"data\":{}}]},\"height\":{\"connections\":[{\"node\":\"5189291d4a0b99c3\",\"output\":\"result\",\"data\":{}}]},\"color\":{\"connections\":[{\"node\":\"14ea460327313f84\",\"output\":\"result\",\"data\":{}}]}},\"position\":[-906.6855973027857,10056.533240815332]},\"dfd5ec0585a0e37f\":{\"id\":\"dfd5ec0585a0e37f\",\"name\":\"bitbybit.babylon.gui.button.createSimpleButton\",\"customName\":\"simple button\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"name\":\"sourceCode\",\"label\":\"Source Code\",\"color\":\"white\",\"background\":\"black\",\"fontSize\":24},\"inputs\":{\"color\":{\"connections\":[{\"node\":\"14ea460327313f84\",\"output\":\"result\",\"data\":{}}]},\"height\":{\"connections\":[{\"node\":\"5189291d4a0b99c3\",\"output\":\"result\",\"data\":{}}]},\"width\":{\"connections\":[{\"node\":\"9627abcea218d31f\",\"output\":\"result\",\"data\":{}}]}},\"position\":[-906.7686354515675,10569.423308562755]},\"9de5622b3e543a8a\":{\"id\":\"9de5622b3e543a8a\",\"name\":\"bitbybit.babylon.gui.control.changeControlPadding\",\"customName\":\"change control padding\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false}},\"inputs\":{\"paddingTop\":{\"connections\":[{\"node\":\"ce084356ce41072e\",\"output\":\"result\",\"data\":{}}]},\"control\":{\"connections\":[{\"node\":\"27161889f007dc04\",\"output\":\"result\",\"data\":{}}]},\"paddingLeft\":{\"connections\":[{\"node\":\"ce084356ce41072e\",\"output\":\"result\",\"data\":{}}]},\"paddingRight\":{\"connections\":[{\"node\":\"ce084356ce41072e\",\"output\":\"result\",\"data\":{}}]},\"paddingBottom\":{\"connections\":[{\"node\":\"ce084356ce41072e\",\"output\":\"result\",\"data\":{}}]}},\"position\":[386.5736003150091,9022.420560407636]},\"ce084356ce41072e\":{\"id\":\"ce084356ce41072e\",\"name\":\"bitbybit.text.create\",\"customName\":\"create\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"text\":\"0px\"},\"inputs\":{},\"position\":[-150.892111299047,9269.41326836467]},\"3b1402c27d9aa4d9\":{\"id\":\"3b1402c27d9aa4d9\",\"name\":\"bitbybit.babylon.gui.control.changeControlPadding\",\"customName\":\"change control padding\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false}},\"inputs\":{\"paddingTop\":{\"connections\":[{\"node\":\"7c43fbf3b4039859\",\"output\":\"result\",\"data\":{}}]},\"control\":{\"connections\":[{\"node\":\"22b0aaced3db29ad\",\"output\":\"result\",\"data\":{}}]}},\"position\":[468.6889889862706,7806.3724958885105]},\"7c43fbf3b4039859\":{\"id\":\"7c43fbf3b4039859\",\"name\":\"bitbybit.text.create\",\"customName\":\"create\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"text\":\"40px\"},\"inputs\":{},\"position\":[38.94985237381003,8082.178454308819]},\"bf021b750fd00e30\":{\"id\":\"bf021b750fd00e30\",\"name\":\"bitbybit.text.create\",\"customName\":\"create\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"text\":\"45px\"},\"inputs\":{},\"position\":[-26.956821924678025,4278.492442388621]},\"f6b793e8e89edda0\":{\"id\":\"f6b793e8e89edda0\",\"name\":\"bitbybit.text.create\",\"customName\":\"create\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"text\":\"35px\"},\"inputs\":{},\"position\":[-204.24116761177675,5756.856375833485]},\"f1f8cf3eadfa0ebb\":{\"id\":\"f1f8cf3eadfa0ebb\",\"name\":\"bitbybit.babylon.gui.control.createControlObservableSelector\",\"customName\":\"control observable selector\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"selector\":\"onPointerUpObservable\"},\"inputs\":{},\"position\":[-284.4470112110814,10728.8905088672]},\"43441120529c36e3\":{\"id\":\"43441120529c36e3\",\"name\":\"bitbybit.flow.babylon.observableListener\",\"customName\":\"babylon observable listener\",\"data\":{},\"inputs\":{\"observableSelector\":{\"connections\":[{\"node\":\"f1f8cf3eadfa0ebb\",\"output\":\"result\",\"data\":{}}]},\"object\":{\"connections\":[{\"node\":\"dfd5ec0585a0e37f\",\"output\":\"result\",\"data\":{}}]}},\"position\":[379.3161481874706,10607.903050757823]},\"38f701184db60233\":{\"id\":\"38f701184db60233\",\"name\":\"bitbybit.flow.time.delay\",\"customName\":\"delay\",\"data\":{\"timeout\":0},\"inputs\":{\"exec\":{\"connections\":[{\"node\":\"43441120529c36e3\",\"output\":\"exec\",\"data\":{}}]}},\"position\":[933.2062286858425,10749.580736333644]},\"fbe1705ff510913a\":{\"id\":\"fbe1705ff510913a\",\"name\":\"bitbybit.flow.logic.flipFlop\",\"customName\":\"flip flop\",\"data\":{},\"inputs\":{\"exec\":{\"connections\":[{\"node\":\"43441120529c36e3\",\"output\":\"exec\",\"data\":{}},{\"node\":\"38f701184db60233\",\"output\":\"exec\",\"data\":{}}]}},\"position\":[1286.7786245546422,10638.06142237177]},\"83ffa041662302e3\":{\"id\":\"83ffa041662302e3\",\"name\":\"bitbybit.code.typeScriptEditor\",\"customName\":\"typescript editor\",\"async\":true,\"drawable\":true,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":true},\"code\":{\"code\":\"// DO NOT REMOVE THIS FUNCTION\\nconst start83ffa041662302e3 = async (inputs: any, index: number) => {\\n // ADD YOUR CODE HERE\\n if (inputs === true) {\\n window.open(\\\"https://bitbybit.dev/app/bitbybit/KtIymkYFZ8Qty9h8mhew/Y7NQIgaXLy0dqffnc825?editor=rete\\\", '_blank').focus();\\n }\\n return inputs;\\n}\"}},\"inputs\":{\"inputs\":{\"connections\":[{\"node\":\"fbe1705ff510913a\",\"output\":\"isA\",\"data\":{}}]},\"exec\":{\"connections\":[{\"node\":\"fbe1705ff510913a\",\"output\":\"execA\",\"data\":{}},{\"node\":\"fbe1705ff510913a\",\"output\":\"execB\",\"data\":{}}]}},\"position\":[1749.7763306366996,10636.786904135595]},\"af7350efdb0b85b3\":{\"id\":\"af7350efdb0b85b3\",\"name\":\"bitbybit.babylon.gui.control.createControlObservableSelector\",\"customName\":\"control observable selector\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"selector\":\"onPointerUpObservable\"},\"inputs\":{},\"position\":[686.4715121547069,8508.681235887017]},\"f2e18ffd18566787\":{\"id\":\"f2e18ffd18566787\",\"name\":\"bitbybit.flow.babylon.observableListener\",\"customName\":\"babylon observable listener\",\"data\":{},\"inputs\":{\"object\":{\"connections\":[{\"node\":\"22b0aaced3db29ad\",\"output\":\"result\",\"data\":{}}]},\"observableSelector\":{\"connections\":[{\"node\":\"af7350efdb0b85b3\",\"output\":\"result\",\"data\":{}}]}},\"position\":[1453.070365919411,8258.538315404885]},\"70259fc69f3db105\":{\"id\":\"70259fc69f3db105\",\"name\":\"bitbybit.flow.time.delay\",\"customName\":\"delay\",\"data\":{\"timeout\":0},\"inputs\":{\"exec\":{\"connections\":[{\"node\":\"f2e18ffd18566787\",\"output\":\"exec\",\"data\":{}}]}},\"position\":[1987.6045976314351,8437.042718662588]},\"291c95f88aae5725\":{\"id\":\"291c95f88aae5725\",\"name\":\"bitbybit.flow.logic.flipFlop\",\"customName\":\"flip flop\",\"data\":{},\"inputs\":{\"exec\":{\"connections\":[{\"node\":\"70259fc69f3db105\",\"output\":\"exec\",\"data\":{}},{\"node\":\"f2e18ffd18566787\",\"output\":\"exec\",\"data\":{}}]}},\"position\":[2323.4070267726706,8288.053843144928]},\"ac5f02670de06852\":{\"id\":\"ac5f02670de06852\",\"name\":\"bitbybit.code.typeScriptEditor\",\"customName\":\"typescript editor\",\"async\":true,\"drawable\":true,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":true},\"code\":{\"code\":\"// DO NOT REMOVE THIS FUNCTION\\nconst startac5f02670de06852 = async (inputs: any, index: number) => {\\n // ADD YOUR CODE HERE\\n if (inputs === true) {\\n window.open(\\\"https://bitbybit.dev/auth/sign-up\\\", '_blank').focus();\\n }\\n return inputs;\\n}\"}},\"inputs\":{\"inputs\":{\"connections\":[{\"node\":\"291c95f88aae5725\",\"output\":\"isA\",\"data\":{}}]},\"exec\":{\"connections\":[{\"node\":\"291c95f88aae5725\",\"output\":\"execA\",\"data\":{}},{\"node\":\"291c95f88aae5725\",\"output\":\"execB\",\"data\":{}}]}},\"position\":[2681.990286952205,8287.587249893892]},\"b5af9279ffdd84e5\":{\"id\":\"b5af9279ffdd84e5\",\"name\":\"bitbybit.babylon.scene.enableSkybox\",\"customName\":\"enable skybox\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"skybox\":\"city\",\"size\":1000,\"blur\":0.5,\"environmentIntensity\":0.7,\"hideSkybox\":false},\"inputs\":{},\"position\":[2884.1306675480555,-186.0490873535386]},\"9dca219fedacecca\":{\"id\":\"9dca219fedacecca\",\"name\":\"bitbybit.flow.babylon.observableListener\",\"customName\":\"babylon observable listener\",\"data\":{},\"inputs\":{\"observableSelector\":{\"connections\":[{\"node\":\"f1f8cf3eadfa0ebb\",\"output\":\"result\",\"data\":{}}]},\"object\":{\"connections\":[{\"node\":\"71fbc1ccee37d577\",\"output\":\"result\",\"data\":{}}]}},\"position\":[385.9268891419183,10329.874563653837]},\"bb201b1ec9f17a1e\":{\"id\":\"bb201b1ec9f17a1e\",\"name\":\"bitbybit.flow.babylon.observableListener\",\"customName\":\"babylon observable listener\",\"data\":{},\"inputs\":{\"observableSelector\":{\"connections\":[{\"node\":\"f1f8cf3eadfa0ebb\",\"output\":\"result\",\"data\":{}}]},\"object\":{\"connections\":[{\"node\":\"fc36f702c3f8146e\",\"output\":\"result\",\"data\":{}}]}},\"position\":[394.16500271911553,10076.96114156523]},\"4a5d1c196a0b447e\":{\"id\":\"4a5d1c196a0b447e\",\"name\":\"bitbybit.flow.time.delay\",\"customName\":\"delay\",\"data\":{\"timeout\":0},\"inputs\":{\"exec\":{\"connections\":[{\"node\":\"9dca219fedacecca\",\"output\":\"exec\",\"data\":{}}]}},\"position\":[936.4095297912264,10457.862715124222]},\"4fd171db189ad173\":{\"id\":\"4fd171db189ad173\",\"name\":\"bitbybit.flow.logic.flipFlop\",\"customName\":\"flip flop\",\"data\":{},\"inputs\":{\"exec\":{\"connections\":[{\"node\":\"9dca219fedacecca\",\"output\":\"exec\",\"data\":{}},{\"node\":\"4a5d1c196a0b447e\",\"output\":\"exec\",\"data\":{}}]}},\"position\":[1273.654131279585,10355.281487174021]},\"94b6dd1354940df2\":{\"id\":\"94b6dd1354940df2\",\"name\":\"bitbybit.flow.time.delay\",\"customName\":\"delay\",\"data\":{\"timeout\":0},\"inputs\":{\"exec\":{\"connections\":[{\"node\":\"bb201b1ec9f17a1e\",\"output\":\"exec\",\"data\":{}}]}},\"position\":[926.4956949832613,10212.522265939324]},\"27eac850201a9701\":{\"id\":\"27eac850201a9701\",\"name\":\"bitbybit.flow.logic.flipFlop\",\"customName\":\"flip flop\",\"data\":{},\"inputs\":{\"exec\":{\"connections\":[{\"node\":\"bb201b1ec9f17a1e\",\"output\":\"exec\",\"data\":{}},{\"node\":\"94b6dd1354940df2\",\"output\":\"exec\",\"data\":{}}]}},\"position\":[1272.0778730255988,10103.055278248028]},\"9190095ec9cfd394\":{\"id\":\"9190095ec9cfd394\",\"name\":\"bitbybit.logic.valueGate\",\"customName\":\"value gate\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"boolean\":false},\"inputs\":{\"value\":{\"connections\":[{\"node\":\"73ee3cd6670755bb\",\"output\":\"result\",\"data\":{}}]},\"boolean\":{\"connections\":[{\"node\":\"27eac850201a9701\",\"output\":\"isA\",\"data\":{}}]},\"exec\":{\"connections\":[{\"node\":\"27eac850201a9701\",\"output\":\"execA\",\"data\":{}},{\"node\":\"27eac850201a9701\",\"output\":\"execB\",\"data\":{}}]}},\"position\":[2098.7596218076405,9630.876889007699]},\"73ee3cd6670755bb\":{\"id\":\"73ee3cd6670755bb\",\"name\":\"bitbybit.text.create\",\"customName\":\"create\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"text\":\"bitbybit-toy.step\"},\"inputs\":{},\"position\":[1701.8222304032442,9540.575618331815]},\"f9a87606405961ae\":{\"id\":\"f9a87606405961ae\",\"name\":\"bitbybit.text.create\",\"customName\":\"create\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"text\":\"bitbybit-toy.stl\"},\"inputs\":{},\"position\":[1934.0481177357838,10057.705993169464]},\"f8db44954a566616\":{\"id\":\"f8db44954a566616\",\"name\":\"bitbybit.logic.valueGate\",\"customName\":\"value gate\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"boolean\":false},\"inputs\":{\"value\":{\"connections\":[{\"node\":\"f9a87606405961ae\",\"output\":\"result\",\"data\":{}}]},\"boolean\":{\"connections\":[{\"node\":\"4fd171db189ad173\",\"output\":\"isA\",\"data\":{}}]},\"exec\":{\"connections\":[{\"node\":\"4fd171db189ad173\",\"output\":\"execA\",\"data\":{}},{\"node\":\"4fd171db189ad173\",\"output\":\"execB\",\"data\":{}}]}},\"position\":[2360.5651787274305,10179.991268481712]},\"7ae3f1f373ab7ce8\":{\"id\":\"7ae3f1f373ab7ce8\",\"name\":\"bitbybit.occt.io.saveShapeSTEPAndReturn\",\"customName\":\"save shape step and return\",\"async\":true,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"fileName\":\"\",\"adjustYtoZ\":true,\"fromRightHanded\":false,\"tryDownload\":true},\"inputs\":{\"shape\":{\"connections\":[{\"node\":\"ff3a5dfe26c1203f\",\"output\":\"result\",\"data\":{}}]},\"fileName\":{\"connections\":[{\"node\":\"9190095ec9cfd394\",\"output\":\"result\",\"data\":{}}]},\"exec\":{\"connections\":[{\"node\":\"9190095ec9cfd394\",\"output\":\"exec\",\"data\":{}}]}},\"position\":[4105.580503617983,9860.933809645778]},\"b358af77da1782cf\":{\"id\":\"b358af77da1782cf\",\"name\":\"bitbybit.occt.io.saveShapeStl\",\"customName\":\"save shape stl\",\"async\":true,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"fileName\":\"shape.stl\",\"precision\":0.01,\"adjustYtoZ\":true,\"tryDownload\":true,\"binary\":true},\"inputs\":{\"fileName\":{\"connections\":[{\"node\":\"f8db44954a566616\",\"output\":\"result\",\"data\":{}}]},\"exec\":{\"connections\":[{\"node\":\"f8db44954a566616\",\"output\":\"exec\",\"data\":{}}]},\"shape\":{\"connections\":[{\"node\":\"ff3a5dfe26c1203f\",\"output\":\"result\",\"data\":{}}]}},\"position\":[4097.343815578738,10313.986149668373]},\"feef4ec0e40282e7\":{\"id\":\"feef4ec0e40282e7\",\"name\":\"bitbybit.math.number\",\"customName\":\"number\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"number\":0.5},\"inputs\":{},\"position\":[2389.4392361815517,2241.565476619029]},\"03303a3d3cb2a6b5\":{\"id\":\"03303a3d3cb2a6b5\",\"name\":\"bitbybit.json.parse\",\"customName\":\"parse\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"text\":\"[true,false,true,true]\"},\"inputs\":{},\"position\":[2389.302212365796,2597.6283579746796]},\"f39c312f7e1e1bef\":{\"id\":\"f39c312f7e1e1bef\",\"name\":\"bitbybit.flow.babylon.observableListener\",\"customName\":\"babylon observable listener\",\"data\":{},\"inputs\":{\"observableSelector\":{\"connections\":[{\"node\":\"19dd5abb3a2ed30a\",\"output\":\"result\",\"data\":{}}]},\"object\":{\"connections\":[{\"node\":\"dda72ba4bc855075\",\"output\":\"result\",\"data\":{}}]}},\"position\":[634.3045048773648,6411.35023828563]},\"19dd5abb3a2ed30a\":{\"id\":\"19dd5abb3a2ed30a\",\"name\":\"bitbybit.babylon.gui.slider.createSliderObservableSelector\",\"customName\":\"slider observable selector\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"selector\":\"onValueChangedObservable\"},\"inputs\":{},\"position\":[119.33402358269528,6252.634270289916]},\"3f3e9efb919889cb\":{\"id\":\"3f3e9efb919889cb\",\"name\":\"bitbybit.flow.babylon.observableListener\",\"customName\":\"babylon observable listener\",\"data\":{},\"inputs\":{\"observableSelector\":{\"connections\":[{\"node\":\"19dd5abb3a2ed30a\",\"output\":\"result\",\"data\":{}}]},\"object\":{\"connections\":[{\"node\":\"eb164cb9f2c3d0b2\",\"output\":\"result\",\"data\":{}}]}},\"position\":[626.2393558517689,6035.026931379336]},\"b85e303f418ea094\":{\"id\":\"b85e303f418ea094\",\"name\":\"bitbybit.flow.babylon.getEventDataFromObservedResult\",\"customName\":\"get event data\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false}},\"inputs\":{\"json\":{\"connections\":[{\"node\":\"3f3e9efb919889cb\",\"output\":\"result\",\"data\":{}}]},\"exec\":{\"connections\":[{\"node\":\"3f3e9efb919889cb\",\"output\":\"exec\",\"data\":{}}]}},\"position\":[1213.8284182083087,6031.8004190176025]},\"0ae184887b347212\":{\"id\":\"0ae184887b347212\",\"name\":\"bitbybit.flow.babylon.getEventDataFromObservedResult\",\"customName\":\"get event data\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false}},\"inputs\":{\"exec\":{\"connections\":[{\"node\":\"f39c312f7e1e1bef\",\"output\":\"exec\",\"data\":{}}]},\"json\":{\"connections\":[{\"node\":\"f39c312f7e1e1bef\",\"output\":\"result\",\"data\":{}}]}},\"position\":[1212.113699374194,6401.279001431719]},\"ffecd6164df0c288\":{\"id\":\"ffecd6164df0c288\",\"name\":\"bitbybit.logic.firstDefinedValueGate\",\"customName\":\"first defined value gate\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false}},\"inputs\":{\"value1\":{\"connections\":[{\"node\":\"b85e303f418ea094\",\"output\":\"result\",\"data\":{}}]},\"value2\":{\"connections\":[{\"node\":\"6e51a85f13ab5259\",\"output\":\"result\",\"data\":{}}]},\"exec\":{\"connections\":[{\"node\":\"b85e303f418ea094\",\"output\":\"exec\",\"data\":{}}]}},\"position\":[1795.1547936226411,6012.662361553964]},\"d90e74b18631a7e7\":{\"id\":\"d90e74b18631a7e7\",\"name\":\"bitbybit.logic.firstDefinedValueGate\",\"customName\":\"first defined value gate\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false}},\"inputs\":{\"exec\":{\"connections\":[{\"node\":\"0ae184887b347212\",\"output\":\"exec\",\"data\":{}}]},\"value2\":{\"connections\":[{\"node\":\"dc27ec58598933e4\",\"output\":\"result\",\"data\":{}}]},\"value1\":{\"connections\":[{\"node\":\"0ae184887b347212\",\"output\":\"result\",\"data\":{}}]}},\"position\":[1827.0393870782336,6490.834733956343]},\"9ed742a672a607ce\":{\"id\":\"9ed742a672a607ce\",\"name\":\"bitbybit.lists.createList\",\"customName\":\"create list\",\"data\":{},\"inputs\":{\"listElements\":{\"connections\":[{\"node\":\"ffecd6164df0c288\",\"output\":\"result\",\"data\":{}}]},\"exec\":{\"connections\":[{\"node\":\"ffecd6164df0c288\",\"output\":\"exec\",\"data\":{}}]}},\"position\":[2408.212815313349,6050.3207511429555]},\"48046af83dbc9299\":{\"id\":\"48046af83dbc9299\",\"name\":\"bitbybit.lists.createList\",\"customName\":\"create list\",\"data\":{},\"inputs\":{\"listElements\":{\"connections\":[{\"node\":\"d90e74b18631a7e7\",\"output\":\"result\",\"data\":{}}]},\"exec\":{\"connections\":[{\"node\":\"d90e74b18631a7e7\",\"output\":\"exec\",\"data\":{}}]}},\"position\":[2407.3069815807094,6523.841211518347]},\"46f99a9e9cfc9152\":{\"id\":\"46f99a9e9cfc9152\",\"name\":\"bitbybit.text.format\",\"customName\":\"format\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"text\":\"Number Of Rays - {0}\",\"values\":[\"World\"]},\"inputs\":{\"values\":{\"connections\":[{\"node\":\"9ed742a672a607ce\",\"output\":\"list\",\"data\":{}}]},\"exec\":{\"connections\":[{\"node\":\"9ed742a672a607ce\",\"output\":\"exec\",\"data\":{}}]}},\"position\":[2774.3846965928947,5974.2361780617475]},\"ced830dd20fb5b02\":{\"id\":\"ced830dd20fb5b02\",\"name\":\"bitbybit.text.format\",\"customName\":\"format\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"text\":\"Vertical Divsions - {0}\",\"values\":[\"World\"]},\"inputs\":{\"exec\":{\"connections\":[{\"node\":\"48046af83dbc9299\",\"output\":\"exec\",\"data\":{}}]},\"values\":{\"connections\":[{\"node\":\"48046af83dbc9299\",\"output\":\"list\",\"data\":{}}]}},\"position\":[2794.9763891153702,6450.397669292677]},\"af2cb4893a5bc1cb\":{\"id\":\"af2cb4893a5bc1cb\",\"name\":\"bitbybit.babylon.gui.textBlock.setText\",\"customName\":\"set text\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"text\":\"\"},\"inputs\":{\"text\":{\"connections\":[{\"node\":\"46f99a9e9cfc9152\",\"output\":\"result\",\"data\":{}}]},\"exec\":{\"connections\":[{\"node\":\"46f99a9e9cfc9152\",\"output\":\"exec\",\"data\":{}}]},\"textBlock\":{\"connections\":[{\"node\":\"f80263a3d6977ea4\",\"output\":\"result\",\"data\":{}}]}},\"position\":[3408.9286383465733,6175.853417797766]},\"bb5fa4b16d910cb5\":{\"id\":\"bb5fa4b16d910cb5\",\"name\":\"bitbybit.babylon.gui.textBlock.setText\",\"customName\":\"set text\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"text\":\"\"},\"inputs\":{\"textBlock\":{\"connections\":[{\"node\":\"a3006cf7f5041ef6\",\"output\":\"result\",\"data\":{}}]},\"text\":{\"connections\":[{\"node\":\"ced830dd20fb5b02\",\"output\":\"result\",\"data\":{}}]},\"exec\":{\"connections\":[{\"node\":\"ced830dd20fb5b02\",\"output\":\"exec\",\"data\":{}}]}},\"position\":[3443.5303027369487,6538.552534619226]},\"8ecfa2d91d973882\":{\"id\":\"8ecfa2d91d973882\",\"name\":\"bitbybit.babylon.gui.control.createControlObservableSelector\",\"customName\":\"control observable selector\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"selector\":\"onPointerUpObservable\"},\"inputs\":{},\"position\":[112.53197228874697,7216.911800887681]},\"8478c18af95701d2\":{\"id\":\"8478c18af95701d2\",\"name\":\"bitbybit.flow.babylon.observableListener\",\"customName\":\"babylon observable listener\",\"data\":{},\"inputs\":{\"observableSelector\":{\"connections\":[{\"node\":\"8ecfa2d91d973882\",\"output\":\"result\",\"data\":{}}]},\"object\":{\"connections\":[{\"node\":\"dda72ba4bc855075\",\"output\":\"result\",\"data\":{}}]}},\"position\":[666.0061734678349,7042.204203322666]},\"fa5a486b0621317a\":{\"id\":\"fa5a486b0621317a\",\"name\":\"bitbybit.flow.babylon.observableListener\",\"customName\":\"babylon observable listener\",\"data\":{},\"inputs\":{\"observableSelector\":{\"connections\":[{\"node\":\"8ecfa2d91d973882\",\"output\":\"result\",\"data\":{}}]},\"object\":{\"connections\":[{\"node\":\"eb164cb9f2c3d0b2\",\"output\":\"result\",\"data\":{}}]}},\"position\":[667.4427756519425,6826.609623951564]},\"7299a501c8e860c5\":{\"id\":\"7299a501c8e860c5\",\"name\":\"bitbybit.lists.passThrough\",\"customName\":\"pass through\",\"data\":{},\"inputs\":{\"exec\":{\"connections\":[{\"node\":\"fa5a486b0621317a\",\"output\":\"exec\",\"data\":{}},{\"node\":\"8478c18af95701d2\",\"output\":\"exec\",\"data\":{}}]}},\"position\":[6778.4019145441225,6945.999036012015]},\"68fc3da5a920f715\":{\"id\":\"68fc3da5a920f715\",\"name\":\"bitbybit.babylon.scene.adjustActiveArcRotateCamera\",\"customName\":\"adjust active arc rotate camera\",\"async\":false,\"drawable\":false,\"data\":{\"genericNodeData\":{\"hide\":false,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"position\":[10,10,10],\"lookAt\":[0,0,0],\"lowerBetaLimit\":1,\"upperBetaLimit\":179,\"angularSensibilityX\":1000,\"angularSensibilityY\":1000,\"maxZ\":1000,\"panningSensibility\":1000,\"wheelPrecision\":3},\"inputs\":{\"position\":{\"connections\":[{\"node\":\"2c23a73974610198\",\"output\":\"result\",\"data\":{}}]},\"lookAt\":{\"connections\":[{\"node\":\"4b908f56b3ed505c\",\"output\":\"result\",\"data\":{}}]}},\"position\":[2457.6836534900826,-2687.8751308577216]},\"2c23a73974610198\":{\"id\":\"2c23a73974610198\",\"name\":\"bitbybit.vector.vectorXYZ\",\"customName\":\"vector xyz\",\"async\":false,\"drawable\":true,\"data\":{\"genericNodeData\":{\"hide\":true,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"x\":30,\"y\":25,\"z\":0},\"inputs\":{},\"position\":[2028.1960653764377,-2763.197379436671]},\"4b908f56b3ed505c\":{\"id\":\"4b908f56b3ed505c\",\"name\":\"bitbybit.vector.vectorXYZ\",\"customName\":\"vector xyz\",\"async\":false,\"drawable\":true,\"data\":{\"genericNodeData\":{\"hide\":true,\"oneOnOne\":false,\"flatten\":0,\"forceExecution\":false},\"x\":0,\"y\":4,\"z\":0},\"inputs\":{},\"position\":[2033.62438677469,-2317.355175655833]}}}","version":"0.21.1","type":"rete"}} title="Christmas tree ornament" /> diff --git a/docs/learn/code/common/occt/modeling/festive-decor/tree.md b/docs/learn/code/common/occt/modeling/festive-decor/tree.md index bc11ea9c..0ad3ea5d 100644 --- a/docs/learn/code/common/occt/modeling/festive-decor/tree.md +++ b/docs/learn/code/common/occt/modeling/festive-decor/tree.md @@ -28,21 +28,21 @@ Our tree starts with the `createChristmasTreeWire` function, which generates a s heightnrSkirtsthicknesstreeWireoffsetWirereversedWiretreeFacetreeSolidfinalTreedrawnTreeMeshheight8nrSkirts4thickness2treeWireheight1.53nrSkirts11FALSE0000010offsetWiretreeWire-0.20.1reversedWireoffsetWiretreeFacetreeWirereversedWireTRUEtreeSolidtreeFace00thicknessfinalTreetreeSolid00DIVIDENEGthickness2drawnTreeMeshfinalTree0.001Tree Material#ffffff#00ffcc0.80.991FALSE2TRUE#0000001drawnTreeMeshTRUE0.80TRUE","version":"0.21.0","type":"blockly"}} + script={{"script":"heightnrSkirtsthicknesstreeWireoffsetWirereversedWiretreeFacetreeSolidfinalTreedrawnTreeMeshheight8nrSkirts4thickness2treeWireheight1.53nrSkirts11FALSE0000010offsetWiretreeWire-0.20.1reversedWireoffsetWiretreeFacetreeWirereversedWireTRUEtreeSolidtreeFace00thicknessfinalTreetreeSolid00DIVIDENEGthickness2drawnTreeMeshfinalTree0.001Tree Material#ffffff#00ffcc0.80.991FALSE2TRUE#0000001drawnTreeMeshTRUE0.80TRUE","version":"0.21.1","type":"blockly"}} title="Christmas tree ornament" /> {\n // Define control variables\n const height = 6.5;\n const nrSkirts = 5;\n const thickness = 0.5;\n\n // Create PBR material with emissive glow\n const materialOptions = new PBRMetallicRoughnessDto();\n materialOptions.name = \"Tree Material\";\n materialOptions.baseColor = \"#ffffff\";\n materialOptions.emissiveColor = \"#00ffcc\";\n materialOptions.metallic = 0.8;\n materialOptions.roughness = 0.99;\n materialOptions.alpha = 1;\n materialOptions.backFaceCulling = false;\n materialOptions.zOffset = 2;\n const material = bitbybit.babylon.material.pbrMetallicRoughness.create(materialOptions);\n\n // Create the Christmas tree wire\n const treeOptions = new ChristmasTreeDto();\n treeOptions.height = height;\n treeOptions.nrSkirts = nrSkirts;\n treeOptions.innerDist = 1.5;\n treeOptions.outerDist = 3;\n treeOptions.trunkHeight = 1;\n treeOptions.trunkWidth = 1;\n treeOptions.origin = [0, 0, 0];\n treeOptions.direction = [0, 1, 0];\n treeOptions.half = false;\n const treeWire = await wire.createChristmasTreeWire(treeOptions);\n\n // Create offset wire (inner boundary)\n const offsetOptions = new OffsetDto();\n offsetOptions.shape = treeWire;\n offsetOptions.distance = -0.2;\n offsetOptions.tolerance = 0.1;\n const offsetWire = await operations.offset(offsetOptions);\n\n // Reverse the inner wire for proper face creation\n const reversedWire = await wire.reversedWire({ shape: offsetWire });\n\n // Create face from both wires (outer and reversed inner)\n const faceOptions = new FaceFromWiresDto();\n faceOptions.shapes = [treeWire, reversedWire];\n faceOptions.planar = true;\n const treeFace = await face.createFaceFromWires(faceOptions);\n\n // Extrude the face to create thickness\n const extrudeOptions = new ExtrudeDto();\n extrudeOptions.shape = treeFace;\n extrudeOptions.direction = [0, 0, thickness];\n const treeSolid = await operations.extrude(extrudeOptions);\n\n // Translate to center the shape\n const translateOptions = new TranslateDto();\n translateOptions.shape = treeSolid;\n translateOptions.translation = [0, 0, -thickness / 2];\n const finalTree = await transforms.translate(translateOptions);\n\n // Draw with custom material and edge styling\n const drawOptions = new Bit.Inputs.Draw.DrawOcctShapeOptions();\n drawOptions.precision = 0.001;\n drawOptions.drawEdges = true;\n drawOptions.edgeColour = \"#000000\";\n drawOptions.edgeWidth = 1;\n drawOptions.faceMaterial = material;\n\n const drawnTreeMesh = await bitbybit.draw.drawAnyAsync({\n entity: finalTree,\n options: drawOptions\n });\n\n const zoomOptions = new ZoomOnDto([drawnTreeMesh]);\n bitbybit.advanced.navigation.zoomOn(zoomOptions);\n}\n\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"const { ChristmasTreeDto, OffsetDto, FaceFromWiresDto, ExtrudeDto, TranslateDto } = Bit.Inputs.OCCT;\nconst { PBRMetallicRoughnessDto } = Bit.Inputs.BabylonMaterial;\nconst { ZoomOnDto } = Bit.Advanced.Navigation;\n\ntype TopoDSWirePointer = Bit.Inputs.OCCT.TopoDSWirePointer;\ntype TopoDSFacePointer = Bit.Inputs.OCCT.TopoDSFacePointer;\ntype TopoDSShapePointer = Bit.Inputs.OCCT.TopoDSShapePointer;\n\nconst { wire, face } = bitbybit.occt.shapes;\nconst { operations, transforms } = bitbybit.occt;\n\nconst start = async () => {\n // Define control variables\n const height = 6.5;\n const nrSkirts = 5;\n const thickness = 0.5;\n\n // Create PBR material with emissive glow\n const materialOptions = new PBRMetallicRoughnessDto();\n materialOptions.name = \"Tree Material\";\n materialOptions.baseColor = \"#ffffff\";\n materialOptions.emissiveColor = \"#00ffcc\";\n materialOptions.metallic = 0.8;\n materialOptions.roughness = 0.99;\n materialOptions.alpha = 1;\n materialOptions.backFaceCulling = false;\n materialOptions.zOffset = 2;\n const material = bitbybit.babylon.material.pbrMetallicRoughness.create(materialOptions);\n\n // Create the Christmas tree wire\n const treeOptions = new ChristmasTreeDto();\n treeOptions.height = height;\n treeOptions.nrSkirts = nrSkirts;\n treeOptions.innerDist = 1.5;\n treeOptions.outerDist = 3;\n treeOptions.trunkHeight = 1;\n treeOptions.trunkWidth = 1;\n treeOptions.origin = [0, 0, 0];\n treeOptions.direction = [0, 1, 0];\n treeOptions.half = false;\n const treeWire = await wire.createChristmasTreeWire(treeOptions);\n\n // Create offset wire (inner boundary)\n const offsetOptions = new OffsetDto();\n offsetOptions.shape = treeWire;\n offsetOptions.distance = -0.2;\n offsetOptions.tolerance = 0.1;\n const offsetWire = await operations.offset(offsetOptions);\n\n // Reverse the inner wire for proper face creation\n const reversedWire = await wire.reversedWire({ shape: offsetWire });\n\n // Create face from both wires (outer and reversed inner)\n const faceOptions = new FaceFromWiresDto();\n faceOptions.shapes = [treeWire, reversedWire];\n faceOptions.planar = true;\n const treeFace = await face.createFaceFromWires(faceOptions);\n\n // Extrude the face to create thickness\n const extrudeOptions = new ExtrudeDto();\n extrudeOptions.shape = treeFace;\n extrudeOptions.direction = [0, 0, thickness];\n const treeSolid = await operations.extrude(extrudeOptions);\n\n // Translate to center the shape\n const translateOptions = new TranslateDto();\n translateOptions.shape = treeSolid;\n translateOptions.translation = [0, 0, -thickness / 2];\n const finalTree = await transforms.translate(translateOptions);\n\n // Draw with custom material and edge styling\n const drawOptions = new Bit.Inputs.Draw.DrawOcctShapeOptions();\n drawOptions.precision = 0.001;\n drawOptions.drawEdges = true;\n drawOptions.edgeColour = \"#000000\";\n drawOptions.edgeWidth = 1;\n drawOptions.faceMaterial = material;\n\n const drawnTreeMesh = await bitbybit.draw.drawAnyAsync({\n entity: finalTree,\n options: drawOptions\n });\n\n const zoomOptions = new ZoomOnDto([drawnTreeMesh]);\n bitbybit.advanced.navigation.zoomOn(zoomOptions);\n}\n\nstart();","version":"0.21.1","type":"typescript"}} title="Christmas tree ornament" /> diff --git a/docs/learn/code/common/occt/modeling/festive-decor/twisted-polygon-ornament.md b/docs/learn/code/common/occt/modeling/festive-decor/twisted-polygon-ornament.md index 95a0aaea..62ddd1e1 100644 --- a/docs/learn/code/common/occt/modeling/festive-decor/twisted-polygon-ornament.md +++ b/docs/learn/code/common/occt/modeling/festive-decor/twisted-polygon-ornament.md @@ -22,21 +22,21 @@ Create an elegant twisted ornament by systematically rotating and scaling hexago nrCornerswire1wire2wire3wire4list1list2ianglefactortempShapefinalListitemloftShapeunifiedShape'city'10000.230.7TRUEnrCorners6wire1000010nrCorners1wire200.10010nrCorners1wire300.20010nrCorners1wire400.30010nrCorners1list1list2i0101angleMULTIPLYi9factorADDi1tempShapewire1001angletempShapetempShapefactorINSERTLASTlist1tempShapetempShapewire2001angletempShapetempShapefactorINSERTLASTlist1tempShapetempShapewire4001angletempShapetempShapefactorINSERTLASTlist2tempShapetempShapewire3001angletempShapetempShapefactorINSERTLASTlist2tempShapelist1list1TRUElist2list2TRUETRUEfinalListitemlist2INSERTLASTfinalListitemitemlist1INSERTLASTfinalListitemfinalListfinalListTRUEloftShapefinalListFALSETRUEFALSETRUE10FALSE31e-7approxCentripetalunifiedShapeloftShapeTRUETRUETRUEunifiedShape0.01Custom Material#94ffd1#0000000.90.31FALSE2TRUE#ffffff2","version":"0.21.0","type":"blockly"}} + script={{"script":"nrCornerswire1wire2wire3wire4list1list2ianglefactortempShapefinalListitemloftShapeunifiedShape'city'10000.230.7TRUEnrCorners6wire1000010nrCorners1wire200.10010nrCorners1wire300.20010nrCorners1wire400.30010nrCorners1list1list2i0101angleMULTIPLYi9factorADDi1tempShapewire1001angletempShapetempShapefactorINSERTLASTlist1tempShapetempShapewire2001angletempShapetempShapefactorINSERTLASTlist1tempShapetempShapewire4001angletempShapetempShapefactorINSERTLASTlist2tempShapetempShapewire3001angletempShapetempShapefactorINSERTLASTlist2tempShapelist1list1TRUElist2list2TRUETRUEfinalListitemlist2INSERTLASTfinalListitemitemlist1INSERTLASTfinalListitemfinalListfinalListTRUEloftShapefinalListFALSETRUEFALSETRUE10FALSE31e-7approxCentripetalunifiedShapeloftShapeTRUETRUETRUEunifiedShape0.01Custom Material#94ffd1#0000000.90.31FALSE2TRUE#ffffff2","version":"0.21.1","type":"blockly"}} title="Twisted Polygon Ornament" /> {\n\n const skyboxOpt = new SkyboxDto();\n skyboxOpt.skybox = skyboxEnum.city;\n skyboxOpt.hideSkybox = true;\n bitbybit.babylon.scene.enableSkybox(skyboxOpt);\n\n const nrCorners = 6;\n\n // 1. Create Base Wires\n const ngonDto = new NGonWireDto();\n ngonDto.nrCorners = nrCorners;\n ngonDto.direction = [0, 1, 0];\n ngonDto.radius = 1;\n\n ngonDto.center = [0, 0, 0];\n const wire1 = await wire.createNGonWire(ngonDto);\n\n ngonDto.center = [0, 0.1, 0];\n const wire2 = await wire.createNGonWire(ngonDto);\n\n ngonDto.center = [0, 0.2, 0];\n const wire3 = await wire.createNGonWire(ngonDto);\n\n ngonDto.center = [0, 0.3, 0];\n const wire4 = await wire.createNGonWire(ngonDto);\n\n // 2. Generate Lists of Transformed Wires\n const list1: TopoDSShapePointer[] = [];\n const list2: TopoDSShapePointer[] = [];\n\n for (let i = 0; i <= 10; i++) {\n const angle = i * 9;\n const factor = i + 1;\n\n // Helper to rotate and scale\n const transform = async (w: TopoDSShapePointer) => {\n const rotDto = new RotateDto();\n rotDto.shape = w;\n rotDto.axis = [0, 0, 1];\n rotDto.angle = angle;\n const rotated = await transforms.rotate(rotDto);\n\n const scaleDto = new ScaleDto();\n scaleDto.shape = rotated;\n scaleDto.factor = factor;\n return await transforms.scale(scaleDto);\n };\n\n list1.push(await transform(wire1));\n list1.push(await transform(wire2));\n list2.push(await transform(wire3));\n list2.push(await transform(wire4));\n }\n\n // 3. Process Lists\n // Remove first item from list1\n list1.shift();\n // Reverse list2 and remove last item\n list2.reverse();\n list2.shift();\n list2.pop();\n\n // 4. Merge and Reverse Final List\n // Merge: list2 items then list1 items\n let finalList = [...list2, ...list1];\n\n // Reverse the final list for the loft direction\n finalList.reverse();\n\n // 5. Loft\n const loftDto = new LoftAdvancedDto();\n loftDto.shapes = finalList;\n loftDto.makeSolid = false;\n loftDto.closed = true;\n loftDto.periodic = false;\n loftDto.straight = true;\n loftDto.nrPeriodicSections = 10;\n loftDto.useSmoothing = false;\n loftDto.maxUDegree = 3;\n loftDto.tolerance = 1e-7;\n loftDto.parType = approxParametrizationTypeEnum.approxCentripetal;\n const loftShape = await operations.loftAdvanced(loftDto);\n\n // 6. Unify Domain\n const unifyDto = new UnifySameDomainDto();\n unifyDto.shape = loftShape;\n unifyDto.unifyEdges = true;\n unifyDto.unifyFaces = true;\n unifyDto.concatBSplines = true;\n const unifiedShape = await shape.unifySameDomain(unifyDto);\n\n // 7. Draw\n const materialOptions = new PBRMetallicRoughnessDto();\n materialOptions.name = 'Custom Material';\n materialOptions.baseColor = '#94ffd1';\n materialOptions.emissiveColor = '#000000';\n materialOptions.metallic = 0.9;\n materialOptions.roughness = 0.3;\n materialOptions.alpha = 1;\n materialOptions.backFaceCulling = false;\n materialOptions.zOffset = 2;\n const material = bitbybit.babylon.material.pbrMetallicRoughness.create(materialOptions);\n\n const drawOptions = new DrawOcctShapeOptions();\n drawOptions.precision = 0.01;\n drawOptions.drawEdges = true;\n drawOptions.edgeColour = '#ffffff';\n drawOptions.edgeWidth = 2;\n drawOptions.faceMaterial = material;\n\n const drawnMesh = await bitbybit.draw.drawAnyAsync({\n entity: unifiedShape,\n options: drawOptions,\n });\n\n const zoomDto = new ZoomOnDto();\n zoomDto.meshes = [drawnMesh];\n bitbybit.advanced.navigation.zoomOn(zoomDto);\n};\n\nstart();","version":"0.21.0","type":"typescript"}} +script={{"script":"const { NGonWireDto, RotateDto, ScaleDto, LoftAdvancedDto, UnifySameDomainDto } = Bit.Inputs.OCCT;\nconst { PBRMetallicRoughnessDto } = Bit.Inputs.BabylonMaterial;\nconst { SkyboxDto } = Bit.Inputs.BabylonScene;\nconst { DrawOcctShapeOptions } = Bit.Inputs.Draw;\nconst { skyboxEnum } = Bit.Inputs.Base;\nconst { ZoomOnDto } = Bit.Advanced.Navigation;\nconst { approxParametrizationTypeEnum } = Bit.Inputs.OCCT;\ntype TopoDSShapePointer = Bit.Inputs.OCCT.TopoDSShapePointer;\n\nconst { wire, shape } = bitbybit.occt.shapes;\nconst { operations, transforms } = bitbybit.occt;\n\nconst start = async () => {\n\n const skyboxOpt = new SkyboxDto();\n skyboxOpt.skybox = skyboxEnum.city;\n skyboxOpt.hideSkybox = true;\n bitbybit.babylon.scene.enableSkybox(skyboxOpt);\n\n const nrCorners = 6;\n\n // 1. Create Base Wires\n const ngonDto = new NGonWireDto();\n ngonDto.nrCorners = nrCorners;\n ngonDto.direction = [0, 1, 0];\n ngonDto.radius = 1;\n\n ngonDto.center = [0, 0, 0];\n const wire1 = await wire.createNGonWire(ngonDto);\n\n ngonDto.center = [0, 0.1, 0];\n const wire2 = await wire.createNGonWire(ngonDto);\n\n ngonDto.center = [0, 0.2, 0];\n const wire3 = await wire.createNGonWire(ngonDto);\n\n ngonDto.center = [0, 0.3, 0];\n const wire4 = await wire.createNGonWire(ngonDto);\n\n // 2. Generate Lists of Transformed Wires\n const list1: TopoDSShapePointer[] = [];\n const list2: TopoDSShapePointer[] = [];\n\n for (let i = 0; i <= 10; i++) {\n const angle = i * 9;\n const factor = i + 1;\n\n // Helper to rotate and scale\n const transform = async (w: TopoDSShapePointer) => {\n const rotDto = new RotateDto();\n rotDto.shape = w;\n rotDto.axis = [0, 0, 1];\n rotDto.angle = angle;\n const rotated = await transforms.rotate(rotDto);\n\n const scaleDto = new ScaleDto();\n scaleDto.shape = rotated;\n scaleDto.factor = factor;\n return await transforms.scale(scaleDto);\n };\n\n list1.push(await transform(wire1));\n list1.push(await transform(wire2));\n list2.push(await transform(wire3));\n list2.push(await transform(wire4));\n }\n\n // 3. Process Lists\n // Remove first item from list1\n list1.shift();\n // Reverse list2 and remove last item\n list2.reverse();\n list2.shift();\n list2.pop();\n\n // 4. Merge and Reverse Final List\n // Merge: list2 items then list1 items\n let finalList = [...list2, ...list1];\n\n // Reverse the final list for the loft direction\n finalList.reverse();\n\n // 5. Loft\n const loftDto = new LoftAdvancedDto();\n loftDto.shapes = finalList;\n loftDto.makeSolid = false;\n loftDto.closed = true;\n loftDto.periodic = false;\n loftDto.straight = true;\n loftDto.nrPeriodicSections = 10;\n loftDto.useSmoothing = false;\n loftDto.maxUDegree = 3;\n loftDto.tolerance = 1e-7;\n loftDto.parType = approxParametrizationTypeEnum.approxCentripetal;\n const loftShape = await operations.loftAdvanced(loftDto);\n\n // 6. Unify Domain\n const unifyDto = new UnifySameDomainDto();\n unifyDto.shape = loftShape;\n unifyDto.unifyEdges = true;\n unifyDto.unifyFaces = true;\n unifyDto.concatBSplines = true;\n const unifiedShape = await shape.unifySameDomain(unifyDto);\n\n // 7. Draw\n const materialOptions = new PBRMetallicRoughnessDto();\n materialOptions.name = 'Custom Material';\n materialOptions.baseColor = '#94ffd1';\n materialOptions.emissiveColor = '#000000';\n materialOptions.metallic = 0.9;\n materialOptions.roughness = 0.3;\n materialOptions.alpha = 1;\n materialOptions.backFaceCulling = false;\n materialOptions.zOffset = 2;\n const material = bitbybit.babylon.material.pbrMetallicRoughness.create(materialOptions);\n\n const drawOptions = new DrawOcctShapeOptions();\n drawOptions.precision = 0.01;\n drawOptions.drawEdges = true;\n drawOptions.edgeColour = '#ffffff';\n drawOptions.edgeWidth = 2;\n drawOptions.faceMaterial = material;\n\n const drawnMesh = await bitbybit.draw.drawAnyAsync({\n entity: unifiedShape,\n options: drawOptions,\n });\n\n const zoomDto = new ZoomOnDto();\n zoomDto.meshes = [drawnMesh];\n bitbybit.advanced.navigation.zoomOn(zoomDto);\n};\n\nstart();","version":"0.21.1","type":"typescript"}} title="Twisted Polygon Ornament" /> diff --git a/docs/learn/code/common/occt/modeling/hollow-shapes/hexagon-hive-flat.md b/docs/learn/code/common/occt/modeling/hollow-shapes/hexagon-hive-flat.md index 7b1fcd98..4c154145 100644 --- a/docs/learn/code/common/occt/modeling/hollow-shapes/hexagon-hive-flat.md +++ b/docs/learn/code/common/occt/modeling/hollow-shapes/hexagon-hive-flat.md @@ -22,21 +22,21 @@ Flat hexagon hive construction creates optimized honeycomb panels by treating th widthheightnrHexWidthnrHexHeightwiresHexLargewiresHexSmallrandomHeightshexagonFacesiwidth10height20nrHexWidth10nrHexHeight20wiresHexLargewidthheightnrHexWidthnrHexHeightFALSEFALSEFALSEFALSEFALSEwiresHexSmallwidthheightnrHexWidthnrHexHeightFALSEFALSEFALSEFALSEFALSE0.70.7randomHeights12wiresHexLargehexagonFacesi1wiresHexLarge1INSERTLASThexagonFacesGETFROM_STARTwiresHexLargeiGETFROM_STARTwiresHexSmalliTRUEhexagonFaces1e-7TRUETRUETRUE010","version":"0.21.0","type":"blockly"}} + script={{"script":"widthheightnrHexWidthnrHexHeightwiresHexLargewiresHexSmallrandomHeightshexagonFacesiwidth10height20nrHexWidth10nrHexHeight20wiresHexLargewidthheightnrHexWidthnrHexHeightFALSEFALSEFALSEFALSEFALSEwiresHexSmallwidthheightnrHexWidthnrHexHeightFALSEFALSEFALSEFALSEFALSE0.70.7randomHeights12wiresHexLargehexagonFacesi1wiresHexLarge1INSERTLASThexagonFacesGETFROM_STARTwiresHexLargeiGETFROM_STARTwiresHexSmalliTRUEhexagonFaces1e-7TRUETRUETRUE010","version":"0.21.1","type":"blockly"}} title="Hexagon hive" /> {\n // Create hexagonal grid parameters\n const gridWidth = 10;\n const gridHeight = 20;\n const hexagonsInWidth = 10;\n const hexagonsInHeight = 20;\n\n // Generate large hexagonal wire grid (outer walls)\n const hexGridLargeOptions = new HexagonsInGridDto();\n hexGridLargeOptions.width = gridWidth;\n hexGridLargeOptions.height = gridHeight;\n hexGridLargeOptions.nrHexagonsInWidth = hexagonsInWidth;\n hexGridLargeOptions.nrHexagonsInHeight = hexagonsInHeight;\n hexGridLargeOptions.flatTop = false;\n hexGridLargeOptions.extendTop = false;\n hexGridLargeOptions.extendBottom = false;\n hexGridLargeOptions.extendLeft = false;\n hexGridLargeOptions.extendRight = false;\n\n const wiresHexLarge = await wire.hexagonsInGrid(hexGridLargeOptions);\n\n // Generate small hexagonal wire grid (inner holes)\n const hexGridSmallOptions = new HexagonsInGridDto();\n hexGridSmallOptions.width = gridWidth;\n hexGridSmallOptions.height = gridHeight;\n hexGridSmallOptions.nrHexagonsInWidth = hexagonsInWidth;\n hexGridSmallOptions.nrHexagonsInHeight = hexagonsInHeight;\n hexGridSmallOptions.flatTop = false;\n hexGridSmallOptions.extendTop = false;\n hexGridSmallOptions.extendBottom = false;\n hexGridSmallOptions.extendLeft = false;\n hexGridSmallOptions.extendRight = false;\n hexGridSmallOptions.scalePatternWidth = [0.7];\n hexGridSmallOptions.scalePatternHeight = [0.7];\n\n const wiresHexSmall = await wire.hexagonsInGrid(hexGridSmallOptions);\n\n // Generate random heights for creating individual faces\n const randomHeights = math.randomNumbers({\n low: 1,\n high: 2,\n count: wiresHexLarge.length\n });\n\n // Create faces with holes for each hexagon cell\n const hexagonFaces: TopoDSFacePointer[] = [];\n for (let i = 0; i < wiresHexLarge.length; i++) {\n // Get the outer and inner wires for this cell\n const outerWire = wiresHexLarge[i];\n const innerWire = wiresHexSmall[i];\n\n // Reverse the inner wire to create a hole\n const reverseOptions = new ShapeDto();\n reverseOptions.shape = innerWire;\n const reversedInnerWire = await wire.reversedWire(reverseOptions);\n\n // Create face with hole\n const faceOptions = new FaceFromWiresDto();\n faceOptions.shapes = [outerWire, reversedInnerWire];\n faceOptions.planar = true;\n const hexFaceWithHole = await face.createFaceFromWires(faceOptions);\n\n hexagonFaces.push(hexFaceWithHole);\n }\n\n // Sew faces together\n const sewOptions = new SewDto(hexagonFaces);\n sewOptions.tolerance = 1e-7;\n const sewedFaces = await shell.sewFaces(sewOptions);\n\n // Unify same domain for cleaner geometry\n const unifyOptions = new UnifySameDomainDto();\n unifyOptions.shape = sewedFaces;\n unifyOptions.unifyEdges = true;\n unifyOptions.unifyFaces = true;\n unifyOptions.concatBSplines = true;\n const unifiedShape = await shape.unifySameDomain(unifyOptions);\n\n // Extrude the unified shape\n const extrudeOptions = new ExtrudeDto();\n extrudeOptions.shape = unifiedShape;\n extrudeOptions.direction = [0, 1, 0];\n const extrudedHive = await operations.extrude(extrudeOptions);\n\n // Draw the resulting flat hive structure\n bitbybit.draw.drawAnyAsync({\n entity: extrudedHive\n });\n}\n\n// Execute the function\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"// Import required DTOs for hexagon grid creation and operations\nconst { HexagonsInGridDto, FaceFromWiresDto, ExtrudeDto, ShapesDto, SewDto, UnifySameDomainDto, ShapeDto } = Bit.Inputs.OCCT;\n// Import type definitions for type safety\ntype TopoDSWirePointer = Bit.Inputs.OCCT.TopoDSWirePointer;\ntype TopoDSFacePointer = Bit.Inputs.OCCT.TopoDSFacePointer;\ntype TopoDSShellPointer = Bit.Inputs.OCCT.TopoDSShellPointer;\ntype TopoDSSolidPointer = Bit.Inputs.OCCT.TopoDSSolidPointer;\n\n// Get access to OCCT modules and utilities\nconst { wire, face, shell, shape } = bitbybit.occt.shapes;\nconst { operations } = bitbybit.occt;\nconst { math } = bitbybit;\n\n// Define the main function to create a flat hexagon hive\nconst start = async () => {\n // Create hexagonal grid parameters\n const gridWidth = 10;\n const gridHeight = 20;\n const hexagonsInWidth = 10;\n const hexagonsInHeight = 20;\n\n // Generate large hexagonal wire grid (outer walls)\n const hexGridLargeOptions = new HexagonsInGridDto();\n hexGridLargeOptions.width = gridWidth;\n hexGridLargeOptions.height = gridHeight;\n hexGridLargeOptions.nrHexagonsInWidth = hexagonsInWidth;\n hexGridLargeOptions.nrHexagonsInHeight = hexagonsInHeight;\n hexGridLargeOptions.flatTop = false;\n hexGridLargeOptions.extendTop = false;\n hexGridLargeOptions.extendBottom = false;\n hexGridLargeOptions.extendLeft = false;\n hexGridLargeOptions.extendRight = false;\n\n const wiresHexLarge = await wire.hexagonsInGrid(hexGridLargeOptions);\n\n // Generate small hexagonal wire grid (inner holes)\n const hexGridSmallOptions = new HexagonsInGridDto();\n hexGridSmallOptions.width = gridWidth;\n hexGridSmallOptions.height = gridHeight;\n hexGridSmallOptions.nrHexagonsInWidth = hexagonsInWidth;\n hexGridSmallOptions.nrHexagonsInHeight = hexagonsInHeight;\n hexGridSmallOptions.flatTop = false;\n hexGridSmallOptions.extendTop = false;\n hexGridSmallOptions.extendBottom = false;\n hexGridSmallOptions.extendLeft = false;\n hexGridSmallOptions.extendRight = false;\n hexGridSmallOptions.scalePatternWidth = [0.7];\n hexGridSmallOptions.scalePatternHeight = [0.7];\n\n const wiresHexSmall = await wire.hexagonsInGrid(hexGridSmallOptions);\n\n // Generate random heights for creating individual faces\n const randomHeights = math.randomNumbers({\n low: 1,\n high: 2,\n count: wiresHexLarge.length\n });\n\n // Create faces with holes for each hexagon cell\n const hexagonFaces: TopoDSFacePointer[] = [];\n for (let i = 0; i < wiresHexLarge.length; i++) {\n // Get the outer and inner wires for this cell\n const outerWire = wiresHexLarge[i];\n const innerWire = wiresHexSmall[i];\n\n // Reverse the inner wire to create a hole\n const reverseOptions = new ShapeDto();\n reverseOptions.shape = innerWire;\n const reversedInnerWire = await wire.reversedWire(reverseOptions);\n\n // Create face with hole\n const faceOptions = new FaceFromWiresDto();\n faceOptions.shapes = [outerWire, reversedInnerWire];\n faceOptions.planar = true;\n const hexFaceWithHole = await face.createFaceFromWires(faceOptions);\n\n hexagonFaces.push(hexFaceWithHole);\n }\n\n // Sew faces together\n const sewOptions = new SewDto(hexagonFaces);\n sewOptions.tolerance = 1e-7;\n const sewedFaces = await shell.sewFaces(sewOptions);\n\n // Unify same domain for cleaner geometry\n const unifyOptions = new UnifySameDomainDto();\n unifyOptions.shape = sewedFaces;\n unifyOptions.unifyEdges = true;\n unifyOptions.unifyFaces = true;\n unifyOptions.concatBSplines = true;\n const unifiedShape = await shape.unifySameDomain(unifyOptions);\n\n // Extrude the unified shape\n const extrudeOptions = new ExtrudeDto();\n extrudeOptions.shape = unifiedShape;\n extrudeOptions.direction = [0, 1, 0];\n const extrudedHive = await operations.extrude(extrudeOptions);\n\n // Draw the resulting flat hive structure\n bitbybit.draw.drawAnyAsync({\n entity: extrudedHive\n });\n}\n\n// Execute the function\nstart();","version":"0.21.1","type":"typescript"}} title="Hexagon hive" /> diff --git a/docs/learn/code/common/occt/modeling/hollow-shapes/hexagon-hive.md b/docs/learn/code/common/occt/modeling/hollow-shapes/hexagon-hive.md index 62b6f954..cba5b355 100644 --- a/docs/learn/code/common/occt/modeling/hollow-shapes/hexagon-hive.md +++ b/docs/learn/code/common/occt/modeling/hollow-shapes/hexagon-hive.md @@ -22,21 +22,21 @@ Moving beyond simple perforated patterns, three-dimensional hive structures crea widthheightnrHexWidthnrHexHeightwiresHexLargewiresHexSmallrandomHeightshexagons3DicompoundShapeForFastRenderingwidth10height20nrHexWidth10nrHexHeight20wiresHexLargewidthheightnrHexWidthnrHexHeightFALSEFALSEFALSEFALSEFALSEwiresHexSmallwidthheightnrHexWidthnrHexHeightFALSEFALSEFALSEFALSEFALSE0.80.8randomHeights12wiresHexLargehexagons3Di1wiresHexLarge1INSERTLASThexagons3DGETFROM_STARTwiresHexLargeiGETFROM_STARTwiresHexSmalliTRUE0GETFROM_STARTrandomHeightsi0compoundShapeForFastRenderinghexagons3DcompoundShapeForFastRendering","version":"0.21.0","type":"blockly"}} + script={{"script":"widthheightnrHexWidthnrHexHeightwiresHexLargewiresHexSmallrandomHeightshexagons3DicompoundShapeForFastRenderingwidth10height20nrHexWidth10nrHexHeight20wiresHexLargewidthheightnrHexWidthnrHexHeightFALSEFALSEFALSEFALSEFALSEwiresHexSmallwidthheightnrHexWidthnrHexHeightFALSEFALSEFALSEFALSEFALSE0.80.8randomHeights12wiresHexLargehexagons3Di1wiresHexLarge1INSERTLASThexagons3DGETFROM_STARTwiresHexLargeiGETFROM_STARTwiresHexSmalliTRUE0GETFROM_STARTrandomHeightsi0compoundShapeForFastRenderinghexagons3DcompoundShapeForFastRendering","version":"0.21.1","type":"blockly"}} title="Hexagon hive" /> {\n // Create hexagonal grid parameters\n const gridWidth = 10;\n const gridHeight = 20;\n const hexagonsInWidth = 10;\n const hexagonsInHeight = 20;\n\n // Generate large hexagonal wire grid (outer walls)\n const hexGridLargeOptions = new HexagonsInGridDto();\n hexGridLargeOptions.width = gridWidth;\n hexGridLargeOptions.height = gridHeight;\n hexGridLargeOptions.nrHexagonsInWidth = hexagonsInWidth;\n hexGridLargeOptions.nrHexagonsInHeight = hexagonsInHeight;\n\n const wiresHexLarge = await wire.hexagonsInGrid(hexGridLargeOptions);\n\n // Generate small hexagonal wire grid (inner holes)\n const hexGridSmallOptions = new HexagonsInGridDto();\n hexGridSmallOptions.width = gridWidth;\n hexGridSmallOptions.height = gridHeight;\n hexGridSmallOptions.nrHexagonsInWidth = hexagonsInWidth;\n hexGridSmallOptions.nrHexagonsInHeight = hexagonsInHeight;\n hexGridSmallOptions.scalePatternWidth = [0.8];\n hexGridSmallOptions.scalePatternHeight = [0.8];\n\n const wiresHexSmall = await wire.hexagonsInGrid(hexGridSmallOptions);\n\n // Generate random heights for each hexagon cell\n const randomHeights = math.randomNumbers({\n low: 1,\n high: 2,\n count: wiresHexLarge.length\n });\n\n // Process each hexagon to create 3D cells with holes\n const hexagons3D: TopoDSSolidPointer[] = [];\n\n for (let i = 0; i < wiresHexLarge.length; i++) {\n // Get the outer and inner wires for this cell\n const outerWire = wiresHexLarge[i];\n const innerWire = wiresHexSmall[i];\n\n // Reverse the inner wire to create a hole\n const reverseOptions = new ShapeDto();\n reverseOptions.shape = innerWire;\n const reversedInnerWire = await wire.reversedWire(reverseOptions);\n\n // Create face with hole\n const faceOptions = new FaceFromWiresDto();\n faceOptions.shapes = [outerWire, reversedInnerWire];\n faceOptions.planar = true;\n const hexFaceWithHole = await face.createFaceFromWires(faceOptions);\n\n // Extrude the face with random height\n const extrudeOptions = new ExtrudeDto();\n extrudeOptions.shape = hexFaceWithHole;\n extrudeOptions.direction = [0, randomHeights[i], 0];\n\n const extrudedCell = await operations.extrude(extrudeOptions);\n hexagons3D.push(extrudedCell);\n }\n\n // Combine all extruded cells into a compound shape for fast rendering\n const compoundOptions = new CompoundShapesDto();\n compoundOptions.shapes = hexagons3D;\n const compoundShapeForFastRendering = await compound.makeCompound(compoundOptions);\n\n // Draw the resulting three-dimensional hive structure\n bitbybit.draw.drawAnyAsync({\n entity: compoundShapeForFastRendering\n });\n}\n\n// Execute the function\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"// Import required DTOs for hexagon grid creation and operations\nconst { HexagonsInGridDto, FaceFromWiresDto, ExtrudeDto, CompoundShapesDto, ShapeDto } = Bit.Inputs.OCCT;\n// Import type definitions for type safety\ntype TopoDSWirePointer = Bit.Inputs.OCCT.TopoDSWirePointer;\ntype TopoDSFacePointer = Bit.Inputs.OCCT.TopoDSFacePointer;\ntype TopoDSSolidPointer = Bit.Inputs.OCCT.TopoDSSolidPointer;\n\n// Get access to OCCT modules and utilities\nconst { wire, face, compound } = bitbybit.occt.shapes;\nconst { operations } = bitbybit.occt;\nconst { math } = bitbybit;\n\n// Define the main function to create a three-dimensional hexagon hive\nconst start = async () => {\n // Create hexagonal grid parameters\n const gridWidth = 10;\n const gridHeight = 20;\n const hexagonsInWidth = 10;\n const hexagonsInHeight = 20;\n\n // Generate large hexagonal wire grid (outer walls)\n const hexGridLargeOptions = new HexagonsInGridDto();\n hexGridLargeOptions.width = gridWidth;\n hexGridLargeOptions.height = gridHeight;\n hexGridLargeOptions.nrHexagonsInWidth = hexagonsInWidth;\n hexGridLargeOptions.nrHexagonsInHeight = hexagonsInHeight;\n\n const wiresHexLarge = await wire.hexagonsInGrid(hexGridLargeOptions);\n\n // Generate small hexagonal wire grid (inner holes)\n const hexGridSmallOptions = new HexagonsInGridDto();\n hexGridSmallOptions.width = gridWidth;\n hexGridSmallOptions.height = gridHeight;\n hexGridSmallOptions.nrHexagonsInWidth = hexagonsInWidth;\n hexGridSmallOptions.nrHexagonsInHeight = hexagonsInHeight;\n hexGridSmallOptions.scalePatternWidth = [0.8];\n hexGridSmallOptions.scalePatternHeight = [0.8];\n\n const wiresHexSmall = await wire.hexagonsInGrid(hexGridSmallOptions);\n\n // Generate random heights for each hexagon cell\n const randomHeights = math.randomNumbers({\n low: 1,\n high: 2,\n count: wiresHexLarge.length\n });\n\n // Process each hexagon to create 3D cells with holes\n const hexagons3D: TopoDSSolidPointer[] = [];\n\n for (let i = 0; i < wiresHexLarge.length; i++) {\n // Get the outer and inner wires for this cell\n const outerWire = wiresHexLarge[i];\n const innerWire = wiresHexSmall[i];\n\n // Reverse the inner wire to create a hole\n const reverseOptions = new ShapeDto();\n reverseOptions.shape = innerWire;\n const reversedInnerWire = await wire.reversedWire(reverseOptions);\n\n // Create face with hole\n const faceOptions = new FaceFromWiresDto();\n faceOptions.shapes = [outerWire, reversedInnerWire];\n faceOptions.planar = true;\n const hexFaceWithHole = await face.createFaceFromWires(faceOptions);\n\n // Extrude the face with random height\n const extrudeOptions = new ExtrudeDto();\n extrudeOptions.shape = hexFaceWithHole;\n extrudeOptions.direction = [0, randomHeights[i], 0];\n\n const extrudedCell = await operations.extrude(extrudeOptions);\n hexagons3D.push(extrudedCell);\n }\n\n // Combine all extruded cells into a compound shape for fast rendering\n const compoundOptions = new CompoundShapesDto();\n compoundOptions.shapes = hexagons3D;\n const compoundShapeForFastRendering = await compound.makeCompound(compoundOptions);\n\n // Draw the resulting three-dimensional hive structure\n bitbybit.draw.drawAnyAsync({\n entity: compoundShapeForFastRendering\n });\n}\n\n// Execute the function\nstart();","version":"0.21.1","type":"typescript"}} title="Hexagon hive" /> diff --git a/docs/learn/code/common/occt/modeling/hollow-shapes/hexagon-holes-on-face.md b/docs/learn/code/common/occt/modeling/hollow-shapes/hexagon-holes-on-face.md index 7277fa02..6409704a 100644 --- a/docs/learn/code/common/occt/modeling/hollow-shapes/hexagon-holes-on-face.md +++ b/docs/learn/code/common/occt/modeling/hollow-shapes/hexagon-holes-on-face.md @@ -22,21 +22,21 @@ Hexagonal patterns are found throughout nature - from honeycomb structures to cr recFacefacesrecFace2014000010facesrecFace1010[0.9][0.9]FALSEFALSE0.010.01GETFIRSTfaces010","version":"0.21.0","type":"blockly"}} + script={{"script":"recFacefacesrecFace2014000010facesrecFace1010[0.9][0.9]FALSEFALSE0.010.01GETFIRSTfaces010","version":"0.21.1","type":"blockly"}} title="Hexagon holes on face" /> {\n // Create a rectangular face as the base shape\n const faceOptions = new RectangleDto();\n faceOptions.width = 20;\n faceOptions.length = 14;\n faceOptions.center = [0, 0, 0];\n faceOptions.direction = [0, 1, 0];\n const rectangleFace = await face.createRectangleFace(faceOptions);\n\n // Define scale patterns for U and V directions\n // For hexagons, uniform scaling often works best due to natural packing\n const scalePatternU = [0.9]; // Uniform hexagon size in U direction\n const scalePatternV = [0.9]; // Uniform hexagon size in V direction\n\n // Subdivide the face into hexagonal holes\n const subdivideOptions = new FaceSubdivideToHexagonHolesDto();\n subdivideOptions.shape = rectangleFace;\n subdivideOptions.nrHexagonsU = 10; // Number of hexagon divisions in U direction\n subdivideOptions.nrHexagonsV = 10; // Number of hexagon divisions in V direction\n subdivideOptions.flatU = false; // Pointy-top orientation (false) vs flat-top (true)\n subdivideOptions.holesToFaces = false; // Return wires instead of faces\n subdivideOptions.offsetFromBorderU = 0.01; // Small border offset in U direction\n subdivideOptions.offsetFromBorderV = 0.01; // Small border offset in V direction\n subdivideOptions.scalePatternU = scalePatternU;\n subdivideOptions.scalePatternV = scalePatternV;\n\n const holes = await face.subdivideToHexagonHoles(subdivideOptions);\n\n // Get the first hole (the outer boundary with hexagonal holes)\n const firstHole = lists.getItem({ list: holes, index: 0, clone: true });\n\n // Extrude the face with holes to create a 3D honeycomb structure\n const extrudeOptions = new ExtrudeDto();\n extrudeOptions.shape = firstHole;\n extrudeOptions.direction = [0, 1, 0];\n const extrudedSolid = await operations.extrude(extrudeOptions);\n\n // Draw the resulting 3D solid with hexagonal holes\n bitbybit.draw.drawAnyAsync({\n entity: extrudedSolid\n });\n}\n\n// Execute the function\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"// Import required DTOs for face creation, subdivision, and extrusion\nconst { RectangleDto, FaceSubdivideToHexagonHolesDto, ExtrudeDto } = Bit.Inputs.OCCT;\n// Import type definitions for type safety\ntype TopoDSFacePointer = Bit.Inputs.OCCT.TopoDSFacePointer;\ntype TopoDSWirePointer = Bit.Inputs.OCCT.TopoDSWirePointer;\n\n// Get access to OCCT modules for face operations\nconst { face } = bitbybit.occt.shapes;\nconst { operations } = bitbybit.occt;\nconst { lists } = bitbybit;\n\n// Define the main function to create hexagon holes on a face\nconst start = async () => {\n // Create a rectangular face as the base shape\n const faceOptions = new RectangleDto();\n faceOptions.width = 20;\n faceOptions.length = 14;\n faceOptions.center = [0, 0, 0];\n faceOptions.direction = [0, 1, 0];\n const rectangleFace = await face.createRectangleFace(faceOptions);\n\n // Define scale patterns for U and V directions\n // For hexagons, uniform scaling often works best due to natural packing\n const scalePatternU = [0.9]; // Uniform hexagon size in U direction\n const scalePatternV = [0.9]; // Uniform hexagon size in V direction\n\n // Subdivide the face into hexagonal holes\n const subdivideOptions = new FaceSubdivideToHexagonHolesDto();\n subdivideOptions.shape = rectangleFace;\n subdivideOptions.nrHexagonsU = 10; // Number of hexagon divisions in U direction\n subdivideOptions.nrHexagonsV = 10; // Number of hexagon divisions in V direction\n subdivideOptions.flatU = false; // Pointy-top orientation (false) vs flat-top (true)\n subdivideOptions.holesToFaces = false; // Return wires instead of faces\n subdivideOptions.offsetFromBorderU = 0.01; // Small border offset in U direction\n subdivideOptions.offsetFromBorderV = 0.01; // Small border offset in V direction\n subdivideOptions.scalePatternU = scalePatternU;\n subdivideOptions.scalePatternV = scalePatternV;\n\n const holes = await face.subdivideToHexagonHoles(subdivideOptions);\n\n // Get the first hole (the outer boundary with hexagonal holes)\n const firstHole = lists.getItem({ list: holes, index: 0, clone: true });\n\n // Extrude the face with holes to create a 3D honeycomb structure\n const extrudeOptions = new ExtrudeDto();\n extrudeOptions.shape = firstHole;\n extrudeOptions.direction = [0, 1, 0];\n const extrudedSolid = await operations.extrude(extrudeOptions);\n\n // Draw the resulting 3D solid with hexagonal holes\n bitbybit.draw.drawAnyAsync({\n entity: extrudedSolid\n });\n}\n\n// Execute the function\nstart();","version":"0.21.1","type":"typescript"}} title="Hexagon holes on face" /> diff --git a/docs/learn/code/common/occt/modeling/hollow-shapes/rectangle-holes-on-face.md b/docs/learn/code/common/occt/modeling/hollow-shapes/rectangle-holes-on-face.md index 8788f06f..25dba700 100644 --- a/docs/learn/code/common/occt/modeling/hollow-shapes/rectangle-holes-on-face.md +++ b/docs/learn/code/common/occt/modeling/hollow-shapes/rectangle-holes-on-face.md @@ -22,21 +22,21 @@ Creating regular patterns of holes manually can be time-consuming and error-pron recFacefacesrecFace2014000010facesrecFace1010[0.8,0.5,0.5][0.8,0.5,0.5]FALSE00GETFIRSTfaces010","version":"0.21.0","type":"blockly"}} + script={{"script":"recFacefacesrecFace2014000010facesrecFace1010[0.8,0.5,0.5][0.8,0.5,0.5]FALSE00GETFIRSTfaces010","version":"0.21.1","type":"blockly"}} title="Rectangle holes on face" /> {\n // Create a rectangular face as the base shape\n const faceOptions = new RectangleDto();\n faceOptions.width = 20;\n faceOptions.length = 14;\n faceOptions.center = [0, 0, 0];\n faceOptions.direction = [0, 1, 0];\n const rectangleFace = await face.createRectangleFace(faceOptions);\n\n // Define scale patterns for U and V directions\n // These arrays control the size of holes in each row and column\n const scalePatternU = [0.8, 0.5, 0.5]; // Varying hole sizes in U direction\n const scalePatternV = [0.8, 0.5, 0.5]; // Varying hole sizes in V direction\n\n // Subdivide the face into rectangular holes\n const subdivideOptions = new FaceSubdivideToRectangleHolesDto();\n subdivideOptions.shape = rectangleFace;\n subdivideOptions.nrRectanglesU = 10; // Number of divisions in U direction\n subdivideOptions.nrRectanglesV = 10; // Number of divisions in V direction\n subdivideOptions.holesToFaces = false; // Return wires instead of faces\n subdivideOptions.offsetFromBorderU = 0.05; // Border offset in U direction\n subdivideOptions.offsetFromBorderV = 0.05; // Border offset in V direction\n subdivideOptions.scalePatternU = scalePatternU;\n subdivideOptions.scalePatternV = scalePatternV;\n\n const holes = await face.subdivideToRectangleHoles(subdivideOptions);\n\n // Get the first hole (the outer boundary with holes)\n const firstHole = lists.getItem({ list: holes, index: 0, clone: true });\n\n // Extrude the face with holes to create a 3D solid\n const extrudeOptions = new ExtrudeDto();\n extrudeOptions.shape = firstHole;\n extrudeOptions.direction = [0, 1, 0];\n const extrudedSolid = await operations.extrude(extrudeOptions);\n\n // Draw the resulting 3D solid with rectangular holes\n bitbybit.draw.drawAnyAsync({\n entity: extrudedSolid\n });\n}\n\n// Execute the function\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"// Import required DTOs for face creation, subdivision, and extrusion\nconst { RectangleDto, FaceSubdivideToRectangleHolesDto, ExtrudeDto } = Bit.Inputs.OCCT;\n// Import type definitions for type safety\ntype TopoDSFacePointer = Bit.Inputs.OCCT.TopoDSFacePointer;\ntype TopoDSWirePointer = Bit.Inputs.OCCT.TopoDSWirePointer;\n\n// Get access to OCCT modules for face operations\nconst { face } = bitbybit.occt.shapes;\nconst { operations } = bitbybit.occt;\nconst { lists } = bitbybit;\n\n// Define the main function to create rectangle holes on a face\nconst start = async () => {\n // Create a rectangular face as the base shape\n const faceOptions = new RectangleDto();\n faceOptions.width = 20;\n faceOptions.length = 14;\n faceOptions.center = [0, 0, 0];\n faceOptions.direction = [0, 1, 0];\n const rectangleFace = await face.createRectangleFace(faceOptions);\n\n // Define scale patterns for U and V directions\n // These arrays control the size of holes in each row and column\n const scalePatternU = [0.8, 0.5, 0.5]; // Varying hole sizes in U direction\n const scalePatternV = [0.8, 0.5, 0.5]; // Varying hole sizes in V direction\n\n // Subdivide the face into rectangular holes\n const subdivideOptions = new FaceSubdivideToRectangleHolesDto();\n subdivideOptions.shape = rectangleFace;\n subdivideOptions.nrRectanglesU = 10; // Number of divisions in U direction\n subdivideOptions.nrRectanglesV = 10; // Number of divisions in V direction\n subdivideOptions.holesToFaces = false; // Return wires instead of faces\n subdivideOptions.offsetFromBorderU = 0.05; // Border offset in U direction\n subdivideOptions.offsetFromBorderV = 0.05; // Border offset in V direction\n subdivideOptions.scalePatternU = scalePatternU;\n subdivideOptions.scalePatternV = scalePatternV;\n\n const holes = await face.subdivideToRectangleHoles(subdivideOptions);\n\n // Get the first hole (the outer boundary with holes)\n const firstHole = lists.getItem({ list: holes, index: 0, clone: true });\n\n // Extrude the face with holes to create a 3D solid\n const extrudeOptions = new ExtrudeDto();\n extrudeOptions.shape = firstHole;\n extrudeOptions.direction = [0, 1, 0];\n const extrudedSolid = await operations.extrude(extrudeOptions);\n\n // Draw the resulting 3D solid with rectangular holes\n bitbybit.draw.drawAnyAsync({\n entity: extrudedSolid\n });\n}\n\n// Execute the function\nstart();","version":"0.21.1","type":"typescript"}} title="Rectangle holes on face" /> diff --git a/docs/learn/code/common/occt/modeling/hollow-shapes/simple-hole.md b/docs/learn/code/common/occt/modeling/hollow-shapes/simple-hole.md index cfc75d46..3abc8bab 100644 --- a/docs/learn/code/common/occt/modeling/hollow-shapes/simple-hole.md +++ b/docs/learn/code/common/occt/modeling/hollow-shapes/simple-hole.md @@ -30,21 +30,21 @@ This technique is fundamental because it establishes the basic principle that ap 200000107000010TRUE","version":"0.21.0","type":"blockly"}} + script={{"script":"200000107000010TRUE","version":"0.21.1","type":"blockly"}} title="Simple hole from two wires" /> {\n // Create the outer square wire (boundary of the shape)\n const outerWireOptions = new SquareDto();\n outerWireOptions.size = 20;\n outerWireOptions.center = [0, 0, 0];\n outerWireOptions.direction = [0, 1, 0];\n const outerWire = await wire.createSquareWire(outerWireOptions);\n\n // Create the inner square wire (defines the hole)\n const innerWireOptions = new SquareDto();\n innerWireOptions.size = 7;\n innerWireOptions.center = [0, 0, 0];\n innerWireOptions.direction = [0, 1, 0];\n const innerWire = await wire.createSquareWire(innerWireOptions);\n\n // Reverse the inner wire - this is crucial for proper hole creation\n const reversedInnerWire = await wire.reversedWire({ shape: innerWire });\n\n // Create a face from both wires - outer boundary and inner hole\n const faceOptions = new FaceFromWiresDto();\n faceOptions.shapes = [outerWire, reversedInnerWire];\n faceOptions.planar = true;\n const faceWithHole = await face.createFaceFromWires(faceOptions);\n\n // Draw the resulting face with hole\n bitbybit.draw.drawAnyAsync({\n entity: faceWithHole\n });\n}\n\n// Execute the function\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"// Import required types and DTOs for creating wire shapes and faces\nconst { SquareDto, FaceFromWiresDto } = Bit.Inputs.OCCT;\n// Import the wire pointer type for type safety\ntype TopoDSWirePointer = Bit.Inputs.OCCT.TopoDSWirePointer;\n\n// Get direct access to OCCT wire and face creation functions\nconst { wire } = bitbybit.occt.shapes;\nconst { face } = bitbybit.occt.shapes;\n\n// Define the main function to create a simple hole\nconst start = async () => {\n // Create the outer square wire (boundary of the shape)\n const outerWireOptions = new SquareDto();\n outerWireOptions.size = 20;\n outerWireOptions.center = [0, 0, 0];\n outerWireOptions.direction = [0, 1, 0];\n const outerWire = await wire.createSquareWire(outerWireOptions);\n\n // Create the inner square wire (defines the hole)\n const innerWireOptions = new SquareDto();\n innerWireOptions.size = 7;\n innerWireOptions.center = [0, 0, 0];\n innerWireOptions.direction = [0, 1, 0];\n const innerWire = await wire.createSquareWire(innerWireOptions);\n\n // Reverse the inner wire - this is crucial for proper hole creation\n const reversedInnerWire = await wire.reversedWire({ shape: innerWire });\n\n // Create a face from both wires - outer boundary and inner hole\n const faceOptions = new FaceFromWiresDto();\n faceOptions.shapes = [outerWire, reversedInnerWire];\n faceOptions.planar = true;\n const faceWithHole = await face.createFaceFromWires(faceOptions);\n\n // Draw the resulting face with hole\n bitbybit.draw.drawAnyAsync({\n entity: faceWithHole\n });\n}\n\n// Execute the function\nstart();","version":"0.21.1","type":"typescript"}} title="Simple hole from two wires" /> @@ -60,21 +60,21 @@ The transition from a 2D hollow face to a 3D hollow solid is achieved through ex 2014000010177000010101045TRUE020","version":"0.21.0","type":"blockly"}} + script={{"script":"2014000010177000010101045TRUE020","version":"0.21.1","type":"blockly"}} title="More complex solid with the hole" /> {\n // Create the outer rectangular wire\n const outerWireOptions = new RectangleDto();\n outerWireOptions.width = 20;\n outerWireOptions.length = 14;\n outerWireOptions.center = [0, 0, 0];\n outerWireOptions.direction = [0, 1, 0];\n const outerWire = await wire.createRectangleWire(outerWireOptions);\n\n // Apply fillet to the outer wire for rounded corners\n const outerFilletOptions = new FilletDto();\n outerFilletOptions.radius = 1;\n outerFilletOptions.shape = outerWire;\n const filletedOuterWire = await fillets.fillet2d(outerFilletOptions);\n\n // Create the inner rectangular wire (hole)\n const innerWireOptions = new RectangleDto();\n innerWireOptions.width = 7;\n innerWireOptions.length = 7;\n innerWireOptions.center = [0, 0, 0];\n innerWireOptions.direction = [0, 1, 0];\n const innerWire = await wire.createRectangleWire(innerWireOptions);\n\n // Apply fillet to the inner wire\n const innerFilletOptions = new FilletDto();\n innerFilletOptions.radius = 1;\n innerFilletOptions.shape = innerWire;\n const filletedInnerWire = await fillets.fillet2d(innerFilletOptions);\n\n // Rotate the inner wire by 45 degrees for visual interest\n const rotatedInnerWire = await transforms.rotate({\n shape: filletedInnerWire,\n axis: [0, 1, 0],\n angle: 45\n });\n\n // Reverse the rotated inner wire for proper hole creation\n const reversedInnerWire = await wire.reversedWire({ shape: rotatedInnerWire });\n\n // Create a face from both wires\n const faceOptions = new FaceFromWiresDto();\n faceOptions.shapes = [filletedOuterWire, reversedInnerWire];\n faceOptions.planar = true;\n const faceWithHole = await face.createFaceFromWires(faceOptions);\n\n // Extrude the face to create a 3D solid\n const extrudeOptions = new ExtrudeDto();\n extrudeOptions.shape = faceWithHole;\n extrudeOptions.direction = [0, 2, 0]; // Extrude 2 units in Y direction\n const solidWithHole = await operations.extrude(extrudeOptions);\n\n // Draw the resulting 3D solid with hole\n bitbybit.draw.drawAnyAsync({\n entity: solidWithHole\n });\n}\n\n// Execute the function\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"// Import required DTOs for creating wires, fillets, faces, and extrusion operations\nconst { RectangleDto, FilletDto, FaceFromWiresDto, ExtrudeDto } = Bit.Inputs.OCCT;\n// Import wire pointer type for type safety\ntype TopoDSWirePointer = Bit.Inputs.OCCT.TopoDSWirePointer;\ntype TopoDSFacePointer = Bit.Inputs.OCCT.TopoDSFacePointer;\n\n// Get access to OCCT modules for creating shapes and operations\nconst { wire, face } = bitbybit.occt.shapes;\nconst { fillets, operations, transforms } = bitbybit.occt;\n\n// Define the main function to create an extruded solid with a hole\nconst start = async () => {\n // Create the outer rectangular wire\n const outerWireOptions = new RectangleDto();\n outerWireOptions.width = 20;\n outerWireOptions.length = 14;\n outerWireOptions.center = [0, 0, 0];\n outerWireOptions.direction = [0, 1, 0];\n const outerWire = await wire.createRectangleWire(outerWireOptions);\n\n // Apply fillet to the outer wire for rounded corners\n const outerFilletOptions = new FilletDto();\n outerFilletOptions.radius = 1;\n outerFilletOptions.shape = outerWire;\n const filletedOuterWire = await fillets.fillet2d(outerFilletOptions);\n\n // Create the inner rectangular wire (hole)\n const innerWireOptions = new RectangleDto();\n innerWireOptions.width = 7;\n innerWireOptions.length = 7;\n innerWireOptions.center = [0, 0, 0];\n innerWireOptions.direction = [0, 1, 0];\n const innerWire = await wire.createRectangleWire(innerWireOptions);\n\n // Apply fillet to the inner wire\n const innerFilletOptions = new FilletDto();\n innerFilletOptions.radius = 1;\n innerFilletOptions.shape = innerWire;\n const filletedInnerWire = await fillets.fillet2d(innerFilletOptions);\n\n // Rotate the inner wire by 45 degrees for visual interest\n const rotatedInnerWire = await transforms.rotate({\n shape: filletedInnerWire,\n axis: [0, 1, 0],\n angle: 45\n });\n\n // Reverse the rotated inner wire for proper hole creation\n const reversedInnerWire = await wire.reversedWire({ shape: rotatedInnerWire });\n\n // Create a face from both wires\n const faceOptions = new FaceFromWiresDto();\n faceOptions.shapes = [filletedOuterWire, reversedInnerWire];\n faceOptions.planar = true;\n const faceWithHole = await face.createFaceFromWires(faceOptions);\n\n // Extrude the face to create a 3D solid\n const extrudeOptions = new ExtrudeDto();\n extrudeOptions.shape = faceWithHole;\n extrudeOptions.direction = [0, 2, 0]; // Extrude 2 units in Y direction\n const solidWithHole = await operations.extrude(extrudeOptions);\n\n // Draw the resulting 3D solid with hole\n bitbybit.draw.drawAnyAsync({\n entity: solidWithHole\n });\n}\n\n// Execute the function\nstart();","version":"0.21.1","type":"typescript"}} title="More complex solid with the hole" /> @@ -90,21 +90,21 @@ The process simply involves creating additional inner wires and including them a 231400001017700001010104550077000010101045-500TRUE020","version":"0.21.0","type":"blockly"}} + script={{"script":"231400001017700001010104550077000010101045-500TRUE020","version":"0.21.1","type":"blockly"}} title="Solid with 2 holes" /> {\n // Create the outer rectangular wire (larger this time)\n const outerWireOptions = new RectangleDto();\n outerWireOptions.width = 23;\n outerWireOptions.length = 14;\n outerWireOptions.center = [0, 0, 0];\n outerWireOptions.direction = [0, 1, 0];\n const outerWire = await wire.createRectangleWire(outerWireOptions);\n\n // Apply fillet to the outer wire\n const outerFilletOptions = new FilletDto();\n outerFilletOptions.radius = 1;\n outerFilletOptions.shape = outerWire;\n const filletedOuterWire = await fillets.fillet2d(outerFilletOptions);\n\n // Reverse the outer wire (optimization - reverse once instead of multiple inner wires)\n const reversedOuterWire = await wire.reversedWire({ shape: filletedOuterWire });\n\n // Create the base inner rectangular wire\n const innerWireOptions = new RectangleDto();\n innerWireOptions.width = 7;\n innerWireOptions.length = 7;\n innerWireOptions.center = [0, 0, 0];\n innerWireOptions.direction = [0, 1, 0];\n const innerWire = await wire.createRectangleWire(innerWireOptions);\n\n // Apply fillet to the inner wire\n const innerFilletOptions = new FilletDto();\n innerFilletOptions.radius = 1;\n innerFilletOptions.shape = innerWire;\n const filletedInnerWire = await fillets.fillet2d(innerFilletOptions);\n\n // Rotate the inner wire for visual interest\n const rotatedInnerWire = await transforms.rotate({\n shape: filletedInnerWire,\n axis: [0, 1, 0],\n angle: 45\n });\n\n // Create first hole by translating the rotated wire to the right\n const firstHole = await transforms.translate({\n shape: rotatedInnerWire,\n translation: [5, 0, 0]\n });\n\n // Create second hole by translating the rotated wire to the left\n const secondHole = await transforms.translate({\n shape: rotatedInnerWire,\n translation: [-5, 0, 0]\n });\n\n // Create a face from the outer boundary and multiple holes\n const faceOptions = new FaceFromWiresDto();\n faceOptions.shapes = [reversedOuterWire, firstHole, secondHole];\n faceOptions.planar = true;\n const faceWithHoles = await face.createFaceFromWires(faceOptions);\n\n // Extrude the face to create a 3D solid with multiple holes\n const extrudeOptions = new ExtrudeDto();\n extrudeOptions.shape = faceWithHoles;\n extrudeOptions.direction = [0, 2, 0];\n const solidWithHoles = await operations.extrude(extrudeOptions);\n\n // Draw the resulting 3D solid with multiple holes\n bitbybit.draw.drawAnyAsync({\n entity: solidWithHoles\n });\n}\n\n// Execute the function\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"// Import required DTOs for creating complex shapes with multiple holes\nconst { RectangleDto, FilletDto, FaceFromWiresDto, ExtrudeDto } = Bit.Inputs.OCCT;\n// Import type definitions for type safety\ntype TopoDSWirePointer = Bit.Inputs.OCCT.TopoDSWirePointer;\ntype TopoDSFacePointer = Bit.Inputs.OCCT.TopoDSFacePointer;\n\n// Get access to OCCT modules\nconst { wire, face } = bitbybit.occt.shapes;\nconst { fillets, operations, transforms } = bitbybit.occt;\n\n// Define the main function to create a solid with multiple holes\nconst start = async () => {\n // Create the outer rectangular wire (larger this time)\n const outerWireOptions = new RectangleDto();\n outerWireOptions.width = 23;\n outerWireOptions.length = 14;\n outerWireOptions.center = [0, 0, 0];\n outerWireOptions.direction = [0, 1, 0];\n const outerWire = await wire.createRectangleWire(outerWireOptions);\n\n // Apply fillet to the outer wire\n const outerFilletOptions = new FilletDto();\n outerFilletOptions.radius = 1;\n outerFilletOptions.shape = outerWire;\n const filletedOuterWire = await fillets.fillet2d(outerFilletOptions);\n\n // Reverse the outer wire (optimization - reverse once instead of multiple inner wires)\n const reversedOuterWire = await wire.reversedWire({ shape: filletedOuterWire });\n\n // Create the base inner rectangular wire\n const innerWireOptions = new RectangleDto();\n innerWireOptions.width = 7;\n innerWireOptions.length = 7;\n innerWireOptions.center = [0, 0, 0];\n innerWireOptions.direction = [0, 1, 0];\n const innerWire = await wire.createRectangleWire(innerWireOptions);\n\n // Apply fillet to the inner wire\n const innerFilletOptions = new FilletDto();\n innerFilletOptions.radius = 1;\n innerFilletOptions.shape = innerWire;\n const filletedInnerWire = await fillets.fillet2d(innerFilletOptions);\n\n // Rotate the inner wire for visual interest\n const rotatedInnerWire = await transforms.rotate({\n shape: filletedInnerWire,\n axis: [0, 1, 0],\n angle: 45\n });\n\n // Create first hole by translating the rotated wire to the right\n const firstHole = await transforms.translate({\n shape: rotatedInnerWire,\n translation: [5, 0, 0]\n });\n\n // Create second hole by translating the rotated wire to the left\n const secondHole = await transforms.translate({\n shape: rotatedInnerWire,\n translation: [-5, 0, 0]\n });\n\n // Create a face from the outer boundary and multiple holes\n const faceOptions = new FaceFromWiresDto();\n faceOptions.shapes = [reversedOuterWire, firstHole, secondHole];\n faceOptions.planar = true;\n const faceWithHoles = await face.createFaceFromWires(faceOptions);\n\n // Extrude the face to create a 3D solid with multiple holes\n const extrudeOptions = new ExtrudeDto();\n extrudeOptions.shape = faceWithHoles;\n extrudeOptions.direction = [0, 2, 0];\n const solidWithHoles = await operations.extrude(extrudeOptions);\n\n // Draw the resulting 3D solid with multiple holes\n bitbybit.draw.drawAnyAsync({\n entity: solidWithHoles\n });\n}\n\n// Execute the function\nstart();","version":"0.21.1","type":"typescript"}} title="Solid with 2 holes" /> diff --git a/docs/learn/code/common/occt/modeling/hollow-shapes/simple-hollow-grids.md b/docs/learn/code/common/occt/modeling/hollow-shapes/simple-hollow-grids.md index ab2aead8..eb699176 100644 --- a/docs/learn/code/common/occt/modeling/hollow-shapes/simple-hollow-grids.md +++ b/docs/learn/code/common/occt/modeling/hollow-shapes/simple-hollow-grids.md @@ -30,21 +30,21 @@ This approach not only saves time but also ensures perfect regularity and makes gridSizeholeRadiusholeSpacingextrudeHeighthalfGridboundarySizesquarexPositionsyPositionswiresxzhollowFacehollowGridSolidgridSize14holeRadius0.8holeSpacing2extrudeHeight0.5halfGridDIVIDEgridSize2boundarySizeADDgridSize4squareboundarySize000010xPositionsholeSpacingNEGhalfGridhalfGridyPositionsholeSpacingNEGhalfGridhalfGridwiressquarex1xPositions1z1xPositions1INSERTLASTwiresholeRadiusGETFROM_STARTxPositionsx0GETFROM_STARTyPositionsz010hollowFacewiresTRUEhollowGridSolidhollowFace0extrudeHeight0hollowGridSolid","version":"0.21.0","type":"blockly"}} + script={{"script":"gridSizeholeRadiusholeSpacingextrudeHeighthalfGridboundarySizesquarexPositionsyPositionswiresxzhollowFacehollowGridSolidgridSize14holeRadius0.8holeSpacing2extrudeHeight0.5halfGridDIVIDEgridSize2boundarySizeADDgridSize4squareboundarySize000010xPositionsholeSpacingNEGhalfGridhalfGridyPositionsholeSpacingNEGhalfGridhalfGridwiressquarex1xPositions1z1xPositions1INSERTLASTwiresholeRadiusGETFROM_STARTxPositionsx0GETFROM_STARTyPositionsz010hollowFacewiresTRUEhollowGridSolidhollowFace0extrudeHeight0hollowGridSolid","version":"0.21.1","type":"blockly"}} title="Simple hollow grid" /> {\n // Grid parameters - easily adjustable for different requirements\n const gridSize = 14; // Overall grid dimension\n const holeRadius = 0.8; // Radius of each circular hole\n const holeSpacing = 2; // Distance between hole centers\n const extrudeHeight = 0.5; // Thickness of the final solid\n \n // Calculate grid boundaries\n const halfGrid = gridSize / 2;\n const boundarySize = gridSize + 4; // Add padding around holes\n \n // Create the outer boundary wire (square frame)\n const boundaryOptions = new SquareDto();\n boundaryOptions.size = boundarySize;\n boundaryOptions.center = [0, 0, 0];\n boundaryOptions.direction = [0, 1, 0];\n const boundaryWire = await wire.createSquareWire(boundaryOptions);\n \n // Generate grid positions using span functions\n const xPositions = vector.span({\n min: -halfGrid,\n max: halfGrid,\n step: holeSpacing\n });\n \n const zPositions = vector.span({\n min: -halfGrid,\n max: halfGrid,\n step: holeSpacing\n });\n \n // Create grid points by combining X and Z coordinates\n const gridPoints: Point3[] = [];\n for (const xPos of xPositions) {\n for (const zPos of zPositions) {\n gridPoints.push([xPos, 0, zPos]);\n }\n }\n \n // Create the hole template (circular wire)\n const holeOptions = new CircleDto();\n holeOptions.radius = holeRadius;\n holeOptions.center = [0, 0, 0];\n holeOptions.direction = [0, 1, 0];\n const holeTemplate = await wire.createCircleWire(holeOptions);\n \n // Create holes at each grid position\n const holes: TopoDSWirePointer[] = [];\n for (const position of gridPoints) {\n const translatedHole = await transforms.translate({\n shape: holeTemplate,\n translation: position\n });\n \n // Reverse each hole wire for proper orientation\n const reversedHole = await wire.reversedWire({ shape: translatedHole });\n holes.push(reversedHole);\n }\n \n // Combine boundary and all holes into a single wire list\n const allWires = [boundaryWire, ...holes];\n \n // Create a face from the boundary and all holes\n const faceOptions = new FaceFromWiresDto();\n faceOptions.shapes = allWires;\n faceOptions.planar = true;\n const gridFace = await face.createFaceFromWires(faceOptions);\n \n // Extrude the face to create a 3D hollow grid\n const extrudeOptions = new ExtrudeDto();\n extrudeOptions.shape = gridFace;\n extrudeOptions.direction = [0, extrudeHeight, 0];\n const hollowGrid = await operations.extrude(extrudeOptions);\n \n // Draw the resulting hollow grid\n bitbybit.draw.drawAnyAsync({\n entity: hollowGrid\n });\n}\n\n// Execute the function\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"// Import required DTOs for creating grids, shapes, and operations\nconst { SquareDto, CircleDto, FaceFromWiresDto, ExtrudeDto } = Bit.Inputs.OCCT;\n// Import type definitions for type safety\ntype Point3 = Bit.Inputs.Base.Point3;\ntype TopoDSWirePointer = Bit.Inputs.OCCT.TopoDSWirePointer;\ntype TopoDSFacePointer = Bit.Inputs.OCCT.TopoDSFacePointer;\n\n// Get access to OCCT modules and utility functions\nconst { wire, face } = bitbybit.occt.shapes;\nconst { operations, transforms } = bitbybit.occt;\nconst { vector } = bitbybit;\n\n// Define the main function to create a parametric hollow grid\nconst start = async () => {\n // Grid parameters - easily adjustable for different requirements\n const gridSize = 14; // Overall grid dimension\n const holeRadius = 0.8; // Radius of each circular hole\n const holeSpacing = 2; // Distance between hole centers\n const extrudeHeight = 0.5; // Thickness of the final solid\n \n // Calculate grid boundaries\n const halfGrid = gridSize / 2;\n const boundarySize = gridSize + 4; // Add padding around holes\n \n // Create the outer boundary wire (square frame)\n const boundaryOptions = new SquareDto();\n boundaryOptions.size = boundarySize;\n boundaryOptions.center = [0, 0, 0];\n boundaryOptions.direction = [0, 1, 0];\n const boundaryWire = await wire.createSquareWire(boundaryOptions);\n \n // Generate grid positions using span functions\n const xPositions = vector.span({\n min: -halfGrid,\n max: halfGrid,\n step: holeSpacing\n });\n \n const zPositions = vector.span({\n min: -halfGrid,\n max: halfGrid,\n step: holeSpacing\n });\n \n // Create grid points by combining X and Z coordinates\n const gridPoints: Point3[] = [];\n for (const xPos of xPositions) {\n for (const zPos of zPositions) {\n gridPoints.push([xPos, 0, zPos]);\n }\n }\n \n // Create the hole template (circular wire)\n const holeOptions = new CircleDto();\n holeOptions.radius = holeRadius;\n holeOptions.center = [0, 0, 0];\n holeOptions.direction = [0, 1, 0];\n const holeTemplate = await wire.createCircleWire(holeOptions);\n \n // Create holes at each grid position\n const holes: TopoDSWirePointer[] = [];\n for (const position of gridPoints) {\n const translatedHole = await transforms.translate({\n shape: holeTemplate,\n translation: position\n });\n \n // Reverse each hole wire for proper orientation\n const reversedHole = await wire.reversedWire({ shape: translatedHole });\n holes.push(reversedHole);\n }\n \n // Combine boundary and all holes into a single wire list\n const allWires = [boundaryWire, ...holes];\n \n // Create a face from the boundary and all holes\n const faceOptions = new FaceFromWiresDto();\n faceOptions.shapes = allWires;\n faceOptions.planar = true;\n const gridFace = await face.createFaceFromWires(faceOptions);\n \n // Extrude the face to create a 3D hollow grid\n const extrudeOptions = new ExtrudeDto();\n extrudeOptions.shape = gridFace;\n extrudeOptions.direction = [0, extrudeHeight, 0];\n const hollowGrid = await operations.extrude(extrudeOptions);\n \n // Draw the resulting hollow grid\n bitbybit.draw.drawAnyAsync({\n entity: hollowGrid\n });\n}\n\n// Execute the function\nstart();","version":"0.21.1","type":"typescript"}} title="Simple hollow grid" /> diff --git a/docs/learn/code/common/occt/modeling/parametric-art/simple-flower.md b/docs/learn/code/common/occt/modeling/parametric-art/simple-flower.md index acaee7cb..db77d550 100644 --- a/docs/learn/code/common/occt/modeling/parametric-art/simple-flower.md +++ b/docs/learn/code/common/occt/modeling/parametric-art/simple-flower.md @@ -30,21 +30,21 @@ This method is highly parametric—by adjusting the control points, rotation ang controlPointscurvemirrorNormalmirroredCurvecombinedWiresflowerFacethickFlowerrotationAxisrotationAnglesflowerPetalsanglerotatedPetalfinalFlowercontrolPoints00020.531.1-0.570010curvecontrolPointsFALSE1e-7mirrorNormal100mirroredCurvecurve000mirrorNormalcombinedWirescurvemirroredCurveflowerFacecombinedWiresFALSEthickFlowerflowerFace0.1rotationAxis220rotationAngles300360flowerPetalsangle1rotationAngles1rotatedPetalthickFlowerrotationAxisGETFROM_STARTrotationAnglesangleINSERTLASTflowerPetalsrotatedPetalfinalFlowerflowerPetalsfinalFlower0.01Custom Material#14ffa5#0000000.60.51FALSE2TRUE#0000002-100-100-1003#ffffff#ffffff1024TRUE0TRUE0.20.00010.00210000#090a0b#a4f9ef'to top'0100","version":"0.21.0","type":"blockly"}} + script={{"script":"controlPointscurvemirrorNormalmirroredCurvecombinedWiresflowerFacethickFlowerrotationAxisrotationAnglesflowerPetalsanglerotatedPetalfinalFlowercontrolPoints00020.531.1-0.570010curvecontrolPointsFALSE1e-7mirrorNormal100mirroredCurvecurve000mirrorNormalcombinedWirescurvemirroredCurveflowerFacecombinedWiresFALSEthickFlowerflowerFace0.1rotationAxis220rotationAngles300360flowerPetalsangle1rotationAngles1rotatedPetalthickFlowerrotationAxisGETFROM_STARTrotationAnglesangleINSERTLASTflowerPetalsrotatedPetalfinalFlowerflowerPetalsfinalFlower0.01Custom Material#14ffa5#0000000.60.51FALSE2TRUE#0000002-100-100-1003#ffffff#ffffff1024TRUE0TRUE0.20.00010.00210000#090a0b#a4f9ef'to top'0100","version":"0.21.1","type":"blockly"}} title="Simple flower" /> {\n const backgroundOpt = new SceneTwoColorLinearGradientDto();\n backgroundOpt.colorFrom = \"#090a0b\";\n backgroundOpt.colorTo = \"#a4f9ef\";\n backgroundOpt.direction = gradientDirectionEnum.toTop;\n scene.twoColorLinearGradient(backgroundOpt);\n\n const dirLightOpt = new DirectionalLightDto();\n dirLightOpt.intensity = 3;\n scene.drawDirectionalLight(dirLightOpt);\n}\n\n// Define the main function to create a parametric flower\nconst start = async () => {\n createEnvironment();\n // Flower parameters - easily adjustable for different designs\n const thickness = 0.1; // Thickness of the flower petals\n const rotationStep = 30; // Degrees between each petal (12 petals total)\n const rotationAxis: Vector3 = [2, 2, 0]; // Axis for petal rotation\n\n // Define control points for the flower petal curve\n const controlPoints: Point3[] = [\n [0, 0, 0], // Start point (flower center)\n [2, 0.5, 3], // First control point (petal width)\n [1.1, -0.5, 7], // Second control point (petal curve)\n [0, 0, 10] // End point (petal tip)\n ];\n\n // Create interpolated curve through control points\n const curveOptions = new InterpolationDto();\n curveOptions.points = controlPoints;\n curveOptions.periodic = false;\n curveOptions.tolerance = 1e-7;\n const petalCurve = await wire.interpolatePoints(curveOptions);\n\n // Mirror the curve to create symmetry for the petal\n const mirrorOptions = new MirrorAlongNormalDto();\n mirrorOptions.shape = petalCurve;\n mirrorOptions.origin = [0, 0, 0];\n mirrorOptions.normal = [1, 0, 0]; // Mirror along X-axis\n const mirroredCurve = await transforms.mirrorAlongNormal(mirrorOptions);\n\n // Combine the original and mirrored curves into a single wire\n const combineOptions = new ShapesDto();\n combineOptions.shapes = [petalCurve, mirroredCurve];\n const combinedWire = await wire.combineEdgesAndWiresIntoAWire(combineOptions);\n\n // Create a face from the combined wire\n const faceOptions = new FaceFromWireDto();\n faceOptions.shape = combinedWire;\n faceOptions.planar = false; // Allow non-planar surface\n const petalFace = await face.createFaceFromWire(faceOptions);\n\n // Create a thick solid from the face\n const thickOptions = new ThisckSolidSimpleDto();\n thickOptions.shape = petalFace;\n thickOptions.offset = thickness;\n const thickPetal = await operations.makeThickSolidSimple(thickOptions);\n\n // Generate rotation angles for petals (0° to 360° in steps)\n const rotationAngles = vector.span({\n min: 0,\n max: 360,\n step: rotationStep\n });\n\n // Create all flower petals by rotating the base petal\n const flowerPetalPromises: Promise[] = [];\n for (const angle of rotationAngles) {\n const rotateOptions = new RotateDto();\n rotateOptions.shape = thickPetal;\n rotateOptions.axis = rotationAxis;\n rotateOptions.angle = angle;\n\n const rotatedPetal = transforms.rotate(rotateOptions);\n flowerPetalPromises.push(rotatedPetal);\n }\n\n const flowerPetals = await Promise.all(flowerPetalPromises);\n\n // Combine all petals into a single compound shape\n const compoundOptions = new CompoundShapesDto();\n compoundOptions.shapes = flowerPetals;\n const flower = await compound.makeCompound(compoundOptions);\n\n const pbrOptions = new Bit.Inputs.BabylonMaterial.PBRMetallicRoughnessDto();\n pbrOptions.baseColor = \"#14ffa5\";\n pbrOptions.metallic = 0.6;\n pbrOptions.roughness = 0.6;\n pbrOptions.zOffset = 2;\n const pbrMaterial = pbrMetallicRoughness.create(pbrOptions);\n\n const drawOpt = new Bit.Inputs.Draw.DrawOcctShapeMaterialOptions();\n drawOpt.faceMaterial = pbrMaterial;\n drawOpt.edgeColour = \"#000000\";\n\n // Draw the completed flower with material options\n bitbybit.draw.drawAnyAsync({\n entity: flower,\n options: drawOpt\n });\n}\n\n// Execute the flower creation function\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"// Import required DTOs for creating curves, shapes, and operations\nconst { InterpolationDto, MirrorAlongNormalDto, ShapesDto, CompoundShapesDto,\n FaceFromWireDto, ThisckSolidSimpleDto, RotateDto } = Bit.Inputs.OCCT;\nconst { SceneTwoColorLinearGradientDto, DirectionalLightDto } = Bit.Inputs.BabylonScene;\nconst { gradientDirectionEnum } = Bit.Inputs.Base;\n\n// Import type definitions for type safety\ntype Point3 = Bit.Inputs.Base.Point3;\ntype Vector3 = Bit.Inputs.Base.Vector3;\ntype TopoDSWirePointer = Bit.Inputs.OCCT.TopoDSWirePointer;\ntype TopoDSFacePointer = Bit.Inputs.OCCT.TopoDSFacePointer;\ntype TopoDSShapePointer = Bit.Inputs.OCCT.TopoDSShapePointer;\n\n// Get access to OCCT modules and utility functions\nconst { wire, face, compound } = bitbybit.occt.shapes;\nconst { operations, transforms } = bitbybit.occt;\nconst { vector } = bitbybit;\nconst { scene } = bitbybit.babylon;\nconst { pbrMetallicRoughness } = bitbybit.babylon.material;\n\n\nconst createEnvironment = async () => {\n const backgroundOpt = new SceneTwoColorLinearGradientDto();\n backgroundOpt.colorFrom = \"#090a0b\";\n backgroundOpt.colorTo = \"#a4f9ef\";\n backgroundOpt.direction = gradientDirectionEnum.toTop;\n scene.twoColorLinearGradient(backgroundOpt);\n\n const dirLightOpt = new DirectionalLightDto();\n dirLightOpt.intensity = 3;\n scene.drawDirectionalLight(dirLightOpt);\n}\n\n// Define the main function to create a parametric flower\nconst start = async () => {\n createEnvironment();\n // Flower parameters - easily adjustable for different designs\n const thickness = 0.1; // Thickness of the flower petals\n const rotationStep = 30; // Degrees between each petal (12 petals total)\n const rotationAxis: Vector3 = [2, 2, 0]; // Axis for petal rotation\n\n // Define control points for the flower petal curve\n const controlPoints: Point3[] = [\n [0, 0, 0], // Start point (flower center)\n [2, 0.5, 3], // First control point (petal width)\n [1.1, -0.5, 7], // Second control point (petal curve)\n [0, 0, 10] // End point (petal tip)\n ];\n\n // Create interpolated curve through control points\n const curveOptions = new InterpolationDto();\n curveOptions.points = controlPoints;\n curveOptions.periodic = false;\n curveOptions.tolerance = 1e-7;\n const petalCurve = await wire.interpolatePoints(curveOptions);\n\n // Mirror the curve to create symmetry for the petal\n const mirrorOptions = new MirrorAlongNormalDto();\n mirrorOptions.shape = petalCurve;\n mirrorOptions.origin = [0, 0, 0];\n mirrorOptions.normal = [1, 0, 0]; // Mirror along X-axis\n const mirroredCurve = await transforms.mirrorAlongNormal(mirrorOptions);\n\n // Combine the original and mirrored curves into a single wire\n const combineOptions = new ShapesDto();\n combineOptions.shapes = [petalCurve, mirroredCurve];\n const combinedWire = await wire.combineEdgesAndWiresIntoAWire(combineOptions);\n\n // Create a face from the combined wire\n const faceOptions = new FaceFromWireDto();\n faceOptions.shape = combinedWire;\n faceOptions.planar = false; // Allow non-planar surface\n const petalFace = await face.createFaceFromWire(faceOptions);\n\n // Create a thick solid from the face\n const thickOptions = new ThisckSolidSimpleDto();\n thickOptions.shape = petalFace;\n thickOptions.offset = thickness;\n const thickPetal = await operations.makeThickSolidSimple(thickOptions);\n\n // Generate rotation angles for petals (0° to 360° in steps)\n const rotationAngles = vector.span({\n min: 0,\n max: 360,\n step: rotationStep\n });\n\n // Create all flower petals by rotating the base petal\n const flowerPetalPromises: Promise[] = [];\n for (const angle of rotationAngles) {\n const rotateOptions = new RotateDto();\n rotateOptions.shape = thickPetal;\n rotateOptions.axis = rotationAxis;\n rotateOptions.angle = angle;\n\n const rotatedPetal = transforms.rotate(rotateOptions);\n flowerPetalPromises.push(rotatedPetal);\n }\n\n const flowerPetals = await Promise.all(flowerPetalPromises);\n\n // Combine all petals into a single compound shape\n const compoundOptions = new CompoundShapesDto();\n compoundOptions.shapes = flowerPetals;\n const flower = await compound.makeCompound(compoundOptions);\n\n const pbrOptions = new Bit.Inputs.BabylonMaterial.PBRMetallicRoughnessDto();\n pbrOptions.baseColor = \"#14ffa5\";\n pbrOptions.metallic = 0.6;\n pbrOptions.roughness = 0.6;\n pbrOptions.zOffset = 2;\n const pbrMaterial = pbrMetallicRoughness.create(pbrOptions);\n\n const drawOpt = new Bit.Inputs.Draw.DrawOcctShapeMaterialOptions();\n drawOpt.faceMaterial = pbrMaterial;\n drawOpt.edgeColour = \"#000000\";\n\n // Draw the completed flower with material options\n bitbybit.draw.drawAnyAsync({\n entity: flower,\n options: drawOpt\n });\n}\n\n// Execute the flower creation function\nstart();","version":"0.21.1","type":"typescript"}} title="Simple flower" /> @@ -107,7 +107,7 @@ Despite managing up to 25,000 particles simultaneously, the system maintains smo {\n const dirLightOpt = new DirectionalLightDto();\n dirLightOpt.intensity = 3;\n scene.drawDirectionalLight(dirLightOpt);\n}\n\n// Define the main function to create a parametric flower\nconst start = async () => {\n createEnvironment();\n // Flower parameters - easily adjustable for different designs\n const thickness = 0.1; // Thickness of the flower petals\n const rotationStep = 60; // Degrees between each petal (12 petals total)\n const rotationAxis: Vector3 = [2, 2, 0]; // Axis for petal rotation\n\n // Define control points for the flower petal curve\n const controlPoints: Point3[] = [\n [0, 0, 0], // Start point (flower center)\n [5, 1.25, 7.5], // First control point (petal width)\n [2.75, -1.25, 17.5], // Second control point (petal curve)\n [0, 0, 25] // End point (petal tip)\n ];\n\n // Create interpolated curve through control points\n const curveOptions = new InterpolationDto();\n curveOptions.points = controlPoints;\n curveOptions.periodic = false;\n curveOptions.tolerance = 1e-7;\n const petalCurve = await wire.interpolatePoints(curveOptions);\n\n // Mirror the curve to create symmetry for the petal\n const mirrorOptions = new MirrorAlongNormalDto();\n mirrorOptions.shape = petalCurve;\n mirrorOptions.origin = [0, 0, 0];\n mirrorOptions.normal = [1, 0, 0]; // Mirror along X-axis\n const mirroredCurve = await transforms.mirrorAlongNormal(mirrorOptions);\n\n // Combine the original and mirrored curves into a single wire\n const combineOptions = new ShapesDto();\n combineOptions.shapes = [petalCurve, mirroredCurve];\n const combinedWire = await wire.combineEdgesAndWiresIntoAWire(combineOptions);\n\n // Create a face from the combined wire\n const faceOptions = new FaceFromWireDto();\n faceOptions.shape = combinedWire;\n faceOptions.planar = false; // Allow non-planar surface\n const petalFace = await face.createFaceFromWire(faceOptions);\n\n // Create a thick solid from the face\n const thickOptions = new ThisckSolidSimpleDto();\n thickOptions.shape = petalFace;\n thickOptions.offset = thickness;\n const thickPetal = await operations.makeThickSolidSimple(thickOptions);\n\n // Generate rotation angles for petals (0° to 360° in steps)\n const rotationAngles = vector.span({\n min: 0,\n max: 360,\n step: rotationStep\n });\n\n const rotationAngles2 = vector.span({\n min: 30,\n max: 360,\n step: rotationStep\n });\n\n // Create all flower petals by rotating the base petal\n const flowerPetalPromises: Promise[] = [];\n const flowerPetalPromises2: Promise[] = [];\n\n for (const angle of rotationAngles) {\n const rotateOptions = new RotateDto();\n rotateOptions.shape = thickPetal;\n rotateOptions.axis = rotationAxis;\n rotateOptions.angle = angle;\n\n const rotatedPetal = transforms.rotate(rotateOptions);\n flowerPetalPromises.push(rotatedPetal);\n }\n\n for (const angle of rotationAngles2) {\n const rotateOptions = new RotateDto();\n rotateOptions.shape = thickPetal;\n rotateOptions.axis = rotationAxis;\n rotateOptions.angle = angle;\n\n const rotatedPetal = transforms.rotate(rotateOptions);\n flowerPetalPromises2.push(rotatedPetal);\n }\n\n const flowerPetals = await Promise.all(flowerPetalPromises);\n const flowerPetals2 = await Promise.all(flowerPetalPromises2);\n\n // Combine all petals into a single compound shape\n const compoundOptions = new CompoundShapesDto();\n compoundOptions.shapes = flowerPetals;\n const flower = await compound.makeCompound(compoundOptions);\n compoundOptions.shapes = flowerPetals2;\n const flower2 = await compound.makeCompound(compoundOptions);\n\n const pbrOptions = new Bit.Inputs.BabylonMaterial.PBRMetallicRoughnessDto();\n pbrOptions.baseColor = \"#111111\";\n pbrOptions.metallic = 0.6;\n pbrOptions.roughness = 0.6;\n pbrOptions.alpha = 0.4;\n pbrOptions.zOffset = 2;\n const pbrMaterial = pbrMetallicRoughness.create(pbrOptions);\n\n const drawOpt = new Bit.Inputs.Draw.DrawOcctShapeMaterialOptions();\n drawOpt.faceMaterial = pbrMaterial;\n drawOpt.edgeColour = \"#ffffff\";\n drawOpt.drawEdges = true;\n drawOpt.precision = 0.1;\n\n // Draw the completed flower with material options\n const flowerMesh = await bitbybit.draw.drawAnyAsync({\n entity: flower,\n options: drawOpt\n });\n\n const flowerMesh2 = await bitbybit.draw.drawAnyAsync({\n entity: flower2,\n options: drawOpt\n });\n\n const emitterMesh = flowerMesh.getChildMeshes()[0] as BABYLON.Mesh;\n emitterMesh.isPickable = false;\n\n const emitterMesh2 = flowerMesh2.getChildMeshes()[0] as BABYLON.Mesh;\n emitterMesh2.isPickable = false;\n\n const scene = bitbybit.babylon.scene.getScene();\n\n const purpleStartColor = new BABYLON.Color4(0.7, 0.3, 1.0, 1.0);\n const purpleMidColor = new BABYLON.Color4(1.0, 0.4, 0.8, 1.0);\n\n const blueStartColor = new BABYLON.Color4(0.2, 0.7, 1.0, 1.0);\n const blueMidColor = new BABYLON.Color4(0.5, 0.8, 1.0, 1.0);\n\n // This object will be shared with both particle systems to track the mouse.\n const mouseTracker = { position: null as BABYLON.Vector3 | null };\n\n // Create all the 3D assets: emitters, particle systems, and the interaction plane.\n\n // Remove any old observable before adding a new one.\n if (scene.metadata && scene.metadata.observable) {\n scene.metadata.observable.remove();\n }\n\n // Centralized mouse interaction logic.\n const resObs = scene.onPointerObservable.add((pointerInfo) => {\n if (pointerInfo.type === BABYLON.PointerEventTypes.POINTERMOVE) {\n // We only check for hits against our single, invisible interaction plane.\n const pickInfo = scene.pick(scene.pointerX, scene.pointerY, (mesh) => mesh === emitterMesh);\n if (pickInfo.hit) {\n // If we hit the plane, update the shared tracker object's position.\n mouseTracker.position = pickInfo.pickedPoint;\n } else {\n // If the mouse is not over the plane, clear the position.\n mouseTracker.position = null;\n }\n }\n });\n\n if (scene.metadata) {\n scene.metadata.observable = resObs;\n } else {\n scene.metadata = { observable: resObs };\n }\n\n createParticleSystemForMesh(emitterMesh, scene, purpleStartColor, purpleMidColor, mouseTracker);\n createParticleSystemForMesh(emitterMesh2, scene, blueStartColor, blueMidColor, mouseTracker);\n\n}\n\n// Execute the flower creation function\nstart();\n\n\n// The core particle system definition.\nfunction createParticleSystemForMesh(\n emitterMesh: BABYLON.Mesh,\n scene: BABYLON.Scene,\n animStartColor: BABYLON.Color4,\n animMidColor: BABYLON.Color4,\n mouseTracker: { position: BABYLON.Vector3 | null }\n): BABYLON.ParticleSystem {\n\n const animEndColor = new BABYLON.Color4(0.1, 0.2, 0.8, 0.0);\n const DRIFTER_CHANCE = 0.07;\n const DRIFTER_SPEED = 0.4;\n\n const particleSystem = new BABYLON.ParticleSystem(\"particles_\" + emitterMesh.name, 25000, scene);\n particleSystem.particleTexture = new BABYLON.Texture(\"https://assets.babylonjs.com/textures/flare.png\", scene);\n particleSystem.emitter = emitterMesh;\n particleSystem.particleEmitterType = createUniformMeshParticleEmitter(emitterMesh);\n\n particleSystem.color1 = animEndColor.clone();\n particleSystem.color2 = animEndColor.clone();\n particleSystem.colorDead = animEndColor.clone();\n particleSystem.minSize = 0;\n particleSystem.maxSize = 0;\n particleSystem.blendMode = BABYLON.ParticleSystem.BLENDMODE_ONEONE;\n particleSystem.minLifeTime = 4.0;\n particleSystem.maxLifeTime = 8.0;\n particleSystem.emitRate = 2000;\n particleSystem.minEmitPower = 0.1;\n particleSystem.maxEmitPower = 0.5;\n particleSystem.gravity = new BABYLON.Vector3(0, -1.0, 0);\n (particleSystem as any).dragFactor = 0.97;\n\n particleSystem.updateFunction = function (particles) {\n const repulsionRadius = 20.0, repulsionStrength = 30;\n const scaledUpdateSpeed = this._scaledUpdateSpeed;\n const mousePickPosition = mouseTracker.position;\n const regularStartSize = 0.35, regularEndSize = 0.1;\n const largeStartSize = 0.8, largeEndSize = 0.2;\n\n for (let index = 0; index < particles.length; index++) {\n const particle = particles[index] as Particle;\n particle.age += scaledUpdateSpeed;\n if (particle.age >= particle.lifeTime) {\n particles.splice(index, 1); this._stockParticles.push(particle); index--; continue;\n }\n\n if (particle.age === scaledUpdateSpeed) {\n particle.isLarge = (Math.random() < 0.05);\n particle.isDrifter = (Math.random() < DRIFTER_CHANCE);\n if (particle.isDrifter) {\n const driftVector = new BABYLON.Vector3(Math.random() - 0.5, Math.random() - 0.5, Math.random() - 0.5);\n particle.driftDirection = driftVector.normalize();\n }\n }\n\n particle.direction.scaleInPlace(this.dragFactor);\n if (particle.isDrifter) {\n const driftForce = particle.driftDirection.scale(DRIFTER_SPEED * scaledUpdateSpeed);\n particle.direction.addInPlace(driftForce);\n } else {\n particle.direction.addInPlace(this.gravity.scale(scaledUpdateSpeed));\n }\n\n if (mousePickPosition) {\n const distance = BABYLON.Vector3.Distance(particle.position, mousePickPosition);\n if (distance < repulsionRadius) {\n const forceDirection = particle.position.subtract(mousePickPosition).normalize();\n const forceMagnitude = repulsionStrength * (1 - distance / repulsionRadius);\n const forceVector = forceDirection.scale(forceMagnitude * scaledUpdateSpeed);\n particle.direction.addInPlace(forceVector);\n }\n }\n\n particle.position.addInPlace(particle.direction.scale(scaledUpdateSpeed));\n\n const startSize = particle.isLarge ? largeStartSize : regularStartSize;\n const endSize = particle.isLarge ? largeEndSize : regularEndSize;\n const lifeRatio = particle.age / particle.lifeTime;\n const fadeInDuration = 0.1;\n\n if (lifeRatio < fadeInDuration) {\n const fadeInRatio = lifeRatio / fadeInDuration;\n particle.size = BABYLON.Scalar.Lerp(0, startSize, fadeInRatio);\n BABYLON.Color4.LerpToRef(animEndColor, animStartColor, fadeInRatio, particle.color);\n } else {\n const mainLifeRatio = (lifeRatio - fadeInDuration) / (1 - fadeInDuration);\n particle.size = BABYLON.Scalar.Lerp(startSize, endSize, mainLifeRatio);\n if (mainLifeRatio < 0.5) {\n BABYLON.Color4.LerpToRef(animStartColor, animMidColor, mainLifeRatio * 2, particle.color);\n } else {\n BABYLON.Color4.LerpToRef(animMidColor, animEndColor, (mainLifeRatio - 0.5) * 2, particle.color);\n }\n }\n }\n };\n\n particleSystem.start();\n return particleSystem;\n}\n\n// Creates a custom emitter to ensure particles are distributed evenly across a mesh surface.\nfunction createUniformMeshParticleEmitter(mesh: BABYLON.Mesh): BABYLON.CustomParticleEmitter {\n const positions = mesh.getVerticesData(BABYLON.VertexBuffer.PositionKind);\n const indices = mesh.getIndices();\n const totalFaces = indices.length / 3;\n const cumulativeTriangleAreas: number[] = [];\n let totalArea = 0;\n const vA = new BABYLON.Vector3(), vB = new BABYLON.Vector3(), vC = new BABYLON.Vector3();\n const edge1 = new BABYLON.Vector3(), edge2 = new BABYLON.Vector3();\n\n for (let i = 0; i < totalFaces; i++) {\n const indexA = indices[i * 3], indexB = indices[i * 3 + 1], indexC = indices[i * 3 + 2];\n BABYLON.Vector3.FromArrayToRef(positions, indexA * 3, vA);\n BABYLON.Vector3.FromArrayToRef(positions, indexB * 3, vB);\n BABYLON.Vector3.FromArrayToRef(positions, indexC * 3, vC);\n vB.subtractToRef(vA, edge1);\n vC.subtractToRef(vA, edge2);\n const area = BABYLON.Vector3.Cross(edge1, edge2).length() * 0.5;\n totalArea += area;\n cumulativeTriangleAreas.push(totalArea);\n }\n\n for (let i = 0; i < totalFaces; i++) cumulativeTriangleAreas[i] /= totalArea;\n\n const customEmitter = new BABYLON.CustomParticleEmitter();\n customEmitter.particlePositionGenerator = (index, particle, out) => {\n const random = Math.random();\n let triangleIndex = 0;\n for (let i = 0; i < totalFaces; i++) if (random < cumulativeTriangleAreas[i]) { triangleIndex = i; break; }\n const iA = indices[triangleIndex * 3], iB = indices[triangleIndex * 3 + 1], iC = indices[triangleIndex * 3 + 2];\n BABYLON.Vector3.FromArrayToRef(positions, iA * 3, vA);\n BABYLON.Vector3.FromArrayToRef(positions, iB * 3, vB);\n BABYLON.Vector3.FromArrayToRef(positions, iC * 3, vC);\n let r1 = Math.random(), r2 = Math.random();\n if (r1 + r2 > 1) { r1 = 1 - r1; r2 = 1 - r2; }\n vB.subtractToRef(vA, edge1);\n vC.subtractToRef(vA, edge2);\n out.copyFrom(vA).addInPlace(edge1.scaleInPlace(r1)).addInPlace(edge2.scaleInPlace(r2));\n };\n customEmitter.particleDestinationGenerator = (index, particle, out) => {\n out.set(Math.random() - 0.5, Math.random() - 0.5, Math.random() - 0.5);\n };\n return customEmitter;\n}\n","version":"0.21.0","type":"typescript"}} + script={{"script":"// Import required DTOs for creating curves, shapes, and operations\nconst { InterpolationDto, MirrorAlongNormalDto, ShapesDto, CompoundShapesDto,\n FaceFromWireDto, ThisckSolidSimpleDto, RotateDto } = Bit.Inputs.OCCT;\nconst { SceneTwoColorLinearGradientDto, DirectionalLightDto } = Bit.Inputs.BabylonScene;\nconst { gradientDirectionEnum } = Bit.Inputs.Base;\n\n// Import type definitions for type safety\ntype Point3 = Bit.Inputs.Base.Point3;\ntype Vector3 = Bit.Inputs.Base.Vector3;\ntype TopoDSWirePointer = Bit.Inputs.OCCT.TopoDSWirePointer;\ntype TopoDSFacePointer = Bit.Inputs.OCCT.TopoDSFacePointer;\ntype TopoDSShapePointer = Bit.Inputs.OCCT.TopoDSShapePointer;\n\ninterface Particle extends BABYLON.Particle {\n isLarge: boolean,\n isDrifter: boolean,\n driftDirection: BABYLON.Vector3\n}\n\n// Get access to OCCT modules and utility functions\nconst { wire, face, compound } = bitbybit.occt.shapes;\nconst { operations, transforms } = bitbybit.occt;\nconst { vector } = bitbybit;\nconst { scene } = bitbybit.babylon;\nconst { pbrMetallicRoughness } = bitbybit.babylon.material;\n\n\nconst createEnvironment = async () => {\n const dirLightOpt = new DirectionalLightDto();\n dirLightOpt.intensity = 3;\n scene.drawDirectionalLight(dirLightOpt);\n}\n\n// Define the main function to create a parametric flower\nconst start = async () => {\n createEnvironment();\n // Flower parameters - easily adjustable for different designs\n const thickness = 0.1; // Thickness of the flower petals\n const rotationStep = 60; // Degrees between each petal (12 petals total)\n const rotationAxis: Vector3 = [2, 2, 0]; // Axis for petal rotation\n\n // Define control points for the flower petal curve\n const controlPoints: Point3[] = [\n [0, 0, 0], // Start point (flower center)\n [5, 1.25, 7.5], // First control point (petal width)\n [2.75, -1.25, 17.5], // Second control point (petal curve)\n [0, 0, 25] // End point (petal tip)\n ];\n\n // Create interpolated curve through control points\n const curveOptions = new InterpolationDto();\n curveOptions.points = controlPoints;\n curveOptions.periodic = false;\n curveOptions.tolerance = 1e-7;\n const petalCurve = await wire.interpolatePoints(curveOptions);\n\n // Mirror the curve to create symmetry for the petal\n const mirrorOptions = new MirrorAlongNormalDto();\n mirrorOptions.shape = petalCurve;\n mirrorOptions.origin = [0, 0, 0];\n mirrorOptions.normal = [1, 0, 0]; // Mirror along X-axis\n const mirroredCurve = await transforms.mirrorAlongNormal(mirrorOptions);\n\n // Combine the original and mirrored curves into a single wire\n const combineOptions = new ShapesDto();\n combineOptions.shapes = [petalCurve, mirroredCurve];\n const combinedWire = await wire.combineEdgesAndWiresIntoAWire(combineOptions);\n\n // Create a face from the combined wire\n const faceOptions = new FaceFromWireDto();\n faceOptions.shape = combinedWire;\n faceOptions.planar = false; // Allow non-planar surface\n const petalFace = await face.createFaceFromWire(faceOptions);\n\n // Create a thick solid from the face\n const thickOptions = new ThisckSolidSimpleDto();\n thickOptions.shape = petalFace;\n thickOptions.offset = thickness;\n const thickPetal = await operations.makeThickSolidSimple(thickOptions);\n\n // Generate rotation angles for petals (0° to 360° in steps)\n const rotationAngles = vector.span({\n min: 0,\n max: 360,\n step: rotationStep\n });\n\n const rotationAngles2 = vector.span({\n min: 30,\n max: 360,\n step: rotationStep\n });\n\n // Create all flower petals by rotating the base petal\n const flowerPetalPromises: Promise[] = [];\n const flowerPetalPromises2: Promise[] = [];\n\n for (const angle of rotationAngles) {\n const rotateOptions = new RotateDto();\n rotateOptions.shape = thickPetal;\n rotateOptions.axis = rotationAxis;\n rotateOptions.angle = angle;\n\n const rotatedPetal = transforms.rotate(rotateOptions);\n flowerPetalPromises.push(rotatedPetal);\n }\n\n for (const angle of rotationAngles2) {\n const rotateOptions = new RotateDto();\n rotateOptions.shape = thickPetal;\n rotateOptions.axis = rotationAxis;\n rotateOptions.angle = angle;\n\n const rotatedPetal = transforms.rotate(rotateOptions);\n flowerPetalPromises2.push(rotatedPetal);\n }\n\n const flowerPetals = await Promise.all(flowerPetalPromises);\n const flowerPetals2 = await Promise.all(flowerPetalPromises2);\n\n // Combine all petals into a single compound shape\n const compoundOptions = new CompoundShapesDto();\n compoundOptions.shapes = flowerPetals;\n const flower = await compound.makeCompound(compoundOptions);\n compoundOptions.shapes = flowerPetals2;\n const flower2 = await compound.makeCompound(compoundOptions);\n\n const pbrOptions = new Bit.Inputs.BabylonMaterial.PBRMetallicRoughnessDto();\n pbrOptions.baseColor = \"#111111\";\n pbrOptions.metallic = 0.6;\n pbrOptions.roughness = 0.6;\n pbrOptions.alpha = 0.4;\n pbrOptions.zOffset = 2;\n const pbrMaterial = pbrMetallicRoughness.create(pbrOptions);\n\n const drawOpt = new Bit.Inputs.Draw.DrawOcctShapeMaterialOptions();\n drawOpt.faceMaterial = pbrMaterial;\n drawOpt.edgeColour = \"#ffffff\";\n drawOpt.drawEdges = true;\n drawOpt.precision = 0.1;\n\n // Draw the completed flower with material options\n const flowerMesh = await bitbybit.draw.drawAnyAsync({\n entity: flower,\n options: drawOpt\n });\n\n const flowerMesh2 = await bitbybit.draw.drawAnyAsync({\n entity: flower2,\n options: drawOpt\n });\n\n const emitterMesh = flowerMesh.getChildMeshes()[0] as BABYLON.Mesh;\n emitterMesh.isPickable = false;\n\n const emitterMesh2 = flowerMesh2.getChildMeshes()[0] as BABYLON.Mesh;\n emitterMesh2.isPickable = false;\n\n const scene = bitbybit.babylon.scene.getScene();\n\n const purpleStartColor = new BABYLON.Color4(0.7, 0.3, 1.0, 1.0);\n const purpleMidColor = new BABYLON.Color4(1.0, 0.4, 0.8, 1.0);\n\n const blueStartColor = new BABYLON.Color4(0.2, 0.7, 1.0, 1.0);\n const blueMidColor = new BABYLON.Color4(0.5, 0.8, 1.0, 1.0);\n\n // This object will be shared with both particle systems to track the mouse.\n const mouseTracker = { position: null as BABYLON.Vector3 | null };\n\n // Create all the 3D assets: emitters, particle systems, and the interaction plane.\n\n // Remove any old observable before adding a new one.\n if (scene.metadata && scene.metadata.observable) {\n scene.metadata.observable.remove();\n }\n\n // Centralized mouse interaction logic.\n const resObs = scene.onPointerObservable.add((pointerInfo) => {\n if (pointerInfo.type === BABYLON.PointerEventTypes.POINTERMOVE) {\n // We only check for hits against our single, invisible interaction plane.\n const pickInfo = scene.pick(scene.pointerX, scene.pointerY, (mesh) => mesh === emitterMesh);\n if (pickInfo.hit) {\n // If we hit the plane, update the shared tracker object's position.\n mouseTracker.position = pickInfo.pickedPoint;\n } else {\n // If the mouse is not over the plane, clear the position.\n mouseTracker.position = null;\n }\n }\n });\n\n if (scene.metadata) {\n scene.metadata.observable = resObs;\n } else {\n scene.metadata = { observable: resObs };\n }\n\n createParticleSystemForMesh(emitterMesh, scene, purpleStartColor, purpleMidColor, mouseTracker);\n createParticleSystemForMesh(emitterMesh2, scene, blueStartColor, blueMidColor, mouseTracker);\n\n}\n\n// Execute the flower creation function\nstart();\n\n\n// The core particle system definition.\nfunction createParticleSystemForMesh(\n emitterMesh: BABYLON.Mesh,\n scene: BABYLON.Scene,\n animStartColor: BABYLON.Color4,\n animMidColor: BABYLON.Color4,\n mouseTracker: { position: BABYLON.Vector3 | null }\n): BABYLON.ParticleSystem {\n\n const animEndColor = new BABYLON.Color4(0.1, 0.2, 0.8, 0.0);\n const DRIFTER_CHANCE = 0.07;\n const DRIFTER_SPEED = 0.4;\n\n const particleSystem = new BABYLON.ParticleSystem(\"particles_\" + emitterMesh.name, 25000, scene);\n particleSystem.particleTexture = new BABYLON.Texture(\"https://assets.babylonjs.com/textures/flare.png\", scene);\n particleSystem.emitter = emitterMesh;\n particleSystem.particleEmitterType = createUniformMeshParticleEmitter(emitterMesh);\n\n particleSystem.color1 = animEndColor.clone();\n particleSystem.color2 = animEndColor.clone();\n particleSystem.colorDead = animEndColor.clone();\n particleSystem.minSize = 0;\n particleSystem.maxSize = 0;\n particleSystem.blendMode = BABYLON.ParticleSystem.BLENDMODE_ONEONE;\n particleSystem.minLifeTime = 4.0;\n particleSystem.maxLifeTime = 8.0;\n particleSystem.emitRate = 2000;\n particleSystem.minEmitPower = 0.1;\n particleSystem.maxEmitPower = 0.5;\n particleSystem.gravity = new BABYLON.Vector3(0, -1.0, 0);\n (particleSystem as any).dragFactor = 0.97;\n\n particleSystem.updateFunction = function (particles) {\n const repulsionRadius = 20.0, repulsionStrength = 30;\n const scaledUpdateSpeed = this._scaledUpdateSpeed;\n const mousePickPosition = mouseTracker.position;\n const regularStartSize = 0.35, regularEndSize = 0.1;\n const largeStartSize = 0.8, largeEndSize = 0.2;\n\n for (let index = 0; index < particles.length; index++) {\n const particle = particles[index] as Particle;\n particle.age += scaledUpdateSpeed;\n if (particle.age >= particle.lifeTime) {\n particles.splice(index, 1); this._stockParticles.push(particle); index--; continue;\n }\n\n if (particle.age === scaledUpdateSpeed) {\n particle.isLarge = (Math.random() < 0.05);\n particle.isDrifter = (Math.random() < DRIFTER_CHANCE);\n if (particle.isDrifter) {\n const driftVector = new BABYLON.Vector3(Math.random() - 0.5, Math.random() - 0.5, Math.random() - 0.5);\n particle.driftDirection = driftVector.normalize();\n }\n }\n\n particle.direction.scaleInPlace(this.dragFactor);\n if (particle.isDrifter) {\n const driftForce = particle.driftDirection.scale(DRIFTER_SPEED * scaledUpdateSpeed);\n particle.direction.addInPlace(driftForce);\n } else {\n particle.direction.addInPlace(this.gravity.scale(scaledUpdateSpeed));\n }\n\n if (mousePickPosition) {\n const distance = BABYLON.Vector3.Distance(particle.position, mousePickPosition);\n if (distance < repulsionRadius) {\n const forceDirection = particle.position.subtract(mousePickPosition).normalize();\n const forceMagnitude = repulsionStrength * (1 - distance / repulsionRadius);\n const forceVector = forceDirection.scale(forceMagnitude * scaledUpdateSpeed);\n particle.direction.addInPlace(forceVector);\n }\n }\n\n particle.position.addInPlace(particle.direction.scale(scaledUpdateSpeed));\n\n const startSize = particle.isLarge ? largeStartSize : regularStartSize;\n const endSize = particle.isLarge ? largeEndSize : regularEndSize;\n const lifeRatio = particle.age / particle.lifeTime;\n const fadeInDuration = 0.1;\n\n if (lifeRatio < fadeInDuration) {\n const fadeInRatio = lifeRatio / fadeInDuration;\n particle.size = BABYLON.Scalar.Lerp(0, startSize, fadeInRatio);\n BABYLON.Color4.LerpToRef(animEndColor, animStartColor, fadeInRatio, particle.color);\n } else {\n const mainLifeRatio = (lifeRatio - fadeInDuration) / (1 - fadeInDuration);\n particle.size = BABYLON.Scalar.Lerp(startSize, endSize, mainLifeRatio);\n if (mainLifeRatio < 0.5) {\n BABYLON.Color4.LerpToRef(animStartColor, animMidColor, mainLifeRatio * 2, particle.color);\n } else {\n BABYLON.Color4.LerpToRef(animMidColor, animEndColor, (mainLifeRatio - 0.5) * 2, particle.color);\n }\n }\n }\n };\n\n particleSystem.start();\n return particleSystem;\n}\n\n// Creates a custom emitter to ensure particles are distributed evenly across a mesh surface.\nfunction createUniformMeshParticleEmitter(mesh: BABYLON.Mesh): BABYLON.CustomParticleEmitter {\n const positions = mesh.getVerticesData(BABYLON.VertexBuffer.PositionKind);\n const indices = mesh.getIndices();\n const totalFaces = indices.length / 3;\n const cumulativeTriangleAreas: number[] = [];\n let totalArea = 0;\n const vA = new BABYLON.Vector3(), vB = new BABYLON.Vector3(), vC = new BABYLON.Vector3();\n const edge1 = new BABYLON.Vector3(), edge2 = new BABYLON.Vector3();\n\n for (let i = 0; i < totalFaces; i++) {\n const indexA = indices[i * 3], indexB = indices[i * 3 + 1], indexC = indices[i * 3 + 2];\n BABYLON.Vector3.FromArrayToRef(positions, indexA * 3, vA);\n BABYLON.Vector3.FromArrayToRef(positions, indexB * 3, vB);\n BABYLON.Vector3.FromArrayToRef(positions, indexC * 3, vC);\n vB.subtractToRef(vA, edge1);\n vC.subtractToRef(vA, edge2);\n const area = BABYLON.Vector3.Cross(edge1, edge2).length() * 0.5;\n totalArea += area;\n cumulativeTriangleAreas.push(totalArea);\n }\n\n for (let i = 0; i < totalFaces; i++) cumulativeTriangleAreas[i] /= totalArea;\n\n const customEmitter = new BABYLON.CustomParticleEmitter();\n customEmitter.particlePositionGenerator = (index, particle, out) => {\n const random = Math.random();\n let triangleIndex = 0;\n for (let i = 0; i < totalFaces; i++) if (random < cumulativeTriangleAreas[i]) { triangleIndex = i; break; }\n const iA = indices[triangleIndex * 3], iB = indices[triangleIndex * 3 + 1], iC = indices[triangleIndex * 3 + 2];\n BABYLON.Vector3.FromArrayToRef(positions, iA * 3, vA);\n BABYLON.Vector3.FromArrayToRef(positions, iB * 3, vB);\n BABYLON.Vector3.FromArrayToRef(positions, iC * 3, vC);\n let r1 = Math.random(), r2 = Math.random();\n if (r1 + r2 > 1) { r1 = 1 - r1; r2 = 1 - r2; }\n vB.subtractToRef(vA, edge1);\n vC.subtractToRef(vA, edge2);\n out.copyFrom(vA).addInPlace(edge1.scaleInPlace(r1)).addInPlace(edge2.scaleInPlace(r2));\n };\n customEmitter.particleDestinationGenerator = (index, particle, out) => {\n out.set(Math.random() - 0.5, Math.random() - 0.5, Math.random() - 0.5);\n };\n return customEmitter;\n}\n","version":"0.21.1","type":"typescript"}} title="Simple flower" /> diff --git a/docs/learn/code/common/occt/operations/advanced-loft.md b/docs/learn/code/common/occt/operations/advanced-loft.md index 79c53970..53c38008 100644 --- a/docs/learn/code/common/occt/operations/advanced-loft.md +++ b/docs/learn/code/common/occt/operations/advanced-loft.md @@ -45,21 +45,21 @@ Here's a breakdown of the process described: nrCornerswire1wire2wire3nrCorners10151515030117910001000100010003wire1000010nrCorners31wire2030010nrCorners10.3wire3070010nrCorners60.5wire3wire2wire1FALSEFALSEFALSEFALSE10FALSE31e-7'approxChordLength'01000-300.01TRUE#cc33ccTRUE#ffffff2","version":"0.21.0","type":"blockly"}} + script={{"script":"nrCornerswire1wire2wire3nrCorners10151515030117910001000100010003wire1000010nrCorners31wire2030010nrCorners10.3wire3070010nrCorners60.5wire3wire2wire1FALSEFALSEFALSEFALSE10FALSE31e-7'approxChordLength'01000-300.01TRUE#cc33ccTRUE#ffffff2","version":"0.21.1","type":"blockly"}} title="Advanced Loft Operation" /> {\n\n // --- 1. Camera Configuration ---\n // Create a new configuration object for the scene's Arc Rotate Camera.\n const arcCameraOptions = new CameraConfigurationDto();\n // Set the camera's position in 3D space (x, y, z).\n arcCameraOptions.position = [15, 15, 15];\n // Set the point the camera will look at.\n arcCameraOptions.lookAt = [0, 3, 0];\n // Apply these settings to the active camera in the scene.\n scene.adjustActiveArcRotateCamera(arcCameraOptions);\n\n // Define the number of corners for the polygonal profiles.\n const nrCorners = 10;\n\n // --- 2. Create the First Profile (Bottom) ---\n // Create a DTO to define an n-sided polygon wire.\n const ngonOpt = new NGonWireDto();\n ngonOpt.nrCorners = nrCorners;\n ngonOpt.radius = 3;\n // Asynchronously create the first polygon wire shape at the default center [0,0,0].\n const wire1 = await wire.createNGonWire(ngonOpt);\n\n // Create a DTO for a 2D fillet operation to round the corners of a wire.\n const filletOpt = new FilletDto();\n filletOpt.radius = 0.3; // The radius of the rounded corners.\n filletOpt.shape = wire1; // Specify that the fillet should be applied to wire1.\n // Asynchronously apply the fillet and store the new, smoothed wire.\n const filletedWire1 = await fillets.fillet2d(filletOpt);\n\n // --- 3. Create the Second Profile (Middle) ---\n // Reuse the ngonOpt DTO but modify its properties for the next shape.\n ngonOpt.center = [0, 3, 0]; // Move the center up along the Y-axis.\n ngonOpt.radius = 1; // Make this polygon smaller.\n const wire2 = await wire.createNGonWire(ngonOpt);\n\n // Reuse the filletOpt DTO to apply the same fillet radius to the new wire.\n filletOpt.shape = wire2;\n const filletedWire2 = await fillets.fillet2d(filletOpt);\n\n // --- 4. Create the Third Profile (Top) ---\n // Reuse and modify the DTOs again for the third and final profile.\n ngonOpt.center = [0, 7, 0]; // Move this one even higher.\n ngonOpt.radius = 6; // Make this polygon the largest.\n const wire3 = await wire.createNGonWire(ngonOpt);\n\n // Use a larger fillet radius for this larger wire.\n filletOpt.radius = 0.5;\n filletOpt.shape = wire3;\n const filletedWire3 = await fillets.fillet2d(filletOpt);\n\n // --- 5. Perform the Loft Operation ---\n // A loft creates a 3D solid by connecting a series of 2D profiles.\n const loftAdvancedOptions = new LoftAdvancedDto();\n // Specify a single point where the loft should begin, creating a pointed top.\n loftAdvancedOptions.startVertex = [0, 10, 0];\n // Specify a single point where the loft should end, creating a pointed bottom.\n loftAdvancedOptions.endVertex = [0, -3, 0];\n // Provide the array of profiles to connect. The order matters.\n loftAdvancedOptions.shapes = [filletedWire3, filletedWire2, filletedWire1];\n // Asynchronously execute the loft operation to create the final 3D shape.\n const loftedShape = await operations.loftAdvanced(loftAdvancedOptions)\n\n // --- 6. Draw the Final Shape ---\n // Create a DTO to define how the shape should be drawn.\n const drawOptions = new DrawOcctShapeSimpleOptions();\n // Set the color of the shape's faces to magenta.\n drawOptions.faceColour = \"#ff00ff\";\n\n // Call the generic drawing function to render the OCCT shape in the scene.\n bitbybit.draw.drawAnyAsync({\n entity: loftedShape, // The shape to draw.\n options: drawOptions // The drawing options to apply.\n });\n\n}\n\n// Execute the main function to start the script.\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"\n// Import DTOs for configuring various operations. DTOs are objects used to pass data.\n// Import camera configuration for setting up the scene view.\nconst { CameraConfigurationDto } = Bit.Inputs.BabylonScene;\n// Import DTOs for OpenCASCADE (OCCT) geometric modeling: creating polygons, fillets, and lofts.\nconst { NGonWireDto, FilletDto, LoftAdvancedDto } = Bit.Inputs.OCCT;\n// Import DTO for specifying drawing options, like color and opacity.\nconst { DrawOcctShapeSimpleOptions } = Bit.Inputs.Draw;\n// Import a specific type for an OCCT wire, ensuring type safety in our code.\ntype TopoDSWirePointer = Bit.Inputs.OCCT.TopoDSWirePointer;\n\n// Destructure the bitbybit API to get direct access to its main modules.\n// 'scene' provides access to BabylonJS scene controls.\nconst { scene } = bitbybit.babylon;\n// 'wire', 'fillets', and 'operations' are part of the OCCT module for creating and manipulating shapes.\nconst { wire } = bitbybit.occt.shapes;\nconst { fillets, operations } = bitbybit.occt;\n\n// Define an asynchronous function to execute the main logic.\n// Using async/await is necessary because geometry creation and drawing are non-blocking operations.\nconst start = async () => {\n\n // --- 1. Camera Configuration ---\n // Create a new configuration object for the scene's Arc Rotate Camera.\n const arcCameraOptions = new CameraConfigurationDto();\n // Set the camera's position in 3D space (x, y, z).\n arcCameraOptions.position = [15, 15, 15];\n // Set the point the camera will look at.\n arcCameraOptions.lookAt = [0, 3, 0];\n // Apply these settings to the active camera in the scene.\n scene.adjustActiveArcRotateCamera(arcCameraOptions);\n\n // Define the number of corners for the polygonal profiles.\n const nrCorners = 10;\n\n // --- 2. Create the First Profile (Bottom) ---\n // Create a DTO to define an n-sided polygon wire.\n const ngonOpt = new NGonWireDto();\n ngonOpt.nrCorners = nrCorners;\n ngonOpt.radius = 3;\n // Asynchronously create the first polygon wire shape at the default center [0,0,0].\n const wire1 = await wire.createNGonWire(ngonOpt);\n\n // Create a DTO for a 2D fillet operation to round the corners of a wire.\n const filletOpt = new FilletDto();\n filletOpt.radius = 0.3; // The radius of the rounded corners.\n filletOpt.shape = wire1; // Specify that the fillet should be applied to wire1.\n // Asynchronously apply the fillet and store the new, smoothed wire.\n const filletedWire1 = await fillets.fillet2d(filletOpt);\n\n // --- 3. Create the Second Profile (Middle) ---\n // Reuse the ngonOpt DTO but modify its properties for the next shape.\n ngonOpt.center = [0, 3, 0]; // Move the center up along the Y-axis.\n ngonOpt.radius = 1; // Make this polygon smaller.\n const wire2 = await wire.createNGonWire(ngonOpt);\n\n // Reuse the filletOpt DTO to apply the same fillet radius to the new wire.\n filletOpt.shape = wire2;\n const filletedWire2 = await fillets.fillet2d(filletOpt);\n\n // --- 4. Create the Third Profile (Top) ---\n // Reuse and modify the DTOs again for the third and final profile.\n ngonOpt.center = [0, 7, 0]; // Move this one even higher.\n ngonOpt.radius = 6; // Make this polygon the largest.\n const wire3 = await wire.createNGonWire(ngonOpt);\n\n // Use a larger fillet radius for this larger wire.\n filletOpt.radius = 0.5;\n filletOpt.shape = wire3;\n const filletedWire3 = await fillets.fillet2d(filletOpt);\n\n // --- 5. Perform the Loft Operation ---\n // A loft creates a 3D solid by connecting a series of 2D profiles.\n const loftAdvancedOptions = new LoftAdvancedDto();\n // Specify a single point where the loft should begin, creating a pointed top.\n loftAdvancedOptions.startVertex = [0, 10, 0];\n // Specify a single point where the loft should end, creating a pointed bottom.\n loftAdvancedOptions.endVertex = [0, -3, 0];\n // Provide the array of profiles to connect. The order matters.\n loftAdvancedOptions.shapes = [filletedWire3, filletedWire2, filletedWire1];\n // Asynchronously execute the loft operation to create the final 3D shape.\n const loftedShape = await operations.loftAdvanced(loftAdvancedOptions)\n\n // --- 6. Draw the Final Shape ---\n // Create a DTO to define how the shape should be drawn.\n const drawOptions = new DrawOcctShapeSimpleOptions();\n // Set the color of the shape's faces to magenta.\n drawOptions.faceColour = \"#ff00ff\";\n\n // Call the generic drawing function to render the OCCT shape in the scene.\n bitbybit.draw.drawAnyAsync({\n entity: loftedShape, // The shape to draw.\n options: drawOptions // The drawing options to apply.\n });\n\n}\n\n// Execute the main function to start the script.\nstart();","version":"0.21.1","type":"typescript"}} title="Advanced Loft Operation" /> diff --git a/docs/learn/code/common/occt/operations/extrusions.md b/docs/learn/code/common/occt/operations/extrusions.md index 34ab5df5..2f90d476 100644 --- a/docs/learn/code/common/occt/operations/extrusions.md +++ b/docs/learn/code/common/occt/operations/extrusions.md @@ -35,21 +35,21 @@ By understanding extrusion, you gain a powerful tool for your 3D modeling toolki heightheight40000107740FALSE0.50height0","version":"0.21.0","type":"blockly"}} + script={{"script":"heightheight40000107740FALSE0.50height0","version":"0.21.1","type":"blockly"}} title="Extrude the wire into shell kind of shape" /> {\n\n // Define a constant 'height' for the extrusion operation.\n const height = 4;\n\n // Create a new StarDto instance to configure the properties of a star-shaped wire.\n const starOpt = new StarDto();\n // Set the inner radius of the star.\n starOpt.innerRadius = 4;\n // Set the outer radius of the star.\n starOpt.outerRadius = 7;\n // Asynchronously create the star-shaped wire using the configured options.\n // The 'await' keyword pauses execution until the wire creation is complete.\n // Bitbybit runs such CAD operations in the worker thread, which doesn't block UI\n // and is usually faster.\n const star = await wire.createStarWire(starOpt);\n\n // Create a new FilletDto instance to configure a 2D fillet operation.\n // The generic type specifies that this fillet will be applied to a wire.\n const filletOpt = new FilletDto();\n // Set the shape to be filleted to the previously created star wire.\n filletOpt.shape = star;\n // Set the radius for the fillet (rounding of corners).\n filletOpt.radius = 0.5;\n // Asynchronously apply the 2D fillet to the star wire.\n const roundedStar = await fillets.fillet2d(filletOpt);\n\n // Create a new ExtrudeDto instance to configure an extrusion operation.\n // The generic type specifies that a wire will be extruded.\n const extrudeOpt = new ExtrudeDto();\n // Set the shape to be extruded to the previously created rounded star wire.\n extrudeOpt.shape = roundedStar;\n // Set the direction and magnitude of the extrusion as a 3D vector [x, y, z].\n // Here, it extrudes along the Y-axis by the value of 'height'.\n extrudeOpt.direction = [0, height, 0];\n // Asynchronously perform the extrusion operation on the rounded star wire.\n const extrudedRoundStar = await operations.extrude(extrudeOpt);\n\n // Asynchronously draw the final extruded shape in the 3D scene.\n // 'entity' specifies the shape to be drawn.\n bitbybit.draw.drawAnyAsync({ entity: extrudedRoundStar });\n\n}\n\n// Call the 'start' function to execute the script.\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"// Import the 'wire' module for creating wire shapes from the OCCT (OpenCASCADE Technology) library.\nconst { wire } = bitbybit.occt.shapes;\n// Import 'fillets' and 'operations' modules for performing filleting and extrusion operations on OCCT shapes.\nconst { fillets, operations } = bitbybit.occt;\n// Import Data Transfer Objects (DTOs) for configuring star creation, filleting, and extrusion.\n// DTOs are used to pass parameters to the respective functions.\nconst { StarDto, FilletDto, ExtrudeDto } = Bit.Inputs.OCCT;\n// Define a type alias for a pointer to a TopoDS_Wire, which is an OCCT data structure representing a wire.\ntype TopoDSWirePointer = Bit.Inputs.OCCT.TopoDSWirePointer;\n\n// Define an asynchronous function named 'start' which will contain the main logic for creating and drawing the shape.\n// The 'async' keyword allows the use of 'await' for operations that might take time, like geometry creation.\nconst start = async () => {\n\n // Define a constant 'height' for the extrusion operation.\n const height = 4;\n\n // Create a new StarDto instance to configure the properties of a star-shaped wire.\n const starOpt = new StarDto();\n // Set the inner radius of the star.\n starOpt.innerRadius = 4;\n // Set the outer radius of the star.\n starOpt.outerRadius = 7;\n // Asynchronously create the star-shaped wire using the configured options.\n // The 'await' keyword pauses execution until the wire creation is complete.\n // Bitbybit runs such CAD operations in the worker thread, which doesn't block UI\n // and is usually faster.\n const star = await wire.createStarWire(starOpt);\n\n // Create a new FilletDto instance to configure a 2D fillet operation.\n // The generic type specifies that this fillet will be applied to a wire.\n const filletOpt = new FilletDto();\n // Set the shape to be filleted to the previously created star wire.\n filletOpt.shape = star;\n // Set the radius for the fillet (rounding of corners).\n filletOpt.radius = 0.5;\n // Asynchronously apply the 2D fillet to the star wire.\n const roundedStar = await fillets.fillet2d(filletOpt);\n\n // Create a new ExtrudeDto instance to configure an extrusion operation.\n // The generic type specifies that a wire will be extruded.\n const extrudeOpt = new ExtrudeDto();\n // Set the shape to be extruded to the previously created rounded star wire.\n extrudeOpt.shape = roundedStar;\n // Set the direction and magnitude of the extrusion as a 3D vector [x, y, z].\n // Here, it extrudes along the Y-axis by the value of 'height'.\n extrudeOpt.direction = [0, height, 0];\n // Asynchronously perform the extrusion operation on the rounded star wire.\n const extrudedRoundStar = await operations.extrude(extrudeOpt);\n\n // Asynchronously draw the final extruded shape in the 3D scene.\n // 'entity' specifies the shape to be drawn.\n bitbybit.draw.drawAnyAsync({ entity: extrudedRoundStar });\n\n}\n\n// Call the 'start' function to execute the script.\nstart();","version":"0.21.1","type":"typescript"}} title="Extrude the wire into shell kind of shape" /> @@ -69,21 +69,21 @@ In the following examples, we first construct a complex wire, then create a plan heightheight4000010070000100520FALSEFALSETRUETRUE0height0","version":"0.21.0","type":"blockly"}} + script={{"script":"heightheight4000010070000100520FALSEFALSETRUETRUE0height0","version":"0.21.1","type":"blockly"}} title="Extrude the face into solid shape" /> {\n\n const height = 4;\n\n const heartOpt = new Heart2DDto();\n heartOpt.sizeApprox = 7;\n const heart1 = await wire.createHeartWire(heartOpt);\n\n heartOpt.sizeApprox = 5;\n const heart2 = await wire.createHeartWire(heartOpt);\n\n const zigZagOpt = new ZigZagBetweenTwoWiresDto(heart1, heart2, 31);\n const zigZagWire = await wire.createZigZagBetweenTwoWires(zigZagOpt);\n\n const faceFromWireOpt = new FaceFromWireDto(zigZagWire, true);\n const zigZagFace = await face.createFaceFromWire(faceFromWireOpt);\n \n const extrudeOpt = new ExtrudeDto();\n extrudeOpt.shape = zigZagFace;\n extrudeOpt.direction = [0, height, 0];\n const extrudedZigZag = await operations.extrude(extrudeOpt);\n\n bitbybit.draw.drawAnyAsync({ entity: extrudedZigZag });\n\n}\n\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"const { wire, face } = bitbybit.occt.shapes;\nconst { fillets, operations } = bitbybit.occt;\nconst { FilletDto, ExtrudeDto, Heart2DDto, ZigZagBetweenTwoWiresDto, FaceFromWireDto } = Bit.Inputs.OCCT;\ntype TopoDSWirePointer = Bit.Inputs.OCCT.TopoDSWirePointer;\ntype TopoDSFacePointer = Bit.Inputs.OCCT.TopoDSFacePointer;\nconst start = async () => {\n\n const height = 4;\n\n const heartOpt = new Heart2DDto();\n heartOpt.sizeApprox = 7;\n const heart1 = await wire.createHeartWire(heartOpt);\n\n heartOpt.sizeApprox = 5;\n const heart2 = await wire.createHeartWire(heartOpt);\n\n const zigZagOpt = new ZigZagBetweenTwoWiresDto(heart1, heart2, 31);\n const zigZagWire = await wire.createZigZagBetweenTwoWires(zigZagOpt);\n\n const faceFromWireOpt = new FaceFromWireDto(zigZagWire, true);\n const zigZagFace = await face.createFaceFromWire(faceFromWireOpt);\n \n const extrudeOpt = new ExtrudeDto();\n extrudeOpt.shape = zigZagFace;\n extrudeOpt.direction = [0, height, 0];\n const extrudedZigZag = await operations.extrude(extrudeOpt);\n\n bitbybit.draw.drawAnyAsync({ entity: extrudedZigZag });\n\n}\n\nstart();","version":"0.21.1","type":"typescript"}} title="Extrude the face into solid shape" /> diff --git a/docs/learn/code/common/occt/operations/offset-operations.md b/docs/learn/code/common/occt/operations/offset-operations.md index a4320400..e97de720 100644 --- a/docs/learn/code/common/occt/operations/offset-operations.md +++ b/docs/learn/code/common/occt/operations/offset-operations.md @@ -44,21 +44,21 @@ Key parameters for wire offset include: hexagonoffsetDistanceoffsetShapehexagon00001046offsetDistance1.2offsetShapehexagonoffsetDistance0.1hexagon#00ff004offsetShape#ff00004","version":"0.21.0","type":"blockly"}} + script={{"script":"hexagonoffsetDistanceoffsetShapehexagon00001046offsetDistance1.2offsetShapehexagonoffsetDistance0.1hexagon#00ff004offsetShape#ff00004","version":"0.21.1","type":"blockly"}} title="Basic Wire Offset Operation" /> {\n\n // Define the offset distance - positive values expand the shape, negative values contract it\n const offsetDistance = 1.2;\n\n // Create a new NGonWireDto instance to configure a hexagonal wire\n const hexagonOpt = new Bit.Inputs.OCCT.NGonWireDto();\n // Set the center point of the polygon\n hexagonOpt.center = [0, 0, 0];\n // Set the direction vector (normal to the plane of the polygon)\n hexagonOpt.direction = [0, 1, 0];\n // Set the radius from center to vertices\n hexagonOpt.radius = 4;\n // Set the number of corners (6 for hexagon)\n hexagonOpt.nrCorners = 6;\n \n // Create the hexagonal wire\n const hexagon = await wire.createNGonWire(hexagonOpt);\n\n // Create a new OffsetDto instance to configure the offset operation\n const offsetOpt = new OffsetDto();\n // Set the shape to be offset\n offsetOpt.shape = hexagon;\n // Set the offset distance (positive = outward, negative = inward)\n offsetOpt.distance = offsetDistance;\n // Set the tolerance for the offset calculation\n offsetOpt.tolerance = 0.1;\n \n // Perform the offset operation\n const offsetShape = await operations.offset(offsetOpt);\n\n // Draw both the original and offset shapes with different colors for comparison\n const originalOptions = new Bit.Inputs.Draw.DrawOcctShapeSimpleOptions();\n originalOptions.edgeWidth = 4;\n originalOptions.edgeColour = \"#00ff00\"; // Green for original\n \n const offsetOptions = new Bit.Inputs.Draw.DrawOcctShapeSimpleOptions();\n offsetOptions.edgeWidth = 4;\n offsetOptions.edgeColour = \"#ff0000\"; // Red for offset\n \n bitbybit.draw.drawAnyAsync({ entity: hexagon, options: originalOptions });\n bitbybit.draw.drawAnyAsync({ entity: offsetShape, options: offsetOptions });\n\n}\n\n// Call the 'start' function to execute the script\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"// Import the 'wire' module for creating wire shapes from the OCCT library\nconst { wire } = bitbybit.occt.shapes;\n// Import the 'operations' module for offset operations\nconst { operations } = bitbybit.occt;\n// Import Data Transfer Objects (DTOs) for configuring polygon creation and offset operations\nconst { NGonWireDto, OffsetDto } = Bit.Inputs.OCCT;\n// Define a type alias for a pointer to a TopoDS_Wire\ntype TopoDSWirePointer = Bit.Inputs.OCCT.TopoDSWirePointer;\n\n// Define an asynchronous function named 'start' which will contain the main logic\nconst start = async () => {\n\n // Define the offset distance - positive values expand the shape, negative values contract it\n const offsetDistance = 1.2;\n\n // Create a new NGonWireDto instance to configure a hexagonal wire\n const hexagonOpt = new Bit.Inputs.OCCT.NGonWireDto();\n // Set the center point of the polygon\n hexagonOpt.center = [0, 0, 0];\n // Set the direction vector (normal to the plane of the polygon)\n hexagonOpt.direction = [0, 1, 0];\n // Set the radius from center to vertices\n hexagonOpt.radius = 4;\n // Set the number of corners (6 for hexagon)\n hexagonOpt.nrCorners = 6;\n \n // Create the hexagonal wire\n const hexagon = await wire.createNGonWire(hexagonOpt);\n\n // Create a new OffsetDto instance to configure the offset operation\n const offsetOpt = new OffsetDto();\n // Set the shape to be offset\n offsetOpt.shape = hexagon;\n // Set the offset distance (positive = outward, negative = inward)\n offsetOpt.distance = offsetDistance;\n // Set the tolerance for the offset calculation\n offsetOpt.tolerance = 0.1;\n \n // Perform the offset operation\n const offsetShape = await operations.offset(offsetOpt);\n\n // Draw both the original and offset shapes with different colors for comparison\n const originalOptions = new Bit.Inputs.Draw.DrawOcctShapeSimpleOptions();\n originalOptions.edgeWidth = 4;\n originalOptions.edgeColour = \"#00ff00\"; // Green for original\n \n const offsetOptions = new Bit.Inputs.Draw.DrawOcctShapeSimpleOptions();\n offsetOptions.edgeWidth = 4;\n offsetOptions.edgeColour = \"#ff0000\"; // Red for offset\n \n bitbybit.draw.drawAnyAsync({ entity: hexagon, options: originalOptions });\n bitbybit.draw.drawAnyAsync({ entity: offsetShape, options: offsetOptions });\n\n}\n\n// Call the 'start' function to execute the script\nstart();","version":"0.21.1","type":"typescript"}} title="Basic Wire Offset Operation" /> @@ -83,21 +83,21 @@ The join types available are: starWireoffsetDistanceoffsetShapestarWire000010531.50FALSEoffsetDistance0.8offsetShapestarWireoffsetDistance0.1intersectionFALSEstarWire#00ff004offsetShape#ff00004","version":"0.21.0","type":"blockly"}} + script={{"script":"starWireoffsetDistanceoffsetShapestarWire000010531.50FALSEoffsetDistance0.8offsetShapestarWireoffsetDistance0.1intersectionFALSEstarWire#00ff004offsetShape#ff00004","version":"0.21.1","type":"blockly"}} title="Advanced Offset with Join Type Control" /> {\n\n // Define the offset distance\n const offsetDistance = 0.8;\n\n // Create a star-shaped wire for demonstration\n const starOpt = new StarDto();\n starOpt.center = [0, 0, 0];\n starOpt.direction = [0, 1, 0];\n starOpt.numRays = 5;\n starOpt.outerRadius = 3;\n starOpt.innerRadius = 1.5;\n \n const starWire = await wire.createStarWire(starOpt);\n\n // Create an advanced offset with specific join type\n const offsetAdvOpt = new OffsetAdvancedDto();\n offsetAdvOpt.shape = starWire;\n offsetAdvOpt.distance = offsetDistance;\n offsetAdvOpt.tolerance = 0.1;\n // Set join type to 'intersection' for sharp corners\n // Other options: 'arc' (rounded), 'tangent' (beveled)\n offsetAdvOpt.joinType = Bit.Inputs.OCCT.joinTypeEnum.intersection;\n offsetAdvOpt.removeIntEdges = false;\n \n const offsetShape = await operations.offsetAdv(offsetAdvOpt);\n\n // Draw both shapes with different colors for comparison\n const originalOptions = new Bit.Inputs.Draw.DrawOcctShapeSimpleOptions();\n originalOptions.edgeWidth = 4;\n originalOptions.edgeColour = \"#00ff00\"; // Green for original\n \n const offsetOptions = new Bit.Inputs.Draw.DrawOcctShapeSimpleOptions();\n offsetOptions.edgeWidth = 4;\n offsetOptions.edgeColour = \"#ff0000\"; // Red for offset\n \n bitbybit.draw.drawAnyAsync({ entity: starWire, options: originalOptions });\n bitbybit.draw.drawAnyAsync({ entity: offsetShape, options: offsetOptions });\n\n}\n\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"// Import required modules for wire creation and operations\nconst { wire } = bitbybit.occt.shapes;\nconst { operations } = bitbybit.occt;\n// Import DTOs and enums for star creation and advanced offset\nconst { StarDto, OffsetAdvancedDto } = Bit.Inputs.OCCT;\ntype TopoDSWirePointer = Bit.Inputs.OCCT.TopoDSWirePointer;\n\nconst start = async () => {\n\n // Define the offset distance\n const offsetDistance = 0.8;\n\n // Create a star-shaped wire for demonstration\n const starOpt = new StarDto();\n starOpt.center = [0, 0, 0];\n starOpt.direction = [0, 1, 0];\n starOpt.numRays = 5;\n starOpt.outerRadius = 3;\n starOpt.innerRadius = 1.5;\n \n const starWire = await wire.createStarWire(starOpt);\n\n // Create an advanced offset with specific join type\n const offsetAdvOpt = new OffsetAdvancedDto();\n offsetAdvOpt.shape = starWire;\n offsetAdvOpt.distance = offsetDistance;\n offsetAdvOpt.tolerance = 0.1;\n // Set join type to 'intersection' for sharp corners\n // Other options: 'arc' (rounded), 'tangent' (beveled)\n offsetAdvOpt.joinType = Bit.Inputs.OCCT.joinTypeEnum.intersection;\n offsetAdvOpt.removeIntEdges = false;\n \n const offsetShape = await operations.offsetAdv(offsetAdvOpt);\n\n // Draw both shapes with different colors for comparison\n const originalOptions = new Bit.Inputs.Draw.DrawOcctShapeSimpleOptions();\n originalOptions.edgeWidth = 4;\n originalOptions.edgeColour = \"#00ff00\"; // Green for original\n \n const offsetOptions = new Bit.Inputs.Draw.DrawOcctShapeSimpleOptions();\n offsetOptions.edgeWidth = 4;\n offsetOptions.edgeColour = \"#ff0000\"; // Red for offset\n \n bitbybit.draw.drawAnyAsync({ entity: starWire, options: originalOptions });\n bitbybit.draw.drawAnyAsync({ entity: offsetShape, options: offsetOptions });\n\n}\n\nstart();","version":"0.21.1","type":"typescript"}} title="Advanced Offset with Join Type Control" /> @@ -117,21 +117,21 @@ The thick solid operation takes a shell (collection of connected faces) or a fac circleWirecircularFacethicknessthickSolidcircleWire0000103circularFacecircleWireTRUEthickness0.5thickSolidcircularFacethicknesstranslatedSolidthickSolid010circularFace#00ff004translatedSolid#ff00004","version":"0.21.0","type":"blockly"}} + script={{"script":"circleWirecircularFacethicknessthickSolidcircleWire0000103circularFacecircleWireTRUEthickness0.5thickSolidcircularFacethicknesstranslatedSolidthickSolid010circularFace#00ff004translatedSolid#ff00004","version":"0.21.1","type":"blockly"}} title="Creating Thick Solid from Face" /> {\n\n // Define the thickness for the solid\n const thickness = 0.5;\n\n // Step 1: Create a circular wire\n const circleOpt = new CircleDto();\n circleOpt.center = [0, 0, 0];\n circleOpt.direction = [0, 1, 0];\n circleOpt.radius = 3;\n \n const circleWire = await wire.createCircleWire(circleOpt);\n\n // Step 2: Convert the wire to a face\n const faceOpt = new FaceFromWireDto();\n faceOpt.shape = circleWire;\n faceOpt.planar = true;\n \n const circularFace = await face.createFaceFromWire(faceOpt);\n\n // Step 3: Create a thick solid from the face\n const thickSolidOpt = new ThisckSolidSimpleDto();\n thickSolidOpt.shape = circularFace;\n // Positive offset creates thickness in the direction of the face normal\n thickSolidOpt.offset = thickness;\n \n const thickSolid = await operations.makeThickSolidSimple(thickSolidOpt);\n\n // Step 4: Translate the thick solid upwards to make the original face visible\n const translationOpt = new TranslateDto();\n translationOpt.shape = thickSolid;\n translationOpt.translation = [0, 1, 0]; // Move up by 1 unit\n \n const translatedSolid = await transforms.translate(translationOpt);\n\n // Draw both the original face and resulting thick solid with different colors for comparison\n const originalOptions = new Bit.Inputs.Draw.DrawOcctShapeSimpleOptions();\n originalOptions.edgeWidth = 4;\n originalOptions.edgeColour = \"#00ff00\"; // Green for original\n \n const thickSolidOptions = new Bit.Inputs.Draw.DrawOcctShapeSimpleOptions();\n thickSolidOptions.edgeWidth = 4;\n thickSolidOptions.edgeColour = \"#ff0000\"; // Red for thick solid\n \n bitbybit.draw.drawAnyAsync({ entity: circularFace, options: originalOptions });\n bitbybit.draw.drawAnyAsync({ entity: translatedSolid, options: thickSolidOptions });\n\n}\n\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"// Import required modules for wire, face creation and operations\nconst { wire, face } = bitbybit.occt.shapes;\nconst { operations, transforms } = bitbybit.occt;\n// Import DTOs for circle, face and thick solid creation\nconst { CircleDto, FaceFromWireDto, ThisckSolidSimpleDto, TranslateDto } = Bit.Inputs.OCCT;\ntype TopoDSWirePointer = Bit.Inputs.OCCT.TopoDSWirePointer;\ntype TopoDSFacePointer = Bit.Inputs.OCCT.TopoDSFacePointer;\n\nconst start = async () => {\n\n // Define the thickness for the solid\n const thickness = 0.5;\n\n // Step 1: Create a circular wire\n const circleOpt = new CircleDto();\n circleOpt.center = [0, 0, 0];\n circleOpt.direction = [0, 1, 0];\n circleOpt.radius = 3;\n \n const circleWire = await wire.createCircleWire(circleOpt);\n\n // Step 2: Convert the wire to a face\n const faceOpt = new FaceFromWireDto();\n faceOpt.shape = circleWire;\n faceOpt.planar = true;\n \n const circularFace = await face.createFaceFromWire(faceOpt);\n\n // Step 3: Create a thick solid from the face\n const thickSolidOpt = new ThisckSolidSimpleDto();\n thickSolidOpt.shape = circularFace;\n // Positive offset creates thickness in the direction of the face normal\n thickSolidOpt.offset = thickness;\n \n const thickSolid = await operations.makeThickSolidSimple(thickSolidOpt);\n\n // Step 4: Translate the thick solid upwards to make the original face visible\n const translationOpt = new TranslateDto();\n translationOpt.shape = thickSolid;\n translationOpt.translation = [0, 1, 0]; // Move up by 1 unit\n \n const translatedSolid = await transforms.translate(translationOpt);\n\n // Draw both the original face and resulting thick solid with different colors for comparison\n const originalOptions = new Bit.Inputs.Draw.DrawOcctShapeSimpleOptions();\n originalOptions.edgeWidth = 4;\n originalOptions.edgeColour = \"#00ff00\"; // Green for original\n \n const thickSolidOptions = new Bit.Inputs.Draw.DrawOcctShapeSimpleOptions();\n thickSolidOptions.edgeWidth = 4;\n thickSolidOptions.edgeColour = \"#ff0000\"; // Red for thick solid\n \n bitbybit.draw.drawAnyAsync({ entity: circularFace, options: originalOptions });\n bitbybit.draw.drawAnyAsync({ entity: translatedSolid, options: thickSolidOptions });\n\n}\n\nstart();","version":"0.21.1","type":"typescript"}} title="Creating Thick Solid from Face" /> @@ -151,21 +151,21 @@ This operation works by: curvedWireoffsetDistanceextrusionDirectionoffset3DWirecurvedWire0002124-11623FALSEoffsetDistance0.5extrusionDirection010offset3DWirecurvedWireextrusionDirectionoffsetDistancecurvedWire#00ff004offset3DWire#ff00004","version":"0.21.0","type":"blockly"}} + script={{"script":"curvedWireoffsetDistanceextrusionDirectionoffset3DWirecurvedWire0002124-11623FALSEoffsetDistance0.5extrusionDirection010offset3DWirecurvedWireextrusionDirectionoffsetDistancecurvedWire#00ff004offset3DWire#ff00004","version":"0.21.1","type":"blockly"}} title="3D Wire Offset Operation" /> {\n\n // Define parameters for the 3D offset\n const offsetDistance = 0.5;\n const extrusionDirection = [0, 1, 0]; // Y-axis direction\n\n // Step 1: Create a curved 3D wire using B-spline\n const curveOpt = new BSplineDto();\n // Define control points for a truly 3D curve with varying Y coordinates\n curveOpt.points = [\n [0, 0, 0], // Start point\n [2, 1, 2], // First control point (elevated in Y)\n [4, -1, 1], // Second control point (lowered in Y)\n [6, 2, 3] // End point (elevated in Y and Z)\n ];\n curveOpt.closed = false;\n \n const curvedWire = await wire.createBSpline(curveOpt);\n\n // Step 2: Create 3D offset of the wire\n const offset3DOpt = new Offset3DWireDto();\n offset3DOpt.shape = curvedWire;\n // Direction for the temporary extrusion used in the offset calculation\n offset3DOpt.direction = extrusionDirection as Bit.Inputs.Base.Point3;\n // Distance to offset the wire\n offset3DOpt.offset = offsetDistance;\n \n const offset3DWire = await operations.offset3DWire(offset3DOpt);\n\n // Draw both the original and offset wires with different colors for comparison\n const originalOptions = new Bit.Inputs.Draw.DrawOcctShapeSimpleOptions();\n originalOptions.edgeWidth = 4;\n originalOptions.edgeColour = \"#00ff00\"; // Green for original\n \n const offsetOptions = new Bit.Inputs.Draw.DrawOcctShapeSimpleOptions();\n offsetOptions.edgeWidth = 4;\n offsetOptions.edgeColour = \"#ff0000\"; // Red for offset\n \n bitbybit.draw.drawAnyAsync({ entity: curvedWire, options: originalOptions });\n bitbybit.draw.drawAnyAsync({ entity: offset3DWire, options: offsetOptions });\n\n}\n\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"// Import required modules for wire creation and operations\nconst { wire } = bitbybit.occt.shapes;\nconst { operations } = bitbybit.occt;\n// Import DTOs for BSpline and 3D wire offset\nconst { BSplineDto, Offset3DWireDto } = Bit.Inputs.OCCT;\ntype TopoDSWirePointer = Bit.Inputs.OCCT.TopoDSWirePointer;\n\nconst start = async () => {\n\n // Define parameters for the 3D offset\n const offsetDistance = 0.5;\n const extrusionDirection = [0, 1, 0]; // Y-axis direction\n\n // Step 1: Create a curved 3D wire using B-spline\n const curveOpt = new BSplineDto();\n // Define control points for a truly 3D curve with varying Y coordinates\n curveOpt.points = [\n [0, 0, 0], // Start point\n [2, 1, 2], // First control point (elevated in Y)\n [4, -1, 1], // Second control point (lowered in Y)\n [6, 2, 3] // End point (elevated in Y and Z)\n ];\n curveOpt.closed = false;\n \n const curvedWire = await wire.createBSpline(curveOpt);\n\n // Step 2: Create 3D offset of the wire\n const offset3DOpt = new Offset3DWireDto();\n offset3DOpt.shape = curvedWire;\n // Direction for the temporary extrusion used in the offset calculation\n offset3DOpt.direction = extrusionDirection as Bit.Inputs.Base.Point3;\n // Distance to offset the wire\n offset3DOpt.offset = offsetDistance;\n \n const offset3DWire = await operations.offset3DWire(offset3DOpt);\n\n // Draw both the original and offset wires with different colors for comparison\n const originalOptions = new Bit.Inputs.Draw.DrawOcctShapeSimpleOptions();\n originalOptions.edgeWidth = 4;\n originalOptions.edgeColour = \"#00ff00\"; // Green for original\n \n const offsetOptions = new Bit.Inputs.Draw.DrawOcctShapeSimpleOptions();\n offsetOptions.edgeWidth = 4;\n offsetOptions.edgeColour = \"#ff0000\"; // Red for offset\n \n bitbybit.draw.drawAnyAsync({ entity: curvedWire, options: originalOptions });\n bitbybit.draw.drawAnyAsync({ entity: offset3DWire, options: offsetOptions });\n\n}\n\nstart();","version":"0.21.1","type":"typescript"}} title="3D Wire Offset Operation" /> diff --git a/docs/learn/code/common/occt/operations/rotated-extrusions.md b/docs/learn/code/common/occt/operations/rotated-extrusions.md index 622ea449..954142ba 100644 --- a/docs/learn/code/common/occt/operations/rotated-extrusions.md +++ b/docs/learn/code/common/occt/operations/rotated-extrusions.md @@ -34,21 +34,21 @@ In the examples below, we will demonstrate how to create a simple solid 3D helic 130000104360TRUE","version":"0.21.0","type":"blockly"}} + script={{"script":"130000104360TRUE","version":"0.21.1","type":"blockly"}} title="Extrude the wire into shell kind of shape" /> {\n\n const recOpt = new Bit.Inputs.OCCT.RectangleDto(1, 3);\n const rectangle = await bitbybit.occt.shapes.wire.createRectangleWire(recOpt);\n const rotatedExtrudeOpt = new Bit.Inputs.OCCT.RotationExtrudeDto(rectangle, 4);\n const rotatedExtrude = await bitbybit.occt.operations.rotatedExtrude(rotatedExtrudeOpt)\n\n bitbybit.draw.drawAnyAsync({ entity: rotatedExtrude });\n\n}\n\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"const start = async () => {\n\n const recOpt = new Bit.Inputs.OCCT.RectangleDto(1, 3);\n const rectangle = await bitbybit.occt.shapes.wire.createRectangleWire(recOpt);\n const rotatedExtrudeOpt = new Bit.Inputs.OCCT.RotationExtrudeDto(rectangle, 4);\n const rotatedExtrude = await bitbybit.occt.operations.rotatedExtrude(rotatedExtrudeOpt)\n\n bitbybit.draw.drawAnyAsync({ entity: rotatedExtrude });\n\n}\n\nstart();","version":"0.21.1","type":"typescript"}} title="Extrude the wire into shell kind of shape" /> @@ -62,21 +62,21 @@ When the profile is further from the center it will form a helix like shape. Thi pointPromisespointsngonRotationPromisesi3050300150117910001000100010003pointPromises00001061012FALSETRUEpointspointPromisesngonRotationPromisesipointsINSERTLASTngonRotationPromisesi01061.530270TRUEngonRotationPromises","version":"0.21.0","type":"blockly"}} + script={{"script":"pointPromisespointsngonRotationPromisesi3050300150117910001000100010003pointPromises00001061012FALSETRUEpointspointPromisesngonRotationPromisesipointsINSERTLASTngonRotationPromisesi01061.530270TRUEngonRotationPromises","version":"0.21.1","type":"blockly"}} title="Extrude the wire into shell kind of shape" /> {\n\n // Adjust the default camera position to face the object\n const cameraOptions = new CameraConfigurationDto();\n cameraOptions.position = [30, 50, 50];\n cameraOptions.lookAt = [0, 15, 0];\n scene.adjustActiveArcRotateCamera(cameraOptions);\n\n // This ellipse will be used to derive origins for ngons on the ground plane\n const ellipseOptions = new EllipseDto();\n ellipseOptions.radiusMinor = 6;\n ellipseOptions.radiusMajor = 10;\n const ellipse = await wire.createEllipseWire(ellipseOptions);\n\n // We divide the wire into 12 segments and return the points\n const divideOptions = new DivideDto(ellipse);\n divideOptions.removeEndPoint = true;\n divideOptions.nrOfDivisions = 12;\n const points = await wire.divideWireByEqualDistanceToPoints(divideOptions);\n\n // Create ngons on these points\n const ngonOptions = new NGonWireDto();\n ngonOptions.radius = 1.5;\n const ngonPromises = points.map(point => {\n ngonOptions.center = point;\n return wire.createNGonWire(ngonOptions);\n });\n\n const ngons = await Promise.all(ngonPromises);\n\n // Form rotated extrusions on all of the points\n const rotatedExtrudeOptions = new RotationExtrudeDto();\n rotatedExtrudeOptions.angle = 270;\n rotatedExtrudeOptions.height = 30;\n const rotatedExtrusionPromises = ngons.map(ngon => {\n rotatedExtrudeOptions.shape = ngon;\n return operations.rotatedExtrude(rotatedExtrudeOptions);\n });\n\n const rotatedExtrusions = await Promise.all(rotatedExtrusionPromises);\n\n // Compounding multiple shapes will generally deliver much better rendering performance\n // as it will form a single mesh for all of the geometries involved in compound\n const compoundOptions = new CompoundShapesDto(rotatedExtrusions);\n const ngonCompound = await compound.makeCompound(compoundOptions);\n\n // As a last step we draw the ngon with default occt settings (defualt because we omit specifying options property)\n bitbybit.draw.drawAnyAsync({ entity: ngonCompound });\n\n}\n\n// Let's not forget to execute the start function, otherwise nothing will happen.\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"// These destructured imports are optional, but convenient later on - option DTO's are classes\nconst { EllipseDto, RotationExtrudeDto, DivideDto, NGonWireDto, CompoundShapesDto } = Bit.Inputs.OCCT;\nconst { CameraConfigurationDto } = Bit.Inputs.BabylonScene;\n// These are parts of the bitbybit API that will be used in the script\nconst { wire, compound } = bitbybit.occt.shapes;\nconst { operations } = bitbybit.occt;\nconst { scene } = bitbybit.babylon;\n// Types need to be destructured one by one\ntype TopoDSWirePointer = Bit.Inputs.OCCT.TopoDSWirePointer;\n\n// Async definition of the start function where we can await on asynchronous CAD algorithms running inside the web workers\nconst start = async () => {\n\n // Adjust the default camera position to face the object\n const cameraOptions = new CameraConfigurationDto();\n cameraOptions.position = [30, 50, 50];\n cameraOptions.lookAt = [0, 15, 0];\n scene.adjustActiveArcRotateCamera(cameraOptions);\n\n // This ellipse will be used to derive origins for ngons on the ground plane\n const ellipseOptions = new EllipseDto();\n ellipseOptions.radiusMinor = 6;\n ellipseOptions.radiusMajor = 10;\n const ellipse = await wire.createEllipseWire(ellipseOptions);\n\n // We divide the wire into 12 segments and return the points\n const divideOptions = new DivideDto(ellipse);\n divideOptions.removeEndPoint = true;\n divideOptions.nrOfDivisions = 12;\n const points = await wire.divideWireByEqualDistanceToPoints(divideOptions);\n\n // Create ngons on these points\n const ngonOptions = new NGonWireDto();\n ngonOptions.radius = 1.5;\n const ngonPromises = points.map(point => {\n ngonOptions.center = point;\n return wire.createNGonWire(ngonOptions);\n });\n\n const ngons = await Promise.all(ngonPromises);\n\n // Form rotated extrusions on all of the points\n const rotatedExtrudeOptions = new RotationExtrudeDto();\n rotatedExtrudeOptions.angle = 270;\n rotatedExtrudeOptions.height = 30;\n const rotatedExtrusionPromises = ngons.map(ngon => {\n rotatedExtrudeOptions.shape = ngon;\n return operations.rotatedExtrude(rotatedExtrudeOptions);\n });\n\n const rotatedExtrusions = await Promise.all(rotatedExtrusionPromises);\n\n // Compounding multiple shapes will generally deliver much better rendering performance\n // as it will form a single mesh for all of the geometries involved in compound\n const compoundOptions = new CompoundShapesDto(rotatedExtrusions);\n const ngonCompound = await compound.makeCompound(compoundOptions);\n\n // As a last step we draw the ngon with default occt settings (defualt because we omit specifying options property)\n bitbybit.draw.drawAnyAsync({ entity: ngonCompound });\n\n}\n\n// Let's not forget to execute the start function, otherwise nothing will happen.\nstart();","version":"0.21.1","type":"typescript"}} title="Extrude the wire into shell kind of shape" /> diff --git a/docs/learn/code/common/occt/operations/simple-loft.md b/docs/learn/code/common/occt/operations/simple-loft.md index 9dca8132..26ba4736 100644 --- a/docs/learn/code/common/occt/operations/simple-loft.md +++ b/docs/learn/code/common/occt/operations/simple-loft.md @@ -37,21 +37,21 @@ In this tutorial, we'll walk through the process of creating a simple lofted sha ellipse1ellipse2ellipse3ellipsesloftellipse100001048ellipse203001014ellipse307001026ellipsesellipse1ellipse2ellipse3loftellipsesFALSEloft0.001TRUE#6600ccTRUE#ffffff2","version":"0.21.0","type":"blockly"}} + script={{"script":"ellipse1ellipse2ellipse3ellipsesloftellipse100001048ellipse203001014ellipse307001026ellipsesellipse1ellipse2ellipse3loftellipsesFALSEloft0.001TRUE#6600ccTRUE#ffffff2","version":"0.21.1","type":"blockly"}} title="Simple Loft Operation" /> {\n\n // Create an instance of EllipseDto to define the properties of the first ellipse.\n const ellipseOpt = new EllipseDto();\n // Set the minor radius of the ellipse.\n ellipseOpt.radiusMinor = 4;\n // Set the major radius of the ellipse.\n ellipseOpt.radiusMajor = 8;\n // Create the first elliptical wire. The center defaults to [0,0,0] and direction to [0,1,0] if not specified.\n // 'await' is used because shape creation is an asynchronous operation.\n const ellipse1 = await shapes.wire.createEllipseWire(ellipseOpt);\n\n // Modify the ellipseOpt for the second ellipse.\n // Set the center of the second ellipse.\n ellipseOpt.center = [0, 3, 0];\n // Set the minor radius for the second ellipse.\n ellipseOpt.radiusMinor = 1;\n // Set the major radius for the second ellipse.\n ellipseOpt.radiusMajor = 4;\n // Create the second elliptical wire with the updated options.\n const ellipse2 = await shapes.wire.createEllipseWire(ellipseOpt);\n\n // Modify the ellipseOpt for the third ellipse.\n // Set the center of the third ellipse.\n ellipseOpt.center = [0, 7, 0];\n // Set the minor radius for the third ellipse.\n ellipseOpt.radiusMinor = 2;\n // Set the major radius for the third ellipse.\n ellipseOpt.radiusMajor = 6;\n // Create the third elliptical wire with the updated options.\n const ellipse3 = await shapes.wire.createEllipseWire(ellipseOpt);\n\n // Create an instance of LoftDto to define the parameters for the loft operation.\n // The generic type TopoDSShapePointer indicates the type of shapes to be lofted.\n const loftOpt = new LoftDto();\n // Assign an array of the created ellipse wires to the 'shapes' property of loftOpt.\n // These are the profiles that will be connected by the loft.\n loftOpt.shapes = [ellipse1, ellipse2, ellipse3];\n // Perform the loft operation using the defined options.\n // This will create a surface (or shell) connecting the three ellipses.\n // 'makeSolid' defaults to false, creating a shell.\n const loft = await operations.loft(loftOpt);\n\n // Create an instance of DrawOcctShapeSimpleOptions to define how the lofted shape will be displayed.\n const drawOpt = new DrawOcctShapeSimpleOptions();\n // Set the precision for drawing the shape. This affects the tessellation quality.\n drawOpt.precision = 0.001;\n // Set the color of the faces of the lofted shape.\n drawOpt.faceColour = \"#ff00ff\"; // Magenta\n // Draw the lofted shape asynchronously using the specified entity and drawing options.\n draw.drawAnyAsync({ entity: loft, options: drawOpt });\n\n}\n\n// Call the start function to execute the script.\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"// Import necessary modules from the bitbybit library.\n// 'operations' and 'shapes' are for OpenCascade Technology (OCCT) functionalities like lofting and creating wires.\nconst { operations, shapes } = bitbybit.occt;\n// 'draw' module is used for rendering shapes on the canvas.\nconst { draw } = bitbybit;\n// Import Data Transfer Objects (DTOs) for defining OCCT inputs.\n// 'EllipseDto' for creating ellipses, 'LoftDto' for loft operation parameters.\nconst { EllipseDto, LoftDto } = Bit.Inputs.OCCT;\n// Import DTO for drawing options.\nconst { DrawOcctShapeSimpleOptions } = Bit.Inputs.Draw;\n// Define a type alias for OCCT shape pointers for better readability.\ntype TopoDSShapePointer = Bit.Inputs.OCCT.TopoDSShapePointer;\n\n// Define an asynchronous function 'start' which will contain the main logic.\nconst start = async () => {\n\n // Create an instance of EllipseDto to define the properties of the first ellipse.\n const ellipseOpt = new EllipseDto();\n // Set the minor radius of the ellipse.\n ellipseOpt.radiusMinor = 4;\n // Set the major radius of the ellipse.\n ellipseOpt.radiusMajor = 8;\n // Create the first elliptical wire. The center defaults to [0,0,0] and direction to [0,1,0] if not specified.\n // 'await' is used because shape creation is an asynchronous operation.\n const ellipse1 = await shapes.wire.createEllipseWire(ellipseOpt);\n\n // Modify the ellipseOpt for the second ellipse.\n // Set the center of the second ellipse.\n ellipseOpt.center = [0, 3, 0];\n // Set the minor radius for the second ellipse.\n ellipseOpt.radiusMinor = 1;\n // Set the major radius for the second ellipse.\n ellipseOpt.radiusMajor = 4;\n // Create the second elliptical wire with the updated options.\n const ellipse2 = await shapes.wire.createEllipseWire(ellipseOpt);\n\n // Modify the ellipseOpt for the third ellipse.\n // Set the center of the third ellipse.\n ellipseOpt.center = [0, 7, 0];\n // Set the minor radius for the third ellipse.\n ellipseOpt.radiusMinor = 2;\n // Set the major radius for the third ellipse.\n ellipseOpt.radiusMajor = 6;\n // Create the third elliptical wire with the updated options.\n const ellipse3 = await shapes.wire.createEllipseWire(ellipseOpt);\n\n // Create an instance of LoftDto to define the parameters for the loft operation.\n // The generic type TopoDSShapePointer indicates the type of shapes to be lofted.\n const loftOpt = new LoftDto();\n // Assign an array of the created ellipse wires to the 'shapes' property of loftOpt.\n // These are the profiles that will be connected by the loft.\n loftOpt.shapes = [ellipse1, ellipse2, ellipse3];\n // Perform the loft operation using the defined options.\n // This will create a surface (or shell) connecting the three ellipses.\n // 'makeSolid' defaults to false, creating a shell.\n const loft = await operations.loft(loftOpt);\n\n // Create an instance of DrawOcctShapeSimpleOptions to define how the lofted shape will be displayed.\n const drawOpt = new DrawOcctShapeSimpleOptions();\n // Set the precision for drawing the shape. This affects the tessellation quality.\n drawOpt.precision = 0.001;\n // Set the color of the faces of the lofted shape.\n drawOpt.faceColour = \"#ff00ff\"; // Magenta\n // Draw the lofted shape asynchronously using the specified entity and drawing options.\n draw.drawAnyAsync({ entity: loft, options: drawOpt });\n\n}\n\n// Call the start function to execute the script.\nstart();","version":"0.21.1","type":"typescript"}} title="Simple Loft Operation" /> diff --git a/docs/learn/code/common/occt/operations/thick-solids.md b/docs/learn/code/common/occt/operations/thick-solids.md index 676a080d..06ad3095 100644 --- a/docs/learn/code/common/occt/operations/thick-solids.md +++ b/docs/learn/code/common/occt/operations/thick-solids.md @@ -63,21 +63,21 @@ The following examples demonstrate creating thick solids from complex lofted sur bottomPointsmiddlePointstopPointsbottomWiremiddleWiretopWirewireListloftSurfacethickSolidtranslatedSolidthicknessoffsetVectorsurfaceOptionssolidOptionsbottomPoints-30-2-10000110030-2middlePoints-22-1-0.521.50220.521.522-1topPoints-1.540-0.540.50410.540.51.540bottomWirebottomPointsFALSE0.1middleWiremiddlePointsFALSE0.1topWiretopPointsFALSE0.1wireListbottomWiremiddleWiretopWireloftSurfacewireListFALSEthickness0.1thickSolidloftSurfacethicknessoffsetVector003translatedSolidthickSolidoffsetVectorsurfaceOptions0.01TRUE#00ff00TRUE#ffffff2solidOptions0.01TRUE#ff6600TRUE#ffffff2loftSurfacesurfaceOptionstranslatedSolidsolidOptions","version":"0.21.0","type":"blockly"}} + script={{"script":"bottomPointsmiddlePointstopPointsbottomWiremiddleWiretopWirewireListloftSurfacethickSolidtranslatedSolidthicknessoffsetVectorsurfaceOptionssolidOptionsbottomPoints-30-2-10000110030-2middlePoints-22-1-0.521.50220.521.522-1topPoints-1.540-0.540.50410.540.51.540bottomWirebottomPointsFALSE0.1middleWiremiddlePointsFALSE0.1topWiretopPointsFALSE0.1wireListbottomWiremiddleWiretopWireloftSurfacewireListFALSEthickness0.1thickSolidloftSurfacethicknessoffsetVector003translatedSolidthickSolidoffsetVectorsurfaceOptions0.01TRUE#00ff00TRUE#ffffff2solidOptions0.01TRUE#ff6600TRUE#ffffff2loftSurfacesurfaceOptionstranslatedSolidsolidOptions","version":"0.21.1","type":"blockly"}} title="Thick Solid from Lofted Surface (Blockly)" /> {\n\n // Define points for bottom curve (wave-like pattern)\n const bottomPoints = [\n [-3, 0, -2],\n [-1, 0, 0],\n [0, 0, 1],\n [1, 0, 0],\n [3, 0, -2]\n ] as Point3[];\n\n // Define points for middle curve (elevated and more curved)\n const middlePoints = [\n [-2, 2, -1],\n [-0.5, 2, 1.5],\n [0, 2, 2],\n [0.5, 2, 1.5],\n [2, 2, -1]\n ] as Point3[];\n\n // Define points for top curve (simpler, less curved)\n const topPoints = [\n [-1.5, 4, 0],\n [-0.5, 4, 0.5],\n [0, 4, 1],\n [0.5, 4, 0.5],\n [1.5, 4, 0]\n ] as Point3[];\n\n // Create interpolated wires from points\n const bottomWireOpt = new InterpolationDto();\n bottomWireOpt.points = bottomPoints;\n bottomWireOpt.periodic = false;\n bottomWireOpt.tolerance = 0.1;\n const bottomWire = await wire.interpolatePoints(bottomWireOpt);\n\n const middleWireOpt = new InterpolationDto();\n middleWireOpt.points = middlePoints;\n middleWireOpt.periodic = false;\n middleWireOpt.tolerance = 0.1;\n const middleWire = await wire.interpolatePoints(middleWireOpt);\n\n const topWireOpt = new InterpolationDto();\n topWireOpt.points = topPoints;\n topWireOpt.periodic = false;\n topWireOpt.tolerance = 0.1;\n const topWire = await wire.interpolatePoints(topWireOpt);\n\n // Create lofted surface from the three wires\n const loftOpt = new LoftDto();\n loftOpt.shapes = [bottomWire, middleWire, topWire];\n loftOpt.makeSolid = false;\n const loftSurface = await operations.loft(loftOpt);\n\n // Create thick solid from the lofted surface\n const thickness = 0.1;\n const thickSolidOpt = new ThisckSolidSimpleDto();\n thickSolidOpt.shape = loftSurface;\n thickSolidOpt.offset = thickness;\n const thickSolid = await operations.makeThickSolidSimple(thickSolidOpt);\n\n // Translate the thick solid for better visualization\n const offsetVector = [0, 0, 3] as Vector3;\n const translateOpt = new TranslateDto();\n translateOpt.shape = thickSolid;\n translateOpt.translation = offsetVector;\n const translatedSolid = await transforms.translate(translateOpt);\n\n // Create drawing options for the original surface (green)\n const surfaceOptions = new Bit.Inputs.Draw.DrawOcctShapeSimpleOptions();\n surfaceOptions.precision = 0.01;\n surfaceOptions.drawFaces = true;\n surfaceOptions.faceColour = \"#00ff00\";\n surfaceOptions.drawEdges = true;\n surfaceOptions.edgeColour = \"#ffffff\";\n surfaceOptions.edgeWidth = 2;\n\n // Create drawing options for the thick solid (orange)\n const solidOptions = new Bit.Inputs.Draw.DrawOcctShapeSimpleOptions();\n solidOptions.precision = 0.01;\n solidOptions.drawFaces = true;\n solidOptions.faceColour = \"#ff6600\";\n solidOptions.drawEdges = true;\n solidOptions.edgeColour = \"#ffffff\";\n solidOptions.edgeWidth = 2;\n\n // Draw both the original lofted surface and the thick solid\n bitbybit.draw.drawAnyAsync({ entity: loftSurface, options: surfaceOptions });\n bitbybit.draw.drawAnyAsync({ entity: translatedSolid, options: solidOptions });\n\n}\n\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"// Import required modules from global bitbybit variable\nconst { wire } = bitbybit.occt.shapes;\nconst { operations } = bitbybit.occt;\nconst { transforms } = bitbybit.occt;\n\nconst { InterpolationDto, LoftDto, ThisckSolidSimpleDto, TranslateDto } = Bit.Inputs.OCCT;\ntype Point3 = Bit.Inputs.Base.Point3;\ntype Vector3 = Bit.Inputs.Base.Vector3;\n\n// Define a type alias for pointers\ntype TopoDSWirePointer = Bit.Inputs.OCCT.TopoDSWirePointer;\ntype TopoDSFacePointer = Bit.Inputs.OCCT.TopoDSFacePointer;\ntype TopoDSShapePointer = Bit.Inputs.OCCT.TopoDSShapePointer;\n\nconst start = async () => {\n\n // Define points for bottom curve (wave-like pattern)\n const bottomPoints = [\n [-3, 0, -2],\n [-1, 0, 0],\n [0, 0, 1],\n [1, 0, 0],\n [3, 0, -2]\n ] as Point3[];\n\n // Define points for middle curve (elevated and more curved)\n const middlePoints = [\n [-2, 2, -1],\n [-0.5, 2, 1.5],\n [0, 2, 2],\n [0.5, 2, 1.5],\n [2, 2, -1]\n ] as Point3[];\n\n // Define points for top curve (simpler, less curved)\n const topPoints = [\n [-1.5, 4, 0],\n [-0.5, 4, 0.5],\n [0, 4, 1],\n [0.5, 4, 0.5],\n [1.5, 4, 0]\n ] as Point3[];\n\n // Create interpolated wires from points\n const bottomWireOpt = new InterpolationDto();\n bottomWireOpt.points = bottomPoints;\n bottomWireOpt.periodic = false;\n bottomWireOpt.tolerance = 0.1;\n const bottomWire = await wire.interpolatePoints(bottomWireOpt);\n\n const middleWireOpt = new InterpolationDto();\n middleWireOpt.points = middlePoints;\n middleWireOpt.periodic = false;\n middleWireOpt.tolerance = 0.1;\n const middleWire = await wire.interpolatePoints(middleWireOpt);\n\n const topWireOpt = new InterpolationDto();\n topWireOpt.points = topPoints;\n topWireOpt.periodic = false;\n topWireOpt.tolerance = 0.1;\n const topWire = await wire.interpolatePoints(topWireOpt);\n\n // Create lofted surface from the three wires\n const loftOpt = new LoftDto();\n loftOpt.shapes = [bottomWire, middleWire, topWire];\n loftOpt.makeSolid = false;\n const loftSurface = await operations.loft(loftOpt);\n\n // Create thick solid from the lofted surface\n const thickness = 0.1;\n const thickSolidOpt = new ThisckSolidSimpleDto();\n thickSolidOpt.shape = loftSurface;\n thickSolidOpt.offset = thickness;\n const thickSolid = await operations.makeThickSolidSimple(thickSolidOpt);\n\n // Translate the thick solid for better visualization\n const offsetVector = [0, 0, 3] as Vector3;\n const translateOpt = new TranslateDto();\n translateOpt.shape = thickSolid;\n translateOpt.translation = offsetVector;\n const translatedSolid = await transforms.translate(translateOpt);\n\n // Create drawing options for the original surface (green)\n const surfaceOptions = new Bit.Inputs.Draw.DrawOcctShapeSimpleOptions();\n surfaceOptions.precision = 0.01;\n surfaceOptions.drawFaces = true;\n surfaceOptions.faceColour = \"#00ff00\";\n surfaceOptions.drawEdges = true;\n surfaceOptions.edgeColour = \"#ffffff\";\n surfaceOptions.edgeWidth = 2;\n\n // Create drawing options for the thick solid (orange)\n const solidOptions = new Bit.Inputs.Draw.DrawOcctShapeSimpleOptions();\n solidOptions.precision = 0.01;\n solidOptions.drawFaces = true;\n solidOptions.faceColour = \"#ff6600\";\n solidOptions.drawEdges = true;\n solidOptions.edgeColour = \"#ffffff\";\n solidOptions.edgeWidth = 2;\n\n // Draw both the original lofted surface and the thick solid\n bitbybit.draw.drawAnyAsync({ entity: loftSurface, options: surfaceOptions });\n bitbybit.draw.drawAnyAsync({ entity: translatedSolid, options: solidOptions });\n\n}\n\nstart();","version":"0.21.1","type":"typescript"}} title="Thick Solid from Lofted Surface" /> diff --git a/docs/learn/code/common/occt/operations/wire-offset-multiple.md b/docs/learn/code/common/occt/operations/wire-offset-multiple.md index f6daecab..bb3396df 100644 --- a/docs/learn/code/common/occt/operations/wire-offset-multiple.md +++ b/docs/learn/code/common/occt/operations/wire-offset-multiple.md @@ -31,7 +31,7 @@ The following example demonstrates creating multiple offset curves from a single @@ -39,7 +39,7 @@ The following example demonstrates creating multiple offset curves from a single controlPointsbaseWirestepoverDistanceoffset1offset2offset3baseStyleoffset1Styleoffset2Styleoffset3StylecontrolPoints-40-2-202001203400stepoverDistance0.5baseWirecontrolPointsFALSE0.01offset1baseWirestepoverDistance0.01offset2baseWireMULTIPLYstepoverDistance20.01offset3baseWireMULTIPLYstepoverDistance30.01baseStyle0.01FALSETRUE#00ff004offset1Style0.01FALSETRUE#ff99003offset2Style0.01FALSETRUE#ff66003offset3Style0.01FALSETRUE#ff33003baseWirebaseStyleoffset1offset1Styleoffset2offset2Styleoffset3offset3Style","version":"0.21.0","type":"blockly"}} + script={{"script":"controlPointsbaseWirestepoverDistanceoffset1offset2offset3baseStyleoffset1Styleoffset2Styleoffset3StylecontrolPoints-40-2-202001203400stepoverDistance0.5baseWirecontrolPointsFALSE0.01offset1baseWirestepoverDistance0.01offset2baseWireMULTIPLYstepoverDistance20.01offset3baseWireMULTIPLYstepoverDistance30.01baseStyle0.01FALSETRUE#00ff004offset1Style0.01FALSETRUE#ff99003offset2Style0.01FALSETRUE#ff66003offset3Style0.01FALSETRUE#ff33003baseWirebaseStyleoffset1offset1Styleoffset2offset2Styleoffset3offset3Style","version":"0.21.1","type":"blockly"}} title="Multiple Wire Offsets" /> @@ -47,7 +47,7 @@ The following example demonstrates creating multiple offset curves from a single {\n\n // Define the stepover distance for CNC toolpaths\n const stepoverDistance = 0.5;\n\n // Step 1: Define control points for the base toolpath\n const points = [\n [-4, 0, -2],\n [-2, 0, 2],\n [0, 0, 1],\n [2, 0, 3],\n [4, 0, 0]\n ] as Point3[];\n\n // Step 2: Create base wire through interpolation\n const interpolationOpt = new InterpolationDto();\n interpolationOpt.points = points;\n interpolationOpt.periodic = false;\n interpolationOpt.tolerance = 0.01;\n \n const baseWire = await wire.interpolatePoints(interpolationOpt);\n\n // Step 3: Create multiple offset toolpaths\n // First offset\n const offset1Opt = new OffsetDto();\n offset1Opt.shape = baseWire;\n offset1Opt.distance = stepoverDistance;\n offset1Opt.tolerance = 0.01;\n \n const offset1 = await operations.offset(offset1Opt);\n\n // Second offset\n const offset2Opt = new OffsetDto();\n offset2Opt.shape = baseWire;\n offset2Opt.distance = stepoverDistance * 2;\n offset2Opt.tolerance = 0.01;\n \n const offset2 = await operations.offset(offset2Opt);\n\n // Third offset\n const offset3Opt = new OffsetDto();\n offset3Opt.shape = baseWire;\n offset3Opt.distance = stepoverDistance * 3;\n offset3Opt.tolerance = 0.01;\n \n const offset3 = await operations.offset(offset3Opt);\n\n // Step 4: Visualize all toolpaths with different colors\n // Base wire (green - reference path)\n const baseOptions = new Bit.Inputs.Draw.DrawOcctShapeSimpleOptions();\n baseOptions.edgeWidth = 4;\n baseOptions.edgeColour = \"#00ff00\"; // Green\n baseOptions.drawFaces = false;\n \n // Offset 1 (orange)\n const offset1Options = new Bit.Inputs.Draw.DrawOcctShapeSimpleOptions();\n offset1Options.edgeWidth = 3;\n offset1Options.edgeColour = \"#ff9900\"; // Orange\n offset1Options.drawFaces = false;\n \n // Offset 2 (red-orange)\n const offset2Options = new Bit.Inputs.Draw.DrawOcctShapeSimpleOptions();\n offset2Options.edgeWidth = 3;\n offset2Options.edgeColour = \"#ff6600\"; // Red-orange\n offset2Options.drawFaces = false;\n \n // Offset 3 (red)\n const offset3Options = new Bit.Inputs.Draw.DrawOcctShapeSimpleOptions();\n offset3Options.edgeWidth = 3;\n offset3Options.edgeColour = \"#ff3300\"; // Red\n offset3Options.drawFaces = false;\n \n // Draw all toolpaths\n bitbybit.draw.drawAnyAsync({ entity: baseWire, options: baseOptions });\n bitbybit.draw.drawAnyAsync({ entity: offset1, options: offset1Options });\n bitbybit.draw.drawAnyAsync({ entity: offset2, options: offset2Options });\n bitbybit.draw.drawAnyAsync({ entity: offset3, options: offset3Options });\n\n}\n\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"// Import required modules for wire creation and operations\nconst { wire } = bitbybit.occt.shapes;\nconst { operations } = bitbybit.occt;\n// Import DTOs for interpolation and offset operations\nconst { InterpolationDto, OffsetDto } = Bit.Inputs.OCCT;\ntype TopoDSWirePointer = Bit.Inputs.OCCT.TopoDSWirePointer;\ntype Point3 = Bit.Inputs.Base.Point3;\n\nconst start = async () => {\n\n // Define the stepover distance for CNC toolpaths\n const stepoverDistance = 0.5;\n\n // Step 1: Define control points for the base toolpath\n const points = [\n [-4, 0, -2],\n [-2, 0, 2],\n [0, 0, 1],\n [2, 0, 3],\n [4, 0, 0]\n ] as Point3[];\n\n // Step 2: Create base wire through interpolation\n const interpolationOpt = new InterpolationDto();\n interpolationOpt.points = points;\n interpolationOpt.periodic = false;\n interpolationOpt.tolerance = 0.01;\n \n const baseWire = await wire.interpolatePoints(interpolationOpt);\n\n // Step 3: Create multiple offset toolpaths\n // First offset\n const offset1Opt = new OffsetDto();\n offset1Opt.shape = baseWire;\n offset1Opt.distance = stepoverDistance;\n offset1Opt.tolerance = 0.01;\n \n const offset1 = await operations.offset(offset1Opt);\n\n // Second offset\n const offset2Opt = new OffsetDto();\n offset2Opt.shape = baseWire;\n offset2Opt.distance = stepoverDistance * 2;\n offset2Opt.tolerance = 0.01;\n \n const offset2 = await operations.offset(offset2Opt);\n\n // Third offset\n const offset3Opt = new OffsetDto();\n offset3Opt.shape = baseWire;\n offset3Opt.distance = stepoverDistance * 3;\n offset3Opt.tolerance = 0.01;\n \n const offset3 = await operations.offset(offset3Opt);\n\n // Step 4: Visualize all toolpaths with different colors\n // Base wire (green - reference path)\n const baseOptions = new Bit.Inputs.Draw.DrawOcctShapeSimpleOptions();\n baseOptions.edgeWidth = 4;\n baseOptions.edgeColour = \"#00ff00\"; // Green\n baseOptions.drawFaces = false;\n \n // Offset 1 (orange)\n const offset1Options = new Bit.Inputs.Draw.DrawOcctShapeSimpleOptions();\n offset1Options.edgeWidth = 3;\n offset1Options.edgeColour = \"#ff9900\"; // Orange\n offset1Options.drawFaces = false;\n \n // Offset 2 (red-orange)\n const offset2Options = new Bit.Inputs.Draw.DrawOcctShapeSimpleOptions();\n offset2Options.edgeWidth = 3;\n offset2Options.edgeColour = \"#ff6600\"; // Red-orange\n offset2Options.drawFaces = false;\n \n // Offset 3 (red)\n const offset3Options = new Bit.Inputs.Draw.DrawOcctShapeSimpleOptions();\n offset3Options.edgeWidth = 3;\n offset3Options.edgeColour = \"#ff3300\"; // Red\n offset3Options.drawFaces = false;\n \n // Draw all toolpaths\n bitbybit.draw.drawAnyAsync({ entity: baseWire, options: baseOptions });\n bitbybit.draw.drawAnyAsync({ entity: offset1, options: offset1Options });\n bitbybit.draw.drawAnyAsync({ entity: offset2, options: offset2Options });\n bitbybit.draw.drawAnyAsync({ entity: offset3, options: offset3Options });\n\n}\n\nstart();","version":"0.21.1","type":"typescript"}} title="Multiple Wire Offsets" /> diff --git a/docs/learn/code/common/occt/shapes/compound/compounded-drawing.md b/docs/learn/code/common/occt/shapes/compound/compounded-drawing.md index 4c65c2ae..c753261f 100644 --- a/docs/learn/code/common/occt/shapes/compound/compounded-drawing.md +++ b/docs/learn/code/common/occt/shapes/compound/compounded-drawing.md @@ -40,21 +40,21 @@ The example below demonstrates this principle through a complex workflow that cr bottomPointsmiddlePointstopPointsbottomWiremiddleWiretopWirewiresListloftedSurfacemainFacenrHexagonsUnrHexagonsVscalePatternhexWires1hexWires2reversedWiresiframesfirstFramesCompoundsecondFramesCompoundmaterial1material2bottomPoints[[-30, 0, -20], [-10, 0, 0], [0, 0, 10], [10, 0, 0],[30, 0, -20]]middlePoints[[-20, 20, -10], [-5, 20, 15], [0, 20, 20], [5, 20, 15],[20, 20, -10]]topPoints[[-15, 30, 0], [-5, 30, 5], [0, 30, 10], [5, 30, 5],[15, 30, 0]]bottomWirebottomPointsFALSE0.1middleWiremiddlePointsFALSE0.1topWiretopPointsFALSE0.1wiresListbottomWiremiddleWiretopWireloftedSurfacewiresListFALSEmainFaceloftedSurface0nrHexagonsU28nrHexagonsV10scalePattern0.7hexWires1mainFacenrHexagonsUnrHexagonsVFALSE00FALSEFALSEFALSEFALSEhexWires2mainFacenrHexagonsUnrHexagonsVFALSEscalePatternscalePattern00FALSEFALSEFALSEFALSEreversedWiresi1hexWires21INSERTLASTreversedWiresGETFROM_STARThexWires2iframesi1hexWires11INSERTLASTframesGETFROM_STARThexWires1iGETFROM_STARTreversedWiresiFALSEfirstFramesCompoundframes[true, true, false]secondFramesCompoundframes[false,false,true]material1First#9155ff#0000000.150.91FALSE3material2Second#000000#0000000.90.151FALSE3firstFramesCompound0.01material1TRUE#00000010secondFramesCompound0.01material2TRUE#00000010-100-100-1003#ffffff#ffffff1024TRUE0TRUE0.20.00010.00210000'default'10000.10.7TRUE442244015011791000100010001000340040010100.450.50.5FALSE#ffffff#ffffff#050506#627a9d'to top'0100","version":"0.21.0","type":"blockly"}} + script={{"script":"bottomPointsmiddlePointstopPointsbottomWiremiddleWiretopWirewiresListloftedSurfacemainFacenrHexagonsUnrHexagonsVscalePatternhexWires1hexWires2reversedWiresiframesfirstFramesCompoundsecondFramesCompoundmaterial1material2bottomPoints[[-30, 0, -20], [-10, 0, 0], [0, 0, 10], [10, 0, 0],[30, 0, -20]]middlePoints[[-20, 20, -10], [-5, 20, 15], [0, 20, 20], [5, 20, 15],[20, 20, -10]]topPoints[[-15, 30, 0], [-5, 30, 5], [0, 30, 10], [5, 30, 5],[15, 30, 0]]bottomWirebottomPointsFALSE0.1middleWiremiddlePointsFALSE0.1topWiretopPointsFALSE0.1wiresListbottomWiremiddleWiretopWireloftedSurfacewiresListFALSEmainFaceloftedSurface0nrHexagonsU28nrHexagonsV10scalePattern0.7hexWires1mainFacenrHexagonsUnrHexagonsVFALSE00FALSEFALSEFALSEFALSEhexWires2mainFacenrHexagonsUnrHexagonsVFALSEscalePatternscalePattern00FALSEFALSEFALSEFALSEreversedWiresi1hexWires21INSERTLASTreversedWiresGETFROM_STARThexWires2iframesi1hexWires11INSERTLASTframesGETFROM_STARThexWires1iGETFROM_STARTreversedWiresiFALSEfirstFramesCompoundframes[true, true, false]secondFramesCompoundframes[false,false,true]material1First#9155ff#0000000.150.91FALSE3material2Second#000000#0000000.90.151FALSE3firstFramesCompound0.01material1TRUE#00000010secondFramesCompound0.01material2TRUE#00000010-100-100-1003#ffffff#ffffff1024TRUE0TRUE0.20.00010.00210000'default'10000.10.7TRUE442244015011791000100010001000340040010100.450.50.5FALSE#ffffff#ffffff#050506#627a9d'to top'0100","version":"0.21.1","type":"blockly"}} title="Compounding hex frames into single entity will render faster" /> {\n // Define point sets for three different wire levels\n const bottomPoints: Point3[] = [\n [-30, 0, -20],\n [-10, 0, 0],\n [0, 0, 10],\n [10, 0, 0],\n [30, 0, -20]\n ];\n\n const middlePoints: Point3[] = [\n [-20, 20, -10],\n [-5, 20, 15],\n [0, 20, 20],\n [5, 20, 15],\n [20, 20, -10]\n ];\n\n const topPoints: Point3[] = [\n [-15, 30, 0],\n [-5, 30, 5],\n [0, 30, 10],\n [5, 30, 5],\n [15, 30, 0]\n ];\n\n // Create wires by interpolating points\n const bottomWireOptions = new InterpolationDto();\n bottomWireOptions.points = bottomPoints;\n bottomWireOptions.periodic = false;\n bottomWireOptions.tolerance = 0.1;\n const bottomWire = await wire.interpolatePoints(bottomWireOptions);\n\n const middleWireOptions = new InterpolationDto();\n middleWireOptions.points = middlePoints;\n middleWireOptions.periodic = false;\n middleWireOptions.tolerance = 0.1;\n const middleWire = await wire.interpolatePoints(middleWireOptions);\n\n const topWireOptions = new InterpolationDto();\n topWireOptions.points = topPoints;\n topWireOptions.periodic = false;\n topWireOptions.tolerance = 0.1;\n const topWire = await wire.interpolatePoints(topWireOptions);\n\n // Create list of wires for lofting\n const wiresList = [bottomWire, middleWire, topWire];\n\n // Loft the wires to create a surface\n const loftOptions = new LoftDto();\n loftOptions.shapes = wiresList;\n loftOptions.makeSolid = false;\n const loftedSurface = await operations.loft(loftOptions);\n\n // Get the face from the lofted surface\n const getFaceOptions = new ShapeIndexDto();\n getFaceOptions.shape = loftedSurface;\n getFaceOptions.index = 0;\n const mainFace = await face.getFace(getFaceOptions);\n\n // Subdivision parameters\n const nrHexagonsU = 28;\n const nrHexagonsV = 10;\n const scalePattern = [0.7];\n\n // Create first hexagon subdivision (regular pattern)\n const hexSubdivision1Options = new FaceSubdivideToHexagonWiresDto();\n hexSubdivision1Options.shape = mainFace;\n hexSubdivision1Options.nrHexagonsU = nrHexagonsU;\n hexSubdivision1Options.nrHexagonsV = nrHexagonsV;\n const hexWires1 = await face.subdivideToHexagonWires(hexSubdivision1Options);\n\n // Create second hexagon subdivision (scaled pattern)\n const hexSubdivision2Options = new FaceSubdivideToHexagonWiresDto();\n hexSubdivision2Options.shape = mainFace;\n hexSubdivision2Options.nrHexagonsU = nrHexagonsU;\n hexSubdivision2Options.nrHexagonsV = nrHexagonsV;\n hexSubdivision2Options.scalePatternU = scalePattern;\n hexSubdivision2Options.scalePatternV = scalePattern;\n const hexWires2 = await face.subdivideToHexagonWires(hexSubdivision2Options);\n\n // Reverse the wires from the second subdivision using for loop\n const reversedWiresPromises: Promise[] = [];\n for (const hexWire of hexWires2) {\n const reversedWire = wire.reversedWire({ shape: hexWire });\n reversedWiresPromises.push(reversedWire);\n }\n\n const reversedWires = await Promise.all(reversedWiresPromises);\n\n // Combine both wire sets - equivalent to flip lists operation in Rete\n const frameWiresGrouped = hexWires1.map((h, i) => [h, reversedWires[i]]);\n\n // Create frames\n const framePromises = frameWiresGrouped.map(f => {\n const faceFromWires2Options = new FaceFromWiresDto();\n faceFromWires2Options.shapes = f;\n faceFromWires2Options.planar = false;\n return face.createFaceFromWires(faceFromWires2Options);\n });\n\n const frames = await Promise.all(framePromises);\n\n const firstFrames = await bitbybit.lists.getByPattern({\n list: frames,\n pattern: [true, true, false]\n });\n\n const secondFrames = await bitbybit.lists.getByPattern({\n list: frames,\n pattern: [false, false, true]\n })\n\n // Create first compound from the first pattern of hexagon faces\n const compoundOptions = new CompoundShapesDto();\n compoundOptions.shapes = firstFrames;\n const firstCompound = await compound.makeCompound(compoundOptions);\n\n // Create second compound from the first pattern of hexagon faces\n compoundOptions.shapes = secondFrames;\n const secondCompound = await compound.makeCompound(compoundOptions);\n\n // Create materials for rendering\n const firstMaterial = new PBRMetallicRoughnessDto();\n firstMaterial.name = \"Blue Material\";\n firstMaterial.baseColor = \"#9155ff\";\n firstMaterial.metallic = 0.1;\n firstMaterial.roughness = 0.9;\n firstMaterial.backFaceCulling = false;\n firstMaterial.zOffset = 3;\n const blueMatResult = material.pbrMetallicRoughness.create(firstMaterial);\n\n // Create drawing options for the first frames\n const firstDrawOptions = new DrawOcctShapeOptions();\n firstDrawOptions.drawEdges = true;\n firstDrawOptions.edgeColour = \"#000000\";\n firstDrawOptions.edgeWidth = 10;\n firstDrawOptions.faceMaterial = blueMatResult;\n\n bitbybit.draw.drawAnyAsync({\n entity: firstCompound,\n options: firstDrawOptions\n });\n\n // Create materials for rendering\n const secondMaterial = new PBRMetallicRoughnessDto();\n secondMaterial.name = \"Black Material\";\n secondMaterial.baseColor = \"#000000\";\n secondMaterial.metallic = 0.9;\n secondMaterial.roughness = 0.23;\n secondMaterial.backFaceCulling = false;\n secondMaterial.zOffset = 3;\n const secondMatResult = material.pbrMetallicRoughness.create(secondMaterial);\n\n // Create drawing options for the first frames\n const secondDrawOptions = new DrawOcctShapeOptions();\n secondDrawOptions.drawEdges = true;\n secondDrawOptions.edgeColour = \"#000000\";\n secondDrawOptions.edgeWidth = 10;\n secondDrawOptions.faceMaterial = secondMatResult;\n\n bitbybit.draw.drawAnyAsync({\n entity: secondCompound,\n options: secondDrawOptions\n });\n\n // Set up scene lighting and camera\n const skyboxOptions = new SkyboxDto();\n skyboxOptions.skybox = skyboxEnum.city;\n skyboxOptions.hideSkybox = true;\n scene.enableSkybox(skyboxOptions);\n\n const dirLightOptions = new DirectionalLightDto();\n dirLightOptions.intensity = 3;\n scene.drawDirectionalLight(dirLightOptions);\n\n const gradientBackgroundOptions = new SceneTwoColorLinearGradientDto();\n gradientBackgroundOptions.colorFrom = \"#050506\";\n gradientBackgroundOptions.colorTo = \"#627a9d\";\n gradientBackgroundOptions.direction = gradientDirectionEnum.toTop;\n scene.twoColorLinearGradient(gradientBackgroundOptions);\n\n const cameraConfigurationOptions = new CameraConfigurationDto();\n cameraConfigurationOptions.position = [44, 30, 44];\n cameraConfigurationOptions.lookAt = [0, 15, 0];\n scene.adjustActiveArcRotateCamera(cameraConfigurationOptions);\n\n const gridOptions = new SceneDrawGridMeshDto();\n bitbybit.draw.drawGridMesh(gridOptions);\n}\n\n// Execute the function\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"// Import required DTOs for wire creation, lofting, face operations, and compounds\nconst { InterpolationDto, LoftDto, ShapeIndexDto, FaceSubdivideToHexagonWiresDto, FaceFromWiresDto, CompoundShapesDto } = Bit.Inputs.OCCT;\nconst { DrawOcctShapeOptions, SceneDrawGridMeshDto } = Bit.Inputs.Draw;\nconst { PBRMetallicRoughnessDto } = Bit.Inputs.BabylonMaterial;\nconst { CameraConfigurationDto, DirectionalLightDto, SceneTwoColorLinearGradientDto, SkyboxDto } = Bit.Inputs.BabylonScene;\nconst { skyboxEnum, gradientDirectionEnum } = Bit.Inputs.Base;\n\n\n// Import type definitions for type safety\ntype Point3 = Bit.Inputs.Base.Point3;\ntype Vector3 = Bit.Inputs.Base.Vector3;\ntype TopoDSWirePointer = Bit.Inputs.OCCT.TopoDSWirePointer;\ntype TopoDSFacePointer = Bit.Inputs.OCCT.TopoDSFacePointer;\ntype TopoDSCompoundPointer = Bit.Inputs.OCCT.TopoDSCompoundPointer;\n// Get access to OCCT modules\nconst { wire, face, compound } = bitbybit.occt.shapes;\nconst { operations } = bitbybit.occt;\nconst { material } = bitbybit.babylon;\nconst { scene } = bitbybit.babylon;\n\n// Define the main function to create complex face compound\nconst start = async () => {\n // Define point sets for three different wire levels\n const bottomPoints: Point3[] = [\n [-30, 0, -20],\n [-10, 0, 0],\n [0, 0, 10],\n [10, 0, 0],\n [30, 0, -20]\n ];\n\n const middlePoints: Point3[] = [\n [-20, 20, -10],\n [-5, 20, 15],\n [0, 20, 20],\n [5, 20, 15],\n [20, 20, -10]\n ];\n\n const topPoints: Point3[] = [\n [-15, 30, 0],\n [-5, 30, 5],\n [0, 30, 10],\n [5, 30, 5],\n [15, 30, 0]\n ];\n\n // Create wires by interpolating points\n const bottomWireOptions = new InterpolationDto();\n bottomWireOptions.points = bottomPoints;\n bottomWireOptions.periodic = false;\n bottomWireOptions.tolerance = 0.1;\n const bottomWire = await wire.interpolatePoints(bottomWireOptions);\n\n const middleWireOptions = new InterpolationDto();\n middleWireOptions.points = middlePoints;\n middleWireOptions.periodic = false;\n middleWireOptions.tolerance = 0.1;\n const middleWire = await wire.interpolatePoints(middleWireOptions);\n\n const topWireOptions = new InterpolationDto();\n topWireOptions.points = topPoints;\n topWireOptions.periodic = false;\n topWireOptions.tolerance = 0.1;\n const topWire = await wire.interpolatePoints(topWireOptions);\n\n // Create list of wires for lofting\n const wiresList = [bottomWire, middleWire, topWire];\n\n // Loft the wires to create a surface\n const loftOptions = new LoftDto();\n loftOptions.shapes = wiresList;\n loftOptions.makeSolid = false;\n const loftedSurface = await operations.loft(loftOptions);\n\n // Get the face from the lofted surface\n const getFaceOptions = new ShapeIndexDto();\n getFaceOptions.shape = loftedSurface;\n getFaceOptions.index = 0;\n const mainFace = await face.getFace(getFaceOptions);\n\n // Subdivision parameters\n const nrHexagonsU = 28;\n const nrHexagonsV = 10;\n const scalePattern = [0.7];\n\n // Create first hexagon subdivision (regular pattern)\n const hexSubdivision1Options = new FaceSubdivideToHexagonWiresDto();\n hexSubdivision1Options.shape = mainFace;\n hexSubdivision1Options.nrHexagonsU = nrHexagonsU;\n hexSubdivision1Options.nrHexagonsV = nrHexagonsV;\n const hexWires1 = await face.subdivideToHexagonWires(hexSubdivision1Options);\n\n // Create second hexagon subdivision (scaled pattern)\n const hexSubdivision2Options = new FaceSubdivideToHexagonWiresDto();\n hexSubdivision2Options.shape = mainFace;\n hexSubdivision2Options.nrHexagonsU = nrHexagonsU;\n hexSubdivision2Options.nrHexagonsV = nrHexagonsV;\n hexSubdivision2Options.scalePatternU = scalePattern;\n hexSubdivision2Options.scalePatternV = scalePattern;\n const hexWires2 = await face.subdivideToHexagonWires(hexSubdivision2Options);\n\n // Reverse the wires from the second subdivision using for loop\n const reversedWiresPromises: Promise[] = [];\n for (const hexWire of hexWires2) {\n const reversedWire = wire.reversedWire({ shape: hexWire });\n reversedWiresPromises.push(reversedWire);\n }\n\n const reversedWires = await Promise.all(reversedWiresPromises);\n\n // Combine both wire sets - equivalent to flip lists operation in Rete\n const frameWiresGrouped = hexWires1.map((h, i) => [h, reversedWires[i]]);\n\n // Create frames\n const framePromises = frameWiresGrouped.map(f => {\n const faceFromWires2Options = new FaceFromWiresDto();\n faceFromWires2Options.shapes = f;\n faceFromWires2Options.planar = false;\n return face.createFaceFromWires(faceFromWires2Options);\n });\n\n const frames = await Promise.all(framePromises);\n\n const firstFrames = await bitbybit.lists.getByPattern({\n list: frames,\n pattern: [true, true, false]\n });\n\n const secondFrames = await bitbybit.lists.getByPattern({\n list: frames,\n pattern: [false, false, true]\n })\n\n // Create first compound from the first pattern of hexagon faces\n const compoundOptions = new CompoundShapesDto();\n compoundOptions.shapes = firstFrames;\n const firstCompound = await compound.makeCompound(compoundOptions);\n\n // Create second compound from the first pattern of hexagon faces\n compoundOptions.shapes = secondFrames;\n const secondCompound = await compound.makeCompound(compoundOptions);\n\n // Create materials for rendering\n const firstMaterial = new PBRMetallicRoughnessDto();\n firstMaterial.name = \"Blue Material\";\n firstMaterial.baseColor = \"#9155ff\";\n firstMaterial.metallic = 0.1;\n firstMaterial.roughness = 0.9;\n firstMaterial.backFaceCulling = false;\n firstMaterial.zOffset = 3;\n const blueMatResult = material.pbrMetallicRoughness.create(firstMaterial);\n\n // Create drawing options for the first frames\n const firstDrawOptions = new DrawOcctShapeOptions();\n firstDrawOptions.drawEdges = true;\n firstDrawOptions.edgeColour = \"#000000\";\n firstDrawOptions.edgeWidth = 10;\n firstDrawOptions.faceMaterial = blueMatResult;\n\n bitbybit.draw.drawAnyAsync({\n entity: firstCompound,\n options: firstDrawOptions\n });\n\n // Create materials for rendering\n const secondMaterial = new PBRMetallicRoughnessDto();\n secondMaterial.name = \"Black Material\";\n secondMaterial.baseColor = \"#000000\";\n secondMaterial.metallic = 0.9;\n secondMaterial.roughness = 0.23;\n secondMaterial.backFaceCulling = false;\n secondMaterial.zOffset = 3;\n const secondMatResult = material.pbrMetallicRoughness.create(secondMaterial);\n\n // Create drawing options for the first frames\n const secondDrawOptions = new DrawOcctShapeOptions();\n secondDrawOptions.drawEdges = true;\n secondDrawOptions.edgeColour = \"#000000\";\n secondDrawOptions.edgeWidth = 10;\n secondDrawOptions.faceMaterial = secondMatResult;\n\n bitbybit.draw.drawAnyAsync({\n entity: secondCompound,\n options: secondDrawOptions\n });\n\n // Set up scene lighting and camera\n const skyboxOptions = new SkyboxDto();\n skyboxOptions.skybox = skyboxEnum.city;\n skyboxOptions.hideSkybox = true;\n scene.enableSkybox(skyboxOptions);\n\n const dirLightOptions = new DirectionalLightDto();\n dirLightOptions.intensity = 3;\n scene.drawDirectionalLight(dirLightOptions);\n\n const gradientBackgroundOptions = new SceneTwoColorLinearGradientDto();\n gradientBackgroundOptions.colorFrom = \"#050506\";\n gradientBackgroundOptions.colorTo = \"#627a9d\";\n gradientBackgroundOptions.direction = gradientDirectionEnum.toTop;\n scene.twoColorLinearGradient(gradientBackgroundOptions);\n\n const cameraConfigurationOptions = new CameraConfigurationDto();\n cameraConfigurationOptions.position = [44, 30, 44];\n cameraConfigurationOptions.lookAt = [0, 15, 0];\n scene.adjustActiveArcRotateCamera(cameraConfigurationOptions);\n\n const gridOptions = new SceneDrawGridMeshDto();\n bitbybit.draw.drawGridMesh(gridOptions);\n}\n\n// Execute the function\nstart();","version":"0.21.1","type":"typescript"}} title="Compounding hex frames into single entity will render faster" /> diff --git a/docs/learn/code/common/occt/shapes/compound/intro.md b/docs/learn/code/common/occt/shapes/compound/intro.md index 30d4f7c1..d11fd051 100644 --- a/docs/learn/code/common/occt/shapes/compound/intro.md +++ b/docs/learn/code/common/occt/shapes/compound/intro.md @@ -48,21 +48,21 @@ If you're not experiencing noticeable performance issues in the first example, t gridSizesphereRadiusspacinghalfGridxPositionsyPositionszPositionsxyzgridSize3sphereRadius1spacing2.5halfGridDIVIDEMULTIPLYgridSizespacing2xPositionsspacingNEGhalfGridhalfGridyPositionsspacingNEGhalfGridhalfGridzPositionsspacingNEGhalfGridhalfGridx1xPositions1y1yPositions1z1zPositions1GETFROM_STARTxPositionsxGETFROM_STARTyPositionsyGETFROM_STARTzPositionsz","version":"0.21.0","type":"blockly"}} + script={{"script":"gridSizesphereRadiusspacinghalfGridxPositionsyPositionszPositionsxyzgridSize3sphereRadius1spacing2.5halfGridDIVIDEMULTIPLYgridSizespacing2xPositionsspacingNEGhalfGridhalfGridyPositionsspacingNEGhalfGridhalfGridzPositionsspacingNEGhalfGridhalfGridx1xPositions1y1yPositions1z1zPositions1GETFROM_STARTxPositionsxGETFROM_STARTyPositionsyGETFROM_STARTzPositionsz","version":"0.21.1","type":"blockly"}} title="Creating individual spheres leads to performance issues" /> {\n // Grid parameters\n const gridSize = 3; // Number of spheres per side\n const sphereRadius = 1; // Radius of each sphere\n const spacing = 2.5; // Distance between sphere centers\n \n // Calculate grid boundaries\n const halfGrid = (gridSize * spacing) / 2;\n \n // Generate grid positions using span functions for 3D grid\n const xPositions = vector.span({\n min: -halfGrid,\n max: halfGrid,\n step: spacing\n });\n \n const yPositions = vector.span({\n min: -halfGrid,\n max: halfGrid,\n step: spacing\n });\n \n const zPositions = vector.span({\n min: -halfGrid,\n max: halfGrid,\n step: spacing\n });\n \n // Create individual spheres using nested loops for 3D grid\n // This approach creates each sphere separately, leading to performance issues\n for (const xPos of xPositions) {\n for (const yPos of yPositions) {\n for (const zPos of zPositions) {\n // Define sphere creation options\n const sphereOptions = new SphereDto();\n sphereOptions.radius = sphereRadius;\n sphereOptions.center = [xPos, yPos, zPos];\n \n // Create and immediately draw each sphere individually\n // This is inefficient as each sphere requires its own mesh and draw call\n const sphere = await solid.createSphere(sphereOptions);\n \n // Each draw call is separate, creating performance overhead\n bitbybit.draw.drawAnyAsync({\n entity: sphere\n });\n }\n }\n }\n}\n\n// Execute the function\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"// Import required DTOs for creating spheres\nconst { SphereDto } = Bit.Inputs.OCCT;\n// Import type definitions for type safety\ntype Point3 = Bit.Inputs.Base.Point3;\n\n// Get access to OCCT modules and utility functions\nconst { solid } = bitbybit.occt.shapes;\nconst { vector } = bitbybit;\n\n// Define the main function to create individual spheres (performance problem)\nconst start = async () => {\n // Grid parameters\n const gridSize = 3; // Number of spheres per side\n const sphereRadius = 1; // Radius of each sphere\n const spacing = 2.5; // Distance between sphere centers\n \n // Calculate grid boundaries\n const halfGrid = (gridSize * spacing) / 2;\n \n // Generate grid positions using span functions for 3D grid\n const xPositions = vector.span({\n min: -halfGrid,\n max: halfGrid,\n step: spacing\n });\n \n const yPositions = vector.span({\n min: -halfGrid,\n max: halfGrid,\n step: spacing\n });\n \n const zPositions = vector.span({\n min: -halfGrid,\n max: halfGrid,\n step: spacing\n });\n \n // Create individual spheres using nested loops for 3D grid\n // This approach creates each sphere separately, leading to performance issues\n for (const xPos of xPositions) {\n for (const yPos of yPositions) {\n for (const zPos of zPositions) {\n // Define sphere creation options\n const sphereOptions = new SphereDto();\n sphereOptions.radius = sphereRadius;\n sphereOptions.center = [xPos, yPos, zPos];\n \n // Create and immediately draw each sphere individually\n // This is inefficient as each sphere requires its own mesh and draw call\n const sphere = await solid.createSphere(sphereOptions);\n \n // Each draw call is separate, creating performance overhead\n bitbybit.draw.drawAnyAsync({\n entity: sphere\n });\n }\n }\n }\n}\n\n// Execute the function\nstart();","version":"0.21.1","type":"typescript"}} title="Creating individual spheres leads to performance issues" /> @@ -76,21 +76,21 @@ The solution to this performance problem is to use compounds. Instead of creatin gridSizesphereRadiusspacinghalfGridxPositionsyPositionszPositionsspheresxycompoundzgridSize3sphereRadius1spacing2.5halfGridDIVIDEMULTIPLYgridSizespacing2xPositionsspacingNEGhalfGridhalfGridyPositionsspacingNEGhalfGridhalfGridzPositionsspacingNEGhalfGridhalfGridspheresx1xPositions1y1yPositions1z1zPositions1INSERTLASTspheressphereRadiusGETFROM_STARTxPositionsxGETFROM_STARTyPositionsyGETFROM_STARTzPositionszcompoundspherescompound","version":"0.21.0","type":"blockly"}} + script={{"script":"gridSizesphereRadiusspacinghalfGridxPositionsyPositionszPositionsspheresxycompoundzgridSize3sphereRadius1spacing2.5halfGridDIVIDEMULTIPLYgridSizespacing2xPositionsspacingNEGhalfGridhalfGridyPositionsspacingNEGhalfGridhalfGridzPositionsspacingNEGhalfGridhalfGridspheresx1xPositions1y1yPositions1z1zPositions1INSERTLASTspheressphereRadiusGETFROM_STARTxPositionsxGETFROM_STARTyPositionsyGETFROM_STARTzPositionszcompoundspherescompound","version":"0.21.1","type":"blockly"}} title="Compounded spheres provide significantly better performance" /> {\n // Grid parameters\n const gridSize = 5; // Number of spheres per side\n const sphereRadius = 1; // Radius of each sphere\n const spacing = 2.5; // Distance between sphere centers\n\n // Calculate grid boundaries\n const halfGrid = (gridSize * spacing) / 2;\n\n // Generate grid positions using span functions\n const xPositions = vector.span({\n min: -halfGrid,\n max: halfGrid,\n step: spacing\n });\n\n const yPositions = vector.span({\n min: -halfGrid,\n max: halfGrid,\n step: spacing\n });\n\n const zPositions = vector.span({\n min: -halfGrid,\n max: halfGrid,\n step: spacing\n });\n\n // Create array to store all spheres before compounding\n const spheres: TopoDSSolidPointer[] = [];\n\n // Create all spheres first and store them in the array\n for (const xPos of xPositions) {\n for (const yPos of yPositions) {\n for (const zPos of zPositions) {\n // Define sphere creation options\n const sphereOptions = new SphereDto();\n sphereOptions.radius = sphereRadius;\n sphereOptions.center = [xPos, yPos, zPos];\n\n // Create sphere and add to array\n const sphere = await solid.createSphere(sphereOptions);\n spheres.push(sphere);\n }\n }\n }\n\n // Create compound from all spheres\n const compoundOptions = new CompoundShapesDto();\n compoundOptions.shapes = spheres;\n const sphereCompound = await compound.makeCompound(compoundOptions);\n\n // Draw compound\n bitbybit.draw.drawAnyAsync({\n entity: sphereCompound\n });\n\n}\n\n// Execute the function\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"// Import required DTOs for creating spheres, compounds, and transformations\nconst { SphereDto, CompoundShapesDto, RotateDto, TranslateDto } = Bit.Inputs.OCCT;\n// Import type definitions for type safety\ntype Point3 = Bit.Inputs.Base.Point3;\ntype Vector3 = Bit.Inputs.Base.Vector3;\ntype TopoDSSolidPointer = Bit.Inputs.OCCT.TopoDSSolidPointer;\ntype TopoDSCompoundPointer = Bit.Inputs.OCCT.TopoDSCompoundPointer;\n\n// Get access to OCCT modules and utility functions\nconst { solid, compound } = bitbybit.occt.shapes;\nconst { transforms } = bitbybit.occt;\nconst { vector } = bitbybit;\n\n// Define the main function to create a compound\nconst start = async () => {\n // Grid parameters\n const gridSize = 5; // Number of spheres per side\n const sphereRadius = 1; // Radius of each sphere\n const spacing = 2.5; // Distance between sphere centers\n\n // Calculate grid boundaries\n const halfGrid = (gridSize * spacing) / 2;\n\n // Generate grid positions using span functions\n const xPositions = vector.span({\n min: -halfGrid,\n max: halfGrid,\n step: spacing\n });\n\n const yPositions = vector.span({\n min: -halfGrid,\n max: halfGrid,\n step: spacing\n });\n\n const zPositions = vector.span({\n min: -halfGrid,\n max: halfGrid,\n step: spacing\n });\n\n // Create array to store all spheres before compounding\n const spheres: TopoDSSolidPointer[] = [];\n\n // Create all spheres first and store them in the array\n for (const xPos of xPositions) {\n for (const yPos of yPositions) {\n for (const zPos of zPositions) {\n // Define sphere creation options\n const sphereOptions = new SphereDto();\n sphereOptions.radius = sphereRadius;\n sphereOptions.center = [xPos, yPos, zPos];\n\n // Create sphere and add to array\n const sphere = await solid.createSphere(sphereOptions);\n spheres.push(sphere);\n }\n }\n }\n\n // Create compound from all spheres\n const compoundOptions = new CompoundShapesDto();\n compoundOptions.shapes = spheres;\n const sphereCompound = await compound.makeCompound(compoundOptions);\n\n // Draw compound\n bitbybit.draw.drawAnyAsync({\n entity: sphereCompound\n });\n\n}\n\n// Execute the function\nstart();","version":"0.21.1","type":"typescript"}} title="Compounded spheres provide significantly better performance" /> @@ -105,21 +105,21 @@ Another major advantage of compounds is the ability to transform the entire grou gridSizesphereRadiusspacinghalfGridxPositionsyPositionszPositionsspheresxycompoundzrotatedCompoundgridSize5sphereRadius1spacing2.5halfGridDIVIDEMULTIPLYgridSizespacing2xPositionsspacingNEGhalfGridhalfGridyPositionsspacingNEGhalfGridhalfGridzPositionsspacingNEGhalfGridhalfGridspheresx1xPositions1y1yPositions1z1zPositions1INSERTLASTspheressphereRadiusGETFROM_STARTxPositionsxGETFROM_STARTyPositionsyGETFROM_STARTzPositionszcompoundspheresrotatedCompoundcompound00145rotatedCompound","version":"0.21.0","type":"blockly"}} + script={{"script":"gridSizesphereRadiusspacinghalfGridxPositionsyPositionszPositionsspheresxycompoundzrotatedCompoundgridSize5sphereRadius1spacing2.5halfGridDIVIDEMULTIPLYgridSizespacing2xPositionsspacingNEGhalfGridhalfGridyPositionsspacingNEGhalfGridhalfGridzPositionsspacingNEGhalfGridhalfGridspheresx1xPositions1y1yPositions1z1zPositions1INSERTLASTspheressphereRadiusGETFROM_STARTxPositionsxGETFROM_STARTyPositionsyGETFROM_STARTzPositionszcompoundspheresrotatedCompoundcompound00145rotatedCompound","version":"0.21.1","type":"blockly"}} title="Compound can be rotated and translated as a single grouped entity" /> {\n // Grid parameters\n const gridSize = 5; // Number of spheres per side\n const sphereRadius = 1; // Radius of each sphere\n const spacing = 2.5; // Distance between sphere centers\n\n // Calculate grid boundaries\n const halfGrid = (gridSize * spacing) / 2;\n\n // Generate grid positions using span functions\n const xPositions = vector.span({\n min: -halfGrid,\n max: halfGrid,\n step: spacing\n });\n\n const yPositions = vector.span({\n min: -halfGrid,\n max: halfGrid,\n step: spacing\n });\n\n const zPositions = vector.span({\n min: -halfGrid,\n max: halfGrid,\n step: spacing\n });\n\n // Create array to store all spheres before compounding\n const spheres: TopoDSSolidPointer[] = [];\n\n // Create all spheres first and store them in the array\n for (const xPos of xPositions) {\n for (const yPos of yPositions) {\n for (const zPos of zPositions) {\n // Define sphere creation options\n const sphereOptions = new SphereDto();\n sphereOptions.radius = sphereRadius;\n sphereOptions.center = [xPos, yPos, zPos];\n\n // Create sphere and add to array\n const sphere = await solid.createSphere(sphereOptions);\n spheres.push(sphere);\n }\n }\n }\n\n // Create compound from all spheres\n const compoundOptions = new CompoundShapesDto();\n compoundOptions.shapes = spheres;\n const sphereCompound = await compound.makeCompound(compoundOptions);\n\n // Transform the entire compound as a single entity\n // First, rotate the compound around the Z-axis\n const rotateOptions = new RotateDto();\n rotateOptions.shape = sphereCompound;\n rotateOptions.axis = [0, 0, 1]; // Z-axis rotation\n rotateOptions.angle = 45; // 45 degrees\n const rotatedCompound = await transforms.rotate(rotateOptions);\n\n // Draw the transformed compound\n // All spheres move together as a single unified entity\n bitbybit.draw.drawAnyAsync({\n entity: rotatedCompound\n });\n}\n\n// Execute the function\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"// Import required DTOs for creating spheres, compounds, and transformations\nconst { SphereDto, CompoundShapesDto, RotateDto, TranslateDto } = Bit.Inputs.OCCT;\n// Import type definitions for type safety\ntype Point3 = Bit.Inputs.Base.Point3;\ntype Vector3 = Bit.Inputs.Base.Vector3;\ntype TopoDSSolidPointer = Bit.Inputs.OCCT.TopoDSSolidPointer;\ntype TopoDSCompoundPointer = Bit.Inputs.OCCT.TopoDSCompoundPointer;\n\n// Get access to OCCT modules and utility functions\nconst { solid, compound } = bitbybit.occt.shapes;\nconst { transforms } = bitbybit.occt;\nconst { vector } = bitbybit;\n\n// Define the main function to create and transform a compound (unified transformation)\nconst start = async () => {\n // Grid parameters\n const gridSize = 5; // Number of spheres per side\n const sphereRadius = 1; // Radius of each sphere\n const spacing = 2.5; // Distance between sphere centers\n\n // Calculate grid boundaries\n const halfGrid = (gridSize * spacing) / 2;\n\n // Generate grid positions using span functions\n const xPositions = vector.span({\n min: -halfGrid,\n max: halfGrid,\n step: spacing\n });\n\n const yPositions = vector.span({\n min: -halfGrid,\n max: halfGrid,\n step: spacing\n });\n\n const zPositions = vector.span({\n min: -halfGrid,\n max: halfGrid,\n step: spacing\n });\n\n // Create array to store all spheres before compounding\n const spheres: TopoDSSolidPointer[] = [];\n\n // Create all spheres first and store them in the array\n for (const xPos of xPositions) {\n for (const yPos of yPositions) {\n for (const zPos of zPositions) {\n // Define sphere creation options\n const sphereOptions = new SphereDto();\n sphereOptions.radius = sphereRadius;\n sphereOptions.center = [xPos, yPos, zPos];\n\n // Create sphere and add to array\n const sphere = await solid.createSphere(sphereOptions);\n spheres.push(sphere);\n }\n }\n }\n\n // Create compound from all spheres\n const compoundOptions = new CompoundShapesDto();\n compoundOptions.shapes = spheres;\n const sphereCompound = await compound.makeCompound(compoundOptions);\n\n // Transform the entire compound as a single entity\n // First, rotate the compound around the Z-axis\n const rotateOptions = new RotateDto();\n rotateOptions.shape = sphereCompound;\n rotateOptions.axis = [0, 0, 1]; // Z-axis rotation\n rotateOptions.angle = 45; // 45 degrees\n const rotatedCompound = await transforms.rotate(rotateOptions);\n\n // Draw the transformed compound\n // All spheres move together as a single unified entity\n bitbybit.draw.drawAnyAsync({\n entity: rotatedCompound\n });\n}\n\n// Execute the function\nstart();","version":"0.21.1","type":"typescript"}} title="Compound can be rotated and translated as a single grouped entity" /> diff --git a/docs/learn/code/common/occt/shapes/edge/edge-constraints.md b/docs/learn/code/common/occt/shapes/edge/edge-constraints.md index b7a1912b..891abff2 100644 --- a/docs/learn/code/common/occt/shapes/edge/edge-constraints.md +++ b/docs/learn/code/common/occt/shapes/edge/edge-constraints.md @@ -46,21 +46,21 @@ This is particularly useful in mechanical design when you need to connect two sp circlepoint1point2tangentLinescircle4000010point1007point2909tangentLinescirclepoint1point21e-7'all''none'tangentLinescirclepoint1point2","version":"0.21.0","type":"blockly"}} + script={{"script":"circlepoint1point2tangentLinescircle4000010point1007point2909tangentLinescirclepoint1point21e-7'all''none'tangentLinescirclepoint1point2","version":"0.21.1","type":"blockly"}} title="Constraint tangent lines from two points to circle" /> {\n // Create a circle edge\n const circleOptions = new CircleDto();\n circleOptions.radius = 4;\n circleOptions.center = [0, 0, 0] as Point3;\n circleOptions.direction = [0, 1, 0] as Vector3;\n\n const circle = await bitbybit.occt.shapes.edge.createCircleEdge(circleOptions);\n\n // Define two points\n const point1: Point3 = [0, 0, 7];\n const point2: Point3 = [9, 0, 9];\n\n // Create constraint options for tangent lines from two points to circle\n const constraintOptions = new ConstraintTanLinesFromTwoPtsToCircleDto();\n constraintOptions.circle = circle;\n constraintOptions.point1 = point1;\n constraintOptions.point2 = point2;\n constraintOptions.tolerance = 1e-7;\n constraintOptions.positionResult = positionResultEnum.all;\n constraintOptions.circleRemainder = circleInclusionEnum.none;\n\n // Create the constraint tangent lines\n const tangentLines = await bitbybit.occt.shapes.edge.constraintTanLinesFromTwoPtsToCircle(constraintOptions);\n\n // Draw the tangent lines\n bitbybit.draw.drawAnyAsync({ entity: tangentLines });\n // Draw the circle\n bitbybit.draw.drawAnyAsync({ entity: circle });\n // Draw the two points\n bitbybit.draw.drawAnyAsync({ entity: [point1] });\n bitbybit.draw.drawAnyAsync({ entity: [point2] });\n}\n\n// Execute the function\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"const { CircleDto, ConstraintTanLinesFromTwoPtsToCircleDto, positionResultEnum, circleInclusionEnum } = Bit.Inputs.OCCT;\n// Import required types\ntype Point3 = Bit.Inputs.Base.Point3;\ntype Vector3 = Bit.Inputs.Base.Vector3;\ntype TopoDSEdgePointer = Bit.Inputs.OCCT.TopoDSEdgePointer;\n\n// Define the main function\nconst start = async () => {\n // Create a circle edge\n const circleOptions = new CircleDto();\n circleOptions.radius = 4;\n circleOptions.center = [0, 0, 0] as Point3;\n circleOptions.direction = [0, 1, 0] as Vector3;\n\n const circle = await bitbybit.occt.shapes.edge.createCircleEdge(circleOptions);\n\n // Define two points\n const point1: Point3 = [0, 0, 7];\n const point2: Point3 = [9, 0, 9];\n\n // Create constraint options for tangent lines from two points to circle\n const constraintOptions = new ConstraintTanLinesFromTwoPtsToCircleDto();\n constraintOptions.circle = circle;\n constraintOptions.point1 = point1;\n constraintOptions.point2 = point2;\n constraintOptions.tolerance = 1e-7;\n constraintOptions.positionResult = positionResultEnum.all;\n constraintOptions.circleRemainder = circleInclusionEnum.none;\n\n // Create the constraint tangent lines\n const tangentLines = await bitbybit.occt.shapes.edge.constraintTanLinesFromTwoPtsToCircle(constraintOptions);\n\n // Draw the tangent lines\n bitbybit.draw.drawAnyAsync({ entity: tangentLines });\n // Draw the circle\n bitbybit.draw.drawAnyAsync({ entity: circle });\n // Draw the two points\n bitbybit.draw.drawAnyAsync({ entity: [point1] });\n bitbybit.draw.drawAnyAsync({ entity: [point2] });\n}\n\n// Execute the function\nstart();","version":"0.21.1","type":"typescript"}} title="Constraint tangent lines from two points to circle" /> @@ -77,21 +77,21 @@ This operation is commonly used in architectural drawings when you need to creat circlepointtangentLinescircle4000010point807tangentLinescirclepoint1e-7'all''none'tangentLinescirclepoint","version":"0.21.0","type":"blockly"}} + script={{"script":"circlepointtangentLinescircle4000010point807tangentLinescirclepoint1e-7'all''none'tangentLinescirclepoint","version":"0.21.1","type":"blockly"}} title="Constraint tangent lines from point to circle" /> {\n // Create a circle edge\n const circleOptions = new CircleDto();\n circleOptions.radius = 4;\n circleOptions.center = [0, 0, 0] as Point3;\n circleOptions.direction = [0, 1, 0] as Vector3;\n\n const circle = await bitbybit.occt.shapes.edge.createCircleEdge(circleOptions);\n\n // Define a point\n const point: Point3 = [8, 0, 7];\n\n // Create constraint options for tangent lines from point to circle\n const constraintOptions = new ConstraintTanLinesFromPtToCircleDto();\n constraintOptions.circle = circle;\n constraintOptions.point = point;\n constraintOptions.tolerance = 1e-7;\n constraintOptions.positionResult = positionResultEnum.all;\n constraintOptions.circleRemainder = circleInclusionEnum.none;\n\n // Create the constraint tangent lines\n const tangentLines = await bitbybit.occt.shapes.edge.constraintTanLinesFromPtToCircle(constraintOptions);\n\n // Draw the tangent lines\n bitbybit.draw.drawAnyAsync({ entity: tangentLines });\n // Draw the circle\n bitbybit.draw.drawAnyAsync({ entity: circle });\n // Draw the point\n bitbybit.draw.drawAnyAsync({ entity: point });\n}\n\n// Execute the function\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"const { CircleDto, ConstraintTanLinesFromPtToCircleDto, positionResultEnum, circleInclusionEnum } = Bit.Inputs.OCCT;\n// Import required types\ntype Point3 = Bit.Inputs.Base.Point3;\ntype Vector3 = Bit.Inputs.Base.Vector3;\ntype TopoDSEdgePointer = Bit.Inputs.OCCT.TopoDSEdgePointer;\n\n// Define the main function\nconst start = async () => {\n // Create a circle edge\n const circleOptions = new CircleDto();\n circleOptions.radius = 4;\n circleOptions.center = [0, 0, 0] as Point3;\n circleOptions.direction = [0, 1, 0] as Vector3;\n\n const circle = await bitbybit.occt.shapes.edge.createCircleEdge(circleOptions);\n\n // Define a point\n const point: Point3 = [8, 0, 7];\n\n // Create constraint options for tangent lines from point to circle\n const constraintOptions = new ConstraintTanLinesFromPtToCircleDto();\n constraintOptions.circle = circle;\n constraintOptions.point = point;\n constraintOptions.tolerance = 1e-7;\n constraintOptions.positionResult = positionResultEnum.all;\n constraintOptions.circleRemainder = circleInclusionEnum.none;\n\n // Create the constraint tangent lines\n const tangentLines = await bitbybit.occt.shapes.edge.constraintTanLinesFromPtToCircle(constraintOptions);\n\n // Draw the tangent lines\n bitbybit.draw.drawAnyAsync({ entity: tangentLines });\n // Draw the circle\n bitbybit.draw.drawAnyAsync({ entity: circle });\n // Draw the point\n bitbybit.draw.drawAnyAsync({ entity: point });\n}\n\n// Execute the function\nstart();","version":"0.21.1","type":"typescript"}} title="Constraint tangent lines from point to circle" /> @@ -107,21 +107,21 @@ This is especially valuable in gear design, pulley systems, or any mechanical ap circle1circle2tangentLinescircle13000010circle22700010tangentLinescircle1circle21e-7'all''none'tangentLinescircle1circle2","version":"0.21.0","type":"blockly"}} + script={{"script":"circle1circle2tangentLinescircle13000010circle22700010tangentLinescircle1circle21e-7'all''none'tangentLinescircle1circle2","version":"0.21.1","type":"blockly"}} title="Constraint tangent lines on two circles" /> {\n // Create first circle edge\n const circle1Options = new CircleDto();\n circle1Options.radius = 3;\n circle1Options.center = [0, 0, 0] as Point3;\n circle1Options.direction = [0, 1, 0] as Vector3;\n\n const circle1 = await bitbybit.occt.shapes.edge.createCircleEdge(circle1Options);\n\n // Create second circle edge\n const circle2Options = new CircleDto();\n circle2Options.radius = 2;\n circle2Options.center = [7, 0, 0] as Point3;\n circle2Options.direction = [0, 1, 0] as Vector3;\n\n const circle2 = await bitbybit.occt.shapes.edge.createCircleEdge(circle2Options);\n\n // Create constraint options for tangent lines between two circles\n const constraintOptions = new ConstraintTanLinesOnTwoCirclesDto();\n constraintOptions.circle1 = circle1;\n constraintOptions.circle2 = circle2;\n constraintOptions.tolerance = 1e-7;\n constraintOptions.positionResult = positionResultEnum.all;\n constraintOptions.circleRemainders = twoCircleInclusionEnum.none;\n\n // Create the constraint tangent lines\n const tangentLines = await bitbybit.occt.shapes.edge.constraintTanLinesOnTwoCircles(constraintOptions);\n\n // Draw the tangent lines\n bitbybit.draw.drawAnyAsync({ entity: tangentLines });\n // Draw the first circle\n bitbybit.draw.drawAnyAsync({ entity: circle1 });\n // Draw the second circle\n bitbybit.draw.drawAnyAsync({ entity: circle2 });\n}\n\n// Execute the function\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"const { CircleDto, ConstraintTanLinesOnTwoCirclesDto, positionResultEnum, twoCircleInclusionEnum } = Bit.Inputs.OCCT;\n// Import required types\ntype Point3 = Bit.Inputs.Base.Point3;\ntype Vector3 = Bit.Inputs.Base.Vector3;\ntype TopoDSEdgePointer = Bit.Inputs.OCCT.TopoDSEdgePointer;\n\n// Define the main function\nconst start = async () => {\n // Create first circle edge\n const circle1Options = new CircleDto();\n circle1Options.radius = 3;\n circle1Options.center = [0, 0, 0] as Point3;\n circle1Options.direction = [0, 1, 0] as Vector3;\n\n const circle1 = await bitbybit.occt.shapes.edge.createCircleEdge(circle1Options);\n\n // Create second circle edge\n const circle2Options = new CircleDto();\n circle2Options.radius = 2;\n circle2Options.center = [7, 0, 0] as Point3;\n circle2Options.direction = [0, 1, 0] as Vector3;\n\n const circle2 = await bitbybit.occt.shapes.edge.createCircleEdge(circle2Options);\n\n // Create constraint options for tangent lines between two circles\n const constraintOptions = new ConstraintTanLinesOnTwoCirclesDto();\n constraintOptions.circle1 = circle1;\n constraintOptions.circle2 = circle2;\n constraintOptions.tolerance = 1e-7;\n constraintOptions.positionResult = positionResultEnum.all;\n constraintOptions.circleRemainders = twoCircleInclusionEnum.none;\n\n // Create the constraint tangent lines\n const tangentLines = await bitbybit.occt.shapes.edge.constraintTanLinesOnTwoCircles(constraintOptions);\n\n // Draw the tangent lines\n bitbybit.draw.drawAnyAsync({ entity: tangentLines });\n // Draw the first circle\n bitbybit.draw.drawAnyAsync({ entity: circle1 });\n // Draw the second circle\n bitbybit.draw.drawAnyAsync({ entity: circle2 });\n}\n\n// Execute the function\nstart();","version":"0.21.1","type":"typescript"}} title="Constraint tangent lines on two circles" /> @@ -138,21 +138,21 @@ This is particularly useful for creating buffer zones around existing circular f circle1circle2tangentCirclescircle13000010circle21.5500010tangentCirclescircle1circle21e-70.8tangentCirclescircle1circle2","version":"0.21.0","type":"blockly"}} + script={{"script":"circle1circle2tangentCirclescircle13000010circle21.5500010tangentCirclescircle1circle21e-70.8tangentCirclescircle1circle2","version":"0.21.1","type":"blockly"}} title="Constraint tangent circles on two circles" /> {\n // Create first circle edge\n const circle1Options = new CircleDto();\n circle1Options.radius = 3;\n circle1Options.center = [0, 0, 0] as Point3;\n circle1Options.direction = [0, 1, 0] as Vector3;\n\n const circle1 = await bitbybit.occt.shapes.edge.createCircleEdge(circle1Options);\n\n // Create second circle edge\n const circle2Options = new CircleDto();\n circle2Options.radius = 1.5;\n circle2Options.center = [5, 0, 0] as Point3;\n circle2Options.direction = [0, 1, 0] as Vector3;\n\n const circle2 = await bitbybit.occt.shapes.edge.createCircleEdge(circle2Options);\n\n // Create constraint options for tangent circles between two circles\n const constraintOptions = new ConstraintTanCirclesOnTwoCirclesDto();\n constraintOptions.circle1 = circle1;\n constraintOptions.circle2 = circle2;\n constraintOptions.tolerance = 1e-7;\n constraintOptions.radius = 0.8;\n\n // Create the constraint tangent circles\n const tangentCircles = await bitbybit.occt.shapes.edge.constraintTanCirclesOnTwoCircles(constraintOptions);\n\n // Draw the tangent circles\n bitbybit.draw.drawAnyAsync({ entity: tangentCircles });\n // Draw the first circle\n bitbybit.draw.drawAnyAsync({ entity: circle1 });\n // Draw the second circle\n bitbybit.draw.drawAnyAsync({ entity: circle2 });\n}\n\n// Execute the function\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"const { CircleDto, ConstraintTanCirclesOnTwoCirclesDto } = Bit.Inputs.OCCT;\n// Import required types\ntype Point3 = Bit.Inputs.Base.Point3;\ntype Vector3 = Bit.Inputs.Base.Vector3;\ntype TopoDSEdgePointer = Bit.Inputs.OCCT.TopoDSEdgePointer;\n\n// Define the main function\nconst start = async () => {\n // Create first circle edge\n const circle1Options = new CircleDto();\n circle1Options.radius = 3;\n circle1Options.center = [0, 0, 0] as Point3;\n circle1Options.direction = [0, 1, 0] as Vector3;\n\n const circle1 = await bitbybit.occt.shapes.edge.createCircleEdge(circle1Options);\n\n // Create second circle edge\n const circle2Options = new CircleDto();\n circle2Options.radius = 1.5;\n circle2Options.center = [5, 0, 0] as Point3;\n circle2Options.direction = [0, 1, 0] as Vector3;\n\n const circle2 = await bitbybit.occt.shapes.edge.createCircleEdge(circle2Options);\n\n // Create constraint options for tangent circles between two circles\n const constraintOptions = new ConstraintTanCirclesOnTwoCirclesDto();\n constraintOptions.circle1 = circle1;\n constraintOptions.circle2 = circle2;\n constraintOptions.tolerance = 1e-7;\n constraintOptions.radius = 0.8;\n\n // Create the constraint tangent circles\n const tangentCircles = await bitbybit.occt.shapes.edge.constraintTanCirclesOnTwoCircles(constraintOptions);\n\n // Draw the tangent circles\n bitbybit.draw.drawAnyAsync({ entity: tangentCircles });\n // Draw the first circle\n bitbybit.draw.drawAnyAsync({ entity: circle1 });\n // Draw the second circle\n bitbybit.draw.drawAnyAsync({ entity: circle2 });\n}\n\n// Execute the function\nstart();","version":"0.21.1","type":"typescript"}} title="Constraint tangent circles on two circles" /> @@ -169,21 +169,21 @@ This constraint is perfect for creating rounded transitions in designs where you circlepointtangentCirclescircle3000010point400tangentCirclescirclepoint1e-72tangentCirclescirclepoint","version":"0.21.0","type":"blockly"}} + script={{"script":"circlepointtangentCirclescircle3000010point400tangentCirclescirclepoint1e-72tangentCirclescirclepoint","version":"0.21.1","type":"blockly"}} title="Constraint tangent circles on circle and point" /> {\n // Create a circle edge\n const circleOptions = new CircleDto();\n circleOptions.radius = 3;\n circleOptions.center = [0, 0, 0] as Point3;\n circleOptions.direction = [0, 1, 0] as Vector3;\n\n const circle = await bitbybit.occt.shapes.edge.createCircleEdge(circleOptions);\n\n // Define a point\n const point: Point3 = [4, 0, 0];\n\n // Create constraint options for tangent circles between circle and point\n const constraintOptions = new ConstraintTanCirclesOnCircleAndPntDto();\n constraintOptions.circle = circle;\n constraintOptions.point = point;\n constraintOptions.tolerance = 1e-7;\n constraintOptions.radius = 2;\n\n // Create the constraint tangent circles\n const tangentCircles = await bitbybit.occt.shapes.edge.constraintTanCirclesOnCircleAndPnt(constraintOptions);\n\n // Draw the tangent circles\n bitbybit.draw.drawAnyAsync({ entity: tangentCircles });\n // Draw the circle\n bitbybit.draw.drawAnyAsync({ entity: circle });\n // Draw the point\n bitbybit.draw.drawAnyAsync({ entity: point });\n}\n\n// Execute the function\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"const { CircleDto, ConstraintTanCirclesOnCircleAndPntDto } = Bit.Inputs.OCCT;\n// Import required types\ntype Point3 = Bit.Inputs.Base.Point3;\ntype Vector3 = Bit.Inputs.Base.Vector3;\ntype TopoDSEdgePointer = Bit.Inputs.OCCT.TopoDSEdgePointer;\n\n// Define the main function\nconst start = async () => {\n // Create a circle edge\n const circleOptions = new CircleDto();\n circleOptions.radius = 3;\n circleOptions.center = [0, 0, 0] as Point3;\n circleOptions.direction = [0, 1, 0] as Vector3;\n\n const circle = await bitbybit.occt.shapes.edge.createCircleEdge(circleOptions);\n\n // Define a point\n const point: Point3 = [4, 0, 0];\n\n // Create constraint options for tangent circles between circle and point\n const constraintOptions = new ConstraintTanCirclesOnCircleAndPntDto();\n constraintOptions.circle = circle;\n constraintOptions.point = point;\n constraintOptions.tolerance = 1e-7;\n constraintOptions.radius = 2;\n\n // Create the constraint tangent circles\n const tangentCircles = await bitbybit.occt.shapes.edge.constraintTanCirclesOnCircleAndPnt(constraintOptions);\n\n // Draw the tangent circles\n bitbybit.draw.drawAnyAsync({ entity: tangentCircles });\n // Draw the circle\n bitbybit.draw.drawAnyAsync({ entity: circle });\n // Draw the point\n bitbybit.draw.drawAnyAsync({ entity: point });\n}\n\n// Execute the function\nstart();","version":"0.21.1","type":"typescript"}} title="Constraint tangent circles on circle and point" /> diff --git a/docs/learn/code/common/occt/shapes/edge/edge-indexes.mdx b/docs/learn/code/common/occt/shapes/edge/edge-indexes.mdx index e16719af..6baf909b 100644 --- a/docs/learn/code/common/occt/shapes/edge/edge-indexes.mdx +++ b/docs/learn/code/common/occt/shapes/edge/edge-indexes.mdx @@ -42,21 +42,21 @@ Below are examples in TypeScript, Blockly, and Rete that demonstrate creating a **TypeScript Example: Drawing Edge Indexes** {\n\n const boxOpt = new Bit.Inputs.OCCT.BoxDto();\n boxOpt.width = 5;\n boxOpt.length = 8;\n boxOpt.height = 10;\n const box = await bitbybit.occt.shapes.solid.createBox(boxOpt);\n\n const drawOpt = new Bit.Inputs.Draw.DrawOcctShapeOptions();\n drawOpt.drawEdgeIndexes = true;\n drawOpt.faceOpacity = 0.3;\n drawOpt.edgeOpacity = 0.3;\n drawOpt.edgeIndexHeight = 0.24\n\n bitbybit.draw.drawAnyAsync({\n entity: box,\n options: drawOpt\n });\n}\n\nstart();\n","version":"0.21.0","type":"typescript"}} + script={{"script":"const start = async () => {\n\n const boxOpt = new Bit.Inputs.OCCT.BoxDto();\n boxOpt.width = 5;\n boxOpt.length = 8;\n boxOpt.height = 10;\n const box = await bitbybit.occt.shapes.solid.createBox(boxOpt);\n\n const drawOpt = new Bit.Inputs.Draw.DrawOcctShapeOptions();\n drawOpt.drawEdgeIndexes = true;\n drawOpt.faceOpacity = 0.3;\n drawOpt.edgeOpacity = 0.3;\n drawOpt.edgeIndexHeight = 0.24\n\n bitbybit.draw.drawAnyAsync({\n entity: box,\n options: drawOpt\n });\n}\n\nstart();\n","version":"0.21.1","type":"typescript"}} title="Edge Indexing" /> **Blockly Example: Drawing Edge Indexes** 58100000.30.3#ffffff#ff00002TRUETRUE0.01TRUE0.24#ff00ffFALSE0.06#0000ff","version":"0.21.0","type":"blockly"}} + script={{"script":"58100000.30.3#ffffff#ff00002TRUETRUE0.01TRUE0.24#ff00ffFALSE0.06#0000ff","version":"0.21.1","type":"blockly"}} title="Edge Indexing" /> **Rete Example: Drawing Edge Indexes** diff --git a/docs/learn/code/common/occt/shapes/edge/edge-primitives.md b/docs/learn/code/common/occt/shapes/edge/edge-primitives.md index 282b011c..92f2eab7 100644 --- a/docs/learn/code/common/occt/shapes/edge/edge-primitives.md +++ b/docs/learn/code/common/occt/shapes/edge/edge-primitives.md @@ -48,21 +48,21 @@ Let's start with the most basic edge primitive - the line edge. startPointendPointstartPoint-500endPoint500startPointendPointstartPointendPoint","version":"0.21.0","type":"blockly"}} + script={{"script":"startPointendPointstartPoint-500endPoint500startPointendPointstartPointendPoint","version":"0.21.1","type":"blockly"}} title="Creating primitive solids" /> {\n // Create start and end points\n const startPoint: Point3 = [-5, 0, 0];\n const endPoint: Point3 = [5, 0, 0];\n\n // Create a line between the points\n const lineOptions = new LineDto();\n lineOptions.start = startPoint;\n lineOptions.end = endPoint;\n\n const line = await bitbybit.occt.shapes.edge.line(lineOptions);\n\n // Draw the line and points\n bitbybit.draw.drawAnyAsync({ entity: line });\n bitbybit.draw.drawAnyAsync({ entity: startPoint });\n bitbybit.draw.drawAnyAsync({ entity: endPoint });\n}\n\n// Execute the function\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"const { LineDto } = Bit.Inputs.OCCT;\n// Import required types\ntype Point3 = Bit.Inputs.Base.Point3;\n\n// Define the main function\nconst start = async () => {\n // Create start and end points\n const startPoint: Point3 = [-5, 0, 0];\n const endPoint: Point3 = [5, 0, 0];\n\n // Create a line between the points\n const lineOptions = new LineDto();\n lineOptions.start = startPoint;\n lineOptions.end = endPoint;\n\n const line = await bitbybit.occt.shapes.edge.line(lineOptions);\n\n // Draw the line and points\n bitbybit.draw.drawAnyAsync({ entity: line });\n bitbybit.draw.drawAnyAsync({ entity: startPoint });\n bitbybit.draw.drawAnyAsync({ entity: endPoint });\n}\n\n// Execute the function\nstart();","version":"0.21.1","type":"typescript"}} title="Creating primitive solids" /> @@ -88,21 +88,21 @@ This example demonstrates how to create a simple straight line edge in 3D space. startPointmidPointendPointstartPoint-500midPoint060endPoint500startPointmidPointendPointstartPointmidPointendPoint","version":"0.21.0","type":"blockly"}} + script={{"script":"startPointmidPointendPointstartPoint-500midPoint060endPoint500startPointmidPointendPointstartPointmidPointendPoint","version":"0.21.1","type":"blockly"}} title="Arc edge through 3 points" /> {\n // Create start and end points\n const startPoint: Point3 = [-5, 0, 0];\n const midPoint: Point3 = [0, 6, 0];\n const endPoint: Point3 = [5, 0, 0];\n\n // Create a arc between three points\n const arcOptions = new ArcEdgeThreePointsDto();\n arcOptions.start = startPoint;\n arcOptions.middle = midPoint;\n arcOptions.end = endPoint;\n\n const arc = await bitbybit.occt.shapes.edge.arcThroughThreePoints(arcOptions);\n\n // Draw the arc and points\n bitbybit.draw.drawAnyAsync({ entity: arc });\n bitbybit.draw.drawAnyAsync({ entity: [startPoint, midPoint, endPoint] });\n}\n\n// Execute the function\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"const { ArcEdgeThreePointsDto } = Bit.Inputs.OCCT;\n// Import required types\ntype Point3 = Bit.Inputs.Base.Point3;\n\n// Define the main function\nconst start = async () => {\n // Create start and end points\n const startPoint: Point3 = [-5, 0, 0];\n const midPoint: Point3 = [0, 6, 0];\n const endPoint: Point3 = [5, 0, 0];\n\n // Create a arc between three points\n const arcOptions = new ArcEdgeThreePointsDto();\n arcOptions.start = startPoint;\n arcOptions.middle = midPoint;\n arcOptions.end = endPoint;\n\n const arc = await bitbybit.occt.shapes.edge.arcThroughThreePoints(arcOptions);\n\n // Draw the arc and points\n bitbybit.draw.drawAnyAsync({ entity: arc });\n bitbybit.draw.drawAnyAsync({ entity: [startPoint, midPoint, endPoint] });\n}\n\n// Execute the function\nstart();","version":"0.21.1","type":"typescript"}} title="Arc edge through 3 points" /> @@ -128,21 +128,21 @@ This example shows how to create an arc edge that passes through three specific startPointvecEndPtendPointvectorstartPoint-500vecEndPt-230endPoint500vectorstartPointvecEndPtstartPointvectorendPointstartPointvecEndPtendPointstartPointvecEndPt","version":"0.21.0","type":"blockly"}} + script={{"script":"startPointvecEndPtendPointvectorstartPoint-500vecEndPt-230endPoint500vectorstartPointvecEndPtstartPointvectorendPointstartPointvecEndPtendPointstartPointvecEndPt","version":"0.21.1","type":"blockly"}} title="Arc edge from two points and tangent" /> {\n // Create start and end points\n const startPoint: Point3 = [-5, 0, 0];\n const vecEndPt: Point3 = [-2, 3, 0];\n const endPoint: Point3 = [5, 0, 0];\n\n // Create tangent vector\n const vecOpt = new TwoVectorsDto();\n vecOpt.first = startPoint;\n vecOpt.second = vecEndPt;\n const vector = bitbybit.vector.sub(vecOpt) as Vector3;\n\n // Create an arc\n const arcOptions = new ArcEdgeTwoPointsTangentDto();\n arcOptions.start = startPoint;\n arcOptions.tangentVec = vector;\n arcOptions.end = endPoint;\n\n const arc = await bitbybit.occt.shapes.edge.arcThroughTwoPointsAndTangent(arcOptions);\n\n // Draw the arc, points and tangent\n bitbybit.draw.drawAnyAsync({ entity: arc });\n bitbybit.draw.drawAnyAsync({ entity: [startPoint, vecEndPt, endPoint] });\n\n // When two points are provided Bitbybit draws them as a line segment\n bitbybit.draw.drawAnyAsync({ entity: [startPoint, vecEndPt] });\n}\n\n// Execute the function\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"const { ArcEdgeTwoPointsTangentDto } = Bit.Inputs.OCCT;\nconst { TwoVectorsDto } = Bit.Inputs.Vector;\n\n// Import required types\ntype Point3 = Bit.Inputs.Base.Point3;\ntype Vector3 = Bit.Inputs.Base.Vector3;\n\n\n// Define the main function\nconst start = async () => {\n // Create start and end points\n const startPoint: Point3 = [-5, 0, 0];\n const vecEndPt: Point3 = [-2, 3, 0];\n const endPoint: Point3 = [5, 0, 0];\n\n // Create tangent vector\n const vecOpt = new TwoVectorsDto();\n vecOpt.first = startPoint;\n vecOpt.second = vecEndPt;\n const vector = bitbybit.vector.sub(vecOpt) as Vector3;\n\n // Create an arc\n const arcOptions = new ArcEdgeTwoPointsTangentDto();\n arcOptions.start = startPoint;\n arcOptions.tangentVec = vector;\n arcOptions.end = endPoint;\n\n const arc = await bitbybit.occt.shapes.edge.arcThroughTwoPointsAndTangent(arcOptions);\n\n // Draw the arc, points and tangent\n bitbybit.draw.drawAnyAsync({ entity: arc });\n bitbybit.draw.drawAnyAsync({ entity: [startPoint, vecEndPt, endPoint] });\n\n // When two points are provided Bitbybit draws them as a line segment\n bitbybit.draw.drawAnyAsync({ entity: [startPoint, vecEndPt] });\n}\n\n// Execute the function\nstart();","version":"0.21.1","type":"typescript"}} title="Arc edge from two points and tangent" /> @@ -169,21 +169,21 @@ This example demonstrates creating an arc using two endpoints and a tangent vect circlestartPointendPointcenterPointarccircle5000010startPoint800endPoint808centerPoint000arccirclestartPointendPointTRUEarccenterPointstartPointcenterPointendPointstartPointcenterPointendPoint","version":"0.21.0","type":"blockly"}} + script={{"script":"circlestartPointendPointcenterPointarccircle5000010startPoint800endPoint808centerPoint000arccirclestartPointendPointTRUEarccenterPointstartPointcenterPointendPointstartPointcenterPointendPoint","version":"0.21.1","type":"blockly"}} title="Arc edge from circle and two points" /> {\n // Create a circle edge\n const circleOptions = new CircleDto();\n circleOptions.radius = 5;\n circleOptions.center = [0, 0, 0] as Point3;\n circleOptions.direction = [0, 1, 0] as Vector3;\n\n const circle = await bitbybit.occt.shapes.edge.createCircleEdge(circleOptions);\n\n // Create start and end points for the arc\n const startPoint: Point3 = [8, 0, 0];\n const endPoint: Point3 = [8, 0, 8];\n const centerPoint: Point3 = [0, 0, 0];\n\n // Create arc from circle and two points\n const arcOptions = new ArcEdgeCircleTwoPointsDto();\n arcOptions.circle = circle;\n arcOptions.start = startPoint;\n arcOptions.end = endPoint;\n arcOptions.sense = true;\n\n const arc = await bitbybit.occt.shapes.edge.arcFromCircleAndTwoPoints(arcOptions);\n // Draw the arc and helper points\n bitbybit.draw.drawAnyAsync({ entity: arc });\n bitbybit.draw.drawAnyAsync({ entity: [endPoint, centerPoint, startPoint] });\n bitbybit.draw.drawAnyAsync({ entity: [centerPoint, endPoint] });\n bitbybit.draw.drawAnyAsync({ entity: [centerPoint, startPoint] });\n}\n\n// Execute the function\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"const { CircleDto, ArcEdgeCircleTwoPointsDto } = Bit.Inputs.OCCT;\n// Import required types\ntype TopoDSEdgePointer = Bit.Inputs.OCCT.TopoDSEdgePointer;\ntype Point3 = Bit.Inputs.Base.Point3;\ntype Vector3 = Bit.Inputs.Base.Vector3;\n\n// Define the main function\nconst start = async () => {\n // Create a circle edge\n const circleOptions = new CircleDto();\n circleOptions.radius = 5;\n circleOptions.center = [0, 0, 0] as Point3;\n circleOptions.direction = [0, 1, 0] as Vector3;\n\n const circle = await bitbybit.occt.shapes.edge.createCircleEdge(circleOptions);\n\n // Create start and end points for the arc\n const startPoint: Point3 = [8, 0, 0];\n const endPoint: Point3 = [8, 0, 8];\n const centerPoint: Point3 = [0, 0, 0];\n\n // Create arc from circle and two points\n const arcOptions = new ArcEdgeCircleTwoPointsDto();\n arcOptions.circle = circle;\n arcOptions.start = startPoint;\n arcOptions.end = endPoint;\n arcOptions.sense = true;\n\n const arc = await bitbybit.occt.shapes.edge.arcFromCircleAndTwoPoints(arcOptions);\n // Draw the arc and helper points\n bitbybit.draw.drawAnyAsync({ entity: arc });\n bitbybit.draw.drawAnyAsync({ entity: [endPoint, centerPoint, startPoint] });\n bitbybit.draw.drawAnyAsync({ entity: [centerPoint, endPoint] });\n bitbybit.draw.drawAnyAsync({ entity: [centerPoint, startPoint] });\n}\n\n// Execute the function\nstart();","version":"0.21.1","type":"typescript"}} title="Arc edge from circle and two points" /> @@ -211,21 +211,21 @@ This example shows how to create an arc by extracting a portion of an existing c 500001045270TRUE","version":"0.21.0","type":"blockly"}} + script={{"script":"500001045270TRUE","version":"0.21.1","type":"blockly"}} title="Arc edge from circle and two points" /> {\n // Create a circle edge\n const circleOptions = new CircleDto();\n circleOptions.radius = 5;\n circleOptions.center = [0, 0, 0] as Point3;\n circleOptions.direction = [0, 1, 0] as Vector3;\n\n const circle = await bitbybit.occt.shapes.edge.createCircleEdge(circleOptions);\n\n // Create arc from circle and two angles\n const arcOptions = new ArcEdgeCircleTwoAnglesDto();\n arcOptions.circle = circle;\n arcOptions.alphaAngle1 = 45;\n arcOptions.alphaAngle2 = 270;\n arcOptions.sense = true;\n\n const arc = await bitbybit.occt.shapes.edge.arcFromCircleAndTwoAngles(arcOptions);\n\n // Draw the arc\n bitbybit.draw.drawAnyAsync({ entity: arc });\n}\n\n// Execute the function\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"const { CircleDto, ArcEdgeCircleTwoAnglesDto } = Bit.Inputs.OCCT;\n// Import required types\ntype Point3 = Bit.Inputs.Base.Point3;\ntype Vector3 = Bit.Inputs.Base.Vector3;\ntype TopoDSEdgePointer = Bit.Inputs.OCCT.TopoDSEdgePointer;\n\n\n// Define the main function\nconst start = async () => {\n // Create a circle edge\n const circleOptions = new CircleDto();\n circleOptions.radius = 5;\n circleOptions.center = [0, 0, 0] as Point3;\n circleOptions.direction = [0, 1, 0] as Vector3;\n\n const circle = await bitbybit.occt.shapes.edge.createCircleEdge(circleOptions);\n\n // Create arc from circle and two angles\n const arcOptions = new ArcEdgeCircleTwoAnglesDto();\n arcOptions.circle = circle;\n arcOptions.alphaAngle1 = 45;\n arcOptions.alphaAngle2 = 270;\n arcOptions.sense = true;\n\n const arc = await bitbybit.occt.shapes.edge.arcFromCircleAndTwoAngles(arcOptions);\n\n // Draw the arc\n bitbybit.draw.drawAnyAsync({ entity: arc });\n}\n\n// Execute the function\nstart();","version":"0.21.1","type":"typescript"}} title="Arc edge from circle and two angles" /> @@ -252,21 +252,21 @@ This example demonstrates creating an arc by specifying a base circle and two an circlepointcenterPointarccircle5000010point808centerPoint000arccirclepoint360TRUEarccenterPointpointcenterPointpoint","version":"0.21.0","type":"blockly"}} + script={{"script":"circlepointcenterPointarccircle5000010point808centerPoint000arccirclepoint360TRUEarccenterPointpointcenterPointpoint","version":"0.21.1","type":"blockly"}} title="Arc edge from circle point and an angle" /> {\n // Create a circle edge\n const circleOptions = new CircleDto();\n circleOptions.radius = 5;\n circleOptions.center = [0, 0, 0] as Point3;\n circleOptions.direction = [0, 1, 0] as Vector3;\n\n const circle = await bitbybit.occt.shapes.edge.createCircleEdge(circleOptions);\n\n // Create a point on the circle\n const point: Point3 = [8, 0, 8];\n const centerPoint: Point3 = [0, 0, 0];\n\n // Create arc from circle, point and angle\n const arcOptions = new ArcEdgeCirclePointAngleDto();\n arcOptions.circle = circle;\n arcOptions.point = point;\n arcOptions.alphaAngle = 360;\n arcOptions.sense = true;\n\n const arc = await bitbybit.occt.shapes.edge.arcFromCirclePointAndAngle(arcOptions);\n\n // Draw the arc and helper elements\n bitbybit.draw.drawAnyAsync({ entity: arc });\n bitbybit.draw.drawAnyAsync({ entity: [centerPoint, point] });\n bitbybit.draw.drawAnyAsync({ entity: [centerPoint] });\n bitbybit.draw.drawAnyAsync({ entity: [point] });\n\n}\n\n// Execute the function\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"const { CircleDto, ArcEdgeCirclePointAngleDto } = Bit.Inputs.OCCT;\n// Import required types\ntype Point3 = Bit.Inputs.Base.Point3;\ntype Vector3 = Bit.Inputs.Base.Vector3;\ntype TopoDSEdgePointer = Bit.Inputs.OCCT.TopoDSEdgePointer;\n\n// Define the main function\nconst start = async () => {\n // Create a circle edge\n const circleOptions = new CircleDto();\n circleOptions.radius = 5;\n circleOptions.center = [0, 0, 0] as Point3;\n circleOptions.direction = [0, 1, 0] as Vector3;\n\n const circle = await bitbybit.occt.shapes.edge.createCircleEdge(circleOptions);\n\n // Create a point on the circle\n const point: Point3 = [8, 0, 8];\n const centerPoint: Point3 = [0, 0, 0];\n\n // Create arc from circle, point and angle\n const arcOptions = new ArcEdgeCirclePointAngleDto();\n arcOptions.circle = circle;\n arcOptions.point = point;\n arcOptions.alphaAngle = 360;\n arcOptions.sense = true;\n\n const arc = await bitbybit.occt.shapes.edge.arcFromCirclePointAndAngle(arcOptions);\n\n // Draw the arc and helper elements\n bitbybit.draw.drawAnyAsync({ entity: arc });\n bitbybit.draw.drawAnyAsync({ entity: [centerPoint, point] });\n bitbybit.draw.drawAnyAsync({ entity: [centerPoint] });\n bitbybit.draw.drawAnyAsync({ entity: [point] });\n\n}\n\n// Execute the function\nstart();","version":"0.21.1","type":"typescript"}} title="Arc edge from circle point and an angle" /> @@ -294,21 +294,21 @@ This example shows how to create an arc starting from a specific point on a circ 5000010","version":"0.21.0","type":"blockly"}} + script={{"script":"5000010","version":"0.21.1","type":"blockly"}} title="Circle edge" /> {\n // Create a circle edge\n const circleOptions = new CircleDto();\n circleOptions.radius = 5;\n circleOptions.center = [0, 0, 0] as Point3;\n circleOptions.direction = [0, 1, 0] as Vector3;\n\n const circle = await bitbybit.occt.shapes.edge.createCircleEdge(circleOptions);\n\n // Draw the circle\n bitbybit.draw.drawAnyAsync({ entity: circle });\n}\n\n// Execute the function\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"const { CircleDto } = Bit.Inputs.OCCT;\n// Import required types\ntype Point3 = Bit.Inputs.Base.Point3;\ntype Vector3 = Bit.Inputs.Base.Vector3;\n\n// Define the main function\nconst start = async () => {\n // Create a circle edge\n const circleOptions = new CircleDto();\n circleOptions.radius = 5;\n circleOptions.center = [0, 0, 0] as Point3;\n circleOptions.direction = [0, 1, 0] as Vector3;\n\n const circle = await bitbybit.occt.shapes.edge.createCircleEdge(circleOptions);\n\n // Draw the circle\n bitbybit.draw.drawAnyAsync({ entity: circle });\n}\n\n// Execute the function\nstart();","version":"0.21.1","type":"typescript"}} title="Circle edge" /> @@ -335,21 +335,21 @@ This example demonstrates creating a complete circular edge, which is one of the 000010310","version":"0.21.0","type":"blockly"}} + script={{"script":"000010310","version":"0.21.1","type":"blockly"}} title="Ellipse edge" /> {\n // Create an ellipse edge\n const ellipseOptions = new EllipseDto();\n ellipseOptions.center = [0, 0, 0] as Point3;\n ellipseOptions.direction = [0, 1, 0] as Vector3;\n ellipseOptions.radiusMinor = 3;\n ellipseOptions.radiusMajor = 10;\n\n const ellipse = await bitbybit.occt.shapes.edge.createEllipseEdge(ellipseOptions);\n\n // Draw the ellipse\n bitbybit.draw.drawAnyAsync({ entity: ellipse });\n}\n\n// Execute the function\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"const { EllipseDto } = Bit.Inputs.OCCT;\n// Import required types\ntype Point3 = Bit.Inputs.Base.Point3;\ntype Vector3 = Bit.Inputs.Base.Vector3;\n\n// Define the main function\nconst start = async () => {\n // Create an ellipse edge\n const ellipseOptions = new EllipseDto();\n ellipseOptions.center = [0, 0, 0] as Point3;\n ellipseOptions.direction = [0, 1, 0] as Vector3;\n ellipseOptions.radiusMinor = 3;\n ellipseOptions.radiusMajor = 10;\n\n const ellipse = await bitbybit.occt.shapes.edge.createEllipseEdge(ellipseOptions);\n\n // Draw the ellipse\n bitbybit.draw.drawAnyAsync({ entity: ellipse });\n}\n\n// Execute the function\nstart();","version":"0.21.1","type":"typescript"}} title="Ellipse edge" /> diff --git a/docs/learn/code/common/occt/shapes/face/face-basic-primitives.md b/docs/learn/code/common/occt/shapes/face/face-basic-primitives.md index e349889d..a473a026 100644 --- a/docs/learn/code/common/occt/shapes/face/face-basic-primitives.md +++ b/docs/learn/code/common/occt/shapes/face/face-basic-primitives.md @@ -26,21 +26,21 @@ Think of wires as the frame of a window, and faces as the glass that fills the f circleFacesquareFacerectangleFaceellipseFacecircleFace4000010squareFace3700010rectangleFace37-700010ellipseFace00-901013circleFacesquareFacerectangleFaceellipseFace","version":"0.21.0","type":"blockly"}} + script={{"script":"circleFacesquareFacerectangleFaceellipseFacecircleFace4000010squareFace3700010rectangleFace37-700010ellipseFace00-901013circleFacesquareFacerectangleFaceellipseFace","version":"0.21.1","type":"blockly"}} title="Creating basic face primitives" /> {\n // Create a circle face\n const circleOptions = new CircleDto();\n circleOptions.radius = 4;\n circleOptions.center = [0, 0, 0] as Point3;\n circleOptions.direction = [0, 1, 0] as Vector3;\n\n const circleFace = await face.createCircleFace(circleOptions);\n\n // Create a square face at a different position\n const squareOptions = new SquareDto();\n squareOptions.size = 3;\n squareOptions.center = [7, 0, 0] as Point3;\n squareOptions.direction = [0, 1, 0] as Vector3;\n\n const squareFace = await face.createSquareFace(squareOptions);\n\n // Create a rectangle face\n const rectangleOptions = new RectangleDto();\n rectangleOptions.width = 3;\n rectangleOptions.length = 7;\n rectangleOptions.center = [-7, 0, 0] as Point3;\n rectangleOptions.direction = [0, 1, 0] as Vector3;\n\n const rectangleFace = await face.createRectangleFace(rectangleOptions);\n\n // Create an ellipse face\n const ellipseOptions = new EllipseDto();\n ellipseOptions.center = [0, 0, -9] as Point3;\n ellipseOptions.direction = [0, 1, 0] as Vector3;\n ellipseOptions.radiusMinor = 1;\n ellipseOptions.radiusMajor = 3;\n\n const ellipseFace = await face.createEllipseFace(ellipseOptions);\n\n // Draw all the created faces\n bitbybit.draw.drawAnyAsync({ entity: circleFace });\n bitbybit.draw.drawAnyAsync({ entity: squareFace });\n bitbybit.draw.drawAnyAsync({ entity: rectangleFace });\n bitbybit.draw.drawAnyAsync({ entity: ellipseFace });\n}\n\n// Execute the function\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"// Import required DTOs and types for face creation\nconst { CircleDto, SquareDto, RectangleDto, EllipseDto } = Bit.Inputs.OCCT;\ntype Point3 = Bit.Inputs.Base.Point3;\ntype Vector3 = Bit.Inputs.Base.Vector3;\n\n// Get access to OCCT face creation functions\nconst { face } = bitbybit.occt.shapes;\n\n// Define the main function to create various primitive faces\nconst start = async () => {\n // Create a circle face\n const circleOptions = new CircleDto();\n circleOptions.radius = 4;\n circleOptions.center = [0, 0, 0] as Point3;\n circleOptions.direction = [0, 1, 0] as Vector3;\n\n const circleFace = await face.createCircleFace(circleOptions);\n\n // Create a square face at a different position\n const squareOptions = new SquareDto();\n squareOptions.size = 3;\n squareOptions.center = [7, 0, 0] as Point3;\n squareOptions.direction = [0, 1, 0] as Vector3;\n\n const squareFace = await face.createSquareFace(squareOptions);\n\n // Create a rectangle face\n const rectangleOptions = new RectangleDto();\n rectangleOptions.width = 3;\n rectangleOptions.length = 7;\n rectangleOptions.center = [-7, 0, 0] as Point3;\n rectangleOptions.direction = [0, 1, 0] as Vector3;\n\n const rectangleFace = await face.createRectangleFace(rectangleOptions);\n\n // Create an ellipse face\n const ellipseOptions = new EllipseDto();\n ellipseOptions.center = [0, 0, -9] as Point3;\n ellipseOptions.direction = [0, 1, 0] as Vector3;\n ellipseOptions.radiusMinor = 1;\n ellipseOptions.radiusMajor = 3;\n\n const ellipseFace = await face.createEllipseFace(ellipseOptions);\n\n // Draw all the created faces\n bitbybit.draw.drawAnyAsync({ entity: circleFace });\n bitbybit.draw.drawAnyAsync({ entity: squareFace });\n bitbybit.draw.drawAnyAsync({ entity: rectangleFace });\n bitbybit.draw.drawAnyAsync({ entity: ellipseFace });\n}\n\n// Execute the function\nstart();","version":"0.21.1","type":"typescript"}} title="Creating basic face primitives" /> diff --git a/docs/learn/code/common/occt/shapes/face/face-from-points.md b/docs/learn/code/common/occt/shapes/face/face-from-points.md index d769cf04..3740ee38 100644 --- a/docs/learn/code/common/occt/shapes/face/face-from-points.md +++ b/docs/learn/code/common/occt/shapes/face/face-from-points.md @@ -28,21 +28,21 @@ This example demonstrates creating a quadrilateral face from four strategically point1point2point3point4pointsListpolygonFacepoint1-30-8point2-303point3303point4500pointsListpoint1point2point3point4polygonFacepointsListpolygonFacepointsList","version":"0.21.0","type":"blockly"}} + script={{"script":"point1point2point3point4pointsListpolygonFacepoint1-30-8point2-303point3303point4500pointsListpoint1point2point3point4polygonFacepointsListpolygonFacepointsList","version":"0.21.1","type":"blockly"}} title="Creating face from points" /> {\n // Define the four points that will form the polygon face\n const point1: Point3 = [-3, 0, -8];\n const point2: Point3 = [-3, 0, 3];\n const point3: Point3 = [3, 0, 3];\n const point4: Point3 = [5, 0, 0];\n\n // Create a list of points in the correct order\n const points: Point3[] = [point1, point2, point3, point4];\n\n // Create the polygon face options\n const polygonOptions = new PolygonDto();\n polygonOptions.points = points;\n\n // Create the polygon face from the points\n const polygonFace = await face.createPolygonFace(polygonOptions);\n\n // Draw the polygon face\n bitbybit.draw.drawAnyAsync({ entity: polygonFace });\n\n // Optionally, draw the points to visualize the vertices\n bitbybit.draw.drawAnyAsync({ entity: points });\n}\n\n// Execute the function\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"// Import required DTOs and types for polygon face creation\nconst { PolygonDto } = Bit.Inputs.OCCT;\ntype Point3 = Bit.Inputs.Base.Point3;\n\n// Get access to OCCT face creation functions\nconst { face } = bitbybit.occt.shapes;\n\n// Define the main function to create a polygon face from points\nconst start = async () => {\n // Define the four points that will form the polygon face\n const point1: Point3 = [-3, 0, -8];\n const point2: Point3 = [-3, 0, 3];\n const point3: Point3 = [3, 0, 3];\n const point4: Point3 = [5, 0, 0];\n\n // Create a list of points in the correct order\n const points: Point3[] = [point1, point2, point3, point4];\n\n // Create the polygon face options\n const polygonOptions = new PolygonDto();\n polygonOptions.points = points;\n\n // Create the polygon face from the points\n const polygonFace = await face.createPolygonFace(polygonOptions);\n\n // Draw the polygon face\n bitbybit.draw.drawAnyAsync({ entity: polygonFace });\n\n // Optionally, draw the points to visualize the vertices\n bitbybit.draw.drawAnyAsync({ entity: points });\n}\n\n// Execute the function\nstart();","version":"0.21.1","type":"typescript"}} title="Creating face from points" /> diff --git a/docs/learn/code/common/occt/shapes/face/face-from-wire.md b/docs/learn/code/common/occt/shapes/face/face-from-wire.md index eca1050f..73830cfc 100644 --- a/docs/learn/code/common/occt/shapes/face/face-from-wire.md +++ b/docs/learn/code/common/occt/shapes/face/face-from-wire.md @@ -36,21 +36,21 @@ This example demonstrates creating a star-shaped face from a reversed wire to co starWirereversedWirefaceFromWirestarWire0000107730FALSEreversedWirestarWirefaceFromWirereversedWireTRUEfaceFromWire","version":"0.21.0","type":"blockly"}} + script={{"script":"starWirereversedWirefaceFromWirestarWire0000107730FALSEreversedWirestarWirefaceFromWirereversedWireTRUEfaceFromWire","version":"0.21.1","type":"blockly"}} title="Creating face from wire" /> {\n // Create a star wire\n const starOptions = new StarDto();\n starOptions.center = [0, 0, 0] as Point3;\n starOptions.direction = [0, 1, 0] as Vector3;\n starOptions.numRays = 7;\n starOptions.outerRadius = 7;\n starOptions.innerRadius = 3;\n starOptions.offsetOuterEdges = 0;\n starOptions.half = false;\n\n const starWire = await wire.createStarWire(starOptions);\n\n // Reverse the wire orientation\n const reversedWire = await wire.reversedWire({ shape: starWire });\n\n // Create a face from the reversed wire\n const faceOptions = new FaceFromWireDto();\n faceOptions.shape = reversedWire;\n faceOptions.planar = true;\n\n const faceFromWire = await face.createFaceFromWire(faceOptions);\n\n // Draw the created face\n bitbybit.draw.drawAnyAsync({ entity: faceFromWire });\n}\n\n// Execute the function\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"// Import required DTOs and types for wire and face creation\nconst { StarDto, FaceFromWireDto } = Bit.Inputs.OCCT;\ntype Point3 = Bit.Inputs.Base.Point3;\ntype Vector3 = Bit.Inputs.Base.Vector3;\ntype TopoDSWirePointer = Bit.Inputs.OCCT.TopoDSWirePointer;\n\n// Get access to OCCT wire and face creation functions\nconst { wire, face } = bitbybit.occt.shapes;\n\n// Define the main function to create a face from a wire\nconst start = async () => {\n // Create a star wire\n const starOptions = new StarDto();\n starOptions.center = [0, 0, 0] as Point3;\n starOptions.direction = [0, 1, 0] as Vector3;\n starOptions.numRays = 7;\n starOptions.outerRadius = 7;\n starOptions.innerRadius = 3;\n starOptions.offsetOuterEdges = 0;\n starOptions.half = false;\n\n const starWire = await wire.createStarWire(starOptions);\n\n // Reverse the wire orientation\n const reversedWire = await wire.reversedWire({ shape: starWire });\n\n // Create a face from the reversed wire\n const faceOptions = new FaceFromWireDto();\n faceOptions.shape = reversedWire;\n faceOptions.planar = true;\n\n const faceFromWire = await face.createFaceFromWire(faceOptions);\n\n // Draw the created face\n bitbybit.draw.drawAnyAsync({ entity: faceFromWire });\n}\n\n// Execute the function\nstart();","version":"0.21.1","type":"typescript"}} title="Creating face from wire" /> diff --git a/docs/learn/code/common/occt/shapes/face/face-hex-grid-pattern.md b/docs/learn/code/common/occt/shapes/face/face-hex-grid-pattern.md index 5a3f2f86..ef7a0d80 100644 --- a/docs/learn/code/common/occt/shapes/face/face-hex-grid-pattern.md +++ b/docs/learn/code/common/occt/shapes/face/face-hex-grid-pattern.md @@ -23,21 +23,21 @@ Learn how to create hexagonal face patterns that respond to a control point. Hex gridWidthgridHeighthexagonsInWidthhexagonsInHeightcontrolPointUcontrolPointVrectangleFacecontrolPointhexGridhexCentersdistancesminDistancemaxDistancescalePatterndistancescaledValueinclusionPatternhexagonFacesaffectorPointpingridWidth16.5gridHeight9hexagonsInWidth29hexagonsInHeight29controlPointU0controlPointV0.49rectangleFacegridWidthgridHeight000010controlPointrectangleFacecontrolPointUcontrolPointVhexGridgridWidthgridHeighthexagonsInWidthhexagonsInHeightTRUEFALSEFALSEFALSEFALSETRUETRUEhexCentershexGridcentersdistancescontrolPointhexCentersminDistancedistancesmaxDistancedistancesscalePatterndistancedistancesscaledValuedistanceminDistancemaxDistance0.2110.9INSERTLASTscalePatternscaledValueinclusionPattern[true, true, true, true, false]hexagonFacesgridWidthgridHeighthexagonsInWidthhexagonsInHeightTRUEFALSEFALSEFALSEFALSEscalePatternscalePatterninclusionPatternaffectorPointcontrolPoint030pincontrolPointaffectorPoint0010.1Affector0.30.1hexagonFacespincontrolPoint","version":"0.21.0","type":"blockly"}} + script={{"script":"gridWidthgridHeighthexagonsInWidthhexagonsInHeightcontrolPointUcontrolPointVrectangleFacecontrolPointhexGridhexCentersdistancesminDistancemaxDistancescalePatterndistancescaledValueinclusionPatternhexagonFacesaffectorPointpingridWidth16.5gridHeight9hexagonsInWidth29hexagonsInHeight29controlPointU0controlPointV0.49rectangleFacegridWidthgridHeight000010controlPointrectangleFacecontrolPointUcontrolPointVhexGridgridWidthgridHeighthexagonsInWidthhexagonsInHeightTRUEFALSEFALSEFALSEFALSETRUETRUEhexCentershexGridcentersdistancescontrolPointhexCentersminDistancedistancesmaxDistancedistancesscalePatterndistancedistancesscaledValuedistanceminDistancemaxDistance0.2110.9INSERTLASTscalePatternscaledValueinclusionPattern[true, true, true, true, false]hexagonFacesgridWidthgridHeighthexagonsInWidthhexagonsInHeightTRUEFALSEFALSEFALSEFALSEscalePatternscalePatterninclusionPatternaffectorPointcontrolPoint030pincontrolPointaffectorPoint0010.1Affector0.30.1hexagonFacespincontrolPoint","version":"0.21.1","type":"blockly"}} title="Creating face from wire" /> {\n // Define grid parameters\n const gridWidth = 16.5;\n const gridHeight = 9;\n const hexagonsInWidth = 29;\n const hexagonsInHeight = 29;\n const controlPointU = 0; // UV parameter for control point position\n const controlPointV = 0.49; // UV parameter for control point position\n\n // Create a reference rectangle face to define the control point\n const rectangleOptions = new RectangleDto();\n rectangleOptions.width = gridWidth;\n rectangleOptions.length = gridHeight;\n rectangleOptions.center = [0, 0, 0] as Point3;\n rectangleOptions.direction = [0, 1, 0] as Vector3;\n\n const rectangleFace = await face.createRectangleFace(rectangleOptions);\n\n // Create control point on the rectangle face using UV parameters\n const pointOnUVOptions = new DataOnUVDto();\n pointOnUVOptions.shape = rectangleFace;\n pointOnUVOptions.paramU = controlPointU;\n pointOnUVOptions.paramV = controlPointV;\n\n const controlPoint = await face.pointOnUV(pointOnUVOptions);\n\n // Generate hexagon grid centers for distance calculation\n const hexGridOptions = new HexGridScaledToFitDto();\n hexGridOptions.width = gridWidth;\n hexGridOptions.height = gridHeight;\n hexGridOptions.nrHexagonsInWidth = hexagonsInWidth;\n hexGridOptions.nrHexagonsInHeight = hexagonsInHeight;\n hexGridOptions.flatTop = true;\n hexGridOptions.extendTop = false;\n hexGridOptions.extendBottom = false;\n hexGridOptions.extendLeft = false;\n hexGridOptions.extendRight = false;\n hexGridOptions.centerGrid = true;\n hexGridOptions.pointsOnGround = true;\n\n const hexGrid = point.hexGridScaledToFit(hexGridOptions);\n const hexCenters = hexGrid.centers;\n\n // Calculate distances from control point to all hexagon centers\n const distances = point.distancesToPoints({\n startPoint: controlPoint,\n endPoints: hexCenters\n });\n\n // Flatten the distance array and find min/max values\n const minDistance = vector.min({ vector: distances });\n const maxDistance = vector.max({ vector: distances });\n\n // Remap distances to scale factors (0.211 to 0.9)\n const remapOptions = new RemapNumberDto();\n remapOptions.fromLow = minDistance;\n remapOptions.fromHigh = maxDistance;\n remapOptions.toLow = 0.211;\n remapOptions.toHigh = 0.9;\n\n const scalePattern = distances.map(x => {\n remapOptions.number = x;\n return math.remap(remapOptions);\n })\n\n // Create inclusion pattern for selective hexagon removal\n const inclusionPattern = json.parse({ text: \"[true, true, true, true, false]\" });\n\n // Create the hexagon faces with advanced patterns\n const hexFaceOptions = new HexagonsInGridDto();\n hexFaceOptions.width = gridWidth;\n hexFaceOptions.height = gridHeight;\n hexFaceOptions.nrHexagonsInWidth = hexagonsInWidth;\n hexFaceOptions.nrHexagonsInHeight = hexagonsInHeight;\n hexFaceOptions.flatTop = true;\n hexFaceOptions.extendTop = false;\n hexFaceOptions.extendBottom = false;\n hexFaceOptions.extendLeft = false;\n hexFaceOptions.extendRight = false;\n hexFaceOptions.scalePatternWidth = scalePattern;\n hexFaceOptions.scalePatternHeight = scalePattern;\n hexFaceOptions.inclusionPattern = inclusionPattern;\n\n const hexagonFaces = await face.hexagonsInGrid(hexFaceOptions);\n\n // Create affector point visualization (control point elevated)\n const affectorPoint = vector.add({\n first: controlPoint,\n second: [0, 3, 0] as Vector3\n }) as Point3;\n\n // Create pin with label to show the affector point\n const pinOptions = new PinWithLabelDto();\n pinOptions.startPoint = controlPoint;\n pinOptions.endPoint = affectorPoint;\n pinOptions.direction = [0, 0, 1] as Vector3;\n pinOptions.offsetFromStart = 0.1;\n pinOptions.label = \"Affector\";\n pinOptions.labelOffset = 0.3;\n pinOptions.labelSize = 0.1;\n\n const pin = await dimensions.pinWithLabel(pinOptions);\n\n // Draw the hexagon faces and affector pin\n bitbybit.draw.drawAnyAsync({ entity: hexagonFaces });\n bitbybit.draw.drawAnyAsync({ entity: pin });\n\n // Optional: Draw the control point for reference\n bitbybit.draw.drawAnyAsync({\n entity: controlPoint,\n });\n}\n\n// Execute the function\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"// Import required DTOs and types for face hexagon grid creation\nconst { HexagonsInGridDto, RectangleDto, DataOnUVDto, PinWithLabelDto } = Bit.Inputs.OCCT;\nconst { HexGridScaledToFitDto } = Bit.Inputs.Point;\nconst { RemapNumberDto } = Bit.Inputs.Math;\nconst { HexGridData } = Bit.Models.Point;\n\ntype Point3 = Bit.Inputs.Base.Point3;\ntype Vector3 = Bit.Inputs.Base.Vector3;\ntype TopoDSFacePointer = Bit.Inputs.OCCT.TopoDSFacePointer;\n\n// Get access to OCCT face, point, and utility functions\nconst { face } = bitbybit.occt.shapes;\nconst { point } = bitbybit;\nconst { math, vector, json, lists } = bitbybit;\nconst { dimensions } = bitbybit.occt;\n\n// Define the main function to create advanced hexagon face pattern\nconst start = async () => {\n // Define grid parameters\n const gridWidth = 16.5;\n const gridHeight = 9;\n const hexagonsInWidth = 29;\n const hexagonsInHeight = 29;\n const controlPointU = 0; // UV parameter for control point position\n const controlPointV = 0.49; // UV parameter for control point position\n\n // Create a reference rectangle face to define the control point\n const rectangleOptions = new RectangleDto();\n rectangleOptions.width = gridWidth;\n rectangleOptions.length = gridHeight;\n rectangleOptions.center = [0, 0, 0] as Point3;\n rectangleOptions.direction = [0, 1, 0] as Vector3;\n\n const rectangleFace = await face.createRectangleFace(rectangleOptions);\n\n // Create control point on the rectangle face using UV parameters\n const pointOnUVOptions = new DataOnUVDto();\n pointOnUVOptions.shape = rectangleFace;\n pointOnUVOptions.paramU = controlPointU;\n pointOnUVOptions.paramV = controlPointV;\n\n const controlPoint = await face.pointOnUV(pointOnUVOptions);\n\n // Generate hexagon grid centers for distance calculation\n const hexGridOptions = new HexGridScaledToFitDto();\n hexGridOptions.width = gridWidth;\n hexGridOptions.height = gridHeight;\n hexGridOptions.nrHexagonsInWidth = hexagonsInWidth;\n hexGridOptions.nrHexagonsInHeight = hexagonsInHeight;\n hexGridOptions.flatTop = true;\n hexGridOptions.extendTop = false;\n hexGridOptions.extendBottom = false;\n hexGridOptions.extendLeft = false;\n hexGridOptions.extendRight = false;\n hexGridOptions.centerGrid = true;\n hexGridOptions.pointsOnGround = true;\n\n const hexGrid = point.hexGridScaledToFit(hexGridOptions);\n const hexCenters = hexGrid.centers;\n\n // Calculate distances from control point to all hexagon centers\n const distances = point.distancesToPoints({\n startPoint: controlPoint,\n endPoints: hexCenters\n });\n\n // Flatten the distance array and find min/max values\n const minDistance = vector.min({ vector: distances });\n const maxDistance = vector.max({ vector: distances });\n\n // Remap distances to scale factors (0.211 to 0.9)\n const remapOptions = new RemapNumberDto();\n remapOptions.fromLow = minDistance;\n remapOptions.fromHigh = maxDistance;\n remapOptions.toLow = 0.211;\n remapOptions.toHigh = 0.9;\n\n const scalePattern = distances.map(x => {\n remapOptions.number = x;\n return math.remap(remapOptions);\n })\n\n // Create inclusion pattern for selective hexagon removal\n const inclusionPattern = json.parse({ text: \"[true, true, true, true, false]\" });\n\n // Create the hexagon faces with advanced patterns\n const hexFaceOptions = new HexagonsInGridDto();\n hexFaceOptions.width = gridWidth;\n hexFaceOptions.height = gridHeight;\n hexFaceOptions.nrHexagonsInWidth = hexagonsInWidth;\n hexFaceOptions.nrHexagonsInHeight = hexagonsInHeight;\n hexFaceOptions.flatTop = true;\n hexFaceOptions.extendTop = false;\n hexFaceOptions.extendBottom = false;\n hexFaceOptions.extendLeft = false;\n hexFaceOptions.extendRight = false;\n hexFaceOptions.scalePatternWidth = scalePattern;\n hexFaceOptions.scalePatternHeight = scalePattern;\n hexFaceOptions.inclusionPattern = inclusionPattern;\n\n const hexagonFaces = await face.hexagonsInGrid(hexFaceOptions);\n\n // Create affector point visualization (control point elevated)\n const affectorPoint = vector.add({\n first: controlPoint,\n second: [0, 3, 0] as Vector3\n }) as Point3;\n\n // Create pin with label to show the affector point\n const pinOptions = new PinWithLabelDto();\n pinOptions.startPoint = controlPoint;\n pinOptions.endPoint = affectorPoint;\n pinOptions.direction = [0, 0, 1] as Vector3;\n pinOptions.offsetFromStart = 0.1;\n pinOptions.label = \"Affector\";\n pinOptions.labelOffset = 0.3;\n pinOptions.labelSize = 0.1;\n\n const pin = await dimensions.pinWithLabel(pinOptions);\n\n // Draw the hexagon faces and affector pin\n bitbybit.draw.drawAnyAsync({ entity: hexagonFaces });\n bitbybit.draw.drawAnyAsync({ entity: pin });\n\n // Optional: Draw the control point for reference\n bitbybit.draw.drawAnyAsync({\n entity: controlPoint,\n });\n}\n\n// Execute the function\nstart();","version":"0.21.1","type":"typescript"}} title="Creating face from wire" /> diff --git a/docs/learn/code/common/occt/shapes/shells/intro-shells.md b/docs/learn/code/common/occt/shapes/shells/intro-shells.md index 4946f8d5..3d82e613 100644 --- a/docs/learn/code/common/occt/shapes/shells/intro-shells.md +++ b/docs/learn/code/common/occt/shapes/shells/intro-shells.md @@ -40,21 +40,21 @@ This first example demonstrates the fundamental concept of shell creation by sew sizeface1face2rotatedFace2translatedFace2facesshellsize5face1size000010face2size000010rotatedFace2face200190translatedFace2rotatedFace2DIVIDEsize2DIVIDEsize20facesface1translatedFace2shellfaces0.0000001shell","version":"0.21.0","type":"blockly"}} + script={{"script":"sizeface1face2rotatedFace2translatedFace2facesshellsize5face1size000010face2size000010rotatedFace2face200190translatedFace2rotatedFace2DIVIDEsize2DIVIDEsize20facesface1translatedFace2shellfaces0.0000001shell","version":"0.21.1","type":"blockly"}} title="Creating shells by sewing two square faces" /> {\n // Define the size for both square faces\n const size = 5;\n\n // Create first square face at origin\n const face1Options = new SquareDto();\n face1Options.size = size;\n face1Options.center = [0, 0, 0] as Point3;\n face1Options.direction = [0, 1, 0] as Vector3; // Y-up orientation\n\n const face1 = await face.createSquareFace(face1Options);\n\n // Create second square face (initially identical to first)\n const face2Options = new SquareDto();\n face2Options.size = size;\n face2Options.center = [0, 0, 0] as Point3;\n face2Options.direction = [0, 1, 0] as Vector3;\n\n const face2 = await face.createSquareFace(face2Options);\n\n // Rotate the second face 90 degrees around Z-axis to create perpendicular orientation\n const rotateOptions = new RotateDto();\n rotateOptions.shape = face2;\n rotateOptions.axis = [0, 0, 1] as Vector3; // Z-axis\n rotateOptions.angle = 90; // 90 degrees\n\n const rotatedFace2 = await transforms.rotate(rotateOptions);\n\n // Translate the rotated face to share an edge with the first face\n const translateOptions = new TranslateDto();\n translateOptions.shape = rotatedFace2;\n translateOptions.translation = [size / 2, size / 2, 0] as Vector3;\n\n const translatedFace2 = await transforms.translate(translateOptions);\n\n // Create array of faces to sew together\n const faces = [face1, translatedFace2];\n\n // Sew the faces together to create a shell\n const sewOptions = new SewDto(faces);\n sewOptions.tolerance = 1e-7; // Very tight tolerance for precise sewing\n\n const resultShell = await shell.sewFaces(sewOptions);\n\n // Verify that we created a shell (not just individual faces)\n const shapeType = await shape.getShapeType({ shape: resultShell });\n console.log('Shell shape type:', shapeType); // Should output \"shell\"\n\n // Draw the resulting shell\n bitbybit.draw.drawAnyAsync({\n entity: resultShell\n });\n}\n\n// Execute the function\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"// Import required DTOs for creating faces, shells, and transformations\nconst { SquareDto, SewDto, RotateDto, TranslateDto } = Bit.Inputs.OCCT;\n// Import type definitions for type safety\ntype Point3 = Bit.Inputs.Base.Point3;\ntype Vector3 = Bit.Inputs.Base.Vector3;\ntype TopoDSFacePointer = Bit.Inputs.OCCT.TopoDSFacePointer;\ntype TopoDSShellPointer = Bit.Inputs.OCCT.TopoDSShellPointer;\n\n// Get access to OCCT modules and utility functions\nconst { face, shell, shape } = bitbybit.occt.shapes;\nconst { transforms } = bitbybit.occt;\n\n// Define the main function to create a simple shell from two faces\nconst start = async () => {\n // Define the size for both square faces\n const size = 5;\n\n // Create first square face at origin\n const face1Options = new SquareDto();\n face1Options.size = size;\n face1Options.center = [0, 0, 0] as Point3;\n face1Options.direction = [0, 1, 0] as Vector3; // Y-up orientation\n\n const face1 = await face.createSquareFace(face1Options);\n\n // Create second square face (initially identical to first)\n const face2Options = new SquareDto();\n face2Options.size = size;\n face2Options.center = [0, 0, 0] as Point3;\n face2Options.direction = [0, 1, 0] as Vector3;\n\n const face2 = await face.createSquareFace(face2Options);\n\n // Rotate the second face 90 degrees around Z-axis to create perpendicular orientation\n const rotateOptions = new RotateDto();\n rotateOptions.shape = face2;\n rotateOptions.axis = [0, 0, 1] as Vector3; // Z-axis\n rotateOptions.angle = 90; // 90 degrees\n\n const rotatedFace2 = await transforms.rotate(rotateOptions);\n\n // Translate the rotated face to share an edge with the first face\n const translateOptions = new TranslateDto();\n translateOptions.shape = rotatedFace2;\n translateOptions.translation = [size / 2, size / 2, 0] as Vector3;\n\n const translatedFace2 = await transforms.translate(translateOptions);\n\n // Create array of faces to sew together\n const faces = [face1, translatedFace2];\n\n // Sew the faces together to create a shell\n const sewOptions = new SewDto(faces);\n sewOptions.tolerance = 1e-7; // Very tight tolerance for precise sewing\n\n const resultShell = await shell.sewFaces(sewOptions);\n\n // Verify that we created a shell (not just individual faces)\n const shapeType = await shape.getShapeType({ shape: resultShell });\n console.log('Shell shape type:', shapeType); // Should output \"shell\"\n\n // Draw the resulting shell\n bitbybit.draw.drawAnyAsync({\n entity: resultShell\n });\n}\n\n// Execute the function\nstart();","version":"0.21.1","type":"typescript"}} title="Creating shells by sewing two square faces" /> @@ -81,21 +81,21 @@ While this cylindrical solid **can be constructed in Bitbybit using the simple s radiusheightcircleWireextrusionVectorcylindricalSurfacebottomFacetopFacefacesshellsolidradius5height5circleWireradius000010extrusionVector0height0cylindricalSurfacecircleWireextrusionVectorbottomFacecircleWireTRUEtopFacebottomFaceextrusionVectorfacestopFacecylindricalSurfacebottomFaceshellfaces1e-7solidshellsolid","version":"0.21.0","type":"blockly"}} + script={{"script":"radiusheightcircleWireextrusionVectorcylindricalSurfacebottomFacetopFacefacesshellsolidradius5height5circleWireradius000010extrusionVector0height0cylindricalSurfacecircleWireextrusionVectorbottomFacecircleWireTRUEtopFacebottomFaceextrusionVectorfacestopFacecylindricalSurfacebottomFaceshellfaces1e-7solidshellsolid","version":"0.21.1","type":"blockly"}} title="Creating closed shells and converting to solids" /> {\n // Define geometric parameters\n const radius = 5;\n const height = 5;\n\n // Step 1: Create base circle wire\n const circleOptions = new CircleDto();\n circleOptions.radius = radius;\n circleOptions.center = [0, 0, 0] as Point3;\n circleOptions.direction = [0, 1, 0] as Vector3; // Y-up orientation\n\n const circleWire = await wire.createCircleWire(circleOptions);\n\n // Step 2: Create extrusion vector for cylindrical surface\n const extrusionVector: Vector3 = [0, height, 0];\n\n // Step 3: Create cylindrical surface by extruding the circle wire\n const extrudeOptions = new ExtrudeDto();\n extrudeOptions.shape = circleWire;\n extrudeOptions.direction = extrusionVector;\n\n const cylindricalSurface = await operations.extrude(extrudeOptions);\n\n // Step 4: Create bottom face from the circle wire\n const bottomFaceOptions = new FaceFromWireDto();\n bottomFaceOptions.shape = circleWire;\n bottomFaceOptions.planar = true; // Ensure flat circular face\n\n const bottomFace = await face.createFaceFromWire(bottomFaceOptions);\n\n // Step 5: Create top face by translating bottom face\n const translateOptions = new TranslateDto();\n translateOptions.shape = bottomFace;\n translateOptions.translation = extrusionVector;\n\n const topFace = await transforms.translate(translateOptions);\n\n // Step 6: Collect all faces that will form the closed shell\n const faces = [topFace, cylindricalSurface, bottomFace];\n\n // Step 7: Sew faces together to create a closed shell\n const sewOptions = new SewDto(faces);\n sewOptions.tolerance = 1e-7; // High precision for closed shell\n\n const closedShell = await shell.sewFaces(sewOptions);\n\n // Step 8: Convert closed shell to solid\n const solidOptions = new ShapeDto();\n solidOptions.shape = closedShell;\n\n const cylinderSolid = await solid.fromClosedShell(solidOptions);\n\n // Step 9: Verify the shape types\n const shellType = await shape.getShapeType({ shape: closedShell });\n const solidType = await shape.getShapeType({ shape: cylinderSolid });\n\n console.log('Shell type:', shellType); // Should output \"shell\"\n console.log('Solid type:', solidType); // Should output \"solid\"\n\n // Step 10: Draw the final solid\n bitbybit.draw.drawAnyAsync({\n entity: cylinderSolid\n });\n}\n\n// Execute the function\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"// Import required DTOs for creating complex geometries\nconst { CircleDto, FaceFromWireDto, ShapeDto, SewDto, ExtrudeDto, TranslateDto } = Bit.Inputs.OCCT;\n\n// Import type definitions for type safety\ntype Point3 = Bit.Inputs.Base.Point3;\ntype Vector3 = Bit.Inputs.Base.Vector3;\ntype TopoDSWirePointer = Bit.Inputs.OCCT.TopoDSWirePointer;\ntype TopoDSFacePointer = Bit.Inputs.OCCT.TopoDSFacePointer;\ntype TopoDSShellPointer = Bit.Inputs.OCCT.TopoDSShellPointer;\n\n// Get access to OCCT modules and utility functions\nconst { wire, face, shell, solid, shape } = bitbybit.occt.shapes;\nconst { operations, transforms } = bitbybit.occt;\n\n// Define the main function to create a complex shell and convert to solid\nconst start = async () => {\n // Define geometric parameters\n const radius = 5;\n const height = 5;\n\n // Step 1: Create base circle wire\n const circleOptions = new CircleDto();\n circleOptions.radius = radius;\n circleOptions.center = [0, 0, 0] as Point3;\n circleOptions.direction = [0, 1, 0] as Vector3; // Y-up orientation\n\n const circleWire = await wire.createCircleWire(circleOptions);\n\n // Step 2: Create extrusion vector for cylindrical surface\n const extrusionVector: Vector3 = [0, height, 0];\n\n // Step 3: Create cylindrical surface by extruding the circle wire\n const extrudeOptions = new ExtrudeDto();\n extrudeOptions.shape = circleWire;\n extrudeOptions.direction = extrusionVector;\n\n const cylindricalSurface = await operations.extrude(extrudeOptions);\n\n // Step 4: Create bottom face from the circle wire\n const bottomFaceOptions = new FaceFromWireDto();\n bottomFaceOptions.shape = circleWire;\n bottomFaceOptions.planar = true; // Ensure flat circular face\n\n const bottomFace = await face.createFaceFromWire(bottomFaceOptions);\n\n // Step 5: Create top face by translating bottom face\n const translateOptions = new TranslateDto();\n translateOptions.shape = bottomFace;\n translateOptions.translation = extrusionVector;\n\n const topFace = await transforms.translate(translateOptions);\n\n // Step 6: Collect all faces that will form the closed shell\n const faces = [topFace, cylindricalSurface, bottomFace];\n\n // Step 7: Sew faces together to create a closed shell\n const sewOptions = new SewDto(faces);\n sewOptions.tolerance = 1e-7; // High precision for closed shell\n\n const closedShell = await shell.sewFaces(sewOptions);\n\n // Step 8: Convert closed shell to solid\n const solidOptions = new ShapeDto();\n solidOptions.shape = closedShell;\n\n const cylinderSolid = await solid.fromClosedShell(solidOptions);\n\n // Step 9: Verify the shape types\n const shellType = await shape.getShapeType({ shape: closedShell });\n const solidType = await shape.getShapeType({ shape: cylinderSolid });\n\n console.log('Shell type:', shellType); // Should output \"shell\"\n console.log('Solid type:', solidType); // Should output \"solid\"\n\n // Step 10: Draw the final solid\n bitbybit.draw.drawAnyAsync({\n entity: cylinderSolid\n });\n}\n\n// Execute the function\nstart();","version":"0.21.1","type":"typescript"}} title="Creating closed shells and converting to solids" /> diff --git a/docs/learn/code/common/occt/shapes/solids/intro-solids.md b/docs/learn/code/common/occt/shapes/solids/intro-solids.md index f54fba82..58060361 100644 --- a/docs/learn/code/common/occt/shapes/solids/intro-solids.md +++ b/docs/learn/code/common/occt/shapes/solids/intro-solids.md @@ -32,21 +32,21 @@ This example demonstrates the creation of the most common primitive solid types: boxcubecylindersphereconebox378000TRUEcube5500TRUEcylinder23-500010360TRUEsphere1.51000cone213360-1000010boxcubecylinderspherecone","version":"0.21.0","type":"blockly"}} + script={{"script":"boxcubecylindersphereconebox378000TRUEcube5500TRUEcylinder23-500010360TRUEsphere1.51000cone213360-1000010boxcubecylinderspherecone","version":"0.21.1","type":"blockly"}} title="Creating primitive solids" /> {\n // Create a rectangular box\n const boxOptions = new BoxDto();\n boxOptions.width = 3;\n boxOptions.length = 7;\n boxOptions.height = 8;\n boxOptions.center = [0, 0, 0] as Point3;\n boxOptions.originOnCenter = true;\n \n const box = await solid.createBox(boxOptions);\n \n // Create a cube at a different position\n const cubeOptions = new CubeDto();\n cubeOptions.size = 5;\n cubeOptions.center = [5, 0, 0] as Point3;\n cubeOptions.originOnCenter = true;\n \n const cube = await solid.createCube(cubeOptions);\n \n // Create a cylinder\n const cylinderOptions = new CylinderDto();\n cylinderOptions.radius = 2;\n cylinderOptions.height = 3;\n cylinderOptions.center = [-5, 0, 0] as Point3;\n cylinderOptions.direction = [0, 1, 0] as Vector3;\n cylinderOptions.angle = 360;\n cylinderOptions.originOnCenter = true;\n \n const cylinder = await solid.createCylinder(cylinderOptions);\n \n // Create a sphere\n const sphereOptions = new SphereDto();\n sphereOptions.radius = 1.5;\n sphereOptions.center = [10, 0, 0] as Point3;\n \n const sphere = await solid.createSphere(sphereOptions);\n \n // Create a cone\n const coneOptions = new ConeDto();\n coneOptions.radius1 = 2;\n coneOptions.radius2 = 1;\n coneOptions.height = 3;\n coneOptions.angle = 360;\n coneOptions.center = [-10, 0, 0] as Point3;\n coneOptions.direction = [0, 1, 0] as Vector3;\n \n const cone = await solid.createCone(coneOptions);\n \n // Draw all the created solids\n bitbybit.draw.drawAnyAsync({ entity: box });\n bitbybit.draw.drawAnyAsync({ entity: cube });\n bitbybit.draw.drawAnyAsync({ entity: cylinder });\n bitbybit.draw.drawAnyAsync({ entity: sphere });\n bitbybit.draw.drawAnyAsync({ entity: cone });\n}\n\n// Execute the function\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"// Import required DTOs and types for solid creation\nconst { BoxDto, CubeDto, CylinderDto, SphereDto, ConeDto } = Bit.Inputs.OCCT;\ntype Point3 = Bit.Inputs.Base.Point3;\ntype Vector3 = Bit.Inputs.Base.Vector3;\n\n// Get access to OCCT solid creation functions\nconst { solid } = bitbybit.occt.shapes;\n\n// Define the main function to create various primitive solids\nconst start = async () => {\n // Create a rectangular box\n const boxOptions = new BoxDto();\n boxOptions.width = 3;\n boxOptions.length = 7;\n boxOptions.height = 8;\n boxOptions.center = [0, 0, 0] as Point3;\n boxOptions.originOnCenter = true;\n \n const box = await solid.createBox(boxOptions);\n \n // Create a cube at a different position\n const cubeOptions = new CubeDto();\n cubeOptions.size = 5;\n cubeOptions.center = [5, 0, 0] as Point3;\n cubeOptions.originOnCenter = true;\n \n const cube = await solid.createCube(cubeOptions);\n \n // Create a cylinder\n const cylinderOptions = new CylinderDto();\n cylinderOptions.radius = 2;\n cylinderOptions.height = 3;\n cylinderOptions.center = [-5, 0, 0] as Point3;\n cylinderOptions.direction = [0, 1, 0] as Vector3;\n cylinderOptions.angle = 360;\n cylinderOptions.originOnCenter = true;\n \n const cylinder = await solid.createCylinder(cylinderOptions);\n \n // Create a sphere\n const sphereOptions = new SphereDto();\n sphereOptions.radius = 1.5;\n sphereOptions.center = [10, 0, 0] as Point3;\n \n const sphere = await solid.createSphere(sphereOptions);\n \n // Create a cone\n const coneOptions = new ConeDto();\n coneOptions.radius1 = 2;\n coneOptions.radius2 = 1;\n coneOptions.height = 3;\n coneOptions.angle = 360;\n coneOptions.center = [-10, 0, 0] as Point3;\n coneOptions.direction = [0, 1, 0] as Vector3;\n \n const cone = await solid.createCone(coneOptions);\n \n // Draw all the created solids\n bitbybit.draw.drawAnyAsync({ entity: box });\n bitbybit.draw.drawAnyAsync({ entity: cube });\n bitbybit.draw.drawAnyAsync({ entity: cylinder });\n bitbybit.draw.drawAnyAsync({ entity: sphere });\n bitbybit.draw.drawAnyAsync({ entity: cone });\n}\n\n// Execute the function\nstart();","version":"0.21.1","type":"typescript"}} title="Creating primitive solids" /> diff --git a/docs/learn/code/common/occt/shapes/solids/volume-and-surface-area.md b/docs/learn/code/common/occt/shapes/solids/volume-and-surface-area.md index f2b71927..4c3c427c 100644 --- a/docs/learn/code/common/occt/shapes/solids/volume-and-surface-area.md +++ b/docs/learn/code/common/occt/shapes/solids/volume-and-surface-area.md @@ -32,21 +32,21 @@ The example shows a practical workflow for measuring and displaying geometric pr heightconevolumesurfaceArearoundedVolumeroundedSurfaceAreavolumeTextareaTextvolumePinareaPinheight5cone21height360000010volumeconesurfaceAreaconeroundedVolumevolume2roundedSurfaceAreasurfaceArea2volumeTextVolume {0} m3roundedVolumeareaTextArea {0} m3roundedSurfaceAreavolumePin0height01ADDheight301000volumeText0.30.3areaPin0height01ADDheight401000areaText0.30.3conevolumePinareaPin","version":"0.21.0","type":"blockly"}} + script={{"script":"heightconevolumesurfaceArearoundedVolumeroundedSurfaceAreavolumeTextareaTextvolumePinareaPinheight5cone21height360000010volumeconesurfaceAreaconeroundedVolumevolume2roundedSurfaceAreasurfaceArea2volumeTextVolume {0} m3roundedVolumeareaTextArea {0} m3roundedSurfaceAreavolumePin0height01ADDheight301000volumeText0.30.3areaPin0height01ADDheight401000areaText0.30.3conevolumePinareaPin","version":"0.21.1","type":"blockly"}} title="Get volume and surface area from solid" /> {\n // Parametric height value\n const height = 5;\n\n // Create a cone\n const coneOptions = new ConeDto();\n coneOptions.radius1 = 2;\n coneOptions.radius2 = 1;\n coneOptions.height = height;\n coneOptions.angle = 360;\n coneOptions.center = [0, 0, 0] as Point3;\n coneOptions.direction = [0, 1, 0] as Vector3;\n\n const cone = await solid.createCone(coneOptions);\n\n // Get volume and surface area\n const volume = await solid.getSolidVolume({ shape: cone });\n const surfaceArea = await solid.getSolidSurfaceArea({ shape: cone });\n\n // Round to 2 decimal places\n const roundedVolume = math.roundToDecimals({ number: volume, decimalPlaces: 2 });\n const roundedSurfaceArea = math.roundToDecimals({ number: surfaceArea, decimalPlaces: 2 });\n\n // Format as text with units\n const volumeText = text.format({\n text: \"Volume {0} m3\",\n values: [text.toString({ item: roundedVolume })]\n });\n const areaText = text.format({\n text: \"Area {0} m2\",\n values: [text.toString({ item: roundedSurfaceArea })]\n });\n\n // Create pin labels to display the measurements\n const volumePinOptions = new PinWithLabelDto();\n volumePinOptions.startPoint = [0, height, 0] as Point3;\n volumePinOptions.endPoint = [1, height + 3, 0] as Point3;\n volumePinOptions.direction = [1, 0, 0] as Vector3;\n volumePinOptions.offsetFromStart = 0;\n volumePinOptions.label = volumeText;\n volumePinOptions.labelOffset = 0.3;\n volumePinOptions.labelSize = 0.3;\n\n const volumePin = await dimensions.pinWithLabel(volumePinOptions);\n\n const areaPinOptions = new PinWithLabelDto();\n areaPinOptions.startPoint = [0, height, 0] as Point3;\n areaPinOptions.endPoint = [1, height + 4, 0] as Point3;\n areaPinOptions.direction = [1, 0, 0] as Vector3;\n areaPinOptions.offsetFromStart = 0;\n areaPinOptions.label = areaText;\n areaPinOptions.labelOffset = 0.3;\n areaPinOptions.labelSize = 0.3;\n\n const areaPin = await dimensions.pinWithLabel(areaPinOptions);\n\n // Draw the cone and labels\n bitbybit.draw.drawAnyAsync({ entity: cone });\n bitbybit.draw.drawAnyAsync({ entity: volumePin });\n bitbybit.draw.drawAnyAsync({ entity: areaPin });\n}\n\n// Execute the function\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"// Import required DTOs and types\nconst { ConeDto, PinWithLabelDto } = Bit.Inputs.OCCT;\ntype Point3 = Bit.Inputs.Base.Point3;\ntype Vector3 = Bit.Inputs.Base.Vector3;\n\n// Get access to OCCT modules\nconst { solid } = bitbybit.occt.shapes;\nconst { dimensions } = bitbybit.occt;\nconst { math, text } = bitbybit;\n\n// Define the main function to demonstrate volume and surface area calculation\nconst start = async () => {\n // Parametric height value\n const height = 5;\n\n // Create a cone\n const coneOptions = new ConeDto();\n coneOptions.radius1 = 2;\n coneOptions.radius2 = 1;\n coneOptions.height = height;\n coneOptions.angle = 360;\n coneOptions.center = [0, 0, 0] as Point3;\n coneOptions.direction = [0, 1, 0] as Vector3;\n\n const cone = await solid.createCone(coneOptions);\n\n // Get volume and surface area\n const volume = await solid.getSolidVolume({ shape: cone });\n const surfaceArea = await solid.getSolidSurfaceArea({ shape: cone });\n\n // Round to 2 decimal places\n const roundedVolume = math.roundToDecimals({ number: volume, decimalPlaces: 2 });\n const roundedSurfaceArea = math.roundToDecimals({ number: surfaceArea, decimalPlaces: 2 });\n\n // Format as text with units\n const volumeText = text.format({\n text: \"Volume {0} m3\",\n values: [text.toString({ item: roundedVolume })]\n });\n const areaText = text.format({\n text: \"Area {0} m2\",\n values: [text.toString({ item: roundedSurfaceArea })]\n });\n\n // Create pin labels to display the measurements\n const volumePinOptions = new PinWithLabelDto();\n volumePinOptions.startPoint = [0, height, 0] as Point3;\n volumePinOptions.endPoint = [1, height + 3, 0] as Point3;\n volumePinOptions.direction = [1, 0, 0] as Vector3;\n volumePinOptions.offsetFromStart = 0;\n volumePinOptions.label = volumeText;\n volumePinOptions.labelOffset = 0.3;\n volumePinOptions.labelSize = 0.3;\n\n const volumePin = await dimensions.pinWithLabel(volumePinOptions);\n\n const areaPinOptions = new PinWithLabelDto();\n areaPinOptions.startPoint = [0, height, 0] as Point3;\n areaPinOptions.endPoint = [1, height + 4, 0] as Point3;\n areaPinOptions.direction = [1, 0, 0] as Vector3;\n areaPinOptions.offsetFromStart = 0;\n areaPinOptions.label = areaText;\n areaPinOptions.labelOffset = 0.3;\n areaPinOptions.labelSize = 0.3;\n\n const areaPin = await dimensions.pinWithLabel(areaPinOptions);\n\n // Draw the cone and labels\n bitbybit.draw.drawAnyAsync({ entity: cone });\n bitbybit.draw.drawAnyAsync({ entity: volumePin });\n bitbybit.draw.drawAnyAsync({ entity: areaPin });\n}\n\n// Execute the function\nstart();","version":"0.21.1","type":"typescript"}} title="Get volume and surface area from solid" /> diff --git a/docs/learn/code/common/occt/shapes/wire/wire-basic-primitives.md b/docs/learn/code/common/occt/shapes/wire/wire-basic-primitives.md index 4404b6ad..8d3bf181 100644 --- a/docs/learn/code/common/occt/shapes/wire/wire-basic-primitives.md +++ b/docs/learn/code/common/occt/shapes/wire/wire-basic-primitives.md @@ -33,21 +33,21 @@ This example demonstrates the creation of the most common primitive wire types: circleWiresquareWirengonWireparallelogramWirerectangleWireellipseWirecircleWire3000010squareWire3500010ngonWire-60001062parallelogramWire-1100010TRUE3230rectangleWire26900010ellipseWire120001014circleWiresquareWirengonWireparallelogramWirerectangleWireellipseWire","version":"0.21.0","type":"blockly"}} + script={{"script":"circleWiresquareWirengonWireparallelogramWirerectangleWireellipseWirecircleWire3000010squareWire3500010ngonWire-60001062parallelogramWire-1100010TRUE3230rectangleWire26900010ellipseWire120001014circleWiresquareWirengonWireparallelogramWirerectangleWireellipseWire","version":"0.21.1","type":"blockly"}} title="Creating basic wire primitives" /> {\n // Create a circle wire\n const circleOptions = new CircleDto();\n circleOptions.radius = 3;\n circleOptions.center = [0, 0, 0] as Point3;\n circleOptions.direction = [0, 1, 0] as Vector3;\n\n const circleWire = await wire.createCircleWire(circleOptions);\n\n // Create a square wire at a different position\n const squareOptions = new SquareDto();\n squareOptions.size = 3;\n squareOptions.center = [5, 0, 0] as Point3;\n squareOptions.direction = [0, 1, 0] as Vector3;\n\n const squareWire = await wire.createSquareWire(squareOptions);\n\n // Create an NGon wire (hexagon)\n const ngonOptions = new NGonWireDto();\n ngonOptions.center = [-6, 0, 0] as Point3;\n ngonOptions.direction = [0, 1, 0] as Vector3;\n ngonOptions.nrCorners = 6;\n ngonOptions.radius = 2;\n\n const ngonWire = await wire.createNGonWire(ngonOptions);\n\n // Create a parallelogram wire\n const parallelogramOptions = new ParallelogramDto();\n parallelogramOptions.center = [-11, 0, 0] as Point3;\n parallelogramOptions.direction = [0, 1, 0] as Vector3;\n parallelogramOptions.aroundCenter = true;\n parallelogramOptions.width = 3;\n parallelogramOptions.height = 2;\n parallelogramOptions.angle = 30;\n\n const parallelogramWire = await wire.createParallelogramWire(parallelogramOptions);\n\n // Create a rectangle wire\n const rectangleOptions = new RectangleDto();\n rectangleOptions.width = 2;\n rectangleOptions.length = 6;\n rectangleOptions.center = [9, 0, 0] as Point3;\n rectangleOptions.direction = [0, 1, 0] as Vector3;\n\n const rectangleWire = await wire.createRectangleWire(rectangleOptions);\n\n // Create an ellipse wire\n const ellipseOptions = new EllipseDto();\n ellipseOptions.center = [12, 0, 0] as Point3;\n ellipseOptions.direction = [0, 1, 0] as Vector3;\n ellipseOptions.radiusMinor = 1;\n ellipseOptions.radiusMajor = 4;\n\n const ellipseWire = await wire.createEllipseWire(ellipseOptions);\n\n // Draw all the created wires\n bitbybit.draw.drawAnyAsync({ entity: circleWire });\n bitbybit.draw.drawAnyAsync({ entity: squareWire });\n bitbybit.draw.drawAnyAsync({ entity: ngonWire });\n bitbybit.draw.drawAnyAsync({ entity: parallelogramWire });\n bitbybit.draw.drawAnyAsync({ entity: rectangleWire });\n bitbybit.draw.drawAnyAsync({ entity: ellipseWire });\n}\n\n// Execute the function\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"// Import required DTOs and types for wire creation\nconst { CircleDto, SquareDto, NGonWireDto, ParallelogramDto, RectangleDto, EllipseDto } = Bit.Inputs.OCCT;\ntype Point3 = Bit.Inputs.Base.Point3;\ntype Vector3 = Bit.Inputs.Base.Vector3;\n\n// Get access to OCCT wire creation functions\nconst { wire } = bitbybit.occt.shapes;\n\n// Define the main function to create various primitive wires\nconst start = async () => {\n // Create a circle wire\n const circleOptions = new CircleDto();\n circleOptions.radius = 3;\n circleOptions.center = [0, 0, 0] as Point3;\n circleOptions.direction = [0, 1, 0] as Vector3;\n\n const circleWire = await wire.createCircleWire(circleOptions);\n\n // Create a square wire at a different position\n const squareOptions = new SquareDto();\n squareOptions.size = 3;\n squareOptions.center = [5, 0, 0] as Point3;\n squareOptions.direction = [0, 1, 0] as Vector3;\n\n const squareWire = await wire.createSquareWire(squareOptions);\n\n // Create an NGon wire (hexagon)\n const ngonOptions = new NGonWireDto();\n ngonOptions.center = [-6, 0, 0] as Point3;\n ngonOptions.direction = [0, 1, 0] as Vector3;\n ngonOptions.nrCorners = 6;\n ngonOptions.radius = 2;\n\n const ngonWire = await wire.createNGonWire(ngonOptions);\n\n // Create a parallelogram wire\n const parallelogramOptions = new ParallelogramDto();\n parallelogramOptions.center = [-11, 0, 0] as Point3;\n parallelogramOptions.direction = [0, 1, 0] as Vector3;\n parallelogramOptions.aroundCenter = true;\n parallelogramOptions.width = 3;\n parallelogramOptions.height = 2;\n parallelogramOptions.angle = 30;\n\n const parallelogramWire = await wire.createParallelogramWire(parallelogramOptions);\n\n // Create a rectangle wire\n const rectangleOptions = new RectangleDto();\n rectangleOptions.width = 2;\n rectangleOptions.length = 6;\n rectangleOptions.center = [9, 0, 0] as Point3;\n rectangleOptions.direction = [0, 1, 0] as Vector3;\n\n const rectangleWire = await wire.createRectangleWire(rectangleOptions);\n\n // Create an ellipse wire\n const ellipseOptions = new EllipseDto();\n ellipseOptions.center = [12, 0, 0] as Point3;\n ellipseOptions.direction = [0, 1, 0] as Vector3;\n ellipseOptions.radiusMinor = 1;\n ellipseOptions.radiusMajor = 4;\n\n const ellipseWire = await wire.createEllipseWire(ellipseOptions);\n\n // Draw all the created wires\n bitbybit.draw.drawAnyAsync({ entity: circleWire });\n bitbybit.draw.drawAnyAsync({ entity: squareWire });\n bitbybit.draw.drawAnyAsync({ entity: ngonWire });\n bitbybit.draw.drawAnyAsync({ entity: parallelogramWire });\n bitbybit.draw.drawAnyAsync({ entity: rectangleWire });\n bitbybit.draw.drawAnyAsync({ entity: ellipseWire });\n}\n\n// Execute the function\nstart();","version":"0.21.1","type":"typescript"}} title="Creating basic wire primitives" /> diff --git a/docs/learn/code/common/occt/shapes/wire/wire-bezier-weights.md b/docs/learn/code/common/occt/shapes/wire/wire-bezier-weights.md index b4875453..6c8624db 100644 --- a/docs/learn/code/common/occt/shapes/wire/wire-bezier-weights.md +++ b/docs/learn/code/common/occt/shapes/wire/wire-bezier-weights.md @@ -34,21 +34,21 @@ This technique is invaluable for design work where you need the curve to emphasi point1point2point3point4point5pointsListweightsbezierWirepolylineRefminWeightmaxWeightspheressphere1sphere2sphere3sphere4sphere5point1-1000point2-503point307-5point4503point51000pointsListpoint1point2point3point4point5weights10602003010bezierWirepointsListweightsFALSEbezierWire0.01FALSETRUE#e4ff1a10polylineRefpointsListFALSEpolylineRefminWeightweightsmaxWeightweightssphere1point110minWeightmaxWeight0.30.9sphere2point260minWeightmaxWeight0.30.9sphere3point3200minWeightmaxWeight0.30.9sphere4point430minWeightmaxWeight0.30.9sphere5point510minWeightmaxWeight0.30.9spheressphere1sphere2sphere3sphere4sphere5spheres0.05TRUEFALSE#37ff00","version":"0.21.0","type":"blockly"}} + script={{"script":"point1point2point3point4point5pointsListweightsbezierWirepolylineRefminWeightmaxWeightspheressphere1sphere2sphere3sphere4sphere5point1-1000point2-503point307-5point4503point51000pointsListpoint1point2point3point4point5weights10602003010bezierWirepointsListweightsFALSEbezierWire0.01FALSETRUE#e4ff1a10polylineRefpointsListFALSEpolylineRefminWeightweightsmaxWeightweightssphere1point110minWeightmaxWeight0.30.9sphere2point260minWeightmaxWeight0.30.9sphere3point3200minWeightmaxWeight0.30.9sphere4point430minWeightmaxWeight0.30.9sphere5point510minWeightmaxWeight0.30.9spheressphere1sphere2sphere3sphere4sphere5spheres0.05TRUEFALSE#37ff00","version":"0.21.1","type":"blockly"}} title="Bezier curves with different weight distributions" /> {\n // Define control points for the Bezier curve\n const controlPoints: Point3[] = [\n [-10, 0, 0],\n [-5, 0, 3],\n [0, 7, -5],\n [5, 0, 3],\n [10, 0, 0]\n ];\n\n // Weight values - higher weights pull the curve closer to that point\n const weights: number[] = [10, 60, 200, 30, 10];\n \n // Create weighted Bezier curve\n const bezierOptions = new BezierWeightsDto();\n bezierOptions.points = controlPoints;\n bezierOptions.weights = weights;\n bezierOptions.closed = false;\n const bezierWire = await wire.createBezierWeights(bezierOptions);\n\n // Draw the Bezier curve with thick yellow line\n const wireDrawOptions = new DrawOcctShapeSimpleOptions();\n wireDrawOptions.precision = 0.01;\n wireDrawOptions.drawFaces = false;\n wireDrawOptions.drawEdges = true;\n wireDrawOptions.edgeColour = \"#e4ff1a\";\n wireDrawOptions.edgeWidth = 10;\n\n await draw.drawAnyAsync({ entity: bezierWire, options: wireDrawOptions });\n\n // Draw reference polyline connecting control points\n const plnOptions = new PolylineCreateDto();\n plnOptions.points = controlPoints;\n const pln = polyline.create(plnOptions) as Bit.Inputs.Draw.Entity;\n await draw.drawAnyAsync({ entity: pln });\n\n // Calculate weight range for sphere scaling\n const minWeight = vector.min({ vector: weights });\n const maxWeight = vector.max({ vector: weights });\n\n // Create spheres at control points, sized by their weights\n const spherePromises = [];\n for (let i = 0; i < controlPoints.length; i++) {\n // Remap weight to sphere radius (0.3 to 0.9)\n const remapOptions = new RemapNumberDto();\n remapOptions.number = weights[i];\n remapOptions.fromLow = minWeight;\n remapOptions.fromHigh = maxWeight;\n remapOptions.toLow = 0.3;\n remapOptions.toHigh = 0.9;\n\n const sphereOptions = new SphereDto();\n sphereOptions.center = controlPoints[i];\n sphereOptions.radius = bitbybit.math.remap(remapOptions);\n\n spherePromises.push(shapes.solid.createSphere(sphereOptions));\n }\n\n const spheres = await Promise.all(spherePromises);\n\n // Draw spheres in green\n const sphereDrawOptions = new DrawOcctShapeSimpleOptions();\n sphereDrawOptions.precision = 0.05;\n sphereDrawOptions.drawFaces = true;\n sphereDrawOptions.drawEdges = false;\n sphereDrawOptions.faceColour = \"#37ff00\";\n \n draw.drawAnyAsync({ entity: spheres, options: sphereDrawOptions });\n};\n\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"// Import required DTOs and types\nconst { BezierWeightsDto, SphereDto } = Bit.Inputs.OCCT;\nconst { DrawOcctShapeSimpleOptions } = Bit.Inputs.Draw;\nconst { RemapNumberDto } = Bit.Inputs.Math;\nconst { PolylineCreateDto } = Bit.Inputs.Polyline;\n\ntype Point3 = Bit.Inputs.Base.Point3;\ntype Vector3 = Bit.Inputs.Base.Vector3;\ntype TopoDSShapePointer = Bit.Inputs.OCCT.TopoDSShapePointer;\n\n// Get access to BitByBit functions\nconst { wire } = bitbybit.occt.shapes;\nconst { shapes } = bitbybit.occt;\nconst { draw, vector, polyline } = bitbybit;\n\nconst start = async () => {\n // Define control points for the Bezier curve\n const controlPoints: Point3[] = [\n [-10, 0, 0],\n [-5, 0, 3],\n [0, 7, -5],\n [5, 0, 3],\n [10, 0, 0]\n ];\n\n // Weight values - higher weights pull the curve closer to that point\n const weights: number[] = [10, 60, 200, 30, 10];\n \n // Create weighted Bezier curve\n const bezierOptions = new BezierWeightsDto();\n bezierOptions.points = controlPoints;\n bezierOptions.weights = weights;\n bezierOptions.closed = false;\n const bezierWire = await wire.createBezierWeights(bezierOptions);\n\n // Draw the Bezier curve with thick yellow line\n const wireDrawOptions = new DrawOcctShapeSimpleOptions();\n wireDrawOptions.precision = 0.01;\n wireDrawOptions.drawFaces = false;\n wireDrawOptions.drawEdges = true;\n wireDrawOptions.edgeColour = \"#e4ff1a\";\n wireDrawOptions.edgeWidth = 10;\n\n await draw.drawAnyAsync({ entity: bezierWire, options: wireDrawOptions });\n\n // Draw reference polyline connecting control points\n const plnOptions = new PolylineCreateDto();\n plnOptions.points = controlPoints;\n const pln = polyline.create(plnOptions) as Bit.Inputs.Draw.Entity;\n await draw.drawAnyAsync({ entity: pln });\n\n // Calculate weight range for sphere scaling\n const minWeight = vector.min({ vector: weights });\n const maxWeight = vector.max({ vector: weights });\n\n // Create spheres at control points, sized by their weights\n const spherePromises = [];\n for (let i = 0; i < controlPoints.length; i++) {\n // Remap weight to sphere radius (0.3 to 0.9)\n const remapOptions = new RemapNumberDto();\n remapOptions.number = weights[i];\n remapOptions.fromLow = minWeight;\n remapOptions.fromHigh = maxWeight;\n remapOptions.toLow = 0.3;\n remapOptions.toHigh = 0.9;\n\n const sphereOptions = new SphereDto();\n sphereOptions.center = controlPoints[i];\n sphereOptions.radius = bitbybit.math.remap(remapOptions);\n\n spherePromises.push(shapes.solid.createSphere(sphereOptions));\n }\n\n const spheres = await Promise.all(spherePromises);\n\n // Draw spheres in green\n const sphereDrawOptions = new DrawOcctShapeSimpleOptions();\n sphereDrawOptions.precision = 0.05;\n sphereDrawOptions.drawFaces = true;\n sphereDrawOptions.drawEdges = false;\n sphereDrawOptions.faceColour = \"#37ff00\";\n \n draw.drawAnyAsync({ entity: spheres, options: sphereDrawOptions });\n};\n\nstart();","version":"0.21.1","type":"typescript"}} title="Bezier curves with different weight distributions" /> diff --git a/docs/learn/code/common/occt/shapes/wire/wire-from-edges.md b/docs/learn/code/common/occt/shapes/wire/wire-from-edges.md index 60c1ce6a..2c842eed 100644 --- a/docs/learn/code/common/occt/shapes/wire/wire-from-edges.md +++ b/docs/learn/code/common/occt/shapes/wire/wire-from-edges.md @@ -60,21 +60,21 @@ This example showcases how simple geometric operations (arc creation and rotatio arc1arc2arc3arc4edgesListcombinedWirearc1505003-505arc2arc101090arc3arc201090arc4arc301090edgesListarc1arc2arc3arc4combinedWireedgesListcombinedWire","version":"0.21.0","type":"blockly"}} + script={{"script":"arc1arc2arc3arc4edgesListcombinedWirearc1505003-505arc2arc101090arc3arc201090arc4arc301090edgesListarc1arc2arc3arc4combinedWireedgesListcombinedWire","version":"0.21.1","type":"blockly"}} title="Combining edges into a wire" /> {\n // Create the first arc through three points\n const arcOptions = new ArcEdgeThreePointsDto();\n arcOptions.start = [5, 0, 5] as Point3;\n arcOptions.middle = [0, 0, 3] as Point3;\n arcOptions.end = [-5, 0, 5] as Point3;\n\n const arc1 = await edge.arcThroughThreePoints(arcOptions);\n\n // Create rotation options for Y-axis rotation\n const rotateOptions = new RotateDto();\n rotateOptions.axis = [0, 1, 0] as Vector3;\n rotateOptions.angle = 90; // 90 degrees\n\n // Create three more arcs by rotating the first arc\n rotateOptions.shape = arc1;\n const arc2 = await transforms.rotate(rotateOptions);\n\n rotateOptions.shape = arc2;\n const arc3 = await transforms.rotate(rotateOptions);\n\n rotateOptions.shape = arc3;\n const arc4 = await transforms.rotate(rotateOptions);\n\n // Combine all arc edges into a single wire\n const combineOptions = new ShapesDto();\n combineOptions.shapes = [arc1, arc2, arc3, arc4];\n\n const combinedWire = await wire.combineEdgesAndWiresIntoAWire(combineOptions);\n\n // Draw the combined wire\n bitbybit.draw.drawAnyAsync({ entity: combinedWire });\n}\n\n// Execute the function\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"// Import required DTOs and types for edge and wire creation\nconst { ArcEdgeThreePointsDto, RotateDto, ShapesDto } = Bit.Inputs.OCCT;\ntype Point3 = Bit.Inputs.Base.Point3;\ntype Vector3 = Bit.Inputs.Base.Vector3;\ntype TopoDSShapePointer = Bit.Inputs.OCCT.TopoDSShapePointer;\ntype TopoDSEdgePointer = Bit.Inputs.OCCT.TopoDSEdgePointer;\n\n// Get access to OCCT edge, wire, and transform functions\nconst { edge, wire } = bitbybit.occt.shapes;\nconst { transforms } = bitbybit.occt;\n\n// Define the main function to create a wire from multiple edges\nconst start = async () => {\n // Create the first arc through three points\n const arcOptions = new ArcEdgeThreePointsDto();\n arcOptions.start = [5, 0, 5] as Point3;\n arcOptions.middle = [0, 0, 3] as Point3;\n arcOptions.end = [-5, 0, 5] as Point3;\n\n const arc1 = await edge.arcThroughThreePoints(arcOptions);\n\n // Create rotation options for Y-axis rotation\n const rotateOptions = new RotateDto();\n rotateOptions.axis = [0, 1, 0] as Vector3;\n rotateOptions.angle = 90; // 90 degrees\n\n // Create three more arcs by rotating the first arc\n rotateOptions.shape = arc1;\n const arc2 = await transforms.rotate(rotateOptions);\n\n rotateOptions.shape = arc2;\n const arc3 = await transforms.rotate(rotateOptions);\n\n rotateOptions.shape = arc3;\n const arc4 = await transforms.rotate(rotateOptions);\n\n // Combine all arc edges into a single wire\n const combineOptions = new ShapesDto();\n combineOptions.shapes = [arc1, arc2, arc3, arc4];\n\n const combinedWire = await wire.combineEdgesAndWiresIntoAWire(combineOptions);\n\n // Draw the combined wire\n bitbybit.draw.drawAnyAsync({ entity: combinedWire });\n}\n\n// Execute the function\nstart();","version":"0.21.1","type":"typescript"}} title="Combining edges into a wire" /> diff --git a/docs/learn/code/common/occt/shapes/wire/wire-hexagons-advanced-pattern.md b/docs/learn/code/common/occt/shapes/wire/wire-hexagons-advanced-pattern.md index 5a0e78e6..cd86b585 100644 --- a/docs/learn/code/common/occt/shapes/wire/wire-hexagons-advanced-pattern.md +++ b/docs/learn/code/common/occt/shapes/wire/wire-hexagons-advanced-pattern.md @@ -35,21 +35,21 @@ This approach demonstrates the power of parametric design thinking, where simple gridWidthgridHeighthexagonsInWidthhexagonsInHeightcontrolPointXcontrolPointZcontrolPointhexGridhexCentersdistancesminDistancemaxDistancescalePatternidistancescaledValueinclusionPatternhexagonWiresboundaryWiregridWidth16.5gridHeight9hexagonsInWidth20hexagonsInHeight20controlPointX2.2controlPointZ2.8controlPointcontrolPointX0controlPointZhexGridgridWidthgridHeighthexagonsInWidthhexagonsInHeightTRUEFALSEFALSEFALSEFALSETRUETRUEhexCentershexGridcentersdistancescontrolPointhexCentersminDistancedistancesmaxDistancedistancesscalePatterndistancedistancesscaledValuedistanceminDistancemaxDistance0.1110.999INSERTLASTscalePatternscaledValueinclusionPattern[true, true, false]hexagonWiresgridWidthgridHeighthexagonsInWidthhexagonsInHeightTRUEFALSEFALSEFALSEFALSEscalePatternscalePatterninclusionPatternboundaryWiregridWidthgridHeight000010hexagonWiresboundaryWirecontrolPoint","version":"0.21.0","type":"blockly"}} + script={{"script":"gridWidthgridHeighthexagonsInWidthhexagonsInHeightcontrolPointXcontrolPointZcontrolPointhexGridhexCentersdistancesminDistancemaxDistancescalePatternidistancescaledValueinclusionPatternhexagonWiresboundaryWiregridWidth16.5gridHeight9hexagonsInWidth20hexagonsInHeight20controlPointX2.2controlPointZ2.8controlPointcontrolPointX0controlPointZhexGridgridWidthgridHeighthexagonsInWidthhexagonsInHeightTRUEFALSEFALSEFALSEFALSETRUETRUEhexCentershexGridcentersdistancescontrolPointhexCentersminDistancedistancesmaxDistancedistancesscalePatterndistancedistancesscaledValuedistanceminDistancemaxDistance0.1110.999INSERTLASTscalePatternscaledValueinclusionPattern[true, true, false]hexagonWiresgridWidthgridHeighthexagonsInWidthhexagonsInHeightTRUEFALSEFALSEFALSEFALSEscalePatternscalePatterninclusionPatternboundaryWiregridWidthgridHeight000010hexagonWiresboundaryWirecontrolPoint","version":"0.21.1","type":"blockly"}} title="Creating hexagon grids in beautiful patterns" /> {\n // Define grid dimensions\n const gridWidth = 16.5;\n const gridHeight = 9;\n const hexagonsInWidth = 20;\n const hexagonsInHeight = 20;\n\n // Control point for distance calculation\n const controlPointX = 2.2;\n const controlPointZ = 2.8;\n const controlPoint: Point3 = [controlPointX, 0, controlPointZ];\n\n // Generate hex grid to get center points\n const hexGridOptions = new HexGridScaledToFitDto();\n hexGridOptions.width = gridWidth;\n hexGridOptions.height = gridHeight;\n hexGridOptions.nrHexagonsInWidth = hexagonsInWidth;\n hexGridOptions.nrHexagonsInHeight = hexagonsInHeight;\n hexGridOptions.flatTop = true;\n hexGridOptions.extendTop = false;\n hexGridOptions.extendBottom = false;\n hexGridOptions.extendLeft = false;\n hexGridOptions.extendRight = false;\n hexGridOptions.centerGrid = true;\n hexGridOptions.pointsOnGround = true;\n\n const hexGrid: HexGridData = bitbybit.point.hexGridScaledToFit(hexGridOptions);\n const hexCenters = hexGrid.centers;\n\n // Calculate distances from control point to all hex centers\n const distanceOptions = new StartEndPointsListDto();\n distanceOptions.startPoint = controlPoint;\n distanceOptions.endPoints = hexCenters;\n\n const distances = bitbybit.point.distancesToPoints(distanceOptions);\n\n // Find min and max distances for remapping\n const minDistance = bitbybit.vector.min({ vector: distances });\n const maxDistance = bitbybit.vector.max({ vector: distances });\n\n // Remap distances to scale values between 0.111 and 0.999\n const scalePattern: number[] = [];\n\n for (const distance of distances) {\n const remapOptions = new RemapNumberDto();\n remapOptions.number = distance;\n remapOptions.fromLow = minDistance;\n remapOptions.fromHigh = maxDistance;\n remapOptions.toLow = 0.111;\n remapOptions.toHigh = 0.999;\n\n const scaledValue = bitbybit.math.remap(remapOptions);\n scalePattern.push(scaledValue);\n }\n\n // Create hexagonal grid with patterns\n const hexGridPatternOptions = new HexagonsInGridDto();\n hexGridPatternOptions.width = gridWidth;\n hexGridPatternOptions.height = gridHeight;\n hexGridPatternOptions.nrHexagonsInWidth = hexagonsInWidth;\n hexGridPatternOptions.nrHexagonsInHeight = hexagonsInHeight;\n hexGridPatternOptions.flatTop = true;\n hexGridPatternOptions.extendTop = false;\n hexGridPatternOptions.extendBottom = false;\n hexGridPatternOptions.extendLeft = false;\n hexGridPatternOptions.extendRight = false;\n\n // Apply the distance-based scale pattern to both width and height\n hexGridPatternOptions.scalePatternWidth = scalePattern;\n hexGridPatternOptions.scalePatternHeight = scalePattern;\n\n // Apply inclusion pattern to selectively remove some hexagons\n const inclusionPattern = [true, true, false]; // Pattern repeats across the grid\n hexGridPatternOptions.inclusionPattern = inclusionPattern;\n\n // Generate the patterned hexagon grid\n const hexagonWires = await bitbybit.occt.shapes.wire.hexagonsInGrid(hexGridPatternOptions);\n\n // Create a boundary rectangle for reference\n const boundaryOptions = new RectangleDto();\n boundaryOptions.width = gridWidth;\n boundaryOptions.length = gridHeight;\n boundaryOptions.center = [0, 0, 0] as Point3;\n boundaryOptions.direction = [0, 1, 0] as Vector3;\n\n const boundaryWire = await bitbybit.occt.shapes.wire.createRectangleWire(boundaryOptions);\n\n // Draw the patterned hexagon grid and boundary\n bitbybit.draw.drawAnyAsync({ entity: hexagonWires });\n bitbybit.draw.drawAnyAsync({ entity: boundaryWire });\n\n // Optionally draw the control point for reference\n bitbybit.draw.drawAnyAsync({ entity: controlPoint });\n}\n\n// Execute the function\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"const { HexagonsInGridDto, RectangleDto } = Bit.Inputs.OCCT;\nconst { HexGridScaledToFitDto, StartEndPointsListDto } = Bit.Inputs.Point;\nconst { RemapNumberDto } = Bit.Inputs.Math;\n// Import required types\ntype TopoDSWirePointer = Bit.Inputs.OCCT.TopoDSWirePointer;\ntype Point3 = Bit.Inputs.Base.Point3;\ntype Vector3 = Bit.Inputs.Base.Vector3;\ntype HexGridData = Bit.Models.Point.HexGridData;\n\n// Define the main function\nconst start = async () => {\n // Define grid dimensions\n const gridWidth = 16.5;\n const gridHeight = 9;\n const hexagonsInWidth = 20;\n const hexagonsInHeight = 20;\n\n // Control point for distance calculation\n const controlPointX = 2.2;\n const controlPointZ = 2.8;\n const controlPoint: Point3 = [controlPointX, 0, controlPointZ];\n\n // Generate hex grid to get center points\n const hexGridOptions = new HexGridScaledToFitDto();\n hexGridOptions.width = gridWidth;\n hexGridOptions.height = gridHeight;\n hexGridOptions.nrHexagonsInWidth = hexagonsInWidth;\n hexGridOptions.nrHexagonsInHeight = hexagonsInHeight;\n hexGridOptions.flatTop = true;\n hexGridOptions.extendTop = false;\n hexGridOptions.extendBottom = false;\n hexGridOptions.extendLeft = false;\n hexGridOptions.extendRight = false;\n hexGridOptions.centerGrid = true;\n hexGridOptions.pointsOnGround = true;\n\n const hexGrid: HexGridData = bitbybit.point.hexGridScaledToFit(hexGridOptions);\n const hexCenters = hexGrid.centers;\n\n // Calculate distances from control point to all hex centers\n const distanceOptions = new StartEndPointsListDto();\n distanceOptions.startPoint = controlPoint;\n distanceOptions.endPoints = hexCenters;\n\n const distances = bitbybit.point.distancesToPoints(distanceOptions);\n\n // Find min and max distances for remapping\n const minDistance = bitbybit.vector.min({ vector: distances });\n const maxDistance = bitbybit.vector.max({ vector: distances });\n\n // Remap distances to scale values between 0.111 and 0.999\n const scalePattern: number[] = [];\n\n for (const distance of distances) {\n const remapOptions = new RemapNumberDto();\n remapOptions.number = distance;\n remapOptions.fromLow = minDistance;\n remapOptions.fromHigh = maxDistance;\n remapOptions.toLow = 0.111;\n remapOptions.toHigh = 0.999;\n\n const scaledValue = bitbybit.math.remap(remapOptions);\n scalePattern.push(scaledValue);\n }\n\n // Create hexagonal grid with patterns\n const hexGridPatternOptions = new HexagonsInGridDto();\n hexGridPatternOptions.width = gridWidth;\n hexGridPatternOptions.height = gridHeight;\n hexGridPatternOptions.nrHexagonsInWidth = hexagonsInWidth;\n hexGridPatternOptions.nrHexagonsInHeight = hexagonsInHeight;\n hexGridPatternOptions.flatTop = true;\n hexGridPatternOptions.extendTop = false;\n hexGridPatternOptions.extendBottom = false;\n hexGridPatternOptions.extendLeft = false;\n hexGridPatternOptions.extendRight = false;\n\n // Apply the distance-based scale pattern to both width and height\n hexGridPatternOptions.scalePatternWidth = scalePattern;\n hexGridPatternOptions.scalePatternHeight = scalePattern;\n\n // Apply inclusion pattern to selectively remove some hexagons\n const inclusionPattern = [true, true, false]; // Pattern repeats across the grid\n hexGridPatternOptions.inclusionPattern = inclusionPattern;\n\n // Generate the patterned hexagon grid\n const hexagonWires = await bitbybit.occt.shapes.wire.hexagonsInGrid(hexGridPatternOptions);\n\n // Create a boundary rectangle for reference\n const boundaryOptions = new RectangleDto();\n boundaryOptions.width = gridWidth;\n boundaryOptions.length = gridHeight;\n boundaryOptions.center = [0, 0, 0] as Point3;\n boundaryOptions.direction = [0, 1, 0] as Vector3;\n\n const boundaryWire = await bitbybit.occt.shapes.wire.createRectangleWire(boundaryOptions);\n\n // Draw the patterned hexagon grid and boundary\n bitbybit.draw.drawAnyAsync({ entity: hexagonWires });\n bitbybit.draw.drawAnyAsync({ entity: boundaryWire });\n\n // Optionally draw the control point for reference\n bitbybit.draw.drawAnyAsync({ entity: controlPoint });\n}\n\n// Execute the function\nstart();","version":"0.21.1","type":"typescript"}} title="Creating hexagon grids" /> diff --git a/docs/learn/code/common/occt/shapes/wire/wire-hexagons-in-grid.md b/docs/learn/code/common/occt/shapes/wire/wire-hexagons-in-grid.md index 45688c92..ba5a815d 100644 --- a/docs/learn/code/common/occt/shapes/wire/wire-hexagons-in-grid.md +++ b/docs/learn/code/common/occt/shapes/wire/wire-hexagons-in-grid.md @@ -50,21 +50,21 @@ The component also includes advanced patterning capabilities through optional ar widthheightwidth16.5height9widthheight2318FALSEFALSEFALSEFALSEFALSEwidthheight000010","version":"0.21.0","type":"blockly"}} + script={{"script":"widthheightwidth16.5height9widthheight2318FALSEFALSEFALSEFALSEFALSEwidthheight000010","version":"0.21.1","type":"blockly"}} title="Creating hexagon grids" /> {\n // Define grid dimensions\n const gridWidth = 16.5;\n const gridHeight = 9;\n const hexagonsInWidth = 23;\n const hexagonsInHeight = 18;\n\n // Create hexagonal grid parameters\n const hexGridOptions = new HexagonsInGridDto();\n hexGridOptions.width = gridWidth;\n hexGridOptions.height = gridHeight;\n hexGridOptions.nrHexagonsInWidth = hexagonsInWidth;\n hexGridOptions.nrHexagonsInHeight = hexagonsInHeight;\n hexGridOptions.flatTop = false; // Pointed-top hexagons\n hexGridOptions.extendTop = false;\n hexGridOptions.extendBottom = false;\n hexGridOptions.extendLeft = false;\n hexGridOptions.extendRight = false;\n\n // Generate the hexagon grid\n const hexagonWires = await bitbybit.occt.shapes.wire.hexagonsInGrid(hexGridOptions);\n\n // Create a boundary rectangle for reference\n const boundaryOptions = new RectangleDto();\n boundaryOptions.width = gridWidth;\n boundaryOptions.length = gridHeight;\n boundaryOptions.center = [0, 0, 0] as Point3;\n boundaryOptions.direction = [0, 1, 0] as Vector3;\n\n const boundaryWire = await bitbybit.occt.shapes.wire.createRectangleWire(boundaryOptions);\n\n // Draw the hexagon grid and boundary\n bitbybit.draw.drawAnyAsync({ entity: hexagonWires });\n bitbybit.draw.drawAnyAsync({ entity: boundaryWire });\n}\n\n// Execute the function\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"const { HexagonsInGridDto, RectangleDto } = Bit.Inputs.OCCT;\n// Import required types\ntype TopoDSWirePointer = Bit.Inputs.OCCT.TopoDSWirePointer;\ntype Point3 = Bit.Inputs.Base.Point3;\ntype Vector3 = Bit.Inputs.Base.Vector3;\n\n// Define the main function\nconst start = async () => {\n // Define grid dimensions\n const gridWidth = 16.5;\n const gridHeight = 9;\n const hexagonsInWidth = 23;\n const hexagonsInHeight = 18;\n\n // Create hexagonal grid parameters\n const hexGridOptions = new HexagonsInGridDto();\n hexGridOptions.width = gridWidth;\n hexGridOptions.height = gridHeight;\n hexGridOptions.nrHexagonsInWidth = hexagonsInWidth;\n hexGridOptions.nrHexagonsInHeight = hexagonsInHeight;\n hexGridOptions.flatTop = false; // Pointed-top hexagons\n hexGridOptions.extendTop = false;\n hexGridOptions.extendBottom = false;\n hexGridOptions.extendLeft = false;\n hexGridOptions.extendRight = false;\n\n // Generate the hexagon grid\n const hexagonWires = await bitbybit.occt.shapes.wire.hexagonsInGrid(hexGridOptions);\n\n // Create a boundary rectangle for reference\n const boundaryOptions = new RectangleDto();\n boundaryOptions.width = gridWidth;\n boundaryOptions.length = gridHeight;\n boundaryOptions.center = [0, 0, 0] as Point3;\n boundaryOptions.direction = [0, 1, 0] as Vector3;\n\n const boundaryWire = await bitbybit.occt.shapes.wire.createRectangleWire(boundaryOptions);\n\n // Draw the hexagon grid and boundary\n bitbybit.draw.drawAnyAsync({ entity: hexagonWires });\n bitbybit.draw.drawAnyAsync({ entity: boundaryWire });\n}\n\n// Execute the function\nstart();","version":"0.21.1","type":"typescript"}} title="Creating hexagon grids" /> diff --git a/docs/learn/code/common/occt/shapes/wire/wire-shape-primitives.md b/docs/learn/code/common/occt/shapes/wire/wire-shape-primitives.md index 86a92a6f..591acaf0 100644 --- a/docs/learn/code/common/occt/shapes/wire/wire-shape-primitives.md +++ b/docs/learn/code/common/occt/shapes/wire/wire-shape-primitives.md @@ -50,21 +50,21 @@ The star wire creates beautiful star-shaped patterns with customizable rays, rad starWirestarWire000010107.83.70FALSEstarWire","version":"0.21.0","type":"blockly"}} + script={{"script":"starWirestarWire000010107.83.70FALSEstarWire","version":"0.21.1","type":"blockly"}} title="Creating basic wire star primitive" /> {\n // Create a star wire with customizable parameters\n const starOptions = new StarDto();\n starOptions.center = [0, 0, 0] as Point3;\n starOptions.direction = [0, 1, 0] as Vector3;\n starOptions.numRays = 10;\n starOptions.outerRadius = 7.8;\n starOptions.innerRadius = 3.7;\n starOptions.offsetOuterEdges = 0;\n starOptions.half = false;\n\n const starWire = await wire.createStarWire(starOptions);\n\n // Draw the created star wire\n bitbybit.draw.drawAnyAsync({ entity: starWire });\n}\n\n// Execute the function\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"// Import required DTOs and types for star wire creation\nconst { StarDto } = Bit.Inputs.OCCT;\ntype Point3 = Bit.Inputs.Base.Point3;\ntype Vector3 = Bit.Inputs.Base.Vector3;\n\n// Get access to OCCT wire creation functions\nconst { wire } = bitbybit.occt.shapes;\n\n// Define the main function to create a star wire\nconst start = async () => {\n // Create a star wire with customizable parameters\n const starOptions = new StarDto();\n starOptions.center = [0, 0, 0] as Point3;\n starOptions.direction = [0, 1, 0] as Vector3;\n starOptions.numRays = 10;\n starOptions.outerRadius = 7.8;\n starOptions.innerRadius = 3.7;\n starOptions.offsetOuterEdges = 0;\n starOptions.half = false;\n\n const starWire = await wire.createStarWire(starOptions);\n\n // Draw the created star wire\n bitbybit.draw.drawAnyAsync({ entity: starWire });\n}\n\n// Execute the function\nstart();","version":"0.21.1","type":"typescript"}} title="Creating basic wire star primitive" /> @@ -86,21 +86,21 @@ The Christmas tree wire creates detailed tree-like structures perfect for season christmasTreeWirechristmasTreeWire61.53511FALSE0000010christmasTreeWire","version":"0.21.0","type":"blockly"}} + script={{"script":"christmasTreeWirechristmasTreeWire61.53511FALSE0000010christmasTreeWire","version":"0.21.1","type":"blockly"}} title="Creating basic wire primitive of christmass tree" /> {\n // Create a Christmas tree wire with customizable parameters\n const treeOptions = new ChristmasTreeDto();\n treeOptions.height = 6;\n treeOptions.innerDist = 1.5;\n treeOptions.outerDist = 3;\n treeOptions.nrSkirts = 5;\n treeOptions.trunkHeight = 1;\n treeOptions.trunkWidth = 1;\n treeOptions.half = false;\n treeOptions.rotation = 0;\n treeOptions.origin = [0, 0, 0] as Point3;\n treeOptions.direction = [0, 1, 0] as Vector3;\n\n const christmasTreeWire = await wire.createChristmasTreeWire(treeOptions);\n\n // Draw the created Christmas tree wire\n bitbybit.draw.drawAnyAsync({ entity: christmasTreeWire });\n}\n\n// Execute the function\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"// Import required DTOs and types for Christmas tree wire creation\nconst { ChristmasTreeDto } = Bit.Inputs.OCCT;\ntype Point3 = Bit.Inputs.Base.Point3;\ntype Vector3 = Bit.Inputs.Base.Vector3;\n\n// Get access to OCCT wire creation functions\nconst { wire } = bitbybit.occt.shapes;\n\n// Define the main function to create a Christmas tree wire\nconst start = async () => {\n // Create a Christmas tree wire with customizable parameters\n const treeOptions = new ChristmasTreeDto();\n treeOptions.height = 6;\n treeOptions.innerDist = 1.5;\n treeOptions.outerDist = 3;\n treeOptions.nrSkirts = 5;\n treeOptions.trunkHeight = 1;\n treeOptions.trunkWidth = 1;\n treeOptions.half = false;\n treeOptions.rotation = 0;\n treeOptions.origin = [0, 0, 0] as Point3;\n treeOptions.direction = [0, 1, 0] as Vector3;\n\n const christmasTreeWire = await wire.createChristmasTreeWire(treeOptions);\n\n // Draw the created Christmas tree wire\n bitbybit.draw.drawAnyAsync({ entity: christmasTreeWire });\n}\n\n// Execute the function\nstart();","version":"0.21.1","type":"typescript"}} title="Creating basic wire primitive of christmass tree" /> @@ -122,21 +122,21 @@ The heart wire creates elegant heart-shaped curves, perfect for decorative appli heartWireheartWire00001008heartWire","version":"0.21.0","type":"blockly"}} + script={{"script":"heartWireheartWire00001008heartWire","version":"0.21.1","type":"blockly"}} title="Creating basic wire primitive of heart" /> {\n // Create a heart wire with customizable parameters\n const heartOptions = new Heart2DDto();\n heartOptions.center = [0, 0, 0] as Point3;\n heartOptions.direction = [0, 1, 0] as Vector3;\n heartOptions.rotation = 0;\n heartOptions.sizeApprox = 8;\n\n const heartWire = await wire.createHeartWire(heartOptions);\n\n // Draw the created heart wire\n bitbybit.draw.drawAnyAsync({ entity: heartWire });\n}\n\n// Execute the function\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"// Import required DTOs and types for heart wire creation\nconst { Heart2DDto } = Bit.Inputs.OCCT;\ntype Point3 = Bit.Inputs.Base.Point3;\ntype Vector3 = Bit.Inputs.Base.Vector3;\n\n// Get access to OCCT wire creation functions\nconst { wire } = bitbybit.occt.shapes;\n\n// Define the main function to create a heart wire\nconst start = async () => {\n // Create a heart wire with customizable parameters\n const heartOptions = new Heart2DDto();\n heartOptions.center = [0, 0, 0] as Point3;\n heartOptions.direction = [0, 1, 0] as Vector3;\n heartOptions.rotation = 0;\n heartOptions.sizeApprox = 8;\n\n const heartWire = await wire.createHeartWire(heartOptions);\n\n // Draw the created heart wire\n bitbybit.draw.drawAnyAsync({ entity: heartWire });\n}\n\n// Execute the function\nstart();","version":"0.21.1","type":"typescript"}} title="Creating basic wire primitive of heart" /> @@ -156,21 +156,21 @@ The L-polygon wire creates precise L-shaped structures essential for architectur lPolygonWirelPolygonWire3537'outside'0000010lPolygonWire","version":"0.21.0","type":"blockly"}} + script={{"script":"lPolygonWirelPolygonWire3537'outside'0000010lPolygonWire","version":"0.21.1","type":"blockly"}} title="Creating basic wire primitive of L polygon" /> {\n // Create an L polygon wire with customizable parameters\n const lPolygonOptions = new LPolygonDto();\n lPolygonOptions.widthFirst = 3;\n lPolygonOptions.lengthFirst = 5;\n lPolygonOptions.widthSecond = 3;\n lPolygonOptions.lengthSecond = 7;\n lPolygonOptions.align = directionEnum.outside;\n lPolygonOptions.rotation = 0;\n lPolygonOptions.center = [0, 0, 0] as Point3;\n lPolygonOptions.direction = [0, 1, 0] as Vector3;\n\n const lPolygonWire = await wire.createLPolygonWire(lPolygonOptions);\n\n // Draw the created L polygon wire\n bitbybit.draw.drawAnyAsync({ entity: lPolygonWire });\n}\n\n// Execute the function\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"// Import required DTOs and types for L polygon wire creation\nconst { LPolygonDto, directionEnum } = Bit.Inputs.OCCT;\ntype Point3 = Bit.Inputs.Base.Point3;\ntype Vector3 = Bit.Inputs.Base.Vector3;\n\n// Get access to OCCT wire creation functions\nconst { wire } = bitbybit.occt.shapes;\n\n// Define the main function to create an L polygon wire\nconst start = async () => {\n // Create an L polygon wire with customizable parameters\n const lPolygonOptions = new LPolygonDto();\n lPolygonOptions.widthFirst = 3;\n lPolygonOptions.lengthFirst = 5;\n lPolygonOptions.widthSecond = 3;\n lPolygonOptions.lengthSecond = 7;\n lPolygonOptions.align = directionEnum.outside;\n lPolygonOptions.rotation = 0;\n lPolygonOptions.center = [0, 0, 0] as Point3;\n lPolygonOptions.direction = [0, 1, 0] as Vector3;\n\n const lPolygonWire = await wire.createLPolygonWire(lPolygonOptions);\n\n // Draw the created L polygon wire\n bitbybit.draw.drawAnyAsync({ entity: lPolygonWire });\n}\n\n// Execute the function\nstart();","version":"0.21.1","type":"typescript"}} title="Creating basic wire primitive of L polygon" /> diff --git a/docs/learn/code/common/occt/shapes/wire/wire-via-points.md b/docs/learn/code/common/occt/shapes/wire/wire-via-points.md index da02562f..91ff5a30 100644 --- a/docs/learn/code/common/occt/shapes/wire/wire-via-points.md +++ b/docs/learn/code/common/occt/shapes/wire/wire-via-points.md @@ -75,21 +75,21 @@ This example demonstrates all major methods for creating wires from points, show point1point2point3point4point5pointsListlineWirepolylineWirepolygonWireinterpolatedWireinterpolatedPeriodicWirebezierWirebsplineWirepoint1-400point2-201point300-1point4202point5400pointsListpoint1point2point3point4point5lineWirepoint1point5polylineWirepointsList010polygonWirepointsList020interpolatedWirepointsListFALSE1e-7030interpolatedPeriodicWirepointsListTRUE1e-7040bezierWirepointsList050bsplineWirepointsListFALSE3060lineWirepolylineWirepolygonWireinterpolatedWireinterpolatedPeriodicWirebezierWirebsplineWire","version":"0.21.0","type":"blockly"}} + script={{"script":"point1point2point3point4point5pointsListlineWirepolylineWirepolygonWireinterpolatedWireinterpolatedPeriodicWirebezierWirebsplineWirepoint1-400point2-201point300-1point4202point5400pointsListpoint1point2point3point4point5lineWirepoint1point5polylineWirepointsList010polygonWirepointsList020interpolatedWirepointsListFALSE1e-7030interpolatedPeriodicWirepointsListTRUE1e-7040bezierWirepointsList050bsplineWirepointsListFALSE3060lineWirepolylineWirepolygonWireinterpolatedWireinterpolatedPeriodicWirebezierWirebsplineWire","version":"0.21.1","type":"blockly"}} title="Comprehensive wire creation from points" /> {\n // Define a set of control points for wire creation\n const points: Point3[] = [\n [-4, 0, 0], // Start point\n [-2, 0, 1], // First control point\n [0, 0, -1], // Second control point\n [2, 0, 2], // Third control point\n [4, 0, 0] // End point\n ];\n\n // 1. Create a simple line wire between first and last points\n const lineOptions = new LineDto();\n lineOptions.start = points[0];\n lineOptions.end = points[4];\n const lineWire = await wire.createLineWire(lineOptions);\n\n // 2. Create a polyline wire connecting all points with straight segments\n const polylineOptions = new PolylineDto();\n polylineOptions.points = points;\n const polylineWire = await wire.createPolylineWire(polylineOptions);\n\n // 3. Create a polygon wire (closed shape) from the points\n const polygonOptions = new PolygonDto();\n polygonOptions.points = points;\n const polygonWire = await wire.createPolygonWire(polygonOptions);\n\n // 4. Create an interpolated wire that passes smoothly through all points\n const interpolationOptions = new InterpolationDto();\n interpolationOptions.points = points;\n interpolationOptions.periodic = false;\n interpolationOptions.tolerance = 1e-7;\n const interpolatedWire = await wire.interpolatePoints(interpolationOptions);\n\n // 5. Create an interpolated periodic wire that creates a closed smooth curve\n const interpolationPeriodicOptions = new InterpolationDto();\n interpolationPeriodicOptions.points = points;\n interpolationPeriodicOptions.periodic = true;\n interpolationPeriodicOptions.tolerance = 1e-7;\n const interpolatedPeriodicWire = await wire.interpolatePoints(interpolationPeriodicOptions);\n\n // 6. Create a Bezier curve using points as control points\n const bezierOptions = new BezierDto();\n bezierOptions.points = points;\n bezierOptions.closed = false;\n const bezierWire = await wire.createBezier(bezierOptions);\n\n // 7. Create a BSpline curve with specified degree\n const bsplineOptions = new BSplineDto();\n bsplineOptions.points = points;\n bsplineOptions.closed = false;\n const bsplineWire = await wire.createBSpline(bsplineOptions);\n\n // Translate wires to different Y positions for better visualization\n const translateOptions = new TranslateDto();\n\n // Translate polyline\n translateOptions.shape = polylineWire;\n translateOptions.translation = [0, 1, 0] as Vector3;\n const translatedPolyline = await transforms.translate(translateOptions);\n\n // Translate polygon\n translateOptions.shape = polygonWire;\n translateOptions.translation = [0, 2, 0] as Vector3;\n const translatedPolygon = await transforms.translate(translateOptions);\n\n // Translate interpolated wire\n translateOptions.shape = interpolatedWire;\n translateOptions.translation = [0, 3, 0] as Vector3;\n const translatedInterpolated = await transforms.translate(translateOptions);\n\n // Translate interpolated periodic wire\n translateOptions.shape = interpolatedPeriodicWire;\n translateOptions.translation = [0, 4, 0] as Vector3;\n const translatedInterpolatedPeriodic = await transforms.translate(translateOptions);\n\n // Translate Bezier wire\n translateOptions.shape = bezierWire;\n translateOptions.translation = [0, 5, 0] as Vector3;\n const translatedBezier = await transforms.translate(translateOptions);\n\n // Translate BSpline wire\n translateOptions.shape = bsplineWire;\n translateOptions.translation = [0, 6, 0] as Vector3;\n const translatedBSpline = await transforms.translate(translateOptions);\n\n // Draw all the created wires\n bitbybit.draw.drawAnyAsync({ entity: lineWire });\n bitbybit.draw.drawAnyAsync({ entity: translatedPolyline });\n bitbybit.draw.drawAnyAsync({ entity: translatedPolygon });\n bitbybit.draw.drawAnyAsync({ entity: translatedInterpolated });\n bitbybit.draw.drawAnyAsync({ entity: translatedInterpolatedPeriodic });\n bitbybit.draw.drawAnyAsync({ entity: translatedBezier });\n bitbybit.draw.drawAnyAsync({ entity: translatedBSpline });\n}\n\n// Execute the function\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"// Import required DTOs and types for wire creation\nconst { LineDto, PolylineDto, PolygonDto, InterpolationDto, BezierDto, BSplineDto, TranslateDto } = Bit.Inputs.OCCT;\ntype Point3 = Bit.Inputs.Base.Point3;\ntype Vector3 = Bit.Inputs.Base.Vector3;\ntype TopoDSShapePointer = Bit.Inputs.OCCT.TopoDSShapePointer;\n\n// Get access to OCCT wire creation and transform functions\nconst { wire } = bitbybit.occt.shapes;\nconst { transforms } = bitbybit.occt;\n\n// Define the main function to demonstrate various wire creation methods\nconst start = async () => {\n // Define a set of control points for wire creation\n const points: Point3[] = [\n [-4, 0, 0], // Start point\n [-2, 0, 1], // First control point\n [0, 0, -1], // Second control point\n [2, 0, 2], // Third control point\n [4, 0, 0] // End point\n ];\n\n // 1. Create a simple line wire between first and last points\n const lineOptions = new LineDto();\n lineOptions.start = points[0];\n lineOptions.end = points[4];\n const lineWire = await wire.createLineWire(lineOptions);\n\n // 2. Create a polyline wire connecting all points with straight segments\n const polylineOptions = new PolylineDto();\n polylineOptions.points = points;\n const polylineWire = await wire.createPolylineWire(polylineOptions);\n\n // 3. Create a polygon wire (closed shape) from the points\n const polygonOptions = new PolygonDto();\n polygonOptions.points = points;\n const polygonWire = await wire.createPolygonWire(polygonOptions);\n\n // 4. Create an interpolated wire that passes smoothly through all points\n const interpolationOptions = new InterpolationDto();\n interpolationOptions.points = points;\n interpolationOptions.periodic = false;\n interpolationOptions.tolerance = 1e-7;\n const interpolatedWire = await wire.interpolatePoints(interpolationOptions);\n\n // 5. Create an interpolated periodic wire that creates a closed smooth curve\n const interpolationPeriodicOptions = new InterpolationDto();\n interpolationPeriodicOptions.points = points;\n interpolationPeriodicOptions.periodic = true;\n interpolationPeriodicOptions.tolerance = 1e-7;\n const interpolatedPeriodicWire = await wire.interpolatePoints(interpolationPeriodicOptions);\n\n // 6. Create a Bezier curve using points as control points\n const bezierOptions = new BezierDto();\n bezierOptions.points = points;\n bezierOptions.closed = false;\n const bezierWire = await wire.createBezier(bezierOptions);\n\n // 7. Create a BSpline curve with specified degree\n const bsplineOptions = new BSplineDto();\n bsplineOptions.points = points;\n bsplineOptions.closed = false;\n const bsplineWire = await wire.createBSpline(bsplineOptions);\n\n // Translate wires to different Y positions for better visualization\n const translateOptions = new TranslateDto();\n\n // Translate polyline\n translateOptions.shape = polylineWire;\n translateOptions.translation = [0, 1, 0] as Vector3;\n const translatedPolyline = await transforms.translate(translateOptions);\n\n // Translate polygon\n translateOptions.shape = polygonWire;\n translateOptions.translation = [0, 2, 0] as Vector3;\n const translatedPolygon = await transforms.translate(translateOptions);\n\n // Translate interpolated wire\n translateOptions.shape = interpolatedWire;\n translateOptions.translation = [0, 3, 0] as Vector3;\n const translatedInterpolated = await transforms.translate(translateOptions);\n\n // Translate interpolated periodic wire\n translateOptions.shape = interpolatedPeriodicWire;\n translateOptions.translation = [0, 4, 0] as Vector3;\n const translatedInterpolatedPeriodic = await transforms.translate(translateOptions);\n\n // Translate Bezier wire\n translateOptions.shape = bezierWire;\n translateOptions.translation = [0, 5, 0] as Vector3;\n const translatedBezier = await transforms.translate(translateOptions);\n\n // Translate BSpline wire\n translateOptions.shape = bsplineWire;\n translateOptions.translation = [0, 6, 0] as Vector3;\n const translatedBSpline = await transforms.translate(translateOptions);\n\n // Draw all the created wires\n bitbybit.draw.drawAnyAsync({ entity: lineWire });\n bitbybit.draw.drawAnyAsync({ entity: translatedPolyline });\n bitbybit.draw.drawAnyAsync({ entity: translatedPolygon });\n bitbybit.draw.drawAnyAsync({ entity: translatedInterpolated });\n bitbybit.draw.drawAnyAsync({ entity: translatedInterpolatedPeriodic });\n bitbybit.draw.drawAnyAsync({ entity: translatedBezier });\n bitbybit.draw.drawAnyAsync({ entity: translatedBSpline });\n}\n\n// Execute the function\nstart();","version":"0.21.1","type":"typescript"}} title="Comprehensive wire creation from points" /> diff --git a/docs/learn/getting-started/basics/assets/local/gltf.mdx b/docs/learn/getting-started/basics/assets/local/gltf.mdx index 324ca090..ea66dba1 100644 --- a/docs/learn/getting-started/basics/assets/local/gltf.mdx +++ b/docs/learn/getting-started/basics/assets/local/gltf.mdx @@ -59,7 +59,7 @@ Your Rete graph should now look similar to the setup in the embedded editor belo **Rete Editor Example:** @@ -101,7 +101,7 @@ After assembling the blocks, click "Run". You should see the BoomBox model. **Blockly Editor Example:** TRUEBoomBoxFALSE","version":"0.21.0","type":"blockly"}} + script={{"script":"TRUEBoomBoxFALSE","version":"0.21.1","type":"blockly"}} title="Bitbybit Blockly Editor - Using Local glTF Asset" description="Upload local asset from tutorial named accordingly and it will appear in 3D scene after you hit run." /> @@ -126,7 +126,7 @@ Here's the example code, which should be fairly self-explanatory for those famil **TypeScript Editor Example:** {\n bitbybit.babylon.scene.useRightHandedSystem({\n use: true,\n });\n const file = await bitbybit.asset.getLocalFile({\n fileName: \"BoomBox\"\n }) as File;\n await bitbybit.babylon.io.loadAssetIntoScene({\n assetFile: file,\n hidden: false\n });\n}\n\nstart();\n","version":"0.21.0","type":"typescript"}} + script={{"script":"const start = async () => {\n bitbybit.babylon.scene.useRightHandedSystem({\n use: true,\n });\n const file = await bitbybit.asset.getLocalFile({\n fileName: \"BoomBox\"\n }) as File;\n await bitbybit.babylon.io.loadAssetIntoScene({\n assetFile: file,\n hidden: false\n });\n}\n\nstart();\n","version":"0.21.1","type":"typescript"}} title="Bitbybit Blockly Editor - Using Local glTF Asset" description="Upload local asset from tutorial named accordingly and it will appear in 3D scene after you hit run." /> diff --git a/docs/learn/getting-started/basics/assets/local/step.mdx b/docs/learn/getting-started/basics/assets/local/step.mdx index 2dc2d9cf..f3502740 100644 --- a/docs/learn/getting-started/basics/assets/local/step.mdx +++ b/docs/learn/getting-started/basics/assets/local/step.mdx @@ -54,7 +54,7 @@ That's it! Your Rete graph should be set up. It might take a moment for the Kuka **Rete Editor Example:** @@ -95,7 +95,7 @@ After assembling the blocks, click "Run". **Blockly Editor Example:** KukaRobotTRUE","version":"0.21.0","type":"blockly"}} + script={{"script":"KukaRobotTRUE","version":"0.21.1","type":"blockly"}} title="Bitbybit Blockly Editor - Using Local STEP Asset" description="Upload local asset from tutorial named accordingly and it will appear in 3D scene after you hit run." /> @@ -122,7 +122,7 @@ Here's an example of how to do that: **TypeScript Editor Example:** {\n\n const file = await bitbybit.asset.getLocalFile({\n fileName: \"KukaRobot\"\n }) as File;\n\n const shape = await bitbybit.occt.io.loadSTEPorIGES({\n assetFile: file,\n adjustZtoY: true,\n });\n\n bitbybit.draw.drawAnyAsync({\n entity: shape\n })\n}\n\nstart();\n","version":"0.21.0","type":"typescript"}} + script={{"script":"const start = async () => {\n\n const file = await bitbybit.asset.getLocalFile({\n fileName: \"KukaRobot\"\n }) as File;\n\n const shape = await bitbybit.occt.io.loadSTEPorIGES({\n assetFile: file,\n adjustZtoY: true,\n });\n\n bitbybit.draw.drawAnyAsync({\n entity: shape\n })\n}\n\nstart();\n","version":"0.21.1","type":"typescript"}} title="Bitbybit TypeScript Editor - Using Local STEP Asset" description="Upload local asset from tutorial named accordingly and it will appear in 3D scene after you hit run." /> diff --git a/docs/learn/getting-started/blockly/hello-world.mdx b/docs/learn/getting-started/blockly/hello-world.mdx index 45eaae9e..88e3bb4a 100644 --- a/docs/learn/getting-started/blockly/hello-world.mdx +++ b/docs/learn/getting-started/blockly/hello-world.mdx @@ -56,7 +56,7 @@ Your setup should resemble this interactive example: Hello World!'Aboreto''Regular'1.50.20000010'leftTop'","version":"0.21.0","type":"blockly"}} + script={{"script":"Hello World!'Aboreto''Regular'1.50.20000010'leftTop'","version":"0.21.1","type":"blockly"}} title="Draw 3D Text" description="Draws the text on the screen." /> @@ -88,7 +88,7 @@ After completing these steps, your Blockly script should look similar to this: 40040010100.450.50.5FALSE#ffffff#ffffffHello World!'Roboto''Regular'1.50.2-9000000-1'centerBottom'","version":"0.21.0","type":"blockly"}} + script={{"script":"40040010100.450.50.5FALSE#ffffff#ffffffHello World!'Roboto''Regular'1.50.2-9000000-1'centerBottom'","version":"0.21.1","type":"blockly"}} title="Draw 3D text and grid" description="Draws 3D text and the grid on the screen. Text is placed in better orientation." /> diff --git a/docs/learn/getting-started/blockly/parametric-cube.mdx b/docs/learn/getting-started/blockly/parametric-cube.mdx index c8dfadb4..0db3dbd9 100644 --- a/docs/learn/getting-started/blockly/parametric-cube.mdx +++ b/docs/learn/getting-started/blockly/parametric-cube.mdx @@ -69,7 +69,7 @@ Your Blockly workspace should now look something like this interactive example: sizesize3size000","version":"0.21.0","type":"blockly"}} + script={{"script":"sizesize3size000","version":"0.21.1","type":"blockly"}} title="Parametric cube example" description="Draws the parametrically controlled cube." /> diff --git a/docs/learn/getting-started/rete/hello-world.mdx b/docs/learn/getting-started/rete/hello-world.mdx index 30dd5e63..7dc147f9 100644 --- a/docs/learn/getting-started/rete/hello-world.mdx +++ b/docs/learn/getting-started/rete/hello-world.mdx @@ -41,7 +41,7 @@ If you've done it correctly, your canvas should have the "Draw Grid Mesh" compon @@ -79,7 +79,7 @@ The setup should resemble this: @@ -109,7 +109,7 @@ Here's the final result you should aim for: diff --git a/docs/learn/getting-started/rete/parametric-cube.mdx b/docs/learn/getting-started/rete/parametric-cube.mdx index 16e6073e..a66d79d7 100644 --- a/docs/learn/getting-started/rete/parametric-cube.mdx +++ b/docs/learn/getting-started/rete/parametric-cube.mdx @@ -44,7 +44,7 @@ We'll use the OpenCascade Technology (OCCT) geometry kernel to create our cube. @@ -69,7 +69,7 @@ If you've connected them correctly, your setup should resemble the following int diff --git a/docs/learn/getting-started/typescript/hello-world.mdx b/docs/learn/getting-started/typescript/hello-world.mdx index 0268ef33..6d7c7c1f 100644 --- a/docs/learn/getting-started/typescript/hello-world.mdx +++ b/docs/learn/getting-started/typescript/hello-world.mdx @@ -26,7 +26,7 @@ Check out the script below: {\n const gridOptions = new Bit.Inputs.Draw.SceneDrawGridMeshDto();\n bitbybit.draw.drawGridMesh(gridOptions);\n}\n\nstart();\n","version":"0.21.0","type":"typescript"}} + script={{"script":"const start = async () => {\n const gridOptions = new Bit.Inputs.Draw.SceneDrawGridMeshDto();\n bitbybit.draw.drawGridMesh(gridOptions);\n}\n\nstart();\n","version":"0.21.1","type":"typescript"}} title="Draw the grid" description="Draws the grid mesh with lines in 3D space." /> @@ -51,7 +51,7 @@ The script below shows a working example. We've set the `rotation` to -90 degree {\n const gridOptions = new Bit.Inputs.Draw.SceneDrawGridMeshDto();\n bitbybit.draw.drawGridMesh(gridOptions);\n\n const textOpt = new Bit.Advanced.Text3D.Text3DDto();\n textOpt.text = \"Hello World!\";\n textOpt.rotation = -90;\n textOpt.originAlignment = Bit.Advanced.Text3D.recAlignmentEnum.centerBottom;\n textOpt.direction = [0, 0, -1];\n const text3D = await bitbybit.advanced.text3d.create(textOpt);\n\n bitbybit.draw.drawAnyAsync({\n entity: text3D\n });\n}\n\nstart();\n","version":"0.21.0","type":"typescript"}} + script={{"script":"const start = async () => {\n const gridOptions = new Bit.Inputs.Draw.SceneDrawGridMeshDto();\n bitbybit.draw.drawGridMesh(gridOptions);\n\n const textOpt = new Bit.Advanced.Text3D.Text3DDto();\n textOpt.text = \"Hello World!\";\n textOpt.rotation = -90;\n textOpt.originAlignment = Bit.Advanced.Text3D.recAlignmentEnum.centerBottom;\n textOpt.direction = [0, 0, -1];\n const text3D = await bitbybit.advanced.text3d.create(textOpt);\n\n bitbybit.draw.drawAnyAsync({\n entity: text3D\n });\n}\n\nstart();\n","version":"0.21.1","type":"typescript"}} title="Draw the text & grid" description="Draws the grid mesh with text in 3D space." /> diff --git a/docs/learn/getting-started/typescript/how-to-code-in-monaco.md b/docs/learn/getting-started/typescript/how-to-code-in-monaco.md index 997b0b99..aee076b9 100644 --- a/docs/learn/getting-started/typescript/how-to-code-in-monaco.md +++ b/docs/learn/getting-started/typescript/how-to-code-in-monaco.md @@ -197,7 +197,7 @@ start(); {\n // Step 3a: Create input objects (DTOs) and set their properties for a cube\n const cubeOptions = new CubeDto(); // Instantiate the DTO\n cubeOptions.size = 6; // Set the cube's size\n // Call the bitbybit function to create the cube, awaiting its promise\n const cube: TopoDSShapePointer = await solid.createCube(cubeOptions);\n\n // Step 3b: Create input objects (DTOs) for a sphere\n const sphereOptions = new SphereDto();\n sphereOptions.radius = 3;\n sphereOptions.center = [3, 3, -3]; // Define center as [x, y, z] coordinates\n const sphere: TopoDSShapePointer = await solid.createSphere(sphereOptions);\n\n // Step 4: Perform geometric operations\n // Example: Boolean difference (subtract sphere from cube)\n const diffOptions = new DifferenceDto(); // Generic type for the shapes involved\n diffOptions.shape = cube; // The base shape\n diffOptions.shapes = [sphere]; // An array of shapes to subtract\n const diff: TopoDSShapePointer = await booleans.difference(diffOptions);\n\n // Example: Apply fillets (round edges) to the result of the difference\n const roundingOptions = new FilletDto();\n roundingOptions.shape = diff; // The shape to fillet\n roundingOptions.radius = 1; // The radius of the fillet\n // Note: Some operations might have specific methods like 'filletEdges' for common tasks\n const solidRoundedCorners: TopoDSShapePointer = await fillets.filletEdges(roundingOptions);\n\n // Step 5: Visualize the result in the 3D viewer\n // Prepare drawing options to customize appearance\n const occtDrawOptions = new DrawOcctShapeOptions();\n occtDrawOptions.faceColour = \"#0000ff\"; // Blue faces\n occtDrawOptions.edgeColour = \"#ff00ff\"; // Magenta edges\n occtDrawOptions.edgeWidth = 5; // Width of the edges\n occtDrawOptions.precision = 0.001; // Rendering precision for complex shapes (lower is finer)\n // Draw the final shape. 'drawAnyAsync' is a versatile function for drawing various entity types.\n draw.drawAnyAsync({ entity: solidRoundedCorners, options: occtDrawOptions });\n\n // Step 6: (Optional) Adjust scene elements like lighting for better visualization\n const dirLight = new DirectionalLightDto();\n dirLight.shadowGeneratorMapSize = 2000; // Higher values for better shadow quality\n dirLight.intensity = 3; // Light intensity\n scene.drawDirectionalLight(dirLight); // Adds or updates a directional light in the scene\n\n // Step 7: (Optional) Export your model to common CAD file formats\n // Export as STEP file (a common format for solid models)\n const stepExportOptions = new SaveStepDto();\n stepExportOptions.shape = solidRoundedCorners;\n stepExportOptions.adjustYtoZ = true; // Optional: Adjusts coordinate system (Y-up to Z-up) if needed\n stepExportOptions.fileName = \"cube_with_sphere_cutout.step\";\n stepExportOptions.tryDownload = true; // Attempts to trigger a browser download of the file\n await io.saveShapeSTEP(stepExportOptions); // Use the destructured 'io'\n\n // Export as STL file (a common format for 3D printing)\n const stlExportOptions = new SaveStlDto();\n stlExportOptions.shape = solidRoundedCorners;\n stlExportOptions.adjustYtoZ = true;\n stlExportOptions.fileName = \"cube_with_sphere_cutout.stl\";\n stlExportOptions.precision = 0.001; // Affects STL mesh quality (smaller values for finer mesh)\n stlExportOptions.tryDownload = true;\n await io.saveShapeStl(stlExportOptions); // Use the destructured 'io'\n};\n\n// Step 8: Call the start function to execute your script\nstart();","version":"0.21.0","type":"typescript"}} + script={{"script":"// Step 1: (Optional but Recommended) Destructure for convenience\n// This makes your code less verbose and easier to read.\nconst { solid } = bitbybit.occt.shapes;\nconst { booleans, fillets, io } = bitbybit.occt; // Added 'io' for export functions\nconst { draw } = bitbybit;\nconst { scene } = bitbybit.babylon;\n\n// Step 2: Import type definitions for input objects and shapes\n// This enables type checking and autocompletion.\ntype TopoDSShapePointer = Bit.Inputs.OCCT.TopoDSShapePointer; // Represents an OCCT shape\n\nconst { CubeDto, SphereDto, FilletDto, DifferenceDto, SaveStepDto, SaveStlDto } = Bit.Inputs.OCCT;\nconst DrawOcctShapeOptions = Bit.Inputs.Draw.DrawOcctShapeOptions;\nconst DirectionalLightDto = Bit.Inputs.BabylonScene.DirectionalLightDto;\n\n// Step 3: Define your main logic within an async function\nconst start = async () => {\n // Step 3a: Create input objects (DTOs) and set their properties for a cube\n const cubeOptions = new CubeDto(); // Instantiate the DTO\n cubeOptions.size = 6; // Set the cube's size\n // Call the bitbybit function to create the cube, awaiting its promise\n const cube: TopoDSShapePointer = await solid.createCube(cubeOptions);\n\n // Step 3b: Create input objects (DTOs) for a sphere\n const sphereOptions = new SphereDto();\n sphereOptions.radius = 3;\n sphereOptions.center = [3, 3, -3]; // Define center as [x, y, z] coordinates\n const sphere: TopoDSShapePointer = await solid.createSphere(sphereOptions);\n\n // Step 4: Perform geometric operations\n // Example: Boolean difference (subtract sphere from cube)\n const diffOptions = new DifferenceDto(); // Generic type for the shapes involved\n diffOptions.shape = cube; // The base shape\n diffOptions.shapes = [sphere]; // An array of shapes to subtract\n const diff: TopoDSShapePointer = await booleans.difference(diffOptions);\n\n // Example: Apply fillets (round edges) to the result of the difference\n const roundingOptions = new FilletDto();\n roundingOptions.shape = diff; // The shape to fillet\n roundingOptions.radius = 1; // The radius of the fillet\n // Note: Some operations might have specific methods like 'filletEdges' for common tasks\n const solidRoundedCorners: TopoDSShapePointer = await fillets.filletEdges(roundingOptions);\n\n // Step 5: Visualize the result in the 3D viewer\n // Prepare drawing options to customize appearance\n const occtDrawOptions = new DrawOcctShapeOptions();\n occtDrawOptions.faceColour = \"#0000ff\"; // Blue faces\n occtDrawOptions.edgeColour = \"#ff00ff\"; // Magenta edges\n occtDrawOptions.edgeWidth = 5; // Width of the edges\n occtDrawOptions.precision = 0.001; // Rendering precision for complex shapes (lower is finer)\n // Draw the final shape. 'drawAnyAsync' is a versatile function for drawing various entity types.\n draw.drawAnyAsync({ entity: solidRoundedCorners, options: occtDrawOptions });\n\n // Step 6: (Optional) Adjust scene elements like lighting for better visualization\n const dirLight = new DirectionalLightDto();\n dirLight.shadowGeneratorMapSize = 2000; // Higher values for better shadow quality\n dirLight.intensity = 3; // Light intensity\n scene.drawDirectionalLight(dirLight); // Adds or updates a directional light in the scene\n\n // Step 7: (Optional) Export your model to common CAD file formats\n // Export as STEP file (a common format for solid models)\n const stepExportOptions = new SaveStepDto();\n stepExportOptions.shape = solidRoundedCorners;\n stepExportOptions.adjustYtoZ = true; // Optional: Adjusts coordinate system (Y-up to Z-up) if needed\n stepExportOptions.fileName = \"cube_with_sphere_cutout.step\";\n stepExportOptions.tryDownload = true; // Attempts to trigger a browser download of the file\n await io.saveShapeSTEP(stepExportOptions); // Use the destructured 'io'\n\n // Export as STL file (a common format for 3D printing)\n const stlExportOptions = new SaveStlDto();\n stlExportOptions.shape = solidRoundedCorners;\n stlExportOptions.adjustYtoZ = true;\n stlExportOptions.fileName = \"cube_with_sphere_cutout.stl\";\n stlExportOptions.precision = 0.001; // Affects STL mesh quality (smaller values for finer mesh)\n stlExportOptions.tryDownload = true;\n await io.saveShapeStl(stlExportOptions); // Use the destructured 'io'\n};\n\n// Step 8: Call the start function to execute your script\nstart();","version":"0.21.1","type":"typescript"}} title="Create And Download STEP & STL 3D Models" description="Contains example code that can be executed directly inside the editor by clicking Run button." /> diff --git a/docs/learn/getting-started/typescript/parametric-cube.mdx b/docs/learn/getting-started/typescript/parametric-cube.mdx index aae81a37..90012bd6 100644 --- a/docs/learn/getting-started/typescript/parametric-cube.mdx +++ b/docs/learn/getting-started/typescript/parametric-cube.mdx @@ -35,7 +35,7 @@ The script shown in the editor below is fairly straightforward, but let's break {\n const size = 10;\n const cubeOptions = new Bit.Inputs.OCCT.CubeDto();\n cubeOptions.size = size;\n const cube = await bitbybit.occt.shapes.solid.createCube(cubeOptions);\n\n bitbybit.draw.drawAnyAsync({\n entity: cube\n });\n}\n\nstart();\n","version":"0.21.0","type":"typescript"}} + script={{"script":"const start = async () => {\n const size = 10;\n const cubeOptions = new Bit.Inputs.OCCT.CubeDto();\n cubeOptions.size = size;\n const cube = await bitbybit.occt.shapes.solid.createCube(cubeOptions);\n\n bitbybit.draw.drawAnyAsync({\n entity: cube\n });\n}\n\nstart();\n","version":"0.21.1","type":"typescript"}} title="Draw the grid" description="Draws the grid mesh with lines in 3D space." /> diff --git a/docs/learn/getting-started/viewer-editor/basics/getting-started.md b/docs/learn/getting-started/viewer-editor/basics/getting-started.md index 5f06fd4d..38979895 100644 --- a/docs/learn/getting-started/viewer-editor/basics/getting-started.md +++ b/docs/learn/getting-started/viewer-editor/basics/getting-started.md @@ -139,7 +139,7 @@ When you export, you get JSON like this: ```json { - "$schema": "https://app-store.bitbybit.dev/files/ecommerce/viewer-editor/viewer-scene-schema-v0.21.0.json", + "$schema": "https://app-store.bitbybit.dev/files/ecommerce/viewer-editor/viewer-scene-schema-v0.21.1.json", "models": [ { "name": "Main Product", diff --git a/docs/learn/getting-started/viewer-editor/basics/overview.md b/docs/learn/getting-started/viewer-editor/basics/overview.md index 22956577..c8382ca2 100644 --- a/docs/learn/getting-started/viewer-editor/basics/overview.md +++ b/docs/learn/getting-started/viewer-editor/basics/overview.md @@ -78,7 +78,7 @@ For Shopify users, see [Subscription Plans](../../../3d-bits/plans/subscription- ## Generated Output -The Viewer Editor generates valid JSON that conforms to the [**Viewer Scene Schema**](https://app-store.bitbybit.dev/files/ecommerce/viewer-editor/viewer-scene-schema-v0.21.0.json). This JSON can be: +The Viewer Editor generates valid JSON that conforms to the [**Viewer Scene Schema**](https://app-store.bitbybit.dev/files/ecommerce/viewer-editor/viewer-scene-schema-v0.21.1.json). This JSON can be: - Copied to clipboard and pasted into Shopify product metafields - Downloaded as a file and hosted on your CDN diff --git a/docs/learn/npm-packages/babylonjs/start-with-babylon-js.md b/docs/learn/npm-packages/babylonjs/start-with-babylon-js.md index 32fc38cf..92de0ce3 100644 --- a/docs/learn/npm-packages/babylonjs/start-with-babylon-js.md +++ b/docs/learn/npm-packages/babylonjs/start-with-babylon-js.md @@ -159,7 +159,7 @@ const init = async () => { // This CDN link provides a hosted version. // For production, you might want to host this yourself. locateFile: () => { - return 'https://cdn.jsdelivr.net/gh/bitbybit-dev/bitbybit-assets@0.21.0/wasm/manifold-3-3-2.wasm'; + return 'https://cdn.jsdelivr.net/gh/bitbybit-dev/bitbybit-assets@0.21.1/wasm/manifold-3-3-2.wasm'; }, }); wasm.setup(); // Additional setup step for Manifold diff --git a/docs/learn/npm-packages/playcanvas/start-with-playcanvas.md b/docs/learn/npm-packages/playcanvas/start-with-playcanvas.md index 4e3efa4f..940f0b46 100644 --- a/docs/learn/npm-packages/playcanvas/start-with-playcanvas.md +++ b/docs/learn/npm-packages/playcanvas/start-with-playcanvas.md @@ -159,7 +159,7 @@ const init = async () => { // This CDN link provides a hosted version. // For production, you might want to host this yourself. locateFile: () => { - return 'https://cdn.jsdelivr.net/gh/bitbybit-dev/bitbybit-assets@0.21.0/wasm/manifold-3-3-2.wasm'; + return 'https://cdn.jsdelivr.net/gh/bitbybit-dev/bitbybit-assets@0.21.1/wasm/manifold-3-3-2.wasm'; }, }); wasm.setup(); // Additional setup step for Manifold diff --git a/docs/learn/npm-packages/threejs/start-with-three-js.md b/docs/learn/npm-packages/threejs/start-with-three-js.md index e8ecc821..675249a9 100644 --- a/docs/learn/npm-packages/threejs/start-with-three-js.md +++ b/docs/learn/npm-packages/threejs/start-with-three-js.md @@ -159,7 +159,7 @@ const init = async () => { // This CDN link provides a hosted version. // For production, you might want to host this yourself. locateFile: () => { - return 'https://cdn.jsdelivr.net/gh/bitbybit-dev/bitbybit-assets@0.21.0/wasm/manifold-3-3-2.wasm'; + return 'https://cdn.jsdelivr.net/gh/bitbybit-dev/bitbybit-assets@0.21.1/wasm/manifold-3-3-2.wasm'; }, }); wasm.setup(); // Additional setup step for Manifold diff --git a/docs/learn/runners/intro-blockly.mdx b/docs/learn/runners/intro-blockly.mdx index 48e3e04b..ea6f0b03 100644 --- a/docs/learn/runners/intro-blockly.mdx +++ b/docs/learn/runners/intro-blockly.mdx @@ -48,7 +48,7 @@ The following Bitbybit Blockly script is the visual program we'll be creating. T sizecubeMeshsizesizesizesize1cubeMeshsize0000.40.005TRUE#000099TRUE#ffffff1cubeMeshcubeMesh","version":"0.21.0","type":"blockly"}} + script={{"script":"sizecubeMeshsizesizesizesize1cubeMeshsize0000.40.005TRUE#000099TRUE#ffffff1cubeMeshcubeMesh","version":"0.21.1","type":"blockly"}} title="Bitbybit Blockly Editor - Simple Cube for Runner Tutorial" description="Draws 3D Cube and controls its size via inputs coming from external executing program" /> @@ -68,7 +68,7 @@ Below are the `index.html` and `script.js` files you would use on StackBlitz or - + diff --git a/docs/learn/runners/intro-rete.mdx b/docs/learn/runners/intro-rete.mdx index 592a86d4..9e8d5a4e 100644 --- a/docs/learn/runners/intro-rete.mdx +++ b/docs/learn/runners/intro-rete.mdx @@ -51,7 +51,7 @@ The following Bitbybit Rete script is the visual program we'll be creating. The diff --git a/docs/learn/runners/intro-typescript.mdx b/docs/learn/runners/intro-typescript.mdx index ac365a39..4fe9768e 100644 --- a/docs/learn/runners/intro-typescript.mdx +++ b/docs/learn/runners/intro-typescript.mdx @@ -46,7 +46,7 @@ The following is the Bitbybit TypeScript script we'll be creating. The JavaScrip {\n const cube = await occt.shapes.solid.createCube({\n size: inputs.size,\n center: [0, 0, 0],\n });\n const filletCube = await occt.fillets.filletEdges({\n shape: cube,\n radius: 0.4\n });\n const drawOptions = new Bit.Inputs.Draw.DrawOcctShapeSimpleOptions();\n drawOptions.faceColour = \"#0000ff\";\n drawOptions.edgeWidth = 1;\n drawOptions.precision = 0.005;\n const cubeMesh = await bitbybit.draw.drawAnyAsync({\n entity: filletCube,\n options: drawOptions,\n });\n return { cubeMesh };\n}\n\nconst runnerOutput = start();\nBit.setBitbybitRunnerResult(runnerOutput);\n","version":"0.21.0","type":"typescript"}} + script={{"script":"type Inputs = {\n size: number;\n}\n\nBit.mockBitbybitRunnerInputs({ size: 1 });\nconst inputs: Inputs = Bit.getBitbybitRunnerInputs();\n\nconst { occt } = bitbybit;\n\nconst start = async () => {\n const cube = await occt.shapes.solid.createCube({\n size: inputs.size,\n center: [0, 0, 0],\n });\n const filletCube = await occt.fillets.filletEdges({\n shape: cube,\n radius: 0.4\n });\n const drawOptions = new Bit.Inputs.Draw.DrawOcctShapeSimpleOptions();\n drawOptions.faceColour = \"#0000ff\";\n drawOptions.edgeWidth = 1;\n drawOptions.precision = 0.005;\n const cubeMesh = await bitbybit.draw.drawAnyAsync({\n entity: filletCube,\n options: drawOptions,\n });\n return { cubeMesh };\n}\n\nconst runnerOutput = start();\nBit.setBitbybitRunnerResult(runnerOutput);\n","version":"0.21.1","type":"typescript"}} title="Bitbybit TypeScript Editor - Simple Cube for Runner Tutorial" description="Draws 3D Cube and controls its size via inputs coming from external executing program" /> diff --git a/docs/learn/runners/live-examples/configurable-cad-part.mdx b/docs/learn/runners/live-examples/configurable-cad-part.mdx index 3b380d42..aa6ab74b 100644 --- a/docs/learn/runners/live-examples/configurable-cad-part.mdx +++ b/docs/learn/runners/live-examples/configurable-cad-part.mdx @@ -30,7 +30,7 @@ Below is an interactive preview of the Rete visual program. Notice how this scri @@ -129,7 +129,7 @@ await runner.run(runnerOptions); // Asynchronously initializes the runner and Ba function exportedScript() { // This is the very long JavaScript string generated by "Export to Runner" from Rete. // It starts with "!async function(e,t,s,n,r){..." where e=BitByBit, t=bitbybit, etc. - return '{"type":"rete","version":"0.21.0","script":"!async function(e,t,s,n,r){let a={};a={x:[0],y:[0],z:[1],...a};const o=[{result:e.HS.executeBasedOnType(a,!1,(e=>t.vector.vectorXYZ(e))),transformers:[]}]; ... (rest of the very long exported JS string) ... }(BitByBit,bitbybit,bitbybitRunnerResult,bitbybitRunnerInputs,Bit);"}' + return '{"type":"rete","version":"0.21.1","script":"!async function(e,t,s,n,r){let a={};a={x:[0],y:[0],z:[1],...a};const o=[{result:e.HS.executeBasedOnType(a,!1,(e=>t.vector.vectorXYZ(e))),transformers:[]}]; ... (rest of the very long exported JS string) ... }(BitByBit,bitbybit,bitbybitRunnerResult,bitbybitRunnerInputs,Bit);"}' } // Step 4: Execute the Script diff --git a/docs/learn/runners/table-configurator-blockly.mdx b/docs/learn/runners/table-configurator-blockly.mdx index f4c7b051..f5065820 100644 --- a/docs/learn/runners/table-configurator-blockly.mdx +++ b/docs/learn/runners/table-configurator-blockly.mdx @@ -46,7 +46,7 @@ The following Bitbybit Blockly script is the visual program that defines the log widthlengthlegHeightheighthalfLegheightthicknesshalfThicknesswidthOffsetlengthOffsetlegShapecompoundShapetable'clearSky'10000.10.7-100-100-1003#ffffff#ffffff1024TRUE0legHeightMINUSheightthicknesshalfLegheightDIVIDElegHeight2halfThicknessDIVIDEthickness2widthOffsetMINUSDIVIDEwidth2halfThicknesslengthOffsetMINUSDIVIDElength2halfThicknesslegShapethicknessthicknesslegHeight000compoundShapewidthlengththickness0MINUSheighthalfThickness0legShapewidthOffsethalfLegheightlengthOffsetlegShapeNEGwidthOffsethalfLegheightlengthOffsetlegShapewidthOffsethalfLegheightNEGlengthOffsetlegShapeNEGwidthOffsethalfLegheightNEGlengthOffset2000010tablecompoundShape0.01TRUE#999999TRUE#ffffff1tabletablesetupParamsDescribe this function...widthwidthlengthlengthheightheightthicknessthicknesswidthwidth1lengthlength1heightheight0.5thicknessthickness0.05","version":"0.21.0","type":"blockly"}} + script={{"script":"widthlengthlegHeightheighthalfLegheightthicknesshalfThicknesswidthOffsetlengthOffsetlegShapecompoundShapetable'clearSky'10000.10.7-100-100-1003#ffffff#ffffff1024TRUE0legHeightMINUSheightthicknesshalfLegheightDIVIDElegHeight2halfThicknessDIVIDEthickness2widthOffsetMINUSDIVIDEwidth2halfThicknesslengthOffsetMINUSDIVIDElength2halfThicknesslegShapethicknessthicknesslegHeight000compoundShapewidthlengththickness0MINUSheighthalfThickness0legShapewidthOffsethalfLegheightlengthOffsetlegShapeNEGwidthOffsethalfLegheightlengthOffsetlegShapewidthOffsethalfLegheightNEGlengthOffsetlegShapeNEGwidthOffsethalfLegheightNEGlengthOffset2000010tablecompoundShape0.01TRUE#999999TRUE#ffffff1tabletablesetupParamsDescribe this function...widthwidthlengthlengthheightheightthicknessthicknesswidthwidth1lengthlength1heightheight0.5thicknessthickness0.05","version":"0.21.1","type":"blockly"}} title="Bitbybit Blockly Editor - Simple Cube for Runner Tutorial" description="Draws 3D Table and controls its size via inputs coming from external executing program" /> @@ -66,7 +66,7 @@ Below are the `index.html` and `script.js` files you would use on StackBlitz or - + diff --git a/docs/learn/runners/table-configurator-rete.mdx b/docs/learn/runners/table-configurator-rete.mdx index 0b42f2ef..32f63539 100644 --- a/docs/learn/runners/table-configurator-rete.mdx +++ b/docs/learn/runners/table-configurator-rete.mdx @@ -46,7 +46,7 @@ The following Bitbybit Rete script is the visual program that defines the logic diff --git a/docs/learn/runners/table-configurator-typescript.mdx b/docs/learn/runners/table-configurator-typescript.mdx index 9bee2a17..29e6a04b 100644 --- a/docs/learn/runners/table-configurator-typescript.mdx +++ b/docs/learn/runners/table-configurator-typescript.mdx @@ -51,7 +51,7 @@ The following Bitbybit TypeScript script is the program that defines the logic f {\n\n const skyboxOptions = new Bit.Inputs.BabylonScene.SkyboxDto();\n skyboxOptions.skybox = Bit.Inputs.Base.skyboxEnum.clearSky;\n bitbybit.babylon.scene.enableSkybox(skyboxOptions);\n\n const lightOptions = new Bit.Inputs.BabylonScene.DirectionalLightDto();\n lightOptions.intensity = 3;\n bitbybit.babylon.scene.drawDirectionalLight(lightOptions);\n\n const tableTopShape = await solid.createBox({\n width: inputs.width,\n length: inputs.length,\n height: inputs.thickness,\n center: [0, inputs.height - halfThickness, 0],\n });\n\n const leg1Shape = await solid.createBox({\n width: inputs.thickness,\n length: inputs.thickness,\n height: legHeight,\n center: [widthOffset, halfLegHeight, lengthOffset],\n });\n const leg2Shape = await solid.createBox({\n width: inputs.thickness,\n length: inputs.thickness,\n height: legHeight,\n center: [-widthOffset, halfLegHeight, lengthOffset],\n });\n const leg3Shape = await solid.createBox({\n width: inputs.thickness,\n length: inputs.thickness,\n height: legHeight,\n center: [widthOffset, halfLegHeight, -lengthOffset],\n });\n const leg4Shape = await solid.createBox({\n width: inputs.thickness,\n length: inputs.thickness,\n height: legHeight,\n center: [-widthOffset, halfLegHeight, -lengthOffset],\n });\n\n const groundShape = await face.createCircleFace({\n radius: 2,\n center: [0, 0, 0],\n direction: [0, 1, 0]\n });\n\n const compoundShape = await compound.makeCompound({\n shapes: [tableTopShape, leg1Shape, leg2Shape, leg3Shape, leg4Shape, groundShape],\n });\n\n const drawOptions = new Bit.Inputs.Draw.DrawOcctShapeSimpleOptions();\n drawOptions.faceColour = \"#555577\";\n drawOptions.edgeWidth = 1;\n const table = await bitbybit.draw.drawAnyAsync({ entity: compoundShape, options: drawOptions });\n return { table };\n}\n\nconst runnerOutput = start();\nBit.setBitbybitRunnerResult(runnerOutput);\n","version":"0.21.0","type":"typescript"}} + script={{"script":"type Inputs = {\n width: number;\n length: number;\n height: number;\n thickness: number;\n};\n\nconst defaultValues: Inputs = {\n width: 1,\n length: 1,\n height: 0.5,\n thickness: 0.05,\n};\n\nBit.mockBitbybitRunnerInputs(defaultValues);\nconst inputs: Inputs = Bit.getBitbybitRunnerInputs();\n\nconst { solid, compound, face } = bitbybit.occt.shapes;\n\nconst legHeight = inputs.height - inputs.thickness;\nconst halfLegHeight = legHeight / 2;\nconst halfThickness = inputs.thickness / 2;\nconst widthOffset = inputs.width / 2 - halfThickness;\nconst lengthOffset = inputs.length / 2 - halfThickness;\n\n\nconst start = async () => {\n\n const skyboxOptions = new Bit.Inputs.BabylonScene.SkyboxDto();\n skyboxOptions.skybox = Bit.Inputs.Base.skyboxEnum.clearSky;\n bitbybit.babylon.scene.enableSkybox(skyboxOptions);\n\n const lightOptions = new Bit.Inputs.BabylonScene.DirectionalLightDto();\n lightOptions.intensity = 3;\n bitbybit.babylon.scene.drawDirectionalLight(lightOptions);\n\n const tableTopShape = await solid.createBox({\n width: inputs.width,\n length: inputs.length,\n height: inputs.thickness,\n center: [0, inputs.height - halfThickness, 0],\n });\n\n const leg1Shape = await solid.createBox({\n width: inputs.thickness,\n length: inputs.thickness,\n height: legHeight,\n center: [widthOffset, halfLegHeight, lengthOffset],\n });\n const leg2Shape = await solid.createBox({\n width: inputs.thickness,\n length: inputs.thickness,\n height: legHeight,\n center: [-widthOffset, halfLegHeight, lengthOffset],\n });\n const leg3Shape = await solid.createBox({\n width: inputs.thickness,\n length: inputs.thickness,\n height: legHeight,\n center: [widthOffset, halfLegHeight, -lengthOffset],\n });\n const leg4Shape = await solid.createBox({\n width: inputs.thickness,\n length: inputs.thickness,\n height: legHeight,\n center: [-widthOffset, halfLegHeight, -lengthOffset],\n });\n\n const groundShape = await face.createCircleFace({\n radius: 2,\n center: [0, 0, 0],\n direction: [0, 1, 0]\n });\n\n const compoundShape = await compound.makeCompound({\n shapes: [tableTopShape, leg1Shape, leg2Shape, leg3Shape, leg4Shape, groundShape],\n });\n\n const drawOptions = new Bit.Inputs.Draw.DrawOcctShapeSimpleOptions();\n drawOptions.faceColour = \"#555577\";\n drawOptions.edgeWidth = 1;\n const table = await bitbybit.draw.drawAnyAsync({ entity: compoundShape, options: drawOptions });\n return { table };\n}\n\nconst runnerOutput = start();\nBit.setBitbybitRunnerResult(runnerOutput);\n","version":"0.21.1","type":"typescript"}} title="Bitbybit TypeScript Editor - 3D Table Configurator" description="Draws 3D Table and controls its size via inputs coming from external executing program" /> diff --git a/docs/static/llms.txt b/docs/static/llms.txt index 434692e4..cf00da62 100644 --- a/docs/static/llms.txt +++ b/docs/static/llms.txt @@ -91,29 +91,29 @@ Using AI assistants with Bitbybit for enhanced coding workflows. - AI Introduction: https://learn.bitbybit.dev/learn/using-ai-with-bitbybit/intro - Context7 MCP Integration: https://learn.bitbybit.dev/learn/using-ai-with-bitbybit/mcp/context-7 -### AI Context Files (v0.21.0) +### AI Context Files (v0.21.1) Attach these files to your AI coding assistant for Bitbybit API knowledge. #### Beginner Context (Monaco Editor) For online TypeScript editor at bitbybit.dev: -- Full Context (116k tokens): https://app.bitbybit.dev/assets/ai-prompt-context/v0.21.0/bitbybit-babylon-monaco-ai-context-v0.21.0.md +- Full Context (116k tokens): https://app.bitbybit.dev/assets/ai-prompt-context/v0.21.1/bitbybit-babylon-monaco-ai-context-v0.21.1.md #### BabylonJS Context -- Full (116k tokens): https://app.bitbybit.dev/assets/ai-prompt-context/v0.21.0/bitbybit-babylon-ai-context-v0.21.0.md -- Lite (114k tokens): https://app.bitbybit.dev/assets/ai-prompt-context/v0.21.0/bitbybit-babylon-no-comment-min-ai-v0.21.0.md +- Full (116k tokens): https://app.bitbybit.dev/assets/ai-prompt-context/v0.21.1/bitbybit-babylon-ai-context-v0.21.1.md +- Lite (114k tokens): https://app.bitbybit.dev/assets/ai-prompt-context/v0.21.1/bitbybit-babylon-no-comment-min-ai-v0.21.1.md #### Three.js Context -- Full (95k tokens): https://app.bitbybit.dev/assets/ai-prompt-context/v0.21.0/bitbybit-three-ai-context-v0.21.0.md -- Lite (82k tokens): https://app.bitbybit.dev/assets/ai-prompt-context/v0.21.0/bitbybit-three-no-comment-min-ai-v0.21.0.md +- Full (95k tokens): https://app.bitbybit.dev/assets/ai-prompt-context/v0.21.1/bitbybit-three-ai-context-v0.21.1.md +- Lite (82k tokens): https://app.bitbybit.dev/assets/ai-prompt-context/v0.21.1/bitbybit-three-no-comment-min-ai-v0.21.1.md #### PlayCanvas Context -- Full (94k tokens): https://app.bitbybit.dev/assets/ai-prompt-context/v0.21.0/bitbybit-playcanvas-ai-context-v0.21.0.md -- Lite (82k tokens): https://app.bitbybit.dev/assets/ai-prompt-context/v0.21.0/bitbybit-playcanvas-no-comment-min-ai-v0.21.0.md +- Full (94k tokens): https://app.bitbybit.dev/assets/ai-prompt-context/v0.21.1/bitbybit-playcanvas-ai-context-v0.21.1.md +- Lite (82k tokens): https://app.bitbybit.dev/assets/ai-prompt-context/v0.21.1/bitbybit-playcanvas-no-comment-min-ai-v0.21.1.md ### MCP Server diff --git a/examples/angular/babylonjs/laptop-holder/package-lock.json b/examples/angular/babylonjs/laptop-holder/package-lock.json index fe74d691..2ddfb3f3 100644 --- a/examples/angular/babylonjs/laptop-holder/package-lock.json +++ b/examples/angular/babylonjs/laptop-holder/package-lock.json @@ -17,7 +17,7 @@ "@angular/platform-browser": "13.3.0", "@angular/platform-browser-dynamic": "13.3.0", "@angular/router": "13.3.0", - "@bitbybit-dev/babylonjs": "0.21.0", + "@bitbybit-dev/babylonjs": "0.21.1", "rxjs": "7.5.5", "tslib": "2.3.1", "zone.js": "0.11.5" @@ -2331,15 +2331,15 @@ } }, "node_modules/@babylonjs/core": { - "version": "8.44.1", - "resolved": "https://registry.npmjs.org/@babylonjs/core/-/core-8.44.1.tgz", - "integrity": "sha512-sF2WWK2d7lg18ESOCxUoRG4d1SzCWz42asjRjRGxZ8r3D7w9ZM3H2wftJIqwaZvD3zWr+wmCVKpQ6hWkboHIXw==", + "version": "8.45.4", + "resolved": "https://registry.npmjs.org/@babylonjs/core/-/core-8.45.4.tgz", + "integrity": "sha512-fmpaitVpe+bB3PCLY0RKYO/e5n1vLNvueJrglt6SENVE/frZNS4har8odAd1UDNf5KFgOdb8YK91jK4BUwIgcQ==", "license": "Apache-2.0" }, "node_modules/@babylonjs/gui": { - "version": "8.44.1", - "resolved": "https://registry.npmjs.org/@babylonjs/gui/-/gui-8.44.1.tgz", - "integrity": "sha512-6STDK+Hr8GpY29YMLKnTVhEnWw1NKPrIpz+MqgWuoAAmmpiFtNCr0nnAnCj5fhgGf25L89jy51ogXyg3jfiuDA==", + "version": "8.45.4", + "resolved": "https://registry.npmjs.org/@babylonjs/gui/-/gui-8.45.4.tgz", + "integrity": "sha512-1pMjQs7fgSEvUQoXyit96kNRqzX74oMNkMkAOmz7NjOkBX3tacAfNfoEC6aw+AB+iAjlCO5/DXatZU5m6EYyIQ==", "license": "Apache-2.0", "peerDependencies": { "@babylonjs/core": "^8.0.0" @@ -2354,9 +2354,9 @@ } }, "node_modules/@babylonjs/loaders": { - "version": "8.44.1", - "resolved": "https://registry.npmjs.org/@babylonjs/loaders/-/loaders-8.44.1.tgz", - "integrity": "sha512-h5rUGCwhdWv3Hq48DP8sy4/+3QUYjOprxu2i6zXKb69LHMnYE0tZ1xQHBJEOUF60hxA+TwhzdjC8bxInKoeojA==", + "version": "8.45.4", + "resolved": "https://registry.npmjs.org/@babylonjs/loaders/-/loaders-8.45.4.tgz", + "integrity": "sha512-P1H8XpIJK7NnrtGGSGkCJZIPBvtJ+0+l7yGXDY2UaNFKU80y2Oty8DZ8JRKdbJdSc4cOe8ucBY5w7x+Bbllxuw==", "license": "Apache-2.0", "peerDependencies": { "@babylonjs/core": "^8.0.0", @@ -2364,18 +2364,18 @@ } }, "node_modules/@babylonjs/materials": { - "version": "8.44.1", - "resolved": "https://registry.npmjs.org/@babylonjs/materials/-/materials-8.44.1.tgz", - "integrity": "sha512-FD0S/aA68oEjKCSNY5ydGkiHbsyo08KlhQ+6R8swtJhx5aq7ojWBt3P9KC78+wjZiCJW37176CIObcV8QcjMAQ==", + "version": "8.45.4", + "resolved": "https://registry.npmjs.org/@babylonjs/materials/-/materials-8.45.4.tgz", + "integrity": "sha512-ElTXhC83alnMFFyv2sPG/Im5UwTZoDzd1R8otPQwbEEERcRK8A71Hu1gFdBu/8l9O752IWnZcPSEj1WwLqeR5A==", "license": "Apache-2.0", "peerDependencies": { "@babylonjs/core": "^8.6.0" } }, "node_modules/@babylonjs/serializers": { - "version": "8.44.1", - "resolved": "https://registry.npmjs.org/@babylonjs/serializers/-/serializers-8.44.1.tgz", - "integrity": "sha512-3FRRdKpHr2qTkALHEvq0ih0P59iTINUFrGZWFUfO3Wu24UBSuTxY9Kq820dvUUWaRtWkXEnMSQbR+5glzcfqBw==", + "version": "8.45.4", + "resolved": "https://registry.npmjs.org/@babylonjs/serializers/-/serializers-8.45.4.tgz", + "integrity": "sha512-i83RQIP3XSi3DFJwhc/+JNNPm49DdtNyDobuyBBwIDyMpQdbcFLhkL0DW/7/H+vFUWz0xWx+mgmsb6HY/ePGmg==", "license": "Apache-2.0", "peerDependencies": { "@babylonjs/core": "^8.0.0", @@ -2383,49 +2383,49 @@ } }, "node_modules/@bitbybit-dev/babylonjs": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/babylonjs/-/babylonjs-0.21.0.tgz", - "integrity": "sha512-8aPJ+XTXzcnO4bXfmW34lTnVCzC6Hy6TMkh7/ziQSoUsjPp7e7LFHoBBfqCk09LdTLa85gb5x/f6WNAn306Odg==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/babylonjs/-/babylonjs-0.21.1.tgz", + "integrity": "sha512-OyQI5FC4qI5EYW/RFZt/6WR2We2bEpbhM8I8ptiJkviY0e1yIjiV11A4aF8B6fpjS5Bd7Rb30LrUdWNHbAo1Nw==", "license": "MIT", "dependencies": { - "@babylonjs/core": "8.44.1", - "@babylonjs/gui": "8.44.1", + "@babylonjs/core": "8.45.4", + "@babylonjs/gui": "8.45.4", "@babylonjs/havok": "1.3.10", - "@babylonjs/loaders": "8.44.1", - "@babylonjs/materials": "8.44.1", - "@babylonjs/serializers": "8.44.1", - "@bitbybit-dev/core": "0.21.0", + "@babylonjs/loaders": "8.45.4", + "@babylonjs/materials": "8.45.4", + "@babylonjs/serializers": "8.45.4", + "@bitbybit-dev/core": "0.21.1", "earcut": "2.2.3" } }, "node_modules/@bitbybit-dev/base": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/base/-/base-0.21.0.tgz", - "integrity": "sha512-dNfsf2tu3/QUD1mvZzzTze8RwHyK2Jrt+Ary8EDKdNKMw+abtCpQYNerdrg0ZQPxvwu/OOQz6N1xCsCwsPkQJg==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/base/-/base-0.21.1.tgz", + "integrity": "sha512-d3aHPpLHigeNTceMi0U/wOIzCqkvHg8S2gNa4b8VGSTifbn7Fo1XbQ2pzetbcOtwtJhkcLgNYn3nFqW8S2MUpw==", "license": "MIT" }, "node_modules/@bitbybit-dev/core": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/core/-/core-0.21.0.tgz", - "integrity": "sha512-IbeQ8ROreu0/RkkngUE+Eb19ecvqKOWhGefXvIqQmplxt3zEc0FI4Kw8wR3vYl2XMannuVt1xAIYtqqH0tjBzg==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/core/-/core-0.21.1.tgz", + "integrity": "sha512-Zr2w4h1eBRgOHevKevTaDeL1KlOju6Q8uT62zLeKAAAAn5P1RNn2jOVnHEJtd7y4wPn7G2rZwlwtBQlYe5t9AQ==", "license": "MIT", "dependencies": { - "@bitbybit-dev/base": "0.21.0", - "@bitbybit-dev/jscad-worker": "0.21.0", - "@bitbybit-dev/manifold-worker": "0.21.0", - "@bitbybit-dev/occt-worker": "0.21.0", - "jsonpath-plus": "10.1.0", + "@bitbybit-dev/base": "0.21.1", + "@bitbybit-dev/jscad-worker": "0.21.1", + "@bitbybit-dev/manifold-worker": "0.21.1", + "@bitbybit-dev/occt-worker": "0.21.1", + "jsonpath-plus": "10.3.0", "rxjs": "7.5.5", "verb-nurbs-web": "2.1.3" } }, "node_modules/@bitbybit-dev/jscad": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/jscad/-/jscad-0.21.0.tgz", - "integrity": "sha512-Q7eE2ILrJRstW4L1711aJZdpwPf1kuhZJqB+KLkkBLsneRsGsh82lBcCbVYAOMuF/q8Lnd4JHxPiIG/m+LYmPQ==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/jscad/-/jscad-0.21.1.tgz", + "integrity": "sha512-nw8dHGYy3GPXoX0xLZeVsB0Z013mzIy4GoniLKvzN7ApnTruPxSFisxrvFajCcQpL5UbU8SW4k+LhJDI8FTlRg==", "license": "MIT", "dependencies": { - "@bitbybit-dev/base": "0.21.0", + "@bitbybit-dev/base": "0.21.1", "@jscad/3mf-serializer": "2.1.12", "@jscad/dxf-serializer": "2.1.18", "@jscad/io-utils": "2.0.28", @@ -2434,51 +2434,51 @@ } }, "node_modules/@bitbybit-dev/jscad-worker": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/jscad-worker/-/jscad-worker-0.21.0.tgz", - "integrity": "sha512-nIvd7GH5Gg51u6PmFXOADXVYTIvixTkNf0YapS1uix7D2JS9Mx10Z4wHAeRKzvJxUAAbEPPRFNkakE22HFGtLQ==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/jscad-worker/-/jscad-worker-0.21.1.tgz", + "integrity": "sha512-ccaXGTnKseWGDGEdgf3HfQqBWmM4Q384NQWO2kdzZ4EHaZlSp9tEHY8NHOxyxPoMol+qK9u9puH4ux13zY+FrQ==", "license": "MIT", "dependencies": { - "@bitbybit-dev/jscad": "0.21.0", + "@bitbybit-dev/jscad": "0.21.1", "rxjs": "7.5.5" } }, "node_modules/@bitbybit-dev/manifold": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/manifold/-/manifold-0.21.0.tgz", - "integrity": "sha512-DPpwK9ESB+auDeAbzXcfWRVEzWoMDkpkjc+/uwh+zuSiHSx92PSkzx1/LVTbQCsK+aOfOOy03HQCF5Bu2KQYtw==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/manifold/-/manifold-0.21.1.tgz", + "integrity": "sha512-/UqejYCN9YIyBzf5yQXPdSawoKqEUd1aQAKdmge4LoUaZ19eQyRHLK4WpZQ8K+7lTr7qcNQARr7mLx0FQMBFew==", "license": "MIT", "dependencies": { - "@bitbybit-dev/base": "0.21.0", + "@bitbybit-dev/base": "0.21.1", "manifold-3d": "3.3.2" } }, "node_modules/@bitbybit-dev/manifold-worker": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/manifold-worker/-/manifold-worker-0.21.0.tgz", - "integrity": "sha512-6Cqv3BP+uI8mHKHI6Jx9TzCxRg1/kMHhCe18+B3KD/rTl9B5mnScCKRBnDansR3bH7aYZGnIw9PmiFnWLkQWEQ==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/manifold-worker/-/manifold-worker-0.21.1.tgz", + "integrity": "sha512-A+oV172dZzehkeF5kdCFzQuyyfj9FLixq5nGNviOpJX3zaF+0efl1ung1o45V5pLtZkuGCgCZaQ6lY0zNQcYig==", "license": "MIT", "dependencies": { - "@bitbybit-dev/manifold": "0.21.0", + "@bitbybit-dev/manifold": "0.21.1", "rxjs": "7.5.5" } }, "node_modules/@bitbybit-dev/occt": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/occt/-/occt-0.21.0.tgz", - "integrity": "sha512-vPu3NmF1kBZMOkOdysolGfFxEEnwdHNGORoX3eWbMWT2JL/Tag5Q2CAc5jwa2VvZnS1nE/9x+DVlFQSo8LQnIg==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/occt/-/occt-0.21.1.tgz", + "integrity": "sha512-0+yffQRmph9W1qLSyRBUvaQDiZ9OHA2kD2/LsCgxR3NVtKs3GZaAYYhoUfaRqtt2I8Go99e8WBB5daaQceudjA==", "license": "MIT", "dependencies": { - "@bitbybit-dev/base": "0.21.0" + "@bitbybit-dev/base": "0.21.1" } }, "node_modules/@bitbybit-dev/occt-worker": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/occt-worker/-/occt-worker-0.21.0.tgz", - "integrity": "sha512-xG1sgo6q/RdVA8AgG72wPe4qxcQlrO1V7/Ksn6MqIhZVTsJcm5RbVYlK+nziIWhvlMc1sKE0GNQFcPdALISLuQ==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/occt-worker/-/occt-worker-0.21.1.tgz", + "integrity": "sha512-3BW0lTiY8muPSiCWplAT/VQHaHFVUvljMGD1ynQo7cqv/Zna9ACn+SHOMY2HJ7m1MnZq5d2dGjJJXo8k19iV8Q==", "license": "MIT", "dependencies": { - "@bitbybit-dev/occt": "0.21.0", + "@bitbybit-dev/occt": "0.21.1", "rxjs": "7.5.5" } }, @@ -4225,9 +4225,9 @@ } }, "node_modules/babylonjs-gltf2interface": { - "version": "8.44.1", - "resolved": "https://registry.npmjs.org/babylonjs-gltf2interface/-/babylonjs-gltf2interface-8.44.1.tgz", - "integrity": "sha512-+z0P0wms1FD5xuVpuRJ1qjvGAbPAWhEWGBWENRPD0Hbz6nd9cnL28/pjxgk39/QhlIuJKL9JZ0o8G0JgLHEnRQ==", + "version": "8.45.5", + "resolved": "https://registry.npmjs.org/babylonjs-gltf2interface/-/babylonjs-gltf2interface-8.45.5.tgz", + "integrity": "sha512-o1OMBVdeKCK7b+L1VUW1w1+KIi1DTP7Po+SAJ3vwPqRG6xD2eTL+w5IaFHVue3dVjnlU8Z+9y3BP3AadmK0H9w==", "license": "Apache-2.0", "peer": true }, @@ -8002,14 +8002,14 @@ ] }, "node_modules/jsonpath-plus": { - "version": "10.1.0", - "resolved": "https://registry.npmjs.org/jsonpath-plus/-/jsonpath-plus-10.1.0.tgz", - "integrity": "sha512-gHfV1IYqH8uJHYVTs8BJX1XKy2/rR93+f8QQi0xhx95aCiXn1ettYAd5T+7FU6wfqyDoX/wy0pm/fL3jOKJ9Lg==", + "version": "10.3.0", + "resolved": "https://registry.npmjs.org/jsonpath-plus/-/jsonpath-plus-10.3.0.tgz", + "integrity": "sha512-8TNmfeTCk2Le33A3vRRwtuworG/L5RrgMvdjhKZxvyShO+mBu2fP50OWUjRLNtvw344DdDarFh9buFAZs5ujeA==", "license": "MIT", "dependencies": { - "@jsep-plugin/assignment": "^1.2.1", - "@jsep-plugin/regex": "^1.0.3", - "jsep": "^1.3.9" + "@jsep-plugin/assignment": "^1.3.0", + "@jsep-plugin/regex": "^1.0.4", + "jsep": "^1.4.0" }, "bin": { "jsonpath": "bin/jsonpath-cli.js", @@ -14469,14 +14469,14 @@ } }, "@babylonjs/core": { - "version": "8.44.1", - "resolved": "https://registry.npmjs.org/@babylonjs/core/-/core-8.44.1.tgz", - "integrity": "sha512-sF2WWK2d7lg18ESOCxUoRG4d1SzCWz42asjRjRGxZ8r3D7w9ZM3H2wftJIqwaZvD3zWr+wmCVKpQ6hWkboHIXw==" + "version": "8.45.4", + "resolved": "https://registry.npmjs.org/@babylonjs/core/-/core-8.45.4.tgz", + "integrity": "sha512-fmpaitVpe+bB3PCLY0RKYO/e5n1vLNvueJrglt6SENVE/frZNS4har8odAd1UDNf5KFgOdb8YK91jK4BUwIgcQ==" }, "@babylonjs/gui": { - "version": "8.44.1", - "resolved": "https://registry.npmjs.org/@babylonjs/gui/-/gui-8.44.1.tgz", - "integrity": "sha512-6STDK+Hr8GpY29YMLKnTVhEnWw1NKPrIpz+MqgWuoAAmmpiFtNCr0nnAnCj5fhgGf25L89jy51ogXyg3jfiuDA==", + "version": "8.45.4", + "resolved": "https://registry.npmjs.org/@babylonjs/gui/-/gui-8.45.4.tgz", + "integrity": "sha512-1pMjQs7fgSEvUQoXyit96kNRqzX74oMNkMkAOmz7NjOkBX3tacAfNfoEC6aw+AB+iAjlCO5/DXatZU5m6EYyIQ==", "requires": {} }, "@babylonjs/havok": { @@ -14488,63 +14488,63 @@ } }, "@babylonjs/loaders": { - "version": "8.44.1", - "resolved": "https://registry.npmjs.org/@babylonjs/loaders/-/loaders-8.44.1.tgz", - "integrity": "sha512-h5rUGCwhdWv3Hq48DP8sy4/+3QUYjOprxu2i6zXKb69LHMnYE0tZ1xQHBJEOUF60hxA+TwhzdjC8bxInKoeojA==", + "version": "8.45.4", + "resolved": "https://registry.npmjs.org/@babylonjs/loaders/-/loaders-8.45.4.tgz", + "integrity": "sha512-P1H8XpIJK7NnrtGGSGkCJZIPBvtJ+0+l7yGXDY2UaNFKU80y2Oty8DZ8JRKdbJdSc4cOe8ucBY5w7x+Bbllxuw==", "requires": {} }, "@babylonjs/materials": { - "version": "8.44.1", - "resolved": "https://registry.npmjs.org/@babylonjs/materials/-/materials-8.44.1.tgz", - "integrity": "sha512-FD0S/aA68oEjKCSNY5ydGkiHbsyo08KlhQ+6R8swtJhx5aq7ojWBt3P9KC78+wjZiCJW37176CIObcV8QcjMAQ==", + "version": "8.45.4", + "resolved": "https://registry.npmjs.org/@babylonjs/materials/-/materials-8.45.4.tgz", + "integrity": "sha512-ElTXhC83alnMFFyv2sPG/Im5UwTZoDzd1R8otPQwbEEERcRK8A71Hu1gFdBu/8l9O752IWnZcPSEj1WwLqeR5A==", "requires": {} }, "@babylonjs/serializers": { - "version": "8.44.1", - "resolved": "https://registry.npmjs.org/@babylonjs/serializers/-/serializers-8.44.1.tgz", - "integrity": "sha512-3FRRdKpHr2qTkALHEvq0ih0P59iTINUFrGZWFUfO3Wu24UBSuTxY9Kq820dvUUWaRtWkXEnMSQbR+5glzcfqBw==", + "version": "8.45.4", + "resolved": "https://registry.npmjs.org/@babylonjs/serializers/-/serializers-8.45.4.tgz", + "integrity": "sha512-i83RQIP3XSi3DFJwhc/+JNNPm49DdtNyDobuyBBwIDyMpQdbcFLhkL0DW/7/H+vFUWz0xWx+mgmsb6HY/ePGmg==", "requires": {} }, "@bitbybit-dev/babylonjs": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/babylonjs/-/babylonjs-0.21.0.tgz", - "integrity": "sha512-8aPJ+XTXzcnO4bXfmW34lTnVCzC6Hy6TMkh7/ziQSoUsjPp7e7LFHoBBfqCk09LdTLa85gb5x/f6WNAn306Odg==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/babylonjs/-/babylonjs-0.21.1.tgz", + "integrity": "sha512-OyQI5FC4qI5EYW/RFZt/6WR2We2bEpbhM8I8ptiJkviY0e1yIjiV11A4aF8B6fpjS5Bd7Rb30LrUdWNHbAo1Nw==", "requires": { - "@babylonjs/core": "8.44.1", - "@babylonjs/gui": "8.44.1", + "@babylonjs/core": "8.45.4", + "@babylonjs/gui": "8.45.4", "@babylonjs/havok": "1.3.10", - "@babylonjs/loaders": "8.44.1", - "@babylonjs/materials": "8.44.1", - "@babylonjs/serializers": "8.44.1", - "@bitbybit-dev/core": "0.21.0", + "@babylonjs/loaders": "8.45.4", + "@babylonjs/materials": "8.45.4", + "@babylonjs/serializers": "8.45.4", + "@bitbybit-dev/core": "0.21.1", "earcut": "2.2.3" } }, "@bitbybit-dev/base": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/base/-/base-0.21.0.tgz", - "integrity": "sha512-dNfsf2tu3/QUD1mvZzzTze8RwHyK2Jrt+Ary8EDKdNKMw+abtCpQYNerdrg0ZQPxvwu/OOQz6N1xCsCwsPkQJg==" + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/base/-/base-0.21.1.tgz", + "integrity": "sha512-d3aHPpLHigeNTceMi0U/wOIzCqkvHg8S2gNa4b8VGSTifbn7Fo1XbQ2pzetbcOtwtJhkcLgNYn3nFqW8S2MUpw==" }, "@bitbybit-dev/core": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/core/-/core-0.21.0.tgz", - "integrity": "sha512-IbeQ8ROreu0/RkkngUE+Eb19ecvqKOWhGefXvIqQmplxt3zEc0FI4Kw8wR3vYl2XMannuVt1xAIYtqqH0tjBzg==", - "requires": { - "@bitbybit-dev/base": "0.21.0", - "@bitbybit-dev/jscad-worker": "0.21.0", - "@bitbybit-dev/manifold-worker": "0.21.0", - "@bitbybit-dev/occt-worker": "0.21.0", - "jsonpath-plus": "10.1.0", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/core/-/core-0.21.1.tgz", + "integrity": "sha512-Zr2w4h1eBRgOHevKevTaDeL1KlOju6Q8uT62zLeKAAAAn5P1RNn2jOVnHEJtd7y4wPn7G2rZwlwtBQlYe5t9AQ==", + "requires": { + "@bitbybit-dev/base": "0.21.1", + "@bitbybit-dev/jscad-worker": "0.21.1", + "@bitbybit-dev/manifold-worker": "0.21.1", + "@bitbybit-dev/occt-worker": "0.21.1", + "jsonpath-plus": "10.3.0", "rxjs": "7.5.5", "verb-nurbs-web": "2.1.3" } }, "@bitbybit-dev/jscad": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/jscad/-/jscad-0.21.0.tgz", - "integrity": "sha512-Q7eE2ILrJRstW4L1711aJZdpwPf1kuhZJqB+KLkkBLsneRsGsh82lBcCbVYAOMuF/q8Lnd4JHxPiIG/m+LYmPQ==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/jscad/-/jscad-0.21.1.tgz", + "integrity": "sha512-nw8dHGYy3GPXoX0xLZeVsB0Z013mzIy4GoniLKvzN7ApnTruPxSFisxrvFajCcQpL5UbU8SW4k+LhJDI8FTlRg==", "requires": { - "@bitbybit-dev/base": "0.21.0", + "@bitbybit-dev/base": "0.21.1", "@jscad/3mf-serializer": "2.1.12", "@jscad/dxf-serializer": "2.1.18", "@jscad/io-utils": "2.0.28", @@ -14553,46 +14553,46 @@ } }, "@bitbybit-dev/jscad-worker": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/jscad-worker/-/jscad-worker-0.21.0.tgz", - "integrity": "sha512-nIvd7GH5Gg51u6PmFXOADXVYTIvixTkNf0YapS1uix7D2JS9Mx10Z4wHAeRKzvJxUAAbEPPRFNkakE22HFGtLQ==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/jscad-worker/-/jscad-worker-0.21.1.tgz", + "integrity": "sha512-ccaXGTnKseWGDGEdgf3HfQqBWmM4Q384NQWO2kdzZ4EHaZlSp9tEHY8NHOxyxPoMol+qK9u9puH4ux13zY+FrQ==", "requires": { - "@bitbybit-dev/jscad": "0.21.0", + "@bitbybit-dev/jscad": "0.21.1", "rxjs": "7.5.5" } }, "@bitbybit-dev/manifold": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/manifold/-/manifold-0.21.0.tgz", - "integrity": "sha512-DPpwK9ESB+auDeAbzXcfWRVEzWoMDkpkjc+/uwh+zuSiHSx92PSkzx1/LVTbQCsK+aOfOOy03HQCF5Bu2KQYtw==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/manifold/-/manifold-0.21.1.tgz", + "integrity": "sha512-/UqejYCN9YIyBzf5yQXPdSawoKqEUd1aQAKdmge4LoUaZ19eQyRHLK4WpZQ8K+7lTr7qcNQARr7mLx0FQMBFew==", "requires": { - "@bitbybit-dev/base": "0.21.0", + "@bitbybit-dev/base": "0.21.1", "manifold-3d": "3.3.2" } }, "@bitbybit-dev/manifold-worker": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/manifold-worker/-/manifold-worker-0.21.0.tgz", - "integrity": "sha512-6Cqv3BP+uI8mHKHI6Jx9TzCxRg1/kMHhCe18+B3KD/rTl9B5mnScCKRBnDansR3bH7aYZGnIw9PmiFnWLkQWEQ==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/manifold-worker/-/manifold-worker-0.21.1.tgz", + "integrity": "sha512-A+oV172dZzehkeF5kdCFzQuyyfj9FLixq5nGNviOpJX3zaF+0efl1ung1o45V5pLtZkuGCgCZaQ6lY0zNQcYig==", "requires": { - "@bitbybit-dev/manifold": "0.21.0", + "@bitbybit-dev/manifold": "0.21.1", "rxjs": "7.5.5" } }, "@bitbybit-dev/occt": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/occt/-/occt-0.21.0.tgz", - "integrity": "sha512-vPu3NmF1kBZMOkOdysolGfFxEEnwdHNGORoX3eWbMWT2JL/Tag5Q2CAc5jwa2VvZnS1nE/9x+DVlFQSo8LQnIg==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/occt/-/occt-0.21.1.tgz", + "integrity": "sha512-0+yffQRmph9W1qLSyRBUvaQDiZ9OHA2kD2/LsCgxR3NVtKs3GZaAYYhoUfaRqtt2I8Go99e8WBB5daaQceudjA==", "requires": { - "@bitbybit-dev/base": "0.21.0" + "@bitbybit-dev/base": "0.21.1" } }, "@bitbybit-dev/occt-worker": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/occt-worker/-/occt-worker-0.21.0.tgz", - "integrity": "sha512-xG1sgo6q/RdVA8AgG72wPe4qxcQlrO1V7/Ksn6MqIhZVTsJcm5RbVYlK+nziIWhvlMc1sKE0GNQFcPdALISLuQ==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/occt-worker/-/occt-worker-0.21.1.tgz", + "integrity": "sha512-3BW0lTiY8muPSiCWplAT/VQHaHFVUvljMGD1ynQo7cqv/Zna9ACn+SHOMY2HJ7m1MnZq5d2dGjJJXo8k19iV8Q==", "requires": { - "@bitbybit-dev/occt": "0.21.0", + "@bitbybit-dev/occt": "0.21.1", "rxjs": "7.5.5" } }, @@ -15834,9 +15834,9 @@ } }, "babylonjs-gltf2interface": { - "version": "8.44.1", - "resolved": "https://registry.npmjs.org/babylonjs-gltf2interface/-/babylonjs-gltf2interface-8.44.1.tgz", - "integrity": "sha512-+z0P0wms1FD5xuVpuRJ1qjvGAbPAWhEWGBWENRPD0Hbz6nd9cnL28/pjxgk39/QhlIuJKL9JZ0o8G0JgLHEnRQ==", + "version": "8.45.5", + "resolved": "https://registry.npmjs.org/babylonjs-gltf2interface/-/babylonjs-gltf2interface-8.45.5.tgz", + "integrity": "sha512-o1OMBVdeKCK7b+L1VUW1w1+KIi1DTP7Po+SAJ3vwPqRG6xD2eTL+w5IaFHVue3dVjnlU8Z+9y3BP3AadmK0H9w==", "peer": true }, "balanced-match": { @@ -18573,13 +18573,13 @@ "dev": true }, "jsonpath-plus": { - "version": "10.1.0", - "resolved": "https://registry.npmjs.org/jsonpath-plus/-/jsonpath-plus-10.1.0.tgz", - "integrity": "sha512-gHfV1IYqH8uJHYVTs8BJX1XKy2/rR93+f8QQi0xhx95aCiXn1ettYAd5T+7FU6wfqyDoX/wy0pm/fL3jOKJ9Lg==", + "version": "10.3.0", + "resolved": "https://registry.npmjs.org/jsonpath-plus/-/jsonpath-plus-10.3.0.tgz", + "integrity": "sha512-8TNmfeTCk2Le33A3vRRwtuworG/L5RrgMvdjhKZxvyShO+mBu2fP50OWUjRLNtvw344DdDarFh9buFAZs5ujeA==", "requires": { - "@jsep-plugin/assignment": "^1.2.1", - "@jsep-plugin/regex": "^1.0.3", - "jsep": "^1.3.9" + "@jsep-plugin/assignment": "^1.3.0", + "@jsep-plugin/regex": "^1.0.4", + "jsep": "^1.4.0" } }, "karma": { diff --git a/examples/angular/babylonjs/laptop-holder/package.json b/examples/angular/babylonjs/laptop-holder/package.json index 9f8dd5ff..d385d337 100644 --- a/examples/angular/babylonjs/laptop-holder/package.json +++ b/examples/angular/babylonjs/laptop-holder/package.json @@ -10,7 +10,7 @@ }, "private": true, "dependencies": { - "@bitbybit-dev/babylonjs": "0.21.0", + "@bitbybit-dev/babylonjs": "0.21.1", "@angular/animations": "13.3.0", "@angular/common": "13.3.0", "@angular/compiler": "13.3.0", diff --git a/examples/angular/threejs/simple/package-lock.json b/examples/angular/threejs/simple/package-lock.json index cbee6b1a..a4aa416c 100644 --- a/examples/angular/threejs/simple/package-lock.json +++ b/examples/angular/threejs/simple/package-lock.json @@ -17,7 +17,7 @@ "@angular/platform-browser": "13.3.0", "@angular/platform-browser-dynamic": "13.3.0", "@angular/router": "13.3.0", - "@bitbybit-dev/threejs": "0.21.0", + "@bitbybit-dev/threejs": "0.21.1", "rxjs": "7.5.5", "tslib": "2.3.1", "zone.js": "0.11.5" @@ -2331,33 +2331,33 @@ } }, "node_modules/@bitbybit-dev/base": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/base/-/base-0.21.0.tgz", - "integrity": "sha512-dNfsf2tu3/QUD1mvZzzTze8RwHyK2Jrt+Ary8EDKdNKMw+abtCpQYNerdrg0ZQPxvwu/OOQz6N1xCsCwsPkQJg==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/base/-/base-0.21.1.tgz", + "integrity": "sha512-d3aHPpLHigeNTceMi0U/wOIzCqkvHg8S2gNa4b8VGSTifbn7Fo1XbQ2pzetbcOtwtJhkcLgNYn3nFqW8S2MUpw==", "license": "MIT" }, "node_modules/@bitbybit-dev/core": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/core/-/core-0.21.0.tgz", - "integrity": "sha512-IbeQ8ROreu0/RkkngUE+Eb19ecvqKOWhGefXvIqQmplxt3zEc0FI4Kw8wR3vYl2XMannuVt1xAIYtqqH0tjBzg==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/core/-/core-0.21.1.tgz", + "integrity": "sha512-Zr2w4h1eBRgOHevKevTaDeL1KlOju6Q8uT62zLeKAAAAn5P1RNn2jOVnHEJtd7y4wPn7G2rZwlwtBQlYe5t9AQ==", "license": "MIT", "dependencies": { - "@bitbybit-dev/base": "0.21.0", - "@bitbybit-dev/jscad-worker": "0.21.0", - "@bitbybit-dev/manifold-worker": "0.21.0", - "@bitbybit-dev/occt-worker": "0.21.0", - "jsonpath-plus": "10.1.0", + "@bitbybit-dev/base": "0.21.1", + "@bitbybit-dev/jscad-worker": "0.21.1", + "@bitbybit-dev/manifold-worker": "0.21.1", + "@bitbybit-dev/occt-worker": "0.21.1", + "jsonpath-plus": "10.3.0", "rxjs": "7.5.5", "verb-nurbs-web": "2.1.3" } }, "node_modules/@bitbybit-dev/jscad": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/jscad/-/jscad-0.21.0.tgz", - "integrity": "sha512-Q7eE2ILrJRstW4L1711aJZdpwPf1kuhZJqB+KLkkBLsneRsGsh82lBcCbVYAOMuF/q8Lnd4JHxPiIG/m+LYmPQ==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/jscad/-/jscad-0.21.1.tgz", + "integrity": "sha512-nw8dHGYy3GPXoX0xLZeVsB0Z013mzIy4GoniLKvzN7ApnTruPxSFisxrvFajCcQpL5UbU8SW4k+LhJDI8FTlRg==", "license": "MIT", "dependencies": { - "@bitbybit-dev/base": "0.21.0", + "@bitbybit-dev/base": "0.21.1", "@jscad/3mf-serializer": "2.1.12", "@jscad/dxf-serializer": "2.1.18", "@jscad/io-utils": "2.0.28", @@ -2366,61 +2366,61 @@ } }, "node_modules/@bitbybit-dev/jscad-worker": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/jscad-worker/-/jscad-worker-0.21.0.tgz", - "integrity": "sha512-nIvd7GH5Gg51u6PmFXOADXVYTIvixTkNf0YapS1uix7D2JS9Mx10Z4wHAeRKzvJxUAAbEPPRFNkakE22HFGtLQ==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/jscad-worker/-/jscad-worker-0.21.1.tgz", + "integrity": "sha512-ccaXGTnKseWGDGEdgf3HfQqBWmM4Q384NQWO2kdzZ4EHaZlSp9tEHY8NHOxyxPoMol+qK9u9puH4ux13zY+FrQ==", "license": "MIT", "dependencies": { - "@bitbybit-dev/jscad": "0.21.0", + "@bitbybit-dev/jscad": "0.21.1", "rxjs": "7.5.5" } }, "node_modules/@bitbybit-dev/manifold": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/manifold/-/manifold-0.21.0.tgz", - "integrity": "sha512-DPpwK9ESB+auDeAbzXcfWRVEzWoMDkpkjc+/uwh+zuSiHSx92PSkzx1/LVTbQCsK+aOfOOy03HQCF5Bu2KQYtw==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/manifold/-/manifold-0.21.1.tgz", + "integrity": "sha512-/UqejYCN9YIyBzf5yQXPdSawoKqEUd1aQAKdmge4LoUaZ19eQyRHLK4WpZQ8K+7lTr7qcNQARr7mLx0FQMBFew==", "license": "MIT", "dependencies": { - "@bitbybit-dev/base": "0.21.0", + "@bitbybit-dev/base": "0.21.1", "manifold-3d": "3.3.2" } }, "node_modules/@bitbybit-dev/manifold-worker": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/manifold-worker/-/manifold-worker-0.21.0.tgz", - "integrity": "sha512-6Cqv3BP+uI8mHKHI6Jx9TzCxRg1/kMHhCe18+B3KD/rTl9B5mnScCKRBnDansR3bH7aYZGnIw9PmiFnWLkQWEQ==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/manifold-worker/-/manifold-worker-0.21.1.tgz", + "integrity": "sha512-A+oV172dZzehkeF5kdCFzQuyyfj9FLixq5nGNviOpJX3zaF+0efl1ung1o45V5pLtZkuGCgCZaQ6lY0zNQcYig==", "license": "MIT", "dependencies": { - "@bitbybit-dev/manifold": "0.21.0", + "@bitbybit-dev/manifold": "0.21.1", "rxjs": "7.5.5" } }, "node_modules/@bitbybit-dev/occt": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/occt/-/occt-0.21.0.tgz", - "integrity": "sha512-vPu3NmF1kBZMOkOdysolGfFxEEnwdHNGORoX3eWbMWT2JL/Tag5Q2CAc5jwa2VvZnS1nE/9x+DVlFQSo8LQnIg==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/occt/-/occt-0.21.1.tgz", + "integrity": "sha512-0+yffQRmph9W1qLSyRBUvaQDiZ9OHA2kD2/LsCgxR3NVtKs3GZaAYYhoUfaRqtt2I8Go99e8WBB5daaQceudjA==", "license": "MIT", "dependencies": { - "@bitbybit-dev/base": "0.21.0" + "@bitbybit-dev/base": "0.21.1" } }, "node_modules/@bitbybit-dev/occt-worker": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/occt-worker/-/occt-worker-0.21.0.tgz", - "integrity": "sha512-xG1sgo6q/RdVA8AgG72wPe4qxcQlrO1V7/Ksn6MqIhZVTsJcm5RbVYlK+nziIWhvlMc1sKE0GNQFcPdALISLuQ==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/occt-worker/-/occt-worker-0.21.1.tgz", + "integrity": "sha512-3BW0lTiY8muPSiCWplAT/VQHaHFVUvljMGD1ynQo7cqv/Zna9ACn+SHOMY2HJ7m1MnZq5d2dGjJJXo8k19iV8Q==", "license": "MIT", "dependencies": { - "@bitbybit-dev/occt": "0.21.0", + "@bitbybit-dev/occt": "0.21.1", "rxjs": "7.5.5" } }, "node_modules/@bitbybit-dev/threejs": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/threejs/-/threejs-0.21.0.tgz", - "integrity": "sha512-p0fHuLTjoXs3UIWoC2TFUBAhu0F4sTPU//PCvwwPLmLrbrVmpEFV61tGs0739hbU4eKS5goCTUM99RfjbRxW6A==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/threejs/-/threejs-0.21.1.tgz", + "integrity": "sha512-BXQXMB0QIpvUNCRuVM6KJKn0Of/XBY0+Mt+GlyBe/s0Npk5XX9D4WYUX4A7byKGfhQxE/+FczLGs4ibcuipfmA==", "license": "MIT", "dependencies": { - "@bitbybit-dev/core": "0.21.0", + "@bitbybit-dev/core": "0.21.1", "three": "0.182.0" } }, @@ -7927,14 +7927,14 @@ ] }, "node_modules/jsonpath-plus": { - "version": "10.1.0", - "resolved": "https://registry.npmjs.org/jsonpath-plus/-/jsonpath-plus-10.1.0.tgz", - "integrity": "sha512-gHfV1IYqH8uJHYVTs8BJX1XKy2/rR93+f8QQi0xhx95aCiXn1ettYAd5T+7FU6wfqyDoX/wy0pm/fL3jOKJ9Lg==", + "version": "10.3.0", + "resolved": "https://registry.npmjs.org/jsonpath-plus/-/jsonpath-plus-10.3.0.tgz", + "integrity": "sha512-8TNmfeTCk2Le33A3vRRwtuworG/L5RrgMvdjhKZxvyShO+mBu2fP50OWUjRLNtvw344DdDarFh9buFAZs5ujeA==", "license": "MIT", "dependencies": { - "@jsep-plugin/assignment": "^1.2.1", - "@jsep-plugin/regex": "^1.0.3", - "jsep": "^1.3.9" + "@jsep-plugin/assignment": "^1.3.0", + "@jsep-plugin/regex": "^1.0.4", + "jsep": "^1.4.0" }, "bin": { "jsonpath": "bin/jsonpath-cli.js", @@ -14400,30 +14400,30 @@ } }, "@bitbybit-dev/base": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/base/-/base-0.21.0.tgz", - "integrity": "sha512-dNfsf2tu3/QUD1mvZzzTze8RwHyK2Jrt+Ary8EDKdNKMw+abtCpQYNerdrg0ZQPxvwu/OOQz6N1xCsCwsPkQJg==" + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/base/-/base-0.21.1.tgz", + "integrity": "sha512-d3aHPpLHigeNTceMi0U/wOIzCqkvHg8S2gNa4b8VGSTifbn7Fo1XbQ2pzetbcOtwtJhkcLgNYn3nFqW8S2MUpw==" }, "@bitbybit-dev/core": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/core/-/core-0.21.0.tgz", - "integrity": "sha512-IbeQ8ROreu0/RkkngUE+Eb19ecvqKOWhGefXvIqQmplxt3zEc0FI4Kw8wR3vYl2XMannuVt1xAIYtqqH0tjBzg==", - "requires": { - "@bitbybit-dev/base": "0.21.0", - "@bitbybit-dev/jscad-worker": "0.21.0", - "@bitbybit-dev/manifold-worker": "0.21.0", - "@bitbybit-dev/occt-worker": "0.21.0", - "jsonpath-plus": "10.1.0", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/core/-/core-0.21.1.tgz", + "integrity": "sha512-Zr2w4h1eBRgOHevKevTaDeL1KlOju6Q8uT62zLeKAAAAn5P1RNn2jOVnHEJtd7y4wPn7G2rZwlwtBQlYe5t9AQ==", + "requires": { + "@bitbybit-dev/base": "0.21.1", + "@bitbybit-dev/jscad-worker": "0.21.1", + "@bitbybit-dev/manifold-worker": "0.21.1", + "@bitbybit-dev/occt-worker": "0.21.1", + "jsonpath-plus": "10.3.0", "rxjs": "7.5.5", "verb-nurbs-web": "2.1.3" } }, "@bitbybit-dev/jscad": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/jscad/-/jscad-0.21.0.tgz", - "integrity": "sha512-Q7eE2ILrJRstW4L1711aJZdpwPf1kuhZJqB+KLkkBLsneRsGsh82lBcCbVYAOMuF/q8Lnd4JHxPiIG/m+LYmPQ==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/jscad/-/jscad-0.21.1.tgz", + "integrity": "sha512-nw8dHGYy3GPXoX0xLZeVsB0Z013mzIy4GoniLKvzN7ApnTruPxSFisxrvFajCcQpL5UbU8SW4k+LhJDI8FTlRg==", "requires": { - "@bitbybit-dev/base": "0.21.0", + "@bitbybit-dev/base": "0.21.1", "@jscad/3mf-serializer": "2.1.12", "@jscad/dxf-serializer": "2.1.18", "@jscad/io-utils": "2.0.28", @@ -14432,55 +14432,55 @@ } }, "@bitbybit-dev/jscad-worker": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/jscad-worker/-/jscad-worker-0.21.0.tgz", - "integrity": "sha512-nIvd7GH5Gg51u6PmFXOADXVYTIvixTkNf0YapS1uix7D2JS9Mx10Z4wHAeRKzvJxUAAbEPPRFNkakE22HFGtLQ==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/jscad-worker/-/jscad-worker-0.21.1.tgz", + "integrity": "sha512-ccaXGTnKseWGDGEdgf3HfQqBWmM4Q384NQWO2kdzZ4EHaZlSp9tEHY8NHOxyxPoMol+qK9u9puH4ux13zY+FrQ==", "requires": { - "@bitbybit-dev/jscad": "0.21.0", + "@bitbybit-dev/jscad": "0.21.1", "rxjs": "7.5.5" } }, "@bitbybit-dev/manifold": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/manifold/-/manifold-0.21.0.tgz", - "integrity": "sha512-DPpwK9ESB+auDeAbzXcfWRVEzWoMDkpkjc+/uwh+zuSiHSx92PSkzx1/LVTbQCsK+aOfOOy03HQCF5Bu2KQYtw==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/manifold/-/manifold-0.21.1.tgz", + "integrity": "sha512-/UqejYCN9YIyBzf5yQXPdSawoKqEUd1aQAKdmge4LoUaZ19eQyRHLK4WpZQ8K+7lTr7qcNQARr7mLx0FQMBFew==", "requires": { - "@bitbybit-dev/base": "0.21.0", + "@bitbybit-dev/base": "0.21.1", "manifold-3d": "3.3.2" } }, "@bitbybit-dev/manifold-worker": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/manifold-worker/-/manifold-worker-0.21.0.tgz", - "integrity": "sha512-6Cqv3BP+uI8mHKHI6Jx9TzCxRg1/kMHhCe18+B3KD/rTl9B5mnScCKRBnDansR3bH7aYZGnIw9PmiFnWLkQWEQ==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/manifold-worker/-/manifold-worker-0.21.1.tgz", + "integrity": "sha512-A+oV172dZzehkeF5kdCFzQuyyfj9FLixq5nGNviOpJX3zaF+0efl1ung1o45V5pLtZkuGCgCZaQ6lY0zNQcYig==", "requires": { - "@bitbybit-dev/manifold": "0.21.0", + "@bitbybit-dev/manifold": "0.21.1", "rxjs": "7.5.5" } }, "@bitbybit-dev/occt": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/occt/-/occt-0.21.0.tgz", - "integrity": "sha512-vPu3NmF1kBZMOkOdysolGfFxEEnwdHNGORoX3eWbMWT2JL/Tag5Q2CAc5jwa2VvZnS1nE/9x+DVlFQSo8LQnIg==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/occt/-/occt-0.21.1.tgz", + "integrity": "sha512-0+yffQRmph9W1qLSyRBUvaQDiZ9OHA2kD2/LsCgxR3NVtKs3GZaAYYhoUfaRqtt2I8Go99e8WBB5daaQceudjA==", "requires": { - "@bitbybit-dev/base": "0.21.0" + "@bitbybit-dev/base": "0.21.1" } }, "@bitbybit-dev/occt-worker": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/occt-worker/-/occt-worker-0.21.0.tgz", - "integrity": "sha512-xG1sgo6q/RdVA8AgG72wPe4qxcQlrO1V7/Ksn6MqIhZVTsJcm5RbVYlK+nziIWhvlMc1sKE0GNQFcPdALISLuQ==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/occt-worker/-/occt-worker-0.21.1.tgz", + "integrity": "sha512-3BW0lTiY8muPSiCWplAT/VQHaHFVUvljMGD1ynQo7cqv/Zna9ACn+SHOMY2HJ7m1MnZq5d2dGjJJXo8k19iV8Q==", "requires": { - "@bitbybit-dev/occt": "0.21.0", + "@bitbybit-dev/occt": "0.21.1", "rxjs": "7.5.5" } }, "@bitbybit-dev/threejs": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/threejs/-/threejs-0.21.0.tgz", - "integrity": "sha512-p0fHuLTjoXs3UIWoC2TFUBAhu0F4sTPU//PCvwwPLmLrbrVmpEFV61tGs0739hbU4eKS5goCTUM99RfjbRxW6A==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/threejs/-/threejs-0.21.1.tgz", + "integrity": "sha512-BXQXMB0QIpvUNCRuVM6KJKn0Of/XBY0+Mt+GlyBe/s0Npk5XX9D4WYUX4A7byKGfhQxE/+FczLGs4ibcuipfmA==", "requires": { - "@bitbybit-dev/core": "0.21.0", + "@bitbybit-dev/core": "0.21.1", "three": "0.182.0" } }, @@ -18445,13 +18445,13 @@ "dev": true }, "jsonpath-plus": { - "version": "10.1.0", - "resolved": "https://registry.npmjs.org/jsonpath-plus/-/jsonpath-plus-10.1.0.tgz", - "integrity": "sha512-gHfV1IYqH8uJHYVTs8BJX1XKy2/rR93+f8QQi0xhx95aCiXn1ettYAd5T+7FU6wfqyDoX/wy0pm/fL3jOKJ9Lg==", + "version": "10.3.0", + "resolved": "https://registry.npmjs.org/jsonpath-plus/-/jsonpath-plus-10.3.0.tgz", + "integrity": "sha512-8TNmfeTCk2Le33A3vRRwtuworG/L5RrgMvdjhKZxvyShO+mBu2fP50OWUjRLNtvw344DdDarFh9buFAZs5ujeA==", "requires": { - "@jsep-plugin/assignment": "^1.2.1", - "@jsep-plugin/regex": "^1.0.3", - "jsep": "^1.3.9" + "@jsep-plugin/assignment": "^1.3.0", + "@jsep-plugin/regex": "^1.0.4", + "jsep": "^1.4.0" } }, "karma": { diff --git a/examples/angular/threejs/simple/package.json b/examples/angular/threejs/simple/package.json index b3122257..19b517eb 100644 --- a/examples/angular/threejs/simple/package.json +++ b/examples/angular/threejs/simple/package.json @@ -10,7 +10,7 @@ }, "private": true, "dependencies": { - "@bitbybit-dev/threejs": "0.21.0", + "@bitbybit-dev/threejs": "0.21.1", "@angular/animations": "13.3.0", "@angular/common": "13.3.0", "@angular/compiler": "13.3.0", diff --git a/examples/angular/threejs/vite-basic-example/package-lock.json b/examples/angular/threejs/vite-basic-example/package-lock.json index 88c4c047..ecae6a35 100644 --- a/examples/angular/threejs/vite-basic-example/package-lock.json +++ b/examples/angular/threejs/vite-basic-example/package-lock.json @@ -13,7 +13,7 @@ "@angular/forms": "^20.0.0", "@angular/platform-browser": "^20.0.0", "@angular/router": "^20.0.0", - "@bitbybit-dev/threejs": "0.21.0", + "@bitbybit-dev/threejs": "0.21.1", "rxjs": "7.5.5", "tslib": "^2.5.0", "zone.js": "~0.15.0" @@ -929,33 +929,33 @@ } }, "node_modules/@bitbybit-dev/base": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/base/-/base-0.21.0.tgz", - "integrity": "sha512-dNfsf2tu3/QUD1mvZzzTze8RwHyK2Jrt+Ary8EDKdNKMw+abtCpQYNerdrg0ZQPxvwu/OOQz6N1xCsCwsPkQJg==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/base/-/base-0.21.1.tgz", + "integrity": "sha512-d3aHPpLHigeNTceMi0U/wOIzCqkvHg8S2gNa4b8VGSTifbn7Fo1XbQ2pzetbcOtwtJhkcLgNYn3nFqW8S2MUpw==", "license": "MIT" }, "node_modules/@bitbybit-dev/core": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/core/-/core-0.21.0.tgz", - "integrity": "sha512-IbeQ8ROreu0/RkkngUE+Eb19ecvqKOWhGefXvIqQmplxt3zEc0FI4Kw8wR3vYl2XMannuVt1xAIYtqqH0tjBzg==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/core/-/core-0.21.1.tgz", + "integrity": "sha512-Zr2w4h1eBRgOHevKevTaDeL1KlOju6Q8uT62zLeKAAAAn5P1RNn2jOVnHEJtd7y4wPn7G2rZwlwtBQlYe5t9AQ==", "license": "MIT", "dependencies": { - "@bitbybit-dev/base": "0.21.0", - "@bitbybit-dev/jscad-worker": "0.21.0", - "@bitbybit-dev/manifold-worker": "0.21.0", - "@bitbybit-dev/occt-worker": "0.21.0", - "jsonpath-plus": "10.1.0", + "@bitbybit-dev/base": "0.21.1", + "@bitbybit-dev/jscad-worker": "0.21.1", + "@bitbybit-dev/manifold-worker": "0.21.1", + "@bitbybit-dev/occt-worker": "0.21.1", + "jsonpath-plus": "10.3.0", "rxjs": "7.5.5", "verb-nurbs-web": "2.1.3" } }, "node_modules/@bitbybit-dev/jscad": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/jscad/-/jscad-0.21.0.tgz", - "integrity": "sha512-Q7eE2ILrJRstW4L1711aJZdpwPf1kuhZJqB+KLkkBLsneRsGsh82lBcCbVYAOMuF/q8Lnd4JHxPiIG/m+LYmPQ==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/jscad/-/jscad-0.21.1.tgz", + "integrity": "sha512-nw8dHGYy3GPXoX0xLZeVsB0Z013mzIy4GoniLKvzN7ApnTruPxSFisxrvFajCcQpL5UbU8SW4k+LhJDI8FTlRg==", "license": "MIT", "dependencies": { - "@bitbybit-dev/base": "0.21.0", + "@bitbybit-dev/base": "0.21.1", "@jscad/3mf-serializer": "2.1.12", "@jscad/dxf-serializer": "2.1.18", "@jscad/io-utils": "2.0.28", @@ -964,61 +964,61 @@ } }, "node_modules/@bitbybit-dev/jscad-worker": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/jscad-worker/-/jscad-worker-0.21.0.tgz", - "integrity": "sha512-nIvd7GH5Gg51u6PmFXOADXVYTIvixTkNf0YapS1uix7D2JS9Mx10Z4wHAeRKzvJxUAAbEPPRFNkakE22HFGtLQ==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/jscad-worker/-/jscad-worker-0.21.1.tgz", + "integrity": "sha512-ccaXGTnKseWGDGEdgf3HfQqBWmM4Q384NQWO2kdzZ4EHaZlSp9tEHY8NHOxyxPoMol+qK9u9puH4ux13zY+FrQ==", "license": "MIT", "dependencies": { - "@bitbybit-dev/jscad": "0.21.0", + "@bitbybit-dev/jscad": "0.21.1", "rxjs": "7.5.5" } }, "node_modules/@bitbybit-dev/manifold": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/manifold/-/manifold-0.21.0.tgz", - "integrity": "sha512-DPpwK9ESB+auDeAbzXcfWRVEzWoMDkpkjc+/uwh+zuSiHSx92PSkzx1/LVTbQCsK+aOfOOy03HQCF5Bu2KQYtw==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/manifold/-/manifold-0.21.1.tgz", + "integrity": "sha512-/UqejYCN9YIyBzf5yQXPdSawoKqEUd1aQAKdmge4LoUaZ19eQyRHLK4WpZQ8K+7lTr7qcNQARr7mLx0FQMBFew==", "license": "MIT", "dependencies": { - "@bitbybit-dev/base": "0.21.0", + "@bitbybit-dev/base": "0.21.1", "manifold-3d": "3.3.2" } }, "node_modules/@bitbybit-dev/manifold-worker": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/manifold-worker/-/manifold-worker-0.21.0.tgz", - "integrity": "sha512-6Cqv3BP+uI8mHKHI6Jx9TzCxRg1/kMHhCe18+B3KD/rTl9B5mnScCKRBnDansR3bH7aYZGnIw9PmiFnWLkQWEQ==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/manifold-worker/-/manifold-worker-0.21.1.tgz", + "integrity": "sha512-A+oV172dZzehkeF5kdCFzQuyyfj9FLixq5nGNviOpJX3zaF+0efl1ung1o45V5pLtZkuGCgCZaQ6lY0zNQcYig==", "license": "MIT", "dependencies": { - "@bitbybit-dev/manifold": "0.21.0", + "@bitbybit-dev/manifold": "0.21.1", "rxjs": "7.5.5" } }, "node_modules/@bitbybit-dev/occt": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/occt/-/occt-0.21.0.tgz", - "integrity": "sha512-vPu3NmF1kBZMOkOdysolGfFxEEnwdHNGORoX3eWbMWT2JL/Tag5Q2CAc5jwa2VvZnS1nE/9x+DVlFQSo8LQnIg==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/occt/-/occt-0.21.1.tgz", + "integrity": "sha512-0+yffQRmph9W1qLSyRBUvaQDiZ9OHA2kD2/LsCgxR3NVtKs3GZaAYYhoUfaRqtt2I8Go99e8WBB5daaQceudjA==", "license": "MIT", "dependencies": { - "@bitbybit-dev/base": "0.21.0" + "@bitbybit-dev/base": "0.21.1" } }, "node_modules/@bitbybit-dev/occt-worker": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/occt-worker/-/occt-worker-0.21.0.tgz", - "integrity": "sha512-xG1sgo6q/RdVA8AgG72wPe4qxcQlrO1V7/Ksn6MqIhZVTsJcm5RbVYlK+nziIWhvlMc1sKE0GNQFcPdALISLuQ==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/occt-worker/-/occt-worker-0.21.1.tgz", + "integrity": "sha512-3BW0lTiY8muPSiCWplAT/VQHaHFVUvljMGD1ynQo7cqv/Zna9ACn+SHOMY2HJ7m1MnZq5d2dGjJJXo8k19iV8Q==", "license": "MIT", "dependencies": { - "@bitbybit-dev/occt": "0.21.0", + "@bitbybit-dev/occt": "0.21.1", "rxjs": "7.5.5" } }, "node_modules/@bitbybit-dev/threejs": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/threejs/-/threejs-0.21.0.tgz", - "integrity": "sha512-p0fHuLTjoXs3UIWoC2TFUBAhu0F4sTPU//PCvwwPLmLrbrVmpEFV61tGs0739hbU4eKS5goCTUM99RfjbRxW6A==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/threejs/-/threejs-0.21.1.tgz", + "integrity": "sha512-BXQXMB0QIpvUNCRuVM6KJKn0Of/XBY0+Mt+GlyBe/s0Npk5XX9D4WYUX4A7byKGfhQxE/+FczLGs4ibcuipfmA==", "license": "MIT", "dependencies": { - "@bitbybit-dev/core": "0.21.0", + "@bitbybit-dev/core": "0.21.1", "three": "0.182.0" } }, @@ -6149,14 +6149,14 @@ "license": "MIT" }, "node_modules/jsonpath-plus": { - "version": "10.1.0", - "resolved": "https://registry.npmjs.org/jsonpath-plus/-/jsonpath-plus-10.1.0.tgz", - "integrity": "sha512-gHfV1IYqH8uJHYVTs8BJX1XKy2/rR93+f8QQi0xhx95aCiXn1ettYAd5T+7FU6wfqyDoX/wy0pm/fL3jOKJ9Lg==", + "version": "10.3.0", + "resolved": "https://registry.npmjs.org/jsonpath-plus/-/jsonpath-plus-10.3.0.tgz", + "integrity": "sha512-8TNmfeTCk2Le33A3vRRwtuworG/L5RrgMvdjhKZxvyShO+mBu2fP50OWUjRLNtvw344DdDarFh9buFAZs5ujeA==", "license": "MIT", "dependencies": { - "@jsep-plugin/assignment": "^1.2.1", - "@jsep-plugin/regex": "^1.0.3", - "jsep": "^1.3.9" + "@jsep-plugin/assignment": "^1.3.0", + "@jsep-plugin/regex": "^1.0.4", + "jsep": "^1.4.0" }, "bin": { "jsonpath": "bin/jsonpath-cli.js", @@ -7842,10 +7842,13 @@ } }, "node_modules/sax": { - "version": "1.4.3", - "resolved": "https://registry.npmjs.org/sax/-/sax-1.4.3.tgz", - "integrity": "sha512-yqYn1JhPczigF94DMS+shiDMjDowYO6y9+wB/4WgO0Y19jWYk0lQ4tuG5KI7kj4FTp1wxPj5IFfcrz/s1c3jjQ==", - "license": "BlueOak-1.0.0" + "version": "1.4.4", + "resolved": "https://registry.npmjs.org/sax/-/sax-1.4.4.tgz", + "integrity": "sha512-1n3r/tGXO6b6VXMdFT54SHzT9ytu9yr7TaELowdYpMqY/Ao7EnlQGmAQ1+RatX7Tkkdm6hONI2owqNx2aZj5Sw==", + "license": "BlueOak-1.0.0", + "engines": { + "node": ">=11.0.0" + } }, "node_modules/semver": { "version": "7.7.2", diff --git a/examples/angular/threejs/vite-basic-example/package.json b/examples/angular/threejs/vite-basic-example/package.json index 06a23538..3bd2e6d5 100644 --- a/examples/angular/threejs/vite-basic-example/package.json +++ b/examples/angular/threejs/vite-basic-example/package.json @@ -14,7 +14,7 @@ "@angular/forms": "^20.0.0", "@angular/platform-browser": "^20.0.0", "@angular/router": "^20.0.0", - "@bitbybit-dev/threejs": "0.21.0", + "@bitbybit-dev/threejs": "0.21.1", "rxjs": "7.5.5", "tslib": "^2.5.0", "zone.js": "~0.15.0" diff --git a/examples/angular/threejs/vite-basic-example/src/workers/manifold.worker.ts b/examples/angular/threejs/vite-basic-example/src/workers/manifold.worker.ts index 09625fcb..01d47f90 100644 --- a/examples/angular/threejs/vite-basic-example/src/workers/manifold.worker.ts +++ b/examples/angular/threejs/vite-basic-example/src/workers/manifold.worker.ts @@ -7,7 +7,7 @@ import Module from "manifold-3d"; const init = async () => { const wasm = await Module({ locateFile: () => { - return "https://cdn.jsdelivr.net/gh/bitbybit-dev/bitbybit-assets@0.21.0/wasm/manifold-3-3-2.wasm"; + return "https://cdn.jsdelivr.net/gh/bitbybit-dev/bitbybit-assets@0.21.1/wasm/manifold-3-3-2.wasm"; }, }); wasm.setup(); diff --git a/examples/nextjs/babylonjs/simple/package-lock.json b/examples/nextjs/babylonjs/simple/package-lock.json index c83a835a..564a198c 100644 --- a/examples/nextjs/babylonjs/simple/package-lock.json +++ b/examples/nextjs/babylonjs/simple/package-lock.json @@ -8,7 +8,7 @@ "name": "simple", "version": "0.1.0", "dependencies": { - "@bitbybit-dev/babylonjs": "0.21.0", + "@bitbybit-dev/babylonjs": "0.21.1", "file-loader": "6.2.0", "next": "15.0.1", "react": "19.0.0-rc-69d4b800-20241021", @@ -38,15 +38,15 @@ } }, "node_modules/@babylonjs/core": { - "version": "8.44.1", - "resolved": "https://registry.npmjs.org/@babylonjs/core/-/core-8.44.1.tgz", - "integrity": "sha512-sF2WWK2d7lg18ESOCxUoRG4d1SzCWz42asjRjRGxZ8r3D7w9ZM3H2wftJIqwaZvD3zWr+wmCVKpQ6hWkboHIXw==", + "version": "8.45.4", + "resolved": "https://registry.npmjs.org/@babylonjs/core/-/core-8.45.4.tgz", + "integrity": "sha512-fmpaitVpe+bB3PCLY0RKYO/e5n1vLNvueJrglt6SENVE/frZNS4har8odAd1UDNf5KFgOdb8YK91jK4BUwIgcQ==", "license": "Apache-2.0" }, "node_modules/@babylonjs/gui": { - "version": "8.44.1", - "resolved": "https://registry.npmjs.org/@babylonjs/gui/-/gui-8.44.1.tgz", - "integrity": "sha512-6STDK+Hr8GpY29YMLKnTVhEnWw1NKPrIpz+MqgWuoAAmmpiFtNCr0nnAnCj5fhgGf25L89jy51ogXyg3jfiuDA==", + "version": "8.45.4", + "resolved": "https://registry.npmjs.org/@babylonjs/gui/-/gui-8.45.4.tgz", + "integrity": "sha512-1pMjQs7fgSEvUQoXyit96kNRqzX74oMNkMkAOmz7NjOkBX3tacAfNfoEC6aw+AB+iAjlCO5/DXatZU5m6EYyIQ==", "license": "Apache-2.0", "peerDependencies": { "@babylonjs/core": "^8.0.0" @@ -61,9 +61,9 @@ } }, "node_modules/@babylonjs/loaders": { - "version": "8.44.1", - "resolved": "https://registry.npmjs.org/@babylonjs/loaders/-/loaders-8.44.1.tgz", - "integrity": "sha512-h5rUGCwhdWv3Hq48DP8sy4/+3QUYjOprxu2i6zXKb69LHMnYE0tZ1xQHBJEOUF60hxA+TwhzdjC8bxInKoeojA==", + "version": "8.45.4", + "resolved": "https://registry.npmjs.org/@babylonjs/loaders/-/loaders-8.45.4.tgz", + "integrity": "sha512-P1H8XpIJK7NnrtGGSGkCJZIPBvtJ+0+l7yGXDY2UaNFKU80y2Oty8DZ8JRKdbJdSc4cOe8ucBY5w7x+Bbllxuw==", "license": "Apache-2.0", "peerDependencies": { "@babylonjs/core": "^8.0.0", @@ -71,18 +71,18 @@ } }, "node_modules/@babylonjs/materials": { - "version": "8.44.1", - "resolved": "https://registry.npmjs.org/@babylonjs/materials/-/materials-8.44.1.tgz", - "integrity": "sha512-FD0S/aA68oEjKCSNY5ydGkiHbsyo08KlhQ+6R8swtJhx5aq7ojWBt3P9KC78+wjZiCJW37176CIObcV8QcjMAQ==", + "version": "8.45.4", + "resolved": "https://registry.npmjs.org/@babylonjs/materials/-/materials-8.45.4.tgz", + "integrity": "sha512-ElTXhC83alnMFFyv2sPG/Im5UwTZoDzd1R8otPQwbEEERcRK8A71Hu1gFdBu/8l9O752IWnZcPSEj1WwLqeR5A==", "license": "Apache-2.0", "peerDependencies": { "@babylonjs/core": "^8.6.0" } }, "node_modules/@babylonjs/serializers": { - "version": "8.44.1", - "resolved": "https://registry.npmjs.org/@babylonjs/serializers/-/serializers-8.44.1.tgz", - "integrity": "sha512-3FRRdKpHr2qTkALHEvq0ih0P59iTINUFrGZWFUfO3Wu24UBSuTxY9Kq820dvUUWaRtWkXEnMSQbR+5glzcfqBw==", + "version": "8.45.4", + "resolved": "https://registry.npmjs.org/@babylonjs/serializers/-/serializers-8.45.4.tgz", + "integrity": "sha512-i83RQIP3XSi3DFJwhc/+JNNPm49DdtNyDobuyBBwIDyMpQdbcFLhkL0DW/7/H+vFUWz0xWx+mgmsb6HY/ePGmg==", "license": "Apache-2.0", "peerDependencies": { "@babylonjs/core": "^8.0.0", @@ -90,49 +90,49 @@ } }, "node_modules/@bitbybit-dev/babylonjs": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/babylonjs/-/babylonjs-0.21.0.tgz", - "integrity": "sha512-8aPJ+XTXzcnO4bXfmW34lTnVCzC6Hy6TMkh7/ziQSoUsjPp7e7LFHoBBfqCk09LdTLa85gb5x/f6WNAn306Odg==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/babylonjs/-/babylonjs-0.21.1.tgz", + "integrity": "sha512-OyQI5FC4qI5EYW/RFZt/6WR2We2bEpbhM8I8ptiJkviY0e1yIjiV11A4aF8B6fpjS5Bd7Rb30LrUdWNHbAo1Nw==", "license": "MIT", "dependencies": { - "@babylonjs/core": "8.44.1", - "@babylonjs/gui": "8.44.1", + "@babylonjs/core": "8.45.4", + "@babylonjs/gui": "8.45.4", "@babylonjs/havok": "1.3.10", - "@babylonjs/loaders": "8.44.1", - "@babylonjs/materials": "8.44.1", - "@babylonjs/serializers": "8.44.1", - "@bitbybit-dev/core": "0.21.0", + "@babylonjs/loaders": "8.45.4", + "@babylonjs/materials": "8.45.4", + "@babylonjs/serializers": "8.45.4", + "@bitbybit-dev/core": "0.21.1", "earcut": "2.2.3" } }, "node_modules/@bitbybit-dev/base": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/base/-/base-0.21.0.tgz", - "integrity": "sha512-dNfsf2tu3/QUD1mvZzzTze8RwHyK2Jrt+Ary8EDKdNKMw+abtCpQYNerdrg0ZQPxvwu/OOQz6N1xCsCwsPkQJg==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/base/-/base-0.21.1.tgz", + "integrity": "sha512-d3aHPpLHigeNTceMi0U/wOIzCqkvHg8S2gNa4b8VGSTifbn7Fo1XbQ2pzetbcOtwtJhkcLgNYn3nFqW8S2MUpw==", "license": "MIT" }, "node_modules/@bitbybit-dev/core": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/core/-/core-0.21.0.tgz", - "integrity": "sha512-IbeQ8ROreu0/RkkngUE+Eb19ecvqKOWhGefXvIqQmplxt3zEc0FI4Kw8wR3vYl2XMannuVt1xAIYtqqH0tjBzg==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/core/-/core-0.21.1.tgz", + "integrity": "sha512-Zr2w4h1eBRgOHevKevTaDeL1KlOju6Q8uT62zLeKAAAAn5P1RNn2jOVnHEJtd7y4wPn7G2rZwlwtBQlYe5t9AQ==", "license": "MIT", "dependencies": { - "@bitbybit-dev/base": "0.21.0", - "@bitbybit-dev/jscad-worker": "0.21.0", - "@bitbybit-dev/manifold-worker": "0.21.0", - "@bitbybit-dev/occt-worker": "0.21.0", - "jsonpath-plus": "10.1.0", + "@bitbybit-dev/base": "0.21.1", + "@bitbybit-dev/jscad-worker": "0.21.1", + "@bitbybit-dev/manifold-worker": "0.21.1", + "@bitbybit-dev/occt-worker": "0.21.1", + "jsonpath-plus": "10.3.0", "rxjs": "7.5.5", "verb-nurbs-web": "2.1.3" } }, "node_modules/@bitbybit-dev/jscad": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/jscad/-/jscad-0.21.0.tgz", - "integrity": "sha512-Q7eE2ILrJRstW4L1711aJZdpwPf1kuhZJqB+KLkkBLsneRsGsh82lBcCbVYAOMuF/q8Lnd4JHxPiIG/m+LYmPQ==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/jscad/-/jscad-0.21.1.tgz", + "integrity": "sha512-nw8dHGYy3GPXoX0xLZeVsB0Z013mzIy4GoniLKvzN7ApnTruPxSFisxrvFajCcQpL5UbU8SW4k+LhJDI8FTlRg==", "license": "MIT", "dependencies": { - "@bitbybit-dev/base": "0.21.0", + "@bitbybit-dev/base": "0.21.1", "@jscad/3mf-serializer": "2.1.12", "@jscad/dxf-serializer": "2.1.18", "@jscad/io-utils": "2.0.28", @@ -141,51 +141,51 @@ } }, "node_modules/@bitbybit-dev/jscad-worker": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/jscad-worker/-/jscad-worker-0.21.0.tgz", - "integrity": "sha512-nIvd7GH5Gg51u6PmFXOADXVYTIvixTkNf0YapS1uix7D2JS9Mx10Z4wHAeRKzvJxUAAbEPPRFNkakE22HFGtLQ==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/jscad-worker/-/jscad-worker-0.21.1.tgz", + "integrity": "sha512-ccaXGTnKseWGDGEdgf3HfQqBWmM4Q384NQWO2kdzZ4EHaZlSp9tEHY8NHOxyxPoMol+qK9u9puH4ux13zY+FrQ==", "license": "MIT", "dependencies": { - "@bitbybit-dev/jscad": "0.21.0", + "@bitbybit-dev/jscad": "0.21.1", "rxjs": "7.5.5" } }, "node_modules/@bitbybit-dev/manifold": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/manifold/-/manifold-0.21.0.tgz", - "integrity": "sha512-DPpwK9ESB+auDeAbzXcfWRVEzWoMDkpkjc+/uwh+zuSiHSx92PSkzx1/LVTbQCsK+aOfOOy03HQCF5Bu2KQYtw==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/manifold/-/manifold-0.21.1.tgz", + "integrity": "sha512-/UqejYCN9YIyBzf5yQXPdSawoKqEUd1aQAKdmge4LoUaZ19eQyRHLK4WpZQ8K+7lTr7qcNQARr7mLx0FQMBFew==", "license": "MIT", "dependencies": { - "@bitbybit-dev/base": "0.21.0", + "@bitbybit-dev/base": "0.21.1", "manifold-3d": "3.3.2" } }, "node_modules/@bitbybit-dev/manifold-worker": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/manifold-worker/-/manifold-worker-0.21.0.tgz", - "integrity": "sha512-6Cqv3BP+uI8mHKHI6Jx9TzCxRg1/kMHhCe18+B3KD/rTl9B5mnScCKRBnDansR3bH7aYZGnIw9PmiFnWLkQWEQ==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/manifold-worker/-/manifold-worker-0.21.1.tgz", + "integrity": "sha512-A+oV172dZzehkeF5kdCFzQuyyfj9FLixq5nGNviOpJX3zaF+0efl1ung1o45V5pLtZkuGCgCZaQ6lY0zNQcYig==", "license": "MIT", "dependencies": { - "@bitbybit-dev/manifold": "0.21.0", + "@bitbybit-dev/manifold": "0.21.1", "rxjs": "7.5.5" } }, "node_modules/@bitbybit-dev/occt": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/occt/-/occt-0.21.0.tgz", - "integrity": "sha512-vPu3NmF1kBZMOkOdysolGfFxEEnwdHNGORoX3eWbMWT2JL/Tag5Q2CAc5jwa2VvZnS1nE/9x+DVlFQSo8LQnIg==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/occt/-/occt-0.21.1.tgz", + "integrity": "sha512-0+yffQRmph9W1qLSyRBUvaQDiZ9OHA2kD2/LsCgxR3NVtKs3GZaAYYhoUfaRqtt2I8Go99e8WBB5daaQceudjA==", "license": "MIT", "dependencies": { - "@bitbybit-dev/base": "0.21.0" + "@bitbybit-dev/base": "0.21.1" } }, "node_modules/@bitbybit-dev/occt-worker": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/occt-worker/-/occt-worker-0.21.0.tgz", - "integrity": "sha512-xG1sgo6q/RdVA8AgG72wPe4qxcQlrO1V7/Ksn6MqIhZVTsJcm5RbVYlK+nziIWhvlMc1sKE0GNQFcPdALISLuQ==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/occt-worker/-/occt-worker-0.21.1.tgz", + "integrity": "sha512-3BW0lTiY8muPSiCWplAT/VQHaHFVUvljMGD1ynQo7cqv/Zna9ACn+SHOMY2HJ7m1MnZq5d2dGjJJXo8k19iV8Q==", "license": "MIT", "dependencies": { - "@bitbybit-dev/occt": "0.21.0", + "@bitbybit-dev/occt": "0.21.1", "rxjs": "7.5.5" } }, @@ -1934,9 +1934,9 @@ } }, "node_modules/babylonjs-gltf2interface": { - "version": "8.44.1", - "resolved": "https://registry.npmjs.org/babylonjs-gltf2interface/-/babylonjs-gltf2interface-8.44.1.tgz", - "integrity": "sha512-+z0P0wms1FD5xuVpuRJ1qjvGAbPAWhEWGBWENRPD0Hbz6nd9cnL28/pjxgk39/QhlIuJKL9JZ0o8G0JgLHEnRQ==", + "version": "8.45.5", + "resolved": "https://registry.npmjs.org/babylonjs-gltf2interface/-/babylonjs-gltf2interface-8.45.5.tgz", + "integrity": "sha512-o1OMBVdeKCK7b+L1VUW1w1+KIi1DTP7Po+SAJ3vwPqRG6xD2eTL+w5IaFHVue3dVjnlU8Z+9y3BP3AadmK0H9w==", "license": "Apache-2.0", "peer": true }, @@ -4196,14 +4196,14 @@ } }, "node_modules/jsonpath-plus": { - "version": "10.1.0", - "resolved": "https://registry.npmjs.org/jsonpath-plus/-/jsonpath-plus-10.1.0.tgz", - "integrity": "sha512-gHfV1IYqH8uJHYVTs8BJX1XKy2/rR93+f8QQi0xhx95aCiXn1ettYAd5T+7FU6wfqyDoX/wy0pm/fL3jOKJ9Lg==", + "version": "10.3.0", + "resolved": "https://registry.npmjs.org/jsonpath-plus/-/jsonpath-plus-10.3.0.tgz", + "integrity": "sha512-8TNmfeTCk2Le33A3vRRwtuworG/L5RrgMvdjhKZxvyShO+mBu2fP50OWUjRLNtvw344DdDarFh9buFAZs5ujeA==", "license": "MIT", "dependencies": { - "@jsep-plugin/assignment": "^1.2.1", - "@jsep-plugin/regex": "^1.0.3", - "jsep": "^1.3.9" + "@jsep-plugin/assignment": "^1.3.0", + "@jsep-plugin/regex": "^1.0.4", + "jsep": "^1.4.0" }, "bin": { "jsonpath": "bin/jsonpath-cli.js", @@ -5818,10 +5818,13 @@ } }, "node_modules/sax": { - "version": "1.4.3", - "resolved": "https://registry.npmjs.org/sax/-/sax-1.4.3.tgz", - "integrity": "sha512-yqYn1JhPczigF94DMS+shiDMjDowYO6y9+wB/4WgO0Y19jWYk0lQ4tuG5KI7kj4FTp1wxPj5IFfcrz/s1c3jjQ==", - "license": "BlueOak-1.0.0" + "version": "1.4.4", + "resolved": "https://registry.npmjs.org/sax/-/sax-1.4.4.tgz", + "integrity": "sha512-1n3r/tGXO6b6VXMdFT54SHzT9ytu9yr7TaELowdYpMqY/Ao7EnlQGmAQ1+RatX7Tkkdm6hONI2owqNx2aZj5Sw==", + "license": "BlueOak-1.0.0", + "engines": { + "node": ">=11.0.0" + } }, "node_modules/scheduler": { "version": "0.25.0-rc-69d4b800-20241021", diff --git a/examples/nextjs/babylonjs/simple/package.json b/examples/nextjs/babylonjs/simple/package.json index 0783b369..60c40354 100644 --- a/examples/nextjs/babylonjs/simple/package.json +++ b/examples/nextjs/babylonjs/simple/package.json @@ -9,7 +9,7 @@ "lint": "next lint" }, "dependencies": { - "@bitbybit-dev/babylonjs": "0.21.0", + "@bitbybit-dev/babylonjs": "0.21.1", "react": "19.0.0-rc-69d4b800-20241021", "react-dom": "19.0.0-rc-69d4b800-20241021", "next": "15.0.1", diff --git a/examples/node/basic/package-lock.json b/examples/node/basic/package-lock.json index 6f5bf751..d9657fa5 100644 --- a/examples/node/basic/package-lock.json +++ b/examples/node/basic/package-lock.json @@ -9,7 +9,7 @@ "version": "1.0.0", "license": "MIT", "dependencies": { - "@bitbybit-dev/occt": "^0.21.0" + "@bitbybit-dev/occt": "^0.21.1" }, "devDependencies": { "concurrently": "^7.6.0", @@ -34,18 +34,18 @@ } }, "node_modules/@bitbybit-dev/base": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/base/-/base-0.21.0.tgz", - "integrity": "sha512-dNfsf2tu3/QUD1mvZzzTze8RwHyK2Jrt+Ary8EDKdNKMw+abtCpQYNerdrg0ZQPxvwu/OOQz6N1xCsCwsPkQJg==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/base/-/base-0.21.1.tgz", + "integrity": "sha512-d3aHPpLHigeNTceMi0U/wOIzCqkvHg8S2gNa4b8VGSTifbn7Fo1XbQ2pzetbcOtwtJhkcLgNYn3nFqW8S2MUpw==", "license": "MIT" }, "node_modules/@bitbybit-dev/occt": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/occt/-/occt-0.21.0.tgz", - "integrity": "sha512-vPu3NmF1kBZMOkOdysolGfFxEEnwdHNGORoX3eWbMWT2JL/Tag5Q2CAc5jwa2VvZnS1nE/9x+DVlFQSo8LQnIg==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/occt/-/occt-0.21.1.tgz", + "integrity": "sha512-0+yffQRmph9W1qLSyRBUvaQDiZ9OHA2kD2/LsCgxR3NVtKs3GZaAYYhoUfaRqtt2I8Go99e8WBB5daaQceudjA==", "license": "MIT", "dependencies": { - "@bitbybit-dev/base": "0.21.0" + "@bitbybit-dev/base": "0.21.1" } }, "node_modules/ansi-regex": { diff --git a/examples/node/basic/package.json b/examples/node/basic/package.json index c5f5dd6e..9e42551a 100644 --- a/examples/node/basic/package.json +++ b/examples/node/basic/package.json @@ -15,7 +15,7 @@ "node": ">=20.19.4" }, "dependencies": { - "@bitbybit-dev/occt": "^0.21.0" + "@bitbybit-dev/occt": "^0.21.1" }, "devDependencies": { "extensionless": "1.9.9", diff --git a/examples/node/express-app/package-lock.json b/examples/node/express-app/package-lock.json index d041066d..24c66639 100644 --- a/examples/node/express-app/package-lock.json +++ b/examples/node/express-app/package-lock.json @@ -9,7 +9,7 @@ "version": "1.0.0", "license": "MIT", "dependencies": { - "@bitbybit-dev/core": "0.21.0", + "@bitbybit-dev/core": "0.21.1", "cors": "^2.8.5", "dotenv": "^16.0.3", "express": "^4.18.2", @@ -41,33 +41,33 @@ } }, "node_modules/@bitbybit-dev/base": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/base/-/base-0.21.0.tgz", - "integrity": "sha512-dNfsf2tu3/QUD1mvZzzTze8RwHyK2Jrt+Ary8EDKdNKMw+abtCpQYNerdrg0ZQPxvwu/OOQz6N1xCsCwsPkQJg==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/base/-/base-0.21.1.tgz", + "integrity": "sha512-d3aHPpLHigeNTceMi0U/wOIzCqkvHg8S2gNa4b8VGSTifbn7Fo1XbQ2pzetbcOtwtJhkcLgNYn3nFqW8S2MUpw==", "license": "MIT" }, "node_modules/@bitbybit-dev/core": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/core/-/core-0.21.0.tgz", - "integrity": "sha512-IbeQ8ROreu0/RkkngUE+Eb19ecvqKOWhGefXvIqQmplxt3zEc0FI4Kw8wR3vYl2XMannuVt1xAIYtqqH0tjBzg==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/core/-/core-0.21.1.tgz", + "integrity": "sha512-Zr2w4h1eBRgOHevKevTaDeL1KlOju6Q8uT62zLeKAAAAn5P1RNn2jOVnHEJtd7y4wPn7G2rZwlwtBQlYe5t9AQ==", "license": "MIT", "dependencies": { - "@bitbybit-dev/base": "0.21.0", - "@bitbybit-dev/jscad-worker": "0.21.0", - "@bitbybit-dev/manifold-worker": "0.21.0", - "@bitbybit-dev/occt-worker": "0.21.0", - "jsonpath-plus": "10.1.0", + "@bitbybit-dev/base": "0.21.1", + "@bitbybit-dev/jscad-worker": "0.21.1", + "@bitbybit-dev/manifold-worker": "0.21.1", + "@bitbybit-dev/occt-worker": "0.21.1", + "jsonpath-plus": "10.3.0", "rxjs": "7.5.5", "verb-nurbs-web": "2.1.3" } }, "node_modules/@bitbybit-dev/jscad": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/jscad/-/jscad-0.21.0.tgz", - "integrity": "sha512-Q7eE2ILrJRstW4L1711aJZdpwPf1kuhZJqB+KLkkBLsneRsGsh82lBcCbVYAOMuF/q8Lnd4JHxPiIG/m+LYmPQ==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/jscad/-/jscad-0.21.1.tgz", + "integrity": "sha512-nw8dHGYy3GPXoX0xLZeVsB0Z013mzIy4GoniLKvzN7ApnTruPxSFisxrvFajCcQpL5UbU8SW4k+LhJDI8FTlRg==", "license": "MIT", "dependencies": { - "@bitbybit-dev/base": "0.21.0", + "@bitbybit-dev/base": "0.21.1", "@jscad/3mf-serializer": "2.1.12", "@jscad/dxf-serializer": "2.1.18", "@jscad/io-utils": "2.0.28", @@ -76,51 +76,51 @@ } }, "node_modules/@bitbybit-dev/jscad-worker": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/jscad-worker/-/jscad-worker-0.21.0.tgz", - "integrity": "sha512-nIvd7GH5Gg51u6PmFXOADXVYTIvixTkNf0YapS1uix7D2JS9Mx10Z4wHAeRKzvJxUAAbEPPRFNkakE22HFGtLQ==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/jscad-worker/-/jscad-worker-0.21.1.tgz", + "integrity": "sha512-ccaXGTnKseWGDGEdgf3HfQqBWmM4Q384NQWO2kdzZ4EHaZlSp9tEHY8NHOxyxPoMol+qK9u9puH4ux13zY+FrQ==", "license": "MIT", "dependencies": { - "@bitbybit-dev/jscad": "0.21.0", + "@bitbybit-dev/jscad": "0.21.1", "rxjs": "7.5.5" } }, "node_modules/@bitbybit-dev/manifold": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/manifold/-/manifold-0.21.0.tgz", - "integrity": "sha512-DPpwK9ESB+auDeAbzXcfWRVEzWoMDkpkjc+/uwh+zuSiHSx92PSkzx1/LVTbQCsK+aOfOOy03HQCF5Bu2KQYtw==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/manifold/-/manifold-0.21.1.tgz", + "integrity": "sha512-/UqejYCN9YIyBzf5yQXPdSawoKqEUd1aQAKdmge4LoUaZ19eQyRHLK4WpZQ8K+7lTr7qcNQARr7mLx0FQMBFew==", "license": "MIT", "dependencies": { - "@bitbybit-dev/base": "0.21.0", + "@bitbybit-dev/base": "0.21.1", "manifold-3d": "3.3.2" } }, "node_modules/@bitbybit-dev/manifold-worker": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/manifold-worker/-/manifold-worker-0.21.0.tgz", - "integrity": "sha512-6Cqv3BP+uI8mHKHI6Jx9TzCxRg1/kMHhCe18+B3KD/rTl9B5mnScCKRBnDansR3bH7aYZGnIw9PmiFnWLkQWEQ==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/manifold-worker/-/manifold-worker-0.21.1.tgz", + "integrity": "sha512-A+oV172dZzehkeF5kdCFzQuyyfj9FLixq5nGNviOpJX3zaF+0efl1ung1o45V5pLtZkuGCgCZaQ6lY0zNQcYig==", "license": "MIT", "dependencies": { - "@bitbybit-dev/manifold": "0.21.0", + "@bitbybit-dev/manifold": "0.21.1", "rxjs": "7.5.5" } }, "node_modules/@bitbybit-dev/occt": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/occt/-/occt-0.21.0.tgz", - "integrity": "sha512-vPu3NmF1kBZMOkOdysolGfFxEEnwdHNGORoX3eWbMWT2JL/Tag5Q2CAc5jwa2VvZnS1nE/9x+DVlFQSo8LQnIg==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/occt/-/occt-0.21.1.tgz", + "integrity": "sha512-0+yffQRmph9W1qLSyRBUvaQDiZ9OHA2kD2/LsCgxR3NVtKs3GZaAYYhoUfaRqtt2I8Go99e8WBB5daaQceudjA==", "license": "MIT", "dependencies": { - "@bitbybit-dev/base": "0.21.0" + "@bitbybit-dev/base": "0.21.1" } }, "node_modules/@bitbybit-dev/occt-worker": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/occt-worker/-/occt-worker-0.21.0.tgz", - "integrity": "sha512-xG1sgo6q/RdVA8AgG72wPe4qxcQlrO1V7/Ksn6MqIhZVTsJcm5RbVYlK+nziIWhvlMc1sKE0GNQFcPdALISLuQ==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/occt-worker/-/occt-worker-0.21.1.tgz", + "integrity": "sha512-3BW0lTiY8muPSiCWplAT/VQHaHFVUvljMGD1ynQo7cqv/Zna9ACn+SHOMY2HJ7m1MnZq5d2dGjJJXo8k19iV8Q==", "license": "MIT", "dependencies": { - "@bitbybit-dev/occt": "0.21.0", + "@bitbybit-dev/occt": "0.21.1", "rxjs": "7.5.5" } }, @@ -726,6 +726,7 @@ "version": "1.3.0", "resolved": "https://registry.npmjs.org/@jsep-plugin/assignment/-/assignment-1.3.0.tgz", "integrity": "sha512-VVgV+CXrhbMI3aSusQyclHkenWSAm95WaiKrMxRFam3JSUiIaQjoMIw2sEs/OX4XifnqeQUN4DYbJjlA8EfktQ==", + "license": "MIT", "engines": { "node": ">= 10.16.0" }, @@ -737,6 +738,7 @@ "version": "1.0.4", "resolved": "https://registry.npmjs.org/@jsep-plugin/regex/-/regex-1.0.4.tgz", "integrity": "sha512-q7qL4Mgjs1vByCaTnDFcBnV9HS7GVPJX5vyVoCgZHNSC9rjwIlmbXG5sUuorR5ndfHAIlJ8pVStxvjXHbNvtUg==", + "license": "MIT", "engines": { "node": ">= 10.16.0" }, @@ -1704,18 +1706,20 @@ "version": "1.4.0", "resolved": "https://registry.npmjs.org/jsep/-/jsep-1.4.0.tgz", "integrity": "sha512-B7qPcEVE3NVkmSJbaYxvv4cHkVW7DQsZz13pUMrfS8z8Q/BuShN+gcTXrUlPiGqM2/t/EEaI030bpxMqY8gMlw==", + "license": "MIT", "engines": { "node": ">= 10.16.0" } }, "node_modules/jsonpath-plus": { - "version": "10.1.0", - "resolved": "https://registry.npmjs.org/jsonpath-plus/-/jsonpath-plus-10.1.0.tgz", - "integrity": "sha512-gHfV1IYqH8uJHYVTs8BJX1XKy2/rR93+f8QQi0xhx95aCiXn1ettYAd5T+7FU6wfqyDoX/wy0pm/fL3jOKJ9Lg==", + "version": "10.3.0", + "resolved": "https://registry.npmjs.org/jsonpath-plus/-/jsonpath-plus-10.3.0.tgz", + "integrity": "sha512-8TNmfeTCk2Le33A3vRRwtuworG/L5RrgMvdjhKZxvyShO+mBu2fP50OWUjRLNtvw344DdDarFh9buFAZs5ujeA==", + "license": "MIT", "dependencies": { - "@jsep-plugin/assignment": "^1.2.1", - "@jsep-plugin/regex": "^1.0.3", - "jsep": "^1.3.9" + "@jsep-plugin/assignment": "^1.3.0", + "@jsep-plugin/regex": "^1.0.4", + "jsep": "^1.4.0" }, "bin": { "jsonpath": "bin/jsonpath-cli.js", @@ -2171,10 +2175,13 @@ "integrity": "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==" }, "node_modules/sax": { - "version": "1.4.3", - "resolved": "https://registry.npmjs.org/sax/-/sax-1.4.3.tgz", - "integrity": "sha512-yqYn1JhPczigF94DMS+shiDMjDowYO6y9+wB/4WgO0Y19jWYk0lQ4tuG5KI7kj4FTp1wxPj5IFfcrz/s1c3jjQ==", - "license": "BlueOak-1.0.0" + "version": "1.4.4", + "resolved": "https://registry.npmjs.org/sax/-/sax-1.4.4.tgz", + "integrity": "sha512-1n3r/tGXO6b6VXMdFT54SHzT9ytu9yr7TaELowdYpMqY/Ao7EnlQGmAQ1+RatX7Tkkdm6hONI2owqNx2aZj5Sw==", + "license": "BlueOak-1.0.0", + "engines": { + "node": ">=11.0.0" + } }, "node_modules/semver": { "version": "5.7.2", @@ -2633,30 +2640,30 @@ } }, "@bitbybit-dev/base": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/base/-/base-0.21.0.tgz", - "integrity": "sha512-dNfsf2tu3/QUD1mvZzzTze8RwHyK2Jrt+Ary8EDKdNKMw+abtCpQYNerdrg0ZQPxvwu/OOQz6N1xCsCwsPkQJg==" + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/base/-/base-0.21.1.tgz", + "integrity": "sha512-d3aHPpLHigeNTceMi0U/wOIzCqkvHg8S2gNa4b8VGSTifbn7Fo1XbQ2pzetbcOtwtJhkcLgNYn3nFqW8S2MUpw==" }, "@bitbybit-dev/core": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/core/-/core-0.21.0.tgz", - "integrity": "sha512-IbeQ8ROreu0/RkkngUE+Eb19ecvqKOWhGefXvIqQmplxt3zEc0FI4Kw8wR3vYl2XMannuVt1xAIYtqqH0tjBzg==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/core/-/core-0.21.1.tgz", + "integrity": "sha512-Zr2w4h1eBRgOHevKevTaDeL1KlOju6Q8uT62zLeKAAAAn5P1RNn2jOVnHEJtd7y4wPn7G2rZwlwtBQlYe5t9AQ==", "requires": { - "@bitbybit-dev/base": "0.21.0", - "@bitbybit-dev/jscad-worker": "0.21.0", - "@bitbybit-dev/manifold-worker": "0.21.0", - "@bitbybit-dev/occt-worker": "0.21.0", - "jsonpath-plus": "10.1.0", + "@bitbybit-dev/base": "0.21.1", + "@bitbybit-dev/jscad-worker": "0.21.1", + "@bitbybit-dev/manifold-worker": "0.21.1", + "@bitbybit-dev/occt-worker": "0.21.1", + "jsonpath-plus": "10.3.0", "rxjs": "7.5.5", "verb-nurbs-web": "2.1.3" } }, "@bitbybit-dev/jscad": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/jscad/-/jscad-0.21.0.tgz", - "integrity": "sha512-Q7eE2ILrJRstW4L1711aJZdpwPf1kuhZJqB+KLkkBLsneRsGsh82lBcCbVYAOMuF/q8Lnd4JHxPiIG/m+LYmPQ==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/jscad/-/jscad-0.21.1.tgz", + "integrity": "sha512-nw8dHGYy3GPXoX0xLZeVsB0Z013mzIy4GoniLKvzN7ApnTruPxSFisxrvFajCcQpL5UbU8SW4k+LhJDI8FTlRg==", "requires": { - "@bitbybit-dev/base": "0.21.0", + "@bitbybit-dev/base": "0.21.1", "@jscad/3mf-serializer": "2.1.12", "@jscad/dxf-serializer": "2.1.18", "@jscad/io-utils": "2.0.28", @@ -2665,46 +2672,46 @@ } }, "@bitbybit-dev/jscad-worker": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/jscad-worker/-/jscad-worker-0.21.0.tgz", - "integrity": "sha512-nIvd7GH5Gg51u6PmFXOADXVYTIvixTkNf0YapS1uix7D2JS9Mx10Z4wHAeRKzvJxUAAbEPPRFNkakE22HFGtLQ==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/jscad-worker/-/jscad-worker-0.21.1.tgz", + "integrity": "sha512-ccaXGTnKseWGDGEdgf3HfQqBWmM4Q384NQWO2kdzZ4EHaZlSp9tEHY8NHOxyxPoMol+qK9u9puH4ux13zY+FrQ==", "requires": { - "@bitbybit-dev/jscad": "0.21.0", + "@bitbybit-dev/jscad": "0.21.1", "rxjs": "7.5.5" } }, "@bitbybit-dev/manifold": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/manifold/-/manifold-0.21.0.tgz", - "integrity": "sha512-DPpwK9ESB+auDeAbzXcfWRVEzWoMDkpkjc+/uwh+zuSiHSx92PSkzx1/LVTbQCsK+aOfOOy03HQCF5Bu2KQYtw==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/manifold/-/manifold-0.21.1.tgz", + "integrity": "sha512-/UqejYCN9YIyBzf5yQXPdSawoKqEUd1aQAKdmge4LoUaZ19eQyRHLK4WpZQ8K+7lTr7qcNQARr7mLx0FQMBFew==", "requires": { - "@bitbybit-dev/base": "0.21.0", + "@bitbybit-dev/base": "0.21.1", "manifold-3d": "3.3.2" } }, "@bitbybit-dev/manifold-worker": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/manifold-worker/-/manifold-worker-0.21.0.tgz", - "integrity": "sha512-6Cqv3BP+uI8mHKHI6Jx9TzCxRg1/kMHhCe18+B3KD/rTl9B5mnScCKRBnDansR3bH7aYZGnIw9PmiFnWLkQWEQ==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/manifold-worker/-/manifold-worker-0.21.1.tgz", + "integrity": "sha512-A+oV172dZzehkeF5kdCFzQuyyfj9FLixq5nGNviOpJX3zaF+0efl1ung1o45V5pLtZkuGCgCZaQ6lY0zNQcYig==", "requires": { - "@bitbybit-dev/manifold": "0.21.0", + "@bitbybit-dev/manifold": "0.21.1", "rxjs": "7.5.5" } }, "@bitbybit-dev/occt": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/occt/-/occt-0.21.0.tgz", - "integrity": "sha512-vPu3NmF1kBZMOkOdysolGfFxEEnwdHNGORoX3eWbMWT2JL/Tag5Q2CAc5jwa2VvZnS1nE/9x+DVlFQSo8LQnIg==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/occt/-/occt-0.21.1.tgz", + "integrity": "sha512-0+yffQRmph9W1qLSyRBUvaQDiZ9OHA2kD2/LsCgxR3NVtKs3GZaAYYhoUfaRqtt2I8Go99e8WBB5daaQceudjA==", "requires": { - "@bitbybit-dev/base": "0.21.0" + "@bitbybit-dev/base": "0.21.1" } }, "@bitbybit-dev/occt-worker": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/occt-worker/-/occt-worker-0.21.0.tgz", - "integrity": "sha512-xG1sgo6q/RdVA8AgG72wPe4qxcQlrO1V7/Ksn6MqIhZVTsJcm5RbVYlK+nziIWhvlMc1sKE0GNQFcPdALISLuQ==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/occt-worker/-/occt-worker-0.21.1.tgz", + "integrity": "sha512-3BW0lTiY8muPSiCWplAT/VQHaHFVUvljMGD1ynQo7cqv/Zna9ACn+SHOMY2HJ7m1MnZq5d2dGjJJXo8k19iV8Q==", "requires": { - "@bitbybit-dev/occt": "0.21.0", + "@bitbybit-dev/occt": "0.21.1", "rxjs": "7.5.5" } }, @@ -3733,13 +3740,13 @@ "integrity": "sha512-B7qPcEVE3NVkmSJbaYxvv4cHkVW7DQsZz13pUMrfS8z8Q/BuShN+gcTXrUlPiGqM2/t/EEaI030bpxMqY8gMlw==" }, "jsonpath-plus": { - "version": "10.1.0", - "resolved": "https://registry.npmjs.org/jsonpath-plus/-/jsonpath-plus-10.1.0.tgz", - "integrity": "sha512-gHfV1IYqH8uJHYVTs8BJX1XKy2/rR93+f8QQi0xhx95aCiXn1ettYAd5T+7FU6wfqyDoX/wy0pm/fL3jOKJ9Lg==", + "version": "10.3.0", + "resolved": "https://registry.npmjs.org/jsonpath-plus/-/jsonpath-plus-10.3.0.tgz", + "integrity": "sha512-8TNmfeTCk2Le33A3vRRwtuworG/L5RrgMvdjhKZxvyShO+mBu2fP50OWUjRLNtvw344DdDarFh9buFAZs5ujeA==", "requires": { - "@jsep-plugin/assignment": "^1.2.1", - "@jsep-plugin/regex": "^1.0.3", - "jsep": "^1.3.9" + "@jsep-plugin/assignment": "^1.3.0", + "@jsep-plugin/regex": "^1.0.4", + "jsep": "^1.4.0" } }, "ktx-parse": { @@ -4072,9 +4079,9 @@ "integrity": "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==" }, "sax": { - "version": "1.4.3", - "resolved": "https://registry.npmjs.org/sax/-/sax-1.4.3.tgz", - "integrity": "sha512-yqYn1JhPczigF94DMS+shiDMjDowYO6y9+wB/4WgO0Y19jWYk0lQ4tuG5KI7kj4FTp1wxPj5IFfcrz/s1c3jjQ==" + "version": "1.4.4", + "resolved": "https://registry.npmjs.org/sax/-/sax-1.4.4.tgz", + "integrity": "sha512-1n3r/tGXO6b6VXMdFT54SHzT9ytu9yr7TaELowdYpMqY/Ao7EnlQGmAQ1+RatX7Tkkdm6hONI2owqNx2aZj5Sw==" }, "semver": { "version": "5.7.2", diff --git a/examples/node/express-app/package.json b/examples/node/express-app/package.json index fc99a1d2..f3cad1bf 100644 --- a/examples/node/express-app/package.json +++ b/examples/node/express-app/package.json @@ -11,7 +11,7 @@ "author": "Bit By Bit Developers", "license": "MIT", "dependencies": { - "@bitbybit-dev/core": "0.21.0", + "@bitbybit-dev/core": "0.21.1", "cors": "^2.8.5", "dotenv": "^16.0.3", "express": "^4.18.2", diff --git a/examples/nuxt/babylonjs/basic/package-lock.json b/examples/nuxt/babylonjs/basic/package-lock.json index cb4a0b5c..db6ae3a7 100644 --- a/examples/nuxt/babylonjs/basic/package-lock.json +++ b/examples/nuxt/babylonjs/basic/package-lock.json @@ -8,7 +8,7 @@ "hasInstallScript": true, "license": "MIT", "dependencies": { - "@bitbybit-dev/babylonjs": "0.21.0", + "@bitbybit-dev/babylonjs": "0.21.1", "@pinia/nuxt": "^0.5.4", "nuxt": "^3.13.0", "pinia": "^2.2.2", @@ -486,15 +486,15 @@ } }, "node_modules/@babylonjs/core": { - "version": "8.44.1", - "resolved": "https://registry.npmjs.org/@babylonjs/core/-/core-8.44.1.tgz", - "integrity": "sha512-sF2WWK2d7lg18ESOCxUoRG4d1SzCWz42asjRjRGxZ8r3D7w9ZM3H2wftJIqwaZvD3zWr+wmCVKpQ6hWkboHIXw==", + "version": "8.45.4", + "resolved": "https://registry.npmjs.org/@babylonjs/core/-/core-8.45.4.tgz", + "integrity": "sha512-fmpaitVpe+bB3PCLY0RKYO/e5n1vLNvueJrglt6SENVE/frZNS4har8odAd1UDNf5KFgOdb8YK91jK4BUwIgcQ==", "license": "Apache-2.0" }, "node_modules/@babylonjs/gui": { - "version": "8.44.1", - "resolved": "https://registry.npmjs.org/@babylonjs/gui/-/gui-8.44.1.tgz", - "integrity": "sha512-6STDK+Hr8GpY29YMLKnTVhEnWw1NKPrIpz+MqgWuoAAmmpiFtNCr0nnAnCj5fhgGf25L89jy51ogXyg3jfiuDA==", + "version": "8.45.4", + "resolved": "https://registry.npmjs.org/@babylonjs/gui/-/gui-8.45.4.tgz", + "integrity": "sha512-1pMjQs7fgSEvUQoXyit96kNRqzX74oMNkMkAOmz7NjOkBX3tacAfNfoEC6aw+AB+iAjlCO5/DXatZU5m6EYyIQ==", "license": "Apache-2.0", "peerDependencies": { "@babylonjs/core": "^8.0.0" @@ -509,9 +509,9 @@ } }, "node_modules/@babylonjs/loaders": { - "version": "8.44.1", - "resolved": "https://registry.npmjs.org/@babylonjs/loaders/-/loaders-8.44.1.tgz", - "integrity": "sha512-h5rUGCwhdWv3Hq48DP8sy4/+3QUYjOprxu2i6zXKb69LHMnYE0tZ1xQHBJEOUF60hxA+TwhzdjC8bxInKoeojA==", + "version": "8.45.4", + "resolved": "https://registry.npmjs.org/@babylonjs/loaders/-/loaders-8.45.4.tgz", + "integrity": "sha512-P1H8XpIJK7NnrtGGSGkCJZIPBvtJ+0+l7yGXDY2UaNFKU80y2Oty8DZ8JRKdbJdSc4cOe8ucBY5w7x+Bbllxuw==", "license": "Apache-2.0", "peerDependencies": { "@babylonjs/core": "^8.0.0", @@ -519,18 +519,18 @@ } }, "node_modules/@babylonjs/materials": { - "version": "8.44.1", - "resolved": "https://registry.npmjs.org/@babylonjs/materials/-/materials-8.44.1.tgz", - "integrity": "sha512-FD0S/aA68oEjKCSNY5ydGkiHbsyo08KlhQ+6R8swtJhx5aq7ojWBt3P9KC78+wjZiCJW37176CIObcV8QcjMAQ==", + "version": "8.45.4", + "resolved": "https://registry.npmjs.org/@babylonjs/materials/-/materials-8.45.4.tgz", + "integrity": "sha512-ElTXhC83alnMFFyv2sPG/Im5UwTZoDzd1R8otPQwbEEERcRK8A71Hu1gFdBu/8l9O752IWnZcPSEj1WwLqeR5A==", "license": "Apache-2.0", "peerDependencies": { "@babylonjs/core": "^8.6.0" } }, "node_modules/@babylonjs/serializers": { - "version": "8.44.1", - "resolved": "https://registry.npmjs.org/@babylonjs/serializers/-/serializers-8.44.1.tgz", - "integrity": "sha512-3FRRdKpHr2qTkALHEvq0ih0P59iTINUFrGZWFUfO3Wu24UBSuTxY9Kq820dvUUWaRtWkXEnMSQbR+5glzcfqBw==", + "version": "8.45.4", + "resolved": "https://registry.npmjs.org/@babylonjs/serializers/-/serializers-8.45.4.tgz", + "integrity": "sha512-i83RQIP3XSi3DFJwhc/+JNNPm49DdtNyDobuyBBwIDyMpQdbcFLhkL0DW/7/H+vFUWz0xWx+mgmsb6HY/ePGmg==", "license": "Apache-2.0", "peerDependencies": { "@babylonjs/core": "^8.0.0", @@ -538,49 +538,49 @@ } }, "node_modules/@bitbybit-dev/babylonjs": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/babylonjs/-/babylonjs-0.21.0.tgz", - "integrity": "sha512-8aPJ+XTXzcnO4bXfmW34lTnVCzC6Hy6TMkh7/ziQSoUsjPp7e7LFHoBBfqCk09LdTLa85gb5x/f6WNAn306Odg==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/babylonjs/-/babylonjs-0.21.1.tgz", + "integrity": "sha512-OyQI5FC4qI5EYW/RFZt/6WR2We2bEpbhM8I8ptiJkviY0e1yIjiV11A4aF8B6fpjS5Bd7Rb30LrUdWNHbAo1Nw==", "license": "MIT", "dependencies": { - "@babylonjs/core": "8.44.1", - "@babylonjs/gui": "8.44.1", + "@babylonjs/core": "8.45.4", + "@babylonjs/gui": "8.45.4", "@babylonjs/havok": "1.3.10", - "@babylonjs/loaders": "8.44.1", - "@babylonjs/materials": "8.44.1", - "@babylonjs/serializers": "8.44.1", - "@bitbybit-dev/core": "0.21.0", + "@babylonjs/loaders": "8.45.4", + "@babylonjs/materials": "8.45.4", + "@babylonjs/serializers": "8.45.4", + "@bitbybit-dev/core": "0.21.1", "earcut": "2.2.3" } }, "node_modules/@bitbybit-dev/base": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/base/-/base-0.21.0.tgz", - "integrity": "sha512-dNfsf2tu3/QUD1mvZzzTze8RwHyK2Jrt+Ary8EDKdNKMw+abtCpQYNerdrg0ZQPxvwu/OOQz6N1xCsCwsPkQJg==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/base/-/base-0.21.1.tgz", + "integrity": "sha512-d3aHPpLHigeNTceMi0U/wOIzCqkvHg8S2gNa4b8VGSTifbn7Fo1XbQ2pzetbcOtwtJhkcLgNYn3nFqW8S2MUpw==", "license": "MIT" }, "node_modules/@bitbybit-dev/core": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/core/-/core-0.21.0.tgz", - "integrity": "sha512-IbeQ8ROreu0/RkkngUE+Eb19ecvqKOWhGefXvIqQmplxt3zEc0FI4Kw8wR3vYl2XMannuVt1xAIYtqqH0tjBzg==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/core/-/core-0.21.1.tgz", + "integrity": "sha512-Zr2w4h1eBRgOHevKevTaDeL1KlOju6Q8uT62zLeKAAAAn5P1RNn2jOVnHEJtd7y4wPn7G2rZwlwtBQlYe5t9AQ==", "license": "MIT", "dependencies": { - "@bitbybit-dev/base": "0.21.0", - "@bitbybit-dev/jscad-worker": "0.21.0", - "@bitbybit-dev/manifold-worker": "0.21.0", - "@bitbybit-dev/occt-worker": "0.21.0", - "jsonpath-plus": "10.1.0", + "@bitbybit-dev/base": "0.21.1", + "@bitbybit-dev/jscad-worker": "0.21.1", + "@bitbybit-dev/manifold-worker": "0.21.1", + "@bitbybit-dev/occt-worker": "0.21.1", + "jsonpath-plus": "10.3.0", "rxjs": "7.5.5", "verb-nurbs-web": "2.1.3" } }, "node_modules/@bitbybit-dev/jscad": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/jscad/-/jscad-0.21.0.tgz", - "integrity": "sha512-Q7eE2ILrJRstW4L1711aJZdpwPf1kuhZJqB+KLkkBLsneRsGsh82lBcCbVYAOMuF/q8Lnd4JHxPiIG/m+LYmPQ==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/jscad/-/jscad-0.21.1.tgz", + "integrity": "sha512-nw8dHGYy3GPXoX0xLZeVsB0Z013mzIy4GoniLKvzN7ApnTruPxSFisxrvFajCcQpL5UbU8SW4k+LhJDI8FTlRg==", "license": "MIT", "dependencies": { - "@bitbybit-dev/base": "0.21.0", + "@bitbybit-dev/base": "0.21.1", "@jscad/3mf-serializer": "2.1.12", "@jscad/dxf-serializer": "2.1.18", "@jscad/io-utils": "2.0.28", @@ -589,51 +589,51 @@ } }, "node_modules/@bitbybit-dev/jscad-worker": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/jscad-worker/-/jscad-worker-0.21.0.tgz", - "integrity": "sha512-nIvd7GH5Gg51u6PmFXOADXVYTIvixTkNf0YapS1uix7D2JS9Mx10Z4wHAeRKzvJxUAAbEPPRFNkakE22HFGtLQ==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/jscad-worker/-/jscad-worker-0.21.1.tgz", + "integrity": "sha512-ccaXGTnKseWGDGEdgf3HfQqBWmM4Q384NQWO2kdzZ4EHaZlSp9tEHY8NHOxyxPoMol+qK9u9puH4ux13zY+FrQ==", "license": "MIT", "dependencies": { - "@bitbybit-dev/jscad": "0.21.0", + "@bitbybit-dev/jscad": "0.21.1", "rxjs": "7.5.5" } }, "node_modules/@bitbybit-dev/manifold": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/manifold/-/manifold-0.21.0.tgz", - "integrity": "sha512-DPpwK9ESB+auDeAbzXcfWRVEzWoMDkpkjc+/uwh+zuSiHSx92PSkzx1/LVTbQCsK+aOfOOy03HQCF5Bu2KQYtw==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/manifold/-/manifold-0.21.1.tgz", + "integrity": "sha512-/UqejYCN9YIyBzf5yQXPdSawoKqEUd1aQAKdmge4LoUaZ19eQyRHLK4WpZQ8K+7lTr7qcNQARr7mLx0FQMBFew==", "license": "MIT", "dependencies": { - "@bitbybit-dev/base": "0.21.0", + "@bitbybit-dev/base": "0.21.1", "manifold-3d": "3.3.2" } }, "node_modules/@bitbybit-dev/manifold-worker": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/manifold-worker/-/manifold-worker-0.21.0.tgz", - "integrity": "sha512-6Cqv3BP+uI8mHKHI6Jx9TzCxRg1/kMHhCe18+B3KD/rTl9B5mnScCKRBnDansR3bH7aYZGnIw9PmiFnWLkQWEQ==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/manifold-worker/-/manifold-worker-0.21.1.tgz", + "integrity": "sha512-A+oV172dZzehkeF5kdCFzQuyyfj9FLixq5nGNviOpJX3zaF+0efl1ung1o45V5pLtZkuGCgCZaQ6lY0zNQcYig==", "license": "MIT", "dependencies": { - "@bitbybit-dev/manifold": "0.21.0", + "@bitbybit-dev/manifold": "0.21.1", "rxjs": "7.5.5" } }, "node_modules/@bitbybit-dev/occt": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/occt/-/occt-0.21.0.tgz", - "integrity": "sha512-vPu3NmF1kBZMOkOdysolGfFxEEnwdHNGORoX3eWbMWT2JL/Tag5Q2CAc5jwa2VvZnS1nE/9x+DVlFQSo8LQnIg==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/occt/-/occt-0.21.1.tgz", + "integrity": "sha512-0+yffQRmph9W1qLSyRBUvaQDiZ9OHA2kD2/LsCgxR3NVtKs3GZaAYYhoUfaRqtt2I8Go99e8WBB5daaQceudjA==", "license": "MIT", "dependencies": { - "@bitbybit-dev/base": "0.21.0" + "@bitbybit-dev/base": "0.21.1" } }, "node_modules/@bitbybit-dev/occt-worker": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/occt-worker/-/occt-worker-0.21.0.tgz", - "integrity": "sha512-xG1sgo6q/RdVA8AgG72wPe4qxcQlrO1V7/Ksn6MqIhZVTsJcm5RbVYlK+nziIWhvlMc1sKE0GNQFcPdALISLuQ==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/occt-worker/-/occt-worker-0.21.1.tgz", + "integrity": "sha512-3BW0lTiY8muPSiCWplAT/VQHaHFVUvljMGD1ynQo7cqv/Zna9ACn+SHOMY2HJ7m1MnZq5d2dGjJJXo8k19iV8Q==", "license": "MIT", "dependencies": { - "@bitbybit-dev/occt": "0.21.0", + "@bitbybit-dev/occt": "0.21.1", "rxjs": "7.5.5" } }, @@ -3559,9 +3559,9 @@ "integrity": "sha512-5Tk1HLk6b6ctmjIkAcU/Ujv/1WqiDl0F0JdRCR80VsOcUlHcu7pWeWRlOqQLHfDEsVx9YH/aif5AG4ehoCtTmg==" }, "node_modules/babylonjs-gltf2interface": { - "version": "8.44.1", - "resolved": "https://registry.npmjs.org/babylonjs-gltf2interface/-/babylonjs-gltf2interface-8.44.1.tgz", - "integrity": "sha512-+z0P0wms1FD5xuVpuRJ1qjvGAbPAWhEWGBWENRPD0Hbz6nd9cnL28/pjxgk39/QhlIuJKL9JZ0o8G0JgLHEnRQ==", + "version": "8.45.5", + "resolved": "https://registry.npmjs.org/babylonjs-gltf2interface/-/babylonjs-gltf2interface-8.45.5.tgz", + "integrity": "sha512-o1OMBVdeKCK7b+L1VUW1w1+KIi1DTP7Po+SAJ3vwPqRG6xD2eTL+w5IaFHVue3dVjnlU8Z+9y3BP3AadmK0H9w==", "license": "Apache-2.0", "peer": true }, @@ -5698,14 +5698,14 @@ } }, "node_modules/jsonpath-plus": { - "version": "10.1.0", - "resolved": "https://registry.npmjs.org/jsonpath-plus/-/jsonpath-plus-10.1.0.tgz", - "integrity": "sha512-gHfV1IYqH8uJHYVTs8BJX1XKy2/rR93+f8QQi0xhx95aCiXn1ettYAd5T+7FU6wfqyDoX/wy0pm/fL3jOKJ9Lg==", + "version": "10.3.0", + "resolved": "https://registry.npmjs.org/jsonpath-plus/-/jsonpath-plus-10.3.0.tgz", + "integrity": "sha512-8TNmfeTCk2Le33A3vRRwtuworG/L5RrgMvdjhKZxvyShO+mBu2fP50OWUjRLNtvw344DdDarFh9buFAZs5ujeA==", "license": "MIT", "dependencies": { - "@jsep-plugin/assignment": "^1.2.1", - "@jsep-plugin/regex": "^1.0.3", - "jsep": "^1.3.9" + "@jsep-plugin/assignment": "^1.3.0", + "@jsep-plugin/regex": "^1.0.4", + "jsep": "^1.4.0" }, "bin": { "jsonpath": "bin/jsonpath-cli.js", @@ -8163,10 +8163,13 @@ ] }, "node_modules/sax": { - "version": "1.4.3", - "resolved": "https://registry.npmjs.org/sax/-/sax-1.4.3.tgz", - "integrity": "sha512-yqYn1JhPczigF94DMS+shiDMjDowYO6y9+wB/4WgO0Y19jWYk0lQ4tuG5KI7kj4FTp1wxPj5IFfcrz/s1c3jjQ==", - "license": "BlueOak-1.0.0" + "version": "1.4.4", + "resolved": "https://registry.npmjs.org/sax/-/sax-1.4.4.tgz", + "integrity": "sha512-1n3r/tGXO6b6VXMdFT54SHzT9ytu9yr7TaELowdYpMqY/Ao7EnlQGmAQ1+RatX7Tkkdm6hONI2owqNx2aZj5Sw==", + "license": "BlueOak-1.0.0", + "engines": { + "node": ">=11.0.0" + } }, "node_modules/scule": { "version": "1.3.0", diff --git a/examples/nuxt/babylonjs/basic/package.json b/examples/nuxt/babylonjs/basic/package.json index 6583831e..623ccd38 100644 --- a/examples/nuxt/babylonjs/basic/package.json +++ b/examples/nuxt/babylonjs/basic/package.json @@ -11,7 +11,7 @@ "postinstall": "nuxt prepare" }, "dependencies": { - "@bitbybit-dev/babylonjs": "0.21.0", + "@bitbybit-dev/babylonjs": "0.21.1", "@pinia/nuxt": "^0.5.4", "nuxt": "^3.13.0", "pinia": "^2.2.2", diff --git a/examples/package.json b/examples/package.json index 630afa9d..46a09bac 100644 --- a/examples/package.json +++ b/examples/package.json @@ -1,6 +1,6 @@ { "name": "bitbybit-examples", - "version": "0.21.0", + "version": "0.21.1", "description": "Monorepo for browser CAD which holds bitbybit.dev npm packages", "main": "index.js", "scripts": { @@ -17,12 +17,18 @@ "ci-vite-babylonjs-hex-house-concept": "cd vite/babylonjs/hex-house-concept && npm install", "ci-vite-babylonjs-hex-shell": "cd vite/babylonjs/hex-shell && npm install", "ci-vite-babylonjs-starter-template": "cd vite/babylonjs/starter-template && npm install", + "ci-vite-babylonjs-starter-template-full": "cd vite/babylonjs/starter-template-full && npm install", "ci-vite-threejs-cup": "cd vite/threejs/cup && npm install", "ci-vite-threejs-hex-house-concept": "cd vite/threejs/hex-house-concept && npm install", "ci-vite-threejs-hex-shell": "cd vite/threejs/hex-shell && npm install", "ci-vite-threejs-starter-template": "cd vite/threejs/starter-template && npm install", + "ci-vite-threejs-starter-template-full": "cd vite/threejs/starter-template-full && npm install", + "ci-vite-playcanvas-hex-house-concept": "cd vite/playcanvas/hex-house-concept && npm install", + "ci-vite-playcanvas-hex-shell": "cd vite/playcanvas/hex-shell && npm install", + "ci-vite-playcanvas-starter-template": "cd vite/playcanvas/starter-template && npm install", + "ci-vite-playcanvas-starter-template-full": "cd vite/playcanvas/starter-template-full && npm install", "ci-webpack-threejs": "cd webpack/threejs && npm install", - "ci-packages": "npm run ci-angular-babylonjs-laptop-holder && npm run ci-angular-threejs-simple-viewer && npm run ci-angular-three-vite-basic-example && npm run ci-nextjs-babylonjs-simple && npm run ci-node-basic && npm run ci-node-express-app && npm run ci-nuxt-babylonjs-basic && npm run ci-react-babylonjs-cup && npm run ci-react-babylonjs-laptop-holder && npm run ci-react-threejs-vase && npm run ci-vite-babylonjs-hex-house-concept && npm run ci-vite-babylonjs-hex-shell && npm run ci-vite-babylonjs-starter-template && npm run ci-vite-threejs-cup && npm run ci-vite-threejs-hex-house-concept && npm run ci-vite-threejs-hex-shell && npm run ci-vite-threejs-starter-template && npm run ci-webpack-threejs" + "ci-packages": "npm run ci-angular-babylonjs-laptop-holder && npm run ci-angular-threejs-simple-viewer && npm run ci-angular-three-vite-basic-example && npm run ci-nextjs-babylonjs-simple && npm run ci-node-basic && npm run ci-node-express-app && npm run ci-nuxt-babylonjs-basic && npm run ci-react-babylonjs-cup && npm run ci-react-babylonjs-laptop-holder && npm run ci-react-threejs-vase && npm run ci-vite-babylonjs-hex-house-concept && npm run ci-vite-babylonjs-hex-shell && npm run ci-vite-babylonjs-starter-template && npm run ci-vite-babylonjs-starter-template-full && npm run ci-vite-threejs-cup && npm run ci-vite-threejs-hex-house-concept && npm run ci-vite-threejs-hex-shell && npm run ci-vite-threejs-starter-template && npm run ci-vite-threejs-starter-template-full && npm run ci-webpack-threejs && npm run ci-vite-playcanvas-hex-house-concept && npm run ci-vite-playcanvas-hex-shell && npm run ci-vite-playcanvas-starter-template && npm run ci-vite-playcanvas-starter-template-full" }, "repository": { "type": "git", diff --git a/examples/react/babylonjs/cup/package-lock.json b/examples/react/babylonjs/cup/package-lock.json index fcef378c..7bc548b2 100644 --- a/examples/react/babylonjs/cup/package-lock.json +++ b/examples/react/babylonjs/cup/package-lock.json @@ -8,7 +8,7 @@ "name": "cup", "version": "0.1.0", "dependencies": { - "@bitbybit-dev/babylonjs": "0.21.0", + "@bitbybit-dev/babylonjs": "0.21.1", "@emotion/react": "11.9.0", "@emotion/styled": "11.8.1", "@mui/icons-material": "5.6.2", @@ -1809,15 +1809,15 @@ } }, "node_modules/@babylonjs/core": { - "version": "8.44.1", - "resolved": "https://registry.npmjs.org/@babylonjs/core/-/core-8.44.1.tgz", - "integrity": "sha512-sF2WWK2d7lg18ESOCxUoRG4d1SzCWz42asjRjRGxZ8r3D7w9ZM3H2wftJIqwaZvD3zWr+wmCVKpQ6hWkboHIXw==", + "version": "8.45.4", + "resolved": "https://registry.npmjs.org/@babylonjs/core/-/core-8.45.4.tgz", + "integrity": "sha512-fmpaitVpe+bB3PCLY0RKYO/e5n1vLNvueJrglt6SENVE/frZNS4har8odAd1UDNf5KFgOdb8YK91jK4BUwIgcQ==", "license": "Apache-2.0" }, "node_modules/@babylonjs/gui": { - "version": "8.44.1", - "resolved": "https://registry.npmjs.org/@babylonjs/gui/-/gui-8.44.1.tgz", - "integrity": "sha512-6STDK+Hr8GpY29YMLKnTVhEnWw1NKPrIpz+MqgWuoAAmmpiFtNCr0nnAnCj5fhgGf25L89jy51ogXyg3jfiuDA==", + "version": "8.45.4", + "resolved": "https://registry.npmjs.org/@babylonjs/gui/-/gui-8.45.4.tgz", + "integrity": "sha512-1pMjQs7fgSEvUQoXyit96kNRqzX74oMNkMkAOmz7NjOkBX3tacAfNfoEC6aw+AB+iAjlCO5/DXatZU5m6EYyIQ==", "license": "Apache-2.0", "peerDependencies": { "@babylonjs/core": "^8.0.0" @@ -1832,9 +1832,9 @@ } }, "node_modules/@babylonjs/loaders": { - "version": "8.44.1", - "resolved": "https://registry.npmjs.org/@babylonjs/loaders/-/loaders-8.44.1.tgz", - "integrity": "sha512-h5rUGCwhdWv3Hq48DP8sy4/+3QUYjOprxu2i6zXKb69LHMnYE0tZ1xQHBJEOUF60hxA+TwhzdjC8bxInKoeojA==", + "version": "8.45.4", + "resolved": "https://registry.npmjs.org/@babylonjs/loaders/-/loaders-8.45.4.tgz", + "integrity": "sha512-P1H8XpIJK7NnrtGGSGkCJZIPBvtJ+0+l7yGXDY2UaNFKU80y2Oty8DZ8JRKdbJdSc4cOe8ucBY5w7x+Bbllxuw==", "license": "Apache-2.0", "peerDependencies": { "@babylonjs/core": "^8.0.0", @@ -1842,18 +1842,18 @@ } }, "node_modules/@babylonjs/materials": { - "version": "8.44.1", - "resolved": "https://registry.npmjs.org/@babylonjs/materials/-/materials-8.44.1.tgz", - "integrity": "sha512-FD0S/aA68oEjKCSNY5ydGkiHbsyo08KlhQ+6R8swtJhx5aq7ojWBt3P9KC78+wjZiCJW37176CIObcV8QcjMAQ==", + "version": "8.45.4", + "resolved": "https://registry.npmjs.org/@babylonjs/materials/-/materials-8.45.4.tgz", + "integrity": "sha512-ElTXhC83alnMFFyv2sPG/Im5UwTZoDzd1R8otPQwbEEERcRK8A71Hu1gFdBu/8l9O752IWnZcPSEj1WwLqeR5A==", "license": "Apache-2.0", "peerDependencies": { "@babylonjs/core": "^8.6.0" } }, "node_modules/@babylonjs/serializers": { - "version": "8.44.1", - "resolved": "https://registry.npmjs.org/@babylonjs/serializers/-/serializers-8.44.1.tgz", - "integrity": "sha512-3FRRdKpHr2qTkALHEvq0ih0P59iTINUFrGZWFUfO3Wu24UBSuTxY9Kq820dvUUWaRtWkXEnMSQbR+5glzcfqBw==", + "version": "8.45.4", + "resolved": "https://registry.npmjs.org/@babylonjs/serializers/-/serializers-8.45.4.tgz", + "integrity": "sha512-i83RQIP3XSi3DFJwhc/+JNNPm49DdtNyDobuyBBwIDyMpQdbcFLhkL0DW/7/H+vFUWz0xWx+mgmsb6HY/ePGmg==", "license": "Apache-2.0", "peerDependencies": { "@babylonjs/core": "^8.0.0", @@ -1866,49 +1866,49 @@ "integrity": "sha512-0hYQ8SB4Db5zvZB4axdMHGwEaQjkZzFjQiN9LVYvIFB2nSUHW9tYpxWriPrWDASIxiaXax83REcLxuSdnGPZtw==" }, "node_modules/@bitbybit-dev/babylonjs": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/babylonjs/-/babylonjs-0.21.0.tgz", - "integrity": "sha512-8aPJ+XTXzcnO4bXfmW34lTnVCzC6Hy6TMkh7/ziQSoUsjPp7e7LFHoBBfqCk09LdTLa85gb5x/f6WNAn306Odg==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/babylonjs/-/babylonjs-0.21.1.tgz", + "integrity": "sha512-OyQI5FC4qI5EYW/RFZt/6WR2We2bEpbhM8I8ptiJkviY0e1yIjiV11A4aF8B6fpjS5Bd7Rb30LrUdWNHbAo1Nw==", "license": "MIT", "dependencies": { - "@babylonjs/core": "8.44.1", - "@babylonjs/gui": "8.44.1", + "@babylonjs/core": "8.45.4", + "@babylonjs/gui": "8.45.4", "@babylonjs/havok": "1.3.10", - "@babylonjs/loaders": "8.44.1", - "@babylonjs/materials": "8.44.1", - "@babylonjs/serializers": "8.44.1", - "@bitbybit-dev/core": "0.21.0", + "@babylonjs/loaders": "8.45.4", + "@babylonjs/materials": "8.45.4", + "@babylonjs/serializers": "8.45.4", + "@bitbybit-dev/core": "0.21.1", "earcut": "2.2.3" } }, "node_modules/@bitbybit-dev/base": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/base/-/base-0.21.0.tgz", - "integrity": "sha512-dNfsf2tu3/QUD1mvZzzTze8RwHyK2Jrt+Ary8EDKdNKMw+abtCpQYNerdrg0ZQPxvwu/OOQz6N1xCsCwsPkQJg==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/base/-/base-0.21.1.tgz", + "integrity": "sha512-d3aHPpLHigeNTceMi0U/wOIzCqkvHg8S2gNa4b8VGSTifbn7Fo1XbQ2pzetbcOtwtJhkcLgNYn3nFqW8S2MUpw==", "license": "MIT" }, "node_modules/@bitbybit-dev/core": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/core/-/core-0.21.0.tgz", - "integrity": "sha512-IbeQ8ROreu0/RkkngUE+Eb19ecvqKOWhGefXvIqQmplxt3zEc0FI4Kw8wR3vYl2XMannuVt1xAIYtqqH0tjBzg==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/core/-/core-0.21.1.tgz", + "integrity": "sha512-Zr2w4h1eBRgOHevKevTaDeL1KlOju6Q8uT62zLeKAAAAn5P1RNn2jOVnHEJtd7y4wPn7G2rZwlwtBQlYe5t9AQ==", "license": "MIT", "dependencies": { - "@bitbybit-dev/base": "0.21.0", - "@bitbybit-dev/jscad-worker": "0.21.0", - "@bitbybit-dev/manifold-worker": "0.21.0", - "@bitbybit-dev/occt-worker": "0.21.0", - "jsonpath-plus": "10.1.0", + "@bitbybit-dev/base": "0.21.1", + "@bitbybit-dev/jscad-worker": "0.21.1", + "@bitbybit-dev/manifold-worker": "0.21.1", + "@bitbybit-dev/occt-worker": "0.21.1", + "jsonpath-plus": "10.3.0", "rxjs": "7.5.5", "verb-nurbs-web": "2.1.3" } }, "node_modules/@bitbybit-dev/jscad": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/jscad/-/jscad-0.21.0.tgz", - "integrity": "sha512-Q7eE2ILrJRstW4L1711aJZdpwPf1kuhZJqB+KLkkBLsneRsGsh82lBcCbVYAOMuF/q8Lnd4JHxPiIG/m+LYmPQ==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/jscad/-/jscad-0.21.1.tgz", + "integrity": "sha512-nw8dHGYy3GPXoX0xLZeVsB0Z013mzIy4GoniLKvzN7ApnTruPxSFisxrvFajCcQpL5UbU8SW4k+LhJDI8FTlRg==", "license": "MIT", "dependencies": { - "@bitbybit-dev/base": "0.21.0", + "@bitbybit-dev/base": "0.21.1", "@jscad/3mf-serializer": "2.1.12", "@jscad/dxf-serializer": "2.1.18", "@jscad/io-utils": "2.0.28", @@ -1917,51 +1917,51 @@ } }, "node_modules/@bitbybit-dev/jscad-worker": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/jscad-worker/-/jscad-worker-0.21.0.tgz", - "integrity": "sha512-nIvd7GH5Gg51u6PmFXOADXVYTIvixTkNf0YapS1uix7D2JS9Mx10Z4wHAeRKzvJxUAAbEPPRFNkakE22HFGtLQ==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/jscad-worker/-/jscad-worker-0.21.1.tgz", + "integrity": "sha512-ccaXGTnKseWGDGEdgf3HfQqBWmM4Q384NQWO2kdzZ4EHaZlSp9tEHY8NHOxyxPoMol+qK9u9puH4ux13zY+FrQ==", "license": "MIT", "dependencies": { - "@bitbybit-dev/jscad": "0.21.0", + "@bitbybit-dev/jscad": "0.21.1", "rxjs": "7.5.5" } }, "node_modules/@bitbybit-dev/manifold": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/manifold/-/manifold-0.21.0.tgz", - "integrity": "sha512-DPpwK9ESB+auDeAbzXcfWRVEzWoMDkpkjc+/uwh+zuSiHSx92PSkzx1/LVTbQCsK+aOfOOy03HQCF5Bu2KQYtw==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/manifold/-/manifold-0.21.1.tgz", + "integrity": "sha512-/UqejYCN9YIyBzf5yQXPdSawoKqEUd1aQAKdmge4LoUaZ19eQyRHLK4WpZQ8K+7lTr7qcNQARr7mLx0FQMBFew==", "license": "MIT", "dependencies": { - "@bitbybit-dev/base": "0.21.0", + "@bitbybit-dev/base": "0.21.1", "manifold-3d": "3.3.2" } }, "node_modules/@bitbybit-dev/manifold-worker": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/manifold-worker/-/manifold-worker-0.21.0.tgz", - "integrity": "sha512-6Cqv3BP+uI8mHKHI6Jx9TzCxRg1/kMHhCe18+B3KD/rTl9B5mnScCKRBnDansR3bH7aYZGnIw9PmiFnWLkQWEQ==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/manifold-worker/-/manifold-worker-0.21.1.tgz", + "integrity": "sha512-A+oV172dZzehkeF5kdCFzQuyyfj9FLixq5nGNviOpJX3zaF+0efl1ung1o45V5pLtZkuGCgCZaQ6lY0zNQcYig==", "license": "MIT", "dependencies": { - "@bitbybit-dev/manifold": "0.21.0", + "@bitbybit-dev/manifold": "0.21.1", "rxjs": "7.5.5" } }, "node_modules/@bitbybit-dev/occt": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/occt/-/occt-0.21.0.tgz", - "integrity": "sha512-vPu3NmF1kBZMOkOdysolGfFxEEnwdHNGORoX3eWbMWT2JL/Tag5Q2CAc5jwa2VvZnS1nE/9x+DVlFQSo8LQnIg==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/occt/-/occt-0.21.1.tgz", + "integrity": "sha512-0+yffQRmph9W1qLSyRBUvaQDiZ9OHA2kD2/LsCgxR3NVtKs3GZaAYYhoUfaRqtt2I8Go99e8WBB5daaQceudjA==", "license": "MIT", "dependencies": { - "@bitbybit-dev/base": "0.21.0" + "@bitbybit-dev/base": "0.21.1" } }, "node_modules/@bitbybit-dev/occt-worker": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/occt-worker/-/occt-worker-0.21.0.tgz", - "integrity": "sha512-xG1sgo6q/RdVA8AgG72wPe4qxcQlrO1V7/Ksn6MqIhZVTsJcm5RbVYlK+nziIWhvlMc1sKE0GNQFcPdALISLuQ==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/occt-worker/-/occt-worker-0.21.1.tgz", + "integrity": "sha512-3BW0lTiY8muPSiCWplAT/VQHaHFVUvljMGD1ynQo7cqv/Zna9ACn+SHOMY2HJ7m1MnZq5d2dGjJJXo8k19iV8Q==", "license": "MIT", "dependencies": { - "@bitbybit-dev/occt": "0.21.0", + "@bitbybit-dev/occt": "0.21.1", "rxjs": "7.5.5" } }, @@ -6225,9 +6225,9 @@ } }, "node_modules/babylonjs-gltf2interface": { - "version": "8.44.1", - "resolved": "https://registry.npmjs.org/babylonjs-gltf2interface/-/babylonjs-gltf2interface-8.44.1.tgz", - "integrity": "sha512-+z0P0wms1FD5xuVpuRJ1qjvGAbPAWhEWGBWENRPD0Hbz6nd9cnL28/pjxgk39/QhlIuJKL9JZ0o8G0JgLHEnRQ==", + "version": "8.45.5", + "resolved": "https://registry.npmjs.org/babylonjs-gltf2interface/-/babylonjs-gltf2interface-8.45.5.tgz", + "integrity": "sha512-o1OMBVdeKCK7b+L1VUW1w1+KIi1DTP7Po+SAJ3vwPqRG6xD2eTL+w5IaFHVue3dVjnlU8Z+9y3BP3AadmK0H9w==", "license": "Apache-2.0", "peer": true }, @@ -12753,14 +12753,14 @@ } }, "node_modules/jsonpath-plus": { - "version": "10.1.0", - "resolved": "https://registry.npmjs.org/jsonpath-plus/-/jsonpath-plus-10.1.0.tgz", - "integrity": "sha512-gHfV1IYqH8uJHYVTs8BJX1XKy2/rR93+f8QQi0xhx95aCiXn1ettYAd5T+7FU6wfqyDoX/wy0pm/fL3jOKJ9Lg==", + "version": "10.3.0", + "resolved": "https://registry.npmjs.org/jsonpath-plus/-/jsonpath-plus-10.3.0.tgz", + "integrity": "sha512-8TNmfeTCk2Le33A3vRRwtuworG/L5RrgMvdjhKZxvyShO+mBu2fP50OWUjRLNtvw344DdDarFh9buFAZs5ujeA==", "license": "MIT", "dependencies": { - "@jsep-plugin/assignment": "^1.2.1", - "@jsep-plugin/regex": "^1.0.3", - "jsep": "^1.3.9" + "@jsep-plugin/assignment": "^1.3.0", + "@jsep-plugin/regex": "^1.0.4", + "jsep": "^1.4.0" }, "bin": { "jsonpath": "bin/jsonpath-cli.js", @@ -19819,14 +19819,14 @@ } }, "@babylonjs/core": { - "version": "8.44.1", - "resolved": "https://registry.npmjs.org/@babylonjs/core/-/core-8.44.1.tgz", - "integrity": "sha512-sF2WWK2d7lg18ESOCxUoRG4d1SzCWz42asjRjRGxZ8r3D7w9ZM3H2wftJIqwaZvD3zWr+wmCVKpQ6hWkboHIXw==" + "version": "8.45.4", + "resolved": "https://registry.npmjs.org/@babylonjs/core/-/core-8.45.4.tgz", + "integrity": "sha512-fmpaitVpe+bB3PCLY0RKYO/e5n1vLNvueJrglt6SENVE/frZNS4har8odAd1UDNf5KFgOdb8YK91jK4BUwIgcQ==" }, "@babylonjs/gui": { - "version": "8.44.1", - "resolved": "https://registry.npmjs.org/@babylonjs/gui/-/gui-8.44.1.tgz", - "integrity": "sha512-6STDK+Hr8GpY29YMLKnTVhEnWw1NKPrIpz+MqgWuoAAmmpiFtNCr0nnAnCj5fhgGf25L89jy51ogXyg3jfiuDA==", + "version": "8.45.4", + "resolved": "https://registry.npmjs.org/@babylonjs/gui/-/gui-8.45.4.tgz", + "integrity": "sha512-1pMjQs7fgSEvUQoXyit96kNRqzX74oMNkMkAOmz7NjOkBX3tacAfNfoEC6aw+AB+iAjlCO5/DXatZU5m6EYyIQ==", "requires": {} }, "@babylonjs/havok": { @@ -19838,21 +19838,21 @@ } }, "@babylonjs/loaders": { - "version": "8.44.1", - "resolved": "https://registry.npmjs.org/@babylonjs/loaders/-/loaders-8.44.1.tgz", - "integrity": "sha512-h5rUGCwhdWv3Hq48DP8sy4/+3QUYjOprxu2i6zXKb69LHMnYE0tZ1xQHBJEOUF60hxA+TwhzdjC8bxInKoeojA==", + "version": "8.45.4", + "resolved": "https://registry.npmjs.org/@babylonjs/loaders/-/loaders-8.45.4.tgz", + "integrity": "sha512-P1H8XpIJK7NnrtGGSGkCJZIPBvtJ+0+l7yGXDY2UaNFKU80y2Oty8DZ8JRKdbJdSc4cOe8ucBY5w7x+Bbllxuw==", "requires": {} }, "@babylonjs/materials": { - "version": "8.44.1", - "resolved": "https://registry.npmjs.org/@babylonjs/materials/-/materials-8.44.1.tgz", - "integrity": "sha512-FD0S/aA68oEjKCSNY5ydGkiHbsyo08KlhQ+6R8swtJhx5aq7ojWBt3P9KC78+wjZiCJW37176CIObcV8QcjMAQ==", + "version": "8.45.4", + "resolved": "https://registry.npmjs.org/@babylonjs/materials/-/materials-8.45.4.tgz", + "integrity": "sha512-ElTXhC83alnMFFyv2sPG/Im5UwTZoDzd1R8otPQwbEEERcRK8A71Hu1gFdBu/8l9O752IWnZcPSEj1WwLqeR5A==", "requires": {} }, "@babylonjs/serializers": { - "version": "8.44.1", - "resolved": "https://registry.npmjs.org/@babylonjs/serializers/-/serializers-8.44.1.tgz", - "integrity": "sha512-3FRRdKpHr2qTkALHEvq0ih0P59iTINUFrGZWFUfO3Wu24UBSuTxY9Kq820dvUUWaRtWkXEnMSQbR+5glzcfqBw==", + "version": "8.45.4", + "resolved": "https://registry.npmjs.org/@babylonjs/serializers/-/serializers-8.45.4.tgz", + "integrity": "sha512-i83RQIP3XSi3DFJwhc/+JNNPm49DdtNyDobuyBBwIDyMpQdbcFLhkL0DW/7/H+vFUWz0xWx+mgmsb6HY/ePGmg==", "requires": {} }, "@bcoe/v8-coverage": { @@ -19861,45 +19861,45 @@ "integrity": "sha512-0hYQ8SB4Db5zvZB4axdMHGwEaQjkZzFjQiN9LVYvIFB2nSUHW9tYpxWriPrWDASIxiaXax83REcLxuSdnGPZtw==" }, "@bitbybit-dev/babylonjs": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/babylonjs/-/babylonjs-0.21.0.tgz", - "integrity": "sha512-8aPJ+XTXzcnO4bXfmW34lTnVCzC6Hy6TMkh7/ziQSoUsjPp7e7LFHoBBfqCk09LdTLa85gb5x/f6WNAn306Odg==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/babylonjs/-/babylonjs-0.21.1.tgz", + "integrity": "sha512-OyQI5FC4qI5EYW/RFZt/6WR2We2bEpbhM8I8ptiJkviY0e1yIjiV11A4aF8B6fpjS5Bd7Rb30LrUdWNHbAo1Nw==", "requires": { - "@babylonjs/core": "8.44.1", - "@babylonjs/gui": "8.44.1", + "@babylonjs/core": "8.45.4", + "@babylonjs/gui": "8.45.4", "@babylonjs/havok": "1.3.10", - "@babylonjs/loaders": "8.44.1", - "@babylonjs/materials": "8.44.1", - "@babylonjs/serializers": "8.44.1", - "@bitbybit-dev/core": "0.21.0", + "@babylonjs/loaders": "8.45.4", + "@babylonjs/materials": "8.45.4", + "@babylonjs/serializers": "8.45.4", + "@bitbybit-dev/core": "0.21.1", "earcut": "2.2.3" } }, "@bitbybit-dev/base": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/base/-/base-0.21.0.tgz", - "integrity": "sha512-dNfsf2tu3/QUD1mvZzzTze8RwHyK2Jrt+Ary8EDKdNKMw+abtCpQYNerdrg0ZQPxvwu/OOQz6N1xCsCwsPkQJg==" + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/base/-/base-0.21.1.tgz", + "integrity": "sha512-d3aHPpLHigeNTceMi0U/wOIzCqkvHg8S2gNa4b8VGSTifbn7Fo1XbQ2pzetbcOtwtJhkcLgNYn3nFqW8S2MUpw==" }, "@bitbybit-dev/core": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/core/-/core-0.21.0.tgz", - "integrity": "sha512-IbeQ8ROreu0/RkkngUE+Eb19ecvqKOWhGefXvIqQmplxt3zEc0FI4Kw8wR3vYl2XMannuVt1xAIYtqqH0tjBzg==", - "requires": { - "@bitbybit-dev/base": "0.21.0", - "@bitbybit-dev/jscad-worker": "0.21.0", - "@bitbybit-dev/manifold-worker": "0.21.0", - "@bitbybit-dev/occt-worker": "0.21.0", - "jsonpath-plus": "10.1.0", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/core/-/core-0.21.1.tgz", + "integrity": "sha512-Zr2w4h1eBRgOHevKevTaDeL1KlOju6Q8uT62zLeKAAAAn5P1RNn2jOVnHEJtd7y4wPn7G2rZwlwtBQlYe5t9AQ==", + "requires": { + "@bitbybit-dev/base": "0.21.1", + "@bitbybit-dev/jscad-worker": "0.21.1", + "@bitbybit-dev/manifold-worker": "0.21.1", + "@bitbybit-dev/occt-worker": "0.21.1", + "jsonpath-plus": "10.3.0", "rxjs": "7.5.5", "verb-nurbs-web": "2.1.3" } }, "@bitbybit-dev/jscad": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/jscad/-/jscad-0.21.0.tgz", - "integrity": "sha512-Q7eE2ILrJRstW4L1711aJZdpwPf1kuhZJqB+KLkkBLsneRsGsh82lBcCbVYAOMuF/q8Lnd4JHxPiIG/m+LYmPQ==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/jscad/-/jscad-0.21.1.tgz", + "integrity": "sha512-nw8dHGYy3GPXoX0xLZeVsB0Z013mzIy4GoniLKvzN7ApnTruPxSFisxrvFajCcQpL5UbU8SW4k+LhJDI8FTlRg==", "requires": { - "@bitbybit-dev/base": "0.21.0", + "@bitbybit-dev/base": "0.21.1", "@jscad/3mf-serializer": "2.1.12", "@jscad/dxf-serializer": "2.1.18", "@jscad/io-utils": "2.0.28", @@ -19908,46 +19908,46 @@ } }, "@bitbybit-dev/jscad-worker": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/jscad-worker/-/jscad-worker-0.21.0.tgz", - "integrity": "sha512-nIvd7GH5Gg51u6PmFXOADXVYTIvixTkNf0YapS1uix7D2JS9Mx10Z4wHAeRKzvJxUAAbEPPRFNkakE22HFGtLQ==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/jscad-worker/-/jscad-worker-0.21.1.tgz", + "integrity": "sha512-ccaXGTnKseWGDGEdgf3HfQqBWmM4Q384NQWO2kdzZ4EHaZlSp9tEHY8NHOxyxPoMol+qK9u9puH4ux13zY+FrQ==", "requires": { - "@bitbybit-dev/jscad": "0.21.0", + "@bitbybit-dev/jscad": "0.21.1", "rxjs": "7.5.5" } }, "@bitbybit-dev/manifold": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/manifold/-/manifold-0.21.0.tgz", - "integrity": "sha512-DPpwK9ESB+auDeAbzXcfWRVEzWoMDkpkjc+/uwh+zuSiHSx92PSkzx1/LVTbQCsK+aOfOOy03HQCF5Bu2KQYtw==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/manifold/-/manifold-0.21.1.tgz", + "integrity": "sha512-/UqejYCN9YIyBzf5yQXPdSawoKqEUd1aQAKdmge4LoUaZ19eQyRHLK4WpZQ8K+7lTr7qcNQARr7mLx0FQMBFew==", "requires": { - "@bitbybit-dev/base": "0.21.0", + "@bitbybit-dev/base": "0.21.1", "manifold-3d": "3.3.2" } }, "@bitbybit-dev/manifold-worker": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/manifold-worker/-/manifold-worker-0.21.0.tgz", - "integrity": "sha512-6Cqv3BP+uI8mHKHI6Jx9TzCxRg1/kMHhCe18+B3KD/rTl9B5mnScCKRBnDansR3bH7aYZGnIw9PmiFnWLkQWEQ==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/manifold-worker/-/manifold-worker-0.21.1.tgz", + "integrity": "sha512-A+oV172dZzehkeF5kdCFzQuyyfj9FLixq5nGNviOpJX3zaF+0efl1ung1o45V5pLtZkuGCgCZaQ6lY0zNQcYig==", "requires": { - "@bitbybit-dev/manifold": "0.21.0", + "@bitbybit-dev/manifold": "0.21.1", "rxjs": "7.5.5" } }, "@bitbybit-dev/occt": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/occt/-/occt-0.21.0.tgz", - "integrity": "sha512-vPu3NmF1kBZMOkOdysolGfFxEEnwdHNGORoX3eWbMWT2JL/Tag5Q2CAc5jwa2VvZnS1nE/9x+DVlFQSo8LQnIg==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/occt/-/occt-0.21.1.tgz", + "integrity": "sha512-0+yffQRmph9W1qLSyRBUvaQDiZ9OHA2kD2/LsCgxR3NVtKs3GZaAYYhoUfaRqtt2I8Go99e8WBB5daaQceudjA==", "requires": { - "@bitbybit-dev/base": "0.21.0" + "@bitbybit-dev/base": "0.21.1" } }, "@bitbybit-dev/occt-worker": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/occt-worker/-/occt-worker-0.21.0.tgz", - "integrity": "sha512-xG1sgo6q/RdVA8AgG72wPe4qxcQlrO1V7/Ksn6MqIhZVTsJcm5RbVYlK+nziIWhvlMc1sKE0GNQFcPdALISLuQ==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/occt-worker/-/occt-worker-0.21.1.tgz", + "integrity": "sha512-3BW0lTiY8muPSiCWplAT/VQHaHFVUvljMGD1ynQo7cqv/Zna9ACn+SHOMY2HJ7m1MnZq5d2dGjJJXo8k19iV8Q==", "requires": { - "@bitbybit-dev/occt": "0.21.0", + "@bitbybit-dev/occt": "0.21.1", "rxjs": "7.5.5" } }, @@ -22807,9 +22807,9 @@ } }, "babylonjs-gltf2interface": { - "version": "8.44.1", - "resolved": "https://registry.npmjs.org/babylonjs-gltf2interface/-/babylonjs-gltf2interface-8.44.1.tgz", - "integrity": "sha512-+z0P0wms1FD5xuVpuRJ1qjvGAbPAWhEWGBWENRPD0Hbz6nd9cnL28/pjxgk39/QhlIuJKL9JZ0o8G0JgLHEnRQ==", + "version": "8.45.5", + "resolved": "https://registry.npmjs.org/babylonjs-gltf2interface/-/babylonjs-gltf2interface-8.45.5.tgz", + "integrity": "sha512-o1OMBVdeKCK7b+L1VUW1w1+KIi1DTP7Po+SAJ3vwPqRG6xD2eTL+w5IaFHVue3dVjnlU8Z+9y3BP3AadmK0H9w==", "peer": true }, "balanced-match": { @@ -27538,13 +27538,13 @@ } }, "jsonpath-plus": { - "version": "10.1.0", - "resolved": "https://registry.npmjs.org/jsonpath-plus/-/jsonpath-plus-10.1.0.tgz", - "integrity": "sha512-gHfV1IYqH8uJHYVTs8BJX1XKy2/rR93+f8QQi0xhx95aCiXn1ettYAd5T+7FU6wfqyDoX/wy0pm/fL3jOKJ9Lg==", + "version": "10.3.0", + "resolved": "https://registry.npmjs.org/jsonpath-plus/-/jsonpath-plus-10.3.0.tgz", + "integrity": "sha512-8TNmfeTCk2Le33A3vRRwtuworG/L5RrgMvdjhKZxvyShO+mBu2fP50OWUjRLNtvw344DdDarFh9buFAZs5ujeA==", "requires": { - "@jsep-plugin/assignment": "^1.2.1", - "@jsep-plugin/regex": "^1.0.3", - "jsep": "^1.3.9" + "@jsep-plugin/assignment": "^1.3.0", + "@jsep-plugin/regex": "^1.0.4", + "jsep": "^1.4.0" } }, "jsonpointer": { diff --git a/examples/react/babylonjs/cup/package.json b/examples/react/babylonjs/cup/package.json index b6e0b454..33c5f0b4 100644 --- a/examples/react/babylonjs/cup/package.json +++ b/examples/react/babylonjs/cup/package.json @@ -4,7 +4,7 @@ "private": true, "homepage": "https://app-store.bitbybit.dev/cup", "dependencies": { - "@bitbybit-dev/babylonjs": "0.21.0", + "@bitbybit-dev/babylonjs": "0.21.1", "@emotion/react": "11.9.0", "@emotion/styled": "11.8.1", "web-ifc": "0.0.68", diff --git a/examples/react/babylonjs/laptop-holder/package-lock.json b/examples/react/babylonjs/laptop-holder/package-lock.json index 8354f5e1..0790d7d2 100644 --- a/examples/react/babylonjs/laptop-holder/package-lock.json +++ b/examples/react/babylonjs/laptop-holder/package-lock.json @@ -8,7 +8,7 @@ "name": "laptop-holder", "version": "0.1.0", "dependencies": { - "@bitbybit-dev/babylonjs": "0.21.0", + "@bitbybit-dev/babylonjs": "0.21.1", "@emotion/react": "11.9.0", "@emotion/styled": "11.8.1", "@mui/icons-material": "5.6.2", @@ -1847,15 +1847,15 @@ } }, "node_modules/@babylonjs/core": { - "version": "8.44.1", - "resolved": "https://registry.npmjs.org/@babylonjs/core/-/core-8.44.1.tgz", - "integrity": "sha512-sF2WWK2d7lg18ESOCxUoRG4d1SzCWz42asjRjRGxZ8r3D7w9ZM3H2wftJIqwaZvD3zWr+wmCVKpQ6hWkboHIXw==", + "version": "8.45.4", + "resolved": "https://registry.npmjs.org/@babylonjs/core/-/core-8.45.4.tgz", + "integrity": "sha512-fmpaitVpe+bB3PCLY0RKYO/e5n1vLNvueJrglt6SENVE/frZNS4har8odAd1UDNf5KFgOdb8YK91jK4BUwIgcQ==", "license": "Apache-2.0" }, "node_modules/@babylonjs/gui": { - "version": "8.44.1", - "resolved": "https://registry.npmjs.org/@babylonjs/gui/-/gui-8.44.1.tgz", - "integrity": "sha512-6STDK+Hr8GpY29YMLKnTVhEnWw1NKPrIpz+MqgWuoAAmmpiFtNCr0nnAnCj5fhgGf25L89jy51ogXyg3jfiuDA==", + "version": "8.45.4", + "resolved": "https://registry.npmjs.org/@babylonjs/gui/-/gui-8.45.4.tgz", + "integrity": "sha512-1pMjQs7fgSEvUQoXyit96kNRqzX74oMNkMkAOmz7NjOkBX3tacAfNfoEC6aw+AB+iAjlCO5/DXatZU5m6EYyIQ==", "license": "Apache-2.0", "peerDependencies": { "@babylonjs/core": "^8.0.0" @@ -1870,9 +1870,9 @@ } }, "node_modules/@babylonjs/loaders": { - "version": "8.44.1", - "resolved": "https://registry.npmjs.org/@babylonjs/loaders/-/loaders-8.44.1.tgz", - "integrity": "sha512-h5rUGCwhdWv3Hq48DP8sy4/+3QUYjOprxu2i6zXKb69LHMnYE0tZ1xQHBJEOUF60hxA+TwhzdjC8bxInKoeojA==", + "version": "8.45.4", + "resolved": "https://registry.npmjs.org/@babylonjs/loaders/-/loaders-8.45.4.tgz", + "integrity": "sha512-P1H8XpIJK7NnrtGGSGkCJZIPBvtJ+0+l7yGXDY2UaNFKU80y2Oty8DZ8JRKdbJdSc4cOe8ucBY5w7x+Bbllxuw==", "license": "Apache-2.0", "peerDependencies": { "@babylonjs/core": "^8.0.0", @@ -1880,18 +1880,18 @@ } }, "node_modules/@babylonjs/materials": { - "version": "8.44.1", - "resolved": "https://registry.npmjs.org/@babylonjs/materials/-/materials-8.44.1.tgz", - "integrity": "sha512-FD0S/aA68oEjKCSNY5ydGkiHbsyo08KlhQ+6R8swtJhx5aq7ojWBt3P9KC78+wjZiCJW37176CIObcV8QcjMAQ==", + "version": "8.45.4", + "resolved": "https://registry.npmjs.org/@babylonjs/materials/-/materials-8.45.4.tgz", + "integrity": "sha512-ElTXhC83alnMFFyv2sPG/Im5UwTZoDzd1R8otPQwbEEERcRK8A71Hu1gFdBu/8l9O752IWnZcPSEj1WwLqeR5A==", "license": "Apache-2.0", "peerDependencies": { "@babylonjs/core": "^8.6.0" } }, "node_modules/@babylonjs/serializers": { - "version": "8.44.1", - "resolved": "https://registry.npmjs.org/@babylonjs/serializers/-/serializers-8.44.1.tgz", - "integrity": "sha512-3FRRdKpHr2qTkALHEvq0ih0P59iTINUFrGZWFUfO3Wu24UBSuTxY9Kq820dvUUWaRtWkXEnMSQbR+5glzcfqBw==", + "version": "8.45.4", + "resolved": "https://registry.npmjs.org/@babylonjs/serializers/-/serializers-8.45.4.tgz", + "integrity": "sha512-i83RQIP3XSi3DFJwhc/+JNNPm49DdtNyDobuyBBwIDyMpQdbcFLhkL0DW/7/H+vFUWz0xWx+mgmsb6HY/ePGmg==", "license": "Apache-2.0", "peerDependencies": { "@babylonjs/core": "^8.0.0", @@ -1904,49 +1904,49 @@ "integrity": "sha512-0hYQ8SB4Db5zvZB4axdMHGwEaQjkZzFjQiN9LVYvIFB2nSUHW9tYpxWriPrWDASIxiaXax83REcLxuSdnGPZtw==" }, "node_modules/@bitbybit-dev/babylonjs": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/babylonjs/-/babylonjs-0.21.0.tgz", - "integrity": "sha512-8aPJ+XTXzcnO4bXfmW34lTnVCzC6Hy6TMkh7/ziQSoUsjPp7e7LFHoBBfqCk09LdTLa85gb5x/f6WNAn306Odg==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/babylonjs/-/babylonjs-0.21.1.tgz", + "integrity": "sha512-OyQI5FC4qI5EYW/RFZt/6WR2We2bEpbhM8I8ptiJkviY0e1yIjiV11A4aF8B6fpjS5Bd7Rb30LrUdWNHbAo1Nw==", "license": "MIT", "dependencies": { - "@babylonjs/core": "8.44.1", - "@babylonjs/gui": "8.44.1", + "@babylonjs/core": "8.45.4", + "@babylonjs/gui": "8.45.4", "@babylonjs/havok": "1.3.10", - "@babylonjs/loaders": "8.44.1", - "@babylonjs/materials": "8.44.1", - "@babylonjs/serializers": "8.44.1", - "@bitbybit-dev/core": "0.21.0", + "@babylonjs/loaders": "8.45.4", + "@babylonjs/materials": "8.45.4", + "@babylonjs/serializers": "8.45.4", + "@bitbybit-dev/core": "0.21.1", "earcut": "2.2.3" } }, "node_modules/@bitbybit-dev/base": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/base/-/base-0.21.0.tgz", - "integrity": "sha512-dNfsf2tu3/QUD1mvZzzTze8RwHyK2Jrt+Ary8EDKdNKMw+abtCpQYNerdrg0ZQPxvwu/OOQz6N1xCsCwsPkQJg==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/base/-/base-0.21.1.tgz", + "integrity": "sha512-d3aHPpLHigeNTceMi0U/wOIzCqkvHg8S2gNa4b8VGSTifbn7Fo1XbQ2pzetbcOtwtJhkcLgNYn3nFqW8S2MUpw==", "license": "MIT" }, "node_modules/@bitbybit-dev/core": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/core/-/core-0.21.0.tgz", - "integrity": "sha512-IbeQ8ROreu0/RkkngUE+Eb19ecvqKOWhGefXvIqQmplxt3zEc0FI4Kw8wR3vYl2XMannuVt1xAIYtqqH0tjBzg==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/core/-/core-0.21.1.tgz", + "integrity": "sha512-Zr2w4h1eBRgOHevKevTaDeL1KlOju6Q8uT62zLeKAAAAn5P1RNn2jOVnHEJtd7y4wPn7G2rZwlwtBQlYe5t9AQ==", "license": "MIT", "dependencies": { - "@bitbybit-dev/base": "0.21.0", - "@bitbybit-dev/jscad-worker": "0.21.0", - "@bitbybit-dev/manifold-worker": "0.21.0", - "@bitbybit-dev/occt-worker": "0.21.0", - "jsonpath-plus": "10.1.0", + "@bitbybit-dev/base": "0.21.1", + "@bitbybit-dev/jscad-worker": "0.21.1", + "@bitbybit-dev/manifold-worker": "0.21.1", + "@bitbybit-dev/occt-worker": "0.21.1", + "jsonpath-plus": "10.3.0", "rxjs": "7.5.5", "verb-nurbs-web": "2.1.3" } }, "node_modules/@bitbybit-dev/jscad": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/jscad/-/jscad-0.21.0.tgz", - "integrity": "sha512-Q7eE2ILrJRstW4L1711aJZdpwPf1kuhZJqB+KLkkBLsneRsGsh82lBcCbVYAOMuF/q8Lnd4JHxPiIG/m+LYmPQ==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/jscad/-/jscad-0.21.1.tgz", + "integrity": "sha512-nw8dHGYy3GPXoX0xLZeVsB0Z013mzIy4GoniLKvzN7ApnTruPxSFisxrvFajCcQpL5UbU8SW4k+LhJDI8FTlRg==", "license": "MIT", "dependencies": { - "@bitbybit-dev/base": "0.21.0", + "@bitbybit-dev/base": "0.21.1", "@jscad/3mf-serializer": "2.1.12", "@jscad/dxf-serializer": "2.1.18", "@jscad/io-utils": "2.0.28", @@ -1955,51 +1955,51 @@ } }, "node_modules/@bitbybit-dev/jscad-worker": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/jscad-worker/-/jscad-worker-0.21.0.tgz", - "integrity": "sha512-nIvd7GH5Gg51u6PmFXOADXVYTIvixTkNf0YapS1uix7D2JS9Mx10Z4wHAeRKzvJxUAAbEPPRFNkakE22HFGtLQ==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/jscad-worker/-/jscad-worker-0.21.1.tgz", + "integrity": "sha512-ccaXGTnKseWGDGEdgf3HfQqBWmM4Q384NQWO2kdzZ4EHaZlSp9tEHY8NHOxyxPoMol+qK9u9puH4ux13zY+FrQ==", "license": "MIT", "dependencies": { - "@bitbybit-dev/jscad": "0.21.0", + "@bitbybit-dev/jscad": "0.21.1", "rxjs": "7.5.5" } }, "node_modules/@bitbybit-dev/manifold": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/manifold/-/manifold-0.21.0.tgz", - "integrity": "sha512-DPpwK9ESB+auDeAbzXcfWRVEzWoMDkpkjc+/uwh+zuSiHSx92PSkzx1/LVTbQCsK+aOfOOy03HQCF5Bu2KQYtw==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/manifold/-/manifold-0.21.1.tgz", + "integrity": "sha512-/UqejYCN9YIyBzf5yQXPdSawoKqEUd1aQAKdmge4LoUaZ19eQyRHLK4WpZQ8K+7lTr7qcNQARr7mLx0FQMBFew==", "license": "MIT", "dependencies": { - "@bitbybit-dev/base": "0.21.0", + "@bitbybit-dev/base": "0.21.1", "manifold-3d": "3.3.2" } }, "node_modules/@bitbybit-dev/manifold-worker": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/manifold-worker/-/manifold-worker-0.21.0.tgz", - "integrity": "sha512-6Cqv3BP+uI8mHKHI6Jx9TzCxRg1/kMHhCe18+B3KD/rTl9B5mnScCKRBnDansR3bH7aYZGnIw9PmiFnWLkQWEQ==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/manifold-worker/-/manifold-worker-0.21.1.tgz", + "integrity": "sha512-A+oV172dZzehkeF5kdCFzQuyyfj9FLixq5nGNviOpJX3zaF+0efl1ung1o45V5pLtZkuGCgCZaQ6lY0zNQcYig==", "license": "MIT", "dependencies": { - "@bitbybit-dev/manifold": "0.21.0", + "@bitbybit-dev/manifold": "0.21.1", "rxjs": "7.5.5" } }, "node_modules/@bitbybit-dev/occt": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/occt/-/occt-0.21.0.tgz", - "integrity": "sha512-vPu3NmF1kBZMOkOdysolGfFxEEnwdHNGORoX3eWbMWT2JL/Tag5Q2CAc5jwa2VvZnS1nE/9x+DVlFQSo8LQnIg==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/occt/-/occt-0.21.1.tgz", + "integrity": "sha512-0+yffQRmph9W1qLSyRBUvaQDiZ9OHA2kD2/LsCgxR3NVtKs3GZaAYYhoUfaRqtt2I8Go99e8WBB5daaQceudjA==", "license": "MIT", "dependencies": { - "@bitbybit-dev/base": "0.21.0" + "@bitbybit-dev/base": "0.21.1" } }, "node_modules/@bitbybit-dev/occt-worker": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/occt-worker/-/occt-worker-0.21.0.tgz", - "integrity": "sha512-xG1sgo6q/RdVA8AgG72wPe4qxcQlrO1V7/Ksn6MqIhZVTsJcm5RbVYlK+nziIWhvlMc1sKE0GNQFcPdALISLuQ==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/occt-worker/-/occt-worker-0.21.1.tgz", + "integrity": "sha512-3BW0lTiY8muPSiCWplAT/VQHaHFVUvljMGD1ynQo7cqv/Zna9ACn+SHOMY2HJ7m1MnZq5d2dGjJJXo8k19iV8Q==", "license": "MIT", "dependencies": { - "@bitbybit-dev/occt": "0.21.0", + "@bitbybit-dev/occt": "0.21.1", "rxjs": "7.5.5" } }, @@ -5933,9 +5933,9 @@ } }, "node_modules/babylonjs-gltf2interface": { - "version": "8.44.1", - "resolved": "https://registry.npmjs.org/babylonjs-gltf2interface/-/babylonjs-gltf2interface-8.44.1.tgz", - "integrity": "sha512-+z0P0wms1FD5xuVpuRJ1qjvGAbPAWhEWGBWENRPD0Hbz6nd9cnL28/pjxgk39/QhlIuJKL9JZ0o8G0JgLHEnRQ==", + "version": "8.45.5", + "resolved": "https://registry.npmjs.org/babylonjs-gltf2interface/-/babylonjs-gltf2interface-8.45.5.tgz", + "integrity": "sha512-o1OMBVdeKCK7b+L1VUW1w1+KIi1DTP7Po+SAJ3vwPqRG6xD2eTL+w5IaFHVue3dVjnlU8Z+9y3BP3AadmK0H9w==", "license": "Apache-2.0", "peer": true }, @@ -11995,14 +11995,14 @@ } }, "node_modules/jsonpath-plus": { - "version": "10.1.0", - "resolved": "https://registry.npmjs.org/jsonpath-plus/-/jsonpath-plus-10.1.0.tgz", - "integrity": "sha512-gHfV1IYqH8uJHYVTs8BJX1XKy2/rR93+f8QQi0xhx95aCiXn1ettYAd5T+7FU6wfqyDoX/wy0pm/fL3jOKJ9Lg==", + "version": "10.3.0", + "resolved": "https://registry.npmjs.org/jsonpath-plus/-/jsonpath-plus-10.3.0.tgz", + "integrity": "sha512-8TNmfeTCk2Le33A3vRRwtuworG/L5RrgMvdjhKZxvyShO+mBu2fP50OWUjRLNtvw344DdDarFh9buFAZs5ujeA==", "license": "MIT", "dependencies": { - "@jsep-plugin/assignment": "^1.2.1", - "@jsep-plugin/regex": "^1.0.3", - "jsep": "^1.3.9" + "@jsep-plugin/assignment": "^1.3.0", + "@jsep-plugin/regex": "^1.0.4", + "jsep": "^1.4.0" }, "bin": { "jsonpath": "bin/jsonpath-cli.js", @@ -18897,14 +18897,14 @@ } }, "@babylonjs/core": { - "version": "8.44.1", - "resolved": "https://registry.npmjs.org/@babylonjs/core/-/core-8.44.1.tgz", - "integrity": "sha512-sF2WWK2d7lg18ESOCxUoRG4d1SzCWz42asjRjRGxZ8r3D7w9ZM3H2wftJIqwaZvD3zWr+wmCVKpQ6hWkboHIXw==" + "version": "8.45.4", + "resolved": "https://registry.npmjs.org/@babylonjs/core/-/core-8.45.4.tgz", + "integrity": "sha512-fmpaitVpe+bB3PCLY0RKYO/e5n1vLNvueJrglt6SENVE/frZNS4har8odAd1UDNf5KFgOdb8YK91jK4BUwIgcQ==" }, "@babylonjs/gui": { - "version": "8.44.1", - "resolved": "https://registry.npmjs.org/@babylonjs/gui/-/gui-8.44.1.tgz", - "integrity": "sha512-6STDK+Hr8GpY29YMLKnTVhEnWw1NKPrIpz+MqgWuoAAmmpiFtNCr0nnAnCj5fhgGf25L89jy51ogXyg3jfiuDA==", + "version": "8.45.4", + "resolved": "https://registry.npmjs.org/@babylonjs/gui/-/gui-8.45.4.tgz", + "integrity": "sha512-1pMjQs7fgSEvUQoXyit96kNRqzX74oMNkMkAOmz7NjOkBX3tacAfNfoEC6aw+AB+iAjlCO5/DXatZU5m6EYyIQ==", "requires": {} }, "@babylonjs/havok": { @@ -18916,21 +18916,21 @@ } }, "@babylonjs/loaders": { - "version": "8.44.1", - "resolved": "https://registry.npmjs.org/@babylonjs/loaders/-/loaders-8.44.1.tgz", - "integrity": "sha512-h5rUGCwhdWv3Hq48DP8sy4/+3QUYjOprxu2i6zXKb69LHMnYE0tZ1xQHBJEOUF60hxA+TwhzdjC8bxInKoeojA==", + "version": "8.45.4", + "resolved": "https://registry.npmjs.org/@babylonjs/loaders/-/loaders-8.45.4.tgz", + "integrity": "sha512-P1H8XpIJK7NnrtGGSGkCJZIPBvtJ+0+l7yGXDY2UaNFKU80y2Oty8DZ8JRKdbJdSc4cOe8ucBY5w7x+Bbllxuw==", "requires": {} }, "@babylonjs/materials": { - "version": "8.44.1", - "resolved": "https://registry.npmjs.org/@babylonjs/materials/-/materials-8.44.1.tgz", - "integrity": "sha512-FD0S/aA68oEjKCSNY5ydGkiHbsyo08KlhQ+6R8swtJhx5aq7ojWBt3P9KC78+wjZiCJW37176CIObcV8QcjMAQ==", + "version": "8.45.4", + "resolved": "https://registry.npmjs.org/@babylonjs/materials/-/materials-8.45.4.tgz", + "integrity": "sha512-ElTXhC83alnMFFyv2sPG/Im5UwTZoDzd1R8otPQwbEEERcRK8A71Hu1gFdBu/8l9O752IWnZcPSEj1WwLqeR5A==", "requires": {} }, "@babylonjs/serializers": { - "version": "8.44.1", - "resolved": "https://registry.npmjs.org/@babylonjs/serializers/-/serializers-8.44.1.tgz", - "integrity": "sha512-3FRRdKpHr2qTkALHEvq0ih0P59iTINUFrGZWFUfO3Wu24UBSuTxY9Kq820dvUUWaRtWkXEnMSQbR+5glzcfqBw==", + "version": "8.45.4", + "resolved": "https://registry.npmjs.org/@babylonjs/serializers/-/serializers-8.45.4.tgz", + "integrity": "sha512-i83RQIP3XSi3DFJwhc/+JNNPm49DdtNyDobuyBBwIDyMpQdbcFLhkL0DW/7/H+vFUWz0xWx+mgmsb6HY/ePGmg==", "requires": {} }, "@bcoe/v8-coverage": { @@ -18939,45 +18939,45 @@ "integrity": "sha512-0hYQ8SB4Db5zvZB4axdMHGwEaQjkZzFjQiN9LVYvIFB2nSUHW9tYpxWriPrWDASIxiaXax83REcLxuSdnGPZtw==" }, "@bitbybit-dev/babylonjs": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/babylonjs/-/babylonjs-0.21.0.tgz", - "integrity": "sha512-8aPJ+XTXzcnO4bXfmW34lTnVCzC6Hy6TMkh7/ziQSoUsjPp7e7LFHoBBfqCk09LdTLa85gb5x/f6WNAn306Odg==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/babylonjs/-/babylonjs-0.21.1.tgz", + "integrity": "sha512-OyQI5FC4qI5EYW/RFZt/6WR2We2bEpbhM8I8ptiJkviY0e1yIjiV11A4aF8B6fpjS5Bd7Rb30LrUdWNHbAo1Nw==", "requires": { - "@babylonjs/core": "8.44.1", - "@babylonjs/gui": "8.44.1", + "@babylonjs/core": "8.45.4", + "@babylonjs/gui": "8.45.4", "@babylonjs/havok": "1.3.10", - "@babylonjs/loaders": "8.44.1", - "@babylonjs/materials": "8.44.1", - "@babylonjs/serializers": "8.44.1", - "@bitbybit-dev/core": "0.21.0", + "@babylonjs/loaders": "8.45.4", + "@babylonjs/materials": "8.45.4", + "@babylonjs/serializers": "8.45.4", + "@bitbybit-dev/core": "0.21.1", "earcut": "2.2.3" } }, "@bitbybit-dev/base": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/base/-/base-0.21.0.tgz", - "integrity": "sha512-dNfsf2tu3/QUD1mvZzzTze8RwHyK2Jrt+Ary8EDKdNKMw+abtCpQYNerdrg0ZQPxvwu/OOQz6N1xCsCwsPkQJg==" + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/base/-/base-0.21.1.tgz", + "integrity": "sha512-d3aHPpLHigeNTceMi0U/wOIzCqkvHg8S2gNa4b8VGSTifbn7Fo1XbQ2pzetbcOtwtJhkcLgNYn3nFqW8S2MUpw==" }, "@bitbybit-dev/core": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/core/-/core-0.21.0.tgz", - "integrity": "sha512-IbeQ8ROreu0/RkkngUE+Eb19ecvqKOWhGefXvIqQmplxt3zEc0FI4Kw8wR3vYl2XMannuVt1xAIYtqqH0tjBzg==", - "requires": { - "@bitbybit-dev/base": "0.21.0", - "@bitbybit-dev/jscad-worker": "0.21.0", - "@bitbybit-dev/manifold-worker": "0.21.0", - "@bitbybit-dev/occt-worker": "0.21.0", - "jsonpath-plus": "10.1.0", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/core/-/core-0.21.1.tgz", + "integrity": "sha512-Zr2w4h1eBRgOHevKevTaDeL1KlOju6Q8uT62zLeKAAAAn5P1RNn2jOVnHEJtd7y4wPn7G2rZwlwtBQlYe5t9AQ==", + "requires": { + "@bitbybit-dev/base": "0.21.1", + "@bitbybit-dev/jscad-worker": "0.21.1", + "@bitbybit-dev/manifold-worker": "0.21.1", + "@bitbybit-dev/occt-worker": "0.21.1", + "jsonpath-plus": "10.3.0", "rxjs": "7.5.5", "verb-nurbs-web": "2.1.3" } }, "@bitbybit-dev/jscad": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/jscad/-/jscad-0.21.0.tgz", - "integrity": "sha512-Q7eE2ILrJRstW4L1711aJZdpwPf1kuhZJqB+KLkkBLsneRsGsh82lBcCbVYAOMuF/q8Lnd4JHxPiIG/m+LYmPQ==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/jscad/-/jscad-0.21.1.tgz", + "integrity": "sha512-nw8dHGYy3GPXoX0xLZeVsB0Z013mzIy4GoniLKvzN7ApnTruPxSFisxrvFajCcQpL5UbU8SW4k+LhJDI8FTlRg==", "requires": { - "@bitbybit-dev/base": "0.21.0", + "@bitbybit-dev/base": "0.21.1", "@jscad/3mf-serializer": "2.1.12", "@jscad/dxf-serializer": "2.1.18", "@jscad/io-utils": "2.0.28", @@ -18986,46 +18986,46 @@ } }, "@bitbybit-dev/jscad-worker": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/jscad-worker/-/jscad-worker-0.21.0.tgz", - "integrity": "sha512-nIvd7GH5Gg51u6PmFXOADXVYTIvixTkNf0YapS1uix7D2JS9Mx10Z4wHAeRKzvJxUAAbEPPRFNkakE22HFGtLQ==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/jscad-worker/-/jscad-worker-0.21.1.tgz", + "integrity": "sha512-ccaXGTnKseWGDGEdgf3HfQqBWmM4Q384NQWO2kdzZ4EHaZlSp9tEHY8NHOxyxPoMol+qK9u9puH4ux13zY+FrQ==", "requires": { - "@bitbybit-dev/jscad": "0.21.0", + "@bitbybit-dev/jscad": "0.21.1", "rxjs": "7.5.5" } }, "@bitbybit-dev/manifold": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/manifold/-/manifold-0.21.0.tgz", - "integrity": "sha512-DPpwK9ESB+auDeAbzXcfWRVEzWoMDkpkjc+/uwh+zuSiHSx92PSkzx1/LVTbQCsK+aOfOOy03HQCF5Bu2KQYtw==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/manifold/-/manifold-0.21.1.tgz", + "integrity": "sha512-/UqejYCN9YIyBzf5yQXPdSawoKqEUd1aQAKdmge4LoUaZ19eQyRHLK4WpZQ8K+7lTr7qcNQARr7mLx0FQMBFew==", "requires": { - "@bitbybit-dev/base": "0.21.0", + "@bitbybit-dev/base": "0.21.1", "manifold-3d": "3.3.2" } }, "@bitbybit-dev/manifold-worker": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/manifold-worker/-/manifold-worker-0.21.0.tgz", - "integrity": "sha512-6Cqv3BP+uI8mHKHI6Jx9TzCxRg1/kMHhCe18+B3KD/rTl9B5mnScCKRBnDansR3bH7aYZGnIw9PmiFnWLkQWEQ==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/manifold-worker/-/manifold-worker-0.21.1.tgz", + "integrity": "sha512-A+oV172dZzehkeF5kdCFzQuyyfj9FLixq5nGNviOpJX3zaF+0efl1ung1o45V5pLtZkuGCgCZaQ6lY0zNQcYig==", "requires": { - "@bitbybit-dev/manifold": "0.21.0", + "@bitbybit-dev/manifold": "0.21.1", "rxjs": "7.5.5" } }, "@bitbybit-dev/occt": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/occt/-/occt-0.21.0.tgz", - "integrity": "sha512-vPu3NmF1kBZMOkOdysolGfFxEEnwdHNGORoX3eWbMWT2JL/Tag5Q2CAc5jwa2VvZnS1nE/9x+DVlFQSo8LQnIg==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/occt/-/occt-0.21.1.tgz", + "integrity": "sha512-0+yffQRmph9W1qLSyRBUvaQDiZ9OHA2kD2/LsCgxR3NVtKs3GZaAYYhoUfaRqtt2I8Go99e8WBB5daaQceudjA==", "requires": { - "@bitbybit-dev/base": "0.21.0" + "@bitbybit-dev/base": "0.21.1" } }, "@bitbybit-dev/occt-worker": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/occt-worker/-/occt-worker-0.21.0.tgz", - "integrity": "sha512-xG1sgo6q/RdVA8AgG72wPe4qxcQlrO1V7/Ksn6MqIhZVTsJcm5RbVYlK+nziIWhvlMc1sKE0GNQFcPdALISLuQ==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/occt-worker/-/occt-worker-0.21.1.tgz", + "integrity": "sha512-3BW0lTiY8muPSiCWplAT/VQHaHFVUvljMGD1ynQo7cqv/Zna9ACn+SHOMY2HJ7m1MnZq5d2dGjJJXo8k19iV8Q==", "requires": { - "@bitbybit-dev/occt": "0.21.0", + "@bitbybit-dev/occt": "0.21.1", "rxjs": "7.5.5" } }, @@ -21688,9 +21688,9 @@ } }, "babylonjs-gltf2interface": { - "version": "8.44.1", - "resolved": "https://registry.npmjs.org/babylonjs-gltf2interface/-/babylonjs-gltf2interface-8.44.1.tgz", - "integrity": "sha512-+z0P0wms1FD5xuVpuRJ1qjvGAbPAWhEWGBWENRPD0Hbz6nd9cnL28/pjxgk39/QhlIuJKL9JZ0o8G0JgLHEnRQ==", + "version": "8.45.5", + "resolved": "https://registry.npmjs.org/babylonjs-gltf2interface/-/babylonjs-gltf2interface-8.45.5.tgz", + "integrity": "sha512-o1OMBVdeKCK7b+L1VUW1w1+KIi1DTP7Po+SAJ3vwPqRG6xD2eTL+w5IaFHVue3dVjnlU8Z+9y3BP3AadmK0H9w==", "peer": true }, "balanced-match": { @@ -26074,13 +26074,13 @@ } }, "jsonpath-plus": { - "version": "10.1.0", - "resolved": "https://registry.npmjs.org/jsonpath-plus/-/jsonpath-plus-10.1.0.tgz", - "integrity": "sha512-gHfV1IYqH8uJHYVTs8BJX1XKy2/rR93+f8QQi0xhx95aCiXn1ettYAd5T+7FU6wfqyDoX/wy0pm/fL3jOKJ9Lg==", + "version": "10.3.0", + "resolved": "https://registry.npmjs.org/jsonpath-plus/-/jsonpath-plus-10.3.0.tgz", + "integrity": "sha512-8TNmfeTCk2Le33A3vRRwtuworG/L5RrgMvdjhKZxvyShO+mBu2fP50OWUjRLNtvw344DdDarFh9buFAZs5ujeA==", "requires": { - "@jsep-plugin/assignment": "^1.2.1", - "@jsep-plugin/regex": "^1.0.3", - "jsep": "^1.3.9" + "@jsep-plugin/assignment": "^1.3.0", + "@jsep-plugin/regex": "^1.0.4", + "jsep": "^1.4.0" } }, "jsonpointer": { diff --git a/examples/react/babylonjs/laptop-holder/package.json b/examples/react/babylonjs/laptop-holder/package.json index 4935f85f..8d88d1b6 100644 --- a/examples/react/babylonjs/laptop-holder/package.json +++ b/examples/react/babylonjs/laptop-holder/package.json @@ -16,7 +16,7 @@ "react-scripts": "5.0.1", "typescript": "^4.6.2", "web-vitals": "^2.1.4", - "@bitbybit-dev/babylonjs": "0.21.0", + "@bitbybit-dev/babylonjs": "0.21.1", "file-loader": "6.2.0", "@mui/icons-material": "5.6.2", "@mui/material": "5.6.4", diff --git a/examples/react/threejs/vase/package-lock.json b/examples/react/threejs/vase/package-lock.json index 6fff5bd8..5b7e0822 100644 --- a/examples/react/threejs/vase/package-lock.json +++ b/examples/react/threejs/vase/package-lock.json @@ -9,7 +9,7 @@ "version": "0.1.0", "dependencies": { "@babel/plugin-proposal-private-property-in-object": "7.21.11", - "@bitbybit-dev/threejs": "0.21.0", + "@bitbybit-dev/threejs": "0.21.1", "@emotion/react": "11.11.0", "@emotion/styled": "11.11.0", "@mui/icons-material": "5.11.16", @@ -1995,33 +1995,33 @@ "integrity": "sha512-0hYQ8SB4Db5zvZB4axdMHGwEaQjkZzFjQiN9LVYvIFB2nSUHW9tYpxWriPrWDASIxiaXax83REcLxuSdnGPZtw==" }, "node_modules/@bitbybit-dev/base": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/base/-/base-0.21.0.tgz", - "integrity": "sha512-dNfsf2tu3/QUD1mvZzzTze8RwHyK2Jrt+Ary8EDKdNKMw+abtCpQYNerdrg0ZQPxvwu/OOQz6N1xCsCwsPkQJg==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/base/-/base-0.21.1.tgz", + "integrity": "sha512-d3aHPpLHigeNTceMi0U/wOIzCqkvHg8S2gNa4b8VGSTifbn7Fo1XbQ2pzetbcOtwtJhkcLgNYn3nFqW8S2MUpw==", "license": "MIT" }, "node_modules/@bitbybit-dev/core": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/core/-/core-0.21.0.tgz", - "integrity": "sha512-IbeQ8ROreu0/RkkngUE+Eb19ecvqKOWhGefXvIqQmplxt3zEc0FI4Kw8wR3vYl2XMannuVt1xAIYtqqH0tjBzg==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/core/-/core-0.21.1.tgz", + "integrity": "sha512-Zr2w4h1eBRgOHevKevTaDeL1KlOju6Q8uT62zLeKAAAAn5P1RNn2jOVnHEJtd7y4wPn7G2rZwlwtBQlYe5t9AQ==", "license": "MIT", "dependencies": { - "@bitbybit-dev/base": "0.21.0", - "@bitbybit-dev/jscad-worker": "0.21.0", - "@bitbybit-dev/manifold-worker": "0.21.0", - "@bitbybit-dev/occt-worker": "0.21.0", - "jsonpath-plus": "10.1.0", + "@bitbybit-dev/base": "0.21.1", + "@bitbybit-dev/jscad-worker": "0.21.1", + "@bitbybit-dev/manifold-worker": "0.21.1", + "@bitbybit-dev/occt-worker": "0.21.1", + "jsonpath-plus": "10.3.0", "rxjs": "7.5.5", "verb-nurbs-web": "2.1.3" } }, "node_modules/@bitbybit-dev/jscad": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/jscad/-/jscad-0.21.0.tgz", - "integrity": "sha512-Q7eE2ILrJRstW4L1711aJZdpwPf1kuhZJqB+KLkkBLsneRsGsh82lBcCbVYAOMuF/q8Lnd4JHxPiIG/m+LYmPQ==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/jscad/-/jscad-0.21.1.tgz", + "integrity": "sha512-nw8dHGYy3GPXoX0xLZeVsB0Z013mzIy4GoniLKvzN7ApnTruPxSFisxrvFajCcQpL5UbU8SW4k+LhJDI8FTlRg==", "license": "MIT", "dependencies": { - "@bitbybit-dev/base": "0.21.0", + "@bitbybit-dev/base": "0.21.1", "@jscad/3mf-serializer": "2.1.12", "@jscad/dxf-serializer": "2.1.18", "@jscad/io-utils": "2.0.28", @@ -2030,61 +2030,61 @@ } }, "node_modules/@bitbybit-dev/jscad-worker": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/jscad-worker/-/jscad-worker-0.21.0.tgz", - "integrity": "sha512-nIvd7GH5Gg51u6PmFXOADXVYTIvixTkNf0YapS1uix7D2JS9Mx10Z4wHAeRKzvJxUAAbEPPRFNkakE22HFGtLQ==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/jscad-worker/-/jscad-worker-0.21.1.tgz", + "integrity": "sha512-ccaXGTnKseWGDGEdgf3HfQqBWmM4Q384NQWO2kdzZ4EHaZlSp9tEHY8NHOxyxPoMol+qK9u9puH4ux13zY+FrQ==", "license": "MIT", "dependencies": { - "@bitbybit-dev/jscad": "0.21.0", + "@bitbybit-dev/jscad": "0.21.1", "rxjs": "7.5.5" } }, "node_modules/@bitbybit-dev/manifold": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/manifold/-/manifold-0.21.0.tgz", - "integrity": "sha512-DPpwK9ESB+auDeAbzXcfWRVEzWoMDkpkjc+/uwh+zuSiHSx92PSkzx1/LVTbQCsK+aOfOOy03HQCF5Bu2KQYtw==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/manifold/-/manifold-0.21.1.tgz", + "integrity": "sha512-/UqejYCN9YIyBzf5yQXPdSawoKqEUd1aQAKdmge4LoUaZ19eQyRHLK4WpZQ8K+7lTr7qcNQARr7mLx0FQMBFew==", "license": "MIT", "dependencies": { - "@bitbybit-dev/base": "0.21.0", + "@bitbybit-dev/base": "0.21.1", "manifold-3d": "3.3.2" } }, "node_modules/@bitbybit-dev/manifold-worker": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/manifold-worker/-/manifold-worker-0.21.0.tgz", - "integrity": "sha512-6Cqv3BP+uI8mHKHI6Jx9TzCxRg1/kMHhCe18+B3KD/rTl9B5mnScCKRBnDansR3bH7aYZGnIw9PmiFnWLkQWEQ==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/manifold-worker/-/manifold-worker-0.21.1.tgz", + "integrity": "sha512-A+oV172dZzehkeF5kdCFzQuyyfj9FLixq5nGNviOpJX3zaF+0efl1ung1o45V5pLtZkuGCgCZaQ6lY0zNQcYig==", "license": "MIT", "dependencies": { - "@bitbybit-dev/manifold": "0.21.0", + "@bitbybit-dev/manifold": "0.21.1", "rxjs": "7.5.5" } }, "node_modules/@bitbybit-dev/occt": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/occt/-/occt-0.21.0.tgz", - "integrity": "sha512-vPu3NmF1kBZMOkOdysolGfFxEEnwdHNGORoX3eWbMWT2JL/Tag5Q2CAc5jwa2VvZnS1nE/9x+DVlFQSo8LQnIg==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/occt/-/occt-0.21.1.tgz", + "integrity": "sha512-0+yffQRmph9W1qLSyRBUvaQDiZ9OHA2kD2/LsCgxR3NVtKs3GZaAYYhoUfaRqtt2I8Go99e8WBB5daaQceudjA==", "license": "MIT", "dependencies": { - "@bitbybit-dev/base": "0.21.0" + "@bitbybit-dev/base": "0.21.1" } }, "node_modules/@bitbybit-dev/occt-worker": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/occt-worker/-/occt-worker-0.21.0.tgz", - "integrity": "sha512-xG1sgo6q/RdVA8AgG72wPe4qxcQlrO1V7/Ksn6MqIhZVTsJcm5RbVYlK+nziIWhvlMc1sKE0GNQFcPdALISLuQ==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/occt-worker/-/occt-worker-0.21.1.tgz", + "integrity": "sha512-3BW0lTiY8muPSiCWplAT/VQHaHFVUvljMGD1ynQo7cqv/Zna9ACn+SHOMY2HJ7m1MnZq5d2dGjJJXo8k19iV8Q==", "license": "MIT", "dependencies": { - "@bitbybit-dev/occt": "0.21.0", + "@bitbybit-dev/occt": "0.21.1", "rxjs": "7.5.5" } }, "node_modules/@bitbybit-dev/threejs": { - "version": "0.21.0", - "resolved": "https://registry.npmjs.org/@bitbybit-dev/threejs/-/threejs-0.21.0.tgz", - "integrity": "sha512-p0fHuLTjoXs3UIWoC2TFUBAhu0F4sTPU//PCvwwPLmLrbrVmpEFV61tGs0739hbU4eKS5goCTUM99RfjbRxW6A==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/@bitbybit-dev/threejs/-/threejs-0.21.1.tgz", + "integrity": "sha512-BXQXMB0QIpvUNCRuVM6KJKn0Of/XBY0+Mt+GlyBe/s0Npk5XX9D4WYUX4A7byKGfhQxE/+FczLGs4ibcuipfmA==", "license": "MIT", "dependencies": { - "@bitbybit-dev/core": "0.21.0", + "@bitbybit-dev/core": "0.21.1", "three": "0.182.0" } }, @@ -13008,14 +13008,14 @@ } }, "node_modules/jsonpath-plus": { - "version": "10.1.0", - "resolved": "https://registry.npmjs.org/jsonpath-plus/-/jsonpath-plus-10.1.0.tgz", - "integrity": "sha512-gHfV1IYqH8uJHYVTs8BJX1XKy2/rR93+f8QQi0xhx95aCiXn1ettYAd5T+7FU6wfqyDoX/wy0pm/fL3jOKJ9Lg==", + "version": "10.3.0", + "resolved": "https://registry.npmjs.org/jsonpath-plus/-/jsonpath-plus-10.3.0.tgz", + "integrity": "sha512-8TNmfeTCk2Le33A3vRRwtuworG/L5RrgMvdjhKZxvyShO+mBu2fP50OWUjRLNtvw344DdDarFh9buFAZs5ujeA==", "license": "MIT", "dependencies": { - "@jsep-plugin/assignment": "^1.2.1", - "@jsep-plugin/regex": "^1.0.3", - "jsep": "^1.3.9" + "@jsep-plugin/assignment": "^1.3.0", + "@jsep-plugin/regex": "^1.0.4", + "jsep": "^1.4.0" }, "bin": { "jsonpath": "bin/jsonpath-cli.js", @@ -16460,10 +16460,13 @@ } }, "node_modules/sax": { - "version": "1.4.3", - "resolved": "https://registry.npmjs.org/sax/-/sax-1.4.3.tgz", - "integrity": "sha512-yqYn1JhPczigF94DMS+shiDMjDowYO6y9+wB/4WgO0Y19jWYk0lQ4tuG5KI7kj4FTp1wxPj5IFfcrz/s1c3jjQ==", - "license": "BlueOak-1.0.0" + "version": "1.4.4", + "resolved": "https://registry.npmjs.org/sax/-/sax-1.4.4.tgz", + "integrity": "sha512-1n3r/tGXO6b6VXMdFT54SHzT9ytu9yr7TaELowdYpMqY/Ao7EnlQGmAQ1+RatX7Tkkdm6hONI2owqNx2aZj5Sw==", + "license": "BlueOak-1.0.0", + "engines": { + "node": ">=11.0.0" + } }, "node_modules/saxes": { "version": "5.0.1", diff --git a/examples/react/threejs/vase/package.json b/examples/react/threejs/vase/package.json index 0356dbca..8cbc5594 100644 --- a/examples/react/threejs/vase/package.json +++ b/examples/react/threejs/vase/package.json @@ -4,7 +4,7 @@ "private": true, "homepage": "https://app-store.bitbybit.dev/bitbybit-threejs", "dependencies": { - "@bitbybit-dev/threejs": "0.21.0", + "@bitbybit-dev/threejs": "0.21.1", "@testing-library/jest-dom": "5.16.5", "@testing-library/react": "14.0.0", "@testing-library/user-event": "14.4.3", diff --git a/examples/runner/babylon/full/inline-include/index.html b/examples/runner/babylon/full/inline-include/index.html index fd54a69b..b84bd7f5 100644 --- a/examples/runner/babylon/full/inline-include/index.html +++ b/examples/runner/babylon/full/inline-include/index.html @@ -34,7 +34,7 @@ // This function simply outputs the script that was exported from the Rete editor by clicking "Export to Runner" and selecting Minify option. function exportedScript() { - return '{\"type\":\"rete\",\"version\":\"0.21.0\",\"script\":\"!async function(e,t,s,n,r){let a={};a={x:[0],y:[0],z:[1],...a};const o=[{result:e.HS.executeBasedOnType(a,!1,(e=>t.vector.vectorXYZ(e))),transformers:[]}];let i={};i={text:[\\"[true,false]\\"],...i};const c=[{result:e.HS.executeBasedOnType(i,!1,(e=>t.json.parse(e))),transformers:[]}];let p={};p={text:[\\"[false,true]\\"],...p};const u=[{result:e.HS.executeBasedOnType(p,!1,(e=>t.json.parse(e))),transformers:[]}],l=[{result:[5],transformers:[]}];let d={};d={x:[1],y:[0],z:[0],...d};const m=[{result:e.HS.executeBasedOnType(d,!1,(e=>t.vector.vectorXYZ(e))),transformers:[]}],y=[{result:[12],transformers:[]}],S=[{result:[7],transformers:[]}];let H={};H={x:[0],y:[1],z:[0],...H};const f=[{result:e.HS.executeBasedOnType(H,!1,(e=>t.vector.vectorXYZ(e))),transformers:[]}];let h={};h={x:[0],y:[0],z:[1],...h};const x=[{result:e.HS.executeBasedOnType(h,!1,(e=>t.vector.vectorXYZ(e))),transformers:[]}];let v={};v={number:[.4],...v};const O=[{result:e.HS.executeBasedOnType(v,!1,(e=>t.math.number(e))),transformers:[]}];let I={};I={x:[0],y:[0],z:[-1],...I};const L=[{result:e.HS.executeBasedOnType(I,!1,(e=>t.vector.vectorXYZ(e))),transformers:[]}];let B={};B={x:[0],y:[0],z:[-2],...B};const w=[{result:e.HS.executeBasedOnType(B,!1,(e=>t.vector.vectorXYZ(e))),transformers:[]}];let T={};T={x:[0],y:[0],z:[1],...T};const g=[{result:e.HS.executeBasedOnType(T,!1,(e=>t.vector.vectorXYZ(e))),transformers:[]}];let A={};A={x:[0],y:[1.5],z:[0],...A};const E=[{result:e.HS.executeBasedOnType(A,!1,(e=>t.vector.vectorXYZ(e))),transformers:[]}];let b={};b={...{faceOpacity:[.5],edgeOpacity:[.5],edgeColour:[\\"#000000\\"],faceColour:[\\"#212121\\"],vertexColour:[\\"#ff00ff\\"],faceMaterial:[void 0],edgeWidth:[2],vertexSize:[.03],drawEdges:[!0],drawFaces:[!0],drawVertices:[!1],precision:[.02],drawEdgeIndexes:[!1],edgeIndexHeight:[.06],edgeIndexColour:[\\"ff00ff\\"],drawFaceIndexes:[!1],faceIndexHeight:[.06],faceIndexColour:[\\"#0000ff\\"]},...b};const z=[{result:e.HS.executeBasedOnType(b,!1,(e=>t.draw.optionsOcctShape(e))),transformers:[]}];let W={};W={name:[\\"Custom Material\\"],baseColor:[\\"#9c9cba\\"],emissiveColor:[\\"#000000\\"],metallic:[.9],roughness:[.1],alpha:[1],backFaceCulling:[!1],zOffset:[2],...W};const C=[{result:e.HS.executeBasedOnType(W,!1,(e=>t.babylon.material.pbrMetallicRoughness.create(e))),transformers:[]}];let P={};P={x:[0],y:[0],z:[-1],...P};const X=[{result:e.HS.executeBasedOnType(P,!1,(e=>t.vector.vectorXYZ(e))),transformers:[]}];let Y={};Y={x:[0],y:[0],z:[-1.5],...Y};const Z=[{result:e.HS.executeBasedOnType(Y,!1,(e=>t.vector.vectorXYZ(e))),transformers:[]}];let N={};N={x:[0],y:[0],z:[1],...N};const k=[{result:e.HS.executeBasedOnType(N,!1,(e=>t.vector.vectorXYZ(e))),transformers:[]}];let M={};M={skybox:[\\"city\\"],size:[1e3],blur:[.4],environmentIntensity:[.4],...M};e.HS.executeBasedOnType(M,!1,(e=>t.babylon.scene.enableSkybox(e)));let F={number:[{result:[20],transformers:[]}]};e.HS.updateListInputs(F),F={number:[20],...F};const D=[{result:e.HS.executeBasedOnType(F,!1,(e=>t.math.number(e))),transformers:[]}];let R={};R.y=y,e.HS.updateListInputs(R),R={x:[0],y:[0],z:[0],...R};const j=[{result:e.HS.executeBasedOnType(R,!1,(e=>t.vector.vectorXYZ(e))),transformers:[]}];let q={};q.item=y,e.HS.updateListInputs(q),q={...q};const V=[{result:q.item}];let G={};G.first=S,e.HS.updateListInputs(G),G={first:[1],second:[-2],operation:[\\"divide\\"],...G};const J=[{result:e.HS.executeBasedOnType(G,!1,(e=>t.math.twoNrOperation(e))),transformers:[]}];let K={};K.first=S,e.HS.updateListInputs(K),K={first:[1],second:[-4],operation:[\\"divide\\"],...K};const Q=[{result:e.HS.executeBasedOnType(K,!1,(e=>t.math.twoNrOperation(e))),transformers:[]}];let U={};U.first=y,U.second=O,e.HS.updateListInputs(U),U={first:[1],second:[.4],operation:[\\"add\\"],...U};const $=[{result:e.HS.executeBasedOnType(U,!1,(e=>t.math.twoNrOperation(e))),transformers:[]}];let _={};_.item=S,e.HS.updateListInputs(_),_={..._};const ee=[{result:_.item}],te={faceOpacity:[1],edgeOpacity:[1],edgeColour:[\\"#1c1c1c\\"],faceColour:[\\"#bdbdbd\\"],vertexColour:[\\"#ff00ff\\"],faceMaterial:[void 0],edgeWidth:[2],vertexSize:[.03],drawEdges:[!0],drawFaces:[!0],drawVertices:[!1],precision:[.01],drawEdgeIndexes:[!1],edgeIndexHeight:[.06],edgeIndexColour:[\\"ff00ff\\"],drawFaceIndexes:[!1],faceIndexHeight:[.06],faceIndexColour:[\\"#0000ff\\"]};let se={};se.faceMaterial=C,e.HS.updateListInputs(se),se={...te,...se};const ne=[{result:e.HS.executeBasedOnType(se,!1,(e=>t.draw.optionsOcctShape(e))),transformers:[]}];let re={};re.center=Z,re.direction=X,e.HS.updateListInputs(re),re={radius:[3],height:[1.9],center:[[0,0,0]],direction:[[0,1,0]],...re};const ae=[{result:await e.HS.executeBasedOnTypeAsync(re,!1,(e=>t.occt.shapes.solid.createCylinder(e))),transformers:[]}];let oe={};oe.y=$,e.HS.updateListInputs(oe),oe={x:[0],y:[12],z:[0],...oe};const ie=[{result:e.HS.executeBasedOnType(oe,!1,(e=>t.vector.vectorXYZ(e))),transformers:[]}];let ce={};ce.first=D,e.HS.updateListInputs(ce),ce={first:[1],second:[3],operation:[\\"multiply\\"],...ce};const pe=[{result:e.HS.executeBasedOnType(ce,!1,(e=>t.math.twoNrOperation(e))),transformers:[]}];let ue={};ue.first=V,ue.second=O,e.HS.updateListInputs(ue),ue={first:[1],second:[.4],operation:[\\"add\\"],...ue};const le=[{result:e.HS.executeBasedOnType(ue,!1,(e=>t.math.twoNrOperation(e))),transformers:[]}];let de={};de.first=V,de.second=O,e.HS.updateListInputs(de),de={first:[1],second:[.4],operation:[\\"subtract\\"],...de};const me=[{result:e.HS.executeBasedOnType(de,!1,(e=>t.math.twoNrOperation(e))),transformers:[]}];let ye={};ye.first=ee,e.HS.updateListInputs(ye),ye={first:[1],second:[-.2],operation:[\\"multiply\\"],...ye};const Se=[{result:e.HS.executeBasedOnType(ye,!1,(e=>t.math.twoNrOperation(e))),transformers:[]}];let He={};He.second=D,e.HS.updateListInputs(He),He={first:[360],second:[1],operation:[\\"divide\\"],...He};const fe=[{result:e.HS.executeBasedOnType(He,!1,(e=>t.math.twoNrOperation(e))),transformers:[]}],he={shape:[void 0],radius:[.3],radiusList:[void 0],indexes:[void 0]};let xe={};xe.shape=ae,e.HS.updateListInputs(xe),xe={...he,...xe};const ve=[{result:await e.HS.executeBasedOnTypeAsync(xe,!1,(e=>t.occt.fillets.filletEdges(e))),transformers:[]}];let Oe={};Oe.start=L,Oe.end=ie,e.HS.updateListInputs(Oe),Oe={start:[[0,0,0]],end:[[0,1,0]],...Oe};const Ie=[{result:await e.HS.executeBasedOnTypeAsync(Oe,!1,(e=>t.occt.shapes.wire.createLineWire(e))),transformers:[]}];let Le={};Le.second=pe,e.HS.updateListInputs(Le),Le={first:[360],second:[1],operation:[\\"divide\\"],...Le};const Be=[{result:e.HS.executeBasedOnType(Le,!1,(e=>t.math.twoNrOperation(e))),transformers:[]}];let we={};we.start=w,we.end=ie,e.HS.updateListInputs(we),we={start:[[0,0,0]],end:[[0,1,0]],...we};const Te=[{result:await e.HS.executeBasedOnTypeAsync(we,!1,(e=>t.occt.shapes.wire.createLineWire(e))),transformers:[]}];let ge={};ge.y=le,e.HS.updateListInputs(ge),ge={x:[0],y:[0],z:[.05],...ge};const Ae=[{result:e.HS.executeBasedOnType(ge,!1,(e=>t.vector.vectorXYZ(e))),transformers:[]}];let Ee={};Ee.y=me,Ee.z=Q,e.HS.updateListInputs(Ee),Ee={x:[0],y:[0],z:[-1],...Ee};const be=[{result:e.HS.executeBasedOnType(Ee,!1,(e=>t.vector.vectorXYZ(e))),transformers:[]}];let ze={};ze.y=me,ze.z=J,e.HS.updateListInputs(ze),ze={x:[0],y:[0],z:[0],...ze};const We=[{result:e.HS.executeBasedOnType(ze,!1,(e=>t.vector.vectorXYZ(e))),transformers:[]}];let Ce={};Ce.z=Se,e.HS.updateListInputs(Ce),Ce={x:[0],y:[0],z:[0],...Ce};const Pe=[{result:e.HS.executeBasedOnType(Ce,!1,(e=>t.vector.vectorXYZ(e))),transformers:[]}];let Xe={};Xe.step=fe,e.HS.updateListInputs(Xe),Xe={step:[.1],min:[0],max:[360],...Xe};const Ye=e.HS.executeBasedOnType(Xe,!1,(e=>t.vector.span(e))),Ze=[];for(let e=0;e<1;e++)Ze.push({type:\\"flat\\"});const Ne=[{result:Ye,transformers:Ze}];let ke={};ke.first=Se,e.HS.updateListInputs(ke),ke={first:[2],second:[-2],operation:[\\"multiply\\"],...ke};e.HS.executeBasedOnType(ke,!1,(e=>t.math.twoNrOperation(e)));let Me={};Me.listElements=ve,e.HS.updateListInputs(Me),Me={...Me};const Fe=[{result:[Me.listElements?Me.listElements:[]]}],De={shape:[void 0],axis:[[0,0,1]],angle:[0]};let Re={};Re.shape=Ie,Re.axis=o,Re.angle=Be,e.HS.updateListInputs(Re),Re={...De,...Re};const je=[{result:await e.HS.executeBasedOnTypeAsync(Re,!1,(e=>t.occt.transforms.rotate(e))),transformers:[]}];let qe={};qe.first=Be,e.HS.updateListInputs(qe),qe={first:[1],second:[.4],operation:[\\"multiply\\"],...qe};const Ve=[{result:e.HS.executeBasedOnType(qe,!1,(e=>t.math.twoNrOperation(e))),transformers:[]}];let Ge={};Ge.first=Be,e.HS.updateListInputs(Ge),Ge={first:[1],second:[.6],operation:[\\"multiply\\"],...Ge};const Je=[{result:e.HS.executeBasedOnType(Ge,!1,(e=>t.math.twoNrOperation(e))),transformers:[]}];let Ke={};Ke.listElements=[Ae[0],j[0],be[0],We[0]],e.HS.updateListInputs(Ke),Ke={...Ke};const Qe=[{result:[Ke.listElements?Ke.listElements:[]]}];let Ue={};Ue.item=Ne,e.HS.updateListInputs(Ue),Ue={...Ue};const $e=[{result:Ue.item}],_e={shape:[void 0],nrOfDivisions:[11],removeStartPoint:[!1],removeEndPoint:[!1]};let et={};et.shape=je,et.nrOfDivisions=l,e.HS.updateListInputs(et),et={..._e,...et};const tt=[{result:await e.HS.executeBasedOnTypeAsync(et,!1,(e=>t.occt.shapes.wire.divideWireByEqualDistanceToPoints(e))),transformers:[]}],st={shape:[void 0],axis:[[0,0,1]],angle:[0]};let nt={};nt.shape=Te,nt.axis=o,nt.angle=[Ve[0],Je[0]],e.HS.updateListInputs(nt),nt={...st,...nt};const rt=[{result:await e.HS.executeBasedOnTypeAsync(nt,!1,(e=>t.occt.transforms.rotate(e))),transformers:[]}];let at={};at.number=Ve,e.HS.updateListInputs(at),at={number:[1],operation:[\\"negate\\"],...at};const ot=[{result:e.HS.executeBasedOnType(at,!1,(e=>t.math.oneNrOperation(e))),transformers:[]}],it={points:[void 0]};let ct={};ct.points=Qe,e.HS.updateListInputs(ct),ct={...it,...ct};const pt=[{result:await e.HS.executeBasedOnTypeAsync(ct,!1,(e=>t.occt.shapes.wire.createPolylineWire(e))),transformers:[]}];e.HS.drawNodeMeshes(pt,t);const ut={list:[void 0],pattern:[[!0,!0,!1]]};let lt={};lt.list=tt,lt.pattern=u,e.HS.updateListInputs(lt),lt={...ut,...lt};const dt=[{result:e.HS.executeBasedOnType(lt,!0,(e=>t.lists.getByPattern(e))),transformers:[]}];let mt={};mt.listElements=rt,e.HS.updateListInputs(mt),mt={...mt};const yt=[{result:[mt.listElements?mt.listElements:[]]}],St={shape:[void 0],origin:[[0,0,0]],direction:[[0,0,1]]};let Ht={};Ht.shape=pt,Ht.origin=We,Ht.direction=f,e.HS.updateListInputs(Ht),Ht={...St,...Ht};const ft=[{result:await e.HS.executeBasedOnTypeAsync(Ht,!1,(e=>t.occt.transforms.mirror(e))),transformers:[]}],ht={shape:[void 0]};let xt={};xt.shape=pt,e.HS.updateListInputs(xt),xt={...ht,...xt};const vt=await e.HS.executeBasedOnTypeAsync(xt,!1,(e=>t.occt.shapes.edge.getCornerPointsOfEdgesForShape(e))),Ot=[];for(let e=0;e<1;e++)Ot.push({type:\\"flat\\"});const It=[{result:vt,transformers:Ot}],Lt={list:[void 0],index:[0],clone:[!0]};let Bt={};Bt.list=yt,e.HS.updateListInputs(Bt),Bt={...Lt,...Bt};const wt=[{result:e.HS.executeBasedOnType(Bt,!1,(e=>t.lists.getItem(e))),transformers:[]}],Tt={shape:[void 0]};let gt={};gt.shape=ft,e.HS.updateListInputs(gt),gt={...Tt,...gt};const At=[{result:await e.HS.executeBasedOnTypeAsync(gt,!1,(e=>t.occt.shapes.edge.getCornerPointsOfEdgesForShape(e))),transformers:[]}],Et={shape:[void 0],nrOfDivisions:[11],removeStartPoint:[!1],removeEndPoint:[!1]};let bt={};bt.shape=wt,bt.nrOfDivisions=l,e.HS.updateListInputs(bt),bt={...Et,...bt};const zt=[{result:await e.HS.executeBasedOnTypeAsync(bt,!1,(e=>t.occt.shapes.wire.divideWireByEqualDistanceToPoints(e))),transformers:[]}],Wt={list:[void 0],index:[3],clone:[!0]};let Ct={};Ct.list=At,e.HS.updateListInputs(Ct),Ct={...Wt,...Ct};const Pt=[{result:e.HS.executeBasedOnType(Ct,!1,(e=>t.lists.removeItemAtIndex(e))),transformers:[]}],Xt={list:[void 0],pattern:[[!0,!0,!1]]};let Yt={};Yt.list=zt,Yt.pattern=c,e.HS.updateListInputs(Yt),Yt={...Xt,...Yt};const Zt=[{result:e.HS.executeBasedOnType(Yt,!1,(e=>t.lists.getByPattern(e))),transformers:[]}],Nt={list:[void 0],clone:[!0]};let kt={};kt.list=Pt,e.HS.updateListInputs(kt),kt={...Nt,...kt};const Mt=e.HS.executeBasedOnType(kt,!1,(e=>t.lists.reverse(e))),Ft=[];for(let e=0;e<1;e++)Ft.push({type:\\"flat\\"});const Dt=[{result:Mt,transformers:Ft}];let Rt={};Rt.listElements=[Zt[0],dt[0]],e.HS.updateListInputs(Rt),Rt={...Rt};const jt=[{result:[Rt.listElements?Rt.listElements:[]]}];let qt={};qt.listElements=[It[0],Dt[0]],e.HS.updateListInputs(qt),qt={...qt};const Vt=[{result:[qt.listElements?qt.listElements:[]]}],Gt={list:[void 0],clone:[!0]};let Jt={};Jt.list=jt,e.HS.updateListInputs(Jt),Jt={...Gt,...Jt};const Kt=e.HS.executeBasedOnType(Jt,!1,(e=>t.lists.flipLists(e))),Qt=[];for(let e=0;e<2;e++)Qt.push({type:\\"flat\\"});const Ut=[{result:Kt,transformers:Qt}],$t={points:[void 0]};let _t={};_t.points=Vt,e.HS.updateListInputs(_t),_t={...$t,..._t};const es=[{result:await e.HS.executeBasedOnTypeAsync(_t,!1,(e=>t.occt.shapes.wire.createPolylineWire(e))),transformers:[]}];let ts={};ts.listElements=Ut,e.HS.updateListInputs(ts),ts={...ts};const ss=[{result:[ts.listElements?ts.listElements:[]]}],ns={shape:[void 0],radius:[.3],radiusList:[void 0],indexes:[void 0]};let rs={};rs.shape=es,e.HS.updateListInputs(rs),rs={...ns,...rs};const as=[{result:await e.HS.executeBasedOnTypeAsync(rs,!1,(e=>t.occt.fillets.fillet2d(e))),transformers:[]}],os={points:[void 0]};let is={};is.points=ss,e.HS.updateListInputs(is),is={...os,...is};const cs=[{result:await e.HS.executeBasedOnTypeAsync(is,!1,(e=>t.occt.shapes.wire.createPolylineWire(e))),transformers:[]}],ps={shape:[void 0],angle:[360],direction:[[0,1,0]],copy:[!1]};let us={};us.shape=as,us.direction=x,e.HS.updateListInputs(us),us={...ps,...us};const ls=[{result:await e.HS.executeBasedOnTypeAsync(us,!1,(e=>t.occt.operations.revolve(e))),transformers:[]}],ds={shape:[void 0]};let ms={};ms.shape=as,e.HS.updateListInputs(ms),ms={...ds,...ms};const ys=[{result:await e.HS.executeBasedOnTypeAsync(ms,!1,(e=>t.occt.shapes.wire.startPointOnWire(e))),transformers:[]}],Ss={shape:[void 0]};let Hs={};Hs.shape=as,e.HS.updateListInputs(Hs),Hs={...Ss,...Hs};const fs=[{result:await e.HS.executeBasedOnTypeAsync(Hs,!1,(e=>t.occt.shapes.wire.endPointOnWire(e))),transformers:[]}],hs={shape:[void 0]};let xs={};xs.shape=as,e.HS.updateListInputs(xs),xs={...hs,...xs};const vs=[{result:await e.HS.executeBasedOnTypeAsync(xs,!1,(e=>t.occt.shapes.wire.closeOpenWire(e))),transformers:[]}],Os={shape:[void 0],angle:[360],direction:[[0,1,0]],copy:[!1]};let Is={};Is.shape=vs,Is.direction=x,e.HS.updateListInputs(Is),Is={...Os,...Is};const Ls=[{result:await e.HS.executeBasedOnTypeAsync(Is,!1,(e=>t.occt.operations.revolve(e))),transformers:[]}],Bs={shape:[void 0],radius:[1],radiusList:[void 0],indexes:[void 0],direction:[[0,1,0]]};let ws={};ws.shape=cs,ws.direction=g,e.HS.updateListInputs(ws),ws={...Bs,...ws};const Ts=[{result:await e.HS.executeBasedOnTypeAsync(ws,!1,(e=>t.occt.fillets.fillet3DWire(e))),transformers:[]}],gs={shape:[void 0],face:[void 0],distance:[-.2],tolerance:[.1]};let As={};As.shape=ls,e.HS.updateListInputs(As),As={...gs,...As};const Es=[{result:await e.HS.executeBasedOnTypeAsync(As,!1,(e=>t.occt.operations.offset(e))),transformers:[]}],bs={shape:[void 0],index:[0]};let zs={};zs.shape=ls,e.HS.updateListInputs(zs),zs={...bs,...zs};const Ws=[{result:await e.HS.executeBasedOnTypeAsync(zs,!1,(e=>t.occt.shapes.wire.getWire(e))),transformers:[]}];let Cs={};Cs.item=ys,e.HS.updateListInputs(Cs),Cs={...Cs};const Ps=[{result:Cs.item}];let Xs={};Xs.item=fs,e.HS.updateListInputs(Xs),Xs={...Xs};const Ys=[{result:Xs.item}];let Zs={};Zs.start=fs,Zs.end=ys,e.HS.updateListInputs(Zs),Zs={start:[[0,0,0]],end:[[0,1,0]],...Zs};const Ns=[{result:await e.HS.executeBasedOnTypeAsync(Zs,!1,(e=>t.occt.shapes.wire.createLineWire(e))),transformers:[]}];e.HS.drawNodeMeshes(Ns,t);const ks={shape:[void 0],angle:[360],direction:[[0,1,0]],copy:[!1]};let Ms={};Ms.shape=Ts,Ms.angle=ot,Ms.direction=o,e.HS.updateListInputs(Ms),Ms={...ks,...Ms};const Fs=[{result:await e.HS.executeBasedOnTypeAsync(Ms,!1,(e=>t.occt.operations.revolve(e))),transformers:[]}],Ds={shape:[void 0]};let Rs={};Rs.shape=Ls,e.HS.updateListInputs(Rs),Rs={...Ds,...Rs};const js=[{result:await e.HS.executeBasedOnTypeAsync(Rs,!1,(e=>t.occt.shapes.solid.fromClosedShell(e))),transformers:[]}],qs={shape:[void 0],index:[1]};let Vs={};Vs.shape=Ws,e.HS.updateListInputs(Vs),Vs={...qs,...Vs};const Gs=[{result:await e.HS.executeBasedOnTypeAsync(Vs,!1,(e=>t.occt.shapes.edge.getEdge(e))),transformers:[]}],Js={shape:[void 0],index:[0]};let Ks={};Ks.shape=Es,e.HS.updateListInputs(Ks),Ks={...Js,...Ks};const Qs=[{result:await e.HS.executeBasedOnTypeAsync(Ks,!1,(e=>t.occt.shapes.wire.getWire(e))),transformers:[]}],Us={shape:[void 0],translation:[[0,0,0]]};let $s={};$s.shape=Ns,$s.translation=E,e.HS.updateListInputs($s),$s={...Us,...$s};const _s=[{result:await e.HS.executeBasedOnTypeAsync($s,!1,(e=>t.occt.transforms.translate(e))),transformers:[]}],en={shape:[void 0],direction:[[0,1,0]]};let tn={};tn.shape=Fs,tn.direction=Pe,e.HS.updateListInputs(tn),tn={...en,...tn};const sn=[{result:await e.HS.executeBasedOnTypeAsync(tn,!1,(e=>t.occt.operations.extrude(e))),transformers:[]}];let nn={};nn.listElements=js,e.HS.updateListInputs(nn),nn={...nn};const rn=[{result:[nn.listElements?nn.listElements:[]]}],an={shape:[void 0],index:[1]};let on={};on.shape=Qs,e.HS.updateListInputs(on),on={...an,...on};const cn=[{result:await e.HS.executeBasedOnTypeAsync(on,!1,(e=>t.occt.shapes.edge.getEdge(e))),transformers:[]}];let pn={};pn.listElements=Gs,e.HS.updateListInputs(pn),pn={...pn};const un=[{result:[pn.listElements?pn.listElements:[]]}],ln={shape:[void 0]};let dn={};dn.shape=_s,e.HS.updateListInputs(dn),dn={...ln,...dn};const mn=[{result:await e.HS.executeBasedOnTypeAsync(dn,!1,(e=>t.occt.shapes.wire.startPointOnWire(e))),transformers:[]}],yn={shape:[void 0]};let Sn={};Sn.shape=_s,e.HS.updateListInputs(Sn),Sn={...yn,...Sn};const Hn=[{result:await e.HS.executeBasedOnTypeAsync(Sn,!1,(e=>t.occt.shapes.wire.endPointOnWire(e))),transformers:[]}],fn={shapes:[void 0]};let hn={};hn.shapes=un,e.HS.updateListInputs(hn),hn={...fn,...hn};const xn=[{result:await e.HS.executeBasedOnTypeAsync(hn,!1,(e=>t.occt.shapes.wire.combineEdgesAndWiresIntoAWire(e))),transformers:[]}];let vn={};vn.listElements=cn,e.HS.updateListInputs(vn),vn={...vn};const On=[{result:[vn.listElements?vn.listElements:[]]}],In={shape:[void 0],shapes:[void 0],keepEdges:[!1]};let Ln={};Ln.shape=sn,Ln.shapes=Fe,e.HS.updateListInputs(Ln),Ln={...In,...Ln};const Bn=[{result:await e.HS.executeBasedOnTypeAsync(Ln,!1,(e=>t.occt.booleans.difference(e))),transformers:[]}];let wn={};wn.item=Hn,e.HS.updateListInputs(wn),wn={...wn};const Tn=[{result:wn.item}];let gn={};gn.item=mn,e.HS.updateListInputs(gn),gn={...gn};const An=[{result:gn.item}],En={shape:[void 0],shapes:[void 0],keepEdges:[!1]};let bn={};bn.shape=Bn,bn.shapes=rn,e.HS.updateListInputs(bn),bn={...En,...bn};const zn=[{result:await e.HS.executeBasedOnTypeAsync(bn,!1,(e=>t.occt.booleans.difference(e))),transformers:[]}],Wn={shapes:[void 0]};let Cn={};Cn.shapes=On,e.HS.updateListInputs(Cn),Cn={...Wn,...Cn};const Pn=[{result:await e.HS.executeBasedOnTypeAsync(Cn,!1,(e=>t.occt.shapes.wire.combineEdgesAndWiresIntoAWire(e))),transformers:[]}];let Xn={};Xn.listElements=[Ps[0],Tn[0],An[0],Ys[0]],e.HS.updateListInputs(Xn),Xn={...Xn};const Yn=[{result:[Xn.listElements?Xn.listElements:[]]}],Zn={shape:[void 0],origin:[[0,0,0]],normal:[[0,0,1]]};let Nn={};Nn.shape=zn,Nn.normal=m,e.HS.updateListInputs(Nn),Nn={...Zn,...Nn};const kn=[{result:await e.HS.executeBasedOnTypeAsync(Nn,!1,(e=>t.occt.transforms.mirrorAlongNormal(e))),transformers:[]}];let Mn={};Mn.listElements=[xn[0],Pn[0]],e.HS.updateListInputs(Mn),Mn={...Mn};const Fn=[{result:[Mn.listElements?Mn.listElements:[]]}],Dn={points:[void 0]};let Rn={};Rn.points=Yn,e.HS.updateListInputs(Rn),Rn={...Dn,...Rn};const jn=[{result:await e.HS.executeBasedOnTypeAsync(Rn,!1,(e=>t.occt.shapes.wire.createPolylineWire(e))),transformers:[]}];let qn={};qn.listElements=[kn[0],zn[0]],e.HS.updateListInputs(qn),qn={...qn};const Vn=[{result:[qn.listElements?qn.listElements:[]]}],Gn={shapes:[void 0],makeSolid:[!1]};let Jn={};Jn.shapes=Fn,e.HS.updateListInputs(Jn),Jn={...Gn,...Jn};const Kn=[{result:await e.HS.executeBasedOnTypeAsync(Jn,!1,(e=>t.occt.operations.loft(e))),transformers:[]}],Qn={shape:[void 0],radius:[.5],radiusList:[void 0],indexes:[void 0]};let Un={};Un.shape=jn,e.HS.updateListInputs(Un),Un={...Qn,...Un};const $n=[{result:await e.HS.executeBasedOnTypeAsync(Un,!1,(e=>t.occt.fillets.fillet2d(e))),transformers:[]}],_n={shapes:[void 0]};let er={};er.shapes=Vn,e.HS.updateListInputs(er),er={..._n,...er};const tr=[{result:await e.HS.executeBasedOnTypeAsync(er,!1,(e=>t.occt.shapes.compound.makeCompound(e))),transformers:[]}],sr={shape:[void 0],origin:[[0,0,0]],direction:[[0,0,1]]};let nr={};nr.shape=Kn,nr.origin=We,nr.direction=f,e.HS.updateListInputs(nr),nr={...sr,...nr};const rr=[{result:await e.HS.executeBasedOnTypeAsync(nr,!1,(e=>t.occt.transforms.mirror(e))),transformers:[]}],ar={shape:[void 0],angle:[360],direction:[[0,1,0]],copy:[!1]};let or={};or.shape=$n,or.direction=x,e.HS.updateListInputs(or),or={...ar,...or};const ir=[{result:await e.HS.executeBasedOnTypeAsync(or,!1,(e=>t.occt.operations.revolve(e))),transformers:[]}];let cr={};cr.listElements=[ls[0],Es[0],Kn[0],rr[0]],e.HS.updateListInputs(cr),cr={...cr};const pr=[{result:[cr.listElements?cr.listElements:[]]}],ur={shape:[void 0],offset:[-.1]};let lr={};lr.shape=ir,e.HS.updateListInputs(lr),lr={...ur,...lr};const dr=[{result:await e.HS.executeBasedOnTypeAsync(lr,!1,(e=>t.occt.operations.makeThickSolidSimple(e))),transformers:[]}],mr={shape:[void 0],angle:[0],center:[[0,0,0]],axis:[[0,0,1]]};let yr={};yr.shape=tr,yr.angle=$e,yr.axis=k,e.HS.updateListInputs(yr),yr={...mr,...yr};const Sr=[{result:await e.HS.executeBasedOnTypeAsync(yr,!1,(e=>t.occt.transforms.rotateAroundCenter(e))),transformers:[]}],Hr={shapes:[void 0],tolerance:[1e-7]};let fr={};fr.shapes=pr,e.HS.updateListInputs(fr),fr={...Hr,...fr};const hr=[{result:await e.HS.executeBasedOnTypeAsync(fr,!1,(e=>t.occt.shapes.shell.sewFaces(e))),transformers:[]}],xr={entity:[void 0],options:[void 0],babylonMesh:[void 0]};let vr={};vr.entity=dr,vr.options=z,e.HS.updateListInputs(vr),vr={...xr,...vr};await e.HS.executeBasedOnTypeAsync(vr,!1,(e=>t.draw.drawAnyAsync(e)));let Or={};Or.listElements=Sr,e.HS.updateListInputs(Or),Or={...Or};const Ir=[{result:[Or.listElements?Or.listElements:[]]}],Lr={shapes:[void 0]};let Br={};Br.shapes=Ir,e.HS.updateListInputs(Br),Br={...Lr,...Br};const wr=[{result:await e.HS.executeBasedOnTypeAsync(Br,!1,(e=>t.occt.shapes.compound.makeCompound(e))),transformers:[]}];let Tr={};Tr.listElements=[hr[0],ve[0],wr[0]],e.HS.updateListInputs(Tr),Tr={...Tr};const gr=[{result:[Tr.listElements?Tr.listElements:[]]}],Ar={shapes:[void 0]};let Er={};Er.shapes=gr,e.HS.updateListInputs(Er),Er={...Ar,...Er};const br=[{result:await e.HS.executeBasedOnTypeAsync(Er,!1,(e=>t.occt.shapes.compound.makeCompound(e))),transformers:[]}],zr={entity:[void 0],options:[void 0],babylonMesh:[void 0]};let Wr={};Wr.entity=br,Wr.options=ne,e.HS.updateListInputs(Wr),Wr={...zr,...Wr};await e.HS.executeBasedOnTypeAsync(Wr,!1,(e=>t.draw.drawAnyAsync(e)))}(BitByBit,bitbybit,bitbybitRunnerResult,bitbybitRunnerInputs,Bit);\"}' + return '{\"type\":\"rete\",\"version\":\"0.21.1\",\"script\":\"!async function(e,t,s,n,r){let a={};a={x:[0],y:[0],z:[1],...a};const o=[{result:e.HS.executeBasedOnType(a,!1,(e=>t.vector.vectorXYZ(e))),transformers:[]}];let i={};i={text:[\\"[true,false]\\"],...i};const c=[{result:e.HS.executeBasedOnType(i,!1,(e=>t.json.parse(e))),transformers:[]}];let p={};p={text:[\\"[false,true]\\"],...p};const u=[{result:e.HS.executeBasedOnType(p,!1,(e=>t.json.parse(e))),transformers:[]}],l=[{result:[5],transformers:[]}];let d={};d={x:[1],y:[0],z:[0],...d};const m=[{result:e.HS.executeBasedOnType(d,!1,(e=>t.vector.vectorXYZ(e))),transformers:[]}],y=[{result:[12],transformers:[]}],S=[{result:[7],transformers:[]}];let H={};H={x:[0],y:[1],z:[0],...H};const f=[{result:e.HS.executeBasedOnType(H,!1,(e=>t.vector.vectorXYZ(e))),transformers:[]}];let h={};h={x:[0],y:[0],z:[1],...h};const x=[{result:e.HS.executeBasedOnType(h,!1,(e=>t.vector.vectorXYZ(e))),transformers:[]}];let v={};v={number:[.4],...v};const O=[{result:e.HS.executeBasedOnType(v,!1,(e=>t.math.number(e))),transformers:[]}];let I={};I={x:[0],y:[0],z:[-1],...I};const L=[{result:e.HS.executeBasedOnType(I,!1,(e=>t.vector.vectorXYZ(e))),transformers:[]}];let B={};B={x:[0],y:[0],z:[-2],...B};const w=[{result:e.HS.executeBasedOnType(B,!1,(e=>t.vector.vectorXYZ(e))),transformers:[]}];let T={};T={x:[0],y:[0],z:[1],...T};const g=[{result:e.HS.executeBasedOnType(T,!1,(e=>t.vector.vectorXYZ(e))),transformers:[]}];let A={};A={x:[0],y:[1.5],z:[0],...A};const E=[{result:e.HS.executeBasedOnType(A,!1,(e=>t.vector.vectorXYZ(e))),transformers:[]}];let b={};b={...{faceOpacity:[.5],edgeOpacity:[.5],edgeColour:[\\"#000000\\"],faceColour:[\\"#212121\\"],vertexColour:[\\"#ff00ff\\"],faceMaterial:[void 0],edgeWidth:[2],vertexSize:[.03],drawEdges:[!0],drawFaces:[!0],drawVertices:[!1],precision:[.02],drawEdgeIndexes:[!1],edgeIndexHeight:[.06],edgeIndexColour:[\\"ff00ff\\"],drawFaceIndexes:[!1],faceIndexHeight:[.06],faceIndexColour:[\\"#0000ff\\"]},...b};const z=[{result:e.HS.executeBasedOnType(b,!1,(e=>t.draw.optionsOcctShape(e))),transformers:[]}];let W={};W={name:[\\"Custom Material\\"],baseColor:[\\"#9c9cba\\"],emissiveColor:[\\"#000000\\"],metallic:[.9],roughness:[.1],alpha:[1],backFaceCulling:[!1],zOffset:[2],...W};const C=[{result:e.HS.executeBasedOnType(W,!1,(e=>t.babylon.material.pbrMetallicRoughness.create(e))),transformers:[]}];let P={};P={x:[0],y:[0],z:[-1],...P};const X=[{result:e.HS.executeBasedOnType(P,!1,(e=>t.vector.vectorXYZ(e))),transformers:[]}];let Y={};Y={x:[0],y:[0],z:[-1.5],...Y};const Z=[{result:e.HS.executeBasedOnType(Y,!1,(e=>t.vector.vectorXYZ(e))),transformers:[]}];let N={};N={x:[0],y:[0],z:[1],...N};const k=[{result:e.HS.executeBasedOnType(N,!1,(e=>t.vector.vectorXYZ(e))),transformers:[]}];let M={};M={skybox:[\\"city\\"],size:[1e3],blur:[.4],environmentIntensity:[.4],...M};e.HS.executeBasedOnType(M,!1,(e=>t.babylon.scene.enableSkybox(e)));let F={number:[{result:[20],transformers:[]}]};e.HS.updateListInputs(F),F={number:[20],...F};const D=[{result:e.HS.executeBasedOnType(F,!1,(e=>t.math.number(e))),transformers:[]}];let R={};R.y=y,e.HS.updateListInputs(R),R={x:[0],y:[0],z:[0],...R};const j=[{result:e.HS.executeBasedOnType(R,!1,(e=>t.vector.vectorXYZ(e))),transformers:[]}];let q={};q.item=y,e.HS.updateListInputs(q),q={...q};const V=[{result:q.item}];let G={};G.first=S,e.HS.updateListInputs(G),G={first:[1],second:[-2],operation:[\\"divide\\"],...G};const J=[{result:e.HS.executeBasedOnType(G,!1,(e=>t.math.twoNrOperation(e))),transformers:[]}];let K={};K.first=S,e.HS.updateListInputs(K),K={first:[1],second:[-4],operation:[\\"divide\\"],...K};const Q=[{result:e.HS.executeBasedOnType(K,!1,(e=>t.math.twoNrOperation(e))),transformers:[]}];let U={};U.first=y,U.second=O,e.HS.updateListInputs(U),U={first:[1],second:[.4],operation:[\\"add\\"],...U};const $=[{result:e.HS.executeBasedOnType(U,!1,(e=>t.math.twoNrOperation(e))),transformers:[]}];let _={};_.item=S,e.HS.updateListInputs(_),_={..._};const ee=[{result:_.item}],te={faceOpacity:[1],edgeOpacity:[1],edgeColour:[\\"#1c1c1c\\"],faceColour:[\\"#bdbdbd\\"],vertexColour:[\\"#ff00ff\\"],faceMaterial:[void 0],edgeWidth:[2],vertexSize:[.03],drawEdges:[!0],drawFaces:[!0],drawVertices:[!1],precision:[.01],drawEdgeIndexes:[!1],edgeIndexHeight:[.06],edgeIndexColour:[\\"ff00ff\\"],drawFaceIndexes:[!1],faceIndexHeight:[.06],faceIndexColour:[\\"#0000ff\\"]};let se={};se.faceMaterial=C,e.HS.updateListInputs(se),se={...te,...se};const ne=[{result:e.HS.executeBasedOnType(se,!1,(e=>t.draw.optionsOcctShape(e))),transformers:[]}];let re={};re.center=Z,re.direction=X,e.HS.updateListInputs(re),re={radius:[3],height:[1.9],center:[[0,0,0]],direction:[[0,1,0]],...re};const ae=[{result:await e.HS.executeBasedOnTypeAsync(re,!1,(e=>t.occt.shapes.solid.createCylinder(e))),transformers:[]}];let oe={};oe.y=$,e.HS.updateListInputs(oe),oe={x:[0],y:[12],z:[0],...oe};const ie=[{result:e.HS.executeBasedOnType(oe,!1,(e=>t.vector.vectorXYZ(e))),transformers:[]}];let ce={};ce.first=D,e.HS.updateListInputs(ce),ce={first:[1],second:[3],operation:[\\"multiply\\"],...ce};const pe=[{result:e.HS.executeBasedOnType(ce,!1,(e=>t.math.twoNrOperation(e))),transformers:[]}];let ue={};ue.first=V,ue.second=O,e.HS.updateListInputs(ue),ue={first:[1],second:[.4],operation:[\\"add\\"],...ue};const le=[{result:e.HS.executeBasedOnType(ue,!1,(e=>t.math.twoNrOperation(e))),transformers:[]}];let de={};de.first=V,de.second=O,e.HS.updateListInputs(de),de={first:[1],second:[.4],operation:[\\"subtract\\"],...de};const me=[{result:e.HS.executeBasedOnType(de,!1,(e=>t.math.twoNrOperation(e))),transformers:[]}];let ye={};ye.first=ee,e.HS.updateListInputs(ye),ye={first:[1],second:[-.2],operation:[\\"multiply\\"],...ye};const Se=[{result:e.HS.executeBasedOnType(ye,!1,(e=>t.math.twoNrOperation(e))),transformers:[]}];let He={};He.second=D,e.HS.updateListInputs(He),He={first:[360],second:[1],operation:[\\"divide\\"],...He};const fe=[{result:e.HS.executeBasedOnType(He,!1,(e=>t.math.twoNrOperation(e))),transformers:[]}],he={shape:[void 0],radius:[.3],radiusList:[void 0],indexes:[void 0]};let xe={};xe.shape=ae,e.HS.updateListInputs(xe),xe={...he,...xe};const ve=[{result:await e.HS.executeBasedOnTypeAsync(xe,!1,(e=>t.occt.fillets.filletEdges(e))),transformers:[]}];let Oe={};Oe.start=L,Oe.end=ie,e.HS.updateListInputs(Oe),Oe={start:[[0,0,0]],end:[[0,1,0]],...Oe};const Ie=[{result:await e.HS.executeBasedOnTypeAsync(Oe,!1,(e=>t.occt.shapes.wire.createLineWire(e))),transformers:[]}];let Le={};Le.second=pe,e.HS.updateListInputs(Le),Le={first:[360],second:[1],operation:[\\"divide\\"],...Le};const Be=[{result:e.HS.executeBasedOnType(Le,!1,(e=>t.math.twoNrOperation(e))),transformers:[]}];let we={};we.start=w,we.end=ie,e.HS.updateListInputs(we),we={start:[[0,0,0]],end:[[0,1,0]],...we};const Te=[{result:await e.HS.executeBasedOnTypeAsync(we,!1,(e=>t.occt.shapes.wire.createLineWire(e))),transformers:[]}];let ge={};ge.y=le,e.HS.updateListInputs(ge),ge={x:[0],y:[0],z:[.05],...ge};const Ae=[{result:e.HS.executeBasedOnType(ge,!1,(e=>t.vector.vectorXYZ(e))),transformers:[]}];let Ee={};Ee.y=me,Ee.z=Q,e.HS.updateListInputs(Ee),Ee={x:[0],y:[0],z:[-1],...Ee};const be=[{result:e.HS.executeBasedOnType(Ee,!1,(e=>t.vector.vectorXYZ(e))),transformers:[]}];let ze={};ze.y=me,ze.z=J,e.HS.updateListInputs(ze),ze={x:[0],y:[0],z:[0],...ze};const We=[{result:e.HS.executeBasedOnType(ze,!1,(e=>t.vector.vectorXYZ(e))),transformers:[]}];let Ce={};Ce.z=Se,e.HS.updateListInputs(Ce),Ce={x:[0],y:[0],z:[0],...Ce};const Pe=[{result:e.HS.executeBasedOnType(Ce,!1,(e=>t.vector.vectorXYZ(e))),transformers:[]}];let Xe={};Xe.step=fe,e.HS.updateListInputs(Xe),Xe={step:[.1],min:[0],max:[360],...Xe};const Ye=e.HS.executeBasedOnType(Xe,!1,(e=>t.vector.span(e))),Ze=[];for(let e=0;e<1;e++)Ze.push({type:\\"flat\\"});const Ne=[{result:Ye,transformers:Ze}];let ke={};ke.first=Se,e.HS.updateListInputs(ke),ke={first:[2],second:[-2],operation:[\\"multiply\\"],...ke};e.HS.executeBasedOnType(ke,!1,(e=>t.math.twoNrOperation(e)));let Me={};Me.listElements=ve,e.HS.updateListInputs(Me),Me={...Me};const Fe=[{result:[Me.listElements?Me.listElements:[]]}],De={shape:[void 0],axis:[[0,0,1]],angle:[0]};let Re={};Re.shape=Ie,Re.axis=o,Re.angle=Be,e.HS.updateListInputs(Re),Re={...De,...Re};const je=[{result:await e.HS.executeBasedOnTypeAsync(Re,!1,(e=>t.occt.transforms.rotate(e))),transformers:[]}];let qe={};qe.first=Be,e.HS.updateListInputs(qe),qe={first:[1],second:[.4],operation:[\\"multiply\\"],...qe};const Ve=[{result:e.HS.executeBasedOnType(qe,!1,(e=>t.math.twoNrOperation(e))),transformers:[]}];let Ge={};Ge.first=Be,e.HS.updateListInputs(Ge),Ge={first:[1],second:[.6],operation:[\\"multiply\\"],...Ge};const Je=[{result:e.HS.executeBasedOnType(Ge,!1,(e=>t.math.twoNrOperation(e))),transformers:[]}];let Ke={};Ke.listElements=[Ae[0],j[0],be[0],We[0]],e.HS.updateListInputs(Ke),Ke={...Ke};const Qe=[{result:[Ke.listElements?Ke.listElements:[]]}];let Ue={};Ue.item=Ne,e.HS.updateListInputs(Ue),Ue={...Ue};const $e=[{result:Ue.item}],_e={shape:[void 0],nrOfDivisions:[11],removeStartPoint:[!1],removeEndPoint:[!1]};let et={};et.shape=je,et.nrOfDivisions=l,e.HS.updateListInputs(et),et={..._e,...et};const tt=[{result:await e.HS.executeBasedOnTypeAsync(et,!1,(e=>t.occt.shapes.wire.divideWireByEqualDistanceToPoints(e))),transformers:[]}],st={shape:[void 0],axis:[[0,0,1]],angle:[0]};let nt={};nt.shape=Te,nt.axis=o,nt.angle=[Ve[0],Je[0]],e.HS.updateListInputs(nt),nt={...st,...nt};const rt=[{result:await e.HS.executeBasedOnTypeAsync(nt,!1,(e=>t.occt.transforms.rotate(e))),transformers:[]}];let at={};at.number=Ve,e.HS.updateListInputs(at),at={number:[1],operation:[\\"negate\\"],...at};const ot=[{result:e.HS.executeBasedOnType(at,!1,(e=>t.math.oneNrOperation(e))),transformers:[]}],it={points:[void 0]};let ct={};ct.points=Qe,e.HS.updateListInputs(ct),ct={...it,...ct};const pt=[{result:await e.HS.executeBasedOnTypeAsync(ct,!1,(e=>t.occt.shapes.wire.createPolylineWire(e))),transformers:[]}];e.HS.drawNodeMeshes(pt,t);const ut={list:[void 0],pattern:[[!0,!0,!1]]};let lt={};lt.list=tt,lt.pattern=u,e.HS.updateListInputs(lt),lt={...ut,...lt};const dt=[{result:e.HS.executeBasedOnType(lt,!0,(e=>t.lists.getByPattern(e))),transformers:[]}];let mt={};mt.listElements=rt,e.HS.updateListInputs(mt),mt={...mt};const yt=[{result:[mt.listElements?mt.listElements:[]]}],St={shape:[void 0],origin:[[0,0,0]],direction:[[0,0,1]]};let Ht={};Ht.shape=pt,Ht.origin=We,Ht.direction=f,e.HS.updateListInputs(Ht),Ht={...St,...Ht};const ft=[{result:await e.HS.executeBasedOnTypeAsync(Ht,!1,(e=>t.occt.transforms.mirror(e))),transformers:[]}],ht={shape:[void 0]};let xt={};xt.shape=pt,e.HS.updateListInputs(xt),xt={...ht,...xt};const vt=await e.HS.executeBasedOnTypeAsync(xt,!1,(e=>t.occt.shapes.edge.getCornerPointsOfEdgesForShape(e))),Ot=[];for(let e=0;e<1;e++)Ot.push({type:\\"flat\\"});const It=[{result:vt,transformers:Ot}],Lt={list:[void 0],index:[0],clone:[!0]};let Bt={};Bt.list=yt,e.HS.updateListInputs(Bt),Bt={...Lt,...Bt};const wt=[{result:e.HS.executeBasedOnType(Bt,!1,(e=>t.lists.getItem(e))),transformers:[]}],Tt={shape:[void 0]};let gt={};gt.shape=ft,e.HS.updateListInputs(gt),gt={...Tt,...gt};const At=[{result:await e.HS.executeBasedOnTypeAsync(gt,!1,(e=>t.occt.shapes.edge.getCornerPointsOfEdgesForShape(e))),transformers:[]}],Et={shape:[void 0],nrOfDivisions:[11],removeStartPoint:[!1],removeEndPoint:[!1]};let bt={};bt.shape=wt,bt.nrOfDivisions=l,e.HS.updateListInputs(bt),bt={...Et,...bt};const zt=[{result:await e.HS.executeBasedOnTypeAsync(bt,!1,(e=>t.occt.shapes.wire.divideWireByEqualDistanceToPoints(e))),transformers:[]}],Wt={list:[void 0],index:[3],clone:[!0]};let Ct={};Ct.list=At,e.HS.updateListInputs(Ct),Ct={...Wt,...Ct};const Pt=[{result:e.HS.executeBasedOnType(Ct,!1,(e=>t.lists.removeItemAtIndex(e))),transformers:[]}],Xt={list:[void 0],pattern:[[!0,!0,!1]]};let Yt={};Yt.list=zt,Yt.pattern=c,e.HS.updateListInputs(Yt),Yt={...Xt,...Yt};const Zt=[{result:e.HS.executeBasedOnType(Yt,!1,(e=>t.lists.getByPattern(e))),transformers:[]}],Nt={list:[void 0],clone:[!0]};let kt={};kt.list=Pt,e.HS.updateListInputs(kt),kt={...Nt,...kt};const Mt=e.HS.executeBasedOnType(kt,!1,(e=>t.lists.reverse(e))),Ft=[];for(let e=0;e<1;e++)Ft.push({type:\\"flat\\"});const Dt=[{result:Mt,transformers:Ft}];let Rt={};Rt.listElements=[Zt[0],dt[0]],e.HS.updateListInputs(Rt),Rt={...Rt};const jt=[{result:[Rt.listElements?Rt.listElements:[]]}];let qt={};qt.listElements=[It[0],Dt[0]],e.HS.updateListInputs(qt),qt={...qt};const Vt=[{result:[qt.listElements?qt.listElements:[]]}],Gt={list:[void 0],clone:[!0]};let Jt={};Jt.list=jt,e.HS.updateListInputs(Jt),Jt={...Gt,...Jt};const Kt=e.HS.executeBasedOnType(Jt,!1,(e=>t.lists.flipLists(e))),Qt=[];for(let e=0;e<2;e++)Qt.push({type:\\"flat\\"});const Ut=[{result:Kt,transformers:Qt}],$t={points:[void 0]};let _t={};_t.points=Vt,e.HS.updateListInputs(_t),_t={...$t,..._t};const es=[{result:await e.HS.executeBasedOnTypeAsync(_t,!1,(e=>t.occt.shapes.wire.createPolylineWire(e))),transformers:[]}];let ts={};ts.listElements=Ut,e.HS.updateListInputs(ts),ts={...ts};const ss=[{result:[ts.listElements?ts.listElements:[]]}],ns={shape:[void 0],radius:[.3],radiusList:[void 0],indexes:[void 0]};let rs={};rs.shape=es,e.HS.updateListInputs(rs),rs={...ns,...rs};const as=[{result:await e.HS.executeBasedOnTypeAsync(rs,!1,(e=>t.occt.fillets.fillet2d(e))),transformers:[]}],os={points:[void 0]};let is={};is.points=ss,e.HS.updateListInputs(is),is={...os,...is};const cs=[{result:await e.HS.executeBasedOnTypeAsync(is,!1,(e=>t.occt.shapes.wire.createPolylineWire(e))),transformers:[]}],ps={shape:[void 0],angle:[360],direction:[[0,1,0]],copy:[!1]};let us={};us.shape=as,us.direction=x,e.HS.updateListInputs(us),us={...ps,...us};const ls=[{result:await e.HS.executeBasedOnTypeAsync(us,!1,(e=>t.occt.operations.revolve(e))),transformers:[]}],ds={shape:[void 0]};let ms={};ms.shape=as,e.HS.updateListInputs(ms),ms={...ds,...ms};const ys=[{result:await e.HS.executeBasedOnTypeAsync(ms,!1,(e=>t.occt.shapes.wire.startPointOnWire(e))),transformers:[]}],Ss={shape:[void 0]};let Hs={};Hs.shape=as,e.HS.updateListInputs(Hs),Hs={...Ss,...Hs};const fs=[{result:await e.HS.executeBasedOnTypeAsync(Hs,!1,(e=>t.occt.shapes.wire.endPointOnWire(e))),transformers:[]}],hs={shape:[void 0]};let xs={};xs.shape=as,e.HS.updateListInputs(xs),xs={...hs,...xs};const vs=[{result:await e.HS.executeBasedOnTypeAsync(xs,!1,(e=>t.occt.shapes.wire.closeOpenWire(e))),transformers:[]}],Os={shape:[void 0],angle:[360],direction:[[0,1,0]],copy:[!1]};let Is={};Is.shape=vs,Is.direction=x,e.HS.updateListInputs(Is),Is={...Os,...Is};const Ls=[{result:await e.HS.executeBasedOnTypeAsync(Is,!1,(e=>t.occt.operations.revolve(e))),transformers:[]}],Bs={shape:[void 0],radius:[1],radiusList:[void 0],indexes:[void 0],direction:[[0,1,0]]};let ws={};ws.shape=cs,ws.direction=g,e.HS.updateListInputs(ws),ws={...Bs,...ws};const Ts=[{result:await e.HS.executeBasedOnTypeAsync(ws,!1,(e=>t.occt.fillets.fillet3DWire(e))),transformers:[]}],gs={shape:[void 0],face:[void 0],distance:[-.2],tolerance:[.1]};let As={};As.shape=ls,e.HS.updateListInputs(As),As={...gs,...As};const Es=[{result:await e.HS.executeBasedOnTypeAsync(As,!1,(e=>t.occt.operations.offset(e))),transformers:[]}],bs={shape:[void 0],index:[0]};let zs={};zs.shape=ls,e.HS.updateListInputs(zs),zs={...bs,...zs};const Ws=[{result:await e.HS.executeBasedOnTypeAsync(zs,!1,(e=>t.occt.shapes.wire.getWire(e))),transformers:[]}];let Cs={};Cs.item=ys,e.HS.updateListInputs(Cs),Cs={...Cs};const Ps=[{result:Cs.item}];let Xs={};Xs.item=fs,e.HS.updateListInputs(Xs),Xs={...Xs};const Ys=[{result:Xs.item}];let Zs={};Zs.start=fs,Zs.end=ys,e.HS.updateListInputs(Zs),Zs={start:[[0,0,0]],end:[[0,1,0]],...Zs};const Ns=[{result:await e.HS.executeBasedOnTypeAsync(Zs,!1,(e=>t.occt.shapes.wire.createLineWire(e))),transformers:[]}];e.HS.drawNodeMeshes(Ns,t);const ks={shape:[void 0],angle:[360],direction:[[0,1,0]],copy:[!1]};let Ms={};Ms.shape=Ts,Ms.angle=ot,Ms.direction=o,e.HS.updateListInputs(Ms),Ms={...ks,...Ms};const Fs=[{result:await e.HS.executeBasedOnTypeAsync(Ms,!1,(e=>t.occt.operations.revolve(e))),transformers:[]}],Ds={shape:[void 0]};let Rs={};Rs.shape=Ls,e.HS.updateListInputs(Rs),Rs={...Ds,...Rs};const js=[{result:await e.HS.executeBasedOnTypeAsync(Rs,!1,(e=>t.occt.shapes.solid.fromClosedShell(e))),transformers:[]}],qs={shape:[void 0],index:[1]};let Vs={};Vs.shape=Ws,e.HS.updateListInputs(Vs),Vs={...qs,...Vs};const Gs=[{result:await e.HS.executeBasedOnTypeAsync(Vs,!1,(e=>t.occt.shapes.edge.getEdge(e))),transformers:[]}],Js={shape:[void 0],index:[0]};let Ks={};Ks.shape=Es,e.HS.updateListInputs(Ks),Ks={...Js,...Ks};const Qs=[{result:await e.HS.executeBasedOnTypeAsync(Ks,!1,(e=>t.occt.shapes.wire.getWire(e))),transformers:[]}],Us={shape:[void 0],translation:[[0,0,0]]};let $s={};$s.shape=Ns,$s.translation=E,e.HS.updateListInputs($s),$s={...Us,...$s};const _s=[{result:await e.HS.executeBasedOnTypeAsync($s,!1,(e=>t.occt.transforms.translate(e))),transformers:[]}],en={shape:[void 0],direction:[[0,1,0]]};let tn={};tn.shape=Fs,tn.direction=Pe,e.HS.updateListInputs(tn),tn={...en,...tn};const sn=[{result:await e.HS.executeBasedOnTypeAsync(tn,!1,(e=>t.occt.operations.extrude(e))),transformers:[]}];let nn={};nn.listElements=js,e.HS.updateListInputs(nn),nn={...nn};const rn=[{result:[nn.listElements?nn.listElements:[]]}],an={shape:[void 0],index:[1]};let on={};on.shape=Qs,e.HS.updateListInputs(on),on={...an,...on};const cn=[{result:await e.HS.executeBasedOnTypeAsync(on,!1,(e=>t.occt.shapes.edge.getEdge(e))),transformers:[]}];let pn={};pn.listElements=Gs,e.HS.updateListInputs(pn),pn={...pn};const un=[{result:[pn.listElements?pn.listElements:[]]}],ln={shape:[void 0]};let dn={};dn.shape=_s,e.HS.updateListInputs(dn),dn={...ln,...dn};const mn=[{result:await e.HS.executeBasedOnTypeAsync(dn,!1,(e=>t.occt.shapes.wire.startPointOnWire(e))),transformers:[]}],yn={shape:[void 0]};let Sn={};Sn.shape=_s,e.HS.updateListInputs(Sn),Sn={...yn,...Sn};const Hn=[{result:await e.HS.executeBasedOnTypeAsync(Sn,!1,(e=>t.occt.shapes.wire.endPointOnWire(e))),transformers:[]}],fn={shapes:[void 0]};let hn={};hn.shapes=un,e.HS.updateListInputs(hn),hn={...fn,...hn};const xn=[{result:await e.HS.executeBasedOnTypeAsync(hn,!1,(e=>t.occt.shapes.wire.combineEdgesAndWiresIntoAWire(e))),transformers:[]}];let vn={};vn.listElements=cn,e.HS.updateListInputs(vn),vn={...vn};const On=[{result:[vn.listElements?vn.listElements:[]]}],In={shape:[void 0],shapes:[void 0],keepEdges:[!1]};let Ln={};Ln.shape=sn,Ln.shapes=Fe,e.HS.updateListInputs(Ln),Ln={...In,...Ln};const Bn=[{result:await e.HS.executeBasedOnTypeAsync(Ln,!1,(e=>t.occt.booleans.difference(e))),transformers:[]}];let wn={};wn.item=Hn,e.HS.updateListInputs(wn),wn={...wn};const Tn=[{result:wn.item}];let gn={};gn.item=mn,e.HS.updateListInputs(gn),gn={...gn};const An=[{result:gn.item}],En={shape:[void 0],shapes:[void 0],keepEdges:[!1]};let bn={};bn.shape=Bn,bn.shapes=rn,e.HS.updateListInputs(bn),bn={...En,...bn};const zn=[{result:await e.HS.executeBasedOnTypeAsync(bn,!1,(e=>t.occt.booleans.difference(e))),transformers:[]}],Wn={shapes:[void 0]};let Cn={};Cn.shapes=On,e.HS.updateListInputs(Cn),Cn={...Wn,...Cn};const Pn=[{result:await e.HS.executeBasedOnTypeAsync(Cn,!1,(e=>t.occt.shapes.wire.combineEdgesAndWiresIntoAWire(e))),transformers:[]}];let Xn={};Xn.listElements=[Ps[0],Tn[0],An[0],Ys[0]],e.HS.updateListInputs(Xn),Xn={...Xn};const Yn=[{result:[Xn.listElements?Xn.listElements:[]]}],Zn={shape:[void 0],origin:[[0,0,0]],normal:[[0,0,1]]};let Nn={};Nn.shape=zn,Nn.normal=m,e.HS.updateListInputs(Nn),Nn={...Zn,...Nn};const kn=[{result:await e.HS.executeBasedOnTypeAsync(Nn,!1,(e=>t.occt.transforms.mirrorAlongNormal(e))),transformers:[]}];let Mn={};Mn.listElements=[xn[0],Pn[0]],e.HS.updateListInputs(Mn),Mn={...Mn};const Fn=[{result:[Mn.listElements?Mn.listElements:[]]}],Dn={points:[void 0]};let Rn={};Rn.points=Yn,e.HS.updateListInputs(Rn),Rn={...Dn,...Rn};const jn=[{result:await e.HS.executeBasedOnTypeAsync(Rn,!1,(e=>t.occt.shapes.wire.createPolylineWire(e))),transformers:[]}];let qn={};qn.listElements=[kn[0],zn[0]],e.HS.updateListInputs(qn),qn={...qn};const Vn=[{result:[qn.listElements?qn.listElements:[]]}],Gn={shapes:[void 0],makeSolid:[!1]};let Jn={};Jn.shapes=Fn,e.HS.updateListInputs(Jn),Jn={...Gn,...Jn};const Kn=[{result:await e.HS.executeBasedOnTypeAsync(Jn,!1,(e=>t.occt.operations.loft(e))),transformers:[]}],Qn={shape:[void 0],radius:[.5],radiusList:[void 0],indexes:[void 0]};let Un={};Un.shape=jn,e.HS.updateListInputs(Un),Un={...Qn,...Un};const $n=[{result:await e.HS.executeBasedOnTypeAsync(Un,!1,(e=>t.occt.fillets.fillet2d(e))),transformers:[]}],_n={shapes:[void 0]};let er={};er.shapes=Vn,e.HS.updateListInputs(er),er={..._n,...er};const tr=[{result:await e.HS.executeBasedOnTypeAsync(er,!1,(e=>t.occt.shapes.compound.makeCompound(e))),transformers:[]}],sr={shape:[void 0],origin:[[0,0,0]],direction:[[0,0,1]]};let nr={};nr.shape=Kn,nr.origin=We,nr.direction=f,e.HS.updateListInputs(nr),nr={...sr,...nr};const rr=[{result:await e.HS.executeBasedOnTypeAsync(nr,!1,(e=>t.occt.transforms.mirror(e))),transformers:[]}],ar={shape:[void 0],angle:[360],direction:[[0,1,0]],copy:[!1]};let or={};or.shape=$n,or.direction=x,e.HS.updateListInputs(or),or={...ar,...or};const ir=[{result:await e.HS.executeBasedOnTypeAsync(or,!1,(e=>t.occt.operations.revolve(e))),transformers:[]}];let cr={};cr.listElements=[ls[0],Es[0],Kn[0],rr[0]],e.HS.updateListInputs(cr),cr={...cr};const pr=[{result:[cr.listElements?cr.listElements:[]]}],ur={shape:[void 0],offset:[-.1]};let lr={};lr.shape=ir,e.HS.updateListInputs(lr),lr={...ur,...lr};const dr=[{result:await e.HS.executeBasedOnTypeAsync(lr,!1,(e=>t.occt.operations.makeThickSolidSimple(e))),transformers:[]}],mr={shape:[void 0],angle:[0],center:[[0,0,0]],axis:[[0,0,1]]};let yr={};yr.shape=tr,yr.angle=$e,yr.axis=k,e.HS.updateListInputs(yr),yr={...mr,...yr};const Sr=[{result:await e.HS.executeBasedOnTypeAsync(yr,!1,(e=>t.occt.transforms.rotateAroundCenter(e))),transformers:[]}],Hr={shapes:[void 0],tolerance:[1e-7]};let fr={};fr.shapes=pr,e.HS.updateListInputs(fr),fr={...Hr,...fr};const hr=[{result:await e.HS.executeBasedOnTypeAsync(fr,!1,(e=>t.occt.shapes.shell.sewFaces(e))),transformers:[]}],xr={entity:[void 0],options:[void 0],babylonMesh:[void 0]};let vr={};vr.entity=dr,vr.options=z,e.HS.updateListInputs(vr),vr={...xr,...vr};await e.HS.executeBasedOnTypeAsync(vr,!1,(e=>t.draw.drawAnyAsync(e)));let Or={};Or.listElements=Sr,e.HS.updateListInputs(Or),Or={...Or};const Ir=[{result:[Or.listElements?Or.listElements:[]]}],Lr={shapes:[void 0]};let Br={};Br.shapes=Ir,e.HS.updateListInputs(Br),Br={...Lr,...Br};const wr=[{result:await e.HS.executeBasedOnTypeAsync(Br,!1,(e=>t.occt.shapes.compound.makeCompound(e))),transformers:[]}];let Tr={};Tr.listElements=[hr[0],ve[0],wr[0]],e.HS.updateListInputs(Tr),Tr={...Tr};const gr=[{result:[Tr.listElements?Tr.listElements:[]]}],Ar={shapes:[void 0]};let Er={};Er.shapes=gr,e.HS.updateListInputs(Er),Er={...Ar,...Er};const br=[{result:await e.HS.executeBasedOnTypeAsync(Er,!1,(e=>t.occt.shapes.compound.makeCompound(e))),transformers:[]}],zr={entity:[void 0],options:[void 0],babylonMesh:[void 0]};let Wr={};Wr.entity=br,Wr.options=ne,e.HS.updateListInputs(Wr),Wr={...zr,...Wr};await e.HS.executeBasedOnTypeAsync(Wr,!1,(e=>t.draw.drawAnyAsync(e)))}(BitByBit,bitbybit,bitbybitRunnerResult,bitbybitRunnerInputs,Bit);\"}' };