IPropertyPaneCustomFieldProps interface
PropertyPane CustomPropertyField props.
Properties
context | Instance specific context. This context is passed back to the web part in the onRender and onDispose APIs. The web part can use this context to manage state information. |
key | An UNIQUE key indicates the identity of this control. The PropertyPane uses ReactJS to render its components. ReactJS uses keys to identify a component and if it should be re-rendered or not. This is a performance feature in ReactJS. Please read the following link to understand how to pick the value of the key. For more information, see the React documentation. |
on |
This API is called when the component is unmounted from the host element. |
on |
This API will be called once the custom field is mounted on the host element. |
Property Details
context
Instance specific context. This context is passed back to the web part in the onRender and onDispose APIs. The web part can use this context to manage state information.
context?: any;
Property Value
any
key
An UNIQUE key indicates the identity of this control.
The PropertyPane uses ReactJS to render its components. ReactJS uses keys to identify a component and if it should be re-rendered or not. This is a performance feature in ReactJS. Please read the following link to understand how to pick the value of the key.
For more information, see the React documentation.
key: string;
Property Value
string
onDispose
This API is called when the component is unmounted from the host element.
onDispose?: (domElement: HTMLElement, context?: any) => void;
Property Value
(domElement: HTMLElement, context?: any) => void
onRender
This API will be called once the custom field is mounted on the host element.
onRender: (domElement: HTMLElement, context?: any, changeCallback?: (targetProperty?: string, newValue?: any) => void) => void;
Property Value
(domElement: HTMLElement, context?: any, changeCallback?: (targetProperty?: string, newValue?: any) => void) => void