abstract-3d 0.2.1 → 0.2.2
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.
|
@@ -32,32 +32,32 @@ exports.toReact = (0, react_1.memo)(({ scene, selectedId, activeHotSpots, active
|
|
|
32
32
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u, _v, _w, _x, _y, _z, _0, _1, _2, _3, _4, _5;
|
|
33
33
|
return (react_1.default.createElement(fiber_1.Canvas, Object.assign({ dpr: [1, window.devicePixelRatio], frameloop: "demand" }, canvasProps),
|
|
34
34
|
react_1.default.createElement(react_camera_1.ReactCamera, { scene: scene, useAnimations: useAnimations, camera: camera, view: view, controlsHelper: controlsHelper, orbitContolsProps: orbitContolsProps }),
|
|
35
|
-
react_1.default.createElement("ambientLight", { intensity:
|
|
35
|
+
react_1.default.createElement("ambientLight", { intensity: 3 }),
|
|
36
36
|
react_1.default.createElement("directionalLight", { position: [
|
|
37
37
|
-((_b = (_a = scene.center_deprecated) === null || _a === void 0 ? void 0 : _a.x) !== null && _b !== void 0 ? _b : 0),
|
|
38
38
|
-((_d = (_c = scene.center_deprecated) === null || _c === void 0 ? void 0 : _c.y) !== null && _d !== void 0 ? _d : 0) + 1.5 * scene.size_deprecated.y,
|
|
39
39
|
-((_f = (_e = scene.center_deprecated) === null || _e === void 0 ? void 0 : _e.z) !== null && _f !== void 0 ? _f : 0),
|
|
40
|
-
], intensity: 0.
|
|
40
|
+
], intensity: 0.4 }),
|
|
41
41
|
react_1.default.createElement("directionalLight", { position: [
|
|
42
42
|
-((_h = (_g = scene.center_deprecated) === null || _g === void 0 ? void 0 : _g.x) !== null && _h !== void 0 ? _h : 0),
|
|
43
43
|
-((_k = (_j = scene.center_deprecated) === null || _j === void 0 ? void 0 : _j.y) !== null && _k !== void 0 ? _k : 0),
|
|
44
44
|
-((_m = (_l = scene.center_deprecated) === null || _l === void 0 ? void 0 : _l.z) !== null && _m !== void 0 ? _m : 0) + 1.5 * scene.size_deprecated.z,
|
|
45
|
-
], intensity: 0.
|
|
45
|
+
], intensity: 0.4 }),
|
|
46
46
|
react_1.default.createElement("directionalLight", { position: [
|
|
47
47
|
-((_p = (_o = scene.center_deprecated) === null || _o === void 0 ? void 0 : _o.x) !== null && _p !== void 0 ? _p : 0),
|
|
48
48
|
-((_r = (_q = scene.center_deprecated) === null || _q === void 0 ? void 0 : _q.y) !== null && _r !== void 0 ? _r : 0),
|
|
49
49
|
-((_t = (_s = scene.center_deprecated) === null || _s === void 0 ? void 0 : _s.z) !== null && _t !== void 0 ? _t : 0) - 1.5 * scene.size_deprecated.z,
|
|
50
|
-
], intensity: 0.
|
|
50
|
+
], intensity: 0.4 }),
|
|
51
51
|
react_1.default.createElement("directionalLight", { position: [
|
|
52
52
|
-((_v = (_u = scene.center_deprecated) === null || _u === void 0 ? void 0 : _u.x) !== null && _v !== void 0 ? _v : 0) - 1.5 * scene.size_deprecated.x,
|
|
53
53
|
-((_x = (_w = scene.center_deprecated) === null || _w === void 0 ? void 0 : _w.y) !== null && _x !== void 0 ? _x : 0),
|
|
54
54
|
-((_z = (_y = scene.center_deprecated) === null || _y === void 0 ? void 0 : _y.z) !== null && _z !== void 0 ? _z : 0),
|
|
55
|
-
], intensity: 0.
|
|
55
|
+
], intensity: 0.4 }),
|
|
56
56
|
react_1.default.createElement("directionalLight", { position: [
|
|
57
57
|
-((_1 = (_0 = scene.center_deprecated) === null || _0 === void 0 ? void 0 : _0.x) !== null && _1 !== void 0 ? _1 : 0) + 1.5 * scene.size_deprecated.x,
|
|
58
58
|
-((_3 = (_2 = scene.center_deprecated) === null || _2 === void 0 ? void 0 : _2.y) !== null && _3 !== void 0 ? _3 : 0),
|
|
59
59
|
-((_5 = (_4 = scene.center_deprecated) === null || _4 === void 0 ? void 0 : _4.z) !== null && _5 !== void 0 ? _5 : 0),
|
|
60
|
-
], intensity: 0.
|
|
60
|
+
], intensity: 0.4 }),
|
|
61
61
|
react_1.default.createElement(react_1.default.Suspense, { fallback: react_1.default.createElement(react_1.default.Fragment, null) },
|
|
62
62
|
react_1.default.createElement(react_scene_1.ReactScene, { scene: scene, selectedId: selectedId, activeHotSpots: activeHotSpots, activeComponents: activeComponents, showDimensions: showDimensions, showHotSpotTexts: showHotSpotTexts, hoveredIdExternal: hoveredIdExternal, hotSpotTexts: hotSpotTexts, materialStateImages: materialStateImages, onClickGroup: onClickGroup, onContextMenuGroup: onContextMenuGroup, onClickHotSpot: onClickHotSpot, createGroupKey: createGroupKey, createGroupId: createGroupId }))));
|
|
63
63
|
});
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "abstract-3d",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.2",
|
|
4
4
|
"description": "Abstract 3D",
|
|
5
5
|
"author": "Divid AB <info@divid.se>",
|
|
6
6
|
"repository": "https://github.com/dividab/abstract-visuals/tree/master/packages/abstract-3d",
|
|
@@ -27,5 +27,5 @@
|
|
|
27
27
|
"@types/react-reconciler": "^0.28.8",
|
|
28
28
|
"@types/three": "0.165.0"
|
|
29
29
|
},
|
|
30
|
-
"gitHead": "
|
|
30
|
+
"gitHead": "35beb28527e5b525c8edf8dca1c276b385437694"
|
|
31
31
|
}
|
|
@@ -78,14 +78,14 @@ export const toReact = memo(
|
|
|
78
78
|
controlsHelper={controlsHelper}
|
|
79
79
|
orbitContolsProps={orbitContolsProps}
|
|
80
80
|
/>
|
|
81
|
-
<ambientLight intensity={
|
|
81
|
+
<ambientLight intensity={3} />
|
|
82
82
|
<directionalLight
|
|
83
83
|
position={[
|
|
84
84
|
-(scene.center_deprecated?.x ?? 0),
|
|
85
85
|
-(scene.center_deprecated?.y ?? 0) + 1.5 * scene.size_deprecated.y,
|
|
86
86
|
-(scene.center_deprecated?.z ?? 0),
|
|
87
87
|
]}
|
|
88
|
-
intensity={0.
|
|
88
|
+
intensity={0.4}
|
|
89
89
|
/>
|
|
90
90
|
<directionalLight
|
|
91
91
|
position={[
|
|
@@ -93,7 +93,7 @@ export const toReact = memo(
|
|
|
93
93
|
-(scene.center_deprecated?.y ?? 0),
|
|
94
94
|
-(scene.center_deprecated?.z ?? 0) + 1.5 * scene.size_deprecated.z,
|
|
95
95
|
]}
|
|
96
|
-
intensity={0.
|
|
96
|
+
intensity={0.4}
|
|
97
97
|
/>
|
|
98
98
|
<directionalLight
|
|
99
99
|
position={[
|
|
@@ -101,7 +101,7 @@ export const toReact = memo(
|
|
|
101
101
|
-(scene.center_deprecated?.y ?? 0),
|
|
102
102
|
-(scene.center_deprecated?.z ?? 0) - 1.5 * scene.size_deprecated.z,
|
|
103
103
|
]}
|
|
104
|
-
intensity={0.
|
|
104
|
+
intensity={0.4}
|
|
105
105
|
/>
|
|
106
106
|
<directionalLight
|
|
107
107
|
position={[
|
|
@@ -109,7 +109,7 @@ export const toReact = memo(
|
|
|
109
109
|
-(scene.center_deprecated?.y ?? 0),
|
|
110
110
|
-(scene.center_deprecated?.z ?? 0),
|
|
111
111
|
]}
|
|
112
|
-
intensity={0.
|
|
112
|
+
intensity={0.4}
|
|
113
113
|
/>
|
|
114
114
|
<directionalLight
|
|
115
115
|
position={[
|
|
@@ -117,7 +117,7 @@ export const toReact = memo(
|
|
|
117
117
|
-(scene.center_deprecated?.y ?? 0),
|
|
118
118
|
-(scene.center_deprecated?.z ?? 0),
|
|
119
119
|
]}
|
|
120
|
-
intensity={0.
|
|
120
|
+
intensity={0.4}
|
|
121
121
|
/>
|
|
122
122
|
<React.Suspense fallback={<></>}>
|
|
123
123
|
<ReactScene
|