Add square roots (\sqrt)

Summary:
Follow the TeXbook instructions on how to construct square roots. Using
makeCustomSizedDelim, this becomes nearly trivial.

Test Plan:
 - Make sure normal tests work
 - Make sure the new huxley test looks good, and other huxley tests haven't changed.

Reviewers: alpert

Reviewed By: alpert

Differential Revision: http://phabricator.khanacademy.org/D12918
This commit is contained in:
Emily Eisenberg
2014-09-06 15:08:23 -07:00
parent 5a94faac9e
commit 925c96dbe2
9 changed files with 164 additions and 2 deletions

View File

@@ -350,6 +350,46 @@ big parens
}
}
.sqrt {
> .sqrt-sign {
position: relative;
}
> .sqrt-body {
.baseline-align-hack-outer;
> .sqrt-line,
> .sqrt-inner,
> .fix-ie {
.baseline-align-hack-middle;
position: relative;
> span {
.baseline-align-hack-inner;
}
}
> .sqrt-line > .line {
width: 100%;
&:before {
border-bottom-style: solid;
border-bottom-width: 1px;
content: "";
display: block;
}
&:after {
border-bottom-style: solid;
border-bottom-width: 0.04em;
content: "";
display: block;
margin-top: -1px;
}
}
}
}
.sizing, .fontsize-ensurer {
display: inline-block;