We are evaluating OnlyOffice to be the editor in our product. Our use case for OnlyOffice to use it to edit docx file and mark part of the words as form fields using custom plugin.
Plugin is using this code to add inline form field:
For some reason tag isn’t attached to form at all, and for this, we can’t bind our plugins input fields to form field. What is correct way to add tag to form?
Not quite understand why InsertTextForm is used in document editor when it is method for Forms editor. Instead of tags, these forms use key, please check out this sample of interaction with fields from outside the editor:
I have seen that example. In that example document already has form fields defined. I´m trying to define form fields using document editor and then fill them later.
Form fields have only InternalId defined when fetched with GetAllForms method. Tag and key are both empty.
I can define ContentFields and ContentFields preserves tags when accesses with GetAllContentFields. I can’t use Content fields because I couldn’t find a way to highlight them programmatically nor I couldn’t find a way to set values to them like in example you provided.
Yes, I’m adding key to form, but the key isn’t saved at all. I tested with the example you provided and used GetAllForms to fetch all form fields. For some reason, my form fields contains only Tag, Lock and InternalId props when returned by GetAllForms.
I’m using DocumentEditor from npm package @onlyoffice/document-editor-react to load the editor and inside config, I have defined plugin inside config with