diff --git a/MJLite.js b/MJLite.js index b024e3340..1d744cee1 100644 --- a/MJLite.js +++ b/MJLite.js @@ -88,6 +88,8 @@ var buildGroup = function(group, prev) { return makeSpan("rlap", inner); } else if (group.type === "punct") { return makeSpan("mpunct", textit(group.value)); + } else if (group.type === "ordgroup") { + return makeSpan("mord", buildExpression(group.value)); } else { console.log("Unknown type:", group.type); } diff --git a/parser.jison b/parser.jison index 0c14f24f4..ed3709c36 100644 --- a/parser.jison +++ b/parser.jison @@ -36,7 +36,7 @@ group : atom {$$ = $1;} | '{' ex '}' - {$$ = $2;} + {$$ = [{type: 'ordgroup', value: $2}];} | func {$$ = $1;} ;