diff options
author | hailey <me@haileyok.com> | 2025-05-02 13:23:39 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2025-05-02 13:23:39 -0700 |
commit | 544f7befe0f7d3e61fb03365ec588a2ab3c5a17a (patch) | |
tree | 9d6276058aeeb44e77cba2b11bcc9e95cb8b7521 /src/lib | |
parent | 46ea3fdbeeab4e31657638955401145683738fbf (diff) | |
download | voidsky-544f7befe0f7d3e61fb03365ec588a2ab3c5a17a.tar.zst |
bump it bop it upgrade it (rn 79/expo 53) (#8281)
* basic bumps * more tweaking * fix rn patch * fix crop picker patch * fix media library patch * rm unnecessary patch * fix notifications patch * update bottomsheet * Update withAppDelegateReferrer.js * Delete withNoBundleCompression.js * rm withNoBundleCompression plugin * rm findLast shim * metro package exports is enabled by default * update react/react-dom/react-compiler * fix reanimated issue * vendor expo-ized emoji popup * fix types * hackfix view full thread * Update EmojiPickerModule.podspec * more upgrades * fix multiformats package version * add baseurl * bump mmkv * bumps * update react-keyed-flatten-children * bump locale packages * fix emoji picker dark mode * rn upgrades * Revert "bump locale packages" This reverts commit fc82f0f173032127dd7c18ed0316ae26f53db51d. * upgrade testing-library * rm test renderer * update patch name minors * rm findNodeHandle from tabbar * only do scrollview tag thing on ios * disable package exports * update expo notifications handler * memoize emoji picker styles * fix tests, mock multiformats * bump some dev deps with RC versions * completely rearchitect toasts * rm logs * layout animation config for composer footer * disable autolinking for patched libs * undo lingui changes * version bump from release candidate to 0.1 * update atproto deps * rm @did-plc/server * fix key issue (maybe) * move URL polyfill to the polyfill file * fix yarn lock * upgrade to 53.0.3 * reanimated layout anim bug patch * workletize a function that wasn't getting autoworkletized anymore (#8309) * bump to expo 53.0.4 * bump RN to 0.79.2 * fix yarn lock ci * Revert "completely rearchitect toasts" This reverts commit 2e2fcaeeed527580a6c485718544b85e8b4f52b9. * final upgrades * chore: cleanup yarn lock * prettier --------- Co-authored-by: Samuel Newman <mozzius@protonmail.com>
Diffstat (limited to 'src/lib')
-rw-r--r-- | src/lib/api/index.ts | 30 | ||||
-rw-r--r-- | src/lib/hooks/useDraggableScrollView.ts | 8 | ||||
-rw-r--r-- | src/lib/hooks/useNotificationHandler.ts | 13 | ||||
-rw-r--r-- | src/lib/strings/starter-pack.ts | 2 |
4 files changed, 28 insertions, 25 deletions
diff --git a/src/lib/api/index.ts b/src/lib/api/index.ts index d1f304d4a..7621fbb4c 100644 --- a/src/lib/api/index.ts +++ b/src/lib/api/index.ts @@ -1,23 +1,23 @@ import { - $Typed, - AppBskyEmbedExternal, - AppBskyEmbedImages, - AppBskyEmbedRecord, - AppBskyEmbedRecordWithMedia, - AppBskyEmbedVideo, - AppBskyFeedPost, + type $Typed, + type AppBskyEmbedExternal, + type AppBskyEmbedImages, + type AppBskyEmbedRecord, + type AppBskyEmbedRecordWithMedia, + type AppBskyEmbedVideo, + type AppBskyFeedPost, AtUri, BlobRef, - BskyAgent, - ComAtprotoLabelDefs, - ComAtprotoRepoApplyWrites, - ComAtprotoRepoStrongRef, + type BskyAgent, + type ComAtprotoLabelDefs, + type ComAtprotoRepoApplyWrites, + type ComAtprotoRepoStrongRef, RichText, } from '@atproto/api' import {TID} from '@atproto/common-web' import * as dcbor from '@ipld/dag-cbor' import {t} from '@lingui/macro' -import {QueryClient} from '@tanstack/react-query' +import {type QueryClient} from '@tanstack/react-query' import {sha256} from 'js-sha256' import {CID} from 'multiformats/cid' import * as Hasher from 'multiformats/hashes/hasher' @@ -35,9 +35,9 @@ import { threadgateAllowUISettingToAllowRecordValue, } from '#/state/queries/threadgate' import { - EmbedDraft, - PostDraft, - ThreadDraft, + type EmbedDraft, + type PostDraft, + type ThreadDraft, } from '#/view/com/composer/state/composer' import {createGIFDescription} from '../gif-alt-text' import {uploadBlob} from './upload-blob' diff --git a/src/lib/hooks/useDraggableScrollView.ts b/src/lib/hooks/useDraggableScrollView.ts index 3471d0d06..05fda9a9f 100644 --- a/src/lib/hooks/useDraggableScrollView.ts +++ b/src/lib/hooks/useDraggableScrollView.ts @@ -1,6 +1,6 @@ -import {ForwardedRef, useEffect, useMemo, useRef} from 'react' -import type {ScrollView} from 'react-native' -import {findNodeHandle, Platform} from 'react-native' +import {type ForwardedRef, useEffect, useMemo, useRef} from 'react' +import {type ScrollView} from 'react-native' +import {Platform} from 'react-native' import {mergeRefs} from '#/lib/merge-refs' @@ -19,7 +19,7 @@ export function useDraggableScroll<Scrollable extends ScrollView = ScrollView>({ if (Platform.OS !== 'web' || !ref.current) { return } - const slider = findNodeHandle(ref.current) as unknown as HTMLDivElement + const slider = ref.current as unknown as HTMLDivElement if (!slider) { return } diff --git a/src/lib/hooks/useNotificationHandler.ts b/src/lib/hooks/useNotificationHandler.ts index b5566f8a6..9c9522aa5 100644 --- a/src/lib/hooks/useNotificationHandler.ts +++ b/src/lib/hooks/useNotificationHandler.ts @@ -4,7 +4,7 @@ import {CommonActions, useNavigation} from '@react-navigation/native' import {useQueryClient} from '@tanstack/react-query' import {useAccountSwitcher} from '#/lib/hooks/useAccountSwitcher' -import {NavigationProp} from '#/lib/routes/types' +import {type NavigationProp} from '#/lib/routes/types' import {logEvent} from '#/lib/statsig/statsig' import {Logger} from '#/logger' import {isAndroid} from '#/platform/detection' @@ -41,10 +41,11 @@ type NotificationPayload = } const DEFAULT_HANDLER_OPTIONS = { - shouldShowAlert: false, + shouldShowBanner: false, + shouldShowList: false, shouldPlaySound: false, shouldSetBadge: true, -} +} satisfies Notifications.NotificationBehavior // These need to stay outside the hook to persist between account switches let storedPayload: NotificationPayload | undefined @@ -195,11 +196,13 @@ export function useNotificationsHandler() { payload.reason === 'chat-message' && payload.recipientDid === currentAccount?.did ) { + const shouldAlert = payload.convoId !== currentConvoId return { - shouldShowAlert: payload.convoId !== currentConvoId, + shouldShowList: shouldAlert, + shouldShowBanner: shouldAlert, shouldPlaySound: false, shouldSetBadge: false, - } + } satisfies Notifications.NotificationBehavior } // Any notification other than a chat message should invalidate the unread page diff --git a/src/lib/strings/starter-pack.ts b/src/lib/strings/starter-pack.ts index ced947b59..01e0256b5 100644 --- a/src/lib/strings/starter-pack.ts +++ b/src/lib/strings/starter-pack.ts @@ -1,6 +1,6 @@ import {AtUri} from '@atproto/api' -import * as bsky from '#/types/bsky' +import type * as bsky from '#/types/bsky' export function createStarterPackLinkFromAndroidReferrer( referrerQueryString: string, |