Skip to content

Conversation

@edalzell
Copy link
Member

@edalzell edalzell commented Sep 30, 2025

Add is_review variable to the entry so you can change the behaviour if you're viewing an entry in "review" mode.

References https://github.com/transformstudios/zakat-v3/issues/1993
References https://github.com/transformstudios/zakat-v3/issues/1996

@github-actions github-actions bot added the fix label Sep 30, 2025
@marcorieser
Copy link

marcorieser commented Oct 1, 2025

@edalzell nice one! only thing i'm wondering is: is simulating live_preview the right way to do it? for us, sure! but is it what folks expect when they open a page in review mode? for example, folks might add some js stuff when being in the live preview mode (https://jacksleight.dev/posts/hot-reloading-statamic-s-live-preview-in-a-traditonal-mpa). couldnt we do ->setSupplement('is_review', true) and check for that in antlers like {{ if live_preview || is_review }} , if to use the tw cdn?

@edalzell
Copy link
Member Author

edalzell commented Oct 1, 2025

ya good point, I use to have something like that in Review, I'll bring it back.

@edalzell edalzell changed the title Pretend to be Live Preview Add is_review variable Oct 1, 2025
@edalzell edalzell added feature and removed fix labels Oct 1, 2025
@edalzell edalzell merged commit 7fa5a6a into main Oct 1, 2025
@edalzell edalzell deleted the fix/live-preview branch October 1, 2025 17:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants