When wiki="true", there is no reason to no handle the html macro exactly like any other wiki content macro. The fix most probably involves implementing a HTMLMacroRefactoring component.
This message was sent by Atlassian Jira (v9.3.0#930000-sha1:287aeb6)
If image attachments aren't displayed, see this article.