Skip to content

Commit

Permalink
fix example
Browse files Browse the repository at this point in the history
  • Loading branch information
antoniohof committed Feb 8, 2019
1 parent 334ba84 commit b1f3b88
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
2 changes: 1 addition & 1 deletion example/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
</a-assets>

<a-sky src="#lake"></a-sky>
<a-entity text-texture="text: Texture Based Text with accented characters (á, ã, â...); scale: 1.0" position="0 0 -10"> </a-entity>
<a-entity text-texture="text: Texture Based Text with accented characters (á, ã, â...); scale: 1.0; fillStyle: White" position="0 0 -10"> </a-entity>
</a-scene>
</body>
</html>
5 changes: 3 additions & 2 deletions src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ AFRAME.registerComponent("text-texture", {
type: "number"
},
fillStyle: {
default: "#fffff",
default: "#fef9ff",
type: "color"
},
lineWidth: {
Expand All @@ -56,7 +56,7 @@ AFRAME.registerComponent("text-texture", {
type: "number"
},
strokeStyle: {
default: "#fffff",
default: "#fef9ff",
type: "color"
},
opacity: {
Expand Down Expand Up @@ -96,6 +96,7 @@ AFRAME.registerComponent("text-texture", {
this.geometry = new THREE.PlaneGeometry(1, 1, 1);
this.mesh = new THREE.Mesh(this.geometry, this.material);
this.el.setObject3D("mesh", this.mesh);
this.textTexture.fillStyle = this.data.fillStyle;
},
play: function() {},
update: function(oldData) {
Expand Down

0 comments on commit b1f3b88

Please sign in to comment.