survey-core 2.3.4 → 2.3.5

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 (281) hide show
  1. package/fesm/i18n/arabic.mjs +1 -1
  2. package/fesm/i18n/basque.mjs +1 -1
  3. package/fesm/i18n/bulgarian.mjs +1 -1
  4. package/fesm/i18n/burmese.mjs +1 -1
  5. package/fesm/i18n/catalan.mjs +1 -1
  6. package/fesm/i18n/croatian.mjs +1 -1
  7. package/fesm/i18n/czech.mjs +1 -1
  8. package/fesm/i18n/danish.mjs +1 -1
  9. package/fesm/i18n/dutch.mjs +1 -1
  10. package/fesm/i18n/english.mjs +1 -1
  11. package/fesm/i18n/estonian.mjs +1 -1
  12. package/fesm/i18n/finnish.mjs +1 -1
  13. package/fesm/i18n/french.mjs +1 -1
  14. package/fesm/i18n/georgian.mjs +1 -1
  15. package/fesm/i18n/german.mjs +1 -1
  16. package/fesm/i18n/greek.mjs +1 -1
  17. package/fesm/i18n/haitian-creole.mjs +1 -1
  18. package/fesm/i18n/hebrew.mjs +1 -1
  19. package/fesm/i18n/hindi.mjs +1 -1
  20. package/fesm/i18n/hungarian.mjs +1 -1
  21. package/fesm/i18n/icelandic.mjs +1 -1
  22. package/fesm/i18n/index.mjs +1 -1
  23. package/fesm/i18n/indonesian.mjs +1 -1
  24. package/fesm/i18n/italian.mjs +1 -1
  25. package/fesm/i18n/japanese.mjs +1 -1
  26. package/fesm/i18n/kazakh.mjs +1 -1
  27. package/fesm/i18n/korean.mjs +1 -1
  28. package/fesm/i18n/latvian.mjs +1 -1
  29. package/fesm/i18n/lithuanian.mjs +1 -1
  30. package/fesm/i18n/macedonian.mjs +1 -1
  31. package/fesm/i18n/malay.mjs +1 -1
  32. package/fesm/i18n/nl-BE.mjs +1 -1
  33. package/fesm/i18n/norwegian.mjs +1 -1
  34. package/fesm/i18n/persian.mjs +1 -1
  35. package/fesm/i18n/philippines.mjs +1 -1
  36. package/fesm/i18n/polish.mjs +1 -1
  37. package/fesm/i18n/portuguese-br.mjs +1 -1
  38. package/fesm/i18n/portuguese.mjs +1 -1
  39. package/fesm/i18n/romanian.mjs +1 -1
  40. package/fesm/i18n/russian.mjs +1 -1
  41. package/fesm/i18n/serbian.mjs +1 -1
  42. package/fesm/i18n/simplified-chinese.mjs +1 -1
  43. package/fesm/i18n/slovak.mjs +1 -1
  44. package/fesm/i18n/slovenian.mjs +1 -1
  45. package/fesm/i18n/spanish.mjs +1 -1
  46. package/fesm/i18n/swahili.mjs +1 -1
  47. package/fesm/i18n/swedish.mjs +1 -1
  48. package/fesm/i18n/tajik.mjs +1 -1
  49. package/fesm/i18n/telugu.mjs +1 -1
  50. package/fesm/i18n/thai.mjs +1 -1
  51. package/fesm/i18n/traditional-chinese.mjs +1 -1
  52. package/fesm/i18n/turkish.mjs +1 -1
  53. package/fesm/i18n/ukrainian.mjs +1 -1
  54. package/fesm/i18n/urdu.mjs +1 -1
  55. package/fesm/i18n/vietnamese.mjs +1 -1
  56. package/fesm/i18n/welsh.mjs +1 -1
  57. package/fesm/icons/iconsV1.mjs +1 -1
  58. package/fesm/icons/iconsV2.mjs +1 -1
  59. package/fesm/survey-core.mjs +146 -61
  60. package/fesm/survey-core.mjs.map +1 -1
  61. package/fesm/survey.i18n.mjs +1 -1
  62. package/fesm/themes/index.mjs +1 -1
  63. package/i18n/arabic.js +1 -1
  64. package/i18n/arabic.min.js.LICENSE.txt +1 -1
  65. package/i18n/basque.js +1 -1
  66. package/i18n/basque.min.js.LICENSE.txt +1 -1
  67. package/i18n/bulgarian.js +1 -1
  68. package/i18n/bulgarian.min.js.LICENSE.txt +1 -1
  69. package/i18n/burmese.js +1 -1
  70. package/i18n/burmese.min.js.LICENSE.txt +1 -1
  71. package/i18n/catalan.js +1 -1
  72. package/i18n/catalan.min.js.LICENSE.txt +1 -1
  73. package/i18n/croatian.js +1 -1
  74. package/i18n/croatian.min.js.LICENSE.txt +1 -1
  75. package/i18n/czech.js +1 -1
  76. package/i18n/czech.min.js.LICENSE.txt +1 -1
  77. package/i18n/danish.js +1 -1
  78. package/i18n/danish.min.js.LICENSE.txt +1 -1
  79. package/i18n/dutch.js +1 -1
  80. package/i18n/dutch.min.js.LICENSE.txt +1 -1
  81. package/i18n/english.js +1 -1
  82. package/i18n/english.min.js.LICENSE.txt +1 -1
  83. package/i18n/estonian.js +1 -1
  84. package/i18n/estonian.min.js.LICENSE.txt +1 -1
  85. package/i18n/finnish.js +1 -1
  86. package/i18n/finnish.min.js.LICENSE.txt +1 -1
  87. package/i18n/french.js +1 -1
  88. package/i18n/french.min.js.LICENSE.txt +1 -1
  89. package/i18n/georgian.js +1 -1
  90. package/i18n/georgian.min.js.LICENSE.txt +1 -1
  91. package/i18n/german.js +1 -1
  92. package/i18n/german.min.js.LICENSE.txt +1 -1
  93. package/i18n/greek.js +1 -1
  94. package/i18n/greek.min.js.LICENSE.txt +1 -1
  95. package/i18n/haitian-creole.js +1 -1
  96. package/i18n/haitian-creole.min.js.LICENSE.txt +1 -1
  97. package/i18n/hebrew.js +1 -1
  98. package/i18n/hebrew.min.js.LICENSE.txt +1 -1
  99. package/i18n/hindi.js +1 -1
  100. package/i18n/hindi.min.js.LICENSE.txt +1 -1
  101. package/i18n/hungarian.js +1 -1
  102. package/i18n/hungarian.min.js.LICENSE.txt +1 -1
  103. package/i18n/icelandic.js +1 -1
  104. package/i18n/icelandic.min.js.LICENSE.txt +1 -1
  105. package/i18n/index.js +1 -1
  106. package/i18n/index.min.js.LICENSE.txt +1 -1
  107. package/i18n/indonesian.js +1 -1
  108. package/i18n/indonesian.min.js.LICENSE.txt +1 -1
  109. package/i18n/italian.js +1 -1
  110. package/i18n/italian.min.js.LICENSE.txt +1 -1
  111. package/i18n/japanese.js +1 -1
  112. package/i18n/japanese.min.js.LICENSE.txt +1 -1
  113. package/i18n/kazakh.js +1 -1
  114. package/i18n/kazakh.min.js.LICENSE.txt +1 -1
  115. package/i18n/korean.js +1 -1
  116. package/i18n/korean.min.js.LICENSE.txt +1 -1
  117. package/i18n/latvian.js +1 -1
  118. package/i18n/latvian.min.js.LICENSE.txt +1 -1
  119. package/i18n/lithuanian.js +1 -1
  120. package/i18n/lithuanian.min.js.LICENSE.txt +1 -1
  121. package/i18n/macedonian.js +1 -1
  122. package/i18n/macedonian.min.js.LICENSE.txt +1 -1
  123. package/i18n/malay.js +1 -1
  124. package/i18n/malay.min.js.LICENSE.txt +1 -1
  125. package/i18n/nl-BE.js +1 -1
  126. package/i18n/nl-BE.min.js.LICENSE.txt +1 -1
  127. package/i18n/norwegian.js +1 -1
  128. package/i18n/norwegian.min.js.LICENSE.txt +1 -1
  129. package/i18n/persian.js +1 -1
  130. package/i18n/persian.min.js.LICENSE.txt +1 -1
  131. package/i18n/philippines.js +1 -1
  132. package/i18n/philippines.min.js.LICENSE.txt +1 -1
  133. package/i18n/polish.js +1 -1
  134. package/i18n/polish.min.js.LICENSE.txt +1 -1
  135. package/i18n/portuguese-br.js +1 -1
  136. package/i18n/portuguese-br.min.js.LICENSE.txt +1 -1
  137. package/i18n/portuguese.js +1 -1
  138. package/i18n/portuguese.min.js.LICENSE.txt +1 -1
  139. package/i18n/romanian.js +1 -1
  140. package/i18n/romanian.min.js.LICENSE.txt +1 -1
  141. package/i18n/russian.js +1 -1
  142. package/i18n/russian.min.js.LICENSE.txt +1 -1
  143. package/i18n/serbian.js +1 -1
  144. package/i18n/serbian.min.js.LICENSE.txt +1 -1
  145. package/i18n/simplified-chinese.js +1 -1
  146. package/i18n/simplified-chinese.min.js.LICENSE.txt +1 -1
  147. package/i18n/slovak.js +1 -1
  148. package/i18n/slovak.min.js.LICENSE.txt +1 -1
  149. package/i18n/slovenian.js +1 -1
  150. package/i18n/slovenian.min.js.LICENSE.txt +1 -1
  151. package/i18n/spanish.js +1 -1
  152. package/i18n/spanish.min.js.LICENSE.txt +1 -1
  153. package/i18n/swahili.js +1 -1
  154. package/i18n/swahili.min.js.LICENSE.txt +1 -1
  155. package/i18n/swedish.js +1 -1
  156. package/i18n/swedish.min.js.LICENSE.txt +1 -1
  157. package/i18n/tajik.js +1 -1
  158. package/i18n/tajik.min.js.LICENSE.txt +1 -1
  159. package/i18n/telugu.js +1 -1
  160. package/i18n/telugu.min.js.LICENSE.txt +1 -1
  161. package/i18n/thai.js +1 -1
  162. package/i18n/thai.min.js.LICENSE.txt +1 -1
  163. package/i18n/traditional-chinese.js +1 -1
  164. package/i18n/traditional-chinese.min.js.LICENSE.txt +1 -1
  165. package/i18n/turkish.js +1 -1
  166. package/i18n/turkish.min.js.LICENSE.txt +1 -1
  167. package/i18n/ukrainian.js +1 -1
  168. package/i18n/ukrainian.min.js.LICENSE.txt +1 -1
  169. package/i18n/urdu.js +1 -1
  170. package/i18n/urdu.min.js.LICENSE.txt +1 -1
  171. package/i18n/vietnamese.js +1 -1
  172. package/i18n/vietnamese.min.js.LICENSE.txt +1 -1
  173. package/i18n/welsh.js +1 -1
  174. package/i18n/welsh.min.js.LICENSE.txt +1 -1
  175. package/icons/iconsV1.js +1 -1
  176. package/icons/iconsV1.min.js.LICENSE.txt +1 -1
  177. package/icons/iconsV2.js +1 -1
  178. package/icons/iconsV2.min.js.LICENSE.txt +1 -1
  179. package/package.json +1 -1
  180. package/survey-core.css +1 -1
  181. package/survey-core.fontless.css +1 -1
  182. package/survey-core.fontless.min.css +1 -1
  183. package/survey-core.min.css +1 -1
  184. package/survey.core.js +147 -60
  185. package/survey.core.js.map +1 -1
  186. package/survey.core.min.js +1 -1
  187. package/survey.core.min.js.LICENSE.txt +1 -1
  188. package/survey.i18n.js +1 -1
  189. package/survey.i18n.min.js.LICENSE.txt +1 -1
  190. package/themes/borderless-dark-panelless.js +1 -1
  191. package/themes/borderless-dark-panelless.min.js.LICENSE.txt +1 -1
  192. package/themes/borderless-dark.js +1 -1
  193. package/themes/borderless-dark.min.js.LICENSE.txt +1 -1
  194. package/themes/borderless-light-panelless.js +1 -1
  195. package/themes/borderless-light-panelless.min.js.LICENSE.txt +1 -1
  196. package/themes/borderless-light.js +1 -1
  197. package/themes/borderless-light.min.js.LICENSE.txt +1 -1
  198. package/themes/contrast-dark-panelless.js +1 -1
  199. package/themes/contrast-dark-panelless.min.js.LICENSE.txt +1 -1
  200. package/themes/contrast-dark.js +1 -1
  201. package/themes/contrast-dark.min.js.LICENSE.txt +1 -1
  202. package/themes/contrast-light-panelless.js +1 -1
  203. package/themes/contrast-light-panelless.min.js.LICENSE.txt +1 -1
  204. package/themes/contrast-light.js +1 -1
  205. package/themes/contrast-light.min.js.LICENSE.txt +1 -1
  206. package/themes/default-dark-panelless.js +1 -1
  207. package/themes/default-dark-panelless.min.js.LICENSE.txt +1 -1
  208. package/themes/default-dark.js +1 -1
  209. package/themes/default-dark.min.js.LICENSE.txt +1 -1
  210. package/themes/default-light-panelless.js +1 -1
  211. package/themes/default-light-panelless.min.js.LICENSE.txt +1 -1
  212. package/themes/default-light.js +1 -1
  213. package/themes/default-light.min.js.LICENSE.txt +1 -1
  214. package/themes/doubleborder-dark-panelless.js +1 -1
  215. package/themes/doubleborder-dark-panelless.min.js.LICENSE.txt +1 -1
  216. package/themes/doubleborder-dark.js +1 -1
  217. package/themes/doubleborder-dark.min.js.LICENSE.txt +1 -1
  218. package/themes/doubleborder-light-panelles.js +1 -1
  219. package/themes/doubleborder-light-panelles.min.js.LICENSE.txt +1 -1
  220. package/themes/doubleborder-light.js +1 -1
  221. package/themes/doubleborder-light.min.js.LICENSE.txt +1 -1
  222. package/themes/flat-dark-panelless.js +1 -1
  223. package/themes/flat-dark-panelless.min.js.LICENSE.txt +1 -1
  224. package/themes/flat-dark.js +1 -1
  225. package/themes/flat-dark.min.js.LICENSE.txt +1 -1
  226. package/themes/flat-light-panelless.js +1 -1
  227. package/themes/flat-light-panelless.min.js.LICENSE.txt +1 -1
  228. package/themes/flat-light.js +1 -1
  229. package/themes/flat-light.min.js.LICENSE.txt +1 -1
  230. package/themes/index.js +1 -1
  231. package/themes/index.min.js.LICENSE.txt +1 -1
  232. package/themes/layered-dark-panelless.js +1 -1
  233. package/themes/layered-dark-panelless.min.js.LICENSE.txt +1 -1
  234. package/themes/layered-dark.js +1 -1
  235. package/themes/layered-dark.min.js.LICENSE.txt +1 -1
  236. package/themes/layered-light-panelless.js +1 -1
  237. package/themes/layered-light-panelless.min.js.LICENSE.txt +1 -1
  238. package/themes/layered-light.js +1 -1
  239. package/themes/layered-light.min.js.LICENSE.txt +1 -1
  240. package/themes/plain-dark-panelless.js +1 -1
  241. package/themes/plain-dark-panelless.min.js.LICENSE.txt +1 -1
  242. package/themes/plain-dark.js +1 -1
  243. package/themes/plain-dark.min.js.LICENSE.txt +1 -1
  244. package/themes/plain-light-panelless.js +1 -1
  245. package/themes/plain-light-panelless.min.js.LICENSE.txt +1 -1
  246. package/themes/plain-light.js +1 -1
  247. package/themes/plain-light.min.js.LICENSE.txt +1 -1
  248. package/themes/sharp-dark-panelless.js +1 -1
  249. package/themes/sharp-dark-panelless.min.js.LICENSE.txt +1 -1
  250. package/themes/sharp-dark.js +1 -1
  251. package/themes/sharp-dark.min.js.LICENSE.txt +1 -1
  252. package/themes/sharp-light-panelless.js +1 -1
  253. package/themes/sharp-light-panelless.min.js.LICENSE.txt +1 -1
  254. package/themes/sharp-light.js +1 -1
  255. package/themes/sharp-light.min.js.LICENSE.txt +1 -1
  256. package/themes/solid-dark-panelless.js +1 -1
  257. package/themes/solid-dark-panelless.min.js.LICENSE.txt +1 -1
  258. package/themes/solid-dark.js +1 -1
  259. package/themes/solid-dark.min.js.LICENSE.txt +1 -1
  260. package/themes/solid-light-panelless.js +1 -1
  261. package/themes/solid-light-panelless.min.js.LICENSE.txt +1 -1
  262. package/themes/solid-light.js +1 -1
  263. package/themes/solid-light.min.js.LICENSE.txt +1 -1
  264. package/themes/three-dimensional-dark-panelless.js +1 -1
  265. package/themes/three-dimensional-dark-panelless.min.js.LICENSE.txt +1 -1
  266. package/themes/three-dimensional-dark.js +1 -1
  267. package/themes/three-dimensional-dark.min.js.LICENSE.txt +1 -1
  268. package/themes/three-dimensional-light-panelless.js +1 -1
  269. package/themes/three-dimensional-light-panelless.min.js.LICENSE.txt +1 -1
  270. package/themes/three-dimensional-light.js +1 -1
  271. package/themes/three-dimensional-light.min.js.LICENSE.txt +1 -1
  272. package/typings/src/base-interfaces.d.ts +2 -2
  273. package/typings/src/conditionProcessValue.d.ts +5 -0
  274. package/typings/src/conditions.d.ts +1 -1
  275. package/typings/src/question.d.ts +1 -0
  276. package/typings/src/question_matrixdropdownbase.d.ts +3 -0
  277. package/typings/src/question_matrixdropdowncolumn.d.ts +1 -0
  278. package/typings/src/question_matrixdynamic.d.ts +1 -0
  279. package/typings/src/question_paneldynamic.d.ts +2 -0
  280. package/typings/src/question_slider.d.ts +2 -1
  281. package/typings/src/survey.d.ts +2 -2
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * surveyjs - Survey JavaScript library v2.3.4
2
+ * surveyjs - Survey JavaScript library v2.3.5
3
3
  * Copyright (c) 2015-2025 Devsoft Baltic OÜ - http://surveyjs.io/
