Fixed
- RichEditor: Filament now renders the editor itself and the counter is placed around it. File attachments, mentions, floating toolbars, link protocols and resizable images were silently switched off by the copied view.
- The counter no longer breaks when the limit is empty: the limit is always a number, so Alpine gets valid JavaScript.
- The counter now follows every input event and the Livewire state, so it updates on paste, autofill, dictation,
$set()and form resets, not only on key presses. - Characters are counted per code point in the browser too, so an emoji counts as one, like Laravel's
max:rule. - The RichEditor counter no longer polls every 500 ms and no longer leaks a Livewire hook per editor.
- Invalid inline height on the Textarea.
- Development files (
.claude/,CLAUDE.md,package-lock.json,stubs/and more) are no longer included in the Packagist archive.
Added
- Going over the limit is shown in words, for example "(12 too many)", and in bold, not by colour alone. The message is announced to screen readers and the input points at the counter with
aria-describedby. characters_overtranslation in every language.shouldShowCharacterCounter();getShowCharacterCounter()is deprecated.- Support for Laravel 13. CI now tests PHP 8.2 to 8.5 on Laravel 12 and 13 with Filament 4 and 5. Laravel 11 is no longer tested: Composer refuses its releases because of open security advisories.
Changed
- The package requires
filament/formsandfilament/supportinstead of the wholefilament/filamentpanel package. - The stylesheet is plain CSS using Filament's colour variables (dark mode included), so there is no build step anymore. The exceeded class is now
fi-input-charcounter-exceededinstead ofwarning. - The old translation key
character_seperatoris no longer read. declare(strict_types=1)everywhere, PHPStan on the highest level.
Fixed
-
RichEditor character counting: Completely refactored RichEditor character counter implementation
- Fixed JavaScript errors during component initialization (missing parameters for richEditorFormComponent)
- Added all required Filament v4/v5 parameters (acceptedFileTypes, floatingToolbars, mentions, linkProtocols, etc.) with safe defaults
- Changed from trying to access TipTap editor instance to directly reading DOM element text content
- Character counter now uses
$el.querySelector('.fi-fo-rich-editor-content')to get text content - Implemented Livewire.hook('commit') for reactive updates + periodic polling (500ms) as fallback
- RichEditor now properly counts characters in real-time while typing
-
HasCharacterLimit trait: Made
characterLimit()automatically callmaxLength()to enforce HTML maxlength attribute- Prevents users from pasting or entering more characters than the limit
- Ensures consistency between visual counter and actual enforcement
Technical Details
- Session timestamp: 2026-01-30
- Estimated time: ~2 hours debugging and implementation
- Components tested: TextInput ✓, Textarea ✓, RichEditor ✓
- Test environments: Filament v4 and v5 test projects