12 lines
1.2 KiB
TypeScript
12 lines
1.2 KiB
TypeScript
// Metro module 13043 (f13044).
|
|
import { useShareChatInputActions } from "./useShareChatInputActions";
|
|
import ShareFooterLayout from "./ShareFooterLayout";
|
|
import { Button } from "../../../design/components/Button/native/Button.native";
|
|
import ShareChatInput from "./ShareChatInput";
|
|
export default function ShareScreenFooter(props) {
|
|
const { text, setText, preview, sendLabel, canSend, isSending, onSend, appEntryKey, disabled = false } = props;
|
|
const shareChatInputActions = useShareChatInputActions(setText, void 0, appEntryKey);
|
|
const { textInputRef, isInputFocused } = shareChatInputActions;
|
|
return <ShareFooterLayout preview={preview} sendButton={<Button variant="primary" size="md" text={sendLabel} disabled={canSend ? disabled : !canSend} onPress={isSending ? void 0 : onSend} loading={isSending} />} chatInput={<ShareChatInput inputRef={textInputRef} text={text} onChange={setText} onSelectionChange={shareChatInputActions.handleSelectionChange} onFocus={shareChatInputActions.handleMessageFocus} onBlur={shareChatInputActions.handleMessageBlur} onPressEmoji={shareChatInputActions.handlePressEmoji} onSend={onSend} disabled={disabled} />} avoidKeyboard={isInputFocused} />;
|
|
};
|