forked from FrederikBaerentsen/BrickTracker
42 lines
1.8 KiB
HTML
42 lines
1.8 KiB
HTML
{% import 'macro/accordion.html' as accordion %}
|
|
{% import 'macro/card.html' as card %}
|
|
|
|
<div class="container">
|
|
<div class="card mb-3">
|
|
<div class="card-header">
|
|
<h5 class="mb-0"><i class="ri-file-line"></i> Instructions</h5>
|
|
</div>
|
|
<div class="accordion accordion-flush" id="instructions">
|
|
{{ accordion.header('Management', 'instructions-rename', 'instructions', expanded=true) }}
|
|
{% if item.brickset %}
|
|
<div class="d-flex justify-content-center">
|
|
{% with item=item.brickset %}
|
|
{% include 'set/mini.html' %}
|
|
{% endwith %}
|
|
</div>
|
|
{% endif %}
|
|
<form action="{{ url_for('instructions.do_rename', name=item.filename) }}" method="post">
|
|
{% if error %}<div class="alert alert-danger" role="alert"><strong>Error:</strong> {{ error }}.</div>{% endif %}
|
|
<div class="mb-3">
|
|
<label for="filename" class="form-label">File name</label> (current name: <code>{{ item.filename }}</code>)
|
|
<div class="input-group">
|
|
<input type="input" class="form-control" id="filename" name="filename" value="{{ item.name }}" autocomplete="off">
|
|
<span class="input-group-text">{{ item.extension }}</span>
|
|
</div>
|
|
</div>
|
|
<div class="text-end">
|
|
<a class="btn btn-primary" href="{{ url_for('instructions.list') }}" role="button"><i class="ri-arrow-left-long-line"></i> Back to the instructions</a>
|
|
<button type="submit" class="btn btn-primary"><i class="ri-edit-line"></i> Rename</button>
|
|
</div>
|
|
</form>
|
|
{{ accordion.footer() }}
|
|
</div>
|
|
<div class="card-footer"></div>
|
|
</div>
|
|
</div>
|
|
<script type="text/javascript">
|
|
document.addEventListener("DOMContentLoaded", () => {
|
|
baguetteBox.run('[data-lightbox]');
|
|
});
|
|
</script>
|