|
| 1 | +<!DOCTYPE html> |
| 2 | +<html> |
| 3 | + <head> |
| 4 | + <meta charset="utf-8" /> |
| 5 | + <title>Sketchpad</title> |
| 6 | + <style> |
| 7 | + body { |
| 8 | + margin: 0; |
| 9 | + padding: 0; |
| 10 | + position: absolute; |
| 11 | + top: 0; |
| 12 | + left: 0; |
| 13 | + display: flex; |
| 14 | + flex-direction: column; |
| 15 | + align-items: center; |
| 16 | + justify-content: center; |
| 17 | + background: #999; |
| 18 | + |
| 19 | + font-family: system-ui, "Helvetica Neue"; |
| 20 | + } |
| 21 | + menu { |
| 22 | + display: flex; |
| 23 | + justify-content: left; |
| 24 | + gap: 6px; |
| 25 | + } |
| 26 | + #fps { |
| 27 | + position: absolute; |
| 28 | + bottom: 0px; |
| 29 | + right: 0px; |
| 30 | + padding: 5px; |
| 31 | + background: #ccc; |
| 32 | + font: 12px "Fira Mono", mono; |
| 33 | + white-space: pre; |
| 34 | + } |
| 35 | + .panel { |
| 36 | + padding: 20px; |
| 37 | + } |
| 38 | + canvas { |
| 39 | + border-radius: 2px; |
| 40 | + } |
| 41 | + .display-module { |
| 42 | + position: relative; |
| 43 | + background: black; |
| 44 | + padding: 43px; |
| 45 | + border: 3px outset #999; |
| 46 | + } |
| 47 | + .screw { |
| 48 | + display: block; |
| 49 | + position: absolute; |
| 50 | + width: 6px; |
| 51 | + height: 6px; |
| 52 | + border-radius: 4px; |
| 53 | + background-color: #666; |
| 54 | + border: 1px inset #ccc; |
| 55 | + } |
| 56 | + .screw.top { |
| 57 | + top: 10px; |
| 58 | + } |
| 59 | + .screw.mid { |
| 60 | + top: 360px; |
| 61 | + } |
| 62 | + .screw.bottom { |
| 63 | + bottom: 10px; |
| 64 | + } |
| 65 | + .screw.left { |
| 66 | + left: 10px; |
| 67 | + } |
| 68 | + .screw.right { |
| 69 | + right: 10px; |
| 70 | + } |
| 71 | + .screw.center { |
| 72 | + left: 360px; |
| 73 | + } |
| 74 | + |
| 75 | + footer { |
| 76 | + padding-top: 10px; |
| 77 | + display: flex; |
| 78 | + justify-content: space-between; |
| 79 | + } |
| 80 | + nav.buttons { |
| 81 | + background-color: rgb(255 255 255 / 0.5); |
| 82 | + text-align: center; |
| 83 | + border: 1px solid black; |
| 84 | + padding: 5px; |
| 85 | + } |
| 86 | + nav.buttons button { |
| 87 | + height: 40px; |
| 88 | + width: 40px; |
| 89 | + border: 1px inset black; |
| 90 | + font-family: monospace; |
| 91 | + color: rgb(0 0 0 / 0.8); |
| 92 | + } |
| 93 | + .indicators { |
| 94 | + display: inline-grid; |
| 95 | + grid-template-columns: 1fr 1fr 1fr 1fr 1fr 1fr 1fr 1fr; |
| 96 | + padding: 10px 20px; |
| 97 | + background: #111; |
| 98 | + border-radius: 2px; |
| 99 | + } |
| 100 | + |
| 101 | + #controller { |
| 102 | + position: absolute; |
| 103 | + left: 650px; |
| 104 | + width: 300px; |
| 105 | + top: 0; |
| 106 | + padding-top: 50px; |
| 107 | + } |
| 108 | + |
| 109 | + #controller select { |
| 110 | + display: block; |
| 111 | + } |
| 112 | + #controller label { |
| 113 | + display: block; |
| 114 | + } |
| 115 | + </style> |
| 116 | + </head> |
| 117 | + <body> |
| 118 | + <div id="controller"> |
| 119 | + <label for="current-picture" |
| 120 | + >Current picture |
| 121 | + <select id="current-picture"></select |
| 122 | + ></label> |
| 123 | + <br /> |
| 124 | + |
| 125 | + <label>Mode</label> |
| 126 | + <label><input type="radio" name="mode" value="move" /> Move</label> |
| 127 | + <label><input type="radio" name="mode" value="line" /> Line</label> |
| 128 | + <label><input type="radio" name="mode" value="arc" /> Arc</label> |
| 129 | + <label><input type="radio" name="mode" value="delete" /> Delete</label> |
| 130 | + |
| 131 | + <label>Options</label> |
| 132 | + <label><input type="checkbox" name="twinkle" checked /> Twinkle</label> |
| 133 | + </div> |
| 134 | + <div class="panel"> |
| 135 | + <div class="display-module"> |
| 136 | + <span class="screw top left"></span> |
| 137 | + <span class="screw top center"></span> |
| 138 | + <span class="screw top right"></span> |
| 139 | + <span class="screw mid left"></span> |
| 140 | + <span class="screw mid right"></span> |
| 141 | + <span class="screw bottom left"></span> |
| 142 | + <span class="screw bottom center"></span> |
| 143 | + <span class="screw bottom right"></span |
| 144 | + ><canvas height="512" width="512" id="sketchpad-canvas"></canvas> |
| 145 | + </div> |
| 146 | + </div> |
| 147 | + |
| 148 | + <script src="index.js"></script> |
| 149 | + </body> |
| 150 | +</html> |
0 commit comments