forgecad 0.7.0 → 0.8.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -1
- package/dist/assets/{AdminPage-DAu1C1ST.js → AdminPage-D4bocK4E.js} +1 -1
- package/dist/assets/{DocsPage-Gc_BCdqC.js → DocsPage-D3A_g8V3.js} +85 -45
- package/dist/assets/{EditorApp-DG1-oUSV.css → EditorApp-BWYUSpUN.css} +133 -51
- package/dist/assets/EditorApp-Cihhqcsq.js +11692 -0
- package/dist/assets/{EmbedViewer-CEO8XbV8.js → EmbedViewer-kWjKaC_t.js} +1 -1
- package/dist/assets/LandingPageProofDriven-Bg2IUc3l.css +856 -0
- package/dist/assets/LandingPageProofDriven-DXkKlyhI.js +601 -0
- package/dist/assets/{PricingPage-BSrxu6d7.js → PricingPage-BsU5vzEx.js} +1 -1
- package/dist/assets/{SettingsPage-FUCSIRq6.js → SettingsPage-PqvpAKIs.js} +1 -1
- package/dist/assets/{evalWorker-KoR0SNKq.js → evalWorker-C-hzNUMy.js} +2218 -286
- package/dist/assets/{index-wTEK39at.js → index-Pz321YAt.js} +7416 -1481
- package/dist/assets/{index-CyVd1D4D.css → index-ay13WNfa.css} +501 -2
- package/dist/assets/{manifold-B1sGWdYk.js → manifold-BcbjWLIo.js} +3 -3
- package/dist/assets/{manifold-D7o0N50J.js → manifold-DBckbFgx.js} +1 -1
- package/dist/assets/{manifold-G5sBaXzi.js → manifold-O2AAGXyj.js} +1 -1
- package/dist/assets/{reportWorker-DYcRHhv9.js → reportWorker-Dxr-5A7w.js} +2003 -259
- package/dist/docs/index.html +2 -2
- package/dist/docs-raw/CLI.md +488 -0
- package/dist/docs-raw/generated/assembly.md +19 -11
- package/dist/docs-raw/generated/concepts.md +1023 -360
- package/dist/docs-raw/generated/core.md +1165 -264
- package/dist/docs-raw/generated/curves.md +168 -1
- package/dist/docs-raw/generated/lib.md +10 -5
- package/dist/docs-raw/generated/output.md +1 -1
- package/dist/docs-raw/generated/sdf.md +208 -0
- package/dist/docs-raw/generated/sketch.md +1281 -329
- package/dist/docs-raw/generated/viewport.md +29 -2
- package/dist/index.html +2 -2
- package/dist/landing/proof-ams-adapter.png +0 -0
- package/dist/landing/proof-bolt-and-nut.png +0 -0
- package/dist/landing/proof-fillet-enclosure.png +0 -0
- package/dist/landing/proof-glasses.png +0 -0
- package/dist/landing/proof-gyroid.png +0 -0
- package/dist/sitemap.xml +6 -6
- package/dist-cli/forgecad.js +3148 -555
- package/dist-cli/forgecad.js.map +1 -1
- package/dist-cli/{solver-FV7TJZGI.js → solver-46FFSK2U.js} +1 -3
- package/dist-cli/{solver-FV7TJZGI.js.map → solver-46FFSK2U.js.map} +1 -1
- package/dist-skill/CONTEXT.md +3700 -1153
- package/dist-skill/SKILL-dev.md +15 -17
- package/dist-skill/SKILL.md +14 -9
- package/dist-skill/docs/API/core/concepts.md +28 -1
- package/dist-skill/docs/CLI.md +488 -0
- package/dist-skill/docs/generated/assembly.md +19 -11
- package/dist-skill/docs/generated/core.md +1165 -264
- package/dist-skill/docs/generated/curves.md +168 -1
- package/dist-skill/docs/generated/lib.md +10 -5
- package/dist-skill/docs/generated/output.md +1 -1
- package/dist-skill/docs/generated/sdf.md +208 -0
- package/dist-skill/docs/generated/sketch.md +1281 -329
- package/dist-skill/docs/generated/viewport.md +29 -2
- package/dist-skill/docs/guides/joint-design.md +78 -0
- package/dist-skill/docs-dev/API/core/concepts.md +28 -1
- package/dist-skill/docs-dev/CLI.md +488 -0
- package/dist-skill/docs-dev/coding.md +1 -1
- package/dist-skill/docs-dev/component-model.md +164 -0
- package/dist-skill/docs-dev/generated/assembly.md +19 -11
- package/dist-skill/docs-dev/generated/core.md +1165 -264
- package/dist-skill/docs-dev/generated/curves.md +168 -1
- package/dist-skill/docs-dev/generated/lib.md +10 -5
- package/dist-skill/docs-dev/generated/output.md +1 -1
- package/dist-skill/docs-dev/generated/sdf.md +208 -0
- package/dist-skill/docs-dev/generated/sketch.md +1281 -329
- package/dist-skill/docs-dev/generated/viewport.md +29 -2
- package/dist-skill/docs-dev/guides/joint-design.md +78 -0
- package/examples/api/attachTo-basics.forge.js +3 -3
- package/examples/api/bill-of-materials.forge.js +9 -9
- package/examples/api/bolt-pattern.forge.js +5 -5
- package/examples/api/boolean-operations.forge.js +2 -2
- package/examples/api/bounding-box-visualizer.forge.js +1 -1
- package/examples/api/clone-duplicate.forge.js +1 -1
- package/examples/api/connector-assembly.forge.js +4 -2
- package/examples/api/connector-basics.forge.js +5 -5
- package/examples/api/constrained-sketch-mechanical.forge.js +4 -4
- package/examples/api/elbow-test.forge.js +3 -3
- package/examples/api/extrude-options.forge.js +4 -4
- package/examples/api/fillet-showcase.forge.js +1 -1
- package/examples/api/gears-tier1.forge.js +5 -5
- package/examples/api/group-test.forge.js +2 -2
- package/examples/api/mesh-import-slats.forge.js +3 -3
- package/examples/api/patterns.forge.js +3 -3
- package/examples/api/pointAlong-orientation.forge.js +2 -2
- package/examples/api/profile-2020-b-slot6.forge.js +4 -4
- package/examples/api/sketch-rounding-strategies.forge.js +1 -1
- package/examples/api/smooth-curve-connections.forge.js +1 -1
- package/examples/api/transition-curves.forge.js +3 -3
- package/examples/constraints/01-fully-constrained-rect.forge.js +2 -2
- package/examples/constraints/02-underconstrained-triangle.forge.js +1 -1
- package/examples/constraints/03-redundant-constraints.forge.js +2 -2
- package/examples/constraints/05-parallel-with-linedistance.forge.js +2 -2
- package/examples/constraints/06-complex-spectrogram.forge.js +1 -1
- package/examples/constraints/07-perpendicular-chain.forge.js +4 -4
- package/examples/constraints/08-symmetric-bracket.forge.js +4 -4
- package/examples/constraints/09-stress-spiral.forge.js +1 -1
- package/examples/constraints/10-stress-honeycomb.forge.js +1 -1
- package/examples/constraints/11-surface-grid.forge.js +2 -2
- package/examples/constraints/12-surface-nested.forge.js +4 -4
- package/examples/constraints/13-surface-complex.forge.js +1 -1
- package/examples/exact-arc-housing.forge.js +12 -0
- package/examples/furniture/adjustable-table.forge.js +13 -13
- package/examples/furniture/bathroom.forge.js +15 -15
- package/examples/furniture/chair.forge.js +12 -12
- package/examples/furniture/picture-frame.forge.js +6 -6
- package/examples/furniture/shoe-rack-doors.forge.js +8 -8
- package/examples/furniture/shoe-rack.forge.js +7 -7
- package/examples/furniture/table-lamp.forge.js +8 -8
- package/examples/gcode/lissajous-vase.forge.js +4 -4
- package/examples/gcode/math-surface.forge.js +3 -3
- package/examples/gcode/parametric-vase.forge.js +4 -4
- package/examples/gcode/spiral-tower.forge.js +4 -4
- package/examples/generative/crystal-growth.forge.js +7 -7
- package/examples/generative/frost-spires.forge.js +6 -6
- package/examples/generative/golden-spiral-tower.forge.js +8 -8
- package/examples/generative/molten-forge.forge.js +6 -6
- package/examples/generative/neon-coral.forge.js +7 -7
- package/examples/mechanical/3d-printer.forge.js +9 -9
- package/examples/mechanical/5-finger-robot-hand.forge.js +4 -4
- package/examples/mechanical/airplane-propeller.forge.js +7 -7
- package/examples/mechanical/bolt-and-nut.forge.js +10 -10
- package/examples/mechanical/door-with-hinges.forge.js +7 -7
- package/examples/mechanical/fillet-enclosure.forge.js +14 -10
- package/examples/mechanical/headphone-hanger-v2.forge.js +9 -9
- package/examples/mechanical/robot_hand.forge.js +10 -10
- package/examples/mechanical/robot_hand_2.forge.js +17 -17
- package/examples/nurbs-surface.forge.js +8 -0
- package/examples/nurbs-tube.forge.js +7 -0
- package/examples/products/bottle.forge.js +7 -7
- package/examples/products/chess-set.forge.js +6 -6
- package/examples/products/classical-piano.forge.js +9 -9
- package/examples/products/clock.forge.js +21 -21
- package/examples/products/cup.forge.js +5 -5
- package/examples/products/iphone.forge.js +12 -12
- package/examples/products/laptop.forge.js +9 -9
- package/examples/products/laser-cut-box.forge.js +6 -6
- package/examples/products/laser-cut-tray.forge.js +6 -6
- package/examples/products/liquid-soap-dispenser.forge.js +5 -5
- package/examples/products/origami-fish.forge.js +6 -6
- package/examples/products/spiderman-cake.forge.js +2 -2
- package/examples/shelf/container.forge.js +5 -5
- package/examples/shelf/shelf-unit.forge.js +6 -6
- package/examples/toolbox/bolted-joint.forge.js +5 -5
- package/package.json +3 -1
- package/dist/assets/EditorApp-D9bJvtf7.js +0 -11338
- package/dist/assets/LandingPage-CdCuEOdC.js +0 -451
- package/dist-cli/chunk-PZ5AY32C.js +0 -10
- package/dist-cli/chunk-PZ5AY32C.js.map +0 -1
- package/dist-skill/docs/CLI/export.md +0 -91
- package/dist-skill/docs/CLI/projects.md +0 -107
- package/dist-skill/docs/CLI/studio_publishing.md +0 -52
- package/dist-skill/docs/CLI/validation.md +0 -66
- package/dist-skill/docs-dev/API/core/sdf-advanced.md +0 -92
- package/dist-skill/docs-dev/API/core/sdf-primitives.md +0 -58
- package/dist-skill/docs-dev/API/core/sdf-workflow.md +0 -42
- package/dist-skill/docs-dev/CLI/export.md +0 -91
- package/dist-skill/docs-dev/CLI/projects.md +0 -107
- package/dist-skill/docs-dev/CLI/studio_publishing.md +0 -52
- package/dist-skill/docs-dev/CLI/validation.md +0 -66
|
@@ -1,19 +1,20 @@
|
|
|
1
1
|
// Filleted Electronics Enclosure — practical engineering part
|
|
2
2
|
// Demonstrates: fillet() for professional-looking product design
|
|
3
3
|
|
|
4
|
-
const width =
|
|
5
|
-
const depth =
|
|
6
|
-
const height =
|
|
7
|
-
const wall =
|
|
8
|
-
const outerR =
|
|
4
|
+
const width = Param.number("Width", 80, { min: 50, max: 120, unit: "mm" });
|
|
5
|
+
const depth = Param.number("Depth", 50, { min: 30, max: 80, unit: "mm" });
|
|
6
|
+
const height = Param.number("Height", 25, { min: 15, max: 40, unit: "mm" });
|
|
7
|
+
const wall = Param.number("Wall", 2.5, { min: 1.5, max: 4, unit: "mm" });
|
|
8
|
+
const outerR = Param.number("Outer Fillet", 4, { min: 1, max: 10, unit: "mm" });
|
|
9
9
|
|
|
10
10
|
// ── Outer shell with rounded vertical edges ─────────────────────────────────
|
|
11
11
|
const outer = box(width, depth, height);
|
|
12
12
|
let enclosure = fillet(outer, outerR, { parallel: [0, 0, 1], convex: true });
|
|
13
13
|
|
|
14
14
|
// ── Hollow interior ─────────────────────────────────────────────────────────
|
|
15
|
+
// box() is XY-centered, Z starts at 0 — cavity just needs a Z shift
|
|
15
16
|
const cavity = box(width - wall * 2, depth - wall * 2, height - wall)
|
|
16
|
-
.translate(
|
|
17
|
+
.translate(0, 0, wall + 0.01);
|
|
17
18
|
enclosure = difference(enclosure, cavity);
|
|
18
19
|
|
|
19
20
|
// ── Screw bosses ────────────────────────────────────────────────────────────
|
|
@@ -27,12 +28,15 @@ function screwBoss(x, y) {
|
|
|
27
28
|
return difference(boss, hole);
|
|
28
29
|
}
|
|
29
30
|
|
|
31
|
+
// Positions relative to centered box: -width/2..+width/2
|
|
32
|
+
const hw = width / 2;
|
|
33
|
+
const hd = depth / 2;
|
|
30
34
|
enclosure = union(
|
|
31
35
|
enclosure,
|
|
32
|
-
screwBoss(inset, inset),
|
|
33
|
-
screwBoss(
|
|
34
|
-
screwBoss(inset,
|
|
35
|
-
screwBoss(
|
|
36
|
+
screwBoss(-hw + inset, -hd + inset),
|
|
37
|
+
screwBoss( hw - inset, -hd + inset),
|
|
38
|
+
screwBoss(-hw + inset, hd - inset),
|
|
39
|
+
screwBoss( hw - inset, hd - inset),
|
|
36
40
|
);
|
|
37
41
|
|
|
38
42
|
return enclosure;
|
|
@@ -2,15 +2,15 @@
|
|
|
2
2
|
// Clamps to the bottom edge of a desk, hook hangs below.
|
|
3
3
|
// Designed for actual 3D printing / building.
|
|
4
4
|
|
|
5
|
-
const deskThick =
|
|
6
|
-
const clampDepth =
|
|
7
|
-
const width =
|
|
8
|
-
const thick =
|
|
9
|
-
const hookDrop =
|
|
10
|
-
const hookLen =
|
|
11
|
-
const hookCurveR =
|
|
12
|
-
const padThick =
|
|
13
|
-
const boltHoleD =
|
|
5
|
+
const deskThick = Param.number("Desk Thickness", 25, { min: 15, max: 50, unit: "mm" });
|
|
6
|
+
const clampDepth = Param.number("Clamp Depth", 40, { min: 25, max: 70, unit: "mm" });
|
|
7
|
+
const width = Param.number("Width", 50, { min: 30, max: 80, unit: "mm" });
|
|
8
|
+
const thick = Param.number("Material Thick", 5, { min: 3, max: 10, unit: "mm" });
|
|
9
|
+
const hookDrop = Param.number("Hook Drop", 60, { min: 30, max: 100, unit: "mm" });
|
|
10
|
+
const hookLen = Param.number("Hook Length", 35, { min: 15, max: 60, unit: "mm" });
|
|
11
|
+
const hookCurveR = Param.number("Hook Curve R", 15, { min: 5, max: 30, unit: "mm" });
|
|
12
|
+
const padThick = Param.number("Pad Thickness", 2, { min: 1, max: 5, unit: "mm" });
|
|
13
|
+
const boltHoleD = Param.number("Bolt Hole", 5, { min: 0, max: 8, unit: "mm" });
|
|
14
14
|
|
|
15
15
|
// The clamp is a C-shape that grips the desk edge.
|
|
16
16
|
// Top jaw sits on top of desk, bottom jaw presses from below.
|
|
@@ -5,16 +5,16 @@
|
|
|
5
5
|
// 3) Mount included: base, mast, wrist clevis
|
|
6
6
|
// 4) Iterative construction: build primitives -> segments -> fingers -> full assembly
|
|
7
7
|
|
|
8
|
-
const grip =
|
|
9
|
-
const fingerSpread =
|
|
10
|
-
const thumbOpposition =
|
|
11
|
-
const wristPitch =
|
|
12
|
-
const explode =
|
|
13
|
-
|
|
14
|
-
const scale =
|
|
15
|
-
const pinD =
|
|
16
|
-
const jointClearance =
|
|
17
|
-
const wall =
|
|
8
|
+
const grip = Param.number("Grip", 55, { min: 0, max: 100, unit: "%" });
|
|
9
|
+
const fingerSpread = Param.number("Finger Spread", 18, { min: 0, max: 35, unit: "°" });
|
|
10
|
+
const thumbOpposition = Param.number("Thumb Opposition", 42, { min: 20, max: 70, unit: "°" });
|
|
11
|
+
const wristPitch = Param.number("Wrist Pitch", 8, { min: -35, max: 45, unit: "°" });
|
|
12
|
+
const explode = Param.number("Explode", 0, { min: 0, max: 26, unit: "mm" });
|
|
13
|
+
|
|
14
|
+
const scale = Param.number("Scale", 1.0, { min: 0.75, max: 1.25, step: 0.01 });
|
|
15
|
+
const pinD = Param.number("Pin Diameter", 3.2, { min: 2.0, max: 5.0, step: 0.1, unit: "mm" }) * scale;
|
|
16
|
+
const jointClearance = Param.number("Joint Clearance", 0.32, { min: 0.2, max: 0.7, step: 0.02, unit: "mm" }) * scale;
|
|
17
|
+
const wall = Param.number("Min Wall", 2.4, { min: 1.6, max: 4.0, step: 0.1, unit: "mm" }) * scale;
|
|
18
18
|
|
|
19
19
|
// Core hand dimensions
|
|
20
20
|
const palmW = 84 * scale;
|
|
@@ -3,24 +3,24 @@
|
|
|
3
3
|
// Strategy: build small reliable modules, then combine with parametric kinematics.
|
|
4
4
|
|
|
5
5
|
// ---- 1) Control params (motion + fabrication) ----
|
|
6
|
-
const baseYaw =
|
|
7
|
-
const shoulderPitch =
|
|
8
|
-
const elbowPitch =
|
|
9
|
-
const wristPitch =
|
|
10
|
-
const wristRoll =
|
|
6
|
+
const baseYaw = Param.number("Base Yaw", 20, { min: -170, max: 170, unit: "°" });
|
|
7
|
+
const shoulderPitch = Param.number("Shoulder Pitch", 35, { min: -25, max: 105, unit: "°" });
|
|
8
|
+
const elbowPitch = Param.number("Elbow Pitch", 55, { min: -15, max: 135, unit: "°" });
|
|
9
|
+
const wristPitch = Param.number("Wrist Pitch", -20, { min: -100, max: 100, unit: "°" });
|
|
10
|
+
const wristRoll = Param.number("Wrist Roll", 10, { min: -180, max: 180, unit: "°" });
|
|
11
11
|
|
|
12
|
-
const upperLen =
|
|
13
|
-
const foreLen =
|
|
14
|
-
const foreExtension =
|
|
12
|
+
const upperLen = Param.number("Upper Arm Len", 210, { min: 140, max: 320, unit: "mm" });
|
|
13
|
+
const foreLen = Param.number("Forearm Len", 220, { min: 150, max: 340, unit: "mm" });
|
|
14
|
+
const foreExtension = Param.number("Forearm Ext", 70, { min: 0, max: 150, unit: "mm" });
|
|
15
15
|
|
|
16
|
-
const gripperOpen =
|
|
17
|
-
const fingerCurl =
|
|
18
|
-
const payloadType =
|
|
19
|
-
const payloadSize =
|
|
20
|
-
const carryPayload =
|
|
16
|
+
const gripperOpen = Param.number("Gripper Open", 55, { min: 0, max: 90, unit: "mm" });
|
|
17
|
+
const fingerCurl = Param.number("Finger Curl", 72, { min: 0, max: 100, unit: "°" });
|
|
18
|
+
const payloadType = Param.number("Payload Type", 2, { min: 1, max: 4, integer: true });
|
|
19
|
+
const payloadSize = Param.number("Payload Size", 36, { min: 20, max: 65, unit: "mm" });
|
|
20
|
+
const carryPayload = Param.number("Carry Payload", 1, { min: 0, max: 1, integer: true });
|
|
21
21
|
|
|
22
|
-
const exploded =
|
|
23
|
-
const sectionEnabled =
|
|
22
|
+
const exploded = Param.number("Exploded", 0, { min: 0, max: 140, unit: "mm" });
|
|
23
|
+
const sectionEnabled = Param.number("Section Enabled", 0, { min: 0, max: 1, integer: true });
|
|
24
24
|
|
|
25
25
|
// ---- 2) Math + transform helpers ----
|
|
26
26
|
function rad(deg) {
|
|
@@ -602,12 +602,12 @@ const sectionMarginZ = Math.max(30, (sceneBounds.max[2] - sceneBounds.min[2]) *
|
|
|
602
602
|
const sectionDefaultX = (sceneBounds.min[0] + sceneBounds.max[0]) * 0.5;
|
|
603
603
|
const sectionDefaultZ = (sceneBounds.min[2] + sceneBounds.max[2]) * 0.5;
|
|
604
604
|
|
|
605
|
-
const sectionX =
|
|
605
|
+
const sectionX = Param.number("Section X", sectionDefaultX, {
|
|
606
606
|
min: sceneBounds.min[0] - sectionMarginX,
|
|
607
607
|
max: sceneBounds.max[0] + sectionMarginX,
|
|
608
608
|
unit: "mm",
|
|
609
609
|
});
|
|
610
|
-
const sectionZ =
|
|
610
|
+
const sectionZ = Param.number("Section Z", sectionDefaultZ, {
|
|
611
611
|
min: sceneBounds.min[2] - sectionMarginZ,
|
|
612
612
|
max: sceneBounds.max[2] + sectionMarginZ,
|
|
613
613
|
unit: "mm",
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
// Freeform NURBS surface — a gently curved panel
|
|
2
|
+
const grid = [
|
|
3
|
+
[[0,0,0], [10,0,2], [20,0,2], [30,0,0]],
|
|
4
|
+
[[0,10,1], [10,10,6], [20,10,6], [30,10,1]],
|
|
5
|
+
[[0,20,1], [10,20,6], [20,20,6], [30,20,1]],
|
|
6
|
+
[[0,30,0], [10,30,2], [20,30,2], [30,30,0]],
|
|
7
|
+
];
|
|
8
|
+
return nurbsSurface(grid, { thickness: 1.5 });
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
// Water Bottle — revolve profile with cap
|
|
2
2
|
// Demonstrates: revolve, polygon, difference, smoothing, multi-object
|
|
3
3
|
|
|
4
|
-
const bodyH =
|
|
5
|
-
const bodyR =
|
|
6
|
-
const neckH =
|
|
7
|
-
const neckR =
|
|
8
|
-
const wall =
|
|
9
|
-
const capH =
|
|
10
|
-
const shoulderR =
|
|
4
|
+
const bodyH = Param.number("Body Height", 180, { min: 120, max: 250, unit: "mm" });
|
|
5
|
+
const bodyR = Param.number("Body Radius", 35, { min: 25, max: 50, unit: "mm" });
|
|
6
|
+
const neckH = Param.number("Neck Height", 30, { min: 15, max: 50, unit: "mm" });
|
|
7
|
+
const neckR = Param.number("Neck Radius", 14, { min: 10, max: 25, unit: "mm" });
|
|
8
|
+
const wall = Param.number("Wall Thickness", 2, { min: 1, max: 5, unit: "mm" });
|
|
9
|
+
const capH = Param.number("Cap Height", 18, { min: 10, max: 30, unit: "mm" });
|
|
10
|
+
const shoulderR = Param.number("Shoulder Curve", 20, { min: 5, max: 40, unit: "mm" });
|
|
11
11
|
|
|
12
12
|
// Outer profile — polygon traced from bottom-center up and around
|
|
13
13
|
// Bottom flat → body → shoulder curve → neck
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
const squareSize =
|
|
2
|
-
const boardThickness =
|
|
3
|
-
const borderWidth =
|
|
4
|
-
const tileHeight =
|
|
5
|
-
const pieceScale =
|
|
6
|
-
const pieceLift =
|
|
1
|
+
const squareSize = Param.number("Square Size", 36, { min: 24, max: 54, unit: "mm" });
|
|
2
|
+
const boardThickness = Param.number("Board Thickness", 14, { min: 8, max: 24, unit: "mm" });
|
|
3
|
+
const borderWidth = Param.number("Border Width", 10, { min: 4, max: 18, unit: "mm" });
|
|
4
|
+
const tileHeight = Param.number("Tile Height", 1.8, { min: 0.8, max: 4, step: 0.1, unit: "mm" });
|
|
5
|
+
const pieceScale = Param.number("Piece Scale", 1, { min: 0.8, max: 1.25, step: 0.01 });
|
|
6
|
+
const pieceLift = Param.number("Piece Lift", 0, { min: 0, max: 16, unit: "mm" });
|
|
7
7
|
|
|
8
8
|
const boardSize = squareSize * 8;
|
|
9
9
|
const frameSize = boardSize + borderWidth * 2;
|
|
@@ -12,15 +12,15 @@
|
|
|
12
12
|
- Bench
|
|
13
13
|
*/
|
|
14
14
|
|
|
15
|
-
const bodyWidth =
|
|
16
|
-
const bodyLength =
|
|
17
|
-
const rimHeight =
|
|
18
|
-
const lidThickness =
|
|
19
|
-
const lidOpen =
|
|
20
|
-
const legHeight =
|
|
21
|
-
const legTopRadius =
|
|
22
|
-
const keyboardDepth =
|
|
23
|
-
const keyHeight =
|
|
15
|
+
const bodyWidth = Param.number("Body Width", 180, { min: 140, max: 240, unit: "mm" });
|
|
16
|
+
const bodyLength = Param.number("Body Length", 280, { min: 220, max: 360, unit: "mm" });
|
|
17
|
+
const rimHeight = Param.number("Rim Height", 28, { min: 20, max: 40, unit: "mm" });
|
|
18
|
+
const lidThickness = Param.number("Lid Thickness", 6, { min: 4, max: 10, unit: "mm" });
|
|
19
|
+
const lidOpen = Param.number("Lid Angle", 25, { min: 0, max: 50, unit: "°" });
|
|
20
|
+
const legHeight = Param.number("Leg Height", 60, { min: 45, max: 90, unit: "mm" });
|
|
21
|
+
const legTopRadius = Param.number("Leg Top Radius", 8, { min: 5, max: 12, unit: "mm" });
|
|
22
|
+
const keyboardDepth = Param.number("Keyboard Depth", 60, { min: 45, max: 80, unit: "mm" });
|
|
23
|
+
const keyHeight = Param.number("Key Height", 5, { min: 3, max: 8, unit: "mm" });
|
|
24
24
|
|
|
25
25
|
const rimThickness = Math.min(12, bodyWidth * 0.07);
|
|
26
26
|
const keyboardWidth = bodyWidth * 0.9;
|
|
@@ -3,23 +3,23 @@
|
|
|
3
3
|
// Returns named objects to preserve colors and enable individual visibility control
|
|
4
4
|
|
|
5
5
|
// === Dimensions ===
|
|
6
|
-
const diameter =
|
|
7
|
-
const depth =
|
|
8
|
-
const rimWidth =
|
|
6
|
+
const diameter = Param.number("Diameter", 220, { min: 80, max: 400, unit: "mm" });
|
|
7
|
+
const depth = Param.number("Depth", 18, { min: 8, max: 50, unit: "mm" });
|
|
8
|
+
const rimWidth = Param.number("Rim Width", 8, { min: 3, max: 30, unit: "mm" });
|
|
9
9
|
|
|
10
10
|
// === Time Settings — Default 10:10:30 (Apple display time) ===
|
|
11
|
-
const hour =
|
|
12
|
-
const minute =
|
|
13
|
-
const second =
|
|
14
|
-
const showSecondHand =
|
|
11
|
+
const hour = Param.number("Hour", 10, { min: 1, max: 12, integer: true });
|
|
12
|
+
const minute = Param.number("Minute", 10, { min: 0, max: 59, integer: true });
|
|
13
|
+
const second = Param.number("Second", 30, { min: 0, max: 59, integer: true });
|
|
14
|
+
const showSecondHand = Param.number("Show Seconds", 1, { min: 0, max: 1, integer: true });
|
|
15
15
|
|
|
16
16
|
// === Color Customization ===
|
|
17
|
-
const rimColor =
|
|
18
|
-
const faceColor =
|
|
19
|
-
const markerColor =
|
|
20
|
-
const hourHandColor =
|
|
21
|
-
const minuteHandColor =
|
|
22
|
-
const secondHandColor =
|
|
17
|
+
const rimColor = Param.number("Rim Color", 0, { min: 0, max: 3, integer: true }); // 0=silver, 1=gold, 2=black, 3=rose
|
|
18
|
+
const faceColor = Param.number("Face Color", 0, { min: 0, max: 2, integer: true }); // 0=white, 1=black, 2=cream
|
|
19
|
+
const markerColor = Param.number("Marker Color", 0, { min: 0, max: 2, integer: true }); // 0=black, 1=white, 2=gold
|
|
20
|
+
const hourHandColor = Param.number("Hour Hand Color", 0, { min: 0, max: 3, integer: true }); // 0=black, 1=white, 2=gold, 3=red
|
|
21
|
+
const minuteHandColor = Param.number("Minute Hand Color", 1, { min: 0, max: 3, integer: true }); // 0=black, 1=white, 2=gold, 3=red
|
|
22
|
+
const secondHandColor = Param.number("Second Hand Color", 3, { min: 0, max: 3, integer: true }); // 0=black, 1=white, 2=gold, 3=red
|
|
23
23
|
|
|
24
24
|
// Color palette
|
|
25
25
|
const colors = {
|
|
@@ -61,8 +61,8 @@ const face = cylinder(2, innerRadius - 1)
|
|
|
61
61
|
.color(faceHex);
|
|
62
62
|
|
|
63
63
|
// === Hour Markers ===
|
|
64
|
-
const markerLength =
|
|
65
|
-
const markerWidth =
|
|
64
|
+
const markerLength = Param.number("Marker Length", 10, { min: 5, max: 25, unit: "mm" });
|
|
65
|
+
const markerWidth = Param.number("Marker Width", 2.5, { min: 1, max: 6, unit: "mm" });
|
|
66
66
|
|
|
67
67
|
const markerShapes = [];
|
|
68
68
|
for (let i = 0; i < 12; i++) {
|
|
@@ -86,12 +86,12 @@ for (let i = 0; i < 12; i++) {
|
|
|
86
86
|
const markers = union(...markerShapes).color(markerHex);
|
|
87
87
|
|
|
88
88
|
// === Clock Hands ===
|
|
89
|
-
const hourHandLength =
|
|
90
|
-
const hourHandWidth =
|
|
91
|
-
const minuteHandLength =
|
|
92
|
-
const minuteHandWidth =
|
|
93
|
-
const secondHandLength =
|
|
94
|
-
const secondHandWidth =
|
|
89
|
+
const hourHandLength = Param.number("Hour Hand Length", 55, { min: 25, max: 110, unit: "mm" });
|
|
90
|
+
const hourHandWidth = Param.number("Hour Hand Width", 10, { min: 5, max: 20, unit: "mm" });
|
|
91
|
+
const minuteHandLength = Param.number("Minute Hand Length", 80, { min: 40, max: 160, unit: "mm" });
|
|
92
|
+
const minuteHandWidth = Param.number("Minute Hand Width", 7, { min: 3, max: 14, unit: "mm" });
|
|
93
|
+
const secondHandLength = Param.number("Second Hand Length", 85, { min: 50, max: 170, unit: "mm" });
|
|
94
|
+
const secondHandWidth = Param.number("Second Hand Width", 2, { min: 1, max: 5, unit: "mm" });
|
|
95
95
|
|
|
96
96
|
// Calculate hand angles (0 degrees = 12 o'clock, clockwise)
|
|
97
97
|
const hourAngle = (hour % 12) * 30 + (minute / 60) * 30;
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
// Cup with larger top than bottom
|
|
2
2
|
|
|
3
3
|
// Parameters
|
|
4
|
-
const height =
|
|
5
|
-
const topRadius =
|
|
6
|
-
const bottomRadius =
|
|
7
|
-
const wallThickness =
|
|
8
|
-
const baseThickness =
|
|
4
|
+
const height = Param.number("Height", 80, { min: 40, max: 150, unit: "mm" });
|
|
5
|
+
const topRadius = Param.number("Top Radius", 35, { min: 20, max: 60, unit: "mm" });
|
|
6
|
+
const bottomRadius = Param.number("Bottom Radius", 25, { min: 15, max: 50, unit: "mm" });
|
|
7
|
+
const wallThickness = Param.number("Wall Thickness", 3, { min: 1, max: 8, unit: "mm" });
|
|
8
|
+
const baseThickness = Param.number("Base Thickness", 5, { min: 2, max: 10, unit: "mm" });
|
|
9
9
|
|
|
10
10
|
// Outer cup shape - tapered cylinder (truncated cone)
|
|
11
11
|
const outerCup = cylinder(height, bottomRadius, topRadius);
|
|
@@ -2,11 +2,11 @@
|
|
|
2
2
|
// Tests ForgeCAD's sketch→extrude + smoothing workflow
|
|
3
3
|
|
|
4
4
|
// === Dimensions (roughly iPhone 15 Pro proportions) ===
|
|
5
|
-
const w =
|
|
6
|
-
const h =
|
|
7
|
-
const d =
|
|
8
|
-
const cornerR =
|
|
9
|
-
const edgeR =
|
|
5
|
+
const w = Param.number("Width", 71.6, { min: 60, max: 80, unit: "mm" });
|
|
6
|
+
const h = Param.number("Height", 146.6, { min: 120, max: 170, unit: "mm" });
|
|
7
|
+
const d = Param.number("Depth", 8.25, { min: 6, max: 12, unit: "mm" });
|
|
8
|
+
const cornerR = Param.number("Corner Radius", 10, { min: 2, max: 20, unit: "mm" });
|
|
9
|
+
const edgeR = Param.number("Edge Radius", 1.5, { min: 0, max: 3, step: 0.1, unit: "mm" });
|
|
10
10
|
|
|
11
11
|
// === Body ===
|
|
12
12
|
// Rounded-rect profile extruded to phone depth, then subdivision-smoothed
|
|
@@ -15,7 +15,7 @@ const bodyProfile = roundedRect(w, h, cornerR);
|
|
|
15
15
|
let body = bodyProfile.extrude(d).translate(0, 0, -d / 2);
|
|
16
16
|
|
|
17
17
|
// === Screen cutout (top +Z face = phone screen side) ===
|
|
18
|
-
const screenInset =
|
|
18
|
+
const screenInset = Param.number("Screen Inset", 2, { min: 1, max: 5, unit: "mm" });
|
|
19
19
|
const screenDepth = 0.4;
|
|
20
20
|
const screenW = w - screenInset * 2;
|
|
21
21
|
const screenH = h - screenInset * 2;
|
|
@@ -34,9 +34,9 @@ const screenFill = roundedRect(screenW, screenH, screenR)
|
|
|
34
34
|
.translate(0, 0, d / 2 - screenDepth);
|
|
35
35
|
|
|
36
36
|
// === Camera island (bottom -Z face = phone back, upper-left area) ===
|
|
37
|
-
const camSize =
|
|
37
|
+
const camSize = Param.number("Camera Island", 36, { min: 25, max: 45, unit: "mm" });
|
|
38
38
|
const camR = 8;
|
|
39
|
-
const camBump =
|
|
39
|
+
const camBump = Param.number("Camera Bump", 1.5, { min: 0.5, max: 3, unit: "mm" });
|
|
40
40
|
const camEdgeInset = 4;
|
|
41
41
|
const camX = -w / 2 + camSize / 2 + camEdgeInset;
|
|
42
42
|
const camY = h / 2 - camSize / 2 - camEdgeInset;
|
|
@@ -47,8 +47,8 @@ let camIsland = roundedRect(camSize, camSize, camR)
|
|
|
47
47
|
.translate(0, 0, -d / 2 - camBump);
|
|
48
48
|
|
|
49
49
|
// Camera lenses — 3 in L-pattern, positioned via entity geometry
|
|
50
|
-
const lensR =
|
|
51
|
-
const lensGap =
|
|
50
|
+
const lensR = Param.number("Lens Radius", 6, { min: 3, max: 10, unit: "mm" });
|
|
51
|
+
const lensGap = Param.number("Lens Gap", 3, { min: 1, max: 8, unit: "mm" });
|
|
52
52
|
|
|
53
53
|
// Use Rectangle2D entity to derive lens positions from island bounds
|
|
54
54
|
const camRect = Rectangle2D.fromCenterAndDimensions(point(camX, camY), camSize, camSize);
|
|
@@ -71,7 +71,7 @@ camIsland = camIsland.subtract(makeLens(lens1), makeLens(lens2), makeLens(lens3)
|
|
|
71
71
|
|
|
72
72
|
// === Charging port (front -Y face = phone bottom edge) ===
|
|
73
73
|
// pointAlong([0,1,0]) orients the extrusion along +Y so it cuts INTO the body
|
|
74
|
-
const portW =
|
|
74
|
+
const portW = Param.number("Port Width", 9, { min: 6, max: 14, unit: "mm" });
|
|
75
75
|
const portH = 3;
|
|
76
76
|
const portDepth = 4;
|
|
77
77
|
|
|
@@ -82,7 +82,7 @@ const portCut = roundedRect(portW, portH, portH / 2)
|
|
|
82
82
|
|
|
83
83
|
// === Speaker & mic grille (front -Y face) ===
|
|
84
84
|
const holeR = 0.5;
|
|
85
|
-
const holeCount =
|
|
85
|
+
const holeCount = Param.number("Speaker Holes", 6, { min: 3, max: 10, integer: true });
|
|
86
86
|
const holeSpacing = 2.2;
|
|
87
87
|
const grillX0 = portW / 2 + 5;
|
|
88
88
|
|
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
// Laptop — parametric with opening hinge
|
|
2
2
|
// Demonstrates: joint(), multi-object, roundedRect, boolean ops
|
|
3
3
|
|
|
4
|
-
const w =
|
|
5
|
-
const d =
|
|
6
|
-
const baseH =
|
|
7
|
-
const lidH =
|
|
8
|
-
const cornerR =
|
|
9
|
-
const screenInset =
|
|
10
|
-
const kbInsetX =
|
|
11
|
-
const kbInsetY =
|
|
4
|
+
const w = Param.number("Width", 320, { min: 250, max: 400, unit: "mm" });
|
|
5
|
+
const d = Param.number("Depth", 220, { min: 170, max: 300, unit: "mm" });
|
|
6
|
+
const baseH = Param.number("Base Height", 15, { min: 8, max: 25, unit: "mm" });
|
|
7
|
+
const lidH = Param.number("Lid Height", 6, { min: 3, max: 12, unit: "mm" });
|
|
8
|
+
const cornerR = Param.number("Corner Radius", 10, { min: 3, max: 25, unit: "mm" });
|
|
9
|
+
const screenInset = Param.number("Screen Bezel", 8, { min: 3, max: 20, unit: "mm" });
|
|
10
|
+
const kbInsetX = Param.number("KB Inset X", 25, { min: 10, max: 50, unit: "mm" });
|
|
11
|
+
const kbInsetY = Param.number("KB Inset Y", 15, { min: 8, max: 40, unit: "mm" });
|
|
12
12
|
|
|
13
13
|
// ─── Base ───
|
|
14
14
|
const baseProfile = roundedRect(w, d, cornerR);
|
|
@@ -119,7 +119,7 @@ const screenAtHinge = screenPanel.translate(0, -hingeY, 0)
|
|
|
119
119
|
.rotateX(180)
|
|
120
120
|
.translate(0, hingeY, hingeZ);
|
|
121
121
|
|
|
122
|
-
const lidAngle =
|
|
122
|
+
const lidAngle = Param.number("Lid Angle", 110, { min: 0, max: 135, unit: "°" });
|
|
123
123
|
|
|
124
124
|
const openLid = lidAtHinge.rotateAroundAxis([1, 0, 0], lidAngle, [0, hingeY, hingeZ]);
|
|
125
125
|
const openScreen = screenAtHinge.rotateAroundAxis([1, 0, 0], lidAngle, [0, hingeY, hingeZ]);
|
|
@@ -20,12 +20,12 @@
|
|
|
20
20
|
// joints re-adapt because they reference the panel edge lengths.
|
|
21
21
|
|
|
22
22
|
// ── Parameters ─────────────────────────────────────────────────────
|
|
23
|
-
const t =
|
|
24
|
-
const w =
|
|
25
|
-
const d =
|
|
26
|
-
const h =
|
|
27
|
-
const fold =
|
|
28
|
-
const kerf =
|
|
23
|
+
const t = Param.number('Thickness', 3, { min: 2, max: 6, step: 0.5 });
|
|
24
|
+
const w = Param.number('Width', 100, { min: 40, max: 300 });
|
|
25
|
+
const d = Param.number('Depth', 80, { min: 40, max: 200 });
|
|
26
|
+
const h = Param.number('Height', 50, { min: 20, max: 150 });
|
|
27
|
+
const fold = Param.number('Fold', 1, { min: 0, max: 1, step: 0.01 });
|
|
28
|
+
const kerf = Param.number('Kerf', 0.2, { min: 0, max: 0.5, step: 0.05 });
|
|
29
29
|
|
|
30
30
|
// ── Create flat panels ─────────────────────────────────────────────
|
|
31
31
|
// Each panel is a named rectangle with four edges: bottom, right, top, left.
|
|
@@ -15,12 +15,12 @@
|
|
|
15
15
|
// • Step-by-step assembly instructions
|
|
16
16
|
|
|
17
17
|
// ── Parameters ─────────────────────────────────────────────────────────
|
|
18
|
-
const t =
|
|
19
|
-
const w =
|
|
20
|
-
const d =
|
|
21
|
-
const h =
|
|
22
|
-
const fold =
|
|
23
|
-
const kerf =
|
|
18
|
+
const t = Param.number('Thickness', 3, { min: 2, max: 6, step: 0.5 });
|
|
19
|
+
const w = Param.number('Width', 200, { min: 80, max: 400 });
|
|
20
|
+
const d = Param.number('Depth', 120, { min: 60, max: 250 });
|
|
21
|
+
const h = Param.number('Height', 50, { min: 20, max: 120 });
|
|
22
|
+
const fold = Param.number('Fold', 1, { min: 0, max: 1, step: 0.01 });
|
|
23
|
+
const kerf = Param.number('Kerf', 0.2, { min: 0, max: 0.5, step: 0.05 });
|
|
24
24
|
|
|
25
25
|
// ── Flat panels ─────────────────────────────────────────────────────────
|
|
26
26
|
// Named edges: bottom, right, top, left — CCW winding, origin at corner.
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
// Liquid Soap Dispenser — staged dispense animation without fluid simulation.
|
|
2
2
|
// Move "Dispense Progress" from 0 → 100 to preview one pump cycle.
|
|
3
3
|
|
|
4
|
-
const bodyH =
|
|
5
|
-
const bodyR =
|
|
6
|
-
const wall =
|
|
7
|
-
const pumpStroke =
|
|
8
|
-
const progressPct =
|
|
4
|
+
const bodyH = Param.number("Bottle Height", 130, { min: 90, max: 180, unit: "mm" });
|
|
5
|
+
const bodyR = Param.number("Bottle Radius", 34, { min: 24, max: 45, unit: "mm" });
|
|
6
|
+
const wall = Param.number("Wall Thickness", 2.8, { min: 1.5, max: 5, unit: "mm" });
|
|
7
|
+
const pumpStroke = Param.number("Pump Stroke", 10, { min: 4, max: 18, unit: "mm" });
|
|
8
|
+
const progressPct = Param.number("Dispense Progress", 0, { min: 0, max: 100, unit: "%" });
|
|
9
9
|
|
|
10
10
|
const progress = progressPct / 100;
|
|
11
11
|
const clamp01 = (v) => Math.max(0, Math.min(1, v));
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
// Origami Fish
|
|
2
2
|
// Stylized folded-paper fish inspired by a side-view crane-fish form.
|
|
3
3
|
|
|
4
|
-
const scale =
|
|
5
|
-
const paper =
|
|
6
|
-
const fold =
|
|
7
|
-
const tailSpread =
|
|
8
|
-
const tailDrop =
|
|
9
|
-
const showStand =
|
|
4
|
+
const scale = Param.number("Scale", 1.25, { min: 0.7, max: 1.9, step: 0.05 });
|
|
5
|
+
const paper = Param.number("Paper Thickness", 0.9, { min: 0.4, max: 2, step: 0.05, unit: "mm" });
|
|
6
|
+
const fold = Param.number("Fold", 30, { min: 0, max: 65, unit: "°" });
|
|
7
|
+
const tailSpread = Param.number("Tail Spread", 34, { min: 10, max: 70, unit: "°" });
|
|
8
|
+
const tailDrop = Param.number("Tail Drop", 26, { min: 0, max: 55, unit: "°" });
|
|
9
|
+
const showStand = Param.number("Show Stand", 1, { min: 0, max: 1, integer: true });
|
|
10
10
|
|
|
11
11
|
const redMain = "#c51f3a";
|
|
12
12
|
const redLight = "#d8324f";
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
// Spider-Man Birthday Cake
|
|
2
2
|
// A multi-tiered cake with Spider-Man colors and decorations.
|
|
3
3
|
|
|
4
|
-
const tierHeight =
|
|
5
|
-
const baseRadius =
|
|
4
|
+
const tierHeight = Param.number("Tier Height", 30, { min: 20, max: 50, unit: "mm" });
|
|
5
|
+
const baseRadius = Param.number("Base Radius", 60, { min: 40, max: 100, unit: "mm" });
|
|
6
6
|
|
|
7
7
|
// Colors
|
|
8
8
|
const spideyRed = '#e60000';
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
// Storage Container — parametric open-top bin
|
|
2
2
|
// Used by shelf-unit.forge.js via require()
|
|
3
3
|
|
|
4
|
-
const w =
|
|
5
|
-
const d =
|
|
6
|
-
const h =
|
|
7
|
-
const wall =
|
|
8
|
-
const lipH =
|
|
4
|
+
const w = Param.number("Container Width", 120, { min: 60, max: 200, unit: "mm" });
|
|
5
|
+
const d = Param.number("Container Depth", 180, { min: 100, max: 300, unit: "mm" });
|
|
6
|
+
const h = Param.number("Container Height", 100, { min: 50, max: 200, unit: "mm" });
|
|
7
|
+
const wall = Param.number("Wall", 3, { min: 1.5, max: 6, unit: "mm" });
|
|
8
|
+
const lipH = Param.number("Lip Height", 5, { min: 2, max: 10, unit: "mm" });
|
|
9
9
|
|
|
10
10
|
// Outer shell
|
|
11
11
|
const outer = box(w, d, h);
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
// Tool Shelf — multi-shelf unit with identical containers
|
|
2
2
|
// Demonstrates require() for reusing the same container across shelves
|
|
3
3
|
|
|
4
|
-
const shelfW =
|
|
5
|
-
const shelfD =
|
|
6
|
-
const totalH =
|
|
7
|
-
const boardT =
|
|
8
|
-
const rows =
|
|
9
|
-
const cols =
|
|
4
|
+
const shelfW = Param.number("Shelf Width", 800, { min: 400, max: 1200, unit: "mm" });
|
|
5
|
+
const shelfD = Param.number("Shelf Depth", 200, { min: 150, max: 350, unit: "mm" });
|
|
6
|
+
const totalH = Param.number("Total Height", 1200, { min: 600, max: 1800, unit: "mm" });
|
|
7
|
+
const boardT = Param.number("Board Thickness", 18, { min: 12, max: 25, unit: "mm" });
|
|
8
|
+
const rows = Param.number("Shelf Rows", 4, { min: 2, max: 6, integer: true });
|
|
9
|
+
const cols = Param.number("Containers/Row", 3, { min: 1, max: 6, integer: true });
|
|
10
10
|
|
|
11
11
|
// Container dimensions (must match container.forge.js defaults or be close)
|
|
12
12
|
const containerW = 120;
|
|
@@ -7,11 +7,11 @@
|
|
|
7
7
|
// - BOM listing fastener quantities
|
|
8
8
|
// - Optional exploded view
|
|
9
9
|
|
|
10
|
-
const plateW =
|
|
11
|
-
const plateD =
|
|
12
|
-
const topThick =
|
|
13
|
-
const botThick =
|
|
14
|
-
const exploded =
|
|
10
|
+
const plateW = Param.number("Plate Width", 60, { min: 40, max: 120, unit: "mm" });
|
|
11
|
+
const plateD = Param.number("Plate Depth", 40, { min: 30, max: 80, unit: "mm" });
|
|
12
|
+
const topThick = Param.number("Top Thick", 8, { min: 4, max: 20, unit: "mm" });
|
|
13
|
+
const botThick = Param.number("Bot Thick", 8, { min: 4, max: 20, unit: "mm" });
|
|
14
|
+
const exploded = Param.number("Explode", 0, { min: 0, max: 1, step: 1 });
|
|
15
15
|
|
|
16
16
|
// Bolt-circle inset from plate edge
|
|
17
17
|
const inset = 10;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "forgecad",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.8.0",
|
|
4
4
|
"description": "Code-first parametric CAD for JavaScript/TypeScript, in the browser and CLI.",
|
|
5
5
|
"license": "BUSL-1.1",
|
|
6
6
|
"type": "module",
|
|
@@ -68,6 +68,7 @@
|
|
|
68
68
|
"meta:path": "bash scripts/local-meta.sh path",
|
|
69
69
|
"gen:types": "node scripts/gen-forge-types.mjs",
|
|
70
70
|
"gen:docs": "node scripts/gen-api-docs.mjs",
|
|
71
|
+
"gen:cli-docs": "node scripts/gen-cli-docs.mjs",
|
|
71
72
|
"refresh": "node scripts/refresh.mjs"
|
|
72
73
|
},
|
|
73
74
|
"dependencies": {
|
|
@@ -87,6 +88,7 @@
|
|
|
87
88
|
"lz-string": "^1.5.0",
|
|
88
89
|
"manifold-3d": "^3.4.0",
|
|
89
90
|
"meshoptimizer": "^1.0.1",
|
|
91
|
+
"mp4-muxer": "^5.2.1",
|
|
90
92
|
"nanoid": "^5.1.7",
|
|
91
93
|
"opencascade.js": "2.0.0-beta.b5ff984",
|
|
92
94
|
"opentype.js": "^1.3.4",
|