Skip to content

[6.x] Restore “Copy value from site…” on translatable fields - #19683

Merged
brandonkelly merged 5 commits into
6.xfrom
rias/cms-2349-restore-copy-value-from-site-on-translatable-fields
Sep 22, 2026
Merged

brandonkelly merged 5 commits into
6.xfrom
rias/cms-2349-restore-copy-value-from-site-on-translatable-fields

Conversation

@riasvdv

@riasvdv riasvdv commented Sep 21, 2026

Copy link
Copy Markdown
Contributor

Description

Restores the cross-site copy action for translatable fields in the new field renderer.

 Field actions
+└── Copy value from site…
+    ├── Select another supported site
+    └── Replace the rendered field and its value

The action is only offered for persisted, editable, translatable fields on elements that support cross-site copying. The copy response now includes the updated form node and values so the field can refresh without reloading the element editor.

Copy value from site modal

@linear-code

linear-code Bot commented Sep 21, 2026

Copy link
Copy Markdown
Contributor

CMS-2349

@riasvdv
riasvdv marked this pull request as ready for review September 21, 2026 15:58
@github-actions

github-actions Bot commented Sep 21, 2026

Copy link
Copy Markdown

📚 Storybook previews

@craftcms/uiopen Storybook

No changed components detected in this Storybook.

resources/jsopen Storybook

No changed components detected in this Storybook.

…copy-value-from-site-on-translatable-fields

# Conflicts:
#	resources/js/modules/forms/FieldNode.vue
@github-actions

Copy link
Copy Markdown

This PR had conflicts with 6.x. Claude attempted an automatic resolution and pushed a merge commit. Please review the merge commit carefully before approving/merging.

Claude's response

Merge resolved, committed as 192bb87, and pushed.

Summary

The merge of 6.x into this branch had a single conflicted file: resources/js/modules/forms/FieldNode.vue.

The conflict: both sides edited the opening attributes of the <craft-field> element. Our branch (f499447, "Restore cross-site field value copying") refactored the component to read from a new local resolvedNode ref instead of props.node directly — so the field can be re-rendered with a server-returned node after copying a value from another site — and added ref="field" so the cross-site copy event listener can scope events to this field. The 6.x side (8603ddd, "Give all fields an ID") added a :id="fieldId(control.path)" binding plus the corresponding fieldId import.

Resolution: these are independent, non-exclusive changes, so I kept both — our ref="field" and the full resolvedNode.props.* rewrite of every attribute, with 6.x's :id="fieldId(control.path)" inserted alongside. The fieldId import had already auto-merged cleanly. I verified the result by diffing the resolved file against our side: it differs by exactly the two additions from 6.x and nothing else. Nothing ambiguous here — no # CONFLICT-REVIEW: comments were needed.

I also spot-checked the auto-merged CHANGELOG.md, since that file's repeated bullet structure is a known source of silent mis-merges. Our branch never touched it, so the merged version correctly matches 6.x verbatim, with no duplicated section headers.

One caveat for the reviewer: node_modules isn't installed in this environment, so I could not run pnpm typecheck, lint:js, or Prettier to confirm the result passes CI. The change is a two-line template/import addition matching 6.x's own formatting, but CI is the real check.

@brandonkelly
brandonkelly merged commit 5f1314c into 6.x Sep 22, 2026
23 checks passed
@brandonkelly
brandonkelly deleted the rias/cms-2349-restore-copy-value-from-site-on-translatable-fields branch September 22, 2026 19:08
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