edgeToSVG :: Bool -> Path -> S.Svg
edgeToSVG styled path =
    S.path ! A.id_ (stringValue $ "path" ++ pathId_ path)
           ! A.class_ "path"
           ! A.d (stringValue $ 'M' : buildPathString (pathPoints path))
           ! A.markerEnd "url(#arrow)"
           ! S.customAttribute "data-source-node" (stringValue $ sanitizeId
                                                          $ pathSource path)
           ! S.customAttribute "data-target-node" (stringValue $ sanitizeId
                                                          $ pathTarget path)
           ! if styled
             then
                 mappend
                     (A.strokeWidth "2px") $
                     A.style (stringValue $ "fill:" ++
                          pathFill path ++
                          ";fill-opacity:1;")
             else
                 mempty
edgeToSVG :: Bool -> Path -> S.Svg
edgeToSVG styled path =
    S.path ! A.id_ (stringValue $ "path" ++ pathId_ path)
           ! A.class_ "path"
           ! A.d (stringValue $ 'M' : buildPathString (pathPoints path))
           ! A.markerEnd "url(#arrow)"
           ! S.customAttribute "data-source-node" (stringValue $ sanitizeId
                                                          $ pathSource path)
           ! S.customAttribute "data-target-node" (stringValue $ sanitizeId
                                                          $ pathTarget path)
           ! if styled
             then
                 mappend
                     (A.strokeWidth "2px") $
                     A.style (stringValue $ "fill:" ++
                          pathFill path ++
                          ";fill-opacity:1;")
             else
                 mempty
edgeToSVG styled path =
    S.path ! A.id_ (stringValue $ "path" ++ pathId_ path)
           ! A.class_ "path"
           ! A.d (stringValue $ 'M' : buildPathString (pathPoints path))
           ! A.markerEnd "url(#arrow)"
           ! S.customAttribute "data-source-node" (stringValue $ sanitizeId
                                                          $ pathSource path)
           ! S.customAttribute "data-target-node" (stringValue $ sanitizeId
                                                          $ pathTarget path)
           ! if styled
             then
                 mappend
                     (A.strokeWidth "2px") $
                     A.style (stringValue $ "fill:" ++
                          pathFill path ++
                          ";fill-opacity:1;")
             else
                 mempty