Skip to content
Snippets Groups Projects
Commit 29626b08 authored by Robert Speicher's avatar Robert Speicher
Browse files

Remove unused `showAndHide`, `simpleFormat`, and `linkify` functions

Also removes redundant `unbind` call
parent 39d5a487
No related branches found
No related tags found
No related merge requests found
Loading
Loading
@@ -49,8 +49,6 @@ window.slugify = (text) ->
window.ajaxGet = (url) ->
$.ajax({type: "GET", url: url, dataType: "script"})
 
window.showAndHide = (selector) ->
window.split = (val) ->
return val.split( /,\s*/ )
 
Loading
Loading
@@ -92,15 +90,7 @@ window.disableButtonIfAnyEmptyField = (form, form_selector, button_selector) ->
window.sanitize = (str) ->
return str.replace(/<(?:.|\n)*?>/gm, '')
 
window.linkify = (str) ->
exp = /(\b(https?|ftp|file):\/\/[-A-Z0-9+&@#\/%?=~_|!:,.;]*[-A-Z0-9+&@#\/%=~_|])/ig
return str.replace(exp,"<a href='$1'>$1</a>")
window.simpleFormat = (str) ->
linkify(sanitize(str).replace(/\n/g, '<br />'))
window.unbindEvents = ->
$(document).unbind('scroll')
$(document).off('scroll')
 
window.shiftWindow = ->
Loading
Loading
$.fn.showAndHide = ->
$(@).show().
delay(3000).
fadeOut()
# Disable an element and add the 'disabled' Bootstrap class
$.fn.extend disable: ->
$(@)
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment