{% extends base.html %}

{% block content %}
<form class="signin layui-form" action="/signin" method="POST" href="/">
  <div class="layui-form-item">
    <div class="layui-input-wrap">
      <div class="layui-input-prefix">
        <i class="layui-icon layui-icon-username"></i>
      </div>
      <input type="text" name="username" lay-verify="required" placeholder="用户名或邮箱" lay-reqtext="请填写用户名" autocomplete="off" class="layui-input" lay-affix="clear">
    </div>
  </div>
  <div class="layui-form-item">
    <div class="layui-input-wrap">
      <div class="layui-input-prefix">
        <i class="layui-icon layui-icon-password"></i>
      </div>
      <input type="password" name="password" lay-verify="required" placeholder="密码" lay-reqtext="请填写密码" autocomplete="off" class="layui-input" lay-affix="eye">
    </div>
  </div>
  <div class="layui-form-item">
    <input type="checkbox" name="remember" lay-skin="primary" title="记住密码">
    <a href="/reset" style="float: right; margin-top: 7px;">忘记密码？</a>
  </div>
  <div class="layui-form-item">
    <button class="layui-btn layui-btn-fluid" lay-submit lay-filter="default">登录</button>
  </div>
  <div class="layui-form-item">
    {% if handler.opt.site_id %}
    <label>社交账号登录</label>
    <span style="padding: 0 20px 0 6px;">
      <a href="javascript:;"><i class="layui-icon layui-icon-login-wechat weixin-login" data-id="{{ handler.opt.site_id }}"></i></a>
    </span>
    {% end %}
    <a href="/signup">注册帐号</a>
  </div>
</form>

{% end %}
