A modal dialog window. This component uses the react-modal library. The component presents a propup window with a title bar and a close button.
import {DialogWindow} from 'gadgets';
<DialogWindow
height="600px"
icon="plane"
onClose={this.handleCloseDialog}
onOpen={this.handleOpenDialog}
show={true}
title="Demo Dialog Window"
width="600px"
>
<span>Dialog Content</span>
</DialogWindow>
onClose()
- callback invoked when the dialog window is closed.onOpen()
- callback invoked when the dialog window is opened.
ui-dialogwindow
- Placed on the main<div>
component that surrounds the whole component.ui-dialogwindow-content
- Placed on the<div>
that surrounds the child content given to the window.
height="400px" {string}
- the height, in pixels, of the dialog areaicon="window-restore" {string}
- A font awesome icon that will be on the right side of the title barshow=false {boolean}
- when set to true the window is shown, otherwise it is hidden.title="Dialog Window" {string}
- A text string shown within the title bar of the dialog windowwidth="400px" {string}
- the width, in pixels, of the dialog area