Skip to content

Commit ef39dc7

Browse files
committed
Improve the line wrapping of Megaminx and Square-1 scrambles. Addresses #20.
1 parent eb1cd2b commit ef39dc7

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

timerApp.js

+8
Original file line numberDiff line numberDiff line change
@@ -167,6 +167,14 @@ TimerApp.ScrambleView.prototype = {
167167
this._scrambleText.classList.remove("stale");
168168
this._scrambleText.href = Cubing.prototype.urlForScramble(scramble);
169169
this._scrambleText.textContent = scramble.scrambleString;
170+
171+
// TODO(lgarron): Use proper layout code. https://github.com/cubing/timer/issues/20
172+
if (scramble.eventName === "minx") {
173+
this._scrambleText.innerHTML = scramble.scrambleString;
174+
}
175+
else if (scramble.eventName === "sq1") {
176+
this._scrambleText.innerHTML = scramble.scrambleString.replace(", ", ", ").replace(") /", ") /");
177+
}
170178
},
171179

172180
clearScramble: function()

0 commit comments

Comments
 (0)