1
1
mirror of https://github.com/github/semantic.git synced 2024-12-18 20:31:55 +03:00

Remove maybeFirstNewLine

This commit is contained in:
joshvera 2015-12-09 18:50:31 -05:00
parent 40cc463a90
commit 79d8924b58

View File

@ -27,15 +27,6 @@ data HTML =
| Dt String
deriving (Show, Eq)
maybeFirstNewLine :: HTML -> Maybe HTML
maybeFirstNewLine text@(Text "") = Just text
maybeFirstNewLine text@(Text _) = Nothing
maybeFirstNewLine (Span _ _) = Nothing
maybeFirstNewLine (Dt _) = Nothing
maybeFirstNewLine (Ul _ elements) = getFirst $ mconcat $ map First $ map maybeFirstNewLine elements
maybeFirstNewLine (Dl _ elements) = getFirst $ mconcat $ map First $ map maybeFirstNewLine elements
maybeFirstNewLine (Div _ elements) = getFirst $ mconcat $ map First $ map maybeFirstNewLine elements
classifyMarkup :: Maybe ClassName -> Markup -> Markup
classifyMarkup (Just className) element = element ! A.class_ (stringValue className)
classifyMarkup _ element = element