@wavemaker/app-rn-runtime 12.0.0-next.45104 → 12.0.0-next.45128

Sign up to get free protection for your applications and to get access to all the features.
Files changed (292) hide show
  1. app-rn-runtime/components/advanced/carousel/carousel.component.js +31 -5
  2. app-rn-runtime/components/advanced/carousel/carousel.component.js.map +1 -1
  3. app-rn-runtime/components/advanced/carousel/carousel.props.js +1 -0
  4. app-rn-runtime/components/advanced/carousel/carousel.props.js.map +1 -1
  5. app-rn-runtime/components/advanced/carousel/carousel.styles.js +15 -0
  6. app-rn-runtime/components/advanced/carousel/carousel.styles.js.map +1 -1
  7. app-rn-runtime/components/advanced/webview/webview.component.js.map +1 -1
  8. app-rn-runtime/components/basic/anchor/anchor.component.js +15 -5
  9. app-rn-runtime/components/basic/anchor/anchor.component.js.map +1 -1
  10. app-rn-runtime/components/basic/anchor/anchor.styles.js +3 -0
  11. app-rn-runtime/components/basic/anchor/anchor.styles.js.map +1 -1
  12. app-rn-runtime/components/basic/animatedview.component.js +6 -2
  13. app-rn-runtime/components/basic/animatedview.component.js.map +1 -1
  14. app-rn-runtime/components/basic/audio/audio.component.js.map +1 -1
  15. app-rn-runtime/components/basic/button/button.component.js +20 -6
  16. app-rn-runtime/components/basic/button/button.component.js.map +1 -1
  17. app-rn-runtime/components/basic/icon/icon.component.js +14 -6
  18. app-rn-runtime/components/basic/icon/icon.component.js.map +1 -1
  19. app-rn-runtime/components/basic/label/label.component.js +13 -3
  20. app-rn-runtime/components/basic/label/label.component.js.map +1 -1
  21. app-rn-runtime/components/basic/label/label.styles.js.map +1 -1
  22. app-rn-runtime/components/basic/message/message.component.js.map +1 -1
  23. app-rn-runtime/components/basic/picture/picture.component.js +1 -2
  24. app-rn-runtime/components/basic/picture/picture.component.js.map +1 -1
  25. app-rn-runtime/components/basic/progress-bar/progress-bar.component.js +2 -2
  26. app-rn-runtime/components/basic/progress-bar/progress-bar.component.js.map +1 -1
  27. app-rn-runtime/components/basic/progress-circle/progress-circle.component.js +5 -5
  28. app-rn-runtime/components/basic/progress-circle/progress-circle.component.js.map +1 -1
  29. app-rn-runtime/components/basic/search/search.component.js +9 -0
  30. app-rn-runtime/components/basic/search/search.component.js.map +1 -1
  31. app-rn-runtime/components/basic/search/search.props.js +2 -0
  32. app-rn-runtime/components/basic/search/search.props.js.map +1 -1
  33. app-rn-runtime/components/basic/search/search.styles.js +5 -0
  34. app-rn-runtime/components/basic/search/search.styles.js.map +1 -1
  35. app-rn-runtime/components/basic/skeleton/skeleton.component.js +4 -3
  36. app-rn-runtime/components/basic/skeleton/skeleton.component.js.map +1 -1
  37. app-rn-runtime/components/basic/skeleton/skeleton.props.js +9 -1
  38. app-rn-runtime/components/basic/skeleton/skeleton.props.js.map +1 -1
  39. app-rn-runtime/components/basic/spinner/spinner.component.js +2 -3
  40. app-rn-runtime/components/basic/spinner/spinner.component.js.map +1 -1
  41. app-rn-runtime/components/basic/spinner/spinner.styles.js +3 -2
  42. app-rn-runtime/components/basic/spinner/spinner.styles.js.map +1 -1
  43. app-rn-runtime/components/basic/video/video.component.js.map +1 -1
  44. app-rn-runtime/components/basic/video/video.styles.js +4 -1
  45. app-rn-runtime/components/basic/video/video.styles.js.map +1 -1
  46. app-rn-runtime/components/chart/area-chart/area-chart.component.js +2 -1
  47. app-rn-runtime/components/chart/area-chart/area-chart.component.js.map +1 -1
  48. app-rn-runtime/components/chart/area-chart/area-chart.styles.js +7 -1
  49. app-rn-runtime/components/chart/area-chart/area-chart.styles.js.map +1 -1
  50. app-rn-runtime/components/chart/bar-chart/bar-chart.styles.js +7 -1
  51. app-rn-runtime/components/chart/bar-chart/bar-chart.styles.js.map +1 -1
  52. app-rn-runtime/components/chart/basechart.component.js +54 -2
  53. app-rn-runtime/components/chart/basechart.component.js.map +1 -1
  54. app-rn-runtime/components/chart/basechart.props.js +3 -2
  55. app-rn-runtime/components/chart/basechart.props.js.map +1 -1
  56. app-rn-runtime/components/chart/basechart.styles.js +4 -0
  57. app-rn-runtime/components/chart/basechart.styles.js.map +1 -1
  58. app-rn-runtime/components/chart/bubble-chart/bubble-chart.component.js +15 -3
  59. app-rn-runtime/components/chart/bubble-chart/bubble-chart.component.js.map +1 -1
  60. app-rn-runtime/components/chart/bubble-chart/bubble-chart.styles.js +7 -1
  61. app-rn-runtime/components/chart/bubble-chart/bubble-chart.styles.js.map +1 -1
  62. app-rn-runtime/components/chart/column-chart/column-chart.styles.js +7 -1
  63. app-rn-runtime/components/chart/column-chart/column-chart.styles.js.map +1 -1
  64. app-rn-runtime/components/chart/donut-chart/donut-chart.styles.js +7 -1
  65. app-rn-runtime/components/chart/donut-chart/donut-chart.styles.js.map +1 -1
  66. app-rn-runtime/components/chart/line-chart/line-chart.props.js +2 -0
  67. app-rn-runtime/components/chart/line-chart/line-chart.props.js.map +1 -1
  68. app-rn-runtime/components/chart/line-chart/line-chart.styles.js +7 -1
  69. app-rn-runtime/components/chart/line-chart/line-chart.styles.js.map +1 -1
  70. app-rn-runtime/components/chart/pie-chart/pie-chart.component.js +6 -2
  71. app-rn-runtime/components/chart/pie-chart/pie-chart.component.js.map +1 -1
  72. app-rn-runtime/components/chart/pie-chart/pie-chart.styles.js +7 -1
  73. app-rn-runtime/components/chart/pie-chart/pie-chart.styles.js.map +1 -1
  74. app-rn-runtime/components/chart/stack-chart/stack-chart.component.js +37 -11
  75. app-rn-runtime/components/chart/stack-chart/stack-chart.component.js.map +1 -1
  76. app-rn-runtime/components/container/accordion/accordion.component.js +61 -12
  77. app-rn-runtime/components/container/accordion/accordion.component.js.map +1 -1
  78. app-rn-runtime/components/container/accordion/accordion.props.js.map +1 -1
  79. app-rn-runtime/components/container/accordion/accordion.styles.js +5 -0
  80. app-rn-runtime/components/container/accordion/accordion.styles.js.map +1 -1
  81. app-rn-runtime/components/container/accordion/accordionpane/accordionpane.component.js +11 -1
  82. app-rn-runtime/components/container/accordion/accordionpane/accordionpane.component.js.map +1 -1
  83. app-rn-runtime/components/container/container.component.js +36 -2
  84. app-rn-runtime/components/container/container.component.js.map +1 -1
  85. app-rn-runtime/components/container/container.styles.js +7 -0
  86. app-rn-runtime/components/container/container.styles.js.map +1 -1
  87. app-rn-runtime/components/container/layoutgrid/gridcolumn/gridcolumn.component.js.map +1 -1
  88. app-rn-runtime/components/container/layoutgrid/gridrow/gridrow.component.js +5 -1
  89. app-rn-runtime/components/container/layoutgrid/gridrow/gridrow.component.js.map +1 -1
  90. app-rn-runtime/components/container/layoutgrid/gridrow/gridrow.styles.js +6 -1
  91. app-rn-runtime/components/container/layoutgrid/gridrow/gridrow.styles.js.map +1 -1
  92. app-rn-runtime/components/container/layoutgrid/layoutgrid.component.js +28 -2
  93. app-rn-runtime/components/container/layoutgrid/layoutgrid.component.js.map +1 -1
  94. app-rn-runtime/components/container/layoutgrid/layoutgrid.props.js.map +1 -1
  95. app-rn-runtime/components/container/layoutgrid/layoutgrid.styles.js +4 -1
  96. app-rn-runtime/components/container/layoutgrid/layoutgrid.styles.js.map +1 -1
  97. app-rn-runtime/components/container/linearlayout/linearlayout.component.js +31 -5
  98. app-rn-runtime/components/container/linearlayout/linearlayout.component.js.map +1 -1
  99. app-rn-runtime/components/container/linearlayout/linearlayout.props.js.map +1 -1
  100. app-rn-runtime/components/container/linearlayout/linearlayout.styles.js +4 -1
  101. app-rn-runtime/components/container/linearlayout/linearlayout.styles.js.map +1 -1
  102. app-rn-runtime/components/container/panel/panel.component.js +47 -6
  103. app-rn-runtime/components/container/panel/panel.component.js.map +1 -1
  104. app-rn-runtime/components/container/panel/panel.props.js.map +1 -1
  105. app-rn-runtime/components/container/panel/panel.styles.js +3 -0
  106. app-rn-runtime/components/container/panel/panel.styles.js.map +1 -1
  107. app-rn-runtime/components/container/partial-host.component.js.map +1 -1
  108. app-rn-runtime/components/container/tabs/tabheader/tabheader.component.js +3 -4
  109. app-rn-runtime/components/container/tabs/tabheader/tabheader.component.js.map +1 -1
  110. app-rn-runtime/components/container/tabs/tabheader/tabheader.props.js.map +1 -1
  111. app-rn-runtime/components/container/tabs/tabpane/tabpane.component.js +11 -1
  112. app-rn-runtime/components/container/tabs/tabpane/tabpane.component.js.map +1 -1
  113. app-rn-runtime/components/container/tabs/tabpane/tabpane.props.js.map +1 -1
  114. app-rn-runtime/components/container/tabs/tabs.component.js +41 -5
  115. app-rn-runtime/components/container/tabs/tabs.component.js.map +1 -1
  116. app-rn-runtime/components/container/tabs/tabs.props.js.map +1 -1
  117. app-rn-runtime/components/container/tabs/tabs.styles.js +4 -1
  118. app-rn-runtime/components/container/tabs/tabs.styles.js.map +1 -1
  119. app-rn-runtime/components/container/tile/tile.component.js +28 -2
  120. app-rn-runtime/components/container/tile/tile.component.js.map +1 -1
  121. app-rn-runtime/components/container/tile/tile.props.js.map +1 -1
  122. app-rn-runtime/components/container/tile/tile.styles.js +6 -1
  123. app-rn-runtime/components/container/tile/tile.styles.js.map +1 -1
  124. app-rn-runtime/components/container/wizard/wizard.component.js +62 -13
  125. app-rn-runtime/components/container/wizard/wizard.component.js.map +1 -1
  126. app-rn-runtime/components/container/wizard/wizard.props.js.map +1 -1
  127. app-rn-runtime/components/container/wizard/wizard.styles.js +3 -0
  128. app-rn-runtime/components/container/wizard/wizard.styles.js.map +1 -1
  129. app-rn-runtime/components/container/wizard/wizardstep/wizardstep.component.js +4 -1
  130. app-rn-runtime/components/container/wizard/wizardstep/wizardstep.component.js.map +1 -1
  131. app-rn-runtime/components/data/card/card-content/card-content.component.js +6 -2
  132. app-rn-runtime/components/data/card/card-content/card-content.component.js.map +1 -1
  133. app-rn-runtime/components/data/card/card-content/card-content.styles.js +4 -1
  134. app-rn-runtime/components/data/card/card-content/card-content.styles.js.map +1 -1
  135. app-rn-runtime/components/data/card/card.component.js +18 -0
  136. app-rn-runtime/components/data/card/card.component.js.map +1 -1
  137. app-rn-runtime/components/data/card/card.styles.js +3 -0
  138. app-rn-runtime/components/data/card/card.styles.js.map +1 -1
  139. app-rn-runtime/components/data/form/form-field/form-field.component.js.map +1 -1
  140. app-rn-runtime/components/data/form/form.component.js +1 -1
  141. app-rn-runtime/components/data/form/form.component.js.map +1 -1
  142. app-rn-runtime/components/data/form/form.props.js +1 -0
  143. app-rn-runtime/components/data/form/form.props.js.map +1 -1
  144. app-rn-runtime/components/data/list/list-template/list-template.component.js +15 -1
  145. app-rn-runtime/components/data/list/list-template/list-template.component.js.map +1 -1
  146. app-rn-runtime/components/data/list/list-template/list-template.props.js +1 -0
  147. app-rn-runtime/components/data/list/list-template/list-template.props.js.map +1 -1
  148. app-rn-runtime/components/data/list/list-template/list-template.styles.js +11 -1
  149. app-rn-runtime/components/data/list/list-template/list-template.styles.js.map +1 -1
  150. app-rn-runtime/components/data/list/list.component.js +54 -33
  151. app-rn-runtime/components/data/list/list.component.js.map +1 -1
  152. app-rn-runtime/components/data/list/list.props.js +1 -0
  153. app-rn-runtime/components/data/list/list.props.js.map +1 -1
  154. app-rn-runtime/components/data/list/list.styles.js +9 -0
  155. app-rn-runtime/components/data/list/list.styles.js.map +1 -1
  156. app-rn-runtime/components/dialogs/dialog/dialog.component.js +5 -3
  157. app-rn-runtime/components/dialogs/dialog/dialog.component.js.map +1 -1
  158. app-rn-runtime/components/dialogs/dialog/dialog.styles.js.map +1 -1
  159. app-rn-runtime/components/input/basedataset/basedataset.component.js.map +1 -1
  160. app-rn-runtime/components/input/baseinput/baseinput.component.js +11 -4
  161. app-rn-runtime/components/input/baseinput/baseinput.component.js.map +1 -1
  162. app-rn-runtime/components/input/baseinput/baseinput.props.js +1 -0
  163. app-rn-runtime/components/input/baseinput/baseinput.props.js.map +1 -1
  164. app-rn-runtime/components/input/basenumber/basenumber.component.js +25 -12
  165. app-rn-runtime/components/input/basenumber/basenumber.component.js.map +1 -1
  166. app-rn-runtime/components/input/basenumber/basenumber.props.js +2 -0
  167. app-rn-runtime/components/input/basenumber/basenumber.props.js.map +1 -1
  168. app-rn-runtime/components/input/checkbox/checkbox.component.js +5 -6
  169. app-rn-runtime/components/input/checkbox/checkbox.component.js.map +1 -1
  170. app-rn-runtime/components/input/checkbox/checkbox.styles.js.map +1 -1
  171. app-rn-runtime/components/input/checkboxset/checkboxset.component.js +24 -3
  172. app-rn-runtime/components/input/checkboxset/checkboxset.component.js.map +1 -1
  173. app-rn-runtime/components/input/checkboxset/checkboxset.props.js +1 -0
  174. app-rn-runtime/components/input/checkboxset/checkboxset.props.js.map +1 -1
  175. app-rn-runtime/components/input/checkboxset/checkboxset.styles.js +1 -0
  176. app-rn-runtime/components/input/checkboxset/checkboxset.styles.js.map +1 -1
  177. app-rn-runtime/components/input/chips/chips.component.js +3 -2
  178. app-rn-runtime/components/input/chips/chips.component.js.map +1 -1
  179. app-rn-runtime/components/input/currency/currency.component.js +16 -1
  180. app-rn-runtime/components/input/currency/currency.component.js.map +1 -1
  181. app-rn-runtime/components/input/epoch/base-datetime.component.js +22 -5
  182. app-rn-runtime/components/input/epoch/base-datetime.component.js.map +1 -1
  183. app-rn-runtime/components/input/epoch/wheel-date-picker.component.js +123 -12
  184. app-rn-runtime/components/input/epoch/wheel-date-picker.component.js.map +1 -1
  185. app-rn-runtime/components/input/epoch/wheelpicker/wheelpicker.component.js.map +1 -1
  186. app-rn-runtime/components/input/epoch/wheelpickermodal/date/date-picker-modal.component.js +4 -0
  187. app-rn-runtime/components/input/epoch/wheelpickermodal/date/date-picker-modal.component.js.map +1 -1
  188. app-rn-runtime/components/input/epoch/wheelpickermodal/date/date-picker-modal.props.js +2 -0
  189. app-rn-runtime/components/input/epoch/wheelpickermodal/date/date-picker-modal.props.js.map +1 -1
  190. app-rn-runtime/components/input/fileupload/fileupload.component.js +4 -2
  191. app-rn-runtime/components/input/fileupload/fileupload.component.js.map +1 -1
  192. app-rn-runtime/components/input/fileupload/fileupload.props.js +1 -0
  193. app-rn-runtime/components/input/fileupload/fileupload.props.js.map +1 -1
  194. app-rn-runtime/components/input/number/number.component.js +6 -3
  195. app-rn-runtime/components/input/number/number.component.js.map +1 -1
  196. app-rn-runtime/components/input/radioset/radioset.component.js +27 -7
  197. app-rn-runtime/components/input/radioset/radioset.component.js.map +1 -1
  198. app-rn-runtime/components/input/radioset/radioset.props.js +1 -0
  199. app-rn-runtime/components/input/radioset/radioset.props.js.map +1 -1
  200. app-rn-runtime/components/input/radioset/radioset.styles.js +1 -0
  201. app-rn-runtime/components/input/radioset/radioset.styles.js.map +1 -1
  202. app-rn-runtime/components/input/select/select.component.js +23 -9
  203. app-rn-runtime/components/input/select/select.component.js.map +1 -1
  204. app-rn-runtime/components/input/switch/switch.component.js +2 -2
  205. app-rn-runtime/components/input/switch/switch.component.js.map +1 -1
  206. app-rn-runtime/components/input/text/text.component.js +21 -0
  207. app-rn-runtime/components/input/text/text.component.js.map +1 -1
  208. app-rn-runtime/components/input/text/text.props.js +2 -0
  209. app-rn-runtime/components/input/text/text.props.js.map +1 -1
  210. app-rn-runtime/components/input/text/text.styles.js.map +1 -1
  211. app-rn-runtime/components/input/textarea/textarea.component.js +21 -0
  212. app-rn-runtime/components/input/textarea/textarea.component.js.map +1 -1
  213. app-rn-runtime/components/input/textarea/textarea.props.js +2 -0
  214. app-rn-runtime/components/input/textarea/textarea.props.js.map +1 -1
  215. app-rn-runtime/components/input/toggle/toggle.component.js +2 -4
  216. app-rn-runtime/components/input/toggle/toggle.component.js.map +1 -1
  217. app-rn-runtime/components/navigation/appnavbar/appnavbar.component.js +2 -2
  218. app-rn-runtime/components/navigation/appnavbar/appnavbar.component.js.map +1 -1
  219. app-rn-runtime/components/navigation/basenav/basenav.component.js.map +1 -1
  220. app-rn-runtime/components/navigation/navitem/navitem.component.js +2 -3
  221. app-rn-runtime/components/navigation/navitem/navitem.component.js.map +1 -1
  222. app-rn-runtime/components/navigation/popover/popover.component.js.map +1 -1
  223. app-rn-runtime/components/page/content/content.component.js +19 -4
  224. app-rn-runtime/components/page/content/content.component.js.map +1 -1
  225. app-rn-runtime/components/page/page-content/page-content.component.js +27 -2
  226. app-rn-runtime/components/page/page-content/page-content.component.js.map +1 -1
  227. app-rn-runtime/components/page/page-content/page-content.props.js +2 -2
  228. app-rn-runtime/components/page/page-content/page-content.props.js.map +1 -1
  229. app-rn-runtime/components/page/page-content/page-content.styles.js +6 -1
  230. app-rn-runtime/components/page/page-content/page-content.styles.js.map +1 -1
  231. app-rn-runtime/components/page/page.component.js.map +1 -1
  232. app-rn-runtime/components/page/page.props.js.map +1 -1
  233. app-rn-runtime/components/page/page.styles.js +7 -1
  234. app-rn-runtime/components/page/page.styles.js.map +1 -1
  235. app-rn-runtime/components/page/partial/partial.component.js +27 -1
  236. app-rn-runtime/components/page/partial/partial.component.js.map +1 -1
  237. app-rn-runtime/components/page/partial/partial.props.js.map +1 -1
  238. app-rn-runtime/components/page/partial/partial.styles.js +6 -1
  239. app-rn-runtime/components/page/partial/partial.styles.js.map +1 -1
  240. app-rn-runtime/components/page/tabbar/curve.js.map +1 -1
  241. app-rn-runtime/components/page/tabbar/tabbar.component.js.map +1 -1
  242. app-rn-runtime/components/page/tabbar/tabbar.props.js +1 -0
  243. app-rn-runtime/components/page/tabbar/tabbar.props.js.map +1 -1
  244. app-rn-runtime/components/prefab/prefab-container.component.js +27 -1
  245. app-rn-runtime/components/prefab/prefab-container.component.js.map +1 -1
  246. app-rn-runtime/components/prefab/prefab-container.props.js.map +1 -1
  247. app-rn-runtime/components/prefab/prefab-container.styles.js +6 -1
  248. app-rn-runtime/components/prefab/prefab-container.styles.js.map +1 -1
  249. app-rn-runtime/core/base.component.js +5 -3
  250. app-rn-runtime/core/base.component.js.map +1 -1
  251. app-rn-runtime/core/components/textinput.component.js +4 -3
  252. app-rn-runtime/core/components/textinput.component.js.map +1 -1
  253. app-rn-runtime/core/formatters.js.map +1 -1
  254. app-rn-runtime/core/key.extractor.js.map +1 -1
  255. app-rn-runtime/core/props.provider.js +4 -1
  256. app-rn-runtime/core/props.provider.js.map +1 -1
  257. app-rn-runtime/core/storage.service.js.map +1 -1
  258. app-rn-runtime/core/tappable.component.js +34 -27
  259. app-rn-runtime/core/tappable.component.js.map +1 -1
  260. app-rn-runtime/core/ui-preferences.context.js +7 -0
  261. app-rn-runtime/core/ui-preferences.context.js.map +1 -0
  262. app-rn-runtime/core/utils.js +87 -4
  263. app-rn-runtime/core/utils.js.map +1 -1
  264. app-rn-runtime/package.json +30 -7
  265. app-rn-runtime/runtime/App.js +4 -8
  266. app-rn-runtime/runtime/App.js.map +1 -1
  267. app-rn-runtime/runtime/App.navigator.js.map +1 -1
  268. app-rn-runtime/runtime/base-fragment.component.js +43 -13
  269. app-rn-runtime/runtime/base-fragment.component.js.map +1 -1
  270. app-rn-runtime/runtime/base-page.component.js.map +1 -1
  271. app-rn-runtime/runtime/base-partial.component.js.map +1 -1
  272. app-rn-runtime/runtime/base-prefab.component.js.map +1 -1
  273. app-rn-runtime/runtime/navigator/stack.navigator.js.map +1 -1
  274. app-rn-runtime/runtime/services/app-i18n.service.js +10 -0
  275. app-rn-runtime/runtime/services/app-i18n.service.js.map +1 -1
  276. app-rn-runtime/runtime/services/app-security.service.js +42 -2
  277. app-rn-runtime/runtime/services/app-security.service.js.map +1 -1
  278. app-rn-runtime/runtime/services/app-spinner.service.js +1 -1
  279. app-rn-runtime/runtime/services/app-spinner.service.js.map +1 -1
  280. app-rn-runtime/runtime/services/webprocess.service.js.map +1 -1
  281. app-rn-runtime/runtime/watcher.js.map +1 -1
  282. app-rn-runtime/styles/background.component.js +1 -0
  283. app-rn-runtime/styles/background.component.js.map +1 -1
  284. app-rn-runtime/styles/style-prop.validator.js.map +1 -1
  285. app-rn-runtime/styles/theme.js +5 -0
  286. app-rn-runtime/styles/theme.js.map +1 -1
  287. app-rn-runtime/styles/theme.variables.js +1 -0
  288. app-rn-runtime/styles/theme.variables.js.map +1 -1
  289. app-rn-runtime/variables/base-variable.js.map +1 -1
  290. app-rn-runtime/variables/device/file/upload-file.operation.js.map +1 -1
  291. app-rn-runtime/variables/device-variable.js.map +1 -1
  292. app-rn-runtime/variables/service-variable.js.map +1 -1
