Skip to content

Releases: phrase/phrase-android

3.0.1

03 Feb 15:54
b49d63e

Choose a tag to compare

Added

  • Support for NavigationView and BottomNavigationView

Fixed

  • Keep package name in ProGuard #24

3.0.0

22 Jan 14:13
b49d63e

Choose a tag to compare

Breaking Changes

Method overwriting

In previous versions it was neccessary to overwrite attachBaseContext in the activity. This is no longer required and changed to:

@NonNull
@Override
public AppCompatDelegate getDelegate() {
    return Phrase.getDelegate(this, super.getDelegate());
}

Caching behavior

The caching of fetched locales changed. This means that the cache from previous versions of the app will not be used and the latest translations will fetched during the first start of the app.

Added

  • Classes inheriting from Application should overwrite attachBaseContext to enable translations outside of the activity context:
@Override
protected void attachBaseContext(Context newBase) {
    super.attachBaseContext(Phrase.wrapApplicationContext(newBase));
}
  • Support plural translations
  • Support translation of inflatable menus

Switching languages during runtime

Added Phrase.setLocaleCode(localeCode) to change languages during runtime.

Example for switching the language during runtime:

Phrase.setLocaleCode("fr");
Phrase.updateTranslations();
recreate();

Fixed

  • Improve appcompat compatibility
  • Fix webview crash #20
  • Fix rare case where translation could not be loaded from cache

Compatibility

With version 3.0.0 the SDK requires at least appcompat version 1.2.0

2.1.3

22 Sep 12:44
b49d63e

Choose a tag to compare

Fixed

  • Fix updating translations for API level < 25
  • Fix for AppCompat 1.2.0

2.1.2

14 May 14:33
b49d63e

Choose a tag to compare

Fixed

  • Remove leading and trailing double quotes from translations

2.1.0

17 Jan 12:42
b49d63e

Choose a tag to compare

Added

  • Switch locale and fetch translations when system locale changes

2.0.2

14 Jan 16:11
b49d63e

Choose a tag to compare

Fixed

  • Return true for successful translation updates in updateTranslations

2.0.1

20 Dec 08:44
b49d63e

Choose a tag to compare

Fixes

  • Fix display of special characters like '
  • Fix display of newlines for formatted strings when calling getString(int resId, Object... formatArgs)

2.0.0

13 Dec 14:37
b49d63e

Choose a tag to compare

Added

  • CDATA escaping support. Can be enabled in the distribution settings on app.phrase.com and requires creating a new release
  • iOS placeholders are converted to Android placeholders

Both new features require that a new release is created

Breaking Changes

  • Renamed import from com.phraseapp.android.sdk.PhraseApp to import com.phrase.android.sdk.Phrase
  • Renamed PhraseApp class to Phrase

1.2.0

14 Oct 11:41
c905302

Choose a tag to compare

Added

  • Provide compatibility with Android Q

Breaking change

The library now depends on AndroidX. For converting an app see Migrating to AndroidX

1.1.5

09 Sep 12:24
c905302

Choose a tag to compare

  • Fix rendering of newlines