Skip to content

Conversation

@Manik-Khajuria-5
Copy link
Contributor

@Manik-Khajuria-5 Manik-Khajuria-5 commented Dec 13, 2025

Issue number

Contributes to #4460

Description

This PR refactors the HTML Block Edit.jsx component by modernizing it into a fully hook-based functional component.


Key Changes

  • Converted the HTML block Edit.jsx into a functional component using React hooks
  • Replaced legacy lifecycle patterns with useEffect, useRef, and useCallback
  • Improved code editor selection and focus restoration logic
  • Simplified state management for preview and source modes
  • Improved overall readability and consistency with modern Volto code style

@Manik-Khajuria-5 Manik-Khajuria-5 marked this pull request as ready for review December 13, 2025 12:40
@Manik-Khajuria-5 Manik-Khajuria-5 changed the title Refactor Edit.jsx: Class Component to Functional Component Refactor HTML Edit.jsx: Class Component to Functional Component Dec 13, 2025
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.

1 participant