module Data.Char.Ligature where
import Prelude hiding (concatMap)
import Data.Text.Lazy
expandLigature :: Char -> Text
expandLigature '\xFB00' = cons 'f' (cons 'f' empty)
expandLigature '\xFB01' = cons 'f' (cons 'i' empty)
expandLigature '\xFB02' = cons 'f' (cons 'l' empty)
expandLigature '\xFB03' = cons 'f' (cons 'f' (cons 'i' empty))
expandLigature '\xFB04' = cons 'f' (cons 'f' (cons 'l' empty))
expandLigature '\xFB05' = cons 'f' (cons 't' empty)
expandLigature '\xFB06' = cons 's' (cons 't' empty)
expandLigature c = singleton c
expand :: Text -> Text
expand txt = concatMap expandLigature txt