Skip to content

Conversation

@tvdeyen
Copy link
Member

@tvdeyen tvdeyen commented Jan 23, 2026

What is this pull request for?

When publishing a page, only visible top-level elements were being filtered. Nested elements were copied regardless of their public status, which meant hidden nested elements would appear on the published version.

This adds a publishable_only option to DuplicateElement that filters nested elements through the repository's visible method, ensuring only public nested elements are copied to the published version.

Checklist

  • I have followed Pull Request guidelines
  • I have added a detailed description into each commit message
  • I have added tests to cover this change

@tvdeyen tvdeyen requested a review from a team as a code owner January 23, 2026 16:36
@tvdeyen tvdeyen added the bug label Jan 23, 2026
@codecov
Copy link

codecov bot commented Jan 23, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 97.44%. Comparing base (8988cbe) to head (adac074).
⚠️ Report is 2 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #3593   +/-   ##
=======================================
  Coverage   97.44%   97.44%           
=======================================
  Files         314      314           
  Lines        8187     8189    +2     
=======================================
+ Hits         7978     7980    +2     
  Misses        209      209           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@tvdeyen tvdeyen force-pushed the backport-nested-elements-filter-8.0 branch from 025363c to a24511d Compare January 23, 2026 16:50
@tvdeyen tvdeyen changed the title [8.0] fix: Filter nested elements by visibility when publishing pages fix: Filter nested elements by visibility when publishing pages Jan 23, 2026
@tvdeyen tvdeyen changed the base branch from 8.0-stable to main January 23, 2026 16:50
@tvdeyen tvdeyen added the backport-to-8.0-stable Needs to be backported to 8.0-stable label Jan 23, 2026
@tvdeyen tvdeyen marked this pull request as draft January 23, 2026 16:51
When publishing a page, only visible top-level elements were being
filtered. Nested elements were copied regardless of their public status,
which meant hidden nested elements would appear on the published version.

This adds a publishable_only option to DuplicateElement that filters nested
elements through the repository's visible method, ensuring only public
nested elements are copied to the published version.

Signed-off-by: Thomas von Deyen <vondeyen@blish.cloud>
@tvdeyen tvdeyen force-pushed the backport-nested-elements-filter-8.0 branch from a24511d to adac074 Compare January 23, 2026 16:53
@tvdeyen tvdeyen marked this pull request as ready for review January 23, 2026 16:53
@tvdeyen tvdeyen merged commit 74dabc1 into main Jan 26, 2026
22 checks passed
@tvdeyen tvdeyen deleted the backport-nested-elements-filter-8.0 branch January 26, 2026 08:36
@alchemycms-bot
Copy link

💚 All backports created successfully

Status Branch Result
8.0-stable

Questions ?

Please refer to the Backport tool documentation and see the Github Action logs for details

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backport-to-8.0-stable Needs to be backported to 8.0-stable bug

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants