import React from 'react';
import { requireNativeComponent, ViewProps } from 'react-native';

/**
 * Define parameters for the whiteboard view.
 */
type WhiteboardViewProps = {
  /**
   * Optional style props for the whiteboard view container.
   */
} & ViewProps;

const NativeWhiteboardView = requireNativeComponent<WhiteboardViewProps>('RNZoomWhiteboardView');

/**
 * Getting whiteboard view from native layer.
 * This component displays the whiteboard when someone is sharing it.
 * The whiteboard will automatically subscribe when the view is mounted.
 */
export const WhiteboardView = (props: WhiteboardViewProps) => {
  return <NativeWhiteboardView {...props} />;
};

