TelegramPWA/src/components/middle/composer/AttachmentModal.async.tsx
2025-06-04 20:36:48 +02:00

18 lines
569 B
TypeScript

import type { FC } from '../../../lib/teact/teact';
import React from '../../../lib/teact/teact';
import type { OwnProps } from './AttachmentModal';
import { Bundles } from '../../../util/moduleLoader';
import useModuleLoader from '../../../hooks/useModuleLoader';
const AttachmentModalAsync: FC<OwnProps> = (props) => {
const { attachments } = props;
const AttachmentModal = useModuleLoader(Bundles.Extra, 'AttachmentModal', !attachments.length);
return AttachmentModal ? <AttachmentModal {...props} /> : undefined;
};
export default AttachmentModalAsync;