https://github.com/backstagephp/translations
Backstage Translations for Filament
https://github.com/backstagephp/translations
filament languages laravel plugin translations
Last synced: 3 months ago
JSON representation
Backstage Translations for Filament
- Host: GitHub
- URL: https://github.com/backstagephp/translations
- Owner: backstagephp
- License: mit
- Created: 2025-01-14T09:38:57.000Z (about 1 year ago)
- Default Branch: main
- Last Pushed: 2025-04-10T08:32:26.000Z (10 months ago)
- Last Synced: 2025-04-10T08:58:24.975Z (10 months ago)
- Topics: filament, languages, laravel, plugin, translations
- Language: PHP
- Homepage: https://backstagephp.com/docs/translations
- Size: 683 KB
- Stars: 3
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- Contributing: .github/CONTRIBUTING.md
- Funding: .github/FUNDING.yml
- License: LICENSE.md
- Security: .github/SECURITY.md
Awesome Lists containing this project
README
# Backstage: Translations for Filament
[](https://packagist.org/packages/backstage/translations)
[](https://github.com/backstagephp/translations/actions?query=workflow%3Arun-tests+branch%3Amain)
[](https://github.com/backstagephp/translations/actions?query=workflow%3A"Fix+PHP+code+styling"+branch%3Amain)
[](https://packagist.org/packages/backstage/translations)
## Nice to meet you, we're [Vormkracht10](https://vormkracht10.nl)
Hi! We're a digital agency from Nijmegen in the Netherlands and we use Laravel for everything: advanced websites with a lot of bells and whistles and large web applications.
> **Note**: All screenshots used in documentation are taken using browser developer tools simulating a "Nest Hub Max" device with dimensions of 1280x800 pixels at 100% zoom.
## Before using
Please read this documentation first: [https://github.com/backstagephp/laravel-translations](https://github.com/backstagephp/laravel-translations)
## Installation
You can install the package via composer:
```bash
composer require backstage/translations
```
You can publish and run the migrations with:
```bash
php artisan vendor:publish --provider="Backstage\Translations\Laravel\TranslationServiceProvider"
php artisan vendor:publish --provider="Backstage\Translations\Filament\TranslationServiceProvider"
php artisan migrate
```
You can publish the config file with:
```bash
php artisan vendor:publish --tag="translations-config"
php artisan vendor:publish --tag="backstage-translations-config"
```
Optionally, you can publish the views using
```bash
php artisan vendor:publish --tag="backstage-translations-views"
```
Add the TranslationsPlugin to the desired panel provider:
```php
use Backstage\Translations\Filament\TranslationsPlugin;
$panel
->plugins([
TranslationsPlugin::make(),
]);
```
Optionally, you can disable the language switcher and rely on the ``default`` language:
```php
use Backstage\Translations\Filament\TranslationsPlugin;
$panel
->plugins([
TranslationsPlugin::make()
->languageSwitcherDisabled(),
]);
```
If you want to show only the language switcher in a panel, you can set the `canManageTranslations` to `false`:
```php
use Backstage\Translations\Filament\TranslationsPlugin;
$panel
->plugins([
TranslationsPlugin::make()
->userCanManageTranslations(false),
]);
```
## Testing
```bash
composer test
```
## Changelog
Please see [CHANGELOG](CHANGELOG.md) for more information on what has changed recently.
## Contributing
Please see [CONTRIBUTING](.github/CONTRIBUTING.md) for details.
## Security Vulnerabilities
Please review [our security policy](../../security/policy) on how to report security vulnerabilities.
## Credits
- [Manoj Hortulanus](https://github.com/arduinomaster22)
- [Mark van Eijk](https://github.com/markvaneijk)
- [All Contributors](../../contributors)
## License
The MIT License (MIT). Please see [License File](LICENSE.md) for more information.
---
Made with ❤️ by [Vormkracht10](https://vormkracht10.nl)