accessibility-exchange / platform

The Accessibility Exchange platform.
https://github.com/orgs/accessibility-exchange/projects/2/views/8
BSD 3-Clause "New" or "Revised" License
4 stars 10 forks source link

fix: model lsq translations don't fallback to fr (resolves #2014, #2026, #2028, #2029) #2027

Closed jobara closed 11 months ago

jobara commented 11 months ago

Resolves #2014 Resolves #2026 Resolves #2028 Resolves #2029

Prerequisites

If this PR changes PHP code or dependencies:

If this PR changes CSS or JavaScript code or dependencies:

BEGIN_COMMIT_OVERRIDE fix: model lsq translations don't fallback to fr (resolves #2014, #2026) (#2027)

fix: rendering of language changer links (resolves #2028, #2029) (#2027) fix: response time in other languages not saved (#2027) fix: can't add other engagement languages (#2027) fix: not displaying content in translation (#2027) END_COMMIT_OVERRIDE

jobara commented 11 months ago

@greatislander in fixing the failing test I realized that I may have removed some functionality, but I'm also not sure how that part was supposed to work or if it was actually functional on the site. I wonder if you could weigh in. Basically I removed the language bits from the controllers. It looks like you could use that to pass in a query parameter to have an individual or organization public page rendered in an alternative language if one was provided. However, I don't see how a user could have specified that query parameter. Am I understanding this correctly? Have I missed something? Is this still needed?

codecov[bot] commented 11 months ago

Codecov Report

Attention: 4 lines in your changes are missing coverage. Please review.

Comparison is base (ccaa90c) 97.63% compared to head (bb50619) 97.60%. Report is 1 commits behind head on dev.

:exclamation: Current head bb50619 differs from pull request most recent head af2731e. Consider uploading reports for the commit af2731e to get more accurate results

Files Patch % Lines
app/helpers.php 80.95% 4 Missing :warning:
Additional details and impacted files ```diff @@ Coverage Diff @@ ## dev #2027 +/- ## ============================================ - Coverage 97.63% 97.60% -0.03% + Complexity 2105 2101 -4 ============================================ Files 314 313 -1 Lines 9497 9522 +25 ============================================ + Hits 9272 9294 +22 - Misses 225 228 +3 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

jobara commented 11 months ago

@greatislander in fixing the failing test I realized that I may have removed some functionality, but I'm also not sure how that part was supposed to work or if it was actually functional on the site. I wonder if you could weigh in. Basically I removed the language bits from the controllers. It looks like you could use that to pass in a query parameter to have an individual or organization public page rendered in an alternative language if one was provided. However, I don't see how a user could have specified that query parameter. Am I understanding this correctly? Have I missed something? Is this still needed?

I spoke with @greatislander about this. The $language set from the query parameter is to allow those pages to be shown in different languages, if they've been added for them by the user/org. This for example would allow an organization to localize their public page in many languages even though the site only supports a couple. Will need to bring that functionality back. The original work for this was done under #505.

While the written language supports from HasMultimodalTranslations isn't required any more, the rough in for the ASL/LSQ upload options is still requested to remain, in case we implement those features in the future (See: #455).

jobara commented 11 months ago

While reviewing this, @greatislander found two other bugs ( #2029, #2028 ). If possible these should be addressed alongside this one.