@vyr/three-browser 0.0.32 → 0.0.35

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.
Files changed (95) hide show
  1. package/package.json +1 -1
  2. package/src/common/provider.ts +3 -5
  3. package/src/common/validate.ts +2 -4
  4. package/src/fragment/GeoMapFragment.vue +2 -2
  5. package/src/fragment/InstancedMeshFragment.vue +4 -4
  6. package/src/fragment/MeshFragment.vue +4 -4
  7. package/src/fragment/ModelFragment.vue +2 -2
  8. package/src/fragment/NodeFragment.vue +2 -2
  9. package/src/fragment/ParticleFragment.vue +2 -2
  10. package/src/fragment/PointsFragment.vue +2 -2
  11. package/src/fragment/SpriteFragment.vue +2 -2
  12. package/src/fragment/{TextFragment.vue → Text3DFragment.vue} +8 -8
  13. package/src/fragment/animation/AnimationActionFragment.vue +3 -3
  14. package/src/fragment/geometry/BoxGeometryFragment.vue +2 -2
  15. package/src/fragment/geometry/BufferGeometryFragment.vue +2 -2
  16. package/src/fragment/geometry/CircleGeometryFragment.vue +2 -2
  17. package/src/fragment/geometry/CylinderGeometryFragment.vue +2 -2
  18. package/src/fragment/geometry/ExtrudeGeometryFragment.vue +2 -2
  19. package/src/fragment/geometry/PlaneGeometryFragment.vue +2 -2
  20. package/src/fragment/geometry/RingGeometryFragment.vue +2 -2
  21. package/src/fragment/geometry/SphereGeometryFragment.vue +2 -2
  22. package/src/fragment/geometry/SurfaceGeometryFragment.vue +2 -2
  23. package/src/fragment/geometry/TubeGeometryFragment.vue +2 -2
  24. package/src/fragment/light/AmbientLightFragment.vue +2 -2
  25. package/src/fragment/light/DirectionalLightFragment.vue +2 -2
  26. package/src/fragment/light/HemisphereLightFragment.vue +2 -2
  27. package/src/fragment/light/PointLightFragment.vue +2 -2
  28. package/src/fragment/light/RectAreaLightFragment.vue +2 -2
  29. package/src/fragment/light/SpotLightFragment.vue +2 -2
  30. package/src/fragment/material/MaterialFragment.vue +4 -4
  31. package/src/fragment/material/MeshBasicMaterialFragment.vue +4 -4
  32. package/src/fragment/material/MeshPhongMaterialFragment.vue +4 -4
  33. package/src/fragment/material/MeshStandardMaterialFragment.vue +4 -4
  34. package/src/fragment/material/PointsMaterialFragment.vue +4 -4
  35. package/src/fragment/material/ShaderMaterialFragment.vue +2 -2
  36. package/src/fragment/material/ShadowMaterialFragment.vue +4 -4
  37. package/src/fragment/material/SpriteMaterialFragment.vue +4 -4
  38. package/src/fragment/texture/TextureFragment.vue +10 -10
  39. package/src/locale/Language.ts +1 -5
  40. package/src/locale/LanguageProvider.ts +28 -33
  41. package/src/option/Animation.ts +3 -8
  42. package/src/option/Geometry.ts +4 -10
  43. package/src/option/Material.ts +6 -14
  44. package/src/option/Mesh.ts +2 -6
  45. package/src/option/Shadow.ts +3 -8
  46. package/src/option/Texture.ts +6 -14
  47. package/src/service/footer/action/geometry/index.ts +15 -20
  48. package/src/service/footer/action/material/index.ts +12 -17
  49. package/src/service/footer/action/texture/index.ts +6 -11
  50. package/src/service/global/index.ts +0 -1
  51. package/src/service/index.ts +20 -47
  52. package/src/service/inspector/GeoMapViewer.vue +3 -3
  53. package/src/service/inspector/HTMLConvertViewer.vue +3 -3
  54. package/src/service/inspector/InstanceMeshViewer.vue +3 -3
  55. package/src/service/inspector/MeshViewer.vue +3 -3
  56. package/src/service/inspector/ModelViewer.vue +3 -3
  57. package/src/service/inspector/NodeViewer.vue +3 -3
  58. package/src/service/inspector/ParticleViewer.vue +3 -3
  59. package/src/service/inspector/PerspectiveCameraViewer.vue +3 -3
  60. package/src/service/inspector/PointsViewer.vue +3 -3
  61. package/src/service/inspector/ServiceViewer.vue +10 -42
  62. package/src/service/inspector/SpriteViewer.vue +3 -3
  63. package/src/service/inspector/{TextViewer.vue → Text3DViewer.vue} +6 -6
  64. package/src/service/inspector/animation/AnimationActionViewer.vue +3 -3
  65. package/src/service/inspector/geometry/BoxGeometryViewer.vue +3 -3
  66. package/src/service/inspector/geometry/BufferGeometryViewer.vue +3 -3
  67. package/src/service/inspector/geometry/CircleGeometryViewer.vue +3 -3
  68. package/src/service/inspector/geometry/CylinderGeometryViewer.vue +3 -3
  69. package/src/service/inspector/geometry/ExtrudeGeometryViewer.vue +3 -3
  70. package/src/service/inspector/geometry/PlaneGeometryViewer.vue +3 -3
  71. package/src/service/inspector/geometry/RingGeometryViewer.vue +3 -3
  72. package/src/service/inspector/geometry/SphereGeometryViewer.vue +3 -3
  73. package/src/service/inspector/geometry/SurfaceGeometryViewer.vue +3 -3
  74. package/src/service/inspector/geometry/TubeGeometryViewer.vue +3 -3
  75. package/src/service/inspector/index.ts +46 -46
  76. package/src/service/inspector/light/AmbientLightViewer.vue +3 -3
  77. package/src/service/inspector/light/DirectionalLightViewer.vue +3 -3
  78. package/src/service/inspector/light/HemisphereLightViewer.vue +3 -3
  79. package/src/service/inspector/light/PointLightViewer.vue +3 -3
  80. package/src/service/inspector/light/RectAreaLightViewer.vue +3 -3
  81. package/src/service/inspector/light/SpotLightViewer.vue +3 -3
  82. package/src/service/inspector/material/MeshBasicMaterialViewer.vue +3 -3
  83. package/src/service/inspector/material/MeshPhongMaterialViewer.vue +3 -3
  84. package/src/service/inspector/material/MeshStandardMaterialViewer.vue +3 -3
  85. package/src/service/inspector/material/PointsMaterialViewer.vue +3 -3
  86. package/src/service/inspector/material/ShaderMaterialViewer.vue +3 -3
  87. package/src/service/inspector/material/ShadowMaterialViewer.vue +3 -3
  88. package/src/service/inspector/material/SpriteMaterialViewer.vue +3 -3
  89. package/src/service/inspector/texture/TextureViewer.vue +3 -3
  90. package/src/service/sidebar/asset/action/AddAnimationAction.ts +14 -25
  91. package/src/service/sidebar/asset/action/AddLightAction.ts +17 -26
  92. package/src/service/global/scripts/index.ts +0 -22
  93. package/src/service/sidebar/scene/action/AddAnimationAction.ts +0 -65
  94. package/src/service/sidebar/scene/action/AddLightAction.ts +0 -67
  95. package/src/service/sidebar/scene/action/index.ts +0 -7
