Blame view

assets/js/pages/mailbox.js 839 Bytes
cf76164e6   Ting Chan   20190709
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
  $( document ).ready(function() {
      
      jQuery.fn.extend({
      toggleText: function (a, b){
          var that = this;
              if (that.text() != a && that.text() != b){
                  that.text(a);
              }
              else
              if (that.text() == a){
                  that.text(b);
              }
              else
              if (that.text() == b){
                  that.text(a);
              }
          return this;
      }
  });
      $('.details-toggle').click(function() { 
          $('.details-list').toggle();
          $(".details-toggle").toggleText('Hide Details', 'Show Details');
      });
      
      var editor = new Simditor({
          textarea: $('#editor'),
          toolbar: [
    'bold',
    'italic',
    'underline',
    'strikethrough',
    'ol',
    'ul',
    'blockquote',
    'code'
  ]
      });
  });