aframe-troika-text
Advanced tools
Comparing version 0.2.2 to 0.3.1
{ | ||
"name": "aframe-troika-text", | ||
"version": "0.2.2", | ||
"version": "0.3.1", | ||
"description": "An A-Frame component to render text using the Troika 3D text renderer ", | ||
@@ -12,3 +12,3 @@ "main": "dist/aframe-troika-text.js", | ||
"dependencies": { | ||
"troika-3d-text": "0.17.0" | ||
"troika-3d-text": "^0.24.0" | ||
}, | ||
@@ -19,7 +19,7 @@ "peerDependencies": { | ||
"devDependencies": { | ||
"aframe": "1.0.4", | ||
"rollup": "1.31.0", | ||
"rollup-plugin-node-resolve": "5.2.0", | ||
"rollup-plugin-terser": "5.2.0" | ||
"aframe": "^1.0.4", | ||
"rollup": "^2.7.6", | ||
"rollup-plugin-node-resolve": "^5.2.0", | ||
"rollup-plugin-terser": "^5.3.0" | ||
} | ||
} |
@@ -73,3 +73,3 @@ ## aframe-troika-text | ||
<title>My A-Frame Scene</title> | ||
<script src="https://aframe.io/releases/1.0.3/aframe.min.js"></script> | ||
<script src="https://aframe.io/releases/1.0.4/aframe.min.js"></script> | ||
<script src="https://unpkg.com/aframe-troika-text/dist/aframe-troika-text.min.js"></script> | ||
@@ -76,0 +76,0 @@ </head> |
@@ -0,0 +0,0 @@ { |
@@ -0,0 +0,0 @@ import nodeResolve from 'rollup-plugin-node-resolve' |
@@ -87,4 +87,5 @@ import aframe from 'aframe' | ||
mesh.textAlign = data.align | ||
mesh.anchor[0] = anchorMapping[data.anchor] | ||
mesh.anchor[1] = baselineMapping[data.baseline] | ||
mesh.anchorX = anchorMapping[data.anchor === 'align' ? data.align : data.anchor] || 'center' | ||
mesh.anchorY = baselineMapping[data.baseline] || 'middle' | ||
mesh.color = data.color | ||
@@ -131,11 +132,11 @@ mesh.clipRect = data.clipRect | ||
var anchorMapping = { | ||
'left': 0, | ||
'center': 0.5, | ||
'right': 1 | ||
'left': 'left', | ||
'center': 'center', | ||
'right': 'right' | ||
} | ||
var baselineMapping = { | ||
'top': 0, | ||
'center': 0.5, | ||
'bottom': 1 | ||
'top': 'top', | ||
'center': 'middle', | ||
'bottom': 'bottom' | ||
} | ||
@@ -0,0 +0,0 @@ import aframe from 'aframe' |
import './aframe-troika-text-component.js' | ||
import './aframe-troika-text-primitive.js' |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
660761
5885
+ Addedthree@0.115.0(transitive)
+ Addedtroika-3d@0.24.0(transitive)
+ Addedtroika-3d-text@0.24.1(transitive)
+ Addedtroika-animation@0.24.0(transitive)
+ Addedtroika-core@0.24.0(transitive)
+ Addedtroika-three-utils@0.24.0(transitive)
+ Addedtroika-worker-utils@0.24.0(transitive)
- Removedthree@0.112.1(transitive)
- Removedtroika-3d@0.17.1(transitive)
- Removedtroika-3d-text@0.17.0(transitive)
- Removedtroika-animation@0.17.1(transitive)
- Removedtroika-core@0.17.1(transitive)
- Removedtroika-three-utils@0.17.1(transitive)
- Removedtroika-worker-utils@0.17.1(transitive)
Updatedtroika-3d-text@^0.24.0