@fluxhub/fluxhub-lib 19.0.116 → 19.0.118

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -32234,16 +32234,22 @@ class BpmnEditorComponent {
32234
32234
  * Supports formats like: "Activity_10", "Task_20", "Step_30", "10", "Step 10", etc.
32235
32235
  */
32236
32236
  extractStepNumber(elementId, elementName) {
32237
- // Try to extract from ID first (e.g., "Activity_10", "Task_20")
32238
- const idMatch = elementId.match(/(\d+)$/);
32239
- if (idMatch) {
32240
- return parseInt(idMatch[1], 10);
32237
+ // Try to extract from name first (more reliable for this use case)
32238
+ // Pattern: "[10]", "[20]", etc. in brackets
32239
+ let nameMatch = elementName.match(/\[(\d+)\]/);
32240
+ if (nameMatch) {
32241
+ return parseInt(nameMatch[1], 10);
32241
32242
  }
32242
- // Try to extract from name (e.g., "Step 10", "10 - Description", "Agenti (10)")
32243
- const nameMatch = elementName.match(/\b(\d+)\b/);
32243
+ // Try other patterns in name
32244
+ nameMatch = elementName.match(/\b(\d+)\b/);
32244
32245
  if (nameMatch) {
32245
32246
  return parseInt(nameMatch[1], 10);
32246
32247
  }
32248
+ // Finally try to extract from ID (e.g., "Activity_10", "Task_20")
32249
+ const idMatch = elementId.match(/(\d+)$/);
32250
+ if (idMatch) {
32251
+ return parseInt(idMatch[1], 10);
32252
+ }
32247
32253
  return null;
32248
32254
  }
32249
32255
  /**
@@ -32280,10 +32286,11 @@ class BpmnEditorComponent {
32280
32286
  </div>
32281
32287
  `;
32282
32288
  try {
32289
+ // Position overlay below and to the left of the connection
32283
32290
  this.overlays.add(connection.id, {
32284
32291
  position: {
32285
- top: -10,
32286
- left: 0
32292
+ bottom: 5, // Più vicino alla freccia (in basso)
32293
+ left: -20 // Più vicino alla freccia (a sinistra)
32287
32294
  },
32288
32295
  html: overlayHtml
32289
32296
  });
@@ -32453,6 +32460,11 @@ class win_log_v2 {
32453
32460
  if (log.liv_ini != null && log.liv_fin != null) {
32454
32461
  const fromStep = parseInt(log.liv_ini, 10);
32455
32462
  const toStep = parseInt(log.liv_fin, 10);
32463
+ // IMPORTANT: Ignore transitions beyond current step
32464
+ // Only process transitions where BOTH fromStep and toStep are <= currentStep
32465
+ if (fromStep > this.currentStep || toStep > this.currentStep) {
32466
+ return; // Skip this transition
32467
+ }
32456
32468
  // Validate step numbers (10-890 range, exclude final states 900+)
32457
32469
  if (fromStep >= 10 && fromStep < 900 && toStep >= 10) {
32458
32470
  stepNumbers.add(fromStep);