MedieInfo Library U2.5
=======================

Requires:
- ESP32
- ProjectUNION Core 0.3.0
- ProjectUNION MQTT 0.3.0
- PubSubClient
- Adafruit GFX
- Adafruit ST7735 and ST7789 Library
- TJpg_Decoder

Hardware:
- TFT ST7789 240x240
- SPI SCLK GPIO18
- SPI MISO GPIO19
- SPI MOSI GPIO23
- TFT CS GPIO15
- TFT DC GPIO2
- TFT RST GPIO4
- SD CS GPIO5
- Setup button GPIO27

ProjectUNION owns:
- WiFi and setup hotspot
- hostname and mDNS
- language, layout and common pages
- firmware update
- MQTT broker, TLS, reconnect, test and status

MedieInfo owns:
- TFT and SD card
- JPG upload, folders and playlists
- 16 data slides with 4 lines each
- direct MQTT payloads and JSON fields
- mixed image/slide playback
- project-specific MQTT commands and topics

Legacy migration:
- Main configuration is read from namespace: medieinfo
- WiFi fallback is read from namespace: miwifi
- MQTT broker settings are migrated into UnionMqtt
- Media folders, slide definitions and playback files remain on the SD card
- Old Preferences data is not deleted

Recommended test:
1. Upload by USB
2. Verify WiFi and hostname
3. Verify SD and existing media folders
4. Open Media, Slides and Run pages
5. Test an existing JPG
6. Test an existing data slide
7. Verify MQTT broker settings and JSON value updates
8. Test firmware upload


Changes in U2.1
---------------
- Added the missing project_config.h compatibility header.
- Defines APP_VERSION for the original MedieInfo web module.
- Keeps the existing display, SD, slide and playlist logic unchanged.
- Still requires ProjectUNION 0.2.2.


Changes in U2.2
---------------
- Added missing forward declarations required by the large project modules.
- Added shared Preferences instance used by slide storage.
- Fixes missing declarations for:
  - mediaFolderTableHtml()
  - saveMediaFolders()
  - loadDataSlides()
  - loadSlotToCurrentData()
- Project functionality is otherwise unchanged.


Changes in U2.3
---------------
- Added a real global `Preferences prefs;` instance before the project modules are included.
- The previous U2.2 check accidentally detected a local variable with the same name and therefore skipped the global declaration.
- Fixes slide storage compilation in `saveDataSlides()` and `loadDataSlides()`.


Changes in U2.4
---------------
- Restored modal editing for media folders.
- Restored modal editing for slides.
- Added fixed dark modal background, centered dialog and internal scrolling.
- Reduced media thumbnails to a compact gallery size.
- Restored green highlighting for the active playback mode.
- No changes to SD, MQTT, slide or playback functionality.


Changes in U2.5
---------------
- Reduced compiled flash usage to stay below the default OTA partition limit.
- Simplified and minified modal/gallery CSS.
- Shortened a few help texts.
- Modal media editing, modal slide editing and green active playback button remain.
- Project-specific CSS reduced by about 1112 bytes before compilation.


Changes in U2.7 Slim
--------------------
- Removed the unused ArduinoJson include. JSON fields still use the existing
  lightweight built-in extractor.
- Removed only the Weather/Power demo buttons and their demo-data generator.
  Normal slides, MQTT, JSON fields and playlists are unchanged.
- Shortened non-essential help text in all three languages.
- Kept modal media editing, modal slide editing and green active playback button.
- Removed the custom partition experiment; standard OTA partition is used.
- Project web source reduced by about 4040 bytes.


Changes in U2.9 AuditSlim
-------------------------
- Further reduced static web text and modal CSS.
- Replaced the project SVG icon with a smaller equivalent.
- Removed obsolete compatibility wrappers no longer called by the current code.
- Removed source comments/blank lines from the large display module.
- Normal MedieInfo functionality is unchanged.
- Web source reduced by about 417 bytes.
- Display module source reduced by about 2151 bytes.


Changes in U2.9 AuditSlim
-------------------------
- Removed the obsolete legacy single-slide MQTT API (/data/#).
- Slides now render directly from the 16-slide arrays.
- Removed duplicate current-slide variables and copy functions.
- Removed unused legacy helper functions and wrappers.
- Normal slide editing, MQTT topics per line, JSON extraction and playlists remain.


Changes in U2.10 DeepSlim
-------------------------
- Removed the obsolete standalone status page; ProjectUNION already provides it.
- Removed unused folder option/table wrappers.
- Removed unused imageExists(), isLang(), yesNo() and playlistStart().
- Removed helpers that became unused after the status-page removal.
- Simplified legacy view synchronization.
- Reused one redirect helper for playback actions.
- No normal media, slide, MQTT, JSON or playlist functionality was removed.


Changes in U2.11 Modular
------------------------
- Updated for the modular ProjectUNION architecture.
- Uses ProjectUNION Core 0.3.0.
- Uses ProjectUNION MQTT 0.3.0.
- Does not include or depend on ProjectUNION DCC.
- No MedieInfo functionality has been changed.


Changes in U2.12 ReleaseSlim
----------------------------
- Removed the one-time migration from the old standalone MedieInfo U1.1.
- Removed reads from the old `medieinfo` and `miwifi` Preferences namespaces.
- Removed legacy WiFi and MQTT transfer code.
- Current ProjectUNION settings and SD-card content are unchanged.
- Normal media, slides, MQTT/JSON, playlists and OTA functionality remain.

Important:
- Use U2.11 once first when upgrading directly from the old pre-UNION version.
- U2.12 is intended for systems already running a ProjectUNION version and
  for new installations.


Changes in U2.13 FinalSlim
--------------------------
- Flags and all three languages are retained.
- Removed old web routes that are no longer linked by the current interface.
- Removed the corresponding unused page handlers.
- Removed legacy MQTT command aliases while retaining the current commands:
  start, stop, next, prev, show N, slide N, folder NAME,
  playlist slides/images/mixed/stop/next/prev and slideshow.
- Normal media, upload, slide editing, MQTT/JSON, playback and OTA remain.


Changes in U2.14 Language
-------------------------
- Translated the remaining Danish text on the Slides page.
- Translated the slide overview, current display and MQTT help table.
- Translated the MedieInfo MQTT connection state on the Status page.
- Danish, English and German are supported.
- No media, slide, MQTT, playback or OTA functionality was changed.


Changes in U2.15 LanguageSlim
-----------------------------
- Keeps Danish, English and German on the Slides page.
- Replaces the long MQTT documentation table with a compact version.
- Shortens several explanatory texts and buttons.
- No media, slide, MQTT, JSON, playback or OTA functionality changed.


Changes in U2.16 LanguageFix
----------------------------
- Fixed compilation error in handleData().
- Restored the local MQTT base-topic variable before the compact MQTT help table.
- No functionality or translations changed.


Changes in U2.17 DropdownLanguage
---------------------------------
- Icon and theme dropdown values now follow Danish, English and German.
- Slide overview uses the same translated icon and theme labels.
- Removed redundant internal IDs in parentheses from dropdowns to save flash.
- No functionality changed.
