Skip to content
This repository has been archived by the owner on Feb 23, 2024. It is now read-only.

Disable HTML editing on dynamic blocks #801

Merged
merged 2 commits into from
Aug 6, 2019
Merged

Disable HTML editing on dynamic blocks #801

merged 2 commits into from
Aug 6, 2019

Conversation

mikejolley
Copy link
Member

Dynamic blocks have no content until they are rendered on the server side, therefore they should not be HTML editable. The use of shortcodes was dropped in 2.2.

Fixes #800

Also fixes the case of tabIndex introduced in a previous merge.

To test,

  • Add a product category and hand picked product block
  • Click the more icon
  • Confirm 'edit as html' is no longer shown

Copy link
Contributor

@nerrad nerrad left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks straightforward enough. However is there any concern about potential issues with people who might have used this bug to do something edge-case? I'm erring on the side of no, hence approving this pull 👍

@mikejolley
Copy link
Member Author

@nerrad I don't think so - there is nothing to edit, so any edits there wouldn't do anything on these blocks anyway.

Thanks for the review!

@Aljullu
Copy link
Contributor

Aljullu commented Aug 7, 2019

@mikejolley do you think we should cherry-pick this for 2.3?

@mikejolley mikejolley modified the milestones: 2.4, 2.3 Aug 7, 2019
@mikejolley mikejolley added release: cherry-pick Cherry picked into the relevant release branch. and removed release: cherry-pick Cherry picked into the relevant release branch. status: needs review labels Aug 7, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

'Edit with HTML' showing blank on Hand Picked Products and Product Categories
3 participants