Skip to content

Commit f648b8f

Browse files
committed
Make code formatting/indentation consistent
1 parent 31a5c9a commit f648b8f

File tree

2 files changed

+46
-46
lines changed

2 files changed

+46
-46
lines changed

app/styles/crate.scss

Lines changed: 17 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -242,33 +242,32 @@
242242
padding: 20px;
243243
}
244244
button, button:active {
245-
padding:5px 0;
246-
background-color: #FFFFFF;
247-
border: none;
248-
width: 60px;
245+
padding: 5px 0;
246+
background-color: #FFFFFF;
247+
border: none;
248+
width: 60px;
249249
}
250-
button:hover{
251-
background: #edebdd;
250+
button:hover {
251+
background: #edebdd;
252252
}
253253
@media only screen and (min-width: 500px) {
254254
.action { @include flex(2); display: block; }
255255
code { @include flex(8); }
256256
}
257257
}
258258
.copy-result {
259-
text-align:right;
260-
261-
span {
262-
font-size:80%;
263-
font-weight:bold;
264-
}
265-
.copy-success {
266-
color:$link-color;
267-
}
268-
.copy-failure {
269-
color:red;
270-
}
259+
text-align: right;
271260

261+
span {
262+
font-size: 80%;
263+
font-weight: bold;
264+
}
265+
.copy-success {
266+
color: $link-color;
267+
}
268+
.copy-failure {
269+
color: red;
270+
}
272271
}
273272
.last-update {
274273
color: $main-color-light;

app/templates/crate/version.hbs

Lines changed: 29 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@
6363
</button>
6464
</div>
6565
<div class="copy-result">
66-
<span id="copy-notification"></span>
66+
<span id="copy-notification"></span>
6767
</div>
6868
</div>
6969
<div class='authorship'>
@@ -279,37 +279,38 @@
279279
{{/if}}
280280

281281
<script type="text/javascript">
282-
if (!Clipboard.isSupported()) {
283-
document.getElementById('crate-download-button').classList.add('hidden');
284-
}
282+
if (!Clipboard.isSupported()) {
283+
document.getElementById('crate-download-button').classList.add('hidden');
284+
}
285285
286-
var clipboard = new Clipboard('#crate-download-button');
287-
var notificationElement = document.getElementById('copy-notification');
288-
clipboard.on('success', function(e) {
289-
var successText = 'Copied !';
286+
var clipboard = new Clipboard('#crate-download-button');
287+
var notificationElement = document.getElementById('copy-notification');
290288
291-
e.clearSelection();
292-
notificationElement.classList.add('copy-success')
293-
notificationElement.textContent = successText;
294-
fadeOffElement(notificationElement, 2000);
295-
});
296-
clipboard.on('error', function(e) {
297-
var failureText = 'An error occured. Please use CTRL+C.';
289+
clipboard.on('success', function(e) {
290+
var successText = 'Copied !';
298291
299-
notificationElement.classList.add('copy-failure')
300-
notificationElement.textContent = failureText;
301-
fadeOffElement(notificationElement, 2000);
302-
});
292+
e.clearSelection();
293+
notificationElement.classList.add('copy-success')
294+
notificationElement.textContent = successText;
295+
fadeOffElement(notificationElement, 2000);
296+
});
303297
304-
function fadeOffElement(element, delay) {
305-
setTimeout(function() {
306-
resetElement(element);
307-
}, delay);
308-
}
298+
clipboard.on('error', function(e) {
299+
var failureText = 'An error occured. Please use CTRL+C.';
309300
310-
function resetElement(element) {
311-
element.innerHTML = '';
312-
element.className = '';
313-
}
301+
notificationElement.classList.add('copy-failure')
302+
notificationElement.textContent = failureText;
303+
fadeOffElement(notificationElement, 2000);
304+
});
314305
306+
function fadeOffElement(element, delay) {
307+
setTimeout(function() {
308+
resetElement(element);
309+
}, delay);
310+
}
311+
312+
function resetElement(element) {
313+
element.innerHTML = '';
314+
element.className = '';
315+
}
315316
</script>

0 commit comments

Comments
 (0)