@@ -1,3 +1,4 @@
1
+ function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
1
2
  function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
2
3
  function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == typeof i ? i : i + ""; }
3
4
  function _toPrimitive(t, r) { if ("object" != typeof t || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != typeof i) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
@@ -109,6 +110,9 @@ export default class WmCarousel extends BaseComponent {
109
110
  return 'list_item_' + this.keyExtractor.getKey(item, true);
110
111
  }
111
112
  autoPlay() {
113
+ if (!this.initialized) {
114
+ return;
115
+ }
112
116
  const props = this.state.props;
113
117
  this.stopPlay && this.stopPlay();
114
118
  if (props.animation === 'auto' && props.animationinterval) {
@@ -124,6 +128,12 @@ export default class WmCarousel extends BaseComponent {
124
128
  }, 1000);
125
129
  }
126
130
  }
131
+ stopAnimation() {
132
+ this.stopPlay();
133
+ }
134
+ startAnimation() {
135
+ this.autoPlay();
136
+ }
127
137
  onPropertyChange(name, $new, $old) {
128
138
  super.onPropertyChange(name, $new, $old);
129
139
  switch (name) {
@@ -187,6 +197,10 @@ export default class WmCarousel extends BaseComponent {
187
197
  if (maxIndex === data.length) {
188
198
  minIndex = maxIndex - maxNoOfDots;
189
199
  }
200
+ const dotStyle = this._showSkeleton ? {
201
+ ...this.styles.dotStyle,
202
+ ...this.styles.dotSkeleton.root
203
+ } : this.styles.dotStyle;
190
204
  return /*#__PURE__*/React.createElement(View, {
191
205
  style: this.styles.dotsWrapperStyle
192
206
  }, /*#__PURE__*/React.createElement(View, {
@@ -194,11 +208,12 @@ export default class WmCarousel extends BaseComponent {
194
208
  flexDirection: this.isRTL ? 'row-reverse' : 'row'
195
209
  }
196
210
  }, data.map((item, index) => {
197
- return index >= minIndex && index <= maxIndex ? /*#__PURE__*/React.createElement(View, {
198
- key: 'dots_' + this.generateItemKey(item, index, this.state.props),
199
- style: [this.styles.dotStyle]
200
- }) : null;
201
- }), /*#__PURE__*/React.createElement(Animated.View, {
211
+ return index >= minIndex && index <= maxIndex ? /*#__PURE__*/React.createElement(View, _extends({
212
+ key: 'dots_' + this.generateItemKey(item, index, this.state.props)
213
+ }, this.getTestPropsForAction('indicator' + index), {
214
+ style: [dotStyle]
215
+ })) : null;
216
+ }), this._showSkeleton ? null : /*#__PURE__*/React.createElement(Animated.View, {
202
217
  style: [this.styles.dotStyle, this.styles.activeDotStyle, {
203
218
  width: undefined,
204
219
  height: undefined,
@@ -220,6 +235,17 @@ export default class WmCarousel extends BaseComponent {
220
235
  }]
221
236
  }))));
222
237
  }
238
+ renderSkeleton(props) {
239
+ return /*#__PURE__*/React.createElement(View, {
240
+ style: [this.styles.root, {
241
+ ...this.styles.skeleton.root
242
+ }]
243
+ }, this.renderItem({}, 0), this.renderPagination([{}, {}, {}]));
244
+ }
245
+ componentDidMount() {
246
+ super.componentDidMount();
247
+ this.autoPlay();
248
+ }
223
249
  renderWidget(props) {
224
250
  var _data, _this$styles$slide;
225
251
  const hasNavs = props.controls === 'both' || props.controls === 'navs';
@@ -1 +1 @@
1
- {"version":3,"names":["React","isArray","isUndefined","Animated","Easing","View","DefaultKeyExtractor","WmIcon","BaseComponent","BaseComponentState","SwipeAnimation","Tappable","WmCarouselProps","DEFAULT_CLASS","WmCarouselState","constructor","args","_defineProperty","WmCarousel","props","Value","bounds","e","_this$slidesLayout","_this$slidesLayout$ac","activeTabIndex","state","activeIndex","lower","slidesLayout","filter","l","i","reduce","s","width","center","upper","computePhase","value","_this$slidesLayout$ac2","w","Math","abs","onLower","onSlideChange","onUpper","noOfSlides","_this$animationView","animationView","setPosition","index","prevIndex","updateState","invokeEventCallback","animatePagination","item","type","renderSlide","children","data","dataset","length","_this$animationView2","_this$animationView3","goToUpper","_this$animationView4","goToLower","cleanup","push","stopPlay","addSlideLayout","nativeEvent","layout","forceUpdate","generateItemKey","itemkey","_showSkeleton","keyExtractor","getKey","autoPlay","animation","animationinterval","intervalId","setInterval","next","clearInterval","setTimeout","_this$animationView5","onPropertyChange","name","$new","$old","_this$keyExtractor","clear","min","_this$styles$dotStyle","_this$styles$dotStyle2","_this$styles$dotStyle3","margin","styles","dotStyle","marginLeft","marginRight","size","position","max","scale","options","useNativeDriver","duration","easing","out","linear","sequence","timing","dotScale","toValue","parallel","dotPosition","isRTL","start","renderPagination","maxNoOfDots","maxnoofdots","minIndex","maxIndex","createElement","style","dotsWrapperStyle","flexDirection","map","key","activeDotStyle","undefined","height","transform","translateX","right","left","renderWidget","_data","_this$styles$slide","hasNavs","controls","hasDots","slideScale","slideTranslateX","slide","_this$styles$slide2","_this$styles$slide3","find","o","root","_background","enableGestures","enablegestures","flex","direction","ref","r","handlers","animationHandlers","slideMinWidth","_this$animationView6","_this$animationView7","isActive","animationPhase","interpolate","inputRange","outputRange","onLayout","bind","firstSlide","lastSlide","activeSlide","onTap","_this$animationView8","rippleColor","renderItem","btnPanel","id","getTestId","iconclass","prevBtn","prev","accessibilitylabel","nextBtn"],"sources":["carousel.component.tsx"],"sourcesContent":["import React from 'react';\nimport { isArray, isUndefined } from 'lodash-es';\nimport { Animated, Easing, View, LayoutChangeEvent, LayoutRectangle } from 'react-native';\nimport { DefaultKeyExtractor } from '@wavemaker/app-rn-runtime/core/key.extractor';\nimport WmIcon from '@wavemaker/app-rn-runtime/components/basic/icon/icon.component';\nimport { BaseComponent, BaseComponentState } from '@wavemaker/app-rn-runtime/core/base.component';\nimport * as SwipeAnimation from '@wavemaker/app-rn-runtime/gestures/swipe.animation';\nimport { Tappable } from '@wavemaker/app-rn-runtime/core/tappable.component';\n\nimport WmCarouselProps from './carousel.props';\nimport { DEFAULT_CLASS, WmCarouselStyles } from './carousel.styles';\n\nexport class WmCarouselState extends BaseComponentState<WmCarouselProps> {\n activeIndex = 1;\n}\n\nexport default class WmCarousel extends BaseComponent<WmCarouselProps, WmCarouselState, WmCarouselStyles> {\n\n noOfSlides: number = 0;\n private slidesLayout: LayoutRectangle[] = [];\n private keyExtractor = new DefaultKeyExtractor();\n stopPlay: Function = null as any;\n private dotScale = new Animated.Value(0);\n private dotPosition = new Animated.Value(0);\n private animationView: SwipeAnimation.View | null = null as any;\n private animationHandlers = {\n bounds: (e) => {\n const activeTabIndex = this.state.activeIndex - 1;\n let lower = 0;\n if (activeTabIndex > 0) {\n lower = this.slidesLayout\n .filter((l , i) => i < activeTabIndex - 1)\n .reduce((s, l) => s + l.width, 0);\n }\n let center = lower + (this.slidesLayout[activeTabIndex - 1]?.width || 0);\n let upper = center + (this.slidesLayout[activeTabIndex]?.width || 0);\n return {\n lower: -1 * lower,\n center: -1 * center,\n upper: -1 * upper\n };\n },\n computePhase: (value) => {\n const activeTabIndex = this.state.activeIndex - 1;\n const w = this.slidesLayout[activeTabIndex]?.width || 0;\n return w && Math.abs(value / w);\n },\n onLower: (e) => {\n this.onSlideChange(this.state.activeIndex - 1);\n },\n onUpper: (e) => {\n if(this.noOfSlides < this.state.activeIndex + 1){\n this.onSlideChange(1);\n this.animationView?.setPosition(0);\n }\n else{\n this.onSlideChange(this.state.activeIndex + 1);\n }\n }\n } as SwipeAnimation.Handlers;\n\n constructor(props: WmCarouselProps) {\n super(props, DEFAULT_CLASS, new WmCarouselProps(), new WmCarouselState());\n this.cleanup.push(() => {\n this.stopPlay && this.stopPlay();\n })\n }\n\n addSlideLayout(index: number, nativeEvent: LayoutChangeEvent) {\n this.slidesLayout[index] = nativeEvent.nativeEvent.layout;\n if (index === this.state.activeIndex) {\n this.forceUpdate();\n }\n }\n\n private generateItemKey(item: any, index: number, props: WmCarouselProps) {\n if (props.itemkey && item && !this._showSkeleton) {\n return props.itemkey(item, index);\n }\n return 'list_item_' + this.keyExtractor.getKey(item, true);\n }\n\n autoPlay() {\n const props = this.state.props;\n this.stopPlay && this.stopPlay();\n if (props.animation === 'auto' && props.animationinterval) {\n const intervalId = setInterval(() => {\n this.next();\n }, props.animationinterval * 1000);\n this.stopPlay = () => clearInterval(intervalId);\n } else {\n setTimeout(() => {\n this.onSlideChange(1);\n this.animationView?.setPosition(0);\n }, 1000);\n }\n }\n\n onPropertyChange(name: string, $new: any, $old: any): void {\n super.onPropertyChange(name, $new, $old);\n switch (name) {\n case 'dataset': {\n this.keyExtractor?.clear();\n this.updateState({\n activeIndex: Math.min(this.state.activeIndex, $new?.length || 1)\n } as WmCarouselState);\n break;\n }\n case 'animation':\n case 'animationinterval' : {\n this.autoPlay();\n }\n }\n }\n\n animatePagination(index: number) {\n const prevIndex = this.state.activeIndex;\n const margin = ((this.styles.dotStyle?.marginLeft as number)|| 0) + \n ((this.styles.dotStyle?.marginRight as number)|| 0)\n const width = (this.styles.dotStyle?.width as number)|| 2;\n const size = margin + width;\n const position = Math.max(index - 1, 0) * size;\n const scale = Math.abs(index - prevIndex) * size;\n const options = {\n useNativeDriver: true,\n duration: 200,\n easing: Easing.out(Easing.linear)\n };\n if (prevIndex < index) {\n Animated.sequence([\n Animated.timing(this.dotScale, {\n toValue: scale,\n ...options\n }),\n Animated.parallel([\n Animated.timing(this.dotScale, {\n toValue: 0,\n ...options\n }),\n Animated.timing(this.dotPosition, {\n toValue: (this.isRTL ? -1: 1) * position,\n ...options\n })\n ])\n ]).start();\n } else if (prevIndex > index) {\n Animated.sequence([\n Animated.parallel([\n Animated.timing(this.dotScale, {\n toValue: scale,\n ...options\n }),\n Animated.timing(this.dotPosition, {\n toValue: (this.isRTL ? -1: 1) * position,\n ...options\n })\n ]),\n Animated.timing(this.dotScale, {\n toValue: 0,\n ...options\n }),\n ]).start();\n } \n }\n\n onSlideChange = (index: number) => {\n const prevIndex = this.state.activeIndex;\n this.updateState({\n activeIndex: index\n } as WmCarouselState,\n () => this.invokeEventCallback('onChange', [this, index, prevIndex]));\n this.animatePagination(index);\n }\n\n renderItem = (item: any, index: number) => {\n const props = this.state.props;\n if (props.type === 'dynamic') {\n return props.renderSlide ? props.renderSlide(item, index, this) : null;\n }\n return props.children[index];\n }\n\n next = () => {\n const props = this.state.props;\n const data = props.type === 'dynamic' ? props.dataset : props.children;\n if (this.state.activeIndex >= data?.length || 0) {\n this.onSlideChange(1);\n this.animationView?.setPosition(0);\n } else {\n this.animationView?.goToUpper();\n }\n }\n\n prev = () => {\n this.animationView?.goToLower();\n }\n\n renderPagination(data: any) {\n const maxNoOfDots = this.state.props.maxnoofdots;\n let minIndex = Math.max(this.state.activeIndex - maxNoOfDots + 1, 0);\n let maxIndex = Math.min(minIndex + maxNoOfDots - 1, data.length);\n if (maxIndex === data.length) {\n minIndex = maxIndex - maxNoOfDots;\n }\n return (<View style={this.styles.dotsWrapperStyle}>\n <View style={{flexDirection: this.isRTL ? 'row-reverse' : 'row'}}>\n {\n data.map((item: any, index: number) => {\n return index >= minIndex && index <= maxIndex ? (\n <View key={'dots_' + this.generateItemKey(item, index, this.state.props)} \n style={[this.styles.dotStyle]}>\n </View>) : null;\n })\n }\n <Animated.View style={[\n this.styles.dotStyle,\n this.styles.activeDotStyle, {\n width: undefined,\n height: undefined,\n transform: [{\n translateX: this.dotPosition\n }]\n }, this.isRTL ? { right: 0 } : { left: 0}]}>\n <Animated.View style={[{\n width: 1,\n height: 1\n }, {\n // This is failing in Android\n // minWidth: this.dotScale\n }]}>\n </Animated.View>\n </Animated.View>\n </View>\n </View>);\n }\n\n renderWidget(props: WmCarouselProps) {\n const hasNavs = props.controls === 'both' || props.controls ==='navs';\n const hasDots = props.controls === 'both' || props.controls ==='indicators';\n let styles = this.styles;\n let data = props.type === 'dynamic' ? props.dataset : props.children;\n data = isArray(data) ? data : [];\n this.noOfSlides = data?.length || 0;\n let slideScale = undefined as any;\n let slideTranslateX = undefined as any;\n if (isArray(this.styles.slide?.transform)) {\n slideScale = (this.styles.slide?.transform?.find(o => !isUndefined((o as any).scale)) as any)?.scale;\n slideTranslateX = (this.styles.slide?.transform?.find(o => !isUndefined((o as any).translateX)) as any)?.translateX;\n }\n // TODO: loop prop on Carousel is not working Refer: https://github.com/meliorence/react-native-snap-carousel/issues/608\n return (\n <View style={styles.root}>\n {this._background}\n <SwipeAnimation.View \n enableGestures={props.enablegestures && this.noOfSlides > 1}\n style={{\n flex: 1\n }}\n direction='horizontal'\n ref={(r) => {this.animationView = r}}\n handlers = {this.animationHandlers}\n slideMinWidth={this.styles.slide.width}\n >\n {data.map((item: any, index: number) => {\n const isActive = index === this.state.activeIndex - 1;\n let scale = this.animationView?.animationPhase.interpolate({\n inputRange: [-2000, index - 1, index, index + 1, 2000],\n outputRange: [slideScale, slideScale, 1, slideScale, slideScale]\n });\n let translateX = this.animationView?.animationPhase.interpolate({\n inputRange: [-2000, index - 1, index, index + 1, 2000],\n outputRange: [-56, -56, 0, 56, 56]\n });\n return (\n <Animated.View key={this.generateItemKey(item, index, props)}\n onLayout={this.addSlideLayout.bind(this, index)}\n style={[\n {height: props.type === 'dynamic' ? undefined : '100%'},\n this.styles.slide,\n index === 0 ? this.styles.firstSlide : null,\n index === data.length - 1 ? this.styles.lastSlide: null,\n isActive ? this.styles.activeSlide: null,\n translateX && scale ? {\n transform: [\n {\n translateX: !isUndefined(slideTranslateX) ? slideTranslateX : translateX\n }, {\n scale: scale\n }\n ]\n } : null]}>\n <Tappable onTap={() => {\n this.onSlideChange(index + 1);\n const position = this.slidesLayout\n .filter((l , i) => i < index)\n .reduce((s, l) => s + l.width, 0);\n this.animationView?.setPosition(-1 * position);\n }} rippleColor={this.styles.root.rippleColor} styles={{height: \"100%\"}}>\n {this.renderItem(item, index)}\n </Tappable>\n </Animated.View>\n );\n })}\n </SwipeAnimation.View>\n {hasNavs ? (\n <View style={styles.btnPanel}>\n <WmIcon\n id={this.getTestId('prev_icon')}\n iconclass=\"wi wi-chevron-left fa-2x\"\n styles={styles.prevBtn}\n onTap={this.prev}\n accessibilitylabel='back'/>\n <WmIcon\n id={this.getTestId('next_icon')}\n iconclass=\"wi wi-chevron-right fa-2x\"\n styles={styles.nextBtn}\n onTap={this.next}\n accessibilitylabel='next'/>\n </View>): null}\n {hasDots && data ? this.renderPagination(data) : null}\n </View>);\n }\n}\n"],"mappings":";;;AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,SAASC,OAAO,EAAEC,WAAW,QAAQ,WAAW;AAChD,SAASC,QAAQ,EAAEC,MAAM,EAAEC,IAAI,QAA4C,cAAc;AACzF,SAASC,mBAAmB,QAAQ,8CAA8C;AAClF,OAAOC,MAAM,MAAM,gEAAgE;AACnF,SAASC,aAAa,EAAEC,kBAAkB,QAAQ,+CAA+C;AACjG,OAAO,KAAKC,cAAc,MAAM,oDAAoD;AACpF,SAASC,QAAQ,QAAQ,mDAAmD;AAE5E,OAAOC,eAAe,MAAM,kBAAkB;AAC9C,SAASC,aAAa,QAA0B,mBAAmB;AAEnE,OAAO,MAAMC,eAAe,SAASL,kBAAkB,CAAkB;EAAAM,YAAA,GAAAC,IAAA;IAAA,SAAAA,IAAA;IAAAC,eAAA,sBACzD,CAAC;EAAA;AACjB;AAEA,eAAe,MAAMC,UAAU,SAASV,aAAa,CAAqD;EA6CxGO,WAAWA,CAACI,MAAsB,EAAE;IAClC,KAAK,CAACA,MAAK,EAAEN,aAAa,EAAE,IAAID,eAAe,CAAC,CAAC,EAAE,IAAIE,eAAe,CAAC,CAAC,CAAC;IAACG,eAAA,qBA5CvD,CAAC;IAAAA,eAAA,uBACoB,EAAE;IAAAA,eAAA,uBACrB,IAAIX,mBAAmB,CAAC,CAAC;IAAAW,eAAA,mBAC3B,IAAI;IAAAA,eAAA,mBACN,IAAId,QAAQ,CAACiB,KAAK,CAAC,CAAC,CAAC;IAAAH,eAAA,sBAClB,IAAId,QAAQ,CAACiB,KAAK,CAAC,CAAC,CAAC;IAAAH,eAAA,wBACS,IAAI;IAAAA,eAAA,4BAC5B;MAC1BI,MAAM,EAAGC,CAAC,IAAK;QAAA,IAAAC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,CAAC1H,IAAI;MAAC2H,KAAK,EAAE5B,MAAM,CAACgF;IAAS,gBAC3BpL,KAAA,CAAA+H,aAAA,CAACxH,MAAM;MACL8K,EAAE,EAAE,IAAI,CAACC,SAAS,CAAC,WAAW,CAAE;MAChCC,SAAS,EAAC,0BAA0B;MACpCnF,MAAM,EAAEA,MAAM,CAACoF,OAAQ;MACvBR,KAAK,EAAE,IAAI,CAACS,IAAK;MACjBC,kBAAkB,EAAC;IAAM,CAAC,CAAC,eAC7B1L,KAAA,CAAA+H,aAAA,CAACxH,MAAM;MACL8K,EAAE,EAAE,IAAI,CAACC,SAAS,CAAC,WAAW,CAAE;MAChCC,SAAS,EAAC,2BAA2B;MACrCnF,MAAM,EAAEA,MAAM,CAACuF,OAAQ;MACvBX,KAAK,EAAE,IAAI,CAAC3F,IAAK;MACjBqG,kBAAkB,EAAC;IAAM,CAAC,CACxB,CAAC,GAAG,IAAI,EACbzC,OAAO,IAAIrF,IAAI,GAAG,IAAI,CAAC8D,gBAAgB,CAAC9D,IAAI,CAAC,GAAG,IAC/C,CAAC;EACX;AACF","ignoreList":[]}
1
+ {"version":3,"names":["React","isArray","isUndefined","Animated","Easing","View","DefaultKeyExtractor","WmIcon","BaseComponent","BaseComponentState","SwipeAnimation","Tappable","WmCarouselProps","DEFAULT_CLASS","WmCarouselState","constructor","args","_defineProperty","WmCarousel","props","Value","bounds","e","_this$slidesLayout","_this$slidesLayout$ac","activeTabIndex","state","activeIndex","lower","slidesLayout","filter","l","i","reduce","s","width","center","upper","computePhase","value","_this$slidesLayout$ac2","w","Math","abs","onLower","onSlideChange","onUpper","noOfSlides","_this$animationView","animationView","setPosition","index","prevIndex","updateState","invokeEventCallback","animatePagination","item","type","renderSlide","children","data","dataset","length","_this$animationView2","_this$animationView3","goToUpper","_this$animationView4","goToLower","cleanup","push","stopPlay","addSlideLayout","nativeEvent","layout","forceUpdate","generateItemKey","itemkey","_showSkeleton","keyExtractor","getKey","autoPlay","initialized","animation","animationinterval","intervalId","setInterval","next","clearInterval","setTimeout","_this$animationView5","stopAnimation","startAnimation","onPropertyChange","name","$new","$old","_this$keyExtractor","clear","min","_this$styles$dotStyle","_this$styles$dotStyle2","_this$styles$dotStyle3","margin","styles","dotStyle","marginLeft","marginRight","size","position","max","scale","options","useNativeDriver","duration","easing","out","linear","sequence","timing","dotScale","toValue","parallel","dotPosition","isRTL","start","renderPagination","maxNoOfDots","maxnoofdots","minIndex","maxIndex","dotSkeleton","root","createElement","style","dotsWrapperStyle","flexDirection","map","_extends","key","getTestPropsForAction","activeDotStyle","undefined","height","transform","translateX","right","left","renderSkeleton","skeleton","renderItem","componentDidMount","renderWidget","_data","_this$styles$slide","hasNavs","controls","hasDots","slideScale","slideTranslateX","slide","_this$styles$slide2","_this$styles$slide3","find","o","_background","enableGestures","enablegestures","flex","direction","ref","r","handlers","animationHandlers","slideMinWidth","_this$animationView6","_this$animationView7","isActive","animationPhase","interpolate","inputRange","outputRange","onLayout","bind","firstSlide","lastSlide","activeSlide","onTap","_this$animationView8","rippleColor","btnPanel","id","getTestId","iconclass","prevBtn","prev","accessibilitylabel","nextBtn"],"sources":["carousel.component.tsx"],"sourcesContent":["import React from 'react';\nimport { isArray, isUndefined } from 'lodash-es';\nimport { Animated, Easing, View, LayoutChangeEvent, LayoutRectangle } from 'react-native';\nimport { DefaultKeyExtractor } from '@wavemaker/app-rn-runtime/core/key.extractor';\nimport WmIcon from '@wavemaker/app-rn-runtime/components/basic/icon/icon.component';\nimport { BaseComponent, BaseComponentState } from '@wavemaker/app-rn-runtime/core/base.component';\nimport * as SwipeAnimation from '@wavemaker/app-rn-runtime/gestures/swipe.animation';\nimport { Tappable } from '@wavemaker/app-rn-runtime/core/tappable.component';\n\nimport WmCarouselProps from './carousel.props';\nimport { DEFAULT_CLASS, WmCarouselStyles } from './carousel.styles';\nimport { createSkeleton } from '@wavemaker/app-rn-runtime/components/basic/skeleton/skeleton.component';\n\nexport class WmCarouselState extends BaseComponentState<WmCarouselProps> {\n activeIndex = 1;\n}\n\nexport default class WmCarousel extends BaseComponent<WmCarouselProps, WmCarouselState, WmCarouselStyles> {\n\n noOfSlides: number = 0;\n private slidesLayout: LayoutRectangle[] = [];\n private keyExtractor = new DefaultKeyExtractor();\n stopPlay: Function = null as any;\n private dotScale = new Animated.Value(0);\n private dotPosition = new Animated.Value(0);\n private animationView: SwipeAnimation.View | null = null as any;\n private animationHandlers = {\n bounds: (e) => {\n const activeTabIndex = this.state.activeIndex - 1;\n let lower = 0;\n if (activeTabIndex > 0) {\n lower = this.slidesLayout\n .filter((l , i) => i < activeTabIndex - 1)\n .reduce((s, l) => s + l.width, 0);\n }\n let center = lower + (this.slidesLayout[activeTabIndex - 1]?.width || 0);\n let upper = center + (this.slidesLayout[activeTabIndex]?.width || 0);\n return {\n lower: -1 * lower,\n center: -1 * center,\n upper: -1 * upper\n };\n },\n computePhase: (value) => {\n const activeTabIndex = this.state.activeIndex - 1;\n const w = this.slidesLayout[activeTabIndex]?.width || 0;\n return w && Math.abs(value / w);\n },\n onLower: (e) => {\n this.onSlideChange(this.state.activeIndex - 1);\n },\n onUpper: (e) => {\n if(this.noOfSlides < this.state.activeIndex + 1){\n this.onSlideChange(1);\n this.animationView?.setPosition(0);\n }\n else{\n this.onSlideChange(this.state.activeIndex + 1);\n }\n }\n } as SwipeAnimation.Handlers;\n\n constructor(props: WmCarouselProps) {\n super(props, DEFAULT_CLASS, new WmCarouselProps(), new WmCarouselState());\n this.cleanup.push(() => {\n this.stopPlay && this.stopPlay();\n })\n }\n\n addSlideLayout(index: number, nativeEvent: LayoutChangeEvent) {\n this.slidesLayout[index] = nativeEvent.nativeEvent.layout;\n if (index === this.state.activeIndex) {\n this.forceUpdate();\n }\n }\n\n private generateItemKey(item: any, index: number, props: WmCarouselProps) {\n if (props.itemkey && item && !this._showSkeleton) {\n return props.itemkey(item, index);\n }\n return 'list_item_' + this.keyExtractor.getKey(item, true);\n }\n\n autoPlay() {\n if(!this.initialized){\n return;\n }\n const props = this.state.props;\n this.stopPlay && this.stopPlay();\n if (props.animation === 'auto' && props.animationinterval) {\n const intervalId = setInterval(() => {\n this.next();\n }, props.animationinterval * 1000);\n this.stopPlay = () => clearInterval(intervalId);\n } else {\n setTimeout(() => {\n this.onSlideChange(1);\n this.animationView?.setPosition(0);\n }, 1000);\n }\n }\n\n stopAnimation(){ \n this.stopPlay();\n }\n startAnimation() {\n this.autoPlay();\n }\n \n\n onPropertyChange(name: string, $new: any, $old: any): void {\n super.onPropertyChange(name, $new, $old);\n switch (name) {\n case 'dataset': {\n this.keyExtractor?.clear();\n this.updateState({\n activeIndex: Math.min(this.state.activeIndex, $new?.length || 1)\n } as WmCarouselState);\n break;\n }\n case 'animation':\n case 'animationinterval' : {\n this.autoPlay();\n }\n }\n }\n\n animatePagination(index: number) {\n const prevIndex = this.state.activeIndex;\n const margin = ((this.styles.dotStyle?.marginLeft as number)|| 0) + \n ((this.styles.dotStyle?.marginRight as number)|| 0)\n const width = (this.styles.dotStyle?.width as number)|| 2;\n const size = margin + width;\n const position = Math.max(index - 1, 0) * size;\n const scale = Math.abs(index - prevIndex) * size;\n const options = {\n useNativeDriver: true,\n duration: 200,\n easing: Easing.out(Easing.linear)\n };\n if (prevIndex < index) {\n Animated.sequence([\n Animated.timing(this.dotScale, {\n toValue: scale,\n ...options\n }),\n Animated.parallel([\n Animated.timing(this.dotScale, {\n toValue: 0,\n ...options\n }),\n Animated.timing(this.dotPosition, {\n toValue: (this.isRTL ? -1: 1) * position,\n ...options\n })\n ])\n ]).start();\n } else if (prevIndex > index) {\n Animated.sequence([\n Animated.parallel([\n Animated.timing(this.dotScale, {\n toValue: scale,\n ...options\n }),\n Animated.timing(this.dotPosition, {\n toValue: (this.isRTL ? -1: 1) * position,\n ...options\n })\n ]),\n Animated.timing(this.dotScale, {\n toValue: 0,\n ...options\n }),\n ]).start();\n } \n }\n\n onSlideChange = (index: number) => {\n const prevIndex = this.state.activeIndex;\n this.updateState({\n activeIndex: index\n } as WmCarouselState,\n () => this.invokeEventCallback('onChange', [this, index, prevIndex]));\n this.animatePagination(index);\n }\n\n renderItem = (item: any, index: number) => {\n const props = this.state.props;\n if (props.type === 'dynamic') {\n return props.renderSlide ? props.renderSlide(item, index, this) : null;\n }\n return props.children[index];\n }\n\n next = () => {\n const props = this.state.props;\n const data = props.type === 'dynamic' ? props.dataset : props.children;\n if (this.state.activeIndex >= data?.length || 0) {\n this.onSlideChange(1);\n this.animationView?.setPosition(0);\n } else {\n this.animationView?.goToUpper();\n }\n }\n\n prev = () => {\n this.animationView?.goToLower();\n }\n\n renderPagination(data: any) {\n const maxNoOfDots = this.state.props.maxnoofdots;\n let minIndex = Math.max(this.state.activeIndex - maxNoOfDots + 1, 0);\n let maxIndex = Math.min(minIndex + maxNoOfDots - 1, data.length);\n if (maxIndex === data.length) {\n minIndex = maxIndex - maxNoOfDots;\n }\n const dotStyle = this._showSkeleton ? {\n ...this.styles.dotStyle,\n ...this.styles.dotSkeleton.root\n } : this.styles.dotStyle\n return (<View style={this.styles.dotsWrapperStyle}>\n <View style={{flexDirection: this.isRTL ? 'row-reverse' : 'row'}}>\n {\n data.map((item: any, index: number) => {\n return index >= minIndex && index <= maxIndex ? (\n <View key={'dots_' + this.generateItemKey(item, index, this.state.props)} {...this.getTestPropsForAction('indicator'+index)}\n style={[dotStyle]}>\n </View>) : null;\n })\n }\n {\n this._showSkeleton ? null : <Animated.View style={[\n this.styles.dotStyle,\n this.styles.activeDotStyle, {\n width: undefined,\n height: undefined,\n transform: [{\n translateX: this.dotPosition\n }]\n }, this.isRTL ? { right: 0 } : { left: 0}]}>\n <Animated.View style={[{\n width: 1,\n height: 1\n }, {\n // This is failing in Android\n // minWidth: this.dotScale\n }]}>\n </Animated.View>\n </Animated.View>\n }\n </View>\n </View>);\n }\n\n public renderSkeleton(props: WmCarouselProps): React.ReactNode | null {\n return <View style={[this.styles.root, {...this.styles.skeleton.root}]}>\n {this.renderItem({}, 0)}\n {this.renderPagination([{}, {}, {}])}\n </View>\n }\n\n componentDidMount(): void {\n super.componentDidMount();\n this.autoPlay();\n }\n\n renderWidget(props: WmCarouselProps) {\n const hasNavs = props.controls === 'both' || props.controls ==='navs';\n const hasDots = props.controls === 'both' || props.controls ==='indicators';\n let styles = this.styles;\n let data = props.type === 'dynamic' ? props.dataset : props.children;\n data = isArray(data) ? data : [];\n this.noOfSlides = data?.length || 0;\n let slideScale = undefined as any;\n let slideTranslateX = undefined as any;\n if (isArray(this.styles.slide?.transform)) {\n slideScale = (this.styles.slide?.transform?.find(o => !isUndefined((o as any).scale)) as any)?.scale;\n slideTranslateX = (this.styles.slide?.transform?.find(o => !isUndefined((o as any).translateX)) as any)?.translateX;\n }\n // TODO: loop prop on Carousel is not working Refer: https://github.com/meliorence/react-native-snap-carousel/issues/608\n return (\n <View style={styles.root}>\n {this._background}\n <SwipeAnimation.View \n enableGestures={props.enablegestures && this.noOfSlides > 1}\n style={{\n flex: 1\n }}\n direction='horizontal'\n ref={(r) => {this.animationView = r}}\n handlers = {this.animationHandlers}\n slideMinWidth={this.styles.slide.width}\n >\n {data.map((item: any, index: number) => {\n const isActive = index === this.state.activeIndex - 1;\n let scale = this.animationView?.animationPhase.interpolate({\n inputRange: [-2000, index - 1, index, index + 1, 2000],\n outputRange: [slideScale, slideScale, 1, slideScale, slideScale]\n });\n let translateX = this.animationView?.animationPhase.interpolate({\n inputRange: [-2000, index - 1, index, index + 1, 2000],\n outputRange: [-56, -56, 0, 56, 56]\n });\n return (\n <Animated.View key={this.generateItemKey(item, index, props)}\n onLayout={this.addSlideLayout.bind(this, index)}\n style={[\n {height: props.type === 'dynamic' ? undefined : '100%'},\n this.styles.slide,\n index === 0 ? this.styles.firstSlide : null,\n index === data.length - 1 ? this.styles.lastSlide: null,\n isActive ? this.styles.activeSlide: null,\n translateX && scale ? {\n transform: [\n {\n translateX: !isUndefined(slideTranslateX) ? slideTranslateX : translateX\n }, {\n scale: scale\n }\n ]\n } : null]}>\n <Tappable onTap={() => {\n this.onSlideChange(index + 1);\n const position = this.slidesLayout\n .filter((l , i) => i < index)\n .reduce((s, l) => s + l.width, 0);\n this.animationView?.setPosition(-1 * position);\n }} rippleColor={this.styles.root.rippleColor} styles={{height: \"100%\"}}>\n {this.renderItem(item, index)}\n </Tappable>\n </Animated.View>\n );\n })}\n </SwipeAnimation.View>\n {hasNavs ? (\n <View style={styles.btnPanel}>\n <WmIcon\n id={this.getTestId('prev_icon')}\n iconclass=\"wi wi-chevron-left fa-2x\"\n styles={styles.prevBtn}\n onTap={this.prev}\n accessibilitylabel='back'/>\n <WmIcon\n id={this.getTestId('next_icon')}\n iconclass=\"wi wi-chevron-right fa-2x\"\n styles={styles.nextBtn}\n onTap={this.next}\n accessibilitylabel='next'/>\n </View>): null}\n {hasDots && data ? this.renderPagination(data) : null}\n </View>);\n }\n}\n"],"mappings":";;;;AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,SAASC,OAAO,EAAEC,WAAW,QAAQ,WAAW;AAChD,SAASC,QAAQ,EAAEC,MAAM,EAAEC,IAAI,QAA4C,cAAc;AACzF,SAASC,mBAAmB,QAAQ,8CAA8C;AAClF,OAAOC,MAAM,MAAM,gEAAgE;AACnF,SAASC,aAAa,EAAEC,kBAAkB,QAAQ,+CAA+C;AACjG,OAAO,KAAKC,cAAc,MAAM,oDAAoD;AACpF,SAASC,QAAQ,QAAQ,mDAAmD;AAE5E,OAAOC,eAAe,MAAM,kBAAkB;AAC9C,SAASC,aAAa,QAA0B,mBAAmB;AAGnE,OAAO,MAAMC,eAAe,SAASL,kBAAkB,CAAkB;EAAAM,YAAA,GAAAC,IAAA;IAAA,SAAAA,IAAA;IAAAC,eAAA,sBACzD,CAAC;EAAA;AACjB;AAEA,eAAe,MAAMC,UAAU,SAASV,aAAa,CAAqD;EA6CxGO,WAAWA,CAACI,MAAsB,EAAE;IAClC,KAAK,CAACA,MAAK,EAAEN,aAAa,EAAE,IAAID,eAAe,CAAC,CAAC,EAAE,IAAIE,eAAe,CAAC,CAAC,CAAC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AAC7F,IAAI,EAAEL,KAAK,CACpB,CACG,CAAC;IAEpB,CAAC,CACkB,CAAC,EACrBuG,OAAO,gBACN1J,KAAA,CAAAoI,aAAA,CAAC/H,IAAI;MAACgI,KAAK,EAAE9B,MAAM,CAACsF;IAAS,gBAC3B7L,KAAA,CAAAoI,aAAA,CAAC7H,MAAM;MACLuL,EAAE,EAAE,IAAI,CAACC,SAAS,CAAC,WAAW,CAAE;MAChCC,SAAS,EAAC,0BAA0B;MACpCzF,MAAM,EAAEA,MAAM,CAAC0F,OAAQ;MACvBP,KAAK,EAAE,IAAI,CAACQ,IAAK;MACjBC,kBAAkB,EAAC;IAAM,CAAC,CAAC,eAC7BnM,KAAA,CAAAoI,aAAA,CAAC7H,MAAM;MACLuL,EAAE,EAAE,IAAI,CAACC,SAAS,CAAC,WAAW,CAAE;MAChCC,SAAS,EAAC,2BAA2B;MACrCzF,MAAM,EAAEA,MAAM,CAAC6F,OAAQ;MACvBV,KAAK,EAAE,IAAI,CAACpG,IAAK;MACjB6G,kBAAkB,EAAC;IAAM,CAAC,CACxB,CAAC,GAAG,IAAI,EACbvC,OAAO,IAAIhG,IAAI,GAAG,IAAI,CAACiE,gBAAgB,CAACjE,IAAI,CAAC,GAAG,IAC/C,CAAC;EACX;AACF","ignoreList":[]}
@@ -15,6 +15,7 @@ export default class WmCarouselProps extends BaseProps {
15
15
  _defineProperty(this, "renderSlide", void 0);
16
16
  _defineProperty(this, "enablegestures", true);
17
17
  _defineProperty(this, "maxnoofdots", 20);
18
+ _defineProperty(this, "showskeletonchildren", false);
18
19
  }
19
20
  }
20
21
  //# sourceMappingURL=carousel.props.js.map
@@ -1 +1 @@
1
- {"version":3,"names":["BaseProps","WmCarouselProps","constructor","args","_defineProperty"],"sources":["carousel.props.ts"],"sourcesContent":["import { BaseProps } from '@wavemaker/app-rn-runtime/core/base.component';\nimport React from 'react';\n\nexport default class WmCarouselProps extends BaseProps {\n dataset: any = null;\n type?: 'static' | 'dynamic' = 'static';\n animation?: 'auto' | 'none' = 'auto';\n animationinterval?: number = 3;\n controls?: 'both' | 'none' | 'navs' | 'indicators' = 'both';\n children? = null as any;\n itemkey?: ($item: any, $index: any) => any = null as any;\n renderSlide?: ($item: any, $index: number, carousel: any) => React.ReactNode;\n enablegestures = true;\n maxnoofdots = 20;\n}"],"mappings":";;;AAAA,SAASA,SAAS,QAAQ,+CAA+C;AAGzE,eAAe,MAAMC,eAAe,SAASD,SAAS,CAAC;EAAAE,YAAA,GAAAC,IAAA;IAAA,SAAAA,IAAA;IAAAC,eAAA,kBACtC,IAAI;IAAAA,eAAA,eACW,QAAQ;IAAAA,eAAA,oBACR,MAAM;IAAAA,eAAA,4BACP,CAAC;IAAAA,eAAA,mBACuB,MAAM;IAAAA,eAAA,mBAC/C,IAAI;IAAAA,eAAA,kBAC6B,IAAI;IAAAA,eAAA;IAAAA,eAAA,yBAE/B,IAAI;IAAAA,eAAA,sBACR,EAAE;EAAA;AAClB","ignoreList":[]}
1
+ {"version":3,"names":["BaseProps","WmCarouselProps","constructor","args","_defineProperty"],"sources":["carousel.props.ts"],"sourcesContent":["import { BaseProps } from '@wavemaker/app-rn-runtime/core/base.component';\nimport React from 'react';\n\nexport default class WmCarouselProps extends BaseProps {\n dataset: any = null;\n type?: 'static' | 'dynamic' = 'static';\n animation?: 'auto' | 'none' = 'auto';\n animationinterval?: number = 3;\n controls?: 'both' | 'none' | 'navs' | 'indicators' = 'both';\n children? = null as any;\n itemkey?: ($item: any, $index: any) => any = null as any;\n renderSlide?: ($item: any, $index: number, carousel: any) => React.ReactNode;\n enablegestures = true;\n maxnoofdots = 20;\n showskeletonchildren?: boolean = false;\n}"],"mappings":";;;AAAA,SAASA,SAAS,QAAQ,+CAA+C;AAGzE,eAAe,MAAMC,eAAe,SAASD,SAAS,CAAC;EAAAE,YAAA,GAAAC,IAAA;IAAA,SAAAA,IAAA;IAAAC,eAAA,kBACtC,IAAI;IAAAA,eAAA,eACW,QAAQ;IAAAA,eAAA,oBACR,MAAM;IAAAA,eAAA,4BACP,CAAC;IAAAA,eAAA,mBACuB,MAAM;IAAAA,eAAA,mBAC/C,IAAI;IAAAA,eAAA,kBAC6B,IAAI;IAAAA,eAAA;IAAAA,eAAA,yBAE/B,IAAI;IAAAA,eAAA,sBACR,EAAE;IAAAA,eAAA,+BACiB,KAAK;EAAA;AACxC","ignoreList":[]}
@@ -88,6 +88,21 @@ BASE_THEME.registerStyle((themeVariables, addStyle) => {
88
88
  marginLeft: 2,
89
89
  marginRight: 2,
90
90
  backgroundColor: themeVariables.carouselDotColor
91
+ },
92
+ skeleton: {
93
+ root: {
94
+ width: '100%'
95
+ },
96
+ text: {}
97
+ },
98
+ dotSkeleton: {
99
+ root: {
100
+ width: 10,
101
+ height: 10,
102
+ borderRadius: 5,
103
+ opacity: 1,
104
+ backgroundColor: themeVariables.skeletonAnimatedBgColor
105
+ }
91
106
  }
92
107
  });
93
108
  addStyle(DEFAULT_CLASS, '', defaultStyles);
@@ -1 +1 @@
1
- {"version":3,"names":["BASE_THEME","defineStyles","DEFAULT_CLASS","registerStyle","themeVariables","addStyle","btn","height","width","borderRadius","borderColor","transparent","borderWidth","justifyContent","defaultStyles","root","position","rippleColor","text","slide","overflow","paddingHorizontal","transform","scale","firstSlide","lastSlide","activeSlide","btnPanel","top","marginTop","flexDirection","alignItems","prevBtn","marginLeft","backgroundColor","carouselPrevBgColor","fontSize","icon","color","carouselPrevBtnColor","nextBtn","marginRight","carouselNextBtnColor","dotsWrapperStyle","opacity","carouselDotWrapperBgColor","paddingTop","paddingBottom","activeDotStyle","carouselActiveDotColor","padding","dotStyle","carouselDotColor","rotateY","defaultColorF","right","alignSelf","primaryColor"],"sources":["carousel.styles.ts"],"sourcesContent":["import { ViewStyle } from 'react-native';\nimport BASE_THEME, { AllStyle } from '@wavemaker/app-rn-runtime/styles/theme';\nimport { BaseStyles, defineStyles } from '@wavemaker/app-rn-runtime/core/base.component';\nimport { WmIconStyles } from '@wavemaker/app-rn-runtime/components/basic/icon/icon.styles';\n\nexport type WmCarouselStyles = BaseStyles & {\n btnPanel: AllStyle,\n prevBtn: WmIconStyles,\n slide: AllStyle,\n firstSlide: AllStyle,\n lastSlide: AllStyle,\n activeSlide: AllStyle,\n nextBtn: WmIconStyles,\n dotsWrapperStyle: AllStyle,\n dotStyle: AllStyle,\n activeDotStyle: AllStyle\n};\nexport const DEFAULT_CLASS = 'app-carousel';\nBASE_THEME.registerStyle((themeVariables, addStyle) => {\n const btn: ViewStyle = {\n height: 48,\n width: 48,\n borderRadius: 48,\n borderColor: themeVariables.transparent,\n borderWidth: 1,\n justifyContent: 'center'\n };\n const defaultStyles: WmCarouselStyles = defineStyles({\n root: {\n position: 'relative',\n rippleColor: themeVariables.transparent\n },\n text: {},\n slide: {\n width: '100%',\n overflow: 'hidden',\n paddingHorizontal: 16,\n transform: [\n {\n scale: 0.8\n }\n ]\n },\n firstSlide: {},\n lastSlide: {},\n activeSlide: {},\n btnPanel: {\n position: 'absolute',\n top: '50%',\n marginTop: -64,\n height: 64,\n flexDirection: 'row',\n alignItems: 'center',\n justifyContent: 'space-between',\n width: '100%'\n },\n prevBtn : {\n root: {\n marginLeft: 12,\n ...btn,\n backgroundColor: themeVariables.carouselPrevBgColor,\n rippleColor: themeVariables.transparent\n },\n text: {\n fontSize: 32\n },\n icon : {\n color: themeVariables.carouselPrevBtnColor\n }\n } as WmIconStyles,\n nextBtn : {\n root: {\n marginRight: 12,\n ...btn,\n backgroundColor: themeVariables.carouselPrevBgColor,\n rippleColor: themeVariables.transparent\n },\n text: {\n fontSize: 32\n },\n icon : {\n color: themeVariables.carouselNextBtnColor\n }\n } as WmIconStyles,\n dotsWrapperStyle:{\n opacity: 1,\n backgroundColor: themeVariables.carouselDotWrapperBgColor,\n flexDirection: 'row',\n justifyContent: 'center',\n alignItems: 'center',\n paddingTop: 4,\n paddingBottom: 4\n },\n activeDotStyle: {\n position: 'absolute',\n backgroundColor: themeVariables.carouselActiveDotColor,\n opacity: 1,\n padding: 4\n },\n dotStyle: {\n width: 8,\n height: 8,\n borderRadius: 10,\n opacity: 0.2,\n marginLeft: 2,\n marginRight: 2,\n backgroundColor: themeVariables.carouselDotColor\n }\n } as WmCarouselStyles);\n\n addStyle(DEFAULT_CLASS, '', defaultStyles);\n addStyle(DEFAULT_CLASS + '-rtl', '', {\n prevBtn : {\n root:{\n transform: [{rotateY: '180deg'}]\n }\n },\n nextBtn : {\n root:{\n transform: [{rotateY: '180deg'}]\n }\n }\n });\n\n addStyle('app-carousel-1', '', {\n btnPanel: {\n top: '100%'\n },\n prevBtn: {\n root: {\n borderRadius: 6\n }\n },\n nextBtn: {\n root: {\n borderRadius: 6\n }\n }\n } as any as WmCarouselStyles);\n\n addStyle('app-carousel-2', '', {\n btnPanel: {\n backgroundColor: themeVariables.defaultColorF,\n width: '100%',\n top: '100%',\n right: 0,\n padding: 8,\n justifyContent: 'flex-end'\n },\n dotsWrapperStyle:{\n alignSelf: 'flex-start',\n justifyContent: 'flex-start'\n },\n activeDotStyle: {\n backgroundColor: themeVariables.primaryColor,\n },\n dotStyle: {\n backgroundColor: themeVariables.primaryColor,\n },\n prevBtn: {\n root: {\n backgroundColor: 'rgba(255, 255, 255, 0.1)',\n borderColor: themeVariables.primaryColor,\n },\n icon : {\n color: themeVariables.primaryColor\n }\n },\n nextBtn: {\n root: {\n marginLeft: 8,\n backgroundColor: 'rgba(255, 255, 255, 0.1)',\n borderColor: themeVariables.primaryColor,\n },\n icon : {\n color: themeVariables.primaryColor\n }\n }\n } as any as WmCarouselStyles);\n});"],"mappings":"AACA,OAAOA,UAAU,MAAoB,wCAAwC;AAC7E,SAAqBC,YAAY,QAAQ,+CAA+C;AAexF,OAAO,MAAMC,aAAa,GAAG,cAAc;AAC3CF,UAAU,CAACG,aAAa,CAAC,CAACC,cAAc,EAAEC,QAAQ,KAAK;EACnD,MAAMC,GAAc,GAAG;IACnBC,MAAM,EAAE,EAAE;IACVC,KAAK,EAAE,EAAE;IACTC,YAAY,EAAE,EAAE;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EAAE;MACLzB,IAAI,EAAE;QACFN,YAAY,EAAE;MAClB;IACJ;EACJ,CAA4B,CAAC;EAE7BJ,QAAQ,CAAC,gBAAgB,EAAE,EAAE,EAAE;IAC3BsB,QAAQ,EAAE;MACNO,eAAe,EAAE9B,cAAc,CAACkD,aAAa;MAC7C9C,KAAK,EAAE,MAAM;MACboB,GAAG,EAAE,MAAM;MACX2B,KAAK,EAAE,CAAC;MACRL,OAAO,EAAE,CAAC;MACVrC,cAAc,EAAE;IACpB,CAAC;IACD8B,gBAAgB,EAAC;MACba,SAAS,EAAE,YAAY;MACvB3C,cAAc,EAAE;IACpB,CAAC;IACDmC,cAAc,EAAE;MACZd,eAAe,EAAE9B,cAAc,CAACqD;IACpC,CAAC;IACDN,QAAQ,EAAE;MACNjB,eAAe,EAAE9B,cAAc,CAACqD;IACpC,CAAC;IACDzB,OAAO,EAAE;MACLjB,IAAI,EAAE;QACFmB,eAAe,EAAE,0BAA0B;QAC3CxB,WAAW,EAAEN,cAAc,CAACqD;MAChC,CAAC;MACDpB,IAAI,EAAG;QACHC,KAAK,EAAElC,cAAc,CAACqD;MAC1B;IACJ,CAAC;IACDjB,OAAO,EAAE;MACLzB,IAAI,EAAE;QACFkB,UAAU,EAAE,CAAC;QACbC,eAAe,EAAE,0BAA0B;QAC3CxB,WAAW,EAAEN,cAAc,CAACqD;MAChC,CAAC;MACDpB,IAAI,EAAG;QACHC,KAAK,EAAElC,cAAc,CAACqD;MAC1B;IACJ;EACJ,CAA4B,CAAC;AACjC,CAAC,CAAC","ignoreList":[]}
1
+ {"version":3,"names":["BASE_THEME","defineStyles","DEFAULT_CLASS","registerStyle","themeVariables","addStyle","btn","height","width","borderRadius","borderColor","transparent","borderWidth","justifyContent","defaultStyles","root","position","rippleColor","text","slide","overflow","paddingHorizontal","transform","scale","firstSlide","lastSlide","activeSlide","btnPanel","top","marginTop","flexDirection","alignItems","prevBtn","marginLeft","backgroundColor","carouselPrevBgColor","fontSize","icon","color","carouselPrevBtnColor","nextBtn","marginRight","carouselNextBtnColor","dotsWrapperStyle","opacity","carouselDotWrapperBgColor","paddingTop","paddingBottom","activeDotStyle","carouselActiveDotColor","padding","dotStyle","carouselDotColor","skeleton","dotSkeleton","skeletonAnimatedBgColor","rotateY","defaultColorF","right","alignSelf","primaryColor"],"sources":["carousel.styles.ts"],"sourcesContent":["import { ViewStyle } from 'react-native';\nimport BASE_THEME, { AllStyle } from '@wavemaker/app-rn-runtime/styles/theme';\nimport { BaseStyles, defineStyles } from '@wavemaker/app-rn-runtime/core/base.component';\nimport { WmIconStyles } from '@wavemaker/app-rn-runtime/components/basic/icon/icon.styles';\nimport { WmSkeletonStyles } from '@wavemaker/app-rn-runtime/components/basic/skeleton/skeleton.styles';\n\nexport type WmCarouselStyles = BaseStyles & {\n btnPanel: AllStyle,\n prevBtn: WmIconStyles,\n slide: AllStyle,\n firstSlide: AllStyle,\n lastSlide: AllStyle,\n activeSlide: AllStyle,\n nextBtn: WmIconStyles,\n dotsWrapperStyle: AllStyle,\n dotStyle: AllStyle,\n activeDotStyle: AllStyle,\n skeleton: WmSkeletonStyles\n dotSkeleton: WmSkeletonStyles\n};\nexport const DEFAULT_CLASS = 'app-carousel';\nBASE_THEME.registerStyle((themeVariables, addStyle) => {\n const btn: ViewStyle = {\n height: 48,\n width: 48,\n borderRadius: 48,\n borderColor: themeVariables.transparent,\n borderWidth: 1,\n justifyContent: 'center'\n };\n const defaultStyles: WmCarouselStyles = defineStyles({\n root: {\n position: 'relative',\n rippleColor: themeVariables.transparent\n },\n text: {},\n slide: {\n width: '100%',\n overflow: 'hidden',\n paddingHorizontal: 16,\n transform: [\n {\n scale: 0.8\n }\n ]\n },\n firstSlide: {},\n lastSlide: {},\n activeSlide: {},\n btnPanel: {\n position: 'absolute',\n top: '50%',\n marginTop: -64,\n height: 64,\n flexDirection: 'row',\n alignItems: 'center',\n justifyContent: 'space-between',\n width: '100%'\n },\n prevBtn : {\n root: {\n marginLeft: 12,\n ...btn,\n backgroundColor: themeVariables.carouselPrevBgColor,\n rippleColor: themeVariables.transparent\n },\n text: {\n fontSize: 32\n },\n icon : {\n color: themeVariables.carouselPrevBtnColor\n }\n } as WmIconStyles,\n nextBtn : {\n root: {\n marginRight: 12,\n ...btn,\n backgroundColor: themeVariables.carouselPrevBgColor,\n rippleColor: themeVariables.transparent\n },\n text: {\n fontSize: 32\n },\n icon : {\n color: themeVariables.carouselNextBtnColor\n }\n } as WmIconStyles,\n dotsWrapperStyle:{\n opacity: 1,\n backgroundColor: themeVariables.carouselDotWrapperBgColor,\n flexDirection: 'row',\n justifyContent: 'center',\n alignItems: 'center',\n paddingTop: 4,\n paddingBottom: 4\n },\n activeDotStyle: {\n position: 'absolute',\n backgroundColor: themeVariables.carouselActiveDotColor,\n opacity: 1,\n padding: 4\n },\n dotStyle: {\n width: 8,\n height: 8,\n borderRadius: 10,\n opacity: 0.2,\n marginLeft: 2,\n marginRight: 2,\n backgroundColor: themeVariables.carouselDotColor\n },\n skeleton: {\n root: {\n width: '100%',\n },\n text: {}\n } as any as WmSkeletonStyles,\n dotSkeleton: {\n root: {\n width: 10,\n height: 10,\n borderRadius: 5,\n opacity: 1,\n backgroundColor: themeVariables.skeletonAnimatedBgColor \n }\n } as any as WmSkeletonStyles\n } as WmCarouselStyles);\n\n addStyle(DEFAULT_CLASS, '', defaultStyles);\n addStyle(DEFAULT_CLASS + '-rtl', '', {\n prevBtn : {\n root:{\n transform: [{rotateY: '180deg'}]\n }\n },\n nextBtn : {\n root:{\n transform: [{rotateY: '180deg'}]\n }\n }\n });\n\n addStyle('app-carousel-1', '', {\n btnPanel: {\n top: '100%'\n },\n prevBtn: {\n root: {\n borderRadius: 6\n }\n },\n nextBtn: {\n root: {\n borderRadius: 6\n }\n }\n } as any as WmCarouselStyles);\n\n addStyle('app-carousel-2', '', {\n btnPanel: {\n backgroundColor: themeVariables.defaultColorF,\n width: '100%',\n top: '100%',\n right: 0,\n padding: 8,\n justifyContent: 'flex-end'\n },\n dotsWrapperStyle:{\n alignSelf: 'flex-start',\n justifyContent: 'flex-start'\n },\n activeDotStyle: {\n backgroundColor: themeVariables.primaryColor,\n },\n dotStyle: {\n backgroundColor: themeVariables.primaryColor,\n },\n prevBtn: {\n root: {\n backgroundColor: 'rgba(255, 255, 255, 0.1)',\n borderColor: themeVariables.primaryColor,\n },\n icon : {\n color: themeVariables.primaryColor\n }\n },\n nextBtn: {\n root: {\n marginLeft: 8,\n backgroundColor: 'rgba(255, 255, 255, 0.1)',\n borderColor: themeVariables.primaryColor,\n },\n icon : {\n color: themeVariables.primaryColor\n }\n }\n } as any as WmCarouselStyles);\n});"],"mappings":"AACA,OAAOA,UAAU,MAAoB,wCAAwC;AAC7E,SAAqBC,YAAY,QAAQ,+CAA+C;AAkBxF,OAAO,MAAMC,aAAa,GAAG,cAAc;AAC3CF,UAAU,CAACG,aAAa,CAAC,CAACC,cAAc,EAAEC,QAAQ,KAAK;EACnD,MAAMC,GAAc,GAAG;IACnBC,MAAM,EAAE,EAAE;IACVC,KAAK,EAAE,EAAE;IACTC,YAAY,EAAE,EAAE;IAChBC,WAAW,EAAEN,cAAc,CAACO,WAAW;IACvCC,WAAW,EAAE,CAAC;IACdC,cAAc,EAAE;EACpB,CAAC;EACD,MAAMC,aAA+B,GAAGb,YAAY,CAAC;IACjDc,IAAI,EAAE;MACFC,QAAQ,EAAE,UAAU;MACpBC,WAAW,EAAEb,cAAc,CAACO;IAChC,CAAC;IACDO,IAAI,EAAE,CAAC,CAAC;IACRC,KAAK,EAAE;MACHX,KAAK,EAAE,MAAM;MACbY,QAAQ,EAAE,QAAQ;MAClBC,iBAAiB,EAAE,EAAE;MACrBC,SAAS,EAAE,CACP;QACIC,KAAK,EAAE;MACX,CAAC;IAET,CAAC;IACDC,UAAU,EAAE,CAAC,CAAC;IACdC,SAAS,EAAE,CAAC,CAAC;IACbC,WAAW,EAAE,CAAC,CAAC;IACfC,QAAQ,EAAE;MACNX,QAAQ,EAAE,UAAU;MACpBY,GAAG,EA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OAAO,EAAE,CAAC;MACVrC,cAAc,EAAE;IACpB,CAAC;IACD8B,gBAAgB,EAAC;MACbgB,SAAS,EAAE,YAAY;MACvB9C,cAAc,EAAE;IACpB,CAAC;IACDmC,cAAc,EAAE;MACZd,eAAe,EAAE9B,cAAc,CAACwD;IACpC,CAAC;IACDT,QAAQ,EAAE;MACNjB,eAAe,EAAE9B,cAAc,CAACwD;IACpC,CAAC;IACD5B,OAAO,EAAE;MACLjB,IAAI,EAAE;QACFmB,eAAe,EAAE,0BAA0B;QAC3CxB,WAAW,EAAEN,cAAc,CAACwD;MAChC,CAAC;MACDvB,IAAI,EAAG;QACHC,KAAK,EAAElC,cAAc,CAACwD;MAC1B;IACJ,CAAC;IACDpB,OAAO,EAAE;MACLzB,IAAI,EAAE;QACFkB,UAAU,EAAE,CAAC;QACbC,eAAe,EAAE,0BAA0B;QAC3CxB,WAAW,EAAEN,cAAc,CAACwD;MAChC,CAAC;MACDvB,IAAI,EAAG;QACHC,KAAK,EAAElC,cAAc,CAACwD;MAC1B;IACJ;EACJ,CAA4B,CAAC;AACjC,CAAC,CAAC","ignoreList":[]}
@@ -1 +1 @@
1
- {"version":3,"names":["React","BackHandler","Platform","View","WebView","HideMode","BaseComponent","BaseComponentState","WmWebviewProps","DEFAULT_CLASS","AccessibilityWidgetType","getAccessibilityProps","isAndroid","isWebPreviewMode","WmWebViewState","constructor","args","_defineProperty","title","src","WmWebview","props","webview","webViewState","canGoBack","goBack","event","_event$nativeEvent","data","nativeEvent","startsWith","id","match","callback","invokeJSCallbacks","result","substring","indexOf","parseResult","invokeEventCallback","hideMode","DONOT_ADD_TO_DOM","addEventListener","handleBackButtonPress","componentWillUnmount","removeEventListener","_this$state$currentTa","state","currentTarget","currentsrc","_this$state$currentTa2","executeScript","fn","Promise","resolve","reject","Date","now","injectJavaScript","insertCSS","style","replace","JSON","parse","e","getTitle","iframe","contentWindow","document","onLoad","updateState","renderWidget","createElement","styles","root","_background","OS","width","height","_extends","ref","nestedScrollEnabled","source","uri","testID","getTestId","WEBVIEW","incognito","onMessage","sharedCookiesEnabled","onNavigationStateChange","scrollEnabled","onLoadEnd","url"],"sources":["webview.component.tsx"],"sourcesContent":["import React from 'react';\nimport { BackHandler, Platform, View } from 'react-native';\nimport { WebView, WebViewNavigation, WebViewMessageEvent } from 'react-native-webview';\nimport { HideMode } from '@wavemaker/app-rn-runtime/core/if.component';\nimport { BaseComponent, BaseComponentState } from '@wavemaker/app-rn-runtime/core/base.component';\n\nimport WmWebviewProps from './webview.props';\nimport { DEFAULT_CLASS, WebviewStyles } from './webview.styles';\nimport { AccessibilityWidgetType, getAccessibilityProps } from '@wavemaker/app-rn-runtime/core/accessibility';\nimport { isAndroid, isWebPreviewMode } from '@wavemaker/app-rn-runtime/core/utils';\n\nclass WmWebViewState extends BaseComponentState<WmWebviewProps> {\n currentTarget = {\n title: '',\n src: ''\n };\n\n}\n\nexport default class WmWebview extends BaseComponent<WmWebviewProps, WmWebViewState, WebviewStyles> {\n\n private webview: WebView | null = null as any;\n private webViewState: WebViewNavigation = null as any;\n private invokeJSCallbacks = {} as any;\n\n constructor(props: WmWebviewProps) {\n super(props, DEFAULT_CLASS, new WmWebviewProps());\n this.hideMode = HideMode.DONOT_ADD_TO_DOM;\n if (isAndroid() && !isWebPreviewMode()) {\n BackHandler.addEventListener('hardwareBackPress', this.handleBackButtonPress);\n }\n }\n\n componentWillUnmount() {\n super.componentWillUnmount();\n if (isAndroid() && !isWebPreviewMode()) {\n BackHandler.removeEventListener('hardwareBackPress', this.handleBackButtonPress);\n }\n }\n\n handleBackButtonPress = (): boolean => {\n if (this.webview && this.webViewState && this.webViewState.canGoBack) {\n this.webview.goBack();\n return true;\n }\n return false;\n }\n\n get title() {\n return this.state.currentTarget?.title;\n }\n\n get currentsrc() {\n return this.state.currentTarget?.src;\n }\n\n executeScript(fn: string) {\n return new Promise((resolve, reject) => {\n if (this.webview) {\n const id = '' + Date.now();\n this.invokeJSCallbacks[id] = resolve;\n fn = `\n (function(){\n try{\n return (${fn});\n } catch(e) {\n return e.getMessage();\n }\n }())\n `;\n this.webview.injectJavaScript(\n `window.ReactNativeWebView.postMessage('afterInjectJavaScript:' + ${id} + ':' + JSON.stringify(${fn}))`\n );\n } else {\n reject();\n }\n });\n }\n\n insertCSS(style = '') {\n style = style.replace(/[\\n\\t\\r]/g, '');\n return this.executeScript(`\n function() {\n const style = document.createElement('style');\n style.innerHTML = '${style}';\n document.head.appendChild(style);\n return 'SUCCESS';\n }()\n `);\n }\n\n parseResult(result: string) {\n try {\n return JSON.parse(result);\n } catch(e) {\n if (result === 'undefined' || result === 'null') {\n return null;\n }\n return result;\n }\n }\n\n onMessage = (event: WebViewMessageEvent) => {\n const data: string = event.nativeEvent?.data;\n if (data && data.startsWith('afterInjectJavaScript')) {\n const id = data?.match(/\\:([0-9]+)\\:/);\n const callback = id && this.invokeJSCallbacks[id[1]];\n const result = data.substring(data.indexOf(':', data.indexOf(':') + 1) + 1);\n callback && callback(this.parseResult(result));\n } else {\n this.invokeEventCallback('onMessage', [event, this]);\n }\n }\n\n getTitle(iframe: any) {\n try {\n return iframe.currentTarget.contentWindow.document.title;\n } catch(e) {\n // browser blocks cross origin access to iframe content.\n }\n }\n\n public onLoad(e: any, title: string, src: string) {\n this.updateState({\n currentTarget: {\n title: title,\n src: src\n }\n } as WmWebViewState, () => {\n this.invokeEventCallback('onLoad', [e, this]);\n });\n }\n\n protected renderWidget(props: WmWebviewProps) {\n return (\n <View style={this.styles.root}>\n {this._background}\n {Platform.OS === 'web' ?\n (<iframe src={props.src} width={'100%'} height={'100%'}\n onLoad={(e) => this.onLoad(e, this.getTitle(e.currentTarget), (e.currentTarget as any).src)}></iframe>) :\n (<WebView\n ref={(ref) => this.webview = ref}\n nestedScrollEnabled={true}\n style={this.styles.webview}\n source={{\n uri: props.src\n }}\n testID={this.getTestId('web_view')}\n {...getAccessibilityProps(AccessibilityWidgetType.WEBVIEW, props)}\n incognito={props.incognito}\n onMessage={this.onMessage}\n sharedCookiesEnabled={true}\n onNavigationStateChange={(state) => {\n this.webViewState = state;\n }}\n scrollEnabled={true}\n onLoadEnd={(e) => this.onLoad(e, e.nativeEvent.title, e.nativeEvent.url)}>\n </WebView>)}\n </View>\n );\n }\n}\n"],"mappings":";;;;AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,SAASC,WAAW,EAAEC,QAAQ,EAAEC,IAAI,QAAQ,cAAc;AAC1D,SAASC,OAAO,QAAgD,sBAAsB;AACtF,SAASC,QAAQ,QAAQ,6CAA6C;AACtE,SAASC,aAAa,EAAEC,kBAAkB,QAAQ,+CAA+C;AAEjG,OAAOC,cAAc,MAAM,iBAAiB;AAC5C,SAASC,aAAa,QAAuB,kBAAkB;AAC/D,SAASC,uBAAuB,EAAEC,qBAAqB,QAAQ,8CAA8C;AAC7G,SAASC,SAAS,EAAEC,gBAAgB,QAAQ,sCAAsC;AAElF,MAAMC,cAAc,SAASP,kBAAkB,CAAiB;EAAAQ,YAAA,GAAAC,IAAA;IAAA,SAAAA,IAAA;IAAAC,eAAA,wBAC9C;MACdC,KAAK,EAAE,EAAE;MACTC,GAAG,EAAE;IACP,CAAC;EAAA;AAEH;AAEA,eAAe,MAAMC,SAAS,SAASd,aAAa,CAAgD;EAMlGS,WAAWA,CAACM,KAAqB,EAAE;IACjC,KAAK,CAACA,KAAK,EAAEZ,aAAa,EAAE,IAAID,cAAc,CAAC,CAAC,CAAC;IAACS,eAAA,kBALlB,IAAI;IAAAA,eAAA,uBACI,IAAI;IAAAA,eAAA,4BAClB,CAAC,CAAC;IAAAA,eAAA,gCAiBN,MAAe;MACrC,IAAI,IAAI,CAACK,OAAO,IAAI,IAAI,CAACC,YAAY,IAAI,IAAI,CAACA,YAAY,CAACC,SAAS,EAAE;QACpE,IAAI,CAACF,OAAO,CAACG,MAAM,CAAC,CAAC;QACrB,OAAO,IAAI;MACb;MACA,OAAO,KAAK;IACd,CAAC;IAAAR,eAAA,oBAwDYS,KAA0B,IAAK;MAAA,IAAA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AAK,CAACF;MACb,CAAE;MACFiE,MAAM,EAAE,IAAI,CAACC,SAAS,CAAC,UAAU;IAAE,GAC/B1E,qBAAqB,CAACD,uBAAuB,CAAC4E,OAAO,EAAEjE,KAAK,CAAC;MACjEkE,SAAS,EAAElE,KAAK,CAACkE,SAAU;MAC3BC,SAAS,EAAE,IAAI,CAACA,SAAU;MAC1BC,oBAAoB,EAAE,IAAK;MAC3BC,uBAAuB,EAAG3C,KAAK,IAAK;QAClC,IAAI,CAACxB,YAAY,GAAGwB,KAAK;MAC3B,CAAE;MACF4C,aAAa,EAAE,IAAK;MACpBC,SAAS,EAAG5B,CAAC,IAAK,IAAI,CAACK,MAAM,CAACL,CAAC,EAAEA,CAAC,CAACnC,WAAW,CAACX,KAAK,EAAE8C,CAAC,CAACnC,WAAW,CAACgE,GAAG;IAAE,EAClE,CACP,CAAC;EAEX;AACF","ignoreList":[]}
1
+ {"version":3,"names":["React","BackHandler","Platform","View","WebView","HideMode","BaseComponent","BaseComponentState","WmWebviewProps","DEFAULT_CLASS","AccessibilityWidgetType","getAccessibilityProps","isAndroid","isWebPreviewMode","WmWebViewState","constructor","args","_defineProperty","title","src","WmWebview","props","webview","webViewState","canGoBack","goBack","event","_event$nativeEvent","data","nativeEvent","startsWith","id","match","callback","invokeJSCallbacks","result","substring","indexOf","parseResult","invokeEventCallback","hideMode","DONOT_ADD_TO_DOM","addEventListener","handleBackButtonPress","componentWillUnmount","removeEventListener","_this$state$currentTa","state","currentTarget","currentsrc","_this$state$currentTa2","executeScript","fn","Promise","resolve","reject","Date","now","injectJavaScript","insertCSS","style","replace","JSON","parse","e","getTitle","iframe","contentWindow","document","onLoad","updateState","renderWidget","createElement","styles","root","_background","OS","width","height","_extends","ref","nestedScrollEnabled","source","uri","testID","getTestId","WEBVIEW","incognito","onMessage","sharedCookiesEnabled","onNavigationStateChange","scrollEnabled","onLoadEnd","url"],"sources":["webview.component.tsx"],"sourcesContent":["import React from 'react';\nimport { BackHandler, Platform, View } from 'react-native';\nimport { WebView, WebViewNavigation, WebViewMessageEvent } from 'react-native-webview';\nimport { HideMode } from '@wavemaker/app-rn-runtime/core/if.component';\nimport { BaseComponent, BaseComponentState } from '@wavemaker/app-rn-runtime/core/base.component';\n\nimport WmWebviewProps from './webview.props';\nimport { DEFAULT_CLASS, WebviewStyles } from './webview.styles';\nimport { AccessibilityWidgetType, getAccessibilityProps } from '@wavemaker/app-rn-runtime/core/accessibility';\nimport { isAndroid, isWebPreviewMode } from '@wavemaker/app-rn-runtime/core/utils';\n\nclass WmWebViewState extends BaseComponentState<WmWebviewProps> {\n currentTarget = {\n title: '',\n src: ''\n };\n\n}\n\nexport default class WmWebview extends BaseComponent<WmWebviewProps, WmWebViewState, WebviewStyles> {\n\n private webview: WebView | null = null as any;\n private webViewState: WebViewNavigation = null as any;\n private invokeJSCallbacks = {} as any;\n\n constructor(props: WmWebviewProps) {\n super(props, DEFAULT_CLASS, new WmWebviewProps());\n this.hideMode = HideMode.DONOT_ADD_TO_DOM;\n if (isAndroid() && !isWebPreviewMode()) {\n BackHandler.addEventListener('hardwareBackPress', this.handleBackButtonPress);\n }\n }\n\n componentWillUnmount() {\n super.componentWillUnmount();\n if (isAndroid() && !isWebPreviewMode()) {\n BackHandler.removeEventListener('hardwareBackPress', this.handleBackButtonPress);\n }\n }\n\n handleBackButtonPress = (): boolean => {\n if (this.webview && this.webViewState && this.webViewState.canGoBack) {\n this.webview.goBack();\n return true;\n }\n return false;\n }\n\n get title() {\n return this.state.currentTarget?.title;\n }\n\n get currentsrc() {\n return this.state.currentTarget?.src;\n }\n\n executeScript(fn: string) {\n return new Promise((resolve, reject) => {\n if (this.webview) {\n const id = '' + Date.now();\n this.invokeJSCallbacks[id] = resolve;\n fn = `\n (function(){\n try{\n return (${fn});\n } catch(e) {\n return e.getMessage();\n }\n }())\n `;\n this.webview.injectJavaScript(\n `window.ReactNativeWebView.postMessage('afterInjectJavaScript:' + ${id} + ':' + JSON.stringify(${fn}))`\n );\n } else {\n reject();\n }\n });\n }\n\n insertCSS(style = '') {\n style = style.replace(/[\\n\\t\\r]/g, '');\n return this.executeScript(`\n function() {\n const style = document.createElement('style');\n style.innerHTML = '${style}';\n document.head.appendChild(style);\n return 'SUCCESS';\n }()\n `);\n }\n\n parseResult(result: string) {\n try {\n return JSON.parse(result);\n } catch(e) {\n if (result === 'undefined' || result === 'null') {\n return null;\n }\n return result;\n }\n }\n\n onMessage = (event: WebViewMessageEvent) => {\n const data: string = event.nativeEvent?.data;\n if (data && data.startsWith('afterInjectJavaScript')) {\n const id = data?.match(/\\:([0-9]+)\\:/);\n const callback = id && this.invokeJSCallbacks[id[1]];\n const result = data.substring(data.indexOf(':', data.indexOf(':') + 1) + 1);\n callback && callback(this.parseResult(result));\n } else {\n this.invokeEventCallback('onMessage', [event, this]);\n }\n }\n\n getTitle(iframe: any) {\n try {\n return iframe.currentTarget.contentWindow.document.title;\n } catch(e) {\n // browser blocks cross origin access to iframe content.\n }\n }\n\n public onLoad(e: any, title: string, src: string) {\n this.updateState({\n currentTarget: {\n title: title,\n src: src\n }\n } as WmWebViewState, () => {\n this.invokeEventCallback('onLoad', [e, this]);\n });\n }\n\n protected renderWidget(props: WmWebviewProps) {\n return (\n <View style={this.styles.root}>\n {this._background}\n {Platform.OS === 'web' ?\n (<iframe src={props.src} width={'100%'} height={'100%'}\n onLoad={(e) => this.onLoad(e, this.getTitle(e.currentTarget), (e.currentTarget as any).src)}></iframe>) :\n (<WebView\n ref={(ref) => this.webview = ref}\n nestedScrollEnabled={true}\n style={this.styles.webview}\n source={{\n uri: props.src\n }}\n testID={this.getTestId('web_view')}\n {...getAccessibilityProps(AccessibilityWidgetType.WEBVIEW, props)}\n incognito={props.incognito}\n onMessage={this.onMessage}\n sharedCookiesEnabled={true}\n onNavigationStateChange={(state) => {\n this.webViewState = state;\n }}\n scrollEnabled={true}\n onLoadEnd={(e) => this.onLoad(e, e.nativeEvent.title, e.nativeEvent.url)}>\n </WebView>)}\n </View>\n );\n }\n}\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AAS,EAAElE,KAAK,CAACkE,SAAU;MAC3BC,SAAS,EAAE,IAAI,CAACA,SAAU;MAC1BC,oBAAoB,EAAE,IAAK;MAC3BC,uBAAuB,EAAG3C,KAAK,IAAK;QAClC,IAAI,CAACxB,YAAY,GAAGwB,KAAK;MAC3B,CAAE;MACF4C,aAAa,EAAE,IAAK;MACpBC,SAAS,EAAG5B,CAAC,IAAK,IAAI,CAACK,MAAM,CAACL,CAAC,EAAEA,CAAC,CAACnC,WAAW,CAACX,KAAK,EAAE8C,CAAC,CAACnC,WAAW,CAACgE,GAAG;IAAE,EAClE,CACP,CAAC;EAEX;AACF","ignoreList":[]}
@@ -34,6 +34,20 @@ export default class WmAnchor extends BaseComponent {
34
34
  height: this.props.skeletonheight || this.styles.root.height
35
35
  });
36
36
  }
