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

Localization Issue in Single Type - Default Locale Always Applied #19225

Closed
nizhgo opened this issue Jan 15, 2024 · 2 comments
Closed

Localization Issue in Single Type - Default Locale Always Applied #19225

nizhgo opened this issue Jan 15, 2024 · 2 comments

Comments

@nizhgo
Copy link

nizhgo commented Jan 15, 2024

Bug report

Required System information

  • Node.js version: v18
  • NPM version: 10.2.3
  • Strapi version: 4.17.0
  • Database: PostgreSQL
  • Operating system: Ubuntu 22.04.2
  • Is your project Javascript or Typescript: TS

Describe the bug

When attempting to localize a single type entity, the system defaults to the default locale regardless of the selected locale. For instance, if the default locale is set to English (en), and an attempt is made to switch to French (fr), the system still displays and applies the English locale. This issue appears to be specific to single type entities.

Steps to reproduce the behavior

  1. Create two or more locales within the system. For example, English (en), French (fr), and Spanish (es).
  2. Create a single type entity with localized text fields.
  3. Set one of the locales as the default, e.g., set English (en) as the default locale.
  4. Edit the single type entity and input localized content for each locale separately.
  5. Attempt to switch the editing locale from the default (English) to another locale (e.g., French or Spanish).
  6. Observe that despite selecting a non-default locale (e.g., French), the editing and display still occur in the default locale (English).
  7. Any changes made while editing under a non-default locale (e.g., French or Spanish) are applied to the default locale (English), and these changes are reflected across all locales.

Expected behavior

When switching the locale on a single type, the selected locale should be applied and displayed correctly. Each locale should maintain its unique content without defaulting to the default locale.

Settings.Mozilla.Firefox.2024-01-15.17-50-11.mp4
@shivarajnaidu
Copy link

This bug is happening when I use strapi 4.17 (which is the latest release of strapi as of writing this..)

If we use strapi 4.16 it works fine..

I think this is due to incorrect query params from admin panel
this screenshot from strapi 4.16
but in the new version of strapi (4.17) i couldn't see the query params related to the locale
Screenshot 2024-01-16 at 7 54 02 AM

@joshuaellis
Copy link
Member

This should be solved in 4.17.1 via #19209

@joshuaellis joshuaellis closed this as not planned Won't fix, can't repro, duplicate, stale Jan 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Archived in project
Development

No branches or pull requests

3 participants