survey-core 1.10.1 → 1.10.3

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 (253) hide show
  1. package/defaultV2.css +132 -20
  2. package/defaultV2.css.map +1 -1
  3. package/defaultV2.fontless.css +132 -20
  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 +3 -3
  24. package/i18n/english.js.map +1 -1
  25. package/i18n/english.min.js +2 -2
  26. package/i18n/estonian.js +1 -1
  27. package/i18n/estonian.min.js +1 -1
  28. package/i18n/finnish.js +1 -1
  29. package/i18n/finnish.min.js +1 -1
  30. package/i18n/french.js +1 -1
  31. package/i18n/french.min.js +1 -1
  32. package/i18n/georgian.js +1 -1
  33. package/i18n/georgian.min.js +1 -1
  34. package/i18n/german.js +8 -25
  35. package/i18n/german.js.map +1 -1
  36. package/i18n/german.min.js +2 -2
  37. package/i18n/greek.js +1 -1
  38. package/i18n/greek.min.js +1 -1
  39. package/i18n/hebrew.js +1 -1
  40. package/i18n/hebrew.min.js +1 -1
  41. package/i18n/hindi.js +1 -1
  42. package/i18n/hindi.min.js +1 -1
  43. package/i18n/hungarian.js +1 -1
  44. package/i18n/hungarian.min.js +1 -1
  45. package/i18n/icelandic.js +1 -1
  46. package/i18n/icelandic.min.js +1 -1
  47. package/i18n/index.js +8 -25
  48. package/i18n/index.js.map +1 -1
  49. package/i18n/index.min.js +2 -2
  50. package/i18n/indonesian.js +1 -1
  51. package/i18n/indonesian.min.js +1 -1
  52. package/i18n/italian.js +1 -1
  53. package/i18n/italian.min.js +1 -1
  54. package/i18n/japanese.js +1 -1
  55. package/i18n/japanese.min.js +1 -1
  56. package/i18n/kazakh.js +1 -1
  57. package/i18n/kazakh.min.js +1 -1
  58. package/i18n/korean.js +1 -1
  59. package/i18n/korean.min.js +1 -1
  60. package/i18n/latvian.js +1 -1
  61. package/i18n/latvian.min.js +1 -1
  62. package/i18n/lithuanian.js +1 -1
  63. package/i18n/lithuanian.min.js +1 -1
  64. package/i18n/macedonian.js +1 -1
  65. package/i18n/macedonian.min.js +1 -1
  66. package/i18n/malay.js +1 -1
  67. package/i18n/malay.min.js +1 -1
  68. package/i18n/nl-BE.js +1 -1
  69. package/i18n/nl-BE.min.js +1 -1
  70. package/i18n/norwegian.js +1 -1
  71. package/i18n/norwegian.min.js +1 -1
  72. package/i18n/persian.js +1 -1
  73. package/i18n/persian.min.js +1 -1
  74. package/i18n/polish.js +1 -1
  75. package/i18n/polish.min.js +1 -1
  76. package/i18n/portuguese-br.js +1 -1
  77. package/i18n/portuguese-br.min.js +1 -1
  78. package/i18n/portuguese.js +1 -1
  79. package/i18n/portuguese.min.js +1 -1
  80. package/i18n/romanian.js +1 -1
  81. package/i18n/romanian.min.js +1 -1
  82. package/i18n/russian.js +1 -1
  83. package/i18n/russian.min.js +1 -1
  84. package/i18n/serbian.js +1 -1
  85. package/i18n/serbian.min.js +1 -1
  86. package/i18n/simplified-chinese.js +1 -1
  87. package/i18n/simplified-chinese.min.js +1 -1
  88. package/i18n/slovak.js +1 -1
  89. package/i18n/slovak.min.js +1 -1
  90. package/i18n/spanish.js +1 -1
  91. package/i18n/spanish.min.js +1 -1
  92. package/i18n/swahili.js +1 -1
  93. package/i18n/swahili.min.js +1 -1
  94. package/i18n/swedish.js +1 -1
  95. package/i18n/swedish.min.js +1 -1
  96. package/i18n/tajik.js +1 -1
  97. package/i18n/tajik.min.js +1 -1
  98. package/i18n/telugu.js +1 -1
  99. package/i18n/telugu.min.js +1 -1
  100. package/i18n/thai.js +1 -1
  101. package/i18n/thai.min.js +1 -1
  102. package/i18n/traditional-chinese.js +1 -1
  103. package/i18n/traditional-chinese.min.js +1 -1
  104. package/i18n/turkish.js +1 -1
  105. package/i18n/turkish.min.js +1 -1
  106. package/i18n/ukrainian.js +1 -1
  107. package/i18n/ukrainian.min.js +1 -1
  108. package/i18n/urdu.js +1 -1
  109. package/i18n/urdu.min.js +1 -1
  110. package/i18n/vietnamese.js +1 -1
  111. package/i18n/vietnamese.min.js +1 -1
  112. package/i18n/welsh.js +1 -1
  113. package/i18n/welsh.min.js +1 -1
  114. package/modern.css +13 -1
  115. package/modern.css.map +1 -1
  116. package/modern.fontless.css +13 -1
  117. package/modern.fontless.css.map +1 -1
  118. package/modern.fontless.min.css +2 -2
  119. package/modern.min.css +2 -2
  120. package/package.json +1 -1
  121. package/plugins/bootstrap-integration.js +1 -1
  122. package/plugins/bootstrap-integration.min.js +1 -1
  123. package/plugins/bootstrap-material-integration.js +1 -1
  124. package/plugins/bootstrap-material-integration.min.js +1 -1
  125. package/survey.core.js +327 -181
  126. package/survey.core.js.map +1 -1
  127. package/survey.core.min.js +3 -3
  128. package/survey.css +387 -1
  129. package/survey.css.map +1 -1
  130. package/survey.i18n.js +8 -25
  131. package/survey.i18n.js.map +1 -1
  132. package/survey.i18n.min.js +2 -2
  133. package/survey.min.css +2 -2
  134. package/themes/borderless-dark-panelless.js +1 -1
  135. package/themes/borderless-dark-panelless.min.js +1 -1
  136. package/themes/borderless-dark.js +1 -1
  137. package/themes/borderless-dark.min.js +1 -1
  138. package/themes/borderless-light-panelless..js +1 -1
  139. package/themes/borderless-light-panelless..min.js +1 -1
  140. package/themes/borderless-light.js +1 -1
  141. package/themes/borderless-light.min.js +1 -1
  142. package/themes/contrast-dark-panelless.js +1 -1
  143. package/themes/contrast-dark-panelless.min.js +1 -1
  144. package/themes/contrast-dark.js +1 -1
  145. package/themes/contrast-dark.min.js +1 -1
  146. package/themes/contrast-light-panelless.js +1 -1
  147. package/themes/contrast-light-panelless.min.js +1 -1
  148. package/themes/contrast-light.js +1 -1
  149. package/themes/contrast-light.min.js +1 -1
  150. package/themes/default-dark-panelless.js +1 -1
  151. package/themes/default-dark-panelless.min.js +1 -1
  152. package/themes/default-dark.js +1 -1
  153. package/themes/default-dark.min.js +1 -1
  154. package/themes/default-light-panelless.js +1 -1
  155. package/themes/default-light-panelless.min.js +1 -1
  156. package/themes/default-light.js +1 -1
  157. package/themes/default-light.min.js +1 -1
  158. package/themes/doubleborder-dark-panelless.js +1 -1
  159. package/themes/doubleborder-dark-panelless.min.js +1 -1
  160. package/themes/doubleborder-dark.js +1 -1
  161. package/themes/doubleborder-dark.min.js +1 -1
  162. package/themes/doubleborder-light-panelles.js +1 -1
  163. package/themes/doubleborder-light-panelles.min.js +1 -1
  164. package/themes/doubleborder-light.js +1 -1
  165. package/themes/doubleborder-light.min.js +1 -1
  166. package/themes/flat-dark-panelless.js +1 -1
  167. package/themes/flat-dark-panelless.min.js +1 -1
  168. package/themes/flat-dark.js +1 -1
  169. package/themes/flat-dark.min.js +1 -1
  170. package/themes/flat-light-panelless.js +1 -1
  171. package/themes/flat-light-panelless.min.js +1 -1
  172. package/themes/flat-light.js +1 -1
  173. package/themes/flat-light.min.js +1 -1
  174. package/themes/index.js +1 -1
  175. package/themes/index.min.js +1 -1
  176. package/themes/layered-dark-panelless.js +1 -1
  177. package/themes/layered-dark-panelless.min.js +1 -1
  178. package/themes/layered-dark.js +1 -1
  179. package/themes/layered-dark.min.js +1 -1
  180. package/themes/layered-light-panelless.js +1 -1
  181. package/themes/layered-light-panelless.min.js +1 -1
  182. package/themes/layered-light.js +1 -1
  183. package/themes/layered-light.min.js +1 -1
  184. package/themes/plain-dark-panelless.js +1 -1
  185. package/themes/plain-dark-panelless.min.js +1 -1
  186. package/themes/plain-dark.js +1 -1
  187. package/themes/plain-dark.min.js +1 -1
  188. package/themes/plain-light-panelless.js +1 -1
  189. package/themes/plain-light-panelless.min.js +1 -1
  190. package/themes/plain-light.js +1 -1
  191. package/themes/plain-light.min.js +1 -1
  192. package/themes/sharp-dark-panelless.js +1 -1
  193. package/themes/sharp-dark-panelless.min.js +1 -1
  194. package/themes/sharp-dark.js +1 -1
  195. package/themes/sharp-dark.min.js +1 -1
  196. package/themes/sharp-light-panelless.js +1 -1
  197. package/themes/sharp-light-panelless.min.js +1 -1
  198. package/themes/sharp-light.js +1 -1
  199. package/themes/sharp-light.min.js +1 -1
  200. package/themes/solid-dark-panelless.js +1 -1
  201. package/themes/solid-dark-panelless.min.js +1 -1
  202. package/themes/solid-dark.js +1 -1
  203. package/themes/solid-dark.min.js +1 -1
  204. package/themes/solid-light-panelless.js +1 -1
  205. package/themes/solid-light-panelless.min.js +1 -1
  206. package/themes/solid-light.js +1 -1
  207. package/themes/solid-light.min.js +1 -1
  208. package/themes/three-dimensional-dark-panelless.js +1 -1
  209. package/themes/three-dimensional-dark-panelless.min.js +1 -1
  210. package/themes/three-dimensional-dark.js +1 -1
  211. package/themes/three-dimensional-dark.min.js +1 -1
  212. package/themes/three-dimensional-light-panelless.js +1 -1
  213. package/themes/three-dimensional-light-panelless.min.js +1 -1
  214. package/themes/three-dimensional-light.js +1 -1
  215. package/themes/three-dimensional-light.min.js +1 -1
  216. package/ts3.4/typings/base.d.ts +6 -2
  217. package/ts3.4/typings/defaultCss/defaultV2Css.d.ts +2 -0
  218. package/ts3.4/typings/dragdrop/dom-adapter.d.ts +2 -0
  219. package/ts3.4/typings/dropdownListModel.d.ts +1 -0
  220. package/ts3.4/typings/list.d.ts +2 -2
  221. package/ts3.4/typings/multiSelectListModel.d.ts +1 -1
  222. package/ts3.4/typings/page.d.ts +0 -2
  223. package/ts3.4/typings/panel.d.ts +2 -0
  224. package/ts3.4/typings/popup.d.ts +8 -12
  225. package/ts3.4/typings/question_baseselect.d.ts +1 -1
  226. package/ts3.4/typings/question_boolean.d.ts +5 -0
  227. package/ts3.4/typings/question_file.d.ts +2 -1
  228. package/ts3.4/typings/question_imagepicker.d.ts +1 -0
  229. package/ts3.4/typings/question_matrix.d.ts +3 -3
  230. package/ts3.4/typings/question_radiogroup.d.ts +1 -0
  231. package/ts3.4/typings/question_tagbox.d.ts +2 -0
  232. package/ts3.4/typings/rendererFactory.d.ts +3 -2
  233. package/ts3.4/typings/survey.d.ts +1 -0
  234. package/ts3.4/typings/utils/animation.d.ts +1 -0
  235. package/typings/base.d.ts +6 -2
  236. package/typings/defaultCss/defaultV2Css.d.ts +2 -0
  237. package/typings/dragdrop/dom-adapter.d.ts +2 -0
  238. package/typings/dropdownListModel.d.ts +1 -0
  239. package/typings/list.d.ts +2 -2
  240. package/typings/multiSelectListModel.d.ts +1 -1
  241. package/typings/page.d.ts +0 -2
  242. package/typings/panel.d.ts +2 -0
  243. package/typings/popup.d.ts +8 -12
  244. package/typings/question_baseselect.d.ts +1 -1
  245. package/typings/question_boolean.d.ts +5 -0
  246. package/typings/question_file.d.ts +3 -1
  247. package/typings/question_imagepicker.d.ts +1 -0
  248. package/typings/question_matrix.d.ts +4 -3
  249. package/typings/question_radiogroup.d.ts +1 -0
  250. package/typings/question_tagbox.d.ts +2 -0
  251. package/typings/rendererFactory.d.ts +3 -2
  252. package/typings/survey.d.ts +1 -0
  253. package/typings/utils/animation.d.ts +1 -0
package/survey.core.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * surveyjs - Survey JavaScript library v1.10.1
2
+ * surveyjs - Survey JavaScript library v1.10.3
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
  */
@@ -742,11 +742,12 @@ function createDropdownActionModelAdvanced(actionOptions, listOptions, popupOpti
742
742
  }
743
743
  listOptions.onSelectionChanged(item);
744
744
  innerPopupModel.toggleVisibility();
745
- }, listOptions.allowSelection, listOptions.selectedItem, listOptions.onFilterStringChangedCallback);
745
+ }, listOptions.allowSelection, listOptions.selectedItem);
746
746
  listModel.locOwner = locOwner;
747
- var innerPopupModel = new _popup__WEBPACK_IMPORTED_MODULE_4__["PopupModel"]("sv-list", { model: listModel }, popupOptions === null || popupOptions === void 0 ? void 0 : popupOptions.verticalPosition, popupOptions === null || popupOptions === void 0 ? void 0 : popupOptions.horizontalPosition, popupOptions === null || popupOptions === void 0 ? void 0 : popupOptions.showPointer, popupOptions === null || popupOptions === void 0 ? void 0 : popupOptions.isModal, popupOptions === null || popupOptions === void 0 ? void 0 : popupOptions.onCancel, popupOptions === null || popupOptions === void 0 ? void 0 : popupOptions.onApply, popupOptions === null || popupOptions === void 0 ? void 0 : popupOptions.onHide, popupOptions === null || popupOptions === void 0 ? void 0 : popupOptions.onShow, popupOptions === null || popupOptions === void 0 ? void 0 : popupOptions.cssClass, popupOptions === null || popupOptions === void 0 ? void 0 : popupOptions.title, function () {
748
- listModel.dispose();
749
- });
747
+ listModel.setOnFilterStringChangedCallback(listOptions.onFilterStringChangedCallback);
748
+ var options = popupOptions || {};
749
+ options.onDispose = function () { listModel.dispose(); };
750
+ var innerPopupModel = new _popup__WEBPACK_IMPORTED_MODULE_4__["PopupModel"]("sv-list", { model: listModel }, options);
750
751
  innerPopupModel.displayMode = popupOptions === null || popupOptions === void 0 ? void 0 : popupOptions.displayMode;
751
752
  var newActionOptions = Object.assign({}, actionOptions, {
752
753
  component: "sv-action-bar-item-dropdown",
@@ -770,7 +771,6 @@ var BaseAction = /** @class */ (function (_super) {
770
771
  function BaseAction() {
771
772
  var _this = _super !== null && _super.apply(this, arguments) || this;
772
773
  _this.rendredIdValue = BaseAction.getNextRendredId();
773
- _this.iconSize = 24;
774
774
  return _this;
775
775
  }
776
776
  BaseAction.getNextRendredId = function () { return BaseAction.renderedId++; };
@@ -973,7 +973,7 @@ var BaseAction = /** @class */ (function (_super) {
973
973
  Object(_jsonobject__WEBPACK_IMPORTED_MODULE_2__["property"])()
974
974
  ], BaseAction.prototype, "iconName", void 0);
975
975
  __decorate([
976
- Object(_jsonobject__WEBPACK_IMPORTED_MODULE_2__["property"])()
976
+ Object(_jsonobject__WEBPACK_IMPORTED_MODULE_2__["property"])({ defaultValue: 24 })
977
977
  ], BaseAction.prototype, "iconSize", void 0);
978
978
  __decorate([
979
979
  Object(_jsonobject__WEBPACK_IMPORTED_MODULE_2__["property"])()
@@ -994,9 +994,9 @@ var Action = /** @class */ (function (_super) {
994
994
  //Object.assign(this, item) to support IE11
995
995
  if (!!innerItem) {
996
996
  for (var key in innerItem) {
997
- if (key !== "locTitle") {
998
- _this[key] = innerItem[key];
999
- }
997
+ if (key === "locTitle" || key === "title" && !!_this.locTitle && !!_this.title)
998
+ continue;
999
+ _this[key] = innerItem[key];
1000
1000
  }
1001
1001
  }
1002
1002
  if (!!_this.locTitleName) {
@@ -1847,6 +1847,8 @@ var Base = /** @class */ (function () {
1847
1847
  * A new value for the property.
1848
1848
  * - `options.oldValue`: `any`\
1849
1849
  * An old value of the property. If the property is an array, `oldValue` contains the same array as `newValue` does.
1850
+ *
1851
+ * If you need to add and remove property change event handlers dynamically, use the [`registerPropertyChangedHandlers`](#registerPropertyChangedHandlers) and [`unregisterPropertyChangedHandlers`](#unregisterPropertyChangedHandlers) methods instead.
1850
1852
  */
1851
1853
  this.onPropertyChanged = this.addEvent();
1852
1854
  /**
@@ -2242,8 +2244,6 @@ var Base = /** @class */ (function () {
2242
2244
  * @param val A new value for the property.
2243
2245
  */
2244
2246
  Base.prototype.setPropertyValue = function (name, val) {
2245
- if (name) {
2246
- }
2247
2247
  if (!this.isLoadingFromJson) {
2248
2248
  var prop = this.getPropertyByName(name);
2249
2249
  if (!!prop) {
@@ -2419,9 +2419,11 @@ var Base = /** @class */ (function () {
2419
2419
  return res;
2420
2420
  };
2421
2421
  /**
2422
- * Registers a function to call when a property value changes.
2422
+ * Registers a single value change handler for one or multiple properties.
2423
+ *
2424
+ * The `registerPropertyChangedHandlers` and [`unregisterPropertyChangedHandlers`](#unregisterPropertyChangedHandlers) methods allow you to manage property change event handlers dynamically. If you only need to attach an event handler without removing it afterwards, you can use the [`onPropertyChanged`](#onPropertyChanged) event instead.
2423
2425
  * @param propertyNames An array of one or multiple property names.
2424
- * @param handler A function to call when one of the listed properties change.
2426
+ * @param handler A function to call when one of the listed properties change. Accepts a new property value as an argument.
2425
2427
  * @param key *(Optional)* A key that identifies the current registration. If a function for one of the properties is already registered with the same key, the function will be overwritten. You can also use the key to subsequently unregister handlers.
2426
2428
  * @see unregisterPropertyChangedHandlers
2427
2429
  */
@@ -6037,6 +6039,8 @@ var defaultV2Css = {
6037
6039
  selectWrapper: "sv-dropdown_select-wrapper",
6038
6040
  controlValue: "sd-dropdown__value",
6039
6041
  controlDisabled: "sd-input--disabled",
6042
+ controlReadOnly: "sd-input--readonly",
6043
+ controlPreview: "sd-input--preview",
6040
6044
  controlEmpty: "sd-dropdown--empty",
6041
6045
  filterStringInput: "sd-dropdown__filter-string-input",
6042
6046
  chevronButton: "sd-dropdown_chevron-button",
@@ -7366,17 +7370,12 @@ var DragDropDOMAdapter = /** @class */ (function () {
7366
7370
  DragDropDOMAdapter.prototype.getShortcutRightCoordinate = function (currentX, shortcutWidth, shortcutXOffset) {
7367
7371
  return currentX + shortcutWidth - shortcutXOffset;
7368
7372
  };
7369
- DragDropDOMAdapter.prototype.doScroll = function (clientY, clientX) {
7373
+ DragDropDOMAdapter.prototype.requestAnimationFrame = function (callback) {
7374
+ return requestAnimationFrame(callback);
7375
+ };
7376
+ DragDropDOMAdapter.prototype.scrollByDrag = function (scrollableParentNode, clientY, clientX) {
7370
7377
  var _this = this;
7371
- cancelAnimationFrame(this.scrollIntervalId);
7372
7378
  var startScrollBoundary = 100;
7373
- var displayProp = this.draggedElementShortcut.style.display;
7374
- //this.draggedElementShortcut.hidden = true;
7375
- this.draggedElementShortcut.style.display = "none";
7376
- var dragOverNode = this.documentOrShadowRoot.elementFromPoint(clientX, clientY);
7377
- //this.draggedElementShortcut.hidden = false;
7378
- this.draggedElementShortcut.style.display = displayProp || "block";
7379
- var scrollableParentNode = Object(_utils_utils__WEBPACK_IMPORTED_MODULE_0__["findScrollableParent"])(dragOverNode);
7380
7379
  var top;
7381
7380
  var bottom;
7382
7381
  var left;
@@ -7394,21 +7393,36 @@ var DragDropDOMAdapter = /** @class */ (function () {
7394
7393
  right = scrollableParentNode.getBoundingClientRect().right;
7395
7394
  }
7396
7395
  var repeat = function () {
7397
- if (clientY - top <= startScrollBoundary) {
7396
+ var isTop = clientY - top <= startScrollBoundary;
7397
+ var isBottom = bottom - clientY <= startScrollBoundary;
7398
+ var isLeft = clientX - left <= startScrollBoundary;
7399
+ var isRight = right - clientX <= startScrollBoundary;
7400
+ if (isTop && !isLeft && !isRight) {
7398
7401
  scrollableParentNode.scrollTop -= 15;
7399
7402
  }
7400
- else if (bottom - clientY <= startScrollBoundary) {
7403
+ else if (isBottom && !isLeft && !isRight) {
7401
7404
  scrollableParentNode.scrollTop += 15;
7402
7405
  }
7403
- else if (right - clientX <= startScrollBoundary) {
7406
+ else if (isRight && !isTop && !isBottom) {
7404
7407
  scrollableParentNode.scrollLeft += 15;
7405
7408
  }
7406
- else if (clientX - left <= startScrollBoundary) {
7409
+ else if (isLeft && !isTop && !isBottom) {
7407
7410
  scrollableParentNode.scrollLeft -= 15;
7408
7411
  }
7409
- _this.scrollIntervalId = requestAnimationFrame(repeat);
7412
+ _this.scrollIntervalId = _this.requestAnimationFrame(repeat);
7410
7413
  };
7411
- this.scrollIntervalId = requestAnimationFrame(repeat);
7414
+ this.scrollIntervalId = this.requestAnimationFrame(repeat);
7415
+ };
7416
+ DragDropDOMAdapter.prototype.doScroll = function (clientY, clientX) {
7417
+ cancelAnimationFrame(this.scrollIntervalId);
7418
+ var displayProp = this.draggedElementShortcut.style.display;
7419
+ //this.draggedElementShortcut.hidden = true;
7420
+ this.draggedElementShortcut.style.display = "none";
7421
+ var dragOverNode = this.documentOrShadowRoot.elementFromPoint(clientX, clientY);
7422
+ //this.draggedElementShortcut.hidden = false;
7423
+ this.draggedElementShortcut.style.display = displayProp || "block";
7424
+ var scrollableParentNode = Object(_utils_utils__WEBPACK_IMPORTED_MODULE_0__["findScrollableParent"])(dragOverNode);
7425
+ this.scrollByDrag(scrollableParentNode, clientY, clientX);
7412
7426
  };
7413
7427
  DragDropDOMAdapter.prototype.doStartDrag = function (event, draggedElement, parentElement, draggedElementNode) {
7414
7428
  if (_utils_devices__WEBPACK_IMPORTED_MODULE_1__["IsTouch"]) {
@@ -7702,7 +7716,6 @@ var DragDropRankingChoices = /** @class */ (function (_super) {
7702
7716
  if (!draggedElementShortcut)
7703
7717
  return;
7704
7718
  draggedElementShortcut.className = this.shortcutClass + " sv-ranking-shortcut";
7705
- draggedElementShortcut.style.cssText = " \n cursor: grabbing;\n position: absolute;\n z-index: 10000;\n border-radius: calc(12.5 * var(--sjs-base-unit, var(--base-unit, 8px)));\n min-width: 100px;\n max-width: 400px;\n box-shadow: var(--sjs-shadow-medium, 0px 2px 6px 0px rgba(0, 0, 0, 0.1)), var(--sjs-shadow-large, 0px 8px 16px 0px rgba(0, 0, 0, 0.1));\n background-color: var(--sjs-general-backcolor, var(--background, #fff));\n font-family: var(--sjs-font-family, var(--font-family, var(--sjs-default-font-family)));\n ";
7706
7719
  var isDeepClone = true;
7707
7720
  var clone = draggedElementNode.cloneNode(isDeepClone);
7708
7721
  draggedElementShortcut.appendChild(clone);
@@ -8097,6 +8110,7 @@ var DropdownListModel = /** @class */ (function (_super) {
8097
8110
  _this.showInputFieldComponent = _this.question.showInputFieldComponent;
8098
8111
  _this.listModel = _this.createListModel();
8099
8112
  _this.updateAfterListModelCreated(_this.listModel);
8113
+ _this.setChoicesLazyLoadEnabled(_this.question.choicesLazyLoadEnabled);
8100
8114
  _this.setSearchEnabled(_this.question.searchEnabled);
8101
8115
  _this.setTextWrapEnabled(_this.question.textWrapEnabled);
8102
8116
  _this.createPopup();
@@ -8159,7 +8173,8 @@ var DropdownListModel = /** @class */ (function (_super) {
8159
8173
  };
8160
8174
  DropdownListModel.prototype.createPopup = function () {
8161
8175
  var _this = this;
8162
- this._popupModel = new _popup__WEBPACK_IMPORTED_MODULE_5__["PopupModel"]("sv-list", { model: this.listModel }, "bottom", "center", false);
8176
+ var popupOptions = { verticalPosition: "bottom", horizontalPosition: "center", showPointer: false };
8177
+ this._popupModel = new _popup__WEBPACK_IMPORTED_MODULE_5__["PopupModel"]("sv-list", { model: this.listModel }, popupOptions);
8163
8178
  this._popupModel.displayMode = _utils_devices__WEBPACK_IMPORTED_MODULE_9__["IsTouch"] ? "overlay" : "popup";
8164
8179
  this._popupModel.positionMode = "fixed";
8165
8180
  this._popupModel.isFocusedContainer = false;
@@ -8177,6 +8192,7 @@ var DropdownListModel = /** @class */ (function (_super) {
8177
8192
  }
8178
8193
  if (option.isVisible && _this.question.choicesLazyLoadEnabled) {
8179
8194
  _this.listModel.actions = [];
8195
+ _this.resetItemsSettings();
8180
8196
  _this.updateQuestionChoices();
8181
8197
  }
8182
8198
  if (option.isVisible && !!_this.question.onOpenedCallBack) {
@@ -8219,7 +8235,6 @@ var DropdownListModel = /** @class */ (function (_super) {
8219
8235
  DropdownListModel.prototype.onHidePopup = function () {
8220
8236
  this.resetFilterString();
8221
8237
  this.question.suggestedItem = null;
8222
- this.listModel.refresh();
8223
8238
  };
8224
8239
  DropdownListModel.prototype.getAvailableItems = function () {
8225
8240
  return this.question.visibleChoices;
@@ -8247,7 +8262,7 @@ var DropdownListModel = /** @class */ (function (_super) {
8247
8262
  _this.popupModel.isVisible = false;
8248
8263
  };
8249
8264
  }
8250
- var res = new _list__WEBPACK_IMPORTED_MODULE_4__["ListModel"](visibleItems, _onSelectionChanged, false, undefined, this.question.choicesLazyLoadEnabled ? this.listModelFilterStringChanged : undefined, this.listElementId);
8265
+ var res = new _list__WEBPACK_IMPORTED_MODULE_4__["ListModel"](visibleItems, _onSelectionChanged, false, undefined, this.listElementId);
8251
8266
  this.setOnTextSearchCallbackForListModel(res);
8252
8267
  res.renderElements = false;
8253
8268
  res.forceShowFilter = true;
@@ -8480,6 +8495,9 @@ var DropdownListModel = /** @class */ (function (_super) {
8480
8495
  this.listModel.showSearchClearButton = _utils_devices__WEBPACK_IMPORTED_MODULE_9__["IsTouch"];
8481
8496
  this.searchEnabled = newValue;
8482
8497
  };
8498
+ DropdownListModel.prototype.setChoicesLazyLoadEnabled = function (newValue) {
8499
+ this.listModel.setOnFilterStringChangedCallback(newValue ? this.listModelFilterStringChanged : undefined);
8500
+ };
8483
8501
  DropdownListModel.prototype.updateItems = function () {
8484
8502
  this.listModel.setItems(this.getAvailableItems());
8485
8503
  };
@@ -8499,9 +8517,6 @@ var DropdownListModel = /** @class */ (function (_super) {
8499
8517
  if (options.name == "value") {
8500
8518
  this.showInputFieldComponent = this.question.showInputFieldComponent;
8501
8519
  }
8502
- if (options.name == "choicesLazyLoadEnabled" && options.newValue) {
8503
- this.listModel.setOnFilterStringChangedCallback(this.listModelFilterStringChanged);
8504
- }
8505
8520
  if (options.name == "textWrapEnabled") {
8506
8521
  this.setTextWrapEnabled(options.newValue);
8507
8522
  }
@@ -8830,7 +8845,7 @@ var DropdownMultiSelectListModel = /** @class */ (function (_super) {
8830
8845
  }
8831
8846
  };
8832
8847
  }
8833
- var res = new _multiSelectListModel__WEBPACK_IMPORTED_MODULE_3__["MultiSelectListModel"](visibleItems, _onSelectionChanged, false, undefined, this.question.choicesLazyLoadEnabled ? this.listModelFilterStringChanged : undefined, this.listElementId);
8848
+ var res = new _multiSelectListModel__WEBPACK_IMPORTED_MODULE_3__["MultiSelectListModel"](visibleItems, _onSelectionChanged, false, undefined, this.listElementId);
8834
8849
  res.actions.forEach(function (a) { return a.disableTabStop = true; });
8835
8850
  this.setOnTextSearchCallbackForListModel(res);
8836
8851
  res.forceShowFilter = true;
@@ -9694,8 +9709,8 @@ __webpack_require__.r(__webpack_exports__);
9694
9709
 
9695
9710
  var Version;
9696
9711
  var ReleaseDate;
9697
- Version = "" + "1.10.1";
9698
- ReleaseDate = "" + "2024-04-25";
9712
+ Version = "" + "1.10.3";
9713
+ ReleaseDate = "" + "2024-05-07";
9699
9714
  function checkLibraryVersion(ver, libraryName) {
9700
9715
  if (Version != ver) {
9701
9716
  var str = "survey-core has version '" + Version + "' and " + libraryName
@@ -19221,10 +19236,18 @@ var JsonMetadata = /** @class */ (function () {
19221
19236
  return metaClass.getAllProperties();
19222
19237
  };
19223
19238
  JsonMetadata.prototype.getPropertiesByObj = function (obj) {
19224
- if (!obj || !obj.getType)
19239
+ var type = !!obj && !!obj.getType ? obj.getType() : undefined;
19240
+ if (!type)
19225
19241
  return [];
19226
- var props = this.getProperties(obj.getType());
19242
+ var props = this.getProperties(type);
19227
19243
  var dynamicProps = this.getDynamicPropertiesByObj(obj);
19244
+ for (var i = dynamicProps.length - 1; i >= 0; i--) {
19245
+ if (this.findProperty(type, dynamicProps[i].name)) {
19246
+ dynamicProps.splice(i, 1);
19247
+ }
19248
+ }
19249
+ if (dynamicProps.length === 0)
19250
+ return props;
19228
19251
  return [].concat(props).concat(dynamicProps);
19229
19252
  };
19230
19253
  JsonMetadata.prototype.addDynamicPropertiesIntoObj = function (dest, src, props) {
@@ -19935,7 +19958,7 @@ var JsonObject = /** @class */ (function () {
19935
19958
  this.removePosFromObj(value);
19936
19959
  };
19937
19960
  JsonObject.prototype.removePosFromObj = function (obj) {
19938
- if (!obj)
19961
+ if (!obj || typeof obj.getType === "function")
19939
19962
  return;
19940
19963
  if (Array.isArray(obj)) {
19941
19964
  for (var i = 0; i < obj.length; i++) {
@@ -20152,11 +20175,10 @@ var defaultListCss = {
20152
20175
  };
20153
20176
  var ListModel = /** @class */ (function (_super) {
20154
20177
  __extends(ListModel, _super);
20155
- function ListModel(items, onSelectionChanged, allowSelection, selectedItem, onFilterStringChangedCallback, elementId) {
20178
+ function ListModel(items, onSelectionChanged, allowSelection, selectedItem, elementId) {
20156
20179
  var _this = _super.call(this) || this;
20157
20180
  _this.onSelectionChanged = onSelectionChanged;
20158
20181
  _this.allowSelection = allowSelection;
20159
- _this.onFilterStringChangedCallback = onFilterStringChangedCallback;
20160
20182
  _this.elementId = elementId;
20161
20183
  _this.onItemClick = function (itemValue) {
20162
20184
  if (_this.isItemDisabled(itemValue)) {
@@ -21156,7 +21178,7 @@ var englishStrings = {
21156
21178
  questionsProgressText: "Answered {0}/{1} questions",
21157
21179
  emptySurvey: "The survey doesn't contain any visible elements.",
21158
21180
  completingSurvey: "Thank you for completing the survey",
21159
- completingSurveyBefore: "Our records show that you have already completed this survey.",
21181
+ completingSurveyBefore: "You have already completed this survey.",
21160
21182
  loadingSurvey: "Loading Survey...",
21161
21183
  placeholder: "Select...",
21162
21184
  ratingOptionsCaption: "Select...",
@@ -21206,7 +21228,7 @@ var englishStrings = {
21206
21228
  savingData: "The results are being saved on the server...",
21207
21229
  savingDataError: "An error occurred and we could not save the results.",
21208
21230
  savingDataSuccess: "The results were saved successfully!",
21209
- savingExceedSize: "Your response exceeds 64KB. Please reduce the size of your file(s) and try again or contact a survey owner.",
21231
+ savingExceedSize: "Your response exceeds 64KB. Please reduce the size of your file(s) and try again or contact the survey owner.",
21210
21232
  saveAgainButton: "Try again",
21211
21233
  timerMin: "min",
21212
21234
  timerSec: "sec",
@@ -23272,8 +23294,8 @@ var __decorate = (undefined && undefined.__decorate) || function (decorators, ta
23272
23294
 
23273
23295
  var MultiSelectListModel = /** @class */ (function (_super) {
23274
23296
  __extends(MultiSelectListModel, _super);
23275
- function MultiSelectListModel(items, onSelectionChanged, allowSelection, selectedItems, onFilterStringChangedCallback, elementId) {
23276
- var _this = _super.call(this, items, onSelectionChanged, allowSelection, undefined, onFilterStringChangedCallback, elementId) || this;
23297
+ function MultiSelectListModel(items, onSelectionChanged, allowSelection, selectedItems, elementId) {
23298
+ var _this = _super.call(this, items, onSelectionChanged, allowSelection, undefined, elementId) || this;
23277
23299
  _this.onItemClick = function (item) {
23278
23300
  if (_this.isItemDisabled(item))
23279
23301
  return;
@@ -23507,7 +23529,6 @@ var PageModel = /** @class */ (function (_super) {
23507
23529
  return _this.num + ". " + text;
23508
23530
  return text;
23509
23531
  };
23510
- _this.createLocalizableString("navigationTitle", _this, true);
23511
23532
  _this.createLocalizableString("navigationDescription", _this, true);
23512
23533
  _this.dragDropPageHelper = new _drag_drop_page_helper_v1__WEBPACK_IMPORTED_MODULE_3__["DragDropPageHelperV1"](_this);
23513
23534
  return _this;
@@ -23546,13 +23567,6 @@ var PageModel = /** @class */ (function (_super) {
23546
23567
  enumerable: false,
23547
23568
  configurable: true
23548
23569
  });
23549
- Object.defineProperty(PageModel.prototype, "locNavigationTitle", {
23550
- get: function () {
23551
- return this.getLocalizableString("navigationTitle");
23552
- },
23553
- enumerable: false,
23554
- configurable: true
23555
- });
23556
23570
  Object.defineProperty(PageModel.prototype, "navigationDescription", {
23557
23571
  /**
23558
23572
  * Explanatory text displayed under a navigation button in the progress bar. Applies when the [progress bar is visible](https://surveyjs.io/form-library/documentation/api-reference/survey-data-model#showProgressBar), `SurveyModel`'s [`progressBarType`](https://surveyjs.io/form-library/documentation/surveymodel#progressBarType) is set to `"pages"`, and [`progressBarShowPageTitles`](https://surveyjs.io/form-library/documentation/surveymodel#progressBarShowPageTitles) is `true`.
@@ -23574,16 +23588,12 @@ var PageModel = /** @class */ (function (_super) {
23574
23588
  configurable: true
23575
23589
  });
23576
23590
  PageModel.prototype.navigationLocStrChanged = function () {
23591
+ if (this.locNavigationTitle.isEmpty) {
23592
+ this.locTitle.strChanged();
23593
+ }
23577
23594
  this.locNavigationTitle.strChanged();
23578
23595
  this.locNavigationDescription.strChanged();
23579
23596
  };
23580
- Object.defineProperty(PageModel.prototype, "renderedNavigationTitle", {
23581
- get: function () {
23582
- return this.locNavigationTitle.renderedHtml || this.title || this.name;
23583
- },
23584
- enumerable: false,
23585
- configurable: true
23586
- });
23587
23597
  Object.defineProperty(PageModel.prototype, "passed", {
23588
23598
  get: function () {
23589
23599
  return this.getPropertyValue("passed", false);
@@ -24225,6 +24235,9 @@ var PanelModelBase = /** @class */ (function (_super) {
24225
24235
  _this.addExpressionProperty("enableIf", function (obj, res) { _this.readOnly = res === false; });
24226
24236
  _this.addExpressionProperty("requiredIf", function (obj, res) { _this.isRequired = res === true; });
24227
24237
  _this.createLocalizableString("requiredErrorText", _this);
24238
+ _this.createLocalizableString("navigationTitle", _this, true).onGetTextCallback = function (text) {
24239
+ return text || _this.title || _this.name;
24240
+ };
24228
24241
  _this.registerPropertyChangedHandlers(["questionTitleLocation"], function () {
24229
24242
  _this.onVisibleChanged.bind(_this);
24230
24243
  _this.updateElementCss(true);
@@ -24341,9 +24354,22 @@ var PanelModelBase = /** @class */ (function (_super) {
24341
24354
  this.elements[i].locStrsChanged();
24342
24355
  }
24343
24356
  };
24357
+ PanelModelBase.prototype.getMarkdownHtml = function (text, name) {
24358
+ if (name === "navigationTitle" && this.locNavigationTitle.isEmpty) {
24359
+ return this.locTitle.renderedHtml || this.name;
24360
+ }
24361
+ return _super.prototype.getMarkdownHtml.call(this, text, name);
24362
+ };
24363
+ Object.defineProperty(PanelModelBase.prototype, "locNavigationTitle", {
24364
+ get: function () {
24365
+ return this.getLocalizableString("navigationTitle");
24366
+ },
24367
+ enumerable: false,
24368
+ configurable: true
24369
+ });
24344
24370
  Object.defineProperty(PanelModelBase.prototype, "renderedNavigationTitle", {
24345
24371
  get: function () {
24346
- return this.title || this.name;
24372
+ return this.locNavigationTitle.renderedHtml;
24347
24373
  },
24348
24374
  enumerable: false,
24349
24375
  configurable: true
@@ -24855,7 +24881,7 @@ var PanelModelBase = /** @class */ (function (_super) {
24855
24881
  if (rec.result !== true)
24856
24882
  rec.result = false;
24857
24883
  this.hasErrorsCore(rec);
24858
- if (rec.firstErrorQuestion) {
24884
+ if (rec.focuseOnFirstError && rec.firstErrorQuestion) {
24859
24885
  rec.firstErrorQuestion.focus(true);
24860
24886
  }
24861
24887
  return !rec.result;
@@ -27176,14 +27202,30 @@ __webpack_require__.r(__webpack_exports__);
27176
27202
  /* harmony import */ var _popup__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./popup */ "./src/popup.ts");
27177
27203
  /* harmony import */ var _popup_dropdown_view_model__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./popup-dropdown-view-model */ "./src/popup-dropdown-view-model.ts");
27178
27204
  /* harmony import */ var _popup_modal_view_model__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./popup-modal-view-model */ "./src/popup-modal-view-model.ts");
27205
+ var __assign = (undefined && undefined.__assign) || function () {
27206
+ __assign = Object.assign || function(t) {
27207
+ for (var s, i = 1, n = arguments.length; i < n; i++) {
27208
+ s = arguments[i];
27209
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
27210
+ t[p] = s[p];
27211
+ }
27212
+ return t;
27213
+ };
27214
+ return __assign.apply(this, arguments);
27215
+ };
27179
27216
 
27180
27217
 
27181
27218
 
27182
27219
 
27183
27220
  function createPopupModalViewModel(options, rootElement) {
27184
27221
  var _a;
27185
- var popupModel = new _popup__WEBPACK_IMPORTED_MODULE_1__["PopupModel"](options.componentName, options.data, "top", "left", false, true, options.onCancel, options.onApply, options.onHide, options.onShow, options.cssClass, options.title);
27186
- popupModel.displayMode = options.displayMode || "popup";
27222
+ var popupOptions = __assign({}, options);
27223
+ popupOptions.verticalPosition = "top";
27224
+ popupOptions.horizontalPosition = "left";
27225
+ popupOptions.showPointer = false;
27226
+ popupOptions.isModal = true;
27227
+ popupOptions.displayMode = options.displayMode || "popup";
27228
+ var popupModel = new _popup__WEBPACK_IMPORTED_MODULE_1__["PopupModel"](options.componentName, options.data, popupOptions);
27187
27229
  popupModel.isFocusedContent = (_a = options.isFocusedContent) !== null && _a !== void 0 ? _a : true;
27188
27230
  var popupViewModel = new _popup_modal_view_model__WEBPACK_IMPORTED_MODULE_3__["PopupModalViewModel"](popupModel);
27189
27231
  if (!!rootElement && !!rootElement.appendChild) {
@@ -27687,36 +27729,29 @@ var __decorate = (undefined && undefined.__decorate) || function (decorators, ta
27687
27729
 
27688
27730
  var PopupModel = /** @class */ (function (_super) {
27689
27731
  __extends(PopupModel, _super);
27690
- function PopupModel(contentComponentName, contentComponentData, verticalPosition, horizontalPosition, showPointer, isModal, onCancel, onApply, onHide, onShow, cssClass, title, onDispose) {
27691
- if (verticalPosition === void 0) { verticalPosition = "bottom"; }
27692
- if (horizontalPosition === void 0) { horizontalPosition = "left"; }
27693
- if (showPointer === void 0) { showPointer = true; }
27694
- if (isModal === void 0) { isModal = false; }
27695
- if (onCancel === void 0) { onCancel = function () { }; }
27696
- if (onApply === void 0) { onApply = function () { return true; }; }
27697
- if (onHide === void 0) { onHide = function () { }; }
27698
- if (onShow === void 0) { onShow = function () { }; }
27699
- if (cssClass === void 0) { cssClass = ""; }
27700
- if (title === void 0) { title = ""; }
27701
- if (onDispose === void 0) { onDispose = function () { }; }
27732
+ function PopupModel(contentComponentName, contentComponentData, option1, option2) {
27702
27733
  var _this = _super.call(this) || this;
27703
- _this.onDispose = onDispose;
27704
27734
  _this.focusFirstInputSelector = "";
27735
+ _this.onCancel = function () { };
27736
+ _this.onApply = function () { return true; };
27737
+ _this.onHide = function () { };
27738
+ _this.onShow = function () { };
27739
+ _this.onDispose = function () { };
27705
27740
  _this.onVisibilityChanged = _this.addEvent();
27706
27741
  _this.onFooterActionsCreated = _this.addEvent();
27707
27742
  _this.onRecalculatePosition = _this.addEvent();
27708
27743
  _this.contentComponentName = contentComponentName;
27709
27744
  _this.contentComponentData = contentComponentData;
27710
- _this.verticalPosition = verticalPosition;
27711
- _this.horizontalPosition = horizontalPosition;
27712
- _this.showPointer = showPointer;
27713
- _this.isModal = isModal;
27714
- _this.onCancel = onCancel;
27715
- _this.onApply = onApply;
27716
- _this.onHide = onHide;
27717
- _this.onShow = onShow;
27718
- _this.cssClass = cssClass;
27719
- _this.title = title;
27745
+ if (!!option1 && typeof option1 === "string") {
27746
+ _this.verticalPosition = option1;
27747
+ _this.horizontalPosition = option2;
27748
+ }
27749
+ else if (!!option1) {
27750
+ var popupOptions = option1;
27751
+ for (var key in popupOptions) {
27752
+ _this[key] = popupOptions[key];
27753
+ }
27754
+ }
27720
27755
  return _this;
27721
27756
  }
27722
27757
  PopupModel.prototype.refreshInnerModel = function () {
@@ -27772,7 +27807,7 @@ var PopupModel = /** @class */ (function (_super) {
27772
27807
  Object(_jsonobject__WEBPACK_IMPORTED_MODULE_1__["property"])({ defaultValue: "left" })
27773
27808
  ], PopupModel.prototype, "horizontalPosition", void 0);
27774
27809
  __decorate([
27775
- Object(_jsonobject__WEBPACK_IMPORTED_MODULE_1__["property"])({ defaultValue: false })
27810
+ Object(_jsonobject__WEBPACK_IMPORTED_MODULE_1__["property"])({ defaultValue: true })
27776
27811
  ], PopupModel.prototype, "showPointer", void 0);
27777
27812
  __decorate([
27778
27813
  Object(_jsonobject__WEBPACK_IMPORTED_MODULE_1__["property"])({ defaultValue: false })
@@ -27783,18 +27818,6 @@ var PopupModel = /** @class */ (function (_super) {
27783
27818
  __decorate([
27784
27819
  Object(_jsonobject__WEBPACK_IMPORTED_MODULE_1__["property"])({ defaultValue: true })
27785
27820
  ], PopupModel.prototype, "isFocusedContainer", void 0);
27786
- __decorate([
27787
- Object(_jsonobject__WEBPACK_IMPORTED_MODULE_1__["property"])({ defaultValue: function () { } })
27788
- ], PopupModel.prototype, "onCancel", void 0);
27789
- __decorate([
27790
- Object(_jsonobject__WEBPACK_IMPORTED_MODULE_1__["property"])({ defaultValue: function () { return true; } })
27791
- ], PopupModel.prototype, "onApply", void 0);
27792
- __decorate([
27793
- Object(_jsonobject__WEBPACK_IMPORTED_MODULE_1__["property"])({ defaultValue: function () { } })
27794
- ], PopupModel.prototype, "onHide", void 0);
27795
- __decorate([
27796
- Object(_jsonobject__WEBPACK_IMPORTED_MODULE_1__["property"])({ defaultValue: function () { } })
27797
- ], PopupModel.prototype, "onShow", void 0);
27798
27821
  __decorate([
27799
27822
  Object(_jsonobject__WEBPACK_IMPORTED_MODULE_1__["property"])({ defaultValue: "" })
27800
27823
  ], PopupModel.prototype, "cssClass", void 0);
@@ -30953,7 +30976,6 @@ var Question = /** @class */ (function (_super) {
30953
30976
  };
30954
30977
  Question.prototype.isDefaultRendering = function () {
30955
30978
  return (!!this.customWidget ||
30956
- this.renderAs === "default" ||
30957
30979
  this.getComponentName() === "default");
30958
30980
  };
30959
30981
  //ISurveyErrorOwner
@@ -31777,7 +31799,7 @@ var QuestionSelectBase = /** @class */ (function (_super) {
31777
31799
  return "itemvalue";
31778
31800
  };
31779
31801
  QuestionSelectBase.prototype.createItemValue = function (value, text) {
31780
- var res = _jsonobject__WEBPACK_IMPORTED_MODULE_0__["Serializer"].createClass(this.getItemValueType(), value);
31802
+ var res = _jsonobject__WEBPACK_IMPORTED_MODULE_0__["Serializer"].createClass(this.getItemValueType(), { value: value });
31781
31803
  res.locOwner = this;
31782
31804
  if (!!text)
31783
31805
  res.text = text;
@@ -32231,7 +32253,7 @@ var QuestionSelectBase = /** @class */ (function (_super) {
32231
32253
  QuestionSelectBase.prototype.canSurveyChangeItemVisibility = function () {
32232
32254
  return !!this.survey && this.survey.canChangeChoiceItemsVisibility();
32233
32255
  };
32234
- QuestionSelectBase.prototype.changeItemVisisbility = function () {
32256
+ QuestionSelectBase.prototype.changeItemVisibility = function () {
32235
32257
  var _this = this;
32236
32258
  return this.canSurveyChangeItemVisibility() ?
32237
32259
  function (item, val) { return _this.survey.getChoiceItemVisibility(_this, item, val); }
@@ -32239,7 +32261,7 @@ var QuestionSelectBase = /** @class */ (function (_super) {
32239
32261
  };
32240
32262
  QuestionSelectBase.prototype.runConditionsForItems = function (values, properties) {
32241
32263
  this.filteredChoicesValue = [];
32242
- var calcVisibility = this.changeItemVisisbility();
32264
+ var calcVisibility = this.changeItemVisibility();
32243
32265
  return _itemvalue__WEBPACK_IMPORTED_MODULE_3__["ItemValue"].runConditionsForItems(this.activeChoices, this.getFilteredChoices(), this.areInvisibleElementsShowing
32244
32266
  ? null
32245
32267
  : this.conditionChoicesVisibleIfRunner, values, properties, !this.survey || !this.survey.areInvisibleElementsShowing, function (item, val) {
@@ -32897,7 +32919,7 @@ var QuestionSelectBase = /** @class */ (function (_super) {
32897
32919
  QuestionSelectBase.prototype.canShowOptionItem = function (item, isAddAll, hasItem) {
32898
32920
  var res = (isAddAll && (!!this.canShowOptionItemCallback ? this.canShowOptionItemCallback(item) : true)) || hasItem;
32899
32921
  if (this.canSurveyChangeItemVisibility()) {
32900
- var calc = this.changeItemVisisbility();
32922
+ var calc = this.changeItemVisibility();
32901
32923
  return calc(item, res);
32902
32924
  }
32903
32925
  return res;
@@ -33445,8 +33467,8 @@ var QuestionSelectBase = /** @class */ (function (_super) {
33445
33467
  var superVal = _super.prototype.isVisibleCore.call(this);
33446
33468
  if (!this.hideIfChoicesEmpty || !superVal)
33447
33469
  return superVal;
33448
- var filteredChoices = this.getFilteredChoices();
33449
- return !filteredChoices || filteredChoices.length > 0;
33470
+ var choices = this.isUsingCarryForward ? this.visibleChoices : this.getFilteredChoices();
33471
+ return !choices || choices.length > 0;
33450
33472
  };
33451
33473
  QuestionSelectBase.prototype.sortVisibleChoices = function (array) {
33452
33474
  if (this.isDesignMode)
@@ -34166,6 +34188,7 @@ var QuestionBooleanModel = /** @class */ (function (_super) {
34166
34188
  this.value = val == true ? this.getValueTrue() : this.getValueFalse();
34167
34189
  this.booleanValueRendered = val;
34168
34190
  }
34191
+ this.updateThumbMargin();
34169
34192
  };
34170
34193
  Object.defineProperty(QuestionBooleanModel.prototype, "defaultValue", {
34171
34194
  get: function () {
@@ -34205,6 +34228,27 @@ var QuestionBooleanModel = /** @class */ (function (_super) {
34205
34228
  enumerable: false,
34206
34229
  configurable: true
34207
34230
  });
34231
+ QuestionBooleanModel.prototype.updateThumbMargin = function () {
34232
+ var _this = this;
34233
+ if (!this.isIndeterminate && this.leftAnswerElement) {
34234
+ if (!this.swapOrder && this.value === this.getValueTrue() || this.swapOrder && this.value === this.getValueFalse()) {
34235
+ var el_1 = this.leftAnswerElement;
34236
+ setTimeout(function () {
34237
+ _this.thumbMargin = el_1.clientWidth + (_this.swapOrder ? 4 : 2) + "px";
34238
+ }, 50);
34239
+ }
34240
+ }
34241
+ this.thumbMargin = undefined;
34242
+ };
34243
+ QuestionBooleanModel.prototype.afterRender = function (el) {
34244
+ _super.prototype.afterRender.call(this, el);
34245
+ this.leftAnswerElement = el.querySelectorAll("." + this.cssClasses.sliderGhost)[0];
34246
+ this.updateThumbMargin();
34247
+ };
34248
+ QuestionBooleanModel.prototype.beforeDestroyQuestionElement = function (el) {
34249
+ _super.prototype.beforeDestroyQuestionElement.call(this, el);
34250
+ this.leftAnswerElement = undefined;
34251
+ };
34208
34252
  Object.defineProperty(QuestionBooleanModel.prototype, "isLabelRendered", {
34209
34253
  get: function () {
34210
34254
  return this.titleLocation === "hidden";
@@ -34475,6 +34519,12 @@ var QuestionBooleanModel = /** @class */ (function (_super) {
34475
34519
  __decorate([
34476
34520
  Object(_jsonobject__WEBPACK_IMPORTED_MODULE_1__["property"])()
34477
34521
  ], QuestionBooleanModel.prototype, "booleanValueRendered", void 0);
34522
+ __decorate([
34523
+ Object(_jsonobject__WEBPACK_IMPORTED_MODULE_1__["property"])()
34524
+ ], QuestionBooleanModel.prototype, "leftAnswerElement", void 0);
34525
+ __decorate([
34526
+ Object(_jsonobject__WEBPACK_IMPORTED_MODULE_1__["property"])()
34527
+ ], QuestionBooleanModel.prototype, "thumbMargin", void 0);
34478
34528
  __decorate([
34479
34529
  Object(_jsonobject__WEBPACK_IMPORTED_MODULE_1__["property"])()
34480
34530
  ], QuestionBooleanModel.prototype, "showTitle", void 0);
@@ -35408,7 +35458,7 @@ var QuestionCheckboxModel = /** @class */ (function (_super) {
35408
35458
  QuestionCheckboxModel.prototype.getConditionJson = function (operator, path) {
35409
35459
  if (operator === void 0) { operator = null; }
35410
35460
  if (path === void 0) { path = null; }
35411
- var json = _super.prototype.getConditionJson.call(this);
35461
+ var json = _super.prototype.getConditionJson.call(this, operator, path);
35412
35462
  if (operator == "contains" || operator == "notcontains") {
35413
35463
  json["type"] = "radiogroup";
35414
35464
  }
@@ -37335,7 +37385,13 @@ var QuestionDropdownModel = /** @class */ (function (_super) {
37335
37385
  Object(_jsonobject__WEBPACK_IMPORTED_MODULE_0__["property"])({ defaultValue: "" })
37336
37386
  ], QuestionDropdownModel.prototype, "readOnlyText", void 0);
37337
37387
  __decorate([
37338
- Object(_jsonobject__WEBPACK_IMPORTED_MODULE_0__["property"])()
37388
+ Object(_jsonobject__WEBPACK_IMPORTED_MODULE_0__["property"])({
37389
+ onSet: function (newValue, target) {
37390
+ if (!!target.dropdownListModel) {
37391
+ target.dropdownListModel.setChoicesLazyLoadEnabled(newValue);
37392
+ }
37393
+ }
37394
+ })
37339
37395
  ], QuestionDropdownModel.prototype, "choicesLazyLoadEnabled", void 0);
37340
37396
  __decorate([
37341
37397
  Object(_jsonobject__WEBPACK_IMPORTED_MODULE_0__["property"])()
@@ -38236,6 +38292,7 @@ var QuestionFileModel = /** @class */ (function (_super) {
38236
38292
  }
38237
38293
  };
38238
38294
  _this.createLocalizableString("takePhotoCaption", _this, false, true);
38295
+ _this.createLocalizableString("clearCaption", _this, false, true);
38239
38296
  _this.actionsContainer = new _actions_container__WEBPACK_IMPORTED_MODULE_7__["ActionContainer"]();
38240
38297
  _this.actionsContainer.locOwner = _this;
38241
38298
  _this.fileIndexAction = new _actions_action__WEBPACK_IMPORTED_MODULE_8__["Action"]({
@@ -38312,7 +38369,7 @@ var QuestionFileModel = /** @class */ (function (_super) {
38312
38369
  iconName: "icon-clear",
38313
38370
  id: "sv-file-clean",
38314
38371
  iconSize: "auto",
38315
- title: new _base__WEBPACK_IMPORTED_MODULE_3__["ComputedUpdater"](function () { return _this.clearButtonCaption; }),
38372
+ locTitle: _this.locClearButtonCaption,
38316
38373
  showTitle: false,
38317
38374
  enabledIf: function () { return !_this.isInputReadOnly; },
38318
38375
  innerCss: new _base__WEBPACK_IMPORTED_MODULE_3__["ComputedUpdater"](function () { return _this.cssClasses.removeButton; }),
@@ -38624,6 +38681,23 @@ var QuestionFileModel = /** @class */ (function (_super) {
38624
38681
  enumerable: false,
38625
38682
  configurable: true
38626
38683
  });
38684
+ Object.defineProperty(QuestionFileModel.prototype, "clearButtonCaption", {
38685
+ get: function () {
38686
+ return this.getLocalizableStringText("clearCaption");
38687
+ },
38688
+ set: function (value) {
38689
+ this.setLocalizableStringText("clearCaption", value);
38690
+ },
38691
+ enumerable: false,
38692
+ configurable: true
38693
+ });
38694
+ Object.defineProperty(QuestionFileModel.prototype, "locClearButtonCaption", {
38695
+ get: function () {
38696
+ return this.getLocalizableString("clearCaption");
38697
+ },
38698
+ enumerable: false,
38699
+ configurable: true
38700
+ });
38627
38701
  Object.defineProperty(QuestionFileModel.prototype, "locRenderedPlaceholder", {
38628
38702
  get: function () {
38629
38703
  var _this = this;
@@ -39199,9 +39273,6 @@ var QuestionFileModel = /** @class */ (function (_super) {
39199
39273
  __decorate([
39200
39274
  Object(_jsonobject__WEBPACK_IMPORTED_MODULE_1__["property"])({ localizable: { defaultStr: "replaceFileCaption" } })
39201
39275
  ], QuestionFileModel.prototype, "replaceButtonCaption", void 0);
39202
- __decorate([
39203
- Object(_jsonobject__WEBPACK_IMPORTED_MODULE_1__["property"])({ localizable: { defaultStr: "clearCaption" } })
39204
- ], QuestionFileModel.prototype, "clearButtonCaption", void 0);
39205
39276
  __decorate([
39206
39277
  Object(_jsonobject__WEBPACK_IMPORTED_MODULE_1__["property"])({ localizable: { defaultStr: "removeFileCaption" } })
39207
39278
  ], QuestionFileModel.prototype, "removeFileCaption", void 0);
@@ -40223,6 +40294,9 @@ var QuestionImagePickerModel = /** @class */ (function (_super) {
40223
40294
  QuestionImagePickerModel.prototype.needResponsiveness = function () {
40224
40295
  return this.supportResponsiveness() && this.isDefaultV2Theme;
40225
40296
  };
40297
+ QuestionImagePickerModel.prototype.needResponsiveWidth = function () {
40298
+ return this.colCount > 2;
40299
+ };
40226
40300
  QuestionImagePickerModel.prototype.getCurrentColCount = function () {
40227
40301
  if (this.responsiveColCount === undefined || this.colCount === 0) {
40228
40302
  return this.colCount;
@@ -40454,6 +40528,9 @@ var MatrixRowModel = /** @class */ (function (_super) {
40454
40528
  if (_this.data)
40455
40529
  _this.data.onMatrixRowChanged(_this);
40456
40530
  });
40531
+ if (_this.data && _this.data.hasErrorInRow(_this)) {
40532
+ _this.hasError = true;
40533
+ }
40457
40534
  return _this;
40458
40535
  }
40459
40536
  Object.defineProperty(MatrixRowModel.prototype, "name", {
@@ -40504,11 +40581,21 @@ var MatrixRowModel = /** @class */ (function (_super) {
40504
40581
  enumerable: false,
40505
40582
  configurable: true
40506
40583
  });
40584
+ Object.defineProperty(MatrixRowModel.prototype, "hasError", {
40585
+ get: function () {
40586
+ return this.getPropertyValue("hasError", false);
40587
+ },
40588
+ set: function (val) {
40589
+ this.setPropertyValue("hasError", val);
40590
+ },
40591
+ enumerable: false,
40592
+ configurable: true
40593
+ });
40507
40594
  Object.defineProperty(MatrixRowModel.prototype, "rowClasses", {
40508
40595
  get: function () {
40509
40596
  var cssClasses = this.data.cssClasses;
40510
40597
  return new _utils_cssClassBuilder__WEBPACK_IMPORTED_MODULE_11__["CssClassBuilder"]().append(cssClasses.row)
40511
- .append(cssClasses.rowError, this.data.hasErrorInRow(this))
40598
+ .append(cssClasses.rowError, this.hasError)
40512
40599
  .append(cssClasses.rowReadOnly, this.isReadOnly)
40513
40600
  .append(cssClasses.rowDisabled, this.data.isDisabledStyle)
40514
40601
  .toString();
@@ -40834,7 +40921,7 @@ var QuestionMatrixModel = /** @class */ (function (_super) {
40834
40921
  return new _utils_cssClassBuilder__WEBPACK_IMPORTED_MODULE_11__["CssClassBuilder"]()
40835
40922
  .append(css.cell, hasCellText)
40836
40923
  .append(hasCellText ? css.cellText : css.label)
40837
- .append(css.itemOnError, !hasCellText && (this.isAllRowRequired ? this.hasErrorInRow(row) : this.hasCssError()))
40924
+ .append(css.itemOnError, !hasCellText && (this.isAllRowRequired || this.eachRowUnique ? row.hasError : this.hasCssError()))
40838
40925
  .append(hasCellText ? css.cellTextSelected : css.itemChecked, isChecked)
40839
40926
  .append(hasCellText ? css.cellTextDisabled : css.itemDisabled, this.isDisabledStyle)
40840
40927
  .append(hasCellText ? css.cellTextReadOnly : css.itemReadOnly, this.isReadOnlyStyle)
@@ -40964,72 +41051,76 @@ var QuestionMatrixModel = /** @class */ (function (_super) {
40964
41051
  return loc ? loc : this.emptyLocalizableString;
40965
41052
  };
40966
41053
  QuestionMatrixModel.prototype.supportGoNextPageAutomatic = function () {
40967
- return this.isMouseDown === true && this.hasValuesInAllRows(false);
41054
+ return this.isMouseDown === true && this.hasValuesInAllRows();
40968
41055
  };
40969
41056
  QuestionMatrixModel.prototype.onCheckForErrors = function (errors, isOnValueChanged) {
40970
41057
  _super.prototype.onCheckForErrors.call(this, errors, isOnValueChanged);
40971
- this.errorsInRow = undefined;
40972
41058
  if (!isOnValueChanged || this.hasCssError()) {
40973
- if (this.hasErrorAllRowsRequired()) {
41059
+ var rowsErrors = { noValue: false, isNotUnique: false };
41060
+ this.checkErrorsAllRows(true, rowsErrors);
41061
+ if (rowsErrors.noValue) {
40974
41062
  errors.push(new _error__WEBPACK_IMPORTED_MODULE_6__["RequiredInAllRowsError"](null, this));
40975
41063
  }
40976
- if (this.hasErrorEachRowUnique()) {
41064
+ if (rowsErrors.isNotUnique) {
40977
41065
  errors.push(new _error__WEBPACK_IMPORTED_MODULE_6__["EachRowUniqueError"](null, this));
40978
41066
  }
40979
41067
  }
40980
41068
  };
40981
- QuestionMatrixModel.prototype.hasErrorAllRowsRequired = function () {
40982
- return this.isAllRowRequired && !this.hasValuesInAllRows(true);
40983
- };
40984
- QuestionMatrixModel.prototype.hasErrorEachRowUnique = function () {
40985
- return this.eachRowUnique && this.hasNonUniqueValueInRow();
41069
+ QuestionMatrixModel.prototype.hasValuesInAllRows = function () {
41070
+ var rowsErrors = { noValue: false, isNotUnique: false };
41071
+ this.checkErrorsAllRows(false, rowsErrors, true);
41072
+ return !rowsErrors.noValue;
40986
41073
  };
40987
- QuestionMatrixModel.prototype.hasValuesInAllRows = function (addError) {
41074
+ QuestionMatrixModel.prototype.checkErrorsAllRows = function (modifyErrors, res, allRowsRequired) {
41075
+ var _this = this;
40988
41076
  var rows = this.generatedVisibleRows;
40989
41077
  if (!rows)
40990
41078
  rows = this.visibleRows;
40991
41079
  if (!rows)
40992
- return true;
40993
- var res = true;
40994
- for (var i = 0; i < rows.length; i++) {
40995
- var row = rows[i];
40996
- var hasValue = !this.isValueEmpty(row.value);
40997
- if (addError && !hasValue) {
40998
- this.addErrorIntoRow(row);
40999
- }
41000
- res = res && hasValue;
41080
+ return;
41081
+ var rowsRequired = this.isAllRowRequired || allRowsRequired;
41082
+ var rowsUnique = this.eachRowUnique;
41083
+ res.noValue = false;
41084
+ res.isNotUnique = false;
41085
+ if (modifyErrors) {
41086
+ this.errorsInRow = undefined;
41001
41087
  }
41002
- return res;
41003
- };
41004
- QuestionMatrixModel.prototype.hasNonUniqueValueInRow = function () {
41005
- var rows = this.generatedVisibleRows;
41006
- if (!rows)
41007
- rows = this.visibleRows;
41008
- if (!rows)
41009
- return false;
41088
+ if (!rowsRequired && !rowsUnique)
41089
+ return;
41010
41090
  var hash = {};
41011
- var res = true;
41012
41091
  for (var i = 0; i < rows.length; i++) {
41013
41092
  var val = rows[i].value;
41014
41093
  var isEmpty = this.isValueEmpty(val);
41015
- var isUnique = isEmpty || hash[val] !== true;
41016
- if (!isUnique) {
41094
+ var isNotUnique = rowsUnique && (!isEmpty && hash[val] === true);
41095
+ isEmpty = isEmpty && rowsRequired;
41096
+ if (modifyErrors && (isEmpty || isNotUnique)) {
41017
41097
  this.addErrorIntoRow(rows[i]);
41018
41098
  }
41019
- res = res && isUnique;
41020
41099
  if (!isEmpty) {
41021
41100
  hash[val] = true;
41022
41101
  }
41102
+ res.noValue = res.noValue || isEmpty;
41103
+ res.isNotUnique = res.isNotUnique || isNotUnique;
41104
+ }
41105
+ if (modifyErrors) {
41106
+ rows.forEach(function (row) {
41107
+ row.hasError = _this.hasErrorInRow(row);
41108
+ });
41023
41109
  }
41024
- return !res;
41025
41110
  };
41026
41111
  QuestionMatrixModel.prototype.addErrorIntoRow = function (row) {
41027
41112
  if (!this.errorsInRow)
41028
41113
  this.errorsInRow = {};
41029
41114
  this.errorsInRow[row.name] = true;
41115
+ row.hasError = true;
41116
+ };
41117
+ QuestionMatrixModel.prototype.refreshRowsErrors = function () {
41118
+ if (!this.errorsInRow)
41119
+ return;
41120
+ this.checkErrorsAllRows(true, { noValue: false, isNotUnique: false });
41030
41121
  };
41031
41122
  QuestionMatrixModel.prototype.getIsAnswered = function () {
41032
- return _super.prototype.getIsAnswered.call(this) && this.hasValuesInAllRows(false);
41123
+ return _super.prototype.getIsAnswered.call(this) && this.hasValuesInAllRows();
41033
41124
  };
41034
41125
  QuestionMatrixModel.prototype.createMatrixRow = function (item, fullName, value) {
41035
41126
  var row = new MatrixRowModel(item, fullName, this, value);
@@ -41058,6 +41149,7 @@ var QuestionMatrixModel = /** @class */ (function (_super) {
41058
41149
  this.generatedVisibleRows[i].setValueDirectly(rowVal);
41059
41150
  }
41060
41151
  }
41152
+ this.refreshRowsErrors();
41061
41153
  this.updateIsAnswered();
41062
41154
  this.isRowChanging = false;
41063
41155
  };
@@ -41125,7 +41217,7 @@ var QuestionMatrixModel = /** @class */ (function (_super) {
41125
41217
  if (operator === void 0) { operator = null; }
41126
41218
  if (path === void 0) { path = null; }
41127
41219
  if (!path)
41128
- return _super.prototype.getConditionJson.call(this);
41220
+ return _super.prototype.getConditionJson.call(this, operator);
41129
41221
  var question = new _question_dropdown__WEBPACK_IMPORTED_MODULE_9__["QuestionDropdownModel"](path);
41130
41222
  question.choices = this.columns;
41131
41223
  var json = new _jsonobject__WEBPACK_IMPORTED_MODULE_3__["JsonObject"]().toJsonObject(question);
@@ -42962,7 +43054,7 @@ var QuestionMatrixDropdownModelBase = /** @class */ (function (_super) {
42962
43054
  if (operator === void 0) { operator = null; }
42963
43055
  if (path === void 0) { path = null; }
42964
43056
  if (!path)
42965
- return _super.prototype.getConditionJson.call(this);
43057
+ return _super.prototype.getConditionJson.call(this, operator);
42966
43058
  var columnName = "";
42967
43059
  for (var i = path.length - 1; i >= 0; i--) {
42968
43060
  if (path[i] == ".")
@@ -48387,7 +48479,7 @@ var QuestionMultipleTextModel = /** @class */ (function (_super) {
48387
48479
  if (operator === void 0) { operator = null; }
48388
48480
  if (path === void 0) { path = null; }
48389
48481
  if (!path)
48390
- return _super.prototype.getConditionJson.call(this);
48482
+ return _super.prototype.getConditionJson.call(this, operator);
48391
48483
  var item = this.getItemByName(path);
48392
48484
  if (!item)
48393
48485
  return null;
@@ -49646,14 +49738,23 @@ var QuestionPanelDynamicModel = /** @class */ (function (_super) {
49646
49738
  });
49647
49739
  QuestionPanelDynamicModel.prototype.getPanelsAnimationOptions = function () {
49648
49740
  var _this = this;
49649
- var getDirection = function () {
49741
+ var getDirectionCssClass = function () {
49650
49742
  if (_this.isRenderModeList)
49651
49743
  return "";
49744
+ var cssClass = new _utils_cssClassBuilder__WEBPACK_IMPORTED_MODULE_10__["CssClassBuilder"]();
49745
+ var isRemoving = false;
49652
49746
  var leavingPanel = _this.renderedPanels.filter(function (el) { return el !== _this.currentPanel; })[0];
49653
49747
  var leavingPanelIndex = _this.visiblePanels.indexOf(leavingPanel);
49654
- if (leavingPanelIndex < 0)
49748
+ if (leavingPanelIndex < 0) {
49749
+ isRemoving = true;
49655
49750
  leavingPanelIndex = _this.removedPanelIndex;
49656
- return leavingPanelIndex > _this.currentIndex ? "-right" : "-left";
49751
+ }
49752
+ return cssClass
49753
+ .append("sv-pd-animation-adding", !!_this.focusNewPanelCallback)
49754
+ .append("sv-pd-animation-removing", isRemoving)
49755
+ .append("sv-pd-animation-left", leavingPanelIndex <= _this.currentIndex)
49756
+ .append("sv-pd-animation-right", leavingPanelIndex > _this.currentIndex)
49757
+ .toString();
49657
49758
  };
49658
49759
  return {
49659
49760
  getAnimatedElement: function (panel) {
@@ -49664,7 +49765,7 @@ var QuestionPanelDynamicModel = /** @class */ (function (_super) {
49664
49765
  }
49665
49766
  },
49666
49767
  getEnterOptions: function () {
49667
- var cssClass = _this.cssClasses.panelWrapperFadeIn ? "" + _this.cssClasses.panelWrapperFadeIn + getDirection() : "";
49768
+ var cssClass = new _utils_cssClassBuilder__WEBPACK_IMPORTED_MODULE_10__["CssClassBuilder"]().append(_this.cssClasses.panelWrapperFadeIn).append(getDirectionCssClass()).toString();
49668
49769
  return {
49669
49770
  onBeforeRunAnimation: function (el) {
49670
49771
  var _a;
@@ -49683,7 +49784,7 @@ var QuestionPanelDynamicModel = /** @class */ (function (_super) {
49683
49784
  };
49684
49785
  },
49685
49786
  getLeaveOptions: function () {
49686
- var cssClass = _this.cssClasses.panelWrapperFadeOut ? "" + _this.cssClasses.panelWrapperFadeOut + getDirection() : "";
49787
+ var cssClass = new _utils_cssClassBuilder__WEBPACK_IMPORTED_MODULE_10__["CssClassBuilder"]().append(_this.cssClasses.panelWrapperFadeOut).append(getDirectionCssClass()).toString();
49687
49788
  return {
49688
49789
  onBeforeRunAnimation: function (el) {
49689
49790
  var _a;
@@ -50823,11 +50924,16 @@ var QuestionPanelDynamicModel = /** @class */ (function (_super) {
50823
50924
  var prefixName = this.getValueName() + indexStr;
50824
50925
  var prefixText = this.processedTitle + indexStr;
50825
50926
  for (var i = 0; i < panelObjs.length; i++) {
50826
- objects.push({
50827
- name: prefixName + panelObjs[i].name,
50828
- text: prefixText + panelObjs[i].text,
50829
- question: panelObjs[i].question,
50830
- });
50927
+ if (!!panelObjs[i].context) {
50928
+ objects.push(panelObjs[i]);
50929
+ }
50930
+ else {
50931
+ objects.push({
50932
+ name: prefixName + panelObjs[i].name,
50933
+ text: prefixText + panelObjs[i].text,
50934
+ question: panelObjs[i].question,
50935
+ });
50936
+ }
50831
50937
  }
50832
50938
  }
50833
50939
  if (hasContext) {
@@ -50841,9 +50947,7 @@ var QuestionPanelDynamicModel = /** @class */ (function (_super) {
50841
50947
  text: prefixText + QuestionPanelDynamicItem.ItemVariableName + "." + panelObjs[i].text,
50842
50948
  question: panelObjs[i].question
50843
50949
  };
50844
- if (context === true) {
50845
- obj.context = this;
50846
- }
50950
+ obj.context = this;
50847
50951
  objects.push(obj);
50848
50952
  }
50849
50953
  }
@@ -50860,7 +50964,7 @@ var QuestionPanelDynamicModel = /** @class */ (function (_super) {
50860
50964
  if (operator === void 0) { operator = null; }
50861
50965
  if (path === void 0) { path = null; }
50862
50966
  if (!path)
50863
- return _super.prototype.getConditionJson.call(this, operator, path);
50967
+ return _super.prototype.getConditionJson.call(this, operator);
50864
50968
  var questionName = path;
50865
50969
  var pos = path.indexOf(".");
50866
50970
  if (pos > -1) {
@@ -51969,6 +52073,13 @@ var QuestionRadiogroupModel = /** @class */ (function (_super) {
51969
52073
  QuestionRadiogroupModel.prototype.supportGoNextPageAutomatic = function () {
51970
52074
  return this.isMouseDown === true && !this.isOtherSelected;
51971
52075
  };
52076
+ QuestionRadiogroupModel.prototype.getConditionJson = function (operator, path) {
52077
+ if (operator === void 0) { operator = null; }
52078
+ if (path === void 0) { path = null; }
52079
+ var json = _super.prototype.getConditionJson.call(this, operator, path);
52080
+ delete json["showClearButton"];
52081
+ return json;
52082
+ };
51972
52083
  QuestionRadiogroupModel.prototype.setNewComment = function (newValue) {
51973
52084
  this.isMouseDown = true;
51974
52085
  _super.prototype.setNewComment.call(this, newValue);
@@ -53630,7 +53741,9 @@ var QuestionRatingModel = /** @class */ (function (_super) {
53630
53741
  .append(this.cssClasses.control)
53631
53742
  .append(this.cssClasses.controlEmpty, this.isEmpty())
53632
53743
  .append(this.cssClasses.onError, this.hasCssError())
53633
- .append(this.cssClasses.controlDisabled, this.isReadOnly)
53744
+ .append(this.cssClasses.controlDisabled, this.isDisabledStyle)
53745
+ .append(this.cssClasses.controlReadOnly, this.isReadOnlyStyle)
53746
+ .append(this.cssClasses.controlPreview, this.isPreviewStyle)
53634
53747
  .toString();
53635
53748
  };
53636
53749
  Object.defineProperty(QuestionRatingModel.prototype, "placeholder", {
@@ -54605,7 +54718,14 @@ var QuestionTagboxModel = /** @class */ (function (_super) {
54605
54718
  };
54606
54719
  QuestionTagboxModel.prototype.onSurveyLoad = function () {
54607
54720
  _super.prototype.onSurveyLoad.call(this);
54608
- if (!this.dropdownListModel) {
54721
+ this.createDropdownListModel();
54722
+ };
54723
+ QuestionTagboxModel.prototype.onSetData = function () {
54724
+ _super.prototype.onSetData.call(this);
54725
+ this.createDropdownListModel();
54726
+ };
54727
+ QuestionTagboxModel.prototype.createDropdownListModel = function () {
54728
+ if (!this.dropdownListModel && !this.isLoadingFromJson) {
54609
54729
  this.dropdownListModel = new _dropdownMultiSelectListModel__WEBPACK_IMPORTED_MODULE_4__["DropdownMultiSelectListModel"](this);
54610
54730
  }
54611
54731
  };
@@ -54816,7 +54936,13 @@ var QuestionTagboxModel = /** @class */ (function (_super) {
54816
54936
  })
54817
54937
  ], QuestionTagboxModel.prototype, "hideSelectedItems", void 0);
54818
54938
  __decorate([
54819
- Object(_jsonobject__WEBPACK_IMPORTED_MODULE_0__["property"])()
54939
+ Object(_jsonobject__WEBPACK_IMPORTED_MODULE_0__["property"])({
54940
+ onSet: function (newValue, target) {
54941
+ if (!!target.dropdownListModel) {
54942
+ target.dropdownListModel.setChoicesLazyLoadEnabled(newValue);
54943
+ }
54944
+ }
54945
+ })
54820
54946
  ], QuestionTagboxModel.prototype, "choicesLazyLoadEnabled", void 0);
54821
54947
  __decorate([
54822
54948
  Object(_jsonobject__WEBPACK_IMPORTED_MODULE_0__["property"])()
@@ -56287,20 +56413,34 @@ __webpack_require__.r(__webpack_exports__);
56287
56413
  var RendererFactory = /** @class */ (function () {
56288
56414
  function RendererFactory() {
56289
56415
  this.renderersHash = {};
56416
+ this.defaultHash = {};
56290
56417
  }
56291
56418
  RendererFactory.prototype.unregisterRenderer = function (questionType, rendererAs) {
56292
56419
  delete this.renderersHash[questionType][rendererAs];
56420
+ if (this.defaultHash[questionType] === rendererAs) {
56421
+ delete this.defaultHash[questionType];
56422
+ }
56293
56423
  };
56294
- RendererFactory.prototype.registerRenderer = function (questionType, renderAs, renderer) {
56424
+ RendererFactory.prototype.registerRenderer = function (questionType, renderAs, renderer, useAsDefault) {
56425
+ if (useAsDefault === void 0) { useAsDefault = false; }
56295
56426
  if (!this.renderersHash[questionType]) {
56296
56427
  this.renderersHash[questionType] = {};
56297
56428
  }
56298
56429
  this.renderersHash[questionType][renderAs] = renderer;
56430
+ if (useAsDefault) {
56431
+ this.defaultHash[questionType] = renderAs;
56432
+ }
56299
56433
  };
56300
56434
  RendererFactory.prototype.getRenderer = function (questionType, renderAs) {
56301
- return ((this.renderersHash[questionType] &&
56302
- this.renderersHash[questionType][renderAs]) ||
56303
- "default");
56435
+ var qHash = this.renderersHash[questionType];
56436
+ if (!!qHash) {
56437
+ if (!!renderAs && qHash[renderAs])
56438
+ return qHash[renderAs];
56439
+ var dVal = this.defaultHash[questionType];
56440
+ if (!!dVal && qHash[dVal])
56441
+ return qHash[dVal];
56442
+ }
56443
+ return "default";
56304
56444
  };
56305
56445
  RendererFactory.prototype.getRendererByQuestion = function (question) {
56306
56446
  return this.getRenderer(question.getType(), question.renderAs);
@@ -59803,6 +59943,7 @@ var SurveyModel = /** @class */ (function (_super) {
59803
59943
  _this.skippedPages = [];
59804
59944
  _this.skeletonComponentName = "sv-skeleton";
59805
59945
  _this.taskManager = new _surveyTaskManager__WEBPACK_IMPORTED_MODULE_22__["SurveyTaskManagerModel"]();
59946
+ _this.questionErrorComponent = "sv-question-error";
59806
59947
  if (_global_variables_utils__WEBPACK_IMPORTED_MODULE_25__["DomDocumentHelper"].isAvailable()) {
59807
59948
  SurveyModel.stylesManager = new _stylesmanager__WEBPACK_IMPORTED_MODULE_11__["StylesManager"]();
59808
59949
  }
@@ -67467,7 +67608,7 @@ _jsonobject__WEBPACK_IMPORTED_MODULE_1__["Serializer"].addClass("survey", [
67467
67608
  {
67468
67609
  name: "showProgressBar",
67469
67610
  default: "off",
67470
- choices: ["off", "auto", "aboveHeader", "belowHeader", "bottom", "topBottom"],
67611
+ choices: ["off", "auto", "aboveheader", "belowheader", "bottom", "topbottom"],
67471
67612
  },
67472
67613
  {
67473
67614
  name: "progressBarType",
@@ -68106,11 +68247,9 @@ function createTOCListModel(survey, onAction) {
68106
68247
  var _a;
68107
68248
  var pagesSource = survey.questionsOnPageMode === "singlePage" ? (_a = survey.pages[0]) === null || _a === void 0 ? void 0 : _a.elements : survey.pages;
68108
68249
  var items = (pagesSource || []).map(function (page) {
68109
- var _a, _b;
68110
68250
  return new _actions_action__WEBPACK_IMPORTED_MODULE_0__["Action"]({
68111
68251
  id: page.name,
68112
- locTitle: ((_a = page.locNavigationTitle) === null || _a === void 0 ? void 0 : _a.text) ? page.locNavigationTitle : (((_b = page.locTitle) === null || _b === void 0 ? void 0 : _b.text) ? page.locTitle : undefined),
68113
- title: page.renderedNavigationTitle,
68252
+ locTitle: page.locNavigationTitle,
68114
68253
  action: function () {
68115
68254
  _global_variables_utils__WEBPACK_IMPORTED_MODULE_2__["DomDocumentHelper"].activeElementBlur();
68116
68255
  !!onAction && onAction();
@@ -69372,10 +69511,15 @@ var AnimationUtils = /** @class */ (function () {
69372
69511
  options.onBeforeRunAnimation && options.onBeforeRunAnimation(element);
69373
69512
  }
69374
69513
  };
69514
+ AnimationUtils.prototype.getCssClasses = function (options) {
69515
+ return options.cssClass.replace(/\s+$/, "").split(/\s+/);
69516
+ };
69375
69517
  AnimationUtils.prototype.runAnimation = function (element, options, callback) {
69376
69518
  if (element && options.cssClass) {
69377
69519
  this.reflow(element);
69378
- element.classList.add(options.cssClass);
69520
+ this.getCssClasses(options).forEach(function (cssClass) {
69521
+ element.classList.add(cssClass);
69522
+ });
69379
69523
  this.onAnimationEnd(element, callback, options);
69380
69524
  }
69381
69525
  else {
@@ -69384,7 +69528,9 @@ var AnimationUtils = /** @class */ (function () {
69384
69528
  };
69385
69529
  AnimationUtils.prototype.clearHtmlElement = function (element, options) {
69386
69530
  if (element && options.cssClass) {
69387
- element.classList.remove(options.cssClass);
69531
+ this.getCssClasses(options).forEach(function (cssClass) {
69532
+ element.classList.remove(cssClass);
69533
+ });
69388
69534
  }
69389
69535
  };
69390
69536
  AnimationUtils.prototype.onNextRender = function (callback, runEarly, isCancel) {