update documentation
Some checks are pending
Tests & Quality Checks / Test on Python 3.11 (push) Waiting to run
Tests & Quality Checks / Test on Python 3.12 (push) Waiting to run
Tests & Quality Checks / Test on Python 3.11-1 (push) Waiting to run
Tests & Quality Checks / Test on Python 3.12-1 (push) Waiting to run
Tests & Quality Checks / Test on Python 3.10 (push) Waiting to run
Tests & Quality Checks / Test on Python 3.11-2 (push) Waiting to run
Tests & Quality Checks / Test on Python 3.12-2 (push) Waiting to run
Tests & Quality Checks / Build Artifacts (push) Blocked by required conditions
Tests & Quality Checks / Build Artifacts-1 (push) Blocked by required conditions

This commit is contained in:
claudi 2026-03-03 08:41:28 +01:00
parent 4cc158a791
commit f0bab2afa5
4 changed files with 109 additions and 51 deletions

View file

@ -1,8 +1,28 @@
# Drag & Drop Problem Analysis - File Drop + Web App Popup
## Das Kernproblem
**Status**: Phase 1 (File Drop) ✅ Implemented | Phase 2 (Popup Trigger) ⏸️ Planned
**Last Updated**: March 3, 2026
**Ziel**: Bei ALT-Drag soll:
## Overview
### Current Implementation Status
✅ **Phase 1 - File Drop (IMPLEMENTED)**
- JavaScript in `bridge_script_intercept.js` intercepts drag events
- Calls `window.bridge.start_file_drag(url)` via QWebChannel to Qt
- Validates path against whitelist via `PathValidator`
- Converts Azure Storage URLs to local paths via `URLConverter`
- Creates and executes native Qt file drag operation
- Target application (InDesign, Word, etc.) successfully receives file
⏸️ **Phase 2 - Programmatic Popup Trigger (PLANNED)**
- Would require reverse-engineering the web app's popup trigger mechanism
- Could be implemented by calling JavaScript function after successful drop
- Currently: Applications handle popups manually or separately from file drops
---
## Das Kernproblem
1. ✅ File gedroppt werden (Z:\ Laufwerk) → Native File-Drop
2. ✅ Web-App Popup erscheinen (Auschecken-Dialog) → Web-App Drop-Event
@ -250,28 +270,39 @@ Object.defineProperty(DataTransfer.prototype, 'types', {
## 📝 Empfehlung
**Sofortige Maßnahmen:**
### Current Status (as of March 2026)
1. ✅ **Lösung A Phase 1 ist bereits implementiert** (File-Drop funktioniert)
✅ **Phase 1 Complete:**
- File-drop via native Qt drag operations is fully functional
- JavaScript bridge (`bridge_script_intercept.js`) successfully intercepts and converts drags
- Path validation and Azure URL mapping working
- Tested with real applications (InDesign, Word, etc.)
2. 🔍 **Reverse-Engineering durchführen:**
- GlobalDAM JRI im Browser öffnen
- DevTools öffnen (F12)
- ALT-Drag+Drop durchführen
- Beobachten:
- Network-Tab → API-Calls?
- Console → Fehler/Logs?
- Angular DevTools → Component-Events?
### For Future Enhancement (Phase 2 - Popup Trigger)
3. 🛠️ **Popup-Trigger implementieren:**
- Sobald bekannt WIE Popup ausgelöst wird
- JavaScript-Funktion `trigger_checkout_popup()` erstellen
- Von Qt aus nach erfolgreichem Drop aufrufen
**If popup trigger integration is needed:**
4. 🧪 **Testen:**
- ALT-Drag eines Assets
- File-Drop sollte funktionieren
- Popup sollte erscheinen
1. 🔍 **Reverse-Engineering the Target Web App:**
- Identify how popups are triggered (API call, component method, event, etc.)
- Use browser DevTools:
- Network tab → Monitor API calls
- Console → Check for JavaScript errors/logs
- Elements → Inspect component structure
- Angular/Vue DevTools if applicable
**Fallback:**
Falls Reverse-Engineering zu komplex ist → **Lösung B** verwenden (Kein Drag, nur Copy nach Popup-Bestätigung)
2. 🛠️ **Implement Popup Trigger:**
- Create JavaScript hook function (e.g., `window.trigger_popup(assetId)`)
- Connect to drop success signal from Qt
- Call popup trigger after successful file drop
3. 🧪 **Test Integration:**
- Verify file drops successfully
- Verify popup appears after drop
- Test with real assets/files
**Alternative Approaches:**
- **Lösung B (Manual)**: Keep file drop and popup as separate user actions
- **Lösung C (Complex)**: Use overlay window approach (more involved)
Current implementation uses **Phase 1 of Lösung A** and is production-ready.