survey-core 1.12.5 → 1.12.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (228) hide show
  1. package/defaultV2.css +6 -3
  2. package/defaultV2.css.map +1 -1
  3. package/defaultV2.fontless.css +6 -3
  4. package/defaultV2.fontless.css.map +1 -1
  5. package/defaultV2.fontless.min.css +2 -2
  6. package/defaultV2.min.css +2 -2
  7. package/i18n/arabic.js +1 -1
  8. package/i18n/arabic.min.js +1 -1
  9. package/i18n/basque.js +1 -1
  10. package/i18n/basque.min.js +1 -1
  11. package/i18n/bulgarian.js +1 -1
  12. package/i18n/bulgarian.min.js +1 -1
  13. package/i18n/catalan.js +1 -1
  14. package/i18n/catalan.min.js +1 -1
  15. package/i18n/croatian.js +1 -1
  16. package/i18n/croatian.min.js +1 -1
  17. package/i18n/czech.js +1 -1
  18. package/i18n/czech.min.js +1 -1
  19. package/i18n/danish.js +1 -1
  20. package/i18n/danish.min.js +1 -1
  21. package/i18n/dutch.js +1 -1
  22. package/i18n/dutch.min.js +1 -1
  23. package/i18n/english.js +1 -1
  24. package/i18n/english.min.js +1 -1
  25. package/i18n/estonian.js +1 -1
  26. package/i18n/estonian.min.js +1 -1
  27. package/i18n/finnish.js +1 -1
  28. package/i18n/finnish.min.js +1 -1
  29. package/i18n/french.js +1 -1
  30. package/i18n/french.min.js +1 -1
  31. package/i18n/georgian.js +1 -1
  32. package/i18n/georgian.min.js +1 -1
  33. package/i18n/german.js +1 -1
  34. package/i18n/german.min.js +1 -1
  35. package/i18n/greek.js +1 -1
  36. package/i18n/greek.min.js +1 -1
  37. package/i18n/hebrew.js +1 -1
  38. package/i18n/hebrew.min.js +1 -1
  39. package/i18n/hindi.js +1 -1
  40. package/i18n/hindi.min.js +1 -1
  41. package/i18n/hungarian.js +1 -1
  42. package/i18n/hungarian.min.js +1 -1
  43. package/i18n/icelandic.js +1 -1
  44. package/i18n/icelandic.min.js +1 -1
  45. package/i18n/index.js +1 -1
  46. package/i18n/index.min.js +1 -1
  47. package/i18n/indonesian.js +1 -1
  48. package/i18n/indonesian.min.js +1 -1
  49. package/i18n/italian.js +1 -1
  50. package/i18n/italian.min.js +1 -1
  51. package/i18n/japanese.js +1 -1
  52. package/i18n/japanese.min.js +1 -1
  53. package/i18n/kazakh.js +1 -1
  54. package/i18n/kazakh.min.js +1 -1
  55. package/i18n/korean.js +1 -1
  56. package/i18n/korean.min.js +1 -1
  57. package/i18n/latvian.js +1 -1
  58. package/i18n/latvian.min.js +1 -1
  59. package/i18n/lithuanian.js +1 -1
  60. package/i18n/lithuanian.min.js +1 -1
  61. package/i18n/macedonian.js +1 -1
  62. package/i18n/macedonian.min.js +1 -1
  63. package/i18n/malay.js +1 -1
  64. package/i18n/malay.min.js +1 -1
  65. package/i18n/nl-BE.js +1 -1
  66. package/i18n/nl-BE.min.js +1 -1
  67. package/i18n/norwegian.js +1 -1
  68. package/i18n/norwegian.min.js +1 -1
  69. package/i18n/persian.js +1 -1
  70. package/i18n/persian.min.js +1 -1
  71. package/i18n/philippines.js +1 -1
  72. package/i18n/philippines.min.js +1 -1
  73. package/i18n/polish.js +1 -1
  74. package/i18n/polish.min.js +1 -1
  75. package/i18n/portuguese-br.js +1 -1
  76. package/i18n/portuguese-br.min.js +1 -1
  77. package/i18n/portuguese.js +1 -1
  78. package/i18n/portuguese.min.js +1 -1
  79. package/i18n/romanian.js +1 -1
  80. package/i18n/romanian.min.js +1 -1
  81. package/i18n/russian.js +1 -1
  82. package/i18n/russian.min.js +1 -1
  83. package/i18n/serbian.js +1 -1
  84. package/i18n/serbian.min.js +1 -1
  85. package/i18n/simplified-chinese.js +1 -1
  86. package/i18n/simplified-chinese.min.js +1 -1
  87. package/i18n/slovak.js +1 -1
  88. package/i18n/slovak.min.js +1 -1
  89. package/i18n/spanish.js +1 -1
  90. package/i18n/spanish.min.js +1 -1
  91. package/i18n/swahili.js +1 -1
  92. package/i18n/swahili.min.js +1 -1
  93. package/i18n/swedish.js +1 -1
  94. package/i18n/swedish.min.js +1 -1
  95. package/i18n/tajik.js +1 -1
  96. package/i18n/tajik.min.js +1 -1
  97. package/i18n/telugu.js +1 -1
  98. package/i18n/telugu.min.js +1 -1
  99. package/i18n/thai.js +1 -1
  100. package/i18n/thai.min.js +1 -1
  101. package/i18n/traditional-chinese.js +1 -1
  102. package/i18n/traditional-chinese.min.js +1 -1
  103. package/i18n/turkish.js +1 -1
  104. package/i18n/turkish.min.js +1 -1
  105. package/i18n/ukrainian.js +1 -1
  106. package/i18n/ukrainian.min.js +1 -1
  107. package/i18n/urdu.js +1 -1
  108. package/i18n/urdu.min.js +1 -1
  109. package/i18n/vietnamese.js +1 -1
  110. package/i18n/vietnamese.min.js +1 -1
  111. package/i18n/welsh.js +1 -1
  112. package/i18n/welsh.min.js +1 -1
  113. package/modern.css +1 -1
  114. package/modern.fontless.css +1 -1
  115. package/modern.fontless.min.css +1 -1
  116. package/modern.min.css +1 -1
  117. package/package.json +1 -1
  118. package/plugins/bootstrap-integration/index.js +1 -1
  119. package/plugins/bootstrap-integration/index.min.js +1 -1
  120. package/plugins/bootstrap-material-integration/index.js +1 -1
  121. package/plugins/bootstrap-material-integration/index.min.js +1 -1
  122. package/survey.core.js +115 -76
  123. package/survey.core.js.map +1 -1
  124. package/survey.core.min.js +3 -3
  125. package/survey.css +1 -1
  126. package/survey.i18n.js +1 -1
  127. package/survey.i18n.min.js +1 -1
  128. package/survey.min.css +1 -1
  129. package/themes/borderless-dark-panelless.js +1 -1
  130. package/themes/borderless-dark-panelless.min.js +1 -1
  131. package/themes/borderless-dark.js +1 -1
  132. package/themes/borderless-dark.min.js +1 -1
  133. package/themes/borderless-light-panelless..js +1 -1
  134. package/themes/borderless-light-panelless..min.js +1 -1
  135. package/themes/borderless-light.js +1 -1
  136. package/themes/borderless-light.min.js +1 -1
  137. package/themes/contrast-dark-panelless.js +1 -1
  138. package/themes/contrast-dark-panelless.min.js +1 -1
  139. package/themes/contrast-dark.js +1 -1
  140. package/themes/contrast-dark.min.js +1 -1
  141. package/themes/contrast-light-panelless.js +1 -1
  142. package/themes/contrast-light-panelless.min.js +1 -1
  143. package/themes/contrast-light.js +1 -1
  144. package/themes/contrast-light.min.js +1 -1
  145. package/themes/default-dark-panelless.js +1 -1
  146. package/themes/default-dark-panelless.min.js +1 -1
  147. package/themes/default-dark.js +1 -1
  148. package/themes/default-dark.min.js +1 -1
  149. package/themes/default-light-panelless.js +1 -1
  150. package/themes/default-light-panelless.min.js +1 -1
  151. package/themes/default-light.js +1 -1
  152. package/themes/default-light.min.js +1 -1
  153. package/themes/doubleborder-dark-panelless.js +1 -1
  154. package/themes/doubleborder-dark-panelless.min.js +1 -1
  155. package/themes/doubleborder-dark.js +1 -1
  156. package/themes/doubleborder-dark.min.js +1 -1
  157. package/themes/doubleborder-light-panelles.js +1 -1
  158. package/themes/doubleborder-light-panelles.min.js +1 -1
  159. package/themes/doubleborder-light.js +1 -1
  160. package/themes/doubleborder-light.min.js +1 -1
  161. package/themes/flat-dark-panelless.js +1 -1
  162. package/themes/flat-dark-panelless.min.js +1 -1
  163. package/themes/flat-dark.js +1 -1
  164. package/themes/flat-dark.min.js +1 -1
  165. package/themes/flat-light-panelless.js +1 -1
  166. package/themes/flat-light-panelless.min.js +1 -1
  167. package/themes/flat-light.js +1 -1
  168. package/themes/flat-light.min.js +1 -1
  169. package/themes/index.js +1 -1
  170. package/themes/index.min.js +1 -1
  171. package/themes/layered-dark-panelless.js +1 -1
  172. package/themes/layered-dark-panelless.min.js +1 -1
  173. package/themes/layered-dark.js +1 -1
  174. package/themes/layered-dark.min.js +1 -1
  175. package/themes/layered-light-panelless.js +1 -1
  176. package/themes/layered-light-panelless.min.js +1 -1
  177. package/themes/layered-light.js +1 -1
  178. package/themes/layered-light.min.js +1 -1
  179. package/themes/plain-dark-panelless.js +1 -1
  180. package/themes/plain-dark-panelless.min.js +1 -1
  181. package/themes/plain-dark.js +1 -1
  182. package/themes/plain-dark.min.js +1 -1
  183. package/themes/plain-light-panelless.js +1 -1
  184. package/themes/plain-light-panelless.min.js +1 -1
  185. package/themes/plain-light.js +1 -1
  186. package/themes/plain-light.min.js +1 -1
  187. package/themes/sharp-dark-panelless.js +1 -1
  188. package/themes/sharp-dark-panelless.min.js +1 -1
  189. package/themes/sharp-dark.js +1 -1
  190. package/themes/sharp-dark.min.js +1 -1
  191. package/themes/sharp-light-panelless.js +1 -1
  192. package/themes/sharp-light-panelless.min.js +1 -1
  193. package/themes/sharp-light.js +1 -1
  194. package/themes/sharp-light.min.js +1 -1
  195. package/themes/solid-dark-panelless.js +1 -1
  196. package/themes/solid-dark-panelless.min.js +1 -1
  197. package/themes/solid-dark.js +1 -1
  198. package/themes/solid-dark.min.js +1 -1
  199. package/themes/solid-light-panelless.js +1 -1
  200. package/themes/solid-light-panelless.min.js +1 -1
  201. package/themes/solid-light.js +1 -1
  202. package/themes/solid-light.min.js +1 -1
  203. package/themes/three-dimensional-dark-panelless.js +1 -1
  204. package/themes/three-dimensional-dark-panelless.min.js +1 -1
  205. package/themes/three-dimensional-dark.js +1 -1
  206. package/themes/three-dimensional-dark.min.js +1 -1
  207. package/themes/three-dimensional-light-panelless.js +1 -1
  208. package/themes/three-dimensional-light-panelless.min.js +1 -1
  209. package/themes/three-dimensional-light.js +1 -1
  210. package/themes/three-dimensional-light.min.js +1 -1
  211. package/ts3.4/typings/packages/survey-core/src/base-interfaces.d.ts +1 -1
  212. package/ts3.4/typings/packages/survey-core/src/jsonobject.d.ts +2 -0
  213. package/ts3.4/typings/packages/survey-core/src/question.d.ts +1 -1
  214. package/ts3.4/typings/packages/survey-core/src/question_file.d.ts +5 -5
  215. package/ts3.4/typings/packages/survey-core/src/question_matrixdropdownbase.d.ts +2 -0
  216. package/ts3.4/typings/packages/survey-core/src/question_matrixdynamic.d.ts +2 -0
  217. package/ts3.4/typings/packages/survey-core/src/question_text.d.ts +0 -1
  218. package/ts3.4/typings/packages/survey-core/src/survey.d.ts +2 -1
  219. package/ts3.4/typings/packages/survey-core/src/validator.d.ts +1 -0
  220. package/typings/packages/survey-core/src/base-interfaces.d.ts +1 -1
  221. package/typings/packages/survey-core/src/jsonobject.d.ts +2 -0
  222. package/typings/packages/survey-core/src/question.d.ts +1 -1
  223. package/typings/packages/survey-core/src/question_file.d.ts +5 -5
  224. package/typings/packages/survey-core/src/question_matrixdropdownbase.d.ts +2 -0
  225. package/typings/packages/survey-core/src/question_matrixdynamic.d.ts +2 -0
  226. package/typings/packages/survey-core/src/question_text.d.ts +0 -1
  227. package/typings/packages/survey-core/src/survey.d.ts +2 -1
  228. package/typings/packages/survey-core/src/validator.d.ts +1 -0
package/survey.core.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * surveyjs - Survey JavaScript library v1.12.5
2
+ * surveyjs - Survey JavaScript library v1.12.6
3
3
  * Copyright (c) 2015-2024 Devsoft Baltic OÜ - http://surveyjs.io/
4
4
  * License: MIT (http://www.opensource.org/licenses/mit-license.php)
5
5
  */
@@ -3011,6 +3011,9 @@ var jsonobject_JsonMetadataClass = /** @class */ (function () {
3011
3011
  if (propInfo.readOnly === true) {
3012
3012
  prop.readOnly = true;
3013
3013
  }
3014
+ if (propInfo.availableInMatrixColumn === true) {
3015
+ prop.availableInMatrixColumn = true;
3016
+ }
3014
3017
  if (propInfo.choices) {
3015
3018
  var choicesFunc = typeof propInfo.choices === "function" ? propInfo.choices : null;
3016
3019
  var choicesValue = typeof propInfo.choices !== "function" ? propInfo.choices : null;
@@ -12924,18 +12927,6 @@ var survey_element_SurveyElement = /** @class */ (function (_super) {
12924
12927
  requestAnimationFrame(checkPos_1);
12925
12928
  };
12926
12929
  DomWindowHelper.requestAnimationFrame(checkPos_1);
12927
- // let currPageXOffset = window.pageXOffset;
12928
- // let currPageYOffset = window.pageYOffset;
12929
- // var scrollDone = setInterval(() => {
12930
- // DomWindowHelper.requestAnimationFrame(() => {
12931
- // if (currPageXOffset == window.pageXOffset && currPageYOffset == window.pageYOffset) {
12932
- // clearInterval(scrollDone);
12933
- // doneCallback();
12934
- // }
12935
- // currPageXOffset = window.pageXOffset;
12936
- // currPageYOffset = window.pageYOffset;
12937
- // });
12938
- // }, 25);
12939
12930
  }
12940
12931
  };
12941
12932
  SurveyElement.ScrollElementToTop = function (elementId, scrollIfVisible, scrollIntoViewOptions, doneCallback) {
@@ -12946,12 +12937,17 @@ var survey_element_SurveyElement = /** @class */ (function (_super) {
12946
12937
  return SurveyElement.ScrollElementToViewCore(el, false, scrollIfVisible, scrollIntoViewOptions, doneCallback);
12947
12938
  };
12948
12939
  SurveyElement.ScrollElementToViewCore = function (el, checkLeft, scrollIfVisible, scrollIntoViewOptions, doneCallback) {
12949
- if (!el || !el.scrollIntoView)
12940
+ if (!el || !el.scrollIntoView) {
12941
+ doneCallback && doneCallback();
12950
12942
  return false;
12943
+ }
12951
12944
  var needScroll = SurveyElement.IsNeedScrollIntoView(el, checkLeft, scrollIfVisible);
12952
12945
  if (needScroll) {
12953
12946
  SurveyElement.ScrollIntoView(el, scrollIntoViewOptions, doneCallback);
12954
12947
  }
12948
+ else {
12949
+ doneCallback && doneCallback();
12950
+ }
12955
12951
  return needScroll;
12956
12952
  };
12957
12953
  SurveyElement.GetFirstNonTextElement = function (elements, removeSpaces) {
@@ -16675,6 +16671,11 @@ var validator_SurveyValidator = /** @class */ (function (_super) {
16675
16671
  _this.createLocalizableString("text", _this, true);
16676
16672
  return _this;
16677
16673
  }
16674
+ Object.defineProperty(SurveyValidator.prototype, "isValidator", {
16675
+ get: function () { return true; },
16676
+ enumerable: false,
16677
+ configurable: true
16678
+ });
16678
16679
  SurveyValidator.prototype.getSurvey = function (live) {
16679
16680
  if (live === void 0) { live = false; }
16680
16681
  return !!this.errorOwner && !!this.errorOwner["getSurvey"]
@@ -19153,6 +19154,7 @@ var question_Question = /** @class */ (function (_super) {
19153
19154
  * @param onError Pass `true` if you want to focus an input field with the first validation error. Default value: `false` (focuses the first input field). Applies to question types with multiple input fields.
19154
19155
  */
19155
19156
  Question.prototype.focus = function (onError, scrollIfVisible) {
19157
+ var _this = this;
19156
19158
  if (onError === void 0) { onError = false; }
19157
19159
  if (this.isDesignMode || !this.isVisible || !this.survey)
19158
19160
  return;
@@ -19162,16 +19164,17 @@ var question_Question = /** @class */ (function (_super) {
19162
19164
  this.survey.focusQuestionByInstance(this, onError);
19163
19165
  }
19164
19166
  else {
19165
- this.focuscore(onError, scrollIfVisible);
19166
- }
19167
- };
19168
- Question.prototype.focuscore = function (onError, scrollIfVisible) {
19169
- if (onError === void 0) { onError = false; }
19170
- if (!!this.survey) {
19171
- this.expandAllParents();
19172
- this.survey.scrollElementToTop(this, this, null, this.id, scrollIfVisible);
19167
+ if (!!this.survey) {
19168
+ this.expandAllParents();
19169
+ var scrollOptions = this.survey["isSmoothScrollEnabled"] ? { behavior: "smooth" } : undefined;
19170
+ this.survey.scrollElementToTop(this, this, null, this.id, scrollIfVisible, scrollOptions, undefined, function () {
19171
+ _this.focusInputElement(onError);
19172
+ });
19173
+ }
19174
+ else {
19175
+ this.focusInputElement(onError);
19176
+ }
19173
19177
  }
19174
- this.focusInputElement(onError);
19175
19178
  };
19176
19179
  Question.prototype.focusInputElement = function (onError) {
19177
19180
  var id = !onError ? this.getFirstInputElementId() : this.getFirstErrorInputElementId();
@@ -20698,9 +20701,12 @@ var question_Question = /** @class */ (function (_super) {
20698
20701
  if (this.isValueEmpty(value) && helpers_Helpers.isNumber(this[propName])) {
20699
20702
  value = 0;
20700
20703
  }
20701
- this[propName] = value;
20704
+ this.updateBindingProp(propName, value);
20702
20705
  }
20703
20706
  };
20707
+ Question.prototype.updateBindingProp = function (propName, value) {
20708
+ this[propName] = value;
20709
+ };
20704
20710
  Question.prototype.getComponentName = function () {
20705
20711
  return RendererFactory.Instance.getRendererByQuestion(this);
20706
20712
  };
@@ -27802,7 +27808,7 @@ var MatrixDropdownRowTextProcessor = /** @class */ (function (_super) {
27802
27808
  textValue.value = this.row.rowIndex;
27803
27809
  return true;
27804
27810
  }
27805
- if (textValue.name == question_matrixdropdownbase_MatrixDropdownRowModelBase.RowValueVariableName) {
27811
+ if ([question_matrixdropdownbase_MatrixDropdownRowModelBase.RowValueVariableName, question_matrixdropdownbase_MatrixDropdownRowModelBase.RowNameVariableName].indexOf(textValue.name) > -1) {
27806
27812
  textValue.isExists = true;
27807
27813
  textValue.value = this.row.rowName;
27808
27814
  return true;
@@ -28036,11 +28042,12 @@ var question_matrixdropdownbase_MatrixDropdownRowModelBase = /** @class */ (func
28036
28042
  MatrixDropdownRowModelBase.prototype.applyRowVariablesToValues = function (res, rowIndex) {
28037
28043
  res[MatrixDropdownRowModelBase.IndexVariableName] = rowIndex;
28038
28044
  res[MatrixDropdownRowModelBase.RowValueVariableName] = this.rowName;
28045
+ res[MatrixDropdownRowModelBase.RowNameVariableName] = this.rowName;
28039
28046
  };
28040
28047
  MatrixDropdownRowModelBase.prototype.runCondition = function (values, properties, rowsVisibleIf) {
28041
- if (!!this.data) {
28042
- values[MatrixDropdownRowModelBase.OwnerVariableName] = this.data.getFilteredData();
28043
- }
28048
+ if (!this.data)
28049
+ return;
28050
+ values[MatrixDropdownRowModelBase.OwnerVariableName] = this.data.getFilteredData();
28044
28051
  var rowIndex = this.rowIndex;
28045
28052
  this.applyRowVariablesToValues(values, rowIndex);
28046
28053
  var newProps = helpers_Helpers.createCopy(properties);
@@ -28451,11 +28458,14 @@ var question_matrixdropdownbase_MatrixDropdownRowModelBase = /** @class */ (func
28451
28458
  };
28452
28459
  Object.defineProperty(MatrixDropdownRowModelBase.prototype, "rowIndex", {
28453
28460
  get: function () {
28454
- return !!this.data ? this.data.getRowIndex(this) + 1 : -1;
28461
+ return this.getRowIndex();
28455
28462
  },
28456
28463
  enumerable: false,
28457
28464
  configurable: true
28458
28465
  });
28466
+ MatrixDropdownRowModelBase.prototype.getRowIndex = function () {
28467
+ return !!this.data ? this.data.getRowIndex(this) + 1 : -1;
28468
+ };
28459
28469
  Object.defineProperty(MatrixDropdownRowModelBase.prototype, "editingObj", {
28460
28470
  get: function () {
28461
28471
  return this.editingObjValue;
@@ -28493,6 +28503,7 @@ var question_matrixdropdownbase_MatrixDropdownRowModelBase = /** @class */ (func
28493
28503
  MatrixDropdownRowModelBase.OwnerVariableName = "self";
28494
28504
  MatrixDropdownRowModelBase.IndexVariableName = "rowIndex";
28495
28505
  MatrixDropdownRowModelBase.RowValueVariableName = "rowValue";
28506
+ MatrixDropdownRowModelBase.RowNameVariableName = "rowName";
28496
28507
  MatrixDropdownRowModelBase.idCounter = 1;
28497
28508
  return MatrixDropdownRowModelBase;
28498
28509
  }());
@@ -29156,9 +29167,9 @@ var question_matrixdropdownbase_QuestionMatrixDropdownModelBase = /** @class */
29156
29167
  return !!question ? question.getConditionJson(operator) : null;
29157
29168
  };
29158
29169
  QuestionMatrixDropdownModelBase.prototype.clearIncorrectValues = function () {
29159
- var rows = this.visibleRows;
29160
- if (!rows)
29170
+ if (!Array.isArray(this.visibleRows))
29161
29171
  return;
29172
+ var rows = this.generatedVisibleRows;
29162
29173
  for (var i = 0; i < rows.length; i++) {
29163
29174
  rows[i].clearIncorrectValues(this.getRowValue(i));
29164
29175
  }
@@ -29563,13 +29574,13 @@ var question_matrixdropdownbase_QuestionMatrixDropdownModelBase = /** @class */
29563
29574
  * @see setRowValue
29564
29575
  */
29565
29576
  QuestionMatrixDropdownModelBase.prototype.getRowValue = function (rowIndex) {
29566
- if (rowIndex < 0)
29577
+ if (rowIndex < 0 || !Array.isArray(this.visibleRows))
29567
29578
  return null;
29568
- var visRows = this.visibleRows;
29569
- if (rowIndex >= visRows.length)
29579
+ var rows = this.generatedVisibleRows;
29580
+ if (rowIndex >= rows.length)
29570
29581
  return null;
29571
29582
  var newValue = this.createNewValue();
29572
- return this.getRowValueCore(visRows[rowIndex], newValue);
29583
+ return this.getRowValueCore(rows[rowIndex], newValue);
29573
29584
  };
29574
29585
  QuestionMatrixDropdownModelBase.prototype.checkIfValueInRowDuplicated = function (checkedRow, cellQuestion) {
29575
29586
  if (!this.generatedVisibleRows)
@@ -30221,9 +30232,9 @@ var question_matrixdropdownbase_QuestionMatrixDropdownModelBase = /** @class */
30221
30232
  return { value: newValue, rowValue: rowValue };
30222
30233
  };
30223
30234
  QuestionMatrixDropdownModelBase.prototype.getRowIndex = function (row) {
30224
- if (!this.generatedVisibleRows)
30235
+ if (!Array.isArray(this.generatedVisibleRows))
30225
30236
  return -1;
30226
- return this.visibleRows.indexOf(row);
30237
+ return this.generatedVisibleRows.indexOf(row);
30227
30238
  };
30228
30239
  QuestionMatrixDropdownModelBase.prototype.getElementsInDesign = function (includeHidden) {
30229
30240
  if (includeHidden === void 0) { includeHidden = false; }
@@ -30621,17 +30632,17 @@ var question_matrixdropdown_QuestionMatrixDropdownModel = /** @class */ (functio
30621
30632
  if (!rows)
30622
30633
  return res;
30623
30634
  for (var i = 0; i < rows.length; i++) {
30624
- var rowValue = rows[i].rowName;
30625
- var val = value[rowValue];
30635
+ var rowName = rows[i].rowName;
30636
+ var val = value[rowName];
30626
30637
  if (!val)
30627
30638
  continue;
30628
30639
  if (keysAsText) {
30629
- var displayRowValue = itemvalue_ItemValue.getTextOrHtmlByValue(this.rows, rowValue);
30640
+ var displayRowValue = itemvalue_ItemValue.getTextOrHtmlByValue(this.rows, rowName);
30630
30641
  if (!!displayRowValue) {
30631
- rowValue = displayRowValue;
30642
+ rowName = displayRowValue;
30632
30643
  }
30633
30644
  }
30634
- res[rowValue] = this.getRowDisplayValue(keysAsText, rows[i], val);
30645
+ res[rowName] = this.getRowDisplayValue(keysAsText, rows[i], val);
30635
30646
  }
30636
30647
  return res;
30637
30648
  };
@@ -30686,11 +30697,11 @@ var question_matrixdropdown_QuestionMatrixDropdownModel = /** @class */ (functio
30686
30697
  }
30687
30698
  _super.prototype.clearGeneratedRows.call(this);
30688
30699
  };
30689
- QuestionMatrixDropdownModel.prototype.getRowValueForCreation = function (val, rowValue) {
30690
- var res = val[rowValue];
30700
+ QuestionMatrixDropdownModel.prototype.getRowValueForCreation = function (val, rowName) {
30701
+ var res = val[rowName];
30691
30702
  if (!res)
30692
30703
  return res;
30693
- var names = this.defaultValuesInRows[rowValue];
30704
+ var names = this.defaultValuesInRows[rowName];
30694
30705
  if (!Array.isArray(names) || names.length === 0)
30695
30706
  return res;
30696
30707
  names.forEach(function (name) {
@@ -30737,8 +30748,8 @@ var question_matrixdropdown_QuestionMatrixDropdownModel = /** @class */ (functio
30737
30748
  val = {};
30738
30749
  for (var i = 0; i < this.rows.length; i++) {
30739
30750
  var row = this.rows[i];
30740
- var rowValue = val[row.value];
30741
- this.updateProgressInfoByRow(res, !!rowValue ? rowValue : {});
30751
+ var rowName = val[row.value];
30752
+ this.updateProgressInfoByRow(res, !!rowName ? rowName : {});
30742
30753
  }
30743
30754
  };
30744
30755
  return QuestionMatrixDropdownModel;
@@ -31572,6 +31583,10 @@ var MatrixDynamicRowModel = /** @class */ (function (_super) {
31572
31583
  _this.buildCells(value);
31573
31584
  return _this;
31574
31585
  }
31586
+ MatrixDynamicRowModel.prototype.getRowIndex = function () {
31587
+ var res = _super.prototype.getRowIndex.call(this);
31588
+ return res > 0 ? res : this.index + 1;
31589
+ };
31575
31590
  Object.defineProperty(MatrixDynamicRowModel.prototype, "rowName", {
31576
31591
  get: function () {
31577
31592
  return this.id;
@@ -31801,6 +31816,7 @@ var question_matrixdynamic_QuestionMatrixDynamicModel = /** @class */ (function
31801
31816
  return this.rowCountValue;
31802
31817
  },
31803
31818
  set: function (val) {
31819
+ val = helpers_Helpers.getNumber(val);
31804
31820
  if (val < 0 || val > settings.matrix.maxRowCount)
31805
31821
  return;
31806
31822
  this.setRowCountValueFromData = false;
@@ -31833,6 +31849,23 @@ var question_matrixdynamic_QuestionMatrixDynamicModel = /** @class */ (function
31833
31849
  enumerable: false,
31834
31850
  configurable: true
31835
31851
  });
31852
+ QuestionMatrixDynamicModel.prototype.updateBindingProp = function (propName, value) {
31853
+ _super.prototype.updateBindingProp.call(this, propName, value);
31854
+ var rows = this.generatedVisibleRows;
31855
+ if (propName !== "rowCount" || !Array.isArray(rows))
31856
+ return;
31857
+ var val = this.getUnbindValue(this.value) || [];
31858
+ if (val.length < rows.length) {
31859
+ var hasValue = false;
31860
+ for (var i = val.length; i < rows.length; i++) {
31861
+ hasValue || (hasValue = !rows[i].isEmpty);
31862
+ val.push(rows[i].value || {});
31863
+ }
31864
+ if (hasValue) {
31865
+ this.value = val;
31866
+ }
31867
+ }
31868
+ };
31836
31869
  QuestionMatrixDynamicModel.prototype.updateProgressInfoByValues = function (res) {
31837
31870
  var val = this.value;
31838
31871
  if (!Array.isArray(val))
@@ -34305,7 +34338,7 @@ var header_Cover = /** @class */ (function (_super) {
34305
34338
  return this.height ? Math.max(this.height, this.actualHeight + 40) + "px" : undefined;
34306
34339
  }
34307
34340
  if (this.survey && this.survey.isMobile) {
34308
- return this.mobileHeight ? Math.max(this.mobileHeight, this.actualHeight + 40) + "px" : undefined;
34341
+ return this.mobileHeight ? Math.max(this.mobileHeight, this.actualHeight) + "px" : undefined;
34309
34342
  }
34310
34343
  return undefined;
34311
34344
  },
@@ -34386,13 +34419,19 @@ var header_Cover = /** @class */ (function (_super) {
34386
34419
  };
34387
34420
  Cover.prototype.processResponsiveness = function (width) {
34388
34421
  if (this.survey && this.survey.rootElement) {
34389
- var logoEl = this.survey.rootElement.querySelectorAll(".sv-header__logo")[0];
34390
- var titleEl = this.survey.rootElement.querySelectorAll(".sv-header__title")[0];
34391
- var descriptionEl = this.survey.rootElement.querySelectorAll(".sv-header__description")[0];
34392
- var logoHeight = logoEl ? logoEl.getBoundingClientRect().height : 0;
34393
- var titleHeight = titleEl ? titleEl.getBoundingClientRect().height : 0;
34394
- var descriptionHeight = descriptionEl ? descriptionEl.getBoundingClientRect().height : 0;
34395
- this.actualHeight = this.calculateActualHeight(logoHeight, titleHeight, descriptionHeight);
34422
+ if (!this.survey.isMobile) {
34423
+ var logoEl = this.survey.rootElement.querySelectorAll(".sv-header__logo")[0];
34424
+ var titleEl = this.survey.rootElement.querySelectorAll(".sv-header__title")[0];
34425
+ var descriptionEl = this.survey.rootElement.querySelectorAll(".sv-header__description")[0];
34426
+ var logoHeight = logoEl ? logoEl.getBoundingClientRect().height : 0;
34427
+ var titleHeight = titleEl ? titleEl.getBoundingClientRect().height : 0;
34428
+ var descriptionHeight = descriptionEl ? descriptionEl.getBoundingClientRect().height : 0;
34429
+ this.actualHeight = this.calculateActualHeight(logoHeight, titleHeight, descriptionHeight);
34430
+ }
34431
+ else {
34432
+ var headerContainer = this.survey.rootElement.querySelectorAll(".sv-header > div")[0];
34433
+ this.actualHeight = headerContainer ? headerContainer.getBoundingClientRect().height : 0;
34434
+ }
34396
34435
  }
34397
34436
  };
34398
34437
  Object.defineProperty(Cover.prototype, "hasBackground", {
@@ -39453,6 +39492,7 @@ var survey_SurveyModel = /** @class */ (function (_super) {
39453
39492
  _this.isNavigationButtonPressed = false;
39454
39493
  _this.mouseDownPage = null;
39455
39494
  _this.isCalculatingProgressText = false;
39495
+ _this.isSmoothScrollEnabled = false;
39456
39496
  /**
39457
39497
  * An event that is raised when the survey's width or height is changed.
39458
39498
  */
@@ -44502,7 +44542,7 @@ var survey_SurveyModel = /** @class */ (function (_super) {
44502
44542
  this.onGetMatrixRowActions.fire(this, options);
44503
44543
  return options.actions;
44504
44544
  };
44505
- SurveyModel.prototype.scrollElementToTop = function (element, question, page, id, scrollIfVisible, scrollIntoViewOptions, passedRootElement) {
44545
+ SurveyModel.prototype.scrollElementToTop = function (element, question, page, id, scrollIfVisible, scrollIntoViewOptions, passedRootElement, onScolledCallback) {
44506
44546
  var _this = this;
44507
44547
  var options = {
44508
44548
  element: element,
@@ -44526,11 +44566,12 @@ var survey_SurveyModel = /** @class */ (function (_super) {
44526
44566
  survey_element_SurveyElement.ScrollElementToTop(options.elementId, scrollIfVisible, scrollIntoViewOptions, function () {
44527
44567
  _this.releaseLazyRendering();
44528
44568
  activateLazyRenderingChecks(elementPage_1.id);
44569
+ onScolledCallback && onScolledCallback();
44529
44570
  });
44530
44571
  }, elementsToRenderBefore);
44531
44572
  }
44532
44573
  else {
44533
- survey_element_SurveyElement.ScrollElementToTop(options.elementId, scrollIfVisible, scrollIntoViewOptions);
44574
+ survey_element_SurveyElement.ScrollElementToTop(options.elementId, scrollIfVisible, scrollIntoViewOptions, onScolledCallback);
44534
44575
  }
44535
44576
  }
44536
44577
  };
@@ -53607,7 +53648,7 @@ var question_text_QuestionTextModel = /** @class */ (function (_super) {
53607
53648
  return inputMask;
53608
53649
  };
53609
53650
  QuestionTextModel.prototype.isTextValue = function () {
53610
- return ["text", "number", "password"].indexOf(this.inputType) > -1;
53651
+ return this.isDateInputType || ["text", "number", "password"].indexOf(this.inputType) > -1;
53611
53652
  };
53612
53653
  QuestionTextModel.prototype.getType = function () {
53613
53654
  return "text";
@@ -53951,7 +53992,7 @@ var question_text_QuestionTextModel = /** @class */ (function (_super) {
53951
53992
  if (!this.isMinMaxType)
53952
53993
  return true;
53953
53994
  var isValid = !this.isValueLessMin && !this.isValueGreaterMax;
53954
- if (this.inputType === "number" && !!this.survey &&
53995
+ if ((!isValid || this.errors.length > 0) && !!this.survey &&
53955
53996
  (this.survey.isValidateOnValueChanging || this.survey.isValidateOnValueChanged)) {
53956
53997
  this.hasErrors();
53957
53998
  }
@@ -54081,11 +54122,6 @@ var question_text_QuestionTextModel = /** @class */ (function (_super) {
54081
54122
  enumerable: false,
54082
54123
  configurable: true
54083
54124
  });
54084
- QuestionTextModel.prototype.canRunValidators = function (isOnValueChanged) {
54085
- return (this.errors.length > 0 ||
54086
- !isOnValueChanged ||
54087
- this.supportGoNextPageError());
54088
- };
54089
54125
  QuestionTextModel.prototype.setNewValue = function (newValue) {
54090
54126
  newValue = this.correctValueType(newValue);
54091
54127
  if (!!newValue) {
@@ -58892,8 +58928,12 @@ var question_comment_QuestionCommentModel = /** @class */ (function (_super) {
58892
58928
  Object.defineProperty(QuestionCommentModel.prototype, "renderedAllowResize", {
58893
58929
  get: function () {
58894
58930
  var res = this.allowResize;
58895
- var allowResize = res === undefined && this.survey ? this.survey.allowResizeComment : !!res;
58896
- return allowResize && !this.isPreviewStyle && !this.isReadOnlyStyle;
58931
+ if (res === undefined && this.survey) {
58932
+ return this.survey.allowResizeComment;
58933
+ }
58934
+ else {
58935
+ return !!res;
58936
+ }
58897
58937
  },
58898
58938
  enumerable: false,
58899
58939
  configurable: true
@@ -59351,11 +59391,6 @@ var question_file_QuestionFileModelBase = /** @class */ (function (_super) {
59351
59391
  return QuestionFileModelBase;
59352
59392
  }(question_Question));
59353
59393
 
59354
- /**
59355
- * A class that describes the File Upload question type.
59356
- *
59357
- * [View Demo](https://surveyjs.io/form-library/examples/file-upload/ (linkStyle))
59358
- */
59359
59394
  var question_file_QuestionFilePage = /** @class */ (function (_super) {
59360
59395
  question_file_extends(QuestionFilePage, _super);
59361
59396
  function QuestionFilePage(question, index) {
@@ -59382,6 +59417,11 @@ var question_file_QuestionFilePage = /** @class */ (function (_super) {
59382
59417
  return QuestionFilePage;
59383
59418
  }(base_Base));
59384
59419
 
59420
+ /**
59421
+ * A class that describes the File Upload question type.
59422
+ *
59423
+ * [View Demo](https://surveyjs.io/form-library/examples/file-upload/ (linkStyle))
59424
+ */
59385
59425
  var question_file_QuestionFileModel = /** @class */ (function (_super) {
59386
59426
  question_file_extends(QuestionFileModel, _super);
59387
59427
  function QuestionFileModel(name) {
@@ -66528,9 +66568,8 @@ var question_paneldynamic_QuestionPanelDynamicModel = /** @class */ (function (_
66528
66568
  : null;
66529
66569
  };
66530
66570
  QuestionPanelDynamicModel.prototype.addConditionObjectsByContext = function (objects, context) {
66531
- var hasContext = !!context
66532
- ? context === true || this.template.questions.indexOf(context) > -1
66533
- : false;
66571
+ var contextQ = !!(context === null || context === void 0 ? void 0 : context.isValidator) ? context.errorOwner : context;
66572
+ var hasContext = !!context && (context === true || this.template.questions.indexOf(contextQ) > -1);
66534
66573
  var panelObjs = new Array();
66535
66574
  var questions = this.template.questions;
66536
66575
  for (var i = 0; i < questions.length; i++) {
@@ -70531,8 +70570,8 @@ Serializer.addClass("currencymask", [
70531
70570
 
70532
70571
  var Version;
70533
70572
  var ReleaseDate;
70534
- Version = "" + "1.12.5";
70535
- ReleaseDate = "" + "2024-10-07";
70573
+ Version = "" + "1.12.6";
70574
+ ReleaseDate = "" + "2024-10-15";
70536
70575
  function checkLibraryVersion(ver, libraryName) {
70537
70576
  if (Version != ver) {
70538
70577
  var str = "survey-core has version '" + Version + "' and " + libraryName