lint/format

This commit is contained in:
Jon Staab
2024-10-10 17:15:20 -07:00
parent 597ebddf82
commit 46965f5945
12 changed files with 60 additions and 52 deletions
+2 -6
View File
@@ -1,9 +1,7 @@
<script lang="ts">
import {onMount} from "svelte"
import {page} from "$app/stores"
import {ago} from "@welshman/lib"
import {displayRelayUrl, REACTION, NOTE, EVENT_DATE, EVENT_TIME, CLASSIFIED} from "@welshman/util"
import {subscribe} from "@welshman/app"
import {displayRelayUrl} from "@welshman/util"
import {fly, slide} from "@lib/transition"
import Icon from "@lib/components/Icon.svelte"
import Page from "@lib/components/Page.svelte"
@@ -20,11 +18,9 @@
getMembershipRoomsByUrl,
getMembershipUrls,
userMembership,
pullConservatively,
roomsByUrl,
decodeNRelay,
GENERAL,
MESSAGE,
} from "@app/state"
import {checkRelayConnection, checkRelayAuth} from "@app/commands"
import {pushModal} from "@app/modal"
@@ -63,7 +59,7 @@
$: otherRooms = ($roomsByUrl.get(url) || []).filter(room => !rooms.concat(GENERAL).includes(room))
onMount(async () => {
const error = await checkRelayConnection(url) || await checkRelayAuth(url)
const error = (await checkRelayConnection(url)) || (await checkRelayAuth(url))
if (error) {
pushToast({theme: "error", message: error})
@@ -1,10 +1,10 @@
<script lang="ts">
import {onMount} from 'svelte'
import {onMount} from "svelte"
import {page} from "$app/stores"
import {sortBy, last, ago} from "@welshman/lib"
import type {TrustedEvent} from "@welshman/util"
import {EVENT_DATE, EVENT_TIME} from "@welshman/util"
import {repository, subscribe, formatTimestampAsDate, trackerStore} from "@welshman/app"
import {subscribe, formatTimestampAsDate} from "@welshman/app"
import Icon from "@lib/components/Icon.svelte"
import Button from "@lib/components/Button.svelte"
import Spinner from "@lib/components/Spinner.svelte"
@@ -31,7 +31,6 @@
dateDisplay?: string
}
$: items = sortBy(getStart, $events).reduce<Item[]>((r, event) => {
const prevDateDisplay =
r.length > 0 ? formatTimestampAsDate(getStart(last(r).event)) : undefined
@@ -3,8 +3,8 @@
import {page} from "$app/stores"
import {NOTE} from "@welshman/util"
import {feedFromFilter} from "@welshman/feeds"
import {ago, nthEq, sortBy} from "@welshman/lib"
import {repository, trackerStore, feedLoader} from "@welshman/app"
import {nthEq} from "@welshman/lib"
import {feedLoader} from "@welshman/app"
import {createScroller} from "@lib/html"
import Icon from "@lib/components/Icon.svelte"
import Button from "@lib/components/Button.svelte"
@@ -13,7 +13,7 @@
import ThreadItem from "@app/components/ThreadItem.svelte"
import ThreadCreate from "@app/components/ThreadCreate.svelte"
import {pushModal} from "@app/modal"
import {pullConservatively, deriveEventsForUrl, decodeNRelay} from "@app/state"
import {deriveEventsForUrl, decodeNRelay} from "@app/state"
const url = decodeNRelay($page.params.nrelay)
const kinds = [NOTE]