<!DOCTYPE html>
<html lang="en">

<head>
    <?= __seo(); ?>
    <title>Administração | <?= $this->e($title); ?></title>
    <script src="https://kit.fontawesome.com/414ccb13a2.js" crossorigin="anonymous"></script>
    <?= web_files("css") ?>
    <link rel="stylesheet" href="<?= __filesadm("css/admin.css") ?>">
    <link rel="stylesheet" href="<?= __filesadm("css/editor.css") ?>">
    <link rel="stylesheet" href="<?= __filesadm("css/datatable.css") ?>">
    <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/Trumbowyg/2.26.0/plugins/colors/ui/trumbowyg.colors.min.css">
</head>

<body>

    <div class="container mx-auto flex mt-8">

        <?= $this->insert('siderbar') ?>

        <div class="w-full bg-white">
            <div class="flex justify-between items-center bg-gray-900 py-4 px-2">
                <button class="mobile hidden max-lg:block py-1 px-3 bg-red-500 rounded-lg text-white  hover:bg-red-700"><i class="fas fa-bars"></i></button>
                <p class="text-white"><?= $this->e($subtitle) ?></p>
                <a class="py-1 px-3 bg-red-500 rounded-lg text-white inline-block hover:bg-red-700" href="<?= __redirect("administration/account/logout") ?>"> <i class="fas fa-sign-out-alt"></i> </a>

            </div>

            <div class="p-6">
                <?= $this->section('content') ?>
            </div>
        </div>
    </div>

    <div class="web-alerts">
        <div class="message"></div>
    </div>

    <?= web_files("js") ?>
    <script src="<?= __filesadm("js/admin.js"); ?>"></script>
    <script src="<?= __filesadm("js/datatable.js"); ?>"></script>
    <script src="https://cdnjs.cloudflare.com/ajax/libs/Trumbowyg/2.26.0/trumbowyg.min.js"></script>
    <script src="https://cdnjs.cloudflare.com/ajax/libs/Trumbowyg/2.26.0/plugins/colors/trumbowyg.colors.min.js"></script>
    <script src="https://cdnjs.cloudflare.com/ajax/libs/Trumbowyg/2.26.0/plugins/fontsize/trumbowyg.fontsize.min.js"></script>
    <script src="https://cdnjs.cloudflare.com/ajax/libs/Trumbowyg/2.26.0/plugins/fontfamily/trumbowyg.fontfamily.min.js"></script>
    <script>
        $('#editor').trumbowyg({
            btns: [
                ['formatting'],
                ['foreColor', 'backColor'],
                ['fontfamily'],
                ['fontsize'],
                ['strong', 'em'],
                ['superscript', 'subscript'],
                ['link'],
                ['insertImage'],
                ['justifyLeft', 'justifyCenter', 'justifyRight', 'justifyFull'],
                ['fullscreen'],
            ]
        });

        $(document).ready(function() {
            $('#tableitem').DataTable();
        });
    </script>

</body>

</html>