Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
35 changes: 35 additions & 0 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
name: Pipeline

on:
- push

jobs:
check:
name: Source Revision
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [24.x, 22.x]

steps:
- uses: actions/checkout@v4

- uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
cache: 'npm'

- name: Install Dependencies
run: npm ci

- name: Run Format Check
run: npm run format:check

- name: Run Lint Check
run: npm run lint:check

- name: Build
run: npm run build

- name: Run Tests
run: npm run test
1 change: 0 additions & 1 deletion .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
{
"files.exclude": {
".github": true,
"node_modules": true
},
"search.exclude": {
Expand Down
4 changes: 0 additions & 4 deletions CLAUDE.md
Original file line number Diff line number Diff line change
Expand Up @@ -118,10 +118,6 @@ npm run export --silent -- Box > box.stl

## Primitives API

### Angle Constants

`Solid.DEG_45`, `Solid.DEG_90`, `Solid.DEG_180`, `Solid.DEG_270`, `Solid.DEG_360`

### Basic Shapes

```typescript
Expand Down
9 changes: 4 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -154,9 +154,9 @@ const hexNut = Solid.SUBTRACT(
Solid.cylinder(4, 6, { color: 'gray' })
).center();

// Partial geometries with angle parameter
const pieSlice = Solid.cylinder(10, 2, { color: 'red', angle: Solid.DEG_90 });
const hemisphere = Solid.sphere(8, { color: 'cyan', angle: Solid.DEG_180 });
// Partial geometries with angle parameter (in degrees)
const pieSlice = Solid.cylinder(10, 2, { color: 'red', angle: 90 });
const hemisphere = Solid.sphere(8, { color: 'cyan', angle: 180 });
```

### Example: Custom Profile Prisms
Expand Down Expand Up @@ -281,7 +281,7 @@ const quarterVase = Solid.revolutionSolidFromPoints(
[4, 10],
[0, 10]
],
{ angle: Solid.DEG_90, color: 'purple' }
{ angle: 90, color: 'purple' }
);
```

Expand Down Expand Up @@ -325,7 +325,6 @@ const w3 = Wall(30); // Different params, new computation
**Profiles:** `profilePrism(h,builder,opts)`, `profilePrismFromPoints(h,points,opts)`, `profilePrismFromPath(h,segments,opts)`
**Revolution:** `revolutionSolid(builder,opts)`, `revolutionSolidFromPoints(points,opts)`, `revolutionSolidFromPath(segments,opts)`
**Path Factories:** `straight(length)`, `curve(radius,angle)` - positive=right, negative=left, 0=sharp
**Angle Constants:** `DEG_45`, `DEG_90`, `DEG_180`, `DEG_270`, `DEG_360`

**Transforms (chainable):** `at(x,y,z)` absolute, `move({x?,y?,z?})` relative, `rotate({x?,y?,z?})` degrees, `scale({all?,x?,y?,z?})` multiplicative

Expand Down
34 changes: 17 additions & 17 deletions docs/assets/index-C1WGooGK.js → docs/assets/index-DeaveSRz.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion docs/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
<title>CSG Builder</title>
<meta name="viewport" content="width=device-width, initial-scale=1" />
<meta name="theme-color" content="#f3f4f6" />
<script type="module" crossorigin src="/csg-builder/assets/index-C1WGooGK.js"></script>
<script type="module" crossorigin src="/csg-builder/assets/index-DeaveSRz.js"></script>
<link rel="stylesheet" crossorigin href="/csg-builder/assets/index-ByUqiuvw.css">
</head>

Expand Down
1 change: 1 addition & 0 deletions eslint.config.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ export default [
'build',
'docs',
'.svelte-kit',
'vitest.config.*',
'package',
'**/.env',
'**/.env.*',
Expand Down
Loading