@@ -3,7 +3,7 @@
3
3
  <vyr-label :label="language.get('inspector.Material.color')">
4
4
  <vyr-col>
5
5
  <vyr-checked v-model="descriptor.colorWrite"></vyr-checked>
6
- <vyr-color-picker v-model="descriptor.color.value" width="all"></vyr-color-picker>
6
+ <vyr-color-picker v-model="descriptor.color" width="all"></vyr-color-picker>
7
7
  </vyr-col>
8
8
  </vyr-label>
9
9
  </vyr-row>
@@ -27,7 +27,7 @@
27
27
  <vyr-label :label="language.get('inspector.Material.transparent')">
28
28
  <vyr-col>
29
29
  <vyr-checked v-model="descriptor.transparent"></vyr-checked>
30
- <vyr-input-number v-model="descriptor.color.opacity" :allow-null="false"></vyr-input-number>
30
+ <vyr-input-number v-model="descriptor.opacity" :allow-null="false"></vyr-input-number>
31
31
  </vyr-col>
32
32
  </vyr-label>
33
33
  </vyr-row>
@@ -248,7 +248,7 @@
248
248
  <script lang="ts" setup>
249
249
  import { computed } from 'vue'
250
250
  import { DraggableService, runtime } from '@vyr/runtime';
251
- import { MeshPhongMaterialDescriptor } from '@vyr/three';
251
+ import { MeshPhongMaterial } from '@vyr/three';
252
252
  import { VyrInput, VyrRow, VyrCol, VyrLabel, VyrChecked, VyrColorPicker, VyrInputNumber, VyrSelect } from '@vyr/design';
253
253
  import { option } from '@vyr/builtin'
254
254
  import { language } from '../../locale'
@@ -257,7 +257,7 @@ import { Material } from '../../option';
257
257
 
258
258
  const draggableService = runtime.get<DraggableService>('draggable')
259
259
  const draggable = computed(() => draggableService.get(draggableService.key.inspector))
260
- const descriptor = useDescriptor<MeshPhongMaterialDescriptor>()
260
+ const descriptor = useDescriptor<MeshPhongMaterial>()
261
261
  </script>
262
262
 
263
263
  <style lang="less" scoped></style>
@@ -3,7 +3,7 @@
3
3
  <vyr-label :label="language.get('inspector.Material.color')">
4
4
  <vyr-col>
5
5
  <vyr-checked v-model="descriptor.colorWrite"></vyr-checked>
6
- <vyr-color-picker v-model="descriptor.color.value" width="all"></vyr-color-picker>
6
+ <vyr-color-picker v-model="descriptor.color" width="all"></vyr-color-picker>
7
7
  </vyr-col>
8
8
  </vyr-label>
9
9
  </vyr-row>
@@ -19,7 +19,7 @@
19
19
  <vyr-label :label="language.get('inspector.Material.transparent')">
20
20
  <vyr-col>
21
21
  <vyr-checked v-model="descriptor.transparent"></vyr-checked>
22
- <vyr-input-number v-model="descriptor.color.opacity" :allow-null="false"></vyr-input-number>
22
+ <vyr-input-number v-model="descriptor.opacity" :allow-null="false"></vyr-input-number>
23
23
  </vyr-col>
24
24
  </vyr-label>
25
25
  </vyr-row>
@@ -241,7 +241,7 @@
241
241
  <script lang="ts" setup>
242
242
  import { computed } from 'vue'
243
243
  import { DraggableService, runtime } from '@vyr/runtime';
