Version: v1.9.53, estimated release date is Tuesday, October 11, 2022, Total Issue Count: 24

Product Type Description
survey-library Enhancement Rename the hasErrors() method and containsErrors property

Method names usually start with a verb. We should rename the hasErrors() method to validate().

We have many properties that start with "has": hasDescription, hasTitle, hasOther, etc. The containsErrors property works similarly but named differerntly. We should rename this property to hasErrors.

survey-library Enhancement Improve errors in UI in defaultV2 theme

Based on https://surveyjs.answerdesk.io/internal/ticket/details/T10140 and https://surveyjs.answerdesk.io/internal/ticket/details/T9923. Based on users feedback tooltip errors which appear in panel/paneldynamic are inconvenient.

survey-library Enhancement Dropdown, Tagbox - Improve performance when working with large data sets

When a data set contains a lot of items, Dropdown/Tagbox may not handle this well, for example, take more time to load items.

Introduce an option to improve the performance when using large datasets for Dropdown/Tagbox questions.

survey-library Bug Textbox/Tagbox/Dropdown - check disables/enabled state for these questions
survey-library Bug Ranking question duplicates choices with identical values

Create a Ranking question and specify the identical value for all its choices:

 {
     "type": "ranking",
     "name": "question1",
     "choices": [
      {
       "value": "1",
       "text": "item1"
      },
      {
       "value": "1",
       "text": "item1"
      },
      {
       "value": "1",
       "text": "item1"
      }
     ]
}

Reorder items and observe the Ranking duplicates items: example. image

survey-library Enhancement Dynamic Panel - Add custom buttons to individual panels (e.g., the Remove button) and to the top-level area (e.g., Add button)

An option for the Panel Dynamic question to add custom buttons to individual panels (like the Remove button) and to the top-level question area (like the Add button).

Usage scenario A custom Duplicate button which duplicates the current panel with input values: image

Original issue: T10818 - Add a custom button to a Dynamic Panel.

survey-library Enhancement Show console warning if SurveyJS Libraries has different versions

A lot of issues developers have when they are using different versions Library (core/ui), Creator, Pdf and Custom widgets. We should show a console warning if versions are different.

survey-library Enhancement Tagbox. Empty popup has to be smaller.
survey-library Enhancement Rename some `has*` properties

We have two types of has* properties:

  1. Properties that indicate presence of something (hasTitle, hasDescription, hasInput).
  2. Properties that change something (hasComment displays a comment area, hasOther displays the Other item)

We need to split these two types apart by means of naming. Let's keep properties of type 1 as they are and rename properties of type 2 as follows:

hasComment -> showCommentArea hasOther -> showOtherItem hasNone -> showNoneItem hasSelectAll -> showSelectAllItem

survey-library Enhancement Replace custom buttons in Popup window with ActionBar

In our popup window we have two buttons "Cancel" and "OK"/"Apply". It is better to use our ActionBar that will allow to add any action on the footer of Popup window.

survey-library Bug Exception raised if a developer set default locale to incorrect value

The following code will lead to exceptions:

Survey.surveyLocalization.defaultLocale = "en-us";

or

Survey.surveyLocalization.defaultLocale = "unknown";

There is not translation for "en-us" and as result surveyLocalization will start to use undefined object for translated strings. We have to use "en" translation in this case.

survey-creator Bug Width of Popup

We should avoid text trimming. In this case we could increase the popup's width.

Image

survey-creator Bug Survey Creator Custom Options - Cannot show Help Description for a custom Boolean option

I created a custom Boolean property and want to show help description for it. However, the following code doesn't work - a help icon isn't shown for a custom Boolean property.

Survey.Serializer.addProperty(
  "survey", 
   {
     name: "sampleProp:boolean",
     category: "Watermark"
  }
);
const translations = SurveyCreator.localization.getLocale("");
debugger;
translations.pehelp.sampleProp = "Sample tip here";

image

The issue has been reported at https://surveyjs.answerdesk.io/ticket/details/T10340.

survey-creator Enhancement Ability to have different choices per matrixdynamic columns seems to have broken

Are you requesting a feature, reporting a bug or ask a question?

Reporting bug

What is the current behavior?

I had created a Survey in Survey-Creator that at one time allowed me to have different dropdown choices per column on a single Dynamic Matrix object. This no longer seems to be possible which may have something to do with survey library itself and a code change on that end. When attempting to add different choices between columns, Survey Creator does not respect the values:

Choices for column one, "Sex":

sex

Choices for column two, "Age":

age

JSON output when apply is made on both of these columns:

json


Trying to add the data in the actual choices field in right-hand sidebar does not work as this makes the choices global for all columns.

What is the expected behavior?

Differentiating the choice data between columns used to work reliably, but now the JSON will not output to two columns, nor are any choices available when attempting to preview or run the survey in the wild..

Code that used to work now throws error in Creator JSON output: error

How would you reproduce the current behavior (if this is a bug)?

  • Drag a dynamic matrix block into your Survey Creator page
  • Make 2 columns
  • Hover over the pencil Icon on one column and add choices, click Apply
  • Hover over the pencil icon on the other column and add different choices, click Apply
  • Observe that either one set of choices becomes global for all, or no choices persist and JSON choices does not output

Provide the test code and the tested page URL (if applicable)

Code that used to work:

{
 "logoPosition": "right",
 "pages": [
  {
   "name": "page1",
   "elements": [
    {
     "type": "matrixdynamic",
     "name": "child_sex&age",
     "visibleIf": "{Parent} = 'Yes'",
     "title": "Please select your child's biological sex and current age (in years)",
     "columns": [
      {
       "name": "Age",
       "choices": [
        {
         "value": "item1",
         "text": "Prefer not to Answer"
        },
        {
         "value": "item2",
         "text": "Under 12 Months"
        },
        {
         "value": "item3",
         "text": "1"
        },
        {
         "value": "item4",
         "text": "2"
        },
       ],
       "storeOthersAsComment": true,
       "optionsCaption": "Choose "
      },
      {
       "name": "Sex",
       "choices": [
        {
         "value": "item1",
         "text": "Prefer not to Answer"
        },
        {
         "value": "item2",
         "text": "Male"
        },
        {
         "value": "item3",
         "text": "Female"
        },
        {
         "value": "item4",
         "text": "Intersex"
        }
       ],
       "storeOthersAsComment": true,
       "optionsCaption": "Choose "
      }
     ],
     "optionsCaption": "Choose ",
     "rowCount": 1,
     "minRowCount": 1,
     "confirmDelete": true,
     "confirmDeleteText": "Are you sure you want to delete this record?",
     "addRowText": "Add Child"
    }
   ]
  }
 ]
}

Specify your

  • browser: Firefox 102.0
  • editor version: 1.940
survey-creator Enhancement List UX -UX improvement of list filling is required (keyboard navigation).

UX improvement of list filling is required (keyboard navigation).

This applies to the following questions

  • check-box — radio group

  • drop-down — rating — ranking

  • boolean

  • matrix

  • multiple text

  • #3489

  • #3479 Focus question title when create a question At the moment of creating a question, immediately focus the text field of the question (input is activated). SelectBase items Keyboard editing Enter does not end input, but shifts focus to the next input field. You can finish entering by Ctrl (Cmd) + Enter, mouse click “in milk”, or ESC, but with the cancellation of changes, if any. By pressing Enter, the focus is “transferred” to the input fields (within one question). If there are no more input fields, then Enter adds a new item. In questions where there is nothing to fill in, Enter simply ends the input after entering the question text. At the time of adding a new item, the input field is focused.

  • #3497

  • Keyboard interactivity for ranking

  • Keyboard interactivity for boolean

  • Keyboard interactivity for multiple text

  • Keyboard interactivity for matrix For matrix it would be possible to create a new column/row using Enter.

  • #3480

  • After deleting an item, focus should be left on the Remove buttons. Moreover, if the user went up by tabulation at the bottom, then the focus should be left on the item, which is higher, if the user went down from above, then on the item, which is lower.

  • After changing the question type, the focus should be left on the type change combo box.

  • Inserting a ready-made list of answers. By ctrl + V, the list of answers is filled, starting with the focused one.

survey-creator Bug I become very angry when popup disappears after scrolling reaches it's limit.

Image

survey-creator Enhancement Implement survey-creator-angular package
survey-creator Enhancement Matrix Dropdown / Dynamic - Columns are not accessible from the Property Grid selector

It is possible to edit Matrixdropdown / Matrixdynamic columns via the Property Grid, however, they are not listed in the Property Grid popup selector: image

survey-creator Bug The navigation bar doesn't list all survey pages

I have 14 pages in my survey, but the navigation bar doesn't seem to have pages 13 and 14 in the list: image

They are accessible only via the Survey | Pages property section. image

Example.

survey-creator Enhancement Tagbox: implement adding elements at design time

image

survey-creator Enhancement autoComplete property editor replace

image

survey-pdf Enhancement Correct acroform ids for selectbase questions

For radiogroup questions: /V should item's value For checkbox questions: /T should be question's id + item's value

survey-analytics Bug Filtering doesn't apply

May be related to https://github.com/surveyjs/survey-analytics/issues/229

  1. Open the demo: https://surveyjs.io/dashboard/examples/nps-direct
  2. Click any bar in the questions about backend languages, device types, or our libraries.

Result: all charts become empty. image

survey-analytics Bug Fix roundoff and incorrect ranges in bar charts

https://surveyjs.io/dashboard/examples/nps-direct

image

As you can see, we need to automatically roundoff numbers, but also calculate bar ranges more carefully. In the question illustrated above, there cannot be values greater than 10 or lower than 0. However, the chart ignores that and displays extreme ranges of up to 11 and down to -1. I think we could use the question's minRate and maxRate properties to fix that.

Version: v1.9.53, estimated release date is Tuesday, October 11, 2022, Total Issue Count: 24

Product
survey-library
Type
Enhancement
Description
Rename the hasErrors() method and containsErrors property

Method names usually start with a verb. We should rename the hasErrors() method to validate().

We have many properties that start with "has": hasDescription, hasTitle, hasOther, etc. The containsErrors property works similarly but named differerntly. We should rename this property to hasErrors.

Product
survey-library
Type
Enhancement
Description
Improve errors in UI in defaultV2 theme

Based on https://surveyjs.answerdesk.io/internal/ticket/details/T10140 and https://surveyjs.answerdesk.io/internal/ticket/details/T9923. Based on users feedback tooltip errors which appear in panel/paneldynamic are inconvenient.

Product
survey-library
Type
Enhancement
Description
Dropdown, Tagbox - Improve performance when working with large data sets

When a data set contains a lot of items, Dropdown/Tagbox may not handle this well, for example, take more time to load items.

Introduce an option to improve the performance when using large datasets for Dropdown/Tagbox questions.

Product
survey-library
Type
Bug
Description
Ranking question duplicates choices with identical values

Create a Ranking question and specify the identical value for all its choices:

 {
     "type": "ranking",
     "name": "question1",
     "choices": [
      {
       "value": "1",
       "text": "item1"
      },
      {
       "value": "1",
       "text": "item1"
      },
      {
       "value": "1",
       "text": "item1"
      }
     ]
}

Reorder items and observe the Ranking duplicates items: example. image

An option for the Panel Dynamic question to add custom buttons to individual panels (like the Remove button) and to the top-level question area (like the Add button).

Usage scenario A custom Duplicate button which duplicates the current panel with input values: image

Original issue: T10818 - Add a custom button to a Dynamic Panel.

Product
survey-library
Type
Enhancement
Description
Show console warning if SurveyJS Libraries has different versions

A lot of issues developers have when they are using different versions Library (core/ui), Creator, Pdf and Custom widgets. We should show a console warning if versions are different.

Product
survey-library
Type
Enhancement
Description
Tagbox. Empty popup has to be smaller.
Product
survey-library
Type
Enhancement
Description
Rename some `has*` properties

We have two types of has* properties:

  1. Properties that indicate presence of something (hasTitle, hasDescription, hasInput).
  2. Properties that change something (hasComment displays a comment area, hasOther displays the Other item)

We need to split these two types apart by means of naming. Let's keep properties of type 1 as they are and rename properties of type 2 as follows:

hasComment -> showCommentArea hasOther -> showOtherItem hasNone -> showNoneItem hasSelectAll -> showSelectAllItem

Product
survey-library
Type
Enhancement
Description
Replace custom buttons in Popup window with ActionBar

In our popup window we have two buttons "Cancel" and "OK"/"Apply". It is better to use our ActionBar that will allow to add any action on the footer of Popup window.

The following code will lead to exceptions:

Survey.surveyLocalization.defaultLocale = "en-us";

or

Survey.surveyLocalization.defaultLocale = "unknown";

There is not translation for "en-us" and as result surveyLocalization will start to use undefined object for translated strings. We have to use "en" translation in this case.

Product
survey-creator
Type
Bug
Description
Width of Popup

We should avoid text trimming. In this case we could increase the popup's width.

Image

I created a custom Boolean property and want to show help description for it. However, the following code doesn't work - a help icon isn't shown for a custom Boolean property.

Survey.Serializer.addProperty(
  "survey", 
   {
     name: "sampleProp:boolean",
     category: "Watermark"
  }
);
const translations = SurveyCreator.localization.getLocale("");
debugger;
translations.pehelp.sampleProp = "Sample tip here";

image

The issue has been reported at https://surveyjs.answerdesk.io/ticket/details/T10340.

Product
survey-creator
Type
Enhancement
Description
Ability to have different choices per matrixdynamic columns seems to have broken

Are you requesting a feature, reporting a bug or ask a question?

Reporting bug

What is the current behavior?

I had created a Survey in Survey-Creator that at one time allowed me to have different dropdown choices per column on a single Dynamic Matrix object. This no longer seems to be possible which may have something to do with survey library itself and a code change on that end. When attempting to add different choices between columns, Survey Creator does not respect the values:

Choices for column one, "Sex":

sex

Choices for column two, "Age":

age

JSON output when apply is made on both of these columns:

json


Trying to add the data in the actual choices field in right-hand sidebar does not work as this makes the choices global for all columns.

What is the expected behavior?

Differentiating the choice data between columns used to work reliably, but now the JSON will not output to two columns, nor are any choices available when attempting to preview or run the survey in the wild..

Code that used to work now throws error in Creator JSON output: error

How would you reproduce the current behavior (if this is a bug)?

  • Drag a dynamic matrix block into your Survey Creator page
  • Make 2 columns
  • Hover over the pencil Icon on one column and add choices, click Apply
  • Hover over the pencil icon on the other column and add different choices, click Apply
  • Observe that either one set of choices becomes global for all, or no choices persist and JSON choices does not output

Provide the test code and the tested page URL (if applicable)

Code that used to work:

{
 "logoPosition": "right",
 "pages": [
  {
   "name": "page1",
   "elements": [
    {
     "type": "matrixdynamic",
     "name": "child_sex&age",
     "visibleIf": "{Parent} = 'Yes'",
     "title": "Please select your child's biological sex and current age (in years)",
     "columns": [
      {
       "name": "Age",
       "choices": [
        {
         "value": "item1",
         "text": "Prefer not to Answer"
        },
        {
         "value": "item2",
         "text": "Under 12 Months"
        },
        {
         "value": "item3",
         "text": "1"
        },
        {
         "value": "item4",
         "text": "2"
        },
       ],
       "storeOthersAsComment": true,
       "optionsCaption": "Choose "
      },
      {
       "name": "Sex",
       "choices": [
        {
         "value": "item1",
         "text": "Prefer not to Answer"
        },
        {
         "value": "item2",
         "text": "Male"
        },
        {
         "value": "item3",
         "text": "Female"
        },
        {
         "value": "item4",
         "text": "Intersex"
        }
       ],
       "storeOthersAsComment": true,
       "optionsCaption": "Choose "
      }
     ],
     "optionsCaption": "Choose ",
     "rowCount": 1,
     "minRowCount": 1,
     "confirmDelete": true,
     "confirmDeleteText": "Are you sure you want to delete this record?",
     "addRowText": "Add Child"
    }
   ]
  }
 ]
}

Specify your

  • browser: Firefox 102.0
  • editor version: 1.940
Product
survey-creator
Type
Enhancement
Description
List UX -UX improvement of list filling is required (keyboard navigation).

UX improvement of list filling is required (keyboard navigation).

This applies to the following questions

  • check-box — radio group

  • drop-down — rating — ranking

  • boolean

  • matrix

  • multiple text

  • #3489

  • #3479 Focus question title when create a question At the moment of creating a question, immediately focus the text field of the question (input is activated). SelectBase items Keyboard editing Enter does not end input, but shifts focus to the next input field. You can finish entering by Ctrl (Cmd) + Enter, mouse click “in milk”, or ESC, but with the cancellation of changes, if any. By pressing Enter, the focus is “transferred” to the input fields (within one question). If there are no more input fields, then Enter adds a new item. In questions where there is nothing to fill in, Enter simply ends the input after entering the question text. At the time of adding a new item, the input field is focused.

  • #3497

  • Keyboard interactivity for ranking

  • Keyboard interactivity for boolean

  • Keyboard interactivity for multiple text

  • Keyboard interactivity for matrix For matrix it would be possible to create a new column/row using Enter.

  • #3480

  • After deleting an item, focus should be left on the Remove buttons. Moreover, if the user went up by tabulation at the bottom, then the focus should be left on the item, which is higher, if the user went down from above, then on the item, which is lower.

  • After changing the question type, the focus should be left on the type change combo box.

  • Inserting a ready-made list of answers. By ctrl + V, the list of answers is filled, starting with the focused one.

Image

Product
survey-creator
Type
Enhancement
Description
Implement survey-creator-angular package

It is possible to edit Matrixdropdown / Matrixdynamic columns via the Property Grid, however, they are not listed in the Property Grid popup selector: image

Product
survey-creator
Type
Bug
Description
The navigation bar doesn't list all survey pages

I have 14 pages in my survey, but the navigation bar doesn't seem to have pages 13 and 14 in the list: image

They are accessible only via the Survey | Pages property section. image

