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

example of chaining elvis #427

Closed
wants to merge 10 commits into from
Closed

example of chaining elvis #427

wants to merge 10 commits into from

Conversation

bbannon
Copy link
Contributor

@bbannon bbannon commented Oct 7, 2023

This is supposed to select the first that isset(), ! empty() and ! is_null()

see https://stackoverflow.com/questions/34571330/php-short-ternary-elvis-operator-vs-null-coalescing-operator

@craigk5n
Copy link
Owner

Why are we adding a "en-US.txt" translation file when we already have a "English-US.txt" file?

@bbannon
Copy link
Contributor Author

bbannon commented Nov 21, 2023

I'm looking to make all translations/*.txt files into the 'navigator.language' names like captcha, ckeditor and phpmailer use. It would make it easier to copy just the 1 or 2 language files that the user needs. Eventually.

@craigk5n
Copy link
Owner

It's interesting, but I think I'll keep including all or most of the translations in the normal release. This is because the language is supposed to be picked up through the browser, which means that your website supports foreign languages (except for event information). However, we could consider creating a release builder that would allow users to select the languages they want to include. I'm just not sure where it would be hosted.

@bbannon
Copy link
Contributor Author

bbannon commented Nov 21, 2023

Could we figure out a checkbox sort of thing in the installer? Let them choose which languages to download. Javascript 'navigator.languages', notice the plural, is an array of all languages the user has set up.

@bbannon
Copy link
Contributor Author

bbannon commented Nov 21, 2023

Also, renaming the *.txt files would eliminate the functions to convert from 2 letter to full names

@bbannon
Copy link
Contributor Author

bbannon commented Nov 27, 2023

Craig, I think if you delete Elven.txt from your side of this, we could both merge it in.

@craigk5n
Copy link
Owner

I'm not sold on renaming the translation files just yet. In any case, that change should be a separate PR.

@bbannon
Copy link
Contributor Author

bbannon commented Nov 29, 2023

This won't let me 'resolve conflicts'. Can you merge it, if you like the 'chasing Elvis' part? Then delete the *.txt files. Or just close it.

@bbannon bbannon closed this Feb 12, 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.

3 participants