244
- import { MeshStandardMaterialDescriptor } from '@vyr/three';
244
+ import { MeshStandardMaterial } from '@vyr/three';
245
245
  import { VyrInput, VyrRow, VyrCol, VyrLabel, VyrChecked, VyrColorPicker, VyrInputNumber, VyrSelect } from '@vyr/design';
246
246
  import { option } from '@vyr/builtin'
247
247
  import { language } from '../../locale'
@@ -250,7 +250,7 @@ import { Material } from '../../option';
250
250
 
251
251
  const draggableService = runtime.get<DraggableService>('draggable')
252
252
  const draggable = computed(() => draggableService.get(draggableService.key.inspector))
253
- const descriptor = useDescriptor<MeshStandardMaterialDescriptor>()
253
+ const descriptor = useDescriptor<MeshStandardMaterial>()
254
254
  </script>
255
255
 
256
256
  <style lang="less" scoped></style>
@@ -4,7 +4,7 @@
4
4
  <vyr-label :label="language.get('inspector.Material.color')">
5
5
  <vyr-col>
6
6
  <vyr-checked v-model="descriptor.colorWrite"></vyr-checked>
7
- <vyr-color-picker v-model="descriptor.color.value" width="all"></vyr-color-picker>
7
+ <vyr-color-picker v-model="descriptor.color" width="all"></vyr-color-picker>
8
8
  </vyr-col>
9
9
  </vyr-label>
10
10
  </vyr-row>
@@ -20,7 +20,7 @@
20
20
  <vyr-label :label="language.get('inspector.Material.transparent')">
21
21
  <vyr-col>
22
22
  <vyr-checked v-model="descriptor.transparent"></vyr-checked>
23
- <vyr-input-number v-model="descriptor.color.opacity" :allow-null="false"></vyr-input-number>
23
+ <vyr-input-number v-model="descriptor.opacity" :allow-null="false"></vyr-input-number>
24
24
  </vyr-col>
25
25
  </vyr-label>
26
26
  </vyr-row>
@@ -65,7 +65,7 @@
65
65
  <script lang="ts" setup>
66
66
  import { computed } from 'vue'
67
67
  import { DraggableService, runtime } from '@vyr/runtime';
68
- import { PointsMaterialDescriptor } from '@vyr/three';
68
+ import { PointsMaterial } from '@vyr/three';
69
69
  import { VyrInput, VyrRow, VyrCol, VyrLabel, VyrChecked, VyrColorPicker, VyrInputNumber, VyrSelect } from '@vyr/design';
70
70
  import { option } from '@vyr/builtin'
71
71
  import { language } from '../../locale'
@@ -74,7 +74,7 @@ import { useDescriptor } from '../../common';
74
74
  defineProps<{ sizable?: boolean }>()
75
75
  const draggableService = runtime.get<DraggableService>('draggable')
76
76
  const draggable = computed(() => draggableService.get(draggableService.key.inspector))
77
- const descriptor = useDescriptor<PointsMaterialDescriptor>()
77
+ const descriptor = useDescriptor<PointsMaterial>()
78
78
 
79
79
  </script>
80
80
 
@@ -47,7 +47,7 @@
47
47
  <script lang="ts" setup>
48
48
  import { computed } from 'vue'
49
49
  import { DraggableService, runtime } from '@vyr/runtime';
50
- import { ShaderMaterialDescriptor } from '@vyr/three';
50
+ import { ShaderMaterial } from '@vyr/three';
51
51
  import { VyrRow, VyrCol, VyrLabel, VyrInput, VyrSelect } from '@vyr/design';
52
52
  import { option } from '@vyr/builtin'
53
53
  import { language } from '../../locale'
@@ -55,7 +55,7 @@ import { useDescriptor } from '../../common';
55
55
 
56
56
  const draggableService = runtime.get<DraggableService>('draggable')
57
57
  const draggable = computed(() => draggableService.get(draggableService.key.inspector))
58
- const descriptor = useDescriptor<ShaderMaterialDescriptor>()
58
+ const descriptor = useDescriptor<ShaderMaterial>()
59
59
  </script>
60
60
 
61
61
  <style lang="less" scoped></style>
@@ -3,7 +3,7 @@
3
3
  <vyr-label :label="language.get('inspector.Material.color')">
4
4
  <vyr-col>
5
5
  <vyr-checked v-model="descriptor.colorWrite"></vyr-checked>
6
- <vyr-color-picker v-model="descriptor.color.value" width="all"></vyr-color-picker>
6
+ <vyr-color-picker v-model="descriptor.color" width="all"></vyr-color-picker>
7
7
  </vyr-col>
8
8
  </vyr-label>
9
9
  </vyr-row>
@@ -11,7 +11,7 @@
11
11
  <vyr-label :label="language.get('inspector.Material.transparent')">
12
12
  <vyr-col>
13
13
  <vyr-checked v-model="descriptor.transparent"></vyr-checked>
14
- <vyr-input-number v-model="descriptor.color.opacity" :allow-null="false"></vyr-input-number>
14
+ <vyr-input-number v-model="descriptor.opacity" :allow-null="false"></vyr-input-number>
15
15
  </vyr-col>
16
16
  </vyr-label>
17
17
  </vyr-row>
@@ -34,7 +34,7 @@
34
34
  <script lang="ts" setup>
35
35
  import { computed } from 'vue'
36
36
  import { DraggableService, runtime } from '@vyr/runtime';
