Browse Source

Display correct element number.

Per a suggestion on the Google+ post about this example, this change fixes the incorrect element numbers displayed on the table.
Robert 11 năm trước cách đây
mục cha
commit
87870ec83a
1 tập tin đã thay đổi với 1 bổ sung1 xóa
  1. 1 1
      examples/css3d_periodictable.html

+ 1 - 1
examples/css3d_periodictable.html

@@ -262,7 +262,7 @@
 
 					var number = document.createElement( 'div' );
 					number.className = 'number';
-					number.textContent = i + 1;
+					number.textContent = (i/5) + 1;
 					element.appendChild( number );
 
 					var symbol = document.createElement( 'div' );