Replace custom file-upload-queue.js with FilePond

- Delete file-upload-queue.js (495 lines of custom queue logic)
- Delete sortable.min.js dependency
- Add file-upload-filepond.js: thin wrapper that upgrades .tfe-file-picker
  inputs to FilePond instances with storeAsFile:true for native multipart
  form submission (no form-submit interception needed)
- Update fichiers-fragment.php: replace queue container <ul> elements
  and empty-state <p> with bare <input> elements that FilePond upgrades;
  change name attributes to queue_file[tfe][] etc. for PHP compatibility
- Update add.php, edit.php, partage/index.php: swap JS/CSS refs
- Clean up form.css: remove .fq-* and .tfe-file-queue custom styles,
  add FilePond theme overrides matching xamxam design tokens
- Update dead-code fieldset-files.php for consistency

Server-side stays unchanged: PHP receives ['queue_file']['tfe'][]
exactly as before through native multipart submission.
This commit is contained in:
Pontoporeia
2026-05-10 20:10:15 +02:00
parent 223a15b397
commit 1aff5ff46d
12 changed files with 299 additions and 659 deletions

View File

@@ -2,7 +2,7 @@
* Beforeunload guard — prompts the user before navigating away from unsaved changes.
*
* Attach to any form with a data-beforeunload-guard attribute.
* Also watches window.__xamxamDirty (set by file-upload-queue.js).
* Also watches window.__xamxamDirty (set by file-upload-filepond.js on FilePond events).
* No effect when JavaScript is unavailable (form posts normally).
*/
(() => {