Example.

Product
survey-creator
Type
Enhancement
Description
Tagbox: implement adding elements at design time

image

Product
survey-creator
Type
Enhancement
Description
autoComplete property editor replace

image

Product
survey-pdf
Type
Enhancement
Description
Correct acroform ids for selectbase questions

For radiogroup questions: /V should item's value For checkbox questions: /T should be question's id + item's value

Product
survey-analytics
Type
Bug
Description
Filtering doesn't apply

May be related to https://github.com/surveyjs/survey-analytics/issues/229

  1. Open the demo: https://surveyjs.io/dashboard/examples/nps-direct
  2. Click any bar in the questions about backend languages, device types, or our libraries.

Result: all charts become empty. image

Product
survey-analytics
Type
Bug
Description
Fix roundoff and incorrect ranges in bar charts

https://surveyjs.io/dashboard/examples/nps-direct

image

As you can see, we need to automatically roundoff numbers, but also calculate bar ranges more carefully. In the question illustrated above, there cannot be values greater than 10 or lower than 0. However, the chart ignores that and displays extreme ranges of up to 11 and down to -1. I think we could use the question's minRate and maxRate properties to fix that.

Version: v1.9.52, released at Tuesday, October 4, 2022, Total Issue Count: 11

Product Type Description
survey-library Enhancement Dropdown: add the ability to set a field template
survey-library Enhancement Merge and rename the (un)registerFunctionOnProperty(ies)ValueChanged methods

We have two methods that essentially do the same:

The only difference between them is that one registers a property changed event handler for a single property, while the other does this form multiple properties. It is sufficient to keep only the second method. Besides that, we should rename it because the phrase "register function on properties value changed" is read as if the method doesn't register the function until a property value is changed. We also have similar methods that unregister the event handlers. We should get rid of one of them and rename the remaining method as well. Here are the proposed names:

registerPropertyChangedHandlers(propertyNames, handler, key)
unregisterPropertyChangedHandlers(propertyNames, key)
survey-library Bug dropdown spacing

Are you requesting a feature, reporting a bug or asking a question?

bug/feature

What is the current behavior?

Maybe the spacing among dropdown question components need to be improved. In the following example

https://plnkr.co/edit/E1iJdrxQPIlDE3Cu

if you tighten the window enough you see that the option text overflows the input field.

image

At the same time, too much room seems to be reserved for the clear icon button. Moreover the caret and the x seems besed on different font family

Finally there may be a connection with this issue

Don't get me wrong ... it just seems to me that doesn't live up to the style of surveyjs. Hope it helps

survey-library Enhancement Implement an ability to override select base question item rendering
survey-library Bug Dropdown with Bootstrap - Inconsistent look of an input search box with solid borders in v1.9.50

In v1.9.48 the Dropdown allows users to search an item in a drop-down list: image Example.

In v1.9.50, the search box appears inside the input area (OK), but it is surrounded by a solid border which doesn't look consistent: image Example.

survey-library Bug Do not use toISOString() in converting date to string

We should not use toISOString() on converting date to string, since it converts locale date into UTC date. It leads to setting incorrect date.

survey-library Bug React: start survey page jumps to top after first checkbox checked
survey-library Bug MaxSelectedChoices not working in Knockout for questionPerPage mode

Are you requesting a feature, reporting a bug or asking a question?

Bug / regression

What is the current behavior?

maxSelectedChoices no longer in checkbox question type when using knockout

What is the expected behavior?

It should work the same for all frameworks

How would you reproduce the current behavior (if this is a bug)?

Check the plunkr. The sample survey should limit the number of choices to 3.

Provide the test code and the tested page URL (if applicable)

Tested page URL: https://plnkr.co/edit/ZpZdCHiNImtVQO4L

Test code

{
 "logoPosition": "right",
 "pages": [
  {
   "name": "Test",
   "elements": [
    {
     "type": "html",
     "name": "T000",
     "html": "<b>Pagina 1</b>"
    },
    {
     "type": "panel",
     "name": "panel1",
     "elements": [
      {
       "type": "checkbox",
       "name": "V003",
       "title": "Wie is de beste club?",
       "isRequired": true,
       "choices": [
        {
         "value": "1",
         "text": "PSV"
        },
        {
         "value": "2",
         "text": "Ajax"
        },
        {
         "value": "3",
         "text": "Feyenoord"
        },
        {
         "value": "4",
         "text": "Twente "
        },
        {
         "value": "5",
         "text": "AZ"
        }
       ],
       "maxSelectedChoices": 3
      }
     ]
    },
    {
     "type": "panel",
     "name": "panel2",
     "elements": [
      {
       "type": "radiogroup",
       "name": "V005",
       "title": "Wie is de beste club?",
       "isRequired": true,
       "choices": [
        {
         "value": "1",
         "text": "PSV"
        },
        {
         "value": "2",
         "text": "Ajax"
        },
        {
         "value": "3",
         "text": "Feyenoord"
        }
       ],
       "choicesEnableIf": "{V006} notequal {item}"
      },
      {
       "type": "radiogroup",
       "name": "V006",
       "title": "Wie is de beste club?",
       "isRequired": true,
       "choices": [
        {
         "value": "1",
         "text": "PSV"
        },
        {
         "value": "2",
         "text": "Ajax"
        },
        {
         "value": "3",
         "text": "Feyenoord"
        }
       ],
       "choicesEnableIf": "{V005} notcontains {item}"
      }
     ]
    }
   ]
  }
 ],
 "requiredText": "",
 "questionsOnPageMode": "questionPerPage"
}

Specify your

  • browser: Chrome
  • browser version: latest
  • surveyjs platform (angular or react or jquery or knockout or vue): knockout
  • surveyjs version: 1.9.51
survey-creator Enhancement Focus should not come to inactive fields, such as Select All, None, and Other.
survey-creator Enhancement The modifyQuestionTitle event doesn't immediately update a question title with a custom property value

I created a custom property and use it to update a question title in the modifyQuestionTitle event.

Survey.Serializer.addProperty('rating', {
  name: 'code',
  category: 'general',
  visibleIndex: 2,
});
...
creator.onSurveyInstanceCreated.add(function (sender, options) {
  if (options.reason == 'designer') {
    options.survey.onGetQuestionTitle.add(modifyQuestionTitle);
  }
  if (options.reason == 'test') {
    options.survey.onGetQuestionTitle.add(modifyQuestionTitle);
  }
});

Example.

However, the question title doesn't updated once I update a custom property using the Property Grid: https://user-images.githubusercontent.com/22372972/193025242-812b45da-5d07-4728-bad2-73315b13f084.mp4

survey-creator Enhancement Add creator.onTranslationExportItem event

onTranslationExportItem event is called before the text for translation item is exported. You can modify the text to export a different text into csv file. Here is the example that set the default locale text, instead of empty string:

  creator.onTranslationExportItem.add((sender, options) => {
    if(!options.text) {
      options.text = options.locString.getLocaleText("");
    }
  });

Version: v1.9.52, released at Tuesday, October 4, 2022, Total Issue Count: 11

Product
survey-library
Type
Enhancement
Description
Dropdown: add the ability to set a field template
Product
survey-library
Type
Enhancement
Description
Merge and rename the (un)registerFunctionOnProperty(ies)ValueChanged methods

We have two methods that essentially do the same:

The only difference between them is that one registers a property changed event handler for a single property, while the other does this form multiple properties. It is sufficient to keep only the second method. Besides that, we should rename it because the phrase "register function on properties value changed" is read as if the method doesn't register the function until a property value is changed. We also have similar methods that unregister the event handlers. We should get rid of one of them and rename the remaining method as well. Here are the proposed names:

registerPropertyChangedHandlers(propertyNames, handler, key)
unregisterPropertyChangedHandlers(propertyNames, key)
Product
survey-library
Type
Bug
Description
dropdown spacing

Are you requesting a feature, reporting a bug or asking a question?

bug/feature

What is the current behavior?

Maybe the spacing among dropdown question components need to be improved. In the following example

https://plnkr.co/edit/E1iJdrxQPIlDE3Cu

if you tighten the window enough you see that the option text overflows the input field.

image

At the same time, too much room seems to be reserved for the clear icon button. Moreover the caret and the x seems besed on different font family

Finally there may be a connection with this issue

Don't get me wrong ... it just seems to me that doesn't live up to the style of surveyjs. Hope it helps

Product
survey-library
Type
Enhancement
Description
Implement an ability to override select base question item rendering

In v1.9.48 the Dropdown allows users to search an item in a drop-down list: image Example.

In v1.9.50, the search box appears inside the input area (OK), but it is surrounded by a solid border which doesn't look consistent: image Example.

Product
survey-library
Type
Bug
Description
Do not use toISOString() in converting date to string

We should not use toISOString() on converting date to string, since it converts locale date into UTC date. It leads to setting incorrect date.

Product
survey-library
Type
Bug
Description
React: start survey page jumps to top after first checkbox checked
Product
survey-library
Type
Bug
Description
MaxSelectedChoices not working in Knockout for questionPerPage mode

Are you requesting a feature, reporting a bug or asking a question?

Bug / regression

What is the current behavior?

maxSelectedChoices no longer in checkbox question type when using knockout

What is the expected behavior?

It should work the same for all frameworks

How would you reproduce the current behavior (if this is a bug)?

Check the plunkr. The sample survey should limit the number of choices to 3.

Provide the test code and the tested page URL (if applicable)

Tested page URL: https://plnkr.co/edit/ZpZdCHiNImtVQO4L

Test code

{
 "logoPosition": "right",
 "pages": [
  {
   "name": "Test",
   "elements": [
    {
     "type": "html",
     "name": "T000",
     "html": "<b>Pagina 1</b>"
    },
    {
     "type": "panel",
     "name": "panel1",
     "elements": [
      {
       "type": "checkbox",
       "name": "V003",
       "title": "Wie is de beste club?",
       "isRequired": true,
       "choices": [
        {
         "value": "1",
         "text": "PSV"
        },
        {
         "value": "2",
         "text": "Ajax"
        },
        {
         "value": "3",
         "text": "Feyenoord"
        },
        {
         "value": "4",
         "text": "Twente "
        },
        {
         "value": "5",
         "text": "AZ"
        }
       ],
       "maxSelectedChoices": 3
      }
     ]
    },
    {
     "type": "panel",
     "name": "panel2",
     "elements": [
      {
       "type": "radiogroup",
       "name": "V005",
       "title": "Wie is de beste club?",
       "isRequired": true,
       "choices": [
        {
         "value": "1",
         "text": "PSV"
        },
        {
         "value": "2",
         "text": "Ajax"
        },
        {
         "value": "3",
         "text": "Feyenoord"
        }
       ],
       "choicesEnableIf": "{V006} notequal {item}"
      },
      {
       "type": "radiogroup",
       "name": "V006",
       "title": "Wie is de beste club?",
       "isRequired": true,
       "choices": [
        {
         "value": "1",
         "text": "PSV"
        },
        {
         "value": "2",
         "text": "Ajax"
        },
        {
         "value": "3",
         "text": "Feyenoord"
        }
       ],
       "choicesEnableIf": "{V005} notcontains {item}"
      }
     ]
    }
   ]
  }
 ],
 "requiredText": "",
 "questionsOnPageMode": "questionPerPage"
}

Specify your

  • browser: Chrome
  • browser version: latest
  • surveyjs platform (angular or react or jquery or knockout or vue): knockout
  • surveyjs version: 1.9.51
Product
survey-creator
Type
Enhancement
Description
Focus should not come to inactive fields, such as Select All, None, and Other.

I created a custom property and use it to update a question title in the modifyQuestionTitle event.

Survey.Serializer.addProperty('rating', {
  name: 'code',
  category: 'general',
  visibleIndex: 2,
});
...
creator.onSurveyInstanceCreated.add(function (sender, options) {
  if (options.reason == 'designer') {
    options.survey.onGetQuestionTitle.add(modifyQuestionTitle);
  }
  if (options.reason == 'test') {
    options.survey.onGetQuestionTitle.add(modifyQuestionTitle);
  }
});

Example.

However, the question title doesn't updated once I update a custom property using the Property Grid: https://user-images.githubusercontent.com/22372972/193025242-812b45da-5d07-4728-bad2-73315b13f084.mp4

Product
survey-creator
Type
Enhancement
Description
Add creator.onTranslationExportItem event

onTranslationExportItem event is called before the text for translation item is exported. You can modify the text to export a different text into csv file. Here is the example that set the default locale text, instead of empty string:

  creator.onTranslationExportItem.add((sender, options) => {
    if(!options.text) {
      options.text = options.locString.getLocaleText("");
    }
  });

Version: v1.9.51, released at Thursday, September 29, 2022, Total Issue Count: 33

Product Type Description
survey-library Enhancement The survey is very slow when using onTextMarkdown to replace html on questions

Are you requesting a feature, reporting a bug or asking a question?

Bug

What is the current behavior?

When i have a big survey and i use this event, is very slow to load, and when some logic (visibleIf) is applied is very slow

Like 5-10 segs to show 1 question

What is the expected behavior?

Take a normal time

How would you reproduce the current behavior (if this is a bug)?

Create a big survey with all the options, and add the code added on test code section

Provide the test code and the tested page URL (if applicable)

Tested page URL:

Test code

surveyModel.onTextMarkdown.add(function(survey, options) {
	var str = converter.makeHtml(options.text);
	options.html = str;
});

Comments : idk how really works this events, but seems like when we set the property html on the event something happens and seems like we got several re-renderings here

Specify your

  • browser:
  • browser version:
  • surveyjs platform (angular or react or jquery or knockout or vue):
  • surveyjs version:
survey-library Enhancement Markdown and displayed value in dropdown question

Are you requesting a feature, reporting a bug or asking a question?

bug

What is the current behavior?

While using your demo example if I switch to a dropdown question markdown does not get interpreted:

https://plnkr.co/edit/xRA03ZeNOWJR3s06

This is my actual use case

https://plnkr.co/edit/aWixJJ0ixTJrN24u

thank you for any help

survey-library Bug Rename `commentPlaceHolder` and `otherPlaceHolder` to `commentPlaceholder` and `otherPlaceholder`
survey-library Bug Dropdown Question closes the popup when tapping a search box in iOS devices

From T10625 - Auto scroll to input on focus breaks dropdown search on ios

iOS always tries to vertically center a text input on focus. So if you've scrolled down a bit and tap the dropdown, then tap the search box, it will always close the dropdown because iOS automatically tries to scroll it to the center of the screen.

survey-library Enhancement Data saving errors hidden by showCompletedPage

Are you requesting a feature, reporting a bug or asking a question?

Bug / question

What is the current behavior?

The showCompletedPage option effects not only the display of the contents of completedHtml, but also of the data upload progress.

What is the expected behavior?

When data uploads fails (ie options.showDataSavingError() is called), the library shows a retry button. But if showCompletedPage is false then this button is not shown; instead the user is stuck on an empty screen.

I'd love to see the saving status, but not the completedHtml when the showCompletedPage is disabled.

How would you reproduce the current behavior (if this is a bug)?

Go here: https://plnkr.co/edit/DWqo5vM7iqwzBDd6 Complete the survey and observe that you do not get any visible indicator showing that data upload failed.

Provide the test code and the tested page URL (if applicable)

Tested page URL: https://plnkr.co/edit/DWqo5vM7iqwzBDd6

Test code

Survey.StylesManager.applyTheme("defaultV2");
var json = {
  "pages": [
    {
      "name": "page1",
      "elements": [
        {
          "type": "rating",
          "name": "nps_score",
          "title": "On a scale of zero to ten, how likely are you to recommend our product to a friend or colleague?",
          "isRequired": true,
          "rateMin": 0,
          "rateMax": 10,
          "minRateDescription": "(Most unlikely)",
          "maxRateDescription": "(Most likely)"
        }, {
          "type": "checkbox",
          "name": "promoter_features",
          "visibleIf": "{nps_score} >= 9",
          "title": "Which of the following features do you value the most?",
          "description": "Please select no more than three features.",
          "isRequired": true,
          "validators": [
            {
              "type": "answercount",
              "text": "Please select no more than three features.",
              "maxCount": 3
            }
          ],
          "hasOther": true,
          "choices": [
            "Performance",
            "Stability",
            "User interface",
            "Complete functionality",
            "Learning materials (documentation, demos, code examples)",
            "Quality support"
          ],
          "otherText": "Other features:",
          "colCount": 2
        }, {
          "type": "comment",
          "name": "passive_experience",
          "visibleIf": "{nps_score} >= 7  and {nps_score} <= 8",
          "title": "What can we do to make your experience more satisfying?"
        }, {
          "type": "comment",
          "name": "disappointing_experience",
          "visibleIf": "{nps_score} <= 6",
          "title": "Please let us know why you had such a disappointing experience with our product"
        }
      ]
    }
  ],
  "completedHtml": "<h3>Thank you for your feedback</h3>",
  "completedHtmlOnCondition": [
    {
      "expression": "{nps_score} >= 9",
      "html": "<h3>Thank you for your feedback</h3> <h4>We are glad that you love our product. Your ideas and suggestions will help us make it even better.</h4>"
    }, {
      "expression": "{nps_score} >= 6  and {nps_score} <= 8",
      "html": "<h3>Thank you for your feedback</h3> <h4>We are glad that you shared your ideas with us. They will help us make our product better.</h4>"
    }
  ],
  "showCompletedPage": false,
  "showQuestionNumbers": "off"
};
window.survey = new SurveyKnockout.Survey(json);

survey.onComplete.add(function (sender, options) {
options.showDataSavingError(error);
});

Specify your

  • browser: N/A
  • browser version: N/A
  • surveyjs platform (angular or react or jquery or knockout or vue): knockout
  • surveyjs version: 1.9.49
survey-library Enhancement Vertical Resposivity Manager - calculate items height

refers to surveyjs/survey-creator#3446

survey-library Enhancement Add renderedWidth property for survey

Based on calculatedWidthMode

survey-library Bug Seems like wrong reference to survey-knockout-ui from react-ui and vue-ui
survey-library Bug The string "==" in expression returns as "= "

We are replacing "==" in expression vs "= ". We have to fix it.

survey-library Bug Tagbox issues in Safari
  • In Safari, there are some problems with the shadow of the pope.

Image

  • After deleting everything, you can observe the following effect - the text is shifted down a little. There is a suspicion that this is a common problem for all editors in Safari, but this has appeared recently.

Image

survey-library Bug File Question placed within Panel Dynamic - The onDownloadFile event fires twice and the uploaded image is duplicated

Run the following example and upload an image to reproduce the issue: image Example.

Original issue: T10708 - File upload - onDownloadFile event triggers multiple time or twice.

survey-library Bug Bindings doesn't work correctly after value becomes empty

The binding doesn't work correctly after clearing a binding value in the question. Here is the JSON and the example

{
  elements: [
    {
      type: "dropdown",
      name: "q1",
      choicesMin: 1,
      choicesMax: 10,
    },
    {
      type: "matrixdynamic",
      name: "q2",
      bindings: {
        rowCount: "q1",
      },
      columns: [
        {
          name: "name",
        },
      ],
      cellType: "text",
      allowAddRows: false,
      allowRemoveRows: false,
      rowCount: 0,
    },
  ],
}
survey-library Enhancement Support language dialect in localization string

Let's say you have the following title JSON:

{
    default: "Default",
    en: "English",
    "en-UK": "English UK",
    pt: "Portuguese"
  }

For "en-UK" the "English UK" should be used, but for "en-US" and for "pt-BR", "English" and "Portuguese" string should be used. Dialect should check their languages locales first and then check the default locale.

survey-library Enhancement Do not allow to start question name with "#" char

We use "#" in expressions to tell SurveyJS do not convert string value into a boolean or numeric. For example {question1} + 10 and {#question1} + 10 could be different if question1 value is string that equals "123". It will return 133 in the first case and "12310" in the second case. However, if the question names as "#question1", then expression engine will look for "question1" and not for "#question1", since "#" is a reserved character.

survey-creator Bug Option caption of dropdown not updates
  1. Go to https://surveyjs.io/create-survey
  2. Add dropdown question
  3. Enter Options caption in property grid
  4. ???
  5. Caption isn't updated in designer

P.S. If remove or add any dropdown choice via adorner then caption will update

image

survey-creator Enhancement Add separators to Question type converter

image

survey-creator Enhancement Creator Toolbox: add non-nominal groups
survey-creator Bug `showObjectTitles: true` works only partially for the page navigator
survey-creator Enhancement Custom property editors

Are you requesting a feature, reporting a bug or ask a question?

Feature / question

What is the current behavior?

In editor V1 there was an option to implement an editor for a question in the build mode. (For example editing choices for a checkbox type question). It seems this is no longer documented for V2.

My specific case is this exact example: https://surveyjs.io/Documentation/Survey-Creator?id=create-specialized-question-types I've changed it to be a checkbox type instead, see below for code & URL.

What is the expected behavior?

I want some control over whether choices are rendered in the designer. Since in this scenario (using questionJSON with a choicesByUrl set) you already hide the choices configuration from the question properties, it makes sense to not render the "inline" editor.

While I think this should be in the core as a feature, I'm also very interested in a code sample to manually disable such an editor for a custom question type, this should be part of the docs page I mentioned before.

How would you reproduce the current behavior (if this is a bug)?

See URL below.

Provide the test code and the tested page URL (if applicable)

Tested page URL: https://plnkr.co/edit/9htjHDrN3a2oOWJJ

Survey
  .ComponentCollection
  .Instance
  .add({
    // Unique component name. It becomes a new question type. Please note, it should be written in lowercase.
    name: "country",
    // The text that shows on toolbox
    title: "Country",
    // The actual question that will do the job
    questionJSON: {
      type: "checkbox",
      optionsCaption: "Select a country...",
      choicesByUrl: {
        url: "https://surveyjs.io/api/CountriesExample"
      }
    }
  });

survey-creator Bug Toolbox jumps when it is grouped by category

Video

This bug can be reproduced in the Toolbox Categories demo.

survey-creator Enhancement V2: Support survey.width property

Apply survey width property on designer surface and check css classes for preview.

survey-creator Bug [V2] Custom radiogroup component shows adorner choice editing

Are you requesting a feature, reporting a bug or ask a question?

Bug

PS. I worked on this bug before, but can not find it anymore... maybe I never submitted it, maybe I did and this is a duplicate.. If that's the case, apologies!

What is the current behavior?

Creator V2 still shows the adorner allowing editing of choices when it hides the choices in the property grid.

What is the expected behavior?

They should be in sync; if a custom component defines choices and the property grid thus decides to hide this configuration option, the visual editor also should not allow editing choices

How would you reproduce the current behavior (if this is a bug)?

I've provided a plunker.

Provide the test code and the tested page URL (if applicable)

Tested page URL: https://plnkr.co/plunk/SBDqEw9WNCZlwQD4

Specify your

  • browser: Brave / latest
  • editor version: 1.9.45 v2
survey-creator Bug The PDF HTML embed disappears on Safari, MacOS

Run the following survey and observe that PDF is not displayed in Creator nor in preview:

{
 "logoPosition": "right",
 "pages": [
  {
   "name": "page1",
   "elements": [
    {
     "type": "html",
     "name": "PDF",
     "html": "<embed src='https://storage.sbg.cloud.ovh.net/v1/AUTH_dd2d546ccf1f4ec68bc7e13d2fb65abf/images/note-information.pdf' height='650px' width='100%'></embed>"
    }
   ]
  },
  {
   "name": "page2",
   "elements": [
    {
     "type": "text",
     "name": "question1"
    }
   ]
  }
 ]
}

https://user-images.githubusercontent.com/22372972/190594937-1a3db653-bd2c-47cc-b2fe-08957bfdb1e1.mov

survey-creator Bug We can see the scrollbar on some toolbox heights

Image

survey-creator Enhancement Expand/collapse the hierarchy/tree in the JSON Editor

Support expand/collapse JSON nodes in JSON Editor: image

survey-creator Bug Survey Creator with Custom Widgets - The Cannot read properties of undefined (reading 'getType') exception is thrown on an attempt to add a new question

To reproduce the issue, run the Survey Creator | Custom Widgets | React demo in CodeSandbox, and click Add Question. The following exception is thrown:

Uncaught TypeError: Cannot read properties of undefined (reading 'getType')
    at ./src/property-grid/index.ts.PropertyJSONGenerator.createJSON (index.ts:533:28)
    at ./src/property-grid/index.ts.PropertyJSONGenerator.toJSON (index.ts:457:17)
    at ./src/property-grid/index.ts.PropertyJSONGenerator.setupObjPanel (index.ts:470:25)
    at ./src/property-grid/restfull.ts.PropertyGridEditorQuestionRestfull.onCreated (restfull.ts:42:67)
    at Object.onCreated (index.ts:222:11)
    at ./src/property-grid/index.ts.PropertyJSONGenerator.onQuestionsCreated (index.ts:497:36)
    at ./src/property-grid/index.ts.PropertyJSONGenerator.setupObjPanel (index.ts:471:10)
    at ./src/property-grid/index.ts.PropertyGridModel.setObj (index.ts:757:55)
    at PropertyGridModel.set (index.ts:700:10)
    at ./src/creator-base.ts.CreatorBase.selectionChanged (creator-base.ts:2511:36)
    at ./src/creator-base.ts.CreatorBase.selectElement (creator-base.ts:2362:12)
    at ./src/creator-base.ts.CreatorBase.clickToolboxItem (creator-base.ts:2538:12)
    at ./src/creator-base.ts.CreatorBase.addNewQuestionInPage (creator-base.ts:3050:10)
    at descriptor.value [as addNewQuestionInPage] (index.ts:53:40)
    at ./src/components/page.ts.PageAdorner.addNewQuestion (page.ts:108:18)
    at onClick (Page.tsx:102:20)
    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)

CodeSandbox Link. image

This issue was reported at:

survey-creator Bug Empty survey crashes creator V2 in "bypage" pageEditMode
survey-creator Enhancement Take values for dialect languages from the main language during an export

Let's say you have two languages and two dialects: en - default language, en-uk - dialect, pt - Portugues and pt-br - Brasilian dialect. For CSV export, it makes sense to get strings for en-uk from en (default) and for pt-br from pt.

survey-creator Bug Impossible to reorder Toolbox items using the options | questionTypes collection

I expect the Toolbox will preserve the order of items specified in the questionTypes collection. But the order is not changed.

const options = {
  questionTypes: [
  "text", 
  "checkbox", 
  "radiogroup", 
  "dropdown",
  "comment",
  "barrating",
  "ranking",
  "image",
  "boolean"
  ]
};
var creator = new SurveyCreator.SurveyCreator(options);

image

Example.

survey-creator Enhancement Add separator to Question Type selector

Image

survey-creator Enhancement Basic question edit keyboard interactivity
survey-analytics Bug labelTruncateLength doesn't apply its default value

As per docs, the default value of the labelTruncateLength property is 27. However, as you can see in the following plunk, it doesn't apply: https://plnkr.co/edit/xRsyKqvgbwumgsfZ The reason for this is probably a typo on this line: https://github.com/surveyjs/survey-analytics/blob/master/src/visualizerBase.ts#L63

custom-widgets Bug Autocomplete widget breaks Creator V2

Property grid raises exception for Creator V2 if autocomplete widget is enabled.

Version: v1.9.51, released at Thursday, September 29, 2022, Total Issue Count: 33

Product
survey-library
Type
Enhancement
Description
The survey is very slow when using onTextMarkdown to replace html on questions

Are you requesting a feature, reporting a bug or asking a question?

Bug

What is the current behavior?

When i have a big survey and i use this event, is very slow to load, and when some logic (visibleIf) is applied is very slow

Like 5-10 segs to show 1 question

What is the expected behavior?

Take a normal time

How would you reproduce the current behavior (if this is a bug)?

Create a big survey with all the options, and add the code added on test code section

Provide the test code and the tested page URL (if applicable)

Tested page URL:

Test code

surveyModel.onTextMarkdown.add(function(survey, options) {
	var str = converter.makeHtml(options.text);
	options.html = str;
});

Comments : idk how really works this events, but seems like when we set the property html on the event something happens and seems like we got several re-renderings here

Specify your

  • browser:
  • browser version:
  • surveyjs platform (angular or react or jquery or knockout or vue):
  • surveyjs version:
Product
survey-library
Type
Enhancement
Description
Markdown and displayed value in dropdown question

Are you requesting a feature, reporting a bug or asking a question?

bug

What is the current behavior?

While using your demo example if I switch to a dropdown question markdown does not get interpreted:

https://plnkr.co/edit/xRA03ZeNOWJR3s06

This is my actual use case

https://plnkr.co/edit/aWixJJ0ixTJrN24u

thank you for any help

From T10625 - Auto scroll to input on focus breaks dropdown search on ios

iOS always tries to vertically center a text input on focus. So if you've scrolled down a bit and tap the dropdown, then tap the search box, it will always close the dropdown because iOS automatically tries to scroll it to the center of the screen.

Product
survey-library
Type
Enhancement
Description
Data saving errors hidden by showCompletedPage

Are you requesting a feature, reporting a bug or asking a question?

Bug / question

What is the current behavior?

The showCompletedPage option effects not only the display of the contents of completedHtml, but also of the data upload progress.

What is the expected behavior?

When data uploads fails (ie options.showDataSavingError() is called), the library shows a retry button. But if showCompletedPage is false then this button is not shown; instead the user is stuck on an empty screen.

I'd love to see the saving status, but not the completedHtml when the showCompletedPage is disabled.

How would you reproduce the current behavior (if this is a bug)?

Go here: https://plnkr.co/edit/DWqo5vM7iqwzBDd6 Complete the survey and observe that you do not get any visible indicator showing that data upload failed.

Provide the test code and the tested page URL (if applicable)

Tested page URL: https://plnkr.co/edit/DWqo5vM7iqwzBDd6

Test code

Survey.StylesManager.applyTheme("defaultV2");
var json = {
  "pages": [
    {
      "name": "page1",
      "elements": [
        {
          "type": "rating",
          "name": "nps_score",
          "title": "On a scale of zero to ten, how likely are you to recommend our product to a friend or colleague?",
          "isRequired": true,
          "rateMin": 0,
          "rateMax": 10,
          "minRateDescription": "(Most unlikely)",
          "maxRateDescription": "(Most likely)"
        }, {
          "type": "checkbox",
          "name": "promoter_features",
          "visibleIf": "{nps_score} >= 9",
          "title": "Which of the following features do you value the most?",
          "description": "Please select no more than three features.",
          "isRequired": true,
          "validators": [
            {
              "type": "answercount",
              "text": "Please select no more than three features.",
              "maxCount": 3
            }
          ],
          "hasOther": true,
          "choices": [
            "Performance",
            "Stability",
            "User interface",
            "Complete functionality",
            "Learning materials (documentation, demos, code examples)",
            "Quality support"
          ],
          "otherText": "Other features:",
          "colCount": 2
        }, {
          "type": "comment",
          "name": "passive_experience",
          "visibleIf": "{nps_score} >= 7  and {nps_score} <= 8",
          "title": "What can we do to make your experience more satisfying?"
        }, {
          "type": "comment",
          "name": "disappointing_experience",
          "visibleIf": "{nps_score} <= 6",
          "title": "Please let us know why you had such a disappointing experience with our product"
        }
      ]
    }
  ],
  "completedHtml": "<h3>Thank you for your feedback</h3>",
  "completedHtmlOnCondition": [
    {
      "expression": "{nps_score} >= 9",
      "html": "<h3>Thank you for your feedback</h3> <h4>We are glad that you love our product. Your ideas and suggestions will help us make it even better.</h4>"
    }, {
      "expression": "{nps_score} >= 6  and {nps_score} <= 8",
      "html": "<h3>Thank you for your feedback</h3> <h4>We are glad that you shared your ideas with us. They will help us make our product better.</h4>"
    }
  ],
  "showCompletedPage": false,
  "showQuestionNumbers": "off"
};
window.survey = new SurveyKnockout.Survey(json);

survey.onComplete.add(function (sender, options) {
options.showDataSavingError(error);
});

Specify your

  • browser: N/A
  • browser version: N/A
  • surveyjs platform (angular or react or jquery or knockout or vue): knockout
  • surveyjs version: 1.9.49
Product
survey-library
Type
Enhancement
Description
Vertical Resposivity Manager - calculate items height

refers to surveyjs/survey-creator#3446

Product
survey-library
Type
Enhancement
Description
Add renderedWidth property for survey

Based on calculatedWidthMode

Product
survey-library
Type
Bug
Description
The string "==" in expression returns as "= "

We are replacing "==" in expression vs "= ". We have to fix it.

Product
survey-library
Type
Bug
Description
Tagbox issues in Safari
  • In Safari, there are some problems with the shadow of the pope.

Image

  • After deleting everything, you can observe the following effect - the text is shifted down a little. There is a suspicion that this is a common problem for all editors in Safari, but this has appeared recently.

Image

Run the following example and upload an image to reproduce the issue: image Example.

Original issue: T10708 - File upload - onDownloadFile event triggers multiple time or twice.

Product
survey-library
Type
Bug
Description
Bindings doesn't work correctly after value becomes empty

The binding doesn't work correctly after clearing a binding value in the question. Here is the JSON and the example

{
  elements: [
    {
      type: "dropdown",
      name: "q1",
      choicesMin: 1,
      choicesMax: 10,
    },
    {
      type: "matrixdynamic",
      name: "q2",
      bindings: {
        rowCount: "q1",
      },
      columns: [
        {
          name: "name",
        },
      ],
      cellType: "text",
      allowAddRows: false,
      allowRemoveRows: false,
      rowCount: 0,
    },
  ],
}
Product
survey-library
Type
Enhancement
Description
Support language dialect in localization string

Let's say you have the following title JSON:

{
    default: "Default",
    en: "English",
    "en-UK": "English UK",
    pt: "Portuguese"
  }

For "en-UK" the "English UK" should be used, but for "en-US" and for "pt-BR", "English" and "Portuguese" string should be used. Dialect should check their languages locales first and then check the default locale.

Product
survey-library
Type
Enhancement
Description
Do not allow to start question name with "#" char

We use "#" in expressions to tell SurveyJS do not convert string value into a boolean or numeric. For example {question1} + 10 and {#question1} + 10 could be different if question1 value is string that equals "123". It will return 133 in the first case and "12310" in the second case. However, if the question names as "#question1", then expression engine will look for "question1" and not for "#question1", since "#" is a reserved character.

Product
survey-creator
Type
Bug
Description
Option caption of dropdown not updates
  1. Go to https://surveyjs.io/create-survey
  2. Add dropdown question
  3. Enter Options caption in property grid
  4. ???
  5. Caption isn't updated in designer

P.S. If remove or add any dropdown choice via adorner then caption will update

image

Product
survey-creator
Type
Enhancement
Description
Add separators to Question type converter

image

Product
survey-creator
Type
Enhancement
Description
Creator Toolbox: add non-nominal groups
Product
survey-creator
Type
Bug
Description
`showObjectTitles: true` works only partially for the page navigator
Product
survey-creator
Type
Enhancement
Description
Custom property editors

Are you requesting a feature, reporting a bug or ask a question?

Feature / question

What is the current behavior?

In editor V1 there was an option to implement an editor for a question in the build mode. (For example editing choices for a checkbox type question). It seems this is no longer documented for V2.

My specific case is this exact example: https://surveyjs.io/Documentation/Survey-Creator?id=create-specialized-question-types I've changed it to be a checkbox type instead, see below for code & URL.

What is the expected behavior?

I want some control over whether choices are rendered in the designer. Since in this scenario (using questionJSON with a choicesByUrl set) you already hide the choices configuration from the question properties, it makes sense to not render the "inline" editor.

While I think this should be in the core as a feature, I'm also very interested in a code sample to manually disable such an editor for a custom question type, this should be part of the docs page I mentioned before.

How would you reproduce the current behavior (if this is a bug)?

See URL below.

Provide the test code and the tested page URL (if applicable)

Tested page URL: https://plnkr.co/edit/9htjHDrN3a2oOWJJ

Survey
  .ComponentCollection
  .Instance
  .add({
    // Unique component name. It becomes a new question type. Please note, it should be written in lowercase.
    name: "country",
    // The text that shows on toolbox
    title: "Country",
    // The actual question that will do the job
    questionJSON: {
      type: "checkbox",
      optionsCaption: "Select a country...",
      choicesByUrl: {
        url: "https://surveyjs.io/api/CountriesExample"
      }
    }
  });

Product
survey-creator
Type
Bug
Description
Toolbox jumps when it is grouped by category

Video

This bug can be reproduced in the Toolbox Categories demo.

Product
survey-creator
Type
Enhancement
Description
V2: Support survey.width property

Apply survey width property on designer surface and check css classes for preview.

Product
survey-creator
Type
Bug
Description
[V2] Custom radiogroup component shows adorner choice editing

Are you requesting a feature, reporting a bug or ask a question?

Bug

PS. I worked on this bug before, but can not find it anymore... maybe I never submitted it, maybe I did and this is a duplicate.. If that's the case, apologies!

What is the current behavior?

Creator V2 still shows the adorner allowing editing of choices when it hides the choices in the property grid.

What is the expected behavior?

They should be in sync; if a custom component defines choices and the property grid thus decides to hide this configuration option, the visual editor also should not allow editing choices

How would you reproduce the current behavior (if this is a bug)?

I've provided a plunker.

Provide the test code and the tested page URL (if applicable)

Tested page URL: https://plnkr.co/plunk/SBDqEw9WNCZlwQD4

Specify your

  • browser: Brave / latest
  • editor version: 1.9.45 v2
Product
survey-creator
Type
Bug
Description
The PDF HTML embed disappears on Safari, MacOS

Run the following survey and observe that PDF is not displayed in Creator nor in preview:

{
 "logoPosition": "right",
 "pages": [
  {
   "name": "page1",
   "elements": [
    {
     "type": "html",
     "name": "PDF",
     "html": "<embed src='https://storage.sbg.cloud.ovh.net/v1/AUTH_dd2d546ccf1f4ec68bc7e13d2fb65abf/images/note-information.pdf' height='650px' width='100%'></embed>"
    }
   ]
  },
  {
   "name": "page2",
   "elements": [
    {
     "type": "text",
     "name": "question1"
    }
   ]
  }
 ]
}

https://user-images.githubusercontent.com/22372972/190594937-1a3db653-bd2c-47cc-b2fe-08957bfdb1e1.mov

Product
survey-creator
Type
Bug
Description
We can see the scrollbar on some toolbox heights

Image

Product
survey-creator
Type
Enhancement
Description
Expand/collapse the hierarchy/tree in the JSON Editor

Support expand/collapse JSON nodes in JSON Editor: image

To reproduce the issue, run the Survey Creator | Custom Widgets | React demo in CodeSandbox, and click Add Question. The following exception is thrown:

Uncaught TypeError: Cannot read properties of undefined (reading 'getType')
    at ./src/property-grid/index.ts.PropertyJSONGenerator.createJSON (index.ts:533:28)
    at ./src/property-grid/index.ts.PropertyJSONGenerator.toJSON (index.ts:457:17)
    at ./src/property-grid/index.ts.PropertyJSONGenerator.setupObjPanel (index.ts:470:25)
    at ./src/property-grid/restfull.ts.PropertyGridEditorQuestionRestfull.onCreated (restfull.ts:42:67)
    at Object.onCreated (index.ts:222:11)
    at ./src/property-grid/index.ts.PropertyJSONGenerator.onQuestionsCreated (index.ts:497:36)
    at ./src/property-grid/index.ts.PropertyJSONGenerator.setupObjPanel (index.ts:471:10)
    at ./src/property-grid/index.ts.PropertyGridModel.setObj (index.ts:757:55)
    at PropertyGridModel.set (index.ts:700:10)
    at ./src/creator-base.ts.CreatorBase.selectionChanged (creator-base.ts:2511:36)
    at ./src/creator-base.ts.CreatorBase.selectElement (creator-base.ts:2362:12)
    at ./src/creator-base.ts.CreatorBase.clickToolboxItem (creator-base.ts:2538:12)
    at ./src/creator-base.ts.CreatorBase.addNewQuestionInPage (creator-base.ts:3050:10)
    at descriptor.value [as addNewQuestionInPage] (index.ts:53:40)
    at ./src/components/page.ts.PageAdorner.addNewQuestion (page.ts:108:18)
    at onClick (Page.tsx:102:20)
    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)

CodeSandbox Link. image

This issue was reported at:

Product
survey-creator
Type
Bug
Description
Empty survey crashes creator V2 in "bypage" pageEditMode
Product
survey-creator
Type
Enhancement
Description
Take values for dialect languages from the main language during an export

Let's say you have two languages and two dialects: en - default language, en-uk - dialect, pt - Portugues and pt-br - Brasilian dialect. For CSV export, it makes sense to get strings for en-uk from en (default) and for pt-br from pt.

I expect the Toolbox will preserve the order of items specified in the questionTypes collection. But the order is not changed.

const options = {
  questionTypes: [
  "text", 
  "checkbox", 
  "radiogroup", 
  "dropdown",
  "comment",
  "barrating",
  "ranking",
  "image",
  "boolean"
  ]
};
var creator = new SurveyCreator.SurveyCreator(options);

image

Example.

Product
survey-creator
Type
Enhancement
Description
Add separator to Question Type selector

Image

Product
survey-creator
Type
Enhancement
Description
Basic question edit keyboard interactivity
Product
survey-analytics
Type
Bug
Description
labelTruncateLength doesn't apply its default value

As per docs, the default value of the labelTruncateLength property is 27. However, as you can see in the following plunk, it doesn't apply: https://plnkr.co/edit/xRsyKqvgbwumgsfZ The reason for this is probably a typo on this line: https://github.com/surveyjs/survey-analytics/blob/master/src/visualizerBase.ts#L63

Product
custom-widgets
Type
Bug
Description
Autocomplete widget breaks Creator V2

Property grid raises exception for Creator V2 if autocomplete widget is enabled.

Version: v1.9.50, released at Tuesday, September 20, 2022, Total Issue Count: 6

Product Type Description
survey-library Bug Bug: Search - Items are removed instead of the input textSelect some items and then type an incorrect text.

Press Backspace to remove the text but instead, the items get removed: https://user-images.githubusercontent.com/22372972/189840309-978f0d41-1fdc-4508-b293-c5a02e1c975a.mp4

survey-library Enhancement Dropdown/tagbox : Add the ability to select items by pressing the space bar.
survey-library Enhancement Tagbox: close the popup window after selecting an element
survey-library Bug Image Picker: `getDisplayValue()` returns regular `value` instead of `text`
survey-library Enhancement Add locTitleName and locTooltipName properties into IAction interface

You can use these properties to get strings from localization. For example:

survey.addNavigationItem({
    id: "action1",
    locTitleName: "selectAllItemText",
    locToolTipName: "previewText"
  });

"selectAllItemText" and "previewText" the name of the translated strings: "Select All" and "Preview" in English, "Alles auswählen" and "Vorschau" in Deutsch and so on.

survey-library Bug Radiogroup - The text input box disappears on click if the `storeOthersAsComment` option is disabled

If you disable the storeOthersAsComment option for the Radiogroup question, the 'Other' input box disappears if you start typing: 2022-09-15_12-11-15

The Radiogroup question JSON defintion:

{
          storeOthersAsComment: false,
          type: "radiogroup",
          name: "level_5",
          title: "How long do your headaches last when you get them?",
          colCount: 0,
          hasOther: true,
          otherText: "Other ",
          choices: [
            {
              value: "Hours",
              text: "Hours",
            },
            {
              value: "Days",
              text: "Days",
            },
            {
              value: "Constant",
              text: "Constant",
            },
            {
              value: "Minutes",
              text: "Minutes",
            },
            {
              value: "Seconds",
              text: "Seconds",
            }
          ]          
}

Example.

Source: T10641 - Set Value for Other Comment is not working.

Version: v1.9.50, released at Tuesday, September 20, 2022, Total Issue Count: 6

Press Backspace to remove the text but instead, the items get removed: https://user-images.githubusercontent.com/22372972/189840309-978f0d41-1fdc-4508-b293-c5a02e1c975a.mp4

Product
survey-library
Type
Enhancement
Description
Dropdown/tagbox : Add the ability to select items by pressing the space bar.
Product
survey-library
Type
Enhancement
Description
Tagbox: close the popup window after selecting an element
Product
survey-library
Type
Enhancement
Description
Add locTitleName and locTooltipName properties into IAction interface

You can use these properties to get strings from localization. For example:

survey.addNavigationItem({
    id: "action1",
    locTitleName: "selectAllItemText",
    locToolTipName: "previewText"
  });

"selectAllItemText" and "previewText" the name of the translated strings: "Select All" and "Preview" in English, "Alles auswählen" and "Vorschau" in Deutsch and so on.

If you disable the storeOthersAsComment option for the Radiogroup question, the 'Other' input box disappears if you start typing: 2022-09-15_12-11-15

The Radiogroup question JSON defintion:

{
          storeOthersAsComment: false,
          type: "radiogroup",
          name: "level_5",
          title: "How long do your headaches last when you get them?",
          colCount: 0,
          hasOther: true,
          otherText: "Other ",
          choices: [
            {
              value: "Hours",
              text: "Hours",
            },
            {
              value: "Days",
              text: "Days",
            },
            {
              value: "Constant",
              text: "Constant",
            },
            {
              value: "Minutes",
              text: "Minutes",
            },
            {
              value: "Seconds",
              text: "Seconds",
            }
          ]          
}

Example.

Source: T10641 - Set Value for Other Comment is not working.

Version: v1.9.49, released at Thursday, September 15, 2022, Total Issue Count: 13

Product Type Description
survey-library Enhancement Provide originating question object to onDownloadFile to allow to distinguish questions of the same name

Are you requesting a feature, reporting a bug or asking a question?

Feature

What is the current behavior?

onDownloadFile only providing question name (options.name) but not the question itself unlike onUploadFile and onClearFiles.

When having questions of the same name in different dynamic panels (see example below), you may need to find out the exact question. This works with onUploadFile by getting all parent questions, e. g. page1-panel1-file, and the index of the child panels of all dynamic panels on the way, e. g. page1-panel1[1]-file. This is straightforward when having the originating Question object.

You can circumvent the problem by making the file names globally unique when uploading. But this is like cracking a nut with a sledgehammer.

What is the expected behavior?

onDownloadFile providing the question object additionally just like onUploadFile. Or some other easy way to find the downloading question with the same name.

How would you reproduce the current behavior (if this is a bug)?

Use the Survey below, add two panels per dynamic panel and upload a file for each file question. In onDownloadFile you cannot decide which of the 4 file questions is actually downloading since all are named file.

Provide the test code and the tested page URL (if applicable)

{
 "pages": [
  {
   "name": "page1",
   "elements": [
    {
     "type": "paneldynamic",
     "name": "panel1",
     "templateElements": [
      {
       "type": "file",
       "name": "file1"
      }
     ]
    },
    {
     "type": "paneldynamic",
     "name": "panel2",
     "templateElements": [
      {
       "type": "file",
       "name": "file1"
      }
     ]
    }
   ]
  }
 ]
}

Specify your

  • browser: not applicable
  • browser version: not applicable
  • surveyjs platform (angular or react or jquery or knockout or vue): jquery
  • surveyjs version: 1.9.45
survey-library Enhancement checkAndSetPropertyValue and setPropertyValue methods seem to duplicate functionality

The checkAndSetPropertyValue description says that the only difference between this and the setPropertyValue method is the onSettingValue function execution, and when this function is not specified, both methods work identically. However, onSettingValue isn't specified by default in most questions, which means that it is never executed when it is unneeded, and this means that there's no need to have two methods: we can keep the checkAndSetPropertyValue method only (and rename it to setPropertyValue).

survey-library Bug Creator V1: survey should raise onQuestionAdded during drag&drop

survey should raise onQuestionAdded on dragging question to work correct in Creator V1. We should raise it if there is no drag&drop or survey is on designer surface in Creator V1.

survey-library Bug React: progressBarType equals to "requiredQuestions" doesn't work

There is a typo in component registration in react and since we did not have any functional tests on progressBarType equals to "requiredQuestions" we did not see the issue. e2e tests are added and the type is fixed.

survey-library Bug The survey.getPanelByName method returns an IPanel object which doesn't contain the `no` property

I want to access the PanelModel.no property and call the survey.getPanelByName function. However, this method returns an IPanel object which doesn't contain the no property.

survey-library Enhancement Add uniquePropertyName for JSON property

We need to set this property to "value" for "rows"/"columns" proprties for matrices. It will be used in Creator V2 and do not allow to set non-unique values for these properties.

survey-creator Enhancement onConditionQuestionsGetList has a forced questions list sorting

onConditionQuestionsGetList event allows us to modify the questions list appearing in logic panel, but after callback the creator has a hardcoded list.sort which can't be avoided. To deal with this scenarion, a new attribute "options.sortOrder" has been added. It has two options: "asc" (default) and "none". Change it to "none", if you don't want to sort your condition list`.

survey-creator Bug Survey Creator doesn't prevent users from specifying the same name for question items thus producing incorrect question results

In Survey Creator, it is possible to specify identical names for items or columns/rows for the following question types:

  • Single-Choice Matrix
  • Drop-down
  • Radiogroup
  • Checkbox

This produces incorrect results. Refer to the example below. Single-Choice Matrix setup: image The result: sameColumnNameIssue

Check this sample.

The creator should prevent uses from specifying identical names for these items. For example, this is how it's done for Multiple-Choice Matrix: image

survey-creator Bug Knockout V1 - Reorder questions using drag&drop changes property box element to Survey

Are you requesting a feature, reporting a bug or ask a question?

BUG

What is the current behavior?

**V1 Knockout - survey creator:

  1. Add at least 3 questions.

  2. Choose one and reorder it (using drag&drop) -> See Drop-Down elements > Selected element changed to Survey (in the property box dropdonw elements)

  3. Click on another question

  4. Click on the question that you dragged

5 . When selecting the question you dragged, the property box does not update and the user changes the survey property thinking they are changing the question.**

What is the expected behavior?

Reorder the question using drag and drop > when clicking on the question you dragged, the property box should show the properties for that question.

How would you reproduce the current behavior (if this is a bug)?

**V1 Knockout - survey creator:

  1. Add at least 3 questions.

  2. Choose one and reorder it (using drag&drop) -> See Drop-Down elements > Selected element changed to Survey (in the property box dropdonw elements)

  3. Click on another question

  4. Click on the question that you dragged

5 . When selecting the question you dragged, the property box does not update and the user changes the survey property thinking they are changing the question.**

Provide the test code and the tested page URL (if applicable)

Tested page URL:

Survey Creator V1

Test code

your_code_here

Specify your

  • browser: EDGE and Chrome
  • editor version: Survey Creator - V1
survey-creator Enhancement V2: Add options.reason into onQuestionAdded event

There is no way to know how questions has been added, via toolbox or user click on "Add question" on the bottom of the page or via duplicate question/page.

survey-creator Enhancement Expand Property Grid "General" category for all elements except empty survey

If there is not focused property then expand the "General" category. Do not expand any category by default for an empty survey. To disable this functionality please add the following line: SurveyCreator.settings.propertyGrid.defaultExpandedTabName = "";

survey-creator Bug V2: add property, choices from server call with undefined choicesCallback

On defining a new property with attribute choices with a choicesCallback function, choicesCallback can be undefined choices: function (obj, choicesCallback) {.... choicesCallback should not be undefined.

survey-creator Bug The Logic tab - Cannot rename questions within the Select Question drop-down list

I want to add indices to questions in the Logic tab. I handled the creator.onGetObjectDisplayName function and successfully updated the options.displayName to display a question index in the Select... drop-down. image

However, question display names were not updated for the Select Question drop-down: image Example.

Version: v1.9.49, released at Thursday, September 15, 2022, Total Issue Count: 13

Are you requesting a feature, reporting a bug or asking a question?

Feature

What is the current behavior?

onDownloadFile only providing question name (options.name) but not the question itself unlike onUploadFile and onClearFiles.

When having questions of the same name in different dynamic panels (see example below), you may need to find out the exact question. This works with onUploadFile by getting all parent questions, e. g. page1-panel1-file, and the index of the child panels of all dynamic panels on the way, e. g. page1-panel1[1]-file. This is straightforward when having the originating Question object.

You can circumvent the problem by making the file names globally unique when uploading. But this is like cracking a nut with a sledgehammer.

What is the expected behavior?

onDownloadFile providing the question object additionally just like onUploadFile. Or some other easy way to find the downloading question with the same name.

How would you reproduce the current behavior (if this is a bug)?

Use the Survey below, add two panels per dynamic panel and upload a file for each file question. In onDownloadFile you cannot decide which of the 4 file questions is actually downloading since all are named file.

Provide the test code and the tested page URL (if applicable)

{
 "pages": [
  {
   "name": "page1",
   "elements": [
    {
     "type": "paneldynamic",
     "name": "panel1",
     "templateElements": [
      {
       "type": "file",
       "name": "file1"
      }
     ]
    },
    {
     "type": "paneldynamic",
     "name": "panel2",
     "templateElements": [
      {
       "type": "file",
       "name": "file1"
      }
     ]
    }
   ]
  }
 ]
}

Specify your

  • browser: not applicable
  • browser version: not applicable
  • surveyjs platform (angular or react or jquery or knockout or vue): jquery
  • surveyjs version: 1.9.45

The checkAndSetPropertyValue description says that the only difference between this and the setPropertyValue method is the onSettingValue function execution, and when this function is not specified, both methods work identically. However, onSettingValue isn't specified by default in most questions, which means that it is never executed when it is unneeded, and this means that there's no need to have two methods: we can keep the checkAndSetPropertyValue method only (and rename it to setPropertyValue).

Product
survey-library
Type
Bug
Description
Creator V1: survey should raise onQuestionAdded during drag&drop

survey should raise onQuestionAdded on dragging question to work correct in Creator V1. We should raise it if there is no drag&drop or survey is on designer surface in Creator V1.

Product
survey-library
Type
Bug
Description
React: progressBarType equals to "requiredQuestions" doesn't work

There is a typo in component registration in react and since we did not have any functional tests on progressBarType equals to "requiredQuestions" we did not see the issue. e2e tests are added and the type is fixed.

I want to access the PanelModel.no property and call the survey.getPanelByName function. However, this method returns an IPanel object which doesn't contain the no property.

Product
survey-library
Type
Enhancement
Description
Add uniquePropertyName for JSON property

We need to set this property to "value" for "rows"/"columns" proprties for matrices. It will be used in Creator V2 and do not allow to set non-unique values for these properties.

Product
survey-creator
Type
Enhancement
Description
onConditionQuestionsGetList has a forced questions list sorting

onConditionQuestionsGetList event allows us to modify the questions list appearing in logic panel, but after callback the creator has a hardcoded list.sort which can't be avoided. To deal with this scenarion, a new attribute "options.sortOrder" has been added. It has two options: "asc" (default) and "none". Change it to "none", if you don't want to sort your condition list`.

In Survey Creator, it is possible to specify identical names for items or columns/rows for the following question types:

  • Single-Choice Matrix
  • Drop-down
  • Radiogroup
  • Checkbox

This produces incorrect results. Refer to the example below. Single-Choice Matrix setup: image The result: sameColumnNameIssue

Check this sample.

The creator should prevent uses from specifying identical names for these items. For example, this is how it's done for Multiple-Choice Matrix: image

Are you requesting a feature, reporting a bug or ask a question?

BUG

What is the current behavior?

**V1 Knockout - survey creator:

  1. Add at least 3 questions.

  2. Choose one and reorder it (using drag&drop) -> See Drop-Down elements > Selected element changed to Survey (in the property box dropdonw elements)

  3. Click on another question

  4. Click on the question that you dragged

5 . When selecting the question you dragged, the property box does not update and the user changes the survey property thinking they are changing the question.**

What is the expected behavior?

Reorder the question using drag and drop > when clicking on the question you dragged, the property box should show the properties for that question.

How would you reproduce the current behavior (if this is a bug)?

**V1 Knockout - survey creator:

  1. Add at least 3 questions.

  2. Choose one and reorder it (using drag&drop) -> See Drop-Down elements > Selected element changed to Survey (in the property box dropdonw elements)

  3. Click on another question

  4. Click on the question that you dragged

5 . When selecting the question you dragged, the property box does not update and the user changes the survey property thinking they are changing the question.**

Provide the test code and the tested page URL (if applicable)

Tested page URL:

Survey Creator V1

Test code

your_code_here

Specify your

  • browser: EDGE and Chrome
  • editor version: Survey Creator - V1
Product
survey-creator
Type
Enhancement
Description
V2: Add options.reason into onQuestionAdded event

There is no way to know how questions has been added, via toolbox or user click on "Add question" on the bottom of the page or via duplicate question/page.

Product
survey-creator
Type
Enhancement
Description
Expand Property Grid "General" category for all elements except empty survey

If there is not focused property then expand the "General" category. Do not expand any category by default for an empty survey. To disable this functionality please add the following line: SurveyCreator.settings.propertyGrid.defaultExpandedTabName = "";

On defining a new property with attribute choices with a choicesCallback function, choicesCallback can be undefined choices: function (obj, choicesCallback) {.... choicesCallback should not be undefined.

I want to add indices to questions in the Logic tab. I handled the creator.onGetObjectDisplayName function and successfully updated the options.displayName to display a question index in the Select... drop-down. image

However, question display names were not updated for the Select Question drop-down: image Example.

Version: v1.9.48, released at Thursday, September 8, 2022, Total Issue Count: 8

Product Type Description
survey-library Enhancement Get rid of SurveyModel (core class) modifications in survey-knockout library

We need to remove this and similar code from our project:

SurveyModel.prototype["onCreating"] = function() {
  this.implementor = new SurveyImplementor(this);
};
SurveyModel.prototype["render"] = function(element: any = null) {
  this.implementor.render(element);
};
SurveyModel.prototype["getHtmlTemplate"] = function(): string {
  return koTemplate;
};

This allow as to use survey-creator (V2 as well as V1) with angular and vue projects

survey-library Bug ProcessedText functionality doesn't work correctly with checkox vs valuePropertyName feature

If you have the following JSON:

      {
        type: "checkbox",
        name: "q1",
        choices: [{ value: 1, text: "apple" }, { value: 2, text: "banana" }, { value: 3, text: "orange" }],
        valueName: "data1",
        valuePropertyName: "fruit",
        hasOther: true
      }

Then accessing {data1[0].fruit} will return value (1, 2, 3) instead of text ("apple", "banana", "orange")

survey-library Bug JavaScript error is raised if set incorrect defaultValueExpression for matrix dropdown

Matrix dropdown expects an object as a value. On setting a number or string value a JavaScript error will be generated. Here is the example of incorrect JSON:

{
    elements: [
      {
        type: "matrixdropdown",
        name: "matrix",
        defaultValueExpression: "no",
        columns: [
          {
            name: "col1",
          },
        ],
        rows: [
          "row 1",
          "row 2",
        ]
      },
    ],
  }

Currently on loading this JSON JavaScript error is generated and Survey model is failed to loaded.

survey-library Bug Page Description is not applied in a non-default locale if the Description is empty in the Default locale

The following JSON doesn't work correctly if changing survey locale after the survey is rendered:

{
    pages: [{
      name: "page1",
      title: "Page title",
      description: {
        "de": "desc"
      },
      elements: [{
        type: "text",
        name: "q1",
        description: {
          "de": "desc"
        },
      }]
    }]
  }

We do not update hasDescription reactive property on changing locale.

survey-creator Enhancement `onGetObjectDisplayName`: Rename `options.reason` enum values

Suggested variant:

options.area: 
"condition-popup"
"preview-tab:page-list"
"preview-tab:selected-page"
"translation-tab"
"property-grid:property-editor"
"property-grid-header:element-list"
"property-grid-header:selected-element"
survey-creator Enhancement Allow to create a custom survey serialization

Allow to create an alternative serilization for survey. It is needed, when SurveyJS Creator is used to create the JSON form definition that can be used later to generate UI form based on non SurveyJS widgets, for example, for a desktop platform.

A new callback has been added into Serializer: Serializer.onSerializingProperty = (obj: Base, prop: JsonObjectProperty, value: any, json: any): boolean.

Here is the example of using it.

  const mapping : any = {
    base: { elements: "Questions", visible: { name: "IsHidden", converter: (obj: Base, value: any): any => { return !value; } } },
    question: { choices: "AnswerOptions" },
    survey: { title: "Name", pages: "sections" }
  };
  const getMappedObj = function(type: string, name: string): string {
    const typeMap = mapping[type];
    return !!typeMap ? typeMap[name] : undefined;
  };
  Serializer.onSerializingProperty = (obj: Base, prop: JsonObjectProperty, value: any, json: any): boolean => {
    let typesList = new Array<string>();
    typesList.push(obj.getType());
    if(obj.isDescendantOf("question")) {
      typesList.push("question");
    }
    typesList.push("base");

    for(var i = 0; i < typesList.length; i ++) {
      let mapObj = <any>getMappedObj(typesList[i], prop.name);
      if(!mapObj) continue;
      const name = typeof mapObj === "string" ? mapObj : mapObj.name;
      if(typeof mapObj !== "string" && mapObj.converter) {
        value = mapObj.converter(obj, value);
      }
      json[name] = value;
      return true;
    }
    return false;
  };

Original Question

I would like to change the format of the json outputted by the survey creator. Is this possible.

Thanks for your help.

survey-creator Enhancement Add validateValue function into PropertyEditor inteface for custom property editors

There is no easy way to add a validation for a custom property editor. We should add a new validateValue function to make it easy to implement this fuctionality. Consider, you want to implement a new "email" property type and you want to validate the entered value. It should be as easy as the following:

SurveyCreator.PropertyGridEditorCollection.register({
    //Apply for all properties with type "email"
    fit: function (prop) {
      return prop.type === "email";
    },
    //It is a text question type and we update the value on blur only
    getJSON: function (obj, prop, options) {
      return { type: "text", textUpdateMode: "onBlur" };
    },
   //Return error string if the email is incorrect and otherwise return empty string.
    validateValue: function(obj, question, prop, value: any): string {
      if(!value) return "";
      const valid = /^(([^<>()[\]\\.,;:\s@"]+(\.[^<>()[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/.test(value);
      return !valid ? "Incorrect email" : "";
    }
  }
);

You can write the following code to add a new property:

Survey.Serializer.addProperty("survey", { name: "sentTo", type: "email" });
survey-creator Bug Columns in translation tab are not refreshed when a new Survey is loaded to the Creator

Please run this example and activate the Translation tab. Add some languages. Uncheck them to exclude them from the survey definition. Click the 'Reset' button: it will load a default JSON to the creator:

creator.JSON = defaultJSON

Notice that the Translation tab keeps displaying custom translations checked. https://user-images.githubusercontent.com/22372972/188459543-aad73f70-ebdf-4c99-91f3-6a797c2fc0ad.mp4

Expected behavior: the Translation tab doesn't display unchecked translations when resetting the survey.

Version: v1.9.48, released at Thursday, September 8, 2022, Total Issue Count: 8

Product
survey-library
Type
Enhancement
Description
Get rid of SurveyModel (core class) modifications in survey-knockout library

We need to remove this and similar code from our project:

SurveyModel.prototype["onCreating"] = function() {
  this.implementor = new SurveyImplementor(this);
};
SurveyModel.prototype["render"] = function(element: any = null) {
  this.implementor.render(element);
};
SurveyModel.prototype["getHtmlTemplate"] = function(): string {
  return koTemplate;
};

This allow as to use survey-creator (V2 as well as V1) with angular and vue projects

If you have the following JSON:

      {
        type: "checkbox",
        name: "q1",
        choices: [{ value: 1, text: "apple" }, { value: 2, text: "banana" }, { value: 3, text: "orange" }],
        valueName: "data1",
        valuePropertyName: "fruit",
        hasOther: true
      }

Then accessing {data1[0].fruit} will return value (1, 2, 3) instead of text ("apple", "banana", "orange")

Matrix dropdown expects an object as a value. On setting a number or string value a JavaScript error will be generated. Here is the example of incorrect JSON:

{
    elements: [
      {
        type: "matrixdropdown",
        name: "matrix",
        defaultValueExpression: "no",
        columns: [
          {
            name: "col1",
          },
        ],
        rows: [
          "row 1",
          "row 2",
        ]
      },
    ],
  }

Currently on loading this JSON JavaScript error is generated and Survey model is failed to loaded.

The following JSON doesn't work correctly if changing survey locale after the survey is rendered:

{
    pages: [{
      name: "page1",
      title: "Page title",
      description: {
        "de": "desc"
      },
      elements: [{
        type: "text",
        name: "q1",
        description: {
          "de": "desc"
        },
      }]
    }]
  }

We do not update hasDescription reactive property on changing locale.

Product
survey-creator
Type
Enhancement
Description
`onGetObjectDisplayName`: Rename `options.reason` enum values

Suggested variant:

options.area: 
"condition-popup"
"preview-tab:page-list"
"preview-tab:selected-page"
"translation-tab"
"property-grid:property-editor"
"property-grid-header:element-list"
"property-grid-header:selected-element"
Product
survey-creator
Type
Enhancement
Description
Allow to create a custom survey serialization

Allow to create an alternative serilization for survey. It is needed, when SurveyJS Creator is used to create the JSON form definition that can be used later to generate UI form based on non SurveyJS widgets, for example, for a desktop platform.

A new callback has been added into Serializer: Serializer.onSerializingProperty = (obj: Base, prop: JsonObjectProperty, value: any, json: any): boolean.

Here is the example of using it.

  const mapping : any = {
    base: { elements: "Questions", visible: { name: "IsHidden", converter: (obj: Base, value: any): any => { return !value; } } },
    question: { choices: "AnswerOptions" },
    survey: { title: "Name", pages: "sections" }
  };
  const getMappedObj = function(type: string, name: string): string {
    const typeMap = mapping[type];
    return !!typeMap ? typeMap[name] : undefined;
  };
  Serializer.onSerializingProperty = (obj: Base, prop: JsonObjectProperty, value: any, json: any): boolean => {
    let typesList = new Array<string>();
    typesList.push(obj.getType());
    if(obj.isDescendantOf("question")) {
      typesList.push("question");
    }
    typesList.push("base");

    for(var i = 0; i < typesList.length; i ++) {
      let mapObj = <any>getMappedObj(typesList[i], prop.name);
      if(!mapObj) continue;
      const name = typeof mapObj === "string" ? mapObj : mapObj.name;
      if(typeof mapObj !== "string" && mapObj.converter) {
        value = mapObj.converter(obj, value);
      }
      json[name] = value;
      return true;
    }
    return false;
  };

Original Question

I would like to change the format of the json outputted by the survey creator. Is this possible.

Thanks for your help.

There is no easy way to add a validation for a custom property editor. We should add a new validateValue function to make it easy to implement this fuctionality. Consider, you want to implement a new "email" property type and you want to validate the entered value. It should be as easy as the following:

SurveyCreator.PropertyGridEditorCollection.register({
    //Apply for all properties with type "email"
    fit: function (prop) {
      return prop.type === "email";
    },
    //It is a text question type and we update the value on blur only
    getJSON: function (obj, prop, options) {
      return { type: "text", textUpdateMode: "onBlur" };
    },
   //Return error string if the email is incorrect and otherwise return empty string.
    validateValue: function(obj, question, prop, value: any): string {
      if(!value) return "";
      const valid = /^(([^<>()[\]\\.,;:\s@"]+(\.[^<>()[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/.test(value);
      return !valid ? "Incorrect email" : "";
    }
  }
);

You can write the following code to add a new property:

Survey.Serializer.addProperty("survey", { name: "sentTo", type: "email" });

Please run this example and activate the Translation tab. Add some languages. Uncheck them to exclude them from the survey definition. Click the 'Reset' button: it will load a default JSON to the creator:

creator.JSON = defaultJSON

Notice that the Translation tab keeps displaying custom translations checked. https://user-images.githubusercontent.com/22372972/188459543-aad73f70-ebdf-4c99-91f3-6a797c2fc0ad.mp4

Expected behavior: the Translation tab doesn't display unchecked translations when resetting the survey.

Version: v1.9.47, released at Wednesday, August 31, 2022, Total Issue Count: 7

Product Type Description
survey-library Bug Dropdown (v1.9.40): Caret down disappears, wrong font for dropdown items

Are you requesting a feature, reporting a bug or asking a question?

bug

What is the current behavior?

in this example I noticed 2 weird things while using bootstrap theme (starting from version 1.9.40)

  1. the rightmost caret down disappeared
  2. font used in listed items is wrong (Open Sans)

thank you

survey-library BreakingChange Change dropdown placeholder string from "Choose..." to "Select..."

The correct text for dropdown placeholder is "Select...". We have to rename it.

survey-library Bug Svg-img-alt: Ensures <svg> elements with an img, graphics-document or graphics-symbol role have an accessible text

image

survey-library Enhancement angular-ui: Implement PopupSurvey functionality

We missed PopupSurvey functionality in angular-ui because we do not have any e2e tests on it. We have to add a new functional tests for PopupSurvey and implement it for angular-ui.

survey-library Bug Expression properties added to Survey don't work

Are you requesting a feature, reporting a bug or asking a question?

Bug

What is the current behavior?

Custom properties of type condition or expression do not have their onExecuteExpression called when they are attached to the survey.

What is the expected behavior?

It should either work, or fail during setup.

How would you reproduce the current behavior (if this is a bug)?

I've created a plunker that adds a property to questions and to survey.

It shows that it is working for questions (try changing the rating value). But the exact same code is not working for the property added to the survey.

Provide the test code and the tested page URL (if applicable)

Tested page URL: https://plnkr.co/edit/EijsTFbFTZD9jC8B

Specify your

  • browser: N/A
  • browser version: N/A
  • surveyjs platform (angular or react or jquery or knockout or vue): knockout
  • surveyjs version: latest
survey-creator Bug Incorrect style for help/description of "Run expression" property for the trigger

Description renders in one line for "Run Expression" property in the trigger (survey settings). It renders correctly for questions. image

survey-creator Bug V2: Embedded tab, use "defaultV2" theme by default

We currently offer "modern" theme by default, while we have to set "defaultV2" by default.

Version: v1.9.47, released at Wednesday, August 31, 2022, Total Issue Count: 7

Are you requesting a feature, reporting a bug or asking a question?

bug

What is the current behavior?

in this example I noticed 2 weird things while using bootstrap theme (starting from version 1.9.40)

  1. the rightmost caret down disappeared
  2. font used in listed items is wrong (Open Sans)

thank you

Product
survey-library
Type
BreakingChange
Description
Change dropdown placeholder string from "Choose..." to "Select..."

The correct text for dropdown placeholder is "Select...". We have to rename it.

image

Product
survey-library
Type
Enhancement
Description
angular-ui: Implement PopupSurvey functionality

We missed PopupSurvey functionality in angular-ui because we do not have any e2e tests on it. We have to add a new functional tests for PopupSurvey and implement it for angular-ui.

Product
survey-library
Type
Bug
Description
Expression properties added to Survey don't work

Are you requesting a feature, reporting a bug or asking a question?

Bug

What is the current behavior?

Custom properties of type condition or expression do not have their onExecuteExpression called when they are attached to the survey.

What is the expected behavior?

It should either work, or fail during setup.

How would you reproduce the current behavior (if this is a bug)?

I've created a plunker that adds a property to questions and to survey.

It shows that it is working for questions (try changing the rating value). But the exact same code is not working for the property added to the survey.

Provide the test code and the tested page URL (if applicable)

Tested page URL: https://plnkr.co/edit/EijsTFbFTZD9jC8B

Specify your

  • browser: N/A
  • browser version: N/A
  • surveyjs platform (angular or react or jquery or knockout or vue): knockout
  • surveyjs version: latest

Description renders in one line for "Run Expression" property in the trigger (survey settings). It renders correctly for questions. image

Product
survey-creator
Type
Bug
Description
V2: Embedded tab, use "defaultV2" theme by default

We currently offer "modern" theme by default, while we have to set "defaultV2" by default.

Version: v1.9.46, released at Tuesday, August 23, 2022, Total Issue Count: 12

Product Type Description
survey-library Enhancement ListModel: show placeholder if there are no elements

Example image

survey-library Bug hasOther and showInMultipleColumns options in matrix column doesn't work correctly

Are you requesting a feature, reporting a bug or asking a question?

Bug

What is the current behavior?

When configuring a column in a matrixdropdown question to have an other option the text box is not shown when using the "show in multiple columns" option.

What is the expected behavior?

It should either work, or not be available as an option in the survey builder.

How would you reproduce the current behavior (if this is a bug)?

Provide the test code and the tested page URL (if applicable)

Tested page URL: https://surveyjs.io/create-survey

Test code

{
 "logoPosition": "right",
 "pages": [
  {
   "name": "page1",
   "elements": [
    {
     "type": "matrixdropdown",
     "name": "V001",
     "title": "Testvraag",
     "columns": [
      {
       "name": "1",
       "title": " ",
       "cellType": "checkbox",
       "showInMultipleColumns": true,
       "choices": [
        {
         "value": "1",
         "text": "Antwoord A"
        },
        {
         "value": "2",
         "text": "Antwoord B"
        },
        {
         "value": "3",
         "text": "Antwoord C"
        }
       ],
       "hasOther": true,
       "noneText": "Geen van bovenstaande",
       "otherText": "Anders, namelijk:"
      }
     ],
     "choices": [
      1,
      2,
      3,
      4,
      5
     ],
     "rows": [
      {
       "value": "1",
       "text": "Aspect A"
      },
      {
       "value": "2",
       "text": "Aspect B"
      }
     ]
    }
   ]
  }
 ],
 "questionsOnPageMode": "questionPerPage"
}

Specify your

survey-library Bug setObjPropertyValue function JSONPropery class doens't work correctly for setting arrays.

The following code works incorrectly. It leads to errors in Creator V2. Here is the related issue

  Survey.Serializer.addProperty("question", { name: "tagbox:set", choices: [1, 2, 3, 4] });
  const question = new Survey.QuestionText("q1");
  const val = [1, 2];
  Serializer.setObjPropertyValue(question, "tagbox", val);
  //question.tagbox equals to [1, 2] now
  val.splice(0, 1);
  //question.tagbox equals to [2] now, but it should not be changed.
survey-library Bug A question dropdown selection is reset when using row count bindings and `cellType` expression

With the following survey expression, the question 1 dropdown selection is reset when checking an item for question 3.

{
 "logoPosition": "right",
 "pages": [
  {
   "name": "page1",
   "elements": [
    {
     "type": "paneldynamic",
     "name": "question",
     "templateElements": [
      {
       "type": "panel",
       "name": "panel1",
       "elements": [
        {
         "type": "dropdown",
         "name": "question1",
         "choicesMin": 1,
         "choicesMax": 5
        },
        {
         "type": "matrixdynamic",
         "name": "question2",
         "bindings": {
          "rowCount": "question1"
         },
         "columns": [
          {
           "name": "Column 1",
           "cellType": "expression",
           "expression": "'Row ' + {rowIndex}"
          },
          {
           "name": "Column 2"
          },
          {
           "name": "Column 3"
          }
         ],
         "choices": [
          1,
          2,
          3,
          4,
          5
         ],
         "allowAddRows": false,
         "allowRemoveRows": false,
         "rowCount": 0
        }
       ]
      },
      {
       "type": "checkbox",
       "name": "question3",
       "choices": [
        "item1",
        "item2",
        "item3"
       ]
      }
     ],
     "allowAddPanel": false,
     "allowRemovePanel": false,
     "panelCount": 1
    },
    {
     "type": "panel",
     "name": "panel2"
    }
   ]
  }
 ]
}

A complete sample is available at https://plnkr.co/edit/blLZR0Qy5u3K1DKh.

Attachments DemoT10358.mp4.

https://user-images.githubusercontent.com/22372972/184880372-13641448-4da4-4df4-a35b-ebc3047397a5.mp4

The issue has been originally reported at T10358 - rowCount issue in DynamicMatrix when using expressions in columns.

survey-library Enhancement Add survey.width property

You can have one container for different surveys and these diffefrent surveys require to set a different width to look good. We need to apply this property, if it is set, to a root div.

survey-library Bug Deleting a first element in the panel/page row works incorrectly

We have to set "startWithNewLine" to true for the second element in the row on deleting the first element. Otherwise on loading updated survey JSON the row joins with the preivous row. It leads to error in Creator. Here is the Creator issue

survey-library Bug "First page is a start page" breaks navigation in survey with conditionally shown pages

Are you requesting a feature, reporting a bug or asking a question?

Bug

What is the current behavior?

1.9.45

What is the expected behavior?

Page (a first one) should be shown

How would you reproduce the current behavior (if this is a bug)?

Create a survey:

  1. with 2 pages: p1 and p2
  2. with 2 questions on the first page: q1 and q2
  3. have a rule: if q1=yes, then show q2
  4. have a rule: if q2=yes, then show p2
  5. (important) set firstPageIsStarted: true
  6. run surveys ERROR: it says "There is no visible page or question in the survey." EXPECTED: p1 with q1 should be shown (there is nothing preventing them from showing)

Provide the test code and the tested page URL (if applicable)

Tested page URL: https://surveyjs.io/published?id=078a2c6e-1125-4b6f-a82f-bed3d067cb3b

Test code

{
 logoPosition: "right",
 pages: [
  {
   name: "page1",
   elements: [
    {
     type: "radiogroup",
     name: "question1",
     choices: [
      {
       value: "1",
       text: "Yes"
      },
      {
       value: "0",
       text: "No"
      }
     ]
    },
    {
     type: "radiogroup",
     name: "question2",
     visibleIf: "{question1} = 1",
     title: "question2",
     choices: [
      {
       value: "1",
       text: "Yes"
      },
      {
       value: "0",
       text: "No"
      }
     ]
    }
   ]
  },
  {
   name: "page2",
   elements: [
    {
     type: "text",
     name: "question3"
    }
   ],
   visibleIf: "{question2} = 1"
  },
  {
   name: "page3"
  }
 ],
 clearInvisibleValues: "onHiddenContainer",
 firstPageIsStarted: true
}

Specify your

  • browser: Opera
  • browser version: 89.0.4447.83
  • surveyjs platform (angular or react or jquery or knockout or vue): ReactJS, but it doesn't matter
  • surveyjs version: 1.9.45
survey-library Enhancement Add survey.onDynamicPanelRemoving event

We have onMatrixRowRemoving but we do not have similar event for dynamic panel.

  /**
   * The event is fired before removing a panel from Panel Dynamic question. You can disable removing and optionally clear the data instead.
   *- `sender` - the survey object that fires the event.
   *- `options.question` - a panel question.
   *- `options.panelIndex` - a removed panel index.
   *- `options.panel` - a removed panel.
   *- `options.allow` - a boolean property. Set it to `false` to disable the panel removing.
   * @see QuestionPanelDynamicModel
   * @see QuestionPanelDynamicModel.panels
   * @see onDynamicPanelRemoved
   */
   public onDynamicPanelRemoving: EventBase<SurveyModel> = this.addEvent<SurveyModel>();

survey-creator Enhancement Extending itemValue leads to weird behavior

Are you requesting a feature, reporting a bug or ask a question?

Bug / feature

I'm trying to extend the item value class in the creator only. Imagine that I have a multiple choice question type, but for each choice I want the person creator to also specify another property.

For example say we have a list of car models including brand, car models are often classified in rough categories as well.

  • Tesla Model 3 -- Mid-Size
  • Tesla Model X -- Large
  • Mini Cooper -- Minicompact

The goal here is to use this information during analysis, it doesn't need to go in the survey data, but the survey creator should be able to store it.

What is the current behavior?

The survey creator renders the configuration for the choices fine: image (Ignore the clipping of values for now)

But it doesn't load it from the JSON.

What is the expected behavior?

Extending the itemvalue class should either work or explicitly be forbidden.

How would you reproduce the current behavior (if this is a bug)?

https://plnkr.co/edit/rsYMrS9rUDhoSnlI

Provide the test code and the tested page URL (if applicable)

Tested page URL: https://plnkr.co/edit/rsYMrS9rUDhoSnlI

Test code

// New question type for facility type:
  const widgetName = 'facilitytype'
  const facilityQuestionType = {
    name: widgetName,
    title: 'Facility Type',
    iconName: 'icon-radiogroup',
    category: 'HeRAMS',
    isFit (question) {
      return question.getType() === widgetName
    },
    isDefaultRender: true,

    widgetIsLoaded () {
      return true
    },

    init () {
      Survey.Serializer.addClass('facilityitemvalue', [
        {
          name: 'tier',
          displayName: 'Tier',
          choices: ['primary', 'secondary', 'tertiary'],
          default: 'primary'
        }, {
          name: 'text'
        }
      ], null, 'itemvalue')

      Survey.Serializer.addClass(widgetName, [
        {
          name: 'choices',
          type: 'facilityitemvalue[]'

        },
        {
          name: 'choicesFromQuestion',
          visible: false
        },
        {
          name: 'hasOther',
          visible: false
        },
        {
          name: 'hasNone',
          visible: false
        }
      ], null, 'radiogroup')
    },
    afterRender (question, el) {

    }

  }

  Survey.CustomWidgetCollection.Instance.add(facilityQuestionType, 'customtype')

Specify your

  • browser: Brave latest
  • editor version: 1.9.36
survey-creator Bug survey creator tagbox property does not save all questions changes

Are you requesting a feature, reporting a bug or ask a question?

reporting a bug

What is the current behavior?

When adding a tagbox property to question in survery creator, GUI will only save the latest tagged question, and removes the previous tagged questions that was done before.

What is the expected behavior?

All edited questions that gets tagged with tagbox should keep their tags repectively

How would you reproduce the current behavior (if this is a bug)?

Add a tagbox property to the creator instance like so:

Survey.Serializer.addProperty("question", {
            name: "tagbox:set",
            choices: ["one", "two", "three"],
            category: "general"
});

Then try to edit a question and add a tag to the question from the general tab in right property pane of the question, and without saving continue to add a tag to another question , then inspect the JSON preview, only the last edited question gets a tagbox property.

Screenshot_7

Here is a plunker: https://plnkr.co/edit/qighGGf3uvvIxais

Provide the test code and the tested page URL (if applicable)

Tested page URL: https://plnkr.co/edit/qighGGf3uvvIxais

Test code

Survey.Serializer.addProperty("question", {
            name: "tagbox:set",
            choices: ["one", "two", "three"],
            category: "general"
});

Specify your

  • browser: Firefox and chrome
  • editor version: latest
survey-creator Enhancement Drag Indicator

Let's make all drag indicators are similar. They are... — question https://www.figma.com/file/7QOeoDDCaPuqzWAROR0kDY/SJS-Creator?node-id=2217%3A24

— property grid list https://www.figma.com/file/7QOeoDDCaPuqzWAROR0kDY/SJS-Creator?node-id=10957%3A99134

— image (already) — any lists (already)

survey-creator Bug It is not possible to add a question from the toolbox popup.

Version: v1.9.46, released at Tuesday, August 23, 2022, Total Issue Count: 12

Product
survey-library
Type
Enhancement
Description
ListModel: show placeholder if there are no elements

Example image

Are you requesting a feature, reporting a bug or asking a question?

Bug

What is the current behavior?

When configuring a column in a matrixdropdown question to have an other option the text box is not shown when using the "show in multiple columns" option.

What is the expected behavior?

It should either work, or not be available as an option in the survey builder.

How would you reproduce the current behavior (if this is a bug)?

Provide the test code and the tested page URL (if applicable)

Tested page URL: https://surveyjs.io/create-survey

Test code

{
 "logoPosition": "right",
 "pages": [
  {
   "name": "page1",
   "elements": [
    {
     "type": "matrixdropdown",
     "name": "V001",
     "title": "Testvraag",
     "columns": [
      {
       "name": "1",
       "title": " ",
       "cellType": "checkbox",
       "showInMultipleColumns": true,
       "choices": [
        {
         "value": "1",
         "text": "Antwoord A"
        },
        {
         "value": "2",
         "text": "Antwoord B"
        },
        {
         "value": "3",
         "text": "Antwoord C"
        }
       ],
       "hasOther": true,
       "noneText": "Geen van bovenstaande",
       "otherText": "Anders, namelijk:"
      }
     ],
     "choices": [
      1,
      2,
      3,
      4,
      5
     ],
     "rows": [
      {
       "value": "1",
       "text": "Aspect A"
      },
      {
       "value": "2",
       "text": "Aspect B"
      }
     ]
    }
   ]
  }
 ],
 "questionsOnPageMode": "questionPerPage"
}

Specify your

The following code works incorrectly. It leads to errors in Creator V2. Here is the related issue

  Survey.Serializer.addProperty("question", { name: "tagbox:set", choices: [1, 2, 3, 4] });
  const question = new Survey.QuestionText("q1");
  const val = [1, 2];
  Serializer.setObjPropertyValue(question, "tagbox", val);
  //question.tagbox equals to [1, 2] now
  val.splice(0, 1);
  //question.tagbox equals to [2] now, but it should not be changed.

With the following survey expression, the question 1 dropdown selection is reset when checking an item for question 3.

{
 "logoPosition": "right",
 "pages": [
  {
   "name": "page1",
   "elements": [
    {
     "type": "paneldynamic",
     "name": "question",
     "templateElements": [
      {
       "type": "panel",
       "name": "panel1",
       "elements": [
        {
         "type": "dropdown",
         "name": "question1",
         "choicesMin": 1,
         "choicesMax": 5
        },
        {
         "type": "matrixdynamic",
         "name": "question2",
         "bindings": {
          "rowCount": "question1"
         },
         "columns": [
          {
           "name": "Column 1",
           "cellType": "expression",
           "expression": "'Row ' + {rowIndex}"
          },
          {
           "name": "Column 2"
          },
          {
           "name": "Column 3"
          }
         ],
         "choices": [
          1,
          2,
          3,
          4,
          5
         ],
         "allowAddRows": false,
         "allowRemoveRows": false,
         "rowCount": 0
        }
       ]
      },
      {
       "type": "checkbox",
       "name": "question3",
       "choices": [
        "item1",
        "item2",
        "item3"
       ]
      }
     ],
     "allowAddPanel": false,
     "allowRemovePanel": false,
     "panelCount": 1
    },
    {
     "type": "panel",
     "name": "panel2"
    }
   ]
  }
 ]
}

A complete sample is available at https://plnkr.co/edit/blLZR0Qy5u3K1DKh.

Attachments DemoT10358.mp4.

https://user-images.githubusercontent.com/22372972/184880372-13641448-4da4-4df4-a35b-ebc3047397a5.mp4

The issue has been originally reported at T10358 - rowCount issue in DynamicMatrix when using expressions in columns.

Product
survey-library
Type
Enhancement
Description
Add survey.width property

You can have one container for different surveys and these diffefrent surveys require to set a different width to look good. We need to apply this property, if it is set, to a root div.

Product
survey-library
Type
Bug
Description
Deleting a first element in the panel/page row works incorrectly

We have to set "startWithNewLine" to true for the second element in the row on deleting the first element. Otherwise on loading updated survey JSON the row joins with the preivous row. It leads to error in Creator. Here is the Creator issue

Are you requesting a feature, reporting a bug or asking a question?

Bug

What is the current behavior?

1.9.45

What is the expected behavior?

Page (a first one) should be shown

How would you reproduce the current behavior (if this is a bug)?

Create a survey:

  1. with 2 pages: p1 and p2
  2. with 2 questions on the first page: q1 and q2
  3. have a rule: if q1=yes, then show q2
  4. have a rule: if q2=yes, then show p2
  5. (important) set firstPageIsStarted: true
  6. run surveys ERROR: it says "There is no visible page or question in the survey." EXPECTED: p1 with q1 should be shown (there is nothing preventing them from showing)

Provide the test code and the tested page URL (if applicable)

Tested page URL: https://surveyjs.io/published?id=078a2c6e-1125-4b6f-a82f-bed3d067cb3b

Test code

{
 logoPosition: "right",
 pages: [
  {
   name: "page1",
   elements: [
    {
     type: "radiogroup",
     name: "question1",
     choices: [
      {
       value: "1",
       text: "Yes"
      },
      {
       value: "0",
       text: "No"
      }
     ]
    },
    {
     type: "radiogroup",
     name: "question2",
     visibleIf: "{question1} = 1",
     title: "question2",
     choices: [
      {
       value: "1",
       text: "Yes"
      },
      {
       value: "0",
       text: "No"
      }
     ]
    }
   ]
  },
  {
   name: "page2",
   elements: [
    {
     type: "text",
     name: "question3"
    }
   ],
   visibleIf: "{question2} = 1"
  },
  {
   name: "page3"
  }
 ],
 clearInvisibleValues: "onHiddenContainer",
 firstPageIsStarted: true
}

Specify your

  • browser: Opera
  • browser version: 89.0.4447.83
  • surveyjs platform (angular or react or jquery or knockout or vue): ReactJS, but it doesn't matter
  • surveyjs version: 1.9.45
Product
survey-library
Type
Enhancement
Description
Add survey.onDynamicPanelRemoving event

We have onMatrixRowRemoving but we do not have similar event for dynamic panel.

  /**
   * The event is fired before removing a panel from Panel Dynamic question. You can disable removing and optionally clear the data instead.
   *- `sender` - the survey object that fires the event.
   *- `options.question` - a panel question.
   *- `options.panelIndex` - a removed panel index.
   *- `options.panel` - a removed panel.
   *- `options.allow` - a boolean property. Set it to `false` to disable the panel removing.
   * @see QuestionPanelDynamicModel
   * @see QuestionPanelDynamicModel.panels
   * @see onDynamicPanelRemoved
   */
   public onDynamicPanelRemoving: EventBase<SurveyModel> = this.addEvent<SurveyModel>();

Product
survey-creator
Type
Enhancement
Description
Extending itemValue leads to weird behavior

Are you requesting a feature, reporting a bug or ask a question?

Bug / feature

I'm trying to extend the item value class in the creator only. Imagine that I have a multiple choice question type, but for each choice I want the person creator to also specify another property.

For example say we have a list of car models including brand, car models are often classified in rough categories as well.

  • Tesla Model 3 -- Mid-Size
  • Tesla Model X -- Large
  • Mini Cooper -- Minicompact

The goal here is to use this information during analysis, it doesn't need to go in the survey data, but the survey creator should be able to store it.

What is the current behavior?

The survey creator renders the configuration for the choices fine: image (Ignore the clipping of values for now)

But it doesn't load it from the JSON.

What is the expected behavior?

Extending the itemvalue class should either work or explicitly be forbidden.

How would you reproduce the current behavior (if this is a bug)?

https://plnkr.co/edit/rsYMrS9rUDhoSnlI

Provide the test code and the tested page URL (if applicable)

Tested page URL: https://plnkr.co/edit/rsYMrS9rUDhoSnlI

Test code

// New question type for facility type:
  const widgetName = 'facilitytype'
  const facilityQuestionType = {
    name: widgetName,
    title: 'Facility Type',
    iconName: 'icon-radiogroup',
    category: 'HeRAMS',
    isFit (question) {
      return question.getType() === widgetName
    },
    isDefaultRender: true,

    widgetIsLoaded () {
      return true
    },

    init () {
      Survey.Serializer.addClass('facilityitemvalue', [
        {
          name: 'tier',
          displayName: 'Tier',
          choices: ['primary', 'secondary', 'tertiary'],
          default: 'primary'
        }, {
          name: 'text'
        }
      ], null, 'itemvalue')

      Survey.Serializer.addClass(widgetName, [
        {
          name: 'choices',
          type: 'facilityitemvalue[]'

        },
        {
          name: 'choicesFromQuestion',
          visible: false
        },
        {
          name: 'hasOther',
          visible: false
        },
        {
          name: 'hasNone',
          visible: false
        }
      ], null, 'radiogroup')
    },
    afterRender (question, el) {

    }

  }

  Survey.CustomWidgetCollection.Instance.add(facilityQuestionType, 'customtype')

Specify your

  • browser: Brave latest
  • editor version: 1.9.36
Product
survey-creator
Type
Bug
Description
survey creator tagbox property does not save all questions changes

Are you requesting a feature, reporting a bug or ask a question?

reporting a bug

What is the current behavior?

When adding a tagbox property to question in survery creator, GUI will only save the latest tagged question, and removes the previous tagged questions that was done before.

What is the expected behavior?

All edited questions that gets tagged with tagbox should keep their tags repectively

How would you reproduce the current behavior (if this is a bug)?

Add a tagbox property to the creator instance like so:

Survey.Serializer.addProperty("question", {
            name: "tagbox:set",
            choices: ["one", "two", "three"],
            category: "general"
});

Then try to edit a question and add a tag to the question from the general tab in right property pane of the question, and without saving continue to add a tag to another question , then inspect the JSON preview, only the last edited question gets a tagbox property.

Screenshot_7

Here is a plunker: https://plnkr.co/edit/qighGGf3uvvIxais

Provide the test code and the tested page URL (if applicable)

Tested page URL: https://plnkr.co/edit/qighGGf3uvvIxais

Test code

Survey.Serializer.addProperty("question", {
            name: "tagbox:set",
            choices: ["one", "two", "three"],
            category: "general"
});

Specify your

  • browser: Firefox and chrome
  • editor version: latest
Product
survey-creator
Type
Enhancement
Description
Drag Indicator

Let's make all drag indicators are similar. They are... — question https://www.figma.com/file/7QOeoDDCaPuqzWAROR0kDY/SJS-Creator?node-id=2217%3A24

— property grid list https://www.figma.com/file/7QOeoDDCaPuqzWAROR0kDY/SJS-Creator?node-id=10957%3A99134

— image (already) — any lists (already)

Product
survey-creator
Type
Bug
Description
It is not possible to add a question from the toolbox popup.

Version: v1.9.45, released at Tuesday, August 16, 2022, Total Issue Count: 10

Product Type Description
survey-library Bug Bug: Dropdown search bar is visible when "searchEnabled" is set to false

Are you requesting a feature, reporting a bug or asking a question?

Bug

What is the current behavior?

The dropdown search bar is visible when searchEnabled is set to false (with more than 10 choices).

What is the expected behavior?

The dropdown shouldn't display the search bar when searchEnabled is set to false.

How would you reproduce the current behavior (if this is a bug)?

Using the test page provided below, you'll notice that the search bar in the dropdown is visible even though searchEnabled is set to false in the survey json.

Provide the test code and the tested page URL (if applicable)

Tested page URL:

https://plnkr.co/edit/nFz6LbiR0UflYpnD

Test code

Survey.StylesManager.applyTheme("defaultV2");
var json = {
  "elements": [
    {
      "type": "dropdown",
      "name": "car",
      "choices": [
        "Ford",
        "Vauxhall",
        "Volkswagen",
        "Nissan",
        "Audi",
        "Mercedes-Benz",
        "BMW",
        "Peugeot",
        "Toyota",
        "Citroen",
        "Honda",
      ],
      "searchEnabled": false  
    }
  ]
};
window.survey = new Survey.Model(json);
survey.onComplete.add(function (sender) {
  document.querySelector('#surveyResult').textContent = "Result JSON:\n" + JSON.stringify(sender.data, null, 3);
});
var app = new Vue({
  el: '#surveyElement',
  data: {
    survey: survey
  }
});

Specify your

  • browser: Edge
  • browser version: 103.0.1264.71
  • surveyjs platform (angular or react or jquery or knockout or vue): vue
  • surveyjs version: 1.9.42
survey-library Bug Popup list in dropdown doesn't support localization

"Type to search..." string shows for all locales. "ListModel" class doesn't support localization.

survey-library Bug showQuestionNumbers should accept Boolean values

The name of the property suggests that it accepts Boolean values. However, it doesn't, and you won't find out about it until you look in the docs. I myself have been caught in this trap, and even created an issue, thinking that there's something wrong with parsing of Boolean values.

I suggest the following API:

showQuestionNumbers: true // the same as showQuestionNumbers: "on"
showQuestionNumbers: false // the same as showQuestionNumbers: "off"
survey-library Bug Composite component can't be used in matrices cells

We show composite component in matrices cell, but a cell value is not stored in the marix for this colum. Here is the simple example:

//Register a composite component
Survey.ComponentCollection.Instance.add({
    name: "customerinfo",
    elementsJSON: [
      { type: "text", name: "firstName" },
      { type: "text", name: "lastName" },
    ],
  });

Survey JSON:

{
    elements: [{
      type: "matrixdynamic",
      name: "matrix",
      columns: [
        { cellType: "customerinfo", name: "col1" },
      ]
    }]
  }

Matrix has two text questions in the cell, but the data is not stored. It should work correctly as for any other cell question.

survey-library Bug Buttons have different sizes in default theme and it modifications
survey-library Bug Carry forward for ranking question: use other item

If checkbox question hasOther property is set to true and this checkbox is used for carry forward functionality for a ranking question, then other value is not taken into account. Here is the JSON example:

{
 "logoPosition": "right",
 "pages": [
  {
   "name": "page1",
   "elements": [
    {
     "type": "checkbox",
     "name": "smartphone-features",
     "title": "What smartphone features do you think are valuable?",
     "isRequired": true,
     "choices": [
      "Battery life",
      "Screen size",
      "Storage space",
      "Camera quality",
      "Durability",
      "Processor power",
      "Price"
     ],
     "choicesOrder": "asc",
     "hasOther": true,
     "colCount": 4
    },
    {
     "type": "ranking",
     "name": "best-smartphone-features",
     "visibleIf": "{smartphone-features.length} > 1",
     "title": "Please rank the smartphone features in order of importance:",
     "isRequired": true,
     "choicesFromQuestion": "smartphone-features",
     "choicesFromQuestionMode": "selected"
    }
   ]
  }
 ]
}

On selecting other and setting the text in checkbox question, this new value is not shows in visible choices for a ranking question.

survey-library Enhancement Automatically convert youtube url to embed for image question

If imageLink is set to "https://youtu.be/-5CdAup0o-I" then we should use url: "https://www.youtube.com/embed/-5CdAup0o-I". We should covert url automatically, since the most end-users do not know what the correct link should be.

survey-creator Enhancement New selectbase item numbering after item delete

We need item3 in case of two added items image

survey-creator Bug V2: settings.toolbox.defaultJSON doesn't apply on converting question

To reproduce use the following default JSON for radiogroup: settings.toolbox.defaultJSON["radiogroup"] = { choices: [1, 2, 3, 4, 5] }; After that drop radiogroup on surface (choices will be correct 1, 2, 3, 4, 5), then convert the question into "text" and convert to "radiogroup" again. Choices will be "item1", "item2" and "item3" instead of [1, 2, 3, 4, 5].

survey-creator Bug V2: Hide "Add Question" button on page if allowEdit set to false onElementAllowOperations event

The following code should remove buttons: "Delete", "Duplicate" and "Add Question" on the first page in Creator surface. Right now we do not remove "Add Question" buttons.

  creator.onElementAllowOperations.add((sender, options) => {
    if(options.obj.isPage) {
      const isFirstPage = sender.survey.pages.indexOf(options.obj) === 0;
      if(isFirstPage) {
        options.allowDelete = false;
        options.allowEdit = false;
        options.allowCopy = false;
      }
    }
  });

Version: v1.9.45, released at Tuesday, August 16, 2022, Total Issue Count: 10

Are you requesting a feature, reporting a bug or asking a question?

Bug

What is the current behavior?

The dropdown search bar is visible when searchEnabled is set to false (with more than 10 choices).

What is the expected behavior?

The dropdown shouldn't display the search bar when searchEnabled is set to false.

How would you reproduce the current behavior (if this is a bug)?

Using the test page provided below, you'll notice that the search bar in the dropdown is visible even though searchEnabled is set to false in the survey json.

Provide the test code and the tested page URL (if applicable)

Tested page URL:

https://plnkr.co/edit/nFz6LbiR0UflYpnD

Test code

Survey.StylesManager.applyTheme("defaultV2");
var json = {
  "elements": [
    {
      "type": "dropdown",
      "name": "car",
      "choices": [
        "Ford",
        "Vauxhall",
        "Volkswagen",
        "Nissan",
        "Audi",
        "Mercedes-Benz",
        "BMW",
        "Peugeot",
        "Toyota",
        "Citroen",
        "Honda",
      ],
      "searchEnabled": false  
    }
  ]
};
window.survey = new Survey.Model(json);
survey.onComplete.add(function (sender) {
  document.querySelector('#surveyResult').textContent = "Result JSON:\n" + JSON.stringify(sender.data, null, 3);
});
var app = new Vue({
  el: '#surveyElement',
  data: {
    survey: survey
  }
});

Specify your

  • browser: Edge
  • browser version: 103.0.1264.71
  • surveyjs platform (angular or react or jquery or knockout or vue): vue
  • surveyjs version: 1.9.42
Product
survey-library
Type
Bug
Description
Popup list in dropdown doesn't support localization

"Type to search..." string shows for all locales. "ListModel" class doesn't support localization.

Product
survey-library
Type
Bug
Description
showQuestionNumbers should accept Boolean values

The name of the property suggests that it accepts Boolean values. However, it doesn't, and you won't find out about it until you look in the docs. I myself have been caught in this trap, and even created an issue, thinking that there's something wrong with parsing of Boolean values.

I suggest the following API:

showQuestionNumbers: true // the same as showQuestionNumbers: "on"
showQuestionNumbers: false // the same as showQuestionNumbers: "off"
Product
survey-library
Type
Bug
Description
Composite component can't be used in matrices cells

We show composite component in matrices cell, but a cell value is not stored in the marix for this colum. Here is the simple example:

//Register a composite component
Survey.ComponentCollection.Instance.add({
    name: "customerinfo",
    elementsJSON: [
      { type: "text", name: "firstName" },
      { type: "text", name: "lastName" },
    ],
  });

Survey JSON:

{
    elements: [{
      type: "matrixdynamic",
      name: "matrix",
      columns: [
        { cellType: "customerinfo", name: "col1" },
      ]
    }]
  }

Matrix has two text questions in the cell, but the data is not stored. It should work correctly as for any other cell question.

Product
survey-library
Type
Bug
Description
Buttons have different sizes in default theme and it modifications
Product
survey-library
Type
Bug
Description
Carry forward for ranking question: use other item

If checkbox question hasOther property is set to true and this checkbox is used for carry forward functionality for a ranking question, then other value is not taken into account. Here is the JSON example:

{
 "logoPosition": "right",
 "pages": [
  {
   "name": "page1",
   "elements": [
    {
     "type": "checkbox",
     "name": "smartphone-features",
     "title": "What smartphone features do you think are valuable?",
     "isRequired": true,
     "choices": [
      "Battery life",
      "Screen size",
      "Storage space",
      "Camera quality",
      "Durability",
      "Processor power",
      "Price"
     ],
     "choicesOrder": "asc",
     "hasOther": true,
     "colCount": 4
    },
    {
     "type": "ranking",
     "name": "best-smartphone-features",
     "visibleIf": "{smartphone-features.length} > 1",
     "title": "Please rank the smartphone features in order of importance:",
     "isRequired": true,
     "choicesFromQuestion": "smartphone-features",
     "choicesFromQuestionMode": "selected"
    }
   ]
  }
 ]
}

On selecting other and setting the text in checkbox question, this new value is not shows in visible choices for a ranking question.

Product
survey-library
Type
Enhancement
Description
Automatically convert youtube url to embed for image question

If imageLink is set to "https://youtu.be/-5CdAup0o-I" then we should use url: "https://www.youtube.com/embed/-5CdAup0o-I". We should covert url automatically, since the most end-users do not know what the correct link should be.

Product
survey-creator
Type
Enhancement
Description
New selectbase item numbering after item delete

We need item3 in case of two added items image

Product
survey-creator
Type
Bug
Description
V2: settings.toolbox.defaultJSON doesn't apply on converting question

To reproduce use the following default JSON for radiogroup: settings.toolbox.defaultJSON["radiogroup"] = { choices: [1, 2, 3, 4, 5] }; After that drop radiogroup on surface (choices will be correct 1, 2, 3, 4, 5), then convert the question into "text" and convert to "radiogroup" again. Choices will be "item1", "item2" and "item3" instead of [1, 2, 3, 4, 5].

The following code should remove buttons: "Delete", "Duplicate" and "Add Question" on the first page in Creator surface. Right now we do not remove "Add Question" buttons.

  creator.onElementAllowOperations.add((sender, options) => {
    if(options.obj.isPage) {
      const isFirstPage = sender.survey.pages.indexOf(options.obj) === 0;
      if(isFirstPage) {
        options.allowDelete = false;
        options.allowEdit = false;
        options.allowCopy = false;
      }
    }
  });

Version: v1.9.44, released at Tuesday, August 9, 2022, Total Issue Count: 3

Product
survey-library
Type
Enhancement
Description
Tagbox: add property specifying whether or not to hide selected items.
Product
survey-library
Type
Bug
Description
Dropdown doesn't clear item selection in the drop-down list
Product
survey-library
Type
Enhancement
Description
Add an easier ability to create a dropdown action

Version: v1.9.43, released at Wednesday, August 3, 2022, Total Issue Count: 10

Product Type Description
survey-library Enhancement Matrixdropdown: Fix default minimum column width

The default placeholder text should be fully visible. image

survey-library Bug goNextPageAutomatic property set to autogonext not working

It doesn't work when the property is setup in JSON. It works if you setup the value in code. Here is the example

survey-library Bug Share data between questions example for valuePropertyName fails under Angular, jQuery and Knockout

Are you requesting a feature, reporting a bug or asking a question?

Bug

What is the current behavior?

Using the Share data between questions example on the SurveyJS website with Angular, jQuery or Knockout, clicking once on an unselected checkbox item on Page 2 (What car do you own?) does not check it (kinda need 2 or 3 clicks) and even when checked, the selected item is not displayed in the title of the subsequent question (Please describe your car), specifically "templateTitle": "Car: " does not work.

React and Vue doe not exhibit this issue.

What is the expected behavior?

Clicking the checkbox item checks it and that item name displayed in the title of the panel.

How would you reproduce the current behavior (if this is a bug)?

Using the provided SurveyJS example, Page 2 using Angular, jQuery or Knockout.

Provide the test code and the tested page URL (if applicable)

Tested page URL: https://surveyjs.io/Examples/Library?id=survey-shareddata

https://user-images.githubusercontent.com/18456/182078321-815ce5e1-8993-4dc4-9dc4-d89c80dc50d2.mov

Specify your

  • browser: Chrome and Safari
  • browser version: Chrome v103, Safari v15.6 (Mac OS X)
  • surveyjs platform (angular or react or jquery or knockout or vue): Angular, jQuery and Knockout exhibit the bug; React and Vue do not.
  • surveyjs version: latest (1.9.42)
survey-library Bug showQuestionNumbers property doesnt' work correctly in dynamic panel

On adding/deleting panels in dynamic panel question if "showQuestionNumbers" property set to "onPanel" or "onSurvey" then it doesnt' work correctly.

survey-library Bug React warning when using requiredIf on element in matrix and visibleIf/enableIf in columns

We should move code on generating cell question class names inside the cell. It is on matrix level right now. In this case rendering will not trigger state changes.

survey-creator Enhancement Logic tab: Filter unavailable items in dropdown menus

image

survey-creator Bug Panel / Panel dymanic + startWithNewLine selection styles issue
  1. setup json
{
 "logoPosition": "right",
 "pages": [
  {
   "name": "page1",
   "elements": [
    {
     "type": "paneldynamic",
     "name": "paneldynamic1",
     "templateElements": [
      {
       "type": "text",
       "name": "text1"
      },
      {
       "type": "text",
       "name": "text2",
       "startWithNewLine": false
      }
     ]
    }
   ]
  }
 ]
}
  1. go to Designer tab and choose the text1 question (click)
  2. see image
survey-creator Bug Hidden Question Issue

Hidden questions have to be activated during the answering.

Screenshot 2022-07-21 at 18 04 05

survey-creator Bug Question panel on the popup have no border.

Screenshot 2022-07-21 at 15 16 15

survey-creator Enhancement V2: Property Editor "Question" should support creator.onGetObjectDisplayName event

There is no way to change the display text in the dropdown property editor on choosing a question from the question list. For example for "gotoName" property in the skip trigger. We should add a new reason: "property-editor" for this case.

Version: v1.9.43, released at Wednesday, August 3, 2022, Total Issue Count: 10

Product
survey-library
Type
Enhancement
Description
Matrixdropdown: Fix default minimum column width

The default placeholder text should be fully visible. image

Product
survey-library
Type
Bug
Description
goNextPageAutomatic property set to autogonext not working

It doesn't work when the property is setup in JSON. It works if you setup the value in code. Here is the example

Are you requesting a feature, reporting a bug or asking a question?

Bug

What is the current behavior?

Using the Share data between questions example on the SurveyJS website with Angular, jQuery or Knockout, clicking once on an unselected checkbox item on Page 2 (What car do you own?) does not check it (kinda need 2 or 3 clicks) and even when checked, the selected item is not displayed in the title of the subsequent question (Please describe your car), specifically "templateTitle": "Car: " does not work.

React and Vue doe not exhibit this issue.

What is the expected behavior?

Clicking the checkbox item checks it and that item name displayed in the title of the panel.

How would you reproduce the current behavior (if this is a bug)?

Using the provided SurveyJS example, Page 2 using Angular, jQuery or Knockout.

Provide the test code and the tested page URL (if applicable)

Tested page URL: https://surveyjs.io/Examples/Library?id=survey-shareddata

https://user-images.githubusercontent.com/18456/182078321-815ce5e1-8993-4dc4-9dc4-d89c80dc50d2.mov

Specify your

  • browser: Chrome and Safari
  • browser version: Chrome v103, Safari v15.6 (Mac OS X)
  • surveyjs platform (angular or react or jquery or knockout or vue): Angular, jQuery and Knockout exhibit the bug; React and Vue do not.
  • surveyjs version: latest (1.9.42)
Product
survey-library
Type
Bug
Description
showQuestionNumbers property doesnt' work correctly in dynamic panel

On adding/deleting panels in dynamic panel question if "showQuestionNumbers" property set to "onPanel" or "onSurvey" then it doesnt' work correctly.

We should move code on generating cell question class names inside the cell. It is on matrix level right now. In this case rendering will not trigger state changes.

Product
survey-creator
Type
Enhancement
Description
Logic tab: Filter unavailable items in dropdown menus

image

Product
survey-creator
Type
Bug
Description
Panel / Panel dymanic + startWithNewLine selection styles issue
  1. setup json
{
 "logoPosition": "right",
 "pages": [
  {
   "name": "page1",
   "elements": [
    {
     "type": "paneldynamic",
     "name": "paneldynamic1",
     "templateElements": [
      {
       "type": "text",
       "name": "text1"
      },
      {
       "type": "text",
       "name": "text2",
       "startWithNewLine": false
      }
     ]
    }
   ]
  }
 ]
}
  1. go to Designer tab and choose the text1 question (click)
  2. see image
Product
survey-creator
Type
Bug
Description
Hidden Question Issue

Hidden questions have to be activated during the answering.

Screenshot 2022-07-21 at 18 04 05

Product
survey-creator
Type
Bug
Description
Question panel on the popup have no border.

Screenshot 2022-07-21 at 15 16 15

There is no way to change the display text in the dropdown property editor on choosing a question from the question list. For example for "gotoName" property in the skip trigger. We should add a new reason: "property-editor" for this case.

Version: v1.9.42, released at Wednesday, July 27, 2022, Total Issue Count: 5

Product Type Description
survey-library Enhancement Hide "Next" button and show "Complete" if a complete trigger is going to be executed

When a user choose a question value that will trigger a complete trigger then "Next" button should be hidden and "Complete" button should be shown. Here is the JSON example:

{
 "pages": [
  {
   "name": "page1",
   "elements": [
    {
     "type": "radiogroup",
     "name": "question1",
     "choices": [
      "item1",
      "item2",
      "item3"
     ]
    }
   ]
  },
  {
   "name": "page2",
   "elements": [
    {
     "type": "text",
     "name": "question2"
    }
   ]
  }
 ],
 "triggers": [
  {
   "type": "complete",
   "expression": "{question1} = 'item1'"
  }
 ]
}

When a user choose "item1" for the first question then "Complete" button should be shown instead of "Next" button. When the value is cleared or another value is choosen then "Complete" button should be hidden and "Next" button should be shown.

survey-creator Bug Safari Add hovers to toolbar buttons

image

survey-creator Bug V2: visibleIf/enableIf for itemvalue (choices, row) doesn't have context in condition editor

If you are editing "visibleIf" property for a column choices then condition editor doesn't show "row.columnName" in question selector. For example the following visibleIf properties could not set in Creator:

{
     "type": "matrixdynamic",
     "name": "question2",
     "columns": [
      {
       "name": "Medium",
       "cellType": "dropdown",
       "choices": [
        "Road",
        "Water",
        "Air",
        "Rail"
       ]
      },
      {
       "name": "Mode",
       "cellType": "dropdown",
       "choices": [
        {
         "value": "average_lorry",
         "visibleIf": "{row.Medium} = 'Road'"
        },
        {
         "value": "small_lorry",
         "visibleIf": "{row.Medium} = 'Road'"
        },
        {
         "value": "overseas_container_ship",
         "visibleIf": "{row.Medium} = 'Water'"
        },
        {
         "value": "inland_waterways_barge",
         "visibleIf": "{row.Medium} = 'Water'"
        },
        {
         "value": "short_haul_flight",
         "visibleIf": "{row.Medium} = 'Air'"
        },
        {
         "value": "long_haul_flight",
         "visibleIf": "{row.Medium} = 'Air'"
        },
        {
         "value": "average_freight_train",
         "visibleIf": "{row.Medium} = 'Rail'"
        },
        {
         "value": "electric_freight_train",
         "visibleIf": "{row.Medium} = 'Rail'"
        }
       ]
      }
     ]
    }
survey-pdf Bug Html doesn't render in image mode in Firefox
survey-pdf Bug Table with colspan attribute doesn't render in standard mode

For detailed information see this ticket and this in the support center

Version: v1.9.42, released at Wednesday, July 27, 2022, Total Issue Count: 5

When a user choose a question value that will trigger a complete trigger then "Next" button should be hidden and "Complete" button should be shown. Here is the JSON example:

{
 "pages": [
  {
   "name": "page1",
   "elements": [
    {
     "type": "radiogroup",
     "name": "question1",
     "choices": [
      "item1",
      "item2",
      "item3"
     ]
    }
   ]
  },
  {
   "name": "page2",
   "elements": [
    {
     "type": "text",
     "name": "question2"
    }
   ]
  }
 ],
 "triggers": [
  {
   "type": "complete",
   "expression": "{question1} = 'item1'"
  }
 ]
}

When a user choose "item1" for the first question then "Complete" button should be shown instead of "Next" button. When the value is cleared or another value is choosen then "Complete" button should be hidden and "Next" button should be shown.

Product
survey-creator
Type
Bug
Description
Safari Add hovers to toolbar buttons

image

If you are editing "visibleIf" property for a column choices then condition editor doesn't show "row.columnName" in question selector. For example the following visibleIf properties could not set in Creator:

{
     "type": "matrixdynamic",
     "name": "question2",
     "columns": [
      {
       "name": "Medium",
       "cellType": "dropdown",
       "choices": [
        "Road",
        "Water",
        "Air",
        "Rail"
       ]
      },
      {
       "name": "Mode",
       "cellType": "dropdown",
       "choices": [
        {
         "value": "average_lorry",
         "visibleIf": "{row.Medium} = 'Road'"
        },
        {
         "value": "small_lorry",
         "visibleIf": "{row.Medium} = 'Road'"
        },
        {
         "value": "overseas_container_ship",
         "visibleIf": "{row.Medium} = 'Water'"
        },
        {
         "value": "inland_waterways_barge",
         "visibleIf": "{row.Medium} = 'Water'"
        },
        {
         "value": "short_haul_flight",
         "visibleIf": "{row.Medium} = 'Air'"
        },
        {
         "value": "long_haul_flight",
         "visibleIf": "{row.Medium} = 'Air'"
        },
        {
         "value": "average_freight_train",
         "visibleIf": "{row.Medium} = 'Rail'"
        },
        {
         "value": "electric_freight_train",
         "visibleIf": "{row.Medium} = 'Rail'"
        }
       ]
      }
     ]
    }
Product
survey-pdf
Type
Bug
Description
Html doesn't render in image mode in Firefox
Product
survey-pdf
Type
Bug
Description
Table with colspan attribute doesn't render in standard mode

For detailed information see this ticket and this in the support center

Version: v1.9.41, released at Wednesday, July 20, 2022, Total Issue Count: 9

Product Type Description
survey-library Bug Dropdown: If the element's text is very long, the popup will go beyond the visible area.

image

survey-library Bug Support old JSON when column has choices but doesn't have cellType set

The following JSON is incorrect:

      {
        type: "matrixdynamic",
        name: "q1",
        rowCount: 1,
        columns: [
          {
            name: "col1",
            choices: ["a", "b", "c", "d"]
          }
        ]
      }

It should have cellType set. However, this JSON works in previous versions. To support it, we should set cellType on JSON loading.

survey-library Bug Dropdown: set popup z-index to 1500
survey-library Enhancement A11Y aria allowed attr issue
survey-creator Enhancement Preview tab issues
  • top padding
  • do not use "!"
  • check "Preview Survey Again" text with Tech writer
  • panel corners
  • panel shadow
  • table header text align and borders
  • check other paddings, if need discuss with Mike image
survey-creator Bug V2: The ghost page is not created after moving a question from existing page into a ghost page

Steps to reproduce:

  1. Add a new question into Page1
  2. Move this question into ghost page. As result, Page2 is created and a question is added into it from Page1, but a new ghost page is not created.
survey-creator Bug V2: Adding a question to an empty survey from the toolbox does not use the `translations.ed.newPageName` property

Are you requesting a feature, reporting a bug or ask a question?

Reporting a bug

What is the current behavior?

When you add a question to an empty survey form the toolbox. It will auto-create the first page with the name "page1" even if you set the translations property.

Adding via drag drop of toolbox, or the ghost page button works as expected.

What is the expected behavior?

The toolbox should name pages using the translations property

How would you reproduce the current behavior (if this is a bug)?

  1. Open https://plnkr.co/edit/xNnI1L4enxVsUizq
  2. Increase width of preview to show the toolbox
  3. Insert single input question.
  4. Select the page the single input was inserted into. It's name is "page1". [Bug]

  1. Delete the page and insert using drag drop from the toolbox, or using the ghost page's add question button.
  2. Select the Page > Settings. It is named "Page 1". [Expected behaviour]

Specify your

  • browser: Chrome
  • editor version: 1.9.40
survey-creator Bug Type Converter does not work on hover

image

survey-creator Bug onModified event not firing after json property is set to empty
  const creatorOptions = {};
  const creator = new SurveyCreator(creatorOptions);
  creator.JSON = {};
  creator.onModified.add((sender, options) => {
    console.log('IS MODIFIED')
  });

To reproduce: Add a question and on the console you will see a "modified" string signifying that the event was triggered. After this, change the Survey Title and you'll see that the event does not get fired.

https://surveyjs.answerdesk.io/ticket/details/t10050/survey-creator-issues https://surveyjs.answerdesk.io/ticket/details/t10042/onmodified-doesn-t-get-triggered-when-survey-title-is-changed-after-adding-a-question

Version: v1.9.41, released at Wednesday, July 20, 2022, Total Issue Count: 9

image

The following JSON is incorrect:

      {
        type: "matrixdynamic",
        name: "q1",
        rowCount: 1,
        columns: [
          {
            name: "col1",
            choices: ["a", "b", "c", "d"]
          }
        ]
      }

It should have cellType set. However, this JSON works in previous versions. To support it, we should set cellType on JSON loading.

Product
survey-library
Type
Bug
Description
Dropdown: set popup z-index to 1500
Product
survey-library
Type
Enhancement
Description
A11Y aria allowed attr issue
Product
survey-creator
Type
Enhancement
Description
Preview tab issues
  • top padding
  • do not use "!"
  • check "Preview Survey Again" text with Tech writer
  • panel corners
  • panel shadow
  • table header text align and borders
  • check other paddings, if need discuss with Mike image

Steps to reproduce:

  1. Add a new question into Page1
  2. Move this question into ghost page. As result, Page2 is created and a question is added into it from Page1, but a new ghost page is not created.

Are you requesting a feature, reporting a bug or ask a question?

Reporting a bug

What is the current behavior?

When you add a question to an empty survey form the toolbox. It will auto-create the first page with the name "page1" even if you set the translations property.

Adding via drag drop of toolbox, or the ghost page button works as expected.

What is the expected behavior?

The toolbox should name pages using the translations property

How would you reproduce the current behavior (if this is a bug)?

  1. Open https://plnkr.co/edit/xNnI1L4enxVsUizq
  2. Increase width of preview to show the toolbox
  3. Insert single input question.
  4. Select the page the single input was inserted into. It's name is "page1". [Bug]

  1. Delete the page and insert using drag drop from the toolbox, or using the ghost page's add question button.
  2. Select the Page > Settings. It is named "Page 1". [Expected behaviour]

Specify your

  • browser: Chrome
  • editor version: 1.9.40
Product
survey-creator
Type
Bug
Description
Type Converter does not work on hover

image

Product
survey-creator
Type
Bug
Description
onModified event not firing after json property is set to empty
  const creatorOptions = {};
  const creator = new SurveyCreator(creatorOptions);
  creator.JSON = {};
  creator.onModified.add((sender, options) => {
    console.log('IS MODIFIED')
  });

To reproduce: Add a question and on the console you will see a "modified" string signifying that the event was triggered. After this, change the Survey Title and you'll see that the event does not get fired.

https://surveyjs.answerdesk.io/ticket/details/t10050/survey-creator-issues https://surveyjs.answerdesk.io/ticket/details/t10042/onmodified-doesn-t-get-triggered-when-survey-title-is-changed-after-adding-a-question

Version: v1.9.40, released at Tuesday, July 12, 2022, Total Issue Count: 18

Product Type Description
survey-library Enhancement Remove constant array duplication on defining inputTypes and dataList

There are several duplication in constant arrays on defining properties "dataList" and "inputType".

survey-library Bug Dropdown question: clear question value using keyboard.
survey-library Bug Do not set min bigger than max and max less than min for text question for input types: month, week and time

We do not have restrictions for min and max for input types: month, week and time.

survey-library Bug required text is not updated for matrix column when column requriedIf returns true

For the following json, second and third columns do not show "*" required text even when "a" equals 5 and column1 for all rows equals to 2.

{
        type: "matrixdynamic",
        name: "matrix",
        rowCount: 2,
        columns: [
          { name: "column1", isRequired: true },
          { name: "column2", requiredIf: "{a} = 5" },
          { name: "column3", requiredIf: "{row.column1} = 2" }
        ]
      }
survey-library Enhancement Support underline symbol in string constant wihout brackets in expressions

The correct string constant should be in brackets in our expressions: {question1} = "item1" or {question1} = 'item1'. Some people use it without brackets: {question1} = item1. However if there is an underline, it doesn't work {question1} = item_1 is invalid, it should be {question1} = "item_1". We can support {question1} = item_1 as well.

survey-library Enhancement Keep question and column title if it was set directly and equals to name

Currently, on seting question and column title equals to name, we clear the title property. By default, the empty title is rendered as name. However, it is not a good UI. An end-user enters the title in Creator and then it disappeared. We should keep title value if it was set directly even if it equals to name.

survey-library Bug Rating as a drop down list throws an exception when clicked

_this.question.onClick is not a function at SurveyQuestionDropdownBase._this.click (dropdown-base.ts

survey-library Bug Do not generate JSON de-serialization required error if property has a default value

If we have the following new property:

Survey.Serializer.addProperty("question", {
  name: "tag:number",
  default: 0,
  category: "general",
  isRequired: true
});

Then Survey de-serializer starts to generates error if a question doesn't have a tag property in JSON. However, there is a default value for the property.

survey-creator Enhancement Too big padding in toolbar

image

survey-creator Enhancement The default property grid groups should be collapsed when we start working
survey-creator Bug Logic tab: Texts overflow the controls when showTitlesInExpressions is enabled
survey-creator Bug `allowModifyPages: false` doesn't work

This property shouldn't allow users to add, delete, or edit survey pages. However, it doesn't seem to apply.

CodeSandbox

survey-creator Enhancement Create an example on onGetElementWrapperComponentName and onGetElementWrapperComponentData events
survey-creator Bug The column editor has incorrect styles.
survey-creator Enhancement Add "defaultV2" theme into embedded tab

Add defaultV2 theme and make it default in embedded tab.

survey-creator