Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Don't inherit SVG style properties from the environment. #1089

Merged
merged 3 commits into from Jan 25, 2018
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
29 changes: 23 additions & 6 deletions static/katex.less
Expand Up @@ -441,13 +441,30 @@
position: absolute; // absolute relative to parent
width: 100%;

path {
fill: currentColor;
}
// We want to inherit colors from our environment
fill: currentColor;
stroke: currentColor;

line {
stroke: currentColor;
}
// But path elements should not have an outline by default
// that would make them bigger than we expect.
path {
stroke: none;
}

// And we don't want to inherit any other style properties
// that could affect SVG rendering without affecting font
// rendering. So we reset these properties to their default
// values for every <svg> element.
// See https://www.w3.org/TR/SVG/painting.html
fill-rule: nonzero;
fill-opacity: 1;
stroke-width: 1;
stroke-linecap: butt;
stroke-linejoin: miter;
stroke-miterlimit: 4;
stroke-dasharray: none;
stroke-dashoffset: 0;
stroke-opacity: 1;
}

.vertical-separator svg {
Expand Down