More clip-cloppy
This commit is contained in:
@@ -50,6 +50,7 @@
|
||||
"open-analyzer": "EXPO_PUBLIC_OPEN_ANALYZER=1 yarn build-web"
|
||||
},
|
||||
"dependencies": {
|
||||
"@atproto-labs/api": "^0.12.8-clipclops.0",
|
||||
"@atproto/api": "^0.12.5",
|
||||
"@bam.tech/react-native-image-resizer": "^3.0.4",
|
||||
"@braintree/sanitize-url": "^6.0.2",
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
import {BskyAgent} from '@atproto-labs/api'
|
||||
import {
|
||||
useInfiniteQuery,
|
||||
useMutation,
|
||||
@@ -299,3 +300,27 @@ export function useChatQuery(chatId: string) {
|
||||
},
|
||||
})
|
||||
}
|
||||
|
||||
export function useConvoQuery(convoId: string) {
|
||||
const headers = useHeaders()
|
||||
const {serviceUrl} = useDmServiceUrlStorage()
|
||||
|
||||
return useQuery({
|
||||
queryKey: ['convoQuery', convoId],
|
||||
queryFn: async () => {
|
||||
const agent = new BskyAgent({
|
||||
service: serviceUrl,
|
||||
})
|
||||
const {data} = await agent.api.chat.bsky.convo.getConvo(
|
||||
{
|
||||
convoId,
|
||||
},
|
||||
{
|
||||
headers,
|
||||
},
|
||||
)
|
||||
|
||||
return data.convo
|
||||
},
|
||||
})
|
||||
}
|
||||
|
||||
@@ -34,6 +34,18 @@
|
||||
jsonpointer "^5.0.0"
|
||||
leven "^3.1.0"
|
||||
|
||||
"@atproto-labs/api@^0.12.8-clipclops.0":
|
||||
version "0.12.8-clipclops.0"
|
||||
resolved "https://registry.yarnpkg.com/@atproto-labs/api/-/api-0.12.8-clipclops.0.tgz#1c5d41d3396e439a0b645f7e1ccf500cc4b42580"
|
||||
integrity sha512-YYDtWWk6BR+aRBVja/1v+gceNK81lkmF5bi6O4pTmJhFt/321XATx/ql8uTWta4VnVThoFeNPG6nLr7hs8b9cA==
|
||||
dependencies:
|
||||
"@atproto/common-web" "^0.3.0"
|
||||
"@atproto/lexicon" "^0.4.0"
|
||||
"@atproto/syntax" "^0.3.0"
|
||||
"@atproto/xrpc" "^0.5.0"
|
||||
multiformats "^9.9.0"
|
||||
tlds "^1.234.0"
|
||||
|
||||
"@atproto/api@^0.12.3":
|
||||
version "0.12.3"
|
||||
resolved "https://registry.yarnpkg.com/@atproto/api/-/api-0.12.3.tgz#5b7b1c7d4210ee9315961504900c8409395cbb17"
|
||||
|
||||
Reference in New Issue
Block a user