<commit_before>(function() {
  'use strict';

  angular
    .module('app')
    .directive('propText', TextDirective);

  TextDirective.$inject = ['$parse'];
  function TextDirective($parse) {
    var directive = {
      require     : 'ngModel',
      restrict    : 'E',
      template    : templateFunction,
      link        : linkFunction,
    };
    return directive;

    function templateFunction($element, $attrs) {
      /* jshint -W043 */
      return '<textarea id="property-{{model.name}}"\
                        class="form-control" \
                        ng-change="doChange()" \
                        ng-model="value" \
                        ng-keydown="onKeydown($event)"><small></small>';
    }

    function linkFunction($scope, $element, $attrs, $ctrl) {
      var model = $parse($attrs.ngModel)($scope);
      var change = $parse($attrs.ngChange)($scope);
      $scope.model = model;
      $scope.value = model.value;
      $scope.doChange = function() {
        model.value = $scope.value;
        change();
      };
      $scope.onKeydown = function(e) {
        if (e.ctrlKey && e.keyCode == 90) {
          e.preventDefault();
        }
        return false;
      };
    }
  }<commit_msg>Correct template format of Textarea<commit_after>(function() {
  'use strict';

  angular
    .module('app')
    .directive('propText', TextDirective);

  TextDirective.$inject = ['$parse'];
  function TextDirective($parse) {
    var directive = {
      require     : 'ngModel',
      restrict    : 'E',
      template    : templateFunction,
      link        : linkFunction,
    };
    return directive;

    function templateFunction($element, $attrs) {
      /* jshint -W043 */
      return '<textarea id="property-{{model.name}}"\
                        class="form-control" \
                        ng-change="doChange()" \
                        ng-model="value" \
                        ng-keydown="onKeydown($event)"></textarea> \
                        <small></small>';
    }

    function linkFunction($scope, $element, $attrs, $ctrl) {
      var model = $parse($attrs.ngModel)($scope);
      var change = $parse($attrs.ngChange)($scope);
      $scope.model = model;
      $scope.value = model.value;
      $scope.doChange = function() {
        model.value = $scope.value;
        change();
      };
      $scope.onKeydown = function(e) {
        if (e.ctrlKey && e.keyCode == 90) {
          e.preventDefault();
        }
        return false;
      };
    }
  }
{'fraction_non_alphanumeric': 0.152, 'fraction_numerical': 0.004, 'mean_word_length': 1.8388195232690125, 'pattern_counts': {'":': 0, '<': 10, '<?xml version=': 0, '>': 10, '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': '3611578', 'n_tokens_mistral': 743, 'n_tokens_neox': 710, 'n_words': 133}