<h3>{{ _('Pi Support') }}</h3>

<p>{{ _('Please restart OctoPrint after changing any of this plugin\'s settings.') }}</p>

<form class="form-horizontal" onsubmit="return false;">
    <div class="control-group">
        <div class="controls">
            <label class="checkbox">
                <input type="checkbox" data-bind="checked: settings.plugins.pi_support.ignore_unrecommended_model"> {{ _('Disable warning about unsupported hardware') }} <label class="label label-important">{{ _('Warning') }}</label>
            </label>
            <span class="help-block">{{ _('If you check this, you will no longer get warned if you run OctoPrint on Raspberry Pi models that are not officially supported due to bad performance that can lead to failed prints. Do so at your own risk.') }}</span>
        </div>
    </div>

    <div class="control-group">
        <div class="controls">
            <label class="checkbox">
                <input type="checkbox" data-bind="checked: settings.plugins.pi_support.ignore_default_password"> {{ _('Disable warning about default system password') }} <label class="label label-important">{{ _('Warning') }}</label>
            </label>
            <span class="help-block">{{ _('If you check this, you will no longer get warned if you still have the default password set on your "pi" system user. This is a security risk.') }}</span>
        </div>
    </div>

    {% if version.number and version.number.count(".") >= 2 and version.number.split(".")[:2] >= ["1", "7"] %}
    <div class="control-group">
        <div class="controls">
            <label class="checkbox">
                <input type="checkbox" data-bind="checked: settings.plugins.pi_support.ignore_undervoltage_on_printstart"> {{ _('Disable warning about undervoltage on print start') }} <label class="label label-important">{{ _('Warning') }}</label>
            </label>
            <span class="help-block">{{ _('If you check this, you will no longer get warned when starting prints during observed undervoltage issues. Do so at your own risk.') }}</span>
        </div>
    </div>
    {% endif %}

    <div class="control-group">
        <div class="controls">
            <label class="checkbox">
                <input type="checkbox" data-bind="checked: settings.plugins.pi_support.vcgencmd_throttle_check_enabled"> {{ _('Enable under voltage and overheat detection via <code>vcgencmd get_throttled</code>') }}
            </label>
            <span class="help-block">{{ _('This will regularly check with the Pi if something is amiss either with power regulation or CPU/GPU temperature. Disable at your own risk. You will have to re-enable this when getting assistance on the forums or Discord. Changes require a restart of OctoPrint.') }}</span>
        </div>
    </div>

    <div>
        <div><small><a href="#" class="muted" onclick="$(this).children().toggleClass('fa-caret-right fa-caret-down').parent().parent().parent().next().slideToggle('fast')"><i class="fas fa-caret-right"></i> {{ _('Advanced options') }}</a></small></div>
        <div class="hide">
            <form class="form-horizontal" onsubmit="return false;">
                <div class="control-group">
                    <label class="control-label">{{ _('Command for under voltage/overheat detection') }}</label>
                    <div class="controls">
                        <input type="text" class="input-block-level" data-bind="value: settings.plugins.pi_support.vcgencmd_throttle_check_command">
                        <span class="help-block">{{ _('Defaults to <code>/usr/bin/vcgencmd get_throttled</code>. You usually shouldn\'t have to change this.') }}</span>
                    </div>
                </div>
            </form>
        </div>
    </div>
</form>
