Skip to content

Commit 1e8df57

Browse files
committed
more code formatting
1 parent 7c3f2ed commit 1e8df57

File tree

5 files changed

+1684
-1452
lines changed

5 files changed

+1684
-1452
lines changed

.prettier-ignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
handlebars.runtime-v4.0.10.js

app.js

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
var token = ''
22

33
// the backdrop
4-
var backdrop = $('<div class="kamino-backdrop fade in"></div>');
4+
var backdrop = $('<div class="kamino-backdrop fade in"></div>')
55

66
// repo list
77
var repoList = []
@@ -46,7 +46,7 @@ function initializeExtension() {
4646
$(popup).insertBefore($('.sidebar-assignee'))
4747

4848
// remove the open class just to be sure
49-
$('.btn-group').removeClass('open');
49+
$('.btn-group').removeClass('open')
5050

5151
// load the token
5252
chrome.storage.sync.get({
@@ -112,8 +112,8 @@ function saveAppliedFilters(urlObj) {
112112
filters: []
113113
}, (item) => {
114114

115-
var exists = false;
116-
var changed = false;
115+
var exists = false
116+
var changed = false
117117

118118
// convert the string to an empty array for existing users
119119
if (typeof item.filters === 'string') {
@@ -179,7 +179,7 @@ function getRepos(url) {
179179

180180
function loadRepos() {
181181
// wire up search value change events
182-
var lastValue = '';
182+
var lastValue = ''
183183
$(".repoSearch").on('change keyup paste mouseup', function () {
184184
if ($(this).val() != lastValue) {
185185
lastValue = $(this).val()
@@ -220,7 +220,7 @@ function compileRepositoryList(list, searchTerm) {
220220
}, (item) => {
221221
// check for a populated list
222222
if (item.mostUsed && item.mostUsed.length > 0) {
223-
$('.quickClone').attr('data-repo', item.mostUsed[0]);
223+
$('.quickClone').attr('data-repo', item.mostUsed[0])
224224
$('.quickClone').text(`Clone to ${item.mostUsed[0].substring(item.mostUsed[0].indexOf('/') + 1)}`)
225225

226226
// show used separator header
@@ -255,7 +255,7 @@ function compileRepositoryList(list, searchTerm) {
255255
}
256256
else {
257257
$('.dropdown-header-used').removeClass('active')
258-
$('.quickClone').text('Clone to');
258+
$('.quickClone').text('Clone to')
259259
}
260260

261261
// show or hide rest header based on number of items
@@ -266,7 +266,7 @@ function compileRepositoryList(list, searchTerm) {
266266
}
267267

268268
list.forEach((repo) => {
269-
addRepoToList(repo.full_name, repo.name);
269+
addRepoToList(repo.full_name, repo.name)
270270
})
271271
})
272272
}
@@ -409,7 +409,7 @@ function addToMostUsed(repo) {
409409
// find the item
410410
if (item.mostUsed.find((e) => { return e === repo }) !== undefined) {
411411
// if exists, get index
412-
var index = item.mostUsed.indexOf(repo);
412+
var index = item.mostUsed.indexOf(repo)
413413

414414
// remove
415415
item.mostUsed.splice(index, 1)
@@ -462,13 +462,13 @@ function itemClick(repo) {
462462

463463
function closeModal() {
464464
// make sure the modal closes properly
465-
$('.kamino-backdrop').remove();
465+
$('.kamino-backdrop').remove()
466466
$('#kaminoModal').removeClass('in')
467467
$('#kaminoModal').css('display', '')
468468
}
469469

470470
function openModal() {
471471
$('#kaminoModal').addClass('in')
472472
$('#kaminoModal').css('display', 'block')
473-
$('#js-repo-pjax-container').append(backdrop);
473+
$('#js-repo-pjax-container').append(backdrop)
474474
}

background.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,8 @@ chrome.webNavigation.onHistoryStateUpdated.addListener((details) => {
44
chrome.tabs.executeScript(null, { file: "handlebars.runtime-v4.0.10.js", runAt: 'document_end' }, (h) => {
55
chrome.tabs.executeScript(null, { file: "template.js", runAt: 'document_end' }, (h) => {
66
chrome.tabs.executeScript(null, { file: "app.js", runAt: 'document_end' }, (a) => {
7-
chrome.tabs.insertCSS(null, { file: "css/style.css", runAt: 'document_end' });
8-
});
7+
chrome.tabs.insertCSS(null, { file: "css/style.css", runAt: 'document_end' })
8+
})
99
})
1010
})
1111
})
@@ -63,4 +63,4 @@ chrome.runtime.onMessage.addListener((request, sender, sendResponse) => {
6363
}
6464
})
6565
}
66-
})
66+
})

0 commit comments

Comments
 (0)