Weave 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

Statamic One Click Content Translation Laravel Package

appswithlove/statamic-one-click-content-translation

Add one-click content translation to Statamic. Translate entries, pages, and other content into your configured sites or locales directly from the Control Panel, simplifying multilingual publishing and reducing manual copywork for editors and content teams. Ideal for Statamic multisite workflows.

View on GitHub
Deep Wiki
Context7

Getting Started

Install the addon via Composer and let Statamic discover it. Publish the addon assets/config before first use:

composer require <vendor>/statamic-one-click-content-translation
php artisan vendor:publish --tag=statamic-one-click-content-translation

Configure your DeepL or Google API credentials in .env/config, then check resources/sites.yaml first. Each Statamic site should have a locale or lang; add translation_locale when you need an exact regional target such as en-US or pt-PT.

Your first practical use case: open a multilingual entry in the Statamic Control Panel, choose the source and target sites, and run the one-click translation action. Review the generated content in the target site before publishing.

Implementation Patterns

  • Multisite editorial workflow: Use the CP action for day-to-day entry translation. Treat machine translation as a draft step, then have an editor review and publish.
  • Explicit regional targets: For sites that need a specific variant, set translation_locale in resources/sites.yaml rather than relying on the site locale fallback:
    attributes:
      translation_locale: en-US
    
  • Provider-specific glossaries: When using DeepL glossaries, keep glossary keys in DeepL’s language-code format (DE, EN-US, etc.). Maintain separate glossaries for regional variants where terminology differs.
  • UI localization: The addon’s UI strings are available in EN and DE. Publish/override translations if you need custom CP wording for editors.
  • Deployment integration: Include the asset publish command in deployment or upgrade scripts so CP assets stay in sync:
    php artisan vendor:publish --tag=statamic-one-click-content-translation --force
    
  • Fallback strategy: Let the addon derive the target from site config for simple setups, and reserve translation_locale for sites where the provider code must be exact.

Gotchas and Tips

  • Breaking locale behavior in 6.0.8: Sites with a regionless locale such as en or pt now translate to EN-GB / PT-BR. To preserve EN-US / PT-PT, set translation_locale explicitly in resources/sites.yaml.
  • DeepL glossary codes: Glossary keys must use DeepL codes, not generic locale names. A key like EN or PT may not match what DeepL expects; use EN-US, DE, etc.
  • Missing CP assets after upgrade: If assets disappear in the Control Panel, republish with --force:
    php artisan vendor:publish --tag=statamic-one-click-content-translation --force
    
  • Debugging translation targets: First inspect the site’s locale/lang and any translation_locale override. Then confirm the resulting code is supported by the configured provider.
  • Cache clears: After changing site config or publishing assets, clear Statamic/Laravel caches if the CP does not reflect the new target language or assets.
  • Extension points: Use published config/assets and UI translation files for customization; avoid editing vendor files directly so future upgrades remain straightforward.
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.
gmostafa/php-graphql-client
xeviant/paystack
snowsoft/faker
meditationsteps/blogetc
animalyoung/laravel-influxdb
onix-solutions/sms-telera
lonely-lights/prosetta
oxygen/data
oxygen/core
jengo/base
xiloryx/log-collector
a21ns1g4ts/filament-stripe
la-php/laravel-admin
artisan-build/community-prompts
vleroy/smart
ayles-software/laravel-australian-public-holidays
cboxdk/laravel-id-spatie
cboxdk/laravel-id-billing
cboxdk/laravel-id-billing-bridge
simple-as-fuck/php-performance-log