<div class="row-fluid">
    <a href="{{ plugin_octoprint_nanny_urls.cloud }}"><img src="plugin/octoprint_nanny/static/img/print_nanny_logo.png"/></a>
    <hr>
    <h3>⁉️ Help & Support</h3>
    <a target="_blank" href="{{ plugin_octoprint_nanny_urls.getting_started_guide }}" target="_blank"><button class="btn btn-primary">Getting Started Guide</button></a>
    <a target="_blank" href="{{ plugin_octoprint_nanny_urls.discord_invite }}"><button class="btn btn-secondary">Join Discord</button></a>
    <a target="_blank" href="mailto:leigh@printnanny.ai?subject=Question about OctoPrint + PrintNanny"><button class="btn btn-secondary">Email leigh@printnanny.ai</button></a>
    <hr>
    {{ plugin_octoprint_nanny_versions }}
{% if plugin_octoprint_nanny_etc_os_release.ID != "printnanny"%}
        <div class="alert alert-block alert-warning">    
            <h2>
                <strong>⛔ PrintNanny OS v1.x is Required</strong>
            </h2>

            <p>Failed to detect PrintNanny OS version from /etc/os-release</p>
<pre>{{ plugin_octoprint_nanny_etc_os_release}}</pre>
            <h4>
                Please follow the guide below to install PrintNanny OS (OctoPrint Edition). 
            </h4>
            <br>
            <a target="_blank" href="{{ plugin_octoprint_nanny_urls.getting_started_guide }}"><button class= "btn btn-primary btn-large">Getting Started Guide</button></a>
        </div>
{% endif %}
</div>
<div class="row-fluid">
    <ul class="nav nav-tabs">
        <li class="active"><a href="#{{template_name}}_basic" data-toggle="tab">{{ _('Account') }}</a></li>
        <li><a href="#{{template_name}}_report_issue" data-toggle="tab">{{ _('Report an Issue') }}</a></li>
    </ul>

    <div class="tab-content">
        <div id="{{template_name}}_basic" class="tab-pane active">
            <fieldset>

                <div>
                    {% if plugin_octoprint_nanny_config.printnanny_user is undefined %}
                    <h3>🔐 Log into PrintNanny</h3>
                    <a href="{{ plugin_octoprint_nanny_config.dash.base_url }}" class="btn btn-primary btn-large">Link PrintNanny Account</a>
                    {% else %}
                    <h3>✅ Welcome to PrintNanny OS (OctoPrint Edition)</h3>
                    <p>Your PrintNanny account is connected: <strong>{{ plugin_octoprint_nanny_config.user.email }}</strong></p>
                    <br>
                    {% endif %}
                </div>
            </fieldset>
        </div>
        <div id="{{template_name}}_report_issue" class="tab-pane">
            
            <h3>ℹ️ Please include the info below when opening an issue.</h3>
            <a target="_blank" href="https://github.com/bitsy-ai/printnanny-os/issues" class="btn btn-primary">Search Open Issues</a>
            <a target="_blank" href="https://github.com/bitsy-ai/printnanny-os/issues/new/choose" class="btn btn-secondary">Create New Issue</a>
            <hr>
            <pre>
{{ plugin_octoprint_nanny_issue_txt }}</pre>
        </div>
    </div>
</div>
