<div class="toolbar">

    <div class="row">
        <div class="col-lg-8 m-auto">
            <div class="pill-group">

                <div data-category="0" id="pill_0" class="pill active" onclick="changecategory(0)"> <span class="pill-text">සියල්ල</span> </div>
                <?php foreach (userstats::active_letters_by_state(auth::user_id()) as $key => $value) { ?>
                    <div data-category="<?= $value["id"] ?>" id="pill_<?= $value["id"] ?>" class="pill" onclick='changecategory(<?= $value["id"] ?>)'>
                        <span class="pill-text"><?= $value["name"] ?> </span>
                        <span class="pill-badge"><?= $value["count"] ?></span>
                    </div>
                <?php } ?>

            </div>
        </div>

        <div class="col-lg-4 m-auto">

            <div class="input-group input-group-sm">

                <span class="input-group-text">
                    <?= UI::icon("search") ?>
                </span>

                <select id="search_type" style="max-width:6rem" class="form-control">
                    <option data-key="title">මාතෘකාව</option>
                    <option data-key="sender_name">ආයතනය</option>
                    <option data-key="id">ලිපියේ අංකය</option>

                </select>

                <input type="text" placeholder="Search [alt+s]" id="search_text" class="form-control" accesskey="s">

            </div>

        </div>
    </div>

</div>