trypost/app/Support
Paulo Castellano cf045f2cdb Harden per-image alt text across publishers, validation, and attach paths
Publishing:
- Only send alt text for images (isImage guards on LinkedIn, X, Discord, Mastodon); never inject altText into video/document payloads.
- X sets alt via a best-effort media/metadata call so a metadata failure no longer blocks the tweet.

Validation:
- Validate media alt_text with a closure on media.*.meta so width/height/duration/slide_* survive a post update (Laravel's excludeUnvalidatedArrayKeys was stripping them).
- Add ALT_TEXT_MAX_LENGTH constant, a proper string-type error, and a localized attribute name.

Media attach (REST + MCP):
- Support per-image alt on attach-media-from-url via structured urls: [{url, alt?}] and on the MCP upload tool via an optional alt; alt is stored only for images.
- Carry submitted meta onto hosted external-URL media so alt is no longer dropped.

Composer:
- Alt-text dialog disables Save and reddens the counter over the limit, counting code points of the trimmed value to match the backend.
- Autosave shows 'Saved' only on a successful response; the lightbox alt overlay renders for images only.

Adds unit, feature, MCP, and browser tests covering every path above.
2026-07-16 13:55:33 -03:00
..
Billing Ignore never-started subscriptions when detecting a first-time customer 2026-07-09 16:03:25 -03:00
BillingCycle.php refactor: address code review for per-workspace pricing 2026-06-21 21:28:47 -03:00
HexColorName.php feat: AI image generation pipeline and post creation overhaul 2026-05-08 13:38:30 -03:00
MentionParser.php feat: @mentions in comments, AI Action layer + MCP tools, settings tabs 2026-05-01 20:59:03 -03:00
PostMediaRules.php Harden per-image alt text across publishers, validation, and attach paths 2026-07-16 13:55:33 -03:00
PostPlatformMetaRules.php feat(linkedin): support PDF document (carousel) posts 2026-06-24 16:32:27 -03:00
PostStatusRules.php refactor(posts): replace PostStatusGuard with PostStatusRules for editing and deletion checks 2026-05-21 19:32:42 -03:00
WorkspacePresence.php feat: @mentions in comments, AI Action layer + MCP tools, settings tabs 2026-05-01 20:59:03 -03:00