37
- import { ShadowMaterialDescriptor } from '@vyr/three';
37
+ import { ShadowMaterial } from '@vyr/three';
38
38
  import { VyrRow, VyrCol, VyrLabel, VyrChecked, VyrColorPicker, VyrInputNumber, VyrSelect } from '@vyr/design';
39
39
  import { option } from '@vyr/builtin'
40
40
  import { language } from '../../locale'
@@ -42,7 +42,7 @@ import { useDescriptor } from '../../common';
42
42
 
43
43
  const draggableService = runtime.get<DraggableService>('draggable')
44
44
  const draggable = computed(() => draggableService.get(draggableService.key.inspector))
45
- const descriptor = useDescriptor<ShadowMaterialDescriptor>()
45
+ const descriptor = useDescriptor<ShadowMaterial>()
46
46
 
47
47
  </script>
48
48
 
@@ -3,7 +3,7 @@
3
3
  <vyr-label :label="language.get('inspector.Material.color')">
4
4
  <vyr-col>
5
5
  <vyr-checked v-model="descriptor.colorWrite"></vyr-checked>
6
- <vyr-color-picker v-model="descriptor.color.value" width="all"></vyr-color-picker>
6
+ <vyr-color-picker v-model="descriptor.color" width="all"></vyr-color-picker>
7
7
  </vyr-col>
8
8
  </vyr-label>
9
9
  </vyr-row>
@@ -19,7 +19,7 @@
19
19
  <vyr-label :label="language.get('inspector.Material.transparent')">
20
20
  <vyr-col>
21
21
  <vyr-checked v-model="descriptor.transparent"></vyr-checked>
22
- <vyr-input-number v-model="descriptor.color.opacity" :allow-null="false"></vyr-input-number>
22
+ <vyr-input-number v-model="descriptor.opacity" :allow-null="false"></vyr-input-number>
23
23
  </vyr-col>
24
24
  </vyr-label>
25
25
  </vyr-row>
@@ -64,7 +64,7 @@
64
64
  <script lang="ts" setup>
65
65
  import { computed } from 'vue'
66
66
  import { DraggableService, runtime } from '@vyr/runtime';
67
- import { SpriteMaterialDescriptor } from '@vyr/three';
67
+ import { SpriteMaterial } from '@vyr/three';
68
68
  import { VyrInput, VyrRow, VyrCol, VyrLabel, VyrChecked, VyrColorPicker, VyrInputNumber, VyrSelect } from '@vyr/design';
69
69
  import { option } from '@vyr/builtin'
70
70
  import { language } from '../../locale'
@@ -72,7 +72,7 @@ import { useDescriptor } from '../../common';
72
72
 
73
73
  const draggableService = runtime.get<DraggableService>('draggable')
74
74
  const draggable = computed(() => draggableService.get(draggableService.key.inspector))
75
- const descriptor = useDescriptor<SpriteMaterialDescriptor>()
75
+ const descriptor = useDescriptor<SpriteMaterial>()
76
76
 
77
77
  </script>
78
78
 
@@ -10,38 +10,38 @@
10
10
  <vyr-row>
11
11
  <vyr-label :label="language.get('inspector.Texture.mapping')">
12
12
  <vyr-col>
13
- <vyr-select v-model="descriptor.mapping" :data="Texture.mappingOptions"></vyr-select>
13
+ <vyr-select v-model="descriptor.mapping" :data="TextureOption.mappingOptions"></vyr-select>
14
14
  </vyr-col>
15
15
  </vyr-label>
16
16
  </vyr-row>
17
17
  <vyr-row>
18
18
  <vyr-label :label="language.get('inspector.Texture.ftype')">
19
19
  <vyr-col>
20
- <vyr-select v-model="descriptor.ftype" :data="Texture.ftypeOptions"></vyr-select>
20
+ <vyr-select v-model="descriptor.ftype" :data="TextureOption.ftypeOptions"></vyr-select>
21
21
  </vyr-col>
22
22
  </vyr-label>
23
23
  </vyr-row>
24
24
  <vyr-row>
25
25
  <vyr-label :label="language.get('inspector.Texture.format')">
26
26
  <vyr-col>
27
- <vyr-select v-model="descriptor.format" :data="Texture.formatOptions"></vyr-select>
27
+ <vyr-select v-model="descriptor.format" :data="TextureOption.formatOptions"></vyr-select>
28
28
  </vyr-col>
29
29
  </vyr-label>
30
30
  </vyr-row>
31
31
  <vyr-row>
32
32
  <vyr-label :label="language.get('inspector.Texture.colorSpace')">
33
33
  <vyr-col>
34
- <vyr-select v-model="descriptor.colorSpace" :data="Texture.colorSpaceOptions"></vyr-select>
34
+ <vyr-select v-model="descriptor.colorSpace" :data="TextureOption.colorSpaceOptions"></vyr-select>
35
35
  </vyr-col>
36
36
  </vyr-label>
37
37
  </vyr-row>
38
38
  <vyr-row>
39
39
  <vyr-label :label="language.get('inspector.Texture.wrap')">
40
40
  <vyr-col :span="12">
41
- <vyr-select v-model="descriptor.wrapS" :data="Texture.wrapOptions"></vyr-select>
41
+ <vyr-select v-model="descriptor.wrapS" :data="TextureOption.wrapOptions"></vyr-select>
42
42
  </vyr-col>
43
43
  <vyr-col :span="12">
44
- <vyr-select v-model="descriptor.wrapT" :data="Texture.wrapOptions"></vyr-select>
44
+ <vyr-select v-model="descriptor.wrapT" :data="TextureOption.wrapOptions"></vyr-select>
45
45
  </vyr-col>