37
+ renderBadge() {
38
+ const {
39
+ badgevalue
40
+ } = this.props;
41
+ if (this._showSkeleton) {
42
+ return createSkeleton(this.theme, this.styles.badgeSkeleton, {
43
+ ...this.styles.badge
44
+ // marginTop: -50
45
+ });
46
+ }
47
+ return badgevalue != undefined ? /*#__PURE__*/React.createElement(Badge, {
48
+ style: this.styles.badge
49
+ }, badgevalue) : null;
50
+ }
37
51
  renderWidget(props) {
38
52
  const {
39
53
  iconclass,
@@ -58,10 +72,6 @@ export default class WmAnchor extends BaseComponent {
58
72
  iconmargin: iconmargin,
59
73
  iconwidth: iconwidth
60
74
  });
61
- //@ts-ignore
62
- const badge = badgevalue != undefined ? /*#__PURE__*/React.createElement(Badge, {
63
- style: this.styles.badge
64
- }, badgevalue) : null;
65
75
  return /*#__PURE__*/React.createElement(NavigationServiceConsumer, null, navigationService => /*#__PURE__*/React.createElement(Animatedview, {
66
76
  entryanimation: props.animation,
67
77
  delay: props.animationdelay,
@@ -83,7 +93,7 @@ export default class WmAnchor extends BaseComponent {
83
93
  style: this.styles.text
84
94
  }, this.getTestPropsForLabel('caption'), getAccessibilityProps(AccessibilityWidgetType.ANCHOR, props), {
85
95
  numberOfLines: props.nooflines
86
- }), props.caption) : null, props.iconposition === 'right' && icon, badge)));
96
+ }), props.caption) : null, props.iconposition === 'right' && icon, this.renderBadge())));
87
97
  }
