Skip to content
This repository was archived by the owner on Sep 30, 2020. It is now read-only.

Commit 88aa1ef

Browse files
committed
Modify comments to add/subtract/multiply/divide, remove playground button
1 parent ee08e9d commit 88aa1ef

File tree

3 files changed

+4
-23
lines changed

3 files changed

+4
-23
lines changed

css/style.css

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -277,15 +277,6 @@ ul.laundry-list {
277277
outline: none;
278278
}
279279

280-
#playground {
281-
position: absolute;
282-
z-index: 10;
283-
float: right;
284-
right: 8px;
285-
top: 48px;
286-
outline: none;
287-
}
288-
289280
.fa-external-link {
290281
position: relative;
291282
float: right;

index.html

Lines changed: 4 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -50,10 +50,8 @@ <h2>Featuring</h2>
5050
<div id="editor">// This code is editable and runnable!
5151
fn main() {
5252
// A simple integer calculator:
53-
// `+` denotes adding 1
54-
// `-` denotes subtracting 1
55-
// `*` denotes multiplying by 2
56-
// `/` denotes dividing by 2
53+
// `+` or `-` means add or subtract by 1
54+
// `*` or `/` means multiply or divide by 2
5755

5856
let program = "+ + * - /";
5957
let mut accumulator = 0;
@@ -77,10 +75,8 @@ <h2>Featuring</h2>
7775
<pre class='rust'>
7876
<span class='kw'>fn</span> main() {
7977
<span class='comment'>// A simple integer calculator:
80-
// `+` denotes adding 1
81-
// `-` denotes subtracting 1
82-
// `*` denotes multiplying by 2
83-
// `/` denotes dividing by 2</span>
78+
// `+` or `-` means add or subtract by 1
79+
// `*` or `/` means multiply or divide by 2</span>
8480

8581
<span class='kw'>let</span> program = <span class='string'>"+ + * - /"</span>;
8682
<span class='kw'>let</span> <span class='kw'>mut</span> accumulator = <span class='number'>0</span>;

js/editor.js

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,6 @@ var activeCode = document.getElementById("active-code");
1313
var editorDiv = document.getElementById("editor");
1414
var staticCode = document.getElementById("static-code");
1515
var runButton = document.getElementById("run-code");
16-
var playButton = document.getElementById("playground");
1716
var resultDiv = document.getElementById("result");
1817

1918
// Background colors for program result on success/error
@@ -215,11 +214,6 @@ runButton.addEventListener("click", function(ev) {
215214
runProgram(program, handleResult);
216215
});
217216

218-
// Navigate to playground, TODO: Get code from editor and paste into playground
219-
/*playButton.addEventListener("click", function(ev) {
220-
window.location = "http://play.rust-lang.org/"
221-
});*/
222-
223217
// Highlight active line when focused
224218
editor.on('focus', function() {
225219
editor.setHighlightActiveLine(true);

0 commit comments

Comments
 (0)