Skip to content

Commit 61c2d50

Browse files
style: add a dotted background, tweaks and fixes
1 parent da2c4db commit 61c2d50

File tree

6 files changed

+34
-24
lines changed

6 files changed

+34
-24
lines changed

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
"version": "1.0.0",
44
"private": true,
55
"scripts": {
6-
"dev": "vite dev",
6+
"dev": "vite",
77
"build": "vite build",
88
"preview": "vite preview",
99
"check": "svelte-kit sync && svelte-check --tsconfig ./tsconfig.json",

src/app.css

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -150,6 +150,13 @@
150150

151151
body {
152152
@apply flex min-h-screen flex-col bg-background text-foreground;
153+
background-image:
154+
radial-gradient(var(--color-border) 0.5px, transparent 0.5px),
155+
radial-gradient(var(--color-border) 0.5px, var(--color-background) 0.5px);
156+
background-size: 20px 20px;
157+
background-position:
158+
0 0,
159+
10px 10px;
153160
}
154161

155162
/* I like pointer cursors on buttons */

src/routes/+layout.svelte

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -105,9 +105,10 @@
105105

106106
<header
107107
class={[
108-
"sticky top-0 z-40 w-full bg-background/95 backdrop-blur transition-shadow duration-500 supports-backdrop-filter:bg-background/60",
108+
"sticky top-0 z-40 w-full transition-shadow duration-500",
109109
{
110-
"shadow-sm": newsToDisplay || (scrollY.current ?? 0) >= 25
110+
"bg-background/95 shadow-sm backdrop-blur supports-backdrop-filter:bg-background/60":
111+
newsToDisplay || (scrollY.current ?? 0) >= 25
111112
}
112113
]}
113114
>

src/routes/[pid=pid]/[org]/[repo]/[id=number]/BottomCollapsible.svelte

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
let id = $props.id();
2323
</script>
2424

25-
<div class="rounded-md border px-4">
25+
<div class="rounded-md border bg-background px-4">
2626
<Accordion.Root type="single" value={openByDefault ? id : undefined}>
2727
<Accordion.Item value={id} class="border-b-0">
2828
<Accordion.Trigger

src/routes/[pid=pid]/[org]/[repo]/[id=number]/PageRenderer.svelte

Lines changed: 21 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -362,7 +362,7 @@
362362
<!-- Info -->
363363
<div class="mb-8 flex w-full flex-col justify-center gap-8 *:h-fit md:flex-row">
364364
<!-- Left part - body -->
365-
<div class="flex-1 rounded-md border bg-muted/30">
365+
<div class="flex-1 rounded-md border bg-background">
366366
<!-- Author -->
367367
<div
368368
class="inline-flex w-full flex-col gap-1 border-b bg-muted/60 px-4 py-2 xs:flex-row xs:items-center xs:gap-0"
@@ -389,7 +389,7 @@
389389
</span>
390390
</div>
391391
<!-- Body -->
392-
<div class="p-4">
392+
<div class="bg-muted/30 p-4">
393393
<MarkdownRenderer
394394
markdown={info.body || "_No description provided_"}
395395
parseRawHtml
@@ -427,7 +427,7 @@
427427
</div>
428428
<!-- Right part - info -->
429429
<div class="flex flex-col gap-4 md:w-2/5 md:max-w-xs md:min-w-72">
430-
<div class="rounded-md border px-4 pb-3">
430+
<div class="rounded-md border bg-background px-4 pb-3">
431431
<h4 class="-mx-4 mb-4 border-b bg-muted/40 px-4 pt-2 pb-1 text-xl font-semibold">Info</h4>
432432
{#each rightPartInfo as { title, value }, i (title)}
433433
{#if i > 0}
@@ -442,22 +442,24 @@
442442
{#await mergedTagName then mergedTag}
443443
{#if mergedTag}
444444
{@const [tagName, tagVersion] = mergedTag}
445-
<Alert.Root class="rounded-md border-green-500 bg-green-400/10">
446-
<Tag class="size-4" />
447-
<Alert.Description class="inline text-foreground">
448-
This pull request was released in
449-
<Button
450-
variant="link"
451-
href={resolve("/package/[...package]", {
452-
package: tagName
453-
}) + `#${tagVersion}`}
454-
class="h-auto p-0 text-green-500"
455-
>
456-
{tagName}
457-
{tagVersion}
458-
</Button>
459-
</Alert.Description>
460-
</Alert.Root>
445+
<div class="bg-background">
446+
<Alert.Root class="rounded-md border-green-500 bg-green-400/10">
447+
<Tag class="size-4" />
448+
<Alert.Description class="inline text-foreground">
449+
This pull request was released in
450+
<Button
451+
variant="link"
452+
href={resolve("/package/[...package]", {
453+
package: tagName
454+
}) + `#${tagVersion}`}
455+
class="h-auto p-0 text-green-500"
456+
>
457+
{tagName}
458+
{tagVersion}
459+
</Button>
460+
</Alert.Description>
461+
</Alert.Root>
462+
</div>
461463
{/if}
462464
{/await}
463465
</div>

src/routes/package/[...package]/ReleaseCard.svelte

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -223,7 +223,7 @@
223223
id={release.cleanVersion}
224224
value={`${release.id}`}
225225
class={[
226-
"scroll-mt-20 rounded-md border-b-0 shadow-lg outline outline-transparent transition-colors duration-300 data-[state=open]:outline-muted-foreground/20 [&>[data-accordion-content]]:rounded-md [&>[data-accordion-content]]:bg-accent/30",
226+
"scroll-mt-20 rounded-md border-b-0 bg-background shadow-lg outline outline-transparent transition-colors duration-300 data-[state=open]:outline-muted-foreground/20 [&>[data-accordion-content]]:rounded-b-md [&>[data-accordion-content]]:bg-accent/30",
227227
{ "border border-primary": isMajorRelease && index < 3 },
228228
{ "ring ring-primary": page.url.hash && page.url.hash === `#${release.cleanVersion}` }
229229
]}

0 commit comments

Comments
 (0)