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

SwiftUI support #66

Merged
merged 3 commits into from
Jun 10, 2024
Merged

SwiftUI support #66

merged 3 commits into from
Jun 10, 2024

Conversation

stelabouras
Copy link
Collaborator

SwiftUI support

  • Adds attributed string swizzling that allows Transifex SDK to allow
    for SwiftUI support.
  • De-swizzles methods when SDK is deactivated (when dispose is
    called).
  • Adds public static method to deactivate swizzling on passed Bundle
    instance.
  • Ensures that the special Transifex .stringsdict key used to
    calculate the plural rules, cannot be swizzled
    (TRANSIFEX_STRINGSDICT_KEY).
  • Ensures that SDK is properly deactivated when a unit test finishes, so
    that swizzling is re-applied correctly on each test.
  • Adds unit test for the localizedAttributedString:... method in
    Objective-C.
  • Adds unit test for the NSLocalizedString() method in Swift.

NOTE: SwiftUI elements (View, Button etc) cannot be added to unit
tests.


Bump version to 2.0.3

  • Bumps TXNative.version to 2.0.3.
  • Updates CHANGELOG with the changes implemented for 2.0.3.

@stelabouras stelabouras requested a review from n1k0sv June 10, 2024 07:56
* Adds attributed string swizzling that allows Transifex SDK to allow
for SwiftUI support.
* De-swizzles methods when SDK is deactivated (when `dispose` is
called).
* Adds public static method to deactivate swizzling on passed `Bundle`
instance.
* Ensures that the special Transifex `.stringsdict` key used to
calculate the plural rules, cannot be swizzled
(`TRANSIFEX_STRINGSDICT_KEY`).
* Ensures that SDK is properly deactivated when a unit test finishes, so
that swizzling is re-applied correctly on each test.
* Adds unit test for the `localizedAttributedString:...` method in
Objective-C.
* Adds unit test for the `NSLocalizedString()` method in Swift.

NOTE: SwiftUI elements (`View`, `Button` etc) cannot be added to unit
tests.
* Bumps `TXNative.version` to 2.0.3.
* Updates CHANGELOG with the changes implemented for 2.0.3.
@n1k0sv n1k0sv merged commit 2b0f13d into transifex:devel Jun 10, 2024
1 check passed
@txsentinel txsentinel mentioned this pull request Jun 10, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants