Skip to content

Commit

Permalink
Close #63: Include 3D models in the mechanism pages
Browse files Browse the repository at this point in the history
  • Loading branch information
Jonathan Janetzki committed Jul 20, 2018
1 parent 00ed132 commit 3c074e9
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 2 deletions.
1 change: 0 additions & 1 deletion frontend/public/mechanism-article-edit.html
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,6 @@
</div>
</td>
</tr>
</tbody>
</table>
</div>
</div>
Expand Down
18 changes: 17 additions & 1 deletion frontend/public/mechanism-article.html
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
<title>{{name}}</title>
<link rel="stylesheet" type="text/css" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.5/css/bootstrap.min.css">
<link rel="stylesheet" href="../../styles.css">
<link rel="stylesheet" href="../OpenJSCAD/min.css" type="text/css">
</head>

<body>
Expand Down Expand Up @@ -88,6 +89,22 @@ <h1 class="page-header-title">{{name}}</h1>
<tr>
<th style="text-align: left">3D model</th>
<td id="3DModelCell">
<script src="../OpenJSCAD/dist/min.js"></script>
<!-- setup display of the errors as required by OpenJSCAD.js -->
<div class="jscad-container" style="border: 0; padding: 0">
<div id="header">
<div id="errordiv">hello</div>
</div>

<!-- setup display of the viewer, i.e. canvas -->
<div oncontextmenu="return false;" id="viewerContext" design-url="../..{{parametric_model}}"></div>

<!-- setup display of the status, as required by OpenJSCAD.js -->
<!-- set display: block to display this -->
<div id="tail" style="display: none;">
<div id="statusdiv"></div>
</div>
</div>
<a id="3DModelLink" href="{{model}}">{{modelName}}</a>
</td>
</tr>
Expand All @@ -97,7 +114,6 @@ <h1 class="page-header-title">{{name}}</h1>
Incomplete
</td>
</tr>
</tbody>
</table>
</section>
</div>
Expand Down

0 comments on commit 3c074e9

Please sign in to comment.