Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error display text in other language not english. #213

Open
dienht opened this issue Dec 24, 2024 · 0 comments
Open

Error display text in other language not english. #213

dienht opened this issue Dec 24, 2024 · 0 comments

Comments

@dienht
Copy link

dienht commented Dec 24, 2024

Bug Description

When using a non-English locale, the impersonation banner shows raw translation keys instead of the translated text:

Current display:
filament-impersonate::banner.impersonating Nguyễn Khánh Thu filament-impersonate::banner.leave

Expected display:
Đang giả lập người dùng Nguyễn Khánh Thu Kết thúc giả lập

Steps to Reproduce

  1. Set application locale to non-English (e.g. Vietnamese 'vi')
  2. Implement impersonation feature
  3. Start impersonating a user
  4. Observe the banner text

Current Workaround Attempts

  • Created translation files in various locations:
    • lang/vendor/filament-impersonate/vi/translations.php
    • lang/vendor/filament-impersonate/vi/banner.php
    • lang/vi/filament-impersonate.php
  • None of above solutions worked, still showing raw translation keys

Suggested Solutions

  1. Add proper documentation for translation structure
  2. Provide publishable language files:
    php artisan vendor:publish --tag=filament-impersonate-translations
  3. Include example translation files in the package

Environment

  • Laravel version: 11.x
  • Filament v3
  • PHP version: 8.2
  • Package version: latest
  • Locale: vi

Screenshots attached:
image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

1 participant