Skip to content

Commit 9d533be

Browse files
committed
docs(breaking-changes): correct four SDK-mismatch claims
Same four fixes applied to ai-migration.md, now also at source so the audit tracker matches the installed v14 SDK: - BC-008: useMessageComposer().initState(...) → useMessageComposerController().initState(...) (the former hook does not exist). Also correct the file ref to src/components/MessageActions/MessageActions.defaults.tsx:160. - BC-021: FileIconProps still exposes size (retyped to FileIconSize 'sm' | 'md' | 'lg' | 'xl') and adds sizeConfig; only big, sizeSmall, type were removed. - BC-025: ModalGallery no longer accepts initialIndex. Rename guidance now points consumers at Gallery + GalleryUI when a non-zero starting item is required. - BC-059: usePinHandler v14 signature is (message), not (message, notifications?). Notifications are published internally via useNotificationApi().
1 parent b6a220c commit 9d533be

1 file changed

Lines changed: 9 additions & 7 deletions

File tree

ai-docs/breaking-changes.md

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -239,7 +239,7 @@ Only confirmed items should move from this file into the migration guide.
239239
- `src/context/MessageContext.tsx:143` `setTranslationView`
240240
- Replacement:
241241
- delete handlers should call `handleDelete(options?)` without an event argument
242-
- edit flows now go through `MessageComposer`; current default message actions call `useMessageComposer().initState({ composition: message })` in `src/components/MessageActions/defaults.tsx:163`
242+
- edit flows now go through `MessageComposer`; current default message actions call `useMessageComposerController().initState({ composition: message })` in `src/components/MessageActions/MessageActions.defaults.tsx:160`
243243
- custom message actions need to be implemented through the new `MessageActions` customization surface instead of `customMessageActions`
244244
- Evidence:
245245
- current `MessageContextValue` removes the old edit-state and custom-action fields
@@ -763,11 +763,13 @@ Only confirmed items should move from this file into the migration guide.
763763
- `v13.14.2:src/components/ReactFileUtilities/FileIcon/FileIcon.tsx:6` `FileIconProps` exposed `big`, `filename`, `mimeType`, `size`, `sizeSmall`, and `type`
764764
- `v13.14.2:src/components/ReactFileUtilities/FileIcon/FileIcon.tsx:16` `mimeTypeToIcon(type, mimeType)`
765765
- New API:
766-
- `src/components/FileIcon/FileIcon.tsx:5` `FileIconProps` expose only `className`, `fileName`, and `mimeType`
766+
- `src/components/FileIcon/FileIcon.tsx:5` `FileIconProps` expose `className`, `fileName`, `mimeType`, `size`, and `sizeConfig`
767767
- `src/components/FileIcon/FileIcon.tsx:11` `mimeTypeToIcon(mimeType?)`
768+
- `size` is retyped from a pixel number to `FileIconSize` (`'sm' | 'md' | 'lg' | 'xl'`); `sizeConfig` is a new optional per-size dimension override
768769
- Replacement:
769770
- rename `filename` to `fileName`
770-
- remove `big`, `size`, `sizeSmall`, and `type`
771+
- remove `big`, `sizeSmall`, and `type`
772+
- migrate any custom numeric `size` values to one of `'sm' | 'md' | 'lg' | 'xl'`; use `sizeConfig` if custom pixel dimensions are required
771773
- style the rendered icon through `className` or a wrapper instead of size-mode props
772774
- Evidence:
773775
- current file-icon implementation uses an internal label renderer and no longer passes size variants into the icon set
@@ -928,7 +930,7 @@ Only confirmed items should move from this file into the migration guide.
928930
- Replacement:
929931
- if you need the old thumbnail-grid-plus-lightbox behavior, use `ModalGallery`
930932
- if you customize the gallery carousel itself, migrate to the new `Gallery` provider API and a custom `GalleryUI`
931-
- rename `ModalGallery` props from `images` / `index` to `items` / `initialIndex` semantics as appropriate
933+
- rename `ModalGallery` props from `images` / `index` to `items`; `ModalGallery` no longer accepts an `index` / `initialIndex` prop (use `Gallery` + `GalleryUI` with `initialIndex` if a non-zero starting item is required)
932934
- rewrite custom `Image` components against the new `GalleryItem` contract and let `ModalGallery` own modal state
933935
- Evidence:
934936
- current `Gallery` is no longer a visible thumbnail-grid component by itself unless a `GalleryUI` is supplied
@@ -2024,7 +2026,7 @@ Only confirmed items should move from this file into the migration guide.
20242026
- Area: deprecated API cleanup
20252027
- User impact:
20262028
- imports or props using `pinPermissions`, `PinPermissions`, `PinEnabledUserRoles`, or `defaultPinPermissions` no longer compile
2027-
- custom `usePinHandler(message, pinPermissions, notifications)` calls must be rewritten to the new two-argument signature
2029+
- custom `usePinHandler(message, pinPermissions, notifications)` calls must be rewritten to the new one-argument signature `usePinHandler(message)` (notifications are now published internally via `useNotificationApi()`)
20282030
- wrappers around `InfiniteScroll`, `LoadMoreButton`, and `LoadMorePaginator` can no longer use the deprecated alias props `hasMore`, `hasMoreNewer`, `loadMore`, `loadMoreNewer`, or `refreshing`
20292031
- top-level imports using `UploadButton` / `UploadButtonProps` no longer resolve; use `FileInput` / `FileInputProps` instead
20302032
- `ChannelListItemUI` no longer accepts the deprecated `latestMessage` alias; use `latestMessagePreview`
@@ -2041,7 +2043,7 @@ Only confirmed items should move from this file into the migration guide.
20412043
- `v13.14.2:src/plugins/Emojis/EmojiPicker.tsx:30` exposed `popperOptions?: Partial<{ placement: PopperLikePlacement }>`
20422044
- `git grep` on `v13.14.2` finds public exports for `StreamEmoji`, `moveChannelUp`, `hasNotMoreMessages`, `useChannelDeletedListener`, `useNotificationMessageNewListener`, and the rest of the old standalone channel-list listener hooks
20432045
- New API:
2044-
- `src/components/Message/hooks/usePinHandler.ts:16` through `:19` now accept only `(message, notifications?)`
2046+
- `src/components/Message/hooks/usePinHandler.ts:16` through `:19` now accept only `(message)` (no second argument)
20452047
- current source has no `PinPermissions`, `PinEnabledUserRoles`, or `defaultPinPermissions`
20462048
- `src/components/InfiniteScrollPaginator/InfiniteScroll.tsx:16` through `:23` now expose only `hasNextPage`, `hasPreviousPage`, `loadNextPage`, and `loadPreviousPage` through `PaginatorProps`
20472049
- `src/types/types.ts:14` through `:18` expose `hasNextPage`, `hasPreviousPage`, and `isLoading`, with no `refreshing`
@@ -2052,7 +2054,7 @@ Only confirmed items should move from this file into the migration guide.
20522054
- current `rg` over `src` returns no `StreamEmoji`, `moveChannelUp`, `hasNotMoreMessages`, `useChannelDeletedListener`, `useNotificationMessageNewListener`, or sibling standalone listener-hook exports
20532055
- Replacement:
20542056
- remove `pinPermissions` customization and rely on `channelCapabilities['pin-message']`
2055-
- rewrite `usePinHandler(message, notifications?)` callers to the new signature
2057+
- rewrite `usePinHandler` callers to the new one-argument signature `usePinHandler(message)`
20562058
- update paginator wrappers to `hasNextPage`, `hasPreviousPage`, `loadNextPage`, `loadPreviousPage`, and `isLoading`
20572059
- replace top-level `UploadButton` imports with `FileInput`
20582060
- replace `latestMessage` with `latestMessagePreview`

0 commit comments

Comments
 (0)