bigbluebutton-html-plugin-sdk
Version:
This repository contains the SDK for developing BigBlueButton plugins. Plugins are React components that can be loaded from external sources by the BigBlueButton HTML5 client to extend its functionalities.
88 lines (87 loc) • 4.19 kB
TypeScript
import { ChangeEvent, MouseEvent } from 'react';
import { ActionsBarPosition, ActionsBarItemType } from './enums';
import { ActionsBarInterface, ActionsBarItemProps, ActionsBarButtonProps, ActionsBarSeparatorProps, ActionsBarSelectorProps, SelectOption, ToggleGroupOption, ActionsBarToggleGroupProps } from './types';
declare class ActionsBarItem implements ActionsBarInterface {
id: string;
type: ActionsBarItemType;
position: ActionsBarPosition;
constructor({ id, type, position, }: ActionsBarItemProps);
setItemId(id: string): void;
}
export declare class ActionsBarButton extends ActionsBarItem {
icon: string;
tooltip: string;
onClick: () => void;
/**
* Returns object to be used in the setter for action bar. In this case,
* a button.
*
* @param icon - icon to be used in the button for the action bar
* @param tooltip - tooltip to be displayed when hovering the button
* @param onClick - function to be called when clicking the button
* @param position - position that this button will be displayed, see {@link ActionsBarPosition}
*
* @returns Object that will be interpreted by the core of Bigbluebutton (HTML5)
*/
constructor({ id, icon, tooltip, onClick, position, }: ActionsBarButtonProps);
}
export declare class ActionsBarSeparator extends ActionsBarItem {
icon: string;
/**
* Returns object to be used in the setter for action bar. In this case,
* a separator.
*
* @param position - position that this button will be displayed, see {@link ActionsBarPosition}
* @param icon - Icon to be displayed as the separator. If not provided, the default separator
* (a vertical bar) will be displayed.
*
* @returns Object that will be interpreted by the core of Bigbluebutton (HTML5)
*/
constructor({ position, icon, }: ActionsBarSeparatorProps);
}
export declare class ActionsBarSelector extends ActionsBarItem {
title: string;
options: SelectOption[];
defaultOption: SelectOption;
onChange: (value: string | number, event: ChangeEvent<HTMLInputElement>) => void;
width: number;
/**
* Returns object to be used in the setter for action bar. In this case,
* a selector.
*
* @param title - title to be used in the selector for the actions bar
* @param options - an array of options to be available in the selector
* @param defaultOption - the option to be initially selected, if not present, the first option is
* selected
* @param onChange - function to be called when selected value changes
* @param position - position that this button will be displayed, see {@link ActionsBarPosition}
* @param width - desired width for the selector in px, default is 140
*
* @returns Object that will be interpreted by the core of Bigbluebutton (HTML5)
*/
constructor({ id, title, options, defaultOption, onChange, position, width, }: ActionsBarSelectorProps);
}
export declare class ActionsBarToggleGroup extends ActionsBarItem {
title: string;
exclusive: boolean;
options: ToggleGroupOption[];
defaultOption: ToggleGroupOption;
onChange: (values: string | number | string[] | number[], event: MouseEvent<HTMLElement>) => void;
/**
* Returns object to be used in the setter for action bar. In this case,
* a toggle group.
*
* @param title - title to be used in the selector for the actions bar
* @param exclusive - whether the toggle group should be exclusive or not - allow checking
* multiple options
* @param options - an array of options to be available in the toggle group
* @param defaultOption - the option to be initially checked, if not present, the first option is
* checked
* @param onChange - function to be called when checked value changes
* @param position - position that this button will be displayed, see {@link ActionsBarPosition}
*
* @returns Object that will be interpreted by the core of Bigbluebutton (HTML5)
*/
constructor({ id, title, exclusive, options, defaultOption, onChange, position, }: ActionsBarToggleGroupProps);
}
export {};