OptionalclassUseful to set a custom CSS class name on the item.
For default document editor footer items the className is appended to the default
item ones.
OptionalidUnique identifier for the item.
This is useful to identify items whose type is custom.
// In your JavaScript
const documentEditorFooterItems = NutrientViewer.defaultDocumentEditorFooterItems
documentEditorFooterItems.push({ type: 'custom', id: 'my-button', ... })
NutrientViewer.load({
...otherOptions,
documentEditorFooterItems
});
Note: It is ***not*** possible to override this option for built-in document editor footer items.
Optionalnodecustom tool items have to define a DOM node which NutrientViewer will render.
In this case the tool item is rendered inside of a container div. The className which you pass is set to this container div and not to the node that you passed.
The onPress event is registered and fires any time the item is clicked.
OptionalonCallback to invoke when the item is clicked or tapped (on touch devices). It gets the event as
first argument, a document editor UI handler object as the second, and the id of the tool item as the third.
Built in items do not receive a documentEditorUIHandler
The event that is fired on press. onPress is also fired when pressing enter while the item has focus.
OptionaldocumentEditorUIHandler: DocumentEditorUIHandlerAn instance object to set and retrieve different state properties of the document editor UI. Built in items do not receive a documentEditorUIHandler
Optionalid: stringThe tool item id.
The type of a document editor footer item.
It can either be custom for user defined items or one from the NutrientViewer.defaultDocumentEditorFooterItems.
Note: It is not possible to override this option for built-in toolbar items.
Describes the properties of a Document Editor Footer Item.
Check out our guides for more examples.
See