# LibMatic CHANGELOG

## Unreleased

### Library consolidation

- LibMatic-CombatTextBounce-1.0 (MINOR 5), LibMatic-FitText-1.0 (MINOR 1), and LibMatic-RosterFrame-1.0 (MINOR 2) moved into this repo from the individual addons. LibMatic is now the single source of truth for all five shared modules. Consumer addons symlink `Libs/LibMatic` to this repo for development and fetch it as a BigWigs packager external for release.

### LibMatic-Settings

- **MINOR 13**: per-addon descriptions in the General page cross-addon nav block. Each released addon's blurb renders as a full-width, word-wrapped node between its icon and its CurseForge link, localized into every shipped client locale (enUS, deDE, esES, esMX, frFR, itIT, koKR, ptBR, ruRU, zhCN, zhTW; enGB falls back to enUS) and resolved by `GetLocale()`. New `lib:GetAddonDescription(key)` accessor returns the locale-resolved blurb. CritMatic, GearMatic, and RepMatic ship descriptions; the running addon is still excluded from its own block, and addons without a description (or not yet released) render unchanged.
- **MINOR 12**: `BuildShadowControls` returns a shared "Shadow Strength" range node
  (0..1, step 0.05) so consumers source the alert shadow-opacity slider from the
  library instead of hand-rolling it. Mirrors `BuildCountUpControls`.
- **MINOR 11**: `BuildCountUpControls` accepts an optional `startDelay` spec (`startDelay.get`/`startDelay.set`, `names.startDelay`/`names.startDelayDesc`, and `startDelayOrder`/`startDelayWidth`/`startDelayMin`/`startDelayMax`/`startDelayStep` tuning). When supplied it returns a `startDelay` range node, so consumers source the fade-delay-when-animation-off control from the shared builder instead of hand-rolling it. Backward compatible: with no `startDelay` spec the builder returns the prior `toggle`/`duration`/`hold` set unchanged.
- **MINOR 6**: `BuildSoundPage` accepts `opts.scan`, adding a "Scan for Custom Sounds" button that calls `LibMatic-CustomMedia-1.0:Scan(opts.scan.addon)` and reports the result via optional `opts.scan.onResult(sounds, fonts)`.
- **MINOR 3**: `BuildAlertPage` accepts `opts.position`, adding a "Position Alert" button to the Alert page's General tab. The button opens `LibMatic-AlertPositioner-1.0`; `opts.position` carries the `get`/`set`/`default`/`close`/`reopen` callbacks.
- **MINOR 2**: roster entries carry a `released` flag. The General page cross-addon nav block renders an addon's icon and CurseForge link only when its roster entry is `released`, so an ILA addon not yet on CurseForge does not show a dead link. RareMatic, QuestMatic, and MountMatic added to the roster as not-yet-released.
- **MINOR 1**: initial release. `BuildGeneralPage`, `BuildAlertPage`, `BuildSoundPage`, `BuildSocialPage`, `BuildChangeLogPage`, `BuildProfilesPage`, plus `ResolveShow` and `GetRoster`. Ace3 page-builder helper; the consumer keeps its own `RegisterOptionsTable` / `AddToBlizOptions`. Per-page and per-setting developer `show` flag, closure or `bind` get/set, a canonical cross-addon roster with per-faction link icons (the running addon is excluded from its own nav block), configurable alert notification format strings, and a two-option alert bounce-style picker driven by consumer-supplied get/set.

### LibMatic-AlertShadow

- **MINOR 1**: initial release. `ApplyTextShadow` and `ApplyIconShadow` give alert
  text and icons a strength-adjustable drop shadow (0 = none, 1 = full). The icon
  shadow is a cached black silhouette behind the icon, since icon textures have no
  native shadow. Pure, flavor-agnostic.

### LibMatic-OverlayGuard

- **MINOR 2**: `SimulateOverlay(style, seconds)` shows a faithful look-alike of a
  native dark screen (level-up, renown, cinematic) and defers a queued alert behind
  it, so the deferral can be previewed in-game on any flavor without a real event.
- **MINOR 1**: initial release. `RunWhenClear`, `IsBlocked`, `Block`, `Unblock`,
  `Poll`, `RegisterWatch`. Holds an alert while a native dark overlay is on screen
  (cinematics and movies on every flavor, the EventToast level-up and celebration
  banner, the talking head; retail addons can register the renown celebration
  frame), then replays it once the overlay clears. Stale callbacks past a 10s hold
  are dropped; a 20s per-watch timeout plus a 0.5s poll keep the queue from
  stalling.

