diff --git a/.gitignore b/.gitignore index d1d901d01..6415815be 100644 --- a/.gitignore +++ b/.gitignore @@ -1,30 +1,3 @@ -# Nix/Direnv /.direnv/ - -# Logs -logs -*.log -npm-debug.log* -yarn-debug.log* -yarn-error.log* -pnpm-debug.log* -lerna-debug.log* - -# Dependencies -node_modules - -# Build output -dist -dist-ssr -*.local - -# Editor directories and files -.vscode/* -!.vscode/extensions.json -.idea -.DS_Store -*.suo -*.ntvs* -*.njsproj -*.sln -*.sw? +/node_modules/ +/dist/ diff --git a/TODO.md b/TODO.md index 36f72a50a..4a216f0bf 100644 --- a/TODO.md +++ b/TODO.md @@ -36,7 +36,7 @@ A step-by-step checklist for porting MatterControl's design features to a Vue + - [x] Add basic lighting (ambient + two directional) ### Scene Helpers -- [ ] Add ground grid helper (XZ plane) +- [x] Add ground grid helper (XZ plane) - [ ] Add axis helper (RGB arrows for X/Y/Z) - [ ] Add option to toggle grid visibility - [ ] Add option to toggle axis visibility diff --git a/src/components/Viewport.vue b/src/components/Viewport.vue index a82f01c5e..add873fe3 100644 --- a/src/components/Viewport.vue +++ b/src/components/Viewport.vue @@ -32,6 +32,9 @@ function initScene() { // Add lighting addLighting() + // Add grid helper + addGridHelper() + // Add a test cube to verify rendering addTestCube() @@ -42,6 +45,11 @@ function initScene() { animate() } +function addGridHelper() { + const gridHelper = new THREE.GridHelper(10, 10, 0x444444, 0x333333) + scene.add(gridHelper) +} + function addLighting() { // Ambient light for base illumination const ambientLight = new THREE.AmbientLight(0xffffff, 0.4)