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

Rebuild translation table + support ordered factor in scan_data #580

Merged
merged 8 commits into from
Nov 28, 2024

Conversation

olivroy
Copy link
Contributor

@olivroy olivroy commented Nov 27, 2024

  • Update translation file
  • Reduce logic around encoding for the translations (this may mean decreased support for Windows 4.1 and below, but I don't see any reason why to still use R<4.2 on Windows, it solves a lot of problems)
  • Remove workaround for R < 3.2
  • Support ordered factors
  • Correct some translations
  • update links to repo

This example was motivated by this example

scan_data(ggplot2::diamonds[1:100, ], lang = "fr", sections = "v")

Before:

image

Also the link at the bottom was a dead link:
image

This PR:

(notice that factor shows up) and FR translation is correct.

image

Links updated

The initial reason why I pursued this was the link, but the translations + support for ordered factor is a good addition!

@olivroy
Copy link
Contributor Author

olivroy commented Nov 27, 2024

@rich-iannone Ready for review!

With #581, I convinced myself that translations currently don't work correctly on Windows R < 4.2. Therefore, I am more confident with my changes here.

  • I updated some FR translations
  • Update the translations RDS file (it was already out of date)
  • Update links to avoid the old repo address
  • Remove a workaround for very old R
  • Remove complex logic around encoding (It didn't work for me out of the box + doesn't seem to change anything)

(Edit: sorry for closing / reopening. I accidently clicked)

@olivroy olivroy changed the title Rebuild translation table (no need to worry about encoding for R >= 4.2 Rebuild translation table + support ordered factor in scan_data Nov 27, 2024
@olivroy olivroy closed this Nov 27, 2024
@olivroy olivroy reopened this Nov 27, 2024
Copy link
Member

@rich-iannone rich-iannone left a comment

Choose a reason for hiding this comment

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

LGTM!

@rich-iannone
Copy link
Member

This is really great, thanks again!

@rich-iannone rich-iannone merged commit 793abf0 into rstudio:main Nov 28, 2024
24 checks passed
@olivroy olivroy deleted the links branch November 28, 2024 18:32
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