Scalable open-source survey software to generate dynamic JSON-driven forms within your JavaScript application. The form builder features a drag-and-drop UI, CSS Theme Editor, and GUI for conditional logic and form branching.
Check that the new survey appears correctly with the theme defined previously.
Now, activate the Themes tab and try to change a theme. For instance, select Joyful.
The following exception appears:
Uncaught TypeError: Cannot convert undefined or null to object
at Function.keys (<anonymous>)
at assign (survey-creator-core.js:32098:16)
at ./src/components/tabs/theme.ts.ThemeSurveyTabViewModel.applySelectedTheme (survey-creator-core.js:10617:72)
at ./src/components/tabs/theme.ts.ThemeSurveyTabViewModel.resetTheme (survey-creator-core.js:10767:14)
at Array.eval (survey-creator-core.js:10933:27)
at ./src/base.ts.Event.fire (survey.core.js:2682:30)
at ./src/survey.ts.SurveyModel.notifyQuestionOnValueChanged (survey.core.js:55559:37)
at ./src/survey.ts.SurveyModel.updateOnSetValue (survey.core.js:56267:18)
at ./src/survey.ts.SurveyModel.setValue (survey.core.js:56254:14)
at ./src/question.ts.Question.setValueCore (survey.core.js:25868:23)
at ./src/question.ts.Question.setNewValueInData (survey.core.js:25858:18)
at ./src/question.ts.Question.setNewValue (survey.core.js:25822:14)
at ./src/question_baseselect.ts.QuestionSelectBase.setNewValue (survey.core.js:27078:38)
at QuestionDropdownModel.set (survey.core.js:25110:18)
at ListModel._onSelectionChanged [as onSelectionChanged] (survey.core.js:7608:38)
at ListModel._this.onItemClick (survey.core.js:18158:23)
at onClick (survey-react-ui.js:1556:29)
at HTMLUnknownElement.callCallback (react-dom.development.js:4164:14)
at Object.invokeGuardedCallbackDev (react-dom.development.js:4213:16)
at invokeGuardedCallback (react-dom.development.js:4277:31)
at invokeGuardedCallbackAndCatchFirstError (react-dom.development.js:4291:25)
at executeDispatch (react-dom.development.js:9041:3)
at processDispatchQueueItemsInOrder (react-dom.development.js:9073:7)
at processDispatchQueue (react-dom.development.js:9086:5)
at dispatchEventsForPlugins (react-dom.development.js:9097:3)
at eval (react-dom.development.js:9288:12)
at batchedUpdates$1 (react-dom.development.js:26140:12)
at batchedUpdates (react-dom.development.js:3991:12)
at dispatchEventForPluginEventSystem (react-dom.development.js:9287:3)
at dispatchEventWithEnableCapturePhaseSelectiveHydrationWithoutDiscreteEventReplay (react-dom.development.js:6465:5)
at dispatchEvent (react-dom.development.js:6457:5)
at dispatchDiscreteEvent (react-dom.development.js:6430:5)
To reproduce the issue, follow these steps:
Run this demo
Load the following custom theme:
Check that the theme was applied correctly.
Now, replace a survey JSON with the following one:
Check that the new survey appears correctly with the theme defined previously.
Now, activate the Themes tab and try to change a theme. For instance, select Joyful. The following exception appears: