tutor-deck/tutordash/server/templates/installed_plugins.html
2025-02-28 12:45:45 +01:00

49 lines
2.0 KiB
HTML

{% extends "workspace_header_general.html" %}
{% block page_title %}My Plugins{% endblock %}
{% block page_description %}View all your installed plugins in one place.{% endblock %}
{% block page_button %}
<button class="btn btn-primary" type="button" data-bs-toggle="modal" data-bs-target="#exampleModal">Local Launch</button>
{% endblock %}
{% block model_icon %}
<img src="{{ url_for('static', filename='/img/Featured icon.svg') }}" alt="">
{% endblock %}
{% block modal_title %}
Run local launch for all plugins?
{% endblock %}
{% block modal_description %}
Running local launch will allow all changes to plugins to take effect. This could take a few minutes to complete.
{% endblock %}
{% block modal_footer %}
<button type="button" class="btn btn-outline-secondary" data-bs-dismiss="modal">Not Now</button>
<form method="POST" action="{{ url_for('cli_local_launch')}}">
<button type="submit" class="btn btn-primary">Run Local Launch</button>
</form>
{% endblock %}
{% block workspace_content %}
<div class="installed-plugins-list">
{% for plugin in plugins %}
<div class="installed-plugin">
<div class="details">
<div class="name"><a href="{{ url_for('plugin', name=plugin.name) }}">{{ plugin.name }}</a></div>
<div class="author">{{ plugin.author }}</div>
<div class="description">{{ plugin.description|safe }}</div>
</div>
<div class="form-check form-switch">
<form method="POST" action="{{ url_for('plugin_toggle', name=plugin.name) }}">
<input type="checkbox" name="checked" class="form-check-input" role="switch" onchange="this.form.submit()" {% if plugin.is_enabled %} id="flexSwitchCheckDefault" checked {% else %} id="flexSwitchCheckChecked" {% endif %} />
</form>
</div>
</div>
{% endfor %}
</div>
{% endblock %}
{% block scripts %}
<script>
document.getElementById('my-plugins').classList.toggle('sidebar-tab-selected');
document.querySelectorAll('my-plugins-logo').classList.toggle('sidebar-tab-logo-selected');
</script>
{% endblock %}