survey-core 1.12.14 → 1.12.16

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 (246) hide show
  1. package/defaultV2.css +30 -9
  2. package/defaultV2.css.map +1 -1
  3. package/defaultV2.fontless.css +30 -9
  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/icons/iconsV1.js +1 -1
  114. package/icons/iconsV1.min.js +1 -1
  115. package/icons/iconsV2.js +1 -1
  116. package/icons/iconsV2.min.js +1 -1
  117. package/modern.css +18 -16
  118. package/modern.css.map +1 -1
  119. package/modern.fontless.css +18 -16
  120. package/modern.fontless.css.map +1 -1
  121. package/modern.fontless.min.css +2 -2
  122. package/modern.min.css +2 -2
  123. package/package.json +1 -1
  124. package/plugins/bootstrap-integration/index.js +1 -1
  125. package/plugins/bootstrap-integration/index.min.js +1 -1
  126. package/plugins/bootstrap-material-integration/index.js +1 -1
  127. package/plugins/bootstrap-material-integration/index.min.js +1 -1
  128. package/survey.core.js +536 -280
  129. package/survey.core.js.map +1 -1
  130. package/survey.core.min.js +3 -3
  131. package/survey.css +1 -1
  132. package/survey.i18n.js +1 -1
  133. package/survey.i18n.min.js +1 -1
  134. package/survey.min.css +1 -1
  135. package/themes/borderless-dark-panelless.js +1 -1
  136. package/themes/borderless-dark-panelless.min.js +1 -1
  137. package/themes/borderless-dark.js +1 -1
  138. package/themes/borderless-dark.min.js +1 -1
  139. package/themes/borderless-light-panelless..js +1 -1
  140. package/themes/borderless-light-panelless..min.js +1 -1
  141. package/themes/borderless-light.js +1 -1
  142. package/themes/borderless-light.min.js +1 -1
  143. package/themes/contrast-dark-panelless.js +1 -1
  144. package/themes/contrast-dark-panelless.min.js +1 -1
  145. package/themes/contrast-dark.js +1 -1
  146. package/themes/contrast-dark.min.js +1 -1
  147. package/themes/contrast-light-panelless.js +1 -1
  148. package/themes/contrast-light-panelless.min.js +1 -1
  149. package/themes/contrast-light.js +1 -1
  150. package/themes/contrast-light.min.js +1 -1
  151. package/themes/default-dark-panelless.js +1 -1
  152. package/themes/default-dark-panelless.min.js +1 -1
  153. package/themes/default-dark.js +1 -1
  154. package/themes/default-dark.min.js +1 -1
  155. package/themes/default-light-panelless.js +1 -1
  156. package/themes/default-light-panelless.min.js +1 -1
  157. package/themes/default-light.js +1 -1
  158. package/themes/default-light.min.js +1 -1
  159. package/themes/doubleborder-dark-panelless.js +1 -1
  160. package/themes/doubleborder-dark-panelless.min.js +1 -1
  161. package/themes/doubleborder-dark.js +1 -1
  162. package/themes/doubleborder-dark.min.js +1 -1
  163. package/themes/doubleborder-light-panelles.js +1 -1
  164. package/themes/doubleborder-light-panelles.min.js +1 -1
  165. package/themes/doubleborder-light.js +1 -1
  166. package/themes/doubleborder-light.min.js +1 -1
  167. package/themes/flat-dark-panelless.js +1 -1
  168. package/themes/flat-dark-panelless.min.js +1 -1
  169. package/themes/flat-dark.js +1 -1
  170. package/themes/flat-dark.min.js +1 -1
  171. package/themes/flat-light-panelless.js +1 -1
  172. package/themes/flat-light-panelless.min.js +1 -1
  173. package/themes/flat-light.js +1 -1
  174. package/themes/flat-light.min.js +1 -1
  175. package/themes/index.js +1 -1
  176. package/themes/index.min.js +1 -1
  177. package/themes/layered-dark-panelless.js +1 -1
  178. package/themes/layered-dark-panelless.min.js +1 -1
  179. package/themes/layered-dark.js +1 -1
  180. package/themes/layered-dark.min.js +1 -1
  181. package/themes/layered-light-panelless.js +1 -1
  182. package/themes/layered-light-panelless.min.js +1 -1
  183. package/themes/layered-light.js +1 -1
  184. package/themes/layered-light.min.js +1 -1
  185. package/themes/plain-dark-panelless.js +1 -1
  186. package/themes/plain-dark-panelless.min.js +1 -1
  187. package/themes/plain-dark.js +1 -1
  188. package/themes/plain-dark.min.js +1 -1
  189. package/themes/plain-light-panelless.js +1 -1
  190. package/themes/plain-light-panelless.min.js +1 -1
  191. package/themes/plain-light.js +1 -1
  192. package/themes/plain-light.min.js +1 -1
  193. package/themes/sharp-dark-panelless.js +1 -1
  194. package/themes/sharp-dark-panelless.min.js +1 -1
  195. package/themes/sharp-dark.js +1 -1
  196. package/themes/sharp-dark.min.js +1 -1
  197. package/themes/sharp-light-panelless.js +1 -1
  198. package/themes/sharp-light-panelless.min.js +1 -1
  199. package/themes/sharp-light.js +1 -1
  200. package/themes/sharp-light.min.js +1 -1
  201. package/themes/solid-dark-panelless.js +1 -1
  202. package/themes/solid-dark-panelless.min.js +1 -1
  203. package/themes/solid-dark.js +1 -1
  204. package/themes/solid-dark.min.js +1 -1
  205. package/themes/solid-light-panelless.js +1 -1
  206. package/themes/solid-light-panelless.min.js +1 -1
  207. package/themes/solid-light.js +1 -1
  208. package/themes/solid-light.min.js +1 -1
  209. package/themes/three-dimensional-dark-panelless.js +1 -1
  210. package/themes/three-dimensional-dark-panelless.min.js +1 -1
  211. package/themes/three-dimensional-dark.js +1 -1
  212. package/themes/three-dimensional-dark.min.js +1 -1
  213. package/themes/three-dimensional-light-panelless.js +1 -1
  214. package/themes/three-dimensional-light-panelless.min.js +1 -1
  215. package/themes/three-dimensional-light.js +1 -1
  216. package/themes/three-dimensional-light.min.js +1 -1
  217. package/ts3.4/typings/packages/survey-core/entries/chunks/core-wo-model.d.ts +1 -1
  218. package/ts3.4/typings/packages/survey-core/entries/chunks/model.d.ts +1 -1
  219. package/ts3.4/typings/packages/survey-core/src/actions/action.d.ts +2 -2
  220. package/ts3.4/typings/packages/survey-core/src/base-interfaces.d.ts +1 -0
  221. package/ts3.4/typings/packages/survey-core/src/defaultCss/defaultV2Css.d.ts +1 -0
  222. package/ts3.4/typings/packages/survey-core/src/list.d.ts +3 -1
  223. package/ts3.4/typings/packages/survey-core/src/page.d.ts +11 -3
  224. package/ts3.4/typings/packages/survey-core/src/panel.d.ts +11 -7
  225. package/ts3.4/typings/packages/survey-core/src/question.d.ts +3 -0
  226. package/ts3.4/typings/packages/survey-core/src/settings.d.ts +2 -1
  227. package/ts3.4/typings/packages/survey-core/src/survey-element.d.ts +16 -5
  228. package/ts3.4/typings/packages/survey-core/src/survey.d.ts +17 -8
  229. package/ts3.4/typings/packages/survey-core/src/surveyStrings.d.ts +8 -1
  230. package/ts3.4/typings/packages/survey-core/src/utils/utils.d.ts +11 -2
  231. package/ts3.4/typings/packages/survey-core/src/validator.d.ts +1 -1
  232. package/typings/packages/survey-core/entries/chunks/core-wo-model.d.ts +1 -1
  233. package/typings/packages/survey-core/entries/chunks/model.d.ts +1 -1
  234. package/typings/packages/survey-core/src/actions/action.d.ts +2 -2
  235. package/typings/packages/survey-core/src/base-interfaces.d.ts +1 -0
  236. package/typings/packages/survey-core/src/defaultCss/defaultV2Css.d.ts +1 -0
  237. package/typings/packages/survey-core/src/list.d.ts +3 -1
  238. package/typings/packages/survey-core/src/page.d.ts +11 -3
  239. package/typings/packages/survey-core/src/panel.d.ts +11 -7
  240. package/typings/packages/survey-core/src/question.d.ts +3 -0
  241. package/typings/packages/survey-core/src/settings.d.ts +2 -1
  242. package/typings/packages/survey-core/src/survey-element.d.ts +16 -5
  243. package/typings/packages/survey-core/src/survey.d.ts +18 -8
  244. package/typings/packages/survey-core/src/surveyStrings.d.ts +8 -1
  245. package/typings/packages/survey-core/src/utils/utils.d.ts +11 -2
  246. package/typings/packages/survey-core/src/validator.d.ts +1 -1
package/survey.core.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * surveyjs - Survey JavaScript library v1.12.14
2
+ * surveyjs - Survey JavaScript library v1.12.16
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
  */