88
98
  }
89
99
  //# sourceMappingURL=anchor.component.js.map
@@ -1 +1 @@
1
- {"version":3,"names":["React","Text","Badge","BaseComponent","BaseComponentState","Tappable","WmIcon","encodeUrl","AccessibilityWidgetType","getAccessibilityProps","NavigationServiceConsumer","WmAnchorProps","DEFAULT_CLASS","Animatedview","createSkeleton","WmAnchorState","WmAnchor","constructor","props","onTap","navigationService","e","state","hyperlink","link","encodeurl","openUrl","target","invokeEventCallback","proxy","renderSkeleton","theme","styles","skeleton","root","width","skeletonwidth","height","skeletonheight","renderWidget","iconclass","iconurl","name","iconheight","iconmargin","iconwidth","badgevalue","icon","text","color","createElement","id","getTestId","hint","badge","undefined","style","entryanimation","animation","delay","animationdelay","justifyContent","_extends","getTestPropsForAction","flexDirection","iconposition","_background","caption","getTestPropsForLabel","ANCHOR","numberOfLines","nooflines"],"sources":["anchor.component.tsx"],"sourcesContent":["import React from 'react';\nimport { Text } from 'react-native';\nimport { Badge } from 'react-native-paper';\nimport { BaseComponent, BaseComponentState } from '@wavemaker/app-rn-runtime/core/base.component';\nimport { SyntheticEvent, Tappable } from '@wavemaker/app-rn-runtime/core/tappable.component';\nimport WmIcon from '@wavemaker/app-rn-runtime/components/basic/icon/icon.component';\nimport { encodeUrl } from '@wavemaker/app-rn-runtime/core/utils';\nimport { AccessibilityWidgetType, getAccessibilityProps } from '@wavemaker/app-rn-runtime/core/accessibility';\nimport NavigationService, { NavigationServiceConsumer } from '@wavemaker/app-rn-runtime/core/navigation.service';\n\nimport WmAnchorProps from './anchor.props';\nimport { DEFAULT_CLASS, WmAnchorStyles } from './anchor.styles';\nimport { Animatedview } from '@wavemaker/app-rn-runtime/components/basic/animatedview.component';\nimport { createSkeleton } from '../skeleton/skeleton.component';\n\nexport class WmAnchorState extends BaseComponentState<WmAnchorProps> {\n\n}\n\nexport default class WmAnchor extends BaseComponent<WmAnchorProps, WmAnchorState, WmAnchorStyles> {\n\n constructor(props: WmAnchorProps) {\n super(props, DEFAULT_CLASS, new WmAnchorProps());\n }\n\n onTap(navigationService: NavigationService, e: SyntheticEvent) {\n const props = this.state.props;\n if (props.hyperlink) {\n const link = props.encodeurl ? encodeUrl(props.hyperlink) : props.hyperlink;\n navigationService.openUrl(link, {\n target: this.state.props.target\n });\n }\n this.invokeEventCallback('onTap', [e, this.proxy]);\n }\n\n public renderSkeleton(props: WmAnchorProps){\n return createSkeleton(this.theme, this.styles.skeleton, {\n ...this.styles.root,\n width: this.props.skeletonwidth || this.styles.root.width,\n height: this.props.skeletonheight || this.styles.root.height\n });\n }\n\n renderWidget(props: WmAnchorProps) {\n const {\n iconclass,\n iconurl,\n name,\n iconheight,\n iconmargin,\n iconwidth,\n badgevalue,\n } = props;\n\n if (this.styles.icon && this.styles.icon.text) {\n this.styles.icon.text.color = this.styles.text.color;\n }\n\n const icon = (iconclass || iconurl) && (\n <WmIcon\n id={this.getTestId('icon')}\n styles={this.styles.icon}\n hint={props?.hint}\n name={name + '_icon'}\n iconclass={iconclass}\n iconurl={iconurl}\n iconheight={iconheight}\n iconmargin={iconmargin}\n iconwidth={iconwidth}\n />\n );\n //@ts-ignore\n const badge = badgevalue != undefined ? (<Badge style={this.styles.badge}>{badgevalue}</Badge>): null;\n return (\n <NavigationServiceConsumer>\n {(navigationService: NavigationService) =>\n (<Animatedview entryanimation={props.animation} delay={props.animationdelay} style={{width: this.styles.root.width, height: this.styles.root.height, justifyContent: 'center'}}>\n <Tappable {...this.getTestPropsForAction()} target={this} styles={[this.styles.root, this.styles.root.width && this.styles.root.height ? { width: '100%', height: '100%'} : null, {flexDirection: props.iconposition === 'top' ? 'column': 'row'}]}\n onTap={props.hyperlink || props.onTap ? (e: SyntheticEvent) => this.onTap(navigationService, e) : undefined}>\n {this._background}\n {props.iconposition === 'top' && icon}\n {props.iconposition === 'left' && icon}\n {props.caption ? (<Text style={this.styles.text}\n {...this.getTestPropsForLabel('caption')}\n {...getAccessibilityProps(AccessibilityWidgetType.ANCHOR, props)}\n numberOfLines={props.nooflines}>{props.caption}</Text>) : null}\n {props.iconposition === 'right' && icon}\n {badge}\n </Tappable>\n </Animatedview>)\n }\n </NavigationServiceConsumer>\n );\n }\n}\n"],"mappings":";AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,SAASC,IAAI,QAAQ,cAAc;AACnC,SAASC,KAAK,QAAQ,oBAAoB;AAC1C,SAASC,aAAa,EAAEC,kBAAkB,QAAQ,+CAA+C;AACjG,SAAyBC,QAAQ,QAAQ,mDAAmD;AAC5F,OAAOC,MAAM,MAAM,gEAAgE;AACnF,SAASC,SAAS,QAAQ,sCAAsC;AAChE,SAASC,uBAAuB,EAAEC,qBAAqB,QAAQ,8CAA8C;AAC7G,SAA4BC,yBAAyB,QAAQ,mDAAmD;AAEhH,OAAOC,aAAa,MAAM,gBAAgB;AAC1C,SAASC,aAAa,QAAwB,iBAAiB;AAC/D,SAASC,YAAY,QAAQ,mEAAmE;AAChG,SAASC,cAAc,QAAQ,gCAAgC;AAE/D,OAAO,MAAMC,aAAa,SAASX,kBAAkB,CAAgB;AAIrE,eAAe,MAAMY,QAAQ,SAASb,aAAa,CAA+C;EAEhGc,WAAWA,CAACC,KAAoB,EAAE;IAChC,KAAK,CAACA,KAAK,EAAEN,aAAa,EAAE,IAAID,aAAa,CAAC,CAAC,CAAC;EAClD;EAEAQ,KAAKA,CAACC,iBAAoC,EAAEC,CAAiB,EAAE;IAC7D,MAAMH,KAAK,GAAG,IAAI,CAACI,KAAK,CAACJ,KAAK;IAC9B,IAAIA,KAAK,CAACK,SAAS,EAAE;MACnB,MAAMC,IAAI,GAAGN,KAAK,CAACO,SAAS,GAAGlB,SAAS,CAACW,KAAK,CAACK,SAAS,CAAC,GAAGL,KAAK,CAACK,SAAS;MAC3EH,iBAAiB,CAACM,OAAO,CAACF,IAAI,EAAE;QAC9BG,MAAM,EAAE,IAAI,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iBAAiB,EAAEC,CAAC,CAAC,GAAGkC;IAAU,IAC3G,IAAI,CAACW,WAAW,EAChBhD,KAAK,CAAC+C,YAAY,KAAK,KAAK,IAAIlB,IAAI,EACpC7B,KAAK,CAAC+C,YAAY,KAAK,MAAM,IAAIlB,IAAI,EACrC7B,KAAK,CAACiD,OAAO,gBAAInE,KAAA,CAAAkD,aAAA,CAACjD,IAAI,EAAA6D,QAAA;MAACN,KAAK,EAAE,IAAI,CAACxB,MAAM,CAACgB;IAAK,GAC5C,IAAI,CAACoB,oBAAoB,CAAC,SAAS,CAAC,EACpC3D,qBAAqB,CAACD,uBAAuB,CAAC6D,MAAM,EAAEnD,KAAK,CAAC;MAChEoD,aAAa,EAAEpD,KAAK,CAACqD;IAAU,IAAErD,KAAK,CAACiD,OAAc,CAAC,GAAI,IAAI,EAC7DjD,KAAK,CAAC+C,YAAY,KAAK,OAAO,IAAIlB,IAAI,EACtCO,KACO,CACE,CAES,CAAC;EAEhC;AACF","ignoreList":[]}
1
+ {"version":3,"names":["React","Text","Badge","BaseComponent","BaseComponentState","Tappable","WmIcon","encodeUrl","AccessibilityWidgetType","getAccessibilityProps","NavigationServiceConsumer","WmAnchorProps","DEFAULT_CLASS","Animatedview","createSkeleton","WmAnchorState","WmAnchor","constructor","props","onTap","navigationService","e","state","hyperlink","link","encodeurl","openUrl","target","invokeEventCallback","proxy","renderSkeleton","theme","styles","skeleton","root","width","skeletonwidth","height","skeletonheight","renderBadge","badgevalue","_showSkeleton","badgeSkeleton","badge","undefined","createElement","style","renderWidget","iconclass","iconurl","name","iconheight","iconmargin","iconwidth","icon","text","color","id","getTestId","hint","entryanimation","animation","delay","animationdelay","justifyContent","_extends","getTestPropsForAction","flexDirection","iconposition","_background","caption","getTestPropsForLabel","ANCHOR","numberOfLines","nooflines"],"sources":["anchor.component.tsx"],"sourcesContent":["import React from 'react';\nimport { Text } from 'react-native';\nimport { Badge } from 'react-native-paper';\nimport { BaseComponent, BaseComponentState } from '@wavemaker/app-rn-runtime/core/base.component';\nimport { SyntheticEvent, Tappable } from '@wavemaker/app-rn-runtime/core/tappable.component';\nimport WmIcon from '@wavemaker/app-rn-runtime/components/basic/icon/icon.component';\nimport { encodeUrl } from '@wavemaker/app-rn-runtime/core/utils';\nimport { AccessibilityWidgetType, getAccessibilityProps } from '@wavemaker/app-rn-runtime/core/accessibility';\nimport NavigationService, { NavigationServiceConsumer } from '@wavemaker/app-rn-runtime/core/navigation.service';\n\nimport WmAnchorProps from './anchor.props';\nimport { DEFAULT_CLASS, WmAnchorStyles } from './anchor.styles';\nimport { Animatedview } from '@wavemaker/app-rn-runtime/components/basic/animatedview.component';\nimport { createSkeleton } from '../skeleton/skeleton.component';\n\nexport class WmAnchorState extends BaseComponentState<WmAnchorProps> {\n\n}\n\nexport default class WmAnchor extends BaseComponent<WmAnchorProps, WmAnchorState, WmAnchorStyles> {\n\n constructor(props: WmAnchorProps) {\n super(props, DEFAULT_CLASS, new WmAnchorProps());\n }\n\n onTap(navigationService: NavigationService, e: SyntheticEvent) {\n const props = this.state.props;\n if (props.hyperlink) {\n const link = props.encodeurl ? encodeUrl(props.hyperlink) : props.hyperlink;\n navigationService.openUrl(link, {\n target: this.state.props.target\n });\n }\n this.invokeEventCallback('onTap', [e, this.proxy]);\n }\n\n public renderSkeleton(props: WmAnchorProps){\n return createSkeleton(this.theme, this.styles.skeleton, {\n ...this.styles.root,\n width: this.props.skeletonwidth || this.styles.root.width,\n height: this.props.skeletonheight || this.styles.root.height\n });\n }\n \n renderBadge() {\n const { badgevalue } = this.props;\n if(this._showSkeleton) {\n return createSkeleton(this.theme, this.styles.badgeSkeleton, {\n ...this.styles.badge,\n // marginTop: -50\n })\n }\n return badgevalue != undefined ? (<Badge style={this.styles.badge}>{badgevalue}</Badge>): null;\n }\n\n renderWidget(props: WmAnchorProps) {\n const {\n iconclass,\n iconurl,\n name,\n iconheight,\n iconmargin,\n iconwidth,\n badgevalue,\n } = props;\n\n if (this.styles.icon && this.styles.icon.text) {\n this.styles.icon.text.color = this.styles.text.color;\n }\n\n const icon = (iconclass || iconurl) && (\n <WmIcon\n id={this.getTestId('icon')}\n styles={this.styles.icon}\n hint={props?.hint}\n name={name + '_icon'}\n iconclass={iconclass}\n iconurl={iconurl}\n iconheight={iconheight}\n iconmargin={iconmargin}\n iconwidth={iconwidth}\n />\n );\n return (\n <NavigationServiceConsumer>\n {(navigationService: NavigationService) =>\n (<Animatedview entryanimation={props.animation} delay={props.animationdelay} style={{width: this.styles.root.width, height: this.styles.root.height, justifyContent: 'center'}}>\n <Tappable {...this.getTestPropsForAction()} target={this} styles={[this.styles.root, this.styles.root.width && this.styles.root.height ? { width: '100%', height: '100%'} : null, {flexDirection: props.iconposition === 'top' ? 'column': 'row'}]}\n onTap={props.hyperlink || props.onTap ? (e: SyntheticEvent) => this.onTap(navigationService, e) : undefined}>\n {this._background}\n {props.iconposition === 'top' && icon}\n {props.iconposition === 'left' && icon}\n {props.caption ? (<Text style={this.styles.text}\n {...this.getTestPropsForLabel('caption')}\n {...getAccessibilityProps(AccessibilityWidgetType.ANCHOR, props)}\n numberOfLines={props.nooflines}>{props.caption}</Text>) : null}\n {props.iconposition === 'right' && icon}\n {this.renderBadge()}\n </Tappable>\n </Animatedview>)\n }\n </NavigationServiceConsumer>\n );\n }\n}\n"],"mappings":";AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,SAASC,IAAI,QAAQ,cAAc;AACnC,SAASC,KAAK,QAAQ,oBAAoB;AAC1C,SAASC,aAAa,EAAEC,kBAAkB,QAAQ,+CAA+C;AACjG,SAAyBC,QAAQ,QAAQ,mDAAmD;AAC5F,OAAOC,MAAM,MAAM,gEAAgE;AACnF,SAASC,SAAS,QAAQ,sCAAsC;AAChE,SAASC,uBAAuB,EAAEC,qBAAqB,QAAQ,8CAA8C;AAC7G,SAA4BC,yBAAyB,QAAQ,mDAAmD;AAEhH,OAAOC,aAAa,MAAM,gBAAgB;AAC1C,SAASC,aAAa,QAAwB,iBAAiB;AAC/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9D,qBAAqB,CAACD,uBAAuB,CAACgE,MAAM,EAAEtD,KAAK,CAAC;MAChEuD,aAAa,EAAEvD,KAAK,CAACwD;IAAU,IAAExD,KAAK,CAACoD,OAAc,CAAC,GAAI,IAAI,EAC7DpD,KAAK,CAACkD,YAAY,KAAK,OAAO,IAAId,IAAI,EACtC,IAAI,CAACf,WAAW,CAAC,CACV,CACE,CAES,CAAC;EAEhC;AACF","ignoreList":[]}
@@ -41,6 +41,9 @@ BASE_THEME.registerStyle((themeVariables, addStyle) => {
41
41
  height: 20,
42
42
  borderRadius: 4
43
43
  }
44
+ },
45
+ badgeSkeleton: {
46
+ root: {}
44
47
  }
