<commit_before>#content.valign-wrapper
  #screen_content
    - begin
      = render :template => 'homepage/dashboard'
    - rescue

#confirm-modal.info-modal.modal
  .modal-content
    %h5.modal-title Confirmation
    #confirm-content.modal-message Are you sure to do this ?
  .modal-footer
    #confirmed-btn.btn.right.modal-close Yes
    .modal-close.btn-flat.waves-effect No

#error-modal.info-modal.modal
  .modal-content
    %h5.modal-title Error
    #error-content.modal-message Something happened.
  .modal-footer
    .modal-close.btn.right OK

#load-modal.info-modal.modal{style: "width: 150px"}
  .modal-content
    .modal-message Loading...

:javascript
  $(function(){
    // why use setTimeout?
    // Since `.modal` makes the following events not work.
    // Guess Materialize calls the $(selector).modal() automatically in the end
    // We have to make the following events executed after `.modal()`
    setTimeout(() => {
      $('.info-modal').modal({
        onOpenEnd: function(modal, trigger) {
          modal.css('z-index', '9999');
        }
      });

      $('#confirm-modal').modal({
        onCloseEnd: function(modal, trigger) {
          $('#confirm-content').text('Are you sure to do this ?');
          $('#confirm-modal .modal-title').text('Confirmation');
        }<commit_msg>BUG - Fix modal is not jQuery element<commit_after>#content.valign-wrapper
  #screen_content
    - begin
      = render :template => 'homepage/dashboard'
    - rescue

#confirm-modal.info-modal.modal
  .modal-content
    %h5.modal-title Confirmation
    #confirm-content.modal-message Are you sure to do this ?
  .modal-footer
    #confirmed-btn.btn.right.modal-close Yes
    .modal-close.btn-flat.waves-effect No

#error-modal.info-modal.modal
  .modal-content
    %h5.modal-title Error
    #error-content.modal-message Something happened.
  .modal-footer
    .modal-close.btn.right OK

#load-modal.info-modal.modal{style: "width: 150px"}
  .modal-content
    .modal-message Loading...

:javascript
  $(function(){
    // why use setTimeout?
    // Since `.modal` makes the following events not work.
    // Guess Materialize calls the $(selector).modal() automatically in the end
    // We have to make the following events executed after `.modal()`
    setTimeout(() => {
      $('.info-modal').modal({
        onOpenEnd: function(modal, trigger) {
          $(modal).css('z-index', '9999');
        }
      });

      $('#confirm-modal').modal({
        onCloseEnd: function(modal, trigger) {
          $('#confirm-content').text('Are you sure to do this ?');
          $('#confirm-modal .modal-title').text('Confirmation');
        }
{'fraction_non_alphanumeric': 0.14798036995092487, 'fraction_numerical': 0.006795016987542469, 'mean_word_length': 2.695955369595537, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 7, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '490710', 'n_tokens_mistral': 809, 'n_tokens_neox': 797, 'n_words': 186}