@builder.io/sdk-qwik 0.16.11 → 0.16.13

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 (479) hide show
  1. package/lib/browser/blocks/accordion/accordion.qwik.cjs +74 -143
  2. package/lib/browser/blocks/accordion/accordion.qwik.mjs +74 -143
  3. package/lib/browser/blocks/accordion/component-info.qwik.cjs +2 -1
  4. package/lib/browser/blocks/accordion/component-info.qwik.mjs +2 -1
  5. package/lib/browser/blocks/button/button.qwik.cjs +8 -17
  6. package/lib/browser/blocks/button/button.qwik.mjs +8 -17
  7. package/lib/browser/blocks/columns/columns.qwik.cjs +33 -67
  8. package/lib/browser/blocks/columns/columns.qwik.mjs +33 -67
  9. package/lib/browser/blocks/columns/component-info.qwik.cjs +4 -3
  10. package/lib/browser/blocks/columns/component-info.qwik.mjs +4 -3
  11. package/lib/browser/blocks/custom-code/custom-code.qwik.cjs +18 -22
  12. package/lib/browser/blocks/custom-code/custom-code.qwik.mjs +19 -23
  13. package/lib/browser/blocks/embed/embed.qwik.cjs +17 -23
  14. package/lib/browser/blocks/embed/embed.qwik.mjs +17 -23
  15. package/lib/browser/blocks/form/form/form.qwik.cjs +74 -128
  16. package/lib/browser/blocks/form/form/form.qwik.mjs +75 -129
  17. package/lib/browser/blocks/form/input/input.qwik.cjs +2 -2
  18. package/lib/browser/blocks/form/input/input.qwik.mjs +3 -3
  19. package/lib/browser/blocks/form/select/select.qwik.cjs +7 -5
  20. package/lib/browser/blocks/form/select/select.qwik.mjs +8 -6
  21. package/lib/browser/blocks/form/submit-button/submit-button.qwik.cjs +7 -9
  22. package/lib/browser/blocks/form/submit-button/submit-button.qwik.mjs +8 -10
  23. package/lib/browser/blocks/form/textarea/textarea.qwik.cjs +11 -21
  24. package/lib/browser/blocks/form/textarea/textarea.qwik.mjs +12 -22
  25. package/lib/browser/blocks/fragment/fragment.qwik.cjs +6 -3
  26. package/lib/browser/blocks/fragment/fragment.qwik.mjs +7 -4
  27. package/lib/browser/blocks/image/component-info.qwik.cjs +6 -3
  28. package/lib/browser/blocks/image/component-info.qwik.mjs +6 -3
  29. package/lib/browser/blocks/image/image.helpers.qwik.cjs +12 -6
  30. package/lib/browser/blocks/image/image.helpers.qwik.mjs +12 -6
  31. package/lib/browser/blocks/image/image.qwik.cjs +63 -89
  32. package/lib/browser/blocks/image/image.qwik.mjs +63 -89
  33. package/lib/browser/blocks/img/img.qwik.cjs +12 -18
  34. package/lib/browser/blocks/img/img.qwik.mjs +12 -18
  35. package/lib/browser/blocks/section/section.qwik.cjs +7 -6
  36. package/lib/browser/blocks/section/section.qwik.mjs +8 -7
  37. package/lib/browser/blocks/slot/slot.qwik.cjs +17 -43
  38. package/lib/browser/blocks/slot/slot.qwik.mjs +17 -43
  39. package/lib/browser/blocks/symbol/symbol.helpers.qwik.cjs +2 -1
  40. package/lib/browser/blocks/symbol/symbol.helpers.qwik.mjs +2 -1
  41. package/lib/browser/blocks/symbol/symbol.qwik.cjs +45 -137
  42. package/lib/browser/blocks/symbol/symbol.qwik.mjs +45 -137
  43. package/lib/browser/blocks/tabs/tabs.qwik.cjs +45 -99
  44. package/lib/browser/blocks/tabs/tabs.qwik.mjs +45 -99
  45. package/lib/browser/blocks/text/text.qwik.cjs +11 -15
  46. package/lib/browser/blocks/text/text.qwik.mjs +11 -15
  47. package/lib/browser/blocks/video/video.qwik.cjs +73 -87
  48. package/lib/browser/blocks/video/video.qwik.mjs +74 -88
  49. package/lib/browser/components/block/animator.qwik.cjs +22 -11
  50. package/lib/browser/components/block/animator.qwik.mjs +22 -11
  51. package/lib/browser/components/block/block.helpers.qwik.cjs +8 -4
  52. package/lib/browser/components/block/block.helpers.qwik.mjs +8 -4
  53. package/lib/browser/components/block/block.qwik.cjs +114 -320
  54. package/lib/browser/components/block/block.qwik.mjs +115 -321
  55. package/lib/browser/components/block/components/block-styles.qwik.cjs +22 -39
  56. package/lib/browser/components/block/components/block-styles.qwik.mjs +23 -40
  57. package/lib/browser/components/block/components/block-wrapper.qwik.cjs +12 -18
  58. package/lib/browser/components/block/components/block-wrapper.qwik.mjs +12 -18
  59. package/lib/browser/components/block/components/component-ref/component-ref.qwik.cjs +12 -29
  60. package/lib/browser/components/block/components/component-ref/component-ref.qwik.mjs +14 -31
  61. package/lib/browser/components/block/components/interactive-element.qwik.cjs +18 -27
  62. package/lib/browser/components/block/components/interactive-element.qwik.mjs +18 -27
  63. package/lib/browser/components/block/components/repeated-block.qwik.cjs +10 -31
  64. package/lib/browser/components/block/components/repeated-block.qwik.mjs +11 -32
  65. package/lib/browser/components/blocks/blocks-wrapper.qwik.cjs +24 -72
  66. package/lib/browser/components/blocks/blocks-wrapper.qwik.mjs +24 -72
  67. package/lib/browser/components/blocks/blocks.qwik.cjs +19 -78
  68. package/lib/browser/components/blocks/blocks.qwik.mjs +20 -79
  69. package/lib/browser/components/content/components/enable-editor.qwik.cjs +101 -193
  70. package/lib/browser/components/content/components/enable-editor.qwik.mjs +102 -194
  71. package/lib/browser/components/content/components/styles.helpers.qwik.cjs +12 -6
  72. package/lib/browser/components/content/components/styles.helpers.qwik.mjs +12 -6
  73. package/lib/browser/components/content/components/styles.qwik.cjs +8 -20
  74. package/lib/browser/components/content/components/styles.qwik.mjs +8 -20
  75. package/lib/browser/components/content/content.helpers.qwik.cjs +2 -1
  76. package/lib/browser/components/content/content.helpers.qwik.mjs +2 -1
  77. package/lib/browser/components/content/content.qwik.cjs +39 -189
  78. package/lib/browser/components/content/content.qwik.mjs +39 -189
  79. package/lib/browser/components/content-variants/content-variants.qwik.cjs +74 -313
  80. package/lib/browser/components/content-variants/content-variants.qwik.mjs +75 -314
  81. package/lib/browser/components/dynamic-renderer/dynamic-renderer.qwik.cjs +11 -12
  82. package/lib/browser/components/dynamic-renderer/dynamic-renderer.qwik.mjs +12 -13
  83. package/lib/browser/components/inlined-script.qwik.cjs +8 -13
  84. package/lib/browser/components/inlined-script.qwik.mjs +9 -14
  85. package/lib/browser/components/inlined-styles.qwik.cjs +8 -13
  86. package/lib/browser/components/inlined-styles.qwik.mjs +9 -14
  87. package/lib/browser/constants/device-sizes.qwik.cjs +2 -1
  88. package/lib/browser/constants/device-sizes.qwik.mjs +2 -1
  89. package/lib/browser/constants/sdk-version.qwik.cjs +1 -1
  90. package/lib/browser/constants/sdk-version.qwik.mjs +1 -1
  91. package/lib/browser/functions/evaluate/browser-runtime/browser.qwik.cjs +6 -3
  92. package/lib/browser/functions/evaluate/browser-runtime/browser.qwik.mjs +6 -3
  93. package/lib/browser/functions/evaluate/choose-eval.qwik.cjs +3 -1
  94. package/lib/browser/functions/evaluate/choose-eval.qwik.mjs +3 -1
  95. package/lib/browser/functions/evaluate/evaluate.qwik.cjs +6 -3
  96. package/lib/browser/functions/evaluate/evaluate.qwik.mjs +6 -3
  97. package/lib/browser/functions/evaluate/should-force-browser-runtime-in-node.qwik.cjs +4 -2
  98. package/lib/browser/functions/evaluate/should-force-browser-runtime-in-node.qwik.mjs +4 -2
  99. package/lib/browser/functions/get-block-actions-handler.qwik.cjs +9 -15
  100. package/lib/browser/functions/get-block-actions-handler.qwik.mjs +10 -16
  101. package/lib/browser/functions/get-block-actions.qwik.cjs +4 -2
  102. package/lib/browser/functions/get-block-actions.qwik.mjs +4 -2
  103. package/lib/browser/functions/get-builder-search-params/index.qwik.cjs +4 -2
  104. package/lib/browser/functions/get-builder-search-params/index.qwik.mjs +4 -2
  105. package/lib/browser/functions/get-content/generate-content-url.qwik.cjs +22 -11
  106. package/lib/browser/functions/get-content/generate-content-url.qwik.mjs +22 -11
  107. package/lib/browser/functions/get-content/index.qwik.cjs +4 -2
  108. package/lib/browser/functions/get-content/index.qwik.mjs +4 -2
  109. package/lib/browser/functions/get-global-this.qwik.cjs +8 -4
  110. package/lib/browser/functions/get-global-this.qwik.mjs +8 -4
  111. package/lib/browser/functions/get-processed-block.qwik.cjs +15 -8
  112. package/lib/browser/functions/get-processed-block.qwik.mjs +15 -8
  113. package/lib/browser/functions/is-from-trusted-host.qwik.cjs +2 -1
  114. package/lib/browser/functions/is-from-trusted-host.qwik.mjs +2 -1
  115. package/lib/browser/functions/is-previewing.qwik.cjs +2 -1
  116. package/lib/browser/functions/is-previewing.qwik.mjs +2 -1
  117. package/lib/browser/functions/register-component.qwik.cjs +2 -1
  118. package/lib/browser/functions/register-component.qwik.mjs +2 -1
  119. package/lib/browser/functions/register.qwik.cjs +6 -3
  120. package/lib/browser/functions/register.qwik.mjs +6 -3
  121. package/lib/browser/functions/set.qwik.cjs +2 -1
  122. package/lib/browser/functions/set.qwik.mjs +2 -1
  123. package/lib/browser/functions/track/helpers.qwik.cjs +2 -1
  124. package/lib/browser/functions/track/helpers.qwik.mjs +2 -1
  125. package/lib/browser/functions/track/index.qwik.cjs +8 -4
  126. package/lib/browser/functions/track/index.qwik.mjs +8 -4
  127. package/lib/browser/functions/track/interaction.qwik.cjs +6 -3
  128. package/lib/browser/functions/track/interaction.qwik.mjs +6 -3
  129. package/lib/browser/helpers/ab-tests.qwik.cjs +15 -8
  130. package/lib/browser/helpers/ab-tests.qwik.mjs +16 -9
  131. package/lib/browser/helpers/cookie.qwik.cjs +4 -2
  132. package/lib/browser/helpers/cookie.qwik.mjs +4 -2
  133. package/lib/browser/helpers/css.qwik.cjs +6 -4
  134. package/lib/browser/helpers/css.qwik.mjs +6 -4
  135. package/lib/browser/helpers/flatten.qwik.cjs +3 -2
  136. package/lib/browser/helpers/flatten.qwik.mjs +3 -2
  137. package/lib/browser/helpers/localStorage.qwik.cjs +4 -2
  138. package/lib/browser/helpers/localStorage.qwik.mjs +4 -2
  139. package/lib/browser/helpers/omit.qwik.cjs +2 -1
  140. package/lib/browser/helpers/omit.qwik.mjs +2 -1
  141. package/lib/browser/helpers/search/search.qwik.cjs +3 -2
  142. package/lib/browser/helpers/search/search.qwik.mjs +3 -2
  143. package/lib/browser/helpers/sessionId.qwik.cjs +4 -3
  144. package/lib/browser/helpers/sessionId.qwik.mjs +4 -3
  145. package/lib/browser/helpers/subscribe-to-editor.qwik.cjs +10 -5
  146. package/lib/browser/helpers/subscribe-to-editor.qwik.mjs +10 -5
  147. package/lib/browser/helpers/url.qwik.cjs +4 -2
  148. package/lib/browser/helpers/url.qwik.mjs +4 -2
  149. package/lib/browser/helpers/visitorId.qwik.cjs +4 -3
  150. package/lib/browser/helpers/visitorId.qwik.mjs +4 -3
  151. package/lib/browser/scripts/init-editing.qwik.cjs +25 -19
  152. package/lib/browser/scripts/init-editing.qwik.mjs +25 -19
  153. package/lib/edge/blocks/accordion/accordion.qwik.cjs +74 -143
  154. package/lib/edge/blocks/accordion/accordion.qwik.mjs +74 -143
  155. package/lib/edge/blocks/accordion/component-info.qwik.cjs +2 -1
  156. package/lib/edge/blocks/accordion/component-info.qwik.mjs +2 -1
  157. package/lib/edge/blocks/button/button.qwik.cjs +8 -17
  158. package/lib/edge/blocks/button/button.qwik.mjs +8 -17
  159. package/lib/edge/blocks/columns/columns.qwik.cjs +33 -67
  160. package/lib/edge/blocks/columns/columns.qwik.mjs +33 -67
  161. package/lib/edge/blocks/columns/component-info.qwik.cjs +4 -3
  162. package/lib/edge/blocks/columns/component-info.qwik.mjs +4 -3
  163. package/lib/edge/blocks/custom-code/custom-code.qwik.cjs +18 -22
  164. package/lib/edge/blocks/custom-code/custom-code.qwik.mjs +19 -23
  165. package/lib/edge/blocks/embed/embed.qwik.cjs +17 -23
  166. package/lib/edge/blocks/embed/embed.qwik.mjs +17 -23
  167. package/lib/edge/blocks/form/form/form.qwik.cjs +74 -128
  168. package/lib/edge/blocks/form/form/form.qwik.mjs +75 -129
  169. package/lib/edge/blocks/form/input/input.qwik.cjs +2 -2
  170. package/lib/edge/blocks/form/input/input.qwik.mjs +3 -3
  171. package/lib/edge/blocks/form/select/select.qwik.cjs +7 -5
  172. package/lib/edge/blocks/form/select/select.qwik.mjs +8 -6
  173. package/lib/edge/blocks/form/submit-button/submit-button.qwik.cjs +7 -9
  174. package/lib/edge/blocks/form/submit-button/submit-button.qwik.mjs +8 -10
  175. package/lib/edge/blocks/form/textarea/textarea.qwik.cjs +11 -21
  176. package/lib/edge/blocks/form/textarea/textarea.qwik.mjs +12 -22
  177. package/lib/edge/blocks/fragment/fragment.qwik.cjs +6 -3
  178. package/lib/edge/blocks/fragment/fragment.qwik.mjs +7 -4
  179. package/lib/edge/blocks/image/component-info.qwik.cjs +6 -3
  180. package/lib/edge/blocks/image/component-info.qwik.mjs +6 -3
  181. package/lib/edge/blocks/image/image.helpers.qwik.cjs +12 -6
  182. package/lib/edge/blocks/image/image.helpers.qwik.mjs +12 -6
  183. package/lib/edge/blocks/image/image.qwik.cjs +63 -89
  184. package/lib/edge/blocks/image/image.qwik.mjs +63 -89
  185. package/lib/edge/blocks/img/img.qwik.cjs +12 -18
  186. package/lib/edge/blocks/img/img.qwik.mjs +12 -18
  187. package/lib/edge/blocks/section/section.qwik.cjs +7 -6
  188. package/lib/edge/blocks/section/section.qwik.mjs +8 -7
  189. package/lib/edge/blocks/slot/slot.qwik.cjs +17 -43
  190. package/lib/edge/blocks/slot/slot.qwik.mjs +17 -43
  191. package/lib/edge/blocks/symbol/symbol.helpers.qwik.cjs +2 -1
  192. package/lib/edge/blocks/symbol/symbol.helpers.qwik.mjs +2 -1
  193. package/lib/edge/blocks/symbol/symbol.qwik.cjs +45 -137
  194. package/lib/edge/blocks/symbol/symbol.qwik.mjs +45 -137
  195. package/lib/edge/blocks/tabs/tabs.qwik.cjs +45 -99
  196. package/lib/edge/blocks/tabs/tabs.qwik.mjs +45 -99
  197. package/lib/edge/blocks/text/text.qwik.cjs +11 -15
  198. package/lib/edge/blocks/text/text.qwik.mjs +11 -15
  199. package/lib/edge/blocks/video/video.qwik.cjs +73 -87
  200. package/lib/edge/blocks/video/video.qwik.mjs +74 -88
  201. package/lib/edge/components/block/animator.qwik.cjs +22 -11
  202. package/lib/edge/components/block/animator.qwik.mjs +22 -11
  203. package/lib/edge/components/block/block.helpers.qwik.cjs +8 -4
  204. package/lib/edge/components/block/block.helpers.qwik.mjs +8 -4
  205. package/lib/edge/components/block/block.qwik.cjs +114 -320
  206. package/lib/edge/components/block/block.qwik.mjs +115 -321
  207. package/lib/edge/components/block/components/block-styles.qwik.cjs +22 -39
  208. package/lib/edge/components/block/components/block-styles.qwik.mjs +23 -40
  209. package/lib/edge/components/block/components/block-wrapper.qwik.cjs +12 -18
  210. package/lib/edge/components/block/components/block-wrapper.qwik.mjs +12 -18
  211. package/lib/edge/components/block/components/component-ref/component-ref.qwik.cjs +12 -29
  212. package/lib/edge/components/block/components/component-ref/component-ref.qwik.mjs +14 -31
  213. package/lib/edge/components/block/components/interactive-element.qwik.cjs +18 -27
  214. package/lib/edge/components/block/components/interactive-element.qwik.mjs +18 -27
  215. package/lib/edge/components/block/components/repeated-block.qwik.cjs +10 -31
  216. package/lib/edge/components/block/components/repeated-block.qwik.mjs +11 -32
  217. package/lib/edge/components/blocks/blocks-wrapper.qwik.cjs +24 -72
  218. package/lib/edge/components/blocks/blocks-wrapper.qwik.mjs +24 -72
  219. package/lib/edge/components/blocks/blocks.qwik.cjs +19 -78
  220. package/lib/edge/components/blocks/blocks.qwik.mjs +20 -79
  221. package/lib/edge/components/content/components/enable-editor.qwik.cjs +101 -193
  222. package/lib/edge/components/content/components/enable-editor.qwik.mjs +102 -194
  223. package/lib/edge/components/content/components/styles.helpers.qwik.cjs +12 -6
  224. package/lib/edge/components/content/components/styles.helpers.qwik.mjs +12 -6
  225. package/lib/edge/components/content/components/styles.qwik.cjs +8 -20
  226. package/lib/edge/components/content/components/styles.qwik.mjs +8 -20
  227. package/lib/edge/components/content/content.helpers.qwik.cjs +2 -1
  228. package/lib/edge/components/content/content.helpers.qwik.mjs +2 -1
  229. package/lib/edge/components/content/content.qwik.cjs +39 -189
  230. package/lib/edge/components/content/content.qwik.mjs +39 -189
  231. package/lib/edge/components/content-variants/content-variants.qwik.cjs +74 -313
  232. package/lib/edge/components/content-variants/content-variants.qwik.mjs +75 -314
  233. package/lib/edge/components/dynamic-renderer/dynamic-renderer.qwik.cjs +11 -12
  234. package/lib/edge/components/dynamic-renderer/dynamic-renderer.qwik.mjs +12 -13
  235. package/lib/edge/components/inlined-script.qwik.cjs +8 -13
  236. package/lib/edge/components/inlined-script.qwik.mjs +9 -14
  237. package/lib/edge/components/inlined-styles.qwik.cjs +8 -13
  238. package/lib/edge/components/inlined-styles.qwik.mjs +9 -14
  239. package/lib/edge/constants/device-sizes.qwik.cjs +2 -1
  240. package/lib/edge/constants/device-sizes.qwik.mjs +2 -1
  241. package/lib/edge/constants/sdk-version.qwik.cjs +1 -1
  242. package/lib/edge/constants/sdk-version.qwik.mjs +1 -1
  243. package/lib/edge/functions/evaluate/browser-runtime/browser.qwik.cjs +6 -3
  244. package/lib/edge/functions/evaluate/browser-runtime/browser.qwik.mjs +6 -3
  245. package/lib/edge/functions/evaluate/choose-eval.qwik.cjs +3 -1
  246. package/lib/edge/functions/evaluate/choose-eval.qwik.mjs +3 -1
  247. package/lib/edge/functions/evaluate/edge-runtime/acorn-interpreter.qwik.cjs +6 -7
  248. package/lib/edge/functions/evaluate/edge-runtime/acorn-interpreter.qwik.mjs +6 -7
  249. package/lib/edge/functions/evaluate/evaluate.qwik.cjs +6 -3
  250. package/lib/edge/functions/evaluate/evaluate.qwik.mjs +6 -3
  251. package/lib/edge/functions/evaluate/should-force-browser-runtime-in-node.qwik.cjs +4 -2
  252. package/lib/edge/functions/evaluate/should-force-browser-runtime-in-node.qwik.mjs +4 -2
  253. package/lib/edge/functions/get-block-actions-handler.qwik.cjs +9 -15
  254. package/lib/edge/functions/get-block-actions-handler.qwik.mjs +10 -16
  255. package/lib/edge/functions/get-block-actions.qwik.cjs +4 -2
  256. package/lib/edge/functions/get-block-actions.qwik.mjs +4 -2
  257. package/lib/edge/functions/get-builder-search-params/index.qwik.cjs +4 -2
  258. package/lib/edge/functions/get-builder-search-params/index.qwik.mjs +4 -2
  259. package/lib/edge/functions/get-content/generate-content-url.qwik.cjs +22 -11
  260. package/lib/edge/functions/get-content/generate-content-url.qwik.mjs +22 -11
  261. package/lib/edge/functions/get-content/index.qwik.cjs +4 -2
  262. package/lib/edge/functions/get-content/index.qwik.mjs +4 -2
  263. package/lib/edge/functions/get-global-this.qwik.cjs +8 -4
  264. package/lib/edge/functions/get-global-this.qwik.mjs +8 -4
  265. package/lib/edge/functions/get-processed-block.qwik.cjs +15 -8
  266. package/lib/edge/functions/get-processed-block.qwik.mjs +15 -8
  267. package/lib/edge/functions/is-from-trusted-host.qwik.cjs +2 -1
  268. package/lib/edge/functions/is-from-trusted-host.qwik.mjs +2 -1
  269. package/lib/edge/functions/is-previewing.qwik.cjs +2 -1
  270. package/lib/edge/functions/is-previewing.qwik.mjs +2 -1
  271. package/lib/edge/functions/register-component.qwik.cjs +2 -1
  272. package/lib/edge/functions/register-component.qwik.mjs +2 -1
  273. package/lib/edge/functions/register.qwik.cjs +6 -3
  274. package/lib/edge/functions/register.qwik.mjs +6 -3
  275. package/lib/edge/functions/set.qwik.cjs +2 -1
  276. package/lib/edge/functions/set.qwik.mjs +2 -1
  277. package/lib/edge/functions/track/helpers.qwik.cjs +2 -1
  278. package/lib/edge/functions/track/helpers.qwik.mjs +2 -1
  279. package/lib/edge/functions/track/index.qwik.cjs +8 -4
  280. package/lib/edge/functions/track/index.qwik.mjs +8 -4
  281. package/lib/edge/functions/track/interaction.qwik.cjs +6 -3
  282. package/lib/edge/functions/track/interaction.qwik.mjs +6 -3
  283. package/lib/edge/helpers/ab-tests.qwik.cjs +15 -8
  284. package/lib/edge/helpers/ab-tests.qwik.mjs +16 -9
  285. package/lib/edge/helpers/cookie.qwik.cjs +4 -2
  286. package/lib/edge/helpers/cookie.qwik.mjs +4 -2
  287. package/lib/edge/helpers/css.qwik.cjs +6 -4
  288. package/lib/edge/helpers/css.qwik.mjs +6 -4
  289. package/lib/edge/helpers/flatten.qwik.cjs +3 -2
  290. package/lib/edge/helpers/flatten.qwik.mjs +3 -2
  291. package/lib/edge/helpers/localStorage.qwik.cjs +4 -2
  292. package/lib/edge/helpers/localStorage.qwik.mjs +4 -2
  293. package/lib/edge/helpers/omit.qwik.cjs +2 -1
  294. package/lib/edge/helpers/omit.qwik.mjs +2 -1
  295. package/lib/edge/helpers/search/search.qwik.cjs +3 -2
  296. package/lib/edge/helpers/search/search.qwik.mjs +3 -2
  297. package/lib/edge/helpers/sessionId.qwik.cjs +4 -3
  298. package/lib/edge/helpers/sessionId.qwik.mjs +4 -3
  299. package/lib/edge/helpers/subscribe-to-editor.qwik.cjs +10 -5
  300. package/lib/edge/helpers/subscribe-to-editor.qwik.mjs +10 -5
  301. package/lib/edge/helpers/url.qwik.cjs +4 -2
  302. package/lib/edge/helpers/url.qwik.mjs +4 -2
  303. package/lib/edge/helpers/visitorId.qwik.cjs +4 -3
  304. package/lib/edge/helpers/visitorId.qwik.mjs +4 -3
  305. package/lib/edge/scripts/init-editing.qwik.cjs +25 -19
  306. package/lib/edge/scripts/init-editing.qwik.mjs +25 -19
  307. package/lib/node/blocks/accordion/accordion.qwik.cjs +74 -143
  308. package/lib/node/blocks/accordion/accordion.qwik.mjs +74 -143
  309. package/lib/node/blocks/accordion/component-info.qwik.cjs +2 -1
  310. package/lib/node/blocks/accordion/component-info.qwik.mjs +2 -1
  311. package/lib/node/blocks/button/button.qwik.cjs +8 -17
  312. package/lib/node/blocks/button/button.qwik.mjs +8 -17
  313. package/lib/node/blocks/columns/columns.qwik.cjs +33 -67
  314. package/lib/node/blocks/columns/columns.qwik.mjs +33 -67
  315. package/lib/node/blocks/columns/component-info.qwik.cjs +4 -3
  316. package/lib/node/blocks/columns/component-info.qwik.mjs +4 -3
  317. package/lib/node/blocks/custom-code/custom-code.qwik.cjs +18 -22
  318. package/lib/node/blocks/custom-code/custom-code.qwik.mjs +19 -23
  319. package/lib/node/blocks/embed/embed.qwik.cjs +17 -23
  320. package/lib/node/blocks/embed/embed.qwik.mjs +17 -23
  321. package/lib/node/blocks/form/form/form.qwik.cjs +74 -128
  322. package/lib/node/blocks/form/form/form.qwik.mjs +75 -129
  323. package/lib/node/blocks/form/input/input.qwik.cjs +2 -2
  324. package/lib/node/blocks/form/input/input.qwik.mjs +3 -3
  325. package/lib/node/blocks/form/select/select.qwik.cjs +7 -5
  326. package/lib/node/blocks/form/select/select.qwik.mjs +8 -6
  327. package/lib/node/blocks/form/submit-button/submit-button.qwik.cjs +7 -9
  328. package/lib/node/blocks/form/submit-button/submit-button.qwik.mjs +8 -10
  329. package/lib/node/blocks/form/textarea/textarea.qwik.cjs +11 -21
  330. package/lib/node/blocks/form/textarea/textarea.qwik.mjs +12 -22
  331. package/lib/node/blocks/fragment/fragment.qwik.cjs +6 -3
  332. package/lib/node/blocks/fragment/fragment.qwik.mjs +7 -4
  333. package/lib/node/blocks/image/component-info.qwik.cjs +6 -3
  334. package/lib/node/blocks/image/component-info.qwik.mjs +6 -3
  335. package/lib/node/blocks/image/image.helpers.qwik.cjs +12 -6
  336. package/lib/node/blocks/image/image.helpers.qwik.mjs +12 -6
  337. package/lib/node/blocks/image/image.qwik.cjs +63 -89
  338. package/lib/node/blocks/image/image.qwik.mjs +63 -89
  339. package/lib/node/blocks/img/img.qwik.cjs +12 -18
  340. package/lib/node/blocks/img/img.qwik.mjs +12 -18
  341. package/lib/node/blocks/section/section.qwik.cjs +7 -6
  342. package/lib/node/blocks/section/section.qwik.mjs +8 -7
  343. package/lib/node/blocks/slot/slot.qwik.cjs +17 -43
  344. package/lib/node/blocks/slot/slot.qwik.mjs +17 -43
  345. package/lib/node/blocks/symbol/symbol.helpers.qwik.cjs +2 -1
  346. package/lib/node/blocks/symbol/symbol.helpers.qwik.mjs +2 -1
  347. package/lib/node/blocks/symbol/symbol.qwik.cjs +45 -137
  348. package/lib/node/blocks/symbol/symbol.qwik.mjs +45 -137
  349. package/lib/node/blocks/tabs/tabs.qwik.cjs +45 -99
  350. package/lib/node/blocks/tabs/tabs.qwik.mjs +45 -99
  351. package/lib/node/blocks/text/text.qwik.cjs +11 -15
  352. package/lib/node/blocks/text/text.qwik.mjs +11 -15
  353. package/lib/node/blocks/video/video.qwik.cjs +73 -87
  354. package/lib/node/blocks/video/video.qwik.mjs +74 -88
  355. package/lib/node/components/block/animator.qwik.cjs +22 -11
  356. package/lib/node/components/block/animator.qwik.mjs +22 -11
  357. package/lib/node/components/block/block.helpers.qwik.cjs +8 -4
  358. package/lib/node/components/block/block.helpers.qwik.mjs +8 -4
  359. package/lib/node/components/block/block.qwik.cjs +114 -320
  360. package/lib/node/components/block/block.qwik.mjs +115 -321
  361. package/lib/node/components/block/components/block-styles.qwik.cjs +22 -39
  362. package/lib/node/components/block/components/block-styles.qwik.mjs +23 -40
  363. package/lib/node/components/block/components/block-wrapper.qwik.cjs +12 -18
  364. package/lib/node/components/block/components/block-wrapper.qwik.mjs +12 -18
  365. package/lib/node/components/block/components/component-ref/component-ref.qwik.cjs +12 -29
  366. package/lib/node/components/block/components/component-ref/component-ref.qwik.mjs +14 -31
  367. package/lib/node/components/block/components/interactive-element.qwik.cjs +18 -27
  368. package/lib/node/components/block/components/interactive-element.qwik.mjs +18 -27
  369. package/lib/node/components/block/components/repeated-block.qwik.cjs +10 -31
  370. package/lib/node/components/block/components/repeated-block.qwik.mjs +11 -32
  371. package/lib/node/components/blocks/blocks-wrapper.qwik.cjs +24 -72
  372. package/lib/node/components/blocks/blocks-wrapper.qwik.mjs +24 -72
  373. package/lib/node/components/blocks/blocks.qwik.cjs +19 -78
  374. package/lib/node/components/blocks/blocks.qwik.mjs +20 -79
  375. package/lib/node/components/content/components/enable-editor.qwik.cjs +101 -193
  376. package/lib/node/components/content/components/enable-editor.qwik.mjs +102 -194
  377. package/lib/node/components/content/components/styles.helpers.qwik.cjs +12 -6
  378. package/lib/node/components/content/components/styles.helpers.qwik.mjs +12 -6
  379. package/lib/node/components/content/components/styles.qwik.cjs +8 -20
  380. package/lib/node/components/content/components/styles.qwik.mjs +8 -20
  381. package/lib/node/components/content/content.helpers.qwik.cjs +2 -1
  382. package/lib/node/components/content/content.helpers.qwik.mjs +2 -1
  383. package/lib/node/components/content/content.qwik.cjs +39 -189
  384. package/lib/node/components/content/content.qwik.mjs +39 -189
  385. package/lib/node/components/content-variants/content-variants.qwik.cjs +74 -313
  386. package/lib/node/components/content-variants/content-variants.qwik.mjs +75 -314
  387. package/lib/node/components/dynamic-renderer/dynamic-renderer.qwik.cjs +11 -12
  388. package/lib/node/components/dynamic-renderer/dynamic-renderer.qwik.mjs +12 -13
  389. package/lib/node/components/inlined-script.qwik.cjs +8 -13
  390. package/lib/node/components/inlined-script.qwik.mjs +9 -14
  391. package/lib/node/components/inlined-styles.qwik.cjs +8 -13
  392. package/lib/node/components/inlined-styles.qwik.mjs +9 -14
  393. package/lib/node/constants/device-sizes.qwik.cjs +2 -1
  394. package/lib/node/constants/device-sizes.qwik.mjs +2 -1
  395. package/lib/node/constants/sdk-version.qwik.cjs +1 -1
  396. package/lib/node/constants/sdk-version.qwik.mjs +1 -1
  397. package/lib/node/functions/evaluate/browser-runtime/browser.qwik.cjs +6 -3
  398. package/lib/node/functions/evaluate/browser-runtime/browser.qwik.mjs +6 -3
  399. package/lib/node/functions/evaluate/choose-eval.qwik.cjs +3 -1
  400. package/lib/node/functions/evaluate/choose-eval.qwik.mjs +3 -1
  401. package/lib/node/functions/evaluate/evaluate.qwik.cjs +6 -3
  402. package/lib/node/functions/evaluate/evaluate.qwik.mjs +6 -3
  403. package/lib/node/functions/evaluate/node-runtime/init.qwik.cjs +6 -0
  404. package/lib/node/functions/evaluate/node-runtime/init.qwik.mjs +6 -0
  405. package/lib/node/functions/evaluate/should-force-browser-runtime-in-node.qwik.cjs +4 -2
  406. package/lib/node/functions/evaluate/should-force-browser-runtime-in-node.qwik.mjs +4 -2
  407. package/lib/node/functions/get-block-actions-handler.qwik.cjs +9 -15
  408. package/lib/node/functions/get-block-actions-handler.qwik.mjs +10 -16
  409. package/lib/node/functions/get-block-actions.qwik.cjs +4 -2
  410. package/lib/node/functions/get-block-actions.qwik.mjs +4 -2
  411. package/lib/node/functions/get-builder-search-params/index.qwik.cjs +4 -2
  412. package/lib/node/functions/get-builder-search-params/index.qwik.mjs +4 -2
  413. package/lib/node/functions/get-content/generate-content-url.qwik.cjs +22 -11
  414. package/lib/node/functions/get-content/generate-content-url.qwik.mjs +22 -11
  415. package/lib/node/functions/get-content/index.qwik.cjs +4 -2
  416. package/lib/node/functions/get-content/index.qwik.mjs +4 -2
  417. package/lib/node/functions/get-global-this.qwik.cjs +8 -4
  418. package/lib/node/functions/get-global-this.qwik.mjs +8 -4
  419. package/lib/node/functions/get-processed-block.qwik.cjs +15 -8
  420. package/lib/node/functions/get-processed-block.qwik.mjs +15 -8
  421. package/lib/node/functions/is-from-trusted-host.qwik.cjs +2 -1
  422. package/lib/node/functions/is-from-trusted-host.qwik.mjs +2 -1
  423. package/lib/node/functions/is-previewing.qwik.cjs +2 -1
  424. package/lib/node/functions/is-previewing.qwik.mjs +2 -1
  425. package/lib/node/functions/register-component.qwik.cjs +2 -1
  426. package/lib/node/functions/register-component.qwik.mjs +2 -1
  427. package/lib/node/functions/register.qwik.cjs +6 -3
  428. package/lib/node/functions/register.qwik.mjs +6 -3
  429. package/lib/node/functions/set.qwik.cjs +2 -1
  430. package/lib/node/functions/set.qwik.mjs +2 -1
  431. package/lib/node/functions/track/helpers.qwik.cjs +2 -1
  432. package/lib/node/functions/track/helpers.qwik.mjs +2 -1
  433. package/lib/node/functions/track/index.qwik.cjs +8 -4
  434. package/lib/node/functions/track/index.qwik.mjs +8 -4
  435. package/lib/node/functions/track/interaction.qwik.cjs +6 -3
  436. package/lib/node/functions/track/interaction.qwik.mjs +6 -3
  437. package/lib/node/helpers/ab-tests.qwik.cjs +15 -8
  438. package/lib/node/helpers/ab-tests.qwik.mjs +16 -9
  439. package/lib/node/helpers/cookie.qwik.cjs +4 -2
  440. package/lib/node/helpers/cookie.qwik.mjs +4 -2
  441. package/lib/node/helpers/css.qwik.cjs +6 -4
  442. package/lib/node/helpers/css.qwik.mjs +6 -4
  443. package/lib/node/helpers/flatten.qwik.cjs +3 -2
  444. package/lib/node/helpers/flatten.qwik.mjs +3 -2
  445. package/lib/node/helpers/localStorage.qwik.cjs +4 -2
  446. package/lib/node/helpers/localStorage.qwik.mjs +4 -2
  447. package/lib/node/helpers/omit.qwik.cjs +2 -1
  448. package/lib/node/helpers/omit.qwik.mjs +2 -1
  449. package/lib/node/helpers/search/search.qwik.cjs +3 -2
  450. package/lib/node/helpers/search/search.qwik.mjs +3 -2
  451. package/lib/node/helpers/sessionId.qwik.cjs +4 -3
  452. package/lib/node/helpers/sessionId.qwik.mjs +4 -3
  453. package/lib/node/helpers/subscribe-to-editor.qwik.cjs +10 -5
  454. package/lib/node/helpers/subscribe-to-editor.qwik.mjs +10 -5
  455. package/lib/node/helpers/url.qwik.cjs +4 -2
  456. package/lib/node/helpers/url.qwik.mjs +4 -2
  457. package/lib/node/helpers/visitorId.qwik.cjs +4 -3
  458. package/lib/node/helpers/visitorId.qwik.mjs +4 -3
  459. package/lib/node/scripts/init-editing.qwik.cjs +25 -19
  460. package/lib/node/scripts/init-editing.qwik.mjs +25 -19
  461. package/package.json +2 -2
  462. package/types/src/constants/sdk-version.d.ts +1 -1
  463. package/types/src/functions/evaluate/should-force-browser-runtime-in-node.d.ts +3 -1
  464. package/lib/browser/constants/sdk-name.qwik.cjs +0 -15
  465. package/lib/browser/constants/sdk-name.qwik.mjs +0 -15
  466. package/lib/browser/functions/evaluate/node-runtime/init.qwik.cjs +0 -9
  467. package/lib/browser/functions/evaluate/node-runtime/init.qwik.mjs +0 -9
  468. package/lib/browser/functions/evaluate/node-runtime/node-runtime.qwik.cjs +0 -47
  469. package/lib/browser/functions/evaluate/node-runtime/node-runtime.qwik.mjs +0 -47
  470. package/lib/browser/functions/evaluate/node-runtime/safeDynamicRequire.qwik.cjs +0 -15
  471. package/lib/browser/functions/evaluate/node-runtime/safeDynamicRequire.qwik.mjs +0 -15
  472. package/lib/edge/constants/sdk-name.qwik.cjs +0 -15
  473. package/lib/edge/constants/sdk-name.qwik.mjs +0 -15
  474. package/lib/edge/functions/evaluate/node-runtime/init.qwik.cjs +0 -9
  475. package/lib/edge/functions/evaluate/node-runtime/init.qwik.mjs +0 -9
  476. package/lib/edge/functions/evaluate/node-runtime/node-runtime.qwik.cjs +0 -47
  477. package/lib/edge/functions/evaluate/node-runtime/node-runtime.qwik.mjs +0 -47
  478. package/lib/edge/functions/evaluate/node-runtime/safeDynamicRequire.qwik.cjs +0 -15
  479. package/lib/edge/functions/evaluate/node-runtime/safeDynamicRequire.qwik.mjs +0 -15
@@ -1,14 +1,18 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
3
3
  function getGlobalThis() {
4
- if (typeof globalThis !== "undefined")
4
+ if (typeof globalThis !== "undefined") {
5
5
  return globalThis;
6
- if (typeof window !== "undefined")
6
+ }
7
+ if (typeof window !== "undefined") {
7
8
  return window;
8
- if (typeof global !== "undefined")
9
+ }
10
+ if (typeof global !== "undefined") {
9
11
  return global;
10
- if (typeof self !== "undefined")
12
+ }
13
+ if (typeof self !== "undefined") {
11
14
  return self;
15
+ }
12
16
  return globalThis;
13
17
  }
14
18
  exports.getGlobalThis = getGlobalThis;
@@ -1,12 +1,16 @@
1
1
  function getGlobalThis() {
2
- if (typeof globalThis !== "undefined")
2
+ if (typeof globalThis !== "undefined") {
3
3
  return globalThis;
4
- if (typeof window !== "undefined")
4
+ }
5
+ if (typeof window !== "undefined") {
5
6
  return window;
6
- if (typeof global !== "undefined")
7
+ }
8
+ if (typeof global !== "undefined") {
7
9
  return global;
8
- if (typeof self !== "undefined")
10
+ }
11
+ if (typeof self !== "undefined") {
9
12
  return self;
13
+ }
10
14
  return globalThis;
11
15
  }
12
16
  export {
@@ -7,16 +7,21 @@ const fastClone = require("./fast-clone.qwik.cjs");
7
7
  const set = require("./set.qwik.cjs");
8
8
  const transformBlock = require("./transform-block.qwik.cjs");
9
9
  function deepCloneWithConditions(obj) {
10
- if (obj === null || typeof obj !== "object")
10
+ if (obj === null || typeof obj !== "object") {
11
11
  return obj;
12
- if (Array.isArray(obj))
12
+ }
13
+ if (Array.isArray(obj)) {
13
14
  return obj.map((item) => deepCloneWithConditions(item));
14
- if (obj["@type"] === "@builder.io/sdk:Element")
15
+ }
16
+ if (obj["@type"] === "@builder.io/sdk:Element") {
15
17
  return obj;
18
+ }
16
19
  const clonedObj = {};
17
- for (const key in obj)
18
- if (key !== "meta" && Object.prototype.hasOwnProperty.call(obj, key))
20
+ for (const key in obj) {
21
+ if (key !== "meta" && Object.prototype.hasOwnProperty.call(obj, key)) {
19
22
  clonedObj[key] = deepCloneWithConditions(obj[key]);
23
+ }
24
+ }
20
25
  return clonedObj;
21
26
  }
22
27
  const IS_SDK_WITHOUT_CACHED_PROCESSED_BLOCK = [
@@ -55,8 +60,9 @@ const getCopy = (block) => {
55
60
  }
56
61
  };
57
62
  const evaluateBindings = ({ block, context, localState, rootState, rootSetState }) => {
58
- if (!block.bindings)
63
+ if (!block.bindings) {
59
64
  return block;
65
+ }
60
66
  const copied = getCopy(block);
61
67
  for (const binding in block.bindings) {
62
68
  const expression = block.bindings[binding];
@@ -74,7 +80,7 @@ const evaluateBindings = ({ block, context, localState, rootState, rootSetState
74
80
  };
75
81
  function getProcessedBlock({ block, context, shouldEvaluateBindings, localState, rootState, rootSetState }) {
76
82
  const transformedBlock = transformBlock.transformBlock(block);
77
- if (shouldEvaluateBindings)
83
+ if (shouldEvaluateBindings) {
78
84
  return evaluateBindings({
79
85
  block: transformedBlock,
80
86
  localState,
@@ -82,8 +88,9 @@ function getProcessedBlock({ block, context, shouldEvaluateBindings, localState,
82
88
  rootSetState,
83
89
  context
84
90
  });
85
- else
91
+ } else {
86
92
  return transformedBlock;
93
+ }
87
94
  }
88
95
  exports.deepCloneWithConditions = deepCloneWithConditions;
89
96
  exports.getProcessedBlock = getProcessedBlock;
@@ -5,16 +5,21 @@ import { fastClone } from "./fast-clone.qwik.mjs";
5
5
  import { set } from "./set.qwik.mjs";
6
6
  import { transformBlock } from "./transform-block.qwik.mjs";
7
7
  function deepCloneWithConditions(obj) {
8
- if (obj === null || typeof obj !== "object")
8
+ if (obj === null || typeof obj !== "object") {
9
9
  return obj;
10
- if (Array.isArray(obj))
10
+ }
11
+ if (Array.isArray(obj)) {
11
12
  return obj.map((item) => deepCloneWithConditions(item));
12
- if (obj["@type"] === "@builder.io/sdk:Element")
13
+ }
14
+ if (obj["@type"] === "@builder.io/sdk:Element") {
13
15
  return obj;
16
+ }
14
17
  const clonedObj = {};
15
- for (const key in obj)
16
- if (key !== "meta" && Object.prototype.hasOwnProperty.call(obj, key))
18
+ for (const key in obj) {
19
+ if (key !== "meta" && Object.prototype.hasOwnProperty.call(obj, key)) {
17
20
  clonedObj[key] = deepCloneWithConditions(obj[key]);
21
+ }
22
+ }
18
23
  return clonedObj;
19
24
  }
20
25
  const IS_SDK_WITHOUT_CACHED_PROCESSED_BLOCK = [
@@ -53,8 +58,9 @@ const getCopy = (block) => {
53
58
  }
54
59
  };
55
60
  const evaluateBindings = ({ block, context, localState, rootState, rootSetState }) => {
56
- if (!block.bindings)
61
+ if (!block.bindings) {
57
62
  return block;
63
+ }
58
64
  const copied = getCopy(block);
59
65
  for (const binding in block.bindings) {
60
66
  const expression = block.bindings[binding];
@@ -72,7 +78,7 @@ const evaluateBindings = ({ block, context, localState, rootState, rootSetState
72
78
  };
73
79
  function getProcessedBlock({ block, context, shouldEvaluateBindings, localState, rootState, rootSetState }) {
74
80
  const transformedBlock = transformBlock(block);
75
- if (shouldEvaluateBindings)
81
+ if (shouldEvaluateBindings) {
76
82
  return evaluateBindings({
77
83
  block: transformedBlock,
78
84
  localState,
@@ -80,8 +86,9 @@ function getProcessedBlock({ block, context, shouldEvaluateBindings, localState,
80
86
  rootSetState,
81
87
  context
82
88
  });
83
- else
89
+ } else {
84
90
  return transformedBlock;
91
+ }
85
92
  }
86
93
  export {
87
94
  deepCloneWithConditions,
@@ -8,8 +8,9 @@ const DEFAULT_TRUSTED_HOSTS = [
8
8
  "qa.builder.io"
9
9
  ];
10
10
  function isFromTrustedHost(trustedHosts, e) {
11
- if (!e.origin.startsWith("http") && !e.origin.startsWith("https"))
11
+ if (!e.origin.startsWith("http") && !e.origin.startsWith("https")) {
12
12
  return false;
13
+ }
13
14
  const url = new URL(e.origin), hostname = url.hostname;
14
15
  return (trustedHosts || DEFAULT_TRUSTED_HOSTS).findIndex((trustedHost) => trustedHost.startsWith("*.") ? hostname.endsWith(trustedHost.slice(1)) : trustedHost === hostname) > -1;
15
16
  }
@@ -6,8 +6,9 @@ const DEFAULT_TRUSTED_HOSTS = [
6
6
  "qa.builder.io"
7
7
  ];
8
8
  function isFromTrustedHost(trustedHosts, e) {
9
- if (!e.origin.startsWith("http") && !e.origin.startsWith("https"))
9
+ if (!e.origin.startsWith("http") && !e.origin.startsWith("https")) {
10
10
  return false;
11
+ }
11
12
  const url = new URL(e.origin), hostname = url.hostname;
12
13
  return (trustedHosts || DEFAULT_TRUSTED_HOSTS).findIndex((trustedHost) => trustedHost.startsWith("*.") ? hostname.endsWith(trustedHost.slice(1)) : trustedHost === hostname) > -1;
13
14
  }
@@ -4,8 +4,9 @@ const search = require("../helpers/search/search.qwik.cjs");
4
4
  const isBrowser = require("./is-browser.qwik.cjs");
5
5
  function isPreviewing(_search) {
6
6
  const search$1 = _search || (isBrowser.isBrowser() ? window.location.search : void 0);
7
- if (!search$1)
7
+ if (!search$1) {
8
8
  return false;
9
+ }
9
10
  const normalizedSearch = search.getSearchString(search$1);
10
11
  return Boolean(normalizedSearch.indexOf("builder.preview=") !== -1);
11
12
  }
@@ -2,8 +2,9 @@ import { getSearchString } from "../helpers/search/search.qwik.mjs";
2
2
  import { isBrowser } from "./is-browser.qwik.mjs";
3
3
  function isPreviewing(_search) {
4
4
  const search = _search || (isBrowser() ? window.location.search : void 0);
5
- if (!search)
5
+ if (!search) {
6
6
  return false;
7
+ }
7
8
  const normalizedSearch = getSearchString(search);
8
9
  return Boolean(normalizedSearch.indexOf("builder.preview=") !== -1);
9
10
  }
@@ -11,8 +11,9 @@ const serializeFn = (fnValue) => {
11
11
  };
12
12
  function serializeIncludingFunctions(info) {
13
13
  return JSON.parse(JSON.stringify(info, (key, value) => {
14
- if (typeof value === "function")
14
+ if (typeof value === "function") {
15
15
  return serializeFn(value);
16
+ }
16
17
  return value;
17
18
  }));
18
19
  }
@@ -9,8 +9,9 @@ const serializeFn = (fnValue) => {
9
9
  };
10
10
  function serializeIncludingFunctions(info) {
11
11
  return JSON.parse(JSON.stringify(info, (key, value) => {
12
- if (typeof value === "function")
12
+ if (typeof value === "function") {
13
13
  return serializeFn(value);
14
+ }
14
15
  return value;
15
16
  }));
16
17
  }
@@ -4,11 +4,13 @@ const isBrowser = require("./is-browser.qwik.cjs");
4
4
  const registerComponent = require("./register-component.qwik.cjs");
5
5
  const registry = {};
6
6
  function register(type, info) {
7
- if (type === "plugin")
7
+ if (type === "plugin") {
8
8
  info = registerComponent.serializeIncludingFunctions(info);
9
+ }
9
10
  let typeList = registry[type];
10
- if (!typeList)
11
+ if (!typeList) {
11
12
  typeList = registry[type] = [];
13
+ }
12
14
  typeList.push(info);
13
15
  if (isBrowser.isBrowser()) {
14
16
  const message = {
@@ -20,8 +22,9 @@ function register(type, info) {
20
22
  };
21
23
  try {
22
24
  parent.postMessage(message, "*");
23
- if (parent !== window)
25
+ if (parent !== window) {
24
26
  window.postMessage(message, "*");
27
+ }
25
28
  } catch (err) {
26
29
  console.debug("Could not postmessage", err);
27
30
  }
@@ -2,11 +2,13 @@ import { isBrowser } from "./is-browser.qwik.mjs";
2
2
  import { serializeIncludingFunctions } from "./register-component.qwik.mjs";
3
3
  const registry = {};
4
4
  function register(type, info) {
5
- if (type === "plugin")
5
+ if (type === "plugin") {
6
6
  info = serializeIncludingFunctions(info);
7
+ }
7
8
  let typeList = registry[type];
8
- if (!typeList)
9
+ if (!typeList) {
9
10
  typeList = registry[type] = [];
11
+ }
10
12
  typeList.push(info);
11
13
  if (isBrowser()) {
12
14
  const message = {
@@ -18,8 +20,9 @@ function register(type, info) {
18
20
  };
19
21
  try {
20
22
  parent.postMessage(message, "*");
21
- if (parent !== window)
23
+ if (parent !== window) {
22
24
  window.postMessage(message, "*");
25
+ }
23
26
  } catch (err) {
24
27
  console.debug("Could not postmessage", err);
25
28
  }
@@ -1,8 +1,9 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
3
3
  const set = (obj, _path, value) => {
4
- if (Object(obj) !== obj)
4
+ if (Object(obj) !== obj) {
5
5
  return obj;
6
+ }
6
7
  const path = Array.isArray(_path) ? _path : _path.toString().match(/[^.[\]]+/g);
7
8
  path.slice(0, -1).reduce((a, c, i) => Object(a[c]) === a[c] ? a[c] : a[c] = Math.abs(Number(path[i + 1])) >> 0 === +path[i + 1] ? [] : {}, obj)[path[path.length - 1]] = value;
8
9
  return obj;
@@ -1,6 +1,7 @@
1
1
  const set = (obj, _path, value) => {
2
- if (Object(obj) !== obj)
2
+ if (Object(obj) !== obj) {
3
3
  return obj;
4
+ }
4
5
  const path = Array.isArray(_path) ? _path : _path.toString().match(/[^.[\]]+/g);
5
6
  path.slice(0, -1).reduce((a, c, i) => Object(a[c]) === a[c] ? a[c] : a[c] = Math.abs(Number(path[i + 1])) >> 0 === +path[i + 1] ? [] : {}, obj)[path[path.length - 1]] = value;
6
7
  return obj;
@@ -5,8 +5,9 @@ const isBrowser = require("../is-browser.qwik.cjs");
5
5
  const getLocation = () => {
6
6
  if (isBrowser.isBrowser()) {
7
7
  const parsedLocation = new URL(location.href);
8
- if (parsedLocation.pathname === "")
8
+ if (parsedLocation.pathname === "") {
9
9
  parsedLocation.pathname = "/";
10
+ }
10
11
  return parsedLocation;
11
12
  } else {
12
13
  console.warn("Cannot get location for tracking in non-browser environment");
@@ -3,8 +3,9 @@ import { isBrowser } from "../is-browser.qwik.mjs";
3
3
  const getLocation = () => {
4
4
  if (isBrowser()) {
5
5
  const parsedLocation = new URL(location.href);
6
- if (parsedLocation.pathname === "")
6
+ if (parsedLocation.pathname === "") {
7
7
  parsedLocation.pathname = "/";
8
+ }
8
9
  return parsedLocation;
9
10
  } else {
10
11
  console.warn("Cannot get location for tracking in non-browser environment");
@@ -8,11 +8,12 @@ const isBrowser = require("../is-browser.qwik.cjs");
8
8
  const isEditing = require("../is-editing.qwik.cjs");
9
9
  const helpers = require("./helpers.qwik.cjs");
10
10
  const getTrackingEventData = async ({ canTrack }) => {
11
- if (!canTrack)
11
+ if (!canTrack) {
12
12
  return {
13
13
  visitorId: void 0,
14
14
  sessionId: void 0
15
15
  };
16
+ }
16
17
  const sessionId$1 = await sessionId.getSessionId({
17
18
  canTrack
18
19
  });
@@ -44,12 +45,15 @@ async function _track(eventProps) {
44
45
  logger.logger.error("Missing API key for track call. Please provide your API key.");
45
46
  return;
46
47
  }
47
- if (!eventProps.canTrack)
48
+ if (!eventProps.canTrack) {
48
49
  return;
49
- if (isEditing.isEditing())
50
+ }
51
+ if (isEditing.isEditing()) {
50
52
  return;
51
- if (!(isBrowser.isBrowser() || target.TARGET === "reactNative"))
53
+ }
54
+ if (!(isBrowser.isBrowser() || target.TARGET === "reactNative")) {
52
55
  return;
56
+ }
53
57
  return fetch(`https://cdn.builder.io/api/v1/track`, {
54
58
  method: "POST",
55
59
  body: JSON.stringify({
@@ -6,11 +6,12 @@ import { isBrowser } from "../is-browser.qwik.mjs";
6
6
  import { isEditing } from "../is-editing.qwik.mjs";
7
7
  import { getUserAttributes } from "./helpers.qwik.mjs";
8
8
  const getTrackingEventData = async ({ canTrack }) => {
9
- if (!canTrack)
9
+ if (!canTrack) {
10
10
  return {
11
11
  visitorId: void 0,
12
12
  sessionId: void 0
13
13
  };
14
+ }
14
15
  const sessionId = await getSessionId({
15
16
  canTrack
16
17
  });
@@ -42,12 +43,15 @@ async function _track(eventProps) {
42
43
  logger.error("Missing API key for track call. Please provide your API key.");
43
44
  return;
44
45
  }
45
- if (!eventProps.canTrack)
46
+ if (!eventProps.canTrack) {
46
47
  return;
47
- if (isEditing())
48
+ }
49
+ if (isEditing()) {
48
50
  return;
49
- if (!(isBrowser() || TARGET === "reactNative"))
51
+ }
52
+ if (!(isBrowser() || TARGET === "reactNative")) {
50
53
  return;
54
+ }
51
55
  return fetch(`https://cdn.builder.io/api/v1/track`, {
52
56
  method: "POST",
53
57
  body: JSON.stringify({
@@ -4,15 +4,18 @@ function round(num) {
4
4
  return Math.round(num * 1e3) / 1e3;
5
5
  }
6
6
  const findParentElement = (target, callback, checkElement = true) => {
7
- if (!(target instanceof HTMLElement))
7
+ if (!(target instanceof HTMLElement)) {
8
8
  return null;
9
+ }
9
10
  let parent = checkElement ? target : target.parentElement;
10
11
  do {
11
- if (!parent)
12
+ if (!parent) {
12
13
  return null;
14
+ }
13
15
  const matches = callback(parent);
14
- if (matches)
16
+ if (matches) {
15
17
  return parent;
18
+ }
16
19
  } while (parent = parent.parentElement);
17
20
  return null;
18
21
  };
@@ -2,15 +2,18 @@ function round(num) {
2
2
  return Math.round(num * 1e3) / 1e3;
3
3
  }
4
4
  const findParentElement = (target, callback, checkElement = true) => {
5
- if (!(target instanceof HTMLElement))
5
+ if (!(target instanceof HTMLElement)) {
6
6
  return null;
7
+ }
7
8
  let parent = checkElement ? target : target.parentElement;
8
9
  do {
9
- if (!parent)
10
+ if (!parent) {
10
11
  return null;
12
+ }
11
13
  const matches = callback(parent);
12
- if (matches)
14
+ if (matches) {
13
15
  return parent;
16
+ }
14
17
  } while (parent = parent.parentElement);
15
18
  return null;
16
19
  };
@@ -26,8 +26,9 @@ const getRandomVariationId = ({ id, variations }) => {
26
26
  for (const id2 in variations) {
27
27
  const testRatio = (_a = variations[id2]) == null ? void 0 : _a.testRatio;
28
28
  n += testRatio;
29
- if (random < n)
29
+ if (random < n) {
30
30
  return id2;
31
+ }
31
32
  }
32
33
  return id;
33
34
  };
@@ -44,25 +45,29 @@ const getAndSetVariantId = (args) => {
44
45
  const getTestFields = ({ item, testGroupId }) => {
45
46
  const variationValue = item.variations[testGroupId];
46
47
  if (testGroupId === item.id || // handle edge-case where `testGroupId` points to non-existing variation
47
- !variationValue)
48
+ !variationValue) {
48
49
  return {
49
50
  testVariationId: item.id,
50
51
  testVariationName: "Default"
51
52
  };
52
- else
53
+ } else {
53
54
  return {
54
55
  data: variationValue.data,
55
56
  testVariationId: variationValue.id,
56
57
  testVariationName: variationValue.name || (variationValue.id === item.id ? "Default" : "")
57
58
  };
59
+ }
58
60
  };
59
61
  const handleABTestingSync = ({ item, canTrack }) => {
60
- if (!canTrack)
62
+ if (!canTrack) {
61
63
  return item;
62
- if (!item)
64
+ }
65
+ if (!item) {
63
66
  return void 0;
64
- if (!checkIsBuilderContentWithVariations(item))
67
+ }
68
+ if (!checkIsBuilderContentWithVariations(item)) {
65
69
  return item;
70
+ }
66
71
  const testGroupId = getContentVariationCookieSync({
67
72
  contentId: item.id
68
73
  }) || getAndSetVariantId({
@@ -79,10 +84,12 @@ const handleABTestingSync = ({ item, canTrack }) => {
79
84
  };
80
85
  };
81
86
  const handleABTesting = async ({ item, canTrack }) => {
82
- if (!canTrack)
87
+ if (!canTrack) {
83
88
  return item;
84
- if (!checkIsBuilderContentWithVariations(item))
89
+ }
90
+ if (!checkIsBuilderContentWithVariations(item)) {
85
91
  return item;
92
+ }
86
93
  const cookieValue = await getContentVariationCookie({
87
94
  contentId: item.id
88
95
  });
@@ -1,5 +1,5 @@
1
1
  import { checkIsDefined } from "./nullable.qwik.mjs";
2
- import { getCookie, getCookieSync, setCookie } from "./cookie.qwik.mjs";
2
+ import { getCookieSync, getCookie, setCookie } from "./cookie.qwik.mjs";
3
3
  import { logger } from "./logger.qwik.mjs";
4
4
  const BUILDER_STORE_PREFIX = "builder.tests";
5
5
  const getContentTestKey = (id) => `${BUILDER_STORE_PREFIX}.${id}`;
@@ -24,8 +24,9 @@ const getRandomVariationId = ({ id, variations }) => {
24
24
  for (const id2 in variations) {
25
25
  const testRatio = (_a = variations[id2]) == null ? void 0 : _a.testRatio;
26
26
  n += testRatio;
27
- if (random < n)
27
+ if (random < n) {
28
28
  return id2;
29
+ }
29
30
  }
30
31
  return id;
31
32
  };
@@ -42,25 +43,29 @@ const getAndSetVariantId = (args) => {
42
43
  const getTestFields = ({ item, testGroupId }) => {
43
44
  const variationValue = item.variations[testGroupId];
44
45
  if (testGroupId === item.id || // handle edge-case where `testGroupId` points to non-existing variation
45
- !variationValue)
46
+ !variationValue) {
46
47
  return {
47
48
  testVariationId: item.id,
48
49
  testVariationName: "Default"
49
50
  };
50
- else
51
+ } else {
51
52
  return {
52
53
  data: variationValue.data,
53
54
  testVariationId: variationValue.id,
54
55
  testVariationName: variationValue.name || (variationValue.id === item.id ? "Default" : "")
55
56
  };
57
+ }
56
58
  };
57
59
  const handleABTestingSync = ({ item, canTrack }) => {
58
- if (!canTrack)
60
+ if (!canTrack) {
59
61
  return item;
60
- if (!item)
62
+ }
63
+ if (!item) {
61
64
  return void 0;
62
- if (!checkIsBuilderContentWithVariations(item))
65
+ }
66
+ if (!checkIsBuilderContentWithVariations(item)) {
63
67
  return item;
68
+ }
64
69
  const testGroupId = getContentVariationCookieSync({
65
70
  contentId: item.id
66
71
  }) || getAndSetVariantId({
@@ -77,10 +82,12 @@ const handleABTestingSync = ({ item, canTrack }) => {
77
82
  };
78
83
  };
79
84
  const handleABTesting = async ({ item, canTrack }) => {
80
- if (!canTrack)
85
+ if (!canTrack) {
81
86
  return item;
82
- if (!checkIsBuilderContentWithVariations(item))
87
+ }
88
+ if (!checkIsBuilderContentWithVariations(item)) {
83
89
  return item;
90
+ }
84
91
  const cookieValue = await getContentVariationCookie({
85
92
  contentId: item.id
86
93
  });
@@ -7,8 +7,9 @@ const url = require("./url.qwik.cjs");
7
7
  const getCookieSync = ({ name, canTrack }) => {
8
8
  var _a;
9
9
  try {
10
- if (!canTrack)
10
+ if (!canTrack) {
11
11
  return void 0;
12
+ }
12
13
  return (_a = document.cookie.split("; ").find((row) => row.startsWith(`${name}=`))) == null ? void 0 : _a.split("=")[1];
13
14
  } catch (err) {
14
15
  logger.logger.warn("[COOKIE] GET error: ", (err == null ? void 0 : err.message) || err);
@@ -61,8 +62,9 @@ const createCookieString = ({ name, value, expires }) => {
61
62
  };
62
63
  const setCookie = async ({ name, value, expires, canTrack }) => {
63
64
  try {
64
- if (!canTrack)
65
+ if (!canTrack) {
65
66
  return;
67
+ }
66
68
  const cookie = createCookieString({
67
69
  name,
68
70
  value,
@@ -5,8 +5,9 @@ import { getTopLevelDomain } from "./url.qwik.mjs";
5
5
  const getCookieSync = ({ name, canTrack }) => {
6
6
  var _a;
7
7
  try {
8
- if (!canTrack)
8
+ if (!canTrack) {
9
9
  return void 0;
10
+ }
10
11
  return (_a = document.cookie.split("; ").find((row) => row.startsWith(`${name}=`))) == null ? void 0 : _a.split("=")[1];
11
12
  } catch (err) {
12
13
  logger.warn("[COOKIE] GET error: ", (err == null ? void 0 : err.message) || err);
@@ -59,8 +60,9 @@ const createCookieString = ({ name, value, expires }) => {
59
60
  };
60
61
  const setCookie = async ({ name, value, expires, canTrack }) => {
61
62
  try {
62
- if (!canTrack)
63
+ if (!canTrack) {
63
64
  return;
65
+ }
64
66
  const cookie = createCookieString({
65
67
  name,
66
68
  value,
@@ -4,10 +4,11 @@ const camelToKebabCase = require("../functions/camel-to-kebab-case.qwik.cjs");
4
4
  const nullable = require("./nullable.qwik.cjs");
5
5
  const convertStyleMapToCSSArray = (style) => {
6
6
  const cssProps = Object.entries(style).map(([key, value]) => {
7
- if (typeof value === "string")
7
+ if (typeof value === "string") {
8
8
  return `${camelToKebabCase.camelToKebabCase(key)}: ${value};`;
9
- else
9
+ } else {
10
10
  return void 0;
11
+ }
11
12
  });
12
13
  return cssProps.filter(nullable.checkIsDefined);
13
14
  };
@@ -16,12 +17,13 @@ const createCssClass = ({ mediaQuery, className, styles }) => {
16
17
  const cssClass = `.${className} {
17
18
  ${convertStyleMapToCSS(styles)}
18
19
  }`;
19
- if (mediaQuery)
20
+ if (mediaQuery) {
20
21
  return `${mediaQuery} {
21
22
  ${cssClass}
22
23
  }`;
23
- else
24
+ } else {
24
25
  return cssClass;
26
+ }
25
27
  };
26
28
  exports.convertStyleMapToCSS = convertStyleMapToCSS;
27
29
  exports.convertStyleMapToCSSArray = convertStyleMapToCSSArray;