45
48
  });
46
49
  addStyle(DEFAULT_CLASS, '', defaultStyles);
@@ -1 +1 @@
1
- {"version":3,"names":["Color","defineStyles","BASE_THEME","DEFAULT_CLASS","registerStyle","themeVariables","addStyle","defaultStyles","root","color","linkDefaultColor","flexDirection","alignItems","overflow","text","paddingLeft","paddingRight","fontSize","textDecorationLine","badge","backgroundColor","fade","rgb","toString","alignSelf","marginTop","marginLeft","fontWeight","icon","anchorTextPadding","skeleton","width","height","borderRadius","getLinkStyles","linkPrimaryColor","linkSecondaryColor","linkSuccessColor","linkDangerColor","linkWarningColor","linkInfoColor","linkLightColor","linkDarkColor"],"sources":["anchor.styles.ts"],"sourcesContent":["import Color from 'color';\nimport { BaseStyles, defineStyles } from '@wavemaker/app-rn-runtime/core/base.component';\nimport { WmIconStyles } from '@wavemaker/app-rn-runtime/components/basic/icon/icon.styles';\nimport BASE_THEME, { AllStyle } from '@wavemaker/app-rn-runtime/styles/theme';\nimport { WmSkeletonStyles } from '../skeleton/skeleton.styles';\n\nexport type WmAnchorStyles = BaseStyles & {\n badge: AllStyle,\n icon: WmIconStyles\n skeleton: WmSkeletonStyles\n};\n\nexport const DEFAULT_CLASS = 'app-anchor';\n\nBASE_THEME.registerStyle((themeVariables, addStyle) => {\n const defaultStyles: WmAnchorStyles = defineStyles({\n root: {\n color: themeVariables.linkDefaultColor,\n flexDirection: 'row',\n alignItems: 'center',\n overflow: 'visible'\n },\n text: {\n paddingLeft: 8,\n paddingRight: 8,\n color: themeVariables.linkDefaultColor,\n fontSize: 18, \n textDecorationLine: 'underline',\n },\n badge: {\n backgroundColor: Color(themeVariables.linkDefaultColor).fade(0.8).rgb().toString(),\n color: themeVariables.linkDefaultColor,\n alignSelf: 'flex-start',\n marginTop: -12,\n marginLeft: 0,\n fontWeight: 'bold'\n },\n icon: {\n root : {\n alignSelf: 'center'\n },\n text: {\n fontSize: 16,\n paddingRight: themeVariables.anchorTextPadding,\n color: themeVariables.linkDefaultColor\n }\n } as WmIconStyles,\n skeleton: {\n root: {\n width: '100%',\n height: 20,\n borderRadius: 4\n }\n } as any as WmSkeletonStyles\n });\n\n addStyle(DEFAULT_CLASS, '', defaultStyles);\n addStyle(DEFAULT_CLASS + '-rtl', '', {\n text: {\n paddingRight: 8\n }\n });\n\n const getLinkStyles = (color: string) => {\n return {\n root: {\n color: color\n },\n text: {\n color: color\n },\n icon: {\n text: {\n color: color\n }\n },\n badge: {\n backgroundColor: Color(color).fade(0.8).rgb().toString(),\n color: color,\n }\n } as WmAnchorStyles;\n };\n\n addStyle('link-primary', '', getLinkStyles(themeVariables.linkPrimaryColor));\n addStyle('link-secondary', '', getLinkStyles(themeVariables.linkSecondaryColor));\n addStyle('link-success', '', getLinkStyles(themeVariables.linkSuccessColor));\n addStyle('link-danger', '', getLinkStyles(themeVariables.linkDangerColor));\n addStyle('link-warning', '', getLinkStyles(themeVariables.linkWarningColor));\n addStyle('link-info', '', getLinkStyles(themeVariables.linkInfoColor));\n addStyle('link-light', '', getLinkStyles(themeVariables.linkLightColor));\n addStyle('link-dark', '', getLinkStyles(themeVariables.linkDarkColor));\n});\n"],"mappings":"AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,SAAqBC,YAAY,QAAQ,+CAA+C;AAExF,OAAOC,UAAU,MAAoB,wCAAwC;AAS7E,OAAO,MAAMC,aAAa,GAAG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]}
1
+ {"version":3,"names":["Color","defineStyles","BASE_THEME","DEFAULT_CLASS","registerStyle","themeVariables","addStyle","defaultStyles","root","color","linkDefaultColor","flexDirection","alignItems","overflow","text","paddingLeft","paddingRight","fontSize","textDecorationLine","badge","backgroundColor","fade","rgb","toString","alignSelf","marginTop","marginLeft","fontWeight","icon","anchorTextPadding","skeleton","width","height","borderRadius","badgeSkeleton","getLinkStyles","linkPrimaryColor","linkSecondaryColor","linkSuccessColor","linkDangerColor","linkWarningColor","linkInfoColor","linkLightColor","linkDarkColor"],"sources":["anchor.styles.ts"],"sourcesContent":["import Color from 'color';\nimport { BaseStyles, defineStyles } from '@wavemaker/app-rn-runtime/core/base.component';\nimport { WmIconStyles } from '@wavemaker/app-rn-runtime/components/basic/icon/icon.styles';\nimport BASE_THEME, { AllStyle } from '@wavemaker/app-rn-runtime/styles/theme';\nimport { WmSkeletonStyles } from '../skeleton/skeleton.styles';\n\nexport type WmAnchorStyles = BaseStyles & {\n badge: AllStyle,\n icon: WmIconStyles\n skeleton: WmSkeletonStyles\n badgeSkeleton: WmSkeletonStyles\n};\n\nexport const DEFAULT_CLASS = 'app-anchor';\n\nBASE_THEME.registerStyle((themeVariables, addStyle) => {\n const defaultStyles: WmAnchorStyles = defineStyles({\n root: {\n color: themeVariables.linkDefaultColor,\n flexDirection: 'row',\n alignItems: 'center',\n overflow: 'visible'\n },\n text: {\n paddingLeft: 8,\n paddingRight: 8,\n color: themeVariables.linkDefaultColor,\n fontSize: 18, \n textDecorationLine: 'underline',\n },\n badge: {\n backgroundColor: Color(themeVariables.linkDefaultColor).fade(0.8).rgb().toString(),\n color: themeVariables.linkDefaultColor,\n alignSelf: 'flex-start',\n marginTop: -12,\n marginLeft: 0,\n fontWeight: 'bold'\n },\n icon: {\n root : {\n alignSelf: 'center'\n },\n text: {\n fontSize: 16,\n paddingRight: themeVariables.anchorTextPadding,\n color: themeVariables.linkDefaultColor\n }\n } as WmIconStyles,\n skeleton: {\n root: {\n width: '100%',\n height: 20,\n borderRadius: 4\n }\n } as any as WmSkeletonStyles,\n badgeSkeleton: {\n root: {\n }\n } as WmSkeletonStyles\n });\n\n addStyle(DEFAULT_CLASS, '', defaultStyles);\n addStyle(DEFAULT_CLASS + '-rtl', '', {\n text: {\n paddingRight: 8\n }\n });\n\n const getLinkStyles = (color: string) => {\n return {\n root: {\n color: color\n },\n text: {\n color: color\n },\n icon: {\n text: {\n color: color\n }\n },\n badge: {\n backgroundColor: Color(color).fade(0.8).rgb().toString(),\n color: color,\n }\n } as WmAnchorStyles;\n };\n\n addStyle('link-primary', '', getLinkStyles(themeVariables.linkPrimaryColor));\n addStyle('link-secondary', '', getLinkStyles(themeVariables.linkSecondaryColor));\n addStyle('link-success', '', getLinkStyles(themeVariables.linkSuccessColor));\n addStyle('link-danger', '', getLinkStyles(themeVariables.linkDangerColor));\n addStyle('link-warning', '', getLinkStyles(themeVariables.linkWarningColor));\n addStyle('link-info', '', getLinkStyles(themeVariables.linkInfoColor));\n addStyle('link-light', '', getLinkStyles(themeVariables.linkLightColor));\n addStyle('link-dark', '', getLinkStyles(themeVariables.linkDarkColor));\n});\n"],"mappings":"AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,SAAqBC,YAAY,QAAQ,+CAA+C;AAExF,OAAOC,UAAU,MAAoB,wCAAwC;AAU7E,OAAO,MAAMC,aAAa,GAAG,YAAY;AAEzCD,UAAU,CAACE,aAAa,CAAC,CAACC,cAAc,EAAEC,QAAQ,KAAK;EACnD,MAAMC,aAA6B,GAAGN,YAAY,CAAC;IAC/CO,IAAI,EAAE;MACFC,KAAK,EAAEJ,cAAc,CAACK,gBAAgB;MACtCC,aAAa,EAAE,KAAK;MACpBC,UAAU,EAAE,QAAQ;MACpBC,QAAQ,EAAE;IACd,CAAC;IACDC,IAAI,EAAE;MACFC,WAAW,EAAE,CAAC;MACdC,YAAY,EAAE,CAAC;MACfP,KAAK,EAAEJ,cAAc,CAACK,gBAAgB;MACtCO,QAAQ,EAAE,EAAE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AAC,CAACC,GAAG,CAAC,CAAC,CAACC,QAAQ,CAAC,CAAC;QACxDd,KAAK,EAAEA;MACX;IACJ,CAAC;EACL,CAAC;EAEDH,QAAQ,CAAC,cAAc,EAAE,EAAE,EAAE6B,aAAa,CAAC9B,cAAc,CAAC+B,gBAAgB,CAAC,CAAC;EAC5E9B,QAAQ,CAAC,gBAAgB,EAAE,EAAE,EAAE6B,aAAa,CAAC9B,cAAc,CAACgC,kBAAkB,CAAC,CAAC;EAChF/B,QAAQ,CAAC,cAAc,EAAE,EAAE,EAAE6B,aAAa,CAAC9B,cAAc,CAACiC,gBAAgB,CAAC,CAAC;EAC5EhC,QAAQ,CAAC,aAAa,EAAE,EAAE,EAAE6B,aAAa,CAAC9B,cAAc,CAACkC,eAAe,CAAC,CAAC;EAC1EjC,QAAQ,CAAC,cAAc,EAAE,EAAE,EAAE6B,aAAa,CAAC9B,cAAc,CAACmC,gBAAgB,CAAC,CAAC;EAC5ElC,QAAQ,CAAC,WAAW,EAAE,EAAE,EAAE6B,aAAa,CAAC9B,cAAc,CAACoC,aAAa,CAAC,CAAC;EACtEnC,QAAQ,CAAC,YAAY,EAAE,EAAE,EAAE6B,aAAa,CAAC9B,cAAc,CAACqC,cAAc,CAAC,CAAC;EACxEpC,QAAQ,CAAC,WAAW,EAAE,EAAE,EAAE6B,aAAa,CAAC9B,cAAc,CAACsC,aAAa,CAAC,CAAC;AAC1E,CAAC,CAAC","ignoreList":[]}
@@ -207,9 +207,13 @@ export class Animatedview extends React.Component {
207
207
  style: this.props.style,
208
208
  iterationCount: this.props.iterationCount,
209
209
  ref: this.handleViewRef
210
- }, this.props.accessibilityProps), this.props.children) : /*#__PURE__*/React.createElement(View, _extends({
210
+ }, this.props.accessibilityProps, {
211
+ testID: "animatableView"
212
+ }), this.props.children) : /*#__PURE__*/React.createElement(View, _extends({
211
213
  style: this.props.style
212
- }, this.props.accessibilityProps), this.props.children);
214
+ }, this.props.accessibilityProps, {
215
+ testID: "non_animatableView"
216
+ }), this.props.children);
213
217
  }
