fluidcad 0.0.37 → 0.0.38
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/lib/dist/core/plane.d.ts +26 -6
- package/lib/dist/core/plane.js +21 -44
- package/lib/dist/features/2d/offset.js +2 -2
- package/lib/dist/features/plane-from-object.d.ts +16 -4
- package/lib/dist/features/plane-from-object.js +101 -8
- package/lib/dist/oc/sweep-ops.d.ts +7 -16
- package/lib/dist/oc/sweep-ops.js +67 -99
- package/lib/dist/oc/thin-face-maker.d.ts +0 -19
- package/lib/dist/oc/thin-face-maker.js +3 -68
- package/lib/dist/oc/wire-ops.d.ts +17 -2
- package/lib/dist/oc/wire-ops.js +55 -4
- package/lib/dist/tests/features/2d/offset.test.js +74 -1
- package/lib/dist/tests/features/plane.test.js +95 -0
- package/lib/dist/tests/features/sweep.test.js +46 -1
- package/lib/dist/tsconfig.tsbuildinfo +1 -1
- package/llm-docs/api/index.json +1 -1
- package/llm-docs/index.json +1 -1
- package/package.json +1 -1
- package/server/dist/fluidcad-server.d.ts +1 -1
- package/server/dist/fluidcad-server.js +11 -1
- package/server/dist/routes/params.js +1 -1
- package/ui/dist/assets/{index-no7mtr5s.js → index-D8zV21wB.js} +83 -83
- package/ui/dist/index.html +1 -1
package/llm-docs/api/index.json
CHANGED
package/llm-docs/index.json
CHANGED
package/package.json
CHANGED
|
@@ -114,7 +114,7 @@ export declare class FluidCadServer {
|
|
|
114
114
|
processFile(filePath: string, ignoreCache?: boolean): Promise<SceneRenderedData | null>;
|
|
115
115
|
updateLiveCode(fileName: string, code: string): Promise<SceneRenderedData | null>;
|
|
116
116
|
rollbackFromUI(index: number): Promise<SceneRenderedData | null>;
|
|
117
|
-
recomputeCurrentFile(): Promise<SceneRenderedData | null>;
|
|
117
|
+
recomputeCurrentFile(forceFullRebuild?: boolean): Promise<SceneRenderedData | null>;
|
|
118
118
|
rollback(fileName: string, index: number): Promise<SceneRenderedData | null>;
|
|
119
119
|
importFile(workspacePath: string, fileName: string, data: string): Promise<void>;
|
|
120
120
|
getShapeProperties(shapeId: string): any;
|
|
@@ -220,13 +220,23 @@ export class FluidCadServer {
|
|
|
220
220
|
async rollbackFromUI(index) {
|
|
221
221
|
return this.rollback(this.currentFileName, index);
|
|
222
222
|
}
|
|
223
|
-
async recomputeCurrentFile() {
|
|
223
|
+
async recomputeCurrentFile(forceFullRebuild = false) {
|
|
224
224
|
if (!this.currentFilePath) {
|
|
225
225
|
return null;
|
|
226
226
|
}
|
|
227
227
|
const sessionId = this.currentFileName;
|
|
228
228
|
this.renderingCache.delete(sessionId);
|
|
229
229
|
this.lastRendered.delete(sessionId);
|
|
230
|
+
if (forceFullRebuild) {
|
|
231
|
+
// Drop the incremental-compare baseline so every object is rebuilt from
|
|
232
|
+
// scratch instead of being carried over as cached. Without this, an
|
|
233
|
+
// unchanged file compares equal at every index, the whole scene is
|
|
234
|
+
// marked cached, and the render reuses all geometry — so the explicit
|
|
235
|
+
// "Recompute scene" action does no visible work and reports no build
|
|
236
|
+
// timings (buildDurationMs is only recorded for objects that rebuild).
|
|
237
|
+
// Param edits keep the baseline so slider drags stay fast.
|
|
238
|
+
this.previousScenes.delete(sessionId);
|
|
239
|
+
}
|
|
230
240
|
return this.processFileInternal(sessionId, this.currentFilePath, true);
|
|
231
241
|
}
|
|
232
242
|
async rollback(fileName, index) {
|
|
@@ -2,7 +2,7 @@ import { Router } from 'express';
|
|
|
2
2
|
export function createParamsRouter(fluidCadServer, sendToExtension, broadcastToUI) {
|
|
3
3
|
const router = Router();
|
|
4
4
|
router.post('/recompute', async (_req, res) => {
|
|
5
|
-
const data = await fluidCadServer.recomputeCurrentFile();
|
|
5
|
+
const data = await fluidCadServer.recomputeCurrentFile(true);
|
|
6
6
|
if (!data) {
|
|
7
7
|
res.status(404).json({ error: 'No active scene' });
|
|
8
8
|
return;
|