finish phase 3: type-only codemod and zero non-bridge @atproto/api imports

Task 8: codemod repointed 150 namespace-type files to #/lexicons
(AppBskyFeedDefs.PostView -> app.bsky.feed.defs.PostView, .Record -> .Main)
plus ~105 hand-fixed consumers (composer/video state, DebugMod, Profile,
onboarding, dialogs). DM_SERVICE_HEADERS deleted; last chat call sites on
the chat client. RichText.tsx flipped to SDK-only. Remaining @atproto/api
importers: the three session bridge files, the deliberate dual-world
matcher in lib/xrpc-error.ts, and test fixtures. toLex boundary casts are
TODO(phase4)-tagged for bridge removal.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
Samuel Newman
2026-07-17 02:08:48 +03:00
parent 300a50b69a
commit e7d349bc30
283 changed files with 2029 additions and 1806 deletions
+1 -1
View File
@@ -14,7 +14,7 @@ import {
type LiveEventFeed,
type LiveEventFeedMetricContext,
} from '#/features/liveEvents/types'
import {app} from '#/lexicons'
import {type app} from '#/lexicons'
export type LiveEventPreferencesAction = Parameters<
typeof updateLiveEventPreferences
@@ -1,6 +1,5 @@
import {useCallback, useState} from 'react'
import {View} from 'react-native'
import {type AppBskyActorDefs} from '@atproto/api'
import {api} from '@bsky.app/sdk'
import {msg} from '@lingui/core/macro'
import {useLingui} from '@lingui/react'
@@ -15,7 +14,7 @@ import * as Dialog from '#/components/Dialog'
import {Loader} from '#/components/Loader'
import * as Toast from '#/components/Toast'
import {Text} from '#/components/Typography'
import {com, tools} from '#/lexicons'
import {type app, com, tools} from '#/lexicons'
import {toLex} from '#/types/bsky'
export function GoLiveDisabledDialog({
@@ -23,7 +22,7 @@ export function GoLiveDisabledDialog({
status,
}: {
control: Dialog.DialogControlProps
status: AppBskyActorDefs.StatusView
status: app.bsky.actor.defs.StatusView
}) {
return (
<Dialog.Outer control={control} nativeOptions={{preventExpansion: true}}>
@@ -38,7 +37,7 @@ export function DialogInner({
status,
}: {
control: Dialog.DialogControlProps
status: AppBskyActorDefs.StatusView
status: app.bsky.actor.defs.StatusView
}) {
const {_} = useLingui()
const {currentAccount} = useSession()
+2 -2
View File
@@ -332,7 +332,7 @@ export function useUpsertLiveStatusMutation(
$type: 'app.bsky.actor.defs#statusView',
status: 'app.bsky.actor.status#live',
isActive: true,
expiresAt: expiresAt.toISOString(),
expiresAt: expiresAt.toISOString() as DatetimeString,
embed:
record.embed && image
? {
@@ -340,7 +340,7 @@ export function useUpsertLiveStatusMutation(
external: {
...record.embed.external,
$type: 'app.bsky.embed.external#viewExternal',
thumb: image,
thumb: image as UriString,
},
}
: undefined,