I don’t know if this is useful, but NextCloud offers a WOPI link to Collabora Office. It is possible that it could be adapted to link in to ERPNext (though I don’t personally know how one would do that).
actually it’s collabora online which does this part (google docs like online collaboration on spreadsheets/textfiles). As it is a separate project (installed as an ‘app’ in the Nextcloud context (I think it runs inside a docker container) there may be a way to integrate this with ERPNext as well. @bkm Have you looked into this in any way?