<!DOCTYPE html>
<html ng-app="Application" ng-controller="LogsController">
<head>
    <meta charset="utf-8" />
    <meta name="viewport" content="user-scalable=no, initial-scale=1, maximum-scale=1, minimum-scale=1, width=device-width, height=device-height" />

    <!-- this gets changed once we get the config (because angular has not loaded yet, we see template string for a flash) -->
    <title> Logs </title>

    <link id="favicon" href="/api/v1/cloudron/avatar" rel="icon" type="image/png">
    <link rel="apple-touch-icon" href="/api/v1/cloudron/avatar">
    <link rel="icon" href="/api/v1/cloudron/avatar">

    <!-- CSS -->
    <link type="text/css" rel="stylesheet" href="/3rdparty/angular-ui-notification.css"/>
    <link type="text/css" rel="stylesheet" href="/theme.css">

    <!-- Custom Fonts -->
    <link type="text/css" rel="stylesheet" href="/3rdparty/fontawesome/css/all.min.css">

    <!-- jQuery-->
    <script type="text/javascript" src="/3rdparty/js/jquery.min.js"></script>

    <!-- Bootstrap Core JavaScript -->
    <script type="text/javascript" src="/3rdparty/js/bootstrap.min.js"></script>

    <!-- Angularjs scripts -->
    <script type="text/javascript" src="/3rdparty/js/angular.min.js"></script>
    <script type="text/javascript" src="/3rdparty/js/angular-loader.min.js"></script>
    <script type="text/javascript" src="/3rdparty/js/angular-animate.min.js"></script>
    <script type="text/javascript" src="/3rdparty/js/angular-base64.min.js"></script>
    <script type="text/javascript" src="/3rdparty/js/angular-md5.min.js"></script>
    <script type="text/javascript" src="/3rdparty/js/angular-sanitize.min.js"></script>
    <script type="text/javascript" src="/3rdparty/js/angular-ui-notification.js"></script>

    <!-- Angular directives for bootstrap https://angular-ui.github.io/bootstrap/ -->
    <script type="text/javascript" src="/3rdparty/js/ui-bootstrap-tpls-1.3.3.min.js"></script>

    <!-- colors -->
    <script type="text/javascript" src="/3rdparty/js/colors.js"></script>

    <!-- moment -->
    <script type="text/javascript" src="/3rdparty/js/moment.min.js"></script>

    <!-- Main Application -->
    <script type="text/javascript" src="/js/logs.js"></script>

</head>

<body class="logs">

        <a class="offline-banner animateMe" ng-show="client.offline" ng-cloak href="https://cloudron.io/documentation/troubleshooting/" target="_blank"><i class="fa fa-circle-notch fa-spin"></i> Cloudron is offline. Reconnecting...</a>

    <div class="animateMe ng-hide layout-root" ng-show="initialized">

        <div class="logs-controls">
            <h3 style="display: inline-block;">{{ selected.name }} Logs</h3>

            <!-- logs actions -->
            <div class="pull-right">
                <a class="btn btn-primary" ng-href="{{ '/terminal.html?id=' + selected.value }}" target="_blank" ng-show="selected.type === 'app'"><i class="fa fa-terminal"></i> Terminal</a>
                <a class="btn btn-primary" ng-click="clear()"><i class="fa fa-trash"></i> Clear View</a>
                <a class="btn btn-primary" ng-href="{{ selected.url }}&format=short&lines=-1"><i class="fa fa-download"></i> Download Full Logs</a>
            </div>
          </div>

          <div class="logs-container"></div>

    </div>

</body>
</html>
