<commit_before><div class="wrapper" ng-controller="loginCtrl">
  <div class="container content">
    {{#if message}}
      <div class="alert alert-info" role="alert">
        <p>{{message}}</p>
      </div>
    {{/if}}

    <div class="row">
      <div class="col-md-4 col-md-offset-4 col-sm-6 col-sm-offset-3">
        <div class="clearfix">
          <div class="dropdown pull-right">
            <button type="button" id="menus" data-toggle="dropdown" aria-haspopup="true" aria-expanded="true" class="btn btn-link dropdown-toggle">
              <i class="fa fa-globe"></i> {{TRANSLATION "common.language"}}
            </button>
            <ul aria-labelledby="menus" class="dropdown-menu">
              <li><a href="?lang=ko-KR">{{TRANSLATION "common.language.korean"}}</a></li>
              <li><a href="?lang=en-US">{{TRANSLATION "common.language.english"}}</a></li>
            </ul>
          </div>
        </div>

        <div class="reg-page">
          <form action="/login{{{redir}}}" name="loginForm" method="POST" ng-submit="onSubmit($event)">
            <div class="reg-header">
              <p>
                <a class="logo" href="/">
                  {{#if (EQ locale 'ko-KR')}}
                    <img src="/assets/jakduk/img/logo_type_A_kr.png" alt="Logo" class="center-block">
                  {{else}}
                    <img src="/assets/jakduk/img/logo_type_A_en.png" alt="Logo" class="center-block">
                  {{/if}}
                </a>
              </p>
              <h2>
                {{TRANSLATION "user.sign.in.header"}}
              </h2>
            </div>

            <div class="form-group">
              <div class="input-group has-feedback"
                 ng-class="{'has-success':loginForm.username.$valid, 'has-error':!loginForm.username.$pristine && loginForm.username.$invalid}">
                <span class="input-group-addon"><i class="fa fa-at fa-fw"></i></span>
                <input type="email" class="form-control" id="username" name="username" placeholder="{{TRANSLATION "user.placeholder.email"}}" ng-model="email" ng-required="true" ng-minlength="emailLengthMin" ng-maxlength="emailLengthMax" autofocus autofill-fixer>
                <span class="glyphicon form-control-feedback" ng-class="{'glyphicon-ok':loginForm.username.$valid, 'glyphicon-remove':!loginForm.username.$pristine &&  loginForm.username.$invalid}"></span>
              </div>
              <p class="text-danger" ng-model="errorEmail" ng-show="errorEmail" ng-bind="errorEmail"></p>
            </div>

            <div class="form-group">
              <div class="input-group has-feedback" ng-class="{'has-success':loginForm.password.$valid, 'has-error':!loginForm.password.$pristine && loginForm.password.$invalid}">
                <span class="input-group-addon"><i class="fa fa-lock fa-fw"></i></span>
                <input type="password" class="form-control" id="password" name="password" placeholder="{{TRANSLATION "user.placeholder.password"}}" ng-model="password" ng-required="true" ng-minlength="passwordLengthMin" ng-maxlength="passwordLengthMax" autofill-fixer>
              <span class="glyphicon form-control-feedback"
                  ng-class="{'glyphicon-ok':loginForm.password.$valid, 'glyphicon-remove':!loginForm.password.$pristine && loginForm.password.$invalid}"></span>
              </div>
              <p class="text-danger" ng-model="errorPassword" ng-show="errorPassword" ng-bind="errorPassword"></p>
            </div>

            <div class="form-group">

              <div class="checkbox">
                <label>
                  <input id="remember" name="remember" type="checkbox">
                  {{TRANSLATION "user.remember.me"}}
                </label>
              </div>
            </div>

            <button type="submit" class="btn btn-u btn-u-blue rounded btn-block ladda-button" ladda="btnSubmit" data-style="expand-right">
              {{TRANSLATION "user.sign.in"}}
            </button>

            <div class="checkbox">
              <ul class="list-inline">
                <li>
                  <a href="/join{{{redir}}}">
                    <span aria-hidden="true" class="icon-user-follow"></span> {{TRANSLATION "user.register"}}
                  </a>
                </li>
                &mid;
                <li>
                  <a href="/password/find">
                    <span aria-hidden="true" class="icon-real-estate-056"></span> {{TRANSLATION "user.sign.forgot.password"}}
                  </a>
                </li>
              </ul>
            </div>
          </form>

          <hr class="padding-10"/>

          <button
            style="background-color: #00c73c; color: white;"
            class="btn btn-block"
            onclick="javascript:window.location = '/auth/naver{{{redir}}}'"
          >
            {{TRANSLATION "common.button.connect.with.naver"}} <i class="fa fa-angle-right"></i>
          </button>

          <button
            id="kakao"
            class="btn btn-block"
            onclick="javascript:window.location = '/auth/kakao{{{redir}}}'"
          >
            {{TRANSLATION "common.button.connect.with.kakao"}} <i class="fa fa-angle-right"></i>
          </button>

          <button
            class="btn btn-google btn-block"
            onclick="javascript:window.location = '/auth/google{{{redir}}}'"
          >
            <i class="fa fa-google"></i> {{TRANSLATION "common.button.connect.with.google"}} <i class="fa fa-angle-right"></i>
          </button>

          <button
            class="btn btn-facebook btn-block"
            onclick="javascript:window.location = '/auth/facebook{{{redir}}}'"
          >
            <i class="fa fa-facebook"></i> {{TRANSLATION "common.button.connect.with.facebook"}} <i class="fa fa-angle-right"></i>
          </button>

        </div>
      </div>
    </div><!--/row-->
  </div>
  <form
    id="kakao-form"
    action="/auth/kakao/callback"
    method="post"
    style="display: none;"
  >
    <input type="hidden" name="access_token">
  </form>
</div><!-- /.container -->
{{#CHUNK 'css'}}
  <link rel="stylesheet" href="/assets/unify/assets/css/pages/page_log_reg_v1.css"/>
{{/CHUNK}}
{{#CHUNK 'js'}}
  <script type="text/javascript">
    require([
      'angular', 'jakduk'
    ], function (angular, Jakduk) {
      angular.module("jakdukApp", [
        "ngCookies", "angular-ladda", "jakdukCommon"
      ]).controller("loginCtrl", ['$scope', function ($scope) {
        $scope.emailLengthMin = Jakduk.FormEmailLengthMin;
        $scope.emailLengthMax = Jakduk.FormEmailLengthMax;
        $scope.passwordLengthMin = Jakduk.FormPasswordLengthMin;
        $scope.passwordLengthMax = Jakduk.FormPasswordLengthMax;

        $scope.onSubmit = function (event) {
          if ($scope.loginForm.$valid) {
            $scope.btnSubmit = true;
          } else {
            $scope.onEmail();

            if ($scope.loginForm.password.$error.required) {
              $scope.errorPassword = '{{TRANSLATION "common.msg.required"}}';
            } else if ($scope.loginForm.password.$error.minlength || $scope.loginForm.password.$error.maxlength) {
              $scope.errorPassword = '{{TRANSLATION "<PASSWORD>"}}';
            }

            event.preventDefault();
          }
        };

        $scope.onEmail = function () {
          if ($scope.loginForm.username.$invalid) {
            if ($scope.loginForm.username.$error.required) {
              $scope.errorEmail = '{{TRANSLATION "common.msg.required"}}';
            } else if ($scope.loginForm.username.$error.minlength || $scope.loginForm.username.$error.maxlength) {
              $scope.errorEmail = '{{TRANSLATION "Size.userWrite.email"}}';
            } else {
              $scope.errorEmail = '{{TRANSLATION "user.msg.check.mail.format"}}';
            }
          } else {
            $scope.errorEmail = "";
          }
        };
      }]);

      angular.bootstrap(document, ['jakdukApp']);

      Kakao.Auth.createLoginButton({
        container: '#kakao',
        always: function (data) {
          var form = $('#kakao-form');
          form.find('input').val(data.access_token);
          form.submit();
        },
      });
    });
  </script>
{{/CHUNK}}<commit_msg>resolved #138 카카오 로그인 버튼 UI 통일<commit_after><div class="wrapper" ng-controller="loginCtrl">
  <div class="container content">
    {{#if message}}
      <div class="alert alert-info" role="alert">
        <p>{{message}}</p>
      </div>
    {{/if}}

    <div class="row">
      <div class="col-md-4 col-md-offset-4 col-sm-6 col-sm-offset-3">
        <div class="clearfix">
          <div class="dropdown pull-right">
            <button type="button" id="menus" data-toggle="dropdown" aria-haspopup="true" aria-expanded="true" class="btn btn-link dropdown-toggle">
              <i class="fa fa-globe"></i> {{TRANSLATION "common.language"}}
            </button>
            <ul aria-labelledby="menus" class="dropdown-menu">
              <li><a href="?lang=ko-KR">{{TRANSLATION "common.language.korean"}}</a></li>
              <li><a href="?lang=en-US">{{TRANSLATION "common.language.english"}}</a></li>
            </ul>
          </div>
        </div>

        <div class="reg-page">
          <form action="/login{{{redir}}}" name="loginForm" method="POST" ng-submit="onSubmit($event)">
            <div class="reg-header">
              <p>
                <a class="logo" href="/">
                  {{#if (EQ locale 'ko-KR')}}
                    <img src="/assets/jakduk/img/logo_type_A_kr.png" alt="Logo" class="center-block">
                  {{else}}
                    <img src="/assets/jakduk/img/logo_type_A_en.png" alt="Logo" class="center-block">
                  {{/if}}
                </a>
              </p>
              <h2>
                {{TRANSLATION "user.sign.in.header"}}
              </h2>
            </div>

            <div class="form-group">
              <div class="input-group has-feedback"
                 ng-class="{'has-success':loginForm.username.$valid, 'has-error':!loginForm.username.$pristine && loginForm.username.$invalid}">
                <span class="input-group-addon"><i class="fa fa-at fa-fw"></i></span>
                <input type="email" class="form-control" id="username" name="username" placeholder="{{TRANSLATION "user.placeholder.email"}}" ng-model="email" ng-required="true" ng-minlength="emailLengthMin" ng-maxlength="emailLengthMax" autofocus autofill-fixer>
                <span class="glyphicon form-control-feedback" ng-class="{'glyphicon-ok':loginForm.username.$valid, 'glyphicon-remove':!loginForm.username.$pristine &&  loginForm.username.$invalid}"></span>
              </div>
              <p class="text-danger" ng-model="errorEmail" ng-show="errorEmail" ng-bind="errorEmail"></p>
            </div>

            <div class="form-group">
              <div class="input-group has-feedback" ng-class="{'has-success':loginForm.password.$valid, 'has-error':!loginForm.password.$pristine && loginForm.password.$invalid}">
                <span class="input-group-addon"><i class="fa fa-lock fa-fw"></i></span>
                <input type="password" class="form-control" id="password" name="password" placeholder="{{TRANSLATION "user.placeholder.password"}}" ng-model="password" ng-required="true" ng-minlength="passwordLengthMin" ng-maxlength="passwordLengthMax" autofill-fixer>
              <span class="glyphicon form-control-feedback"
                  ng-class="{'glyphicon-ok':loginForm.password.$valid, 'glyphicon-remove':!loginForm.password.$pristine && loginForm.password.$invalid}"></span>
              </div>
              <p class="text-danger" ng-model="errorPassword" ng-show="errorPassword" ng-bind="errorPassword"></p>
            </div>

            <div class="form-group">

              <div class="checkbox">
                <label>
                  <input id="remember" name="remember" type="checkbox">
                  {{TRANSLATION "user.remember.me"}}
                </label>
              </div>
            </div>

            <button type="submit" class="btn btn-u btn-u-blue rounded btn-block ladda-button" ladda="btnSubmit" data-style="expand-right">
              {{TRANSLATION "user.sign.in"}}
            </button>

            <div class="checkbox">
              <ul class="list-inline">
                <li>
                  <a href="/join{{{redir}}}">
                    <span aria-hidden="true" class="icon-user-follow"></span> {{TRANSLATION "user.register"}}
                  </a>
                </li>
                &mid;
                <li>
                  <a href="/password/find">
                    <span aria-hidden="true" class="icon-real-estate-056"></span> {{TRANSLATION "user.sign.forgot.password"}}
                  </a>
                </li>
              </ul>
            </div>
          </form>

          <hr class="padding-10"/>

          <button
            style="background-color: #00c73c; color: white; font-weight: bold;"
            class="btn btn-block"
            onclick="javascript:window.location = '/auth/naver{{{redir}}}'"
          >
            {{TRANSLATION "common.button.connect.with.naver"}} <i class="fa fa-angle-right"></i>
          </button>

          <button
            style="background-color: #ffec00; color: #411b1e; font-weight: bold;"
            id="kakao"
            class="btn btn-block"
          >
            {{TRANSLATION "common.button.connect.with.kakao"}} <i class="fa fa-angle-right"></i>
          </button>

          <button
            class="btn btn-google btn-block"
            onclick="javascript:window.location = '/auth/google{{{redir}}}'"
          >
            {{TRANSLATION "common.button.connect.with.google"}} <i class="fa fa-angle-right"></i>
          </button>

          <button
            class="btn btn-facebook btn-block"
            onclick="javascript:window.location = '/auth/facebook{{{redir}}}'"
          >
            {{TRANSLATION "common.button.connect.with.facebook"}} <i class="fa fa-angle-right"></i>
          </button>

        </div>
      </div>
    </div><!--/row-->
  </div>
  <form
    id="kakao-form"
    action="/auth/kakao/callback"
    method="post"
    style="display: none;"
  >
    <input type="hidden" name="access_token">
  </form>
</div><!-- /.container -->
{{#CHUNK 'css'}}
  <link rel="stylesheet" href="/assets/unify/assets/css/pages/page_log_reg_v1.css"/>
{{/CHUNK}}
{{#CHUNK 'js'}}
  <script type="text/javascript">
    require([
      'angular', 'jakduk'
    ], function (angular, Jakduk) {
      angular.module("jakdukApp", [
        "ngCookies", "angular-ladda", "jakdukCommon"
      ]).controller("loginCtrl", ['$scope', function ($scope) {
        $scope.emailLengthMin = Jakduk.FormEmailLengthMin;
        $scope.emailLengthMax = Jakduk.FormEmailLengthMax;
        $scope.passwordLengthMin = Jakduk.FormPasswordLengthMin;
        $scope.passwordLengthMax = Jakduk.FormPasswordLengthMax;

        $scope.onSubmit = function (event) {
          if ($scope.loginForm.$valid) {
            $scope.btnSubmit = true;
          } else {
            $scope.onEmail();

            if ($scope.loginForm.password.$error.required) {
              $scope.errorPassword = '{{TRANSLATION "common.msg.required"}}';
            } else if ($scope.loginForm.password.$error.minlength || $scope.loginForm.password.$error.maxlength) {
              $scope.errorPassword = '{{TRANSLATION "<PASSWORD>"}}';
            }

            event.preventDefault();
          }
        };

        $scope.onEmail = function () {
          if ($scope.loginForm.username.$invalid) {
            if ($scope.loginForm.username.$error.required) {
              $scope.errorEmail = '{{TRANSLATION "common.msg.required"}}';
            } else if ($scope.loginForm.username.$error.minlength || $scope.loginForm.username.$error.maxlength) {
              $scope.errorEmail = '{{TRANSLATION "Size.userWrite.email"}}';
            } else {
              $scope.errorEmail = '{{TRANSLATION "user.msg.check.mail.format"}}';
            }
          } else {
            $scope.errorEmail = "";
          }
        };
      }]);

      angular.bootstrap(document, ['jakdukApp']);

      $(document).on('click', '#kakao', function () {
        Kakao.Auth.login({
          always: function (data) {
            var form = $('#kakao-form');
            form.find('input').val(data.access_token);
            form.submit();
          },
        });
      });
    });
  </script>
{{/CHUNK}}
{'fraction_non_alphanumeric': 0.17604826546003016, 'fraction_numerical': 0.002473604826546003, 'mean_word_length': 2.0611265004616803, 'pattern_counts': {'":': 0, '<': 249, '<?xml version=': 0, '>': 249, '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': '5660763', 'n_tokens_mistral': 5042, 'n_tokens_neox': 4887, 'n_words': 778}