46
46
  </vyr-label>
47
47
  </vyr-row>
@@ -52,7 +52,7 @@
52
52
  :default-value="0"></vyr-input-number>
53
53
  </vyr-col>
54
54
  <vyr-col :span="12">
55
- <vyr-input-number v-model="descriptor.offset.y" :data="Texture.wrapOptions" :allow-null="false"
55
+ <vyr-input-number v-model="descriptor.offset.y" :data="TextureOption.wrapOptions" :allow-null="false"
56
56
  :default-value="0"></vyr-input-number>
57
57
  </vyr-col>
58
58
  </vyr-label>
@@ -115,15 +115,15 @@
115
115
 
116
116
  <script lang="ts" setup>
117
117
  import { computed } from 'vue';
118
- import { TextureDescriptor } from '@vyr/three';
118
+ import { Texture } from '@vyr/three';
119
119
  import { DraggableService, runtime } from '@vyr/runtime';
120
120
  import { option } from '@vyr/builtin'
121
121
  import { VyrInput, VyrRow, VyrCol, VyrLabel, VyrInputNumber, VyrSelect } from '@vyr/design';
122
122
  import { language } from '../../locale'
123
123
  import { useDescriptor } from '../../common';
124
- import { Texture } from '../../option'
124
+ import { Texture as TextureOption } from '../../option'
125
125
 
126
- const descriptor = useDescriptor<TextureDescriptor>()
126
+ const descriptor = useDescriptor<Texture>()
127
127
  const draggableService = runtime.get<DraggableService>('draggable')
128
128
  const draggable = computed(() => draggableService.get(draggableService.key.inspector))
129
129
  </script>
@@ -3,8 +3,4 @@ import { zhCnLanguageProvider, ZhCNLanguageProvider } from "./LanguageProvider";
3
3
 
4
4
  Locale.register(zhCnLanguageProvider)
5
5
 
6
- const language = Locale.getLanguage<ZhCNLanguageProvider>(zhCnLanguageProvider.name)
7
-
8
- export {
9
- language
10
- }
6
+ export const language = Locale.getLanguage<ZhCNLanguageProvider>(zhCnLanguageProvider.name)
@@ -1,6 +1,6 @@
1
1
  import { LanguageProvider } from '@vyr/locale'
2
2
 
