|
|
|
@@ -216,7 +216,7 @@
|
|
|
|
|
<td>{% if b.element_labels %}{{ b.element_labels|join(', ') }}{% else %}<span class="hint">—</span>{% endif %}</td>
|
|
|
|
|
<td>{{ b.node_count }}</td>
|
|
|
|
|
<td class="fieldsTableActions">
|
|
|
|
|
<button type="button" class="button is-small is-primary" onclick="openLogicBlockPanel({{ b.id }}, {{ b.name|tojson }})" title="Ouvrir le graphe de ce bloc">🧩 Ouvrir</button>
|
|
|
|
|
<button type="button" class="button is-small is-primary" onclick="openLogicBlockPanel({{ b.id }})" title="Ouvrir le graphe de ce bloc">🧩 Ouvrir</button>
|
|
|
|
|
<button type="button" class="button is-small" onclick="toggleBlockEditRow({{ b.id }})" title="Modifier le nom/la description">✏️</button>
|
|
|
|
|
<form method="post" action="{{ url_for('flow_block_delete', slug=game.slug, screen_id=screen.id, block_id=b.id) }}"
|
|
|
|
|
onsubmit="return confirm('Supprimer le bloc « {{ b.name }} » ? Cela supprime aussi ses {{ b.node_count }} nœud(s) et leurs connexions.');" style="display:inline;">
|
|
|
|
@@ -2963,10 +2963,11 @@ function makeFloatPanelFullscreenable(panel, toggleBtn) {
|
|
|
|
|
makeFloatPanelDraggable(panel, document.getElementById('logicBlockPanelHeader'));
|
|
|
|
|
makeFloatPanelResizable(panel, document.getElementById('logicBlockPanelResizeHandle'));
|
|
|
|
|
makeFloatPanelFullscreenable(panel, panel.querySelector('.floatPanelFullscreenBtn'));
|
|
|
|
|
window.openLogicBlockPanel = function (blockId, blockName) {
|
|
|
|
|
window.openLogicBlockPanel = function (blockId) {
|
|
|
|
|
CURRENT_BLOCK_ID = blockId;
|
|
|
|
|
closeNodeForm();
|
|
|
|
|
document.getElementById('logicBlockPanelTitle').textContent = blockName || '?';
|
|
|
|
|
var block = FLOW_BLOCKS.find(function (b) { return b.id === blockId; });
|
|
|
|
|
document.getElementById('logicBlockPanelTitle').textContent = (block && block.name) || '?';
|
|
|
|
|
panel.classList.remove('hidden');
|
|
|
|
|
panel._fsToggle.enter();
|
|
|
|
|
renderFlow();
|
|
|
|
@@ -2988,10 +2989,7 @@ function makeFloatPanelFullscreenable(panel, toggleBtn) {
|
|
|
|
|
var requestedTab = {{ (request.args.get('tab') or '')|tojson }};
|
|
|
|
|
if (requestedTab) switchBuilderTab(requestedTab);
|
|
|
|
|
var requestedBlock = {{ request.args.get('block', type=int)|tojson }};
|
|
|
|
|
if (requestedBlock) {
|
|
|
|
|
var block = FLOW_BLOCKS.find(function (b) { return b.id === requestedBlock; });
|
|
|
|
|
if (block) openLogicBlockPanel(block.id, block.name);
|
|
|
|
|
}
|
|
|
|
|
if (requestedBlock) openLogicBlockPanel(requestedBlock);
|
|
|
|
|
})();
|
|
|
|
|
|
|
|
|
|
// ---------- Timeline d'animation : piste par élément, clips Animate.css ou
|
|
|
|
|