Fix a few small bugs

This commit is contained in:
Jonathan Staab 2023-04-19 08:54:14 -05:00
parent 9e18bb1f3e
commit b46fde360b
4 changed files with 16 additions and 15 deletions

View File

@ -181,7 +181,7 @@
<div class="flex justify-between text-gray-1" on:click|stopPropagation>
<div class="flex">
<button
class={cx("w-14 text-left", {
class={cx("w-16 text-left", {
"pointer-events-none opacity-50": disableActions,
})}
on:click={reply.start}>
@ -189,7 +189,7 @@
{$repliesCount}
</button>
<button
class={cx("w-14 text-left", {
class={cx("w-16 text-left", {
"pointer-events-none opacity-50": disableActions,
"text-accent": like,
})}
@ -201,7 +201,7 @@
{$likesCount}
</button>
<button
class={cx("w-16 text-left", {
class={cx("w-20 text-left", {
"pointer-events-none opacity-50": disableActions,
"text-accent": zap,
})}

View File

@ -40,7 +40,9 @@
return toast.show("error", "A name is required for your list")
}
if (find(e => e.id !== list.id && Tags.from(e).getMeta("d") === values.name, user.getLists())) {
if (
find(e => e.id !== list?.id && Tags.from(e).getMeta("d") === values.name, user.getLists())
) {
return toast.show("error", "That name is already in use")
}

View File

@ -66,16 +66,15 @@
<i slot="before" class={`fa fa-${icon}`} />
</Input>
{/if}
<div
on:click={() => {
isOpen = true
}}>
<slot name="button">
<Anchor type="button">
<i class="fa fa-upload" />
</Anchor>
</slot>
</div>
<slot name="button">
<Anchor
type="button"
on:click={() => {
isOpen = true
}}>
<i class="fa fa-upload" />
</Anchor>
</slot>
</div>
{#if quote}

View File

@ -35,7 +35,7 @@
trigger: triggerType,
animation: "shift-away",
onShow: () => {
const [tooltipContents] = tooltip.children
const [tooltipContents] = tooltip?.children || []
// If we've already triggered it, tooltipContents will be empty
if (tooltipContents) {