<!doctype html>
<html lang="zh">

<head>
    {% block head %}
    <!-- Required meta tags -->
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <meta name="description" content="Ezra 聖經語意搜尋，采用語意模型、開放的聖經經文搜尋引擎。可以用關鍵字查詢和合本相關經文。">
    <meta name="author" content="Ken Hung">

    <!-- Bootstrap CSS -->
    <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bootstrap@4.6.0/dist/css/bootstrap.min.css"
        integrity="sha384-B0vP5xmATw1+K9KRQjQERJvTumQW0nPEzvF6L/Z6nronJ3oUOFUFpCjEUQouq2+l" crossorigin="anonymous">

    <!-- Favicons -->
    <link rel="icon" href="/favicon.ico">

    <link href="/static/css/all.min.css" rel="stylesheet">
    <link href="{{ url_for('static', filename='css/style.css', version=version) }}" rel="stylesheet">

    <title>{% block title %}Ezra 聖經語意搜尋{% endblock %}</title>
    {% endblock %}
</head>

<body>
    <div class="{% block content_class %}content{% endblock %}">
        {% block content %}
        {% endblock %}

        <footer class="mt-auto">
            <hr>
            <p><a href="#" data-toggle="modal" data-target="#aboutModal">關於 Ezra</a></p>
            <p>
                Ezra 聖經語意搜尋 © 2021 Ken Hung<br>
                搜尋採用 <a href="https://github.com/commonsense/conceptnet-numberbatch" target="_blank">ConceptNet
                    Numberbatch</a>
                的語意向量，由 <a href="https://www.luminoso.com/" target="_blank">Luminoso</a> 以
                <a href="https://creativecommons.org/licenses/by-sa/4.0/" target="_blank">CC-By-SA 4.0</a> 條款授權。
            </p>
            <div class="modal fade" id="aboutModal" tabindex="-1" aria-labelledby="aboutModalLabel" aria-hidden="true">
                <div class="modal-dialog">
                    <div class="modal-content">
                        <div class="modal-header">
                            <h5 class="modal-title" id="aboutModalLabel">關於 Ezra</h5>
                            <button type="button" class="close" data-dismiss="modal" aria-label="Close">
                                <span aria-hidden="true">&times;</span>
                            </button>
                        </div>
                        <div class="modal-body">
                            <p>Ezra 聖經語意搜尋，應用語意模型的聖經經文搜尋器。</p>
                            <p>本程式的API也是開放的，<a href="/api">參考文檔</a>。</p>
                            <p>
                                如有任何問題，可以通過這個電郵聯絡：<a href="mailto:eiekenhung@gmail.com"
                                    target="_blank">eiekenhung@gmail.com</a>
                            </p>
                            <p>版權所有 © 2021 Ken Hung</p>
                            <hr>
                            <p>本程式是自由軟件，你可以根據 <a href="https://www.gnu.org/licenses/agpl-3.0.html"
                                    target="_blank">AGPL</a>
                                條款（自由軟體基金會公佈的第三版或是你選擇的後續版本）修改和再發佈它，源代碼位置：
                                <a href="https://github.com/KenHung/ezra-bible-search"
                                    target="_blank">https://github.com/KenHung/ezra-bible-search</a>
                            </p>
                            <p>經文相關數據來自「<a href="https://bible.fhl.net/public">信望愛信仰與聖經資源中心</a>」。
                                <br>語意向量
                                <a href="https://github.com/commonsense/conceptnet-numberbatch"
                                    target="_blank">ConceptNet
                                    Numberbatch</a> 則由 <a href="https://www.luminoso.com/" target="_blank">Luminoso</a>
                                以 <a href="https://creativecommons.org/licenses/by-sa/4.0/" target="_blank">CC-By-SA
                                    4.0</a> 條款授權使用。
                            </p>
                            <hr>
                            <p class="mb-0">本程式旨在幫助人查找經文，但是並不包含任何擔保，搜尋結果可能不準確，歡迎來信指正，惟願上帝賜福予使用者。具體免責聲明請檢視 AGPL 條款。</p>
                        </div>
                        <div class="modal-footer">
                            <button type="button" class="btn btn-secondary" data-dismiss="modal">關閉</button>
                        </div>
                    </div>
                </div>
            </div>
        </footer>
    </div>

    {% block script %}
    {% endblock %}

    <!-- jQuery and Bootstrap Bundle (includes Popper) -->
    <script src="https://code.jquery.com/jquery-3.5.1.slim.min.js"
        integrity="sha384-DfXdz2htPH0lsSSs5nCTpuj/zy4C+OGpamoFVy38MVBnE+IbbVYUew+OrCXaRkfj"
        crossorigin="anonymous"></script>
    <script src="https://cdn.jsdelivr.net/npm/bootstrap@4.6.0/dist/js/bootstrap.bundle.min.js"
        integrity="sha384-Piv4xVNRyMGpqkS2by6br4gNJ7DXjqk09RmUpJ8jgGtD7zP9yug3goQfGII0yAns"
        crossorigin="anonymous"></script>

    <script>
        // search input validation
        (function () {
            'use strict';
            window.addEventListener('load', function () {
                var form = document.getElementById('search-form');
                form.addEventListener('submit', function (event) {
                    if (form.checkValidity() === false) {
                        event.preventDefault();
                        event.stopPropagation();
                        var box = document.getElementById('search-box');
                        box.focus();
                    }
                }, false);
            }, false);
        })();
    </script>
</body>

</html>