mirror of
https://github.com/github/semantic.git
synced 2025-01-03 04:51:57 +03:00
Syntax highlight categories.
This commit is contained in:
parent
867772d749
commit
0775f90ce4
@ -136,7 +136,7 @@ type SplitDiff leaf annotation = Free (Annotated leaf annotation) (Term leaf ann
|
||||
newtype Renderable a = Renderable (String, a)
|
||||
|
||||
instance ToMarkup f => ToMarkup (Renderable (Info, Syntax a (f, Range))) where
|
||||
toMarkup (Renderable (source, (Info range categories, syntax))) = classifyMarkup (maybeLast categories) $ case syntax of
|
||||
toMarkup (Renderable (source, (Info range categories, syntax))) = classifyMarkup (classify categories) $ case syntax of
|
||||
Leaf _ -> span . string $ substring range source
|
||||
Indexed children -> ul . mconcat $ contentElements children
|
||||
Fixed children -> ul . mconcat $ contentElements children
|
||||
|
Loading…
Reference in New Issue
Block a user