Class ModalsManager
Source: modalsManager.ts
Manages the opening, closing and ordering of modals
Accessors
modalIds
Get Signature
get modalIds():
string[]
Returns the IDs of all open modals
Returns
string[]
Constructors
Constructor
new ModalsManager():
ModalsManager
Returns
ModalsManager
Methods
close()
close(
modalId:string|number,sendModalsUpdate:boolean):void
Closes a modal
Parameters
modalId
The ID of the modal to close
string | number
sendModalsUpdate
boolean = true
Returns
void
focus()
focus(
modalId:string):void
Brings a modal into focus
Parameters
modalId
string
The ID of the modal to bring into focus
Returns
void
getModalIconUrl()
staticgetModalIconUrl(name:string):string
Parameters
name
string
Returns
string
open()
open(
modal:Modal,single:boolean):void
Opens a modal
Parameters
modal
single
boolean = true
Set to false to preserve other open modals
Returns
void
setUpdateModals()
setUpdateModals(
updateModals: (modals:Record<string,Modal>) =>void):void
Parameters
updateModals
(modals: Record<string, Modal>) => void
Returns
void
Properties
containerRef?
optionalcontainerRef:MutableRefObject<HTMLElement>
modals
Maps every modal ID to the corresponding modal
updateModals()
Function that handles changes to modals
Parameters
modals
Returns
void