modal

There are multiple components used by modal.

  • A modal service is used to keep state of modal opened in the applications.
  • A modal element directive to define the modal dialog box
  • A modal attribute directive as a modal trigger
Parameters:
Name Type Description
show function

Show a modal based on the modal id

  • {String} id The id of the modal to open
  • {Object} triggerOptions Additional options to open modal
resize function

Update the position and also the size of the modal

  • {Object} modalObject The modal to reposition and resize (default opened modal)
hide function

Hide currently opened modal

  • {Function} callback Callback after modal has been hidden
bindingEvents function

Binding escape key or resize event

  • {String} action Either to bind or unbind events (default 'bind')
register function

Registering modal with the service

  • {String} id ID of the modal
  • {Element} element The modal element
  • {Object} options Additional options for the modal
unregister function

Remove modal from modal service

  • {String} id ID of the modal to unregister
clearWaiting function

Remove certain modal id from waiting list

  • {String} id ID of the modal