Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
PropertyFieldCollectionData - Support custom fields with string values (i.e. code editor) #122
I'm currently working to integrate a result types feature to the react-search-refiners sample and I would like to use the PropertyFieldCollectionData to edit the HTML code for a specific condition set. With current options, I'm able to render the condition as string fields (property, operator, and value) but I'm struggling to add a code editor field.
My first attempt was to use the onRenderOption method with a dropdown field. With this, I'm able to open a code editor dialog from a button option but I'm not able to get back the result and associate it to the PropertyFieldCollectionData corresponding field.
Would it be possible to support custom fields with, for instance onRender/onUpdate methods for the PropertyFieldCollectionData control?
I could implement such a control myself but except this issue, the PropertyFieldCollectionData suits this scenario very well.
Expected / Desired Behavior / Question
Support custom fields with string values like a code editor.
added a commit
Dec 6, 2018
@FranckyC this is an amazing idea which is now implemented in the current beta version.
Feel free to test it out and check if it meets your needs. The initial implementation is very basic, it allows you to override the rendering and tell the value to update.
More information about how to install a beta version can be found here: https://sharepoint.github.io/sp-dev-fx-property-controls/beta/
The documentation for the control has been updated. At the moment it is not yet live, so you have to check it in the DEV branch: https://github.com/SharePoint/sp-dev-fx-property-controls/blob/dev/docs/documentation/docs/controls/PropertyFieldCollectionData.md