Skip to content

Commit 677191d

Browse files
authored
ui-fixes-branches-page (#10873)
* fix borderless commit lists * fix paddings for PR previews * feat(ui): truncate long PR titles in PRBranchView header to prevent overflow
1 parent b2d1da6 commit 677191d

File tree

3 files changed

+13
-7
lines changed

3 files changed

+13
-7
lines changed

apps/desktop/src/components/BranchesView.svelte

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -364,7 +364,7 @@
364364
{/if}
365365

366366
{#if isNonLocalPr && current.prNumber}
367-
<div class="commits" use:focusable={{ vertical: true }}>
367+
<div class="commits with-padding" use:focusable={{ vertical: true }}>
368368
<BranchesViewPr
369369
bind:this={prBranch}
370370
{projectId}

apps/desktop/src/components/BranchesViewBranch.svelte

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -149,6 +149,8 @@
149149

150150
<style lang="postcss">
151151
.branch-commits {
152-
border-top: 1px solid var(--clr-border-2);
152+
overflow: hidden;
153+
border: 1px solid var(--clr-border-2);
154+
border-radius: 0 0 var(--radius-ml) var(--radius-ml);
153155
}
154156
</style>

apps/desktop/src/components/PRBranchView.svelte

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -21,9 +21,13 @@
2121

2222
<ReduxResult result={prQuery?.result} {projectId} {onerror}>
2323
{#snippet children(pr)}
24-
<Drawer testId={TestId.PRBranchDrawer} persistId="pr-branch-drawer-{projectId}-{pr.number}">
24+
<Drawer
25+
testId={TestId.PRBranchDrawer}
26+
persistId="pr-branch-drawer-{projectId}-{pr.number}"
27+
bottomBorder
28+
>
2529
{#snippet header()}
26-
<h3 class="text-14 text-semibold">
30+
<h3 class="text-14 text-semibold truncate">
2731
<span class="clr-text-2">PR {unitSymbol}{pr.number}:</span>
2832
<span> {pr.title}</span>
2933
</h3>
@@ -65,7 +69,7 @@
6569
</div>
6670

6771
{#if pr.body}
68-
<div class="pr-body text-13">
72+
<div class="pr-body text-13 text-body">
6973
<Markdown content={pr.body} />
7074
</div>
7175
{/if}
@@ -78,13 +82,13 @@
7882
.pr-content {
7983
display: flex;
8084
flex-direction: column;
81-
gap: 16px;
8285
}
8386
8487
.pr-request-data {
8588
display: flex;
8689
flex-direction: row;
8790
width: 100%;
91+
padding: 16px;
8892
gap: 10px;
8993
}
9094
@@ -117,7 +121,7 @@
117121
}
118122
119123
.pr-body {
120-
padding-top: 16px;
124+
padding: 16px;
121125
border-top: 1px solid var(--clr-border-2);
122126
}
123127
</style>

0 commit comments

Comments
 (0)