Hydrate body ranges for story replies
This commit is contained in:
parent
9f85db3fd8
commit
be6e988a95
39 changed files with 221 additions and 172 deletions
|
@ -6,8 +6,7 @@ import React, { useCallback, useEffect, useRef, useState } from 'react';
|
|||
import { get } from 'lodash';
|
||||
import classNames from 'classnames';
|
||||
import type {
|
||||
BodyRangeType,
|
||||
BodyRangesType,
|
||||
DraftBodyRangesType,
|
||||
LocalizerType,
|
||||
ThemeType,
|
||||
} from '../types/Util';
|
||||
|
@ -116,7 +115,7 @@ export type OwnProps = Readonly<{
|
|||
onSelectMediaQuality(isHQ: boolean): unknown;
|
||||
onSendMessage(options: {
|
||||
draftAttachments?: ReadonlyArray<AttachmentDraftType>;
|
||||
mentions?: BodyRangesType;
|
||||
mentions?: DraftBodyRangesType;
|
||||
message?: string;
|
||||
timestamp?: number;
|
||||
voiceNoteAttachment?: InMemoryAttachmentDraftType;
|
||||
|
@ -276,7 +275,7 @@ export const CompositionArea = ({
|
|||
}, [inputApiRef, setLarge]);
|
||||
|
||||
const handleSubmit = useCallback(
|
||||
(message: string, mentions: Array<BodyRangeType>, timestamp: number) => {
|
||||
(message: string, mentions: DraftBodyRangesType, timestamp: number) => {
|
||||
emojiButtonRef.current?.close();
|
||||
onSendMessage({
|
||||
draftAttachments,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue