Question T14621
Visible to All Users

Custom component as a custom property in survey creator property grid

created a year ago

Hello surveyJS team,

First of all, thanks for this awesome tool.

Our team is using survey V2, and we want to add a custom property in the survey creator property grid which will use a custom component to render it.

This custom component would only be used as a custom property, not as an available question type.
So far, what we tried is to first extend our custom component using the QuestionAngular class with a model containing all the property change methods, then register our custom component in the AngularComponentFactory with a custom name, after that in the type property of the addProperty method of the serializer add the custom name we used in the previous step to register our custom component in the AngularComponentFactory, and finally using the PropertyGridEditorCollection register method.

Quick resume, what we want to achieve is what we did with SurveyCreator.SurveyPropertyEditorFactory.registerCustomEditor in V1 but in the V2.
We know that we are missing some step/s, if you could help us with this it would be much appreciated. Maybe there is a much more simple way than how we tried to implement this.

We are using Angular framework.

Thanks for your time.
KR

Answers

created a year ago

Can be closed, we missed the static declaration of the components for the tree shaking.
Sorry for the inconvenience.
KR

    Comments (1)

      No problem. Thanks for letting us know. Please feel free to contact us if you have any further questions.