4
4
  * License: MIT (http://www.opensource.org/licenses/mit-license.php)
5
5
  */
@@ -3084,6 +3084,16 @@ class VariableGetterContext extends ValueGetterContextCore {
3084
3084
  return undefined;
3085
3085
  }
3086
3086
  }
3087
+ class VariableGetterContextEx extends VariableGetterContext {
3088
+ constructor(variables, second) {
3089
+ super(variables);
3090
+ this.second = second;
3091
+ }
3092
+ getValue(path, isRoot, index, createObjects) {
3093
+ const res = super.getValue(path, isRoot, index, createObjects);
3094
+ return !this.second || (res === null || res === void 0 ? void 0 : res.isFound) ? res : this.second.getValue(path, isRoot, index, createObjects);
3095
+ }
3096
+ }
3087
3097
  class ProcessValue {
3088
3098
  constructor(context) {
3089
3099
  this.properties = null;
@@ -3310,15 +3320,15 @@ function convertToNumber(val) {
3310
3320
  return Helpers.isNumber(val) ? Helpers.getNumber(val) : undefined;
3311
3321
  return val;
3312
3322
  }
3313
- function processItemInArray(item, name, res, func, needToConvert, condition) {
3323
+ function processItemInArray(item, name, res, func, needToConvert, condition, properties) {
3314
3324
  if (!item || Helpers.isValueEmpty(item[name]))
3315
3325
  return res;
3316
- if (condition && !condition.runValues(item))
3326
+ if (condition && !condition.runValues(item, properties))
3317
3327
  return res;
3318
3328
  const val = needToConvert ? convertToNumber(item[name]) : 1;
3319
3329
  return func(res, val);
3320
3330
  }
3321
- function calcInArray(params, originalParams, func, needToConvert = true) {
3331
+ function calcInArray(properties, params, originalParams, func, needToConvert = true) {
3322
3332
  var v = getInArrayParams(params, originalParams);
3323
3333
  if (!v)
3324
3334
  return undefined;
@@ -3329,18 +3339,26 @@ function calcInArray(params, originalParams, func, needToConvert = true) {
3329
3339
  var res = undefined;
3330
3340
  if (Array.isArray(v.data)) {
3331
3341
  for (var i = 0; i < v.data.length; i++) {
3332
- res = processItemInArray(v.data[i], v.name, res, func, needToConvert, condition);
3342
+ res = processItemInArray(v.data[i], v.name, res, func, needToConvert, condition, properties);
3333
3343
  }
3334
3344
  }
3335
3345
  else {
3336
3346
  for (var key in v.data) {
3337
- res = processItemInArray(v.data[key], v.name, res, func, needToConvert, condition);
3347
+ res = processItemInArray(v.data[key], v.name, res, func, needToConvert, condition, properties);
3338
3348
  }
3339
3349
  }
3340
3350
  return res;
3341
3351
  }
3352
+ function getProperties(self) {
3353
+ var _a;
3354
+ return {
3355
+ survey: self.survey,
3356
+ question: self.question,
3357
+ context: (_a = self.survey) === null || _a === void 0 ? void 0 : _a.getValueGetterContext()
3358
+ };
3359
+ }
3342
3360
  function sumInArray(params, originalParams) {
3343
- var res = calcInArray(params, originalParams, function (res, val) {
3361
+ var res = calcInArray(getProperties(this), params, originalParams, function (res, val) {
3344
3362
  if (res == undefined)
3345
3363
  res = 0;
3346
3364
  if (val == undefined || val == null)
@@ -3351,7 +3369,7 @@ function sumInArray(params, originalParams) {
3351
3369
  }
3352
3370
  FunctionFactory.Instance.register("sumInArray", sumInArray);
3353
3371
  function minInArray(params, originalParams) {
3354
- return calcInArray(params, originalParams, function (res, val) {
3372
+ return calcInArray(getProperties(this), params, originalParams, function (res, val) {
3355
3373
  if (res == undefined)
3356
3374
  return val;
3357
3375
  if (val == undefined || val == null)
@@ -3361,7 +3379,7 @@ function minInArray(params, originalParams) {
3361
3379
  }
3362
3380
  FunctionFactory.Instance.register("minInArray", minInArray);
3363
3381
  function maxInArray(params, originalParams) {
3364
- return calcInArray(params, originalParams, function (res, val) {
3382
+ return calcInArray(getProperties(this), params, originalParams, function (res, val) {
3365
3383
  if (res == undefined)
3366
3384
  return val;
3367
3385
  if (val == undefined || val == null)
@@ -3371,7 +3389,7 @@ function maxInArray(params, originalParams) {
3371
3389
  }
3372
3390
  FunctionFactory.Instance.register("maxInArray", maxInArray);
3373
3391
  function countInArray(params, originalParams) {
3374
- var res = calcInArray(params, originalParams, function (res, val) {
3392
+ var res = calcInArray(getProperties(this), params, originalParams, function (res, val) {
3375
3393
  if (res == undefined)
3376
3394
  res = 0;
3377
3395
  if (val == undefined || val == null)
@@ -3382,10 +3400,12 @@ function countInArray(params, originalParams) {
3382
3400
  }
3383
3401
  FunctionFactory.Instance.register("countInArray", countInArray);
3384
3402
  function avgInArray(params, originalParams) {
3385
- var count = countInArray(params, originalParams);
3403
+ const properties = getProperties(this);
3404
+ const funcCall = (name) => FunctionFactory.Instance.run(name, params, properties, originalParams);
3405
+ const count = funcCall("countInArray");
3386
3406
  if (count == 0)
3387
3407
  return 0;
3388
- return sumInArray(params, originalParams) / count;
3408
+ return funcCall("sumInArray") / count;
3389
3409
  }
3390
3410
  FunctionFactory.Instance.register("avgInArray", avgInArray);
3391
3411
  function iif(params) {
@@ -7414,8 +7434,8 @@ class ExpressionExecutor {
7414
7434
  canRun() {
7415
7435
  return !!this.operand;
7416
7436
  }
7417
- run(values, properties = null, id) {
7418
- return this.runContext(new VariableGetterContext(values), properties, id);
7437
+ run(values, properties, id) {
7438
+ return this.runContext(new VariableGetterContextEx(values, properties === null || properties === void 0 ? void 0 : properties.context), properties, id);
7419
7439
  }
7420
7440
  runContext(context, properties = null, id) {
7421
7441
  if (!this.operand) {
@@ -7477,8 +7497,8 @@ class ExpressionRunnerBase {
7477
7497
  }
7478
7498
  ExpressionRunnerBase.IdRunnerCounter = 1;
7479
7499
  class ConditionRunner extends ExpressionRunnerBase {
7480
- runValues(values, properties = null) {
7481
- return this.runContext(new VariableGetterContext(values), properties);
7500
+ runValues(values, properties) {
7501
+ return this.runContext(new VariableGetterContextEx(values, properties === null || properties === void 0 ? void 0 : properties.context), properties);
7482
7502
  }
7483
7503
  runContext(context, properties) {
7484
7504
  return this.runContextCore(context, properties) == true;
@@ -7490,8 +7510,8 @@ class ConditionRunner extends ExpressionRunnerBase {
7490
7510
  }
7491
7511
  }
7492
7512
  class ExpressionRunner extends ExpressionRunnerBase {
7493
- runValues(values, properties = null) {
7494
- return this.runContext(new VariableGetterContext(values), properties);
7513
+ runValues(values, properties) {
7514
+ return this.runContext(new VariableGetterContextEx(values, properties === null || properties === void 0 ? void 0 : properties.context), properties);
7495
7515
  }
7496
7516
  runContext(context, properties) {
7497
7517
  return this.runContextCore(context, properties);
@@ -15132,12 +15152,11 @@ class ExpressionValidator extends SurveyValidator {
15132
15152
  return this.isRunningValue;
15133
15153
  }
15134
15154
  validate(value, name = null, properties = null) {
15135
- if (!this.expression)
15136
- return null;
15137
15155
  if (!!this.conditionRunner) {
15138
15156
  this.conditionRunner.onRunComplete = null;
15139
15157
  }
15140
- this.ensureConditionRunner(true);
15158
+ if (!this.ensureConditionRunner(true))
15159
+ return null;
15141
15160
  this.conditionRunner.onRunComplete = (res) => {
15142
15161
  this.isRunningValue = false;
15143
15162
  if (!!this.onAsyncCompleted) {
@@ -15603,11 +15622,13 @@ class QuestionItemValueGetterContext extends ValueGetterContextCore {
15603
15622
  return res;
15604
15623
  }
15605
15624
  fillQuestions(qs, q, res) {
15606
- qs.forEach((question) => {
15607
- if (question !== q) {
15608
- res.push(question);
15609
- }
15610
- });
15625
+ if (Array.isArray(qs)) {
15626
+ qs.forEach((question) => {
15627
+ if (question !== q) {
15628
+ res.push(question);
15629
+ }
15630
+ });
15631
+ }
15611
15632
  }
15612
15633
  getRootObj() { return this.getQuestionData(); }
15613
15634
  }
@@ -18415,10 +18436,14 @@ class Question extends SurveyElement {
18415
18436
  }
18416
18437
  }
18417
18438
  setNewValue(newValue) {
18439
+ if (this.survey) {
18440
+ newValue = this.survey.questionValueChanging(this, newValue);
18441
+ }
18418
18442
  if (this.isNewValueEqualsToValue(newValue))
18419
18443
  return;
18420
18444
  if (!this.checkIsValueCorrect(newValue))
18421
18445
  return;
18446
+ const oldValue = this.getUnbindValue(this.value);
18422
18447
  this.isOldAnswered = this.isAnswered;
18423
18448
  this.isSettingQuestionValue = true;
18424
18449
  this.setNewValueInData(newValue);
@@ -18431,7 +18456,11 @@ class Question extends SurveyElement {
18431
18456
  if (this.parent) {
18432
18457
  this.parent.onQuestionValueChanged(this);
18433
18458
  }
18459
+ if (this.survey) {
18460
+ this.survey.questionValueChanged(this, oldValue);
18461
+ }
18434
18462
  }
18463
+ getValueChangingOptions(childQuestion) { return undefined; }
18435
18464
  checkIsValueCorrect(val) {
18436
18465
  const res = this.isValueEmpty(val, !this.allowSpaceAsAnswer) || this.isNewValueCorrect(val);
18437
18466
  if (!res) {
@@ -21939,6 +21968,9 @@ class QuestionCompositeModel extends QuestionCustomModelBase {
21939
21968
  super.setValue(name, newValue, locNotification, allowNotifyValueChanged);
21940
21969
  this.settingNewValue = false;
21941
21970
  this.runPanelTriggers(settings.expressionVariables.composite + "." + name, newValue);
21971
+ if (this.isEditingSurveyElement) {
21972
+ this.runCondition(this.getFilteredProperties());
21973
+ }
21942
21974
  }
21943
21975
  setComment(name, newValue, locNotification) {
21944
21976
  let val = this.getUnbindValue(this.value);
@@ -22721,6 +22753,7 @@ var matrixDropdownColumnTypes = {
22721
22753
  },
22722
22754
  expression: {},
22723
22755
  rating: {},
22756
+ slider: {}
22724
22757
  };
22725
22758
  /**
22726
22759
  * An auxiliary class that describes a column in a [Multi-Select Matrix](https://surveyjs.io/form-library/documentation/api-reference/matrix-table-with-dropdown-list) or [Dynamic Matrix](https://surveyjs.io/form-library/documentation/api-reference/dynamic-matrix-table-question-model).
@@ -22817,6 +22850,7 @@ class MatrixDropdownColumn extends Base {
22817
22850
  * - [`"boolean"`](https://surveyjs.io/form-library/documentation/api-reference/boolean-question-model)
22818
22851
  * - [`"expression"`](https://surveyjs.io/form-library/documentation/api-reference/expression-model)
22819
22852
  * - [`"rating"`](https://surveyjs.io/form-library/documentation/api-reference/rating-scale-question-model)
22853
+ * - [`"slider"`](https://surveyjs.io/form-library/documentation/api-reference/questionslidermodel)
22820
22854
  * - `"default"` (default) - Inherits the input type from the [`cellType`](https://surveyjs.io/form-library/documentation/api-reference/matrix-table-with-dropdown-list#cellType) property specified for the parent matrix.
22821
22855
  *
22822
22856
  * The input types are based upon standalone question types. Depending on the selected input type, the matrix column can have additional configuration properties inherited from the corresponding question type. For instance, Dropdown, Checkboxes, Radio Button Group, and Tag Box columns can specify the [`choices`](https://surveyjs.io/form-library/documentation/api-reference/radio-button-question-model#choices) array, similar to the question types upon which they are based. Refer to the API Reference of these question types for a full list of available properties.
@@ -25863,9 +25897,19 @@ class QuestionMatrixDropdownModelBase extends QuestionMatrixBaseModel {
25863
25897
  this.clearVisibleRows();
25864
25898
  this.resetRenderedTable();
25865
25899
  super.onRowsChanged();
25900
+ this.updateRowsVisibleIndexes();
25901
+ }
25902
+ updateRowsVisibleIndexes() {
25866
25903
  const rows = this.visibleRows;
25904
+ if (!Array.isArray(rows))
25905
+ return;
25906
+ const vriName = settings.expressionVariables.visibleRowIndex;
25907
+ const keys = {};
25908
+ keys[vriName] = 0;
25867
25909
  for (let i = 0; i < rows.length; i++) {
25868
25910
  rows[i].visibleIndex = i;
25911
+ keys[vriName] = i + 1;
25912
+ rows[i].runTriggers(vriName, i + 1, keys);
25869
25913
  }
25870
25914
  }
25871
25915
  onStartRowAddingRemoving() {
@@ -25988,6 +26032,7 @@ class QuestionMatrixDropdownModelBase extends QuestionMatrixBaseModel {
25988
26032
  * - [`"boolean"`](https://surveyjs.io/form-library/documentation/api-reference/boolean-question-model)
25989
26033
  * - [`"expression"`](https://surveyjs.io/form-library/documentation/api-reference/expression-model)
25990
26034
  * - [`"rating"`](https://surveyjs.io/form-library/documentation/api-reference/rating-scale-question-model)
26035
+ * - [`"slider"`](https://surveyjs.io/form-library/documentation/api-reference/questionslidermodel)
25991
26036
  *
25992
26037
  * Default value: `"dropdown"` (inherited from [`settings.matrix.defaultCellType`](https://surveyjs.io/form-library/documentation/settings#matrixDefaultCellType))
25993
26038
  *
@@ -26502,6 +26547,7 @@ class QuestionMatrixDropdownModelBase extends QuestionMatrixBaseModel {
26502
26547
  return this.visibleRowsArray;
26503
26548
  this.generateVisibleRowsIfNeeded();
26504
26549
  this.visibleRowsArray = this.getVisibleFromGenerated(this.generatedVisibleRows);
26550
+ this.updateRowsVisibleIndexes();
26505
26551
  return this.visibleRowsArray;
26506
26552
  }
26507
26553
  get allRows() {
@@ -27258,8 +27304,10 @@ class QuestionMatrixDropdownModelBase extends QuestionMatrixBaseModel {
27258
27304
  if (this.isObject(rowValue) && Object.keys(rowValue).length === 0) {
27259
27305
  newValue = this.deleteRowValue(newValue, row);
27260
27306
  }
27307
+ newValue = this.correctValueForMinMaxRows(newValue);
27261
27308
  return { value: newValue, rowValue: rowValue };
27262
27309
  }
27310
+ correctValueForMinMaxRows(newValue) { return newValue; }
27263
27311
  getRowIndex(row) {
27264
27312
  if (!Array.isArray(this.generatedVisibleRows))
27265
27313
  return -1;
@@ -28708,6 +28756,9 @@ class QuestionMatrixDynamicModel extends QuestionMatrixDropdownModelBase {
28708
28756
  valueFromData(val) {
28709
28757
  if (this.minRowCount < 1 || this.isEmpty())
28710
28758
  return super.valueFromData(val);
28759
+ return this.correctValueForMinMaxRows(val);
28760
+ }
28761
+ correctValueForMinMaxRows(val) {
28711
28762
  if (!Array.isArray(val))
28712
28763
  val = [];
28713
28764
  for (var i = val.length; i < this.minRowCount; i++)
@@ -29238,9 +29289,12 @@ class QuestionMatrixDynamicModel extends QuestionMatrixDropdownModelBase {
29238
29289
  this.onEndRowRemoving(row);
29239
29290
  }
29240
29291
  removeRowCore(index) {
29241
- var row = this.generatedVisibleRows
29242
- ? this.generatedVisibleRows[index]
29292
+ var row = this.visibleRows
29293
+ ? this.visibleRows[index]
29243
29294
  : null;
29295
+ index = this.generatedVisibleRows.indexOf(row);
29296
+ if (index < 0)
29297
+ return;
29244
29298
  if (this.generatedVisibleRows && index < this.generatedVisibleRows.length) {
29245
29299
  this.generatedVisibleRows.splice(index, 1);
29246
29300
  }
@@ -40425,14 +40479,6 @@ class SurveyModel extends SurveyElementCore {
40425
40479
  this.onDynamicPanelRemoving.fire(this, options);
40426
40480
  return options.allow;
40427
40481
  }
40428
- dynamicPanelItemValueChanged(question, options) {
40429
- options.question = question;
40430
- this.onDynamicPanelValueChanged.fire(this, options);
40431
- }
40432
- dynamicPanelItemValueChanging(question, options) {
40433
- options.question = question;
40434
- this.onDynamicPanelValueChanging.fire(this, options);
40435
- }
40436
40482
  dynamicPanelGetTabTitle(question, options) {
40437
40483
  options.question = question;
40438
40484
  this.onGetDynamicPanelTabTitle.fire(this, options);
@@ -41193,15 +41239,14 @@ class SurveyModel extends SurveyElementCore {
41193
41239
  }
41194
41240
  }
41195
41241
  runConditionOnValueChanged(name, value) {
41242
+ if (!this.questionTriggersKeys) {
41243
+ this.questionTriggersKeys = {};
41244
+ }
41245
+ this.questionTriggersKeys[name] = value;
41196
41246
  if (this.isRunningConditions) {
41197
- if (this.questionTriggersKeys) {
41198
- this.questionTriggersKeys[name] = value;
41199
- }
41200
41247
  this.isValueChangedOnRunningCondition = true;
41201
41248
  }
41202
41249
  else {
41203
- this.questionTriggersKeys = {};
41204
- this.questionTriggersKeys[name] = value;
41205
41250
  this.runConditions();
41206
41251
  this.runQuestionsTriggers(name, value);
41207
41252
  this.questionTriggersKeys = undefined;
@@ -41642,6 +41687,35 @@ class SurveyModel extends SurveyElementCore {
41642
41687
  locNotification = this.getLocNotification(locNotification, newValue, oldValue);
41643
41688
  this.updateOnSetValue(name, newValue, oldValue, locNotification, allowNotifyValueChanged, questionName);
41644
41689
  }
41690
+ questionValueChanging(question, newValue) {
41691
+ const q = question;
41692
+ const parentQ = q.parentQuestion;
41693
+ if (!parentQ)
41694
+ return newValue;
41695
+ if (parentQ.isDescendantOf("paneldynamic") && !this.onDynamicPanelValueChanging.isEmpty) {
41696
+ const options = parentQ.getValueChangingOptions(q);
41697
+ if (options) {
41698
+ options.value = newValue;
41699
+ this.onDynamicPanelValueChanging.fire(this, options);
41700
+ return options.value;
41701
+ }
41702
+ }
41703
+ return newValue;
41704
+ }
41705
+ questionValueChanged(question, oldValue) {
41706
+ const q = question;
41707
+ const parentQ = q.parentQuestion;
41708
+ if (!!parentQ) {
41709
+ if (parentQ.isDescendantOf("paneldynamic") && !this.onDynamicPanelValueChanged.isEmpty) {
41710
+ const options = parentQ.getValueChangingOptions(q);
41711
+ if (options) {
41712
+ options.value = q.value;
41713
+ options.oldValue = oldValue;
41714
+ this.onDynamicPanelValueChanged.fire(this, options);
41715
+ }
41716
+ }
41717
+ }
41718
+ }
41645
41719
  isValueEmpyOnSetValue(name, val) {
41646
41720
  if (!this.isValueEmpty(val, false))
41647
41721
  return false;
@@ -56281,6 +56355,8 @@ class QuestionSliderModel extends Question {
56281
56355
  this.handleRangeOnChange = (event) => {
56282
56356
  if (!this.isRangeMoving)
56283
56357
  return;
56358
+ if (!this.isAllowToChange())
56359
+ return;
56284
56360
  const { renderedMax: max, renderedMin: min, renderedValue, ensureMaxRangeBorders, ensureMinRangeBorders } = this;
56285
56361
  const inputNode = event.target;
56286
56362
  const diff = this.oldInputValue - +inputNode.value;
@@ -56366,7 +56442,7 @@ class QuestionSliderModel extends Question {
56366
56442
  input.style.setProperty("--sjs-range-slider-range-input-thumb-position", "absolute");
56367
56443
  };
56368
56444
  this.setSliderValue = (newValue) => {
56369
- if (!this.isReadOnly && !this.isDisabledAttr && !this.isPreviewStyle && !this.isDisabledStyle) {
56445
+ if (this.isAllowToChange()) {
56370
56446
  let result;
56371
56447
  if (this.sliderType === "single") {
56372
56448
  result = Array.isArray(newValue) ? newValue[0] : newValue;
@@ -56426,6 +56502,8 @@ class QuestionSliderModel extends Question {
56426
56502
  refreshInputRange();
56427
56503
  };
56428
56504
  this.handleOnChange = (event, inputNumber) => {
56505
+ if (!this.isAllowToChange())
56506
+ return;
56429
56507
  if (this.oldValue === null)
56430
56508
  return; // Firefox raise one more OnChange after PointerUp and break the value
56431
56509
  const { allowSwap, ensureMaxRangeBorders, ensureMinRangeBorders, renderedValue } = this;
@@ -56746,6 +56824,9 @@ class QuestionSliderModel extends Question {
56746
56824
  }
56747
56825
  return value;
56748
56826
  }
56827
+ isAllowToChange() {
56828
+ return !this.isReadOnly && !this.isDisabledAttr && !this.isPreviewStyle && !this.isDisabledStyle;
56829
+ }
56749
56830
  }
56750
56831
  __decorate([
56751
56832
  property({ defaultValue: "single" })
@@ -61502,6 +61583,22 @@ class QuestionPanelDynamicModel extends Question {
61502
61583
  isNewValueCorrect(val) {
61503
61584
  return Array.isArray(val);
61504
61585
  }
61586
+ getValueChangingOptions(childQuestion) {
61587
+ let pnl = childQuestion.parent;
61588
+ while (pnl.parent) {
61589
+ pnl = pnl.parent;
61590
+ }
61591
+ const panel = pnl;
61592
+ const panelIndex = this.panels.indexOf(panel);
61593
+ return {
61594
+ question: this,
61595
+ panel: panel,
61596
+ name: childQuestion.name,
61597
+ panelIndex: panelIndex,
61598
+ panelData: this.getPanelItemDataByIndex(panelIndex),
61599
+ oldValue: childQuestion.value
61600
+ };
61601
+ }
61505
61602
  //IQuestionPanelDynamicData
61506
61603
  getItemIndex(item) {
61507
61604
  var res = this.items.indexOf(item);
@@ -61516,8 +61613,10 @@ class QuestionPanelDynamicModel extends Question {
61516
61613
  return visPanels.length;
61517
61614
  }
61518
61615
  getPanelItemData(item) {
61519
- var items = this.items;
61520
- var index = items.indexOf(item);
61616
+ return this.getPanelItemDataByIndex(this.items.indexOf(item));
61617
+ }
61618
+ getPanelItemDataByIndex(index) {
61619
+ const items = this.items;
61521
61620
  var qValue = this.value;
61522
61621
  if (index < 0 && Array.isArray(qValue) && qValue.length > items.length) {
61523
61622
  index = items.length;
@@ -61550,7 +61649,7 @@ class QuestionPanelDynamicModel extends Question {
61550
61649
  }
61551
61650
  if (!qValue[index])
61552
61651
  qValue[index] = {};
61553
- const oldVal = qValue[index][name];
61652
+ qValue[index][name];
61554
61653
  if (!this.isValueEmpty(val)) {
61555
61654
  qValue[index][name] = val;
61556
61655
  }
@@ -61560,22 +61659,8 @@ class QuestionPanelDynamicModel extends Question {
61560
61659
  if (index >= 0 && index < this.panelsCore.length) {
61561
61660
  this.changingValueQuestion = this.panelsCore[index].getQuestionByValueName(name);
61562
61661
  }
61563
- const options = {
61564
- panel: item.panel,
61565
- name: name,
61566
- panelIndex: index,
61567
- panelData: qValue[index],
61568
- value: val,
61569
- oldValue: oldVal
61570
- };
61571
- if (this.survey) {
61572
- this.survey.dynamicPanelItemValueChanging(this, options);
61573
- }
61574
61662
  this.value = qValue;
61575
61663
  this.changingValueQuestion = null;
61576
- if (this.survey) {
61577
- this.survey.dynamicPanelItemValueChanged(this, options);
61578
- }
61579
61664
  this.isSetPanelItemData[name]--;
61580
61665
  if (this.isSetPanelItemData[name] - 1) {
61581
61666
  delete this.isSetPanelItemData[name];
@@ -65219,11 +65304,11 @@ var Version;
65219
65304
  var ReleaseDate;
65220
65305
  // eslint-disable-next-line @typescript-eslint/ban-ts-comment
65221
65306
  //@ts-ignore
65222
- Version = `${"2.3.4"}`;
65307
+ Version = `${"2.3.5"}`;
65223
65308
  settings.version = Version;
65224
65309
  // eslint-disable-next-line @typescript-eslint/ban-ts-comment
65225
65310
  //@ts-ignore
65226
- ReleaseDate = `${"2025-08-26"}`;
65311
+ ReleaseDate = `${"2025-09-02"}`;
65227
65312
  function checkLibraryVersion(ver, libraryName) {
65228
65313
  if (Version != ver) {
65229
65314
  const str = "survey-core has version '" + Version + "' and " + libraryName