3
- interface ZhCNLanguageProvider extends LanguageProvider {
3
+ export interface ZhCNLanguageProvider extends LanguageProvider {
4
4
  'descriptor.type.BoxGeometry': string
5
5
  'descriptor.type.CircleGeometry': string
6
6
  'descriptor.type.CylinderGeometry': string
@@ -28,13 +28,13 @@ interface ZhCNLanguageProvider extends LanguageProvider {
28
28
  'descriptor.type.PointLight': string
29
29
  'descriptor.type.RectAreaLight': string
30
30
  'descriptor.type.SpotLight': string
31
- 'descriptor.type.SceneService': string
31
+ 'descriptor.type.Scene3DService': string
32
32
  'descriptor.type.ComposerService': string
33
33
  'descriptor.type.Node': string
34
34
  'descriptor.type.Points': string
35
35
  'descriptor.type.Mesh': string
36
36
  'descriptor.type.InstancedMesh': string
37
- 'descriptor.type.Text': string
37
+ 'descriptor.type.Text3D': string
38
38
  'descriptor.type.Sprite': string
39
39
  'descriptor.type.Particle': string
40
40
  'descriptor.type.GeoMap': string
@@ -138,8 +138,8 @@ interface ZhCNLanguageProvider extends LanguageProvider {
138
138
  'footer.action.AddGeometry.label': string
139
139
  'footer.action.AddMaterial.label': string
140
140
  'footer.action.AddTexture.label': string
141
- 'sidebar.asset.action.AddAnimation.label': string
142
- 'sidebar.asset.action.AddLight.label': string
141
+ 'sidebar.action.AddAnimation.label': string
142
+ 'sidebar.action.AddLight.label': string
143
143
  'sidebar.scene.action.AddAnimation.label': string
144
144
  'sidebar.scene.action.AddLight.label': string
145
145
 
@@ -210,7 +210,7 @@ interface ZhCNLanguageProvider extends LanguageProvider {
210
210
  'inspector.Material.side': string
211
211
  'inspector.Material.blending': string
212
212
  'inspector.Material.depthTest': string
213
- 'inspector.Material.depthrWrite': string
213
+ 'inspector.Material.depthWrite': string
214
214
  'inspector.Material.vertexColors': string
215
215
 
216
216
  'inspector.Material.color': string
@@ -286,14 +286,14 @@ interface ZhCNLanguageProvider extends LanguageProvider {
286
286
  'inspector.Node.material.type': string
287
287
  'inspector.Node.material.index': string
288
288
 
289
- 'inspector.InstancedMesh.setting': string
289
+ 'inspector.InstancedMesh.data': string
290
290
 
291
- 'inspector.Text.font': string
292
- 'inspector.Text.size': string
293
- 'inspector.Text.maxWidth': string
294
- 'inspector.Text.lineHeight': string
295
- 'inspector.Text.letterSpacing': string
296
- 'inspector.Text.text': string
291
+ 'inspector.Text3D.font': string
292
+ 'inspector.Text3D.size': string
293
+ 'inspector.Text3D.maxWidth': string
294
+ 'inspector.Text3D.lineHeight': string
295
+ 'inspector.Text3D.letterSpacing': string
296
+ 'inspector.Text3D.text': string
297
297
 
298
298
  'inspector.Particle.count': string
299
299
  'inspector.Particle.track': string
@@ -317,7 +317,7 @@ interface ZhCNLanguageProvider extends LanguageProvider {
317
317
  'inspector.Service.shadowMap': string
318
318
  'inspector.Service.shadowMap.type': string
319
319
  'inspector.Service.shadowMap.update': string
320
- 'inspector.Service.background': string
320
+ 'inspector.Service.backgroundMap': string
321
321
  'inspector.Service.multisampling': string
322
322
  'inspector.Service.frameBufferType': string
323
323
  'inspector.Service.depthBuffer': string
@@ -326,7 +326,7 @@ interface ZhCNLanguageProvider extends LanguageProvider {
326
326
  'inspector.Sprite.center': string
327
327
  }
328
328
 
329
- const zhCnLanguageProvider: ZhCNLanguageProvider = {
329
+ export const zhCnLanguageProvider: ZhCNLanguageProvider = {
330
330
  id: 'zh_CN',
331
331
  name: '@vyr/three-browser',
332
332
 
@@ -357,13 +357,13 @@ const zhCnLanguageProvider: ZhCNLanguageProvider = {
357
357
  'descriptor.type.PointLight': '点光源',
358
358
  'descriptor.type.RectAreaLight': '矩形区域光',
359
359
  'descriptor.type.SpotLight': '聚光灯',
360
- 'descriptor.type.SceneService': '三维服务',
360
+ 'descriptor.type.Scene3DService': '三维服务',
361
361
  'descriptor.type.ComposerService': '后处理服务',
362
362
  'descriptor.type.Node': '三维节点',
363
363
  'descriptor.type.Points': '三维点',
364
364
  'descriptor.type.Mesh': '三维网格',
365
365
  'descriptor.type.InstancedMesh': '实例化网格',
366
- 'descriptor.type.Text': '三维字体',
366
+ 'descriptor.type.Text3D': '三维字体',
367
367
  'descriptor.type.Sprite': '精灵',
368
368
  'descriptor.type.Particle': '粒子',
369
369
  'descriptor.type.GeoMap': '几何地图',
@@ -467,8 +467,8 @@ const zhCnLanguageProvider: ZhCNLanguageProvider = {
467
467
  'footer.action.AddGeometry.label': '几何体',
468
468
  'footer.action.AddMaterial.label': '材质',
469
469
  'footer.action.AddTexture.label': '纹理',
470
- 'sidebar.asset.action.AddAnimation.label': '新增动画',
471
- 'sidebar.asset.action.AddLight.label': '新增光源',
470
+ 'sidebar.action.AddAnimation.label': '新增动画',
471
+ 'sidebar.action.AddLight.label': '新增光源',
472
472
  'sidebar.scene.action.AddAnimation.label': '新增动画',
473
473
  'sidebar.scene.action.AddLight.label': '新增光源',
474
474
 
@@ -539,7 +539,7 @@ const zhCnLanguageProvider: ZhCNLanguageProvider = {
539
539
  'inspector.Material.side': '类型',
540
540
  'inspector.Material.blending': '混合',
541
541
  'inspector.Material.depthTest': '深度测试',
542
- 'inspector.Material.depthrWrite': '深度写入',
542
+ 'inspector.Material.depthWrite': '深度写入',
543
543
  'inspector.Material.vertexColors': '顶点着色',
544
544
  'inspector.Material.color': '漫反射颜色',
545
545
  'inspector.Material.map': '漫反射贴图',
@@ -609,14 +609,14 @@ const zhCnLanguageProvider: ZhCNLanguageProvider = {
609
609
  'inspector.Node.material.type': '类型',
610
610
  'inspector.Node.material.index': '索引',
611
611
 
612
- 'inspector.InstancedMesh.setting': '实例化数据',
612
+ 'inspector.InstancedMesh.data': '实例化数据',
613
613
 
614
- 'inspector.Text.font': '字体家族',
615
- 'inspector.Text.size': '字体大小',
616
- 'inspector.Text.maxWidth': '最大宽度',
617
- 'inspector.Text.lineHeight': '文本行高',
618
- 'inspector.Text.letterSpacing': '文本间距',
619
- 'inspector.Text.text': '文本内容',
614
+ 'inspector.Text3D.font': '字体家族',
615
+ 'inspector.Text3D.size': '字体大小',
616
+ 'inspector.Text3D.maxWidth': '最大宽度',
617
+ 'inspector.Text3D.lineHeight': '文本行高',
618
+ 'inspector.Text3D.letterSpacing': '文本间距',
619
+ 'inspector.Text3D.text': '文本内容',
620
620
 
621
621
  'inspector.Particle.count': '粒子数量',
622
622
  'inspector.Particle.duration': '持续时间',
@@ -640,16 +640,11 @@ const zhCnLanguageProvider: ZhCNLanguageProvider = {
640
640
  'inspector.Service.shadowMap': '阴影贴图',
641
641
  'inspector.Service.shadowMap.type': '阴影类型',
642
642
  'inspector.Service.shadowMap.update': '阴影更新',
643
- 'inspector.Service.background': '背景贴图',
643
+ 'inspector.Service.backgroundMap': '背景贴图',
644
644
  'inspector.Service.multisampling': '采样率',
645
645
  'inspector.Service.frameBufferType': '缓冲帧',
646
646
  'inspector.Service.depthBuffer': '深度缓冲',
647
647
  'inspector.Service.stencilBuffer': '模板缓冲',
648
648
 
649
649
  'inspector.Sprite.center': '中心',
650
- }
651
-
652
- export {
653
- ZhCNLanguageProvider,
654
- zhCnLanguageProvider,
655
650
  }
@@ -1,17 +1,12 @@
1
1
  import { ActionBlendMode, ActionLoop } from '@vyr/three'
2
2
  import { language } from '../locale'
3
3
 
4
- const loopOptions = [
4
+ export const loopOptions = [
5
5
  { label: language.get('option.AnimationAction.loop.one'), value: ActionLoop.LoopOnce },
6
6
  { label: language.get('option.AnimationAction.loop.repeat'), value: ActionLoop.LoopRepeat },
7
7
  { label: language.get('option.AnimationAction.loop.recirculation'), value: ActionLoop.LoopPingPong },
8
8
  ]
9
- const blendModeOptions = [
9
+ export const blendModeOptions = [
10
10
  { label: language.get('option.AnimationAction.blendMode.norm'), value: ActionBlendMode.NormalAnimationBlendMode },
11
11
  { label: language.get('option.AnimationAction.blendMode.overlay'), value: ActionBlendMode.AdditiveAnimationBlendMode },
12
- ]
13
-
14
- export {
15
- loopOptions,
16
- blendModeOptions,
17
- }
12
+ ]
@@ -1,22 +1,16 @@
1
1
  import { language } from '../locale'
2
2
 
3
- const cylinderOptions = [
3
+ export const cylinderOptions = [
4
4
  { label: language.get('option.Geometry.cylinder.true'), value: true },
5
5
  { label: language.get('option.Geometry.cylinder.false'), value: false },
6
6
  ]
7
7
 
8
- const extrudeUvOptions = [
8
+ export const extrudeUvOptions = [
9
9
  { label: language.get('option.Geometry.extrudeUv.true'), value: true },
10
10
  { label: language.get('option.Geometry.extrudeUv.false'), value: false },
11
11
  ]
12
12
 
13
- const tubeOptions = [
13
+ export const tubeOptions = [
14
14
  { label: language.get('option.Geometry.tube.true'), value: true },
15
15
  { label: language.get('option.Geometry.tube.false'), value: false },
16
- ]
17
-
18
- export {
19
- cylinderOptions,
20
- extrudeUvOptions,
21
- tubeOptions,
22
- }
16
+ ]
@@ -1,29 +1,29 @@
1
1
  import { MaterialCombine, MaterialNormalMapType, MaterialSide, MaterialDlending,MaterialDepthFunc } from '@vyr/three'
2
2
  import { language } from '../locale'
3
3
 
4
- const combineOptions = [
4
+ export const combineOptions = [
5
5
  { label: language.get('option.Material.combine.multiply'), value: MaterialCombine.MultiplyOperation },
6
6
  { label: language.get('option.Material.combine.blend'), value: MaterialCombine.MixOperation },
7
7
  { label: language.get('option.Material.combine.add'), value: MaterialCombine.AddOperation },
8
8
  ]
9
- const normalTypeOptions = [
9
+ export const normalTypeOptions = [
10
10
  { label: language.get('option.Material.normalType.tangentialSpace'), value: MaterialNormalMapType.TangentSpaceNormalMap },
11
11
  { label: language.get('option.Material.normalType.objectSpace'), value: MaterialNormalMapType.ObjectSpaceNormalMap },
12
12
  ]
13
13
 
14
- const sideOptions = [
14
+ export const sideOptions = [
15
15
  { label: language.get('option.Material.side.back'), value: MaterialSide.BackSide },
16
16
  { label: language.get('option.Material.side.front'), value: MaterialSide.FrontSide },
17
17
  { label: language.get('option.Material.side.double'), value: MaterialSide.DoubleSide },
18
18
  ]
19
- const blendingOptions = [
19
+ export const blendingOptions = [
20
20
  { label: language.get('option.Material.blending.disabled'), value: MaterialDlending.NoBlending },
21
21
  { label: language.get('option.Material.blending.normal'), value: MaterialDlending.NormalBlending },
22
22
  { label: language.get('option.Material.blending.overlay'), value: MaterialDlending.AdditiveBlending },
23
23
  { label: language.get('option.Material.blending.subtractive'), value: MaterialDlending.SubtractiveBlending },
24
24
  { label: language.get('option.Material.blending.multiplicative'), value: MaterialDlending.MultiplyBlending },
25
25
  ]
26
- const depthFuncOptions = [
26
+ export const depthFuncOptions = [
27
27
  { label: language.get('option.Material.depthFunc.never'), value: MaterialDepthFunc.NeverDepth },
28
28
  { label: language.get('option.Material.depthFunc.always'), value: MaterialDepthFunc.AlwaysDepth },
29
29
  { label: language.get('option.Material.depthFunc.less'), value: MaterialDepthFunc.LessDepth },
@@ -31,12 +31,4 @@ const depthFuncOptions = [
31
31
  { label: language.get('option.Material.depthFunc.greater/equal'), value: MaterialDepthFunc.GreaterEqualDepth },
32
32
  { label: language.get('option.Material.depthFunc.greater'), value: MaterialDepthFunc.GreaterDepth },
33
33
  { label: language.get('option.Material.depthFunc.notEqual'), value: MaterialDepthFunc.NotEqualDepth },
34
- ]
35
-
36
- export {
37
- combineOptions,
38
- normalTypeOptions,
39
- sideOptions,
40
- blendingOptions,
41
- depthFuncOptions,
42
- }
34
+ ]
@@ -1,10 +1,6 @@
1
1
  import { language } from '../locale'
2
2
 
3
- const typeOptions = [
3
+ export const typeOptions = [
4
4
  { label: language.get('option.Mesh.type.one'), value: 1 },
5
5
  { label: language.get('option.Mesh.type.multiple'), value: 2 },
6
- ]
7
-
8
- export {
9
- typeOptions,
10
- }
6
+ ]
@@ -1,18 +1,13 @@
1
1
  import { SceneShadow } from '@vyr/three'
2
2
  import { language } from '../locale'
3
3
 
4
- const typeOptions = [
4
+ export const typeOptions = [
5
5
  { label: language.get('option.shadow.type.basicShadowMap'), value: SceneShadow.BasicShadowMap },
6
6
  { label: language.get('option.shadow.type.PCFShadowMap'), value: SceneShadow.PCFShadowMap },
7
7
  { label: language.get('option.shadow.type.PCFSoftShadowMap'), value: SceneShadow.PCFSoftShadowMap },
8
8
  { label: language.get('option.shadow.type.VSMShadowMap'), value: SceneShadow.VSMShadowMap },
9
9
  ]
10
- const updateOptions = [
10
+ export const updateOptions = [
11
11
  { label: language.get('option.shadow.update.manual'), value: false },
12
12
  { label: language.get('option.shadow.update.auto'), value: true },
13
- ]
14
-
15
- export {
16
- typeOptions,
17
- updateOptions,
18
- }
13
+ ]
@@ -1,7 +1,7 @@
1
1
  import { TextureMapping, TextureWrap, TextureFType, TextureFormat, TextureColorSpace } from '@vyr/three'
2
2
  import { language } from '../locale'
3
3
 
4
- const mappingOptions = [
4
+ export const mappingOptions = [
5
5
  { label: language.get('option.Texture.mapping.UVMapping'), value: TextureMapping.UVMapping },
6
6
  { label: language.get('option.Texture.mapping.cubeReflectionMapping'), value: TextureMapping.CubeReflectionMapping },
7
7
  { label: language.get('option.Texture.mapping.cubeRefractionMapping'), value: TextureMapping.CubeRefractionMapping },
@@ -9,12 +9,12 @@ const mappingOptions = [
9
9
  { label: language.get('option.Texture.mapping.equirectangularRefractionMapping'), value: TextureMapping.EquirectangularRefractionMapping },
10
10
  { label: language.get('option.Texture.mapping.cubeUVReflectionMapping'), value: TextureMapping.CubeUVReflectionMapping },
11
11
  ]
12
- const wrapOptions = [
12
+ export const wrapOptions = [
13
13
  { label: language.get('option.Texture.wrap.repeatWrapping'), value: TextureWrap.RepeatWrapping },
14
14
  { label: language.get('option.Texture.wrap.clampToEdgeWrapping'), value: TextureWrap.ClampToEdgeWrapping },
15
15
  { label: language.get('option.Texture.wrap.mirroredRepeatWrapping'), value: TextureWrap.MirroredRepeatWrapping },
16
16
  ]
17
- const ftypeOptions = [
17
+ export const ftypeOptions = [
18
18
  { label: language.get('option.Texture.ftype.unsignedByteType'), value: TextureFType.UnsignedByteType },
19
19
  { label: language.get('option.Texture.ftype.byteType'), value: TextureFType.ByteType },
20
20
  { label: language.get('option.Texture.ftype.shortType'), value: TextureFType.ShortType },
@@ -28,7 +28,7 @@ const ftypeOptions = [
28
28
  { label: language.get('option.Texture.ftype.unsignedInt248Type'), value: TextureFType.UnsignedInt248Type },
29
29
  { label: language.get('option.Texture.ftype.unsignedInt5999Type'), value: TextureFType.UnsignedInt5999Type },
30
30
  ]
31
- const formatOptions = [
31
+ export const formatOptions = [
32
32
  { label: language.get('option.Texture.format.alphaFormat'), value: TextureFormat.AlphaFormat },
33
33
  { label: language.get('option.Texture.format.redFormat'), value: TextureFormat.RedFormat },
34
34
  { label: language.get('option.Texture.format.redIntegerFormat'), value: TextureFormat.RedIntegerFormat },
@@ -40,16 +40,8 @@ const formatOptions = [
40
40
  { label: language.get('option.Texture.format.depthFormat'), value: TextureFormat.DepthFormat },
41
41
  { label: language.get('option.Texture.format.depthStencilFormat'), value: TextureFormat.DepthStencilFormat },
42
42
  ]
43
- const colorSpaceOptions = [
43
+ export const colorSpaceOptions = [
44
44
  { label: language.get('option.Texture.colorSpace.no'), value: TextureColorSpace.NoColorSpace },
45
45
  { label: language.get('option.Texture.colorSpace.SRGB'), value: TextureColorSpace.SRGBColorSpace },
46
46
  { label: language.get('option.Texture.colorSpace.linearSRGB'), value: TextureColorSpace.LinearSRGBColorSpace },
47
- ]
48
-
49
- export {
50
- mappingOptions,
51
- wrapOptions,
52
- ftypeOptions,
53
- formatOptions,
54
- colorSpaceOptions,
55
- }
47
+ ]