import React from 'react'; import { StyleProp, ViewStyle } from 'react-native'; import { CustomButton } from './CustomButtons'; import { EventType } from '../../@types/types'; /** * Configuration options for the `MenuModal` component. * * @interface MenuModalOptions * * **Modal Control:** * @property {boolean} isVisible Controls the modal visibility state. * @property {() => void} onClose Handler invoked to dismiss the modal. * * **Appearance:** * @property {string} [backgroundColor='#83c0e9'] Background fill applied to the modal card. * @property {'topRight' | 'topLeft' | 'bottomRight' | 'bottomLeft'} [position='bottomRight'] Preferred anchor location. * @property {StyleProp} [style] Additional styles merged into the modal container. * * **Meeting Metadata:** * @property {string} roomName Human-readable meeting identifier. * @property {string} adminPasscode Host/admin passcode displayed to privileged users. * @property {string} islevel Participant level used to gate passcode visibility (level `'2'` shows the passcode). * @property {EventType} eventType Event classification used by share helpers. * @property {string} [localLink] URL for self-hosted Community Edition shares. * * **Menu Content:** * @property {CustomButton[]} [customButtons] Optional array of bespoke menu actions. * @property {boolean} [shareButtons=true] Toggles the share/action button group. * * **Advanced Render Overrides:** * @property {(options: { defaultContent: JSX.Element; dimensions: { width: number; height: number } }) => JSX.Element} [renderContent] * Override to replace the default internal layout. * @property {(options: { defaultContainer: JSX.Element; dimensions: { width: number; height: number } }) => JSX.Element} [renderContainer] * Override to swap the surrounding modal container implementation. */ export interface MenuModalOptions { backgroundColor?: string; isVisible: boolean; onClose: () => void; customButtons?: CustomButton[]; shareButtons?: boolean; position?: 'topRight' | 'topLeft' | 'bottomRight' | 'bottomLeft'; roomName: string; adminPasscode: string; islevel: string; eventType: EventType; localLink?: string; style?: StyleProp; renderContent?: (options: { defaultContent: JSX.Element; dimensions: { width: number; height: number; }; }) => JSX.Element; renderContainer?: (options: { defaultContainer: JSX.Element; dimensions: { width: number; height: number; }; }) => JSX.Element; } export type MenuModalType = (options: MenuModalOptions) => JSX.Element; /** * MenuModal offers a consolidated hub for meeting metadata, quick actions, and sharing shortcuts. * Hosts and facilitators can expose custom buttons, reveal passcodes, and copy/share meeting details * without navigating away from the current screen. * * ### Key Features * - Auto-resizes based on screen width with a 450px cap for consistent layout. * - Supports custom call-to-actions via `customButtons` with iconography. * - Conditionally reveals admin passcodes for elevated users (level `'2'`). * - Integrates share helpers for room links, event type metadata, and local CE URLs. * - Provides `renderContent` and `renderContainer` overrides for deep customization. * - Anchorable to any corner of the screen using `position`. * * ### Accessibility * - Close button carries descriptive labels for assistive technologies. * - Scrollable content maintains keyboard navigation through focusable items. * * @param {MenuModalOptions} props Modal configuration options. * @returns {JSX.Element} Rendered meeting menu modal. * * @example Basic meeting info menu with default share buttons. * ```tsx * * ``` * * @example Custom action buttons and dark theme styling. * ```tsx * * ``` * * @example Advanced UI override with custom container. * ```tsx * ( * {defaultContainer} * )} * /> * ``` */ declare const MenuModal: React.FC; export default MenuModal;