anchor.diff:  
   <!--thank hover-->
   <script>
  -  $(".thanked_div").hover(function(){
  +$(document).on({
  +    mouseenter: function () {
         $(this).css("background-color", "black");
         $(this).css("color", "white")
         if ($(this).html() === "NOT THANKED") {
  
positive.code:       } else {
          $(this).html("UNTHANK?")
        }
      }, function(){
        if ($(this).html() === "THANK?") {
          $(this).css("background-color", "#ff4d4d");
          $(this).css("font-weight", "bold")
          $(this).css("color", "black")
          $(this).html("NOT THANKED")
        } else {
          $(this).css("background-color", "#3FFE7C");
          $(this).css("font-weight", "bold")
          $(this).css("color", "black")
          $(this).html("THANKED")
        }
    });
  </script>
  
  <!--not thanked hover-->
  <script>
    $(".not_thanked_div").hover(function(){
        $(this).css("background-color", "black");
        $(this).css("color", "white")
        if ($(this).html() === "NOT THANKED") {
  
negative.code:       } else {
          $(this).html("UNTHANK?")
        }
      },
      mouseleave: function () {
        if ($(this).html() === "THANK?") {
          $(this).css("background-color", "#ff4d4d");
          $(this).css("font-weight", "bold")
          $(this).css("color", "black")
          $(this).html("NOT THANKED")
        } else if ($(this).html() === "NOT THANKED") {
          $(this).css("background-color", "#ff4d4d");
          $(this).css("font-weight", "bold")
          $(this).css("color", "black")
          $(this).html("NOT THANKED")
        } else {
          $(this).css("background-color", "#3FFE7C");
          $(this).css("font-weight", "bold")
          $(this).css("color", "black")
          $(this).html("THANKED")
        }
      }
  }, '.not_thanked_div');
  </script>
  
  
  
  <!--thank click-->
  <script>
    $(document).on('click', '.thanked_div', function(event) {
      event.preventDefault()
      var id = $(this).data("id")
      $.get('/gifts/' + id + '/thank', function() {
      })
      if ($(this).html() === "THANK?") {
        $(this).html("THANKED")
        $(this).css("background-color", "#3FFE7C")
        $(this).css("color", "black")
      } else {
        $(this).html("NOT THANKED")
        $(this).css("background-color", "#ff4d4d");
        $(this).css("color", "black")
      }
    })
  </script>
  
  <!--not thanked click-->
  <script>
    $(document).on('click', '.not_thanked_div', function(event) {
      event.preventDefault()
      var id = $(this).data("id")
      $.get('/gifts/' + id + '/thank', function() {
  