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

Spatie Translatable Laravel Package

lara-zeus/spatie-translatable

Filament v4 plugin adding Spatie Laravel Translatable support to your admin panel. Includes default locales, locale switcher, translation on create/edit/list/view pages, per-resource locale settings, and translatable relation managers.

View on GitHub
Deep Wiki
Context7

Product Decisions This Supports

  • Global Content Localization: Enables multilingual support for Filament-administered content (e.g., e-commerce product catalogs, CMS articles, or SaaS documentation) without duplicating resources. Aligns with expansion into new markets or compliance with regional language requirements.
  • Developer Efficiency (Build vs. Buy): Eliminates the need to build custom translation logic for Filament resources, reducing development time and technical debt. Leverages Spatie’s mature laravel-translatable package, which is already adopted by ~50K Laravel projects.
  • Unified Admin Experience: Provides a consistent, locale-aware UI for editors/admins to manage translations in Filament, reducing onboarding time for non-technical users.
  • Roadmap Prioritization:
    • Phase 1: Quick wins for translatable blog posts or product descriptions.
    • Phase 2: Extend to relation managers (e.g., multilingual comments for posts) or custom fields.
    • Phase 3: Integrate with translation APIs (e.g., DeepL) via middleware or custom logic.
  • Use Cases:
    • E-Commerce: Translatable product names, descriptions, and SEO metadata for global stores.
    • CMS/SaaS: Localized help centers, marketing pages, or user-generated content (e.g., forums).
    • Regulatory Compliance: Manage translations for legal disclaimers or localized terms of service.
    • Internal Tools: Multilingual support tickets, HR documentation, or project management content.

When to Consider This Package

  • Adopt if:

    • Your primary admin interface is Filament v4 (v3 requires a separate repo).
    • You need manual content translation (not automated/machine translation) for admin-managed resources.
    • Your team is already using Spatie’s laravel-translatable or plans to adopt it for consistency.
    • You want minimal setup for basic use cases (e.g., simple text fields, relation managers).
    • Your locale requirements are static (e.g., English + Spanish) and don’t require dynamic API-driven translations.
    • You’re comfortable with JSON-based translation storage (default) or can configure separate tables.
  • Look elsewhere if:

    • You’re using Filament v3 (use the v3-specific repo).
    • Your translation needs are frontend-only (e.g., Next.js, Vue I18n, or React Intl).
    • You require real-time machine translation (e.g., Google Translate API) or automatic fallback locales (consider spatie/laravel-translation-manager).
    • Your content is highly dynamic (e.g., user-generated translations with voting/ranking) or requires complex field types (e.g., nested rich text with embedded translations).
    • You’re not using Laravel/Filament as your core stack (e.g., Django, Rails, or static site generators).
    • You need advanced features like:
      • Translation memory (reusing previous translations).
      • Collaborative editing for translations.
      • Versioning for translated content.

How to Pitch It (Stakeholders)

For Executives/Business Leaders:

*"This package lets us manage multilingual content without building custom tools—saving months of dev work. For example:

  • E-commerce: Sell in Spain, Mexico, and Germany by translating product pages in Filament (no frontend changes).
  • Global CMS: Publish blog posts in 10 languages with a single admin interface.
  • Compliance: Localize legal docs or support articles for regional markets.

Why now?

  • Low risk: Built on Spatie’s proven package (used by 50K+ Laravel apps).
  • Scalable: Works for any Filament resource (products, posts, etc.).
  • Cost-effective: Free (MIT license), open-source, and maintained by the community.

Ask: Should we pilot this for [X use case] to validate the workflow before full rollout?"*


For Engineering/Tech Leads:

*"This is a Filament plugin that adds multilingual support to admin panels by extending Spatie’s laravel-translatable. Here’s the breakdown:

Pros:

  • Zero-config for basics: Add a trait to your resource/model, and you get locale switchers on CRUD pages.
  • Relation manager support: Translate nested resources (e.g., comments for multilingual posts).
  • Flexible locales: Override defaults per resource or globally.
  • Filament-native: Integrates with Filament’s ecosystem (e.g., Solution Forest’s Translate Field for complex inputs).

Cons/Limitations:

  • Locale switcher quirks: Avoid with complex fields (use dedicated plugins like mvenghaus/translatable-inline).
  • Filament v4 only: Not backward-compatible with v3.
  • Manual translations: No built-in machine translation or API integrations.

Recommendation: Use this if you’re already using Spatie’s translatable package or need a quick, maintained solution for Filament multilingual content. For advanced needs (e.g., API-driven translations), pair it with custom middleware or third-party services.

Next Steps:

  1. Prototype: Test with a simple resource (e.g., blog posts) to validate the UX.
  2. Field Strategy: Decide if you’ll use the built-in locale switcher or dedicated plugins for complex fields.
  3. Storage: Confirm if JSON columns or separate tables work for your scale.

Alternatives:

  • Custom build: If you need real-time translation APIs or collaborative editing.
  • Frontend-only: If translations are managed outside Filament (e.g., Next.js i18n)."*

For Product Managers:

*"This package helps us ship multilingual features faster by:

  1. Reducing dev time: No need to build translation CRUD from scratch.
  2. Unifying workflows: Editors manage all languages in one Filament interface.
  3. Scaling globally: Supports static locales (e.g., English + Spanish) without upfront complexity.

Key Questions to Validate:

  • Does this fit our translation workflow (manual vs. automated)?
  • Are we okay with JSON storage for translations, or do we need separate tables?
  • Will the locale switcher work for our field types, or do we need plugins like mvenghaus/translatable-inline?

Example Roadmap:

  • Phase 1: Launch with product descriptions (simple text fields).
  • Phase 2: Add relation managers (e.g., multilingual comments).
  • Phase 3: Integrate with a translation API for bulk imports.

Risk: Minimal—built on Spatie’s stable package with active maintenance."*


For Design/UX Teams:

*"This package adds a locale switcher to Filament’s admin panels, letting users:

  • Toggle between languages (e.g., English ↔ Spanish) on resource pages.
  • Edit translations in-context without leaving the Filament UI.

Considerations:

  • Consistency: Ensure the switcher aligns with your Filament theme (e.g., flags vs. language codes).
  • Complex Fields: For rich text or nested data, use dedicated plugins (e.g., solution-forest/translate-field) instead of the built-in switcher.
  • Editor Workflow: Test if the switcher improves or hinders productivity for translators.

Prototype Ask: Can we mock up how the locale switcher would look in our Filament dashboard?"*

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.
codraw/framework-extra-bundle
codraw/messenger
codraw/security
codraw/mailer
codraw/contracts
codraw/profiling
codraw/dependency-injection
codraw/tester
codraw/core
nexmo/api-specification
capell-app/block-library
axium/identity
cetria/laravel-dummy-models
cetria/reflection-helper
agropredict/sso-auth-bundle
evolvestudio/spam-protection
datacore/hub-sdk
develia/commons
cuci/prototurk-sdk
cuci/prototurk-sdk-symfony