Is there a way to show a word document and change the color of its lines in ionic 4

Hi, i am using Ionic 4 . I load a word document using FileOpener: https://ionicframework.com/docs/native/file-opener. This gives me only a preview though.I would like to be able to change the color of each line using a pattern, e.g: red-green-red-green-… and red-green-blue-red-green-blue-… on pressing a button in the toolbar. Is there a way to achieve that?
I was wondering though . Could i a) first create a copy of the file, b) change the color of each line ,using FileWriter : https://cordova.apache.org/docs/en/3.3.0/cordova/file/filewriter/filewriter.html and then c) show the file using FileOpener ? What do you think? Would it be possible?
I was wondering if you could give me any ideas and help me achieve the desired functionality,please?

Thank you in advance

Is there another way then using a Word Document? If you can change that requirement that would be ideal.

If not I’d suggest using a web service with Word Installed and update the document using C# and the MS Office components.