=== Saintara Translation ===
Contributors: saintara
Tags: translation, multilingual, language dropdown, deepl, openai
Requires at least: 6.3
Tested up to: 7.0
Requires PHP: 7.4
Stable tag: 1.1.0
License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html

Add multilingual translation to any WordPress site using your own API key — no vendor lock-in, no data stored by the plugin.

== Description ==

Saintara Translation lets you add a language dropdown to your WordPress site in minutes. Unlike other translation plugins, Saintara uses your own translation API key (DeepL, OpenAI, or Amazon Translate) — so you control your data, your costs, and your provider.

**How it works**

1. Sign up at [saintara.io](https://saintara.io) and connect your translation API key.
2. Install this plugin and enter your Site ID (SB ID).
3. Choose where the dropdown appears — done. Your languages come straight from your Saintara account.

**Features**

* Floating language dropdown — fixed-position, 4 configurable corners
* Place it in your navigation menu, or on any element you choose with a CSS selector
* Manual placement via `[saintara_translation]` shortcode
* Native Gutenberg block for block themes
* Classic widget support
* Searchable language panel showing native language names
* Languages read live from your Saintara account — never drifts out of sync
* Connection health check in the admin, so a misconfigured install tells you why
* Translates text, attributes (alt, title, placeholder, aria-label), and dynamically loaded content
* RTL language support (Arabic, Hebrew, Farsi, Urdu, and more)
* Redis-backed translation cache — fast repeat loads, no redundant API calls
* BYOK (Bring Your Own Key) — your API key, your costs, your data

**Supported translation providers**

* DeepL
* OpenAI
* Amazon Translate

== Installation ==

1. Upload the `saintara-translation` folder to the `/wp-content/plugins/` directory, or install directly through the WordPress plugin screen.
2. Activate the plugin through the **Plugins** screen in WordPress.
3. Go to **Settings → Saintara** and enter your Site ID (found in your Saintara dashboard).
4. Select your languages and dropdown mode, then save.

== Frequently Asked Questions ==

= Do I need a Saintara account? =

Yes. Sign up at [saintara.io](https://saintara.io) to get your Site ID and connect your translation API key. The plugin requires an active Saintara account to function.

= Which translation providers are supported? =

DeepL, OpenAI, and Amazon Translate. You bring your own API key — Saintara never stores it in plain text.

= How do I place the dropdown in my navigation menu? =

Set the dropdown mode to **Manual** in Settings → Saintara. Use the `[saintara_translation]` shortcode or the **Saintara Language Dropdown** Gutenberg block to place it wherever you like.

= Does the plugin store any translated content? =

No. Translated content is cached server-side by Saintara using your connected Redis instance. The plugin itself stores no content.

= Does this work with block (FSE) themes? =

Yes. Use the **Saintara Language Dropdown** Gutenberg block to place the dropdown anywhere in the Site Editor.

= What happens if I deactivate the plugin? =

Your settings are preserved. Re-activating the plugin restores everything. To remove all settings permanently, delete the plugin.

== External Services ==

This plugin connects to the Saintara API to load your site's translation script and to process translation requests.

**What data is sent:**
- Your Site ID (SB ID) is included in the script URL to identify your account.
- Page text content is sent to `api.saintara.io` for translation when a visitor switches language.

**When data is sent:**
- The translation script is loaded from `api.saintara.io` on every page load where the plugin is active.
- Translation requests are made when a visitor selects a language from the dropdown.

**External service details:**
- Service: Saintara API — `https://api.saintara.io`
- Privacy Policy: https://saintara.io/privacy
- Terms of Service: https://saintara.io/terms

Translation is then processed by your chosen provider (DeepL, OpenAI, or Amazon Translate) using your own API key. Saintara does not share your content with any third party beyond your chosen provider.

== Screenshots ==

1. The language panel, opened from the floating button.
2. Settings screen with the connection health check.
3. Placing the dropdown with the block editor.

== Changelog ==

= 1.1.0 =
* Languages now come from your Saintara account instead of a list stored per site. The
  per-site language checkboxes have been removed — the dropdown always matches your plan,
  and can no longer offer a language your account will reject.
* Switched to the hosted Saintara dropdown: adds a search box, native language names, and
  a configurable label, icon and accent colour.
* New: place the dropdown in your site navigation, or bind it to your own elements with a
  CSS selector.
* New: connection health check on the settings screen. A mistyped Site ID, an account with
  no languages, and a lapsed subscription are now told apart instead of all failing silently.
* New: fill any `<select data-sb-dropdown></select>` in your theme automatically.
* Fixed: the plugin required WordPress 6.3 but declared 6.0. On 6.0–6.2 the translation
  engine silently lost its `defer` strategy and loaded in the footer.
* Fixed: four languages (Hmong, Lao, Maithili, Meiteilon) were offered but no longer
  supported, and selecting one failed silently.

= 1.0.0 =
* Initial release.
* Floating language dropdown with 4 configurable positions.
* Manual placement via shortcode and Gutenberg block.
* Classic widget support.
* 134 supported languages.
* RTL support.

== Upgrade Notice ==

= 1.1.0 =
Languages are now managed in your Saintara account rather than per site, so the language
checkboxes have been removed — your existing selection is replaced by your account's list.
Also fixes a declared-compatibility bug affecting WordPress 6.0–6.2.

= 1.0.0 =
Initial release.
