survey-core 1.11.8 → 1.11.9

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 (230) hide show
  1. package/defaultV2.css +7 -8
  2. package/defaultV2.css.map +1 -1
  3. package/defaultV2.fontless.css +7 -8
  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.js +1 -1
  119. package/plugins/bootstrap-integration.min.js +1 -1
  120. package/plugins/bootstrap-material-integration.js +1 -1
  121. package/plugins/bootstrap-material-integration.min.js +1 -1
  122. package/survey.core.js +149 -77
  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/base-interfaces.d.ts +1 -0
  212. package/ts3.4/typings/jsonobject.d.ts +2 -1
  213. package/ts3.4/typings/question_baseselect.d.ts +0 -5
  214. package/ts3.4/typings/question_custom.d.ts +8 -0
  215. package/ts3.4/typings/question_file.d.ts +2 -1
  216. package/ts3.4/typings/question_matrixdropdownbase.d.ts +1 -0
  217. package/ts3.4/typings/question_multipletext.d.ts +1 -0
  218. package/ts3.4/typings/question_paneldynamic.d.ts +2 -0
  219. package/ts3.4/typings/question_text.d.ts +2 -0
  220. package/ts3.4/typings/survey.d.ts +3 -1
  221. package/typings/base-interfaces.d.ts +1 -0
  222. package/typings/jsonobject.d.ts +2 -1
  223. package/typings/question_baseselect.d.ts +0 -5
  224. package/typings/question_custom.d.ts +8 -0
  225. package/typings/question_file.d.ts +2 -1
  226. package/typings/question_matrixdropdownbase.d.ts +1 -0
  227. package/typings/question_multipletext.d.ts +1 -0
  228. package/typings/question_paneldynamic.d.ts +2 -0
  229. package/typings/question_text.d.ts +2 -0
  230. package/typings/survey.d.ts +3 -1
package/survey.core.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * surveyjs - Survey JavaScript library v1.11.8
2
+ * surveyjs - Survey JavaScript library v1.11.9
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
  */
@@ -9847,8 +9847,8 @@ __webpack_require__.r(__webpack_exports__);
9847
9847
 
9848
9848
  var Version;
9849
9849
  var ReleaseDate;
9850
- Version = "" + "1.11.8";
9851
- ReleaseDate = "" + "2024-07-22";
9850
+ Version = "" + "1.11.9";
9851
+ ReleaseDate = "" + "2024-07-30";
9852
9852
  function checkLibraryVersion(ver, libraryName) {
9853
9853
  if (Version != ver) {
9854
9854
  var str = "survey-core has version '" + Version + "' and " + libraryName
@@ -15850,7 +15850,7 @@ function displayValue(params) {
15850
15850
  var q = getQuestionValueByContext(this, params[0]);
15851
15851
  if (!q)
15852
15852
  return "";
15853
- if (params.length > 1 && !!params[1])
15853
+ if (params.length > 1 && !_helpers__WEBPACK_IMPORTED_MODULE_0__["Helpers"].isValueEmpty(params[1]))
15854
15854
  return q.getDisplayValue(true, params[1]);
15855
15855
  return q.displayValue;
15856
15856
  }
@@ -19284,13 +19284,10 @@ var JsonMetadataClass = /** @class */ (function () {
19284
19284
  return prop;
19285
19285
  };
19286
19286
  JsonMetadataClass.prototype.addDependsOnProperties = function (prop, dependsOn) {
19287
- if (Array.isArray(dependsOn)) {
19288
- for (var i = 0; i < dependsOn.length; i++) {
19289
- this.addDependsOnProperty(prop, dependsOn[i]);
19290
- }
19291
- }
19292
- else {
19293
- this.addDependsOnProperty(prop, dependsOn);
19287
+ var dArray = Array.isArray(dependsOn) ? dependsOn : [dependsOn];
19288
+ prop.dependsOn = dArray;
19289
+ for (var i = 0; i < dArray.length; i++) {
19290
+ this.addDependsOnProperty(prop, dArray[i]);
19294
19291
  }
19295
19292
  };
19296
19293
  JsonMetadataClass.prototype.addDependsOnProperty = function (prop, dependsOn) {
@@ -19998,27 +19995,43 @@ var JsonObject = /** @class */ (function () {
19998
19995
  }
19999
19996
  properties = this.addDynamicProperties(obj, jsonObj, properties);
20000
19997
  this.options = options;
19998
+ var processedProps = {};
19999
+ processedProps[JsonObject.typePropertyName] = true;
20000
+ var parentProps = {};
20001
20001
  for (var key in jsonObj) {
20002
- if (key === JsonObject.typePropertyName)
20003
- continue;
20004
- if (key === JsonObject.positionPropertyName) {
20005
- obj[key] = jsonObj[key];
20006
- continue;
20007
- }
20008
- var property = this.findProperty(properties, key);
20009
- if (!property) {
20010
- if (needAddErrors) {
20011
- this.addNewError(new JsonUnknownPropertyError(key.toString(), objType), jsonObj, obj);
20012
- }
20013
- continue;
20014
- }
20015
- this.valueToObj(jsonObj[key], obj, property, jsonObj, options);
20002
+ this.setPropertyValueToObj(jsonObj, obj, key, properties, processedProps, parentProps, objType, needAddErrors, options);
20016
20003
  }
20017
20004
  this.options = undefined;
20018
20005
  if (obj.endLoadingFromJson) {
20019
20006
  obj.endLoadingFromJson();
20020
20007
  }
20021
20008
  };
20009
+ JsonObject.prototype.setPropertyValueToObj = function (jsonObj, obj, key, properties, processedProps, parentProps, objType, needAddErrors, options) {
20010
+ var _this = this;
20011
+ if (processedProps[key])
20012
+ return;
20013
+ if (key === JsonObject.positionPropertyName) {
20014
+ obj[key] = jsonObj[key];
20015
+ return;
20016
+ }
20017
+ var property = this.findProperty(properties, key);
20018
+ if (!property && needAddErrors) {
20019
+ this.addNewError(new JsonUnknownPropertyError(key.toString(), objType), jsonObj, obj);
20020
+ }
20021
+ if (property) {
20022
+ var dProps = property.dependsOn;
20023
+ if (Array.isArray(dProps)) {
20024
+ parentProps[key] = true;
20025
+ dProps.forEach(function (propKey) {
20026
+ if (!parentProps[propKey]) {
20027
+ _this.setPropertyValueToObj(jsonObj, obj, propKey, properties, processedProps, parentProps, objType, needAddErrors, options);
20028
+ }
20029
+ });
20030
+ }
20031
+ this.valueToObj(jsonObj[key], obj, property, jsonObj, options);
20032
+ processedProps[key] = true;
20033
+ }
20034
+ };
20022
20035
  JsonObject.prototype.toJsonObjectCore = function (obj, property, options) {
20023
20036
  if (!obj || !obj.getType)
20024
20037
  return obj;
@@ -26932,7 +26945,8 @@ _jsonobject__WEBPACK_IMPORTED_MODULE_0__["Serializer"].addClass("panelbase", [
26932
26945
  {
26933
26946
  name: "layoutColumns:panellayoutcolumns",
26934
26947
  className: "panellayoutcolumn", isArray: true,
26935
- onSerializeValue: function (obj) { return obj.getSerializableColumnsValue(); }
26948
+ onSerializeValue: function (obj) { return obj.getSerializableColumnsValue(); },
26949
+ visibleIf: function (obj) { return !!obj && !!obj.survey && obj.survey.gridLayoutEnabled; }
26936
26950
  },
26937
26951
  { name: "title:text", serializationProperty: "locTitle" },
26938
26952
  { name: "description:text", serializationProperty: "locDescription" },
@@ -26964,7 +26978,10 @@ _jsonobject__WEBPACK_IMPORTED_MODULE_0__["Serializer"].addClass("panel", [
26964
26978
  name: "colSpan:number", visible: false,
26965
26979
  onSerializeValue: function (obj) { return obj.getPropertyValue("colSpan"); },
26966
26980
  },
26967
- { name: "effectiveColSpan:number", minValue: 1, isSerializable: false },
26981
+ {
26982
+ name: "effectiveColSpan:number", minValue: 1, isSerializable: false,
26983
+ visibleIf: function (obj) { return !!obj && !!obj.survey && obj.survey.gridLayoutEnabled; }
26984
+ },
26968
26985
  { name: "innerIndent:number", default: 0, choices: [0, 1, 2, 3] },
26969
26986
  { name: "indent:number", default: 0, choices: [0, 1, 2, 3], visible: false },
26970
26987
  {
@@ -28657,9 +28674,10 @@ var ProgressButtons = /** @class */ (function (_super) {
28657
28674
  if (!listContainerElement)
28658
28675
  return;
28659
28676
  var listContainerElements = element.querySelectorAll(".sd-progress-buttons__connector");
28660
- var circleWidth = this.showItemNumbers ? 17 : 5;
28661
- var sideCorrection = this.survey.isMobile ? 0 : listContainerElement.children[0].clientWidth;
28662
- var connectorWidth = (listContainerElement.clientWidth - sideCorrection) / (listContainerElement.children.length - 1) - circleWidth;
28677
+ var circleWidth = this.showItemNumbers ? 36 : 20;
28678
+ // const sideCorrection = this.survey.isMobile ? circleWidth : listContainerElement.children[0].clientWidth;
28679
+ // const connectorWidth = (listContainerElement.clientWidth - sideCorrection) / (listContainerElement.children.length - 1) - circleWidth;
28680
+ var connectorWidth = (listContainerElement.clientWidth - circleWidth) / (listContainerElement.children.length - 1) - circleWidth;
28663
28681
  for (var i = 0; i < listContainerElements.length; i++) {
28664
28682
  listContainerElements[i].style.width = connectorWidth + "px";
28665
28683
  }
@@ -28741,6 +28759,7 @@ var ProgressButtonsResponsivityManager = /** @class */ (function () {
28741
28759
  this.canShowItemTitles = true;
28742
28760
  this.processResponsiveness = function (model, options) {
28743
28761
  _this.viewModel.onUpdateScroller(model.isListContainerHasScroller(_this.element));
28762
+ _this.model.clearConnectorsWidth(_this.element);
28744
28763
  if (!model.showItemTitles) {
28745
28764
  _this.model.adjustConnectors(_this.element);
28746
28765
  return;
@@ -28752,7 +28771,6 @@ var ProgressButtonsResponsivityManager = /** @class */ (function () {
28752
28771
  _this.viewModel.onResize(_this.canShowItemTitles);
28753
28772
  return;
28754
28773
  }
28755
- _this.model.clearConnectorsWidth(_this.element);
28756
28774
  if (_this.timer !== undefined) {
28757
28775
  clearTimeout(_this.timer);
28758
28776
  }
@@ -28857,9 +28875,6 @@ var TriggerExpressionInfo = /** @class */ (function () {
28857
28875
  }
28858
28876
  return TriggerExpressionInfo;
28859
28877
  }());
28860
- function querySelectorIncludingSelf(el, selector) {
28861
- return el.querySelector(selector) || el != _global_variables_utils__WEBPACK_IMPORTED_MODULE_14__["DomWindowHelper"].getWindow() && el.matches(selector) && el;
28862
- }
28863
28878
  /**
28864
28879
  * A base class for all questions.
28865
28880
  */
@@ -31817,7 +31832,7 @@ var Question = /** @class */ (function (_super) {
31817
31832
  var scrollableSelector_1 = this.getObservedElementSelector();
31818
31833
  if (!scrollableSelector_1)
31819
31834
  return;
31820
- var defaultRootEl = querySelectorIncludingSelf(el, scrollableSelector_1);
31835
+ var defaultRootEl = el.querySelector(scrollableSelector_1);
31821
31836
  if (!defaultRootEl)
31822
31837
  return;
31823
31838
  var isProcessed_1 = false;
@@ -31829,7 +31844,7 @@ var Question = /** @class */ (function (_super) {
31829
31844
  isProcessed_1 = false;
31830
31845
  }
31831
31846
  var callback = function () {
31832
- var rootEl = querySelectorIncludingSelf(el, scrollableSelector_1);
31847
+ var rootEl = el.querySelector(scrollableSelector_1);
31833
31848
  if (!requiredWidth_1 && _this.isDefaultRendering()) {
31834
31849
  requiredWidth_1 = rootEl.scrollWidth;
31835
31850
  }
@@ -31854,10 +31869,8 @@ var Question = /** @class */ (function (_super) {
31854
31869
  });
31855
31870
  this.onMobileChangedCallback = function () {
31856
31871
  setTimeout(function () {
31857
- var rootEl = querySelectorIncludingSelf(el, scrollableSelector_1);
31858
- if (rootEl) {
31859
- _this.processResponsiveness(requiredWidth_1, Object(_utils_utils__WEBPACK_IMPORTED_MODULE_11__["getElementWidth"])(rootEl));
31860
- }
31872
+ var rootEl = el.querySelector(scrollableSelector_1);
31873
+ _this.processResponsiveness(requiredWidth_1, Object(_utils_utils__WEBPACK_IMPORTED_MODULE_11__["getElementWidth"])(rootEl));
31861
31874
  }, 0);
31862
31875
  };
31863
31876
  this.resizeObserver.observe(el);
@@ -32105,7 +32118,10 @@ _jsonobject__WEBPACK_IMPORTED_MODULE_1__["Serializer"].addClass("question", [
32105
32118
  name: "colSpan:number", visible: false,
32106
32119
  onSerializeValue: function (obj) { return obj.getPropertyValue("colSpan"); },
32107
32120
  },
32108
- { name: "effectiveColSpan:number", minValue: 1, isSerializable: false },
32121
+ {
32122
+ name: "effectiveColSpan:number", minValue: 1, isSerializable: false,
32123
+ visibleIf: function (obj) { return !!obj && !!obj.survey && obj.survey.gridLayoutEnabled; }
32124
+ },
32109
32125
  { name: "startWithNewLine:boolean", default: true, layout: "row" },
32110
32126
  { name: "indent:number", default: 0, choices: [0, 1, 2, 3], layout: "row" },
32111
32127
  {
@@ -32491,7 +32507,6 @@ var QuestionSelectBase = /** @class */ (function (_super) {
32491
32507
  _this.isUpdatingChoicesDependedQuestions = false;
32492
32508
  _this.headItemsCount = 0;
32493
32509
  _this.footItemsCount = 0;
32494
- _this.allowMultiColumns = true;
32495
32510
  _this.prevIsOtherSelected = false;
32496
32511
  _this.noneItemValue = _this.createDefaultItem(_settings__WEBPACK_IMPORTED_MODULE_9__["settings"].noneItemValue, "noneText", "noneItemText");
32497
32512
  _this.refuseItemValue = _this.createDefaultItem(_settings__WEBPACK_IMPORTED_MODULE_9__["settings"].refuseItemValue, "refuseText", "refuseItemText");
@@ -34512,23 +34527,9 @@ var QuestionSelectBase = /** @class */ (function (_super) {
34512
34527
  enumerable: false,
34513
34528
  configurable: true
34514
34529
  });
34515
- QuestionSelectBase.prototype.getObservedElementSelector = function () {
34516
- return Object(_utils_utils__WEBPACK_IMPORTED_MODULE_11__["classesToSelector"])(this.cssClasses.mainRoot);
34517
- };
34518
- QuestionSelectBase.prototype.supportResponsiveness = function () {
34519
- return true;
34520
- };
34521
- QuestionSelectBase.prototype.onBeforeSetCompactRenderer = function () {
34522
- _super.prototype.onBeforeSetDesktopRenderer.call(this);
34523
- this.allowMultiColumns = false;
34524
- };
34525
- QuestionSelectBase.prototype.onBeforeSetDesktopRenderer = function () {
34526
- _super.prototype.onBeforeSetDesktopRenderer.call(this);
34527
- this.allowMultiColumns = true;
34528
- };
34529
34530
  Object.defineProperty(QuestionSelectBase.prototype, "hasColumns", {
34530
34531
  get: function () {
34531
- return !this.isMobile && this.allowMultiColumns &&
34532
+ return !this.isMobile &&
34532
34533
  (this.getCurrentColCount() > 1);
34533
34534
  },
34534
34535
  enumerable: false,
@@ -34686,9 +34687,6 @@ var QuestionSelectBase = /** @class */ (function (_super) {
34686
34687
  __decorate([
34687
34688
  Object(_jsonobject__WEBPACK_IMPORTED_MODULE_0__["property"])({ localizable: true })
34688
34689
  ], QuestionSelectBase.prototype, "otherPlaceholder", void 0);
34689
- __decorate([
34690
- Object(_jsonobject__WEBPACK_IMPORTED_MODULE_0__["property"])()
34691
- ], QuestionSelectBase.prototype, "allowMultiColumns", void 0);
34692
34690
  return QuestionSelectBase;
34693
34691
  }(_question__WEBPACK_IMPORTED_MODULE_2__["Question"]));
34694
34692
 
@@ -37142,6 +37140,9 @@ var QuestionCustomModelBase = /** @class */ (function (_super) {
37142
37140
  QuestionCustomModelBase.prototype.findQuestionByName = function (name) {
37143
37141
  return !!this.data ? this.data.findQuestionByName(name) : null;
37144
37142
  };
37143
+ QuestionCustomModelBase.prototype.getEditingSurveyElement = function () {
37144
+ return undefined;
37145
+ };
37145
37146
  //IPanel
37146
37147
  QuestionCustomModelBase.prototype.addElement = function (element, index) { };
37147
37148
  QuestionCustomModelBase.prototype.removeElement = function (element) {
@@ -37524,6 +37525,40 @@ var QuestionCompositeModel = /** @class */ (function (_super) {
37524
37525
  this.contentPanel.updateElementCss(reNew);
37525
37526
  }
37526
37527
  };
37528
+ QuestionCompositeModel.prototype.dispose = function () {
37529
+ this.unConnectEditingObj();
37530
+ _super.prototype.dispose.call(this);
37531
+ };
37532
+ QuestionCompositeModel.prototype.updateEditingObj = function () {
37533
+ var _this = this;
37534
+ var _a;
37535
+ var obj = (_a = this.data) === null || _a === void 0 ? void 0 : _a.getEditingSurveyElement();
37536
+ if (!obj)
37537
+ return undefined;
37538
+ var newObj = obj[this.getValueName()];
37539
+ if (!!newObj && !newObj.onPropertyChanged) {
37540
+ newObj = undefined;
37541
+ }
37542
+ if (newObj !== this.editingObjValue) {
37543
+ this.unConnectEditingObj();
37544
+ this.editingObjValue = newObj;
37545
+ if (!!newObj) {
37546
+ this.onEditingObjPropertyChanged = function (sender, options) {
37547
+ _this.setNewValueIntoQuestion(options.name, _this.editingObjValue[options.name]);
37548
+ };
37549
+ newObj.onPropertyChanged.add(this.onEditingObjPropertyChanged);
37550
+ }
37551
+ }
37552
+ return this.editingObjValue;
37553
+ };
37554
+ QuestionCompositeModel.prototype.unConnectEditingObj = function () {
37555
+ if (!!this.editingObjValue && !this.editingObjValue.isDisposed) {
37556
+ this.editingObjValue.onPropertyChanged.remove(this.onEditingObjPropertyChanged);
37557
+ }
37558
+ };
37559
+ QuestionCompositeModel.prototype.getEditingSurveyElement = function () {
37560
+ return this.editingObjValue;
37561
+ };
37527
37562
  QuestionCompositeModel.prototype.getTextProcessor = function () {
37528
37563
  return this.textProcessing;
37529
37564
  };
@@ -37583,6 +37618,11 @@ var QuestionCompositeModel = /** @class */ (function (_super) {
37583
37618
  }
37584
37619
  _super.prototype.onReadOnlyChanged.call(this);
37585
37620
  };
37621
+ QuestionCompositeModel.prototype.updateValueFromSurvey = function (newValue, clearData) {
37622
+ if (clearData === void 0) { clearData = false; }
37623
+ this.updateEditingObj();
37624
+ _super.prototype.updateValueFromSurvey.call(this, newValue, clearData);
37625
+ };
37586
37626
  QuestionCompositeModel.prototype.onSurveyLoad = function () {
37587
37627
  this.isSettingValOnLoading = true;
37588
37628
  if (!!this.contentPanel) {
@@ -37754,7 +37794,7 @@ var QuestionCompositeModel = /** @class */ (function (_super) {
37754
37794
  var key = questions[i].getValueName();
37755
37795
  var val = !!newValue ? newValue[key] : undefined;
37756
37796
  var q = questions[i];
37757
- if (!this.isTwoValueEquals(q.value, val)) {
37797
+ if (!this.isTwoValueEquals(q.value, val) && (val !== undefined || !q.isEmpty())) {
37758
37798
  q.value = val;
37759
37799
  }
37760
37800
  }
@@ -39476,9 +39516,11 @@ var QuestionFileModel = /** @class */ (function (_super) {
39476
39516
  });
39477
39517
  QuestionFileModel.prototype.chooseFile = function (event) {
39478
39518
  var _this = this;
39479
- if (!_global_variables_utils__WEBPACK_IMPORTED_MODULE_12__["DomDocumentHelper"].isAvailable())
39519
+ if (!this.rootElement)
39520
+ return;
39521
+ var inputElement = this.rootElement.querySelector("#" + this.inputId);
39522
+ if (!inputElement)
39480
39523
  return;
39481
- var inputElement = _global_variables_utils__WEBPACK_IMPORTED_MODULE_12__["DomDocumentHelper"].getDocument().getElementById(this.inputId);
39482
39524
  event.preventDefault();
39483
39525
  event.stopImmediatePropagation();
39484
39526
  if (inputElement) {
@@ -40025,9 +40067,11 @@ var QuestionFileModel = /** @class */ (function (_super) {
40025
40067
  return false;
40026
40068
  };
40027
40069
  QuestionFileModel.prototype.canDragDrop = function () { return !this.isInputReadOnly && this.currentMode !== "camera" && !this.isPlayingVideo; };
40028
- QuestionFileModel.prototype.afterRender = function (el) {
40070
+ QuestionFileModel.prototype.afterRenderQuestionElement = function (el) {
40029
40071
  this.rootElement = el;
40030
- _super.prototype.afterRender.call(this, el);
40072
+ };
40073
+ QuestionFileModel.prototype.beforeDestroyQuestionElement = function (el) {
40074
+ this.rootElement = undefined;
40031
40075
  };
40032
40076
  QuestionFileModel.prototype.clearFilesCore = function () {
40033
40077
  if (this.rootElement) {
@@ -42974,6 +43018,7 @@ var MatrixDropdownRowModelBase = /** @class */ (function () {
42974
43018
  var survey = this.getSurvey();
42975
43019
  return !!survey ? survey.getQuestionByName(name) : null;
42976
43020
  };
43021
+ MatrixDropdownRowModelBase.prototype.getEditingSurveyElement = function () { return undefined; };
42977
43022
  MatrixDropdownRowModelBase.prototype.setValueCore = function (name, newColumnValue, isComment) {
42978
43023
  if (this.isSettingValue)
42979
43024
  return;
@@ -46321,30 +46366,34 @@ _jsonobject__WEBPACK_IMPORTED_MODULE_0__["Serializer"].addClass("matrixdropdownc
46321
46366
  },
46322
46367
  {
46323
46368
  name: "totalType",
46369
+ visibleIf: function (obj) { return !obj.isShowInMultipleColumns; },
46324
46370
  default: "none",
46325
46371
  choices: ["none", "sum", "count", "min", "max", "avg"],
46326
46372
  },
46327
- "totalExpression:expression",
46328
- { name: "totalFormat", serializationProperty: "locTotalFormat" },
46373
+ { name: "totalExpression:expression", visibleIf: function (obj) { return !obj.isShowInMultipleColumns; } },
46374
+ { name: "totalFormat", serializationProperty: "locTotalFormat", visibleIf: function (obj) { return obj.hasTotal; } },
46329
46375
  {
46330
46376
  name: "totalDisplayStyle",
46377
+ visibleIf: function (obj) { return obj.hasTotal; },
46331
46378
  default: "none",
46332
46379
  choices: ["none", "decimal", "currency", "percent"],
46333
46380
  },
46334
46381
  {
46335
46382
  name: "totalAlignment",
46383
+ visibleIf: function (obj) { return obj.hasTotal; },
46336
46384
  default: "auto",
46337
46385
  choices: ["auto", "left", "center", "right"],
46338
46386
  },
46339
46387
  {
46340
46388
  name: "totalCurrency",
46389
+ visibleIf: function (obj) { return obj.hasTotal; },
46341
46390
  choices: function () {
46342
46391
  return Object(_question_expression__WEBPACK_IMPORTED_MODULE_2__["getCurrecyCodes"])();
46343
46392
  },
46344
46393
  default: "USD",
46345
46394
  },
46346
- { name: "totalMaximumFractionDigits:number", default: -1 },
46347
- { name: "totalMinimumFractionDigits:number", default: -1 },
46395
+ { name: "totalMaximumFractionDigits:number", default: -1, visibleIf: function (obj) { return obj.hasTotal; } },
46396
+ { name: "totalMinimumFractionDigits:number", default: -1, visibleIf: function (obj) { return obj.hasTotal; } },
46348
46397
  { name: "renderAs", default: "default", visible: false },
46349
46398
  ], function () {
46350
46399
  return new MatrixDropdownColumn("");
@@ -49281,6 +49330,7 @@ var MultipleTextItemModel = /** @class */ (function (_super) {
49281
49330
  var survey = this.getSurvey();
49282
49331
  return !!survey ? survey.getQuestionByName(name) : null;
49283
49332
  };
49333
+ MultipleTextItemModel.prototype.getEditingSurveyElement = function () { return undefined; };
49284
49334
  //IValidatorOwner
49285
49335
  MultipleTextItemModel.prototype.getValidatorTitle = function () {
49286
49336
  return this.title;
@@ -50214,6 +50264,7 @@ var QuestionPanelDynamicItem = /** @class */ (function () {
50214
50264
  var survey = this.getSurvey();
50215
50265
  return !!survey ? survey.getQuestionByName(name) : null;
50216
50266
  };
50267
+ QuestionPanelDynamicItem.prototype.getEditingSurveyElement = function () { return undefined; };
50217
50268
  QuestionPanelDynamicItem.prototype.getAllValues = function () {
50218
50269
  return this.data.getPanelItemData(this);
50219
50270
  };
@@ -56133,6 +56184,7 @@ var QuestionTextModel = /** @class */ (function (_super) {
56133
56184
  _this.updateRemainingCharacterCounter(event.target.value);
56134
56185
  };
56135
56186
  _this.onKeyDown = function (event) {
56187
+ _this.updateDateValidationMessage(event);
56136
56188
  _this.onKeyDownPreprocess && _this.onKeyDownPreprocess(event);
56137
56189
  if (_this.isInputTextUpdate) {
56138
56190
  _this._isWaitingForEnter = event.keyCode === 229;
@@ -56140,6 +56192,7 @@ var QuestionTextModel = /** @class */ (function (_super) {
56140
56192
  _this.onTextKeyDownHandler(event);
56141
56193
  };
56142
56194
  _this.onChange = function (event) {
56195
+ _this.updateDateValidationMessage(event);
56143
56196
  var elementIsFocused = event.target === _settings__WEBPACK_IMPORTED_MODULE_6__["settings"].environment.root.activeElement;
56144
56197
  if (elementIsFocused) {
56145
56198
  if (_this.isInputTextUpdate) {
@@ -56571,6 +56624,9 @@ var QuestionTextModel = /** @class */ (function (_super) {
56571
56624
  };
56572
56625
  errors.push(maxError);
56573
56626
  }
56627
+ if (!!this.dateValidationMessage) {
56628
+ errors.push(new _error__WEBPACK_IMPORTED_MODULE_5__["CustomError"](this.dateValidationMessage, this));
56629
+ }
56574
56630
  var valName = this.getValidatorTitle();
56575
56631
  var emailValidator = new _validator__WEBPACK_IMPORTED_MODULE_4__["EmailValidator"]();
56576
56632
  if (this.inputType === "email" &&
@@ -56721,6 +56777,9 @@ var QuestionTextModel = /** @class */ (function (_super) {
56721
56777
  };
56722
56778
  QuestionTextModel.prototype.setNewValue = function (newValue) {
56723
56779
  newValue = this.correctValueType(newValue);
56780
+ if (!!newValue) {
56781
+ this.dateValidationMessage = undefined;
56782
+ }
56724
56783
  _super.prototype.setNewValue.call(this, newValue);
56725
56784
  };
56726
56785
  QuestionTextModel.prototype.correctValueType = function (newValue) {
@@ -56771,6 +56830,9 @@ var QuestionTextModel = /** @class */ (function (_super) {
56771
56830
  this.inputValue = newValue;
56772
56831
  }
56773
56832
  };
56833
+ QuestionTextModel.prototype.updateDateValidationMessage = function (event) {
56834
+ this.dateValidationMessage = this.isDateInputType && !!event.target ? event.target.validationMessage : undefined;
56835
+ };
56774
56836
  QuestionTextModel.prototype.afterRenderQuestionElement = function (el) {
56775
56837
  if (!!el) {
56776
56838
  this.input = el instanceof HTMLInputElement ? el : el.querySelector("input");
@@ -56969,7 +57031,7 @@ _jsonobject__WEBPACK_IMPORTED_MODULE_1__["Serializer"].addClass("text", [
56969
57031
  name: "maskSettings:masksettings",
56970
57032
  className: "masksettings",
56971
57033
  visibleIndex: 1,
56972
- dependsOn: "inputType",
57034
+ dependsOn: ["inputType", "maskType"],
56973
57035
  visibleIf: function (obj) {
56974
57036
  return obj.inputType === "text" || obj.inputType === "tel";
56975
57037
  },
@@ -61132,8 +61194,8 @@ var SurveyModel = /** @class */ (function (_super) {
61132
61194
  _this.isNavigationButtonPressed = false;
61133
61195
  _this.mouseDownPage = null;
61134
61196
  _this.isCalculatingProgressText = false;
61135
- _this.isFirstPageRendering = true;
61136
61197
  _this.isCurrentPageRendering = true;
61198
+ _this.isCurrentPageRendered = undefined;
61137
61199
  _this.isTriggerIsRunning = false;
61138
61200
  _this.triggerValues = null;
61139
61201
  _this.triggerKeys = null;
@@ -63676,9 +63738,7 @@ var SurveyModel = /** @class */ (function (_super) {
63676
63738
  var _this = this;
63677
63739
  if (this.editingObj == val)
63678
63740
  return;
63679
- if (!!this.editingObj) {
63680
- this.editingObj.onPropertyChanged.remove(this.onEditingObjPropertyChanged);
63681
- }
63741
+ this.unConnectEditingObj();
63682
63742
  this.editingObjValue = val;
63683
63743
  if (this.isDisposed)
63684
63744
  return;
@@ -63704,6 +63764,11 @@ var SurveyModel = /** @class */ (function (_super) {
63704
63764
  enumerable: false,
63705
63765
  configurable: true
63706
63766
  });
63767
+ SurveyModel.prototype.unConnectEditingObj = function () {
63768
+ if (!!this.editingObj && !this.editingObj.isDisposed) {
63769
+ this.editingObj.onPropertyChanged.remove(this.onEditingObjPropertyChanged);
63770
+ }
63771
+ };
63707
63772
  Object.defineProperty(SurveyModel.prototype, "isEditingSurveyElement", {
63708
63773
  get: function () {
63709
63774
  return !!this.editingObj;
@@ -64381,6 +64446,9 @@ var SurveyModel = /** @class */ (function (_super) {
64381
64446
  oldValue.passed = true;
64382
64447
  }
64383
64448
  }
64449
+ if (this.isCurrentPageRendered === true) {
64450
+ this.isCurrentPageRendered = false;
64451
+ }
64384
64452
  this.onCurrentPageChanged.fire(this, options);
64385
64453
  };
64386
64454
  SurveyModel.prototype.notifyQuestionsOnHidingContent = function (page) {
@@ -65837,11 +65905,11 @@ var SurveyModel = /** @class */ (function (_super) {
65837
65905
  SurveyModel.prototype.afterRenderPage = function (htmlElement) {
65838
65906
  var _this = this;
65839
65907
  if (!this.isDesignMode && !this.focusingQuestionInfo) {
65840
- var doScroll_1 = !this.isFirstPageRendering;
65908
+ var doScroll_1 = this.isCurrentPageRendered === false;
65841
65909
  setTimeout(function () { return _this.scrollToTopOnPageChange(doScroll_1); }, 1);
65842
65910
  }
65843
65911
  this.focusQuestionInfo();
65844
- this.isFirstPageRendering = false;
65912
+ this.isCurrentPageRendered = true;
65845
65913
  if (this.onAfterRenderPage.isEmpty)
65846
65914
  return;
65847
65915
  this.onAfterRenderPage.fire(this, {
@@ -66379,6 +66447,7 @@ var SurveyModel = /** @class */ (function (_super) {
66379
66447
  SurveyModel.prototype.findQuestionByName = function (name) {
66380
66448
  return this.getQuestionByName(name);
66381
66449
  };
66450
+ SurveyModel.prototype.getEditingSurveyElement = function () { return this.editingObjValue; };
66382
66451
  /**
66383
66452
  * Returns a question with a specified [`valueName`](https://surveyjs.io/form-library/documentation/api-reference/question#valueName).
66384
66453
  *
@@ -68623,6 +68692,7 @@ var SurveyModel = /** @class */ (function (_super) {
68623
68692
  * Call this method to release resources if your application contains multiple survey models or if you re-create a survey model at runtime.
68624
68693
  */
68625
68694
  SurveyModel.prototype.dispose = function () {
68695
+ this.unConnectEditingObj();
68626
68696
  this.removeScrollEventListener();
68627
68697
  this.destroyResizeObserver();
68628
68698
  this.rootElement = undefined;
@@ -69100,7 +69170,7 @@ _jsonobject__WEBPACK_IMPORTED_MODULE_1__["Serializer"].addClass("survey", [
69100
69170
  default: "auto",
69101
69171
  choices: ["auto", "static", "responsive"],
69102
69172
  },
69103
- { name: "gridLayoutEnabled:boolean", default: false, visible: false },
69173
+ { name: "gridLayoutEnabled:boolean", default: false },
69104
69174
  { name: "width", visibleIf: function (obj) { return obj.widthMode === "static"; } },
69105
69175
  { name: "fitToContainer:boolean", default: true, visible: false },
69106
69176
  { name: "headerView", default: "basic", choices: ["basic", "advanced"], visible: false },
@@ -71534,6 +71604,8 @@ function _setIsTouch(val) {
71534
71604
  function detectMouseSupport(matchMedia) {
71535
71605
  if (!matchMedia)
71536
71606
  return false;
71607
+ if (IsMobile)
71608
+ return false;
71537
71609
  var pointerQuery = matchMedia("(pointer:fine)");
71538
71610
  var hoverQuery = matchMedia("(any-hover:hover)");
71539
71611
  return !!pointerQuery && pointerQuery.matches || !!hoverQuery && hoverQuery.matches;