misaf / vendra-faq
Frequently Asked Questions management system with categorization
Requires
- php: ^8.4
- awcodes/filament-badgeable-column: ^4.0
- lara-zeus/spatie-translatable: ^2.0.1
- misaf/filament-jalali: ^5.1.4
- misaf/vendra-multimedia: v1.12.3
- misaf/vendra-support: v1.12.3
- spatie/eloquent-sortable: ^5.0.1
- spatie/laravel-package-tools: ^1.93.1
- spatie/laravel-sluggable: ^4.0.2
Requires (Dev)
None
Suggests
- misaf/vendra-tagger: Install this in the host application to assign typed tags to FAQs.
Provides
None
Conflicts
None
Replaces
None
README
Tenant-aware FAQ management for Vendra applications.
Features
- FAQ categories
- FAQs with translatable content
- Filament resources on the
adminpanel
Requirements
- PHP 8.4+
- Laravel 13
- Filament 5
- Livewire 4
- Pest 4
- Tailwind CSS 4
misaf/vendra-multimediamisaf/vendra-support
Optional:
misaf/vendra-tagger— enables assigningfaq-typed tags through the shared Support resolver
Installation
composer require misaf/vendra-faq php artisan vendor:publish --tag=vendra-faq-migrations php artisan migrate
Optional translations publish:
php artisan vendor:publish --tag=vendra-faq-translations
The service provider and Filament plugin are auto-registered.
Usage
Create an FAQ category:
use Misaf\VendraFaq\Models\FaqCategory; $category = FaqCategory::query()->create([ 'name' => ['en' => 'General'], 'description' => ['en' => 'General questions'], 'slug' => ['en' => 'general'], 'position' => 1, 'active' => true, ]);
Create an FAQ:
use Misaf\VendraFaq\Models\Faq; Faq::query()->create([ 'faq_category_id' => $category->id, 'name' => ['en' => 'How do I create an account?'], 'description' => ['en' => 'Use the register page and verify your email.'], 'slug' => ['en' => 'how-do-i-create-an-account'], 'position' => 1, 'active' => true, ]);
Load FAQs with their category:
$faqs = Faq::query() ->with('faqCategory') ->where('active', true) ->get();
When Tagger is installed, FAQ forms and tables expose tags automatically. Create tags with the reserved faq type:
use Misaf\VendraTagger\Models\Tagger; Tagger::findOrCreate('Account', type: 'faq', locale: 'en');
FAQ imports neither Vendra Tagger nor Spatie Tags.
Filament
Resources are available in the shared Content cluster on the admin panel:
- FAQ Categories
- FAQs
Demo seeders use bundled JSON fixtures in production and when their declared factory classes are unavailable. Local monorepo development continues to use factories when they are autoloadable.
Testing
Run the package checks from the project root:
php artisan test --compact --testsuite=vendra-faq
composer stan
License
MIT. See LICENSE.