### LibMatic-AlertPositioner

- **MINOR 1**: initial release. `lib:Open(opts)`. A drag-to-place overlay for on-screen alerts: a movable frame with a looping mock crit, Accept/Cancel/Reset buttons, and Escape-to-cancel. Works in resolution-independent center-relative percentages. `LibMatic-CombatTextBounce-1.0` soft dependency for the bounce, with a local fallback.

### LibMatic-CustomMedia

- **MINOR 1**: initial release. `Register`, `Scan`, `GetRegistered`. Drop-in custom sounds and fonts: a player renames a file to a fixed slot (`Sound5.ogg`, `Font5.ttf`) in the addon's `CustomSounds`/`CustomFonts` folder; the library load-checks each slot and registers the valid ones into LibSharedMedia-3.0 under per-addon namespaced names. Fonts validate silently at login; sounds probe (`PlaySoundFile` + `StopSound`) behind a Scan button and register from a consumer-persisted cache. Only `.ogg`/`.mp3` and `.ttf`/`.otf` paths are ever referenced. LibSharedMedia-3.0 soft dependency.

### LibMatic-SoundPack

- **MINOR 3**: 15 sounds added to the pack: Alarm Clock, Anima Cast, Artifact Unlock, Banshee, Deathwing Wound, Epic Loot Toast, Icy Touch, Legendary Toast, LFG Denied, Mission Complete, Shop, Shop 2, Ten, Titan Light, World Quest Complete. Every consumer (CritMatic, GearMatic, RepMatic, and the rest) picks them up automatically through `Register`; no addon-side change required.

### LibMatic-Broadcast

- **MINOR 2**: the leader/assistant `RAID_WARNING` shortcut now runs only when election is enabled. With election off, `Broadcast` is a plain direct send with no raid-warning path. An explicit `opts.channel` (for example `GUILD`) is now honored even when the player is not in a party or raid, so election-off consumers can broadcast to guild and other channels.
- **MINOR 1**: initial release. `Register`, `Get`, `Broadcast`, `GetPeers`, `SetElectionEnabled`. Group chat broadcast with an opt-in single-announcer election: one elected peer sends, receiver-side dedupe collapses simultaneous triggers, raid leader/assistant sends a `RAID_WARNING` directly, LFR uses `INSTANCE_CHAT`. The `electionEnabled` dev flag is off by default. `marker` is emitted as the locale-safe `{rtN}` token. AceComm-3.0 soft dependency with a direct-send fallback.

### LibMatic-Startup

- **MINOR 1**: initial release. `Register`, `Get`, `PrintBanner`, `GetBannerText`, `PrintHelp`, `GetHelpLines`, `GetAddOnVersion`, `GetBrandColor`. Renders the chat-frame load banner and slash-command help listing, with optional faction colouring (Alliance blue, Horde red). Renders text only and never registers slash commands.

### LibMatic-ChangeLog

- **MINOR 2**: changelog text renders in one uniform colour, default black, with no coloured version or section headers. `BuildOptionsTable` accepts `opts.profile` as a function so a consumer can register its options panel before its database exists.
- **MINOR 1**: initial release. `lib:Show(spec)`, `lib:ShowIfNew(spec, lastSeenVersion)`, `lib:Close()`, `lib:BuildOptionsTable(opts)`. Structured changelog entries, AceGUI popup with LibSharedMedia styling, StaticPopup fallback.

### LibMatic-IconPicker

- **MINOR 2**: bump strata to `FULLSCREEN_DIALOG` and set `Toplevel`. Fixes z-order conflicts where a host addon's window (also at `DIALOG` strata) painted its tab buttons and widgets through the picker.
- **MINOR 1**: initial release. `lib:Open(currentIcon, callback)`, `lib:Close()`, `lib:IsOpen()`. Callback receives chosen fileDataID or nil.

### Test harness

- `/libmatictest` (alias `/lmt`) opens the picker for visual verification. The `changelog`, `startup`, `settings`, `media`, and `broadcast` subcommands exercise the matching modules. The `settings` subcommand also asserts the alert positioner button and the custom-media scan button are built; the `media` subcommand registers and scans custom media.
