Skip to content

Conversation

@pauljohanneskraft
Copy link
Contributor

Add Spanish Localizations

♻️ Current situation & Problem

We finally received the translations to now support Spanish inside this app! Please make sure to check the attached file during review, just to make sure I didn't mess up during copying over! I also needed to create a new xcstrings file for the InfoPlist strings - this is the way it worked with .strings files, so not sure if it still works this way!

ENGAGEHF-iOS_Spanish.xlsx

⚙️ Release Notes

Add a bullet point list summary of the feature and possible migration guides if this is a breaking change so this section can be added to the release notes.
Include code snippets that provide examples of the feature implemented or links to the documentation if it appends or changes the public interface.

📚 Documentation

Please ensure that you properly document any additions in conformance to Spezi Documentation Guide.
You can use this section to describe your solution, but we encourage contributors to document your reasoning and changes using in-line documentation.

✅ Testing

Please ensure that the PR meets the testing requirements set by CodeCov and that new functionality is appropriately tested.
This section describes important information about the tests and why some elements might not be testable.

Code of Conduct & Contributing Guidelines

By creating and submitting this pull request, you agree to follow our Code of Conduct and Contributing Guidelines:

Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR adds Spanish localizations for the app’s Info.plist usage descriptions, moves those keys into a new .xcstrings file, and updates the project configuration to include the new file and locale.

  • Introduce InfoPlist.xcstrings (with accompanying license) containing English and Spanish translations for all usage-description keys.
  • Remove hardcoded privacy strings from Info.plist so they are sourced from the new JSON-based localization.
  • Update the Xcode project (.pbxproj) to reference InfoPlist.xcstrings, add es to known regions, and enable Swift string extraction.

Reviewed Changes

Copilot reviewed 5 out of 5 changed files in this pull request and generated 1 comment.

File Description
ENGAGEHF/Supporting Files/InfoPlist.xcstrings.license Add MIT license header for the new .xcstrings resource.
ENGAGEHF/Supporting Files/InfoPlist.xcstrings Add JSON entries for English and Spanish localizations of usage strings.
ENGAGEHF/Supporting Files/Info.plist Remove inline <key>/<string> usage-description entries.
ENGAGEHF.xcodeproj/project.pbxproj Reference InfoPlist.xcstrings, register es locale, set build flags.
Comments suppressed due to low confidence (1)

ENGAGEHF/Supporting Files/InfoPlist.xcstrings:13

  • New Spanish localizations have been added; consider adding or updating tests (e.g., UI or snapshot tests) to verify that these InfoPlist keys load correctly under the 'es' locale.
"es" : {

"en" : {
"stringUnit" : {
"state" : "translated",
"value" : "The ENGAGE-HF app uses the step count to demonstrate Spezi's integration with HealthKit."
Copy link

Copilot AI Jun 4, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[nitpick] NSHealthUpdateUsageDescription uses the same message as NSHealthShareUsageDescription. Consider providing distinct messages to clearly differentiate between sharing and updating HealthKit data.

Copilot uses AI. Check for mistakes.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actually a good point; @pauljohanneskraft & @NikolaiMadlener we should adjust this.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I didn't think this was super pressing, so I didn't include this in the updated file - we should probably include the updated text(s) with all the other missing keys within the Spezi ecosystem.

Copy link
Contributor

@NikolaiMadlener NikolaiMadlener left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for copying all the translations over @pauljohanneskraft !
Looks really good.

Copy link
Member

@PSchmiedmayer PSchmiedmayer left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for working on this!

Might make sense to let the translation team know about any missing strings. Wondering if we should merge it first, then merge the Spezi Account elements, and then see if we have any missing pieces?

I also suspect that we will eventually need to also translate some parts of Spezi Account? Might be best to spot all of that in the app itself once we test the localization?

"en" : {
"stringUnit" : {
"state" : "translated",
"value" : "The ENGAGE-HF app uses the step count to demonstrate Spezi's integration with HealthKit."
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actually a good point; @pauljohanneskraft & @NikolaiMadlener we should adjust this.

Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

Copilot reviewed 6 out of 6 changed files in this pull request and generated 1 comment.

Comments suppressed due to low confidence (1)

ENGAGEHF/Supporting Files/InfoPlist.xcstrings:1

  • Corrected Spanish translation of 'Expires in' to be more natural: 'Caduca en:' would be more appropriate than 'Caduca el:'
{

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

Copilot reviewed 6 out of 6 changed files in this pull request and generated 2 comments.


Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

"es" : {
"stringUnit" : {
"state" : "translated",
"value" : "Su cuenta fue desactivada."
Copy link

Copilot AI Oct 14, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The Spanish translation for 'Your account was deactivated\nby your study coordinator.' appears to be missing the second part about the study coordinator. The original English includes information about who deactivated the account, which should be preserved in the Spanish translation.

Suggested change
"value" : "Su cuenta fue desactivada."
"value" : "Su cuenta fue desactivada\npor su coordinador de estudio."

Copilot uses AI. Check for mistakes.
@codecov
Copy link

codecov bot commented Oct 14, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 79.13%. Comparing base (dfbfdea) to head (ab96de1).

Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##             main     #149      +/-   ##
==========================================
+ Coverage   78.93%   79.13%   +0.21%     
==========================================
  Files         153      153              
  Lines         982      982              
==========================================
+ Hits          775      777       +2     
+ Misses        207      205       -2     

see 1 file with indirect coverage changes


Continue to review full report in Codecov by Sentry.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update dfbfdea...ab96de1. Read the comment docs.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Copy link
Member

@PSchmiedmayer PSchmiedmayer left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks solid, thank you for all the improvements here! Happy to see this merged soon 👍

/* End PBXTargetDependency section */

/* Begin XCBuildConfiguration section */
2FEE10302998C89C000822E1 /* Test */ = {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think we need the TEST scheme here; we have removed it from other apps as well.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We might want to update some of the dependencies here; some of them added a Spanish localization in the recent releases.

@PSchmiedmayer
Copy link
Member

@pauljohanneskraft Updated some dependencies in the other branch to pull them in here as well 👍

@PSchmiedmayer
Copy link
Member

@pauljohanneskraft Updated this PR as well; might be good to merge at some point as well 👍

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

Labels

enhancement New feature or request

Projects

Status: No status

Development

Successfully merging this pull request may close these issues.

4 participants