Skip to content
This repository was archived by the owner on Mar 4, 2025. It is now read-only.

Commit 19716e5

Browse files
committed
webui: Adjust some indentation weirdness with new jsx files
No functional change in this commit, it just re-aligns some JS code that's looking weirdly indented. The weirdness only seems to show up in the GitHub web interface though, not in "git diff" from the cli. So it's probably something tab vs spaces or similar then.
1 parent b6e67d9 commit 19716e5

File tree

2 files changed

+21
-21
lines changed

2 files changed

+21
-21
lines changed

webui/jsx/database-commits.js

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -7,25 +7,25 @@ function DatabaseCommitRow({data, index, branch, setStatusMessage, setStatusMess
77
const [commitIndex, setCommitIndex] = React.useState(Number(index));
88

99
// Bounce to the page for creating branches
10-
function createBranch() {
10+
function createBranch() {
1111
window.location = "/createbranch/" + meta.owner + "/" + meta.database + "?commit=" + data.id;
12-
}
12+
}
1313

14-
// Bounce to the page for creating tags
15-
function createTag() {
14+
// Bounce to the page for creating tags
15+
function createTag() {
1616
window.location = "/createtag/" + meta.owner + "/" + meta.database + "?commit=" + data.id;
17-
}
17+
}
1818

19-
// Bounce to the page for viewing changes
20-
function viewChanges() {
19+
// Bounce to the page for viewing changes
20+
function viewChanges() {
2121
window.location = "/diffs/" + meta.owner + "/" + meta.database + "?commit_a=" + commitData[commitIndex + 1].id + "&commit_b=" + data.id;
22-
}
22+
}
2323

2424
// Delete a commit from the viewed branch
25-
function deleteCommit() {
25+
function deleteCommit() {
2626
fetch("/x/deletecommit/", {
2727
method: "post",
28-
headers: {
28+
headers: {
2929
"Content-Type": "application/x-www-form-urlencoded"
3030
},
3131
body: new URLSearchParams({
@@ -46,7 +46,7 @@ function DatabaseCommitRow({data, index, branch, setStatusMessage, setStatusMess
4646
setStatusMessageColour("red");
4747
setStatusMessage("Error: " + error.text());
4848
});
49-
}
49+
}
5050

5151
// Is this the last and/or head commit?
5252
const isHeadCommit = data.id == commitData[0].id;

webui/jsx/discussion-comments.js

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ function DiscussionTopComment({setStatusMessage, setStatusMessageColour}) {
2121
// Send the new discussion text to the server
2222
fetch("/x/updatediscuss/", {
2323
method: "post",
24-
headers: {
24+
headers: {
2525
"Content-Type": "application/x-www-form-urlencoded"
2626
},
2727
body: new URLSearchParams({
@@ -58,7 +58,7 @@ function DiscussionTopComment({setStatusMessage, setStatusMessageColour}) {
5858
function mergeRequest() {
5959
fetch("/x/mergerequest/", {
6060
method: "post",
61-
headers: {
61+
headers: {
6262
"Content-Type": "application/x-www-form-urlencoded"
6363
},
6464
body: new URLSearchParams({
@@ -87,7 +87,7 @@ function DiscussionTopComment({setStatusMessage, setStatusMessageColour}) {
8787
// Send the comment text to the server
8888
fetch("/x/createcomment/", {
8989
method: "post",
90-
headers: {
90+
headers: {
9191
"Content-Type": "application/x-www-form-urlencoded"
9292
},
9393
body: new URLSearchParams({
@@ -217,7 +217,7 @@ function DiscussionComment({commentData, setStatusMessage, setStatusMessageColou
217217

218218
fetch("/x/updatecomment/", {
219219
method: "post",
220-
headers: {
220+
headers: {
221221
"Content-Type": "application/x-www-form-urlencoded"
222222
},
223223
body: new URLSearchParams({
@@ -277,11 +277,11 @@ function DiscussionComment({commentData, setStatusMessage, setStatusMessageColou
277277
// Deleting the comment succeeded, so reload the page
278278
window.location = "/" + (mrData === null ? "discuss" : "merge") + "/" + meta.owner + "/" + meta.database + "?id=" + discussionData.disc_id;
279279
})
280-
.catch((error) => {
281-
// Deleting the comment failed, so display an error message
282-
setStatusMessageColour("red");
283-
setStatusMessage("Deleting comment failed");
284-
});
280+
.catch((error) => {
281+
// Deleting the comment failed, so display an error message
282+
setStatusMessageColour("red");
283+
setStatusMessage("Deleting comment failed");
284+
});
285285
}
286286
},
287287
{
@@ -369,7 +369,7 @@ export default function DiscussionComments() {
369369

370370
fetch("/x/createcomment/", {
371371
method: "post",
372-
headers: {
372+
headers: {
373373
"Content-Type": "application/x-www-form-urlencoded"
374374
},
375375
body: new URLSearchParams({

0 commit comments

Comments
 (0)