214
218
  }
215
219
  _defineProperty(Animatedview, "defaultProps", {
@@ -1 +1 @@
1
- {"version":3,"names":["React","Animatable","initializeRegistryWithDefinitions","View","AnimatedviewProps","constructor","_defineProperty","AnimationMap","bounce","flash","pulse","rotate","rubberBand","shake","swing","tada","wobble","bounceIn","bounceInDown","bounceInLeft","bounceInRight","bounceInUp","fadeIn","fadeInDown","fadeInDownBig","fadeInLeft","fadeInLeftBig","fadeInRight","fadeInRightBig","fadeInUp","fadeInUpBig","flipInX","flipInY","lightSpeedIn","slideInDown","slideInLeft","slideInRight","slideInUp","zoomIn","zoomInDown","zoomInLeft","zoomInRight","zoomInUp","CustomAnimationMap","transform","rotateY","rotateX","flipOutY","flipOutX","from","translateY","to","slideOutUp","slideOutDown","opacity","fadeOutDown","fadeOutUp","Animatedview","Component","props","ref","view","triggerEntry","animate","entryanimation","duration","then","endState","finished","triggerExit","exitanimation","render","createElement","_extends","animation","delay","useNativeDriver","style","iterationCount","handleViewRef","accessibilityProps","children"],"sources":["animatedview.component.tsx"],"sourcesContent":["import React from 'react';\nimport * as Animatable from 'react-native-animatable';\nimport { initializeRegistryWithDefinitions } from 'react-native-animatable';\nimport { View, ViewProps, ViewStyle } from 'react-native';\n\nexport default class AnimatedviewProps {\n entryanimation?: string = null as any;\n children?: any;\n duration?: number = null as any;\n delay?: number = null as any;\n iterationCount?:any;\n style?: any;\n exitanimation?: string = null as any;\n accessibilityProps?: any;\n}\n\nconst AnimationMap: any = {\n bounce: 'bounce',\n flash: 'flash',\n pulse: 'pulse',\n rotate: 'rotate',\n rubberBand: 'rubberBand',\n shake: 'shake',\n swing: 'swing',\n tada: 'tada',\n wobble: 'wobble',\n bounceIn: 'bounceOut',\n bounceInDown: 'bounceOutUp',\n bounceInLeft: 'bounceOutRight',\n bounceInRight: 'bounceOutLeft',\n bounceInUp: 'bounceOutDown',\n fadeIn: 'fadeOut',\n fadeInDown: 'fadeOutUp',\n fadeInDownBig: 'fadeOutUpBig',\n fadeInLeft: 'fadeOutRight',\n fadeInLeftBig: 'fadeOutRightBig',\n fadeInRight: 'fadeOutLeft',\n fadeInRightBig: 'fadeOutLeftBig',\n fadeInUp: 'fadeOutDown',\n fadeInUpBig: 'fadeOutDownBig',\n flipInX: 'flipOutX',\n flipInY: 'flipOutY',\n lightSpeedIn: 'lightSpeedOut',\n slideInDown: 'slideOutUp',\n slideInLeft: 'slideOutRight',\n slideInRight: 'slideOutLeft',\n slideInUp: 'slideOutDown',\n zoomIn: 'zoomOut',\n zoomInDown: 'zoomOutUp',\n zoomInLeft: 'zoomOutRight',\n zoomInRight: 'zoomOutLeft',\n zoomInUp: 'zoomOutDown'\n};\n\nconst CustomAnimationMap: any = {\n flipInY: {\n 0: {\n transform: [{rotateY: \"0deg\"}]\n },\n 1: {\n transform: [{rotateY: \"360deg\"}]\n }\n },\n flipInX: {\n 0: {\n transform: [{rotateX: \"0deg\"}]\n },\n 1: {\n transform: [{rotateX: \"360deg\"}]\n }\n },\n flipOutY: {\n 0: {\n transform: [{rotateY: \"3600deg\"}]\n },\n 1: {\n transform: [{rotateY: \"0deg\"}]\n }\n },\n flipOutX: {\n 0: {\n transform: [{rotateX: \"360deg\"}]\n },\n 1: {\n transform: [{rotateX: \"0deg\"}]\n }\n },\n slideInDown : {\n from: { translateY: -20 },\n to: { translateY: 0 }\n },\n slideInUp : {\n from: { translateY: 20 },\n to: { translateY: 0 }\n },\n slideOutUp: {\n from: { translateY: 0 },\n to: { translateY: -20 }\n },\n slideOutDown : {\n from: { translateY: 0 },\n to: { translateY: 20 }\n },\n fadeInDown: {\n from: { opacity: 0, translateY: -20 },\n to: { opacity: 1, translateY: 0 }\n },\n fadeInUp: {\n from: { opacity: 0, translateY: 20 },\n to: { opacity: 1, translateY: 0 }\n },\n fadeOutDown: {\n from: { opacity: 1, translateY: 0 },\n to: { opacity: 0, translateY: 20 }\n },\n fadeOutUp: {\n from: { opacity: 1, translateY: 0 },\n to: { opacity: 0, translateY: -20 }\n }\n};\n\nexport class Animatedview extends React.Component<AnimatedviewProps> {\n static defaultProps: AnimatedviewProps = {\n duration: 200\n };\n\n private view: Animatable.View = null as any;\n\n constructor(props: AnimatedviewProps) {\n super(props);\n initializeRegistryWithDefinitions(CustomAnimationMap);\n }\n\n triggerEntry() {\n return (this as any).view.animate(this.props.entryanimation, this.props.duration).then((endState: any) => endState.finished)\n }\n\n triggerExit() {\n if (!this.view) {\n return;\n }\n if (this.props.exitanimation) {\n return (this as any).view.animate(this.props.exitanimation, this.props.duration, 1).then((endState: any) => endState.finished)\n } else {\n return (this as any).view.animate(AnimationMap[this.props.entryanimation || ''], this.props.duration, 1).then((endState: any) => endState.finished)\n }\n }\n\n // @ts-ignore\n handleViewRef = (ref: Animatable.View<ViewProps, ViewStyle>) => this.view = ref;\n\n render() {\n return this.props.entryanimation ? (\n <Animatable.View\n animation={this.props.entryanimation}\n duration={this.props.duration}\n delay={this.props.delay}\n useNativeDriver={true}\n style={this.props.style}\n iterationCount={this.props.iterationCount}\n ref={this.handleViewRef}\n {...this.props.accessibilityProps}>\n {this.props.children}\n </Animatable.View>\n ): (<View style={this.props.style} {...this.props.accessibilityProps}>{this.props.children}</View>);\n }\n}\n"],"mappings":";;;;AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,OAAO,KAAKC,UAAU,MAAM,yBAAyB;AACrD,SAASC,iCAAiC,QAAQ,yBAAyB;AAC3E,SAASC,IAAI,QAA8B,cAAc;AAEzD,eAAe,MAAMC,iBAAiB,CAAC;EAAAC,YAAA;IAAAC,eAAA,yBACX,IAAI;IAAAA,eAAA;IAAAA,eAAA,mBAEV,IAAI;IAAAA,eAAA,gBACP,IAAI;IAAAA,eAAA;IAAAA,eAAA;IAAAA,eAAA,wBAGI,IAAI;IAAAA,eAAA;EAAA;AAE/B;AAEA,MAAMC,YAAiB,GAAG;EACxBC,MAAM,EAAE,QAAQ;EAChBC,KAAK,EAAE,OAAO;EACdC,KAAK,EAAE,OAAO;EACdC,MAAM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Q,IAAI,CAASP,IAAI,CAACE,OAAO,CAACxD,YAAY,CAAC,IAAI,CAACoD,KAAK,CAACK,cAAc,IAAI,EAAE,CAAC,EAAE,IAAI,CAACL,KAAK,CAACM,QAAQ,EAAE,CAAC,CAAC,CAACC,IAAI,CAAEC,QAAa,IAAKA,QAAQ,CAACC,QAAQ,CAAC;IACrJ;EACF;EAKAG,MAAMA,CAAA,EAAG;IACP,OAAO,IAAI,CAACZ,KAAK,CAACK,cAAc,gBAC/BhE,KAAA,CAAAwE,aAAA,CAACvE,UAAU,CAACE,IAAI,EAAAsE,QAAA;MACdC,SAAS,EAAE,IAAI,CAACf,KAAK,CAACK,cAAe;MACrCC,QAAQ,EAAE,IAAI,CAACN,KAAK,CAACM,QAAS;MAC9BU,KAAK,EAAE,IAAI,CAAChB,KAAK,CAACgB,KAAM;MACxBC,eAAe,EAAE,IAAK;MACtBC,KAAK,EAAE,IAAI,CAAClB,KAAK,CAACkB,KAAM;MACxBC,cAAc,EAAE,IAAI,CAACnB,KAAK,CAACmB,cAAe;MAC1ClB,GAAG,EAAE,IAAI,CAACmB;IAAc,GACpB,IAAI,CAACpB,KAAK,CAACqB,kBAAkB,GAC/B,IAAI,CAACrB,KAAK,CAACsB,QACG,CAAC,gBAChBjF,KAAA,CAAAwE,aAAA,CAACrE,IAAI,EAAAsE,QAAA;MAACI,KAAK,EAAE,IAAI,CAAClB,KAAK,CAACkB;IAAM,GAAK,IAAI,CAAClB,KAAK,CAACqB,kBAAkB,GAAG,IAAI,CAACrB,KAAK,CAACsB,QAAe,CAAE;EACrG;AACF;AAAC3E,eAAA,CA7CYmD,YAAY,kBACkB;EACvCQ,QAAQ,EAAE;AACZ,CAAC","ignoreList":[]}
1
+ {"version":3,"names":["React","Animatable","initializeRegistryWithDefinitions","View","AnimatedviewProps","constructor","_defineProperty","AnimationMap","bounce","flash","pulse","rotate","rubberBand","shake","swing","tada","wobble","bounceIn","bounceInDown","bounceInLeft","bounceInRight","bounceInUp","fadeIn","fadeInDown","fadeInDownBig","fadeInLeft","fadeInLeftBig","fadeInRight","fadeInRightBig","fadeInUp","fadeInUpBig","flipInX","flipInY","lightSpeedIn","slideInDown","slideInLeft","slideInRight","slideInUp","zoomIn","zoomInDown","zoomInLeft","zoomInRight","zoomInUp","CustomAnimationMap","transform","rotateY","rotateX","flipOutY","flipOutX","from","translateY","to","slideOutUp","slideOutDown","opacity","fadeOutDown","fadeOutUp","Animatedview","Component","props","ref","view","triggerEntry","animate","entryanimation","duration","then","endState","finished","triggerExit","exitanimation","render","createElement","_extends","animation","delay","useNativeDriver","style","iterationCount","handleViewRef","accessibilityProps","testID","children"],"sources":["animatedview.component.tsx"],"sourcesContent":["import React from 'react';\nimport * as Animatable from 'react-native-animatable';\nimport { initializeRegistryWithDefinitions } from 'react-native-animatable';\nimport { View, ViewProps, ViewStyle } from 'react-native';\n\nexport default class AnimatedviewProps {\n entryanimation?: string = null as any;\n children?: any;\n duration?: number = null as any;\n delay?: number = null as any;\n iterationCount?:any;\n style?: any;\n exitanimation?: string = null as any;\n accessibilityProps?: any;\n}\n\nconst AnimationMap: any = {\n bounce: 'bounce',\n flash: 'flash',\n pulse: 'pulse',\n rotate: 'rotate',\n rubberBand: 'rubberBand',\n shake: 'shake',\n swing: 'swing',\n tada: 'tada',\n wobble: 'wobble',\n bounceIn: 'bounceOut',\n bounceInDown: 'bounceOutUp',\n bounceInLeft: 'bounceOutRight',\n bounceInRight: 'bounceOutLeft',\n bounceInUp: 'bounceOutDown',\n fadeIn: 'fadeOut',\n fadeInDown: 'fadeOutUp',\n fadeInDownBig: 'fadeOutUpBig',\n fadeInLeft: 'fadeOutRight',\n fadeInLeftBig: 'fadeOutRightBig',\n fadeInRight: 'fadeOutLeft',\n fadeInRightBig: 'fadeOutLeftBig',\n fadeInUp: 'fadeOutDown',\n fadeInUpBig: 'fadeOutDownBig',\n flipInX: 'flipOutX',\n flipInY: 'flipOutY',\n lightSpeedIn: 'lightSpeedOut',\n slideInDown: 'slideOutUp',\n slideInLeft: 'slideOutRight',\n slideInRight: 'slideOutLeft',\n slideInUp: 'slideOutDown',\n zoomIn: 'zoomOut',\n zoomInDown: 'zoomOutUp',\n zoomInLeft: 'zoomOutRight',\n zoomInRight: 'zoomOutLeft',\n zoomInUp: 'zoomOutDown'\n};\n\nconst CustomAnimationMap: any = {\n flipInY: {\n 0: {\n transform: [{rotateY: \"0deg\"}]\n },\n 1: {\n transform: [{rotateY: \"360deg\"}]\n }\n },\n flipInX: {\n 0: {\n transform: [{rotateX: \"0deg\"}]\n },\n 1: {\n transform: [{rotateX: \"360deg\"}]\n }\n },\n flipOutY: {\n 0: {\n transform: [{rotateY: \"3600deg\"}]\n },\n 1: {\n transform: [{rotateY: \"0deg\"}]\n }\n },\n flipOutX: {\n 0: {\n transform: [{rotateX: \"360deg\"}]\n },\n 1: {\n transform: [{rotateX: \"0deg\"}]\n }\n },\n slideInDown : {\n from: { translateY: -20 },\n to: { translateY: 0 }\n },\n slideInUp : {\n from: { translateY: 20 },\n to: { translateY: 0 }\n },\n slideOutUp: {\n from: { translateY: 0 },\n to: { translateY: -20 }\n },\n slideOutDown : {\n from: { translateY: 0 },\n to: { translateY: 20 }\n },\n fadeInDown: {\n from: { opacity: 0, translateY: -20 },\n to: { opacity: 1, translateY: 0 }\n },\n fadeInUp: {\n from: { opacity: 0, translateY: 20 },\n to: { opacity: 1, translateY: 0 }\n },\n fadeOutDown: {\n from: { opacity: 1, translateY: 0 },\n to: { opacity: 0, translateY: 20 }\n },\n fadeOutUp: {\n from: { opacity: 1, translateY: 0 },\n to: { opacity: 0, translateY: -20 }\n }\n};\n\nexport class Animatedview extends React.Component<AnimatedviewProps> {\n static defaultProps: AnimatedviewProps = {\n duration: 200\n };\n\n private view: Animatable.View = null as any;\n\n constructor(props: AnimatedviewProps) {\n super(props);\n initializeRegistryWithDefinitions(CustomAnimationMap);\n }\n\n triggerEntry() {\n return (this as any).view.animate(this.props.entryanimation, this.props.duration).then((endState: any) => endState.finished)\n }\n\n triggerExit() {\n if (!this.view) {\n return;\n }\n if (this.props.exitanimation) {\n return (this as any).view.animate(this.props.exitanimation, this.props.duration, 1).then((endState: any) => endState.finished)\n } else {\n return (this as any).view.animate(AnimationMap[this.props.entryanimation || ''], this.props.duration, 1).then((endState: any) => endState.finished)\n }\n }\n\n // @ts-ignore\n handleViewRef = (ref: Animatable.View<ViewProps, ViewStyle>) => this.view = ref;\n\n render() {\n return this.props.entryanimation ? (\n <Animatable.View\n animation={this.props.entryanimation}\n duration={this.props.duration}\n delay={this.props.delay}\n useNativeDriver={true}\n style={this.props.style}\n iterationCount={this.props.iterationCount}\n ref={this.handleViewRef}\n {...this.props.accessibilityProps}\n testID=\"animatableView\"\n >\n {this.props.children}\n </Animatable.View>\n ): (<View style={this.props.style} {...this.props.accessibilityProps} testID=\"non_animatableView\">{this.props.children}</View>);\n }\n}\n"],"mappings":";;;;AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,OAAO,KAAKC,UAAU,MAAM,yBAAyB;AACrD,SAASC,iCAAiC,QAAQ,yBAAyB;AAC3E,SAASC,IAAI,QAA8B,cAAc;AAEzD,eAAe,MAAMC,iBAAiB,CAAC;EAAAC,YAAA;IAAAC,eAAA,yBACX,IAAI;IAAAA,eAAA;IAAAA,eAAA,mBAEV,IAAI;IAAAA,eAAA,gBACP,IAAI;IAAAA,eAAA;IAAAA,eAAA;IAAAA,eAAA,wBAGI,IAAI;IAAAA,eAAA;EAAA;AAE/B;AAEA,MAAMC,YAAiB,GAAG;EACxBC,MAAM,EAAE,QAAQ;EAChBC,KAAK,EAAE,OAAO;EACdC,KAAK,EAAE,OAAO;EACdC,MAAM,EAAE,QAAQ;EAChBC,UAAU,EAAE,YAAY;EACxBC,KAAK,EAAE,OAAO;EACdC,KAAK,EAAE,OAAO;EACdC,IAAI,EAAE,MAAM;EACZC,MAAM,EAAE,QAAQ;EAChBC,QAAQ,EAAE,WAAW;EACrBC,YAAY,EAAE,aAAa;EAC3BC,YAAY,EAAE,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