Drop accidental eslint dependency (#11460)
This commit is contained in:
@@ -142,8 +142,7 @@ export function invalidateJoinLinkPreviewsForConvo(
|
||||
const [root] = query.queryKey
|
||||
if (root !== joinLinkPreviewQueryKeyRoot) return false
|
||||
const data = query.state.data as
|
||||
| chat.bsky.group.getJoinLinkPreviews.$OutputBody
|
||||
| undefined
|
||||
chat.bsky.group.getJoinLinkPreviews.$OutputBody | undefined
|
||||
return (
|
||||
data?.joinLinkPreviews.some(
|
||||
preview =>
|
||||
|
||||
@@ -38,10 +38,7 @@ export const RQKEY = (
|
||||
readState: 'all' | 'unread' = 'all',
|
||||
kind: 'all' | 'group' | 'direct' = 'all',
|
||||
lockStatus:
|
||||
| 'unlocked'
|
||||
| 'locked'
|
||||
| 'locked-permanently'
|
||||
| undefined = undefined,
|
||||
'unlocked' | 'locked' | 'locked-permanently' | undefined = undefined,
|
||||
limit?: number,
|
||||
) => [RQKEY_ROOT, status, readState, kind, lockStatus, limit] as const
|
||||
|
||||
@@ -255,9 +252,9 @@ export function ListConvosProviderInner({
|
||||
// memberCount bump to avoid double-counting.
|
||||
const alreadyKnownMember =
|
||||
queryClient
|
||||
.getQueryData<
|
||||
chat.bsky.actor.defs.ProfileViewBasic[]
|
||||
>(listConvoMembersQueryKey(convoId))
|
||||
.getQueryData<chat.bsky.actor.defs.ProfileViewBasic[]>(
|
||||
listConvoMembersQueryKey(convoId),
|
||||
)
|
||||
?.some(m => m.did === did) ?? false
|
||||
mutateMembers(convoId, list =>
|
||||
list.some(m => m.did === did) ? list : list.concat(newMember),
|
||||
@@ -279,9 +276,9 @@ export function ListConvosProviderInner({
|
||||
// list, skip the memberCount decrement to avoid double-counting.
|
||||
const alreadyRemovedMember =
|
||||
queryClient
|
||||
.getQueryData<
|
||||
chat.bsky.actor.defs.ProfileViewBasic[]
|
||||
>(listConvoMembersQueryKey(convoId))
|
||||
.getQueryData<chat.bsky.actor.defs.ProfileViewBasic[]>(
|
||||
listConvoMembersQueryKey(convoId),
|
||||
)
|
||||
?.some(m => m.did === did) === false
|
||||
mutateMembers(convoId, list => list.filter(m => m.did !== did))
|
||||
mutateConvoView(
|
||||
|
||||
@@ -6,10 +6,7 @@ import {useAppviewClient, useSession} from '#/state/session'
|
||||
import {app} from '#/lexicons'
|
||||
|
||||
export type MyListsFilter =
|
||||
| 'all'
|
||||
| 'curate'
|
||||
| 'mod'
|
||||
| 'all-including-subscribed'
|
||||
'all' | 'curate' | 'mod' | 'all-including-subscribed'
|
||||
|
||||
const RQKEY_ROOT = 'my-lists'
|
||||
export const RQKEY = (filter: MyListsFilter) => [RQKEY_ROOT, filter]
|
||||
|
||||
@@ -3,8 +3,7 @@ import {type app} from '#/lexicons'
|
||||
export type Notification = app.bsky.notification.listNotifications.Notification
|
||||
|
||||
export type NotificationType =
|
||||
| StarterPackNotificationType
|
||||
| OtherNotificationType
|
||||
StarterPackNotificationType | OtherNotificationType
|
||||
|
||||
export type FeedNotification =
|
||||
| (FeedNotificationBase & {
|
||||
@@ -56,6 +55,5 @@ type FeedNotificationBase = {
|
||||
additional?: Notification[]
|
||||
subjectUri?: string
|
||||
subject?:
|
||||
| app.bsky.feed.defs.PostView
|
||||
| app.bsky.graph.defs.StarterPackViewBasic
|
||||
app.bsky.feed.defs.PostView | app.bsky.graph.defs.StarterPackViewBasic
|
||||
}
|
||||
|
||||
@@ -89,9 +89,7 @@ export function createMaybeDetachedQuoteEmbed({
|
||||
quoteUri: AtUriString
|
||||
detached: true
|
||||
}):
|
||||
| app.bsky.embed.record.View
|
||||
| app.bsky.embed.recordWithMedia.View
|
||||
| undefined {
|
||||
app.bsky.embed.record.View | app.bsky.embed.recordWithMedia.View | undefined {
|
||||
if (bsky.isType(app.bsky.embed.record.view, post.embed)) {
|
||||
if (detached) {
|
||||
return createEmbedViewDetachedRecord({uri: quoteUri})
|
||||
|
||||
@@ -16,11 +16,6 @@ export type UsePreferencesQueryResponse = Omit<
|
||||
|
||||
export type ThreadViewPreferences = {
|
||||
sort:
|
||||
| 'hotness'
|
||||
| 'oldest'
|
||||
| 'newest'
|
||||
| 'most-likes'
|
||||
| 'random'
|
||||
| (string & {})
|
||||
'hotness' | 'oldest' | 'newest' | 'most-likes' | 'random' | (string & {})
|
||||
lab_treeViewEnabled?: boolean
|
||||
}
|
||||
|
||||
@@ -206,12 +206,13 @@ function mergeList(a?: string[], b?: string[]): string[] | undefined {
|
||||
* than re-validated here. `q`, `limit`, `cursor` and `sort` are the caller's.
|
||||
*/
|
||||
type SearchPostsV2FilterParams = {
|
||||
[K in Exclude<
|
||||
keyof app.bsky.feed.searchPostsV2.$Params,
|
||||
'query' | 'limit' | 'cursor' | 'sort'
|
||||
>]?: app.bsky.feed.searchPostsV2.$Params[K] extends
|
||||
| readonly (infer _E)[]
|
||||
| undefined
|
||||
[
|
||||
K in Exclude<
|
||||
keyof app.bsky.feed.searchPostsV2.$Params,
|
||||
'query' | 'limit' | 'cursor' | 'sort'
|
||||
>
|
||||
]?: app.bsky.feed.searchPostsV2.$Params[K] extends
|
||||
readonly (infer _E)[] | undefined
|
||||
? string[]
|
||||
: app.bsky.feed.searchPostsV2.$Params[K] extends string | undefined
|
||||
? string
|
||||
|
||||
Reference in New Issue
Block a user