@vonage/vivid-react
Version:
Vivid wrapped for easy React usage & IDE autocomplete support & typescript typings
44 lines (43 loc) • 2.43 kB
TypeScript
import React, { ReactNode, SyntheticEvent } from 'react';
/** VwcAlert
* For more info on this Vivid element please visit https://vivid.deno.dev/components/alert
* @param {| string
| null} dismissButtonAriaLabel - Allows setting a custom aria-label for the dismiss button. **attribute** `dismiss-button-aria-label`
* @param {boolean} removable - Adds a close button to the Alert. **attribute** `removable`
* @param {AlertPlacement | undefined} placement - The placement of the Alert on the screen. **attribute** `placement`
* @param {string | undefined} headline - Adds a headline to the Alert. **attribute** `headline`
* @param {string | undefined} text - The main text of the Alert. **attribute** `text`
* @param {number} timeoutms - Timeout after which the Alert will close. **attribute** `timeoutms`
* @param {AlertConnotation | undefined} connotation - Sets an appropriate icon / icon color for the connotation. **attribute** `connotation`
* @param {AlertStrategy | undefined} strategy - Controls the `position` of the Alert. **attribute** `strategy`
* @param {boolean} open - Open state of the Alert. **attribute** `open`
* @param {string | undefined} icon - A decorative icon the custom element should have. **attribute** `icon`
* @param {string} VIVID_VERSION - The current version of the Vivid library, which is useful for debugging.
It can be accessed from any Vivid element via `<el>.constructor.VIVID_VERSION`.
* @param {string} componentName - Core component name, without prefix
*/
declare const VwcAlert: {
(props: {
children?: ReactNode;
slot?: string | undefined;
id?: string | undefined;
style?: React.CSSProperties | undefined;
ref?: React.RefObject<HTMLDivElement> | ((instance: HTMLDivElement | null) => void) | null | undefined;
onOpen?: ((event: SyntheticEvent) => void) | undefined;
onClose?: ((event: SyntheticEvent) => void) | undefined;
dismissButtonAriaLabel?: any;
removable?: boolean | undefined;
placement?: any;
headline?: string | undefined;
text?: string | undefined;
timeoutms?: number | undefined;
connotation?: any;
strategy?: any;
open?: boolean | undefined;
icon?: string | undefined;
VIVID_VERSION?: string | undefined;
componentName?: string | undefined;
}): JSX.Element;
displayName: string;
};
export default VwcAlert;