Explorar o código

Fix #1113: Correct default slugCallback

Kartik Visweswaran %!s(int64=7) %!d(string=hai) anos
pai
achega
f7a3e44354
Modificáronse 3 ficheiros con 2 adicións e 1 borrados
  1. 1 0
      CHANGE.md
  2. 1 1
      js/fileinput.js
  3. 0 0
      js/fileinput.min.js

+ 1 - 0
CHANGE.md

@@ -5,6 +5,7 @@ Change Log: `bootstrap-fileinput`
 
 **Date:** Work in progress
 
+- (enh #1113): Correct slug default callback to include hyphens in file name.
 - (enh #1111): Enhance default file download action to use `button` markup.
 - (enh #1110): Add support for previewing TIFF, EPS, AI, WMF files.
 - (bug #1108): Correct sortable drag element parsing during sorting.

+ 1 - 1
js/fileinput.js

@@ -2822,7 +2822,7 @@
             }
         },
         _slugDefault: function (text) {
-            return $h.isEmpty(text) ? '' : String(text).replace(/[\-\[\]\/\{}:;#%=\(\)\*\+\?\\\^\$\|<>&"']/g, '_');
+            return $h.isEmpty(text) ? '' : String(text).replace(/[\[\]\/\{}:;#%=\(\)\*\+\?\\\^\$\|<>&"']/g, '_');
         },
         _readFiles: function (files) {
             this.reader = new FileReader();

A diferenza do arquivo foi suprimida porque é demasiado grande
+ 0 - 0
js/fileinput.min.js


Algúns arquivos non se mostraron porque demasiados arquivos cambiaron neste cambio