survey-core 1.12.44 → 1.12.45

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 (388) hide show
  1. package/defaultV2.css +1 -1
  2. package/defaultV2.fontless.css +1 -1
  3. package/defaultV2.fontless.min.css +1 -1
  4. package/defaultV2.min.css +1 -1
  5. package/fesm/i18n/arabic.mjs +1 -1
  6. package/fesm/i18n/basque.mjs +1 -1
  7. package/fesm/i18n/bulgarian.mjs +1 -1
  8. package/fesm/i18n/burmese.mjs +1 -1
  9. package/fesm/i18n/catalan.mjs +1 -1
  10. package/fesm/i18n/croatian.mjs +1 -1
  11. package/fesm/i18n/czech.mjs +1 -1
  12. package/fesm/i18n/danish.mjs +1 -1
  13. package/fesm/i18n/dutch.mjs +1 -1
  14. package/fesm/i18n/english.mjs +12 -6
  15. package/fesm/i18n/english.mjs.map +1 -1
  16. package/fesm/i18n/estonian.mjs +1 -1
  17. package/fesm/i18n/finnish.mjs +1 -1
  18. package/fesm/i18n/french.mjs +1 -1
  19. package/fesm/i18n/georgian.mjs +1 -1
  20. package/fesm/i18n/german.mjs +1 -1
  21. package/fesm/i18n/greek.mjs +1 -1
  22. package/fesm/i18n/haitian-creole.mjs +1 -1
  23. package/fesm/i18n/hebrew.mjs +1 -1
  24. package/fesm/i18n/hindi.mjs +1 -1
  25. package/fesm/i18n/hungarian.mjs +1 -1
  26. package/fesm/i18n/icelandic.mjs +1 -1
  27. package/fesm/i18n/index.mjs +1 -1
  28. package/fesm/i18n/indonesian.mjs +1 -1
  29. package/fesm/i18n/italian.mjs +1 -1
  30. package/fesm/i18n/japanese.mjs +1 -1
  31. package/fesm/i18n/kazakh.mjs +1 -1
  32. package/fesm/i18n/korean.mjs +1 -1
  33. package/fesm/i18n/latvian.mjs +1 -1
  34. package/fesm/i18n/lithuanian.mjs +1 -1
  35. package/fesm/i18n/macedonian.mjs +1 -1
  36. package/fesm/i18n/malay.mjs +1 -1
  37. package/fesm/i18n/nl-BE.mjs +1 -1
  38. package/fesm/i18n/norwegian.mjs +1 -1
  39. package/fesm/i18n/persian.mjs +1 -1
  40. package/fesm/i18n/philippines.mjs +1 -1
  41. package/fesm/i18n/polish.mjs +1 -1
  42. package/fesm/i18n/portuguese-br.mjs +1 -1
  43. package/fesm/i18n/portuguese.mjs +1 -1
  44. package/fesm/i18n/romanian.mjs +1 -1
  45. package/fesm/i18n/russian.mjs +1 -1
  46. package/fesm/i18n/serbian.mjs +1 -1
  47. package/fesm/i18n/simplified-chinese.mjs +1 -1
  48. package/fesm/i18n/slovak.mjs +1 -1
  49. package/fesm/i18n/slovenian.mjs +1 -1
  50. package/fesm/i18n/spanish.mjs +1 -1
  51. package/fesm/i18n/swahili.mjs +1 -1
  52. package/fesm/i18n/swedish.mjs +1 -1
  53. package/fesm/i18n/tajik.mjs +1 -1
  54. package/fesm/i18n/telugu.mjs +1 -1
  55. package/fesm/i18n/thai.mjs +1 -1
  56. package/fesm/i18n/traditional-chinese.mjs +1 -1
  57. package/fesm/i18n/turkish.mjs +1 -1
  58. package/fesm/i18n/ukrainian.mjs +1 -1
  59. package/fesm/i18n/urdu.mjs +1 -1
  60. package/fesm/i18n/vietnamese.mjs +1 -1
  61. package/fesm/i18n/welsh.mjs +1 -1
  62. package/fesm/icons/iconsV1.mjs +1 -1
  63. package/fesm/icons/iconsV2.mjs +1 -1
  64. package/fesm/survey-core.mjs +30 -12
  65. package/fesm/survey-core.mjs.map +1 -1
  66. package/fesm/survey.i18n.mjs +1 -1
  67. package/fesm/themes/index.mjs +1 -1
  68. package/i18n/arabic.js +1 -1
  69. package/i18n/arabic.min.js +1 -1
  70. package/i18n/arabic.min.js.LICENSE.txt +1 -1
  71. package/i18n/basque.js +1 -1
  72. package/i18n/basque.min.js +1 -1
  73. package/i18n/basque.min.js.LICENSE.txt +1 -1
  74. package/i18n/bulgarian.js +1 -1
  75. package/i18n/bulgarian.min.js +1 -1
  76. package/i18n/bulgarian.min.js.LICENSE.txt +1 -1
  77. package/i18n/burmese.js +1 -1
  78. package/i18n/burmese.min.js +1 -1
  79. package/i18n/burmese.min.js.LICENSE.txt +1 -1
  80. package/i18n/catalan.js +1 -1
  81. package/i18n/catalan.min.js +1 -1
  82. package/i18n/catalan.min.js.LICENSE.txt +1 -1
  83. package/i18n/croatian.js +1 -1
  84. package/i18n/croatian.min.js +1 -1
  85. package/i18n/croatian.min.js.LICENSE.txt +1 -1
  86. package/i18n/czech.js +1 -1
  87. package/i18n/czech.min.js +1 -1
  88. package/i18n/czech.min.js.LICENSE.txt +1 -1
  89. package/i18n/danish.js +1 -1
  90. package/i18n/danish.min.js +1 -1
  91. package/i18n/danish.min.js.LICENSE.txt +1 -1
  92. package/i18n/dutch.js +1 -1
  93. package/i18n/dutch.min.js +1 -1
  94. package/i18n/dutch.min.js.LICENSE.txt +1 -1
  95. package/i18n/english.js +1 -1
  96. package/i18n/english.min.js +1 -1
  97. package/i18n/english.min.js.LICENSE.txt +1 -1
  98. package/i18n/estonian.js +1 -1
  99. package/i18n/estonian.min.js +1 -1
  100. package/i18n/estonian.min.js.LICENSE.txt +1 -1
  101. package/i18n/finnish.js +1 -1
  102. package/i18n/finnish.min.js +1 -1
  103. package/i18n/finnish.min.js.LICENSE.txt +1 -1
  104. package/i18n/french.js +1 -1
  105. package/i18n/french.min.js +1 -1
  106. package/i18n/french.min.js.LICENSE.txt +1 -1
  107. package/i18n/georgian.js +1 -1
  108. package/i18n/georgian.min.js +1 -1
  109. package/i18n/georgian.min.js.LICENSE.txt +1 -1
  110. package/i18n/german.js +1 -1
  111. package/i18n/german.min.js +1 -1
  112. package/i18n/german.min.js.LICENSE.txt +1 -1
  113. package/i18n/greek.js +1 -1
  114. package/i18n/greek.min.js +1 -1
  115. package/i18n/greek.min.js.LICENSE.txt +1 -1
  116. package/i18n/haitian-creole.js +1 -1
  117. package/i18n/haitian-creole.min.js.LICENSE.txt +1 -1
  118. package/i18n/hebrew.js +1 -1
  119. package/i18n/hebrew.min.js +1 -1
  120. package/i18n/hebrew.min.js.LICENSE.txt +1 -1
  121. package/i18n/hindi.js +1 -1
  122. package/i18n/hindi.min.js +1 -1
  123. package/i18n/hindi.min.js.LICENSE.txt +1 -1
  124. package/i18n/hungarian.js +1 -1
  125. package/i18n/hungarian.min.js +1 -1
  126. package/i18n/hungarian.min.js.LICENSE.txt +1 -1
  127. package/i18n/icelandic.js +1 -1
  128. package/i18n/icelandic.min.js +1 -1
  129. package/i18n/icelandic.min.js.LICENSE.txt +1 -1
  130. package/i18n/index.js +1 -1
  131. package/i18n/index.min.js +1 -1
  132. package/i18n/index.min.js.LICENSE.txt +1 -1
  133. package/i18n/indonesian.js +1 -1
  134. package/i18n/indonesian.min.js +1 -1
  135. package/i18n/indonesian.min.js.LICENSE.txt +1 -1
  136. package/i18n/italian.js +1 -1
  137. package/i18n/italian.min.js +1 -1
  138. package/i18n/italian.min.js.LICENSE.txt +1 -1
  139. package/i18n/japanese.js +1 -1
  140. package/i18n/japanese.min.js +1 -1
  141. package/i18n/japanese.min.js.LICENSE.txt +1 -1
  142. package/i18n/kazakh.js +1 -1
  143. package/i18n/kazakh.min.js +1 -1
  144. package/i18n/kazakh.min.js.LICENSE.txt +1 -1
  145. package/i18n/korean.js +1 -1
  146. package/i18n/korean.min.js +1 -1
  147. package/i18n/korean.min.js.LICENSE.txt +1 -1
  148. package/i18n/latvian.js +1 -1
  149. package/i18n/latvian.min.js +1 -1
  150. package/i18n/latvian.min.js.LICENSE.txt +1 -1
  151. package/i18n/lithuanian.js +1 -1
  152. package/i18n/lithuanian.min.js +1 -1
  153. package/i18n/lithuanian.min.js.LICENSE.txt +1 -1
  154. package/i18n/macedonian.js +1 -1
  155. package/i18n/macedonian.min.js +1 -1
  156. package/i18n/macedonian.min.js.LICENSE.txt +1 -1
  157. package/i18n/malay.js +1 -1
  158. package/i18n/malay.min.js +1 -1
  159. package/i18n/malay.min.js.LICENSE.txt +1 -1
  160. package/i18n/nl-BE.js +1 -1
  161. package/i18n/nl-BE.min.js +1 -1
  162. package/i18n/nl-BE.min.js.LICENSE.txt +1 -1
  163. package/i18n/norwegian.js +1 -1
  164. package/i18n/norwegian.min.js +1 -1
  165. package/i18n/norwegian.min.js.LICENSE.txt +1 -1
  166. package/i18n/persian.js +1 -1
  167. package/i18n/persian.min.js +1 -1
  168. package/i18n/persian.min.js.LICENSE.txt +1 -1
  169. package/i18n/philippines.js +1 -1
  170. package/i18n/philippines.min.js +1 -1
  171. package/i18n/philippines.min.js.LICENSE.txt +1 -1
  172. package/i18n/polish.js +1 -1
  173. package/i18n/polish.min.js +1 -1
  174. package/i18n/polish.min.js.LICENSE.txt +1 -1
  175. package/i18n/portuguese-br.js +1 -1
  176. package/i18n/portuguese-br.min.js +1 -1
  177. package/i18n/portuguese-br.min.js.LICENSE.txt +1 -1
  178. package/i18n/portuguese.js +1 -1
  179. package/i18n/portuguese.min.js +1 -1
  180. package/i18n/portuguese.min.js.LICENSE.txt +1 -1
  181. package/i18n/romanian.js +1 -1
  182. package/i18n/romanian.min.js +1 -1
  183. package/i18n/romanian.min.js.LICENSE.txt +1 -1
  184. package/i18n/russian.js +1 -1
  185. package/i18n/russian.min.js +1 -1
  186. package/i18n/russian.min.js.LICENSE.txt +1 -1
  187. package/i18n/serbian.js +1 -1
  188. package/i18n/serbian.min.js +1 -1
  189. package/i18n/serbian.min.js.LICENSE.txt +1 -1
  190. package/i18n/simplified-chinese.js +1 -1
  191. package/i18n/simplified-chinese.min.js +1 -1
  192. package/i18n/simplified-chinese.min.js.LICENSE.txt +1 -1
  193. package/i18n/slovak.js +1 -1
  194. package/i18n/slovak.min.js +1 -1
  195. package/i18n/slovak.min.js.LICENSE.txt +1 -1
  196. package/i18n/slovenian.js +1 -1
  197. package/i18n/slovenian.min.js +1 -1
  198. package/i18n/slovenian.min.js.LICENSE.txt +1 -1
  199. package/i18n/spanish.js +1 -1
  200. package/i18n/spanish.min.js +1 -1
  201. package/i18n/spanish.min.js.LICENSE.txt +1 -1
  202. package/i18n/swahili.js +1 -1
  203. package/i18n/swahili.min.js +1 -1
  204. package/i18n/swahili.min.js.LICENSE.txt +1 -1
  205. package/i18n/swedish.js +1 -1
  206. package/i18n/swedish.min.js +1 -1
  207. package/i18n/swedish.min.js.LICENSE.txt +1 -1
  208. package/i18n/tajik.js +1 -1
  209. package/i18n/tajik.min.js +1 -1
  210. package/i18n/tajik.min.js.LICENSE.txt +1 -1
  211. package/i18n/telugu.js +1 -1
  212. package/i18n/telugu.min.js +1 -1
  213. package/i18n/telugu.min.js.LICENSE.txt +1 -1
  214. package/i18n/thai.js +1 -1
  215. package/i18n/thai.min.js +1 -1
  216. package/i18n/thai.min.js.LICENSE.txt +1 -1
  217. package/i18n/traditional-chinese.js +1 -1
  218. package/i18n/traditional-chinese.min.js +1 -1
  219. package/i18n/traditional-chinese.min.js.LICENSE.txt +1 -1
  220. package/i18n/turkish.js +1 -1
  221. package/i18n/turkish.min.js +1 -1
  222. package/i18n/turkish.min.js.LICENSE.txt +1 -1
  223. package/i18n/ukrainian.js +1 -1
  224. package/i18n/ukrainian.min.js +1 -1
  225. package/i18n/ukrainian.min.js.LICENSE.txt +1 -1
  226. package/i18n/urdu.js +1 -1
  227. package/i18n/urdu.min.js +1 -1
  228. package/i18n/urdu.min.js.LICENSE.txt +1 -1
  229. package/i18n/vietnamese.js +1 -1
  230. package/i18n/vietnamese.min.js +1 -1
  231. package/i18n/vietnamese.min.js.LICENSE.txt +1 -1
  232. package/i18n/welsh.js +1 -1
  233. package/i18n/welsh.min.js +1 -1
  234. package/i18n/welsh.min.js.LICENSE.txt +1 -1
  235. package/icons/iconsV1.js +1 -1
  236. package/icons/iconsV1.min.js +1 -1
  237. package/icons/iconsV1.min.js.LICENSE.txt +1 -1
  238. package/icons/iconsV2.js +1 -1
  239. package/icons/iconsV2.min.js +1 -1
  240. package/icons/iconsV2.min.js.LICENSE.txt +1 -1
  241. package/modern.css +1 -1
  242. package/modern.fontless.css +1 -1
  243. package/modern.fontless.min.css +1 -1
  244. package/modern.min.css +1 -1
  245. package/package.json +1 -1
  246. package/plugins/bootstrap-integration/index.js +1 -1
  247. package/plugins/bootstrap-integration/index.min.js +1 -1
  248. package/plugins/bootstrap-material-integration/index.js +1 -1
  249. package/plugins/bootstrap-material-integration/index.min.js +1 -1
  250. package/survey-core.css +8 -8
  251. package/survey-core.css.map +1 -1
  252. package/survey-core.fontless.css +8 -8
  253. package/survey-core.fontless.css.map +1 -1
  254. package/survey-core.fontless.min.css +2 -2
  255. package/survey-core.min.css +2 -2
  256. package/survey.core.js +2 -2
  257. package/survey.core.min.js +2 -2
  258. package/survey.core.min.js.LICENSE.txt +1 -1
  259. package/survey.css +1 -1
  260. package/survey.i18n.js +1 -1
  261. package/survey.i18n.min.js +1 -1
  262. package/survey.i18n.min.js.LICENSE.txt +1 -1
  263. package/survey.min.css +1 -1
  264. package/themes/borderless-dark-panelless.js +1 -1
  265. package/themes/borderless-dark-panelless.min.js +1 -1
  266. package/themes/borderless-dark-panelless.min.js.LICENSE.txt +1 -1
  267. package/themes/borderless-dark.js +1 -1
  268. package/themes/borderless-dark.min.js +1 -1
  269. package/themes/borderless-dark.min.js.LICENSE.txt +1 -1
  270. package/themes/borderless-light-panelless..js +1 -1
  271. package/themes/borderless-light-panelless..min.js +1 -1
  272. package/themes/borderless-light-panelless.js +1 -1
  273. package/themes/borderless-light-panelless.min.js.LICENSE.txt +1 -1
  274. package/themes/borderless-light.js +1 -1
  275. package/themes/borderless-light.min.js +1 -1
  276. package/themes/borderless-light.min.js.LICENSE.txt +1 -1
  277. package/themes/contrast-dark-panelless.js +1 -1
  278. package/themes/contrast-dark-panelless.min.js +1 -1
  279. package/themes/contrast-dark-panelless.min.js.LICENSE.txt +1 -1
  280. package/themes/contrast-dark.js +1 -1
  281. package/themes/contrast-dark.min.js +1 -1
  282. package/themes/contrast-dark.min.js.LICENSE.txt +1 -1
  283. package/themes/contrast-light-panelless.js +1 -1
  284. package/themes/contrast-light-panelless.min.js +1 -1
  285. package/themes/contrast-light-panelless.min.js.LICENSE.txt +1 -1
  286. package/themes/contrast-light.js +1 -1
  287. package/themes/contrast-light.min.js +1 -1
  288. package/themes/contrast-light.min.js.LICENSE.txt +1 -1
  289. package/themes/default-dark-panelless.js +1 -1
  290. package/themes/default-dark-panelless.min.js +1 -1
  291. package/themes/default-dark-panelless.min.js.LICENSE.txt +1 -1
  292. package/themes/default-dark.js +1 -1
  293. package/themes/default-dark.min.js +1 -1
  294. package/themes/default-dark.min.js.LICENSE.txt +1 -1
  295. package/themes/default-light-panelless.js +1 -1
  296. package/themes/default-light-panelless.min.js +1 -1
  297. package/themes/default-light-panelless.min.js.LICENSE.txt +1 -1
  298. package/themes/default-light.js +1 -1
  299. package/themes/default-light.min.js +1 -1
  300. package/themes/default-light.min.js.LICENSE.txt +1 -1
  301. package/themes/doubleborder-dark-panelless.js +1 -1
  302. package/themes/doubleborder-dark-panelless.min.js +1 -1
  303. package/themes/doubleborder-dark-panelless.min.js.LICENSE.txt +1 -1
  304. package/themes/doubleborder-dark.js +1 -1
  305. package/themes/doubleborder-dark.min.js +1 -1
  306. package/themes/doubleborder-dark.min.js.LICENSE.txt +1 -1
  307. package/themes/doubleborder-light-panelles.js +1 -1
  308. package/themes/doubleborder-light-panelles.min.js +1 -1
  309. package/themes/doubleborder-light-panelles.min.js.LICENSE.txt +1 -1
  310. package/themes/doubleborder-light.js +1 -1
  311. package/themes/doubleborder-light.min.js +1 -1
  312. package/themes/doubleborder-light.min.js.LICENSE.txt +1 -1
  313. package/themes/flat-dark-panelless.js +1 -1
  314. package/themes/flat-dark-panelless.min.js +1 -1
  315. package/themes/flat-dark-panelless.min.js.LICENSE.txt +1 -1
  316. package/themes/flat-dark.js +1 -1
  317. package/themes/flat-dark.min.js +1 -1
  318. package/themes/flat-dark.min.js.LICENSE.txt +1 -1
  319. package/themes/flat-light-panelless.js +1 -1
  320. package/themes/flat-light-panelless.min.js +1 -1
  321. package/themes/flat-light-panelless.min.js.LICENSE.txt +1 -1
  322. package/themes/flat-light.js +1 -1
  323. package/themes/flat-light.min.js +1 -1
  324. package/themes/flat-light.min.js.LICENSE.txt +1 -1
  325. package/themes/index.js +1 -1
  326. package/themes/index.min.js +1 -1
  327. package/themes/index.min.js.LICENSE.txt +1 -1
  328. package/themes/layered-dark-panelless.js +1 -1
  329. package/themes/layered-dark-panelless.min.js +1 -1
  330. package/themes/layered-dark-panelless.min.js.LICENSE.txt +1 -1
  331. package/themes/layered-dark.js +1 -1
  332. package/themes/layered-dark.min.js +1 -1
  333. package/themes/layered-dark.min.js.LICENSE.txt +1 -1
  334. package/themes/layered-light-panelless.js +1 -1
  335. package/themes/layered-light-panelless.min.js +1 -1
  336. package/themes/layered-light-panelless.min.js.LICENSE.txt +1 -1
  337. package/themes/layered-light.js +1 -1
  338. package/themes/layered-light.min.js +1 -1
  339. package/themes/layered-light.min.js.LICENSE.txt +1 -1
  340. package/themes/plain-dark-panelless.js +1 -1
  341. package/themes/plain-dark-panelless.min.js +1 -1
  342. package/themes/plain-dark-panelless.min.js.LICENSE.txt +1 -1
  343. package/themes/plain-dark.js +1 -1
  344. package/themes/plain-dark.min.js +1 -1
  345. package/themes/plain-dark.min.js.LICENSE.txt +1 -1
  346. package/themes/plain-light-panelless.js +1 -1
  347. package/themes/plain-light-panelless.min.js +1 -1
  348. package/themes/plain-light-panelless.min.js.LICENSE.txt +1 -1
  349. package/themes/plain-light.js +1 -1
  350. package/themes/plain-light.min.js +1 -1
  351. package/themes/plain-light.min.js.LICENSE.txt +1 -1
  352. package/themes/sharp-dark-panelless.js +1 -1
  353. package/themes/sharp-dark-panelless.min.js +1 -1
  354. package/themes/sharp-dark-panelless.min.js.LICENSE.txt +1 -1
  355. package/themes/sharp-dark.js +1 -1
  356. package/themes/sharp-dark.min.js +1 -1
  357. package/themes/sharp-dark.min.js.LICENSE.txt +1 -1
  358. package/themes/sharp-light-panelless.js +1 -1
  359. package/themes/sharp-light-panelless.min.js +1 -1
  360. package/themes/sharp-light-panelless.min.js.LICENSE.txt +1 -1
  361. package/themes/sharp-light.js +1 -1
  362. package/themes/sharp-light.min.js +1 -1
  363. package/themes/sharp-light.min.js.LICENSE.txt +1 -1
  364. package/themes/solid-dark-panelless.js +1 -1
  365. package/themes/solid-dark-panelless.min.js +1 -1
  366. package/themes/solid-dark-panelless.min.js.LICENSE.txt +1 -1
  367. package/themes/solid-dark.js +1 -1
  368. package/themes/solid-dark.min.js +1 -1
  369. package/themes/solid-dark.min.js.LICENSE.txt +1 -1
  370. package/themes/solid-light-panelless.js +1 -1
  371. package/themes/solid-light-panelless.min.js +1 -1
  372. package/themes/solid-light-panelless.min.js.LICENSE.txt +1 -1
  373. package/themes/solid-light.js +1 -1
  374. package/themes/solid-light.min.js +1 -1
  375. package/themes/solid-light.min.js.LICENSE.txt +1 -1
  376. package/themes/three-dimensional-dark-panelless.js +1 -1
  377. package/themes/three-dimensional-dark-panelless.min.js +1 -1
  378. package/themes/three-dimensional-dark-panelless.min.js.LICENSE.txt +1 -1
  379. package/themes/three-dimensional-dark.js +1 -1
  380. package/themes/three-dimensional-dark.min.js +1 -1
  381. package/themes/three-dimensional-dark.min.js.LICENSE.txt +1 -1
  382. package/themes/three-dimensional-light-panelless.js +1 -1
  383. package/themes/three-dimensional-light-panelless.min.js +1 -1
  384. package/themes/three-dimensional-light-panelless.min.js.LICENSE.txt +1 -1
  385. package/themes/three-dimensional-light.js +1 -1
  386. package/themes/three-dimensional-light.min.js +1 -1
  387. package/themes/three-dimensional-light.min.js.LICENSE.txt +1 -1
  388. package/typings/src/question_rating.d.ts +3 -1
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * surveyjs - Survey JavaScript library v1.12.44
2
+ * surveyjs - Survey JavaScript library v1.12.45
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
  */
@@ -8,4 +8,4 @@
8
8
  * Signature Pad v4.2.0 | https://github.com/szimek/signature_pad
9
9
  * (c) 2024 Szymon Nowak | Released under the MIT license
10
10
  */
11
- class zs{constructor(e,t,n,o){if(isNaN(e)||isNaN(t))throw new Error(`Point is invalid: (${e}, ${t})`);this.x=+e,this.y=+t,this.pressure=n||0,this.time=o||Date.now()}distanceTo(e){return Math.sqrt(Math.pow(this.x-e.x,2)+Math.pow(this.y-e.y,2))}equals(e){return this.x===e.x&&this.y===e.y&&this.pressure===e.pressure&&this.time===e.time}velocityFrom(e){return this.time!==e.time?this.distanceTo(e)/(this.time-e.time):0}}class Hs{static fromPoints(e,t){const n=this.calculateControlPoints(e[0],e[1],e[2]).c2,o=this.calculateControlPoints(e[1],e[2],e[3]).c1;return new Hs(e[1],n,o,e[2],t.start,t.end)}static calculateControlPoints(e,t,n){const o=e.x-t.x,i=e.y-t.y,r=t.x-n.x,s=t.y-n.y,a=(e.x+t.x)/2,l=(e.y+t.y)/2,u=(t.x+n.x)/2,c=(t.y+n.y)/2,p=Math.sqrt(o*o+i*i),h=Math.sqrt(r*r+s*s),d=h/(p+h),f=u+(a-u)*d,g=c+(l-c)*d,y=t.x-f,m=t.y-g;return{c1:new zs(a+y,l+m),c2:new zs(u+y,c+m)}}constructor(e,t,n,o,i,r){this.startPoint=e,this.control2=t,this.control1=n,this.endPoint=o,this.startWidth=i,this.endWidth=r}length(){let e,t,n=0;for(let o=0;o<=10;o+=1){const i=o/10,r=this.point(i,this.startPoint.x,this.control1.x,this.control2.x,this.endPoint.x),s=this.point(i,this.startPoint.y,this.control1.y,this.control2.y,this.endPoint.y);if(o>0){const o=r-e,i=s-t;n+=Math.sqrt(o*o+i*i)}e=r,t=s}return n}point(e,t,n,o,i){return t*(1-e)*(1-e)*(1-e)+3*n*(1-e)*(1-e)*e+3*o*(1-e)*e*e+i*e*e*e}}class Us extends class{constructor(){try{this._et=new EventTarget}catch(e){this._et=document}}addEventListener(e,t,n){this._et.addEventListener(e,t,n)}dispatchEvent(e){return this._et.dispatchEvent(e)}removeEventListener(e,t,n){this._et.removeEventListener(e,t,n)}}{constructor(e,t={}){super(),this.canvas=e,this._drawingStroke=!1,this._isEmpty=!0,this._lastPoints=[],this._data=[],this._lastVelocity=0,this._lastWidth=0,this._handleMouseDown=e=>{1===e.buttons&&this._strokeBegin(e)},this._handleMouseMove=e=>{this._strokeMoveUpdate(e)},this._handleMouseUp=e=>{1===e.buttons&&this._strokeEnd(e)},this._handleTouchStart=e=>{if(e.cancelable&&e.preventDefault(),1===e.targetTouches.length){const t=e.changedTouches[0];this._strokeBegin(t)}},this._handleTouchMove=e=>{e.cancelable&&e.preventDefault();const t=e.targetTouches[0];this._strokeMoveUpdate(t)},this._handleTouchEnd=e=>{if(e.target===this.canvas){e.cancelable&&e.preventDefault();const t=e.changedTouches[0];this._strokeEnd(t)}},this._handlePointerStart=e=>{e.preventDefault(),this._strokeBegin(e)},this._handlePointerMove=e=>{this._strokeMoveUpdate(e)},this._handlePointerEnd=e=>{this._drawingStroke&&(e.preventDefault(),this._strokeEnd(e))},this.velocityFilterWeight=t.velocityFilterWeight||.7,this.minWidth=t.minWidth||.5,this.maxWidth=t.maxWidth||2.5,this.throttle="throttle"in t?t.throttle:16,this.minDistance="minDistance"in t?t.minDistance:5,this.dotSize=t.dotSize||0,this.penColor=t.penColor||"black",this.backgroundColor=t.backgroundColor||"rgba(0,0,0,0)",this.compositeOperation=t.compositeOperation||"source-over",this.canvasContextOptions="canvasContextOptions"in t?t.canvasContextOptions:{},this._strokeMoveUpdate=this.throttle?function(e,t=250){let n,o,i,r=0,s=null;const a=()=>{r=Date.now(),s=null,n=e.apply(o,i),s||(o=null,i=[])};return function(...l){const u=Date.now(),c=t-(u-r);return o=this,i=l,c<=0||c>t?(s&&(clearTimeout(s),s=null),r=u,n=e.apply(o,i),s||(o=null,i=[])):s||(s=window.setTimeout(a,c)),n}}(Us.prototype._strokeUpdate,this.throttle):Us.prototype._strokeUpdate,this._ctx=e.getContext("2d",this.canvasContextOptions),this.clear(),this.on()}clear(){const{_ctx:e,canvas:t}=this;e.fillStyle=this.backgroundColor,e.clearRect(0,0,t.width,t.height),e.fillRect(0,0,t.width,t.height),this._data=[],this._reset(this._getPointGroupOptions()),this._isEmpty=!0}fromDataURL(e,t={}){return new Promise((n,o)=>{const i=new Image,r=t.ratio||window.devicePixelRatio||1,s=t.width||this.canvas.width/r,a=t.height||this.canvas.height/r,l=t.xOffset||0,u=t.yOffset||0;this._reset(this._getPointGroupOptions()),i.onload=()=>{this._ctx.drawImage(i,l,u,s,a),n()},i.onerror=e=>{o(e)},i.crossOrigin="anonymous",i.src=e,this._isEmpty=!1})}toDataURL(e="image/png",t){switch(e){case"image/svg+xml":return"object"!=typeof t&&(t=void 0),"data:image/svg+xml;base64,"+btoa(this.toSVG(t));default:return"number"!=typeof t&&(t=void 0),this.canvas.toDataURL(e,t)}}on(){this.canvas.style.touchAction="none",this.canvas.style.msTouchAction="none",this.canvas.style.userSelect="none";const e=/Macintosh/.test(navigator.userAgent)&&"ontouchstart"in document;window.PointerEvent&&!e?this._handlePointerEvents():(this._handleMouseEvents(),"ontouchstart"in window&&this._handleTouchEvents())}off(){this.canvas.style.touchAction="auto",this.canvas.style.msTouchAction="auto",this.canvas.style.userSelect="auto",this.canvas.removeEventListener("pointerdown",this._handlePointerStart),this.canvas.removeEventListener("pointermove",this._handlePointerMove),this.canvas.ownerDocument.removeEventListener("pointerup",this._handlePointerEnd),this.canvas.removeEventListener("mousedown",this._handleMouseDown),this.canvas.removeEventListener("mousemove",this._handleMouseMove),this.canvas.ownerDocument.removeEventListener("mouseup",this._handleMouseUp),this.canvas.removeEventListener("touchstart",this._handleTouchStart),this.canvas.removeEventListener("touchmove",this._handleTouchMove),this.canvas.removeEventListener("touchend",this._handleTouchEnd)}isEmpty(){return this._isEmpty}fromData(e,{clear:t=!0}={}){t&&this.clear(),this._fromData(e,this._drawCurve.bind(this),this._drawDot.bind(this)),this._data=this._data.concat(e)}toData(){return this._data}_getPointGroupOptions(e){return{penColor:e&&"penColor"in e?e.penColor:this.penColor,dotSize:e&&"dotSize"in e?e.dotSize:this.dotSize,minWidth:e&&"minWidth"in e?e.minWidth:this.minWidth,maxWidth:e&&"maxWidth"in e?e.maxWidth:this.maxWidth,velocityFilterWeight:e&&"velocityFilterWeight"in e?e.velocityFilterWeight:this.velocityFilterWeight,compositeOperation:e&&"compositeOperation"in e?e.compositeOperation:this.compositeOperation}}_strokeBegin(e){if(!this.dispatchEvent(new CustomEvent("beginStroke",{detail:e,cancelable:!0})))return;this._drawingStroke=!0;const t=this._getPointGroupOptions(),n=Object.assign(Object.assign({},t),{points:[]});this._data.push(n),this._reset(t),this._strokeUpdate(e)}_strokeUpdate(e){if(!this._drawingStroke)return;if(0===this._data.length)return void this._strokeBegin(e);this.dispatchEvent(new CustomEvent("beforeUpdateStroke",{detail:e}));const t=e.clientX,n=e.clientY,o=void 0!==e.pressure?e.pressure:void 0!==e.force?e.force:0,i=this._createPoint(t,n,o),r=this._data[this._data.length-1],s=r.points,a=s.length>0&&s[s.length-1],l=!!a&&i.distanceTo(a)<=this.minDistance,u=this._getPointGroupOptions(r);if(!a||!a||!l){const e=this._addPoint(i,u);a?e&&this._drawCurve(e,u):this._drawDot(i,u),s.push({time:i.time,x:i.x,y:i.y,pressure:i.pressure})}this.dispatchEvent(new CustomEvent("afterUpdateStroke",{detail:e}))}_strokeEnd(e){this._drawingStroke&&(this._strokeUpdate(e),this._drawingStroke=!1,this.dispatchEvent(new CustomEvent("endStroke",{detail:e})))}_handlePointerEvents(){this._drawingStroke=!1,this.canvas.addEventListener("pointerdown",this._handlePointerStart),this.canvas.addEventListener("pointermove",this._handlePointerMove),this.canvas.ownerDocument.addEventListener("pointerup",this._handlePointerEnd)}_handleMouseEvents(){this._drawingStroke=!1,this.canvas.addEventListener("mousedown",this._handleMouseDown),this.canvas.addEventListener("mousemove",this._handleMouseMove),this.canvas.ownerDocument.addEventListener("mouseup",this._handleMouseUp)}_handleTouchEvents(){this.canvas.addEventListener("touchstart",this._handleTouchStart),this.canvas.addEventListener("touchmove",this._handleTouchMove),this.canvas.addEventListener("touchend",this._handleTouchEnd)}_reset(e){this._lastPoints=[],this._lastVelocity=0,this._lastWidth=(e.minWidth+e.maxWidth)/2,this._ctx.fillStyle=e.penColor,this._ctx.globalCompositeOperation=e.compositeOperation}_createPoint(e,t,n){const o=this.canvas.getBoundingClientRect();return new zs(e-o.left,t-o.top,n,(new Date).getTime())}_addPoint(e,t){const{_lastPoints:n}=this;if(n.push(e),n.length>2){3===n.length&&n.unshift(n[0]);const e=this._calculateCurveWidths(n[1],n[2],t),o=Hs.fromPoints(n,e);return n.shift(),o}return null}_calculateCurveWidths(e,t,n){const o=n.velocityFilterWeight*t.velocityFrom(e)+(1-n.velocityFilterWeight)*this._lastVelocity,i=this._strokeWidth(o,n),r={end:i,start:this._lastWidth};return this._lastVelocity=o,this._lastWidth=i,r}_strokeWidth(e,t){return Math.max(t.maxWidth/(e+1),t.minWidth)}_drawCurveSegment(e,t,n){const o=this._ctx;o.moveTo(e,t),o.arc(e,t,n,0,2*Math.PI,!1),this._isEmpty=!1}_drawCurve(e,t){const n=this._ctx,o=e.endWidth-e.startWidth,i=2*Math.ceil(e.length());n.beginPath(),n.fillStyle=t.penColor;for(let n=0;n<i;n+=1){const r=n/i,s=r*r,a=s*r,l=1-r,u=l*l,c=u*l;let p=c*e.startPoint.x;p+=3*u*r*e.control1.x,p+=3*l*s*e.control2.x,p+=a*e.endPoint.x;let h=c*e.startPoint.y;h+=3*u*r*e.control1.y,h+=3*l*s*e.control2.y,h+=a*e.endPoint.y;const d=Math.min(e.startWidth+a*o,t.maxWidth);this._drawCurveSegment(p,h,d)}n.closePath(),n.fill()}_drawDot(e,t){const n=this._ctx,o=t.dotSize>0?t.dotSize:(t.minWidth+t.maxWidth)/2;n.beginPath(),this._drawCurveSegment(e.x,e.y,o),n.closePath(),n.fillStyle=t.penColor,n.fill()}_fromData(e,t,n){for(const o of e){const{points:e}=o,i=this._getPointGroupOptions(o);if(e.length>1)for(let n=0;n<e.length;n+=1){const o=e[n],r=new zs(o.x,o.y,o.pressure,o.time);0===n&&this._reset(i);const s=this._addPoint(r,i);s&&t(s,i)}else this._reset(i),n(e[0],i)}}toSVG({includeBackgroundColor:e=!1}={}){const t=this._data,n=Math.max(window.devicePixelRatio||1,1),o=this.canvas.width/n,i=this.canvas.height/n,r=document.createElementNS("http://www.w3.org/2000/svg","svg");if(r.setAttribute("xmlns","http://www.w3.org/2000/svg"),r.setAttribute("xmlns:xlink","http://www.w3.org/1999/xlink"),r.setAttribute("viewBox",`0 0 ${o} ${i}`),r.setAttribute("width",o.toString()),r.setAttribute("height",i.toString()),e&&this.backgroundColor){const e=document.createElement("rect");e.setAttribute("width","100%"),e.setAttribute("height","100%"),e.setAttribute("fill",this.backgroundColor),r.appendChild(e)}return this._fromData(t,(e,{penColor:t})=>{const n=document.createElement("path");if(!(isNaN(e.control1.x)||isNaN(e.control1.y)||isNaN(e.control2.x)||isNaN(e.control2.y))){const o=`M ${e.startPoint.x.toFixed(3)},${e.startPoint.y.toFixed(3)} C ${e.control1.x.toFixed(3)},${e.control1.y.toFixed(3)} ${e.control2.x.toFixed(3)},${e.control2.y.toFixed(3)} ${e.endPoint.x.toFixed(3)},${e.endPoint.y.toFixed(3)}`;n.setAttribute("d",o),n.setAttribute("stroke-width",(2.25*e.endWidth).toFixed(3)),n.setAttribute("stroke",t),n.setAttribute("fill","none"),n.setAttribute("stroke-linecap","round"),r.appendChild(n)}},(e,{penColor:t,dotSize:n,minWidth:o,maxWidth:i})=>{const s=document.createElement("circle"),a=n>0?n:(o+i)/2;s.setAttribute("r",a.toString()),s.setAttribute("cx",e.x.toString()),s.setAttribute("cy",e.y.toString()),s.setAttribute("fill",t),r.appendChild(s)}),r.outerHTML}}var Ws=function(){var e=function(t,n){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(t,n)};return function(t,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function o(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(o.prototype=n.prototype,new o)}}(),Gs=function(e,t,n,o){var i,r=arguments.length,s=r<3?t:null===o?o=Object.getOwnPropertyDescriptor(t,n):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,n,o);else for(var a=e.length-1;a>=0;a--)(i=e[a])&&(s=(r<3?i(s):r>3?i(t,n,s):i(t,n))||s);return r>3&&s&&Object.defineProperty(t,n,s),s},Js=function(e){function t(t){var n=e.call(this,t)||this;return n.valueIsUpdatingInternally=!1,n._loadedData=void 0,n.updateValueHandler=function(){n._loadedData=void 0,n.scaleCanvas(!0,!0)},n}return Ws(t,e),t.prototype.getPenColorFromTheme=function(){var e=this.survey;return!!e&&!!e.themeVariables&&e.themeVariables["--sjs-primary-backcolor"]},t.prototype.updateColors=function(e){var t=this.getPenColorFromTheme(),n=this.getPropertyByName("penColor");e.penColor=this.penColor||t||n.defaultValue||"#1ab394";var o=this.getPropertyByName("backgroundColor"),i=t?"transparent":void 0,r=this.backgroundImage?"transparent":this.backgroundColor;e.backgroundColor=r||i||o.defaultValue||"#ffffff"},t.prototype.getCssRoot=function(t){return(new Ee).append(e.prototype.getCssRoot.call(this,t)).append(t.small,"300"===this.signatureWidth.toString()).toString()},t.prototype.getFormat=function(){return"jpeg"===this.dataFormat?"image/jpeg":"svg"===this.dataFormat?"image/svg+xml":""},t.prototype.updateValue=function(){if(this.signaturePad){var e=this.signaturePad.toDataURL(this.getFormat());this.valueIsUpdatingInternally=!0,this.value=e,this.valueIsUpdatingInternally=!1}},t.prototype.getType=function(){return"signaturepad"},t.prototype.afterRenderQuestionElement=function(t){t&&(this.isDesignMode||this.initSignaturePad(t),this.element=t),e.prototype.afterRenderQuestionElement.call(this,t)},t.prototype.beforeDestroyQuestionElement=function(e){e&&this.destroySignaturePad(e)},t.prototype.themeChanged=function(e){this.signaturePad&&this.updateColors(this.signaturePad)},t.prototype.resizeCanvas=function(){this.canvas.width=this.containerWidth,this.canvas.height=this.containerHeight},t.prototype.scaleCanvas=function(e,t){void 0===e&&(e=!0),void 0===t&&(t=!1);var n=this.canvas,o=n.offsetWidth/this.containerWidth;(this.scale!=o||t)&&(this.scale=o,n.style.width=this.renderedCanvasWidth,this.resizeCanvas(),this.signaturePad.minWidth=this.penMinWidth*o,this.signaturePad.maxWidth=this.penMaxWidth*o,n.getContext("2d").scale(1/o,1/o),e&&this.loadPreview(this.value))},t.prototype.fromUrl=function(e){var t=this;if(this.isFileLoading=!0,function(e){return"string"==typeof e?/^data:((?:\w+\/(?:(?!;).)+)?)((?:;[^;]+?)*),(.+)$/.test(e):null}(e))this.fromDataUrl(e),this.isFileLoading=!1;else{var n=new Image;n.crossOrigin="anonymous",n.src=e,n.onload=function(){if(t.canvas){var e=i.createElement("canvas");e.width=t.containerWidth,e.height=t.containerHeight,e.getContext("2d").drawImage(n,0,0);var o=e.toDataURL(t.getFormat());t.fromDataUrl(o)}t.isFileLoading=!1},n.onerror=function(){t.isFileLoading=!1}}},t.prototype.fromDataUrl=function(e){if(this._loadedData=e,this.signaturePad){var t=1,n=this.scale;if("svg"===this.dataFormat)t=o.getDevicePixelRatio()||1,n=1;var i={width:this.canvas.width*n/t,height:this.canvas.height*n/t};this.signaturePad.fromDataURL(e,i)}},Object.defineProperty(t.prototype,"loadedData",{get:function(){return this._loadedData},enumerable:!1,configurable:!0}),t.prototype.loadPreview=function(e){var t=this;if(!e)return this.signaturePad&&this.canvas&&(this.canvas.getContext("2d").clearRect(0,0,this.canvas.width*this.scale,this.canvas.height*this.scale),this.signaturePad.clear()),void(this.valueWasChangedFromLastUpload=!1);if(this.storeDataAsText)this.fromDataUrl(e);else if(this.loadedData)this.fromDataUrl(this.loadedData);else{var n=e?[e]:[];this._previewLoader&&this._previewLoader.dispose(),this.isFileLoading=!0,this._previewLoader=new ws(this,(function(n,o){"success"===n&&o&&o.length>0&&o[0].content?(t.fromDataUrl(o[0].content),t.isFileLoading=!1):"skipped"===n&&t.fromUrl(e),t._previewLoader.dispose(),t._previewLoader=void 0})),this._previewLoader.load(n)}},t.prototype.onChangeQuestionValue=function(t){e.prototype.onChangeQuestionValue.call(this,t),this.isLoadingFromJson||(this._loadedData=void 0,this.loadPreview(t))},t.prototype.onSurveyLoad=function(){e.prototype.onSurveyLoad.call(this),this.loadPreview(this.value)},t.prototype.initSignaturePad=function(e){var t=this,n=e.getElementsByTagName("canvas")[0];this.canvas=n,this.resizeCanvas();var o=new Us(n,{backgroundColor:"#ffffff"});this.signaturePad=o,this.isInputReadOnly&&o.off(),this.readOnlyChangedCallback=function(){t.isInputReadOnly?o.off():o.on()},this.updateColors(o),o.addEventListener("beginStroke",(function(){t.scaleCanvas(),t.isDrawingValue=!0,n.focus()}),{once:!1}),o.addEventListener("endStroke",(function(){t.isDrawingValue=!1,t.storeDataAsText?t.updateValue():t.valueWasChangedFromLastUpload=!0}),{once:!1}),this.updateValueHandler(),this.readOnlyChangedCallback();var i=function(e,n){"signatureWidth"!==n.name&&"signatureHeight"!==n.name||t.valueIsUpdatingInternally||t.updateValueHandler()};this.onPropertyChanged.add(i),this.signaturePad.propertyChangedHandler=i},t.prototype.destroySignaturePad=function(e){this.signaturePad&&(this.onPropertyChanged.remove(this.signaturePad.propertyChangedHandler),this.signaturePad.off()),this.readOnlyChangedCallback=null,this.signaturePad=null},Object.defineProperty(t.prototype,"dataFormat",{get:function(){return this.getPropertyValue("dataFormat")},set:function(e){this.setPropertyValue("dataFormat",Ks(e))},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"signatureWidth",{get:function(){return this.getPropertyValue("signatureWidth")},set:function(e){this.setPropertyValue("signatureWidth",e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"signatureHeight",{get:function(){return this.getPropertyValue("signatureHeight")},set:function(e){this.setPropertyValue("signatureHeight",e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"containerHeight",{get:function(){return this.signatureHeight||200},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"containerWidth",{get:function(){return this.signatureWidth||300},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"renderedCanvasWidth",{get:function(){return this.signatureAutoScaleEnabled?"100%":this.containerWidth+"px"},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"height",{get:function(){return this.getPropertyValue("height")},set:function(e){this.setPropertyValue("height",e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"allowClear",{get:function(){return this.getPropertyValue("allowClear")},set:function(e){this.setPropertyValue("allowClear",e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"canShowClearButton",{get:function(){var e=!this.nothingIsDrawn(),t=this.isUploading;return!this.isInputReadOnly&&this.allowClear&&e&&!t},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"penColor",{get:function(){return this.getPropertyValue("penColor")},set:function(e){this.setPropertyValue("penColor",e),this.signaturePad&&this.updateColors(this.signaturePad)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"backgroundColor",{get:function(){return this.getPropertyValue("backgroundColor")},set:function(e){this.setPropertyValue("backgroundColor",e),this.signaturePad&&this.updateColors(this.signaturePad)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"backgroundImage",{get:function(){return this.getPropertyValue("backgroundImage")},set:function(e){this.setPropertyValue("backgroundImage",e),this.signaturePad&&this.updateColors(this.signaturePad)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"clearButtonCaption",{get:function(){return this.getLocalizationString("clearCaption")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"locRenderedPlaceholder",{get:function(){return this.isReadOnly?this.locPlaceholderReadOnly:this.locPlaceholder},enumerable:!1,configurable:!0}),t.prototype.nothingIsDrawn=function(){var e=this.isDrawingValue,t=this.isEmpty(),n=this.isUploading,o=this.valueWasChangedFromLastUpload;return!e&&t&&!n&&!o},t.prototype.needShowPlaceholder=function(){return this.showPlaceholder&&this.nothingIsDrawn()},t.prototype.onBlurCore=function(t){if(e.prototype.onBlurCore.call(this,t),!this.storeDataAsText&&!this.element.contains(t.relatedTarget)){if(!this.valueWasChangedFromLastUpload)return;this.uploadFiles([(n=this.signaturePad.toDataURL(this.getFormat()),o=this.name+"."+Ks(this.dataFormat),i=this.getFormat(),r=atob(n.split(",")[1]),s=new Uint8Array(r.split("").map((function(e){return e.charCodeAt(0)}))).buffer,new File([s],o,{type:i}))]),this.valueWasChangedFromLastUpload=!1}var n,o,i,r,s},t.prototype.uploadResultItemToValue=function(e){return e.content},t.prototype.setValueFromResult=function(e){this.valueIsUpdatingInternally=!0,this.value=(null==e?void 0:e.length)?e.map((function(e){return e.content}))[0]:void 0,this.valueIsUpdatingInternally=!1},t.prototype.clearValue=function(t){this.valueWasChangedFromLastUpload=!1,e.prototype.clearValue.call(this,t),this._loadedData=void 0,this.loadPreview(this.value)},t.prototype.endLoadingFromJson=function(){e.prototype.endLoadingFromJson.call(this),300===this.signatureWidth&&this.width&&"number"==typeof this.width&&this.width&&(j.warn("Use signatureWidth property to set width for the signature pad"),this.signatureWidth=this.width,this.width=void 0),200===this.signatureHeight&&this.height&&(j.warn("Use signatureHeight property to set width for the signature pad"),this.signatureHeight=this.height,this.height=void 0)},Gs([m({defaultValue:!1})],t.prototype,"isDrawingValue",void 0),Gs([m({defaultValue:!1})],t.prototype,"isReadyForUpload",void 0),Gs([m({defaultValue:!1})],t.prototype,"valueWasChangedFromLastUpload",void 0),Gs([m()],t.prototype,"signatureAutoScaleEnabled",void 0),Gs([m()],t.prototype,"penMinWidth",void 0),Gs([m()],t.prototype,"penMaxWidth",void 0),Gs([m({})],t.prototype,"showPlaceholder",void 0),Gs([m({localizable:{defaultStr:"signaturePlaceHolder"}})],t.prototype,"placeholder",void 0),Gs([m({localizable:{defaultStr:"signaturePlaceHolderReadOnly"}})],t.prototype,"placeholderReadOnly",void 0),t}(bs);function Ks(e){return e||(e="png"),"jpeg"!==(e=e.replace("image/","").replace("+xml",""))&&"svg"!==e&&(e="png"),e}D.addClass("signaturepad",[{name:"signatureWidth:number",category:"general",default:300},{name:"signatureHeight:number",category:"general",default:200},{name:"signatureAutoScaleEnabled:boolean",category:"general",default:!1},{name:"penMinWidth:number",category:"general",default:.5},{name:"penMaxWidth:number",category:"general",default:2.5},{name:"height:number",category:"general",visible:!1},{name:"allowClear:boolean",category:"general",default:!0},{name:"showPlaceholder:boolean",category:"general",default:!0},{name:"placeholder:text",serializationProperty:"locPlaceholder",category:"general",dependsOn:"showPlaceholder",visibleIf:function(e){return e.showPlaceholder}},{name:"placeholderReadOnly:text",serializationProperty:"locPlaceholderReadOnly",category:"general",dependsOn:"showPlaceholder",visibleIf:function(e){return e.showPlaceholder}},{name:"backgroundImage:file",category:"general"},{name:"penColor:color",category:"general"},{name:"backgroundColor:color",category:"general"},{name:"dataFormat",category:"general",default:"png",choices:[{value:"png",text:"PNG"},{value:"jpeg",text:"JPEG"},{value:"svg",text:"SVG"}],onSettingValue:function(e,t){return Ks(t)}},{name:"defaultValue",visible:!1},{name:"correctAnswer",visible:!1},{name:"storeDataAsText:boolean",default:!0},{name:"waitForUpload:boolean",default:!1}],(function(){return new Js("")}),"question"),ao.Instance.registerQuestion("signaturepad",(function(e){return new Js(e)}));var $s=function(){var e=function(t,n){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(t,n)};return function(t,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function o(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(o.prototype=n.prototype,new o)}}(),Ys=function(e,t,n,o){var i,r=arguments.length,s=r<3?t:null===o?o=Object.getOwnPropertyDescriptor(t,n):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,n,o);else for(var a=e.length-1;a>=0;a--)(i=e[a])&&(s=(r<3?i(s):r>3?i(t,n,s):i(t,n))||s);return r>3&&s&&Object.defineProperty(t,n,s),s},Xs=function(e,t){for(var n=0,o=t.length,i=e.length;n<o;n++,i++)e[i]=t[n];return e},Zs=function(e){function t(t,n,o){var i=e.call(this,o)||this;return i.data=t,i.panelItem=n,i.variableName=o,i.sharedQuestions={},i}return $s(t,e),Object.defineProperty(t.prototype,"survey",{get:function(){return this.panelItem.getSurvey()},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"panel",{get:function(){return this.panelItem.panel},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"panelIndex",{get:function(){return this.data?this.data.getItemIndex(this.panelItem):-1},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"visiblePanelIndex",{get:function(){return this.data?this.data.getVisibleItemIndex(this.panelItem):-1},enumerable:!1,configurable:!0}),t.prototype.getValues=function(){return this.panelItem.getAllValues()},t.prototype.getQuestionByName=function(t){var n=e.prototype.getQuestionByName.call(this,t);if(n)return n;var o=this.panelIndex,i=(n=o>-1?this.data.getSharedQuestionFromArray(t,o):void 0)?n.name:t;return this.sharedQuestions[i]=t,n},t.prototype.getQuestionDisplayText=function(t){var n=this.sharedQuestions[t.name];if(!n)return e.prototype.getQuestionDisplayText.call(this,t);var o=this.panelItem.getValue(n);return t.getDisplayValue(!0,o)},t.prototype.onCustomProcessText=function(e){var n;if(e.name==ta.IndexVariableName&&(n=this.panelIndex)>-1)return e.isExists=!0,e.value=n+1,!0;if(e.name==ta.VisibleIndexVariableName&&(n=this.visiblePanelIndex)>-1)return e.isExists=!0,e.value=n+1,!0;if(0==e.name.toLowerCase().indexOf(ta.ParentItemVariableName+".")){var o=this.data;if(o&&o.parentQuestion&&o.parent&&o.parent.data){var i=new t(o.parentQuestion,o.parent.data,ta.ItemVariableName),r=ta.ItemVariableName+e.name.substring(ta.ParentItemVariableName.length),s=i.processValue(r,e.returnDisplayValue);e.isExists=s.isExists,e.value=s.value}return!0}return!1},t}(Zn),ea=function(e){function t(t){return e.call(this,t)||this}return $s(t,e),t}(Xe),ta=function(){function e(t,n){this.data=t,this.panelValue=n,this.textPreProcessor=new Zs(t,this,e.ItemVariableName),this.setSurveyImpl()}return Object.defineProperty(e.prototype,"panel",{get:function(){return this.panelValue},enumerable:!1,configurable:!0}),e.prototype.setSurveyImpl=function(){this.panel.setSurveyImpl(this)},e.prototype.getValue=function(e){return this.getAllValues()[e]},e.prototype.setValue=function(t,n){var o=this.data.getPanelItemData(this),i=o?o[t]:void 0;if(!s.isTwoValueEquals(n,i,!1,!0,!1)){this.data.setPanelItemData(this,t,s.getUnbindValue(n));for(var r=this.panel.questions,a=0;a<r.length;a++){var l=r[a];l.getValueName()!==t&&l.checkBindings(t,n);var u=Xt.commentSuffix;if(t.endsWith(u)){t=t.substring(0,t.length-u.length);var c=this.panel.getQuestionByName(t);c&&(n=c.value)}var p=e.ItemVariableName+"."+t;l.runTriggers(p,n)}}},e.prototype.getVariable=function(e){},e.prototype.setVariable=function(e,t){},e.prototype.getComment=function(e){var t=this.getValue(e+Xt.commentSuffix);return t||""},e.prototype.setComment=function(e,t,n){this.setValue(e+Xt.commentSuffix,t)},e.prototype.findQuestionByName=function(t){if(t){var n=e.ItemVariableName+".";if(0===t.indexOf(n))return this.panel.getQuestionByName(t.substring(n.length));var o=this.getSurvey();return o?o.getQuestionByName(t):null}},e.prototype.getEditingSurveyElement=function(){},e.prototype.getAllValues=function(){return this.data.getPanelItemData(this)},e.prototype.getFilteredValues=function(){var t={},n=this.data&&this.data.getRootData()?this.data.getRootData().getFilteredValues():{};for(var o in n)t[o]=n[o];if(t[e.ItemVariableName]=this.getAllValues(),this.data){var i=e.IndexVariableName,r=e.VisibleIndexVariableName;delete t[i],delete t[r],t[i.toLowerCase()]=this.data.getItemIndex(this),t[r.toLowerCase()]=this.data.getVisibleItemIndex(this);var s=this.data;s&&s.parentQuestion&&s.parent&&(t[e.ParentItemVariableName]=s.parent.getValue())}return t},e.prototype.getFilteredProperties=function(){return this.data&&this.data.getRootData()?this.data.getRootData().getFilteredProperties():{survey:this.getSurvey()}},e.prototype.getSurveyData=function(){return this},e.prototype.getSurvey=function(){return this.data?this.data.getSurvey():null},e.prototype.getTextProcessor=function(){return this.textPreProcessor},e.ItemVariableName="panel",e.ParentItemVariableName="parentpanel",e.IndexVariableName="panelIndex",e.VisibleIndexVariableName="visiblePanelIndex",e}(),na=function(){function e(e){this.data=e}return e.prototype.getSurveyData=function(){return null},e.prototype.getSurvey=function(){return this.data.getSurvey()},e.prototype.getTextProcessor=function(){return null},e}(),oa=function(e){function t(t){var n=e.call(this,t)||this;return n._renderedPanels=[],n.isPanelsAnimationRunning=!1,n.isAddingNewPanels=!1,n.isSetPanelItemData={},n.createNewArray("panels",(function(e){n.onPanelAdded(e)}),(function(e){n.onPanelRemoved(e)})),n.createNewArray("visiblePanels"),n.templateValue=n.createAndSetupNewPanelObject(),n.template.renderWidth="100%",n.template.selectedElementInDesign=n,n.template.addElementCallback=function(e){n.addOnPropertyChangedCallback(e),n.rebuildPanels()},n.template.removeElementCallback=function(){n.rebuildPanels()},n.createLocalizableString("confirmDeleteText",n,!1,"confirmDelete"),n.createLocalizableString("keyDuplicationError",n,!1,!0),n.createLocalizableString("panelAddText",n,!1,"addPanel"),n.createLocalizableString("panelRemoveText",n,!1,"removePanel"),n.createLocalizableString("panelPrevText",n,!1,"pagePrevText"),n.createLocalizableString("panelNextText",n,!1,"pageNextText"),n.createLocalizableString("noEntriesText",n,!1,"noEntriesText"),n.createLocalizableString("templateTabTitle",n,!0,"panelDynamicTabTextFormat"),n.createLocalizableString("tabTitlePlaceholder",n,!0,"tabTitlePlaceholder"),n.registerPropertyChangedHandlers(["panelsState"],(function(){n.setPanelsState()})),n.registerPropertyChangedHandlers(["newPanelPosition","displayMode","showProgressBar"],(function(){n.updateFooterActions()})),n.registerPropertyChangedHandlers(["allowAddPanel"],(function(){n.updateNoEntriesTextDefaultLoc()})),n.registerPropertyChangedHandlers(["minPanelCount"],(function(){n.onMinPanelCountChanged()})),n.registerPropertyChangedHandlers(["maxPanelCount"],(function(){n.onMaxPanelCountChanged()})),n}return $s(t,e),Object.defineProperty(t.prototype,"isCompositeQuestion",{get:function(){return!0},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"hasSingleInput",{get:function(){return!1},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isContainer",{get:function(){return!0},enumerable:!1,configurable:!0}),t.prototype.getFirstQuestionToFocus=function(e){for(var t=0;t<this.visiblePanelsCore.length;t++){var n=this.visiblePanelsCore[t].getFirstQuestionToFocus(e);if(n)return n}return this.showAddPanelButton&&(!e||this.currentErrorCount>0)?this:null},t.prototype.getFirstInputElementId=function(){return this.showAddPanelButton?this.addButtonId:e.prototype.getFirstInputElementId.call(this)},t.prototype.setSurveyImpl=function(t,n){e.prototype.setSurveyImpl.call(this,t,n),this.setTemplatePanelSurveyImpl(),this.setPanelsSurveyImpl()},t.prototype.assignOnPropertyChangedToTemplate=function(){for(var e=this.template.elements,t=0;t<e.length;t++)this.addOnPropertyChangedCallback(e[t])},t.prototype.addOnPropertyChangedCallback=function(e){var t=this;e.isQuestion&&e.setParentQuestion(this),e.onPropertyChanged.add((function(e,n){t.onTemplateElementPropertyChanged(e,n)})),e.isPanel&&(e.addElementCallback=function(e){t.addOnPropertyChangedCallback(e)})},t.prototype.onTemplateElementPropertyChanged=function(e,t){if(!this.isLoadingFromJson&&!this.useTemplatePanel&&0!=this.panelsCore.length&&D.findProperty(e.getType(),t.name))for(var n=this.panelsCore,o=0;o<n.length;o++){var i=n[o].getQuestionByName(e.name);i&&i[t.name]!==t.newValue&&(i[t.name]=t.newValue)}},Object.defineProperty(t.prototype,"useTemplatePanel",{get:function(){return this.isDesignMode&&!this.isContentElement},enumerable:!1,configurable:!0}),t.prototype.getType=function(){return"paneldynamic"},t.prototype.clearOnDeletingContainer=function(){this.panelsCore.forEach((function(e){e.clearOnDeletingContainer()}))},Object.defineProperty(t.prototype,"isAllowTitleLeft",{get:function(){return!1},enumerable:!1,configurable:!0}),t.prototype.removeElement=function(e){return this.template.removeElement(e)},Object.defineProperty(t.prototype,"template",{get:function(){return this.templateValue},enumerable:!1,configurable:!0}),t.prototype.getPanel=function(){return this.template},Object.defineProperty(t.prototype,"templateElements",{get:function(){return this.template.elements},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"templateTitle",{get:function(){return this.template.title},set:function(e){this.template.title=e},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"locTemplateTitle",{get:function(){return this.template.locTitle},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"templateTabTitle",{get:function(){return this.locTemplateTabTitle.text},set:function(e){this.locTemplateTabTitle.text=e},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"locTemplateTabTitle",{get:function(){return this.getLocalizableString("templateTabTitle")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"tabTitlePlaceholder",{get:function(){return this.locTabTitlePlaceholder.text},set:function(e){this.locTabTitlePlaceholder.text=e},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"locTabTitlePlaceholder",{get:function(){return this.getLocalizableString("tabTitlePlaceholder")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"templateDescription",{get:function(){return this.template.description},set:function(e){this.template.description=e},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"locTemplateDescription",{get:function(){return this.template.locDescription},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"templateVisibleIf",{get:function(){return this.getPropertyValue("templateVisibleIf")},set:function(e){this.setPropertyValue("templateVisibleIf",e),this.template.visibleIf=e},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"items",{get:function(){for(var e=[],t=0;t<this.panelsCore.length;t++)e.push(this.panelsCore[t].data);return e},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"panels",{get:function(){return this.buildPanelsFirstTime(this.canBuildPanels),this.panelsCore},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"visiblePanels",{get:function(){return this.buildPanelsFirstTime(this.canBuildPanels),this.visiblePanelsCore},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"panelsCore",{get:function(){return this.getPropertyValue("panels")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"visiblePanelsCore",{get:function(){return this.getPropertyValue("visiblePanels")},enumerable:!1,configurable:!0}),t.prototype.onPanelAdded=function(e){if(this.onPanelRemovedCore(e),e.visible){for(var t=0,n=this.panelsCore,o=0;o<n.length&&n[o]!==e;o++)n[o].visible&&t++;this.visiblePanelsCore.splice(t,0,e),this.addTabFromToolbar(e,t),this.currentPanel||(this.currentPanel=e),this.updateRenderedPanels()}},t.prototype.onPanelRemoved=function(e){var t=this.onPanelRemovedCore(e);if(this.currentPanel===e){var n=this.visiblePanelsCore;t>=n.length&&(t=n.length-1),this.currentPanel=t>=0?n[t]:null}this.updateRenderedPanels()},t.prototype.onPanelRemovedCore=function(e){var t=this.visiblePanelsCore,n=t.indexOf(e);return n>-1&&(t.splice(n,1),this.removeTabFromToolbar(e)),n},Object.defineProperty(t.prototype,"currentIndex",{get:function(){return this.isRenderModeList?-1:this.useTemplatePanel?0:this.visiblePanelsCore.indexOf(this.currentPanel)},set:function(e){e<0||this.visiblePanelCount<1||(e>=this.visiblePanelCount&&(e=this.visiblePanelCount-1),this.currentPanel=this.visiblePanelsCore[e])},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"currentPanel",{get:function(){if(this.isDesignMode)return this.template;if(this.isRenderModeList||this.useTemplatePanel)return null;var e=this.getPropertyValue("currentPanel",null);return!e&&this.visiblePanelCount>0&&(e=this.visiblePanelsCore[0],this.currentPanel=e),e},set:function(e){if(!this.isRenderModeList&&!this.useTemplatePanel){var t=this.getPropertyValue("currentPanel"),n=e?this.visiblePanelsCore.indexOf(e):-1;if(!(e&&n<0||e===t)&&(t&&t.onHidingContent(),this.setPropertyValue("currentPanel",e),this.updateRenderedPanels(),this.updateFooterActions(),this.updateTabToolbarItemsPressedState(),this.fireCallback(this.currentIndexChangedCallback),n>-1&&this.survey)){var o={panel:e,visiblePanelIndex:n};this.survey.dynamicPanelCurrentIndexChanged(this,o)}}},enumerable:!1,configurable:!0}),t.prototype.updateRenderedPanels=function(){this.isRenderModeList?this.renderedPanels=[].concat(this.visiblePanels):this.currentPanel?this.renderedPanels=[this.currentPanel]:this.renderedPanels=[]},Object.defineProperty(t.prototype,"renderedPanels",{get:function(){return this._renderedPanels},set:function(e){0==this.renderedPanels.length||0==e.length?(this.blockAnimations(),this.panelsAnimation.sync(e),this.releaseAnimations()):(this.isPanelsAnimationRunning=!0,this.panelsAnimation.sync(e))},enumerable:!1,configurable:!0}),t.prototype.getPanelsAnimationOptions=function(){var e=this,t=function(){if(e.isRenderModeList)return"";var t=new Ee,n=!1,o=e.renderedPanels.filter((function(t){return t!==e.currentPanel}))[0],i=e.visiblePanels.indexOf(o);return i<0&&(n=!0,i=e.removedPanelIndex),t.append("sv-pd-animation-adding",!!e.focusNewPanelCallback).append("sv-pd-animation-removing",n).append("sv-pd-animation-left",i<=e.currentIndex).append("sv-pd-animation-right",i>e.currentIndex).toString()};return{getRerenderEvent:function(){return e.onElementRerendered},getAnimatedElement:function(t){var n,o;if(t&&e.cssContent){var i=Bt(e.cssContent);return null===(o=null===(n=e.getWrapperElement())||void 0===n?void 0:n.querySelector(":scope "+i+" #"+t.id))||void 0===o?void 0:o.parentElement}},getEnterOptions:function(){return{onBeforeRunAnimation:function(t){if(e.focusNewPanelCallback){var n=e.isRenderModeList?t:t.parentElement;ft.ScrollElementToViewCore(n,!1,!1,{behavior:"smooth"})}!e.isRenderModeList&&t.parentElement?Jt(t.parentElement,{heightTo:t.offsetHeight+"px"}):Kt(t)},onAfterRunAnimation:function(e){$t(e),e.parentElement&&$t(e.parentElement)},cssClass:(new Ee).append(e.cssClasses.panelWrapperEnter).append(t()).toString()}},getLeaveOptions:function(){return{onBeforeRunAnimation:function(t){!e.isRenderModeList&&t.parentElement?Jt(t.parentElement,{heightFrom:t.offsetHeight+"px"}):Kt(t)},onAfterRunAnimation:function(e){$t(e),e.parentElement&&$t(e.parentElement)},cssClass:(new Ee).append(e.cssClasses.panelWrapperLeave).append(t()).toString()}},isAnimationEnabled:function(){return e.animationAllowed&&!!e.getWrapperElement()}}},t.prototype.disablePanelsAnimations=function(){this.panelsCore.forEach((function(e){e.blockAnimations()}))},t.prototype.enablePanelsAnimations=function(){this.panelsCore.forEach((function(e){e.releaseAnimations()}))},t.prototype.updatePanelsAnimation=function(){var e=this;this._panelsAnimations=new(this.isRenderModeList?ut:ct)(this.getPanelsAnimationOptions(),(function(t,n){e._renderedPanels=t,n||(e.isPanelsAnimationRunning=!1,e.focusNewPanel())}),(function(){return e._renderedPanels}))},Object.defineProperty(t.prototype,"panelsAnimation",{get:function(){return this._panelsAnimations||this.updatePanelsAnimation(),this._panelsAnimations},enumerable:!1,configurable:!0}),t.prototype.onHidingContent=function(){e.prototype.onHidingContent.call(this),this.currentPanel?this.currentPanel.onHidingContent():this.visiblePanelsCore.forEach((function(e){return e.onHidingContent()}))},Object.defineProperty(t.prototype,"confirmDelete",{get:function(){return this.getPropertyValue("confirmDelete")},set:function(e){this.setPropertyValue("confirmDelete",e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"keyName",{get:function(){return this.getPropertyValue("keyName","")},set:function(e){this.setPropertyValue("keyName",e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"confirmDeleteText",{get:function(){return this.getLocalizableStringText("confirmDeleteText")},set:function(e){this.setLocalizableStringText("confirmDeleteText",e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"locConfirmDeleteText",{get:function(){return this.getLocalizableString("confirmDeleteText")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"keyDuplicationError",{get:function(){return this.getLocalizableStringText("keyDuplicationError")},set:function(e){this.setLocalizableStringText("keyDuplicationError",e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"locKeyDuplicationError",{get:function(){return this.getLocalizableString("keyDuplicationError")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"panelPrevText",{get:function(){return this.getLocalizableStringText("panelPrevText")},set:function(e){this.setLocalizableStringText("panelPrevText",e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"locPanelPrevText",{get:function(){return this.getLocalizableString("panelPrevText")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"panelNextText",{get:function(){return this.getLocalizableStringText("panelNextText")},set:function(e){this.setLocalizableStringText("panelNextText",e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"locPanelNextText",{get:function(){return this.getLocalizableString("panelNextText")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"panelAddText",{get:function(){return this.getLocalizableStringText("panelAddText")},set:function(e){this.setLocalizableStringText("panelAddText",e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"locPanelAddText",{get:function(){return this.getLocalizableString("panelAddText")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"panelRemoveText",{get:function(){return this.getLocalizableStringText("panelRemoveText")},set:function(e){this.setLocalizableStringText("panelRemoveText",e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"locPanelRemoveText",{get:function(){return this.getLocalizableString("panelRemoveText")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isProgressTopShowing",{get:function(){return"carousel"==this.displayMode&&("top"===this.progressBarLocation||"topBottom"===this.progressBarLocation)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isProgressBottomShowing",{get:function(){return"carousel"==this.displayMode&&("bottom"===this.progressBarLocation||"topBottom"===this.progressBarLocation)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isPrevButtonVisible",{get:function(){return this.currentIndex>0},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isPrevButtonShowing",{get:function(){return this.isPrevButtonVisible},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isNextButtonVisible",{get:function(){return this.currentIndex>=0&&this.currentIndex<this.visiblePanelCount-1},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isNextButtonShowing",{get:function(){return this.isNextButtonVisible},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isRangeShowing",{get:function(){return this.showRangeInProgress&&this.currentIndex>=0&&this.visiblePanelCount>1},enumerable:!1,configurable:!0}),t.prototype.getElementsInDesign=function(e){return void 0===e&&(e=!1),e?[this.template]:this.templateElements},t.prototype.prepareValueForPanelCreating=function(){this.addingNewPanelsValue=this.value,this.isAddingNewPanels=!0,this.isNewPanelsValueChanged=!1},t.prototype.setValueAfterPanelsCreating=function(){this.isAddingNewPanels=!1,this.isNewPanelsValueChanged&&(this.isValueChangingInternally=!0,this.value=this.addingNewPanelsValue,this.isValueChangingInternally=!1)},t.prototype.getValueCore=function(){return this.isAddingNewPanels?this.addingNewPanelsValue:e.prototype.getValueCore.call(this)},t.prototype.setValueCore=function(t){this.isAddingNewPanels?(this.isNewPanelsValueChanged=!0,this.addingNewPanelsValue=t):e.prototype.setValueCore.call(this,t)},t.prototype.setIsMobile=function(t){e.prototype.setIsMobile.call(this,t),(this.panelsCore||[]).forEach((function(e){return e.getQuestions(!0).forEach((function(e){e.setIsMobile(t)}))}))},t.prototype.themeChanged=function(t){e.prototype.themeChanged.call(this,t),(this.panelsCore||[]).forEach((function(e){return e.getQuestions(!0).forEach((function(e){e.themeChanged(t)}))}))},Object.defineProperty(t.prototype,"panelCount",{get:function(){return!this.canBuildPanels||this.wasNotRenderedInSurvey?this.getPropertyValue("panelCount"):this.panelsCore.length},set:function(e){if(!(e<0)){if(!this.canBuildPanels||this.wasNotRenderedInSurvey)return this.setPropertyValue("panelCount",e),void this.updateFooterActions();if(e!=this.panelsCore.length&&!this.useTemplatePanel){this.updateBindings("panelCount",e),this.prepareValueForPanelCreating();for(var t=this.panelCount;t<e;t++){var n=this.createNewPanel();this.panelsCore.push(n),"list"==this.displayMode&&"default"!=this.panelsState&&("expanded"===this.panelsState?n.expand():n.title&&n.collapse())}e<this.panelCount&&this.panelsCore.splice(e,this.panelCount-e),this.disablePanelsAnimations(),this.setValueAfterPanelsCreating(),this.setValueBasedOnPanelCount(),this.reRunCondition(),this.updateFooterActions(),this.fireCallback(this.panelCountChangedCallback),this.enablePanelsAnimations()}}},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"visiblePanelCount",{get:function(){return this.visiblePanels.length},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"panelsState",{get:function(){return this.getPropertyValue("panelsState")},set:function(e){this.setPropertyValue("panelsState",e)},enumerable:!1,configurable:!0}),t.prototype.setTemplatePanelSurveyImpl=function(){this.template.setSurveyImpl(this.useTemplatePanel?this.surveyImpl:new na(this))},t.prototype.setPanelsSurveyImpl=function(){for(var e=0;e<this.panelsCore.length;e++){var t=this.panelsCore[e];t!=this.template&&t.setSurveyImpl(t.data)}},t.prototype.setPanelsState=function(){if(!this.useTemplatePanel&&"list"==this.displayMode&&this.templateTitle)for(var e=0;e<this.panelsCore.length;e++){var t=this.panelsState;"firstExpanded"===t&&(t=0===e?"expanded":"collapsed"),this.panelsCore[e].state=t}},t.prototype.setValueBasedOnPanelCount=function(){var e=this.value;if(e&&Array.isArray(e)||(e=[]),e.length!=this.panelCount){for(var t=e.length;t<this.panelCount;t++){var n=this.panels[t].getValue(),o=s.isValueEmpty(n)?{}:n;e.push(o)}e.length>this.panelCount&&e.splice(this.panelCount,e.length-this.panelCount),this.isValueChangingInternally=!0,this.value=e,this.isValueChangingInternally=!1}},Object.defineProperty(t.prototype,"minPanelCount",{get:function(){return this.getPropertyValue("minPanelCount")},set:function(e){e<0&&(e=0),this.setPropertyValue("minPanelCount",e)},enumerable:!1,configurable:!0}),t.prototype.onMinPanelCountChanged=function(){var e=this.minPanelCount;e>this.maxPanelCount&&(this.maxPanelCount=e),this.panelCount<e&&(this.panelCount=e)},Object.defineProperty(t.prototype,"maxPanelCount",{get:function(){return this.getPropertyValue("maxPanelCount")},set:function(e){e<=0||(e>Xt.panel.maxPanelCount&&(e=Xt.panel.maxPanelCount),this.setPropertyValue("maxPanelCount",e),this.updateFooterActions())},enumerable:!1,configurable:!0}),t.prototype.onMaxPanelCountChanged=function(){var e=this.maxPanelCount;e<this.minPanelCount&&(this.minPanelCount=e),this.panelCount>e&&(this.panelCount=e),this.updateFooterActions()},Object.defineProperty(t.prototype,"allowAddPanel",{get:function(){return this.getPropertyValue("allowAddPanel")},set:function(e){this.setPropertyValue("allowAddPanel",e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"addButtonId",{get:function(){return this.id+"addPanel"},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"newPanelPosition",{get:function(){return this.getPropertyValue("newPanelPosition")},set:function(e){this.setPropertyValue("newPanelPosition",e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"allowRemovePanel",{get:function(){return this.getPropertyValue("allowRemovePanel")},set:function(e){this.setPropertyValue("allowRemovePanel",e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"templateTitleLocation",{get:function(){return this.getPropertyValue("templateTitleLocation")},set:function(e){this.setPropertyValue("templateTitleLocation",e.toLowerCase())},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"templateErrorLocation",{get:function(){return this.getPropertyValue("templateErrorLocation")},set:function(e){this.setPropertyValue("templateErrorLocation",e.toLowerCase())},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"showQuestionNumbers",{get:function(){return this.getPropertyValue("showQuestionNumbers")},set:function(e){this.setPropertyValue("showQuestionNumbers",e),!this.isLoadingFromJson&&this.survey&&this.survey.questionVisibilityChanged(this,this.visible,!0)},enumerable:!1,configurable:!0}),t.prototype.notifySurveyOnChildrenVisibilityChanged=function(){return"onSurvey"===this.showQuestionNumbers},Object.defineProperty(t.prototype,"panelRemoveButtonLocation",{get:function(){return this.getPropertyValue("panelRemoveButtonLocation")},set:function(e){this.setPropertyValue("panelRemoveButtonLocation",e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"showRangeInProgress",{get:function(){return this.showProgressBar},set:function(e){this.showProgressBar=e},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"renderMode",{get:function(){var e=this.displayMode;if("carousel"==e){var t=this.progressBarLocation;if("top"==t)return"progressTop";if("bottom"==t)return"progressBottom";if("topBottom"==t)return"progressTopBottom"}return e},set:function(e){(e||"").startsWith("progress")?("progressTop"==e?this.progressBarLocation="top":"progressBottom"==e?this.progressBarLocation="bottom":"progressTopBottom"==e&&(this.progressBarLocation="topBottom"),this.displayMode="carousel"):this.displayMode=e},enumerable:!1,configurable:!0}),t.prototype.updatePanelView=function(){this.blockAnimations(),this.updateRenderedPanels(),this.releaseAnimations(),this.updatePanelsAnimation()},Object.defineProperty(t.prototype,"tabAlign",{get:function(){return this.getPropertyValue("tabAlign")},set:function(e){this.setPropertyValue("tabAlign",e),this.isRenderModeTab&&(this.tabbedMenu.containerCss=this.getTabbedMenuCss())},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isRenderModeList",{get:function(){return"list"===this.displayMode},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isRenderModeTab",{get:function(){return"tab"===this.displayMode},enumerable:!1,configurable:!0}),t.prototype.setVisibleIndex=function(t){if(!this.isVisible)return 0;for(var n="onSurvey"===this.showQuestionNumbers,o=n?t:0,i=this.isDesignMode?[this.template]:this.visiblePanelsCore,r=0;r<i.length;r++){var s=this.setPanelVisibleIndex(i[r],o,"off"!=this.showQuestionNumbers);n&&(o+=s)}return e.prototype.setVisibleIndex.call(this,n?-1:t),n?o-t:1},t.prototype.setPanelVisibleIndex=function(e,t,n){return n?e.setVisibleIndex(t):(e.setVisibleIndex(-1),0)},Object.defineProperty(t.prototype,"canAddPanel",{get:function(){return!this.isDesignMode&&(!(this.isDefaultV2Theme&&!this.legacyNavigation&&!this.isRenderModeList&&this.currentIndex<this.visiblePanelCount-1&&"next"!==this.newPanelPosition)&&(this.allowAddPanel&&!this.isReadOnly&&this.panelCount<this.maxPanelCount))},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"canRemovePanel",{get:function(){return!this.isDesignMode&&(this.allowRemovePanel&&!this.isReadOnly&&this.panelCount>this.minPanelCount)},enumerable:!1,configurable:!0}),t.prototype.rebuildPanels=function(){var e;if(!this.isLoadingFromJson){this.prepareValueForPanelCreating();var t=[];if(this.useTemplatePanel)new ta(this,this.template),t.push(this.template);else for(var n=0;n<this.panelCount;n++)this.createNewPanel(),t.push(this.createNewPanel());(e=this.panelsCore).splice.apply(e,Xs([0,this.panelsCore.length],t)),this.setValueAfterPanelsCreating(),this.setPanelsState(),this.reRunCondition(),this.updateFooterActions(),this.fireCallback(this.panelCountChangedCallback),this.updateTabToolbar()}},Object.defineProperty(t.prototype,"defaultPanelValue",{get:function(){return this.getPropertyValue("defaultPanelValue")},set:function(e){this.setPropertyValue("defaultPanelValue",e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"defaultValueFromLastPanel",{get:function(){return this.getPropertyValue("defaultValueFromLastPanel")},set:function(e){this.setPropertyValue("defaultValueFromLastPanel",e)},enumerable:!1,configurable:!0}),t.prototype.isDefaultValueEmpty=function(){return e.prototype.isDefaultValueEmpty.call(this)&&this.isValueEmpty(this.defaultPanelValue)},t.prototype.setDefaultValue=function(){if(!this.isValueEmpty(this.defaultPanelValue)&&this.isValueEmpty(this.defaultValue)){if(this.isEmpty()&&0!=this.panelCount){for(var t=[],n=0;n<this.panelCount;n++)t.push(this.defaultPanelValue);this.value=t}}else e.prototype.setDefaultValue.call(this)},Object.defineProperty(t.prototype,"isValueArray",{get:function(){return!0},enumerable:!1,configurable:!0}),t.prototype.isEmpty=function(){var e=this.value;if(!e||!Array.isArray(e))return!0;for(var t=0;t<e.length;t++)if(!this.isRowEmpty(e[t]))return!1;return!0},t.prototype.getProgressInfo=function(){return ft.getProgressInfoByElements(this.visiblePanelsCore,this.isRequired)},t.prototype.isRowEmpty=function(e){for(var t in e)if(e.hasOwnProperty(t))return!1;return!0},t.prototype.addPanelUI=function(){if(!this.canAddPanel)return null;if(!this.canLeaveCurrentPanel())return null;var e=this.addPanel();return"list"===this.displayMode&&"default"!==this.panelsState&&e.expand(),this.focusNewPanelCallback=function(){e.focusFirstQuestion()},this.isPanelsAnimationRunning||this.focusNewPanel(),e},t.prototype.focusNewPanel=function(){this.focusNewPanelCallback&&(this.focusNewPanelCallback(),this.focusNewPanelCallback=void 0)},t.prototype.addPanel=function(e){var t=this.currentIndex;return void 0===e&&(e=t<0?this.panelCount:t+1),(e<0||e>this.panelCount)&&(e=this.panelCount),this.updateValueOnAddingPanel(t<0?this.panelCount-1:t,e),this.isRenderModeList||(this.currentIndex=e),this.notifyOnPanelAddedRemoved(!0,e),this.panelsCore[e]},t.prototype.updateValueOnAddingPanel=function(e,t){this.panelCount++;var n=this.value;if(Array.isArray(n)&&n.length===this.panelCount){var o=!1,i=this.panelCount-1;if(t<i){o=!0;var r=n[i];n.splice(i,1),n.splice(t,0,r)}if(this.isValueEmpty(this.defaultPanelValue)||(o=!0,this.copyValue(n[t],this.defaultPanelValue)),this.defaultValueFromLastPanel&&n.length>1){var s=e>-1&&e<=i?e:i;o=!0,this.copyValue(n[t],n[s])}o&&(this.value=n)}},t.prototype.canLeaveCurrentPanel=function(){return!("list"!==this.displayMode&&this.currentPanel&&this.currentPanel.hasErrors(!0,!0))},t.prototype.copyValue=function(e,t){for(var n in t)e[n]=t[n]},t.prototype.removePanelUI=function(e){var t=this,n=this.getVisualPanelIndex(e);if(!(n<0||n>=this.visiblePanelCount)&&this.canRemovePanel){var o=function(){var e;t.removePanel(n);var o=t.visiblePanelCount,i=n>=o?o-1:n,r=0===o?t.addButtonId:i>-1?t.getPanelRemoveButtonId(t.visiblePanels[i]):"";r&&ft.FocusElement(r,!0,null===(e=t.survey)||void 0===e?void 0:e.rootElement)};this.isRequireConfirmOnDelete(e)?bt({message:this.confirmDeleteText,funcOnYes:function(){o()},locale:this.getLocale(),rootElement:this.survey.rootElement,cssClass:this.cssClasses.confirmDialog}):o()}},t.prototype.getPanelRemoveButtonId=function(e){return e.id+"_remove_button"},t.prototype.isRequireConfirmOnDelete=function(e){if(!this.confirmDelete)return!1;var t=this.getVisualPanelIndex(e);if(t<0||t>=this.visiblePanelCount)return!1;var n=this.visiblePanelsCore[t].getValue();return!this.isValueEmpty(n)&&(this.isValueEmpty(this.defaultPanelValue)||!this.isTwoValueEquals(n,this.defaultPanelValue))},t.prototype.goToNextPanel=function(){return!(this.currentIndex<0)&&(!!this.canLeaveCurrentPanel()&&(this.currentIndex++,!0))},t.prototype.goToPrevPanel=function(){this.currentIndex<0||this.currentIndex--},t.prototype.removePanel=function(e){var t=this.getVisualPanelIndex(e);if(!(t<0||t>=this.visiblePanelCount)){this.removedPanelIndex=t;var n=this.visiblePanelsCore[t],o=this.panelsCore.indexOf(n);if(!(o<0))if(!this.survey||this.survey.dynamicPanelRemoving(this,o,n))this.panelsCore.splice(o,1),this.updateBindings("panelCount",this.panelCount),!(e=this.value)||!Array.isArray(e)||o>=e.length?this.updateFooterActions():(this.isValueChangingInternally=!0,e.splice(o,1),this.value=e,this.updateFooterActions(),this.fireCallback(this.panelCountChangedCallback),this.notifyOnPanelAddedRemoved(!1,o,n),this.isValueChangingInternally=!1)}},t.prototype.notifyOnPanelAddedRemoved=function(e,t,n){if(n||(n=this.panelsCore[t]),this.survey){var o="onSurvey"===this.showQuestionNumbers;e?this.survey.dynamicPanelAdded(this,t,n,o):this.survey.dynamicPanelRemoved(this,t,n,o)}e&&n&&"onPanel"===this.showQuestionNumbers&&n.setVisibleIndex(0)},t.prototype.getVisualPanelIndex=function(e){if(s.isNumber(e))return e;for(var t=this.visiblePanelsCore,n=0;n<t.length;n++)if(t[n]===e||t[n].data===e)return n;return-1},t.prototype.getPanelVisibleIndexById=function(e){for(var t=this.visiblePanelsCore,n=0;n<t.length;n++)if(t[n].id===e)return n;return-1},t.prototype.locStrsChanged=function(){e.prototype.locStrsChanged.call(this);for(var t=this.panelsCore,n=0;n<t.length;n++)t[n].locStrsChanged();this.tabbedMenu&&this.tabbedMenu.locStrsChanged()},t.prototype.clearIncorrectValues=function(){for(var e=0;e<this.panelsCore.length;e++)this.clearIncorrectValuesInPanel(e)},t.prototype.clearErrors=function(){e.prototype.clearErrors.call(this);for(var t=0;t<this.panelsCore.length;t++)this.panelsCore[t].clearErrors()},t.prototype.getQuestionFromArray=function(e,t){return t<0||t>=this.panelsCore.length?null:this.panelsCore[t].getQuestionByName(e)},t.prototype.clearIncorrectValuesInPanel=function(e){var t=this.panelsCore[e];t.clearIncorrectValues();var n=this.value,o=n&&e<n.length?n[e]:null;if(o){var i=!1;for(var r in o){if(!this.getSharedQuestionFromArray(r,e))t.getQuestionByName(r)||this.iscorrectValueWithPostPrefix(t,r,Xt.commentSuffix)||this.iscorrectValueWithPostPrefix(t,r,Xt.matrix.totalsSuffix)||(delete o[r],i=!0)}i&&(n[e]=o,this.value=n)}},t.prototype.iscorrectValueWithPostPrefix=function(e,t,n){return t.indexOf(n)===t.length-n.length&&!!e.getQuestionByName(t.substring(0,t.indexOf(n)))},t.prototype.getSharedQuestionFromArray=function(e,t){return this.survey&&this.valueName?this.survey.getQuestionByValueNameFromArray(this.valueName,e,t):null},t.prototype.addConditionObjectsByContext=function(e,t){for(var n=(null==t?void 0:t.isValidator)?t.errorOwner:t,o=!!t&&(!0===t||this.template.questions.indexOf(n)>-1),i=new Array,r=this.template.questions,s=0;s<r.length;s++)r[s].addConditionObjectsByContext(i,t);for(var a=0;a<Xt.panel.maxPanelCountInCondition;a++){var l="["+a+"].",u=this.getValueName()+l,c=this.processedTitle+l;for(s=0;s<i.length;s++)i[s].context?e.push(i[s]):e.push({name:u+i[s].name,text:c+i[s].text,question:i[s].question})}if(o)for(u=!0===t?this.getValueName()+".":"",c=!0===t?this.processedTitle+".":"",s=0;s<i.length;s++)if(i[s].question!=t){var p={name:u+ta.ItemVariableName+"."+i[s].name,text:c+ta.ItemVariableName+"."+i[s].text,question:i[s].question};p.context=this,e.push(p)}},t.prototype.collectNestedQuestionsCore=function(e,t,n){n&&e.push(this);var o=t?this.visiblePanelsCore:this.panelsCore;Array.isArray(o)&&o.forEach((function(o){o.questions.forEach((function(o){return o.collectNestedQuestions(e,t,n)}))}))},t.prototype.getConditionJson=function(t,n){if(void 0===t&&(t=null),void 0===n&&(n=null),!n)return e.prototype.getConditionJson.call(this,t);var o=n,i=n.indexOf(".");i>-1&&(o=n.substring(0,i),n=n.substring(i+1));var r=this.template.getQuestionByName(o);return r?r.getConditionJson(t,n):null},t.prototype.onReadOnlyChanged=function(){var t=this.isReadOnly;this.template.readOnly=t;for(var n=0;n<this.panelsCore.length;n++)this.panelsCore[n].readOnly=t;this.updateNoEntriesTextDefaultLoc(),this.updateFooterActions(),e.prototype.onReadOnlyChanged.call(this)},t.prototype.updateNoEntriesTextDefaultLoc=function(){var e=this.getLocalizableString("noEntriesText");e&&(e.localizationName=this.isReadOnly||!this.allowAddPanel?"noEntriesReadonlyText":"noEntriesText")},t.prototype.onSurveyLoad=function(){this.template.readOnly=this.isReadOnly,this.template.onSurveyLoad(),this.panelCount<this.minPanelCount&&(this.panelCount=this.minPanelCount),this.panelCount>this.maxPanelCount&&(this.panelCount=this.maxPanelCount),this.buildPanelsFirstTime(),e.prototype.onSurveyLoad.call(this)},t.prototype.buildPanelsFirstTime=function(e){if(void 0===e&&(e=!1),!this.hasPanelBuildFirstTime&&(e||!this.wasNotRenderedInSurvey)){if(this.blockAnimations(),this.hasPanelBuildFirstTime=!0,this.isBuildingPanelsFirstTime=!0,this.getPropertyValue("panelCount")>0&&(this.panelCount=this.getPropertyValue("panelCount")),this.useTemplatePanel&&this.rebuildPanels(),this.setPanelsSurveyImpl(),this.setPanelsState(),this.assignOnPropertyChangedToTemplate(),this.data&&this.isValueChangedWithoutPanels&&(this.isValueChangedWithoutPanels=!1,this.runTriggersOnBuildPanelsFirstTime()),this.survey)for(var t=0;t<this.panelCount;t++)this.notifyOnPanelAddedRemoved(!0,t);this.updateIsReady(),this.showAddPanelButton||this.updateNoEntriesTextDefaultLoc(),this.updateFooterActions(),this.isBuildingPanelsFirstTime=!1,this.releaseAnimations()}},t.prototype.runTriggersOnBuildPanelsFirstTime=function(){var e=this;this.value;this.visiblePanelsCore.forEach((function(t){var n=e.getPanelItemData(t.data);if(!s.isValueEmpty(n)){var o=s.createCopyWithPrefix(n,ta.ItemVariableName+".");t.questions.forEach((function(e){return e.runTriggers("",void 0,o)}))}}))},Object.defineProperty(t.prototype,"showAddPanelButton",{get:function(){return this.allowAddPanel&&!this.isReadOnly},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"wasNotRenderedInSurvey",{get:function(){return!this.hasPanelBuildFirstTime&&!this.wasRendered&&!!this.survey},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"canBuildPanels",{get:function(){return!this.isLoadingFromJson&&!this.useTemplatePanel},enumerable:!1,configurable:!0}),t.prototype.onFirstRenderingCore=function(){e.prototype.onFirstRenderingCore.call(this),this.buildPanelsFirstTime(),this.template.onFirstRendering();for(var t=0;t<this.panelsCore.length;t++)this.panelsCore[t].onFirstRendering()},t.prototype.localeChanged=function(){e.prototype.localeChanged.call(this);for(var t=0;t<this.panelsCore.length;t++)this.panelsCore[t].localeChanged()},t.prototype.runCondition=function(t,n){e.prototype.runCondition.call(this,t,n),this.runPanelsCondition(this.panelsCore,t,n)},t.prototype.runTriggers=function(t,n,o){e.prototype.runTriggers.call(this,t,n,o),this.visiblePanelsCore.forEach((function(e){e.questions.forEach((function(e){return e.runTriggers(t,n,o)}))}))},t.prototype.reRunCondition=function(){this.data&&this.runCondition(this.getDataFilteredValues(),this.getDataFilteredProperties())},t.prototype.runPanelsCondition=function(e,t,n){var o={};t&&t instanceof Object&&(o=JSON.parse(JSON.stringify(t))),this.parentQuestion&&this.parent&&(o[ta.ParentItemVariableName]=this.parent.getValue()),this.isValueChangingInternally=!0;for(var i=0,r=0;r<e.length;r++){var a=e[r],l=this.getPanelItemData(a.data),u=s.createCopy(o),c=ta.ItemVariableName;u[c]=l,u[ta.IndexVariableName.toLowerCase()]=r,u[ta.VisibleIndexVariableName.toLowerCase()]=i;var p=s.createCopy(n);p[c]=a,a.runCondition(u,p),a.isVisible&&i++}this.isValueChangingInternally=!1},t.prototype.onAnyValueChanged=function(t,n){e.prototype.onAnyValueChanged.call(this,t,n),this.hasPanelBuildFirstTime||t!==this.getValueName()||(this.isValueChangedWithoutPanels=!0);for(var o=0;o<this.panelsCore.length;o++)this.panelsCore[o].onAnyValueChanged(t,n),this.panelsCore[o].onAnyValueChanged(ta.ItemVariableName,"")},t.prototype.hasKeysDuplicated=function(e,t){void 0===t&&(t=null);for(var n,o=[],i=0;i<this.panelsCore.length;i++)n=this.isValueDuplicated(this.panelsCore[i],o,t,e)||n;return n},t.prototype.updatePanelsContainsErrors=function(){for(var e=this.changingValueQuestion.parent;e;)e.updateContainsErrors(),e=e.parent;this.updateContainsErrors()},t.prototype.hasErrors=function(t,n){if(void 0===t&&(t=!0),void 0===n&&(n=null),this.isValueChangingInternally||this.isBuildingPanelsFirstTime)return!1;var o=!1;if(this.changingValueQuestion){o=this.changingValueQuestion.hasErrors(t,n);o=this.hasKeysDuplicated(t,n)||o,this.updatePanelsContainsErrors()}else o=this.hasErrorInPanels(t,n);return e.prototype.hasErrors.call(this,t,n)||o},t.prototype.getContainsErrors=function(){var t=e.prototype.getContainsErrors.call(this);if(t)return t;for(var n=this.panelsCore,o=0;o<n.length;o++)if(n[o].containsErrors)return!0;return!1},t.prototype.getIsAnswered=function(){if(!e.prototype.getIsAnswered.call(this))return!1;for(var t=this.visiblePanelsCore,n=0;n<t.length;n++){var o=[];t[n].addQuestionsToList(o,!0);for(var i=0;i<o.length;i++)if(!o[i].isAnswered)return!1}return!0},t.prototype.clearValueOnHidding=function(t){if(!t){if(this.survey&&"none"===this.survey.getQuestionClearIfInvisible("onHidden"))return;this.clearValueInPanelsIfInvisible("onHiddenContainer")}e.prototype.clearValueOnHidding.call(this,t)},t.prototype.clearValueIfInvisible=function(t){void 0===t&&(t="onHidden");var n="onHidden"===t?"onHiddenContainer":t;this.clearValueInPanelsIfInvisible(n),e.prototype.clearValueIfInvisible.call(this,t)},t.prototype.clearValueInPanelsIfInvisible=function(e){for(var t=0;t<this.panelsCore.length;t++){var n=this.panelsCore[t],o=n.questions;this.isSetPanelItemData={};for(var i=0;i<o.length;i++){var r=o[i];r.visible&&!n.isVisible||(r.clearValueIfInvisible(e),this.isSetPanelItemData[r.getValueName()]=this.maxCheckCount+1)}}this.isSetPanelItemData={}},t.prototype.getIsRunningValidators=function(){if(e.prototype.getIsRunningValidators.call(this))return!0;for(var t=0;t<this.panelsCore.length;t++)for(var n=this.panelsCore[t].questions,o=0;o<n.length;o++)if(n[o].isRunningValidators)return!0;return!1},t.prototype.getAllErrors=function(){for(var t=e.prototype.getAllErrors.call(this),n=this.visiblePanelsCore,o=0;o<n.length;o++)for(var i=n[o].questions,r=0;r<i.length;r++){var s=i[r].getAllErrors();s&&s.length>0&&(t=t.concat(s))}return t},t.prototype.getDisplayValueCore=function(e,t){var n=this.getUnbindValue(t);if(!n||!Array.isArray(n))return n;for(var o=0;o<this.panelsCore.length&&o<n.length;o++){var i=n[o];i&&(n[o]=this.getPanelDisplayValue(o,i,e))}return n},t.prototype.getPanelDisplayValue=function(e,t,n){if(!t)return t;for(var o=this.panelsCore[e],i=Object.keys(t),r=0;r<i.length;r++){var s=i[r],a=o.getQuestionByValueName(s);if(a||(a=this.getSharedQuestionFromArray(s,e)),a){var l=a.getDisplayValue(n,t[s]);t[s]=l,n&&a.title&&a.title!==s&&(t[a.title]=l,delete t[s])}}return t},t.prototype.hasErrorInPanels=function(e,t){for(var n=!1,o=this.visiblePanels,i=[],r=0;r<o.length;r++)this.setOnCompleteAsyncInPanel(o[r]);for(var s=!!t&&t.focusOnFirstError,a=0;a<o.length;a++){var l=o[a].hasErrors(e,s,t);l=this.isValueDuplicated(o[a],i,t,e)||l,!this.isRenderModeList&&l&&!n&&s&&(this.currentIndex=a),n=l||n}return n},t.prototype.setOnCompleteAsyncInPanel=function(e){for(var t=this,n=e.questions,o=0;o<n.length;o++)n[o].onCompletedAsyncValidators=function(e){t.raiseOnCompletedAsyncValidators()}},t.prototype.isValueDuplicated=function(e,t,n,o){if(!this.keyName)return!1;var i=e.getQuestionByValueName(this.keyName);if(!i||i.isEmpty())return!1;var r=i.value;this.changingValueQuestion&&i!=this.changingValueQuestion&&i.hasErrors(o,n);for(var s=0;s<t.length;s++)if(r==t[s])return o&&i.addError(new dn(this.keyDuplicationError,this)),n&&!n.firstErrorQuestion&&(n.firstErrorQuestion=i),!0;return t.push(r),!1},t.prototype.getPanelActions=function(e){var t=this,n=e.footerActions;return"right"!==this.panelRemoveButtonLocation&&n.push(new Xe({id:"remove-panel-"+e.id,component:"sv-paneldynamic-remove-btn",visible:new we((function(){return[t.canRemovePanel,"collapsed"!==e.state,"right"!==t.panelRemoveButtonLocation].every((function(e){return!0===e}))})),data:{question:this,panel:e}})),this.survey&&(n=this.survey.getUpdatedPanelFooterActions(e,n,this)),n},t.prototype.createNewPanel=function(){var e=this,t=this.createAndSetupNewPanelObject(),n=this.template.toJSON();(new A).toObject(n,t),t.renderWidth="100%",t.updateCustomWidgets(),new ta(this,t),this.isDesignMode||this.isReadOnly||this.isValueEmpty(t.getValue())||this.runPanelsCondition([t],this.getDataFilteredValues(),this.getDataFilteredProperties());for(var o=t.questions,i=0;i<o.length;i++)o[i].setParentQuestion(this);return this.wasRendered&&(t.onFirstRendering(),t.locStrsChanged()),t.onGetFooterActionsCallback=function(){return e.getPanelActions(t)},t.onGetFooterToolbarCssCallback=function(){return e.cssClasses.panelFooter},t.registerPropertyChangedHandlers(["visible"],(function(){t.visible?e.onPanelAdded(t):e.onPanelRemoved(t),e.updateFooterActions()})),t},t.prototype.createAndSetupNewPanelObject=function(){var e=this,t=this.createNewPanelObject();return t.isInteractiveDesignElement=!1,t.setParentQuestion(this),t.onGetQuestionTitleLocation=function(){return e.getTemplateQuestionTitleLocation()},t},t.prototype.getTemplateQuestionTitleLocation=function(){return"default"!=this.templateTitleLocation?this.templateTitleLocation:this.getTitleLocationCore()},t.prototype.getChildErrorLocation=function(t){return"default"!==this.templateErrorLocation?this.templateErrorLocation:e.prototype.getChildErrorLocation.call(this,t)},t.prototype.createNewPanelObject=function(){return D.createClass("panel")},t.prototype.setPanelCountBasedOnValue=function(){if(!this.isValueChangingInternally&&!this.useTemplatePanel){var e=this.value,t=e&&Array.isArray(e)?e.length:0;0==t&&this.getPropertyValue("panelCount")>0&&(t=this.getPropertyValue("panelCount")),this.settingPanelCountBasedOnValue=!0,this.panelCount=t,this.settingPanelCountBasedOnValue=!1}},t.prototype.setQuestionValue=function(t){if(!this.settingPanelCountBasedOnValue){e.prototype.setQuestionValue.call(this,t,!1),this.setPanelCountBasedOnValue();for(var n=0;n<this.panelsCore.length;n++)this.panelUpdateValueFromSurvey(this.panelsCore[n]);this.updateIsAnswered()}},t.prototype.onSurveyValueChanged=function(t){if(void 0!==t||!this.isAllPanelsEmpty()){e.prototype.onSurveyValueChanged.call(this,t);for(var n=0;n<this.panelsCore.length;n++)this.panelSurveyValueChanged(this.panelsCore[n]);void 0===t&&this.setValueBasedOnPanelCount(),this.updateIsReady()}},t.prototype.isAllPanelsEmpty=function(){for(var e=0;e<this.panelsCore.length;e++)if(!s.isValueEmpty(this.panelsCore[e].getValue()))return!1;return!0},t.prototype.panelUpdateValueFromSurvey=function(e){for(var t=e.questions,n=this.getPanelItemData(e.data),o=0;o<t.length;o++){var i=t[o];i.updateValueFromSurvey(n[i.getValueName()]),i.updateCommentFromSurvey(n[i.getValueName()+Xt.commentSuffix]),i.initDataUI()}},t.prototype.panelSurveyValueChanged=function(e){for(var t=e.questions,n=this.getPanelItemData(e.data),o=0;o<t.length;o++){var i=t[o];i.onSurveyValueChanged(n[i.getValueName()])}},t.prototype.onSetData=function(){e.prototype.onSetData.call(this),!this.isLoadingFromJson&&this.useTemplatePanel&&(this.setTemplatePanelSurveyImpl(),this.rebuildPanels())},t.prototype.isNewValueCorrect=function(e){return Array.isArray(e)},t.prototype.getItemIndex=function(e){var t=this.items.indexOf(e);return t>-1?t:this.items.length},t.prototype.getVisibleItemIndex=function(e){for(var t=this.visiblePanelsCore,n=0;n<t.length;n++)if(t[n].data===e)return n;return t.length},t.prototype.getPanelItemData=function(e){var t=this.items,n=t.indexOf(e),o=this.value;return n<0&&Array.isArray(o)&&o.length>t.length&&(n=t.length),n<0||!o||!Array.isArray(o)||o.length<=n?{}:o[n]},t.prototype.setPanelItemData=function(e,t,n){if(!(this.isSetPanelItemData[t]>this.maxCheckCount)){this.isSetPanelItemData[t]||(this.isSetPanelItemData[t]=0),this.isSetPanelItemData[t]++;var o=this.items,i=o.indexOf(e);i<0&&(i=o.length);var r=this.getUnbindValue(this.value);if(r&&Array.isArray(r)||(r=[]),r.length<=i)for(var s=r.length;s<=i;s++)r.push({});r[i]||(r[i]={});var a=r[i][t];this.isValueEmpty(n)?delete r[i][t]:r[i][t]=n,i>=0&&i<this.panelsCore.length&&(this.changingValueQuestion=this.panelsCore[i].getQuestionByValueName(t));var l={panel:e.panel,name:t,panelIndex:i,panelData:r[i],value:n,oldValue:a};this.survey&&this.survey.dynamicPanelItemValueChanging(this,l),this.value=r,this.changingValueQuestion=null,this.survey&&this.survey.dynamicPanelItemValueChanged(this,l),this.isSetPanelItemData[t]--,this.isSetPanelItemData[t]-1&&delete this.isSetPanelItemData[t]}},t.prototype.getRootData=function(){return this.data},t.prototype.getPlainData=function(t){void 0===t&&(t={includeEmpty:!0});var n=e.prototype.getPlainData.call(this,t);if(n){n.isNode=!0;var o=Array.isArray(n.data)?[].concat(n.data):[];n.data=this.panels.map((function(e,n){var o={name:e.name||n,title:e.title||"Panel",value:e.getValue(),displayValue:e.getValue(),getString:function(e){return"object"==typeof e?JSON.stringify(e):e},isNode:!0,data:e.questions.map((function(e){return e.getPlainData(t)})).filter((function(e){return!!e}))};return(t.calculations||[]).forEach((function(t){o[t.propertyName]=e[t.propertyName]})),o})),n.data=n.data.concat(o)}return n},t.prototype.updateElementCss=function(t){e.prototype.updateElementCss.call(this,t);for(var n=0;n<this.panelsCore.length;n++){this.panelsCore[n].updateElementCss(t)}},Object.defineProperty(t.prototype,"progressText",{get:function(){var e=this.visiblePanelCount;return this.getLocalizationFormatString("panelDynamicProgressText",this.currentIndex+1,e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"progress",{get:function(){return(this.currentIndex+1)/this.visiblePanelCount*100+"%"},enumerable:!1,configurable:!0}),t.prototype.getRootCss=function(){return(new Ee).append(e.prototype.getRootCss.call(this)).append(this.cssClasses.empty,this.getShowNoEntriesPlaceholder()).toString()},Object.defineProperty(t.prototype,"cssHeader",{get:function(){var t=this.isRenderModeTab&&!!this.visiblePanelCount;return(new Ee).append(e.prototype.getCssHeader.call(this,this.cssClasses)).append(this.cssClasses.headerTab,this.hasTitleOnTop&&t).toString()},enumerable:!1,configurable:!0}),t.prototype.getTabsContainerCss=function(){return(new Ee).append(this.cssClasses.tabsContainer).append(this.cssClasses.tabsContainerWithHeader,this.hasTitleOnTop).toString()},t.prototype.getPanelWrapperCss=function(e){return(new Ee).append(this.cssClasses.panelWrapper,!e||e.visible).append(this.cssClasses.panelWrapperList,this.isRenderModeList).append(this.cssClasses.panelWrapperInRow,"right"===this.panelRemoveButtonLocation).toString()},t.prototype.getPanelRemoveButtonCss=function(){return(new Ee).append(this.cssClasses.button).append(this.cssClasses.buttonRemove).append(this.cssClasses.buttonRemoveRight,"right"===this.panelRemoveButtonLocation).toString()},t.prototype.getAddButtonCss=function(){return(new Ee).append(this.cssClasses.button).append(this.cssClasses.buttonAdd).append(this.cssClasses.buttonAdd+"--list-mode","list"===this.displayMode).toString()},t.prototype.getPrevButtonCss=function(){return(new Ee).append(this.cssClasses.buttonPrev).append(this.cssClasses.buttonPrevDisabled,!this.isPrevButtonVisible).toString()},t.prototype.getNextButtonCss=function(){return(new Ee).append(this.cssClasses.buttonNext).append(this.cssClasses.buttonNextDisabled,!this.isNextButtonVisible).toString()},Object.defineProperty(t.prototype,"noEntriesText",{get:function(){return this.getLocalizableStringText("noEntriesText")},set:function(e){this.setLocalizableStringText("noEntriesText",e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"locNoEntriesText",{get:function(){return this.getLocalizableString("noEntriesText")},enumerable:!1,configurable:!0}),t.prototype.getShowNoEntriesPlaceholder=function(){return!!this.cssClasses.noEntriesPlaceholder&&!this.isDesignMode&&0===this.visiblePanelCount},t.prototype.needResponsiveWidth=function(){var e=this.getPanel();return!(!e||!e.needResponsiveWidth())},Object.defineProperty(t.prototype,"hasTabbedMenu",{get:function(){return this.isRenderModeTab&&this.visiblePanels.length>0},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"tabbedMenu",{get:function(){return this.isRenderModeTab?(this.tabbedMenuValue||(this.tabbedMenuValue=new tt,this.tabbedMenuValue.dotsItem.popupModel.showPointer=!1,this.tabbedMenuValue.dotsItem.popupModel.verticalPosition="bottom",this.tabbedMenuValue.dotsItem.popupModel.horizontalPosition="center",this.updateElementCss(!1)),this.tabbedMenuValue):null},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"footerToolbar",{get:function(){return this.footerToolbarValue||this.initFooterToolbar(),this.footerToolbarValue},enumerable:!1,configurable:!0}),t.prototype.updateFooterActions=function(){this.updateFooterActionsCallback&&this.updateFooterActionsCallback()},t.prototype.initFooterToolbar=function(){var e=this;this.footerToolbarValue=this.createActionContainer();var t=[],n=new Xe({id:"sv-pd-prev-btn",title:this.panelPrevText,action:function(){e.goToPrevPanel()}}),o=new Xe({id:"sv-pd-next-btn",title:this.panelNextText,action:function(){e.goToNextPanel()}}),i=new Xe({id:"sv-pd-add-btn",component:"sv-paneldynamic-add-btn",data:{question:this}}),r=new Xe({id:"sv-prev-btn-icon",component:"sv-paneldynamic-prev-btn",data:{question:this}}),s=new Xe({id:"sv-pd-progress-text",component:"sv-paneldynamic-progress-text",data:{question:this}}),a=new Xe({id:"sv-pd-next-btn-icon",component:"sv-paneldynamic-next-btn",data:{question:this}});t.push(n,o,i,r,s,a),this.updateFooterActionsCallback=function(){var t=e.legacyNavigation,l=e.isRenderModeList,u=e.isMobile,c=!t&&!l;n.visible=c&&e.currentIndex>0,o.visible=c&&e.currentIndex<e.visiblePanelCount-1,o.needSpace=u&&o.visible&&n.visible,i.visible=e.canAddPanel,i.needSpace=e.isMobile&&!o.visible&&n.visible,s.visible=!e.isRenderModeList&&!u,s.needSpace=!t&&!e.isMobile;var p=t&&!l;r.visible=p,a.visible=p,r.needSpace=p},this.updateFooterActionsCallback(),this.footerToolbarValue.setItems(t)},t.prototype.createTabByPanel=function(e,t){var n=this;if(this.isRenderModeTab){var o=new yt(e,!0);o.onGetTextCallback=function(o){if(o||(o=n.locTabTitlePlaceholder.renderedHtml),!n.survey)return o;var i={title:o,panel:e,visiblePanelIndex:t};return n.survey.dynamicPanelGetTabTitle(n,i),i.title},o.sharedData=this.locTemplateTabTitle;var i=e.id,r=this.getPanelVisibleIndexById(i)===this.currentIndex;return new ea({id:this.id+"_tab_"+i,panelId:i,pressed:r,locTitle:o,disableHide:r,action:function(){n.currentIndex=n.getPanelVisibleIndexById(i)}})}},t.prototype.getTabbedMenuCss=function(e){var t=null!=e?e:this.cssClasses;return(new Ee).append(t.tabsRoot).append(t.tabsLeft,"left"===this.tabAlign).append(t.tabsRight,"right"===this.tabAlign).append(t.tabsCenter,"center"===this.tabAlign).toString()},t.prototype.updateTabToolbarItemsPressedState=function(){if(this.isRenderModeTab&&!(this.currentIndex<0||this.currentIndex>=this.visiblePanelCount)){var e=this.visiblePanelsCore[this.currentIndex];this.tabbedMenu.renderedActions.forEach((function(t){var n=t.panelId===e.id;t.pressed=n,t.disableHide=n,"popup"===t.mode&&t.disableHide&&t.raiseUpdate()}))}},t.prototype.updateTabToolbar=function(){var e=this;if(this.isRenderModeTab){for(var t=[],n=this.visiblePanelsCore,o=function(o){i.visiblePanelsCore.forEach((function(i){return t.push(e.createTabByPanel(n[o],o))}))},i=this,r=0;r<n.length;r++)o(r);this.tabbedMenu.setItems(t)}},t.prototype.addTabFromToolbar=function(e,t){if(this.isRenderModeTab){var n=this.createTabByPanel(e,t);this.tabbedMenu.actions.splice(t,0,n),this.updateTabToolbarItemsPressedState()}},t.prototype.removeTabFromToolbar=function(e){if(this.isRenderModeTab){var t=this.tabbedMenu.actions.find((function(t){return t.panelId==e.id}));t&&(this.tabbedMenu.actions.splice(this.tabbedMenu.actions.indexOf(t),1),this.updateTabToolbarItemsPressedState())}},Object.defineProperty(t.prototype,"showLegacyNavigation",{get:function(){return!this.isDefaultV2Theme},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"showNavigation",{get:function(){return(!this.isReadOnly||1!=this.visiblePanelCount)&&(this.visiblePanelCount>0&&!this.showLegacyNavigation&&!!this.cssClasses.footer)},enumerable:!1,configurable:!0}),t.prototype.showSeparator=function(e){return this.isRenderModeList&&e<this.renderedPanels.length-1},t.prototype.calcCssClasses=function(t){var n=e.prototype.calcCssClasses.call(this,t),o=this.tabbedMenu;return o&&(o.containerCss=this.getTabbedMenuCss(n),o.cssClasses=n.tabs,o.dotsItem.cssClasses=n.tabs,o.dotsItem.popupModel.contentComponentData.model.cssClasses=t.list),n},t.prototype.onMobileChanged=function(){e.prototype.onMobileChanged.call(this),this.updateFooterActions()},t.maxCheckCount=3,Ys([b({})],t.prototype,"_renderedPanels",void 0),Ys([m({onSet:function(e,t){t.fireCallback(t.renderModeChangedCallback),t.updatePanelView()}})],t.prototype,"displayMode",void 0),Ys([m({onSet:function(e,t){t.fireCallback(t.currentIndexChangedCallback)}})],t.prototype,"showProgressBar",void 0),Ys([m({onSet:function(e,t){}})],t.prototype,"progressBarLocation",void 0),Ys([m({defaultValue:!1,onSet:function(e,t){t.updateFooterActions()}})],t.prototype,"legacyNavigation",void 0),t}(An);D.addClass("paneldynamic",[{name:"showCommentArea:switch",layout:"row",visible:!0,category:"general"},{name:"templateElements",alternativeName:"questions",baseClassName:"question",visible:!1,isLightSerializable:!1},{name:"templateTitle:text",serializationProperty:"locTemplateTitle"},{name:"templateTabTitle",serializationProperty:"locTemplateTabTitle",visibleIf:function(e){return"tab"===e.displayMode}},{name:"tabTitlePlaceholder",serializationProperty:"locTabTitlePlaceholder",visibleIf:function(e){return"tab"===e.displayMode}},{name:"templateDescription:text",serializationProperty:"locTemplateDescription"},{name:"minWidth",defaultFunc:function(){return"auto"}},{name:"noEntriesText:text",serializationProperty:"locNoEntriesText"},{name:"allowAddPanel:boolean",default:!0},{name:"allowRemovePanel:boolean",default:!0},{name:"newPanelPosition",choices:["next","last"],default:"last",category:"layout"},{name:"panelCount:number",isBindable:!0,default:0,choices:[0,1,2,3,4,5,6,7,8,9,10]},{name:"minPanelCount:number",default:0,minValue:0},{name:"maxPanelCount:number",defaultFunc:function(){return Xt.panel.maxPanelCount}},"defaultPanelValue:panelvalue","defaultValueFromLastPanel:boolean",{name:"panelsState",default:"default",choices:["default","collapsed","expanded","firstExpanded"],visibleIf:function(e){return"list"===e.displayMode}},{name:"keyName"},{name:"keyDuplicationError",serializationProperty:"locKeyDuplicationError"},{name:"confirmDelete:boolean"},{name:"confirmDeleteText",serializationProperty:"locConfirmDeleteText",visibleIf:function(e){return e.confirmDelete}},{name:"panelAddText",serializationProperty:"locPanelAddText",visibleIf:function(e){return e.allowAddPanel}},{name:"panelRemoveText",serializationProperty:"locPanelRemoveText",visibleIf:function(e){return e.allowRemovePanel}},{name:"panelPrevText",serializationProperty:"locPanelPrevText",visibleIf:function(e){return"list"!==e.displayMode}},{name:"panelNextText",serializationProperty:"locPanelNextText",visibleIf:function(e){return"list"!==e.displayMode}},{name:"showQuestionNumbers",default:"off",choices:["off","onPanel","onSurvey"]},{name:"renderMode",visible:!1,isSerializable:!1},{name:"displayMode",default:"list",choices:["list","carousel","tab"]},{name:"showProgressBar:boolean",alternativeName:"showRangeInProgress",default:!0,visibleIf:function(e){return"carousel"===e.displayMode}},{name:"progressBarLocation",default:"top",choices:["top","bottom","topBottom"],visibleIf:function(e){return e.showProgressBar}},{name:"tabAlign",default:"center",choices:["left","center","right"],visibleIf:function(e){return"tab"===e.displayMode}},{name:"templateTitleLocation",default:"default",choices:["default","top","bottom","left"]},{name:"templateErrorLocation",default:"default",choices:["default","top","bottom"]},{name:"templateVisibleIf:expression",category:"logic"},{name:"panelRemoveButtonLocation",default:"bottom",choices:["bottom","right"],visibleIf:function(e){return e.allowRemovePanel}}],(function(){return new oa("")}),"question"),ao.Instance.registerQuestion("paneldynamic",(function(e){return new oa(e)}));var ia=function(){function e(){}return e.getProgressTextInBarCss=function(e){return(new Ee).append(e.progressText).append(e.progressTextInBar).toString()},e.getProgressTextUnderBarCss=function(e){return(new Ee).append(e.progressText).append(e.progressTextUnderBar).toString()},e}(),ra=function(){var e=function(t,n){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(t,n)};return function(t,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function o(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(o.prototype=n.prototype,new o)}}(),sa=function(e){function t(){var n=e.call(this)||this;return n.idValue=t.idCounter++,n.registerPropertyChangedHandlers(["operator","value","name"],(function(){n.oldPropertiesChanged()})),n.registerPropertyChangedHandlers(["expression"],(function(){n.onExpressionChanged()})),n}return ra(t,e),Object.defineProperty(t,"operators",{get:function(){return null!=t.operatorsValue||(t.operatorsValue={empty:function(e,t){return!e},notempty:function(e,t){return!!e},equal:function(e,t){return e==t},notequal:function(e,t){return e!=t},contains:function(e,t){return e&&e.indexOf&&e.indexOf(t)>-1},notcontains:function(e,t){return!e||!e.indexOf||-1==e.indexOf(t)},greater:function(e,t){return e>t},less:function(e,t){return e<t},greaterorequal:function(e,t){return e>=t},lessorequal:function(e,t){return e<=t}}),t.operatorsValue},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"id",{get:function(){return this.idValue},enumerable:!1,configurable:!0}),t.prototype.getType=function(){return"triggerbase"},t.prototype.toString=function(){var e=this.getType().replace("trigger",""),t=this.expression?this.expression:this.buildExpression();return t&&(e+=", "+t),e},Object.defineProperty(t.prototype,"isInternal",{get:function(){return!0===this.isGhost},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"operator",{get:function(){return this.getPropertyValue("operator","equal")},set:function(e){e&&(e=e.toLowerCase(),t.operators[e]&&this.setPropertyValue("operator",e))},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"value",{get:function(){return this.getPropertyValue("value",null)},set:function(e){this.setPropertyValue("value",e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"name",{get:function(){return this.getPropertyValue("name","")},set:function(e){this.setPropertyValue("name",e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"expression",{get:function(){return this.getPropertyValue("expression","")},set:function(e){this.setPropertyValue("expression",e)},enumerable:!1,configurable:!0}),t.prototype.canBeExecuted=function(e){return!0},t.prototype.canBeExecutedOnComplete=function(){return!1},t.prototype.checkExpression=function(e){this.isExecutingOnNextPage=e.isOnNextPage,this.isExecutingOnNavigation=e.isOnNavigation||e.isOnNextPage,this.canBeExecuted(e.isOnNextPage)&&(e.isOnComplete&&!this.canBeExecutedOnComplete()||this.isCheckRequired(e.keys)&&(this.conditionRunner?this.perform(e.values,e.properties||null):this.canSuccessOnEmptyExpression()&&this.triggerResult(!0,e.values,e.properties||null)))},t.prototype.canSuccessOnEmptyExpression=function(){return!1},t.prototype.check=function(e){t.operators[this.operator](e,this.value)?this.onSuccess({},null):this.onFailure()},Object.defineProperty(t.prototype,"requireValidQuestion",{get:function(){return!1},enumerable:!1,configurable:!0}),t.prototype.perform=function(e,t){var n=this;this.conditionRunner.onRunComplete=function(o){n.triggerResult(o,e,t)},this.conditionRunner.run(e,t)},t.prototype.triggerResult=function(e,t,n){e?(this.onSuccess(t,n),this.onSuccessExecuted()):this.onFailure()},t.prototype.onSuccess=function(e,t){},t.prototype.onFailure=function(){},t.prototype.onSuccessExecuted=function(){},t.prototype.endLoadingFromJson=function(){e.prototype.endLoadingFromJson.call(this),this.oldPropertiesChanged()},t.prototype.oldPropertiesChanged=function(){this.onExpressionChanged()},t.prototype.onExpressionChanged=function(){this.conditionRunner=null},t.prototype.buildExpression=function(){return this.name?this.isValueEmpty(this.value)&&this.isRequireValue?"":"{"+this.name+"} "+this.operator+" "+se.toOperandString(this.value):""},t.prototype.isCheckRequired=function(e){return!!e&&(this.createConditionRunner(),!(!this.conditionRunner||!0!==this.conditionRunner.hasFunction())||(new L).isAnyKeyChanged(e,this.getUsedVariables()))},t.prototype.getUsedVariables=function(){if(!this.conditionRunner)return[];var e=this.conditionRunner.getVariables();if(Array.isArray(e))for(var t="-unwrapped",n=e.length-1;n>=0;n--){var o=e[n];o.endsWith(t)&&e.push(o.substring(0,o.length-t.length))}return e},t.prototype.createConditionRunner=function(){if(!this.conditionRunner){var e=this.expression;e||(e=this.buildExpression()),e&&(this.conditionRunner=new ye(e))}},Object.defineProperty(t.prototype,"isRequireValue",{get:function(){return"empty"!==this.operator&&"notempty"!=this.operator},enumerable:!1,configurable:!0}),t.idCounter=1,t.operatorsValue=null,t}(Ve),aa=function(e){function t(){var t=e.call(this)||this;return t.ownerValue=null,t}return ra(t,e),Object.defineProperty(t.prototype,"owner",{get:function(){return this.ownerValue},enumerable:!1,configurable:!0}),t.prototype.setOwner=function(e){this.ownerValue=e},t.prototype.getSurvey=function(e){return void 0===e&&(e=!1),this.owner&&this.owner.getSurvey?this.owner.getSurvey():null},t.prototype.isRealExecution=function(){return!0},t.prototype.onSuccessExecuted=function(){this.owner&&this.isRealExecution()&&this.owner.triggerExecuted(this)},t}(sa),la=function(e){function t(){var t=e.call(this)||this;return t.pages=[],t.questions=[],t}return ra(t,e),t.prototype.getType=function(){return"visibletrigger"},t.prototype.onSuccess=function(e,t){this.onTrigger(this.onItemSuccess)},t.prototype.onFailure=function(){this.onTrigger(this.onItemFailure)},t.prototype.onTrigger=function(e){if(this.owner)for(var t=this.owner.getObjects(this.pages,this.questions),n=0;n<t.length;n++)e(t[n])},t.prototype.onItemSuccess=function(e){e.visible=!0},t.prototype.onItemFailure=function(e){e.visible=!1},t}(aa),ua=function(e){function t(){return e.call(this)||this}return ra(t,e),t.prototype.getType=function(){return"completetrigger"},Object.defineProperty(t.prototype,"requireValidQuestion",{get:function(){return!0},enumerable:!1,configurable:!0}),t.prototype.isRealExecution=function(){return!Xt.triggers.executeCompleteOnValueChanged===this.isExecutingOnNavigation},t.prototype.onSuccess=function(e,t){this.owner&&(this.isRealExecution()?this.owner.setCompleted(this):this.owner.canBeCompleted(this,!0))},t.prototype.onFailure=function(){this.owner.canBeCompleted(this,!1)},t}(aa),ca=function(e){function t(){return e.call(this)||this}return ra(t,e),t.prototype.getType=function(){return"setvaluetrigger"},t.prototype.canBeExecuted=function(e){return!e&&!!this.setToName},t.prototype.onPropertyValueChanged=function(t,n,o){if(e.prototype.onPropertyValueChanged.call(this,t,n,o),"setToName"===t){var i=this.getSurvey();i&&!i.isLoadingFromJson&&i.isDesignMode&&(this.setValue=void 0)}},Object.defineProperty(t.prototype,"setToName",{get:function(){return this.getPropertyValue("setToName","")},set:function(e){this.setPropertyValue("setToName",e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"setValue",{get:function(){return this.getPropertyValue("setValue")},set:function(e){this.setPropertyValue("setValue",e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isVariable",{get:function(){return this.getPropertyValue("isVariable")},set:function(e){this.setPropertyValue("isVariable",e)},enumerable:!1,configurable:!0}),t.prototype.onSuccess=function(e,t){this.setToName&&this.owner&&this.owner.setTriggerValue(this.setToName,s.getUnbindValue(this.setValue),this.isVariable)},t}(aa),pa=function(e){function t(){return e.call(this)||this}return ra(t,e),t.prototype.getType=function(){return"skiptrigger"},Object.defineProperty(t.prototype,"requireValidQuestion",{get:function(){return this.canBeExecuted(!1)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"gotoName",{get:function(){return this.getPropertyValue("gotoName","")},set:function(e){this.setPropertyValue("gotoName",e)},enumerable:!1,configurable:!0}),t.prototype.canBeExecuted=function(e){return e===!Xt.triggers.executeSkipOnValueChanged},t.prototype.onSuccess=function(e,t){this.gotoName&&this.owner&&this.owner.focusQuestion(this.gotoName)},t}(aa),ha=function(e){function t(){return e.call(this)||this}return ra(t,e),t.prototype.getType=function(){return"runexpressiontrigger"},Object.defineProperty(t.prototype,"setToName",{get:function(){return this.getPropertyValue("setToName","")},set:function(e){this.setPropertyValue("setToName",e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"runExpression",{get:function(){return this.getPropertyValue("runExpression","")},set:function(e){this.setPropertyValue("runExpression",e)},enumerable:!1,configurable:!0}),t.prototype.canBeExecuted=function(e){return!e},t.prototype.onSuccess=function(e,t){var n=this;if(this.owner&&this.runExpression){var o=new me(this.runExpression);o.canRun&&(o.onRunComplete=function(e){n.onCompleteRunExpression(e)},o.run(e,t))}},t.prototype.onCompleteRunExpression=function(e){this.setToName&&void 0!==e&&this.owner.setTriggerValue(this.setToName,s.convertValToQuestionVal(e),!1)},t}(aa),da=function(e){function t(){return e.call(this)||this}return ra(t,e),t.prototype.canBeExecuted=function(e){return!e&&!!this.setToName&&!!this.fromName},Object.defineProperty(t.prototype,"setToName",{get:function(){return this.getPropertyValue("setToName","")},set:function(e){this.setPropertyValue("setToName",e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"fromName",{get:function(){return this.getPropertyValue("fromName","")},set:function(e){this.setPropertyValue("fromName",e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"copyDisplayValue",{get:function(){return this.getPropertyValue("copyDisplayValue")},set:function(e){this.setPropertyValue("copyDisplayValue",e)},enumerable:!1,configurable:!0}),t.prototype.getType=function(){return"copyvaluetrigger"},t.prototype.onSuccess=function(e,t){this.setToName&&this.owner&&this.owner.copyTriggerValue(this.setToName,this.fromName,this.copyDisplayValue)},t.prototype.canSuccessOnEmptyExpression=function(){return!0},t.prototype.getUsedVariables=function(){var t=e.prototype.getUsedVariables.call(this);return 0===t.length&&this.fromName&&t.push(this.fromName),t},t}(aa);D.addClass("trigger",[{name:"operator",default:"equal",visible:!1},{name:"value",visible:!1},"expression:condition"]),D.addClass("surveytrigger",[{name:"name",visible:!1}],null,"trigger"),D.addClass("visibletrigger",["pages:pages","questions:questions"],(function(){return new la}),"surveytrigger"),D.addClass("completetrigger",[],(function(){return new ua}),"surveytrigger"),D.addClass("setvaluetrigger",[{name:"!setToName:questionvalue"},{name:"setValue:triggervalue",dependsOn:"setToName",visibleIf:function(e){return!!e&&!!e.setToName}},{name:"isVariable:boolean",visible:!1}],(function(){return new ca}),"surveytrigger"),D.addClass("copyvaluetrigger",[{name:"!fromName:questionvalue"},{name:"!setToName:questionvalue"},{name:"copyDisplayValue:boolean",visible:!1}],(function(){return new da}),"surveytrigger"),D.addClass("skiptrigger",[{name:"!gotoName:question"}],(function(){return new pa}),"surveytrigger"),D.addClass("runexpressiontrigger",[{name:"setToName:questionvalue"},"runExpression:expression"],(function(){return new ha}),"surveytrigger");var fa=function(){var e=function(t,n){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(t,n)};return function(t,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function o(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(o.prototype=n.prototype,new o)}}(),ga=function(e,t,n,o){var i,r=arguments.length,s=r<3?t:null===o?o=Object.getOwnPropertyDescriptor(t,n):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,n,o);else for(var a=e.length-1;a>=0;a--)(i=e[a])&&(s=(r<3?i(s):r>3?i(t,n,s):i(t,n))||s);return r>3&&s&&Object.defineProperty(t,n,s),s},ya=function(e){function t(t,n){void 0===n&&(n=null);var o=e.call(this)||this;return o.closeOnCompleteTimeout=0,o.surveyValue=n||o.createSurvey(t),o.surveyValue.fitToContainer=!0,o.windowElement=i.createElement("div"),o.survey.onComplete.add((function(e,t){o.onSurveyComplete()})),o.registerPropertyChangedHandlers(["isShowing"],(function(){o.showingChangedCallback&&o.showingChangedCallback()})),o.registerPropertyChangedHandlers(["isExpanded"],(function(){o.onExpandedChanged()})),o.width=new we((function(){return o.survey.width})),o.width=o.survey.width,o.updateCss(),o.onCreating(),o}return fa(t,e),t.prototype.onCreating=function(){},t.prototype.getType=function(){return"popupsurvey"},Object.defineProperty(t.prototype,"survey",{get:function(){return this.surveyValue},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isShowing",{get:function(){return this.getPropertyValue("isShowing",!1)},set:function(e){this.setPropertyValue("isShowing",e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isFullScreen",{get:function(){return this.getPropertyValue("isFullScreen",!1)},set:function(e){!this.isExpanded&&e&&(this.isExpanded=!0),this.setPropertyValue("isFullScreen",e),this.setCssRoot()},enumerable:!1,configurable:!0}),t.prototype.show=function(){this.isShowing=!0},t.prototype.hide=function(){this.isShowing=!1},t.prototype.toggleFullScreen=function(){this.isFullScreen=!this.isFullScreen},Object.defineProperty(t.prototype,"isExpanded",{get:function(){return this.getPropertyValue("isExpanded",!1)},set:function(e){this.isFullScreen&&!e&&(this.isFullScreen=!1),this.setPropertyValue("isExpanded",e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isCollapsed",{get:function(){return!this.isExpanded},enumerable:!1,configurable:!0}),t.prototype.onExpandedChanged=function(){this.expandedChangedCallback&&this.expandedChangedCallback(),this.updateCssButton()},Object.defineProperty(t.prototype,"title",{get:function(){return this.survey.title},set:function(e){this.survey.title=e},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"locTitle",{get:function(){return this.survey.locTitle.isEmpty?null:this.survey.locTitle},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"locDescription",{get:function(){return this.survey.locTitle.isEmpty?null:this.survey.locDescription},enumerable:!1,configurable:!0}),t.prototype.expand=function(){this.isExpanded=!0},t.prototype.collapse=function(){this.isExpanded=!1},t.prototype.changeExpandCollapse=function(){this.isExpanded=!this.isExpanded},Object.defineProperty(t.prototype,"allowClose",{get:function(){return this.getPropertyValue("allowClose",!1)},set:function(e){this.setPropertyValue("allowClose",e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"allowFullScreen",{get:function(){return this.getPropertyValue("allowFullScreen",!1)},set:function(e){this.setPropertyValue("allowFullScreen",e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"css",{get:function(){return this.survey.css},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"cssButton",{get:function(){return this.getPropertyValue("cssButton","")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"cssRoot",{get:function(){var e=this.getPropertyValue("cssRoot","");return this.isCollapsed&&(e+=" "+this.getPropertyValue("cssRootCollapsedMod","")),e},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"cssRootCollapsedMod",{get:function(){return this.getPropertyValue("cssRootCollapsedMod")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"cssRootContent",{get:function(){return this.getPropertyValue("cssRootContent")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"cssBody",{get:function(){return this.getPropertyValue("cssBody","")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"cssHeaderRoot",{get:function(){return this.getPropertyValue("cssHeaderRoot","")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"cssHeaderTitleCollapsed",{get:function(){return this.getPropertyValue("cssHeaderTitleCollapsed","")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"cssHeaderButtonsContainer",{get:function(){return this.getPropertyValue("cssHeaderButtonsContainer","")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"cssHeaderCollapseButton",{get:function(){return this.getPropertyValue("cssHeaderCollapseButton","")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"cssHeaderCloseButton",{get:function(){return this.getPropertyValue("cssHeaderCloseButton","")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"cssHeaderFullScreenButton",{get:function(){return this.getPropertyValue("cssHeaderFullScreenButton","")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"renderedWidth",{get:function(){var e=this.getPropertyValue("width","60%");return e&&!isNaN(e)&&(e+="px"),e},enumerable:!1,configurable:!0}),t.prototype.updateCss=function(){if(this.css&&this.css.window){var e=this.css.window;this.setCssRoot(),this.setPropertyValue("cssRootCollapsedMod",e.rootCollapsedMod),this.setPropertyValue("cssRootContent",e.rootContent),this.setPropertyValue("cssBody",e.body);var t=e.header;t&&(this.setPropertyValue("cssHeaderRoot",t.root),this.setPropertyValue("cssHeaderTitleCollapsed",t.titleCollapsed),this.setPropertyValue("cssHeaderButtonsContainer",t.buttonsContainer),this.setPropertyValue("cssHeaderCollapseButton",t.collapseButton),this.setPropertyValue("cssHeaderCloseButton",t.closeButton),this.setPropertyValue("cssHeaderFullScreenButton",t.fullScreenButton),this.updateCssButton())}},t.prototype.setCssRoot=function(){var e=this.css.window;this.isFullScreen?this.setPropertyValue("cssRoot",e.root+" "+e.rootFullScreenMode):this.setPropertyValue("cssRoot",e.root)},t.prototype.updateCssButton=function(){var e=this.css.window?this.css.window.header:null;e&&this.setCssButton(this.isExpanded?e.buttonExpanded:e.buttonCollapsed)},t.prototype.setCssButton=function(e){e&&this.setPropertyValue("cssButton",e)},t.prototype.createSurvey=function(e){return new zi(e)},t.prototype.onSurveyComplete=function(){if(!(this.closeOnCompleteTimeout<0))if(0==this.closeOnCompleteTimeout)this.hide();else{var e=this,t=null;t=setInterval((function(){e.hide(),clearInterval(t)}),1e3*this.closeOnCompleteTimeout)}},t.prototype.onScroll=function(){this.survey.onScroll()},ga([m()],t.prototype,"width",void 0),t}(Ve),ma=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return fa(t,e),t}(ya),va=function(){var e=function(t,n){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(t,n)};return function(t,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function o(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(o.prototype=n.prototype,new o)}}(),ba=function(e){function t(t){var n=e.call(this,t)||this;return n.onScrollOutsideCallback=function(e){n.preventScrollOuside(e,e.deltaY)},n}return va(t,e),t.prototype.getStyleClass=function(){return e.prototype.getStyleClass.call(this).append("sv-popup--modal",!this.isOverlay)},t.prototype.getShowFooter=function(){return!0},t.prototype.createFooterActionBar=function(){var t=this;e.prototype.createFooterActionBar.call(this),this.footerToolbar.containerCss="sv-footer-action-bar",this.footerToolbarValue.addAction({id:"apply",visibleIndex:20,title:this.applyButtonText,innerCss:"sv-popup__body-footer-item sv-popup__button sv-popup__button--apply sd-btn sd-btn--action",action:function(){t.apply()}})},Object.defineProperty(t.prototype,"applyButtonText",{get:function(){return this.getLocalizationString("modalApplyButtonText")},enumerable:!1,configurable:!0}),t.prototype.apply=function(){this.model.onApply&&!this.model.onApply()||this.hidePopup()},t.prototype.clickOutside=function(){},t.prototype.onKeyDown=function(t){"Escape"!==t.key&&27!==t.keyCode||this.model.onCancel(),e.prototype.onKeyDown.call(this,t)},t.prototype.updateOnShowing=function(){this.container&&this.container.addEventListener("wheel",this.onScrollOutsideCallback,{passive:!1}),e.prototype.updateOnShowing.call(this)},t.prototype.updateOnHiding=function(){this.container&&this.container.removeEventListener("wheel",this.onScrollOutsideCallback),e.prototype.updateOnHiding.call(this)},t}(tr),Ca=function(){return(Ca=Object.assign||function(e){for(var t,n=1,o=arguments.length;n<o;n++)for(var i in t=arguments[n])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e}).apply(this,arguments)};function Pa(e,t){var n,o=Ca({},e);o.verticalPosition="top",o.horizontalPosition="left",o.showPointer=!1,o.isModal=!0,o.displayMode=e.displayMode||"popup";var r=new Qe(e.componentName,e.data,o);r.isFocusedContent=null===(n=e.isFocusedContent)||void 0===n||n;var s=new ba(r);if(t&&t.appendChild){var a=i.createElement("div");t.appendChild(a),s.setComponentElement(a)}s.container||s.initializePopupContainer();var l=function(e,t){t.isVisible||a&&s.resetComponentElement(),s.onVisibilityChanged.remove(l)};return s.onVisibilityChanged.add(l),s}function wa(e){return e.isModal?new ba(e):new rr(e)}var Va=function(){var e=function(t,n){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(t,n)};return function(t,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function o(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(o.prototype=n.prototype,new o)}}(),xa=function(e,t,n,o){var i,r=arguments.length,s=r<3?t:null===o?o=Object.getOwnPropertyDescriptor(t,n):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,n,o);else for(var a=e.length-1;a>=0;a--)(i=e[a])&&(s=(r<3?i(s):r>3?i(t,n,s):i(t,n))||s);return r>3&&s&&Object.defineProperty(t,n,s),s},Oa=function(e){function t(t,n,o){void 0===n&&(n=null),void 0===o&&(o="buttongroupitemvalue");var i=e.call(this,t,n,o)||this;return i.typeName=o,i}return Va(t,e),t.prototype.getType=function(){return this.typeName?this.typeName:"buttongroupitemvalue"},xa([m()],t.prototype,"iconName",void 0),xa([m()],t.prototype,"iconSize",void 0),xa([m()],t.prototype,"showCaption",void 0),t}(kn),Sa=function(e){function t(t){var n=e.call(this,t)||this;return n.createLocalizableString("buttongroupOptionsCaption",n,!1,!0),n.createLocalizableString("readOnlyText",n,!0),n.registerPropertyChangedHandlers(["value","renderAs","placeholder","choices","visibleChoices"],(function(){n.updateReadOnlyText()})),n.updateReadOnlyText(),n}return Va(t,e),t.prototype.locStrsChanged=function(){var t;e.prototype.locStrsChanged.call(this),this.updateReadOnlyText(),null===(t=this.dropdownListModelValue)||void 0===t||t.locStrsChanged()},t.prototype.updateReadOnlyText=function(){this.readOnlyText=this.displayValue||this.placeholder},t.prototype.getType=function(){return"buttongroup"},t.prototype.getItemValueType=function(){return"buttongroupitemvalue"},t.prototype.supportOther=function(){return!1},t}(Ji);D.addClass("buttongroup",[{name:"choices:buttongroupitemvalue[]"}],(function(){return new Sa("")}),"checkboxbase"),D.addClass("buttongroupitemvalue",[{name:"showCaption:boolean",default:!0},{name:"iconName:text"},{name:"iconSize:number"}],(function(e){return new Oa(e)}),"itemvalue");var Ta=function(){function e(e,t,n){this.question=e,this.item=t,this.index=n}return Object.defineProperty(e.prototype,"value",{get:function(){return this.item.value},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"iconName",{get:function(){return this.item.iconName},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"iconSize",{get:function(){return this.item.iconSize||24},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"caption",{get:function(){return this.item.locText},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"showCaption",{get:function(){return this.item.showCaption||void 0===this.item.showCaption},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"isRequired",{get:function(){return this.question.isRequired},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"selected",{get:function(){return this.question.isItemSelected(this.item)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"readOnly",{get:function(){return this.question.isInputReadOnly||!this.item.isEnabled},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"name",{get:function(){return this.question.name+"_"+this.question.id},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"id",{get:function(){return this.question.inputId+"_"+this.index},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"hasErrors",{get:function(){return this.question.errors.length>0},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"describedBy",{get:function(){return this.question.errors.length>0?this.question.id+"_errors":null},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"labelClass",{get:function(){return(new Ee).append(this.question.cssClasses.item).append(this.question.cssClasses.itemSelected,this.selected).append(this.question.cssClasses.itemHover,!this.readOnly&&!this.selected).append(this.question.cssClasses.itemDisabled,this.question.isReadOnly||!this.item.isEnabled).toString()},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"css",{get:function(){return{label:this.labelClass,icon:this.question.cssClasses.itemIcon,control:this.question.cssClasses.itemControl,caption:this.question.cssClasses.itemCaption,decorator:this.question.cssClasses.itemDecorator}},enumerable:!1,configurable:!0}),e.prototype.onChange=function(){this.question.renderedValue=this.item.value},e}(),Ia=function(){var e=function(t,n){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(t,n)};return function(t,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function o(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(o.prototype=n.prototype,new o)}}(),Ra=function(e,t,n,o){var i,r=arguments.length,s=r<3?t:null===o?o=Object.getOwnPropertyDescriptor(t,n):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,n,o);else for(var a=e.length-1;a>=0;a--)(i=e[a])&&(s=(r<3?i(s):r>3?i(t,n,s):i(t,n))||s);return r>3&&s&&Object.defineProperty(t,n,s),s},Ea=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return Ia(t,e),t.prototype.getSurvey=function(e){return void 0===e&&(e=!1),this.owner},t.prototype.getType=function(){return"masksettings"},t.prototype.setData=function(e){var t=this;D.getProperties(this.getType()).forEach((function(n){var o=e[n.name];t[n.name]=void 0!==o?o:n.getDefaultValue(t)}))},t.prototype.getData=function(){var e=this,t={};return D.getProperties(this.getType()).forEach((function(n){var o=e[n.name];n.isDefaultValue(o)||(t[n.name]=o)})),t},t.prototype.processInput=function(e){return{value:e.prevValue,caretPosition:e.selectionEnd,cancelPreventDefault:!1}},t.prototype.getUnmaskedValue=function(e){return e},t.prototype.getMaskedValue=function(e){return e},t.prototype.getTextAlignment=function(){return"auto"},t.prototype.getTypeForExpressions=function(){return"text"},Ra([m()],t.prototype,"saveMaskedValue",void 0),t}(Ve);D.addClass("masksettings",[{name:"saveMaskedValue:boolean",visibleIf:function(e){return!!e&&"masksettings"!==e.getType()}}],(function(){return new Ea}));var _a=function(){var e=function(t,n){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(t,n)};return function(t,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function o(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(o.prototype=n.prototype,new o)}}(),Aa=function(e,t,n,o){var i,r=arguments.length,s=r<3?t:null===o?o=Object.getOwnPropertyDescriptor(t,n):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,n,o);else for(var a=e.length-1;a>=0;a--)(i=e[a])&&(s=(r<3?i(s):r>3?i(t,n,s):i(t,n))||s);return r>3&&s&&Object.defineProperty(t,n,s),s};function Da(e){for(var t=[],n=!1,o=Object.keys(Xt.maskSettings.patternDefinitions),i=0;i<e.length;i++){var r=e[i];r===Xt.maskSettings.patternEscapeChar?n=!0:n?(n=!1,t.push({type:"fixed",value:r})):t.push({type:-1!==o.indexOf(r)?"regex":"const",value:r})}return t}function La(e,t,n){for(var o=Xt.maskSettings.patternDefinitions[n.value];t<e.length;){if(e[t].match(o))return t;t++}return t}function ja(e,t,n,o){void 0===o&&(o=!1);var i="";if(!e)return i;for(var r="string"==typeof t?Da(t):t,s=0;s<r.length;s++)if("fixed"!==r[s].type||o||(i+=r[s].value),"regex"===r[s].type){var a=Xt.maskSettings.patternDefinitions[r[s].value];if(!e[s]||!e[s].match(a)){if(n){i="";break}break}i+=e[s]}return i}var ka=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.literals=[],t}return _a(t,e),t.prototype.updateLiterals=function(){this.literals=Da(this.pattern||"")},t.prototype.onPropertyValueChanged=function(e,t,n){"pattern"===e&&this.updateLiterals()},t.prototype.getType=function(){return"patternmask"},t.prototype.fromJSON=function(t,n){e.prototype.fromJSON.call(this,t,n),this.updateLiterals()},t.prototype._getMaskedValue=function(e,t){return void 0===t&&(t=!1),function(e,t,n){for(var o=null==e?"":e,i="",r=0,s="string"==typeof t?Da(t):t,a=0;a<s.length;a++)switch(s[a].type){case"regex":if(r<o.length&&(r=La(o,r,s[a])),r<o.length)i+=o[r];else{if(!n)return i;i+=Xt.maskSettings.patternPlaceholderChar}r++;break;case"const":case"fixed":i+=s[a].value,s[a].value===o[r]&&r++}return i}(null==e?"":e,this.literals,t)},t.prototype._getUnmaskedValue=function(e,t){return void 0===t&&(t=!1),ja(null==e?"":e,this.literals,t)},t.prototype.processInput=function(e){var t={value:e.prevValue,caretPosition:e.selectionEnd,cancelPreventDefault:!1};if(!e.insertedChars&&e.selectionStart===e.selectionEnd)return t;var n=e.prevValue.slice(0,e.selectionStart)+(e.insertedChars||""),o=ja(e.prevValue.slice(0,e.selectionStart),this.literals.slice(0,e.selectionStart),!1),i=ja(e.prevValue.slice(e.selectionEnd),this.literals.slice(e.selectionEnd),!1,!0);return t.value=this._getMaskedValue(o+(e.insertedChars||"")+i,!0),e.insertedChars||"backward"!==e.inputDirection?t.caretPosition=this._getMaskedValue(n).length:t.caretPosition=e.selectionStart,t},t.prototype.getMaskedValue=function(e){return this._getMaskedValue(e,!0)},t.prototype.getUnmaskedValue=function(e){return this._getUnmaskedValue(e,!0)},Aa([m()],t.prototype,"pattern",void 0),t}(Ea);D.addClass("patternmask",[{name:"pattern"}],(function(){return new ka}),"masksettings");var Na=function(){var e=function(t,n){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(t,n)};return function(t,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function o(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(o.prototype=n.prototype,new o)}}(),Ma=function(e,t,n,o){var i,r=arguments.length,s=r<3?t:null===o?o=Object.getOwnPropertyDescriptor(t,n):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,n,o);else for(var a=e.length-1;a>=0;a--)(i=e[a])&&(s=(r<3?i(s):r>3?i(t,n,s):i(t,n))||s);return r>3&&s&&Object.defineProperty(t,n,s),s};var Fa=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return Na(t,e),t.prototype.calccaretPosition=function(e,t,n){for(var o=e?this.displayNumber(this.parseNumber(e),!1).length:0,i=0,r=t.selectionStart,s=!t.insertedChars&&"forward"===t.inputDirection,a=0;a<n.length;a++){if(n[a]!==this.thousandsSeparator&&i++,i===o+(s?1:0)){r=s?a:a+1;break}}return r},t.prototype.numericalCompositionIsEmpty=function(e){return!e.integralPart&&!e.fractionalPart},t.prototype.displayNumber=function(e,t,n){void 0===t&&(t=!0),void 0===n&&(n=!1);var o=e.integralPart;t&&o&&(o=function(e,t,n){void 0===t&&(t=!0),void 0===n&&(n=3);var o=[];if(t){for(var i=e.length-n;i>-n;i-=n)o.push(e.substring(i,i+n));o=o.reverse()}else for(i=0;i<e.length;i+=n)o.push(e.substring(i,i+n));return o}(o).join(this.thousandsSeparator));var i=e.fractionalPart,r=e.isNegative?"-":"";if(""===i){if(n)return o&&"0"!==o?r+o:o;var s=o+(e.hasDecimalSeparator&&!n?this.decimalSeparator:"");return"0"===s?s:r+s}return[r+(o=o||"0"),i=i.substring(0,this.precision)].join(this.decimalSeparator)},t.prototype.convertNumber=function(e){var t=e.isNegative?"-":"";return e.fractionalPart?parseFloat(t+(e.integralPart||"0")+"."+e.fractionalPart.substring(0,this.precision)):parseInt(t+e.integralPart||"0")},t.prototype.validateNumber=function(e,t){var n=this.min||Number.MIN_SAFE_INTEGER,o=this.max||Number.MAX_SAFE_INTEGER;if(this.numericalCompositionIsEmpty(e))return!0;if(void 0!==this.min||void 0!==this.max){var i=this.convertNumber(e);if(Number.isNaN(i))return!0;if(i>=n&&i<=o)return!0;if(!t){if(e.hasDecimalSeparator||0==i){var r=Math.pow(.1,(e.fractionalPart||"").length);if(i>=0)return i+r>n&&i<=o;if(i<0)return i>=n&&i-r<o}else{var s=i,a=i;if(i>0){if(i+1>n&&i<=o)return!0;for(;s=10*s+9,!((a*=10)>o);)if(s>n)return!0;return!1}if(i<0){if(i>=n&&i-1<o)return!0;for(;a=10*a-9,!((s*=10)<n);)if(a<o)return!0;return!1}}return i>=0&&i<=o||i<0&&i>=n}return!1}return!0},t.prototype.parseNumber=function(e){for(var t={integralPart:"",fractionalPart:"",hasDecimalSeparator:!1,isNegative:!1},n=null==e?"":e.toString(),o=0,i=0;i<n.length;i++){var r=n[i];switch(r){case"-":this.allowNegativeValues&&(void 0===this.min||this.min<0)&&o++;break;case this.decimalSeparator:this.precision>0&&(t.hasDecimalSeparator=!0);break;case this.thousandsSeparator:break;default:r.match(Pr)&&(t.hasDecimalSeparator?t.fractionalPart+=r:t.integralPart+=r)}}return t.isNegative=o%2!=0,t.integralPart.length>1&&"0"===t.integralPart[0]&&(t.integralPart=t.integralPart.slice(1)),t},t.prototype.getNumberMaskedValue=function(e,t){void 0===t&&(t=!1);var n=this.parseNumber(e);return this.validateNumber(n,t)?this.displayNumber(n,!0,t):null},t.prototype.getNumberUnmaskedValue=function(e){var t=this.parseNumber(e);if(!this.numericalCompositionIsEmpty(t))return this.convertNumber(t)},t.prototype.getTextAlignment=function(){return"right"},t.prototype.getMaskedValue=function(e){var t=null==e?"":e.toString();return t=t.replace(".",this.decimalSeparator),this.getNumberMaskedValue(t,!0)},t.prototype.getUnmaskedValue=function(e){return this.getNumberUnmaskedValue(e)},t.prototype.processInput=function(e){var t={value:e.prevValue,caretPosition:e.selectionEnd,cancelPreventDefault:!1},n=e.prevValue.slice(0,e.selectionStart)+(e.insertedChars||""),o=n+e.prevValue.slice(e.selectionEnd),i=this.parseNumber(o);if(!this.validateNumber(i,!1))return t;var r=this.getNumberMaskedValue(o),s=this.calccaretPosition(n,e,r);return t.value=r,t.caretPosition=s,t},t.prototype.getType=function(){return"numericmask"},t.prototype.isValueUndefined=function(t){return""===t||e.prototype.isValueUndefined.call(this,t)},Ma([m()],t.prototype,"allowNegativeValues",void 0),Ma([m()],t.prototype,"decimalSeparator",void 0),Ma([m()],t.prototype,"precision",void 0),Ma([m()],t.prototype,"thousandsSeparator",void 0),Ma([m()],t.prototype,"min",void 0),Ma([m()],t.prototype,"max",void 0),t}(Ea);D.addClass("numericmask",[{name:"allowNegativeValues:boolean",default:!0},{name:"decimalSeparator",default:".",maxLength:1},{name:"thousandsSeparator",default:",",maxLength:1},{name:"precision:number",default:2,minValue:0},{name:"min:number"},{name:"max:number"}],(function(){return new Fa}),"masksettings");var qa=function(){var e=function(t,n){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(t,n)};return function(t,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function o(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(o.prototype=n.prototype,new o)}}(),Ba=function(){return(Ba=Object.assign||function(e){for(var t,n=1,o=arguments.length;n<o;n++)for(var i in t=arguments[n])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e}).apply(this,arguments)},Qa=function(e,t,n,o){var i,r=arguments.length,s=r<3?t:null===o?o=Object.getOwnPropertyDescriptor(t,n):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,n,o);else for(var a=e.length-1;a>=0;a--)(i=e[a])&&(s=(r<3?i(s):r>3?i(t,n,s):i(t,n))||s);return r>3&&s&&Object.defineProperty(t,n,s),s};function za(e,t){switch(e){case"hour":case"minute":case"second":case"day":case"month":return 2;case"timeMarker":case"year":return t;default:return 1}}var Ha=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.defaultDate="1970-01-01T",t.turnOfTheCentury=68,t.twelve=12,t.lexems=[],t.inputDateTimeData=[],t.validBeginningOfNumbers={hour:1,hourU:2,minute:5,second:5,day:3,month:1},t}return qa(t,e),Object.defineProperty(t.prototype,"hasDatePart",{get:function(){return this.lexems.some((function(e){return"day"===e.type||"month"===e.type||"year"===e.type}))},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"hasTimePart",{get:function(){return this.lexems.some((function(e){return"hour"===e.type||"minute"===e.type||"second"===e.type}))},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"is12Hours",{get:function(){return this.lexems.filter((function(e){return"hour"===e.type&&!e.upperCase})).length>0},enumerable:!1,configurable:!0}),t.prototype.getType=function(){return"datetimemask"},t.prototype.getTypeForExpressions=function(){return this.hasTimePart?"datetime-local":"datetime"},t.prototype.updateLiterals=function(){this.lexems=function(e){for(var t,n=[],o=function(e,o,i){if(void 0===i&&(i=!1),t&&t===e){n[n.length-1].count++;var r=za(e,n[n.length-1].count);n[n.length-1].maxCount=r}else{r=za(e,1);n.push({type:e,value:o,count:1,maxCount:r,upperCase:i})}},i=0;i<e.length;i++){var r=e[i];switch(r){case"m":o("month",r);break;case"d":o("day",r);break;case"y":o("year",r);break;case"h":o("hour",r,!1);break;case"H":o("hour",r,!0);break;case"M":o("minute",r);break;case"s":o("second",r);break;case"t":o("timeMarker",r);break;case"T":o("timeMarker",r,!0);break;default:n.push({type:"separator",value:r,count:1,maxCount:1,upperCase:!1})}t=n[n.length-1].type}return n}(this.pattern||"")},t.prototype.leaveOnlyNumbers=function(e){for(var t="",n=0;n<e.length;n++)e[n].match(Pr)&&(t+=e[n]);return t},t.prototype.getMaskedStrFromISO=function(e){var t=this,n=new Date(e);return this.initInputDateTimeData(),this.hasTimePart||(n=new Date(e+"T00:00:00")),this.hasDatePart||(n=new Date(this.defaultDate+e)),isNaN(n)||this.lexems.forEach((function(e,o){var i=t.inputDateTimeData[o];switch(i.isCompleted=!0,e.type){case"hour":t.is12Hours?i.value=((n.getHours()-1)%t.twelve+1).toString():i.value=n.getHours().toString();break;case"minute":i.value=n.getMinutes().toString();break;case"second":i.value=n.getSeconds().toString();break;case"timeMarker":var r=n.getHours()>=t.twelve?"pm":"am";i.value=e.upperCase?r.toUpperCase():r;break;case"day":i.value=n.getDate().toString();break;case"month":i.value=(n.getMonth()+1).toString();break;case"year":var s=n.getFullYear();2==e.count&&(s%=100),i.value=s.toString()}})),this.getFormatedString(!0)},t.prototype.initInputDateTimeData=function(){var e=this;this.inputDateTimeData=[],this.lexems.forEach((function(t){e.inputDateTimeData.push({lexem:t,isCompleted:!1,value:void 0})}))},t.prototype.getISO_8601Format=function(e){var t=[],n=[];if(void 0!==e.year){var o=this.getPlaceholder(4,e.year.toString(),"0")+e.year;t.push(o)}if(void 0!==e.month&&void 0!==e.year){var i=this.getPlaceholder(2,e.month.toString(),"0")+e.month;t.push(i)}if(void 0!==e.day&&void 0!==e.month&&void 0!==e.year){var r=this.getPlaceholder(2,e.day.toString(),"0")+e.day;t.push(r)}if(void 0!==e.hour){var s=this.getPlaceholder(2,e.hour.toString(),"0")+e.hour;n.push(s)}if(void 0!==e.minute&&void 0!==e.hour){var a=this.getPlaceholder(2,e.minute.toString(),"0")+e.minute;n.push(a)}if(void 0!==e.second&&void 0!==e.minute&&void 0!==e.hour){var l=this.getPlaceholder(2,e.second.toString(),"0")+e.second;n.push(l)}var u=[];return t.length>0&&u.push(t.join("-")),n.length>1&&u.push(n.join(":")),u.join("T")},t.prototype.isYearValid=function(e){if(void 0===e.min&&void 0===e.max)return!1;var t=e.year.toString(),n=e.min.toISOString().slice(0,t.length),o=e.max.toISOString().slice(0,t.length);return e.year>=parseInt(n)&&e.year<=parseInt(o)},t.prototype.createIDateTimeCompositionWithDefaults=function(e,t){var n=29==e.day&&2==e.month,o=e.min.getFullYear(),i=e.max.getFullYear();n&&(o=4*Math.ceil(o/4))>(i=4*Math.floor(i/4))&&(o=void 0,i=void 0);var r=void 0!==e.year?e.year:t?i:o,s=void 0!==e.month?e.month:t&&this.hasDatePart?12:1;return{year:r,month:s,day:void 0!==e.day?e.day:t&&this.hasDatePart?this.getMaxDateForMonth(r,s):1,hour:void 0!==e.hour?e.hour:t?23:0,minute:void 0!==e.minute?e.minute:t?59:0,second:void 0!==e.second?e.second:t?59:0}},t.prototype.getMaxDateForMonth=function(e,t){return 2==t?e%4==0&&e%100!=0||e%400==0?29:28:[31,28,31,30,31,30,31,31,30,31,30,31][t-1]},t.prototype.isDateValid=function(e){var t=new Date(this.getISO_8601Format(this.createIDateTimeCompositionWithDefaults(e,!1))),n=new Date(this.getISO_8601Format(this.createIDateTimeCompositionWithDefaults(e,!0)));return!isNaN(t)&&(t.getDate()===e.day||void 0===e.day)&&(t.getMonth()===e.month-1||void 0===e.month)&&(t.getFullYear()===e.year||void 0===e.year)&&n>=e.min&&t<=e.max},t.prototype.getPlaceholder=function(e,t,n){var o=e-(t||"").length;return o>0?n.repeat(o):""},t.prototype.isDateValid12=function(e){return this.is12Hours?!(this.is12Hours&&e.hour>this.twelve)&&(e.timeMarker?"p"===e.timeMarker[0].toLowerCase()?(e.hour!==this.twelve&&(e.hour+=this.twelve),this.isDateValid(e)):(e.hour===this.twelve&&(e.hour=0),this.isDateValid(e)):!!this.isDateValid(e)||(e.hour+=this.twelve,this.isDateValid(e))):this.isDateValid(e)},t.prototype.updateTimeMarkerInputDateTimeData=function(e,t){var n=e.value;if(n){var o=Ba({},t);o.timeMarker=n,this.isDateValid12(o)?e.isCompleted=!0:n=n.slice(0,n.length-1),e.value=n||void 0,t.timeMarker=n||void 0}},t.prototype.updateInputDateTimeData=function(e,t){var n=e.value;if(n){var o=e.lexem.type,i=Ba({},t);if(i[o]=parseInt(this.parseTwoDigitYear(e)),n.length===e.lexem.maxCount){if(this.isDateValid12(i))return e.isCompleted=!0,e.value=n||void 0,void(t[o]=parseInt(n)>0?parseInt(n):void 0);n=n.slice(0,n.length-1)}i[o]=parseInt(n);var r=parseInt(n[0]),s=this.validBeginningOfNumbers[o+(e.lexem.upperCase?"U":"")];"year"!==o||this.isYearValid(i)?void 0!==s&&r>s?this.isDateValid12(i)?e.isCompleted=!0:n=n.slice(0,n.length-1):void 0!==s&&0!==r&&r<=s&&(this.checkValidationDateTimePart(i,o,e),e.isCompleted&&!this.isDateValid12(i)&&(n=n.slice(0,n.length-1))):(n=n.slice(0,n.length-1),e.isCompleted=!1),e.value=n||void 0,t[o]=parseInt(n)>0?parseInt(n):void 0}},t.prototype.checkValidationDateTimePart=function(e,t,n){var o=e[t],i=10*o,r=10;"month"===t&&(r=3),"hour"===t&&(r=this.is12Hours?3:5),n.isCompleted=!0;for(var s=0;s<r;s++)if(e[t]=i+s,this.isDateValid12(e)){n.isCompleted=!1;break}e[t]=o},t.prototype.getCorrectDatePartFormat=function(e,t){var n=e.lexem,o=e.value||"";if(o&&"timeMarker"===n.type)return t&&(o+=this.getPlaceholder(n.count,o,n.value)),o;(o&&e.isCompleted&&(o=parseInt(o).toString()),o&&e.isCompleted)?o=this.getPlaceholder(n.count,o,"0")+o:(o=function(e,t){var n=t;return e.count<e.maxCount&&("day"===e.type&&0===parseInt(t[0])||"month"===e.type&&0===parseInt(t[0]))&&(n=t.slice(1,t.length)),n}(n,o),t&&(o+=this.getPlaceholder(n.count,o,n.value)));return o},t.prototype.createIDateTimeComposition=function(){var e,t;return this.hasDatePart?(e=this.min||"0001-01-01",t=this.max||"9996-12-31"):(e=this.defaultDate+(this.min||"00:00:00"),t=this.defaultDate+(this.max||"23:59:59")),{hour:void 0,minute:void 0,second:void 0,day:void 0,month:void 0,year:void 0,min:new Date(e),max:new Date(t)}},t.prototype.parseTwoDigitYear=function(e){var t=e.value;return"year"!==e.lexem.type||e.lexem.count>2?t:(this.max&&this.max.length>=4&&(this.turnOfTheCentury=parseInt(this.max.slice(2,4))),(parseInt(t)>this.turnOfTheCentury?"19":"20")+t)},t.prototype.getFormatedString=function(e){var t="",n="",o=!1,i=this.inputDateTimeData.length-1;if(!e){var r=this.inputDateTimeData.filter((function(e){return!!e.value}));i=this.inputDateTimeData.indexOf(r[r.length-1])}for(var s=0;s<this.inputDateTimeData.length;s++){var a=this.inputDateTimeData[s];switch(a.lexem.type){case"timeMarker":case"hour":case"minute":case"second":case"day":case"month":case"year":if(void 0===a.value&&!e)return t+=o?n:"";var l=e||i>s;t+=n+this.getCorrectDatePartFormat(a,l),o=a.isCompleted;break;case"separator":n=a.lexem.value}}return t},t.prototype.cleanTimeMarker=function(e,t){var n="";e=e.toUpperCase();for(var o=0;o<e.length;o++)(!n&&("P"==e[o]||"A"==e[o])||n&&"M"==e[o])&&(n+=e[o]);return n=t?n.toUpperCase():n.toLowerCase()},t.prototype.setInputDateTimeData=function(e){var t=this,n=0;this.initInputDateTimeData(),this.lexems.forEach((function(o,i){if(e.length>0&&n<e.length){if("separator"===o.type)return;var r=t.inputDateTimeData[i],s=e[n],a=void 0;a="timeMarker"===o.type?t.cleanTimeMarker(s,o.upperCase):t.leaveOnlyNumbers(s),r.value=a.slice(0,o.maxCount),n++}}))},t.prototype._getMaskedValue=function(e,t){var n=this;void 0===t&&(t=!0);var o=null==e?"":e.toString(),i=this.getParts(o);this.setInputDateTimeData(i);var r=this.createIDateTimeComposition();return this.inputDateTimeData.forEach((function(e){"timeMarker"===e.lexem.type?n.updateTimeMarkerInputDateTimeData(e,r):n.updateInputDateTimeData(e,r)})),this.getFormatedString(t)},t.prototype.getParts=function(e){for(var t=[],n=this.lexems.filter((function(e){return"separator"!==e.type})),o=this.lexems.filter((function(e){return"separator"===e.type})).map((function(e){return e.value})),i="",r=!1,s=!1,a=0;a<e.length;a++){var l=e[a];if(l.match(Pr)||l===n[t.length].value||"timeMarker"===n[t.length].type?(r=!1,s=!1,i+=l):-1!==o.indexOf(l)?s||(r=!0,t.push(i),i=""):r||(s=!0,t.push(i),i=""),t.length>=n.length){r=!1;break}}return(""!=i||r)&&t.push(i),t},t.prototype.getUnmaskedValue=function(e){var t,n=this,o=null==e?"":e.toString(),i=this.getParts(o);this.setInputDateTimeData(i);var r=null===(t=this.inputDateTimeData.filter((function(e){return"timeMarker"===e.lexem.type}))[0])||void 0===t?void 0:t.value.toLowerCase()[0],s=this.createIDateTimeComposition(),a=!1;return this.inputDateTimeData.forEach((function(e){var t=e.value;if("timeMarker"!=e.lexem.type&&"separator"!=e.lexem.type)if(!t||t.length<e.lexem.count)a=!0;else{var o=parseInt(n.parseTwoDigitYear(e));"hour"==e.lexem.type&&"p"===r&&o!=n.twelve&&(o+=n.twelve),s[e.lexem.type]=o}})),a?"":this.getISO_8601Format(s)},t.prototype.getMaskedValue=function(e){return this.getMaskedStrFromISO(e)},t.prototype.processInput=function(e){var t={value:e.prevValue,caretPosition:e.selectionEnd,cancelPreventDefault:!1},n=e.prevValue.slice(0,e.selectionStart),o=e.prevValue.slice(e.selectionEnd);return t.value=this._getMaskedValue(n+(e.insertedChars||"")+o),e.insertedChars||"backward"!==e.inputDirection?t.caretPosition=this._getMaskedValue(n+(e.insertedChars||""),!1).length:t.caretPosition=e.selectionStart,t},Qa([m()],t.prototype,"min",void 0),Qa([m()],t.prototype,"max",void 0),t}(ka);D.addClass("datetimemask",[{name:"min",type:"datetime",enableIf:function(e){return!!e.pattern}},{name:"max",type:"datetime",enableIf:function(e){return!!e.pattern}}],(function(){return new Ha}),"patternmask");var Ua,Wa,Ga=function(){var e=function(t,n){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(t,n)};return function(t,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function o(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(o.prototype=n.prototype,new o)}}(),Ja=function(e,t,n,o){var i,r=arguments.length,s=r<3?t:null===o?o=Object.getOwnPropertyDescriptor(t,n):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,n,o);else for(var a=e.length-1;a>=0;a--)(i=e[a])&&(s=(r<3?i(s):r>3?i(t,n,s):i(t,n))||s);return r>3&&s&&Object.defineProperty(t,n,s),s},Ka=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return Ga(t,e),t.prototype.getType=function(){return"currencymask"},t.prototype.wrapText=function(e){var t=this.prefix||"",n=this.suffix||"",o=e;return o?(-1===o.indexOf(t)&&(o=t+o),-1===o.indexOf(n)&&(o+=n),o):o},t.prototype.unwrapInputArgs=function(e){var t=e.prevValue;if(t){if(this.prefix&&-1!==t.indexOf(this.prefix)){t=t.slice(t.indexOf(this.prefix)+this.prefix.length);var n=(this.prefix||"").length;e.selectionStart=Math.max(e.selectionStart-n,0),e.selectionEnd-=n}this.suffix&&-1!==t.indexOf(this.suffix)&&(t=t.slice(0,t.indexOf(this.suffix))),e.prevValue=t}},t.prototype.processInput=function(t){this.unwrapInputArgs(t);var n=e.prototype.processInput.call(this,t),o=(this.prefix||"").length;return n.value&&(n.caretPosition+=o),n.value=this.wrapText(n.value),n},t.prototype.getMaskedValue=function(t){var n=e.prototype.getMaskedValue.call(this,t);return this.wrapText(n)},Ja([m()],t.prototype,"prefix",void 0),Ja([m()],t.prototype,"suffix",void 0),t}(Fa);function $a(e,t){if(Ua!=e){var n="survey-core has version '"+Ua+"' and "+t+" has version '"+e+"'. SurveyJS libraries should have the same versions to work correctly.";console.error(n)}}function Ya(e){Xa(e)}function Xa(e){!function(e,t,n){if(!e)return;var i=function(e){var t,n,o,i={},r=0,s=0,a="",l=String.fromCharCode,u=e.length;for(t=0;t<64;t++)i["ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".charAt(t)]=t;for(n=0;n<u;n++){for(r=(r<<6)+i[e.charAt(n)],s+=6;s>=8;)((o=r>>>(s-=8)&255)||n<u-2)&&(a+=l(o))}return a}(e);if(!i)return;var r=i.indexOf(";");if(r<0)return;if(!function(e){if(!e)return!0;var t="domains:",n=e.indexOf(t);if(n<0)return!0;var i=e.substring(n+t.length).toLowerCase().split(",");if(!Array.isArray(i)||0===i.length)return!0;var r=o.getLocation();if(r&&r.hostname){var s=r.hostname.toLowerCase();i.push("localhost");for(var a=0;a<i.length;a++)if(s.indexOf(i[a])>-1)return!0;return!1}return!0}(i.substring(0,r)))return;(i=i.substring(r+1)).split(",").forEach((function(e){var o=e.indexOf("=");o>0&&(t[e.substring(0,o)]=new Date(n)<=new Date(e.substring(o+1)))}))}(e,el,Wa)}function Za(e){return!0===el[e.toString()]}D.addClass("currencymask",[{name:"prefix"},{name:"suffix"}],(function(){return new Ka}),"numericmask"),Ua="1.12.44",Xt.version=Ua,Wa="2025-07-09";var el={};var tl={"$main-color":"#1ab394","$add-button-color":"#1948b3","$remove-button-color":"#ff1800","$disable-color":"#dbdbdb","$progress-text-color":"#9d9d9d","$disabled-label-color":"rgba(64, 64, 64, 0.5)","$slider-color":"white","$disabled-slider-color":"#cfcfcf","$error-color":"#d52901","$text-color":"#404040","$light-text-color":"#fff","$checkmark-color":"#fff","$progress-buttons-color":"#8dd9ca","$inputs-background-color":"transparent","$main-hover-color":"#9f9f9f","$body-container-background-color":"#f4f4f4","$text-border-color":"#d4d4d4","$disabled-text-color":"rgba(64, 64, 64, 0.5)","$border-color":"rgb(64, 64, 64, 0.5)","$header-background-color":"#e7e7e7","$answer-background-color":"rgba(26, 179, 148, 0.2)","$error-background-color":"rgba(213, 41, 1, 0.2)","$radio-checked-color":"#404040","$clean-button-color":"#1948b3","$body-background-color":"#ffffff","$foreground-light":"#909090","$font-family":"Raleway"},nl={"$header-background-color":"#e7e7e7","$body-container-background-color":"#f4f4f4","$main-color":"#1ab394","$main-hover-color":"#0aa384","$body-background-color":"white","$inputs-background-color":"white","$text-color":"#6d7072","$text-input-color":"#6d7072","$header-color":"#6d7072","$border-color":"#e7e7e7","$error-color":"#ed5565","$error-background-color":"#fcdfe2","$progress-text-color":"#9d9d9d","$disable-color":"#dbdbdb","$disabled-label-color":"rgba(64, 64, 64, 0.5)","$slider-color":"white","$disabled-switch-color":"#9f9f9f","$disabled-slider-color":"#cfcfcf","$foreground-light":"#909090","$foreground-disabled":"#161616","$background-dim":"#f3f3f3","$progress-buttons-color":"#8dd9ca","$progress-buttons-line-color":"#d4d4d4"},ol={"$header-background-color":"#4a4a4a","$body-container-background-color":"#f8f8f8","$main-color":"#f78119","$main-hover-color":"#e77109","$body-background-color":"white","$inputs-background-color":"white","$text-color":"#4a4a4a","$text-input-color":"#4a4a4a","$header-color":"#f78119","$border-color":"#e7e7e7","$error-color":"#ed5565","$error-background-color":"#fcdfe2","$progress-text-color":"#9d9d9d","$disable-color":"#dbdbdb","$disabled-label-color":"rgba(64, 64, 64, 0.5)","$slider-color":"white","$disabled-switch-color":"#9f9f9f","$disabled-slider-color":"#cfcfcf","$foreground-light":"#909090","$foreground-disabled":"#161616","$background-dim":"#f3f3f3","$progress-buttons-color":"#f7b781","$progress-buttons-line-color":"#d4d4d4"},il={"$header-background-color":"#d9d8dd","$body-container-background-color":"#f6f7f2","$main-color":"#3c4f6d","$main-hover-color":"#2c3f5d","$body-background-color":"white","$inputs-background-color":"white","$text-color":"#4a4a4a","$text-input-color":"#4a4a4a","$header-color":"#6d7072","$border-color":"#e7e7e7","$error-color":"#ed5565","$error-background-color":"#fcdfe2","$progress-text-color":"#9d9d9d","$disable-color":"#dbdbdb","$disabled-label-color":"rgba(64, 64, 64, 0.5)","$slider-color":"white","$disabled-switch-color":"#9f9f9f","$disabled-slider-color":"#cfcfcf","$foreground-light":"#909090","$foreground-disabled":"#161616","$background-dim":"#f3f3f3","$progress-buttons-color":"#839ec9","$progress-buttons-line-color":"#d4d4d4"},rl={"$header-background-color":"#ddd2ce","$body-container-background-color":"#f7efed","$main-color":"#68656e","$main-hover-color":"#58555e","$body-background-color":"white","$inputs-background-color":"white","$text-color":"#4a4a4a","$text-input-color":"#4a4a4a","$header-color":"#6d7072","$border-color":"#e7e7e7","$error-color":"#ed5565","$error-background-color":"#fcdfe2","$progress-text-color":"#9d9d9d","$disable-color":"#dbdbdb","$disabled-label-color":"rgba(64, 64, 64, 0.5)","$slider-color":"white","$disabled-switch-color":"#9f9f9f","$disabled-slider-color":"#cfcfcf","$foreground-light":"#909090","$foreground-disabled":"#161616","$background-dim":"#f3f3f3","$progress-buttons-color":"#c6bed4","$progress-buttons-line-color":"#d4d4d4"},sl={"$header-background-color":"#cdccd2","$body-container-background-color":"#efedf4","$main-color":"#0f0f33","$main-hover-color":"#191955","$body-background-color":"white","$inputs-background-color":"white","$text-color":"#0f0f33","$text-input-color":"#0f0f33","$header-color":"#0f0f33","$border-color":"#e7e7e7","$error-color":"#ed5565","$error-background-color":"#fcdfe2","$progress-text-color":"#9d9d9d","$disable-color":"#dbdbdb","$disabled-label-color":"rgba(64, 64, 64, 0.5)","$slider-color":"white","$disabled-switch-color":"#9f9f9f","$disabled-slider-color":"#cfcfcf","$foreground-light":"#909090","$foreground-disabled":"#161616","$background-dim":"#f3f3f3","$progress-buttons-color":"#747491","$progress-buttons-line-color":"#d4d4d4"},al={"$header-background-color":"#82b8da","$body-container-background-color":"#dae1e7","$main-color":"#3c3b40","$main-hover-color":"#1e1d20","$body-background-color":"white","$inputs-background-color":"white","$text-color":"#000","$text-input-color":"#000","$header-color":"#000","$border-color":"#e7e7e7","$error-color":"#ed5565","$error-background-color":"#fcdfe2","$disable-color":"#dbdbdb","$progress-text-color":"#9d9d9d","$disabled-label-color":"rgba(64, 64, 64, 0.5)","$slider-color":"white","$disabled-switch-color":"#9f9f9f","$disabled-slider-color":"#cfcfcf","$foreground-light":"#909090","$foreground-disabled":"#161616","$background-dim":"#f3f3f3","$progress-buttons-color":"#d1c9f5","$progress-buttons-line-color":"#d4d4d4"},ll={"$header-background-color":"#323232","$body-container-background-color":"#f8f8f8","$main-color":"#5ac8fa","$main-hover-color":"#06a1e7","$body-background-color":"white","$inputs-background-color":"white","$text-color":"#000","$text-input-color":"#000","$header-color":"#000","$border-color":"#e7e7e7","$error-color":"#ed5565","$error-background-color":"#fcdfe2","$disable-color":"#dbdbdb","$progress-text-color":"#9d9d9d","$disabled-label-color":"rgba(64, 64, 64, 0.5)","$slider-color":"white","$disabled-switch-color":"#9f9f9f","$disabled-slider-color":"#cfcfcf","$foreground-light":"#909090","$foreground-disabled":"#161616","$background-dim":"#f3f3f3","$progress-buttons-color":"#acdcf2","$progress-buttons-line-color":"#d4d4d4"};var ul=function(){function e(){e.autoApplyTheme()}return e.autoApplyTheme=function(){if("bootstrap"!==Xo.currentType&&"bootstrapmaterial"!==Xo.currentType){var t=e.getIncludedThemeCss();1===t.length&&e.applyTheme(t[0].name)}},e.getAvailableThemes=function(){return Xo.getAvailableThemes().filter((function(e){return-1!==["defaultV2","default","modern"].indexOf(e)})).map((function(e){return{name:e,theme:Xo[e]}}))},e.getIncludedThemeCss=function(){if(void 0===Xt.environment)return[];var t=Xt.environment.rootElement,n=e.getAvailableThemes(),o=wt(t)?t.host:t;if(o){var i=getComputedStyle(o);if(i.length)return n.filter((function(e){return e.theme.variables&&i.getPropertyValue(e.theme.variables.themeMark)}))}return[]},e.findSheet=function(e){if(void 0===Xt.environment)return null;for(var t=Xt.environment.root.styleSheets,n=0;n<t.length;n++)if(t[n].ownerNode&&t[n].ownerNode.id===e)return t[n];return null},e.createSheet=function(t){var n=Xt.environment.stylesSheetsMountContainer,o=i.createElement("style");return o.id=t,o.appendChild(new Text("")),Vt(n).appendChild(o),e.Logger&&e.Logger.log("style sheet "+t+" created"),o.sheet},e.applyTheme=function(t,n){if(void 0===t&&(t="default"),void 0!==Xt.environment){var o=Xt.environment.rootElement,i=wt(o)?o.host:o;if(Xo.currentType=t,e.Enabled){if("bootstrap"!==t&&"bootstrapmaterial"!==t)return function(e,t){Object.keys(e||{}).forEach((function(n){var o=n.substring(1);t.style.setProperty("--"+o,e[n])}))}(e.ThemeColors[t],i),void(e.Logger&&e.Logger.log("apply theme "+t+" completed"));var r=e.ThemeCss[t];if(!r)return void(Xo.currentType="defaultV2");e.insertStylesRulesIntoDocument();var s=n||e.ThemeSelector[t]||e.ThemeSelector.default,a=(t+s).trim(),l=e.findSheet(a);if(!l){l=e.createSheet(a);var u=e.ThemeColors[t]||e.ThemeColors.default;Object.keys(r).forEach((function(e){var t=r[e];Object.keys(u||{}).forEach((function(e){return t=t.replace(new RegExp("\\"+e,"g"),u[e])}));try{0===e.indexOf("body")?l.insertRule(e+" { "+t+" }",0):l.insertRule(s+e+" { "+t+" }",0)}catch(e){}}))}}e.Logger&&e.Logger.log("apply theme "+t+" completed")}},e.insertStylesRulesIntoDocument=function(){if(e.Enabled){var t=e.findSheet(e.SurveyJSStylesSheetId);t||(t=e.createSheet(e.SurveyJSStylesSheetId)),Object.keys(e.Styles).length&&Object.keys(e.Styles).forEach((function(n){try{t.insertRule(n+" { "+e.Styles[n]+" }",0)}catch(e){}})),Object.keys(e.Media).length&&Object.keys(e.Media).forEach((function(n){try{t.insertRule(e.Media[n].media+" { "+n+" { "+e.Media[n].style+" } }",0)}catch(e){}}))}},e.SurveyJSStylesSheetId="surveyjs-styles",e.Styles={},e.Media={},e.ThemeColors={modern:tl,default:nl,orange:ol,darkblue:il,darkrose:rl,stone:sl,winter:al,winterstone:ll},e.ThemeCss={},e.ThemeSelector={default:".sv_main ",modern:".sv-root-modern "},e.Enabled=!0,e}();zi.prototype.onBeforeRunConstructor=function(){o.isAvailable()&&ul.autoApplyTheme()};var cl={root:"sv_main sv_default_css",rootProgress:"sv_progress",container:"sv_container",header:"sv_header",bodyContainer:"sv-components-row",body:"sv_body",bodyEmpty:"sv_body sv_body_empty",footer:"sv_nav",title:"",description:"",logo:"sv_logo",logoImage:"sv_logo__image",headerText:"sv_header__text",navigationButton:"sv_nav_btn",completedPage:"sv_completed_page",navigation:{complete:"sv_complete_btn",prev:"sv_prev_btn",next:"sv_next_btn",start:"sv_start_btn",preview:"sv_preview_btn",edit:"sv_edit_btn"},progress:"sv_progress",progressBar:"sv_progress_bar",progressTextInBar:"sv-hidden",progressButtonsContainerCenter:"sv_progress-buttons__container-center",progressButtonsContainer:"sv_progress-buttons__container",progressButtonsImageButtonLeft:"sv_progress-buttons__image-button-left",progressButtonsImageButtonRight:"sv_progress-buttons__image-button-right",progressButtonsImageButtonHidden:"sv_progress-buttons__image-button--hidden",progressButtonsListContainer:"sv_progress-buttons__list-container",progressButtonsList:"sv_progress-buttons__list",progressButtonsListElementPassed:"sv_progress-buttons__list-element--passed",progressButtonsListElementCurrent:"sv_progress-buttons__list-element--current",progressButtonsListElementNonClickable:"sv_progress-buttons__list-element--nonclickable",progressButtonsPageTitle:"sv_progress-buttons__page-title",progressButtonsPageDescription:"sv_progress-buttons__page-description",page:{root:"sv_p_root",title:"sv_page_title",description:""},pageTitle:"sv_page_title",pageDescription:"",row:"sv_row",question:{mainRoot:"sv_q sv_qstn",flowRoot:"sv_q_flow sv_qstn",header:"",headerLeft:"title-left",content:"",contentLeft:"content-left",titleLeftRoot:"sv_qstn_left",requiredText:"sv_q_required_text",title:"sv_q_title",titleExpandable:"sv_q_title_expandable",titleExpandableSvg:"sd-element__title-expandable-svg",titleExpanded:"sv_q_title_expanded",titleCollapsed:"sv_q_title_collapsed",number:"sv_q_num",description:"sv_q_description",comment:"",required:"",titleRequired:"",hasError:"",indent:20,footer:"sv_q_footer",formGroup:"form-group",asCell:"sv_matrix_cell",icon:"sv_question_icon",iconExpanded:"sv_expanded",disabled:"sv_q--disabled"},panel:{title:"sv_p_title",titleExpandable:"sv_p_title_expandable",titleExpandableSvg:"sd-element__title-expandable-svg",titleExpanded:"sv_p_title_expanded",titleCollapsed:"sv_p_title_collapsed",titleOnError:"",icon:"sv_panel_icon",iconExpanded:"sv_expanded",description:"sv_p_description",container:"sv_p_container",footer:"sv_p_footer",number:"sv_q_num",requiredText:"sv_q_required_text"},error:{root:"sv_q_erbox",icon:"",item:"",locationTop:"sv_qstn_error_top",locationBottom:"sv_qstn_error_bottom"},boolean:{root:"sv_qcbc sv_qbln",rootRadio:"sv_qcbc sv_qbln",item:"sv-boolean",control:"sv-visuallyhidden",itemChecked:"sv-boolean--checked checked",itemIndeterminate:"sv-boolean--indeterminate",itemDisabled:"sv-boolean--disabled",switch:"sv-boolean__switch",slider:"sv-boolean__slider",label:"sv-boolean__label ",disabledLabel:"sv-boolean__label--disabled",sliderGhost:"sv-boolean__thumb-ghost",rootCheckbox:"sv_qcbc sv_qbln",checkboxItem:"sv-boolean",checkboxItemChecked:"sv-boolean--checked",controlCheckbox:"sv-visuallyvisible",checkboxControlLabel:"sv-boolean__label",checkboxItemIndeterminate:"sv-boolean--indeterminate",checkboxItemDisabled:"sv-item--disabled sv-boolean--disabled",checkboxMaterialDecorator:"sv-item__decorator sv-boolean__decorator",checkboxItemDecorator:"sv-item__svg sv-boolean__svg"},checkbox:{root:"sv_qcbc sv_qcbx",item:"sv_q_checkbox",itemSelectAll:"sv_q_checkbox_selectall",itemNone:"sv_q_checkbox_none",itemChecked:"checked",itemInline:"sv_q_checkbox_inline",label:"sv_q_checkbox_label",labelChecked:"",itemControl:"sv_q_checkbox_control_item",itemDecorator:"sv-hidden",controlLabel:"sv_q_checkbox_control_label",other:"sv_q_other sv_q_checkbox_other",column:"sv_q_select_column"},ranking:{root:"sv-ranking",rootMobileMod:"sv-ranking--mobile",rootDragMod:"sv-ranking--drag",rootDisabled:"sv-ranking--disabled",rootDragHandleAreaIcon:"sv-ranking--drag-handle-area-icon",rootSelectToRankMod:"sv-ranking--select-to-rank",rootSelectToRankAlignVertical:"sv-ranking--select-to-rank-vertical",rootSelectToRankAlignHorizontal:"sv-ranking--select-to-rank-horizontal",rootSelectToRankSwapAreas:"sv-ranking--select-to-rank-swap-areas",item:"sv-ranking-item",itemContent:"sv-ranking-item__content",itemIndex:"sv-ranking-item__index",itemIndexEmptyMode:"sv-ranking-item__index--empty",controlLabel:"sv-ranking-item__text",itemGhostNode:"sv-ranking-item__ghost",itemIconContainer:"sv-ranking-item__icon-container",itemIcon:"sv-ranking-item__icon",itemIconHoverMod:"sv-ranking-item__icon--hover",itemIconFocusMod:"sv-ranking-item__icon--focus",itemGhostMod:"sv-ranking-item--ghost",itemDragMod:"sv-ranking-item--drag",container:"sv-ranking__container",containerEmptyMode:"sv-ranking__container--empty",containerFromMode:"sv-ranking__container--from",containerToMode:"sv-ranking__container--to",containerPlaceholder:"sv-ranking__container-placeholder",containersDivider:"sv-ranking__containers-divider"},comment:{remainingCharacterCounter:"sv-remaining-character-counter"},dropdown:{root:"",popup:"sv-dropdown-popup",control:"sv_q_dropdown_control",controlInputFieldComponent:"sv_q_dropdown_control__input-field-component",selectWrapper:"sv_select_wrapper",other:"sv_q_dd_other",cleanButton:"sv_q_dropdown_clean-button",cleanButtonSvg:"sv_q_dropdown_clean-button-svg",cleanButtonIconId:"icon-clear_16x16",controlValue:"sv_q_dropdown__value",filterStringInput:"sv_q_dropdown__filter-string-input",hintPrefix:"sv_q_dropdown__hint-prefix",hintSuffix:"sv_q_dropdown__hint-suffix"},html:{root:""},image:{root:"sv_q_image",image:"sv_image_image",noImage:"sv-image__no-image",noImageSvgIconId:"icon-no-image"},matrix:{root:"sv_q_matrix",label:"sv_q_m_label",itemChecked:"checked",itemDecorator:"sv-hidden",cell:"sv_q_m_cell",cellText:"sv_q_m_cell_text",cellTextSelected:"sv_q_m_cell_selected",cellLabel:"sv_q_m_cell_label",cellResponsiveTitle:"sv_q_m_cell_responsive_title"},matrixdropdown:{root:"sv_q_matrix_dropdown",cell:"sv_matrix_cell",cellResponsiveTitle:"sv_matrix_cell_responsive_title",headerCell:"sv_matrix_cell_header",row:"sv_matrix_row",rowAdditional:"sv-matrix__row--additional",rowTextCell:"sv-table__cell--row-text",detailRow:"sv_matrix_detail_row",detailRowText:"sv_matrix_cell_detail_rowtext",detailCell:"sv_matrix_cell_detail",choiceCell:"sv-table__cell--choice",detailButton:"sv_matrix_cell_detail_button",detailButtonExpanded:"sv_matrix_cell_detail_button_expanded",detailIcon:"sv_detail_panel_icon",detailIconExpanded:"sv_detail_expanded",detailPanelCell:"sv_matrix_cell_detail_panel",actionsCell:"sv_matrix_cell sv_matrix_cell_actions"},matrixdynamic:{root:"sv_q_matrix_dynamic",button:"sv_matrix_dynamic_button",buttonAdd:"sv_matrix_dynamic_button--add",buttonRemove:"",iconAdd:"",iconRemove:"",iconDrag:"sv-matrixdynamic__drag-icon",cell:"sv_matrix_cell",cellResponsiveTitle:"sv_matrix_cell_responsive_title",headerCell:"sv_matrix_cell_header",row:"sv_matrix_row",detailRow:"sv_matrix_detail_row",detailCell:"sv_matrix_cell_detail",choiceCell:"sv-table__cell--choice",detailButton:"sv_matrix_cell_detail_button",detailButtonExpanded:"sv_matrix_cell_detail_button_expanded",detailIcon:"sv_detail_panel_icon",detailIconExpanded:"sv_detail_expanded",detailPanelCell:"sv_matrix_cell_detail_panel",actionsCell:"sv_matrix_cell sv_matrix_cell_actions",emptyRowsSection:"sv_matrix_empty_rows_section",emptyRowsText:"sv_matrix_empty_rows_text",emptyRowsButton:"",ghostRow:"sv-matrix-row--drag-drop-ghost-mod",draggedRow:"sv-matrixdynamic-dragged-row"},paneldynamic:{root:"sv_panel_dynamic",title:"sv_p_title",header:"sv-paneldynamic__header sv_header",headerTab:"sv-paneldynamic__header-tab",button:"",buttonAdd:"sv-paneldynamic__add-btn",buttonRemove:"sv_p_remove_btn",buttonRemoveRight:"sv_p_remove_btn_right",buttonPrev:"sv-paneldynamic__prev-btn",buttonPrevDisabled:"sv-paneldynamic__prev-btn--disabled",buttonNextDisabled:"sv-paneldynamic__next-btn--disabled",buttonNext:"sv-paneldynamic__next-btn",progressContainer:"sv-paneldynamic__progress-container",progress:"sv-progress",progressBar:"sv-progress__bar",progressText:"sv-paneldynamic__progress-text",panelWrapper:"sv_p_wrapper",panelWrapperInRow:"sv_p_wrapper_in_row",footer:"",progressBtnIcon:"icon-progressbutton"},multipletext:{root:"sv_q_mt",itemTitle:"sv_q_mt_title",item:"sv_q_mt_item",row:"sv_q_mt_row",itemLabel:"sv_q_mt_label",itemValue:"sv_q_mt_item_value sv_q_text_root"},radiogroup:{root:"sv_qcbc",item:"sv_q_radiogroup",itemChecked:"checked",itemInline:"sv_q_radiogroup_inline",itemDecorator:"sv-hidden",label:"sv_q_radiogroup_label",labelChecked:"",itemControl:"sv_q_radiogroup_control_item",controlLabel:"",other:"sv_q_other sv_q_radiogroup_other",clearButton:"sv_q_radiogroup_clear",column:"sv_q_select_column"},buttongroup:{root:"sv-button-group",item:"sv-button-group__item",itemIcon:"sv-button-group__item-icon",itemDecorator:"sv-button-group__item-decorator",itemCaption:"sv-button-group__item-caption",itemHover:"sv-button-group__item--hover",itemSelected:"sv-button-group__item--selected",itemDisabled:"sv-button-group__item--disabled",itemControl:"sv-visuallyhidden"},imagepicker:{root:"sv_imgsel",item:"sv_q_imgsel",itemChecked:"checked",label:"sv_q_imgsel_label",itemControl:"sv_q_imgsel_control_item",image:"sv_q_imgsel_image",itemInline:"sv_q_imagepicker_inline",itemText:"sv_q_imgsel_text",clearButton:"sv_q_radiogroup_clear",column:"sv_q_select_column",itemNoImage:"sv_q_imgsel__no-image",itemNoImageSvgIcon:"sv_q_imgsel__no-image-svg",itemNoImageSvgIconId:"icon-no-image"},rating:{root:"sv_q_rating",item:"sv_q_rating_item",itemFixedSize:"sv_q_rating_item_fixed",selected:"active",minText:"sv_q_rating_min_text",itemText:"sv_q_rating_item_text",maxText:"sv_q_rating_max_text",itemStar:"sv_q_rating__item-star",itemStarSelected:"sv_q_rating__item-star--selected",itemSmiley:"sv_q_rating__item-smiley",itemSmileySelected:"sv_q_rating__item-smiley--selected"},text:{root:"sv_q_text_root",remainingCharacterCounter:"sv-remaining-character-counter"},expression:"",file:{root:"sv_q_file",placeholderInput:"sv-visuallyhidden",previewItem:"sv_q_file_preview",removeButton:"sv_q_file_remove_button",fileInput:"sv-visuallyhidden",removeFile:"sv_q_file_remove",fileDecorator:"sv-file__decorator",fileSign:"sv_q_file_sign",chooseFile:"sv_q_file_choose_button",noFileChosen:"sv_q_file_placeholder",dragAreaPlaceholder:"sv-hidden",fileList:""},signaturepad:{root:"sv_q_signaturepad sjs_sp_container",controls:"sjs_sp_controls",placeholder:"sjs_sp_placeholder",canvas:"sjs_sp_canvas",backgroundImage:"sjs_sp__background-image",clearButton:"sjs_sp_clear"},saveData:{root:"sv-save-data_root",rootWithButtons:"sv-save-data_root--with-buttons",info:"sv-save-data_info",error:"sv-save-data_error",success:"sv-save-data_success",button:"sv-save-data_button",shown:"sv-save-data_root--shown"},window:{root:"sv_window",rootCollapsedMod:"sv_window--collapsed",rootFullScreenMode:"sv_window--full-screen",rootContent:"sv_window_root-content",body:"sv_window_content",header:{root:"sv_window_header",titleCollapsed:"sv_window_header_title_collapsed",buttonsContainer:"sv_window_buttons_container",button:"sv_window_button",buttonExpanded:"",buttonCollapsed:"",collapseButton:"sv_window_button sv_window_button_collapse",closeButton:"sv_window_button sv_window_button_close",fullScreenButton:"sv_window_button sv_window_button_full_screen"}},variables:{mobileWidth:"--sv-mobile-width",themeMark:"--sv-default-mark"},tagbox:{root:"",popup:"sv-dropdown-popup",small:"sv_q_row__question--small",selectWrapper:"sv_select_wrapper sv_q_tagbox_wrapper",other:"sv_q_input sv_q_comment sv_q_selectbase__other",cleanButton:"sv_q_tagbox_clean-button sv_q_dropdown_clean-button",cleanButtonSvg:"sv_q_tagbox_clean-button-svg sv_q_dropdown_clean-button-svg",cleanButtonIconId:"icon-clear_16x16",cleanItemButton:"sv_q_tagbox-item_clean-button",cleanItemButtonSvg:"sv_q_tagbox-item_clean-button-svg",cleanItemButtonIconId:"icon-clear_16x16",control:"sv_q_input sv_q_tagbox sv_q_dropdown_control",controlValue:"sv_q_tagbox__value sv_q_dropdown__value",controlEmpty:"sv_q_dropdown--empty sv_q_tagbox--empty",placeholderInput:"sv_q_tagbox__placeholder",filterStringInput:"sv_q_tagbox__filter-string-input sv_q_dropdown__filter-string-input",hint:"sv_q_tagbox__hint",hintPrefix:"sv_q_dropdown__hint-prefix sv_q_tagbox__hint-prefix",hintSuffix:"sv_q_dropdown__hint-suffix sv_q_tagbox__hint-suffix",hintSuffixWrapper:"sv_q_tagbox__hint-suffix-wrapper"}};Xo.default=cl,Xo.orange=cl,Xo.darkblue=cl,Xo.darkrose=cl,Xo.stone=cl,Xo.winter=cl,Xo.winterstone=cl;var pl={root:"sv-root-modern",rootProgress:"sv-progress",timerRoot:"sv-body__timer",container:"sv-container-modern",header:"sv-title sv-container-modern__title",headerClose:"sv-container-modern__close",bodyContainer:"sv-components-row",body:"sv-body",bodyEmpty:"sv-body sv-body--empty",footer:"sv-footer sv-body__footer sv-clearfix",title:"",description:"",logo:"sv-logo",logoImage:"sv-logo__image",headerText:"sv-header__text",navigationButton:"sv-btn sv-btn--navigation",completedPage:"sv-completedpage",navigation:{complete:"sv-footer__complete-btn",prev:"sv-footer__prev-btn",next:"sv-footer__next-btn",start:"sv-footer__start-btn",preview:"sv-footer__preview-btn",edit:"sv-footer__edit-btn"},panel:{title:"sv-title sv-panel__title",titleExpandable:"sv-panel__title--expandable",titleExpandableSvg:"sd-element__title-expandable-svg",titleExpanded:"sv-panel__title--expanded",titleCollapsed:"sv-panel__title--collapsed",titleOnError:"sv-panel__title--error",description:"sv-description sv-panel__description",container:"sv-panel sv-row__panel",content:"sv-panel__content",icon:"sv-panel__icon",iconExpanded:"sv-panel__icon--expanded",footer:"sv-panel__footer",requiredText:"sv-panel__required-text",number:"sv-question__num"},paneldynamic:{root:"sv-paneldynamic",navigation:"sv-paneldynamic__navigation",title:"sv-title sv-question__title",button:"sv-btn",buttonRemove:"sv-paneldynamic__remove-btn",buttonRemoveRight:"sv-paneldynamic__remove-btn--right",buttonAdd:"sv-paneldynamic__add-btn",progressTop:"sv-paneldynamic__progress sv-paneldynamic__progress--top",progressBottom:"sv-paneldynamic__progress sv-paneldynamic__progress--bottom",buttonPrev:"sv-paneldynamic__prev-btn",buttonNext:"sv-paneldynamic__next-btn",buttonPrevDisabled:"sv-paneldynamic__prev-btn--disabled",buttonNextDisabled:"sv-paneldynamic__next-btn--disabled",progressContainer:"sv-paneldynamic__progress-container",progress:"sv-progress",progressBar:"sv-progress__bar",progressText:"sv-paneldynamic__progress-text",separator:"sv-paneldynamic__separator",panelWrapper:"sv-paneldynamic__panel-wrapper",panelWrapperInRow:"sv-paneldynamic__panel-wrapper--in-row",progressBtnIcon:"icon-progressbutton",footer:""},progress:"sv-progress sv-body__progress",progressBar:"sv-progress__bar",progressText:"sv-progress__text",progressTextInBar:"sv-hidden",progressButtonsContainerCenter:"sv_progress-buttons__container-center",progressButtonsContainer:"sv_progress-buttons__container",progressButtonsImageButtonLeft:"sv_progress-buttons__image-button-left",progressButtonsImageButtonRight:"sv_progress-buttons__image-button-right",progressButtonsImageButtonHidden:"sv_progress-buttons__image-button--hidden",progressButtonsListContainer:"sv_progress-buttons__list-container",progressButtonsList:"sv_progress-buttons__list",progressButtonsListElementPassed:"sv_progress-buttons__list-element--passed",progressButtonsListElementCurrent:"sv_progress-buttons__list-element--current",progressButtonsListElementNonClickable:"sv_progress-buttons__list-element--nonclickable",progressButtonsPageTitle:"sv_progress-buttons__page-title",progressButtonsPageDescription:"sv_progress-buttons__page-description",page:{root:"sv-page sv-body__page",title:"sv-title sv-page__title",number:"sv-page__num",description:"sv-description sv-page__description"},pageTitle:"sv-title sv-page__title",pageDescription:"sv-description sv-page__description",row:"sv-row sv-clearfix",question:{mainRoot:"sv-question sv-row__question",flowRoot:"sv-question sv-row__question sv-row__question--flow",asCell:"sv-table__cell",header:"sv-question__header",headerLeft:"sv-question__header--location--left",headerTop:"sv-question__header--location--top",headerBottom:"sv-question__header--location--bottom",content:"sv-question__content",contentLeft:"sv-question__content--left",titleLeftRoot:"",answered:"sv-question--answered",titleOnAnswer:"sv-question__title--answer",titleOnError:"sv-question__title--error",title:"sv-title sv-question__title",titleExpandable:"sv-question__title--expandable",titleExpandableSvg:"sd-element__title-expandable-svg",titleExpanded:"sv-question__title--expanded",titleCollapsed:"sv-question__title--collapsed",icon:"sv-question__icon",iconExpanded:"sv-question__icon--expanded",requiredText:"sv-question__required-text",number:"sv-question__num",description:"sv-description sv-question__description",descriptionUnderInput:"sv-description sv-question__description",comment:"sv-comment",required:"sv-question--required",titleRequired:"sv-question__title--required",indent:20,footer:"sv-question__footer",formGroup:"sv-question__form-group",hasError:"",disabled:"sv-question--disabled"},image:{root:"sv-image",image:"sv_image_image"},error:{root:"sv-question__erbox",icon:"",item:"",locationTop:"sv-question__erbox--location--top",locationBottom:"sv-question__erbox--location--bottom"},checkbox:{root:"sv-selectbase",item:"sv-item sv-checkbox sv-selectbase__item",itemSelectAll:"sv-checkbox--selectall",itemNone:"sv-checkbox--none",itemDisabled:"sv-item--disabled sv-checkbox--disabled",itemChecked:"sv-checkbox--checked",itemHover:"sv-checkbox--allowhover",itemInline:"sv-selectbase__item--inline",label:"sv-selectbase__label",labelChecked:"",itemControl:"sv-visuallyhidden sv-item__control",itemDecorator:"sv-item__svg sv-checkbox__svg",itemSvgIconId:"#icon-moderncheck",controlLabel:"sv-item__control-label",materialDecorator:"sv-item__decorator sv-selectbase__decorator sv-checkbox__decorator",other:"sv-comment sv-question__other",column:"sv-selectbase__column"},ranking:{root:"sv-ranking",rootMobileMod:"sv-ranking--mobile",rootDragMod:"sv-ranking--drag",rootDisabled:"sv-ranking--disabled",rootDragHandleAreaIcon:"sv-ranking--drag-handle-area-icon",rootSelectToRankMod:"sv-ranking--select-to-rank",rootSelectToRankAlignVertical:"sv-ranking--select-to-rank-vertical",rootSelectToRankAlignHorizontal:"sv-ranking--select-to-rank-horizontal",rootSelectToRankSwapAreas:"sv-ranking--select-to-rank-swap-areas",item:"sv-ranking-item",itemContent:"sv-ranking-item__content",itemIndex:"sv-ranking-item__index",itemIndexEmptyMode:"sv-ranking-item__index--empty",controlLabel:"sv-ranking-item__text",itemGhostNode:"sv-ranking-item__ghost",itemIconContainer:"sv-ranking-item__icon-container",itemIcon:"sv-ranking-item__icon",itemIconHoverMod:"sv-ranking-item__icon--hover",itemIconFocusMod:"sv-ranking-item__icon--focus",itemGhostMod:"sv-ranking-item--ghost",itemDragMod:"sv-ranking-item--drag",container:"sv-ranking__container",containerEmptyMode:"sv-ranking__container--empty",containerFromMode:"sv-ranking__container--from",containerToMode:"sv-ranking__container--to",containerPlaceholder:"sv-ranking__container-placeholder",containersDivider:"sv-ranking__containers-divider"},radiogroup:{root:"sv-selectbase",item:"sv-item sv-radio sv-selectbase__item",itemInline:"sv-selectbase__item--inline",label:"sv-selectbase__label",labelChecked:"",itemDisabled:"sv-item--disabled sv-radio--disabled",itemChecked:"sv-radio--checked",itemHover:"sv-radio--allowhover",itemControl:"sv-visuallyhidden sv-item__control",itemDecorator:"sv-item__svg sv-radio__svg",itemSvgIconId:"#icon-modernradio",controlLabel:"sv-item__control-label",materialDecorator:"sv-item__decorator sv-selectbase__decorator sv-radio__decorator",other:"sv-comment sv-question__other",clearButton:"sv-btn sv-selectbase__clear-btn",column:"sv-selectbase__column"},buttongroup:{root:"sv-button-group",item:"sv-button-group__item",itemIcon:"sv-button-group__item-icon",itemDecorator:"sv-button-group__item-decorator",itemCaption:"sv-button-group__item-caption",itemSelected:"sv-button-group__item--selected",itemHover:"sv-button-group__item--hover",itemDisabled:"sv-button-group__item--disabled",itemControl:"sv-visuallyhidden"},boolean:{root:"sv_qbln",rootRadio:"sv_qbln",small:"sv-row__question--small",item:"sv-boolean sv-item",control:"sv-visuallyhidden",itemChecked:"sv-boolean--checked",itemIndeterminate:"sv-boolean--indeterminate",itemDisabled:"sv-item--disabled sv-boolean--disabled",switch:"sv-boolean__switch",slider:"sv-boolean__slider",label:"sv-boolean__label",disabledLabel:"sv-boolean__label--disabled",sliderGhost:"sv-boolean__thumb-ghost",rootCheckbox:"sv_qbln",checkboxItem:"sv-boolean sv-item",checkboxItemChecked:"sv-boolean--checked",controlCheckbox:"sv-visuallyhidden",checkboxControlLabel:"sv-boolean__label",checkboxItemIndeterminate:"sv-boolean--indeterminate",checkboxItemDisabled:"sv-item--disabled sv-boolean--disabled",checkboxMaterialDecorator:"sv-item__decorator sv-boolean__decorator ",checkboxItemDecorator:"sv-item__svg sv-boolean__svg",indeterminatePath:"sv-boolean__indeterminate-path",svgIconCheckedId:"#icon-modernbooleancheckchecked",svgIconUncheckedId:"#icon-modernbooleancheckunchecked",svgIconIndId:"#icon-modernbooleancheckind"},text:{root:"sv-text",small:"sv-row__question--small",remainingCharacterCounter:"sv-remaining-character-counter",onError:"sv-text--error"},multipletext:{root:"sv-multipletext",item:"sv-multipletext__item",itemLabel:"sv-multipletext__item-label",itemTitle:"sv-multipletext__item-title",row:"sv-multipletext__row",cell:"sv-multipletext__cell"},dropdown:{root:"",popup:"sv-dropdown-popup",small:"sv-row__question--small",control:"sv-dropdown",selectWrapper:"",other:"sv-comment sv-question__other",onError:"sv-dropdown--error",cleanButton:"sv-dropdown_clean-button",cleanButtonSvg:"sv-dropdown_clean-button-svg",cleanButtonIconId:"icon-clear_16x16",filterStringInput:"sv-dropdown__filter-string-input",controlValue:"sv-dropdown__value",controlInputFieldComponent:"sv_dropdown_control__input-field-component",hintPrefix:"sv-dropdown__hint-prefix",hintSuffix:"sv-dropdown__hint-suffix"},tagbox:{root:"",popup:"sv-dropdown-popup",small:"sv-row__question--small",selectWrapper:"sv_select_wrapper sv-tagbox_wrapper",other:"sv-input sv-comment sv-selectbase__other",cleanButton:"sv-tagbox_clean-button sv-dropdown_clean-button",cleanButtonSvg:"sv-tagbox_clean-button-svg sv-dropdown_clean-button-svg",cleanButtonIconId:"icon-clear_16x16",cleanItemButton:"sv-tagbox__item_clean-button",cleanItemButtonSvg:"sv-tagbox__item_clean-button-svg",cleanItemButtonIconId:"icon-clear_16x16",control:"sv-input sv-tagbox sv-dropdown",controlValue:"sv-tagbox__value sv-dropdown__value",controlEmpty:"sv-dropdown--empty sv-tagbox--empty",placeholderInput:"sv-tagbox__placeholder",filterStringInput:"sv-tagbox__filter-string-input sv-dropdown__filter-string-input"},imagepicker:{root:"sv-selectbase sv-imagepicker",column:"sv-selectbase__column",item:"sv-imagepicker__item",itemInline:"sv-imagepicker__item--inline",itemChecked:"sv-imagepicker__item--checked",itemDisabled:"sv-imagepicker__item--disabled",itemHover:"sv-imagepicker__item--allowhover",label:"sv-imagepicker__label",itemControl:"sv-imagepicker__control sv-visuallyhidden",image:"sv-imagepicker__image",itemText:"sv-imagepicker__text",clearButton:"sv-btn",other:"sv-comment sv-question__other"},matrix:{tableWrapper:"sv-matrix",root:"sv-table sv-matrix-root",rowError:"sv-matrix__row--error",cell:"sv-table__cell sv-matrix__cell",headerCell:"sv-table__cell sv-table__cell--header",label:"sv-item sv-radio sv-matrix__label",itemValue:"sv-visuallyhidden sv-item__control sv-radio__control",itemChecked:"sv-radio--checked",itemDisabled:"sv-item--disabled sv-radio--disabled",itemHover:"sv-radio--allowhover",materialDecorator:"sv-item__decorator sv-radio__decorator",itemDecorator:"sv-item__svg sv-radio__svg",cellText:"sv-matrix__text",cellTextSelected:"sv-matrix__text--checked",cellTextDisabled:"sv-matrix__text--disabled",cellResponsiveTitle:"sv-matrix__cell-responsive-title",itemSvgIconId:"#icon-modernradio"},matrixdropdown:{root:"sv-table sv-matrixdropdown",cell:"sv-table__cell",cellResponsiveTitle:"sv-table__responsive-title",headerCell:"sv-table__cell sv-table__cell--header",row:"sv-table__row",rowTextCell:"sv-table__cell--row-text",rowAdditional:"sv-table__row--additional",detailRow:"sv-table__row--detail",detailRowText:"sv-table__cell--detail-rowtext",detailCell:"sv-table__cell--detail",choiceCell:"sv-table__cell--choice",detailButton:"sv-table__cell--detail-button",detailButtonExpanded:"sv-table__cell--detail-button--expanded",detailIcon:"sv-detail-panel__icon",detailIconExpanded:"sv-detail-panel__icon--expanded",detailPanelCell:"sv-table__cell--detail-panel",actionsCell:"sv-table__cell sv-table__cell--actions"},matrixdynamic:{root:"sv-table sv-matrixdynamic",cell:"sv-table__cell",cellResponsiveTitle:"sv-table__responsive-title",headerCell:"sv-table__cell sv-table__cell--header",button:"sv-btn",buttonAdd:"sv-matrixdynamic__add-btn",buttonRemove:"sv-matrixdynamic__remove-btn",iconAdd:"",iconRemove:"",iconDrag:"sv-matrixdynamic__drag-icon",row:"sv-table__row",detailRow:"sv-table__row--detail",detailCell:"sv-table__cell--detail",choiceCell:"sv-table__cell--choice",detailButton:"sv-table__cell--detail-button",detailButtonExpanded:"sv-table__cell--detail-button--expanded",detailIcon:"sv-detail-panel__icon",detailIconExpanded:"sv-detail-panel__icon--expanded",detailPanelCell:"sv-table__cell--detail-panel",actionsCell:"sv-table__cell sv-table__cell--actions",emptyRowsSection:"sv-table__empty--rows--section",emptyRowsText:"sv-table__empty--rows--text",emptyRowsButton:"",ghostRow:"sv-matrix-row--drag-drop-ghost-mod",draggedRow:"sv-matrixdynamic-dragged-row"},rating:{root:"sv-rating",item:"sv-rating__item",selected:"sv-rating__item--selected",minText:"sv-rating__min-text",itemText:"sv-rating__item-text",maxText:"sv-rating__max-text",itemDisabled:"sv-rating--disabled",filterStringInput:"sv-dropdown__filter-string-input",control:"sv-dropdown",cleanButton:"sv-dropdown_clean-button",cleanButtonSvg:"sv-dropdown_clean-button-svg",cleanButtonIconId:"icon-clear_16x16",controlValue:"sv-dropdown__value",controlInputFieldComponent:"sv_dropdown_control__input-field-component",itemSmiley:"sv-rating__item-smiley",itemStar:"sv-rating__item-star",itemSmileySelected:"sv-rating__item-smiley--selected",itemStarSelected:"sv-rating__item-star--selected"},comment:{root:"sv-comment",small:"sv-row__question--small",remainingCharacterCounter:"sv-remaining-character-counter"},expression:"",file:{root:"sv-file",other:"sv-comment sv-question__other",placeholderInput:"sv-visuallyhidden",previewItem:"sd-file__preview-item",fileSignBottom:"sv-file__sign",fileDecorator:"sv-file__decorator",fileInput:"sv-visuallyhidden",noFileChosen:"sv-description sv-file__no-file-chosen",chooseFile:"sv-btn sv-file__choose-btn",controlDisabled:"sv-file__choose-btn--disabled",removeButton:"sv-hidden",removeButtonBottom:"sv-btn sv-file__clean-btn",removeFile:"sv-hidden",removeFileSvg:"sv-file__remove-svg",removeFileSvgIconId:"icon-removefile",wrapper:"sv-file__wrapper",dragAreaPlaceholder:"sv-hidden",fileList:""},signaturepad:{root:"sv-signaturepad sjs_sp_container",small:"sv-row__question--small",controls:"sjs_sp_controls",placeholder:"sjs_sp_placeholder",canvas:"sjs_sp_canvas",backgroundImage:"sjs_sp__background-image",clearButton:"sjs_sp_clear"},saveData:{root:"sv-save-data_root",rootWithButtons:"sv-save-data_root--with-buttons",info:"sv-save-data_info",error:"sv-save-data_error",success:"sv-save-data_success",button:"sv-save-data_button",shown:"sv-save-data_root--shown"},window:{root:"sv_window",rootCollapsedMod:"sv_window--collapsed",rootFullScreenMode:"sv_window--full-screen",rootContent:"sv_window_root-content",body:"sv_window_content",header:{root:"sv_window_header",titleCollapsed:"sv_window_header_title_collapsed",buttonsContainer:"sv_window_buttons_container",button:"sv_window_button",buttonExpanded:"",buttonCollapsed:"",collapseButton:"sv_window_button sv_window_button_collapse",closeButton:"sv_window_button sv_window_button_close",fullScreenButton:"sv_window_button sv_window_button_full_screen"}},variables:{mobileWidth:"--sv-mobile-width",themeMark:"--sv-modern-mark"}};Xo.modern=pl;var hl=function(){function e(){this.icons={},this.iconPrefix="icon-",this.onIconsChanged=new Se}return e.prototype.processId=function(e,t){return 0==e.indexOf(t)&&(e=e.substring(t.length)),e=It[e]||e},e.prototype.registerIconFromSymbol=function(e,t){this.icons[e]=t},e.prototype.registerIconFromSvgViaElement=function(e,t,n){if(void 0===n&&(n=this.iconPrefix),i.isAvailable()){e=this.processId(e,n);var o=i.createElement("div");o.innerHTML=t;var r=i.createElement("symbol"),s=o.querySelector("svg");r.innerHTML=s.innerHTML;for(var a=0;a<s.attributes.length;a++)r.setAttributeNS("http://www.w3.org/2000/svg",s.attributes[a].name,s.attributes[a].value);r.id=n+e,this.registerIconFromSymbol(e,r.outerHTML)}},e.prototype.registerIconFromSvg=function(e,t,n){void 0===n&&(n=this.iconPrefix),e=this.processId(e,n);var o=(t=t.trim()).toLowerCase();return"<svg "===o.substring(0,"<svg ".length)&&"</svg>"===o.substring(o.length-"</svg>".length,o.length)&&(this.registerIconFromSymbol(e,'<symbol id="'+n+e+'" '+t.substring("<svg ".length,o.length-"</svg>".length)+"</symbol>"),!0)},e.prototype.registerIconsFromFolder=function(e){var t=this;e.keys().forEach((function(n){t.registerIconFromSvg(n.substring(2,n.length-4).toLowerCase(),e(n))}))},e.prototype.registerIcons=function(e){for(var t in e)this.registerIconFromSvg(t,e[t]);this.updateMarkup()},e.prototype.iconsRenderedHtml=function(){var e=this;return Object.keys(this.icons).map((function(t){return e.icons[t]})).join("")},e.prototype.updateMarkup=function(){this.onIconsChanged.fire(this,{})},e}(),dl=new hl,fl={};function gl(e,t){fl[e]||(fl[e]={});var n=fl[e];for(var o in t)n[o]=t[o]}}})}));
11
+ class zs{constructor(e,t,n,o){if(isNaN(e)||isNaN(t))throw new Error(`Point is invalid: (${e}, ${t})`);this.x=+e,this.y=+t,this.pressure=n||0,this.time=o||Date.now()}distanceTo(e){return Math.sqrt(Math.pow(this.x-e.x,2)+Math.pow(this.y-e.y,2))}equals(e){return this.x===e.x&&this.y===e.y&&this.pressure===e.pressure&&this.time===e.time}velocityFrom(e){return this.time!==e.time?this.distanceTo(e)/(this.time-e.time):0}}class Hs{static fromPoints(e,t){const n=this.calculateControlPoints(e[0],e[1],e[2]).c2,o=this.calculateControlPoints(e[1],e[2],e[3]).c1;return new Hs(e[1],n,o,e[2],t.start,t.end)}static calculateControlPoints(e,t,n){const o=e.x-t.x,i=e.y-t.y,r=t.x-n.x,s=t.y-n.y,a=(e.x+t.x)/2,l=(e.y+t.y)/2,u=(t.x+n.x)/2,c=(t.y+n.y)/2,p=Math.sqrt(o*o+i*i),h=Math.sqrt(r*r+s*s),d=h/(p+h),f=u+(a-u)*d,g=c+(l-c)*d,y=t.x-f,m=t.y-g;return{c1:new zs(a+y,l+m),c2:new zs(u+y,c+m)}}constructor(e,t,n,o,i,r){this.startPoint=e,this.control2=t,this.control1=n,this.endPoint=o,this.startWidth=i,this.endWidth=r}length(){let e,t,n=0;for(let o=0;o<=10;o+=1){const i=o/10,r=this.point(i,this.startPoint.x,this.control1.x,this.control2.x,this.endPoint.x),s=this.point(i,this.startPoint.y,this.control1.y,this.control2.y,this.endPoint.y);if(o>0){const o=r-e,i=s-t;n+=Math.sqrt(o*o+i*i)}e=r,t=s}return n}point(e,t,n,o,i){return t*(1-e)*(1-e)*(1-e)+3*n*(1-e)*(1-e)*e+3*o*(1-e)*e*e+i*e*e*e}}class Us extends class{constructor(){try{this._et=new EventTarget}catch(e){this._et=document}}addEventListener(e,t,n){this._et.addEventListener(e,t,n)}dispatchEvent(e){return this._et.dispatchEvent(e)}removeEventListener(e,t,n){this._et.removeEventListener(e,t,n)}}{constructor(e,t={}){super(),this.canvas=e,this._drawingStroke=!1,this._isEmpty=!0,this._lastPoints=[],this._data=[],this._lastVelocity=0,this._lastWidth=0,this._handleMouseDown=e=>{1===e.buttons&&this._strokeBegin(e)},this._handleMouseMove=e=>{this._strokeMoveUpdate(e)},this._handleMouseUp=e=>{1===e.buttons&&this._strokeEnd(e)},this._handleTouchStart=e=>{if(e.cancelable&&e.preventDefault(),1===e.targetTouches.length){const t=e.changedTouches[0];this._strokeBegin(t)}},this._handleTouchMove=e=>{e.cancelable&&e.preventDefault();const t=e.targetTouches[0];this._strokeMoveUpdate(t)},this._handleTouchEnd=e=>{if(e.target===this.canvas){e.cancelable&&e.preventDefault();const t=e.changedTouches[0];this._strokeEnd(t)}},this._handlePointerStart=e=>{e.preventDefault(),this._strokeBegin(e)},this._handlePointerMove=e=>{this._strokeMoveUpdate(e)},this._handlePointerEnd=e=>{this._drawingStroke&&(e.preventDefault(),this._strokeEnd(e))},this.velocityFilterWeight=t.velocityFilterWeight||.7,this.minWidth=t.minWidth||.5,this.maxWidth=t.maxWidth||2.5,this.throttle="throttle"in t?t.throttle:16,this.minDistance="minDistance"in t?t.minDistance:5,this.dotSize=t.dotSize||0,this.penColor=t.penColor||"black",this.backgroundColor=t.backgroundColor||"rgba(0,0,0,0)",this.compositeOperation=t.compositeOperation||"source-over",this.canvasContextOptions="canvasContextOptions"in t?t.canvasContextOptions:{},this._strokeMoveUpdate=this.throttle?function(e,t=250){let n,o,i,r=0,s=null;const a=()=>{r=Date.now(),s=null,n=e.apply(o,i),s||(o=null,i=[])};return function(...l){const u=Date.now(),c=t-(u-r);return o=this,i=l,c<=0||c>t?(s&&(clearTimeout(s),s=null),r=u,n=e.apply(o,i),s||(o=null,i=[])):s||(s=window.setTimeout(a,c)),n}}(Us.prototype._strokeUpdate,this.throttle):Us.prototype._strokeUpdate,this._ctx=e.getContext("2d",this.canvasContextOptions),this.clear(),this.on()}clear(){const{_ctx:e,canvas:t}=this;e.fillStyle=this.backgroundColor,e.clearRect(0,0,t.width,t.height),e.fillRect(0,0,t.width,t.height),this._data=[],this._reset(this._getPointGroupOptions()),this._isEmpty=!0}fromDataURL(e,t={}){return new Promise((n,o)=>{const i=new Image,r=t.ratio||window.devicePixelRatio||1,s=t.width||this.canvas.width/r,a=t.height||this.canvas.height/r,l=t.xOffset||0,u=t.yOffset||0;this._reset(this._getPointGroupOptions()),i.onload=()=>{this._ctx.drawImage(i,l,u,s,a),n()},i.onerror=e=>{o(e)},i.crossOrigin="anonymous",i.src=e,this._isEmpty=!1})}toDataURL(e="image/png",t){switch(e){case"image/svg+xml":return"object"!=typeof t&&(t=void 0),"data:image/svg+xml;base64,"+btoa(this.toSVG(t));default:return"number"!=typeof t&&(t=void 0),this.canvas.toDataURL(e,t)}}on(){this.canvas.style.touchAction="none",this.canvas.style.msTouchAction="none",this.canvas.style.userSelect="none";const e=/Macintosh/.test(navigator.userAgent)&&"ontouchstart"in document;window.PointerEvent&&!e?this._handlePointerEvents():(this._handleMouseEvents(),"ontouchstart"in window&&this._handleTouchEvents())}off(){this.canvas.style.touchAction="auto",this.canvas.style.msTouchAction="auto",this.canvas.style.userSelect="auto",this.canvas.removeEventListener("pointerdown",this._handlePointerStart),this.canvas.removeEventListener("pointermove",this._handlePointerMove),this.canvas.ownerDocument.removeEventListener("pointerup",this._handlePointerEnd),this.canvas.removeEventListener("mousedown",this._handleMouseDown),this.canvas.removeEventListener("mousemove",this._handleMouseMove),this.canvas.ownerDocument.removeEventListener("mouseup",this._handleMouseUp),this.canvas.removeEventListener("touchstart",this._handleTouchStart),this.canvas.removeEventListener("touchmove",this._handleTouchMove),this.canvas.removeEventListener("touchend",this._handleTouchEnd)}isEmpty(){return this._isEmpty}fromData(e,{clear:t=!0}={}){t&&this.clear(),this._fromData(e,this._drawCurve.bind(this),this._drawDot.bind(this)),this._data=this._data.concat(e)}toData(){return this._data}_getPointGroupOptions(e){return{penColor:e&&"penColor"in e?e.penColor:this.penColor,dotSize:e&&"dotSize"in e?e.dotSize:this.dotSize,minWidth:e&&"minWidth"in e?e.minWidth:this.minWidth,maxWidth:e&&"maxWidth"in e?e.maxWidth:this.maxWidth,velocityFilterWeight:e&&"velocityFilterWeight"in e?e.velocityFilterWeight:this.velocityFilterWeight,compositeOperation:e&&"compositeOperation"in e?e.compositeOperation:this.compositeOperation}}_strokeBegin(e){if(!this.dispatchEvent(new CustomEvent("beginStroke",{detail:e,cancelable:!0})))return;this._drawingStroke=!0;const t=this._getPointGroupOptions(),n=Object.assign(Object.assign({},t),{points:[]});this._data.push(n),this._reset(t),this._strokeUpdate(e)}_strokeUpdate(e){if(!this._drawingStroke)return;if(0===this._data.length)return void this._strokeBegin(e);this.dispatchEvent(new CustomEvent("beforeUpdateStroke",{detail:e}));const t=e.clientX,n=e.clientY,o=void 0!==e.pressure?e.pressure:void 0!==e.force?e.force:0,i=this._createPoint(t,n,o),r=this._data[this._data.length-1],s=r.points,a=s.length>0&&s[s.length-1],l=!!a&&i.distanceTo(a)<=this.minDistance,u=this._getPointGroupOptions(r);if(!a||!a||!l){const e=this._addPoint(i,u);a?e&&this._drawCurve(e,u):this._drawDot(i,u),s.push({time:i.time,x:i.x,y:i.y,pressure:i.pressure})}this.dispatchEvent(new CustomEvent("afterUpdateStroke",{detail:e}))}_strokeEnd(e){this._drawingStroke&&(this._strokeUpdate(e),this._drawingStroke=!1,this.dispatchEvent(new CustomEvent("endStroke",{detail:e})))}_handlePointerEvents(){this._drawingStroke=!1,this.canvas.addEventListener("pointerdown",this._handlePointerStart),this.canvas.addEventListener("pointermove",this._handlePointerMove),this.canvas.ownerDocument.addEventListener("pointerup",this._handlePointerEnd)}_handleMouseEvents(){this._drawingStroke=!1,this.canvas.addEventListener("mousedown",this._handleMouseDown),this.canvas.addEventListener("mousemove",this._handleMouseMove),this.canvas.ownerDocument.addEventListener("mouseup",this._handleMouseUp)}_handleTouchEvents(){this.canvas.addEventListener("touchstart",this._handleTouchStart),this.canvas.addEventListener("touchmove",this._handleTouchMove),this.canvas.addEventListener("touchend",this._handleTouchEnd)}_reset(e){this._lastPoints=[],this._lastVelocity=0,this._lastWidth=(e.minWidth+e.maxWidth)/2,this._ctx.fillStyle=e.penColor,this._ctx.globalCompositeOperation=e.compositeOperation}_createPoint(e,t,n){const o=this.canvas.getBoundingClientRect();return new zs(e-o.left,t-o.top,n,(new Date).getTime())}_addPoint(e,t){const{_lastPoints:n}=this;if(n.push(e),n.length>2){3===n.length&&n.unshift(n[0]);const e=this._calculateCurveWidths(n[1],n[2],t),o=Hs.fromPoints(n,e);return n.shift(),o}return null}_calculateCurveWidths(e,t,n){const o=n.velocityFilterWeight*t.velocityFrom(e)+(1-n.velocityFilterWeight)*this._lastVelocity,i=this._strokeWidth(o,n),r={end:i,start:this._lastWidth};return this._lastVelocity=o,this._lastWidth=i,r}_strokeWidth(e,t){return Math.max(t.maxWidth/(e+1),t.minWidth)}_drawCurveSegment(e,t,n){const o=this._ctx;o.moveTo(e,t),o.arc(e,t,n,0,2*Math.PI,!1),this._isEmpty=!1}_drawCurve(e,t){const n=this._ctx,o=e.endWidth-e.startWidth,i=2*Math.ceil(e.length());n.beginPath(),n.fillStyle=t.penColor;for(let n=0;n<i;n+=1){const r=n/i,s=r*r,a=s*r,l=1-r,u=l*l,c=u*l;let p=c*e.startPoint.x;p+=3*u*r*e.control1.x,p+=3*l*s*e.control2.x,p+=a*e.endPoint.x;let h=c*e.startPoint.y;h+=3*u*r*e.control1.y,h+=3*l*s*e.control2.y,h+=a*e.endPoint.y;const d=Math.min(e.startWidth+a*o,t.maxWidth);this._drawCurveSegment(p,h,d)}n.closePath(),n.fill()}_drawDot(e,t){const n=this._ctx,o=t.dotSize>0?t.dotSize:(t.minWidth+t.maxWidth)/2;n.beginPath(),this._drawCurveSegment(e.x,e.y,o),n.closePath(),n.fillStyle=t.penColor,n.fill()}_fromData(e,t,n){for(const o of e){const{points:e}=o,i=this._getPointGroupOptions(o);if(e.length>1)for(let n=0;n<e.length;n+=1){const o=e[n],r=new zs(o.x,o.y,o.pressure,o.time);0===n&&this._reset(i);const s=this._addPoint(r,i);s&&t(s,i)}else this._reset(i),n(e[0],i)}}toSVG({includeBackgroundColor:e=!1}={}){const t=this._data,n=Math.max(window.devicePixelRatio||1,1),o=this.canvas.width/n,i=this.canvas.height/n,r=document.createElementNS("http://www.w3.org/2000/svg","svg");if(r.setAttribute("xmlns","http://www.w3.org/2000/svg"),r.setAttribute("xmlns:xlink","http://www.w3.org/1999/xlink"),r.setAttribute("viewBox",`0 0 ${o} ${i}`),r.setAttribute("width",o.toString()),r.setAttribute("height",i.toString()),e&&this.backgroundColor){const e=document.createElement("rect");e.setAttribute("width","100%"),e.setAttribute("height","100%"),e.setAttribute("fill",this.backgroundColor),r.appendChild(e)}return this._fromData(t,(e,{penColor:t})=>{const n=document.createElement("path");if(!(isNaN(e.control1.x)||isNaN(e.control1.y)||isNaN(e.control2.x)||isNaN(e.control2.y))){const o=`M ${e.startPoint.x.toFixed(3)},${e.startPoint.y.toFixed(3)} C ${e.control1.x.toFixed(3)},${e.control1.y.toFixed(3)} ${e.control2.x.toFixed(3)},${e.control2.y.toFixed(3)} ${e.endPoint.x.toFixed(3)},${e.endPoint.y.toFixed(3)}`;n.setAttribute("d",o),n.setAttribute("stroke-width",(2.25*e.endWidth).toFixed(3)),n.setAttribute("stroke",t),n.setAttribute("fill","none"),n.setAttribute("stroke-linecap","round"),r.appendChild(n)}},(e,{penColor:t,dotSize:n,minWidth:o,maxWidth:i})=>{const s=document.createElement("circle"),a=n>0?n:(o+i)/2;s.setAttribute("r",a.toString()),s.setAttribute("cx",e.x.toString()),s.setAttribute("cy",e.y.toString()),s.setAttribute("fill",t),r.appendChild(s)}),r.outerHTML}}var Ws=function(){var e=function(t,n){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(t,n)};return function(t,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function o(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(o.prototype=n.prototype,new o)}}(),Gs=function(e,t,n,o){var i,r=arguments.length,s=r<3?t:null===o?o=Object.getOwnPropertyDescriptor(t,n):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,n,o);else for(var a=e.length-1;a>=0;a--)(i=e[a])&&(s=(r<3?i(s):r>3?i(t,n,s):i(t,n))||s);return r>3&&s&&Object.defineProperty(t,n,s),s},Js=function(e){function t(t){var n=e.call(this,t)||this;return n.valueIsUpdatingInternally=!1,n._loadedData=void 0,n.updateValueHandler=function(){n._loadedData=void 0,n.scaleCanvas(!0,!0)},n}return Ws(t,e),t.prototype.getPenColorFromTheme=function(){var e=this.survey;return!!e&&!!e.themeVariables&&e.themeVariables["--sjs-primary-backcolor"]},t.prototype.updateColors=function(e){var t=this.getPenColorFromTheme(),n=this.getPropertyByName("penColor");e.penColor=this.penColor||t||n.defaultValue||"#1ab394";var o=this.getPropertyByName("backgroundColor"),i=t?"transparent":void 0,r=this.backgroundImage?"transparent":this.backgroundColor;e.backgroundColor=r||i||o.defaultValue||"#ffffff"},t.prototype.getCssRoot=function(t){return(new Ee).append(e.prototype.getCssRoot.call(this,t)).append(t.small,"300"===this.signatureWidth.toString()).toString()},t.prototype.getFormat=function(){return"jpeg"===this.dataFormat?"image/jpeg":"svg"===this.dataFormat?"image/svg+xml":""},t.prototype.updateValue=function(){if(this.signaturePad){var e=this.signaturePad.toDataURL(this.getFormat());this.valueIsUpdatingInternally=!0,this.value=e,this.valueIsUpdatingInternally=!1}},t.prototype.getType=function(){return"signaturepad"},t.prototype.afterRenderQuestionElement=function(t){t&&(this.isDesignMode||this.initSignaturePad(t),this.element=t),e.prototype.afterRenderQuestionElement.call(this,t)},t.prototype.beforeDestroyQuestionElement=function(e){e&&this.destroySignaturePad(e)},t.prototype.themeChanged=function(e){this.signaturePad&&this.updateColors(this.signaturePad)},t.prototype.resizeCanvas=function(){this.canvas.width=this.containerWidth,this.canvas.height=this.containerHeight},t.prototype.scaleCanvas=function(e,t){void 0===e&&(e=!0),void 0===t&&(t=!1);var n=this.canvas,o=n.offsetWidth/this.containerWidth;(this.scale!=o||t)&&(this.scale=o,n.style.width=this.renderedCanvasWidth,this.resizeCanvas(),this.signaturePad.minWidth=this.penMinWidth*o,this.signaturePad.maxWidth=this.penMaxWidth*o,n.getContext("2d").scale(1/o,1/o),e&&this.loadPreview(this.value))},t.prototype.fromUrl=function(e){var t=this;if(this.isFileLoading=!0,function(e){return"string"==typeof e?/^data:((?:\w+\/(?:(?!;).)+)?)((?:;[^;]+?)*),(.+)$/.test(e):null}(e))this.fromDataUrl(e),this.isFileLoading=!1;else{var n=new Image;n.crossOrigin="anonymous",n.src=e,n.onload=function(){if(t.canvas){var e=i.createElement("canvas");e.width=t.containerWidth,e.height=t.containerHeight,e.getContext("2d").drawImage(n,0,0);var o=e.toDataURL(t.getFormat());t.fromDataUrl(o)}t.isFileLoading=!1},n.onerror=function(){t.isFileLoading=!1}}},t.prototype.fromDataUrl=function(e){if(this._loadedData=e,this.signaturePad){var t=1,n=this.scale;if("svg"===this.dataFormat)t=o.getDevicePixelRatio()||1,n=1;var i={width:this.canvas.width*n/t,height:this.canvas.height*n/t};this.signaturePad.fromDataURL(e,i)}},Object.defineProperty(t.prototype,"loadedData",{get:function(){return this._loadedData},enumerable:!1,configurable:!0}),t.prototype.loadPreview=function(e){var t=this;if(!e)return this.signaturePad&&this.canvas&&(this.canvas.getContext("2d").clearRect(0,0,this.canvas.width*this.scale,this.canvas.height*this.scale),this.signaturePad.clear()),void(this.valueWasChangedFromLastUpload=!1);if(this.storeDataAsText)this.fromDataUrl(e);else if(this.loadedData)this.fromDataUrl(this.loadedData);else{var n=e?[e]:[];this._previewLoader&&this._previewLoader.dispose(),this.isFileLoading=!0,this._previewLoader=new ws(this,(function(n,o){"success"===n&&o&&o.length>0&&o[0].content?(t.fromDataUrl(o[0].content),t.isFileLoading=!1):"skipped"===n&&t.fromUrl(e),t._previewLoader.dispose(),t._previewLoader=void 0})),this._previewLoader.load(n)}},t.prototype.onChangeQuestionValue=function(t){e.prototype.onChangeQuestionValue.call(this,t),this.isLoadingFromJson||(this._loadedData=void 0,this.loadPreview(t))},t.prototype.onSurveyLoad=function(){e.prototype.onSurveyLoad.call(this),this.loadPreview(this.value)},t.prototype.initSignaturePad=function(e){var t=this,n=e.getElementsByTagName("canvas")[0];this.canvas=n,this.resizeCanvas();var o=new Us(n,{backgroundColor:"#ffffff"});this.signaturePad=o,this.isInputReadOnly&&o.off(),this.readOnlyChangedCallback=function(){t.isInputReadOnly?o.off():o.on()},this.updateColors(o),o.addEventListener("beginStroke",(function(){t.scaleCanvas(),t.isDrawingValue=!0,n.focus()}),{once:!1}),o.addEventListener("endStroke",(function(){t.isDrawingValue=!1,t.storeDataAsText?t.updateValue():t.valueWasChangedFromLastUpload=!0}),{once:!1}),this.updateValueHandler(),this.readOnlyChangedCallback();var i=function(e,n){"signatureWidth"!==n.name&&"signatureHeight"!==n.name||t.valueIsUpdatingInternally||t.updateValueHandler()};this.onPropertyChanged.add(i),this.signaturePad.propertyChangedHandler=i},t.prototype.destroySignaturePad=function(e){this.signaturePad&&(this.onPropertyChanged.remove(this.signaturePad.propertyChangedHandler),this.signaturePad.off()),this.readOnlyChangedCallback=null,this.signaturePad=null},Object.defineProperty(t.prototype,"dataFormat",{get:function(){return this.getPropertyValue("dataFormat")},set:function(e){this.setPropertyValue("dataFormat",Ks(e))},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"signatureWidth",{get:function(){return this.getPropertyValue("signatureWidth")},set:function(e){this.setPropertyValue("signatureWidth",e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"signatureHeight",{get:function(){return this.getPropertyValue("signatureHeight")},set:function(e){this.setPropertyValue("signatureHeight",e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"containerHeight",{get:function(){return this.signatureHeight||200},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"containerWidth",{get:function(){return this.signatureWidth||300},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"renderedCanvasWidth",{get:function(){return this.signatureAutoScaleEnabled?"100%":this.containerWidth+"px"},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"height",{get:function(){return this.getPropertyValue("height")},set:function(e){this.setPropertyValue("height",e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"allowClear",{get:function(){return this.getPropertyValue("allowClear")},set:function(e){this.setPropertyValue("allowClear",e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"canShowClearButton",{get:function(){var e=!this.nothingIsDrawn(),t=this.isUploading;return!this.isInputReadOnly&&this.allowClear&&e&&!t},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"penColor",{get:function(){return this.getPropertyValue("penColor")},set:function(e){this.setPropertyValue("penColor",e),this.signaturePad&&this.updateColors(this.signaturePad)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"backgroundColor",{get:function(){return this.getPropertyValue("backgroundColor")},set:function(e){this.setPropertyValue("backgroundColor",e),this.signaturePad&&this.updateColors(this.signaturePad)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"backgroundImage",{get:function(){return this.getPropertyValue("backgroundImage")},set:function(e){this.setPropertyValue("backgroundImage",e),this.signaturePad&&this.updateColors(this.signaturePad)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"clearButtonCaption",{get:function(){return this.getLocalizationString("clearCaption")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"locRenderedPlaceholder",{get:function(){return this.isReadOnly?this.locPlaceholderReadOnly:this.locPlaceholder},enumerable:!1,configurable:!0}),t.prototype.nothingIsDrawn=function(){var e=this.isDrawingValue,t=this.isEmpty(),n=this.isUploading,o=this.valueWasChangedFromLastUpload;return!e&&t&&!n&&!o},t.prototype.needShowPlaceholder=function(){return this.showPlaceholder&&this.nothingIsDrawn()},t.prototype.onBlurCore=function(t){if(e.prototype.onBlurCore.call(this,t),!this.storeDataAsText&&!this.element.contains(t.relatedTarget)){if(!this.valueWasChangedFromLastUpload)return;this.uploadFiles([(n=this.signaturePad.toDataURL(this.getFormat()),o=this.name+"."+Ks(this.dataFormat),i=this.getFormat(),r=atob(n.split(",")[1]),s=new Uint8Array(r.split("").map((function(e){return e.charCodeAt(0)}))).buffer,new File([s],o,{type:i}))]),this.valueWasChangedFromLastUpload=!1}var n,o,i,r,s},t.prototype.uploadResultItemToValue=function(e){return e.content},t.prototype.setValueFromResult=function(e){this.valueIsUpdatingInternally=!0,this.value=(null==e?void 0:e.length)?e.map((function(e){return e.content}))[0]:void 0,this.valueIsUpdatingInternally=!1},t.prototype.clearValue=function(t){this.valueWasChangedFromLastUpload=!1,e.prototype.clearValue.call(this,t),this._loadedData=void 0,this.loadPreview(this.value)},t.prototype.endLoadingFromJson=function(){e.prototype.endLoadingFromJson.call(this),300===this.signatureWidth&&this.width&&"number"==typeof this.width&&this.width&&(j.warn("Use signatureWidth property to set width for the signature pad"),this.signatureWidth=this.width,this.width=void 0),200===this.signatureHeight&&this.height&&(j.warn("Use signatureHeight property to set width for the signature pad"),this.signatureHeight=this.height,this.height=void 0)},Gs([m({defaultValue:!1})],t.prototype,"isDrawingValue",void 0),Gs([m({defaultValue:!1})],t.prototype,"isReadyForUpload",void 0),Gs([m({defaultValue:!1})],t.prototype,"valueWasChangedFromLastUpload",void 0),Gs([m()],t.prototype,"signatureAutoScaleEnabled",void 0),Gs([m()],t.prototype,"penMinWidth",void 0),Gs([m()],t.prototype,"penMaxWidth",void 0),Gs([m({})],t.prototype,"showPlaceholder",void 0),Gs([m({localizable:{defaultStr:"signaturePlaceHolder"}})],t.prototype,"placeholder",void 0),Gs([m({localizable:{defaultStr:"signaturePlaceHolderReadOnly"}})],t.prototype,"placeholderReadOnly",void 0),t}(bs);function Ks(e){return e||(e="png"),"jpeg"!==(e=e.replace("image/","").replace("+xml",""))&&"svg"!==e&&(e="png"),e}D.addClass("signaturepad",[{name:"signatureWidth:number",category:"general",default:300},{name:"signatureHeight:number",category:"general",default:200},{name:"signatureAutoScaleEnabled:boolean",category:"general",default:!1},{name:"penMinWidth:number",category:"general",default:.5},{name:"penMaxWidth:number",category:"general",default:2.5},{name:"height:number",category:"general",visible:!1},{name:"allowClear:boolean",category:"general",default:!0},{name:"showPlaceholder:boolean",category:"general",default:!0},{name:"placeholder:text",serializationProperty:"locPlaceholder",category:"general",dependsOn:"showPlaceholder",visibleIf:function(e){return e.showPlaceholder}},{name:"placeholderReadOnly:text",serializationProperty:"locPlaceholderReadOnly",category:"general",dependsOn:"showPlaceholder",visibleIf:function(e){return e.showPlaceholder}},{name:"backgroundImage:file",category:"general"},{name:"penColor:color",category:"general"},{name:"backgroundColor:color",category:"general"},{name:"dataFormat",category:"general",default:"png",choices:[{value:"png",text:"PNG"},{value:"jpeg",text:"JPEG"},{value:"svg",text:"SVG"}],onSettingValue:function(e,t){return Ks(t)}},{name:"defaultValue",visible:!1},{name:"correctAnswer",visible:!1},{name:"storeDataAsText:boolean",default:!0},{name:"waitForUpload:boolean",default:!1}],(function(){return new Js("")}),"question"),ao.Instance.registerQuestion("signaturepad",(function(e){return new Js(e)}));var $s=function(){var e=function(t,n){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(t,n)};return function(t,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function o(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(o.prototype=n.prototype,new o)}}(),Ys=function(e,t,n,o){var i,r=arguments.length,s=r<3?t:null===o?o=Object.getOwnPropertyDescriptor(t,n):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,n,o);else for(var a=e.length-1;a>=0;a--)(i=e[a])&&(s=(r<3?i(s):r>3?i(t,n,s):i(t,n))||s);return r>3&&s&&Object.defineProperty(t,n,s),s},Xs=function(e,t){for(var n=0,o=t.length,i=e.length;n<o;n++,i++)e[i]=t[n];return e},Zs=function(e){function t(t,n,o){var i=e.call(this,o)||this;return i.data=t,i.panelItem=n,i.variableName=o,i.sharedQuestions={},i}return $s(t,e),Object.defineProperty(t.prototype,"survey",{get:function(){return this.panelItem.getSurvey()},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"panel",{get:function(){return this.panelItem.panel},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"panelIndex",{get:function(){return this.data?this.data.getItemIndex(this.panelItem):-1},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"visiblePanelIndex",{get:function(){return this.data?this.data.getVisibleItemIndex(this.panelItem):-1},enumerable:!1,configurable:!0}),t.prototype.getValues=function(){return this.panelItem.getAllValues()},t.prototype.getQuestionByName=function(t){var n=e.prototype.getQuestionByName.call(this,t);if(n)return n;var o=this.panelIndex,i=(n=o>-1?this.data.getSharedQuestionFromArray(t,o):void 0)?n.name:t;return this.sharedQuestions[i]=t,n},t.prototype.getQuestionDisplayText=function(t){var n=this.sharedQuestions[t.name];if(!n)return e.prototype.getQuestionDisplayText.call(this,t);var o=this.panelItem.getValue(n);return t.getDisplayValue(!0,o)},t.prototype.onCustomProcessText=function(e){var n;if(e.name==ta.IndexVariableName&&(n=this.panelIndex)>-1)return e.isExists=!0,e.value=n+1,!0;if(e.name==ta.VisibleIndexVariableName&&(n=this.visiblePanelIndex)>-1)return e.isExists=!0,e.value=n+1,!0;if(0==e.name.toLowerCase().indexOf(ta.ParentItemVariableName+".")){var o=this.data;if(o&&o.parentQuestion&&o.parent&&o.parent.data){var i=new t(o.parentQuestion,o.parent.data,ta.ItemVariableName),r=ta.ItemVariableName+e.name.substring(ta.ParentItemVariableName.length),s=i.processValue(r,e.returnDisplayValue);e.isExists=s.isExists,e.value=s.value}return!0}return!1},t}(Zn),ea=function(e){function t(t){return e.call(this,t)||this}return $s(t,e),t}(Xe),ta=function(){function e(t,n){this.data=t,this.panelValue=n,this.textPreProcessor=new Zs(t,this,e.ItemVariableName),this.setSurveyImpl()}return Object.defineProperty(e.prototype,"panel",{get:function(){return this.panelValue},enumerable:!1,configurable:!0}),e.prototype.setSurveyImpl=function(){this.panel.setSurveyImpl(this)},e.prototype.getValue=function(e){return this.getAllValues()[e]},e.prototype.setValue=function(t,n){var o=this.data.getPanelItemData(this),i=o?o[t]:void 0;if(!s.isTwoValueEquals(n,i,!1,!0,!1)){this.data.setPanelItemData(this,t,s.getUnbindValue(n));for(var r=this.panel.questions,a=0;a<r.length;a++){var l=r[a];l.getValueName()!==t&&l.checkBindings(t,n);var u=Xt.commentSuffix;if(t.endsWith(u)){t=t.substring(0,t.length-u.length);var c=this.panel.getQuestionByName(t);c&&(n=c.value)}var p=e.ItemVariableName+"."+t;l.runTriggers(p,n)}}},e.prototype.getVariable=function(e){},e.prototype.setVariable=function(e,t){},e.prototype.getComment=function(e){var t=this.getValue(e+Xt.commentSuffix);return t||""},e.prototype.setComment=function(e,t,n){this.setValue(e+Xt.commentSuffix,t)},e.prototype.findQuestionByName=function(t){if(t){var n=e.ItemVariableName+".";if(0===t.indexOf(n))return this.panel.getQuestionByName(t.substring(n.length));var o=this.getSurvey();return o?o.getQuestionByName(t):null}},e.prototype.getEditingSurveyElement=function(){},e.prototype.getAllValues=function(){return this.data.getPanelItemData(this)},e.prototype.getFilteredValues=function(){var t={},n=this.data&&this.data.getRootData()?this.data.getRootData().getFilteredValues():{};for(var o in n)t[o]=n[o];if(t[e.ItemVariableName]=this.getAllValues(),this.data){var i=e.IndexVariableName,r=e.VisibleIndexVariableName;delete t[i],delete t[r],t[i.toLowerCase()]=this.data.getItemIndex(this),t[r.toLowerCase()]=this.data.getVisibleItemIndex(this);var s=this.data;s&&s.parentQuestion&&s.parent&&(t[e.ParentItemVariableName]=s.parent.getValue())}return t},e.prototype.getFilteredProperties=function(){return this.data&&this.data.getRootData()?this.data.getRootData().getFilteredProperties():{survey:this.getSurvey()}},e.prototype.getSurveyData=function(){return this},e.prototype.getSurvey=function(){return this.data?this.data.getSurvey():null},e.prototype.getTextProcessor=function(){return this.textPreProcessor},e.ItemVariableName="panel",e.ParentItemVariableName="parentpanel",e.IndexVariableName="panelIndex",e.VisibleIndexVariableName="visiblePanelIndex",e}(),na=function(){function e(e){this.data=e}return e.prototype.getSurveyData=function(){return null},e.prototype.getSurvey=function(){return this.data.getSurvey()},e.prototype.getTextProcessor=function(){return null},e}(),oa=function(e){function t(t){var n=e.call(this,t)||this;return n._renderedPanels=[],n.isPanelsAnimationRunning=!1,n.isAddingNewPanels=!1,n.isSetPanelItemData={},n.createNewArray("panels",(function(e){n.onPanelAdded(e)}),(function(e){n.onPanelRemoved(e)})),n.createNewArray("visiblePanels"),n.templateValue=n.createAndSetupNewPanelObject(),n.template.renderWidth="100%",n.template.selectedElementInDesign=n,n.template.addElementCallback=function(e){n.addOnPropertyChangedCallback(e),n.rebuildPanels()},n.template.removeElementCallback=function(){n.rebuildPanels()},n.createLocalizableString("confirmDeleteText",n,!1,"confirmDelete"),n.createLocalizableString("keyDuplicationError",n,!1,!0),n.createLocalizableString("panelAddText",n,!1,"addPanel"),n.createLocalizableString("panelRemoveText",n,!1,"removePanel"),n.createLocalizableString("panelPrevText",n,!1,"pagePrevText"),n.createLocalizableString("panelNextText",n,!1,"pageNextText"),n.createLocalizableString("noEntriesText",n,!1,"noEntriesText"),n.createLocalizableString("templateTabTitle",n,!0,"panelDynamicTabTextFormat"),n.createLocalizableString("tabTitlePlaceholder",n,!0,"tabTitlePlaceholder"),n.registerPropertyChangedHandlers(["panelsState"],(function(){n.setPanelsState()})),n.registerPropertyChangedHandlers(["newPanelPosition","displayMode","showProgressBar"],(function(){n.updateFooterActions()})),n.registerPropertyChangedHandlers(["allowAddPanel"],(function(){n.updateNoEntriesTextDefaultLoc()})),n.registerPropertyChangedHandlers(["minPanelCount"],(function(){n.onMinPanelCountChanged()})),n.registerPropertyChangedHandlers(["maxPanelCount"],(function(){n.onMaxPanelCountChanged()})),n}return $s(t,e),Object.defineProperty(t.prototype,"isCompositeQuestion",{get:function(){return!0},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"hasSingleInput",{get:function(){return!1},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isContainer",{get:function(){return!0},enumerable:!1,configurable:!0}),t.prototype.getFirstQuestionToFocus=function(e){for(var t=0;t<this.visiblePanelsCore.length;t++){var n=this.visiblePanelsCore[t].getFirstQuestionToFocus(e);if(n)return n}return this.showAddPanelButton&&(!e||this.currentErrorCount>0)?this:null},t.prototype.getFirstInputElementId=function(){return this.showAddPanelButton?this.addButtonId:e.prototype.getFirstInputElementId.call(this)},t.prototype.setSurveyImpl=function(t,n){e.prototype.setSurveyImpl.call(this,t,n),this.setTemplatePanelSurveyImpl(),this.setPanelsSurveyImpl()},t.prototype.assignOnPropertyChangedToTemplate=function(){for(var e=this.template.elements,t=0;t<e.length;t++)this.addOnPropertyChangedCallback(e[t])},t.prototype.addOnPropertyChangedCallback=function(e){var t=this;e.isQuestion&&e.setParentQuestion(this),e.onPropertyChanged.add((function(e,n){t.onTemplateElementPropertyChanged(e,n)})),e.isPanel&&(e.addElementCallback=function(e){t.addOnPropertyChangedCallback(e)})},t.prototype.onTemplateElementPropertyChanged=function(e,t){if(!this.isLoadingFromJson&&!this.useTemplatePanel&&0!=this.panelsCore.length&&D.findProperty(e.getType(),t.name))for(var n=this.panelsCore,o=0;o<n.length;o++){var i=n[o].getQuestionByName(e.name);i&&i[t.name]!==t.newValue&&(i[t.name]=t.newValue)}},Object.defineProperty(t.prototype,"useTemplatePanel",{get:function(){return this.isDesignMode&&!this.isContentElement},enumerable:!1,configurable:!0}),t.prototype.getType=function(){return"paneldynamic"},t.prototype.clearOnDeletingContainer=function(){this.panelsCore.forEach((function(e){e.clearOnDeletingContainer()}))},Object.defineProperty(t.prototype,"isAllowTitleLeft",{get:function(){return!1},enumerable:!1,configurable:!0}),t.prototype.removeElement=function(e){return this.template.removeElement(e)},Object.defineProperty(t.prototype,"template",{get:function(){return this.templateValue},enumerable:!1,configurable:!0}),t.prototype.getPanel=function(){return this.template},Object.defineProperty(t.prototype,"templateElements",{get:function(){return this.template.elements},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"templateTitle",{get:function(){return this.template.title},set:function(e){this.template.title=e},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"locTemplateTitle",{get:function(){return this.template.locTitle},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"templateTabTitle",{get:function(){return this.locTemplateTabTitle.text},set:function(e){this.locTemplateTabTitle.text=e},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"locTemplateTabTitle",{get:function(){return this.getLocalizableString("templateTabTitle")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"tabTitlePlaceholder",{get:function(){return this.locTabTitlePlaceholder.text},set:function(e){this.locTabTitlePlaceholder.text=e},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"locTabTitlePlaceholder",{get:function(){return this.getLocalizableString("tabTitlePlaceholder")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"templateDescription",{get:function(){return this.template.description},set:function(e){this.template.description=e},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"locTemplateDescription",{get:function(){return this.template.locDescription},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"templateVisibleIf",{get:function(){return this.getPropertyValue("templateVisibleIf")},set:function(e){this.setPropertyValue("templateVisibleIf",e),this.template.visibleIf=e},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"items",{get:function(){for(var e=[],t=0;t<this.panelsCore.length;t++)e.push(this.panelsCore[t].data);return e},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"panels",{get:function(){return this.buildPanelsFirstTime(this.canBuildPanels),this.panelsCore},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"visiblePanels",{get:function(){return this.buildPanelsFirstTime(this.canBuildPanels),this.visiblePanelsCore},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"panelsCore",{get:function(){return this.getPropertyValue("panels")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"visiblePanelsCore",{get:function(){return this.getPropertyValue("visiblePanels")},enumerable:!1,configurable:!0}),t.prototype.onPanelAdded=function(e){if(this.onPanelRemovedCore(e),e.visible){for(var t=0,n=this.panelsCore,o=0;o<n.length&&n[o]!==e;o++)n[o].visible&&t++;this.visiblePanelsCore.splice(t,0,e),this.addTabFromToolbar(e,t),this.currentPanel||(this.currentPanel=e),this.updateRenderedPanels()}},t.prototype.onPanelRemoved=function(e){var t=this.onPanelRemovedCore(e);if(this.currentPanel===e){var n=this.visiblePanelsCore;t>=n.length&&(t=n.length-1),this.currentPanel=t>=0?n[t]:null}this.updateRenderedPanels()},t.prototype.onPanelRemovedCore=function(e){var t=this.visiblePanelsCore,n=t.indexOf(e);return n>-1&&(t.splice(n,1),this.removeTabFromToolbar(e)),n},Object.defineProperty(t.prototype,"currentIndex",{get:function(){return this.isRenderModeList?-1:this.useTemplatePanel?0:this.visiblePanelsCore.indexOf(this.currentPanel)},set:function(e){e<0||this.visiblePanelCount<1||(e>=this.visiblePanelCount&&(e=this.visiblePanelCount-1),this.currentPanel=this.visiblePanelsCore[e])},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"currentPanel",{get:function(){if(this.isDesignMode)return this.template;if(this.isRenderModeList||this.useTemplatePanel)return null;var e=this.getPropertyValue("currentPanel",null);return!e&&this.visiblePanelCount>0&&(e=this.visiblePanelsCore[0],this.currentPanel=e),e},set:function(e){if(!this.isRenderModeList&&!this.useTemplatePanel){var t=this.getPropertyValue("currentPanel"),n=e?this.visiblePanelsCore.indexOf(e):-1;if(!(e&&n<0||e===t)&&(t&&t.onHidingContent(),this.setPropertyValue("currentPanel",e),this.updateRenderedPanels(),this.updateFooterActions(),this.updateTabToolbarItemsPressedState(),this.fireCallback(this.currentIndexChangedCallback),n>-1&&this.survey)){var o={panel:e,visiblePanelIndex:n};this.survey.dynamicPanelCurrentIndexChanged(this,o)}}},enumerable:!1,configurable:!0}),t.prototype.updateRenderedPanels=function(){this.isRenderModeList?this.renderedPanels=[].concat(this.visiblePanels):this.currentPanel?this.renderedPanels=[this.currentPanel]:this.renderedPanels=[]},Object.defineProperty(t.prototype,"renderedPanels",{get:function(){return this._renderedPanels},set:function(e){0==this.renderedPanels.length||0==e.length?(this.blockAnimations(),this.panelsAnimation.sync(e),this.releaseAnimations()):(this.isPanelsAnimationRunning=!0,this.panelsAnimation.sync(e))},enumerable:!1,configurable:!0}),t.prototype.getPanelsAnimationOptions=function(){var e=this,t=function(){if(e.isRenderModeList)return"";var t=new Ee,n=!1,o=e.renderedPanels.filter((function(t){return t!==e.currentPanel}))[0],i=e.visiblePanels.indexOf(o);return i<0&&(n=!0,i=e.removedPanelIndex),t.append("sv-pd-animation-adding",!!e.focusNewPanelCallback).append("sv-pd-animation-removing",n).append("sv-pd-animation-left",i<=e.currentIndex).append("sv-pd-animation-right",i>e.currentIndex).toString()};return{getRerenderEvent:function(){return e.onElementRerendered},getAnimatedElement:function(t){var n,o;if(t&&e.cssContent){var i=Bt(e.cssContent);return null===(o=null===(n=e.getWrapperElement())||void 0===n?void 0:n.querySelector(":scope "+i+" #"+t.id))||void 0===o?void 0:o.parentElement}},getEnterOptions:function(){return{onBeforeRunAnimation:function(t){if(e.focusNewPanelCallback){var n=e.isRenderModeList?t:t.parentElement;ft.ScrollElementToViewCore(n,!1,!1,{behavior:"smooth"})}!e.isRenderModeList&&t.parentElement?Jt(t.parentElement,{heightTo:t.offsetHeight+"px"}):Kt(t)},onAfterRunAnimation:function(e){$t(e),e.parentElement&&$t(e.parentElement)},cssClass:(new Ee).append(e.cssClasses.panelWrapperEnter).append(t()).toString()}},getLeaveOptions:function(){return{onBeforeRunAnimation:function(t){!e.isRenderModeList&&t.parentElement?Jt(t.parentElement,{heightFrom:t.offsetHeight+"px"}):Kt(t)},onAfterRunAnimation:function(e){$t(e),e.parentElement&&$t(e.parentElement)},cssClass:(new Ee).append(e.cssClasses.panelWrapperLeave).append(t()).toString()}},isAnimationEnabled:function(){return e.animationAllowed&&!!e.getWrapperElement()}}},t.prototype.disablePanelsAnimations=function(){this.panelsCore.forEach((function(e){e.blockAnimations()}))},t.prototype.enablePanelsAnimations=function(){this.panelsCore.forEach((function(e){e.releaseAnimations()}))},t.prototype.updatePanelsAnimation=function(){var e=this;this._panelsAnimations=new(this.isRenderModeList?ut:ct)(this.getPanelsAnimationOptions(),(function(t,n){e._renderedPanels=t,n||(e.isPanelsAnimationRunning=!1,e.focusNewPanel())}),(function(){return e._renderedPanels}))},Object.defineProperty(t.prototype,"panelsAnimation",{get:function(){return this._panelsAnimations||this.updatePanelsAnimation(),this._panelsAnimations},enumerable:!1,configurable:!0}),t.prototype.onHidingContent=function(){e.prototype.onHidingContent.call(this),this.currentPanel?this.currentPanel.onHidingContent():this.visiblePanelsCore.forEach((function(e){return e.onHidingContent()}))},Object.defineProperty(t.prototype,"confirmDelete",{get:function(){return this.getPropertyValue("confirmDelete")},set:function(e){this.setPropertyValue("confirmDelete",e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"keyName",{get:function(){return this.getPropertyValue("keyName","")},set:function(e){this.setPropertyValue("keyName",e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"confirmDeleteText",{get:function(){return this.getLocalizableStringText("confirmDeleteText")},set:function(e){this.setLocalizableStringText("confirmDeleteText",e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"locConfirmDeleteText",{get:function(){return this.getLocalizableString("confirmDeleteText")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"keyDuplicationError",{get:function(){return this.getLocalizableStringText("keyDuplicationError")},set:function(e){this.setLocalizableStringText("keyDuplicationError",e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"locKeyDuplicationError",{get:function(){return this.getLocalizableString("keyDuplicationError")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"panelPrevText",{get:function(){return this.getLocalizableStringText("panelPrevText")},set:function(e){this.setLocalizableStringText("panelPrevText",e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"locPanelPrevText",{get:function(){return this.getLocalizableString("panelPrevText")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"panelNextText",{get:function(){return this.getLocalizableStringText("panelNextText")},set:function(e){this.setLocalizableStringText("panelNextText",e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"locPanelNextText",{get:function(){return this.getLocalizableString("panelNextText")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"panelAddText",{get:function(){return this.getLocalizableStringText("panelAddText")},set:function(e){this.setLocalizableStringText("panelAddText",e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"locPanelAddText",{get:function(){return this.getLocalizableString("panelAddText")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"panelRemoveText",{get:function(){return this.getLocalizableStringText("panelRemoveText")},set:function(e){this.setLocalizableStringText("panelRemoveText",e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"locPanelRemoveText",{get:function(){return this.getLocalizableString("panelRemoveText")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isProgressTopShowing",{get:function(){return"carousel"==this.displayMode&&("top"===this.progressBarLocation||"topBottom"===this.progressBarLocation)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isProgressBottomShowing",{get:function(){return"carousel"==this.displayMode&&("bottom"===this.progressBarLocation||"topBottom"===this.progressBarLocation)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isPrevButtonVisible",{get:function(){return this.currentIndex>0},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isPrevButtonShowing",{get:function(){return this.isPrevButtonVisible},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isNextButtonVisible",{get:function(){return this.currentIndex>=0&&this.currentIndex<this.visiblePanelCount-1},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isNextButtonShowing",{get:function(){return this.isNextButtonVisible},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isRangeShowing",{get:function(){return this.showRangeInProgress&&this.currentIndex>=0&&this.visiblePanelCount>1},enumerable:!1,configurable:!0}),t.prototype.getElementsInDesign=function(e){return void 0===e&&(e=!1),e?[this.template]:this.templateElements},t.prototype.prepareValueForPanelCreating=function(){this.addingNewPanelsValue=this.value,this.isAddingNewPanels=!0,this.isNewPanelsValueChanged=!1},t.prototype.setValueAfterPanelsCreating=function(){this.isAddingNewPanels=!1,this.isNewPanelsValueChanged&&(this.isValueChangingInternally=!0,this.value=this.addingNewPanelsValue,this.isValueChangingInternally=!1)},t.prototype.getValueCore=function(){return this.isAddingNewPanels?this.addingNewPanelsValue:e.prototype.getValueCore.call(this)},t.prototype.setValueCore=function(t){this.isAddingNewPanels?(this.isNewPanelsValueChanged=!0,this.addingNewPanelsValue=t):e.prototype.setValueCore.call(this,t)},t.prototype.setIsMobile=function(t){e.prototype.setIsMobile.call(this,t),(this.panelsCore||[]).forEach((function(e){return e.getQuestions(!0).forEach((function(e){e.setIsMobile(t)}))}))},t.prototype.themeChanged=function(t){e.prototype.themeChanged.call(this,t),(this.panelsCore||[]).forEach((function(e){return e.getQuestions(!0).forEach((function(e){e.themeChanged(t)}))}))},Object.defineProperty(t.prototype,"panelCount",{get:function(){return!this.canBuildPanels||this.wasNotRenderedInSurvey?this.getPropertyValue("panelCount"):this.panelsCore.length},set:function(e){if(!(e<0)){if(!this.canBuildPanels||this.wasNotRenderedInSurvey)return this.setPropertyValue("panelCount",e),void this.updateFooterActions();if(e!=this.panelsCore.length&&!this.useTemplatePanel){this.updateBindings("panelCount",e),this.prepareValueForPanelCreating();for(var t=this.panelCount;t<e;t++){var n=this.createNewPanel();this.panelsCore.push(n),"list"==this.displayMode&&"default"!=this.panelsState&&("expanded"===this.panelsState?n.expand():n.title&&n.collapse())}e<this.panelCount&&this.panelsCore.splice(e,this.panelCount-e),this.disablePanelsAnimations(),this.setValueAfterPanelsCreating(),this.setValueBasedOnPanelCount(),this.reRunCondition(),this.updateFooterActions(),this.fireCallback(this.panelCountChangedCallback),this.enablePanelsAnimations()}}},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"visiblePanelCount",{get:function(){return this.visiblePanels.length},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"panelsState",{get:function(){return this.getPropertyValue("panelsState")},set:function(e){this.setPropertyValue("panelsState",e)},enumerable:!1,configurable:!0}),t.prototype.setTemplatePanelSurveyImpl=function(){this.template.setSurveyImpl(this.useTemplatePanel?this.surveyImpl:new na(this))},t.prototype.setPanelsSurveyImpl=function(){for(var e=0;e<this.panelsCore.length;e++){var t=this.panelsCore[e];t!=this.template&&t.setSurveyImpl(t.data)}},t.prototype.setPanelsState=function(){if(!this.useTemplatePanel&&"list"==this.displayMode&&this.templateTitle)for(var e=0;e<this.panelsCore.length;e++){var t=this.panelsState;"firstExpanded"===t&&(t=0===e?"expanded":"collapsed"),this.panelsCore[e].state=t}},t.prototype.setValueBasedOnPanelCount=function(){var e=this.value;if(e&&Array.isArray(e)||(e=[]),e.length!=this.panelCount){for(var t=e.length;t<this.panelCount;t++){var n=this.panels[t].getValue(),o=s.isValueEmpty(n)?{}:n;e.push(o)}e.length>this.panelCount&&e.splice(this.panelCount,e.length-this.panelCount),this.isValueChangingInternally=!0,this.value=e,this.isValueChangingInternally=!1}},Object.defineProperty(t.prototype,"minPanelCount",{get:function(){return this.getPropertyValue("minPanelCount")},set:function(e){e<0&&(e=0),this.setPropertyValue("minPanelCount",e)},enumerable:!1,configurable:!0}),t.prototype.onMinPanelCountChanged=function(){var e=this.minPanelCount;e>this.maxPanelCount&&(this.maxPanelCount=e),this.panelCount<e&&(this.panelCount=e)},Object.defineProperty(t.prototype,"maxPanelCount",{get:function(){return this.getPropertyValue("maxPanelCount")},set:function(e){e<=0||(e>Xt.panel.maxPanelCount&&(e=Xt.panel.maxPanelCount),this.setPropertyValue("maxPanelCount",e),this.updateFooterActions())},enumerable:!1,configurable:!0}),t.prototype.onMaxPanelCountChanged=function(){var e=this.maxPanelCount;e<this.minPanelCount&&(this.minPanelCount=e),this.panelCount>e&&(this.panelCount=e),this.updateFooterActions()},Object.defineProperty(t.prototype,"allowAddPanel",{get:function(){return this.getPropertyValue("allowAddPanel")},set:function(e){this.setPropertyValue("allowAddPanel",e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"addButtonId",{get:function(){return this.id+"addPanel"},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"newPanelPosition",{get:function(){return this.getPropertyValue("newPanelPosition")},set:function(e){this.setPropertyValue("newPanelPosition",e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"allowRemovePanel",{get:function(){return this.getPropertyValue("allowRemovePanel")},set:function(e){this.setPropertyValue("allowRemovePanel",e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"templateTitleLocation",{get:function(){return this.getPropertyValue("templateTitleLocation")},set:function(e){this.setPropertyValue("templateTitleLocation",e.toLowerCase())},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"templateErrorLocation",{get:function(){return this.getPropertyValue("templateErrorLocation")},set:function(e){this.setPropertyValue("templateErrorLocation",e.toLowerCase())},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"showQuestionNumbers",{get:function(){return this.getPropertyValue("showQuestionNumbers")},set:function(e){this.setPropertyValue("showQuestionNumbers",e),!this.isLoadingFromJson&&this.survey&&this.survey.questionVisibilityChanged(this,this.visible,!0)},enumerable:!1,configurable:!0}),t.prototype.notifySurveyOnChildrenVisibilityChanged=function(){return"onSurvey"===this.showQuestionNumbers},Object.defineProperty(t.prototype,"panelRemoveButtonLocation",{get:function(){return this.getPropertyValue("panelRemoveButtonLocation")},set:function(e){this.setPropertyValue("panelRemoveButtonLocation",e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"showRangeInProgress",{get:function(){return this.showProgressBar},set:function(e){this.showProgressBar=e},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"renderMode",{get:function(){var e=this.displayMode;if("carousel"==e){var t=this.progressBarLocation;if("top"==t)return"progressTop";if("bottom"==t)return"progressBottom";if("topBottom"==t)return"progressTopBottom"}return e},set:function(e){(e||"").startsWith("progress")?("progressTop"==e?this.progressBarLocation="top":"progressBottom"==e?this.progressBarLocation="bottom":"progressTopBottom"==e&&(this.progressBarLocation="topBottom"),this.displayMode="carousel"):this.displayMode=e},enumerable:!1,configurable:!0}),t.prototype.updatePanelView=function(){this.blockAnimations(),this.updateRenderedPanels(),this.releaseAnimations(),this.updatePanelsAnimation()},Object.defineProperty(t.prototype,"tabAlign",{get:function(){return this.getPropertyValue("tabAlign")},set:function(e){this.setPropertyValue("tabAlign",e),this.isRenderModeTab&&(this.tabbedMenu.containerCss=this.getTabbedMenuCss())},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isRenderModeList",{get:function(){return"list"===this.displayMode},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isRenderModeTab",{get:function(){return"tab"===this.displayMode},enumerable:!1,configurable:!0}),t.prototype.setVisibleIndex=function(t){if(!this.isVisible)return 0;for(var n="onSurvey"===this.showQuestionNumbers,o=n?t:0,i=this.isDesignMode?[this.template]:this.visiblePanelsCore,r=0;r<i.length;r++){var s=this.setPanelVisibleIndex(i[r],o,"off"!=this.showQuestionNumbers);n&&(o+=s)}return e.prototype.setVisibleIndex.call(this,n?-1:t),n?o-t:1},t.prototype.setPanelVisibleIndex=function(e,t,n){return n?e.setVisibleIndex(t):(e.setVisibleIndex(-1),0)},Object.defineProperty(t.prototype,"canAddPanel",{get:function(){return!this.isDesignMode&&(!(this.isDefaultV2Theme&&!this.legacyNavigation&&!this.isRenderModeList&&this.currentIndex<this.visiblePanelCount-1&&"next"!==this.newPanelPosition)&&(this.allowAddPanel&&!this.isReadOnly&&this.panelCount<this.maxPanelCount))},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"canRemovePanel",{get:function(){return!this.isDesignMode&&(this.allowRemovePanel&&!this.isReadOnly&&this.panelCount>this.minPanelCount)},enumerable:!1,configurable:!0}),t.prototype.rebuildPanels=function(){var e;if(!this.isLoadingFromJson){this.prepareValueForPanelCreating();var t=[];if(this.useTemplatePanel)new ta(this,this.template),t.push(this.template);else for(var n=0;n<this.panelCount;n++)this.createNewPanel(),t.push(this.createNewPanel());(e=this.panelsCore).splice.apply(e,Xs([0,this.panelsCore.length],t)),this.setValueAfterPanelsCreating(),this.setPanelsState(),this.reRunCondition(),this.updateFooterActions(),this.fireCallback(this.panelCountChangedCallback),this.updateTabToolbar()}},Object.defineProperty(t.prototype,"defaultPanelValue",{get:function(){return this.getPropertyValue("defaultPanelValue")},set:function(e){this.setPropertyValue("defaultPanelValue",e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"defaultValueFromLastPanel",{get:function(){return this.getPropertyValue("defaultValueFromLastPanel")},set:function(e){this.setPropertyValue("defaultValueFromLastPanel",e)},enumerable:!1,configurable:!0}),t.prototype.isDefaultValueEmpty=function(){return e.prototype.isDefaultValueEmpty.call(this)&&this.isValueEmpty(this.defaultPanelValue)},t.prototype.setDefaultValue=function(){if(!this.isValueEmpty(this.defaultPanelValue)&&this.isValueEmpty(this.defaultValue)){if(this.isEmpty()&&0!=this.panelCount){for(var t=[],n=0;n<this.panelCount;n++)t.push(this.defaultPanelValue);this.value=t}}else e.prototype.setDefaultValue.call(this)},Object.defineProperty(t.prototype,"isValueArray",{get:function(){return!0},enumerable:!1,configurable:!0}),t.prototype.isEmpty=function(){var e=this.value;if(!e||!Array.isArray(e))return!0;for(var t=0;t<e.length;t++)if(!this.isRowEmpty(e[t]))return!1;return!0},t.prototype.getProgressInfo=function(){return ft.getProgressInfoByElements(this.visiblePanelsCore,this.isRequired)},t.prototype.isRowEmpty=function(e){for(var t in e)if(e.hasOwnProperty(t))return!1;return!0},t.prototype.addPanelUI=function(){if(!this.canAddPanel)return null;if(!this.canLeaveCurrentPanel())return null;var e=this.addPanel();return"list"===this.displayMode&&"default"!==this.panelsState&&e.expand(),this.focusNewPanelCallback=function(){e.focusFirstQuestion()},this.isPanelsAnimationRunning||this.focusNewPanel(),e},t.prototype.focusNewPanel=function(){this.focusNewPanelCallback&&(this.focusNewPanelCallback(),this.focusNewPanelCallback=void 0)},t.prototype.addPanel=function(e){var t=this.currentIndex;return void 0===e&&(e=t<0?this.panelCount:t+1),(e<0||e>this.panelCount)&&(e=this.panelCount),this.updateValueOnAddingPanel(t<0?this.panelCount-1:t,e),this.isRenderModeList||(this.currentIndex=e),this.notifyOnPanelAddedRemoved(!0,e),this.panelsCore[e]},t.prototype.updateValueOnAddingPanel=function(e,t){this.panelCount++;var n=this.value;if(Array.isArray(n)&&n.length===this.panelCount){var o=!1,i=this.panelCount-1;if(t<i){o=!0;var r=n[i];n.splice(i,1),n.splice(t,0,r)}if(this.isValueEmpty(this.defaultPanelValue)||(o=!0,this.copyValue(n[t],this.defaultPanelValue)),this.defaultValueFromLastPanel&&n.length>1){var s=e>-1&&e<=i?e:i;o=!0,this.copyValue(n[t],n[s])}o&&(this.value=n)}},t.prototype.canLeaveCurrentPanel=function(){return!("list"!==this.displayMode&&this.currentPanel&&this.currentPanel.hasErrors(!0,!0))},t.prototype.copyValue=function(e,t){for(var n in t)e[n]=t[n]},t.prototype.removePanelUI=function(e){var t=this,n=this.getVisualPanelIndex(e);if(!(n<0||n>=this.visiblePanelCount)&&this.canRemovePanel){var o=function(){var e;t.removePanel(n);var o=t.visiblePanelCount,i=n>=o?o-1:n,r=0===o?t.addButtonId:i>-1?t.getPanelRemoveButtonId(t.visiblePanels[i]):"";r&&ft.FocusElement(r,!0,null===(e=t.survey)||void 0===e?void 0:e.rootElement)};this.isRequireConfirmOnDelete(e)?bt({message:this.confirmDeleteText,funcOnYes:function(){o()},locale:this.getLocale(),rootElement:this.survey.rootElement,cssClass:this.cssClasses.confirmDialog}):o()}},t.prototype.getPanelRemoveButtonId=function(e){return e.id+"_remove_button"},t.prototype.isRequireConfirmOnDelete=function(e){if(!this.confirmDelete)return!1;var t=this.getVisualPanelIndex(e);if(t<0||t>=this.visiblePanelCount)return!1;var n=this.visiblePanelsCore[t].getValue();return!this.isValueEmpty(n)&&(this.isValueEmpty(this.defaultPanelValue)||!this.isTwoValueEquals(n,this.defaultPanelValue))},t.prototype.goToNextPanel=function(){return!(this.currentIndex<0)&&(!!this.canLeaveCurrentPanel()&&(this.currentIndex++,!0))},t.prototype.goToPrevPanel=function(){this.currentIndex<0||this.currentIndex--},t.prototype.removePanel=function(e){var t=this.getVisualPanelIndex(e);if(!(t<0||t>=this.visiblePanelCount)){this.removedPanelIndex=t;var n=this.visiblePanelsCore[t],o=this.panelsCore.indexOf(n);if(!(o<0))if(!this.survey||this.survey.dynamicPanelRemoving(this,o,n))this.panelsCore.splice(o,1),this.updateBindings("panelCount",this.panelCount),!(e=this.value)||!Array.isArray(e)||o>=e.length?this.updateFooterActions():(this.isValueChangingInternally=!0,e.splice(o,1),this.value=e,this.updateFooterActions(),this.fireCallback(this.panelCountChangedCallback),this.notifyOnPanelAddedRemoved(!1,o,n),this.isValueChangingInternally=!1)}},t.prototype.notifyOnPanelAddedRemoved=function(e,t,n){if(n||(n=this.panelsCore[t]),this.survey){var o="onSurvey"===this.showQuestionNumbers;e?this.survey.dynamicPanelAdded(this,t,n,o):this.survey.dynamicPanelRemoved(this,t,n,o)}e&&n&&"onPanel"===this.showQuestionNumbers&&n.setVisibleIndex(0)},t.prototype.getVisualPanelIndex=function(e){if(s.isNumber(e))return e;for(var t=this.visiblePanelsCore,n=0;n<t.length;n++)if(t[n]===e||t[n].data===e)return n;return-1},t.prototype.getPanelVisibleIndexById=function(e){for(var t=this.visiblePanelsCore,n=0;n<t.length;n++)if(t[n].id===e)return n;return-1},t.prototype.locStrsChanged=function(){e.prototype.locStrsChanged.call(this);for(var t=this.panelsCore,n=0;n<t.length;n++)t[n].locStrsChanged();this.tabbedMenu&&this.tabbedMenu.locStrsChanged()},t.prototype.clearIncorrectValues=function(){for(var e=0;e<this.panelsCore.length;e++)this.clearIncorrectValuesInPanel(e)},t.prototype.clearErrors=function(){e.prototype.clearErrors.call(this);for(var t=0;t<this.panelsCore.length;t++)this.panelsCore[t].clearErrors()},t.prototype.getQuestionFromArray=function(e,t){return t<0||t>=this.panelsCore.length?null:this.panelsCore[t].getQuestionByName(e)},t.prototype.clearIncorrectValuesInPanel=function(e){var t=this.panelsCore[e];t.clearIncorrectValues();var n=this.value,o=n&&e<n.length?n[e]:null;if(o){var i=!1;for(var r in o){if(!this.getSharedQuestionFromArray(r,e))t.getQuestionByName(r)||this.iscorrectValueWithPostPrefix(t,r,Xt.commentSuffix)||this.iscorrectValueWithPostPrefix(t,r,Xt.matrix.totalsSuffix)||(delete o[r],i=!0)}i&&(n[e]=o,this.value=n)}},t.prototype.iscorrectValueWithPostPrefix=function(e,t,n){return t.indexOf(n)===t.length-n.length&&!!e.getQuestionByName(t.substring(0,t.indexOf(n)))},t.prototype.getSharedQuestionFromArray=function(e,t){return this.survey&&this.valueName?this.survey.getQuestionByValueNameFromArray(this.valueName,e,t):null},t.prototype.addConditionObjectsByContext=function(e,t){for(var n=(null==t?void 0:t.isValidator)?t.errorOwner:t,o=!!t&&(!0===t||this.template.questions.indexOf(n)>-1),i=new Array,r=this.template.questions,s=0;s<r.length;s++)r[s].addConditionObjectsByContext(i,t);for(var a=0;a<Xt.panel.maxPanelCountInCondition;a++){var l="["+a+"].",u=this.getValueName()+l,c=this.processedTitle+l;for(s=0;s<i.length;s++)i[s].context?e.push(i[s]):e.push({name:u+i[s].name,text:c+i[s].text,question:i[s].question})}if(o)for(u=!0===t?this.getValueName()+".":"",c=!0===t?this.processedTitle+".":"",s=0;s<i.length;s++)if(i[s].question!=t){var p={name:u+ta.ItemVariableName+"."+i[s].name,text:c+ta.ItemVariableName+"."+i[s].text,question:i[s].question};p.context=this,e.push(p)}},t.prototype.collectNestedQuestionsCore=function(e,t,n){n&&e.push(this);var o=t?this.visiblePanelsCore:this.panelsCore;Array.isArray(o)&&o.forEach((function(o){o.questions.forEach((function(o){return o.collectNestedQuestions(e,t,n)}))}))},t.prototype.getConditionJson=function(t,n){if(void 0===t&&(t=null),void 0===n&&(n=null),!n)return e.prototype.getConditionJson.call(this,t);var o=n,i=n.indexOf(".");i>-1&&(o=n.substring(0,i),n=n.substring(i+1));var r=this.template.getQuestionByName(o);return r?r.getConditionJson(t,n):null},t.prototype.onReadOnlyChanged=function(){var t=this.isReadOnly;this.template.readOnly=t;for(var n=0;n<this.panelsCore.length;n++)this.panelsCore[n].readOnly=t;this.updateNoEntriesTextDefaultLoc(),this.updateFooterActions(),e.prototype.onReadOnlyChanged.call(this)},t.prototype.updateNoEntriesTextDefaultLoc=function(){var e=this.getLocalizableString("noEntriesText");e&&(e.localizationName=this.isReadOnly||!this.allowAddPanel?"noEntriesReadonlyText":"noEntriesText")},t.prototype.onSurveyLoad=function(){this.template.readOnly=this.isReadOnly,this.template.onSurveyLoad(),this.panelCount<this.minPanelCount&&(this.panelCount=this.minPanelCount),this.panelCount>this.maxPanelCount&&(this.panelCount=this.maxPanelCount),this.buildPanelsFirstTime(),e.prototype.onSurveyLoad.call(this)},t.prototype.buildPanelsFirstTime=function(e){if(void 0===e&&(e=!1),!this.hasPanelBuildFirstTime&&(e||!this.wasNotRenderedInSurvey)){if(this.blockAnimations(),this.hasPanelBuildFirstTime=!0,this.isBuildingPanelsFirstTime=!0,this.getPropertyValue("panelCount")>0&&(this.panelCount=this.getPropertyValue("panelCount")),this.useTemplatePanel&&this.rebuildPanels(),this.setPanelsSurveyImpl(),this.setPanelsState(),this.assignOnPropertyChangedToTemplate(),this.data&&this.isValueChangedWithoutPanels&&(this.isValueChangedWithoutPanels=!1,this.runTriggersOnBuildPanelsFirstTime()),this.survey)for(var t=0;t<this.panelCount;t++)this.notifyOnPanelAddedRemoved(!0,t);this.updateIsReady(),this.showAddPanelButton||this.updateNoEntriesTextDefaultLoc(),this.updateFooterActions(),this.isBuildingPanelsFirstTime=!1,this.releaseAnimations()}},t.prototype.runTriggersOnBuildPanelsFirstTime=function(){var e=this;this.value;this.visiblePanelsCore.forEach((function(t){var n=e.getPanelItemData(t.data);if(!s.isValueEmpty(n)){var o=s.createCopyWithPrefix(n,ta.ItemVariableName+".");t.questions.forEach((function(e){return e.runTriggers("",void 0,o)}))}}))},Object.defineProperty(t.prototype,"showAddPanelButton",{get:function(){return this.allowAddPanel&&!this.isReadOnly},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"wasNotRenderedInSurvey",{get:function(){return!this.hasPanelBuildFirstTime&&!this.wasRendered&&!!this.survey},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"canBuildPanels",{get:function(){return!this.isLoadingFromJson&&!this.useTemplatePanel},enumerable:!1,configurable:!0}),t.prototype.onFirstRenderingCore=function(){e.prototype.onFirstRenderingCore.call(this),this.buildPanelsFirstTime(),this.template.onFirstRendering();for(var t=0;t<this.panelsCore.length;t++)this.panelsCore[t].onFirstRendering()},t.prototype.localeChanged=function(){e.prototype.localeChanged.call(this);for(var t=0;t<this.panelsCore.length;t++)this.panelsCore[t].localeChanged()},t.prototype.runCondition=function(t,n){e.prototype.runCondition.call(this,t,n),this.runPanelsCondition(this.panelsCore,t,n)},t.prototype.runTriggers=function(t,n,o){e.prototype.runTriggers.call(this,t,n,o),this.visiblePanelsCore.forEach((function(e){e.questions.forEach((function(e){return e.runTriggers(t,n,o)}))}))},t.prototype.reRunCondition=function(){this.data&&this.runCondition(this.getDataFilteredValues(),this.getDataFilteredProperties())},t.prototype.runPanelsCondition=function(e,t,n){var o={};t&&t instanceof Object&&(o=JSON.parse(JSON.stringify(t))),this.parentQuestion&&this.parent&&(o[ta.ParentItemVariableName]=this.parent.getValue()),this.isValueChangingInternally=!0;for(var i=0,r=0;r<e.length;r++){var a=e[r],l=this.getPanelItemData(a.data),u=s.createCopy(o),c=ta.ItemVariableName;u[c]=l,u[ta.IndexVariableName.toLowerCase()]=r,u[ta.VisibleIndexVariableName.toLowerCase()]=i;var p=s.createCopy(n);p[c]=a,a.runCondition(u,p),a.isVisible&&i++}this.isValueChangingInternally=!1},t.prototype.onAnyValueChanged=function(t,n){e.prototype.onAnyValueChanged.call(this,t,n),this.hasPanelBuildFirstTime||t!==this.getValueName()||(this.isValueChangedWithoutPanels=!0);for(var o=0;o<this.panelsCore.length;o++)this.panelsCore[o].onAnyValueChanged(t,n),this.panelsCore[o].onAnyValueChanged(ta.ItemVariableName,"")},t.prototype.hasKeysDuplicated=function(e,t){void 0===t&&(t=null);for(var n,o=[],i=0;i<this.panelsCore.length;i++)n=this.isValueDuplicated(this.panelsCore[i],o,t,e)||n;return n},t.prototype.updatePanelsContainsErrors=function(){for(var e=this.changingValueQuestion.parent;e;)e.updateContainsErrors(),e=e.parent;this.updateContainsErrors()},t.prototype.hasErrors=function(t,n){if(void 0===t&&(t=!0),void 0===n&&(n=null),this.isValueChangingInternally||this.isBuildingPanelsFirstTime)return!1;var o=!1;if(this.changingValueQuestion){o=this.changingValueQuestion.hasErrors(t,n);o=this.hasKeysDuplicated(t,n)||o,this.updatePanelsContainsErrors()}else o=this.hasErrorInPanels(t,n);return e.prototype.hasErrors.call(this,t,n)||o},t.prototype.getContainsErrors=function(){var t=e.prototype.getContainsErrors.call(this);if(t)return t;for(var n=this.panelsCore,o=0;o<n.length;o++)if(n[o].containsErrors)return!0;return!1},t.prototype.getIsAnswered=function(){if(!e.prototype.getIsAnswered.call(this))return!1;for(var t=this.visiblePanelsCore,n=0;n<t.length;n++){var o=[];t[n].addQuestionsToList(o,!0);for(var i=0;i<o.length;i++)if(!o[i].isAnswered)return!1}return!0},t.prototype.clearValueOnHidding=function(t){if(!t){if(this.survey&&"none"===this.survey.getQuestionClearIfInvisible("onHidden"))return;this.clearValueInPanelsIfInvisible("onHiddenContainer")}e.prototype.clearValueOnHidding.call(this,t)},t.prototype.clearValueIfInvisible=function(t){void 0===t&&(t="onHidden");var n="onHidden"===t?"onHiddenContainer":t;this.clearValueInPanelsIfInvisible(n),e.prototype.clearValueIfInvisible.call(this,t)},t.prototype.clearValueInPanelsIfInvisible=function(e){for(var t=0;t<this.panelsCore.length;t++){var n=this.panelsCore[t],o=n.questions;this.isSetPanelItemData={};for(var i=0;i<o.length;i++){var r=o[i];r.visible&&!n.isVisible||(r.clearValueIfInvisible(e),this.isSetPanelItemData[r.getValueName()]=this.maxCheckCount+1)}}this.isSetPanelItemData={}},t.prototype.getIsRunningValidators=function(){if(e.prototype.getIsRunningValidators.call(this))return!0;for(var t=0;t<this.panelsCore.length;t++)for(var n=this.panelsCore[t].questions,o=0;o<n.length;o++)if(n[o].isRunningValidators)return!0;return!1},t.prototype.getAllErrors=function(){for(var t=e.prototype.getAllErrors.call(this),n=this.visiblePanelsCore,o=0;o<n.length;o++)for(var i=n[o].questions,r=0;r<i.length;r++){var s=i[r].getAllErrors();s&&s.length>0&&(t=t.concat(s))}return t},t.prototype.getDisplayValueCore=function(e,t){var n=this.getUnbindValue(t);if(!n||!Array.isArray(n))return n;for(var o=0;o<this.panelsCore.length&&o<n.length;o++){var i=n[o];i&&(n[o]=this.getPanelDisplayValue(o,i,e))}return n},t.prototype.getPanelDisplayValue=function(e,t,n){if(!t)return t;for(var o=this.panelsCore[e],i=Object.keys(t),r=0;r<i.length;r++){var s=i[r],a=o.getQuestionByValueName(s);if(a||(a=this.getSharedQuestionFromArray(s,e)),a){var l=a.getDisplayValue(n,t[s]);t[s]=l,n&&a.title&&a.title!==s&&(t[a.title]=l,delete t[s])}}return t},t.prototype.hasErrorInPanels=function(e,t){for(var n=!1,o=this.visiblePanels,i=[],r=0;r<o.length;r++)this.setOnCompleteAsyncInPanel(o[r]);for(var s=!!t&&t.focusOnFirstError,a=0;a<o.length;a++){var l=o[a].hasErrors(e,s,t);l=this.isValueDuplicated(o[a],i,t,e)||l,!this.isRenderModeList&&l&&!n&&s&&(this.currentIndex=a),n=l||n}return n},t.prototype.setOnCompleteAsyncInPanel=function(e){for(var t=this,n=e.questions,o=0;o<n.length;o++)n[o].onCompletedAsyncValidators=function(e){t.raiseOnCompletedAsyncValidators()}},t.prototype.isValueDuplicated=function(e,t,n,o){if(!this.keyName)return!1;var i=e.getQuestionByValueName(this.keyName);if(!i||i.isEmpty())return!1;var r=i.value;this.changingValueQuestion&&i!=this.changingValueQuestion&&i.hasErrors(o,n);for(var s=0;s<t.length;s++)if(r==t[s])return o&&i.addError(new dn(this.keyDuplicationError,this)),n&&!n.firstErrorQuestion&&(n.firstErrorQuestion=i),!0;return t.push(r),!1},t.prototype.getPanelActions=function(e){var t=this,n=e.footerActions;return"right"!==this.panelRemoveButtonLocation&&n.push(new Xe({id:"remove-panel-"+e.id,component:"sv-paneldynamic-remove-btn",visible:new we((function(){return[t.canRemovePanel,"collapsed"!==e.state,"right"!==t.panelRemoveButtonLocation].every((function(e){return!0===e}))})),data:{question:this,panel:e}})),this.survey&&(n=this.survey.getUpdatedPanelFooterActions(e,n,this)),n},t.prototype.createNewPanel=function(){var e=this,t=this.createAndSetupNewPanelObject(),n=this.template.toJSON();(new A).toObject(n,t),t.renderWidth="100%",t.updateCustomWidgets(),new ta(this,t),this.isDesignMode||this.isReadOnly||this.isValueEmpty(t.getValue())||this.runPanelsCondition([t],this.getDataFilteredValues(),this.getDataFilteredProperties());for(var o=t.questions,i=0;i<o.length;i++)o[i].setParentQuestion(this);return this.wasRendered&&(t.onFirstRendering(),t.locStrsChanged()),t.onGetFooterActionsCallback=function(){return e.getPanelActions(t)},t.onGetFooterToolbarCssCallback=function(){return e.cssClasses.panelFooter},t.registerPropertyChangedHandlers(["visible"],(function(){t.visible?e.onPanelAdded(t):e.onPanelRemoved(t),e.updateFooterActions()})),t},t.prototype.createAndSetupNewPanelObject=function(){var e=this,t=this.createNewPanelObject();return t.isInteractiveDesignElement=!1,t.setParentQuestion(this),t.onGetQuestionTitleLocation=function(){return e.getTemplateQuestionTitleLocation()},t},t.prototype.getTemplateQuestionTitleLocation=function(){return"default"!=this.templateTitleLocation?this.templateTitleLocation:this.getTitleLocationCore()},t.prototype.getChildErrorLocation=function(t){return"default"!==this.templateErrorLocation?this.templateErrorLocation:e.prototype.getChildErrorLocation.call(this,t)},t.prototype.createNewPanelObject=function(){return D.createClass("panel")},t.prototype.setPanelCountBasedOnValue=function(){if(!this.isValueChangingInternally&&!this.useTemplatePanel){var e=this.value,t=e&&Array.isArray(e)?e.length:0;0==t&&this.getPropertyValue("panelCount")>0&&(t=this.getPropertyValue("panelCount")),this.settingPanelCountBasedOnValue=!0,this.panelCount=t,this.settingPanelCountBasedOnValue=!1}},t.prototype.setQuestionValue=function(t){if(!this.settingPanelCountBasedOnValue){e.prototype.setQuestionValue.call(this,t,!1),this.setPanelCountBasedOnValue();for(var n=0;n<this.panelsCore.length;n++)this.panelUpdateValueFromSurvey(this.panelsCore[n]);this.updateIsAnswered()}},t.prototype.onSurveyValueChanged=function(t){if(void 0!==t||!this.isAllPanelsEmpty()){e.prototype.onSurveyValueChanged.call(this,t);for(var n=0;n<this.panelsCore.length;n++)this.panelSurveyValueChanged(this.panelsCore[n]);void 0===t&&this.setValueBasedOnPanelCount(),this.updateIsReady()}},t.prototype.isAllPanelsEmpty=function(){for(var e=0;e<this.panelsCore.length;e++)if(!s.isValueEmpty(this.panelsCore[e].getValue()))return!1;return!0},t.prototype.panelUpdateValueFromSurvey=function(e){for(var t=e.questions,n=this.getPanelItemData(e.data),o=0;o<t.length;o++){var i=t[o];i.updateValueFromSurvey(n[i.getValueName()]),i.updateCommentFromSurvey(n[i.getValueName()+Xt.commentSuffix]),i.initDataUI()}},t.prototype.panelSurveyValueChanged=function(e){for(var t=e.questions,n=this.getPanelItemData(e.data),o=0;o<t.length;o++){var i=t[o];i.onSurveyValueChanged(n[i.getValueName()])}},t.prototype.onSetData=function(){e.prototype.onSetData.call(this),!this.isLoadingFromJson&&this.useTemplatePanel&&(this.setTemplatePanelSurveyImpl(),this.rebuildPanels())},t.prototype.isNewValueCorrect=function(e){return Array.isArray(e)},t.prototype.getItemIndex=function(e){var t=this.items.indexOf(e);return t>-1?t:this.items.length},t.prototype.getVisibleItemIndex=function(e){for(var t=this.visiblePanelsCore,n=0;n<t.length;n++)if(t[n].data===e)return n;return t.length},t.prototype.getPanelItemData=function(e){var t=this.items,n=t.indexOf(e),o=this.value;return n<0&&Array.isArray(o)&&o.length>t.length&&(n=t.length),n<0||!o||!Array.isArray(o)||o.length<=n?{}:o[n]},t.prototype.setPanelItemData=function(e,t,n){if(!(this.isSetPanelItemData[t]>this.maxCheckCount)){this.isSetPanelItemData[t]||(this.isSetPanelItemData[t]=0),this.isSetPanelItemData[t]++;var o=this.items,i=o.indexOf(e);i<0&&(i=o.length);var r=this.getUnbindValue(this.value);if(r&&Array.isArray(r)||(r=[]),r.length<=i)for(var s=r.length;s<=i;s++)r.push({});r[i]||(r[i]={});var a=r[i][t];this.isValueEmpty(n)?delete r[i][t]:r[i][t]=n,i>=0&&i<this.panelsCore.length&&(this.changingValueQuestion=this.panelsCore[i].getQuestionByValueName(t));var l={panel:e.panel,name:t,panelIndex:i,panelData:r[i],value:n,oldValue:a};this.survey&&this.survey.dynamicPanelItemValueChanging(this,l),this.value=r,this.changingValueQuestion=null,this.survey&&this.survey.dynamicPanelItemValueChanged(this,l),this.isSetPanelItemData[t]--,this.isSetPanelItemData[t]-1&&delete this.isSetPanelItemData[t]}},t.prototype.getRootData=function(){return this.data},t.prototype.getPlainData=function(t){void 0===t&&(t={includeEmpty:!0});var n=e.prototype.getPlainData.call(this,t);if(n){n.isNode=!0;var o=Array.isArray(n.data)?[].concat(n.data):[];n.data=this.panels.map((function(e,n){var o={name:e.name||n,title:e.title||"Panel",value:e.getValue(),displayValue:e.getValue(),getString:function(e){return"object"==typeof e?JSON.stringify(e):e},isNode:!0,data:e.questions.map((function(e){return e.getPlainData(t)})).filter((function(e){return!!e}))};return(t.calculations||[]).forEach((function(t){o[t.propertyName]=e[t.propertyName]})),o})),n.data=n.data.concat(o)}return n},t.prototype.updateElementCss=function(t){e.prototype.updateElementCss.call(this,t);for(var n=0;n<this.panelsCore.length;n++){this.panelsCore[n].updateElementCss(t)}},Object.defineProperty(t.prototype,"progressText",{get:function(){var e=this.visiblePanelCount;return this.getLocalizationFormatString("panelDynamicProgressText",this.currentIndex+1,e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"progress",{get:function(){return(this.currentIndex+1)/this.visiblePanelCount*100+"%"},enumerable:!1,configurable:!0}),t.prototype.getRootCss=function(){return(new Ee).append(e.prototype.getRootCss.call(this)).append(this.cssClasses.empty,this.getShowNoEntriesPlaceholder()).toString()},Object.defineProperty(t.prototype,"cssHeader",{get:function(){var t=this.isRenderModeTab&&!!this.visiblePanelCount;return(new Ee).append(e.prototype.getCssHeader.call(this,this.cssClasses)).append(this.cssClasses.headerTab,this.hasTitleOnTop&&t).toString()},enumerable:!1,configurable:!0}),t.prototype.getTabsContainerCss=function(){return(new Ee).append(this.cssClasses.tabsContainer).append(this.cssClasses.tabsContainerWithHeader,this.hasTitleOnTop).toString()},t.prototype.getPanelWrapperCss=function(e){return(new Ee).append(this.cssClasses.panelWrapper,!e||e.visible).append(this.cssClasses.panelWrapperList,this.isRenderModeList).append(this.cssClasses.panelWrapperInRow,"right"===this.panelRemoveButtonLocation).toString()},t.prototype.getPanelRemoveButtonCss=function(){return(new Ee).append(this.cssClasses.button).append(this.cssClasses.buttonRemove).append(this.cssClasses.buttonRemoveRight,"right"===this.panelRemoveButtonLocation).toString()},t.prototype.getAddButtonCss=function(){return(new Ee).append(this.cssClasses.button).append(this.cssClasses.buttonAdd).append(this.cssClasses.buttonAdd+"--list-mode","list"===this.displayMode).toString()},t.prototype.getPrevButtonCss=function(){return(new Ee).append(this.cssClasses.buttonPrev).append(this.cssClasses.buttonPrevDisabled,!this.isPrevButtonVisible).toString()},t.prototype.getNextButtonCss=function(){return(new Ee).append(this.cssClasses.buttonNext).append(this.cssClasses.buttonNextDisabled,!this.isNextButtonVisible).toString()},Object.defineProperty(t.prototype,"noEntriesText",{get:function(){return this.getLocalizableStringText("noEntriesText")},set:function(e){this.setLocalizableStringText("noEntriesText",e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"locNoEntriesText",{get:function(){return this.getLocalizableString("noEntriesText")},enumerable:!1,configurable:!0}),t.prototype.getShowNoEntriesPlaceholder=function(){return!!this.cssClasses.noEntriesPlaceholder&&!this.isDesignMode&&0===this.visiblePanelCount},t.prototype.needResponsiveWidth=function(){var e=this.getPanel();return!(!e||!e.needResponsiveWidth())},Object.defineProperty(t.prototype,"hasTabbedMenu",{get:function(){return this.isRenderModeTab&&this.visiblePanels.length>0},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"tabbedMenu",{get:function(){return this.isRenderModeTab?(this.tabbedMenuValue||(this.tabbedMenuValue=new tt,this.tabbedMenuValue.dotsItem.popupModel.showPointer=!1,this.tabbedMenuValue.dotsItem.popupModel.verticalPosition="bottom",this.tabbedMenuValue.dotsItem.popupModel.horizontalPosition="center",this.updateElementCss(!1)),this.tabbedMenuValue):null},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"footerToolbar",{get:function(){return this.footerToolbarValue||this.initFooterToolbar(),this.footerToolbarValue},enumerable:!1,configurable:!0}),t.prototype.updateFooterActions=function(){this.updateFooterActionsCallback&&this.updateFooterActionsCallback()},t.prototype.initFooterToolbar=function(){var e=this;this.footerToolbarValue=this.createActionContainer();var t=[],n=new Xe({id:"sv-pd-prev-btn",title:this.panelPrevText,action:function(){e.goToPrevPanel()}}),o=new Xe({id:"sv-pd-next-btn",title:this.panelNextText,action:function(){e.goToNextPanel()}}),i=new Xe({id:"sv-pd-add-btn",component:"sv-paneldynamic-add-btn",data:{question:this}}),r=new Xe({id:"sv-prev-btn-icon",component:"sv-paneldynamic-prev-btn",data:{question:this}}),s=new Xe({id:"sv-pd-progress-text",component:"sv-paneldynamic-progress-text",data:{question:this}}),a=new Xe({id:"sv-pd-next-btn-icon",component:"sv-paneldynamic-next-btn",data:{question:this}});t.push(n,o,i,r,s,a),this.updateFooterActionsCallback=function(){var t=e.legacyNavigation,l=e.isRenderModeList,u=e.isMobile,c=!t&&!l;n.visible=c&&e.currentIndex>0,o.visible=c&&e.currentIndex<e.visiblePanelCount-1,o.needSpace=u&&o.visible&&n.visible,i.visible=e.canAddPanel,i.needSpace=e.isMobile&&!o.visible&&n.visible,s.visible=!e.isRenderModeList&&!u,s.needSpace=!t&&!e.isMobile;var p=t&&!l;r.visible=p,a.visible=p,r.needSpace=p},this.updateFooterActionsCallback(),this.footerToolbarValue.setItems(t)},t.prototype.createTabByPanel=function(e,t){var n=this;if(this.isRenderModeTab){var o=new yt(e,!0);o.onGetTextCallback=function(o){if(o||(o=n.locTabTitlePlaceholder.renderedHtml),!n.survey)return o;var i={title:o,panel:e,visiblePanelIndex:t};return n.survey.dynamicPanelGetTabTitle(n,i),i.title},o.sharedData=this.locTemplateTabTitle;var i=e.id,r=this.getPanelVisibleIndexById(i)===this.currentIndex;return new ea({id:this.id+"_tab_"+i,panelId:i,pressed:r,locTitle:o,disableHide:r,action:function(){n.currentIndex=n.getPanelVisibleIndexById(i)}})}},t.prototype.getTabbedMenuCss=function(e){var t=null!=e?e:this.cssClasses;return(new Ee).append(t.tabsRoot).append(t.tabsLeft,"left"===this.tabAlign).append(t.tabsRight,"right"===this.tabAlign).append(t.tabsCenter,"center"===this.tabAlign).toString()},t.prototype.updateTabToolbarItemsPressedState=function(){if(this.isRenderModeTab&&!(this.currentIndex<0||this.currentIndex>=this.visiblePanelCount)){var e=this.visiblePanelsCore[this.currentIndex];this.tabbedMenu.renderedActions.forEach((function(t){var n=t.panelId===e.id;t.pressed=n,t.disableHide=n,"popup"===t.mode&&t.disableHide&&t.raiseUpdate()}))}},t.prototype.updateTabToolbar=function(){var e=this;if(this.isRenderModeTab){for(var t=[],n=this.visiblePanelsCore,o=function(o){i.visiblePanelsCore.forEach((function(i){return t.push(e.createTabByPanel(n[o],o))}))},i=this,r=0;r<n.length;r++)o(r);this.tabbedMenu.setItems(t)}},t.prototype.addTabFromToolbar=function(e,t){if(this.isRenderModeTab){var n=this.createTabByPanel(e,t);this.tabbedMenu.actions.splice(t,0,n),this.updateTabToolbarItemsPressedState()}},t.prototype.removeTabFromToolbar=function(e){if(this.isRenderModeTab){var t=this.tabbedMenu.actions.find((function(t){return t.panelId==e.id}));t&&(this.tabbedMenu.actions.splice(this.tabbedMenu.actions.indexOf(t),1),this.updateTabToolbarItemsPressedState())}},Object.defineProperty(t.prototype,"showLegacyNavigation",{get:function(){return!this.isDefaultV2Theme},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"showNavigation",{get:function(){return(!this.isReadOnly||1!=this.visiblePanelCount)&&(this.visiblePanelCount>0&&!this.showLegacyNavigation&&!!this.cssClasses.footer)},enumerable:!1,configurable:!0}),t.prototype.showSeparator=function(e){return this.isRenderModeList&&e<this.renderedPanels.length-1},t.prototype.calcCssClasses=function(t){var n=e.prototype.calcCssClasses.call(this,t),o=this.tabbedMenu;return o&&(o.containerCss=this.getTabbedMenuCss(n),o.cssClasses=n.tabs,o.dotsItem.cssClasses=n.tabs,o.dotsItem.popupModel.contentComponentData.model.cssClasses=t.list),n},t.prototype.onMobileChanged=function(){e.prototype.onMobileChanged.call(this),this.updateFooterActions()},t.maxCheckCount=3,Ys([b({})],t.prototype,"_renderedPanels",void 0),Ys([m({onSet:function(e,t){t.fireCallback(t.renderModeChangedCallback),t.updatePanelView()}})],t.prototype,"displayMode",void 0),Ys([m({onSet:function(e,t){t.fireCallback(t.currentIndexChangedCallback)}})],t.prototype,"showProgressBar",void 0),Ys([m({onSet:function(e,t){}})],t.prototype,"progressBarLocation",void 0),Ys([m({defaultValue:!1,onSet:function(e,t){t.updateFooterActions()}})],t.prototype,"legacyNavigation",void 0),t}(An);D.addClass("paneldynamic",[{name:"showCommentArea:switch",layout:"row",visible:!0,category:"general"},{name:"templateElements",alternativeName:"questions",baseClassName:"question",visible:!1,isLightSerializable:!1},{name:"templateTitle:text",serializationProperty:"locTemplateTitle"},{name:"templateTabTitle",serializationProperty:"locTemplateTabTitle",visibleIf:function(e){return"tab"===e.displayMode}},{name:"tabTitlePlaceholder",serializationProperty:"locTabTitlePlaceholder",visibleIf:function(e){return"tab"===e.displayMode}},{name:"templateDescription:text",serializationProperty:"locTemplateDescription"},{name:"minWidth",defaultFunc:function(){return"auto"}},{name:"noEntriesText:text",serializationProperty:"locNoEntriesText"},{name:"allowAddPanel:boolean",default:!0},{name:"allowRemovePanel:boolean",default:!0},{name:"newPanelPosition",choices:["next","last"],default:"last",category:"layout"},{name:"panelCount:number",isBindable:!0,default:0,choices:[0,1,2,3,4,5,6,7,8,9,10]},{name:"minPanelCount:number",default:0,minValue:0},{name:"maxPanelCount:number",defaultFunc:function(){return Xt.panel.maxPanelCount}},"defaultPanelValue:panelvalue","defaultValueFromLastPanel:boolean",{name:"panelsState",default:"default",choices:["default","collapsed","expanded","firstExpanded"],visibleIf:function(e){return"list"===e.displayMode}},{name:"keyName"},{name:"keyDuplicationError",serializationProperty:"locKeyDuplicationError"},{name:"confirmDelete:boolean"},{name:"confirmDeleteText",serializationProperty:"locConfirmDeleteText",visibleIf:function(e){return e.confirmDelete}},{name:"panelAddText",serializationProperty:"locPanelAddText",visibleIf:function(e){return e.allowAddPanel}},{name:"panelRemoveText",serializationProperty:"locPanelRemoveText",visibleIf:function(e){return e.allowRemovePanel}},{name:"panelPrevText",serializationProperty:"locPanelPrevText",visibleIf:function(e){return"list"!==e.displayMode}},{name:"panelNextText",serializationProperty:"locPanelNextText",visibleIf:function(e){return"list"!==e.displayMode}},{name:"showQuestionNumbers",default:"off",choices:["off","onPanel","onSurvey"]},{name:"renderMode",visible:!1,isSerializable:!1},{name:"displayMode",default:"list",choices:["list","carousel","tab"]},{name:"showProgressBar:boolean",alternativeName:"showRangeInProgress",default:!0,visibleIf:function(e){return"carousel"===e.displayMode}},{name:"progressBarLocation",default:"top",choices:["top","bottom","topBottom"],visibleIf:function(e){return e.showProgressBar}},{name:"tabAlign",default:"center",choices:["left","center","right"],visibleIf:function(e){return"tab"===e.displayMode}},{name:"templateTitleLocation",default:"default",choices:["default","top","bottom","left"]},{name:"templateErrorLocation",default:"default",choices:["default","top","bottom"]},{name:"templateVisibleIf:expression",category:"logic"},{name:"panelRemoveButtonLocation",default:"bottom",choices:["bottom","right"],visibleIf:function(e){return e.allowRemovePanel}}],(function(){return new oa("")}),"question"),ao.Instance.registerQuestion("paneldynamic",(function(e){return new oa(e)}));var ia=function(){function e(){}return e.getProgressTextInBarCss=function(e){return(new Ee).append(e.progressText).append(e.progressTextInBar).toString()},e.getProgressTextUnderBarCss=function(e){return(new Ee).append(e.progressText).append(e.progressTextUnderBar).toString()},e}(),ra=function(){var e=function(t,n){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(t,n)};return function(t,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function o(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(o.prototype=n.prototype,new o)}}(),sa=function(e){function t(){var n=e.call(this)||this;return n.idValue=t.idCounter++,n.registerPropertyChangedHandlers(["operator","value","name"],(function(){n.oldPropertiesChanged()})),n.registerPropertyChangedHandlers(["expression"],(function(){n.onExpressionChanged()})),n}return ra(t,e),Object.defineProperty(t,"operators",{get:function(){return null!=t.operatorsValue||(t.operatorsValue={empty:function(e,t){return!e},notempty:function(e,t){return!!e},equal:function(e,t){return e==t},notequal:function(e,t){return e!=t},contains:function(e,t){return e&&e.indexOf&&e.indexOf(t)>-1},notcontains:function(e,t){return!e||!e.indexOf||-1==e.indexOf(t)},greater:function(e,t){return e>t},less:function(e,t){return e<t},greaterorequal:function(e,t){return e>=t},lessorequal:function(e,t){return e<=t}}),t.operatorsValue},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"id",{get:function(){return this.idValue},enumerable:!1,configurable:!0}),t.prototype.getType=function(){return"triggerbase"},t.prototype.toString=function(){var e=this.getType().replace("trigger",""),t=this.expression?this.expression:this.buildExpression();return t&&(e+=", "+t),e},Object.defineProperty(t.prototype,"isInternal",{get:function(){return!0===this.isGhost},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"operator",{get:function(){return this.getPropertyValue("operator","equal")},set:function(e){e&&(e=e.toLowerCase(),t.operators[e]&&this.setPropertyValue("operator",e))},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"value",{get:function(){return this.getPropertyValue("value",null)},set:function(e){this.setPropertyValue("value",e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"name",{get:function(){return this.getPropertyValue("name","")},set:function(e){this.setPropertyValue("name",e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"expression",{get:function(){return this.getPropertyValue("expression","")},set:function(e){this.setPropertyValue("expression",e)},enumerable:!1,configurable:!0}),t.prototype.canBeExecuted=function(e){return!0},t.prototype.canBeExecutedOnComplete=function(){return!1},t.prototype.checkExpression=function(e){this.isExecutingOnNextPage=e.isOnNextPage,this.isExecutingOnNavigation=e.isOnNavigation||e.isOnNextPage,this.canBeExecuted(e.isOnNextPage)&&(e.isOnComplete&&!this.canBeExecutedOnComplete()||this.isCheckRequired(e.keys)&&(this.conditionRunner?this.perform(e.values,e.properties||null):this.canSuccessOnEmptyExpression()&&this.triggerResult(!0,e.values,e.properties||null)))},t.prototype.canSuccessOnEmptyExpression=function(){return!1},t.prototype.check=function(e){t.operators[this.operator](e,this.value)?this.onSuccess({},null):this.onFailure()},Object.defineProperty(t.prototype,"requireValidQuestion",{get:function(){return!1},enumerable:!1,configurable:!0}),t.prototype.perform=function(e,t){var n=this;this.conditionRunner.onRunComplete=function(o){n.triggerResult(o,e,t)},this.conditionRunner.run(e,t)},t.prototype.triggerResult=function(e,t,n){e?(this.onSuccess(t,n),this.onSuccessExecuted()):this.onFailure()},t.prototype.onSuccess=function(e,t){},t.prototype.onFailure=function(){},t.prototype.onSuccessExecuted=function(){},t.prototype.endLoadingFromJson=function(){e.prototype.endLoadingFromJson.call(this),this.oldPropertiesChanged()},t.prototype.oldPropertiesChanged=function(){this.onExpressionChanged()},t.prototype.onExpressionChanged=function(){this.conditionRunner=null},t.prototype.buildExpression=function(){return this.name?this.isValueEmpty(this.value)&&this.isRequireValue?"":"{"+this.name+"} "+this.operator+" "+se.toOperandString(this.value):""},t.prototype.isCheckRequired=function(e){return!!e&&(this.createConditionRunner(),!(!this.conditionRunner||!0!==this.conditionRunner.hasFunction())||(new L).isAnyKeyChanged(e,this.getUsedVariables()))},t.prototype.getUsedVariables=function(){if(!this.conditionRunner)return[];var e=this.conditionRunner.getVariables();if(Array.isArray(e))for(var t="-unwrapped",n=e.length-1;n>=0;n--){var o=e[n];o.endsWith(t)&&e.push(o.substring(0,o.length-t.length))}return e},t.prototype.createConditionRunner=function(){if(!this.conditionRunner){var e=this.expression;e||(e=this.buildExpression()),e&&(this.conditionRunner=new ye(e))}},Object.defineProperty(t.prototype,"isRequireValue",{get:function(){return"empty"!==this.operator&&"notempty"!=this.operator},enumerable:!1,configurable:!0}),t.idCounter=1,t.operatorsValue=null,t}(Ve),aa=function(e){function t(){var t=e.call(this)||this;return t.ownerValue=null,t}return ra(t,e),Object.defineProperty(t.prototype,"owner",{get:function(){return this.ownerValue},enumerable:!1,configurable:!0}),t.prototype.setOwner=function(e){this.ownerValue=e},t.prototype.getSurvey=function(e){return void 0===e&&(e=!1),this.owner&&this.owner.getSurvey?this.owner.getSurvey():null},t.prototype.isRealExecution=function(){return!0},t.prototype.onSuccessExecuted=function(){this.owner&&this.isRealExecution()&&this.owner.triggerExecuted(this)},t}(sa),la=function(e){function t(){var t=e.call(this)||this;return t.pages=[],t.questions=[],t}return ra(t,e),t.prototype.getType=function(){return"visibletrigger"},t.prototype.onSuccess=function(e,t){this.onTrigger(this.onItemSuccess)},t.prototype.onFailure=function(){this.onTrigger(this.onItemFailure)},t.prototype.onTrigger=function(e){if(this.owner)for(var t=this.owner.getObjects(this.pages,this.questions),n=0;n<t.length;n++)e(t[n])},t.prototype.onItemSuccess=function(e){e.visible=!0},t.prototype.onItemFailure=function(e){e.visible=!1},t}(aa),ua=function(e){function t(){return e.call(this)||this}return ra(t,e),t.prototype.getType=function(){return"completetrigger"},Object.defineProperty(t.prototype,"requireValidQuestion",{get:function(){return!0},enumerable:!1,configurable:!0}),t.prototype.isRealExecution=function(){return!Xt.triggers.executeCompleteOnValueChanged===this.isExecutingOnNavigation},t.prototype.onSuccess=function(e,t){this.owner&&(this.isRealExecution()?this.owner.setCompleted(this):this.owner.canBeCompleted(this,!0))},t.prototype.onFailure=function(){this.owner.canBeCompleted(this,!1)},t}(aa),ca=function(e){function t(){return e.call(this)||this}return ra(t,e),t.prototype.getType=function(){return"setvaluetrigger"},t.prototype.canBeExecuted=function(e){return!e&&!!this.setToName},t.prototype.onPropertyValueChanged=function(t,n,o){if(e.prototype.onPropertyValueChanged.call(this,t,n,o),"setToName"===t){var i=this.getSurvey();i&&!i.isLoadingFromJson&&i.isDesignMode&&(this.setValue=void 0)}},Object.defineProperty(t.prototype,"setToName",{get:function(){return this.getPropertyValue("setToName","")},set:function(e){this.setPropertyValue("setToName",e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"setValue",{get:function(){return this.getPropertyValue("setValue")},set:function(e){this.setPropertyValue("setValue",e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isVariable",{get:function(){return this.getPropertyValue("isVariable")},set:function(e){this.setPropertyValue("isVariable",e)},enumerable:!1,configurable:!0}),t.prototype.onSuccess=function(e,t){this.setToName&&this.owner&&this.owner.setTriggerValue(this.setToName,s.getUnbindValue(this.setValue),this.isVariable)},t}(aa),pa=function(e){function t(){return e.call(this)||this}return ra(t,e),t.prototype.getType=function(){return"skiptrigger"},Object.defineProperty(t.prototype,"requireValidQuestion",{get:function(){return this.canBeExecuted(!1)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"gotoName",{get:function(){return this.getPropertyValue("gotoName","")},set:function(e){this.setPropertyValue("gotoName",e)},enumerable:!1,configurable:!0}),t.prototype.canBeExecuted=function(e){return e===!Xt.triggers.executeSkipOnValueChanged},t.prototype.onSuccess=function(e,t){this.gotoName&&this.owner&&this.owner.focusQuestion(this.gotoName)},t}(aa),ha=function(e){function t(){return e.call(this)||this}return ra(t,e),t.prototype.getType=function(){return"runexpressiontrigger"},Object.defineProperty(t.prototype,"setToName",{get:function(){return this.getPropertyValue("setToName","")},set:function(e){this.setPropertyValue("setToName",e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"runExpression",{get:function(){return this.getPropertyValue("runExpression","")},set:function(e){this.setPropertyValue("runExpression",e)},enumerable:!1,configurable:!0}),t.prototype.canBeExecuted=function(e){return!e},t.prototype.onSuccess=function(e,t){var n=this;if(this.owner&&this.runExpression){var o=new me(this.runExpression);o.canRun&&(o.onRunComplete=function(e){n.onCompleteRunExpression(e)},o.run(e,t))}},t.prototype.onCompleteRunExpression=function(e){this.setToName&&void 0!==e&&this.owner.setTriggerValue(this.setToName,s.convertValToQuestionVal(e),!1)},t}(aa),da=function(e){function t(){return e.call(this)||this}return ra(t,e),t.prototype.canBeExecuted=function(e){return!e&&!!this.setToName&&!!this.fromName},Object.defineProperty(t.prototype,"setToName",{get:function(){return this.getPropertyValue("setToName","")},set:function(e){this.setPropertyValue("setToName",e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"fromName",{get:function(){return this.getPropertyValue("fromName","")},set:function(e){this.setPropertyValue("fromName",e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"copyDisplayValue",{get:function(){return this.getPropertyValue("copyDisplayValue")},set:function(e){this.setPropertyValue("copyDisplayValue",e)},enumerable:!1,configurable:!0}),t.prototype.getType=function(){return"copyvaluetrigger"},t.prototype.onSuccess=function(e,t){this.setToName&&this.owner&&this.owner.copyTriggerValue(this.setToName,this.fromName,this.copyDisplayValue)},t.prototype.canSuccessOnEmptyExpression=function(){return!0},t.prototype.getUsedVariables=function(){var t=e.prototype.getUsedVariables.call(this);return 0===t.length&&this.fromName&&t.push(this.fromName),t},t}(aa);D.addClass("trigger",[{name:"operator",default:"equal",visible:!1},{name:"value",visible:!1},"expression:condition"]),D.addClass("surveytrigger",[{name:"name",visible:!1}],null,"trigger"),D.addClass("visibletrigger",["pages:pages","questions:questions"],(function(){return new la}),"surveytrigger"),D.addClass("completetrigger",[],(function(){return new ua}),"surveytrigger"),D.addClass("setvaluetrigger",[{name:"!setToName:questionvalue"},{name:"setValue:triggervalue",dependsOn:"setToName",visibleIf:function(e){return!!e&&!!e.setToName}},{name:"isVariable:boolean",visible:!1}],(function(){return new ca}),"surveytrigger"),D.addClass("copyvaluetrigger",[{name:"!fromName:questionvalue"},{name:"!setToName:questionvalue"},{name:"copyDisplayValue:boolean",visible:!1}],(function(){return new da}),"surveytrigger"),D.addClass("skiptrigger",[{name:"!gotoName:question"}],(function(){return new pa}),"surveytrigger"),D.addClass("runexpressiontrigger",[{name:"setToName:questionvalue"},"runExpression:expression"],(function(){return new ha}),"surveytrigger");var fa=function(){var e=function(t,n){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(t,n)};return function(t,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function o(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(o.prototype=n.prototype,new o)}}(),ga=function(e,t,n,o){var i,r=arguments.length,s=r<3?t:null===o?o=Object.getOwnPropertyDescriptor(t,n):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,n,o);else for(var a=e.length-1;a>=0;a--)(i=e[a])&&(s=(r<3?i(s):r>3?i(t,n,s):i(t,n))||s);return r>3&&s&&Object.defineProperty(t,n,s),s},ya=function(e){function t(t,n){void 0===n&&(n=null);var o=e.call(this)||this;return o.closeOnCompleteTimeout=0,o.surveyValue=n||o.createSurvey(t),o.surveyValue.fitToContainer=!0,o.windowElement=i.createElement("div"),o.survey.onComplete.add((function(e,t){o.onSurveyComplete()})),o.registerPropertyChangedHandlers(["isShowing"],(function(){o.showingChangedCallback&&o.showingChangedCallback()})),o.registerPropertyChangedHandlers(["isExpanded"],(function(){o.onExpandedChanged()})),o.width=new we((function(){return o.survey.width})),o.width=o.survey.width,o.updateCss(),o.onCreating(),o}return fa(t,e),t.prototype.onCreating=function(){},t.prototype.getType=function(){return"popupsurvey"},Object.defineProperty(t.prototype,"survey",{get:function(){return this.surveyValue},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isShowing",{get:function(){return this.getPropertyValue("isShowing",!1)},set:function(e){this.setPropertyValue("isShowing",e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isFullScreen",{get:function(){return this.getPropertyValue("isFullScreen",!1)},set:function(e){!this.isExpanded&&e&&(this.isExpanded=!0),this.setPropertyValue("isFullScreen",e),this.setCssRoot()},enumerable:!1,configurable:!0}),t.prototype.show=function(){this.isShowing=!0},t.prototype.hide=function(){this.isShowing=!1},t.prototype.toggleFullScreen=function(){this.isFullScreen=!this.isFullScreen},Object.defineProperty(t.prototype,"isExpanded",{get:function(){return this.getPropertyValue("isExpanded",!1)},set:function(e){this.isFullScreen&&!e&&(this.isFullScreen=!1),this.setPropertyValue("isExpanded",e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isCollapsed",{get:function(){return!this.isExpanded},enumerable:!1,configurable:!0}),t.prototype.onExpandedChanged=function(){this.expandedChangedCallback&&this.expandedChangedCallback(),this.updateCssButton()},Object.defineProperty(t.prototype,"title",{get:function(){return this.survey.title},set:function(e){this.survey.title=e},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"locTitle",{get:function(){return this.survey.locTitle.isEmpty?null:this.survey.locTitle},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"locDescription",{get:function(){return this.survey.locTitle.isEmpty?null:this.survey.locDescription},enumerable:!1,configurable:!0}),t.prototype.expand=function(){this.isExpanded=!0},t.prototype.collapse=function(){this.isExpanded=!1},t.prototype.changeExpandCollapse=function(){this.isExpanded=!this.isExpanded},Object.defineProperty(t.prototype,"allowClose",{get:function(){return this.getPropertyValue("allowClose",!1)},set:function(e){this.setPropertyValue("allowClose",e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"allowFullScreen",{get:function(){return this.getPropertyValue("allowFullScreen",!1)},set:function(e){this.setPropertyValue("allowFullScreen",e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"css",{get:function(){return this.survey.css},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"cssButton",{get:function(){return this.getPropertyValue("cssButton","")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"cssRoot",{get:function(){var e=this.getPropertyValue("cssRoot","");return this.isCollapsed&&(e+=" "+this.getPropertyValue("cssRootCollapsedMod","")),e},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"cssRootCollapsedMod",{get:function(){return this.getPropertyValue("cssRootCollapsedMod")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"cssRootContent",{get:function(){return this.getPropertyValue("cssRootContent")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"cssBody",{get:function(){return this.getPropertyValue("cssBody","")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"cssHeaderRoot",{get:function(){return this.getPropertyValue("cssHeaderRoot","")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"cssHeaderTitleCollapsed",{get:function(){return this.getPropertyValue("cssHeaderTitleCollapsed","")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"cssHeaderButtonsContainer",{get:function(){return this.getPropertyValue("cssHeaderButtonsContainer","")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"cssHeaderCollapseButton",{get:function(){return this.getPropertyValue("cssHeaderCollapseButton","")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"cssHeaderCloseButton",{get:function(){return this.getPropertyValue("cssHeaderCloseButton","")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"cssHeaderFullScreenButton",{get:function(){return this.getPropertyValue("cssHeaderFullScreenButton","")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"renderedWidth",{get:function(){var e=this.getPropertyValue("width","60%");return e&&!isNaN(e)&&(e+="px"),e},enumerable:!1,configurable:!0}),t.prototype.updateCss=function(){if(this.css&&this.css.window){var e=this.css.window;this.setCssRoot(),this.setPropertyValue("cssRootCollapsedMod",e.rootCollapsedMod),this.setPropertyValue("cssRootContent",e.rootContent),this.setPropertyValue("cssBody",e.body);var t=e.header;t&&(this.setPropertyValue("cssHeaderRoot",t.root),this.setPropertyValue("cssHeaderTitleCollapsed",t.titleCollapsed),this.setPropertyValue("cssHeaderButtonsContainer",t.buttonsContainer),this.setPropertyValue("cssHeaderCollapseButton",t.collapseButton),this.setPropertyValue("cssHeaderCloseButton",t.closeButton),this.setPropertyValue("cssHeaderFullScreenButton",t.fullScreenButton),this.updateCssButton())}},t.prototype.setCssRoot=function(){var e=this.css.window;this.isFullScreen?this.setPropertyValue("cssRoot",e.root+" "+e.rootFullScreenMode):this.setPropertyValue("cssRoot",e.root)},t.prototype.updateCssButton=function(){var e=this.css.window?this.css.window.header:null;e&&this.setCssButton(this.isExpanded?e.buttonExpanded:e.buttonCollapsed)},t.prototype.setCssButton=function(e){e&&this.setPropertyValue("cssButton",e)},t.prototype.createSurvey=function(e){return new zi(e)},t.prototype.onSurveyComplete=function(){if(!(this.closeOnCompleteTimeout<0))if(0==this.closeOnCompleteTimeout)this.hide();else{var e=this,t=null;t=setInterval((function(){e.hide(),clearInterval(t)}),1e3*this.closeOnCompleteTimeout)}},t.prototype.onScroll=function(){this.survey.onScroll()},ga([m()],t.prototype,"width",void 0),t}(Ve),ma=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return fa(t,e),t}(ya),va=function(){var e=function(t,n){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(t,n)};return function(t,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function o(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(o.prototype=n.prototype,new o)}}(),ba=function(e){function t(t){var n=e.call(this,t)||this;return n.onScrollOutsideCallback=function(e){n.preventScrollOuside(e,e.deltaY)},n}return va(t,e),t.prototype.getStyleClass=function(){return e.prototype.getStyleClass.call(this).append("sv-popup--modal",!this.isOverlay)},t.prototype.getShowFooter=function(){return!0},t.prototype.createFooterActionBar=function(){var t=this;e.prototype.createFooterActionBar.call(this),this.footerToolbar.containerCss="sv-footer-action-bar",this.footerToolbarValue.addAction({id:"apply",visibleIndex:20,title:this.applyButtonText,innerCss:"sv-popup__body-footer-item sv-popup__button sv-popup__button--apply sd-btn sd-btn--action",action:function(){t.apply()}})},Object.defineProperty(t.prototype,"applyButtonText",{get:function(){return this.getLocalizationString("modalApplyButtonText")},enumerable:!1,configurable:!0}),t.prototype.apply=function(){this.model.onApply&&!this.model.onApply()||this.hidePopup()},t.prototype.clickOutside=function(){},t.prototype.onKeyDown=function(t){"Escape"!==t.key&&27!==t.keyCode||this.model.onCancel(),e.prototype.onKeyDown.call(this,t)},t.prototype.updateOnShowing=function(){this.container&&this.container.addEventListener("wheel",this.onScrollOutsideCallback,{passive:!1}),e.prototype.updateOnShowing.call(this)},t.prototype.updateOnHiding=function(){this.container&&this.container.removeEventListener("wheel",this.onScrollOutsideCallback),e.prototype.updateOnHiding.call(this)},t}(tr),Ca=function(){return(Ca=Object.assign||function(e){for(var t,n=1,o=arguments.length;n<o;n++)for(var i in t=arguments[n])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e}).apply(this,arguments)};function Pa(e,t){var n,o=Ca({},e);o.verticalPosition="top",o.horizontalPosition="left",o.showPointer=!1,o.isModal=!0,o.displayMode=e.displayMode||"popup";var r=new Qe(e.componentName,e.data,o);r.isFocusedContent=null===(n=e.isFocusedContent)||void 0===n||n;var s=new ba(r);if(t&&t.appendChild){var a=i.createElement("div");t.appendChild(a),s.setComponentElement(a)}s.container||s.initializePopupContainer();var l=function(e,t){t.isVisible||a&&s.resetComponentElement(),s.onVisibilityChanged.remove(l)};return s.onVisibilityChanged.add(l),s}function wa(e){return e.isModal?new ba(e):new rr(e)}var Va=function(){var e=function(t,n){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(t,n)};return function(t,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function o(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(o.prototype=n.prototype,new o)}}(),xa=function(e,t,n,o){var i,r=arguments.length,s=r<3?t:null===o?o=Object.getOwnPropertyDescriptor(t,n):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,n,o);else for(var a=e.length-1;a>=0;a--)(i=e[a])&&(s=(r<3?i(s):r>3?i(t,n,s):i(t,n))||s);return r>3&&s&&Object.defineProperty(t,n,s),s},Oa=function(e){function t(t,n,o){void 0===n&&(n=null),void 0===o&&(o="buttongroupitemvalue");var i=e.call(this,t,n,o)||this;return i.typeName=o,i}return Va(t,e),t.prototype.getType=function(){return this.typeName?this.typeName:"buttongroupitemvalue"},xa([m()],t.prototype,"iconName",void 0),xa([m()],t.prototype,"iconSize",void 0),xa([m()],t.prototype,"showCaption",void 0),t}(kn),Sa=function(e){function t(t){var n=e.call(this,t)||this;return n.createLocalizableString("buttongroupOptionsCaption",n,!1,!0),n.createLocalizableString("readOnlyText",n,!0),n.registerPropertyChangedHandlers(["value","renderAs","placeholder","choices","visibleChoices"],(function(){n.updateReadOnlyText()})),n.updateReadOnlyText(),n}return Va(t,e),t.prototype.locStrsChanged=function(){var t;e.prototype.locStrsChanged.call(this),this.updateReadOnlyText(),null===(t=this.dropdownListModelValue)||void 0===t||t.locStrsChanged()},t.prototype.updateReadOnlyText=function(){this.readOnlyText=this.displayValue||this.placeholder},t.prototype.getType=function(){return"buttongroup"},t.prototype.getItemValueType=function(){return"buttongroupitemvalue"},t.prototype.supportOther=function(){return!1},t}(Ji);D.addClass("buttongroup",[{name:"choices:buttongroupitemvalue[]"}],(function(){return new Sa("")}),"checkboxbase"),D.addClass("buttongroupitemvalue",[{name:"showCaption:boolean",default:!0},{name:"iconName:text"},{name:"iconSize:number"}],(function(e){return new Oa(e)}),"itemvalue");var Ta=function(){function e(e,t,n){this.question=e,this.item=t,this.index=n}return Object.defineProperty(e.prototype,"value",{get:function(){return this.item.value},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"iconName",{get:function(){return this.item.iconName},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"iconSize",{get:function(){return this.item.iconSize||24},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"caption",{get:function(){return this.item.locText},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"showCaption",{get:function(){return this.item.showCaption||void 0===this.item.showCaption},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"isRequired",{get:function(){return this.question.isRequired},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"selected",{get:function(){return this.question.isItemSelected(this.item)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"readOnly",{get:function(){return this.question.isInputReadOnly||!this.item.isEnabled},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"name",{get:function(){return this.question.name+"_"+this.question.id},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"id",{get:function(){return this.question.inputId+"_"+this.index},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"hasErrors",{get:function(){return this.question.errors.length>0},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"describedBy",{get:function(){return this.question.errors.length>0?this.question.id+"_errors":null},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"labelClass",{get:function(){return(new Ee).append(this.question.cssClasses.item).append(this.question.cssClasses.itemSelected,this.selected).append(this.question.cssClasses.itemHover,!this.readOnly&&!this.selected).append(this.question.cssClasses.itemDisabled,this.question.isReadOnly||!this.item.isEnabled).toString()},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"css",{get:function(){return{label:this.labelClass,icon:this.question.cssClasses.itemIcon,control:this.question.cssClasses.itemControl,caption:this.question.cssClasses.itemCaption,decorator:this.question.cssClasses.itemDecorator}},enumerable:!1,configurable:!0}),e.prototype.onChange=function(){this.question.renderedValue=this.item.value},e}(),Ia=function(){var e=function(t,n){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(t,n)};return function(t,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function o(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(o.prototype=n.prototype,new o)}}(),Ra=function(e,t,n,o){var i,r=arguments.length,s=r<3?t:null===o?o=Object.getOwnPropertyDescriptor(t,n):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,n,o);else for(var a=e.length-1;a>=0;a--)(i=e[a])&&(s=(r<3?i(s):r>3?i(t,n,s):i(t,n))||s);return r>3&&s&&Object.defineProperty(t,n,s),s},Ea=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return Ia(t,e),t.prototype.getSurvey=function(e){return void 0===e&&(e=!1),this.owner},t.prototype.getType=function(){return"masksettings"},t.prototype.setData=function(e){var t=this;D.getProperties(this.getType()).forEach((function(n){var o=e[n.name];t[n.name]=void 0!==o?o:n.getDefaultValue(t)}))},t.prototype.getData=function(){var e=this,t={};return D.getProperties(this.getType()).forEach((function(n){var o=e[n.name];n.isDefaultValue(o)||(t[n.name]=o)})),t},t.prototype.processInput=function(e){return{value:e.prevValue,caretPosition:e.selectionEnd,cancelPreventDefault:!1}},t.prototype.getUnmaskedValue=function(e){return e},t.prototype.getMaskedValue=function(e){return e},t.prototype.getTextAlignment=function(){return"auto"},t.prototype.getTypeForExpressions=function(){return"text"},Ra([m()],t.prototype,"saveMaskedValue",void 0),t}(Ve);D.addClass("masksettings",[{name:"saveMaskedValue:boolean",visibleIf:function(e){return!!e&&"masksettings"!==e.getType()}}],(function(){return new Ea}));var _a=function(){var e=function(t,n){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(t,n)};return function(t,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function o(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(o.prototype=n.prototype,new o)}}(),Aa=function(e,t,n,o){var i,r=arguments.length,s=r<3?t:null===o?o=Object.getOwnPropertyDescriptor(t,n):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,n,o);else for(var a=e.length-1;a>=0;a--)(i=e[a])&&(s=(r<3?i(s):r>3?i(t,n,s):i(t,n))||s);return r>3&&s&&Object.defineProperty(t,n,s),s};function Da(e){for(var t=[],n=!1,o=Object.keys(Xt.maskSettings.patternDefinitions),i=0;i<e.length;i++){var r=e[i];r===Xt.maskSettings.patternEscapeChar?n=!0:n?(n=!1,t.push({type:"fixed",value:r})):t.push({type:-1!==o.indexOf(r)?"regex":"const",value:r})}return t}function La(e,t,n){for(var o=Xt.maskSettings.patternDefinitions[n.value];t<e.length;){if(e[t].match(o))return t;t++}return t}function ja(e,t,n,o){void 0===o&&(o=!1);var i="";if(!e)return i;for(var r="string"==typeof t?Da(t):t,s=0;s<r.length;s++)if("fixed"!==r[s].type||o||(i+=r[s].value),"regex"===r[s].type){var a=Xt.maskSettings.patternDefinitions[r[s].value];if(!e[s]||!e[s].match(a)){if(n){i="";break}break}i+=e[s]}return i}var ka=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.literals=[],t}return _a(t,e),t.prototype.updateLiterals=function(){this.literals=Da(this.pattern||"")},t.prototype.onPropertyValueChanged=function(e,t,n){"pattern"===e&&this.updateLiterals()},t.prototype.getType=function(){return"patternmask"},t.prototype.fromJSON=function(t,n){e.prototype.fromJSON.call(this,t,n),this.updateLiterals()},t.prototype._getMaskedValue=function(e,t){return void 0===t&&(t=!1),function(e,t,n){for(var o=null==e?"":e,i="",r=0,s="string"==typeof t?Da(t):t,a=0;a<s.length;a++)switch(s[a].type){case"regex":if(r<o.length&&(r=La(o,r,s[a])),r<o.length)i+=o[r];else{if(!n)return i;i+=Xt.maskSettings.patternPlaceholderChar}r++;break;case"const":case"fixed":i+=s[a].value,s[a].value===o[r]&&r++}return i}(null==e?"":e,this.literals,t)},t.prototype._getUnmaskedValue=function(e,t){return void 0===t&&(t=!1),ja(null==e?"":e,this.literals,t)},t.prototype.processInput=function(e){var t={value:e.prevValue,caretPosition:e.selectionEnd,cancelPreventDefault:!1};if(!e.insertedChars&&e.selectionStart===e.selectionEnd)return t;var n=e.prevValue.slice(0,e.selectionStart)+(e.insertedChars||""),o=ja(e.prevValue.slice(0,e.selectionStart),this.literals.slice(0,e.selectionStart),!1),i=ja(e.prevValue.slice(e.selectionEnd),this.literals.slice(e.selectionEnd),!1,!0);return t.value=this._getMaskedValue(o+(e.insertedChars||"")+i,!0),e.insertedChars||"backward"!==e.inputDirection?t.caretPosition=this._getMaskedValue(n).length:t.caretPosition=e.selectionStart,t},t.prototype.getMaskedValue=function(e){return this._getMaskedValue(e,!0)},t.prototype.getUnmaskedValue=function(e){return this._getUnmaskedValue(e,!0)},Aa([m()],t.prototype,"pattern",void 0),t}(Ea);D.addClass("patternmask",[{name:"pattern"}],(function(){return new ka}),"masksettings");var Na=function(){var e=function(t,n){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(t,n)};return function(t,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function o(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(o.prototype=n.prototype,new o)}}(),Ma=function(e,t,n,o){var i,r=arguments.length,s=r<3?t:null===o?o=Object.getOwnPropertyDescriptor(t,n):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,n,o);else for(var a=e.length-1;a>=0;a--)(i=e[a])&&(s=(r<3?i(s):r>3?i(t,n,s):i(t,n))||s);return r>3&&s&&Object.defineProperty(t,n,s),s};var Fa=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return Na(t,e),t.prototype.calccaretPosition=function(e,t,n){for(var o=e?this.displayNumber(this.parseNumber(e),!1).length:0,i=0,r=t.selectionStart,s=!t.insertedChars&&"forward"===t.inputDirection,a=0;a<n.length;a++){if(n[a]!==this.thousandsSeparator&&i++,i===o+(s?1:0)){r=s?a:a+1;break}}return r},t.prototype.numericalCompositionIsEmpty=function(e){return!e.integralPart&&!e.fractionalPart},t.prototype.displayNumber=function(e,t,n){void 0===t&&(t=!0),void 0===n&&(n=!1);var o=e.integralPart;t&&o&&(o=function(e,t,n){void 0===t&&(t=!0),void 0===n&&(n=3);var o=[];if(t){for(var i=e.length-n;i>-n;i-=n)o.push(e.substring(i,i+n));o=o.reverse()}else for(i=0;i<e.length;i+=n)o.push(e.substring(i,i+n));return o}(o).join(this.thousandsSeparator));var i=e.fractionalPart,r=e.isNegative?"-":"";if(""===i){if(n)return o&&"0"!==o?r+o:o;var s=o+(e.hasDecimalSeparator&&!n?this.decimalSeparator:"");return"0"===s?s:r+s}return[r+(o=o||"0"),i=i.substring(0,this.precision)].join(this.decimalSeparator)},t.prototype.convertNumber=function(e){var t=e.isNegative?"-":"";return e.fractionalPart?parseFloat(t+(e.integralPart||"0")+"."+e.fractionalPart.substring(0,this.precision)):parseInt(t+e.integralPart||"0")},t.prototype.validateNumber=function(e,t){var n=this.min||Number.MIN_SAFE_INTEGER,o=this.max||Number.MAX_SAFE_INTEGER;if(this.numericalCompositionIsEmpty(e))return!0;if(void 0!==this.min||void 0!==this.max){var i=this.convertNumber(e);if(Number.isNaN(i))return!0;if(i>=n&&i<=o)return!0;if(!t){if(e.hasDecimalSeparator||0==i){var r=Math.pow(.1,(e.fractionalPart||"").length);if(i>=0)return i+r>n&&i<=o;if(i<0)return i>=n&&i-r<o}else{var s=i,a=i;if(i>0){if(i+1>n&&i<=o)return!0;for(;s=10*s+9,!((a*=10)>o);)if(s>n)return!0;return!1}if(i<0){if(i>=n&&i-1<o)return!0;for(;a=10*a-9,!((s*=10)<n);)if(a<o)return!0;return!1}}return i>=0&&i<=o||i<0&&i>=n}return!1}return!0},t.prototype.parseNumber=function(e){for(var t={integralPart:"",fractionalPart:"",hasDecimalSeparator:!1,isNegative:!1},n=null==e?"":e.toString(),o=0,i=0;i<n.length;i++){var r=n[i];switch(r){case"-":this.allowNegativeValues&&(void 0===this.min||this.min<0)&&o++;break;case this.decimalSeparator:this.precision>0&&(t.hasDecimalSeparator=!0);break;case this.thousandsSeparator:break;default:r.match(Pr)&&(t.hasDecimalSeparator?t.fractionalPart+=r:t.integralPart+=r)}}return t.isNegative=o%2!=0,t.integralPart.length>1&&"0"===t.integralPart[0]&&(t.integralPart=t.integralPart.slice(1)),t},t.prototype.getNumberMaskedValue=function(e,t){void 0===t&&(t=!1);var n=this.parseNumber(e);return this.validateNumber(n,t)?this.displayNumber(n,!0,t):null},t.prototype.getNumberUnmaskedValue=function(e){var t=this.parseNumber(e);if(!this.numericalCompositionIsEmpty(t))return this.convertNumber(t)},t.prototype.getTextAlignment=function(){return"right"},t.prototype.getMaskedValue=function(e){var t=null==e?"":e.toString();return t=t.replace(".",this.decimalSeparator),this.getNumberMaskedValue(t,!0)},t.prototype.getUnmaskedValue=function(e){return this.getNumberUnmaskedValue(e)},t.prototype.processInput=function(e){var t={value:e.prevValue,caretPosition:e.selectionEnd,cancelPreventDefault:!1},n=e.prevValue.slice(0,e.selectionStart)+(e.insertedChars||""),o=n+e.prevValue.slice(e.selectionEnd),i=this.parseNumber(o);if(!this.validateNumber(i,!1))return t;var r=this.getNumberMaskedValue(o),s=this.calccaretPosition(n,e,r);return t.value=r,t.caretPosition=s,t},t.prototype.getType=function(){return"numericmask"},t.prototype.isValueUndefined=function(t){return""===t||e.prototype.isValueUndefined.call(this,t)},Ma([m()],t.prototype,"allowNegativeValues",void 0),Ma([m()],t.prototype,"decimalSeparator",void 0),Ma([m()],t.prototype,"precision",void 0),Ma([m()],t.prototype,"thousandsSeparator",void 0),Ma([m()],t.prototype,"min",void 0),Ma([m()],t.prototype,"max",void 0),t}(Ea);D.addClass("numericmask",[{name:"allowNegativeValues:boolean",default:!0},{name:"decimalSeparator",default:".",maxLength:1},{name:"thousandsSeparator",default:",",maxLength:1},{name:"precision:number",default:2,minValue:0},{name:"min:number"},{name:"max:number"}],(function(){return new Fa}),"masksettings");var qa=function(){var e=function(t,n){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(t,n)};return function(t,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function o(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(o.prototype=n.prototype,new o)}}(),Ba=function(){return(Ba=Object.assign||function(e){for(var t,n=1,o=arguments.length;n<o;n++)for(var i in t=arguments[n])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e}).apply(this,arguments)},Qa=function(e,t,n,o){var i,r=arguments.length,s=r<3?t:null===o?o=Object.getOwnPropertyDescriptor(t,n):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,n,o);else for(var a=e.length-1;a>=0;a--)(i=e[a])&&(s=(r<3?i(s):r>3?i(t,n,s):i(t,n))||s);return r>3&&s&&Object.defineProperty(t,n,s),s};function za(e,t){switch(e){case"hour":case"minute":case"second":case"day":case"month":return 2;case"timeMarker":case"year":return t;default:return 1}}var Ha=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.defaultDate="1970-01-01T",t.turnOfTheCentury=68,t.twelve=12,t.lexems=[],t.inputDateTimeData=[],t.validBeginningOfNumbers={hour:1,hourU:2,minute:5,second:5,day:3,month:1},t}return qa(t,e),Object.defineProperty(t.prototype,"hasDatePart",{get:function(){return this.lexems.some((function(e){return"day"===e.type||"month"===e.type||"year"===e.type}))},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"hasTimePart",{get:function(){return this.lexems.some((function(e){return"hour"===e.type||"minute"===e.type||"second"===e.type}))},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"is12Hours",{get:function(){return this.lexems.filter((function(e){return"hour"===e.type&&!e.upperCase})).length>0},enumerable:!1,configurable:!0}),t.prototype.getType=function(){return"datetimemask"},t.prototype.getTypeForExpressions=function(){return this.hasTimePart?"datetime-local":"datetime"},t.prototype.updateLiterals=function(){this.lexems=function(e){for(var t,n=[],o=function(e,o,i){if(void 0===i&&(i=!1),t&&t===e){n[n.length-1].count++;var r=za(e,n[n.length-1].count);n[n.length-1].maxCount=r}else{r=za(e,1);n.push({type:e,value:o,count:1,maxCount:r,upperCase:i})}},i=0;i<e.length;i++){var r=e[i];switch(r){case"m":o("month",r);break;case"d":o("day",r);break;case"y":o("year",r);break;case"h":o("hour",r,!1);break;case"H":o("hour",r,!0);break;case"M":o("minute",r);break;case"s":o("second",r);break;case"t":o("timeMarker",r);break;case"T":o("timeMarker",r,!0);break;default:n.push({type:"separator",value:r,count:1,maxCount:1,upperCase:!1})}t=n[n.length-1].type}return n}(this.pattern||"")},t.prototype.leaveOnlyNumbers=function(e){for(var t="",n=0;n<e.length;n++)e[n].match(Pr)&&(t+=e[n]);return t},t.prototype.getMaskedStrFromISO=function(e){var t=this,n=new Date(e);return this.initInputDateTimeData(),this.hasTimePart||(n=new Date(e+"T00:00:00")),this.hasDatePart||(n=new Date(this.defaultDate+e)),isNaN(n)||this.lexems.forEach((function(e,o){var i=t.inputDateTimeData[o];switch(i.isCompleted=!0,e.type){case"hour":t.is12Hours?i.value=((n.getHours()-1)%t.twelve+1).toString():i.value=n.getHours().toString();break;case"minute":i.value=n.getMinutes().toString();break;case"second":i.value=n.getSeconds().toString();break;case"timeMarker":var r=n.getHours()>=t.twelve?"pm":"am";i.value=e.upperCase?r.toUpperCase():r;break;case"day":i.value=n.getDate().toString();break;case"month":i.value=(n.getMonth()+1).toString();break;case"year":var s=n.getFullYear();2==e.count&&(s%=100),i.value=s.toString()}})),this.getFormatedString(!0)},t.prototype.initInputDateTimeData=function(){var e=this;this.inputDateTimeData=[],this.lexems.forEach((function(t){e.inputDateTimeData.push({lexem:t,isCompleted:!1,value:void 0})}))},t.prototype.getISO_8601Format=function(e){var t=[],n=[];if(void 0!==e.year){var o=this.getPlaceholder(4,e.year.toString(),"0")+e.year;t.push(o)}if(void 0!==e.month&&void 0!==e.year){var i=this.getPlaceholder(2,e.month.toString(),"0")+e.month;t.push(i)}if(void 0!==e.day&&void 0!==e.month&&void 0!==e.year){var r=this.getPlaceholder(2,e.day.toString(),"0")+e.day;t.push(r)}if(void 0!==e.hour){var s=this.getPlaceholder(2,e.hour.toString(),"0")+e.hour;n.push(s)}if(void 0!==e.minute&&void 0!==e.hour){var a=this.getPlaceholder(2,e.minute.toString(),"0")+e.minute;n.push(a)}if(void 0!==e.second&&void 0!==e.minute&&void 0!==e.hour){var l=this.getPlaceholder(2,e.second.toString(),"0")+e.second;n.push(l)}var u=[];return t.length>0&&u.push(t.join("-")),n.length>1&&u.push(n.join(":")),u.join("T")},t.prototype.isYearValid=function(e){if(void 0===e.min&&void 0===e.max)return!1;var t=e.year.toString(),n=e.min.toISOString().slice(0,t.length),o=e.max.toISOString().slice(0,t.length);return e.year>=parseInt(n)&&e.year<=parseInt(o)},t.prototype.createIDateTimeCompositionWithDefaults=function(e,t){var n=29==e.day&&2==e.month,o=e.min.getFullYear(),i=e.max.getFullYear();n&&(o=4*Math.ceil(o/4))>(i=4*Math.floor(i/4))&&(o=void 0,i=void 0);var r=void 0!==e.year?e.year:t?i:o,s=void 0!==e.month?e.month:t&&this.hasDatePart?12:1;return{year:r,month:s,day:void 0!==e.day?e.day:t&&this.hasDatePart?this.getMaxDateForMonth(r,s):1,hour:void 0!==e.hour?e.hour:t?23:0,minute:void 0!==e.minute?e.minute:t?59:0,second:void 0!==e.second?e.second:t?59:0}},t.prototype.getMaxDateForMonth=function(e,t){return 2==t?e%4==0&&e%100!=0||e%400==0?29:28:[31,28,31,30,31,30,31,31,30,31,30,31][t-1]},t.prototype.isDateValid=function(e){var t=new Date(this.getISO_8601Format(this.createIDateTimeCompositionWithDefaults(e,!1))),n=new Date(this.getISO_8601Format(this.createIDateTimeCompositionWithDefaults(e,!0)));return!isNaN(t)&&(t.getDate()===e.day||void 0===e.day)&&(t.getMonth()===e.month-1||void 0===e.month)&&(t.getFullYear()===e.year||void 0===e.year)&&n>=e.min&&t<=e.max},t.prototype.getPlaceholder=function(e,t,n){var o=e-(t||"").length;return o>0?n.repeat(o):""},t.prototype.isDateValid12=function(e){return this.is12Hours?!(this.is12Hours&&e.hour>this.twelve)&&(e.timeMarker?"p"===e.timeMarker[0].toLowerCase()?(e.hour!==this.twelve&&(e.hour+=this.twelve),this.isDateValid(e)):(e.hour===this.twelve&&(e.hour=0),this.isDateValid(e)):!!this.isDateValid(e)||(e.hour+=this.twelve,this.isDateValid(e))):this.isDateValid(e)},t.prototype.updateTimeMarkerInputDateTimeData=function(e,t){var n=e.value;if(n){var o=Ba({},t);o.timeMarker=n,this.isDateValid12(o)?e.isCompleted=!0:n=n.slice(0,n.length-1),e.value=n||void 0,t.timeMarker=n||void 0}},t.prototype.updateInputDateTimeData=function(e,t){var n=e.value;if(n){var o=e.lexem.type,i=Ba({},t);if(i[o]=parseInt(this.parseTwoDigitYear(e)),n.length===e.lexem.maxCount){if(this.isDateValid12(i))return e.isCompleted=!0,e.value=n||void 0,void(t[o]=parseInt(n)>0?parseInt(n):void 0);n=n.slice(0,n.length-1)}i[o]=parseInt(n);var r=parseInt(n[0]),s=this.validBeginningOfNumbers[o+(e.lexem.upperCase?"U":"")];"year"!==o||this.isYearValid(i)?void 0!==s&&r>s?this.isDateValid12(i)?e.isCompleted=!0:n=n.slice(0,n.length-1):void 0!==s&&0!==r&&r<=s&&(this.checkValidationDateTimePart(i,o,e),e.isCompleted&&!this.isDateValid12(i)&&(n=n.slice(0,n.length-1))):(n=n.slice(0,n.length-1),e.isCompleted=!1),e.value=n||void 0,t[o]=parseInt(n)>0?parseInt(n):void 0}},t.prototype.checkValidationDateTimePart=function(e,t,n){var o=e[t],i=10*o,r=10;"month"===t&&(r=3),"hour"===t&&(r=this.is12Hours?3:5),n.isCompleted=!0;for(var s=0;s<r;s++)if(e[t]=i+s,this.isDateValid12(e)){n.isCompleted=!1;break}e[t]=o},t.prototype.getCorrectDatePartFormat=function(e,t){var n=e.lexem,o=e.value||"";if(o&&"timeMarker"===n.type)return t&&(o+=this.getPlaceholder(n.count,o,n.value)),o;(o&&e.isCompleted&&(o=parseInt(o).toString()),o&&e.isCompleted)?o=this.getPlaceholder(n.count,o,"0")+o:(o=function(e,t){var n=t;return e.count<e.maxCount&&("day"===e.type&&0===parseInt(t[0])||"month"===e.type&&0===parseInt(t[0]))&&(n=t.slice(1,t.length)),n}(n,o),t&&(o+=this.getPlaceholder(n.count,o,n.value)));return o},t.prototype.createIDateTimeComposition=function(){var e,t;return this.hasDatePart?(e=this.min||"0001-01-01",t=this.max||"9996-12-31"):(e=this.defaultDate+(this.min||"00:00:00"),t=this.defaultDate+(this.max||"23:59:59")),{hour:void 0,minute:void 0,second:void 0,day:void 0,month:void 0,year:void 0,min:new Date(e),max:new Date(t)}},t.prototype.parseTwoDigitYear=function(e){var t=e.value;return"year"!==e.lexem.type||e.lexem.count>2?t:(this.max&&this.max.length>=4&&(this.turnOfTheCentury=parseInt(this.max.slice(2,4))),(parseInt(t)>this.turnOfTheCentury?"19":"20")+t)},t.prototype.getFormatedString=function(e){var t="",n="",o=!1,i=this.inputDateTimeData.length-1;if(!e){var r=this.inputDateTimeData.filter((function(e){return!!e.value}));i=this.inputDateTimeData.indexOf(r[r.length-1])}for(var s=0;s<this.inputDateTimeData.length;s++){var a=this.inputDateTimeData[s];switch(a.lexem.type){case"timeMarker":case"hour":case"minute":case"second":case"day":case"month":case"year":if(void 0===a.value&&!e)return t+=o?n:"";var l=e||i>s;t+=n+this.getCorrectDatePartFormat(a,l),o=a.isCompleted;break;case"separator":n=a.lexem.value}}return t},t.prototype.cleanTimeMarker=function(e,t){var n="";e=e.toUpperCase();for(var o=0;o<e.length;o++)(!n&&("P"==e[o]||"A"==e[o])||n&&"M"==e[o])&&(n+=e[o]);return n=t?n.toUpperCase():n.toLowerCase()},t.prototype.setInputDateTimeData=function(e){var t=this,n=0;this.initInputDateTimeData(),this.lexems.forEach((function(o,i){if(e.length>0&&n<e.length){if("separator"===o.type)return;var r=t.inputDateTimeData[i],s=e[n],a=void 0;a="timeMarker"===o.type?t.cleanTimeMarker(s,o.upperCase):t.leaveOnlyNumbers(s),r.value=a.slice(0,o.maxCount),n++}}))},t.prototype._getMaskedValue=function(e,t){var n=this;void 0===t&&(t=!0);var o=null==e?"":e.toString(),i=this.getParts(o);this.setInputDateTimeData(i);var r=this.createIDateTimeComposition();return this.inputDateTimeData.forEach((function(e){"timeMarker"===e.lexem.type?n.updateTimeMarkerInputDateTimeData(e,r):n.updateInputDateTimeData(e,r)})),this.getFormatedString(t)},t.prototype.getParts=function(e){for(var t=[],n=this.lexems.filter((function(e){return"separator"!==e.type})),o=this.lexems.filter((function(e){return"separator"===e.type})).map((function(e){return e.value})),i="",r=!1,s=!1,a=0;a<e.length;a++){var l=e[a];if(l.match(Pr)||l===n[t.length].value||"timeMarker"===n[t.length].type?(r=!1,s=!1,i+=l):-1!==o.indexOf(l)?s||(r=!0,t.push(i),i=""):r||(s=!0,t.push(i),i=""),t.length>=n.length){r=!1;break}}return(""!=i||r)&&t.push(i),t},t.prototype.getUnmaskedValue=function(e){var t,n=this,o=null==e?"":e.toString(),i=this.getParts(o);this.setInputDateTimeData(i);var r=null===(t=this.inputDateTimeData.filter((function(e){return"timeMarker"===e.lexem.type}))[0])||void 0===t?void 0:t.value.toLowerCase()[0],s=this.createIDateTimeComposition(),a=!1;return this.inputDateTimeData.forEach((function(e){var t=e.value;if("timeMarker"!=e.lexem.type&&"separator"!=e.lexem.type)if(!t||t.length<e.lexem.count)a=!0;else{var o=parseInt(n.parseTwoDigitYear(e));"hour"==e.lexem.type&&"p"===r&&o!=n.twelve&&(o+=n.twelve),s[e.lexem.type]=o}})),a?"":this.getISO_8601Format(s)},t.prototype.getMaskedValue=function(e){return this.getMaskedStrFromISO(e)},t.prototype.processInput=function(e){var t={value:e.prevValue,caretPosition:e.selectionEnd,cancelPreventDefault:!1},n=e.prevValue.slice(0,e.selectionStart),o=e.prevValue.slice(e.selectionEnd);return t.value=this._getMaskedValue(n+(e.insertedChars||"")+o),e.insertedChars||"backward"!==e.inputDirection?t.caretPosition=this._getMaskedValue(n+(e.insertedChars||""),!1).length:t.caretPosition=e.selectionStart,t},Qa([m()],t.prototype,"min",void 0),Qa([m()],t.prototype,"max",void 0),t}(ka);D.addClass("datetimemask",[{name:"min",type:"datetime",enableIf:function(e){return!!e.pattern}},{name:"max",type:"datetime",enableIf:function(e){return!!e.pattern}}],(function(){return new Ha}),"patternmask");var Ua,Wa,Ga=function(){var e=function(t,n){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(t,n)};return function(t,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function o(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(o.prototype=n.prototype,new o)}}(),Ja=function(e,t,n,o){var i,r=arguments.length,s=r<3?t:null===o?o=Object.getOwnPropertyDescriptor(t,n):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,n,o);else for(var a=e.length-1;a>=0;a--)(i=e[a])&&(s=(r<3?i(s):r>3?i(t,n,s):i(t,n))||s);return r>3&&s&&Object.defineProperty(t,n,s),s},Ka=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return Ga(t,e),t.prototype.getType=function(){return"currencymask"},t.prototype.wrapText=function(e){var t=this.prefix||"",n=this.suffix||"",o=e;return o?(-1===o.indexOf(t)&&(o=t+o),-1===o.indexOf(n)&&(o+=n),o):o},t.prototype.unwrapInputArgs=function(e){var t=e.prevValue;if(t){if(this.prefix&&-1!==t.indexOf(this.prefix)){t=t.slice(t.indexOf(this.prefix)+this.prefix.length);var n=(this.prefix||"").length;e.selectionStart=Math.max(e.selectionStart-n,0),e.selectionEnd-=n}this.suffix&&-1!==t.indexOf(this.suffix)&&(t=t.slice(0,t.indexOf(this.suffix))),e.prevValue=t}},t.prototype.processInput=function(t){this.unwrapInputArgs(t);var n=e.prototype.processInput.call(this,t),o=(this.prefix||"").length;return n.value&&(n.caretPosition+=o),n.value=this.wrapText(n.value),n},t.prototype.getMaskedValue=function(t){var n=e.prototype.getMaskedValue.call(this,t);return this.wrapText(n)},Ja([m()],t.prototype,"prefix",void 0),Ja([m()],t.prototype,"suffix",void 0),t}(Fa);function $a(e,t){if(Ua!=e){var n="survey-core has version '"+Ua+"' and "+t+" has version '"+e+"'. SurveyJS libraries should have the same versions to work correctly.";console.error(n)}}function Ya(e){Xa(e)}function Xa(e){!function(e,t,n){if(!e)return;var i=function(e){var t,n,o,i={},r=0,s=0,a="",l=String.fromCharCode,u=e.length;for(t=0;t<64;t++)i["ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".charAt(t)]=t;for(n=0;n<u;n++){for(r=(r<<6)+i[e.charAt(n)],s+=6;s>=8;)((o=r>>>(s-=8)&255)||n<u-2)&&(a+=l(o))}return a}(e);if(!i)return;var r=i.indexOf(";");if(r<0)return;if(!function(e){if(!e)return!0;var t="domains:",n=e.indexOf(t);if(n<0)return!0;var i=e.substring(n+t.length).toLowerCase().split(",");if(!Array.isArray(i)||0===i.length)return!0;var r=o.getLocation();if(r&&r.hostname){var s=r.hostname.toLowerCase();i.push("localhost");for(var a=0;a<i.length;a++)if(s.indexOf(i[a])>-1)return!0;return!1}return!0}(i.substring(0,r)))return;(i=i.substring(r+1)).split(",").forEach((function(e){var o=e.indexOf("=");o>0&&(t[e.substring(0,o)]=new Date(n)<=new Date(e.substring(o+1)))}))}(e,el,Wa)}function Za(e){return!0===el[e.toString()]}D.addClass("currencymask",[{name:"prefix"},{name:"suffix"}],(function(){return new Ka}),"numericmask"),Ua="1.12.45",Xt.version=Ua,Wa="2025-07-09";var el={};var tl={"$main-color":"#1ab394","$add-button-color":"#1948b3","$remove-button-color":"#ff1800","$disable-color":"#dbdbdb","$progress-text-color":"#9d9d9d","$disabled-label-color":"rgba(64, 64, 64, 0.5)","$slider-color":"white","$disabled-slider-color":"#cfcfcf","$error-color":"#d52901","$text-color":"#404040","$light-text-color":"#fff","$checkmark-color":"#fff","$progress-buttons-color":"#8dd9ca","$inputs-background-color":"transparent","$main-hover-color":"#9f9f9f","$body-container-background-color":"#f4f4f4","$text-border-color":"#d4d4d4","$disabled-text-color":"rgba(64, 64, 64, 0.5)","$border-color":"rgb(64, 64, 64, 0.5)","$header-background-color":"#e7e7e7","$answer-background-color":"rgba(26, 179, 148, 0.2)","$error-background-color":"rgba(213, 41, 1, 0.2)","$radio-checked-color":"#404040","$clean-button-color":"#1948b3","$body-background-color":"#ffffff","$foreground-light":"#909090","$font-family":"Raleway"},nl={"$header-background-color":"#e7e7e7","$body-container-background-color":"#f4f4f4","$main-color":"#1ab394","$main-hover-color":"#0aa384","$body-background-color":"white","$inputs-background-color":"white","$text-color":"#6d7072","$text-input-color":"#6d7072","$header-color":"#6d7072","$border-color":"#e7e7e7","$error-color":"#ed5565","$error-background-color":"#fcdfe2","$progress-text-color":"#9d9d9d","$disable-color":"#dbdbdb","$disabled-label-color":"rgba(64, 64, 64, 0.5)","$slider-color":"white","$disabled-switch-color":"#9f9f9f","$disabled-slider-color":"#cfcfcf","$foreground-light":"#909090","$foreground-disabled":"#161616","$background-dim":"#f3f3f3","$progress-buttons-color":"#8dd9ca","$progress-buttons-line-color":"#d4d4d4"},ol={"$header-background-color":"#4a4a4a","$body-container-background-color":"#f8f8f8","$main-color":"#f78119","$main-hover-color":"#e77109","$body-background-color":"white","$inputs-background-color":"white","$text-color":"#4a4a4a","$text-input-color":"#4a4a4a","$header-color":"#f78119","$border-color":"#e7e7e7","$error-color":"#ed5565","$error-background-color":"#fcdfe2","$progress-text-color":"#9d9d9d","$disable-color":"#dbdbdb","$disabled-label-color":"rgba(64, 64, 64, 0.5)","$slider-color":"white","$disabled-switch-color":"#9f9f9f","$disabled-slider-color":"#cfcfcf","$foreground-light":"#909090","$foreground-disabled":"#161616","$background-dim":"#f3f3f3","$progress-buttons-color":"#f7b781","$progress-buttons-line-color":"#d4d4d4"},il={"$header-background-color":"#d9d8dd","$body-container-background-color":"#f6f7f2","$main-color":"#3c4f6d","$main-hover-color":"#2c3f5d","$body-background-color":"white","$inputs-background-color":"white","$text-color":"#4a4a4a","$text-input-color":"#4a4a4a","$header-color":"#6d7072","$border-color":"#e7e7e7","$error-color":"#ed5565","$error-background-color":"#fcdfe2","$progress-text-color":"#9d9d9d","$disable-color":"#dbdbdb","$disabled-label-color":"rgba(64, 64, 64, 0.5)","$slider-color":"white","$disabled-switch-color":"#9f9f9f","$disabled-slider-color":"#cfcfcf","$foreground-light":"#909090","$foreground-disabled":"#161616","$background-dim":"#f3f3f3","$progress-buttons-color":"#839ec9","$progress-buttons-line-color":"#d4d4d4"},rl={"$header-background-color":"#ddd2ce","$body-container-background-color":"#f7efed","$main-color":"#68656e","$main-hover-color":"#58555e","$body-background-color":"white","$inputs-background-color":"white","$text-color":"#4a4a4a","$text-input-color":"#4a4a4a","$header-color":"#6d7072","$border-color":"#e7e7e7","$error-color":"#ed5565","$error-background-color":"#fcdfe2","$progress-text-color":"#9d9d9d","$disable-color":"#dbdbdb","$disabled-label-color":"rgba(64, 64, 64, 0.5)","$slider-color":"white","$disabled-switch-color":"#9f9f9f","$disabled-slider-color":"#cfcfcf","$foreground-light":"#909090","$foreground-disabled":"#161616","$background-dim":"#f3f3f3","$progress-buttons-color":"#c6bed4","$progress-buttons-line-color":"#d4d4d4"},sl={"$header-background-color":"#cdccd2","$body-container-background-color":"#efedf4","$main-color":"#0f0f33","$main-hover-color":"#191955","$body-background-color":"white","$inputs-background-color":"white","$text-color":"#0f0f33","$text-input-color":"#0f0f33","$header-color":"#0f0f33","$border-color":"#e7e7e7","$error-color":"#ed5565","$error-background-color":"#fcdfe2","$progress-text-color":"#9d9d9d","$disable-color":"#dbdbdb","$disabled-label-color":"rgba(64, 64, 64, 0.5)","$slider-color":"white","$disabled-switch-color":"#9f9f9f","$disabled-slider-color":"#cfcfcf","$foreground-light":"#909090","$foreground-disabled":"#161616","$background-dim":"#f3f3f3","$progress-buttons-color":"#747491","$progress-buttons-line-color":"#d4d4d4"},al={"$header-background-color":"#82b8da","$body-container-background-color":"#dae1e7","$main-color":"#3c3b40","$main-hover-color":"#1e1d20","$body-background-color":"white","$inputs-background-color":"white","$text-color":"#000","$text-input-color":"#000","$header-color":"#000","$border-color":"#e7e7e7","$error-color":"#ed5565","$error-background-color":"#fcdfe2","$disable-color":"#dbdbdb","$progress-text-color":"#9d9d9d","$disabled-label-color":"rgba(64, 64, 64, 0.5)","$slider-color":"white","$disabled-switch-color":"#9f9f9f","$disabled-slider-color":"#cfcfcf","$foreground-light":"#909090","$foreground-disabled":"#161616","$background-dim":"#f3f3f3","$progress-buttons-color":"#d1c9f5","$progress-buttons-line-color":"#d4d4d4"},ll={"$header-background-color":"#323232","$body-container-background-color":"#f8f8f8","$main-color":"#5ac8fa","$main-hover-color":"#06a1e7","$body-background-color":"white","$inputs-background-color":"white","$text-color":"#000","$text-input-color":"#000","$header-color":"#000","$border-color":"#e7e7e7","$error-color":"#ed5565","$error-background-color":"#fcdfe2","$disable-color":"#dbdbdb","$progress-text-color":"#9d9d9d","$disabled-label-color":"rgba(64, 64, 64, 0.5)","$slider-color":"white","$disabled-switch-color":"#9f9f9f","$disabled-slider-color":"#cfcfcf","$foreground-light":"#909090","$foreground-disabled":"#161616","$background-dim":"#f3f3f3","$progress-buttons-color":"#acdcf2","$progress-buttons-line-color":"#d4d4d4"};var ul=function(){function e(){e.autoApplyTheme()}return e.autoApplyTheme=function(){if("bootstrap"!==Xo.currentType&&"bootstrapmaterial"!==Xo.currentType){var t=e.getIncludedThemeCss();1===t.length&&e.applyTheme(t[0].name)}},e.getAvailableThemes=function(){return Xo.getAvailableThemes().filter((function(e){return-1!==["defaultV2","default","modern"].indexOf(e)})).map((function(e){return{name:e,theme:Xo[e]}}))},e.getIncludedThemeCss=function(){if(void 0===Xt.environment)return[];var t=Xt.environment.rootElement,n=e.getAvailableThemes(),o=wt(t)?t.host:t;if(o){var i=getComputedStyle(o);if(i.length)return n.filter((function(e){return e.theme.variables&&i.getPropertyValue(e.theme.variables.themeMark)}))}return[]},e.findSheet=function(e){if(void 0===Xt.environment)return null;for(var t=Xt.environment.root.styleSheets,n=0;n<t.length;n++)if(t[n].ownerNode&&t[n].ownerNode.id===e)return t[n];return null},e.createSheet=function(t){var n=Xt.environment.stylesSheetsMountContainer,o=i.createElement("style");return o.id=t,o.appendChild(new Text("")),Vt(n).appendChild(o),e.Logger&&e.Logger.log("style sheet "+t+" created"),o.sheet},e.applyTheme=function(t,n){if(void 0===t&&(t="default"),void 0!==Xt.environment){var o=Xt.environment.rootElement,i=wt(o)?o.host:o;if(Xo.currentType=t,e.Enabled){if("bootstrap"!==t&&"bootstrapmaterial"!==t)return function(e,t){Object.keys(e||{}).forEach((function(n){var o=n.substring(1);t.style.setProperty("--"+o,e[n])}))}(e.ThemeColors[t],i),void(e.Logger&&e.Logger.log("apply theme "+t+" completed"));var r=e.ThemeCss[t];if(!r)return void(Xo.currentType="defaultV2");e.insertStylesRulesIntoDocument();var s=n||e.ThemeSelector[t]||e.ThemeSelector.default,a=(t+s).trim(),l=e.findSheet(a);if(!l){l=e.createSheet(a);var u=e.ThemeColors[t]||e.ThemeColors.default;Object.keys(r).forEach((function(e){var t=r[e];Object.keys(u||{}).forEach((function(e){return t=t.replace(new RegExp("\\"+e,"g"),u[e])}));try{0===e.indexOf("body")?l.insertRule(e+" { "+t+" }",0):l.insertRule(s+e+" { "+t+" }",0)}catch(e){}}))}}e.Logger&&e.Logger.log("apply theme "+t+" completed")}},e.insertStylesRulesIntoDocument=function(){if(e.Enabled){var t=e.findSheet(e.SurveyJSStylesSheetId);t||(t=e.createSheet(e.SurveyJSStylesSheetId)),Object.keys(e.Styles).length&&Object.keys(e.Styles).forEach((function(n){try{t.insertRule(n+" { "+e.Styles[n]+" }",0)}catch(e){}})),Object.keys(e.Media).length&&Object.keys(e.Media).forEach((function(n){try{t.insertRule(e.Media[n].media+" { "+n+" { "+e.Media[n].style+" } }",0)}catch(e){}}))}},e.SurveyJSStylesSheetId="surveyjs-styles",e.Styles={},e.Media={},e.ThemeColors={modern:tl,default:nl,orange:ol,darkblue:il,darkrose:rl,stone:sl,winter:al,winterstone:ll},e.ThemeCss={},e.ThemeSelector={default:".sv_main ",modern:".sv-root-modern "},e.Enabled=!0,e}();zi.prototype.onBeforeRunConstructor=function(){o.isAvailable()&&ul.autoApplyTheme()};var cl={root:"sv_main sv_default_css",rootProgress:"sv_progress",container:"sv_container",header:"sv_header",bodyContainer:"sv-components-row",body:"sv_body",bodyEmpty:"sv_body sv_body_empty",footer:"sv_nav",title:"",description:"",logo:"sv_logo",logoImage:"sv_logo__image",headerText:"sv_header__text",navigationButton:"sv_nav_btn",completedPage:"sv_completed_page",navigation:{complete:"sv_complete_btn",prev:"sv_prev_btn",next:"sv_next_btn",start:"sv_start_btn",preview:"sv_preview_btn",edit:"sv_edit_btn"},progress:"sv_progress",progressBar:"sv_progress_bar",progressTextInBar:"sv-hidden",progressButtonsContainerCenter:"sv_progress-buttons__container-center",progressButtonsContainer:"sv_progress-buttons__container",progressButtonsImageButtonLeft:"sv_progress-buttons__image-button-left",progressButtonsImageButtonRight:"sv_progress-buttons__image-button-right",progressButtonsImageButtonHidden:"sv_progress-buttons__image-button--hidden",progressButtonsListContainer:"sv_progress-buttons__list-container",progressButtonsList:"sv_progress-buttons__list",progressButtonsListElementPassed:"sv_progress-buttons__list-element--passed",progressButtonsListElementCurrent:"sv_progress-buttons__list-element--current",progressButtonsListElementNonClickable:"sv_progress-buttons__list-element--nonclickable",progressButtonsPageTitle:"sv_progress-buttons__page-title",progressButtonsPageDescription:"sv_progress-buttons__page-description",page:{root:"sv_p_root",title:"sv_page_title",description:""},pageTitle:"sv_page_title",pageDescription:"",row:"sv_row",question:{mainRoot:"sv_q sv_qstn",flowRoot:"sv_q_flow sv_qstn",header:"",headerLeft:"title-left",content:"",contentLeft:"content-left",titleLeftRoot:"sv_qstn_left",requiredText:"sv_q_required_text",title:"sv_q_title",titleExpandable:"sv_q_title_expandable",titleExpandableSvg:"sd-element__title-expandable-svg",titleExpanded:"sv_q_title_expanded",titleCollapsed:"sv_q_title_collapsed",number:"sv_q_num",description:"sv_q_description",comment:"",required:"",titleRequired:"",hasError:"",indent:20,footer:"sv_q_footer",formGroup:"form-group",asCell:"sv_matrix_cell",icon:"sv_question_icon",iconExpanded:"sv_expanded",disabled:"sv_q--disabled"},panel:{title:"sv_p_title",titleExpandable:"sv_p_title_expandable",titleExpandableSvg:"sd-element__title-expandable-svg",titleExpanded:"sv_p_title_expanded",titleCollapsed:"sv_p_title_collapsed",titleOnError:"",icon:"sv_panel_icon",iconExpanded:"sv_expanded",description:"sv_p_description",container:"sv_p_container",footer:"sv_p_footer",number:"sv_q_num",requiredText:"sv_q_required_text"},error:{root:"sv_q_erbox",icon:"",item:"",locationTop:"sv_qstn_error_top",locationBottom:"sv_qstn_error_bottom"},boolean:{root:"sv_qcbc sv_qbln",rootRadio:"sv_qcbc sv_qbln",item:"sv-boolean",control:"sv-visuallyhidden",itemChecked:"sv-boolean--checked checked",itemIndeterminate:"sv-boolean--indeterminate",itemDisabled:"sv-boolean--disabled",switch:"sv-boolean__switch",slider:"sv-boolean__slider",label:"sv-boolean__label ",disabledLabel:"sv-boolean__label--disabled",sliderGhost:"sv-boolean__thumb-ghost",rootCheckbox:"sv_qcbc sv_qbln",checkboxItem:"sv-boolean",checkboxItemChecked:"sv-boolean--checked",controlCheckbox:"sv-visuallyvisible",checkboxControlLabel:"sv-boolean__label",checkboxItemIndeterminate:"sv-boolean--indeterminate",checkboxItemDisabled:"sv-item--disabled sv-boolean--disabled",checkboxMaterialDecorator:"sv-item__decorator sv-boolean__decorator",checkboxItemDecorator:"sv-item__svg sv-boolean__svg"},checkbox:{root:"sv_qcbc sv_qcbx",item:"sv_q_checkbox",itemSelectAll:"sv_q_checkbox_selectall",itemNone:"sv_q_checkbox_none",itemChecked:"checked",itemInline:"sv_q_checkbox_inline",label:"sv_q_checkbox_label",labelChecked:"",itemControl:"sv_q_checkbox_control_item",itemDecorator:"sv-hidden",controlLabel:"sv_q_checkbox_control_label",other:"sv_q_other sv_q_checkbox_other",column:"sv_q_select_column"},ranking:{root:"sv-ranking",rootMobileMod:"sv-ranking--mobile",rootDragMod:"sv-ranking--drag",rootDisabled:"sv-ranking--disabled",rootDragHandleAreaIcon:"sv-ranking--drag-handle-area-icon",rootSelectToRankMod:"sv-ranking--select-to-rank",rootSelectToRankAlignVertical:"sv-ranking--select-to-rank-vertical",rootSelectToRankAlignHorizontal:"sv-ranking--select-to-rank-horizontal",rootSelectToRankSwapAreas:"sv-ranking--select-to-rank-swap-areas",item:"sv-ranking-item",itemContent:"sv-ranking-item__content",itemIndex:"sv-ranking-item__index",itemIndexEmptyMode:"sv-ranking-item__index--empty",controlLabel:"sv-ranking-item__text",itemGhostNode:"sv-ranking-item__ghost",itemIconContainer:"sv-ranking-item__icon-container",itemIcon:"sv-ranking-item__icon",itemIconHoverMod:"sv-ranking-item__icon--hover",itemIconFocusMod:"sv-ranking-item__icon--focus",itemGhostMod:"sv-ranking-item--ghost",itemDragMod:"sv-ranking-item--drag",container:"sv-ranking__container",containerEmptyMode:"sv-ranking__container--empty",containerFromMode:"sv-ranking__container--from",containerToMode:"sv-ranking__container--to",containerPlaceholder:"sv-ranking__container-placeholder",containersDivider:"sv-ranking__containers-divider"},comment:{remainingCharacterCounter:"sv-remaining-character-counter"},dropdown:{root:"",popup:"sv-dropdown-popup",control:"sv_q_dropdown_control",controlInputFieldComponent:"sv_q_dropdown_control__input-field-component",selectWrapper:"sv_select_wrapper",other:"sv_q_dd_other",cleanButton:"sv_q_dropdown_clean-button",cleanButtonSvg:"sv_q_dropdown_clean-button-svg",cleanButtonIconId:"icon-clear_16x16",controlValue:"sv_q_dropdown__value",filterStringInput:"sv_q_dropdown__filter-string-input",hintPrefix:"sv_q_dropdown__hint-prefix",hintSuffix:"sv_q_dropdown__hint-suffix"},html:{root:""},image:{root:"sv_q_image",image:"sv_image_image",noImage:"sv-image__no-image",noImageSvgIconId:"icon-no-image"},matrix:{root:"sv_q_matrix",label:"sv_q_m_label",itemChecked:"checked",itemDecorator:"sv-hidden",cell:"sv_q_m_cell",cellText:"sv_q_m_cell_text",cellTextSelected:"sv_q_m_cell_selected",cellLabel:"sv_q_m_cell_label",cellResponsiveTitle:"sv_q_m_cell_responsive_title"},matrixdropdown:{root:"sv_q_matrix_dropdown",cell:"sv_matrix_cell",cellResponsiveTitle:"sv_matrix_cell_responsive_title",headerCell:"sv_matrix_cell_header",row:"sv_matrix_row",rowAdditional:"sv-matrix__row--additional",rowTextCell:"sv-table__cell--row-text",detailRow:"sv_matrix_detail_row",detailRowText:"sv_matrix_cell_detail_rowtext",detailCell:"sv_matrix_cell_detail",choiceCell:"sv-table__cell--choice",detailButton:"sv_matrix_cell_detail_button",detailButtonExpanded:"sv_matrix_cell_detail_button_expanded",detailIcon:"sv_detail_panel_icon",detailIconExpanded:"sv_detail_expanded",detailPanelCell:"sv_matrix_cell_detail_panel",actionsCell:"sv_matrix_cell sv_matrix_cell_actions"},matrixdynamic:{root:"sv_q_matrix_dynamic",button:"sv_matrix_dynamic_button",buttonAdd:"sv_matrix_dynamic_button--add",buttonRemove:"",iconAdd:"",iconRemove:"",iconDrag:"sv-matrixdynamic__drag-icon",cell:"sv_matrix_cell",cellResponsiveTitle:"sv_matrix_cell_responsive_title",headerCell:"sv_matrix_cell_header",row:"sv_matrix_row",detailRow:"sv_matrix_detail_row",detailCell:"sv_matrix_cell_detail",choiceCell:"sv-table__cell--choice",detailButton:"sv_matrix_cell_detail_button",detailButtonExpanded:"sv_matrix_cell_detail_button_expanded",detailIcon:"sv_detail_panel_icon",detailIconExpanded:"sv_detail_expanded",detailPanelCell:"sv_matrix_cell_detail_panel",actionsCell:"sv_matrix_cell sv_matrix_cell_actions",emptyRowsSection:"sv_matrix_empty_rows_section",emptyRowsText:"sv_matrix_empty_rows_text",emptyRowsButton:"",ghostRow:"sv-matrix-row--drag-drop-ghost-mod",draggedRow:"sv-matrixdynamic-dragged-row"},paneldynamic:{root:"sv_panel_dynamic",title:"sv_p_title",header:"sv-paneldynamic__header sv_header",headerTab:"sv-paneldynamic__header-tab",button:"",buttonAdd:"sv-paneldynamic__add-btn",buttonRemove:"sv_p_remove_btn",buttonRemoveRight:"sv_p_remove_btn_right",buttonPrev:"sv-paneldynamic__prev-btn",buttonPrevDisabled:"sv-paneldynamic__prev-btn--disabled",buttonNextDisabled:"sv-paneldynamic__next-btn--disabled",buttonNext:"sv-paneldynamic__next-btn",progressContainer:"sv-paneldynamic__progress-container",progress:"sv-progress",progressBar:"sv-progress__bar",progressText:"sv-paneldynamic__progress-text",panelWrapper:"sv_p_wrapper",panelWrapperInRow:"sv_p_wrapper_in_row",footer:"",progressBtnIcon:"icon-progressbutton"},multipletext:{root:"sv_q_mt",itemTitle:"sv_q_mt_title",item:"sv_q_mt_item",row:"sv_q_mt_row",itemLabel:"sv_q_mt_label",itemValue:"sv_q_mt_item_value sv_q_text_root"},radiogroup:{root:"sv_qcbc",item:"sv_q_radiogroup",itemChecked:"checked",itemInline:"sv_q_radiogroup_inline",itemDecorator:"sv-hidden",label:"sv_q_radiogroup_label",labelChecked:"",itemControl:"sv_q_radiogroup_control_item",controlLabel:"",other:"sv_q_other sv_q_radiogroup_other",clearButton:"sv_q_radiogroup_clear",column:"sv_q_select_column"},buttongroup:{root:"sv-button-group",item:"sv-button-group__item",itemIcon:"sv-button-group__item-icon",itemDecorator:"sv-button-group__item-decorator",itemCaption:"sv-button-group__item-caption",itemHover:"sv-button-group__item--hover",itemSelected:"sv-button-group__item--selected",itemDisabled:"sv-button-group__item--disabled",itemControl:"sv-visuallyhidden"},imagepicker:{root:"sv_imgsel",item:"sv_q_imgsel",itemChecked:"checked",label:"sv_q_imgsel_label",itemControl:"sv_q_imgsel_control_item",image:"sv_q_imgsel_image",itemInline:"sv_q_imagepicker_inline",itemText:"sv_q_imgsel_text",clearButton:"sv_q_radiogroup_clear",column:"sv_q_select_column",itemNoImage:"sv_q_imgsel__no-image",itemNoImageSvgIcon:"sv_q_imgsel__no-image-svg",itemNoImageSvgIconId:"icon-no-image"},rating:{root:"sv_q_rating",item:"sv_q_rating_item",itemFixedSize:"sv_q_rating_item_fixed",selected:"active",minText:"sv_q_rating_min_text",itemText:"sv_q_rating_item_text",maxText:"sv_q_rating_max_text",itemStar:"sv_q_rating__item-star",itemStarSelected:"sv_q_rating__item-star--selected",itemSmiley:"sv_q_rating__item-smiley",itemSmileySelected:"sv_q_rating__item-smiley--selected"},text:{root:"sv_q_text_root",remainingCharacterCounter:"sv-remaining-character-counter"},expression:"",file:{root:"sv_q_file",placeholderInput:"sv-visuallyhidden",previewItem:"sv_q_file_preview",removeButton:"sv_q_file_remove_button",fileInput:"sv-visuallyhidden",removeFile:"sv_q_file_remove",fileDecorator:"sv-file__decorator",fileSign:"sv_q_file_sign",chooseFile:"sv_q_file_choose_button",noFileChosen:"sv_q_file_placeholder",dragAreaPlaceholder:"sv-hidden",fileList:""},signaturepad:{root:"sv_q_signaturepad sjs_sp_container",controls:"sjs_sp_controls",placeholder:"sjs_sp_placeholder",canvas:"sjs_sp_canvas",backgroundImage:"sjs_sp__background-image",clearButton:"sjs_sp_clear"},saveData:{root:"sv-save-data_root",rootWithButtons:"sv-save-data_root--with-buttons",info:"sv-save-data_info",error:"sv-save-data_error",success:"sv-save-data_success",button:"sv-save-data_button",shown:"sv-save-data_root--shown"},window:{root:"sv_window",rootCollapsedMod:"sv_window--collapsed",rootFullScreenMode:"sv_window--full-screen",rootContent:"sv_window_root-content",body:"sv_window_content",header:{root:"sv_window_header",titleCollapsed:"sv_window_header_title_collapsed",buttonsContainer:"sv_window_buttons_container",button:"sv_window_button",buttonExpanded:"",buttonCollapsed:"",collapseButton:"sv_window_button sv_window_button_collapse",closeButton:"sv_window_button sv_window_button_close",fullScreenButton:"sv_window_button sv_window_button_full_screen"}},variables:{mobileWidth:"--sv-mobile-width",themeMark:"--sv-default-mark"},tagbox:{root:"",popup:"sv-dropdown-popup",small:"sv_q_row__question--small",selectWrapper:"sv_select_wrapper sv_q_tagbox_wrapper",other:"sv_q_input sv_q_comment sv_q_selectbase__other",cleanButton:"sv_q_tagbox_clean-button sv_q_dropdown_clean-button",cleanButtonSvg:"sv_q_tagbox_clean-button-svg sv_q_dropdown_clean-button-svg",cleanButtonIconId:"icon-clear_16x16",cleanItemButton:"sv_q_tagbox-item_clean-button",cleanItemButtonSvg:"sv_q_tagbox-item_clean-button-svg",cleanItemButtonIconId:"icon-clear_16x16",control:"sv_q_input sv_q_tagbox sv_q_dropdown_control",controlValue:"sv_q_tagbox__value sv_q_dropdown__value",controlEmpty:"sv_q_dropdown--empty sv_q_tagbox--empty",placeholderInput:"sv_q_tagbox__placeholder",filterStringInput:"sv_q_tagbox__filter-string-input sv_q_dropdown__filter-string-input",hint:"sv_q_tagbox__hint",hintPrefix:"sv_q_dropdown__hint-prefix sv_q_tagbox__hint-prefix",hintSuffix:"sv_q_dropdown__hint-suffix sv_q_tagbox__hint-suffix",hintSuffixWrapper:"sv_q_tagbox__hint-suffix-wrapper"}};Xo.default=cl,Xo.orange=cl,Xo.darkblue=cl,Xo.darkrose=cl,Xo.stone=cl,Xo.winter=cl,Xo.winterstone=cl;var pl={root:"sv-root-modern",rootProgress:"sv-progress",timerRoot:"sv-body__timer",container:"sv-container-modern",header:"sv-title sv-container-modern__title",headerClose:"sv-container-modern__close",bodyContainer:"sv-components-row",body:"sv-body",bodyEmpty:"sv-body sv-body--empty",footer:"sv-footer sv-body__footer sv-clearfix",title:"",description:"",logo:"sv-logo",logoImage:"sv-logo__image",headerText:"sv-header__text",navigationButton:"sv-btn sv-btn--navigation",completedPage:"sv-completedpage",navigation:{complete:"sv-footer__complete-btn",prev:"sv-footer__prev-btn",next:"sv-footer__next-btn",start:"sv-footer__start-btn",preview:"sv-footer__preview-btn",edit:"sv-footer__edit-btn"},panel:{title:"sv-title sv-panel__title",titleExpandable:"sv-panel__title--expandable",titleExpandableSvg:"sd-element__title-expandable-svg",titleExpanded:"sv-panel__title--expanded",titleCollapsed:"sv-panel__title--collapsed",titleOnError:"sv-panel__title--error",description:"sv-description sv-panel__description",container:"sv-panel sv-row__panel",content:"sv-panel__content",icon:"sv-panel__icon",iconExpanded:"sv-panel__icon--expanded",footer:"sv-panel__footer",requiredText:"sv-panel__required-text",number:"sv-question__num"},paneldynamic:{root:"sv-paneldynamic",navigation:"sv-paneldynamic__navigation",title:"sv-title sv-question__title",button:"sv-btn",buttonRemove:"sv-paneldynamic__remove-btn",buttonRemoveRight:"sv-paneldynamic__remove-btn--right",buttonAdd:"sv-paneldynamic__add-btn",progressTop:"sv-paneldynamic__progress sv-paneldynamic__progress--top",progressBottom:"sv-paneldynamic__progress sv-paneldynamic__progress--bottom",buttonPrev:"sv-paneldynamic__prev-btn",buttonNext:"sv-paneldynamic__next-btn",buttonPrevDisabled:"sv-paneldynamic__prev-btn--disabled",buttonNextDisabled:"sv-paneldynamic__next-btn--disabled",progressContainer:"sv-paneldynamic__progress-container",progress:"sv-progress",progressBar:"sv-progress__bar",progressText:"sv-paneldynamic__progress-text",separator:"sv-paneldynamic__separator",panelWrapper:"sv-paneldynamic__panel-wrapper",panelWrapperInRow:"sv-paneldynamic__panel-wrapper--in-row",progressBtnIcon:"icon-progressbutton",footer:""},progress:"sv-progress sv-body__progress",progressBar:"sv-progress__bar",progressText:"sv-progress__text",progressTextInBar:"sv-hidden",progressButtonsContainerCenter:"sv_progress-buttons__container-center",progressButtonsContainer:"sv_progress-buttons__container",progressButtonsImageButtonLeft:"sv_progress-buttons__image-button-left",progressButtonsImageButtonRight:"sv_progress-buttons__image-button-right",progressButtonsImageButtonHidden:"sv_progress-buttons__image-button--hidden",progressButtonsListContainer:"sv_progress-buttons__list-container",progressButtonsList:"sv_progress-buttons__list",progressButtonsListElementPassed:"sv_progress-buttons__list-element--passed",progressButtonsListElementCurrent:"sv_progress-buttons__list-element--current",progressButtonsListElementNonClickable:"sv_progress-buttons__list-element--nonclickable",progressButtonsPageTitle:"sv_progress-buttons__page-title",progressButtonsPageDescription:"sv_progress-buttons__page-description",page:{root:"sv-page sv-body__page",title:"sv-title sv-page__title",number:"sv-page__num",description:"sv-description sv-page__description"},pageTitle:"sv-title sv-page__title",pageDescription:"sv-description sv-page__description",row:"sv-row sv-clearfix",question:{mainRoot:"sv-question sv-row__question",flowRoot:"sv-question sv-row__question sv-row__question--flow",asCell:"sv-table__cell",header:"sv-question__header",headerLeft:"sv-question__header--location--left",headerTop:"sv-question__header--location--top",headerBottom:"sv-question__header--location--bottom",content:"sv-question__content",contentLeft:"sv-question__content--left",titleLeftRoot:"",answered:"sv-question--answered",titleOnAnswer:"sv-question__title--answer",titleOnError:"sv-question__title--error",title:"sv-title sv-question__title",titleExpandable:"sv-question__title--expandable",titleExpandableSvg:"sd-element__title-expandable-svg",titleExpanded:"sv-question__title--expanded",titleCollapsed:"sv-question__title--collapsed",icon:"sv-question__icon",iconExpanded:"sv-question__icon--expanded",requiredText:"sv-question__required-text",number:"sv-question__num",description:"sv-description sv-question__description",descriptionUnderInput:"sv-description sv-question__description",comment:"sv-comment",required:"sv-question--required",titleRequired:"sv-question__title--required",indent:20,footer:"sv-question__footer",formGroup:"sv-question__form-group",hasError:"",disabled:"sv-question--disabled"},image:{root:"sv-image",image:"sv_image_image"},error:{root:"sv-question__erbox",icon:"",item:"",locationTop:"sv-question__erbox--location--top",locationBottom:"sv-question__erbox--location--bottom"},checkbox:{root:"sv-selectbase",item:"sv-item sv-checkbox sv-selectbase__item",itemSelectAll:"sv-checkbox--selectall",itemNone:"sv-checkbox--none",itemDisabled:"sv-item--disabled sv-checkbox--disabled",itemChecked:"sv-checkbox--checked",itemHover:"sv-checkbox--allowhover",itemInline:"sv-selectbase__item--inline",label:"sv-selectbase__label",labelChecked:"",itemControl:"sv-visuallyhidden sv-item__control",itemDecorator:"sv-item__svg sv-checkbox__svg",itemSvgIconId:"#icon-moderncheck",controlLabel:"sv-item__control-label",materialDecorator:"sv-item__decorator sv-selectbase__decorator sv-checkbox__decorator",other:"sv-comment sv-question__other",column:"sv-selectbase__column"},ranking:{root:"sv-ranking",rootMobileMod:"sv-ranking--mobile",rootDragMod:"sv-ranking--drag",rootDisabled:"sv-ranking--disabled",rootDragHandleAreaIcon:"sv-ranking--drag-handle-area-icon",rootSelectToRankMod:"sv-ranking--select-to-rank",rootSelectToRankAlignVertical:"sv-ranking--select-to-rank-vertical",rootSelectToRankAlignHorizontal:"sv-ranking--select-to-rank-horizontal",rootSelectToRankSwapAreas:"sv-ranking--select-to-rank-swap-areas",item:"sv-ranking-item",itemContent:"sv-ranking-item__content",itemIndex:"sv-ranking-item__index",itemIndexEmptyMode:"sv-ranking-item__index--empty",controlLabel:"sv-ranking-item__text",itemGhostNode:"sv-ranking-item__ghost",itemIconContainer:"sv-ranking-item__icon-container",itemIcon:"sv-ranking-item__icon",itemIconHoverMod:"sv-ranking-item__icon--hover",itemIconFocusMod:"sv-ranking-item__icon--focus",itemGhostMod:"sv-ranking-item--ghost",itemDragMod:"sv-ranking-item--drag",container:"sv-ranking__container",containerEmptyMode:"sv-ranking__container--empty",containerFromMode:"sv-ranking__container--from",containerToMode:"sv-ranking__container--to",containerPlaceholder:"sv-ranking__container-placeholder",containersDivider:"sv-ranking__containers-divider"},radiogroup:{root:"sv-selectbase",item:"sv-item sv-radio sv-selectbase__item",itemInline:"sv-selectbase__item--inline",label:"sv-selectbase__label",labelChecked:"",itemDisabled:"sv-item--disabled sv-radio--disabled",itemChecked:"sv-radio--checked",itemHover:"sv-radio--allowhover",itemControl:"sv-visuallyhidden sv-item__control",itemDecorator:"sv-item__svg sv-radio__svg",itemSvgIconId:"#icon-modernradio",controlLabel:"sv-item__control-label",materialDecorator:"sv-item__decorator sv-selectbase__decorator sv-radio__decorator",other:"sv-comment sv-question__other",clearButton:"sv-btn sv-selectbase__clear-btn",column:"sv-selectbase__column"},buttongroup:{root:"sv-button-group",item:"sv-button-group__item",itemIcon:"sv-button-group__item-icon",itemDecorator:"sv-button-group__item-decorator",itemCaption:"sv-button-group__item-caption",itemSelected:"sv-button-group__item--selected",itemHover:"sv-button-group__item--hover",itemDisabled:"sv-button-group__item--disabled",itemControl:"sv-visuallyhidden"},boolean:{root:"sv_qbln",rootRadio:"sv_qbln",small:"sv-row__question--small",item:"sv-boolean sv-item",control:"sv-visuallyhidden",itemChecked:"sv-boolean--checked",itemIndeterminate:"sv-boolean--indeterminate",itemDisabled:"sv-item--disabled sv-boolean--disabled",switch:"sv-boolean__switch",slider:"sv-boolean__slider",label:"sv-boolean__label",disabledLabel:"sv-boolean__label--disabled",sliderGhost:"sv-boolean__thumb-ghost",rootCheckbox:"sv_qbln",checkboxItem:"sv-boolean sv-item",checkboxItemChecked:"sv-boolean--checked",controlCheckbox:"sv-visuallyhidden",checkboxControlLabel:"sv-boolean__label",checkboxItemIndeterminate:"sv-boolean--indeterminate",checkboxItemDisabled:"sv-item--disabled sv-boolean--disabled",checkboxMaterialDecorator:"sv-item__decorator sv-boolean__decorator ",checkboxItemDecorator:"sv-item__svg sv-boolean__svg",indeterminatePath:"sv-boolean__indeterminate-path",svgIconCheckedId:"#icon-modernbooleancheckchecked",svgIconUncheckedId:"#icon-modernbooleancheckunchecked",svgIconIndId:"#icon-modernbooleancheckind"},text:{root:"sv-text",small:"sv-row__question--small",remainingCharacterCounter:"sv-remaining-character-counter",onError:"sv-text--error"},multipletext:{root:"sv-multipletext",item:"sv-multipletext__item",itemLabel:"sv-multipletext__item-label",itemTitle:"sv-multipletext__item-title",row:"sv-multipletext__row",cell:"sv-multipletext__cell"},dropdown:{root:"",popup:"sv-dropdown-popup",small:"sv-row__question--small",control:"sv-dropdown",selectWrapper:"",other:"sv-comment sv-question__other",onError:"sv-dropdown--error",cleanButton:"sv-dropdown_clean-button",cleanButtonSvg:"sv-dropdown_clean-button-svg",cleanButtonIconId:"icon-clear_16x16",filterStringInput:"sv-dropdown__filter-string-input",controlValue:"sv-dropdown__value",controlInputFieldComponent:"sv_dropdown_control__input-field-component",hintPrefix:"sv-dropdown__hint-prefix",hintSuffix:"sv-dropdown__hint-suffix"},tagbox:{root:"",popup:"sv-dropdown-popup",small:"sv-row__question--small",selectWrapper:"sv_select_wrapper sv-tagbox_wrapper",other:"sv-input sv-comment sv-selectbase__other",cleanButton:"sv-tagbox_clean-button sv-dropdown_clean-button",cleanButtonSvg:"sv-tagbox_clean-button-svg sv-dropdown_clean-button-svg",cleanButtonIconId:"icon-clear_16x16",cleanItemButton:"sv-tagbox__item_clean-button",cleanItemButtonSvg:"sv-tagbox__item_clean-button-svg",cleanItemButtonIconId:"icon-clear_16x16",control:"sv-input sv-tagbox sv-dropdown",controlValue:"sv-tagbox__value sv-dropdown__value",controlEmpty:"sv-dropdown--empty sv-tagbox--empty",placeholderInput:"sv-tagbox__placeholder",filterStringInput:"sv-tagbox__filter-string-input sv-dropdown__filter-string-input"},imagepicker:{root:"sv-selectbase sv-imagepicker",column:"sv-selectbase__column",item:"sv-imagepicker__item",itemInline:"sv-imagepicker__item--inline",itemChecked:"sv-imagepicker__item--checked",itemDisabled:"sv-imagepicker__item--disabled",itemHover:"sv-imagepicker__item--allowhover",label:"sv-imagepicker__label",itemControl:"sv-imagepicker__control sv-visuallyhidden",image:"sv-imagepicker__image",itemText:"sv-imagepicker__text",clearButton:"sv-btn",other:"sv-comment sv-question__other"},matrix:{tableWrapper:"sv-matrix",root:"sv-table sv-matrix-root",rowError:"sv-matrix__row--error",cell:"sv-table__cell sv-matrix__cell",headerCell:"sv-table__cell sv-table__cell--header",label:"sv-item sv-radio sv-matrix__label",itemValue:"sv-visuallyhidden sv-item__control sv-radio__control",itemChecked:"sv-radio--checked",itemDisabled:"sv-item--disabled sv-radio--disabled",itemHover:"sv-radio--allowhover",materialDecorator:"sv-item__decorator sv-radio__decorator",itemDecorator:"sv-item__svg sv-radio__svg",cellText:"sv-matrix__text",cellTextSelected:"sv-matrix__text--checked",cellTextDisabled:"sv-matrix__text--disabled",cellResponsiveTitle:"sv-matrix__cell-responsive-title",itemSvgIconId:"#icon-modernradio"},matrixdropdown:{root:"sv-table sv-matrixdropdown",cell:"sv-table__cell",cellResponsiveTitle:"sv-table__responsive-title",headerCell:"sv-table__cell sv-table__cell--header",row:"sv-table__row",rowTextCell:"sv-table__cell--row-text",rowAdditional:"sv-table__row--additional",detailRow:"sv-table__row--detail",detailRowText:"sv-table__cell--detail-rowtext",detailCell:"sv-table__cell--detail",choiceCell:"sv-table__cell--choice",detailButton:"sv-table__cell--detail-button",detailButtonExpanded:"sv-table__cell--detail-button--expanded",detailIcon:"sv-detail-panel__icon",detailIconExpanded:"sv-detail-panel__icon--expanded",detailPanelCell:"sv-table__cell--detail-panel",actionsCell:"sv-table__cell sv-table__cell--actions"},matrixdynamic:{root:"sv-table sv-matrixdynamic",cell:"sv-table__cell",cellResponsiveTitle:"sv-table__responsive-title",headerCell:"sv-table__cell sv-table__cell--header",button:"sv-btn",buttonAdd:"sv-matrixdynamic__add-btn",buttonRemove:"sv-matrixdynamic__remove-btn",iconAdd:"",iconRemove:"",iconDrag:"sv-matrixdynamic__drag-icon",row:"sv-table__row",detailRow:"sv-table__row--detail",detailCell:"sv-table__cell--detail",choiceCell:"sv-table__cell--choice",detailButton:"sv-table__cell--detail-button",detailButtonExpanded:"sv-table__cell--detail-button--expanded",detailIcon:"sv-detail-panel__icon",detailIconExpanded:"sv-detail-panel__icon--expanded",detailPanelCell:"sv-table__cell--detail-panel",actionsCell:"sv-table__cell sv-table__cell--actions",emptyRowsSection:"sv-table__empty--rows--section",emptyRowsText:"sv-table__empty--rows--text",emptyRowsButton:"",ghostRow:"sv-matrix-row--drag-drop-ghost-mod",draggedRow:"sv-matrixdynamic-dragged-row"},rating:{root:"sv-rating",item:"sv-rating__item",selected:"sv-rating__item--selected",minText:"sv-rating__min-text",itemText:"sv-rating__item-text",maxText:"sv-rating__max-text",itemDisabled:"sv-rating--disabled",filterStringInput:"sv-dropdown__filter-string-input",control:"sv-dropdown",cleanButton:"sv-dropdown_clean-button",cleanButtonSvg:"sv-dropdown_clean-button-svg",cleanButtonIconId:"icon-clear_16x16",controlValue:"sv-dropdown__value",controlInputFieldComponent:"sv_dropdown_control__input-field-component",itemSmiley:"sv-rating__item-smiley",itemStar:"sv-rating__item-star",itemSmileySelected:"sv-rating__item-smiley--selected",itemStarSelected:"sv-rating__item-star--selected"},comment:{root:"sv-comment",small:"sv-row__question--small",remainingCharacterCounter:"sv-remaining-character-counter"},expression:"",file:{root:"sv-file",other:"sv-comment sv-question__other",placeholderInput:"sv-visuallyhidden",previewItem:"sd-file__preview-item",fileSignBottom:"sv-file__sign",fileDecorator:"sv-file__decorator",fileInput:"sv-visuallyhidden",noFileChosen:"sv-description sv-file__no-file-chosen",chooseFile:"sv-btn sv-file__choose-btn",controlDisabled:"sv-file__choose-btn--disabled",removeButton:"sv-hidden",removeButtonBottom:"sv-btn sv-file__clean-btn",removeFile:"sv-hidden",removeFileSvg:"sv-file__remove-svg",removeFileSvgIconId:"icon-removefile",wrapper:"sv-file__wrapper",dragAreaPlaceholder:"sv-hidden",fileList:""},signaturepad:{root:"sv-signaturepad sjs_sp_container",small:"sv-row__question--small",controls:"sjs_sp_controls",placeholder:"sjs_sp_placeholder",canvas:"sjs_sp_canvas",backgroundImage:"sjs_sp__background-image",clearButton:"sjs_sp_clear"},saveData:{root:"sv-save-data_root",rootWithButtons:"sv-save-data_root--with-buttons",info:"sv-save-data_info",error:"sv-save-data_error",success:"sv-save-data_success",button:"sv-save-data_button",shown:"sv-save-data_root--shown"},window:{root:"sv_window",rootCollapsedMod:"sv_window--collapsed",rootFullScreenMode:"sv_window--full-screen",rootContent:"sv_window_root-content",body:"sv_window_content",header:{root:"sv_window_header",titleCollapsed:"sv_window_header_title_collapsed",buttonsContainer:"sv_window_buttons_container",button:"sv_window_button",buttonExpanded:"",buttonCollapsed:"",collapseButton:"sv_window_button sv_window_button_collapse",closeButton:"sv_window_button sv_window_button_close",fullScreenButton:"sv_window_button sv_window_button_full_screen"}},variables:{mobileWidth:"--sv-mobile-width",themeMark:"--sv-modern-mark"}};Xo.modern=pl;var hl=function(){function e(){this.icons={},this.iconPrefix="icon-",this.onIconsChanged=new Se}return e.prototype.processId=function(e,t){return 0==e.indexOf(t)&&(e=e.substring(t.length)),e=It[e]||e},e.prototype.registerIconFromSymbol=function(e,t){this.icons[e]=t},e.prototype.registerIconFromSvgViaElement=function(e,t,n){if(void 0===n&&(n=this.iconPrefix),i.isAvailable()){e=this.processId(e,n);var o=i.createElement("div");o.innerHTML=t;var r=i.createElement("symbol"),s=o.querySelector("svg");r.innerHTML=s.innerHTML;for(var a=0;a<s.attributes.length;a++)r.setAttributeNS("http://www.w3.org/2000/svg",s.attributes[a].name,s.attributes[a].value);r.id=n+e,this.registerIconFromSymbol(e,r.outerHTML)}},e.prototype.registerIconFromSvg=function(e,t,n){void 0===n&&(n=this.iconPrefix),e=this.processId(e,n);var o=(t=t.trim()).toLowerCase();return"<svg "===o.substring(0,"<svg ".length)&&"</svg>"===o.substring(o.length-"</svg>".length,o.length)&&(this.registerIconFromSymbol(e,'<symbol id="'+n+e+'" '+t.substring("<svg ".length,o.length-"</svg>".length)+"</symbol>"),!0)},e.prototype.registerIconsFromFolder=function(e){var t=this;e.keys().forEach((function(n){t.registerIconFromSvg(n.substring(2,n.length-4).toLowerCase(),e(n))}))},e.prototype.registerIcons=function(e){for(var t in e)this.registerIconFromSvg(t,e[t]);this.updateMarkup()},e.prototype.iconsRenderedHtml=function(){var e=this;return Object.keys(this.icons).map((function(t){return e.icons[t]})).join("")},e.prototype.updateMarkup=function(){this.onIconsChanged.fire(this,{})},e}(),dl=new hl,fl={};function gl(e,t){fl[e]||(fl[e]={});var n=fl[e];for(var o in t)n[o]=t[o]}}})}));