remove unused code

This commit is contained in:
Stoeffel 2018-02-28 14:18:40 -08:00
parent 158b23d392
commit 9c15a068f6

View File

@ -65,34 +65,3 @@ makeQuizFont size fontColor =
{ class } =
styles
{-| Eliminate widows (single words on their own line caused by
wrapping) by inserting a non-breaking space if there are at least two
words.
-}
noWidow : String -> String
noWidow inputs =
let
-- this value is a unicode non-breaking space since Elm
-- doesn't support named character entities
nbsp =
" "
words =
String.split " " inputs
insertPoint =
List.length words - 1
in
words
|> List.indexedMap
(\i word ->
if i == 0 then
word
else if i == insertPoint && insertPoint > 0 then
nbsp ++ word
else
" " ++ word
)
|> String.join ""