Sfoglia il codice sorgente

Make the build pass again by trimming line length

Kevin van Zonneveld 9 anni fa
parent
commit
cdb4e6ad6f
3 ha cambiato i file con 7 aggiunte e 4 eliminazioni
  1. 0 1
      src/locale/ru.js
  2. 2 1
      src/plugins/DragDrop.js
  3. 5 2
      src/plugins/Dropbox.js

+ 0 - 1
src/locale/ru.js

@@ -4,7 +4,6 @@ ru.strings = {
   'choose_file': 'Выберите файл',
   'or_drag_drop': 'или перенесите его сюда',
   'you_have_chosen': 'Вы выбрали: %{file_name}',
-  // 'files_chosen': 'выбран %{smart_count} файл |||| выбрано %{smart_count} файла |||| выбрано %{smart_count} файлов'
   'files_chosen': {
     0: 'Выбран %{smart_count} файл',
     1: 'Выбрано %{smart_count} файла',

+ 2 - 1
src/plugins/DragDrop.js

@@ -66,7 +66,8 @@ export default class DragDrop extends Plugin {
     }
 
     // prevent default actions for all drag & drop events
-    Utils.addListenerMulti(this.dropzone, 'drag dragstart dragend dragover dragenter dragleave drop', (e) => {
+    const strEvents = 'drag dragstart dragend dragover dragenter dragleave drop'
+    Utils.addListenerMulti(this.dropzone, strEvents, (e) => {
       e.preventDefault()
       e.stopPropagation()
     })

+ 5 - 2
src/plugins/Dropbox.js

@@ -53,14 +53,17 @@ export default class Dropbox extends Plugin {
   }
 
   run(results) {
-    
+
   }
 
   render(files) {
     // for each file in the directory, create a list item element
     const elems = files.map((file, i) => {
       const icon = (file.isFolder) ? 'folder' : 'file'
-      return `<li data-type="${icon}" data-name="${file.name}"><span>${icon} : </span><span> ${file.name}</span></li>`
+      return `<li data-type="${icon}" data-name="${file.name}">
+        <span>${icon} : </span>
+        <span> ${file.name}</span>
+      </li>`
     })
 
     // appends the list items to the target