瀏覽代碼

refactor: clean up unused imports and streamline useControls in basic components

- Removed unused imports such as BasicShadowMap, NoToneMapping, and SRGBColorSpace from Primitives.vue and PrimitivesModel.vue to enhance code clarity.
- Updated the useControls destructuring in index.vue to remove the alpha property, simplifying the control setup for better maintainability.
alvarosabu 2 月之前
父節點
當前提交
99df73a6df

+ 0 - 3
playground/vue/src/pages/basic/Primitives.vue

@@ -4,13 +4,10 @@ import { OrbitControls } from '@tresjs/cientos'
 import { TresCanvas, useRenderLoop } from '@tresjs/core'
 import { TresLeches, useControls } from '@tresjs/leches'
 import {
-  BasicShadowMap,
   Group,
   Mesh,
   MeshToonMaterial,
-  NoToneMapping,
   SphereGeometry,
-  SRGBColorSpace,
   TorusGeometry,
   TorusKnotGeometry,
 } from 'three'

+ 1 - 1
playground/vue/src/pages/basic/index.vue

@@ -5,7 +5,7 @@ import { TresLeches, useControls } from '@tresjs/leches'
 import { OrbitControls } from '@tresjs/cientos'
 import '@tresjs/leches/styles'
 
-const { clearColor, clearAlpha, alpha, toneMapping, shadows, shadowMapType } = useControls({
+const { clearColor, clearAlpha, toneMapping, shadows, shadowMapType } = useControls({
   clearColor: '#82DBC5',
   clearAlpha: {
     value: 1,

+ 1 - 5
playground/vue/src/pages/models/PrimitivesModel.vue

@@ -2,11 +2,7 @@
 import { OrbitControls } from '@tresjs/cientos'
 import { TresCanvas } from '@tresjs/core'
 import { TresLeches, useControls } from '@tresjs/leches'
-import {
-  BasicShadowMap,
-  NoToneMapping,
-  SRGBColorSpace,
-} from 'three'
+
 import '@tresjs/leches/styles'
 
 const gl = {