Files
character-browser/templates/actions/index.html
Aodhan Collins 467c90594c feat: implement Actions Gallery with character integration and triple LoRA chaining
- Added Actions gallery with CRUD and JSON sync
- Implemented Triple LoRA workflow (Character -> Outfit -> Action)
- Added character-integrated previews for Actions with style matching
- Implemented granular prompt selection and default persistence for Actions
- Added detailed development guide for extending gallery features
2026-02-19 20:06:57 +00:00

42 lines
1.9 KiB
HTML

{% extends "layout.html" %}
{% block content %}
<div class="d-flex justify-content-between align-items-center mb-4">
<h2>Action Gallery</h2>
<div class="d-flex">
<a href="{{ url_for('create_action') }}" class="btn btn-success me-2">Create New Action</a>
<form action="{{ url_for('rescan_actions') }}" method="post">
<button type="submit" class="btn btn-outline-primary">Rescan Action Files</button>
</form>
</div>
</div>
<div class="row row-cols-1 row-cols-sm-2 row-cols-md-3 row-cols-lg-4 g-4">
{% for action in actions %}
<div class="col" id="card-{{ action.slug }}">
<div class="card h-100 character-card" onclick="window.location.href='/action/{{ action.slug }}'">
<div class="img-container">
{% if action.image_path %}
<img id="img-{{ action.slug }}" src="{{ url_for('static', filename='uploads/' + action.image_path) }}" alt="{{ action.name }}">
<span id="no-img-{{ action.slug }}" class="text-muted d-none">No Image</span>
{% else %}
<img id="img-{{ action.slug }}" src="" alt="{{ action.name }}" class="d-none">
<span id="no-img-{{ action.slug }}" class="text-muted">No Image</span>
{% endif %}
</div>
<div class="card-body">
<h5 class="card-title text-center">{{ action.name }}</h5>
<p class="card-text small text-center text-muted">{{ action.data.tags | join(', ') }}</p>
</div>
{% if action.data.lora and action.data.lora.lora_name %}
{% set lora_name = action.data.lora.lora_name.split('/')[-1].replace('.safetensors', '') %}
<div class="card-footer text-center p-1">
<small class="text-muted" title="{{ action.data.lora.lora_name }}">{{ lora_name }}</small>
</div>
{% endif %}
</div>
</div>
{% endfor %}
</div>
{% endblock %}