Browse Source

prevent extra \n at end of single notes #3010

hakimel 2 năm trước cách đây
mục cha
commit
8a97ad58b0
5 tập tin đã thay đổi với 1 bổ sung5 xóa
  1. 0 0
      dist/reveal.esm.js
  2. 0 0
      dist/reveal.esm.js.map
  3. 0 0
      dist/reveal.js
  4. 0 0
      dist/reveal.js.map
  5. 1 5
      js/controllers/notes.js

Những thai đổi đã bị hủy bỏ vì nó quá lớn
+ 0 - 0
dist/reveal.esm.js


Những thai đổi đã bị hủy bỏ vì nó quá lớn
+ 0 - 0
dist/reveal.esm.js.map


Những thai đổi đã bị hủy bỏ vì nó quá lớn
+ 0 - 0
dist/reveal.js


Những thai đổi đã bị hủy bỏ vì nó quá lớn
+ 0 - 0
dist/reveal.js.map


+ 1 - 5
js/controllers/notes.js

@@ -104,11 +104,7 @@ export default class Notes {
 		// ... or using <aside class="notes"> elements
 		let notesElements = slide.querySelectorAll( 'aside.notes' );
 		if( notesElements ) {
-			let notes = "";
-			for (let i = 0; i < notesElements.length; i++) {
-				notes += notesElements[i].innerHTML + "\n";
-			}
-			return notes;
+			return Array.from(notesElements).map( notesElement => notesElement.innerHTML ).join( '\n' );
 		}
 
 		return null;

Một số tệp đã không được hiển thị bởi vì quá nhiều tập tin thay đổi trong này khác