components-modal.js 1.4 KB

1234567891011121314151617181920212223242526272829303132333435363738394041
  1. /*=========================================================================================
  2. File Name: components-modal.js
  3. Description: Modals are streamlined, but flexible, dialog prompts with the minimum
  4. required functionality and smart defaults.
  5. ----------------------------------------------------------------------------------------
  6. Item Name: Robust - Responsive Admin Theme
  7. Version: 1.2
  8. Author: GeeksLabs
  9. Author URL: http://www.themeforest.net/user/geekslabs
  10. ==========================================================================================*/
  11. (function(window, document, $) {
  12. 'use strict';
  13. // onShow event
  14. $('#onshowbtn').on('click', function() {
  15. $('#onshow').on('show.bs.modal', function() {
  16. alert('onShow event fired.');
  17. });
  18. });
  19. // onShown event
  20. $('#onshownbtn').on('click', function() {
  21. $('#onshown').on('shown.bs.modal', function() {
  22. alert('onShown event fired.');
  23. });
  24. });
  25. // onHide event
  26. $('#onhidebtn').on('click', function() {
  27. $('#onhide').on('hide.bs.modal', function() {
  28. alert('onHide event fired.');
  29. });
  30. });
  31. // onHidden event
  32. $('#onhiddenbtn').on('click', function() {
  33. $('#onhidden').on('hidden.bs.modal', function() {
  34. alert('onHidden event fired.');
  35. });
  36. });
  37. })(window, document, jQuery);