chevrotain
chevrotain copied to clipboard
diagrams.css should be scoped
Everything in diagrams.css should be scoped to some wrapping css class, because as is it cannot be bundled with the rest of an app's css because of styles like this:
div {
-webkit-touch-callout: none;
-webkit-user-select: none;
-khtml-user-select: none;
-moz-user-select: none;
-ms-user-select: none;
user-select: none;
}
svg {
width: 100%;
}
Currently the only way to bundle it is a partial copy-paste.
Thanks for reporting this @AccessViolator .
I believe this may be simple to fix. I will mark it as "Help Wanted"
Although am not sure where the relevant Div
is created when generating the diagrams html source...
Relevant "places" to start:
- https://github.com/SAP/chevrotain/tree/master/packages/chevrotain/diagrams
- https://github.com/SAP/chevrotain/tree/master/examples/parser/diagrams
- https://sap.github.io/chevrotain/docs/guide/generating_syntax_diagrams.html#examples