@@ -105,7 +105,7 @@ return /******/ (function(modules) { // webpackBootstrap
105
105
  /*!*******************************************!*\
106
106
  !*** ./src/entries/core.ts + 127 modules ***!
107
107
  \*******************************************/
108
- /*! exports provided: Version, ReleaseDate, checkLibraryVersion, setLicenseKey, slk, hasLicense, settings, Helpers, AnswerCountValidator, EmailValidator, NumericValidator, RegexValidator, SurveyValidator, TextValidator, ValidatorResult, ExpressionValidator, ValidatorRunner, ItemValue, Base, Event, EventBase, ArrayChanges, ComputedUpdater, SurveyError, SurveyElementCore, SurveyElement, DragTypeOverMeEnum, CalculatedValue, CustomError, AnswerRequiredError, OneAnswerRequiredError, RequreNumericError, ExceedSizeError, LocalizableString, LocalizableStrings, HtmlConditionItem, UrlConditionItem, ChoicesRestful, ChoicesRestfull, FunctionFactory, registerFunction, ConditionRunner, ExpressionRunner, ExpressionExecutor, Operand, Const, BinaryOperand, Variable, FunctionOperand, ArrayOperand, UnaryOperand, ConditionsParser, ProcessValue, JsonError, JsonIncorrectTypeError, JsonMetadata, JsonMetadataClass, JsonMissingTypeError, JsonMissingTypeErrorBase, JsonObject, JsonObjectProperty, JsonRequiredPropertyError, JsonUnknownPropertyError, Serializer, property, propertyArray, MatrixDropdownCell, MatrixDropdownRowModelBase, QuestionMatrixDropdownModelBase, MatrixDropdownColumn, matrixDropdownColumnTypes, QuestionMatrixDropdownRenderedCell, QuestionMatrixDropdownRenderedRow, QuestionMatrixDropdownRenderedErrorRow, QuestionMatrixDropdownRenderedTable, MatrixDropdownRowModel, QuestionMatrixDropdownModel, MatrixDynamicRowModel, QuestionMatrixDynamicModel, MatrixRowModel, MatrixCells, QuestionMatrixModel, QuestionMatrixBaseModel, MultipleTextItemModel, MultipleTextCell, MultipleTextErrorCell, MutlipleTextErrorRow, MutlipleTextRow, QuestionMultipleTextModel, MultipleTextEditorModel, PanelModel, PanelModelBase, QuestionRowModel, FlowPanelModel, PageModel, DefaultTitleModel, Question, QuestionNonValue, QuestionEmptyModel, QuestionCheckboxBase, QuestionSelectBase, QuestionCheckboxModel, QuestionTagboxModel, QuestionRankingModel, QuestionCommentModel, QuestionDropdownModel, QuestionFactory, ElementFactory, QuestionFileModel, QuestionFilePage, QuestionHtmlModel, QuestionRadiogroupModel, QuestionRatingModel, RenderedRatingItem, QuestionExpressionModel, QuestionTextBase, CharacterCounter, QuestionTextModel, QuestionBooleanModel, QuestionImagePickerModel, ImageItemValue, QuestionImageModel, QuestionSignaturePadModel, QuestionPanelDynamicModel, QuestionPanelDynamicItem, SurveyTimer, SurveyTimerModel, tryFocusPage, createTOCListModel, getTocRootCss, TOCModel, SurveyProgressModel, ProgressButtons, ProgressButtonsResponsivityManager, SurveyModel, SurveyTrigger, SurveyTriggerComplete, SurveyTriggerSetValue, SurveyTriggerVisible, SurveyTriggerCopyValue, SurveyTriggerRunExpression, SurveyTriggerSkip, Trigger, PopupSurveyModel, SurveyWindowModel, TextPreProcessor, Notifier, Cover, CoverCell, dxSurveyService, englishStrings, surveyLocalization, surveyStrings, getLocaleString, setupLocale, QuestionCustomWidget, CustomWidgetCollection, QuestionCustomModel, QuestionCompositeModel, ComponentQuestionJSON, ComponentCollection, ListModel, MultiSelectListModel, PopupModel, createDialogOptions, PopupBaseViewModel, PopupDropdownViewModel, PopupModalViewModel, createPopupViewModel, createPopupModalViewModel, DropdownListModel, DropdownMultiSelectListModel, QuestionButtonGroupModel, ButtonGroupItemModel, ButtonGroupItemValue, IsMobile, IsTouch, _setIsTouch, confirmAction, confirmActionAsync, detectIEOrEdge, doKey2ClickUp, doKey2ClickDown, doKey2ClickBlur, loadFileFromBase64, increaseHeightByContent, createSvg, chooseFiles, sanitizeEditableContent, prepareElementForVerticalAnimation, cleanHtmlElementAfterAnimation, classesToSelector, renamedIcons, getIconNameFromProxy, InputMaskBase, InputMaskPattern, InputMaskNumeric, InputMaskDateTime, InputMaskCurrency, CssClassBuilder, TextAreaModel, surveyCss, defaultV2Css, defaultV2ThemeName, DragDropCore, DragDropChoices, DragDropRankingSelectToRank, StylesManager, defaultStandardCss, modernCss, SvgIconRegistry, SvgRegistry, SvgThemeSets, addIconsToThemeSet, RendererFactory, ResponsivityManager, VerticalResponsivityManager, unwrap, getOriginalEvent, getElement, createDropdownActionModel, createDropdownActionModelAdvanced, createPopupModelWithListModel, getActionDropdownButtonTarget, BaseAction, Action, ActionDropdownViewModel, AnimationUtils, AnimationPropertyUtils, AnimationGroupUtils, AnimationProperty, AnimationBoolean, AnimationGroup, AnimationTab, AdaptiveActionContainer, defaultActionBarCss, ActionContainer, DragOrClickHelper, Model */
108
+ /*! exports provided: Version, ReleaseDate, checkLibraryVersion, setLicenseKey, slk, hasLicense, settings, Helpers, AnswerCountValidator, EmailValidator, NumericValidator, RegexValidator, SurveyValidator, TextValidator, ValidatorResult, ExpressionValidator, ValidatorRunner, ItemValue, Base, Event, EventBase, ArrayChanges, ComputedUpdater, SurveyError, SurveyElementCore, SurveyElement, DragTypeOverMeEnum, CalculatedValue, CustomError, AnswerRequiredError, OneAnswerRequiredError, RequreNumericError, ExceedSizeError, LocalizableString, LocalizableStrings, HtmlConditionItem, UrlConditionItem, ChoicesRestful, ChoicesRestfull, FunctionFactory, registerFunction, ConditionRunner, ExpressionRunner, ExpressionExecutor, Operand, Const, BinaryOperand, Variable, FunctionOperand, ArrayOperand, UnaryOperand, ConditionsParser, ProcessValue, JsonError, JsonIncorrectTypeError, JsonMetadata, JsonMetadataClass, JsonMissingTypeError, JsonMissingTypeErrorBase, JsonObject, JsonObjectProperty, JsonRequiredPropertyError, JsonUnknownPropertyError, Serializer, property, propertyArray, MatrixDropdownCell, MatrixDropdownRowModelBase, QuestionMatrixDropdownModelBase, MatrixDropdownColumn, matrixDropdownColumnTypes, QuestionMatrixDropdownRenderedCell, QuestionMatrixDropdownRenderedRow, QuestionMatrixDropdownRenderedErrorRow, QuestionMatrixDropdownRenderedTable, MatrixDropdownRowModel, QuestionMatrixDropdownModel, MatrixDynamicRowModel, QuestionMatrixDynamicModel, MatrixRowModel, MatrixCells, QuestionMatrixModel, QuestionMatrixBaseModel, MultipleTextItemModel, MultipleTextCell, MultipleTextErrorCell, MutlipleTextErrorRow, MutlipleTextRow, QuestionMultipleTextModel, MultipleTextEditorModel, PanelModel, PanelModelBase, QuestionRowModel, FlowPanelModel, PageModel, DefaultTitleModel, Question, QuestionNonValue, QuestionEmptyModel, QuestionCheckboxBase, QuestionSelectBase, QuestionCheckboxModel, QuestionTagboxModel, QuestionRankingModel, QuestionCommentModel, QuestionDropdownModel, QuestionFactory, ElementFactory, QuestionFileModel, QuestionFilePage, QuestionHtmlModel, QuestionRadiogroupModel, QuestionRatingModel, RenderedRatingItem, QuestionExpressionModel, QuestionTextBase, CharacterCounter, QuestionTextModel, QuestionBooleanModel, QuestionImagePickerModel, ImageItemValue, QuestionImageModel, QuestionSignaturePadModel, QuestionPanelDynamicModel, QuestionPanelDynamicItem, SurveyTimer, SurveyTimerModel, tryFocusPage, createTOCListModel, getTocRootCss, TOCModel, SurveyProgressModel, ProgressButtons, ProgressButtonsResponsivityManager, SurveyModel, SurveyTrigger, SurveyTriggerComplete, SurveyTriggerSetValue, SurveyTriggerVisible, SurveyTriggerCopyValue, SurveyTriggerRunExpression, SurveyTriggerSkip, Trigger, PopupSurveyModel, SurveyWindowModel, TextPreProcessor, Notifier, Cover, CoverCell, dxSurveyService, englishStrings, surveyLocalization, surveyStrings, getLocaleString, getLocaleStrings, setupLocale, QuestionCustomWidget, CustomWidgetCollection, QuestionCustomModel, QuestionCompositeModel, ComponentQuestionJSON, ComponentCollection, ListModel, MultiSelectListModel, PopupModel, createDialogOptions, PopupBaseViewModel, PopupDropdownViewModel, PopupModalViewModel, createPopupViewModel, createPopupModalViewModel, DropdownListModel, DropdownMultiSelectListModel, QuestionButtonGroupModel, ButtonGroupItemModel, ButtonGroupItemValue, IsMobile, IsTouch, _setIsTouch, confirmAction, confirmActionAsync, detectIEOrEdge, doKey2ClickUp, doKey2ClickDown, doKey2ClickBlur, loadFileFromBase64, increaseHeightByContent, createSvg, chooseFiles, sanitizeEditableContent, prepareElementForVerticalAnimation, cleanHtmlElementAfterAnimation, classesToSelector, renamedIcons, getIconNameFromProxy, InputMaskBase, InputMaskPattern, InputMaskNumeric, InputMaskDateTime, InputMaskCurrency, CssClassBuilder, TextAreaModel, surveyCss, defaultV2Css, defaultV2ThemeName, DragDropCore, DragDropChoices, DragDropRankingSelectToRank, StylesManager, defaultStandardCss, modernCss, SvgIconRegistry, SvgRegistry, SvgThemeSets, addIconsToThemeSet, RendererFactory, ResponsivityManager, VerticalResponsivityManager, unwrap, getOriginalEvent, getElement, activateLazyRenderingChecks, createDropdownActionModel, createDropdownActionModelAdvanced, createPopupModelWithListModel, getActionDropdownButtonTarget, BaseAction, Action, ActionDropdownViewModel, AnimationUtils, AnimationPropertyUtils, AnimationGroupUtils, AnimationProperty, AnimationBoolean, AnimationGroup, AnimationTab, AdaptiveActionContainer, defaultActionBarCss, ActionContainer, DragOrClickHelper, Model */
109
109
  /***/ (function(module, __webpack_exports__, __webpack_require__) {
110
110
 
111
111
  "use strict";
@@ -267,6 +267,7 @@ __webpack_require__.d(__webpack_exports__, "englishStrings", function() { return
267
267
  __webpack_require__.d(__webpack_exports__, "surveyLocalization", function() { return /* reexport */ surveyLocalization; });
268
268
  __webpack_require__.d(__webpack_exports__, "surveyStrings", function() { return /* reexport */ surveyStrings; });
269
269
  __webpack_require__.d(__webpack_exports__, "getLocaleString", function() { return /* reexport */ getLocaleString; });
270
+ __webpack_require__.d(__webpack_exports__, "getLocaleStrings", function() { return /* reexport */ getLocaleStrings; });
270
271
  __webpack_require__.d(__webpack_exports__, "setupLocale", function() { return /* reexport */ setupLocale; });
271
272
  __webpack_require__.d(__webpack_exports__, "QuestionCustomWidget", function() { return /* reexport */ QuestionCustomWidget; });
272
273
  __webpack_require__.d(__webpack_exports__, "CustomWidgetCollection", function() { return /* reexport */ questionCustomWidgets_CustomWidgetCollection; });
@@ -333,6 +334,7 @@ __webpack_require__.d(__webpack_exports__, "VerticalResponsivityManager", functi
333
334
  __webpack_require__.d(__webpack_exports__, "unwrap", function() { return /* reexport */ unwrap; });
334
335
  __webpack_require__.d(__webpack_exports__, "getOriginalEvent", function() { return /* reexport */ getOriginalEvent; });
335
336
  __webpack_require__.d(__webpack_exports__, "getElement", function() { return /* reexport */ getElement; });
337
+ __webpack_require__.d(__webpack_exports__, "activateLazyRenderingChecks", function() { return /* reexport */ activateLazyRenderingChecks; });
336
338
  __webpack_require__.d(__webpack_exports__, "createDropdownActionModel", function() { return /* reexport */ createDropdownActionModel; });
337
339
  __webpack_require__.d(__webpack_exports__, "createDropdownActionModelAdvanced", function() { return /* reexport */ createDropdownActionModelAdvanced; });
338
340
  __webpack_require__.d(__webpack_exports__, "createPopupModelWithListModel", function() { return /* reexport */ createPopupModelWithListModel; });
@@ -1142,12 +1144,13 @@ var surveyLocalization = {
1142
1144
  //TODO remove on next week
1143
1145
  get showNamesInEnglish() { return this.useEnglishNames; },
1144
1146
  set showNamesInEnglish(val) { this.useEnglishNames = val; },
1145
- setupLocale: function (loc, strings, name, nameInEngish, direction) {
1146
- this.locales[loc] = strings;
1147
- this.localeNames[loc] = name;
1148
- this.localeNamesInEnglish[loc] = nameInEngish;
1149
- if (direction !== undefined) {
1150
- this.localeDirections[loc] = direction;
1147
+ setupLocale: function (localeConfig) {
1148
+ var loc = localeConfig.localeCode;
1149
+ this.locales[loc] = localeConfig.strings;
1150
+ this.localeNames[loc] = localeConfig.nativeName;
1151
+ this.localeNamesInEnglish[loc] = localeConfig.englishName;
1152
+ if (localeConfig.rtl !== undefined) {
1153
+ this.localeDirections[loc] = localeConfig.rtl;
1151
1154
  }
1152
1155
  },
1153
1156
  get currentLocale() {
@@ -1245,8 +1248,11 @@ function getLocaleString(strName, locale) {
1245
1248
  if (locale === void 0) { locale = null; }
1246
1249
  return surveyLocalization.getString(strName, locale);
1247
1250
  }
1251
+ function getLocaleStrings(locale) {
1252
+ return surveyLocalization.getLocaleStrings(locale);
1253
+ }
1248
1254
  function setupLocale(localeConfig) {
1249
- surveyLocalization.setupLocale(localeConfig.localeCode, localeConfig.strings, localeConfig.nativeName, localeConfig.englishName, localeConfig.rtl ? "rtl" : undefined);
1255
+ surveyLocalization.setupLocale(localeConfig);
1250
1256
  }
1251
1257
  var surveyStrings = englishStrings;
1252
1258
  surveyLocalization.locales["en"] = englishStrings;
@@ -3881,6 +3887,24 @@ function dateDiff(params) {
3881
3887
  return dateDiffMonths(params[0], params[1], (params.length > 2 ? params[2] : "") || "days");
3882
3888
  }
3883
3889
  functionsfactory_FunctionFactory.Instance.register("dateDiff", dateDiff);
3890
+ function dateAdd(params) {
3891
+ if (!Array.isArray(params) || params.length < 2 || !params[0] || !params[1])
3892
+ return null;
3893
+ var date = createDate("function-dateAdd", params[0]);
3894
+ var valToAdd = params[1];
3895
+ var interval = params[2] || "days";
3896
+ if (interval === "days") {
3897
+ date.setDate(date.getDate() + valToAdd);
3898
+ }
3899
+ if (interval === "months") {
3900
+ date.setMonth(date.getMonth() + valToAdd);
3901
+ }
3902
+ if (interval === "years") {
3903
+ date.setFullYear(date.getFullYear() + valToAdd);
3904
+ }
3905
+ return date;
3906
+ }
3907
+ functionsfactory_FunctionFactory.Instance.register("dateAdd", dateAdd);
3884
3908
  function isContainerReadyCore(container) {
3885
3909
  if (!container)
3886
3910
  return false;
@@ -10068,9 +10092,15 @@ var list_ListModel = /** @class */ (function (_super) {
10068
10092
  .append(itemValue.css)
10069
10093
  .toString();
10070
10094
  };
10071
- _this.getItemIndent = function (itemValue) {
10095
+ // public getItemIndent = (itemValue: any) => {
10096
+ // const level: number = itemValue.level || 0;
10097
+ // return (level + 1) * ListModel.INDENT + "px";
10098
+ // };
10099
+ _this.getItemStyle = function (itemValue) {
10072
10100
  var level = itemValue.level || 0;
10073
- return (level + 1) * ListModel.INDENT + "px";
10101
+ return {
10102
+ "--sjs-list-item-level": level + 1
10103
+ };
10074
10104
  };
10075
10105
  if (Object.keys(items).indexOf("items") !== -1) {
10076
10106
  var options_1 = items;
@@ -10986,13 +11016,14 @@ var action_BaseAction = /** @class */ (function (_super) {
10986
11016
 
10987
11017
  var action_Action = /** @class */ (function (_super) {
10988
11018
  action_extends(Action, _super);
10989
- function Action(innerItem) {
11019
+ function Action(innerItemData) {
10990
11020
  var _this = _super.call(this) || this;
10991
- _this.innerItem = innerItem;
10992
11021
  _this.locTitleChanged = function () {
10993
11022
  var val = _this.locTitle.renderedHtml;
10994
11023
  _this.setPropertyValue("_title", !!val ? val : undefined);
10995
11024
  };
11025
+ var innerItem = (innerItemData instanceof Action) ? innerItemData.innerItem : innerItemData;
11026
+ _this.innerItem = innerItem;
10996
11027
  _this.locTitle = !!innerItem ? innerItem["locTitle"] : null;
10997
11028
  //Object.assign(this, item) to support IE11
10998
11029
  if (!!innerItem) {
@@ -11949,7 +11980,13 @@ var survey_element_SurveyElementCore = /** @class */ (function (_super) {
11949
11980
  Object.defineProperty(SurveyElementCore.prototype, "isPage", {
11950
11981
  /**
11951
11982
  * Returns `true` if the survey element is a page.
11952
- * @see Base.getType
11983
+ *
11984
+ * This property returns `false` for [`PageModel`](https://surveyjs.io/form-library/documentation/api-reference/page-model) objects in the following cases:
11985
+ *
11986
+ * - `SurveyModel`'s [`questionsOnPageMode`](https://surveyjs.io/form-library/documentation/api-reference/survey-data-model#questionsOnPageMode) is set to `"singlePage"`.
11987
+ * - The page is included in a [preview of given answers](https://surveyjs.io/form-library/documentation/design-survey/create-a-multi-page-survey#preview-page).
11988
+ *
11989
+ * In those cases, the survey creates an internal `PageModel` object to show all questions on one page, and all regular pages become panels.
11953
11990
  */
11954
11991
  get: function () { return false; },
11955
11992
  enumerable: false,
@@ -11957,8 +11994,14 @@ var survey_element_SurveyElementCore = /** @class */ (function (_super) {
11957
11994
  });
11958
11995
  Object.defineProperty(SurveyElementCore.prototype, "isPanel", {
11959
11996
  /**
11960
- * Returns `true` if the survey element is a panel.
11961
- * @see Base.getType
11997
+ * Returns `true` if the survey element is a panel or acts as one.
11998
+ *
11999
+ * This property returns `true` for `PageModel` objects in the following cases:
12000
+ *
12001
+ * - `SurveyModel`'s [`questionsOnPageMode`](https://surveyjs.io/form-library/documentation/api-reference/survey-data-model#questionsOnPageMode) is set to `"singlePage"`.
12002
+ * - The page is included in a [preview of given answers](https://surveyjs.io/form-library/documentation/design-survey/create-a-multi-page-survey#preview-page).
12003
+ *
12004
+ * In those cases, the survey creates an internal `PageModel` object to show all questions on one page, and all regular pages become panels.
11962
12005
  */
11963
12006
  get: function () { return false; },
11964
12007
  enumerable: false,
@@ -11967,7 +12010,6 @@ var survey_element_SurveyElementCore = /** @class */ (function (_super) {
11967
12010
  Object.defineProperty(SurveyElementCore.prototype, "isQuestion", {
11968
12011
  /**
11969
12012
  * Returns `true` if the survey element is a question.
11970
- * @see Base.getType
11971
12013
  */
11972
12014
  get: function () { return false; },
11973
12015
  enumerable: false,
@@ -11976,7 +12018,6 @@ var survey_element_SurveyElementCore = /** @class */ (function (_super) {
11976
12018
  Object.defineProperty(SurveyElementCore.prototype, "isSurvey", {
11977
12019
  /**
11978
12020
  * Returns `true` if the element is a survey.
11979
- * @see Base.getType
11980
12021
  */
11981
12022
  get: function () { return false; },
11982
12023
  enumerable: false,
@@ -12735,9 +12776,11 @@ var survey_element_SurveyElement = /** @class */ (function (_super) {
12735
12776
  SurveyElement.prototype.createCssClassesValue = function () {
12736
12777
  var res = this.calcCssClasses(this.css);
12737
12778
  this.setPropertyValue("cssClassesValue", res);
12779
+ this.onCalcCssClasses(res);
12738
12780
  this.updateElementCssCore(this.cssClassesValue);
12739
12781
  return res;
12740
12782
  };
12783
+ SurveyElement.prototype.onCalcCssClasses = function (classes) { };
12741
12784
  Object.defineProperty(SurveyElement.prototype, "cssClasses", {
12742
12785
  /**
12743
12786
  * Returns an object in which keys are UI elements and values are CSS classes applied to them.
@@ -12991,7 +13034,7 @@ var survey_element_SurveyElement = /** @class */ (function (_super) {
12991
13034
  SurveyElement.prototype.getPage = function (parent) {
12992
13035
  while (parent && parent.parent)
12993
13036
  parent = parent.parent;
12994
- if (parent && parent.getType() == "page")
13037
+ if (parent && parent.isPage)
12995
13038
  return parent;
12996
13039
  return null;
12997
13040
  };
@@ -13043,7 +13086,7 @@ var survey_element_SurveyElement = /** @class */ (function (_super) {
13043
13086
  });
13044
13087
  Object.defineProperty(SurveyElement.prototype, "hasParent", {
13045
13088
  get: function () {
13046
- return (this.parent && !this.parent.isPage && (!this.parent.originalPage)) || (this.parent === undefined);
13089
+ return (this.parent && !this.parent.isPage) || (this.parent === undefined);
13047
13090
  },
13048
13091
  enumerable: false,
13049
13092
  configurable: true
@@ -13230,9 +13273,18 @@ var survey_element_SurveyElement = /** @class */ (function (_super) {
13230
13273
  }
13231
13274
  }
13232
13275
  if (Object.keys(style).length == 0) {
13233
- var minWidth = this.minWidth;
13234
- if (minWidth != "auto")
13276
+ var minWidth = "" + this.minWidth;
13277
+ if (!!minWidth && minWidth != "auto") {
13278
+ if (minWidth.indexOf("px") != -1 && this.survey) {
13279
+ minWidth = minWidth.replace("px", "");
13280
+ var minWidthNum = parseFloat(minWidth);
13281
+ if (!isNaN(minWidthNum)) {
13282
+ minWidth = minWidthNum * this.survey.widthScale / 100;
13283
+ minWidth = "" + minWidth + "px";
13284
+ }
13285
+ }
13235
13286
  minWidth = "min(100%, " + minWidth + ")";
13287
+ }
13236
13288
  if (this.allowRootStyle && this.renderWidth) {
13237
13289
  // style["width"] = this.renderWidth;
13238
13290
  style["flexGrow"] = 1;
@@ -13303,6 +13355,8 @@ var survey_element_SurveyElement = /** @class */ (function (_super) {
13303
13355
  return null;
13304
13356
  };
13305
13357
  SurveyElement.prototype.getCssTitle = function (cssClasses) {
13358
+ if (!cssClasses)
13359
+ return "";
13306
13360
  var isExpandable = this.state !== "default";
13307
13361
  var numInlineLimit = 4;
13308
13362
  return new CssClassBuilder()
@@ -14202,18 +14256,18 @@ function confirmAction(message) {
14202
14256
  return settings.confirmActionFunc(message);
14203
14257
  return confirm(message);
14204
14258
  }
14205
- function confirmActionAsync(message, funcOnYes, funcOnNo, locale, rootElement) {
14259
+ function confirmActionAsync(options) {
14206
14260
  var callbackFunc = function (res) {
14207
14261
  if (res)
14208
- funcOnYes();
14209
- else if (!!funcOnNo)
14210
- funcOnNo();
14262
+ options.funcOnYes();
14263
+ else if (!!options.funcOnNo)
14264
+ options.funcOnNo();
14211
14265
  };
14212
14266
  if (!!settings && !!settings.confirmActionAsync) {
14213
- if (settings.confirmActionAsync(message, callbackFunc, undefined, locale, rootElement))
14267
+ if (settings.confirmActionAsync(options.message, callbackFunc, options))
14214
14268
  return;
14215
14269
  }
14216
- callbackFunc(confirmAction(message));
14270
+ callbackFunc(confirmAction(options.message));
14217
14271
  }
14218
14272
  function detectIEBrowser() {
14219
14273
  var ua = navigator.userAgent;
@@ -14749,7 +14803,7 @@ var Logger = /** @class */ (function () {
14749
14803
  return Logger;
14750
14804
  }());
14751
14805
 
14752
- function showConfirmDialog(message, callback, applyTitle, locale, rootElement) {
14806
+ function showConfirmDialog(message, callback, options) {
14753
14807
  var locStr = new localizablestring_LocalizableString(undefined);
14754
14808
  var popupViewModel = settings.showDialog({
14755
14809
  componentName: "sv-string-viewer",
@@ -14762,17 +14816,17 @@ function showConfirmDialog(message, callback, applyTitle, locale, rootElement) {
14762
14816
  callback(false);
14763
14817
  return false;
14764
14818
  },
14765
- title: message,
14819
+ title: message || options.message,
14766
14820
  displayMode: "popup",
14767
14821
  isFocusedContent: false,
14768
- cssClass: "sv-popup--confirm-delete"
14769
- }, rootElement);
14822
+ cssClass: options.cssClass || "sv-popup--confirm"
14823
+ }, options.rootElement);
14770
14824
  var toolbar = popupViewModel.footerToolbar;
14771
14825
  var applyBtn = toolbar.getActionById("apply");
14772
14826
  var cancelBtn = toolbar.getActionById("cancel");
14773
- cancelBtn.title = getLocaleString("cancel", locale);
14827
+ cancelBtn.title = getLocaleString("cancel", options.locale);
14774
14828
  cancelBtn.innerCss = "sv-popup__body-footer-item sv-popup__button sd-btn sd-btn--small";
14775
- applyBtn.title = applyTitle || getLocaleString("ok", locale);
14829
+ applyBtn.title = options.applyTitle || getLocaleString("ok", options.locale);
14776
14830
  applyBtn.innerCss = "sv-popup__body-footer-item sv-popup__button sv-popup__button--danger sd-btn sd-btn--small sd-btn--danger";
14777
14831
  configConfirmDialog(popupViewModel);
14778
14832
  return true;
@@ -15389,8 +15443,8 @@ var settings = {
15389
15443
  * @param message A message to be displayed in the confirm dialog window.
15390
15444
  * @param callback A callback function that should be called with `true` if a user confirms an action or `false` otherwise.
15391
15445
  */
15392
- confirmActionAsync: function (message, callback, applyTitle, locale, rootElement) {
15393
- return showConfirmDialog(message, callback, applyTitle, locale, rootElement);
15446
+ confirmActionAsync: function (message, callback, options) {
15447
+ return showConfirmDialog(message, callback, options);
15394
15448
  },
15395
15449
  /**
15396
15450
  * A minimum width value for all survey elements.
@@ -16619,7 +16673,7 @@ var validator_ExpressionValidator = /** @class */ (function (_super) {
16619
16673
  });
16620
16674
  Object.defineProperty(ExpressionValidator.prototype, "isAsync", {
16621
16675
  get: function () {
16622
- if (!this.ensureConditionRunner())
16676
+ if (!this.ensureConditionRunner(false))
16623
16677
  return false;
16624
16678
  return this.conditionRunner.isAsync;
16625
16679
  },
@@ -16638,8 +16692,12 @@ var validator_ExpressionValidator = /** @class */ (function (_super) {
16638
16692
  if (name === void 0) { name = null; }
16639
16693
  if (values === void 0) { values = null; }
16640
16694
  if (properties === void 0) { properties = null; }
16641
- if (!this.ensureConditionRunner())
16695
+ if (!this.expression)
16642
16696
  return null;
16697
+ if (!!this.conditionRunner) {
16698
+ this.conditionRunner.onRunComplete = null;
16699
+ }
16700
+ this.ensureConditionRunner(true);
16643
16701
  this.conditionRunner.onRunComplete = function (res) {
16644
16702
  _this.isRunningValue = false;
16645
16703
  if (!!_this.onAsyncCompleted) {
@@ -16662,14 +16720,15 @@ var validator_ExpressionValidator = /** @class */ (function (_super) {
16662
16720
  ExpressionValidator.prototype.getDefaultErrorText = function (name) {
16663
16721
  return this.getLocalizationFormatString("invalidExpression", this.expression);
16664
16722
  };
16665
- ExpressionValidator.prototype.ensureConditionRunner = function () {
16666
- if (!!this.conditionRunner) {
16667
- this.conditionRunner.expression = this.expression;
16668
- return true;
16669
- }
16723
+ ExpressionValidator.prototype.ensureConditionRunner = function (reNew) {
16670
16724
  if (!this.expression)
16671
16725
  return false;
16672
- this.conditionRunner = new ConditionRunner(this.expression);
16726
+ if (reNew || !this.conditionRunner) {
16727
+ this.conditionRunner = new ConditionRunner(this.expression);
16728
+ }
16729
+ else {
16730
+ this.conditionRunner.expression = this.expression;
16731
+ }
16673
16732
  return true;
16674
16733
  };
16675
16734
  Object.defineProperty(ExpressionValidator.prototype, "expression", {
@@ -18326,13 +18385,16 @@ var question_Question = /** @class */ (function (_super) {
18326
18385
  this.copyCssClasses(classes, css.question);
18327
18386
  this.copyCssClasses(classes.error, css.error);
18328
18387
  this.updateCssClasses(classes, css);
18388
+ return classes;
18389
+ };
18390
+ Question.prototype.onCalcCssClasses = function (classes) {
18391
+ _super.prototype.onCalcCssClasses.call(this, classes);
18329
18392
  if (this.survey) {
18330
18393
  this.survey.updateQuestionCssClasses(this, classes);
18331
18394
  }
18332
18395
  if (this.onUpdateCssClassesCallback) {
18333
18396
  this.onUpdateCssClassesCallback(classes);
18334
18397
  }
18335
- return classes;
18336
18398
  };
18337
18399
  Object.defineProperty(Question.prototype, "cssRoot", {
18338
18400
  get: function () {
@@ -18518,18 +18580,33 @@ var question_Question = /** @class */ (function (_super) {
18518
18580
  .toString();
18519
18581
  };
18520
18582
  Question.prototype.updateElementCss = function (reNew) {
18521
- _super.prototype.updateElementCss.call(this, reNew);
18522
- if (reNew) {
18523
- this.updateQuestionCss(true);
18583
+ if (this.wasRendered) {
18584
+ _super.prototype.updateElementCss.call(this, reNew);
18585
+ if (reNew) {
18586
+ this.updateQuestionCss(true);
18587
+ }
18588
+ }
18589
+ else {
18590
+ this.isRequireUpdateElements = true;
18524
18591
  }
18525
18592
  this.resetIndents();
18526
18593
  };
18594
+ Question.prototype.onFirstRenderingCore = function () {
18595
+ if (this.isRequireUpdateElements) {
18596
+ this.isRequireUpdateElements = false;
18597
+ this.updateElementCss(true);
18598
+ }
18599
+ _super.prototype.onFirstRenderingCore.call(this);
18600
+ };
18527
18601
  Question.prototype.updateQuestionCss = function (reNew) {
18528
- if (this.isLoadingFromJson ||
18529
- !this.survey ||
18530
- (reNew !== true && !this.cssClassesValue))
18602
+ if (this.isLoadingFromJson || !this.survey)
18531
18603
  return;
18532
- this.updateElementCssCore(this.cssClasses);
18604
+ if (this.wasRendered) {
18605
+ this.updateElementCssCore(this.cssClasses);
18606
+ }
18607
+ else {
18608
+ this.isRequireUpdateElements = true;
18609
+ }
18533
18610
  };
18534
18611
  Question.prototype.ensureElementCss = function () {
18535
18612
  if (!this.cssClassesValue) {
@@ -29711,10 +29788,9 @@ var question_matrixdropdownbase_QuestionMatrixDropdownModelBase = /** @class */
29711
29788
  if (isDeletingValue) {
29712
29789
  delete rowValue[columnName];
29713
29790
  }
29714
- for (var i = 0; i < row.cells.length; i++) {
29715
- var key = row.cells[i].question.getValueName();
29716
- delete rowValue[key];
29717
- }
29791
+ row.questions.forEach(function (q) {
29792
+ delete rowValue[q.getValueName()];
29793
+ });
29718
29794
  if (newRowValue) {
29719
29795
  newRowValue = JSON.parse(JSON.stringify(newRowValue));
29720
29796
  for (var key in newRowValue) {
@@ -31805,10 +31881,16 @@ var question_matrixdynamic_QuestionMatrixDynamicModel = /** @class */ (function
31805
31881
  confirmDelete = this.isRequireConfirmOnRowDelete(index);
31806
31882
  }
31807
31883
  if (confirmDelete) {
31808
- confirmActionAsync(this.confirmDeleteText, function () {
31809
- _this.removeRowAsync(index, row);
31810
- onRowRemoved && onRowRemoved();
31811
- }, undefined, this.getLocale(), this.survey.rootElement);
31884
+ confirmActionAsync({
31885
+ message: this.confirmDeleteText,
31886
+ funcOnYes: function () {
31887
+ _this.removeRowAsync(index, row);
31888
+ onRowRemoved && onRowRemoved();
31889
+ },
31890
+ locale: this.getLocale(),
31891
+ rootElement: this.survey.rootElement,
31892
+ cssClass: this.cssClasses.confirmDialog
31893
+ });
31812
31894
  return;
31813
31895
  }
31814
31896
  this.removeRowAsync(index, row);
@@ -32534,7 +32616,8 @@ var defaultV2Css = {
32534
32616
  noPointerEventsMode: "sd-question--no-pointer-events",
32535
32617
  errorsContainer: "sd-element__erbox sd-question__erbox",
32536
32618
  errorsContainerTop: "sd-element__erbox--above-element sd-question__erbox--above-question",
32537
- errorsContainerBottom: "sd-question__erbox--below-question"
32619
+ errorsContainerBottom: "sd-question__erbox--below-question",
32620
+ confirmDialog: "sd-popup--confirm sv-popup--confirm"
32538
32621
  },
32539
32622
  image: {
32540
32623
  mainRoot: "sd-question sd-question--image",
@@ -34467,7 +34550,6 @@ var panel_spreadArray = (undefined && undefined.__spreadArray) || function (to,
34467
34550
 
34468
34551
 
34469
34552
 
34470
-
34471
34553
  var panel_QuestionRowModel = /** @class */ (function (_super) {
34472
34554
  panel_extends(QuestionRowModel, _super);
34473
34555
  function QuestionRowModel(panel) {
@@ -35070,9 +35152,14 @@ var panel_PanelModelBase = /** @class */ (function (_super) {
35070
35152
  });
35071
35153
  Object.defineProperty(PanelModelBase.prototype, "parent", {
35072
35154
  /**
35073
- * Returns a survey element (panel or page) that contains this panel and allows you to move this question to a different survey element.
35155
+ * Returns a survey element (panel or page) that contains this panel and allows you to move the panel to a different survey element.
35074
35156
  *
35075
- * This property is always `null` for the `PageModel` object.
35157
+ * For `PageModel` objects, the `parent` property is `null`, except in the following cases:
35158
+ *
35159
+ * - `SurveyModel`'s [`questionsOnPageMode`](https://surveyjs.io/form-library/documentation/api-reference/survey-data-model#questionsOnPageMode) is set to `"singlePage"`.
35160
+ * - The page is included in a [preview of given answers](https://surveyjs.io/form-library/documentation/design-survey/create-a-multi-page-survey#preview-page).
35161
+ *
35162
+ * In those cases, the survey creates an internal `PageModel` object to show all questions on one page, and the `parent` property contains this object.
35076
35163
  */
35077
35164
  get: function () {
35078
35165
  return this.getPropertyValue("parent", null);
@@ -35155,10 +35242,6 @@ var panel_PanelModelBase = /** @class */ (function (_super) {
35155
35242
  configurable: true
35156
35243
  });
35157
35244
  Object.defineProperty(PanelModelBase.prototype, "isPanel", {
35158
- /**
35159
- * Returns `true` if the survey element is a panel.
35160
- * @see Base.getType
35161
- */
35162
35245
  get: function () {
35163
35246
  return false;
35164
35247
  },
@@ -35900,11 +35983,11 @@ var panel_PanelModelBase = /** @class */ (function (_super) {
35900
35983
  PanelModelBase.prototype.updateRows = function () {
35901
35984
  if (this.isLoadingFromJson)
35902
35985
  return;
35903
- for (var i = 0; i < this.elements.length; i++) {
35904
- if (this.elements[i].isPanel) {
35905
- this.elements[i].updateRows();
35986
+ this.getElementsForRows().forEach(function (el) {
35987
+ if (el.isPanel) {
35988
+ el.updateRows();
35906
35989
  }
35907
- }
35990
+ });
35908
35991
  this.onRowsChanged();
35909
35992
  };
35910
35993
  Object.defineProperty(PanelModelBase.prototype, "rows", {
@@ -36013,7 +36096,9 @@ var panel_PanelModelBase = /** @class */ (function (_super) {
36013
36096
  var _this = this;
36014
36097
  var survey = this.survey;
36015
36098
  var fireNotification = this.canFireAddRemoveNotifications(element);
36016
- element.setSurveyImpl(this.surveyImpl);
36099
+ if (!!this.surveyImpl) {
36100
+ element.setSurveyImpl(this.surveyImpl);
36101
+ }
36017
36102
  element.parent = this;
36018
36103
  this.markQuestionListDirty();
36019
36104
  if (this.canBuildRows()) {
@@ -36039,8 +36124,8 @@ var panel_PanelModelBase = /** @class */ (function (_super) {
36039
36124
  };
36040
36125
  PanelModelBase.prototype.onRemoveElement = function (element) {
36041
36126
  element.parent = null;
36127
+ this.unregisterElementPropertiesChanged(element);
36042
36128
  this.markQuestionListDirty();
36043
- element.unregisterPropertyChangedHandlers(["visible", "isVisible", "startWithNewLine"], this.id);
36044
36129
  this.updateRowsOnElementRemoved(element);
36045
36130
  if (this.isRandomizing)
36046
36131
  return;
@@ -36049,6 +36134,9 @@ var panel_PanelModelBase = /** @class */ (function (_super) {
36049
36134
  this.removeElementCallback(element);
36050
36135
  this.onElementVisibilityChanged(this);
36051
36136
  };
36137
+ PanelModelBase.prototype.unregisterElementPropertiesChanged = function (element) {
36138
+ element.unregisterPropertyChangedHandlers(["visible", "isVisible", "startWithNewLine"], this.id);
36139
+ };
36052
36140
  PanelModelBase.prototype.onRemoveElementNotifySurvey = function (element) {
36053
36141
  if (!this.canFireAddRemoveNotifications(element))
36054
36142
  return;
@@ -36093,19 +36181,21 @@ var panel_PanelModelBase = /** @class */ (function (_super) {
36093
36181
  PanelModelBase.prototype.buildRows = function () {
36094
36182
  if (!this.canBuildRows())
36095
36183
  return [];
36096
- var result = new Array();
36097
- for (var i = 0; i < this.elements.length; i++) {
36098
- var el = this.elements[i];
36184
+ var res = new Array();
36185
+ var els = this.getElementsForRows();
36186
+ for (var i = 0; i < els.length; i++) {
36187
+ var el = els[i];
36099
36188
  var isNewRow = i == 0 || el.startWithNewLine;
36100
- var row = isNewRow ? this.createRowAndSetLazy(result.length) : result[result.length - 1];
36189
+ var row = isNewRow ? this.createRowAndSetLazy(res.length) : res[res.length - 1];
36101
36190
  if (isNewRow)
36102
- result.push(row);
36191
+ res.push(row);
36103
36192
  row.addElement(el);
36104
36193
  }
36105
- for (var i = 0; i < result.length; i++) {
36106
- result[i].updateVisible();
36107
- }
36108
- return result;
36194
+ res.forEach(function (row) { return row.updateVisible(); });
36195
+ return res;
36196
+ };
36197
+ PanelModelBase.prototype.getElementsForRows = function () {
36198
+ return this.elements;
36109
36199
  };
36110
36200
  PanelModelBase.prototype.getDragDropInfo = function () {
36111
36201
  var page = this.getPage(this.parent);
@@ -36668,10 +36758,13 @@ var panel_PanelModelBase = /** @class */ (function (_super) {
36668
36758
  }
36669
36759
  this.rows.splice(0, this.rows.length);
36670
36760
  }
36761
+ this.disposeElements();
36762
+ this.elements.splice(0, this.elements.length);
36763
+ };
36764
+ PanelModelBase.prototype.disposeElements = function () {
36671
36765
  for (var i = 0; i < this.elements.length; i++) {
36672
36766
  this.elements[i].dispose();
36673
36767
  }
36674
- this.elements.splice(0, this.elements.length);
36675
36768
  };
36676
36769
  PanelModelBase.panelCounter = 100;
36677
36770
  panel_decorate([
@@ -36724,7 +36817,7 @@ var panel_PanelModel = /** @class */ (function (_super) {
36724
36817
  });
36725
36818
  PanelModel.prototype.getSurvey = function (live) {
36726
36819
  if (live === void 0) { live = false; }
36727
- if (live) {
36820
+ if (live && this.isPanel) {
36728
36821
  return !!this.parent ? this.parent.getSurvey(live) : null;
36729
36822
  }
36730
36823
  return _super.prototype.getSurvey.call(this, live);
@@ -36875,6 +36968,8 @@ var panel_PanelModel = /** @class */ (function (_super) {
36875
36968
  return locTitleValue;
36876
36969
  };
36877
36970
  PanelModel.prototype.beforeSetVisibleIndex = function (index) {
36971
+ if (this.isPage)
36972
+ return _super.prototype.beforeSetVisibleIndex.call(this, index);
36878
36973
  var visibleIndex = -1;
36879
36974
  if (this.showNumber && (this.isDesignMode || !this.locTitle.isEmpty || this.hasParentInQuestionIndex())) {
36880
36975
  visibleIndex = index;
@@ -36906,7 +37001,7 @@ var panel_PanelModel = /** @class */ (function (_super) {
36906
37001
  }
36907
37002
  };
36908
37003
  PanelModel.prototype.getRenderedTitle = function (str) {
36909
- if (!str) {
37004
+ if (this.isPanel && !str) {
36910
37005
  if (this.isCollapsed || this.isExpanded)
36911
37006
  return this.name;
36912
37007
  if (this.isDesignMode)
@@ -37031,11 +37126,7 @@ var panel_PanelModel = /** @class */ (function (_super) {
37031
37126
  return this.footerToolbarValue;
37032
37127
  };
37033
37128
  Object.defineProperty(PanelModel.prototype, "hasEditButton", {
37034
- get: function () {
37035
- if (this.survey && this.survey.state === "preview")
37036
- return (this.parent && this.parent instanceof page_PageModel);
37037
- return false;
37038
- },
37129
+ get: function () { return false; },
37039
37130
  enumerable: false,
37040
37131
  configurable: true
37041
37132
  });
@@ -37044,19 +37135,16 @@ var panel_PanelModel = /** @class */ (function (_super) {
37044
37135
  return;
37045
37136
  this.survey.cancelPreviewByPage(this);
37046
37137
  };
37047
- PanelModel.prototype.canShowTitle = function (survey) {
37048
- var page = this.originalPage;
37049
- if (!!page)
37050
- return page.canShowTitle(survey);
37051
- return _super.prototype.canShowTitle.call(this, survey);
37052
- };
37053
37138
  Object.defineProperty(PanelModel.prototype, "cssTitle", {
37054
37139
  get: function () {
37055
- return this.getCssTitle(this.cssClasses.panel);
37140
+ return this.getCssPanelTitle();
37056
37141
  },
37057
37142
  enumerable: false,
37058
37143
  configurable: true
37059
37144
  });
37145
+ PanelModel.prototype.getCssPanelTitle = function () {
37146
+ return this.getCssTitle(this.cssClasses.panel);
37147
+ };
37060
37148
  PanelModel.prototype.getCssTitleExpandableSvg = function () {
37061
37149
  if (this.state === "default")
37062
37150
  return null;
@@ -37070,6 +37158,8 @@ var panel_PanelModel = /** @class */ (function (_super) {
37070
37158
  configurable: true
37071
37159
  });
37072
37160
  PanelModel.prototype.getCssError = function (cssClasses) {
37161
+ if (this.isPage)
37162
+ return _super.prototype.getCssError.call(this, cssClasses);
37073
37163
  var builder = new CssClassBuilder()
37074
37164
  .append(_super.prototype.getCssError.call(this, cssClasses))
37075
37165
  .append(cssClasses.panel.errorsContainer);
@@ -37100,10 +37190,7 @@ var panel_PanelModel = /** @class */ (function (_super) {
37100
37190
  };
37101
37191
  Object.defineProperty(PanelModel.prototype, "showPanelAsPage", {
37102
37192
  get: function () {
37103
- var panel = this;
37104
- if (!!panel.originalPage)
37105
- return true;
37106
- return panel.survey.isShowingPreview && panel.survey.isSinglePage && !!panel.parent && !!panel.parent.originalPage;
37193
+ return false;
37107
37194
  },
37108
37195
  enumerable: false,
37109
37196
  configurable: true
@@ -37143,7 +37230,9 @@ var panel_PanelModel = /** @class */ (function (_super) {
37143
37230
  PanelModel.prototype.afterRenderCore = function (element) {
37144
37231
  var _a;
37145
37232
  _super.prototype.afterRenderCore.call(this, element);
37146
- (_a = this.survey) === null || _a === void 0 ? void 0 : _a.afterRenderPanel(this, element);
37233
+ if (this.isPanel) {
37234
+ (_a = this.survey) === null || _a === void 0 ? void 0 : _a.afterRenderPanel(this, element);
37235
+ }
37147
37236
  };
37148
37237
  return PanelModel;
37149
37238
  }(panel_PanelModelBase));
@@ -37191,27 +37280,17 @@ Serializer.addClass("panelbase", [
37191
37280
  return new panel_PanelModelBase();
37192
37281
  });
37193
37282
  Serializer.addClass("panel", [
37194
- {
37195
- name: "state",
37196
- default: "default",
37197
- choices: ["default", "collapsed", "expanded"],
37198
- },
37283
+ { name: "state", default: "default", choices: ["default", "collapsed", "expanded"] },
37199
37284
  { name: "isRequired:switch", overridingProperty: "requiredIf" },
37200
- {
37201
- name: "requiredErrorText:text",
37202
- serializationProperty: "locRequiredErrorText",
37203
- },
37285
+ { name: "requiredErrorText:text", serializationProperty: "locRequiredErrorText" },
37204
37286
  { name: "startWithNewLine:boolean", default: true },
37205
- "width",
37287
+ { name: "width" },
37206
37288
  { name: "minWidth", defaultFunc: function () { return "auto"; } },
37207
37289
  { name: "maxWidth", defaultFunc: function () { return settings.maxWidth; } },
37208
- {
37209
- name: "colSpan:number", visible: false,
37210
- onSerializeValue: function (obj) { return obj.getPropertyValue("colSpan"); },
37211
- },
37290
+ { name: "colSpan:number", visible: false, onSerializeValue: function (obj) { return obj.getPropertyValue("colSpan"); } },
37212
37291
  {
37213
37292
  name: "effectiveColSpan:number", minValue: 1, isSerializable: false,
37214
- visibleIf: function (obj) { return !!obj && !!obj.survey && obj.survey.gridLayoutEnabled; }
37293
+ visibleIf: function (obj) { return !!obj.survey && obj.survey.gridLayoutEnabled; }
37215
37294
  },
37216
37295
  { name: "innerIndent:number", default: 0, choices: [0, 1, 2, 3] },
37217
37296
  { name: "indent:number", default: 0, choices: [0, 1, 2, 3], visible: false },
@@ -37231,13 +37310,9 @@ Serializer.addClass("panel", [
37231
37310
  : [];
37232
37311
  },
37233
37312
  },
37234
- "showNumber:boolean",
37235
- {
37236
- name: "showQuestionNumbers",
37237
- default: "default",
37238
- choices: ["default", "onpanel", "off"],
37239
- },
37240
- "questionStartIndex",
37313
+ { name: "showNumber:boolean" },
37314
+ { name: "showQuestionNumbers", default: "default", choices: ["default", "onpanel", "off"] },
37315
+ { name: "questionStartIndex", visibleIf: function (obj) { return obj.isPanel; } },
37241
37316
  { name: "allowAdaptiveActions:boolean", default: true, visible: false },
37242
37317
  ], function () {
37243
37318
  return new panel_PanelModel();
@@ -37513,12 +37588,61 @@ var page_PageModel = /** @class */ (function (_super) {
37513
37588
  return this.name;
37514
37589
  };
37515
37590
  Object.defineProperty(PageModel.prototype, "isPage", {
37591
+ get: function () {
37592
+ return !this.isPanel;
37593
+ },
37594
+ enumerable: false,
37595
+ configurable: true
37596
+ });
37597
+ Object.defineProperty(PageModel.prototype, "isPanel", {
37598
+ get: function () {
37599
+ return !!this.parent;
37600
+ },
37601
+ enumerable: false,
37602
+ configurable: true
37603
+ });
37604
+ Object.defineProperty(PageModel.prototype, "showPanelAsPage", {
37516
37605
  get: function () {
37517
37606
  return true;
37518
37607
  },
37519
37608
  enumerable: false,
37520
37609
  configurable: true
37521
37610
  });
37611
+ Object.defineProperty(PageModel.prototype, "hasEditButton", {
37612
+ get: function () {
37613
+ return this.isPanel && this.survey && this.survey.state === "preview"
37614
+ && !!this.parent && !this.parent.isPanel;
37615
+ },
37616
+ enumerable: false,
37617
+ configurable: true
37618
+ });
37619
+ PageModel.prototype.getElementsForRows = function () {
37620
+ var _a;
37621
+ var q = (_a = this.survey) === null || _a === void 0 ? void 0 : _a.currentSingleQuestion;
37622
+ if (!!q) {
37623
+ if (q.page === this)
37624
+ return [q];
37625
+ return [];
37626
+ }
37627
+ return _super.prototype.getElementsForRows.call(this);
37628
+ };
37629
+ PageModel.prototype.disposeElements = function () {
37630
+ if (!this.isPageContainer) {
37631
+ _super.prototype.disposeElements.call(this);
37632
+ }
37633
+ };
37634
+ PageModel.prototype.onRemoveElement = function (element) {
37635
+ if (this.isPageContainer) {
37636
+ element.parent = null;
37637
+ this.unregisterElementPropertiesChanged(element);
37638
+ }
37639
+ else {
37640
+ _super.prototype.onRemoveElement.call(this, element);
37641
+ }
37642
+ };
37643
+ PageModel.prototype.getTemplate = function () {
37644
+ return this.isPanel ? "panel" : _super.prototype.getTemplate.call(this);
37645
+ };
37522
37646
  Object.defineProperty(PageModel.prototype, "no", {
37523
37647
  get: function () {
37524
37648
  if (!this.canShowPageNumber() || !this.survey)
@@ -37656,6 +37780,8 @@ var page_PageModel = /** @class */ (function (_super) {
37656
37780
  configurable: true
37657
37781
  });
37658
37782
  PageModel.prototype.calcCssClasses = function (css) {
37783
+ if (this.isPanel)
37784
+ return _super.prototype.calcCssClasses.call(this, css);
37659
37785
  var classes = { page: {}, error: {}, pageTitle: "", pageDescription: "", row: "", rowMultiple: "", pageRow: "", rowCompact: "", rowEnter: "", rowLeave: "", rowDelayedEnter: "", rowReplace: "" };
37660
37786
  this.copyCssClasses(classes.page, css.page);
37661
37787
  this.copyCssClasses(classes.error, css.error);
@@ -37694,20 +37820,18 @@ var page_PageModel = /** @class */ (function (_super) {
37694
37820
  }
37695
37821
  return classes;
37696
37822
  };
37697
- Object.defineProperty(PageModel.prototype, "cssTitle", {
37698
- get: function () {
37699
- if (!this.cssClasses.page)
37700
- return "";
37701
- return new CssClassBuilder()
37702
- .append(this.cssClasses.page.title)
37703
- .toString();
37704
- },
37705
- enumerable: false,
37706
- configurable: true
37707
- });
37823
+ PageModel.prototype.getCssPanelTitle = function () {
37824
+ if (this.isPanel)
37825
+ return _super.prototype.getCssPanelTitle.call(this);
37826
+ if (!this.cssClasses.page)
37827
+ return "";
37828
+ return new CssClassBuilder()
37829
+ .append(this.cssClasses.page.title)
37830
+ .toString();
37831
+ };
37708
37832
  Object.defineProperty(PageModel.prototype, "cssRoot", {
37709
37833
  get: function () {
37710
- if (!this.cssClasses.page || !this.survey)
37834
+ if (this.isPanel || !this.cssClasses.page || !this.survey)
37711
37835
  return "";
37712
37836
  return new CssClassBuilder()
37713
37837
  .append(this.cssClasses.page.root)
@@ -37719,6 +37843,8 @@ var page_PageModel = /** @class */ (function (_super) {
37719
37843
  configurable: true
37720
37844
  });
37721
37845
  PageModel.prototype.getCssError = function (cssClasses) {
37846
+ if (this.isPanel)
37847
+ return _super.prototype.getCssError.call(this, cssClasses);
37722
37848
  return new CssClassBuilder()
37723
37849
  .append(_super.prototype.getCssError.call(this, cssClasses))
37724
37850
  .append(cssClasses.page.errorsContainer).toString();
@@ -37895,7 +38021,7 @@ var page_PageModel = /** @class */ (function (_super) {
37895
38021
  jsonobject_property({ defaultValue: -1, onSet: function (val, target) { return target.onNumChanged(val); } })
37896
38022
  ], PageModel.prototype, "num", void 0);
37897
38023
  return PageModel;
37898
- }(panel_PanelModelBase));
38024
+ }(panel_PanelModel));
37899
38025
 
37900
38026
  Serializer.addClass("page", [
37901
38027
  {
@@ -37920,9 +38046,25 @@ Serializer.addClass("page", [
37920
38046
  },
37921
38047
  { name: "title:text", serializationProperty: "locTitle" },
37922
38048
  { name: "description:text", serializationProperty: "locDescription" },
38049
+ { name: "state", visible: false },
38050
+ { name: "isRequired", visible: false },
38051
+ { name: "startWithNewLine", visible: false },
38052
+ { name: "width", visible: false },
38053
+ { name: "minWidth", visible: false },
38054
+ { name: "maxWidth", visible: false },
38055
+ { name: "colSpan", visible: false, isSerializable: false },
38056
+ { name: "effectiveColSpan:number", visible: false, isSerializable: false },
38057
+ { name: "innerIndent", visible: false },
38058
+ { name: "indent", visible: false },
38059
+ { name: "page", visible: false, isSerializable: false },
38060
+ { name: "showNumber", visible: false },
38061
+ { name: "showQuestionNumbers", visible: false },
38062
+ { name: "questionStartIndex", visible: false },
38063
+ { name: "allowAdaptiveActions", visible: false },
38064
+ { name: "requiredErrorText:text", serializationProperty: "locRequiredErrorText", visible: false },
37923
38065
  ], function () {
37924
38066
  return new page_PageModel();
37925
- }, "panelbase");
38067
+ }, "panel");
37926
38068
 
37927
38069
  // CONCATENATED MODULE: ./packages/survey-core/src/progress-buttons.ts
37928
38070
  var progress_buttons_extends = (undefined && undefined.__extends) || (function () {
@@ -38164,16 +38306,27 @@ var ProgressButtonsResponsivityManager = /** @class */ (function () {
38164
38306
 
38165
38307
 
38166
38308
 
38167
-
38168
38309
  function tryFocusPage(survey, panel) {
38169
38310
  if (survey.isDesignMode)
38170
38311
  return true;
38171
38312
  panel.focusFirstQuestion();
38172
38313
  return true;
38173
38314
  }
38315
+ function getPage(question) {
38316
+ if (!!question.parentQuestion) {
38317
+ return getPage(question.parentQuestion);
38318
+ }
38319
+ var parent = question.parent;
38320
+ while (parent && parent.getType() !== "page" && parent.parent) {
38321
+ parent = parent.parent;
38322
+ }
38323
+ if (parent && parent.getType() === "page") {
38324
+ return parent;
38325
+ }
38326
+ return null;
38327
+ }
38174
38328
  function createTOCListModel(survey, onAction) {
38175
38329
  var items = getTOCItems(survey, onAction);
38176
- var selectedItem = items.filter(function (i) { return !!survey.currentPage && i.id === survey.currentPage.name; })[0] || items[0];
38177
38330
  var listOptions = {
38178
38331
  items: items,
38179
38332
  onSelectionChanged: function (item) {
@@ -38181,15 +38334,20 @@ function createTOCListModel(survey, onAction) {
38181
38334
  listModel.selectedItem = item;
38182
38335
  }
38183
38336
  },
38184
- allowSelection: true,
38185
38337
  searchEnabled: false,
38186
38338
  locOwner: survey,
38187
- selectedItem: selectedItem
38188
38339
  };
38189
38340
  var listModel = new list_ListModel(listOptions);
38190
38341
  listModel.allowSelection = false;
38342
+ var updateSelectedItem = function (currentPage, defaultSelection) {
38343
+ listModel.selectedItem = !!currentPage && listModel.actions.filter(function (i) { return i.id === currentPage.name; })[0] || defaultSelection;
38344
+ };
38345
+ updateSelectedItem(survey.currentPage, items[0]);
38191
38346
  survey.onCurrentPageChanged.add(function (s, o) {
38192
- listModel.selectedItem = listModel.actions.filter(function (i) { return !!survey.currentPage && i.id === survey.currentPage.name; })[0];
38347
+ updateSelectedItem(survey.currentPage);
38348
+ });
38349
+ survey.onFocusInQuestion.add(function (s, o) {
38350
+ updateSelectedItem(getPage(o.question));
38193
38351
  });
38194
38352
  survey.registerFunctionOnPropertyValueChanged("pages", function () {
38195
38353
  listModel.setItems(getTOCItems(survey, onAction));
@@ -38197,8 +38355,7 @@ function createTOCListModel(survey, onAction) {
38197
38355
  return listModel;
38198
38356
  }
38199
38357
  function getTOCItems(survey, onAction) {
38200
- var _a;
38201
- var pagesSource = survey.questionsOnPageMode === "singlePage" ? (_a = survey.pages[0]) === null || _a === void 0 ? void 0 : _a.elements : survey.pages;
38358
+ var pagesSource = survey.pages;
38202
38359
  var items = (pagesSource || []).map(function (page) {
38203
38360
  return new action_Action({
38204
38361
  id: page.name,
@@ -38206,7 +38363,7 @@ function getTOCItems(survey, onAction) {
38206
38363
  action: function () {
38207
38364
  DomDocumentHelper.activeElementBlur();
38208
38365
  !!onAction && onAction();
38209
- if (page instanceof page_PageModel) {
38366
+ if (page.isPage) {
38210
38367
  return survey.tryNavigateToPage(page);
38211
38368
  }
38212
38369
  return tryFocusPage(survey, page);
@@ -41919,6 +42076,8 @@ var survey_SurveyModel = /** @class */ (function (_super) {
41919
42076
  get: function () {
41920
42077
  if (this.isDesignMode)
41921
42078
  return this.pages;
42079
+ if (!!this.pageContainerValue && (this.isShowingPreview || this.isSinglePage))
42080
+ return [this.pageContainerValue];
41922
42081
  var result = new Array();
41923
42082
  for (var i = 0; i < this.pages.length; i++) {
41924
42083
  if (this.isPageInVisibleList(this.pages[i])) {
@@ -42052,7 +42211,7 @@ var survey_SurveyModel = /** @class */ (function (_super) {
42052
42211
  return false;
42053
42212
  if (index === this.currentPageNo)
42054
42213
  return false;
42055
- if (index < this.currentPageNo || this.isValidateOnComplete) {
42214
+ if (index < this.currentPageNo || this.checkErrorsMode === "onComplete" || this.validationAllowSwitchPages) {
42056
42215
  this.currentPageNo = index;
42057
42216
  return true;
42058
42217
  }
@@ -42384,6 +42543,10 @@ var survey_SurveyModel = /** @class */ (function (_super) {
42384
42543
  this.onFirstPageIsStartedChanged();
42385
42544
  if (goToFirstPage) {
42386
42545
  this.currentPage = this.firstVisiblePage;
42546
+ if (this.currentSingleQuestion) {
42547
+ var questions = this.getAllQuestions(true);
42548
+ this.currentSingleQuestion = questions.length > 0 ? questions[0] : undefined;
42549
+ }
42387
42550
  }
42388
42551
  if (clearData) {
42389
42552
  this.updateValuesWithDefaults();
@@ -42421,7 +42584,7 @@ var survey_SurveyModel = /** @class */ (function (_super) {
42421
42584
  SurveyModel.prototype.currentPageChanged = function (newValue, oldValue) {
42422
42585
  this.notifyQuestionsOnHidingContent(oldValue);
42423
42586
  var options = this.createPageChangeEventOptions(newValue, oldValue);
42424
- if (oldValue && !oldValue.passed) {
42587
+ if (oldValue && !oldValue.isDisposed && !oldValue.passed) {
42425
42588
  if (oldValue.validate(false)) {
42426
42589
  oldValue.passed = true;
42427
42590
  }
@@ -42432,9 +42595,9 @@ var survey_SurveyModel = /** @class */ (function (_super) {
42432
42595
  this.onCurrentPageChanged.fire(this, options);
42433
42596
  };
42434
42597
  SurveyModel.prototype.notifyQuestionsOnHidingContent = function (page) {
42435
- if (!page)
42436
- return;
42437
- page.questions.forEach(function (q) { return q.onHidingContent(); });
42598
+ if (page && !page.isDisposed) {
42599
+ page.questions.forEach(function (q) { return q.onHidingContent(); });
42600
+ }
42438
42601
  };
42439
42602
  SurveyModel.prototype.createPageChangeEventOptions = function (newValue, oldValue) {
42440
42603
  var diff = !!newValue && !!oldValue ? newValue.visibleIndex - oldValue.visibleIndex : 0;
@@ -42670,6 +42833,30 @@ var survey_SurveyModel = /** @class */ (function (_super) {
42670
42833
  return false;
42671
42834
  return this.doCurrentPageComplete(false);
42672
42835
  };
42836
+ SurveyModel.prototype.performNext = function () {
42837
+ var q = this.currentSingleQuestion;
42838
+ if (!q)
42839
+ return this.nextPage();
42840
+ if (!q.validate(true))
42841
+ return false;
42842
+ var questions = this.getAllQuestions(true);
42843
+ var index = questions.indexOf(q);
42844
+ if (index < 0 || index === questions.length - 1)
42845
+ return false;
42846
+ this.currentSingleQuestion = questions[index + 1];
42847
+ return true;
42848
+ };
42849
+ SurveyModel.prototype.performPrevious = function () {
42850
+ var q = this.currentSingleQuestion;
42851
+ if (!q)
42852
+ return this.prevPage();
42853
+ var questions = this.getAllQuestions(true);
42854
+ var index = questions.indexOf(q);
42855
+ if (index === 0)
42856
+ return false;
42857
+ this.currentSingleQuestion = questions[index - 1];
42858
+ return true;
42859
+ };
42673
42860
  SurveyModel.prototype.hasErrorsOnNavigate = function (doComplete) {
42674
42861
  var _this = this;
42675
42862
  if (!this.isEditMode || this.ignoreValidation)
@@ -42999,9 +43186,9 @@ var survey_SurveyModel = /** @class */ (function (_super) {
42999
43186
  };
43000
43187
  SurveyModel.prototype.nextPageUIClick = function () {
43001
43188
  if (!!this.mouseDownPage && this.mouseDownPage !== this.activePage)
43002
- return;
43189
+ return false;
43003
43190
  this.mouseDownPage = null;
43004
- return this.nextPage();
43191
+ return this.performNext();
43005
43192
  };
43006
43193
  SurveyModel.prototype.nextPageMouseDown = function () {
43007
43194
  this.mouseDownPage = this.activePage;
@@ -43045,7 +43232,7 @@ var survey_SurveyModel = /** @class */ (function (_super) {
43045
43232
  this.isShowingPreview = false;
43046
43233
  };
43047
43234
  SurveyModel.prototype.cancelPreviewByPage = function (panel) {
43048
- this.cancelPreview(panel["originalPage"]);
43235
+ this.cancelPreview(panel);
43049
43236
  };
43050
43237
  SurveyModel.prototype.doCurrentPageComplete = function (doComplete) {
43051
43238
  if (this.isValidatingOnServer)
@@ -43075,6 +43262,16 @@ var survey_SurveyModel = /** @class */ (function (_super) {
43075
43262
  enumerable: false,
43076
43263
  configurable: true
43077
43264
  });
43265
+ Object.defineProperty(SurveyModel.prototype, "isSingleVisibleQuestion", {
43266
+ get: function () {
43267
+ return this.isSingleVisibleQuestionVal(this.questionsOnPageMode);
43268
+ },
43269
+ enumerable: false,
43270
+ configurable: true
43271
+ });
43272
+ SurveyModel.prototype.isSingleVisibleQuestionVal = function (val) {
43273
+ return val === "questionPerPage" || val === "questionOnPage";
43274
+ };
43078
43275
  Object.defineProperty(SurveyModel.prototype, "questionsOnPageMode", {
43079
43276
  /**
43080
43277
  * Specifies how to distribute survey elements between pages.
@@ -43150,25 +43347,54 @@ var survey_SurveyModel = /** @class */ (function (_super) {
43150
43347
  this.pageVisibilityChanged(this.pages[0], !this.isStartedState);
43151
43348
  };
43152
43349
  SurveyModel.prototype.onShowingPreviewChanged = function () {
43350
+ this.updatePagesContainer();
43351
+ };
43352
+ SurveyModel.prototype.createRootPage = function (name, pages) {
43353
+ var container = Serializer.createClass("page");
43354
+ container.name = name;
43355
+ container.isPageContainer = true;
43356
+ pages.forEach(function (page) {
43357
+ if (!page.isStartPage) {
43358
+ container.addElement(page);
43359
+ }
43360
+ });
43361
+ return container;
43362
+ };
43363
+ SurveyModel.prototype.disposeContainerPage = function () {
43364
+ var cPage = this.pageContainerValue;
43365
+ var elements = [].concat(cPage.elements);
43366
+ elements.forEach(function (el) { return cPage.removeElement(el); });
43367
+ cPage.dispose();
43368
+ this.pageContainerValue = undefined;
43369
+ };
43370
+ SurveyModel.prototype.updatePagesContainer = function () {
43153
43371
  if (this.isDesignMode)
43154
43372
  return;
43155
- if (this.isShowingPreview) {
43156
- this.runningPages = this.pages.slice(0, this.pages.length);
43157
- this.setupPagesForPageModes(true, false);
43158
- }
43159
- else {
43160
- if (this.runningPages) {
43161
- this.restoreOriginalPages(this.runningPages);
43373
+ this.getAllQuestions().forEach(function (q) { return q.updateElementVisibility(); });
43374
+ this.setPropertyValue("currentPage", undefined);
43375
+ var singleName = "single-page";
43376
+ var previewName = "preview-page";
43377
+ var rootPage = undefined;
43378
+ if (this.isSinglePage) {
43379
+ var cPage = this.pageContainerValue;
43380
+ if (cPage && cPage.name === previewName) {
43381
+ rootPage = cPage.elements[0];
43382
+ this.disposeContainerPage();
43383
+ }
43384
+ else {
43385
+ rootPage = this.createRootPage(singleName, this.pages);
43162
43386
  }
43163
- this.runningPages = undefined;
43164
43387
  }
43165
- this.runConditions();
43166
- this.updateAllElementsVisibility(this.pages);
43167
- this.updateVisibleIndexes();
43168
43388
  if (this.isShowingPreview) {
43169
- this.currentPageNo = 0;
43389
+ rootPage = this.createRootPage(previewName, rootPage ? [rootPage] : this.pages);
43170
43390
  }
43171
- else {
43391
+ if (rootPage) {
43392
+ rootPage.setSurveyImpl(this);
43393
+ this.pageContainerValue = rootPage;
43394
+ this.currentPage = rootPage;
43395
+ }
43396
+ if (!this.isSinglePage && !this.isShowingPreview) {
43397
+ this.disposeContainerPage();
43172
43398
  var curPage = this.gotoPageFromPreview;
43173
43399
  this.gotoPageFromPreview = null;
43174
43400
  if (helpers_Helpers.isValueEmpty(curPage) && this.visiblePageCount > 0) {
@@ -43180,110 +43406,62 @@ var survey_SurveyModel = /** @class */ (function (_super) {
43180
43406
  this.changeCurrentPageFromPreview = false;
43181
43407
  }
43182
43408
  }
43409
+ if (!this.currentPage && this.visiblePageCount > 0) {
43410
+ this.currentPage = this.visiblePages[0];
43411
+ }
43412
+ this.pages.forEach(function (page) {
43413
+ if (page.hasShown) {
43414
+ page.updateElementCss(true);
43415
+ }
43416
+ });
43417
+ this.updateButtonsVisibility();
43183
43418
  };
43184
- SurveyModel.prototype.onQuestionsOnPageModeChanged = function (oldValue, isFirstLoad) {
43185
- if (isFirstLoad === void 0) { isFirstLoad = false; }
43419
+ Object.defineProperty(SurveyModel.prototype, "currentSingleQuestion", {
43420
+ get: function () { return this.currentSingleQuestionValue; },
43421
+ set: function (val) {
43422
+ if (val !== this.currentSingleQuestion) {
43423
+ this.currentSingleQuestionValue = val;
43424
+ if (!!val) {
43425
+ var page = val.page;
43426
+ page.updateRows();
43427
+ if (page !== this.currentPage) {
43428
+ this.currentPage = page;
43429
+ }
43430
+ else {
43431
+ if (this.focusFirstQuestionAutomatic) {
43432
+ val.focus();
43433
+ }
43434
+ }
43435
+ this.updateButtonsVisibility();
43436
+ }
43437
+ else {
43438
+ this.visiblePages.forEach(function (page) { return page.updateRows(); });
43439
+ }
43440
+ }
43441
+ },
43442
+ enumerable: false,
43443
+ configurable: true
43444
+ });
43445
+ SurveyModel.prototype.onQuestionsOnPageModeChanged = function (oldValue) {
43186
43446
  if (this.isShowingPreview)
43187
43447
  return;
43188
- if (this.questionsOnPageMode == "standard" || this.isDesignMode) {
43189
- if (this.originalPages) {
43190
- this.restoreOriginalPages(this.originalPages);
43191
- }
43192
- this.originalPages = undefined;
43448
+ this.currentSingleQuestion = undefined;
43449
+ if (oldValue === "singlePage") {
43450
+ this.updatePagesContainer();
43193
43451
  }
43194
- else {
43195
- if (!oldValue || oldValue == "standard") {
43196
- this.originalPages = this.pages.slice(0, this.pages.length);
43197
- }
43198
- this.setupPagesForPageModes(this.isSinglePage, isFirstLoad);
43452
+ if (this.isSinglePage) {
43453
+ this.updatePagesContainer();
43199
43454
  }
43200
- this.runConditions();
43201
- this.updateVisibleIndexes();
43202
- };
43203
- SurveyModel.prototype.restoreOriginalPages = function (originalPages) {
43204
- this.questionHashesClear();
43205
- this.pages.splice(0, this.pages.length);
43206
- for (var i = 0; i < originalPages.length; i++) {
43207
- var page = originalPages[i];
43208
- page.setWasShown(false);
43209
- this.pages.push(page);
43455
+ if (this.isSingleVisibleQuestion) {
43456
+ var questions = this.getAllQuestions(true);
43457
+ if (questions.length > 0) {
43458
+ this.currentSingleQuestion = questions[0];
43459
+ }
43210
43460
  }
43211
43461
  };
43212
43462
  SurveyModel.prototype.getPageStartIndex = function () {
43213
43463
  return this.firstPageIsStarted && this.pages.length > 0 ? 1 : 0;
43214
43464
  };
43215
- SurveyModel.prototype.setupPagesForPageModes = function (isSinglePage, isFirstLoad) {
43216
- var _this = this;
43217
- this.questionHashesClear();
43218
- if (this.firstPageIsStarted && this.pages.length > 0) {
43219
- this.pages[0].questions.forEach(function (q) { return _this.questionHashesAdded(q); });
43220
- }
43221
- this.isLockingUpdateOnPageModes = !isFirstLoad;
43222
- var startIndex = this.getPageStartIndex();
43223
- _super.prototype.startLoadingFromJson.call(this);
43224
- var newPages = this.createPagesForQuestionOnPageMode(isSinglePage, startIndex);
43225
- var deletedLen = this.pages.length - startIndex;
43226
- this.pages.splice(startIndex, deletedLen);
43227
- for (var i = 0; i < newPages.length; i++) {
43228
- this.pages.push(newPages[i]);
43229
- }
43230
- _super.prototype.endLoadingFromJson.call(this);
43231
- for (var i = 0; i < newPages.length; i++) {
43232
- newPages[i].setSurveyImpl(this, true);
43233
- }
43234
- this.doElementsOnLoad();
43235
- this.updateCurrentPage();
43236
- this.isLockingUpdateOnPageModes = false;
43237
- };
43238
- SurveyModel.prototype.createPagesForQuestionOnPageMode = function (isSinglePage, startIndex) {
43239
- if (isSinglePage) {
43240
- return [this.createSinglePage(startIndex)];
43241
- }
43242
- return this.createPagesForEveryQuestion(startIndex);
43243
- };
43244
- SurveyModel.prototype.createSinglePage = function (startIndex) {
43245
- var single = this.createNewPage("all");
43246
- single.setSurveyImpl(this);
43247
- for (var i = startIndex; i < this.pages.length; i++) {
43248
- var page = this.pages[i];
43249
- var panel = Serializer.createClass("panel");
43250
- panel.originalPage = page;
43251
- single.addPanel(panel);
43252
- var json = new jsonobject_JsonObject().toJsonObject(page);
43253
- new jsonobject_JsonObject().toObject(json, panel);
43254
- }
43255
- return single;
43256
- };
43257
- SurveyModel.prototype.createPagesForEveryQuestion = function (startIndex) {
43258
- var res = [];
43259
- for (var i = startIndex; i < this.pages.length; i++) {
43260
- var originalPage = this.pages[i];
43261
- // Initialize randomization
43262
- originalPage.setWasShown(true);
43263
- for (var j = 0; j < originalPage.elements.length; j++) {
43264
- var originalElement = originalPage.elements[j];
43265
- var element = Serializer.createClass(originalElement.getType());
43266
- if (!element)
43267
- continue;
43268
- var jsonObj = new jsonobject_JsonObject();
43269
- //Deserialize page properties only, excluding elements
43270
- jsonObj.lightSerializing = true;
43271
- var pageJson = jsonObj.toJsonObject(originalPage);
43272
- var page = Serializer.createClass(originalPage.getType());
43273
- page.fromJSON(pageJson);
43274
- page.name = originalElement.name;
43275
- page.setSurveyImpl(this);
43276
- res.push(page);
43277
- var json = new jsonobject_JsonObject().toJsonObject(originalElement);
43278
- page.addElement(element);
43279
- new jsonobject_JsonObject().toObject(json, element);
43280
- for (var k = 0; k < page.questions.length; k++) {
43281
- this.questionHashesAdded(page.questions[k]);
43282
- }
43283
- }
43284
- }
43285
- return res;
43286
- };
43287
43465
  Object.defineProperty(SurveyModel.prototype, "isFirstPage", {
43288
43466
  /**
43289
43467
  * Indicates whether the [current page](#currentPage) is the first page.
@@ -43349,30 +43527,73 @@ var survey_SurveyModel = /** @class */ (function (_super) {
43349
43527
  enumerable: false,
43350
43528
  configurable: true
43351
43529
  });
43530
+ Object.defineProperty(SurveyModel.prototype, "isFirstElement", {
43531
+ get: function () {
43532
+ return this.getPropertyValue("isFirstElement");
43533
+ },
43534
+ enumerable: false,
43535
+ configurable: true
43536
+ });
43537
+ Object.defineProperty(SurveyModel.prototype, "isLastElement", {
43538
+ get: function () {
43539
+ return this.getPropertyValue("isLastElement");
43540
+ },
43541
+ enumerable: false,
43542
+ configurable: true
43543
+ });
43352
43544
  SurveyModel.prototype.updateIsFirstLastPageState = function () {
43353
43545
  var curPage = this.currentPage;
43354
43546
  this.setPropertyValue("isFirstPage", !!curPage && curPage === this.firstVisiblePage);
43355
43547
  this.setPropertyValue("isLastPage", !!curPage && curPage === this.lastVisiblePage);
43548
+ var fVal = undefined;
43549
+ var lVal = undefined;
43550
+ var q = this.currentSingleQuestion;
43551
+ if (!!q) {
43552
+ var questions = this.getAllQuestions(true);
43553
+ var index = questions.indexOf(q);
43554
+ if (index >= 0) {
43555
+ fVal = index === 0;
43556
+ lVal = index === questions.length - 1;
43557
+ }
43558
+ }
43559
+ this.setPropertyValue("isFirstElement", fVal);
43560
+ this.setPropertyValue("isLastElement", lVal);
43356
43561
  };
43562
+ Object.defineProperty(SurveyModel.prototype, "isLastPageOrElement", {
43563
+ get: function () {
43564
+ return this.isLastElement !== undefined ? this.isLastElement : this.isLastPage;
43565
+ },
43566
+ enumerable: false,
43567
+ configurable: true
43568
+ });
43569
+ Object.defineProperty(SurveyModel.prototype, "isFirstPageOrElement", {
43570
+ get: function () {
43571
+ return this.isFirstElement !== undefined ? this.isFirstElement : this.isFirstPage;
43572
+ },
43573
+ enumerable: false,
43574
+ configurable: true
43575
+ });
43357
43576
  SurveyModel.prototype.calcIsShowPrevButton = function () {
43358
- if (this.isFirstPage || !this.showPrevButton || this.state !== "running")
43577
+ if (this.isFirstPageOrElement || !this.showPrevButton || this.state !== "running")
43359
43578
  return false;
43579
+ if (this.isFirstElement !== undefined)
43580
+ return true;
43360
43581
  var page = this.visiblePages[this.currentPageNo - 1];
43361
43582
  return page && page.getMaxTimeToFinish() <= 0;
43362
43583
  };
43363
43584
  SurveyModel.prototype.calcIsShowNextButton = function () {
43364
- return this.state === "running" && !this.isLastPage && !this.canBeCompletedByTrigger;
43585
+ return this.state === "running" && !this.isLastPageOrElement && !this.canBeCompletedByTrigger;
43365
43586
  };
43366
43587
  SurveyModel.prototype.calcIsCompleteButtonVisible = function () {
43367
43588
  var state = this.state;
43368
43589
  return this.isEditMode && (this.state === "running" &&
43369
- (this.isLastPage && !this.isShowPreviewBeforeComplete || this.canBeCompletedByTrigger)
43590
+ (this.isLastPageOrElement && !this.isShowPreviewBeforeComplete || this.canBeCompletedByTrigger)
43370
43591
  || state === "preview") && this.showCompleteButton;
43371
43592
  };
43372
43593
  SurveyModel.prototype.calcIsPreviewButtonVisible = function () {
43373
43594
  return (this.isEditMode &&
43374
43595
  this.isShowPreviewBeforeComplete &&
43375
- this.state == "running" && this.isLastPage);
43596
+ this.state == "running" && this.isLastPageOrElement);
43376
43597
  };
43377
43598
  SurveyModel.prototype.calcIsCancelPreviewButtonVisible = function () {
43378
43599
  return (this.isEditMode &&
@@ -43381,6 +43602,8 @@ var survey_SurveyModel = /** @class */ (function (_super) {
43381
43602
  };
43382
43603
  Object.defineProperty(SurveyModel.prototype, "firstVisiblePage", {
43383
43604
  get: function () {
43605
+ if (this.visiblePageCount === 1)
43606
+ return this.visiblePages[0];
43384
43607
  var pages = this.pages;
43385
43608
  for (var i = 0; i < pages.length; i++) {
43386
43609
  if (this.isPageInVisibleList(pages[i]))
@@ -43393,6 +43616,8 @@ var survey_SurveyModel = /** @class */ (function (_super) {
43393
43616
  });
43394
43617
  Object.defineProperty(SurveyModel.prototype, "lastVisiblePage", {
43395
43618
  get: function () {
43619
+ if (this.visiblePageCount === 1)
43620
+ return this.visiblePages[0];
43396
43621
  var pages = this.pages;
43397
43622
  for (var i = pages.length - 1; i >= 0; i--) {
43398
43623
  if (this.isPageInVisibleList(pages[i]))
@@ -43741,7 +43966,7 @@ var survey_SurveyModel = /** @class */ (function (_super) {
43741
43966
  });
43742
43967
  SurveyModel.prototype.updateProgressText = function (onValueChanged) {
43743
43968
  if (onValueChanged === void 0) { onValueChanged = false; }
43744
- if (this.isCalculatingProgressText || this.isShowingPreview || this.isLockingUpdateOnPageModes)
43969
+ if (this.isCalculatingProgressText || this.isShowingPreview)
43745
43970
  return;
43746
43971
  if (onValueChanged &&
43747
43972
  this.progressBarType == "pages" &&
@@ -43852,7 +44077,7 @@ var survey_SurveyModel = /** @class */ (function (_super) {
43852
44077
  width: width,
43853
44078
  };
43854
44079
  this.onResize.fire(this, options);
43855
- this.setResponsiveStartWidth(width);
44080
+ // this.setResponsiveStartWidth(width);
43856
44081
  return isMobileChanged;
43857
44082
  };
43858
44083
  SurveyModel.prototype.triggerResponsiveness = function (hard) {
@@ -45083,7 +45308,7 @@ var survey_SurveyModel = /** @class */ (function (_super) {
45083
45308
  this.updateVisibleIndexes();
45084
45309
  };
45085
45310
  SurveyModel.prototype.updateVisibleIndexes = function (page) {
45086
- if (this.isLoadingFromJson || !!this.isEndLoadingFromJson || this.isLockingUpdateOnPageModes)
45311
+ if (this.isLoadingFromJson || !!this.isEndLoadingFromJson)
45087
45312
  return;
45088
45313
  if (this.isRunningConditions &&
45089
45314
  this.onQuestionVisibleChanged.isEmpty &&
@@ -45152,12 +45377,12 @@ var survey_SurveyModel = /** @class */ (function (_super) {
45152
45377
  SurveyModel.prototype.endLoadingFromJson = function () {
45153
45378
  this.isEndLoadingFromJson = "processing";
45154
45379
  this.onFirstPageIsStartedChanged();
45155
- this.onQuestionsOnPageModeChanged("standard", true);
45156
45380
  _super.prototype.endLoadingFromJson.call(this);
45157
45381
  if (this.hasCookie) {
45158
45382
  this.isCompletedBefore = true;
45159
45383
  }
45160
45384
  this.doElementsOnLoad();
45385
+ this.onQuestionsOnPageModeChanged("standard");
45161
45386
  this.isEndLoadingFromJson = "conditions";
45162
45387
  this.runConditions();
45163
45388
  this.notifyElementsOnAnyValueOrVariableChanged("");
@@ -45205,7 +45430,7 @@ var survey_SurveyModel = /** @class */ (function (_super) {
45205
45430
  mouseDown: function () { return _this.navigationMouseDown(); },
45206
45431
  },
45207
45432
  locTitle: this.locPagePrevText,
45208
- action: function () { return _this.prevPage(); },
45433
+ action: function () { return _this.performPrevious(); },
45209
45434
  component: defaultComponent
45210
45435
  });
45211
45436
  var navNext = new action_Action({
@@ -45485,8 +45710,6 @@ var survey_SurveyModel = /** @class */ (function (_super) {
45485
45710
  SurveyModel.prototype.setValue = function (name, newQuestionValue, locNotification, allowNotifyValueChanged, questionName) {
45486
45711
  if (locNotification === void 0) { locNotification = false; }
45487
45712
  if (allowNotifyValueChanged === void 0) { allowNotifyValueChanged = true; }
45488
- if (this.isLockingUpdateOnPageModes)
45489
- return;
45490
45713
  var newValue = newQuestionValue;
45491
45714
  if (allowNotifyValueChanged) {
45492
45715
  newValue = this.questionOnValueChanging(name, newQuestionValue);
@@ -46171,6 +46394,7 @@ var survey_SurveyModel = /** @class */ (function (_super) {
46171
46394
  if (this.isScaled && this.responsiveStartWidth > 1) {
46172
46395
  var initialWidth = this.responsiveStartWidth;
46173
46396
  try {
46397
+ width = width || this.staticStartWidth;
46174
46398
  initialWidth = !isNaN(width) ? width : parseFloat(width.toString().replace("px", ""));
46175
46399
  }
46176
46400
  catch (e) { }
@@ -46183,6 +46407,9 @@ var survey_SurveyModel = /** @class */ (function (_super) {
46183
46407
  enumerable: false,
46184
46408
  configurable: true
46185
46409
  });
46410
+ SurveyModel.prototype.setStaticStartWidth = function (width) {
46411
+ this.staticStartWidth = width;
46412
+ };
46186
46413
  SurveyModel.prototype.setResponsiveStartWidth = function (width) {
46187
46414
  this.responsiveStartWidth = width;
46188
46415
  };
@@ -47019,8 +47246,16 @@ var survey_SurveyModel = /** @class */ (function (_super) {
47019
47246
  jsonobject_property()
47020
47247
  ], SurveyModel.prototype, "calculatedWidthMode", void 0);
47021
47248
  survey_decorate([
47022
- jsonobject_property({ defaultValue: 100 })
47249
+ jsonobject_property({
47250
+ defaultValue: 100,
47251
+ onSet: function (val, target, prevVal) {
47252
+ target.pages.forEach(function (p) { return p.updateRootStyle(); });
47253
+ },
47254
+ })
47023
47255
  ], SurveyModel.prototype, "widthScale", void 0);
47256
+ survey_decorate([
47257
+ jsonobject_property()
47258
+ ], SurveyModel.prototype, "staticStartWidth", void 0);
47024
47259
  survey_decorate([
47025
47260
  jsonobject_property()
47026
47261
  ], SurveyModel.prototype, "responsiveStartWidth", void 0);
@@ -54275,6 +54510,9 @@ var question_multipletext_MultipleTextItemModel = /** @class */ (function (_supe
54275
54510
  if (title) {
54276
54511
  _this.title = title;
54277
54512
  }
54513
+ _this.editor.onPropertyChanged.add(function (sender, options) {
54514
+ _this.onPropertyChanged.fire(_this, options);
54515
+ });
54278
54516
  return _this;
54279
54517
  }
54280
54518
  MultipleTextItemModel.prototype.getType = function () {
@@ -59296,7 +59534,13 @@ var question_file_QuestionFileModel = /** @class */ (function (_super) {
59296
59534
  };
59297
59535
  _this.doClean = function () {
59298
59536
  if (_this.needConfirmRemoveFile) {
59299
- confirmActionAsync(_this.confirmRemoveAllMessage, function () { _this.clearFilesCore(); }, undefined, _this.getLocale(), _this.survey.rootElement);
59537
+ confirmActionAsync({
59538
+ message: _this.confirmRemoveAllMessage,
59539
+ funcOnYes: function () { _this.clearFilesCore(); },
59540
+ locale: _this.getLocale(),
59541
+ rootElement: _this.survey.rootElement,
59542
+ cssClass: _this.cssClasses.confirmDialog
59543
+ });
59300
59544
  return;
59301
59545
  }
59302
59546
  _this.clearFilesCore();
@@ -59596,7 +59840,7 @@ var question_file_QuestionFileModel = /** @class */ (function (_super) {
59596
59840
  if (this.previewValue.length > 0 && !this.calculatedGapBetweenItems && !this.calculatedItemWidth) {
59597
59841
  setTimeout(function () {
59598
59842
  _this.processResponsiveness(0, _this._width);
59599
- });
59843
+ }, 1);
59600
59844
  }
59601
59845
  this.prevPreviewLength = this.previewValue.length;
59602
59846
  };
@@ -60305,7 +60549,13 @@ var question_file_QuestionFileModel = /** @class */ (function (_super) {
60305
60549
  var _this = this;
60306
60550
  event.stopPropagation();
60307
60551
  if (this.needConfirmRemoveFile) {
60308
- confirmActionAsync(this.getConfirmRemoveMessage(data.name), function () { _this.removeFileCore(data); }, undefined, this.getLocale(), this.survey.rootElement);
60552
+ confirmActionAsync({
60553
+ message: this.getConfirmRemoveMessage(data.name),
60554
+ funcOnYes: function () { _this.clearFilesCore(); },
60555
+ locale: this.getLocale(),
60556
+ rootElement: this.survey.rootElement,
60557
+ cssClass: this.cssClasses.confirmDialog
60558
+ });
60309
60559
  return;
60310
60560
  }
60311
60561
  this.removeFileCore(data);
@@ -66290,7 +66540,13 @@ var question_paneldynamic_QuestionPanelDynamicModel = /** @class */ (function (_
66290
66540
  }
66291
66541
  };
66292
66542
  if (this.isRequireConfirmOnDelete(value)) {
66293
- confirmActionAsync(this.confirmDeleteText, function () { removePanel(); }, undefined, this.getLocale(), this.survey.rootElement);
66543
+ confirmActionAsync({
66544
+ message: this.confirmDeleteText,
66545
+ funcOnYes: function () { removePanel(); },
66546
+ locale: this.getLocale(),
66547
+ rootElement: this.survey.rootElement,
66548
+ cssClass: this.cssClasses.confirmDialog
66549
+ });
66294
66550
  }
66295
66551
  else {
66296
66552
  removePanel();
@@ -70431,8 +70687,8 @@ Serializer.addClass("currencymask", [
70431
70687
 
70432
70688
  var Version;
70433
70689
  var ReleaseDate;
70434
- Version = "" + "1.12.14";
70435
- ReleaseDate = "" + "2024-12-09";
70690
+ Version = "" + "1.12.16";
70691
+ ReleaseDate = "" + "2024-12-24";
70436
70692
  function checkLibraryVersion(ver, libraryName) {
70437
70693
  if (Version != ver) {
70438
70694
  var str = "survey-core has version '" + Version + "' and " + libraryName