theophilusx.yorick.modal
Provides a modal overlay window which can contain almost any content.
modal
(modal body sid model & {:keys [classes]})A basic modal overlay component. The body argument is the content to put into the overlay. It can be HTML, a string or another component. The sid argument is a storage identifier keyword used to determine where to store the modal state (either active or inactive). The model argument is a reagent atom used as the document model store. This component also supports an optional keyword argument :classes, which is a map of strings or vectors of strings representing CSS class names. The supported keys are:
| Keyword | Description |
|---|---|
:modal |
CSS class names to associate with the enclosing modal div |
:background |
CSS class names to associate with the modal background |
| transparency | |
:content |
CSS class names to associate with the content div |
:close |
CSS class names to associate with the close div |
modal-card
(modal-card body sid model & {:keys [header footer classes]})A specialised modal overlay based around the card component. The body argument is the content for the body of the card. It can be a string, HTML or another component. The sid argument is a storage identifier keyword used to determine where state is managed for the modal. The model argument is a reagent atom used as the store for the modal state. The component also supports some optional keyword arguments:
| Keyword | Description |
|---|---|
:header |
The modal card header. Should be a component or Hiccup markup |
:footer |
The modal card footer. Should be a component or hiccup markup |
:classes |
A map of strings or vectors of strings representing CSS class |
names. Supported keys are :modal, :background, :card |
|
:header, :body, :footer and :close |