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

Codemirror support #17

Closed
wants to merge 3 commits into from
Closed
Show file tree
Hide file tree
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
8 changes: 7 additions & 1 deletion src/main/webapp/index.jsp
Expand Up @@ -29,7 +29,7 @@
<link rel="stylesheet" href="${contextroot}/plantuml.css" />
<link rel="stylesheet" href="webjars/codemirror/3.21/lib/codemirror.css" />
<script src="webjars/codemirror/3.21/lib/codemirror.js"></script>
<!-- <script src="mode/plantuml.js"></script> -->
<script src="mode/plantuml.js">
<script>
window.onload = function() {
var myCodeMirror = CodeMirror.fromTextArea(
Expand Down Expand Up @@ -59,6 +59,12 @@
<textarea id="text" name="text" cols="120" rows="10"><c:out value="${decoded}"/></textarea>
<input type="submit" />
</p>
<script>
var myTextarea = document.getElementById("text");
var editor = CodeMirror.fromTextArea(myTextarea, {
lineNumbers: true
});
</script>
</form>
<hr/>
<p>You can enter here a previously generated URL:</p>
Expand Down