Hello,
You need to enable the PHP Tidy extension; it seems you didn't enable this required extension to transform HTML to DOCX when you upgraded your PHP version. This requirement is explained on the documentation pages: https://www.phpdocx.com/documentation/cookbook/convert-html-to-word
Warning
If you haven't installed the Tidy extension, errors may ocurr, like appearing the CSS styles in the document, import with errors the HTML or not displaying accents and other non ASCII characters.
Also please note that phpdocx is compatible with PHP 7.4 since the release of phpdocx 9.5 (https://www.phpdocx.com/news/post/phpdocx-v9-5-release-notes/219). Using previous versions of phpdocx with PHP 7.4 is not supported and you can get unexpected errors. We recommend you to upgrade your version of phpdocx to the latest release on MY PHPDOCX page after login.
Regards.