Weave Code
Code Weaver
Helps Laravel developers discover, compare, and choose open-source packages. See popularity, security, maintainers, and scores at a glance to make better decisions.
Feedback
Share your thoughts, report bugs, or suggest improvements.
Subject
Message
Filament Sticky Header

Filament Sticky Header Laravel Package

awcodes/filament-sticky-header

Filament Panel plugin that makes page headers sticky while scrolling. Install via Composer, import the plugin CSS into your custom theme, then register StickyHeaderPlugin in your panel provider. Includes optional Floating theme and colored header styling.

View on GitHub
Deep Wiki
Context7

A Filament Panels plugin to make headers sticky when scrolling.

Frequently asked questions about Filament Sticky Header
How do I install the Filament Sticky Header plugin in my Laravel project?
Run `composer require awcodes/filament-sticky-header` and register the plugin in your `PanelProvider` using `StickyHeaderPlugin::make()`. Ensure you have a custom Filament theme set up first, as the plugin requires CSS injection via `@import` in your theme file.
Which Filament versions does this plugin support?
The plugin follows a versioned compatibility model: v4.x works with Filament 5.x, v3.x with 4.x, and so on. Check the [compatibility table](https://github.com/awcodes/filament-sticky-header#compatibility) in the README for exact mappings. Always verify with your Filament version before installing.
Can I disable sticky headers on specific pages in Filament?
Yes, use the `disabledOn()` method in your plugin configuration to exclude specific pages or classes. For example, `StickyHeaderPlugin::make()->disabledOn([MyPage::class])` will skip sticky behavior on those pages. This was added in v4.1.0.
Does this plugin work with Filament’s standalone packages (non-Panel)?
No, this plugin is designed specifically for Filament Panels and relies on its plugin system. It won’t work with standalone Filament resources or non-Panel Laravel apps. Ensure you’re using Filament Panels (v3+) for compatibility.
How do I customize the sticky header’s appearance (e.g., colors, shadows)?
Use the `floating()` and `colored()` methods to enable themes. For deeper customization, override the plugin’s CSS in your custom theme file by targeting its Tailwind classes (e.g., `.sticky-header`). The plugin’s styles are scoped to avoid conflicts.
Will this plugin cause performance issues in my Laravel admin dashboard?
No, the plugin is lightweight (~50KB CSS/JS) and uses Alpine.js (Filament’s default), which is scoped to the panel context. Audit with Lighthouse to confirm, but it shouldn’t impact critical rendering paths. Defer non-critical JS if needed.
Can I conditionally enable sticky headers based on user roles or preferences?
Yes, use closures with the `floating()` or `colored()` methods to dynamically enable/disable features. For example, `->floating(fn() => auth()->user()->isAdmin())` will only apply the floating theme to admin users. This aligns with Laravel’s closure-based patterns.
What if I don’t have a custom Filament theme? Can I still use this plugin?
No, the plugin requires a custom theme to inject its CSS. Follow Filament’s [custom theme docs](https://filamentphp.com/docs/4.x/styling/overview#creating-a-custom-theme) to set one up before installing. The CSS import is explicit and isolated to avoid conflicts.
Are there any known issues with notifications or page transitions?
The plugin handles notifications and page transitions gracefully. It reinitializes on `wire:navigated` (fixed in v2.0.6) and avoids conflicts with notification overlays (addressed in v1.2.0). Test on your specific pages to confirm, but regressions are rare.
What are the alternatives to this plugin for sticky headers in Filament?
For Filament Panels, this is the most dedicated solution. Alternatives include manually implementing sticky headers with CSS/JS (e.g., Tailwind’s `sticky` class) or using generic Laravel packages like `spatie/laravel-view-modifiers`, but they lack Filament-specific optimizations. This plugin is tailored for Filament’s ecosystem.
Weaver

How can I help you explore Laravel packages today?

Conversation history is not saved when not logged in.
Prompt
Add packages to context
No packages found.
terminal42/code-quality-tools
codifyo/ts-generator-bundle
andydefer/laravel-cluster
testo/fiber
mintobit/jobqueue
a4sex/maintenance-bundle
a4sex/entity-date-update
a4sex/client-identifier
a4sex/base-utilites
a4sex/key-value-storage
a4sex/micro-status
chilldev/dependency-injection-extra
datinglibre/datinglibre-app-api
biberltd/corebundle
bricre/symfony-bundle-test
biberltd/logbundle
dominium/http-adapter-bundle
dominium/google-analytics
a4sex/auto-clean-entity
christhompsontldr/laravel-inky