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

[5.x]: Translatable Link Field retains same entry across sites #15821

Closed
liencard opened this issue Oct 2, 2024 · 2 comments
Closed

[5.x]: Translatable Link Field retains same entry across sites #15821

liencard opened this issue Oct 2, 2024 · 2 comments
Assignees
Labels

Comments

@liencard
Copy link

liencard commented Oct 2, 2024

What happened?

Description

When using a translatable Link field in a multisite setup, I expect that when I select an entry of the current site, it should default to the corresponding entry in the other sites (languages).

Currently, when I select an entry for a particular site, the same entry is retained across the other sites. This results in linking to the incorrect entry on those other sites.

Steps to reproduce

  1. Create a multisite setup.
  2. Add a translatable Link field to an entry.
  3. Select an entry in one site.
  4. Observe that the same entry is applied across all sites instead of selecting the corresponding entry for the other site.

Expected behavior

When selecting an entry in one site, the Link field should automatically map to the corresponding entry in the other site.

I understand that the Link field should be editable per site, but by default, I would prefer it to automatically select the corresponding entry for each site.

Actual behavior

The selected entry is retained for all sites, leading to incorrect linked entries across the multisite setup.

Craft CMS version

5.4

PHP version

8.2

Operating system and version

No response

Database type and version

No response

Image driver and version

No response

Installed plugins and versions

@brandonkelly
Copy link
Member

Thanks for the suggestion. It’s working as expected currently – when creating a new entry, its translatable field values will automatically be copied over to other sites, just to provide a default value to the author, with the expectation that the author will probably end up modifying it on other sites later on.

That said, I can see how swapping out the selected entry with a localized version during that propagation would be more helpful, so it’s pointing to the same site that the author would have ended up getting if they had selected the same entry manually. So I’ve made that change for the 5.5 release (c3efaec).

@brandonkelly
Copy link
Member

Craft 5.5.0 is out now with that change 🎉

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants