Add Comment from List View Without Opening the Document

Hi,
I want to allow users to add comments directly from the list view by clicking on the comment icon (shown in the screenshot) without needing to open the document. Is there a way to achieve this using a dialog or any other method in Frappe?

I’d appreciate any guidance or examples. Thanks!