From 2ef63bc1d9493823a4fe92a12c7e60ebe2fb8f08 Mon Sep 17 00:00:00 2001 From: Scott Chacon Date: Tue, 30 Apr 2024 10:33:35 +0200 Subject: [PATCH] what in gods name --- app/src/lib/components/Board.svelte | 112 +++++++++++++++------------- 1 file changed, 60 insertions(+), 52 deletions(-) diff --git a/app/src/lib/components/Board.svelte b/app/src/lib/components/Board.svelte index 761d7a20f..76fb538cf 100644 --- a/app/src/lib/components/Board.svelte +++ b/app/src/lib/components/Board.svelte @@ -23,9 +23,11 @@ const activeBranchesError = vbranchService.activeBranchesError; const activeBranches = vbranchService.activeBranches; - let selectedBranch: { - name: string; - } | undefined; + let selectedBranch: + | { + name: string; + } + | undefined; let dragged: any; let dropZone: HTMLDivElement; @@ -46,16 +48,17 @@ if (!selectedBranch) return; // while target is setting, display loading isSwitching = true; - await branchController.setTarget(selectedBranch.name) - .then((res) => { + await branchController + .setTarget(selectedBranch.name) + .then((res) => { console.log('done', res); }) .catch((err) => { console.log('error', err); }) .finally(() => { - isSwitching = false; - showBranchSwitch = false; + isSwitching = false; + showBranchSwitch = false; }); } @@ -65,9 +68,7 @@ {:else if !$activeBranches} {:else if isSwitching} -
- switching base branch... -
+
switching base branch...
{:else}
- {#if showBranchSwitch} - {#await getRemoteBranches(project.id)} - loading remote branches... - {:then remoteBranches} - {#if remoteBranches.length == 0} - No remote branches - {:else} -
- - + {#if showBranchSwitch} + {#await getRemoteBranches(project.id)} + loading remote branches... + {:then remoteBranches} + {#if remoteBranches.length == 0} + No remote branches + {:else} +
+ + +
+ {/if} + {:catch} + No remote branches + {/await} + {:else} +
+
+
Your current base branch is:
+
{$baseBranch.branchName}
- {/if} - {:catch} - No remote branches - {/await} - {:else} -
-
-
Your current base branch is:
-
{$baseBranch.branchName}
+
- -
- {/if} + {/if}