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

❇️ Template language #172

Merged
merged 9 commits into from
Sep 5, 2024
Merged

❇️ Template language #172

merged 9 commits into from
Sep 5, 2024

Conversation

foysalit
Copy link
Contributor

@foysalit foysalit commented Sep 3, 2024

Depends on bluesky-social/atproto#2780

This PR primarily adds UX around communication template language. A few key features here are

  1. Allow mods to create/update templates with a specific language property.
  2. When sending email to a user, the template list will try to find a "supported" non-english language from the user's tags and default the template selector to show items in that language.
  3. Mods can always choose to see the entire list anywhere or just the list of templates of a specific language.

Some additional and unrelated fixes

  1. Show specific error message when saving template fails
  2. Show tags in user profile detail view
template-lang.mov

Copy link

render bot commented Sep 3, 2024

setSelectedLang: (lang?: string) => void
}) => {
const selectedText = selectedLang
? LANGUAGES_MAP_CODE2[selectedLang].name
Copy link
Contributor

@matthieusieben matthieusieben Sep 4, 2024

Choose a reason for hiding this comment

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

Suggested change
? LANGUAGES_MAP_CODE2[selectedLang].name
? getLanguageName(selectedLang)

},
...availableLanguageCodes.map((lang) => ({
id: lang,
text: LANGUAGES_MAP_CODE2[lang].name,
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
text: LANGUAGES_MAP_CODE2[lang].name,
text: getLanguageName(lang),

Copy link
Contributor

@matthieusieben matthieusieben left a comment

Choose a reason for hiding this comment

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

Look good to me 👍

@foysalit foysalit merged commit dfb6c66 into main Sep 5, 2024
3 checks passed
@matthieusieben matthieusieben deleted the template-language branch November 15, 2024 14:55
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