Skip to content

Commit

Permalink
upgrade: mono-svelte 0.3.8 -> 0.4.1
Browse files Browse the repository at this point in the history
  • Loading branch information
Xyphyn committed Sep 29, 2023
1 parent b3b8a10 commit 3bc3258
Show file tree
Hide file tree
Showing 4 changed files with 32 additions and 17 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@
"@dicebear/core": "^6.0.4",
"@dicebear/initials": "^6.0.4",
"markdown-it": "^13.0.1",
"mono-svelte": "^0.3.7"
"mono-svelte": "^0.4.1"
},
"type": "module"
}
4 changes: 2 additions & 2 deletions src/lib/components/lemmy/post/PostMeta.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@
</Badge>
{/if}
{#if removed}
<Badge label="Removed" color="red">
<Badge label="Removed" color="red-subtle">
<Icon src={Trash} mini size="14" />
<span class="max-md:hidden">Removed</span>
</Badge>
Expand All @@ -128,7 +128,7 @@
</Badge>
{/if}
{#if featured}
<Badge label="Featured" color="green">
<Badge label="Featured" color="green-subtle">
<Icon src={Megaphone} mini size="14" />
<span class="max-md:hidden">Featured</span>
</Badge>
Expand Down
35 changes: 25 additions & 10 deletions src/routes/post/[instance]/[id=integer]/+page.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,14 @@
} from 'svelte-hero-icons'
import PostLink from '$lib/components/lemmy/post/PostLink.svelte'
import PostMeta from '$lib/components/lemmy/post/PostMeta.svelte'
import { Badge, Material, Spinner, removeToast, toast } from 'mono-svelte'
import {
Badge,
Material,
Select,
Spinner,
removeToast,
toast,
} from 'mono-svelte'
import type { CommentSortType } from 'lemmy-js-client'
import MultiSelect from '$lib/components/input/Switch.svelte'
import { profile } from '$lib/auth.js'
Expand Down Expand Up @@ -262,17 +269,25 @@
<div class="mt-4 flex flex-col gap-2 w-full">
<div class="flex flex-row justify-between flex-wrap gap-2">
<div class="font-bold opacity-80 text-base flex items-center gap-2">
Comments <Badge color="gray" class="!text-sm">
Comments <Badge
color="blue-subtle"
class="min-w-[1rem] justify-center !font-bold"
>
<FormattedNumber number={post.post_view.counts.comments} />
</Badge>
</div>
<div class="gap-2 flex">
<MultiSelect
options={['Hot', 'Top', 'New']}
bind:selected={commentSort}
on:select={reloadComments}
headless
/>
<div class="gap-2 flex items-center h-8">
<Select
size="sm"
class="!h-full"
bind:value={commentSort}
on:change={reloadComments}
>
<option value="Hot">Hot</option>
<option value="Top">Top</option>
<option value="New">New</option>
<option value="Old">Old</option>
</Select>
<Button size="square-md" on:click={reloadComments}>
<Icon src={ArrowPath} size="16" mini slot="prefix" />
</Button>
Expand All @@ -298,9 +313,9 @@
{:else}
<Button
on:click={() => (showCreateComment = !showCreateComment)}
class="w-max"
size="lg"
rounding="lg"
color="tertiary"
>
<Icon src={Plus} size="16" mini slot="prefix" />
Add a comment
Expand Down
8 changes: 4 additions & 4 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -3023,10 +3023,10 @@ mlly@^1.2.0, mlly@^1.4.0:
pkg-types "^1.0.3"
ufo "^1.1.2"

mono-svelte@^0.3.7:
version "0.3.7"
resolved "https://registry.yarnpkg.com/mono-svelte/-/mono-svelte-0.3.7.tgz#d8100ca072699d672fb951dc33cb9d9f9fb2b60f"
integrity sha512-hgxFt7JhaX+jLIQNpbi29XJZ5yuYk3kyCX6sEBsUppxcrT/xqN7ajAm8uXaHg/kSORoiIBR38iHftEMMbeaxgA==
mono-svelte@^0.4.1:
version "0.4.1"
resolved "https://registry.yarnpkg.com/mono-svelte/-/mono-svelte-0.4.1.tgz#9237b92aaec435db315967851df651d1650a1936"
integrity sha512-yzDxdQaSJroiL6Yt3qnOIM8thI0d4IB3uOOG0dp/oBemiTtyOBY7niJcXhF0zkU0X/LmarBWYNI8Rs139N2NHw==
dependencies:
svelte-focus-trap "^1.2.0"
svelte-hero-icons "^5.0.0"
Expand Down

0 comments on commit 3bc3258

Please sign in to comment.