@wavemaker/app-rn-runtime 11.4.0-next.28152 → 11.4.0-rc.5339

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (453) hide show
  1. app-rn-runtime/actions/base-action.js.map +1 -1
  2. app-rn-runtime/actions/login-action.js.map +1 -1
  3. app-rn-runtime/actions/logout-action.js.map +1 -1
  4. app-rn-runtime/actions/navigation-action.js +14 -2
  5. app-rn-runtime/actions/navigation-action.js.map +1 -1
  6. app-rn-runtime/actions/notification-action.js.map +1 -1
  7. app-rn-runtime/actions/timer-action.js.map +1 -1
  8. app-rn-runtime/components/advanced/carousel/carousel-content/carousel-content.component.js.map +1 -1
  9. app-rn-runtime/components/advanced/carousel/carousel-content/carousel-content.props.js.map +1 -1
  10. app-rn-runtime/components/advanced/carousel/carousel-template/carousel-template.component.js.map +1 -1
  11. app-rn-runtime/components/advanced/carousel/carousel-template/carousel-template.props.js.map +1 -1
  12. app-rn-runtime/components/advanced/carousel/carousel.component.js +1 -1
  13. app-rn-runtime/components/advanced/carousel/carousel.component.js.map +1 -1
  14. app-rn-runtime/components/advanced/carousel/carousel.props.js.map +1 -1
  15. app-rn-runtime/components/advanced/carousel/carousel.styles.js +16 -0
  16. app-rn-runtime/components/advanced/carousel/carousel.styles.js.map +1 -1
  17. app-rn-runtime/components/advanced/login/login.component.js.map +1 -1
  18. app-rn-runtime/components/advanced/login/login.props.js.map +1 -1
  19. app-rn-runtime/components/advanced/network-info-toaster/network-info-toaster.component.js.map +1 -1
  20. app-rn-runtime/components/advanced/network-info-toaster/network-info-toaster.props.js.map +1 -1
  21. app-rn-runtime/components/advanced/webview/webview.component.js.map +1 -1
  22. app-rn-runtime/components/advanced/webview/webview.props.js.map +1 -1
  23. app-rn-runtime/components/basic/anchor/anchor.component.js +1 -0
  24. app-rn-runtime/components/basic/anchor/anchor.component.js.map +1 -1
  25. app-rn-runtime/components/basic/anchor/anchor.props.js.map +1 -1
  26. app-rn-runtime/components/basic/anchor/anchor.styles.js +5 -0
  27. app-rn-runtime/components/basic/anchor/anchor.styles.js.map +1 -1
  28. app-rn-runtime/components/basic/animatedview.component.js +1 -3
  29. app-rn-runtime/components/basic/animatedview.component.js.map +1 -1
  30. app-rn-runtime/components/basic/audio/audio.component.js +240 -0
  31. app-rn-runtime/components/basic/audio/audio.component.js.map +1 -0
  32. app-rn-runtime/components/basic/audio/audio.props.js +15 -0
  33. app-rn-runtime/components/basic/audio/audio.props.js.map +1 -0
  34. app-rn-runtime/components/basic/audio/audio.styles.js +61 -0
  35. app-rn-runtime/components/basic/audio/audio.styles.js.map +1 -0
  36. app-rn-runtime/components/basic/button/button.component.js.map +1 -1
  37. app-rn-runtime/components/basic/button/button.props.js.map +1 -1
  38. app-rn-runtime/components/basic/button/button.styles.js.map +1 -1
  39. app-rn-runtime/components/basic/buttongroup/buttongroup.component.js.map +1 -1
  40. app-rn-runtime/components/basic/buttongroup/buttongroup.props.js.map +1 -1
  41. app-rn-runtime/components/basic/buttongroup/buttongroup.styles.js.map +1 -1
  42. app-rn-runtime/components/basic/custom/custom.component.js.map +1 -1
  43. app-rn-runtime/components/basic/custom/custom.props.js.map +1 -1
  44. app-rn-runtime/components/basic/icon/icon.component.js.map +1 -1
  45. app-rn-runtime/components/basic/icon/icon.props.js.map +1 -1
  46. app-rn-runtime/components/basic/icon/icon.styles.js +5 -0
  47. app-rn-runtime/components/basic/icon/icon.styles.js.map +1 -1
  48. app-rn-runtime/components/basic/label/label.component.js +2 -1
  49. app-rn-runtime/components/basic/label/label.component.js.map +1 -1
  50. app-rn-runtime/components/basic/label/label.props.js.map +1 -1
  51. app-rn-runtime/components/basic/label/label.styles.js +8 -0
  52. app-rn-runtime/components/basic/label/label.styles.js.map +1 -1
  53. app-rn-runtime/components/basic/lottie/lottie.component.js.map +1 -1
  54. app-rn-runtime/components/basic/lottie/lottie.props.js.map +1 -1
  55. app-rn-runtime/components/basic/message/message.component.js.map +1 -1
  56. app-rn-runtime/components/basic/message/message.props.js.map +1 -1
  57. app-rn-runtime/components/basic/message/message.styles.js +22 -0
  58. app-rn-runtime/components/basic/message/message.styles.js.map +1 -1
  59. app-rn-runtime/components/basic/modal/modal.component.js.map +1 -1
  60. app-rn-runtime/components/basic/modal/modal.props.js.map +1 -1
  61. app-rn-runtime/components/basic/modal/modal.styles.js.map +1 -1
  62. app-rn-runtime/components/basic/picture/picture.component.js +3 -3
  63. app-rn-runtime/components/basic/picture/picture.component.js.map +1 -1
  64. app-rn-runtime/components/basic/picture/picture.props.js.map +1 -1
  65. app-rn-runtime/components/basic/picture/picture.styles.js.map +1 -1
  66. app-rn-runtime/components/basic/progress-bar/progress-bar.component.js.map +1 -1
  67. app-rn-runtime/components/basic/progress-bar/progress-bar.props.js.map +1 -1
  68. app-rn-runtime/components/basic/progress-bar/progress-bar.styles.js.map +1 -1
  69. app-rn-runtime/components/basic/progress-circle/progress-circle.component.js.map +1 -1
  70. app-rn-runtime/components/basic/progress-circle/progress-circle.props.js.map +1 -1
  71. app-rn-runtime/components/basic/progress-circle/progress-circle.styles.js.map +1 -1
  72. app-rn-runtime/components/basic/search/local-data-provider.js.map +1 -1
  73. app-rn-runtime/components/basic/search/search.component.js +1 -1
  74. app-rn-runtime/components/basic/search/search.component.js.map +1 -1
  75. app-rn-runtime/components/basic/search/search.props.js +1 -0
  76. app-rn-runtime/components/basic/search/search.props.js.map +1 -1
  77. app-rn-runtime/components/basic/search/search.styles.js +47 -0
  78. app-rn-runtime/components/basic/search/search.styles.js.map +1 -1
  79. app-rn-runtime/components/basic/skeleton/skeleton.component.js.map +1 -1
  80. app-rn-runtime/components/basic/spinner/spinner.component.js +3 -1
  81. app-rn-runtime/components/basic/spinner/spinner.component.js.map +1 -1
  82. app-rn-runtime/components/basic/spinner/spinner.props.js.map +1 -1
  83. app-rn-runtime/components/basic/spinner/spinner.styles.js +8 -0
  84. app-rn-runtime/components/basic/spinner/spinner.styles.js.map +1 -1
  85. app-rn-runtime/components/basic/video/video.component.js +2 -2
  86. app-rn-runtime/components/basic/video/video.component.js.map +1 -1
  87. app-rn-runtime/components/basic/video/video.props.js.map +1 -1
  88. app-rn-runtime/components/chart/area-chart/area-chart.component.js.map +1 -1
  89. app-rn-runtime/components/chart/bar-chart/bar-chart.component.js.map +1 -1
  90. app-rn-runtime/components/chart/bar-chart/bar-chart.props.js.map +1 -1
  91. app-rn-runtime/components/chart/basechart.component.js +6 -2
  92. app-rn-runtime/components/chart/basechart.component.js.map +1 -1
  93. app-rn-runtime/components/chart/basechart.props.js +1 -0
  94. app-rn-runtime/components/chart/basechart.props.js.map +1 -1
  95. app-rn-runtime/components/chart/basechart.styles.js +17 -0
  96. app-rn-runtime/components/chart/basechart.styles.js.map +1 -1
  97. app-rn-runtime/components/chart/bubble-chart/bubble-chart.component.js.map +1 -1
  98. app-rn-runtime/components/chart/column-chart/column-chart.component.js.map +1 -1
  99. app-rn-runtime/components/chart/donut-chart/donut-chart.component.js.map +1 -1
  100. app-rn-runtime/components/chart/donut-chart/donut-chart.props.js +0 -1
  101. app-rn-runtime/components/chart/donut-chart/donut-chart.props.js.map +1 -1
  102. app-rn-runtime/components/chart/legend/legend.component.js +36 -0
  103. app-rn-runtime/components/chart/legend/legend.component.js.map +1 -0
  104. app-rn-runtime/components/chart/line-chart/line-chart.component.js.map +1 -1
  105. app-rn-runtime/components/chart/line-chart/line-chart.props.js.map +1 -1
  106. app-rn-runtime/components/chart/pie-chart/pie-chart.component.js +119 -40
  107. app-rn-runtime/components/chart/pie-chart/pie-chart.component.js.map +1 -1
  108. app-rn-runtime/components/chart/pie-chart/pie-chart.props.js +1 -2
  109. app-rn-runtime/components/chart/pie-chart/pie-chart.props.js.map +1 -1
  110. app-rn-runtime/components/chart/theme/chart.theme.js.map +1 -1
  111. app-rn-runtime/components/container/accordion/accordion.component.js +75 -119
  112. app-rn-runtime/components/container/accordion/accordion.component.js.map +1 -1
  113. app-rn-runtime/components/container/accordion/accordion.props.js +1 -0
  114. app-rn-runtime/components/container/accordion/accordion.props.js.map +1 -1
  115. app-rn-runtime/components/container/accordion/accordion.styles.js +14 -4
  116. app-rn-runtime/components/container/accordion/accordion.styles.js.map +1 -1
  117. app-rn-runtime/components/container/accordion/accordionpane/accordionpane.component.js +48 -7
  118. app-rn-runtime/components/container/accordion/accordionpane/accordionpane.component.js.map +1 -1
  119. app-rn-runtime/components/container/accordion/accordionpane/accordionpane.props.js.map +1 -1
  120. app-rn-runtime/components/container/container.component.js.map +1 -1
  121. app-rn-runtime/components/container/container.props.js.map +1 -1
  122. app-rn-runtime/components/container/container.styles.js.map +1 -1
  123. app-rn-runtime/components/container/layoutgrid/gridcolumn/gridcolumn.component.js.map +1 -1
  124. app-rn-runtime/components/container/layoutgrid/gridcolumn/gridcolumn.props.js.map +1 -1
  125. app-rn-runtime/components/container/layoutgrid/gridrow/gridrow.component.js.map +1 -1
  126. app-rn-runtime/components/container/layoutgrid/gridrow/gridrow.props.js.map +1 -1
  127. app-rn-runtime/components/container/layoutgrid/layoutgrid.component.js.map +1 -1
  128. app-rn-runtime/components/container/layoutgrid/layoutgrid.props.js.map +1 -1
  129. app-rn-runtime/components/container/layoutgrid/layoutgrid.styles.js.map +1 -1
  130. app-rn-runtime/components/container/linearlayout/linearlayout.component.js +1 -0
  131. app-rn-runtime/components/container/linearlayout/linearlayout.component.js.map +1 -1
  132. app-rn-runtime/components/container/linearlayout/linearlayout.props.js.map +1 -1
  133. app-rn-runtime/components/container/linearlayout/linearlayoutitem/linearlayoutitem.component.js +2 -2
  134. app-rn-runtime/components/container/linearlayout/linearlayoutitem/linearlayoutitem.component.js.map +1 -1
  135. app-rn-runtime/components/container/linearlayout/linearlayoutitem/linearlayoutitem.props.js.map +1 -1
  136. app-rn-runtime/components/container/panel/panel-content/panel-content.component.js.map +1 -1
  137. app-rn-runtime/components/container/panel/panel-content/panel-content.props.js.map +1 -1
  138. app-rn-runtime/components/container/panel/panel-footer/panel-footer.component.js.map +1 -1
  139. app-rn-runtime/components/container/panel/panel-footer/panel-footer.props.js.map +1 -1
  140. app-rn-runtime/components/container/panel/panel.component.js.map +1 -1
  141. app-rn-runtime/components/container/panel/panel.props.js.map +1 -1
  142. app-rn-runtime/components/container/panel/panel.styles.js +9 -0
  143. app-rn-runtime/components/container/panel/panel.styles.js.map +1 -1
  144. app-rn-runtime/components/container/partial-host.component.js.map +1 -1
  145. app-rn-runtime/components/container/tabs/tabheader/tabheader.component.js +30 -5
  146. app-rn-runtime/components/container/tabs/tabheader/tabheader.component.js.map +1 -1
  147. app-rn-runtime/components/container/tabs/tabheader/tabheader.props.js.map +1 -1
  148. app-rn-runtime/components/container/tabs/tabheader/tabheader.styles.js +10 -1
  149. app-rn-runtime/components/container/tabs/tabheader/tabheader.styles.js.map +1 -1
  150. app-rn-runtime/components/container/tabs/tabpane/tabpane.component.js.map +1 -1
  151. app-rn-runtime/components/container/tabs/tabpane/tabpane.props.js.map +1 -1
  152. app-rn-runtime/components/container/tabs/tabs.component.js +5 -2
  153. app-rn-runtime/components/container/tabs/tabs.component.js.map +1 -1
  154. app-rn-runtime/components/container/tabs/tabs.props.js.map +1 -1
  155. app-rn-runtime/components/container/tabs/tabs.styles.js +39 -0
  156. app-rn-runtime/components/container/tabs/tabs.styles.js.map +1 -1
  157. app-rn-runtime/components/container/tile/tile.component.js.map +1 -1
  158. app-rn-runtime/components/container/tile/tile.props.js.map +1 -1
  159. app-rn-runtime/components/container/tile/tile.styles.js.map +1 -1
  160. app-rn-runtime/components/container/wizard/wizard.component.js +15 -6
  161. app-rn-runtime/components/container/wizard/wizard.component.js.map +1 -1
  162. app-rn-runtime/components/container/wizard/wizard.props.js.map +1 -1
  163. app-rn-runtime/components/container/wizard/wizard.styles.js +53 -1
  164. app-rn-runtime/components/container/wizard/wizard.styles.js.map +1 -1
  165. app-rn-runtime/components/container/wizard/wizardstep/wizardstep.component.js.map +1 -1
  166. app-rn-runtime/components/container/wizard/wizardstep/wizardstep.props.js.map +1 -1
  167. app-rn-runtime/components/data/card/card-content/card-content.component.js.map +1 -1
  168. app-rn-runtime/components/data/card/card-content/card-content.props.js.map +1 -1
  169. app-rn-runtime/components/data/card/card-footer/card-footer.component.js.map +1 -1
  170. app-rn-runtime/components/data/card/card-footer/card-footer.props.js.map +1 -1
  171. app-rn-runtime/components/data/card/card.component.js.map +1 -1
  172. app-rn-runtime/components/data/card/card.props.js.map +1 -1
  173. app-rn-runtime/components/data/card/card.styles.js.map +1 -1
  174. app-rn-runtime/components/data/form/form-action/form-action.component.js +1 -0
  175. app-rn-runtime/components/data/form/form-action/form-action.component.js.map +1 -1
  176. app-rn-runtime/components/data/form/form-action/form-action.props.js +3 -1
  177. app-rn-runtime/components/data/form/form-action/form-action.props.js.map +1 -1
  178. app-rn-runtime/components/data/form/form-action/form-action.styles.js.map +1 -1
  179. app-rn-runtime/components/data/form/form-body/form-body.component.js.map +1 -1
  180. app-rn-runtime/components/data/form/form-body/form-body.props.js.map +1 -1
  181. app-rn-runtime/components/data/form/form-field/form-field.component.js +23 -2
  182. app-rn-runtime/components/data/form/form-field/form-field.component.js.map +1 -1
  183. app-rn-runtime/components/data/form/form-field/form-field.props.js +8 -0
  184. app-rn-runtime/components/data/form/form-field/form-field.props.js.map +1 -1
  185. app-rn-runtime/components/data/form/form-field/form-field.styles.js.map +1 -1
  186. app-rn-runtime/components/data/form/form-footer/form-footer.component.js.map +1 -1
  187. app-rn-runtime/components/data/form/form-footer/form-footer.props.js.map +1 -1
  188. app-rn-runtime/components/data/form/form.component.js +93 -3
  189. app-rn-runtime/components/data/form/form.component.js.map +1 -1
  190. app-rn-runtime/components/data/form/form.props.js +2 -0
  191. app-rn-runtime/components/data/form/form.props.js.map +1 -1
  192. app-rn-runtime/components/data/form/form.styles.js +6 -0
  193. app-rn-runtime/components/data/form/form.styles.js.map +1 -1
  194. app-rn-runtime/components/data/list/list-template/list-template.component.js.map +1 -1
  195. app-rn-runtime/components/data/list/list-template/list-template.props.js.map +1 -1
  196. app-rn-runtime/components/data/list/list-template/list-template.styles.js.map +1 -1
  197. app-rn-runtime/components/data/list/list.component.js +77 -16
  198. app-rn-runtime/components/data/list/list.component.js.map +1 -1
  199. app-rn-runtime/components/data/list/list.props.js +2 -0
  200. app-rn-runtime/components/data/list/list.props.js.map +1 -1
  201. app-rn-runtime/components/data/list/list.styles.js.map +1 -1
  202. app-rn-runtime/components/data/liveform/liveform.component.js +102 -0
  203. app-rn-runtime/components/data/liveform/liveform.component.js.map +1 -0
  204. app-rn-runtime/components/device/barcodescanner/barcodescanner.component.js.map +1 -1
  205. app-rn-runtime/components/device/barcodescanner/barcodescanner.props.js.map +1 -1
  206. app-rn-runtime/components/device/camera/camera.component.js.map +1 -1
  207. app-rn-runtime/components/device/camera/camera.props.js.map +1 -1
  208. app-rn-runtime/components/dialogs/alertdialog/alertdialog.component.js.map +1 -1
  209. app-rn-runtime/components/dialogs/alertdialog/alertdialog.props.js.map +1 -1
  210. app-rn-runtime/components/dialogs/alertdialog/alertdialog.styles.js.map +1 -1
  211. app-rn-runtime/components/dialogs/confirmdialog/confirmdialog.component.js.map +1 -1
  212. app-rn-runtime/components/dialogs/confirmdialog/confirmdialog.props.js.map +1 -1
  213. app-rn-runtime/components/dialogs/confirmdialog/confirmdialog.styles.js +9 -0
  214. app-rn-runtime/components/dialogs/confirmdialog/confirmdialog.styles.js.map +1 -1
  215. app-rn-runtime/components/dialogs/dialog/dialog.component.js +5 -2
  216. app-rn-runtime/components/dialogs/dialog/dialog.component.js.map +1 -1
  217. app-rn-runtime/components/dialogs/dialog/dialog.props.js.map +1 -1
  218. app-rn-runtime/components/dialogs/dialogactions/dialogactions.component.js.map +1 -1
  219. app-rn-runtime/components/dialogs/dialogactions/dialogactions.props.js.map +1 -1
  220. app-rn-runtime/components/dialogs/dialogcontent/dialogcontent.component.js.map +1 -1
  221. app-rn-runtime/components/dialogs/dialogcontent/dialogcontent.props.js.map +1 -1
  222. app-rn-runtime/components/input/basedataset/basedataset.component.js.map +1 -1
  223. app-rn-runtime/components/input/basedataset/basedataset.props.js.map +1 -1
  224. app-rn-runtime/components/input/baseinput/baseinput.component.js +4 -4
  225. app-rn-runtime/components/input/baseinput/baseinput.component.js.map +1 -1
  226. app-rn-runtime/components/input/baseinput/baseinput.props.js.map +1 -1
  227. app-rn-runtime/components/input/basenumber/basenumber.component.js +1 -1
  228. app-rn-runtime/components/input/basenumber/basenumber.component.js.map +1 -1
  229. app-rn-runtime/components/input/basenumber/basenumber.props.js.map +1 -1
  230. app-rn-runtime/components/input/calendar/calendar.component.js.map +1 -1
  231. app-rn-runtime/components/input/calendar/calendar.props.js.map +1 -1
  232. app-rn-runtime/components/input/calendar/calendar.styles.js +22 -0
  233. app-rn-runtime/components/input/calendar/calendar.styles.js.map +1 -1
  234. app-rn-runtime/components/input/calendar/views/month-view.js +1 -0
  235. app-rn-runtime/components/input/calendar/views/month-view.js.map +1 -1
  236. app-rn-runtime/components/input/checkbox/checkbox.component.js.map +1 -1
  237. app-rn-runtime/components/input/checkbox/checkbox.props.js +1 -1
  238. app-rn-runtime/components/input/checkbox/checkbox.props.js.map +1 -1
  239. app-rn-runtime/components/input/checkbox/checkbox.styles.js.map +1 -1
  240. app-rn-runtime/components/input/checkboxset/checkboxset.component.js.map +1 -1
  241. app-rn-runtime/components/input/checkboxset/checkboxset.props.js.map +1 -1
  242. app-rn-runtime/components/input/checkboxset/checkboxset.styles.js.map +1 -1
  243. app-rn-runtime/components/input/chips/chips.component.js +1 -0
  244. app-rn-runtime/components/input/chips/chips.component.js.map +1 -1
  245. app-rn-runtime/components/input/chips/chips.props.js.map +1 -1
  246. app-rn-runtime/components/input/composite/composite.component.js.map +1 -1
  247. app-rn-runtime/components/input/composite/composite.props.js.map +1 -1
  248. app-rn-runtime/components/input/currency/currency.component.js +6 -4
  249. app-rn-runtime/components/input/currency/currency.component.js.map +1 -1
  250. app-rn-runtime/components/input/currency/currency.props.js +1 -1
  251. app-rn-runtime/components/input/currency/currency.props.js.map +1 -1
  252. app-rn-runtime/components/input/currency/currency.styles.js +9 -0
  253. app-rn-runtime/components/input/currency/currency.styles.js.map +1 -1
  254. app-rn-runtime/components/input/epoch/base-datetime.component.js +5 -2
  255. app-rn-runtime/components/input/epoch/base-datetime.component.js.map +1 -1
  256. app-rn-runtime/components/input/epoch/date/date.component.js.map +1 -1
  257. app-rn-runtime/components/input/epoch/date/date.props.js.map +1 -1
  258. app-rn-runtime/components/input/epoch/date/date.styles.js +9 -0
  259. app-rn-runtime/components/input/epoch/date/date.styles.js.map +1 -1
  260. app-rn-runtime/components/input/epoch/date-picker.component.js.map +1 -1
  261. app-rn-runtime/components/input/epoch/datetime/datetime.component.js.map +1 -1
  262. app-rn-runtime/components/input/epoch/datetime/datetime.props.js.map +1 -1
  263. app-rn-runtime/components/input/epoch/datetime/datetime.styles.js +9 -0
  264. app-rn-runtime/components/input/epoch/datetime/datetime.styles.js.map +1 -1
  265. app-rn-runtime/components/input/epoch/time/time.component.js.map +1 -1
  266. app-rn-runtime/components/input/epoch/time/time.props.js.map +1 -1
  267. app-rn-runtime/components/input/epoch/time/time.styles.js +9 -0
  268. app-rn-runtime/components/input/epoch/time/time.styles.js.map +1 -1
  269. app-rn-runtime/components/input/fileupload/fileupload.component.js.map +1 -1
  270. app-rn-runtime/components/input/fileupload/fileupload.props.js.map +1 -1
  271. app-rn-runtime/components/input/number/number.component.js +6 -4
  272. app-rn-runtime/components/input/number/number.component.js.map +1 -1
  273. app-rn-runtime/components/input/number/number.props.js +1 -1
  274. app-rn-runtime/components/input/number/number.props.js.map +1 -1
  275. app-rn-runtime/components/input/number/number.styles.js +5 -0
  276. app-rn-runtime/components/input/number/number.styles.js.map +1 -1
  277. app-rn-runtime/components/input/radioset/radioset.component.js +3 -1
  278. app-rn-runtime/components/input/radioset/radioset.component.js.map +1 -1
  279. app-rn-runtime/components/input/radioset/radioset.props.js.map +1 -1
  280. app-rn-runtime/components/input/radioset/radioset.styles.js +8 -0
  281. app-rn-runtime/components/input/radioset/radioset.styles.js.map +1 -1
  282. app-rn-runtime/components/input/rating/rating.component.js +1 -1
  283. app-rn-runtime/components/input/rating/rating.component.js.map +1 -1
  284. app-rn-runtime/components/input/rating/rating.props.js.map +1 -1
  285. app-rn-runtime/components/input/select/select.component.js +14 -2
  286. app-rn-runtime/components/input/select/select.component.js.map +1 -1
  287. app-rn-runtime/components/input/select/select.props.js.map +1 -1
  288. app-rn-runtime/components/input/select/select.styles.js +18 -1
  289. app-rn-runtime/components/input/select/select.styles.js.map +1 -1
  290. app-rn-runtime/components/input/slider/slider.component.js +2 -1
  291. app-rn-runtime/components/input/slider/slider.component.js.map +1 -1
  292. app-rn-runtime/components/input/slider/slider.props.js.map +1 -1
  293. app-rn-runtime/components/input/switch/switch.component.js.map +1 -1
  294. app-rn-runtime/components/input/switch/switch.props.js.map +1 -1
  295. app-rn-runtime/components/input/switch/switch.styles.js +36 -0
  296. app-rn-runtime/components/input/switch/switch.styles.js.map +1 -1
  297. app-rn-runtime/components/input/text/text.component.js +5 -3
  298. app-rn-runtime/components/input/text/text.component.js.map +1 -1
  299. app-rn-runtime/components/input/text/text.props.js.map +1 -1
  300. app-rn-runtime/components/input/text/text.styles.js +5 -0
  301. app-rn-runtime/components/input/text/text.styles.js.map +1 -1
  302. app-rn-runtime/components/input/textarea/textarea.component.js +5 -3
  303. app-rn-runtime/components/input/textarea/textarea.component.js.map +1 -1
  304. app-rn-runtime/components/input/textarea/textarea.props.js.map +1 -1
  305. app-rn-runtime/components/input/textarea/textarea.styles.js +5 -0
  306. app-rn-runtime/components/input/textarea/textarea.styles.js.map +1 -1
  307. app-rn-runtime/components/input/toggle/toggle.component.js +17 -11
  308. app-rn-runtime/components/input/toggle/toggle.component.js.map +1 -1
  309. app-rn-runtime/components/input/toggle/toggle.props.js.map +1 -1
  310. app-rn-runtime/components/input/toggle/toggle.styles.js +28 -3
  311. app-rn-runtime/components/input/toggle/toggle.styles.js.map +1 -1
  312. app-rn-runtime/components/navigation/appnavbar/appnavbar.component.js.map +1 -1
  313. app-rn-runtime/components/navigation/appnavbar/appnavbar.props.js.map +1 -1
  314. app-rn-runtime/components/navigation/appnavbar/appnavbar.styles.js.map +1 -1
  315. app-rn-runtime/components/navigation/basenav/basenav.component.js.map +1 -1
  316. app-rn-runtime/components/navigation/basenav/basenav.props.js.map +1 -1
  317. app-rn-runtime/components/navigation/menu/menu.component.js.map +1 -1
  318. app-rn-runtime/components/navigation/menu/menu.props.js.map +1 -1
  319. app-rn-runtime/components/navigation/menu/menu.styles.js +6 -0
  320. app-rn-runtime/components/navigation/menu/menu.styles.js.map +1 -1
  321. app-rn-runtime/components/navigation/navbar/navbar.component.js.map +1 -1
  322. app-rn-runtime/components/navigation/navbar/navbar.props.js.map +1 -1
  323. app-rn-runtime/components/navigation/navbar/navbar.styles.js.map +1 -1
  324. app-rn-runtime/components/navigation/navitem/navitem.component.js.map +1 -1
  325. app-rn-runtime/components/navigation/navitem/navitem.props.js.map +1 -1
  326. app-rn-runtime/components/navigation/navitem/navitem.styles.js.map +1 -1
  327. app-rn-runtime/components/navigation/popover/popover.component.js.map +1 -1
  328. app-rn-runtime/components/navigation/popover/popover.props.js.map +1 -1
  329. app-rn-runtime/components/navigation/popover/popover.styles.js.map +1 -1
  330. app-rn-runtime/components/page/content/content.component.js.map +1 -1
  331. app-rn-runtime/components/page/left-panel/left-panel.component.js.map +1 -1
  332. app-rn-runtime/components/page/left-panel/left-panel.props.js.map +1 -1
  333. app-rn-runtime/components/page/page-content/page-content.component.js.map +1 -1
  334. app-rn-runtime/components/page/page-content/page-content.props.js.map +1 -1
  335. app-rn-runtime/components/page/page.component.js.map +1 -1
  336. app-rn-runtime/components/page/partial/partial.component.js.map +1 -1
  337. app-rn-runtime/components/page/partial-container/partial-container.component.js.map +1 -1
  338. app-rn-runtime/components/page/partial-container/partial-container.props.js.map +1 -1
  339. app-rn-runtime/components/page/tabbar/tabbar.component.js.map +1 -1
  340. app-rn-runtime/components/page/tabbar/tabbar.props.js.map +1 -1
  341. app-rn-runtime/components/prefab/prefab-container.component.js.map +1 -1
  342. app-rn-runtime/core/asset.provider.js.map +1 -1
  343. app-rn-runtime/core/base.component.js +29 -17
  344. app-rn-runtime/core/base.component.js.map +1 -1
  345. app-rn-runtime/core/components/textinput.component.js +37 -0
  346. app-rn-runtime/core/components/textinput.component.js.map +1 -0
  347. app-rn-runtime/core/device/camera-service.js.map +1 -1
  348. app-rn-runtime/core/device/scan-service.js.map +1 -1
  349. app-rn-runtime/core/display.manager.js.map +1 -1
  350. app-rn-runtime/core/event-notifier.js.map +1 -1
  351. app-rn-runtime/core/fixed-view.component.js.map +1 -1
  352. app-rn-runtime/core/formatters.js.map +1 -1
  353. app-rn-runtime/core/i18n.service.js +2 -0
  354. app-rn-runtime/core/i18n.service.js.map +1 -0
  355. app-rn-runtime/core/if.component.js +3 -3
  356. app-rn-runtime/core/if.component.js.map +1 -1
  357. app-rn-runtime/core/imageSizeEstimator.js.map +1 -1
  358. app-rn-runtime/core/injector.js +2 -1
  359. app-rn-runtime/core/injector.js.map +1 -1
  360. app-rn-runtime/core/logger.js +4 -1
  361. app-rn-runtime/core/logger.js.map +1 -1
  362. app-rn-runtime/core/modal.service.js.map +1 -1
  363. app-rn-runtime/core/navigation.service.js.map +1 -1
  364. app-rn-runtime/core/network.service.js +17 -15
  365. app-rn-runtime/core/network.service.js.map +1 -1
  366. app-rn-runtime/core/partial.service.js.map +1 -1
  367. app-rn-runtime/core/props.provider.js +1 -1
  368. app-rn-runtime/core/props.provider.js.map +1 -1
  369. app-rn-runtime/core/scroll-view.component.js.map +1 -1
  370. app-rn-runtime/core/security.service.js.map +1 -1
  371. app-rn-runtime/core/spinner.service.js.map +1 -1
  372. app-rn-runtime/core/storage.service.js.map +1 -1
  373. app-rn-runtime/core/tappable.component.js +11 -2
  374. app-rn-runtime/core/tappable.component.js.map +1 -1
  375. app-rn-runtime/core/toast.service.js.map +1 -1
  376. app-rn-runtime/core/utils.js +22 -0
  377. app-rn-runtime/core/utils.js.map +1 -1
  378. app-rn-runtime/core/viewport.js.map +1 -1
  379. app-rn-runtime/gestures/swipe.animation.js +9 -4
  380. app-rn-runtime/gestures/swipe.animation.js.map +1 -1
  381. app-rn-runtime/package.json +41 -41
  382. app-rn-runtime/runtime/App.js +14 -6
  383. app-rn-runtime/runtime/App.js.map +1 -1
  384. app-rn-runtime/runtime/App.navigator.js +11 -2
  385. app-rn-runtime/runtime/App.navigator.js.map +1 -1
  386. app-rn-runtime/runtime/base-fragment.component.js +20 -7
  387. app-rn-runtime/runtime/base-fragment.component.js.map +1 -1
  388. app-rn-runtime/runtime/base-page.component.js +2 -0
  389. app-rn-runtime/runtime/base-page.component.js.map +1 -1
  390. app-rn-runtime/runtime/base-partial.component.js.map +1 -1
  391. app-rn-runtime/runtime/base-prefab.component.js +5 -7
  392. app-rn-runtime/runtime/base-prefab.component.js.map +1 -1
  393. app-rn-runtime/runtime/lib-patch.js.map +1 -1
  394. app-rn-runtime/runtime/memo.component.js.map +1 -1
  395. app-rn-runtime/runtime/navigator/drawer.navigator.js.map +1 -1
  396. app-rn-runtime/runtime/navigator/stack.navigator.js.map +1 -1
  397. app-rn-runtime/runtime/services/app-display-manager.service.js.map +1 -1
  398. app-rn-runtime/runtime/services/app-i18n.service.js +26 -3
  399. app-rn-runtime/runtime/services/app-i18n.service.js.map +1 -1
  400. app-rn-runtime/runtime/services/app-modal.service.js.map +1 -1
  401. app-rn-runtime/runtime/services/app-security.service.js +7 -7
  402. app-rn-runtime/runtime/services/app-security.service.js.map +1 -1
  403. app-rn-runtime/runtime/services/app-spinner.service.js +3 -2
  404. app-rn-runtime/runtime/services/app-spinner.service.js.map +1 -1
  405. app-rn-runtime/runtime/services/app-toast.service.js.map +1 -1
  406. app-rn-runtime/runtime/services/device/calendar-service.js.map +1 -1
  407. app-rn-runtime/runtime/services/device/camera-service.js +2 -3
  408. app-rn-runtime/runtime/services/device/camera-service.js.map +1 -1
  409. app-rn-runtime/runtime/services/device/contacts-service.js.map +1 -1
  410. app-rn-runtime/runtime/services/device/location-service.js.map +1 -1
  411. app-rn-runtime/runtime/services/device/permissions.js.map +1 -1
  412. app-rn-runtime/runtime/services/device/scan-service.js.map +1 -1
  413. app-rn-runtime/runtime/services/partial.service.js.map +1 -1
  414. app-rn-runtime/runtime/services/webprocess.service.js.map +1 -1
  415. app-rn-runtime/runtime/watcher.js +3 -1
  416. app-rn-runtime/runtime/watcher.js.map +1 -1
  417. app-rn-runtime/styles/MediaQueryList.js.map +1 -1
  418. app-rn-runtime/styles/background.component.js +51 -12
  419. app-rn-runtime/styles/background.component.js.map +1 -1
  420. app-rn-runtime/styles/style-prop.validator.js +4 -0
  421. app-rn-runtime/styles/style-prop.validator.js.map +1 -1
  422. app-rn-runtime/styles/style-props.js.map +1 -1
  423. app-rn-runtime/styles/theme.js +12 -5
  424. app-rn-runtime/styles/theme.js.map +1 -1
  425. app-rn-runtime/styles/theme.variables.js +58 -2
  426. app-rn-runtime/styles/theme.variables.js.map +1 -1
  427. app-rn-runtime/variables/base-variable.js +3 -3
  428. app-rn-runtime/variables/base-variable.js.map +1 -1
  429. app-rn-runtime/variables/device/calendar/create-event.operation.js.map +1 -1
  430. app-rn-runtime/variables/device/calendar/delete-event.operation.js.map +1 -1
  431. app-rn-runtime/variables/device/calendar/get-events.operation.js.map +1 -1
  432. app-rn-runtime/variables/device/camera/capture-image.operation.js.map +1 -1
  433. app-rn-runtime/variables/device/camera/capture-video.operation.js.map +1 -1
  434. app-rn-runtime/variables/device/contacts/get-contacts.operation.js.map +1 -1
  435. app-rn-runtime/variables/device/device/app-info.operation.js.map +1 -1
  436. app-rn-runtime/variables/device/device/current-geo-position.operation.js.map +1 -1
  437. app-rn-runtime/variables/device/device/device-info.operation.js.map +1 -1
  438. app-rn-runtime/variables/device/device/network-info.operation.js.map +1 -1
  439. app-rn-runtime/variables/device/device/vibrate.operation.js.map +1 -1
  440. app-rn-runtime/variables/device/file/upload-file.operation.js.map +1 -1
  441. app-rn-runtime/variables/device/operation.provider.js.map +1 -1
  442. app-rn-runtime/variables/device/scan/scan.operation.js.map +1 -1
  443. app-rn-runtime/variables/device-variable.js.map +1 -1
  444. app-rn-runtime/variables/http.service.js +7 -3
  445. app-rn-runtime/variables/http.service.js.map +1 -1
  446. app-rn-runtime/variables/live-variable.js +115 -0
  447. app-rn-runtime/variables/live-variable.js.map +1 -0
  448. app-rn-runtime/variables/model-variable.js.map +1 -1
  449. app-rn-runtime/variables/service-variable.js +14 -4
  450. app-rn-runtime/variables/service-variable.js.map +1 -1
  451. app-rn-runtime/variables/utils/dataset-util.js.map +1 -1
  452. app-rn-runtime/variables/utils/inflight-queue.js.map +1 -1
  453. app-rn-runtime/variables/utils/variable.utils.js.map +1 -1
@@ -1 +1 @@
1
- {"version":3,"names":["BASE_THEME","defineStyles","DEFAULT_CLASS","registerStyle","themeVariables","addStyle","defaultStyles","root","flexDirection","padding","borderWidth","borderStyle","borderColor","inputBorderColor","backgroundColor","inputBackgroundColor","borderRadius","minWidth","invalid","borderBottomColor","inputInvalidBorderColor","text","fontSize","fontFamily","baseFont","flex","color","inputTextColor","disabledText","inputDisabledBgColor","modal","height","modalContent","selectDropdownBackgroundColor","position","selectBorderColor","width","selectItem","paddingHorizontal","paddingVertical","borderBottomWidth","borderBottomStyle","selecttemBorderColor","alignItems","lastSelectItem","selectItemText","selectItemTextColor","placeholderText","inputPlaceholderColor","dropDownContent","arrowButton","alignSelf","justifyContent"],"sources":["select.styles.ts"],"sourcesContent":["import BASE_THEME, {AllStyle} from '@wavemaker/app-rn-runtime/styles/theme';\nimport { BaseStyles, defineStyles } from '@wavemaker/app-rn-runtime/core/base.component';\nimport { WmButtonStyles } from '@wavemaker/app-rn-runtime/components/basic/button/button.styles';\n\nexport type WmSelectStyles = BaseStyles & {\n arrowButton: WmButtonStyles;\n modal: AllStyle;\n modalContent: AllStyle;\n selectItem: AllStyle;\n lastSelectItem: AllStyle,\n selectItemText: AllStyle;\n dropDownContent: AllStyle;\n disabledText: AllStyle;\n placeholderText: AllStyle;\n invalid: AllStyle;\n};\n\nexport const DEFAULT_CLASS = 'app-select';\nBASE_THEME.registerStyle((themeVariables, addStyle) => {\n const defaultStyles: WmSelectStyles = defineStyles({\n root: {\n flexDirection: 'row',\n padding: 12,\n borderWidth: 1,\n borderStyle: 'solid',\n borderColor: themeVariables.inputBorderColor,\n backgroundColor: themeVariables.inputBackgroundColor,\n borderRadius: 6,\n minWidth: 160\n },\n invalid: {\n borderBottomColor: themeVariables.inputInvalidBorderColor\n },\n text: {\n fontSize: 16,\n fontFamily: themeVariables.baseFont,\n flex: 1,\n color: themeVariables.inputTextColor\n },\n disabledText: {\n backgroundColor : themeVariables.inputDisabledBgColor\n },\n modal: {\n backgroundColor: 'rgba(0, 0, 0, 0.3)',\n height: '100%'\n },\n modalContent: {\n backgroundColor: themeVariables.selectDropdownBackgroundColor,\n borderRadius: 6,\n position: 'absolute',\n borderWidth: 1,\n borderStyle: 'solid',\n borderColor: themeVariables.selectBorderColor,\n width: '90%'\n },\n selectItem: {\n width: '100%',\n paddingHorizontal: 16,\n paddingVertical: 8,\n borderBottomWidth: 1,\n borderBottomStyle: 'solid',\n borderBottomColor: themeVariables.selecttemBorderColor,\n flexDirection: 'row',\n alignItems: 'center'\n },\n lastSelectItem: {\n borderBottomWidth: 0\n },\n selectItemText: {\n fontSize: 16,\n fontFamily: themeVariables.baseFont,\n color: themeVariables.selectItemTextColor\n },\n placeholderText: {\n color: themeVariables.inputPlaceholderColor\n },\n dropDownContent: {},\n arrowButton: {\n root: {\n padding: 0,\n alignItems: 'center',\n alignSelf: 'center',\n justifyContent: 'center',\n backgroundColor: 'transparent'\n }\n } as WmButtonStyles,\n });\n\n addStyle(DEFAULT_CLASS, '', defaultStyles);\n addStyle(DEFAULT_CLASS + '-disabled', '', {\n root : {\n backgroundColor: themeVariables.inputDisabledBgColor\n }\n });\n});\n"],"mappings":"AAAA,OAAOA,UAAU,MAAkB,wCAAwC;AAC3E,SAAqBC,YAAY,QAAQ,+CAA+C;AAgBxF,OAAO,MAAMC,aAAa,G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c,EAAE;MACdJ,iBAAiB,EAAE;IACrB,CAAC;IACDK,cAAc,EAAE;MACdvB,QAAQ,EAAE,EAAE;MACZC,UAAU,EAAEnB,cAAc,CAACoB,QAAQ;MACnCE,KAAK,EAAEtB,cAAc,CAAC0C;IACxB,CAAC;IACDC,eAAe,EAAE;MACfrB,KAAK,EAAEtB,cAAc,CAAC4C;IACxB,CAAC;IACDC,eAAe,EAAE,CAAC,CAAC;IACnBC,WAAW,EAAE;MACX3C,IAAI,EAAE;QACJE,OAAO,EAAE,CAAC;QACVkC,UAAU,EAAE,QAAQ;QACpBQ,SAAS,EAAE,QAAQ;QACnBC,cAAc,EAAE,QAAQ;QACxBtC,eAAe,EAAE;MACnB;IACF;EACF,CAAC,CAAC;EAEFT,QAAQ,CAACH,aAAa,EAAE,EAAE,EAAEI,aAAa,CAAC;EAC1CD,QAAQ,CAACH,aAAa,GAAG,WAAW,EAAE,EAAE,EAAE;IACtCK,IAAI,EAAG;MACLO,eAAe,EAAEV,cAAc,CAACyB;IAClC;EACJ,CAAC,CAAC;AACJ,CAAC,CAAC"}
1
+ {"version":3,"names":["BASE_THEME","defineStyles","Platform","DEFAULT_CLASS","registerStyle","themeVariables","addStyle","defaultStyles","root","flexDirection","padding","borderWidth","borderStyle","borderColor","inputBorderColor","backgroundColor","inputBackgroundColor","borderRadius","minWidth","invalid","borderBottomColor","inputInvalidBorderColor","text","fontSize","fontFamily","baseFont","flex","color","inputTextColor","checkIcon","icon","primaryColor","disabledText","inputDisabledBgColor","modal","height","modalContent","selectDropdownBackgroundColor","position","selectBorderColor","width","selectItem","paddingHorizontal","paddingVertical","borderBottomWidth","borderBottomStyle","selecttemBorderColor","alignItems","lastSelectItem","selectItemText","selectItemTextColor","placeholderText","inputPlaceholderColor","dropDownContent","arrowButton","alignSelf","justifyContent","OS","textAlign"],"sources":["select.styles.ts"],"sourcesContent":["import BASE_THEME, {AllStyle} from '@wavemaker/app-rn-runtime/styles/theme';\nimport { BaseStyles, defineStyles } from '@wavemaker/app-rn-runtime/core/base.component';\nimport { WmButtonStyles } from '@wavemaker/app-rn-runtime/components/basic/button/button.styles';\nimport { Platform } from 'react-native';\nimport { WmIconStyles } from '@wavemaker/app-rn-runtime/components/basic/icon/icon.styles';\n\nexport type WmSelectStyles = BaseStyles & {\n arrowButton: WmButtonStyles;\n modal: AllStyle;\n modalContent: AllStyle;\n checkIcon: WmIconStyles;\n selectItem: AllStyle;\n lastSelectItem: AllStyle,\n selectItemText: AllStyle;\n dropDownContent: AllStyle;\n disabledText: AllStyle;\n placeholderText: AllStyle;\n invalid: AllStyle;\n};\n\nexport const DEFAULT_CLASS = 'app-select';\nBASE_THEME.registerStyle((themeVariables, addStyle) => {\n const defaultStyles: WmSelectStyles = defineStyles({\n root: {\n flexDirection: 'row',\n padding: 12,\n borderWidth: 1,\n borderStyle: 'solid',\n borderColor: themeVariables.inputBorderColor,\n backgroundColor: themeVariables.inputBackgroundColor,\n borderRadius: 6,\n minWidth: 160\n },\n invalid: {\n borderBottomColor: themeVariables.inputInvalidBorderColor\n },\n text: {\n fontSize: 16,\n fontFamily: themeVariables.baseFont,\n flex: 1,\n color: themeVariables.inputTextColor\n },\n checkIcon: {\n icon: {\n fontSize: 24,\n color: themeVariables.primaryColor\n }\n } as WmIconStyles,\n disabledText: {\n backgroundColor : themeVariables.inputDisabledBgColor\n },\n modal: {\n backgroundColor: 'rgba(0, 0, 0, 0.3)',\n height: '100%'\n },\n modalContent: {\n backgroundColor: themeVariables.selectDropdownBackgroundColor,\n borderRadius: 6,\n position: 'absolute',\n borderWidth: 1,\n borderStyle: 'solid',\n borderColor: themeVariables.selectBorderColor,\n width: '90%'\n },\n selectItem: {\n width: '100%',\n paddingHorizontal: 16,\n paddingVertical: 8,\n borderBottomWidth: 1,\n borderBottomStyle: 'solid',\n borderBottomColor: themeVariables.selecttemBorderColor,\n flexDirection: 'row',\n alignItems: 'center'\n },\n lastSelectItem: {\n borderBottomWidth: 0\n },\n selectItemText: {\n fontSize: 16,\n fontFamily: themeVariables.baseFont,\n color: themeVariables.selectItemTextColor,\n flex: 1\n },\n placeholderText: {\n color: themeVariables.inputPlaceholderColor\n },\n dropDownContent: {},\n arrowButton: {\n root: {\n padding: 0,\n alignItems: 'center',\n alignSelf: 'center',\n justifyContent: 'center',\n backgroundColor: 'transparent'\n }\n } as WmButtonStyles,\n });\n\n addStyle(DEFAULT_CLASS, '', defaultStyles);\n addStyle(DEFAULT_CLASS + '-disabled', '', {\n root : {\n backgroundColor: themeVariables.inputDisabledBgColor\n }\n });\n addStyle(DEFAULT_CLASS + '-rtl', '', Platform.OS==\"web\"?{\n text:{\n textAlign:'right',\n }\n }:{\n text:{\n textAlign:'left',\n }\n });\n});\n"],"mappings":"AAAA,OAAOA,UAAU,MAAkB,wCAAwC;AAC3E,SAAqBC,YAAY,QAAQ,+CAA+C;AAExF,SAASC,QAAQ,QAAQ,cAAc;AAiBvC,OAAO,MAAMC,aAAa,GAAG,YAAY;AACzCH,UAAU,CAACI,aAAa,CAAC,CAACC,cAAc,EAAEC,QAAQ,KAAK;EACrD,MAAMC,aAA6B,GAAGN,YAAY,CAAC;IACjDO,IAAI,EAAE;MACJC,aAAa,EAAE,KAAK;MACpBC,OAAO,EAAE,EAAE;MACXC,WAAW,EAAE,CAAC;MACdC,WAAW,EAAE,OAAO;MACpBC,WAAW,EAAER,cAAc,CAACS,gBAAgB;MAC5CC,eAAe,EAAEV,cAAc,CAACW,oBAAoB;MACpDC,YAAY,EAAE,CAAC;MACfC,QAAQ,EAAE;IACZ,CAAC;IACDC,OAAO,EAAE;MACPC,iBAAiB,EAAEf,cAAc,CAACgB;IACpC,CAAC;IACDC,IAAI,EAAE;MACJC,QAAQ,EAAE,EAAE;MACZC,UAAU,EAAEnB,cAAc,CAACoB,QAAQ;MACnCC,IAAI,EAAE,CAAC;MACPC,KAAK,EAAEtB,cAAc,CAACuB;IACxB,CAAC;IACDC,SAAS,EAAE;MACTC,IAAI,EAAE;QACJP,QAAQ,EAAE,EA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AAEI,aAAa,CAAC;EAC1CD,QAAQ,CAACH,aAAa,GAAG,WAAW,EAAE,EAAE,EAAE;IACtCK,IAAI,EAAG;MACLO,eAAe,EAAEV,cAAc,CAAC4B;IAClC;EACJ,CAAC,CAAC;EACF3B,QAAQ,CAACH,aAAa,GAAG,MAAM,EAAE,EAAE,EAAED,QAAQ,CAACuD,EAAE,IAAE,KAAK,GAAC;IACtDnC,IAAI,EAAC;MACHoC,SAAS,EAAC;IACZ;EACF,CAAC,GAAC;IACApC,IAAI,EAAC;MACHoC,SAAS,EAAC;IACZ;EACF,CAAC,CAAC;AACJ,CAAC,CAAC"}
@@ -2,7 +2,7 @@ function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key i
2
2
  function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return typeof key === "symbol" ? key : String(key); }
3
3
  function _toPrimitive(input, hint) { if (typeof input !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (typeof res !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
4
4
  import React from 'react';
5
- import { View, Text } from 'react-native';
5
+ import { View, Text, Platform } from 'react-native';
6
6
  import { debounce, isNumber, isNil } from 'lodash';
7
7
  import Slider from '@react-native-community/slider';
8
8
  import { BaseComponent, BaseComponentState } from '@wavemaker/app-rn-runtime/core/base.component';
@@ -63,6 +63,7 @@ export default class WmSlider extends BaseComponent {
63
63
  value: this.valueBeforeSlide || props.datavalue || 0,
64
64
  disabled: props.readonly,
65
65
  minimumValue: props.minvalue,
66
+ inverted: this.isRTL && (Platform.OS == "android" || Platform.OS == "web"),
66
67
  maximumValue: props.maxvalue,
67
68
  onValueChange: this.onChange,
68
69
  thumbTintColor: this.styles.thumb.backgroundColor,
@@ -1 +1 @@
1
- {"version":3,"names":["React","View","Text","debounce","isNumber","isNil","Slider","BaseComponent","BaseComponentState","WmSliderProps","DEFAULT_CLASS","WmSliderState","WmSlider","constructor","props","value","state","datavalue","updateState","onFieldChange","valueBeforeSlide","getDataValue","minvalue","maxvalue","Math","min","max","onPropertyChange","name","$new","$old","invokeEventCallback","setProp","renderWidget","styles","root","_background","flexDirection","justifyContent","text","minimumValue","maximumValue","readonly","disabled","step","onChange","thumb","backgroundColor","onBeforeSlide","onAfterSlide","minimumTrack","maximumTrack"],"sources":["slider.component.tsx"],"sourcesContent":["import React from 'react';\nimport {View, Text } from 'react-native';\nimport { debounce, isNumber, isNil } from 'lodash';\nimport Slider from '@react-native-community/slider';\nimport { BaseComponent, BaseComponentState } from '@wavemaker/app-rn-runtime/core/base.component';\n\nimport WmSliderProps from './slider.props';\nimport { DEFAULT_CLASS, WmSliderStyles } from './slider.styles';\n\nexport class WmSliderState extends BaseComponentState<WmSliderProps> {}\n\nexport default class WmSlider extends BaseComponent<WmSliderProps, WmSliderState, WmSliderStyles> {\n valueBeforeSlide: number = 0;\n\n constructor(props: WmSliderProps) {\n super(props, DEFAULT_CLASS, new WmSliderProps());\n }\n\n getDataValue() {\n if (isNil(this.props.datavalue)) {\n return this.state.props.minvalue + (this.state.props.maxvalue - this.state.props.minvalue)/2;\n }\n return Math.min(Math.max(this.props.datavalue, this.state.props.minvalue), this.state.props.maxvalue);\n }\n\n onPropertyChange(name: string, $new: any, $old: any) {\n switch(name) {\n case 'datavalue':\n if (isNumber($new) && isNumber($old)) {\n this.invokeEventCallback('onChange', [null, this, $new, $old]);\n }\n case 'maxvalue':\n case 'minvalue': \n this.setProp('datavalue', this.getDataValue() || 0)\n }\n }\n\n onChange = debounce((value: number) => {\n if (this.state.props.datavalue !== value) {\n this.updateState({\n props : {\n datavalue: value\n }\n } as WmSliderState);\n this.props.onFieldChange &&\n this.props.onFieldChange(\n 'datavalue',\n value,\n this.state.props.datavalue\n );\n }\n }, 200);\n\n onBeforeSlide = () => this.valueBeforeSlide = this.props.datavalue;\n\n onAfterSlide = () => this.valueBeforeSlide = 0;\n\n renderWidget(props: WmSliderProps) {\n return (\n <View style={this.styles.root}>\n {this._background}\n <View style={{flexDirection:'row', justifyContent:'space-between'}}>\n <Text style={[this.styles.text, this.styles.minimumValue]}>{props.minvalue}</Text>\n <Text style={[this.styles.text, this.styles.value]}>{props.datavalue}</Text>\n <Text style={[this.styles.text, this.styles.maximumValue]}>{props.maxvalue}</Text>\n </View>\n <Slider\n style={props.readonly || props.disabled ? this.styles.disabled : {}}\n step={props.step}\n value={this.valueBeforeSlide || props.datavalue || 0}\n disabled={props.readonly}\n minimumValue={props.minvalue}\n maximumValue={props.maxvalue}\n onValueChange={this.onChange}\n thumbTintColor={this.styles.thumb.backgroundColor as string}\n onTouchStart={this.onBeforeSlide}\n onTouchEnd={this.onAfterSlide}\n minimumTrackTintColor={this.styles.minimumTrack.backgroundColor as string}\n maximumTrackTintColor={this.styles.maximumTrack.backgroundColor as string}\n />\n </View>);\n }\n}\n"],"mappings":";;;AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,SAAQC,IAAI,EAAEC,IAAI,QAAQ,cAAc;AACxC,SAASC,QAAQ,EAAEC,QAAQ,EAAEC,KAAK,QAAQ,QAAQ;AAClD,OAAOC,MAAM,MAAM,gCAAgC;AACnD,SAASC,aAAa,EAAEC,kBAAkB,QAAQ,+CAA+C;AAEjG,OAAOC,aAAa,MAAM,gBAAgB;AAC1C,SAASC,aAAa,QAAwB,iBAAiB;AAE/D,OAAO,MAAMC,aAAa,SAASH,kBAAkB,CAAgB;AAErE,eAAe,MAAMI,QAAQ,SAASL,aAAa,CAA+C;EAGhGM,WAAW,CAACC,KAAoB,EAAE;IAChC,KAAK,CAACA,KAAK,EAAEJ,aAAa,EAAE,IAAID,aAAa,EAAE,CAAC;IAAC,0CAHxB,CAAC;IAAA,kCAyBjBN,QAAQ,CAAEY,KAAa,IAAK;MACrC,IAAI,IAAI,CAACC,KAAK,CAACF,KAAK,CAACG,SAAS,KAAKF,KAAK,EAAE;QACxC,IAAI,CAACG,WAAW,CAAC;UACfJ,KAAK,E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ACC,aAAc;MACjC,UAAU,EAAE,IAAI,CAACC,YAAa;MAC9B,qBAAqB,EAAE,IAAI,CAACf,MAAM,CAACgB,YAAY,CAACH,eAA0B;MAC1E,qBAAqB,EAAE,IAAI,CAACb,MAAM,CAACiB,YAAY,CAACJ;IAA0B,EAC1E,CACG;EACT;AACF"}
1
+ {"version":3,"names":["React","View","Text","Platform","debounce","isNumber","isNil","Slider","BaseComponent","BaseComponentState","WmSliderProps","DEFAULT_CLASS","WmSliderState","WmSlider","constructor","props","_defineProperty","value","state","datavalue","updateState","onFieldChange","valueBeforeSlide","getDataValue","minvalue","maxvalue","Math","min","max","onPropertyChange","name","$new","$old","invokeEventCallback","setProp","renderWidget","createElement","style","styles","root","_background","flexDirection","justifyContent","text","minimumValue","maximumValue","readonly","disabled","step","inverted","isRTL","OS","onValueChange","onChange","thumbTintColor","thumb","backgroundColor","onTouchStart","onBeforeSlide","onTouchEnd","onAfterSlide","minimumTrackTintColor","minimumTrack","maximumTrackTintColor","maximumTrack"],"sources":["slider.component.tsx"],"sourcesContent":["import React from 'react';\nimport {View, Text, Platform } from 'react-native';\nimport { debounce, isNumber, isNil } from 'lodash';\nimport Slider from '@react-native-community/slider';\nimport { BaseComponent, BaseComponentState } from '@wavemaker/app-rn-runtime/core/base.component';\n\nimport WmSliderProps from './slider.props';\nimport { DEFAULT_CLASS, WmSliderStyles } from './slider.styles';\n\nexport class WmSliderState extends BaseComponentState<WmSliderProps> {}\n\nexport default class WmSlider extends BaseComponent<WmSliderProps, WmSliderState, WmSliderStyles> {\n valueBeforeSlide: number = 0;\n\n constructor(props: WmSliderProps) {\n super(props, DEFAULT_CLASS, new WmSliderProps());\n }\n\n getDataValue() {\n if (isNil(this.props.datavalue)) {\n return this.state.props.minvalue + (this.state.props.maxvalue - this.state.props.minvalue)/2;\n }\n return Math.min(Math.max(this.props.datavalue, this.state.props.minvalue), this.state.props.maxvalue);\n }\n\n onPropertyChange(name: string, $new: any, $old: any) {\n switch(name) {\n case 'datavalue':\n if (isNumber($new) && isNumber($old)) {\n this.invokeEventCallback('onChange', [null, this, $new, $old]);\n }\n case 'maxvalue':\n case 'minvalue': \n this.setProp('datavalue', this.getDataValue() || 0)\n }\n }\n\n onChange = debounce((value: number) => {\n if (this.state.props.datavalue !== value) {\n this.updateState({\n props : {\n datavalue: value\n }\n } as WmSliderState);\n this.props.onFieldChange &&\n this.props.onFieldChange(\n 'datavalue',\n value,\n this.state.props.datavalue\n );\n }\n }, 200);\n\n onBeforeSlide = () => this.valueBeforeSlide = this.props.datavalue;\n\n onAfterSlide = () => this.valueBeforeSlide = 0;\n\n renderWidget(props: WmSliderProps) {\n return (\n <View style={this.styles.root}>\n {this._background}\n <View style={{flexDirection:'row', justifyContent:'space-between'}}>\n <Text style={[this.styles.text, this.styles.minimumValue]}>{props.minvalue}</Text>\n <Text style={[this.styles.text, this.styles.value]}>{props.datavalue}</Text>\n <Text style={[this.styles.text, this.styles.maximumValue]}>{props.maxvalue}</Text>\n </View>\n <Slider\n style={props.readonly || props.disabled ? this.styles.disabled : {}}\n step={props.step}\n value={this.valueBeforeSlide || props.datavalue || 0}\n disabled={props.readonly}\n minimumValue={props.minvalue}\n inverted={this.isRTL && (Platform.OS==\"android\"||Platform.OS==\"web\")}\n maximumValue={props.maxvalue}\n onValueChange={this.onChange}\n thumbTintColor={this.styles.thumb.backgroundColor as string}\n onTouchStart={this.onBeforeSlide}\n onTouchEnd={this.onAfterSlide}\n minimumTrackTintColor={this.styles.minimumTrack.backgroundColor as string}\n maximumTrackTintColor={this.styles.maximumTrack.backgroundColor as string}\n />\n </View>);\n }\n}\n"],"mappings":";;;AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,SAAQC,IAAI,EAAEC,IAAI,EAAEC,QAAQ,QAAQ,cAAc;AAClD,SAASC,QAAQ,EAAEC,QAAQ,EAAEC,KAAK,QAAQ,QAAQ;AAClD,OAAOC,MAAM,MAAM,gCAAgC;AACnD,SAASC,aAAa,EAAEC,kBAAkB,QAA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,CAACC,MAAM,CAACK,IAAI,EAAE,IAAI,CAACL,MAAM,CAACO,YAAY;IAAE,GAAE9B,KAAK,CAACU,QAAe,CAC7E,CAAC,eACPzB,KAAA,CAAAoC,aAAA,CAAC7B,MAAM;MACL8B,KAAK,EAAEtB,KAAK,CAAC+B,QAAQ,IAAI/B,KAAK,CAACgC,QAAQ,GAAG,IAAI,CAACT,MAAM,CAACS,QAAQ,GAAG,CAAC,CAAE;MACpEC,IAAI,EAAEjC,KAAK,CAACiC,IAAK;MACjB/B,KAAK,EAAE,IAAI,CAACK,gBAAgB,IAAIP,KAAK,CAACI,SAAS,IAAI,CAAE;MACrD4B,QAAQ,EAAEhC,KAAK,CAAC+B,QAAS;MACzBF,YAAY,EAAE7B,KAAK,CAACS,QAAS;MAC7ByB,QAAQ,EAAE,IAAI,CAACC,KAAK,KAAK/C,QAAQ,CAACgD,EAAE,IAAE,SAAS,IAAEhD,QAAQ,CAACgD,EAAE,IAAE,KAAK,CAAE;MACrEN,YAAY,EAAE9B,KAAK,CAACU,QAAS;MAC7B2B,aAAa,EAAE,IAAI,CAACC,QAAS;MAC7BC,cAAc,EAAE,IAAI,CAAChB,MAAM,CAACiB,KAAK,CAACC,eAA0B;MAC5DC,YAAY,EAAE,IAAI,CAACC,aAAc;MACjCC,UAAU,EAAE,IAAI,CAACC,YAAa;MAC9BC,qBAAqB,EAAE,IAAI,CAACvB,MAAM,CAACwB,YAAY,CAACN,eAA0B;MAC1EO,qBAAqB,EAAE,IAAI,CAACzB,MAAM,CAAC0B,YAAY,CAACR;IAA0B,CAC3E,CACG,CAAC;EACT;AACF"}
@@ -1 +1 @@
1
- {"version":3,"names":["BaseProps","WmSliderProps"],"sources":["slider.props.ts"],"sourcesContent":["import { BaseProps } from '@wavemaker/app-rn-runtime/core/base.component';\n\nexport default class WmSliderProps extends BaseProps {\n datavalue: any;\n minvalue: number = 0;\n maxvalue: number = 100;\n step: number = 1;\n readonly = false;\n onFieldChange: any;\n}\n"],"mappings":";;;AAAA,SAASA,SAAS,QAAQ,+CAA+C;AAEzE,eAAe,MAAMC,aAAa,SAASD,SAAS,CAAC;EAAA;IAAA;IAAA;IAAA,kCAE9B,CAAC;IAAA,kCACD,GAAG;IAAA,8BACP,CAAC;IAAA,kCACL,KAAK;IAAA;EAAA;AAEpB"}
1
+ {"version":3,"names":["BaseProps","WmSliderProps","constructor","arguments","_defineProperty"],"sources":["slider.props.ts"],"sourcesContent":["import { BaseProps } from '@wavemaker/app-rn-runtime/core/base.component';\n\nexport default class WmSliderProps extends BaseProps {\n datavalue: any;\n minvalue: number = 0;\n maxvalue: number = 100;\n step?: number = 1;\n readonly? = false;\n onFieldChange?: any;\n}\n"],"mappings":";;;AAAA,SAASA,SAAS,QAAQ,+CAA+C;AAEzE,eAAe,MAAMC,aAAa,SAASD,SAAS,CAAC;EAAAE,YAAA;IAAA,SAAAC,SAAA;IAAAC,eAAA;IAAAA,eAAA,mBAE9B,CAAC;IAAAA,eAAA,mBACD,GAAG;IAAAA,eAAA,eACN,CAAC;IAAAA,eAAA,mBACL,KAAK;IAAAA,eAAA;EAAA;AAErB"}
@@ -1 +1 @@
1
- {"version":3,"names":["React","Text","View","isEqual","find","WmSwitchProps","DEFAULT_CLASS","WmIcon","BaseDatasetComponent","BaseDatasetState","Tappable","WmSwitchState","WmSwitch","constructor","props","onChange","value","validate","state","datafield","selectedItem","dataItems","item","key","dataObject","updateState","datavalue","isDefault","invokeEvent","invokeEventCallback","undefined","proxy","onTap","event","getItemKey","renderChild","index","btnClass","length","displayText","displayexp","displayfield","isSelected","disabled","bind","styles","button","selectedButton","iconclass","loadingIcon","icon","text","color","renderWidget","items","root","map"],"sources":["switch.component.tsx"],"sourcesContent":["import React from 'react';\nimport {Text, View} from \"react-native\";\nimport { isEqual, find } from 'lodash';\n\nimport WmSwitchProps from './switch.props';\nimport { DEFAULT_CLASS, WmSwitchStyles } from './switch.styles';\nimport WmIcon from '@wavemaker/app-rn-runtime/components/basic/icon/icon.component';\nimport { BaseDatasetComponent, BaseDatasetState } from '../basedataset/basedataset.component';\nimport { Tappable } from '@wavemaker/app-rn-runtime/core/tappable.component';\n\nexport class WmSwitchState extends BaseDatasetState<WmSwitchProps> {}\n\nexport default class WmSwitch extends BaseDatasetComponent<WmSwitchProps, WmSwitchState, WmSwitchStyles> {\n constructor(props: WmSwitchProps) {\n super(props, DEFAULT_CLASS, new WmSwitchProps());\n }\n\n onChange(value: any) {\n if (!value) {\n return;\n }\n this.validate(value);\n if (this.state.props.datafield === 'All Fields') {\n const selectedItem = find(this.state.dataItems, (item) => isEqual(item.key, value));\n value = selectedItem && selectedItem.dataObject;\n }\n // @ts-ignore\n this.updateState({props: {datavalue: value}, isDefault: false},\n () => {\n if (!this.props.invokeEvent) {\n this.invokeEventCallback('onChange', [undefined, this.proxy, value, this.state.props.datavalue])\n }\n });\n }\n\n onTap(event: any, item: any) {\n const value = this.state.props.datafield === 'All Fields' ? this.getItemKey(item.datafield) : item.datafield;\n this.onChange(value);\n this.invokeEventCallback('onTap', [ event, this.proxy ]);\n }\n\n renderChild(item: any, index: any) {\n let btnClass = 'button';\n const props = this.state.props;\n if(index === 0) {\n btnClass = 'firstButton';\n } else if (index+1 === this.state.dataItems.length) {\n btnClass = 'lastButton';\n }\n const displayText = item.displayexp || item.displayfield;\n const isSelected = this.state.props.datafield === 'All Fields' ? isEqual(props.datavalue, item.datafield) : this.state.props.datavalue === item.datafield;\n return (\n <Tappable \n onTap={this.state.props.disabled ? undefined : this.onTap.bind(this, null, item)}\n styles={[\n this.styles.button,\n this.styles[btnClass],\n isSelected ? this.styles.selectedButton : null]}\n key={item.key}>\n {this.state.props.iconclass ?\n (<WmIcon styles={this.styles.loadingIcon}\n iconclass={item.icon}\n caption={displayText}></WmIcon>)\n : (<View>\n <Text \n style={[this.styles.text, \n {color: isSelected ? this.styles.selectedButton.color : this.styles.button.color }]}>\n {displayText}\n </Text>\n </View>)}\n </Tappable>\n );\n };\n\n renderWidget(props: WmSwitchProps) {\n const items = this.state.dataItems;\n return (<View style={this.styles.root}>\n {items && items.length ?\n items.map((item: any, index: any) => this.renderChild(item, index)): null}\n </View>);\n }\n}\n"],"mappings":"AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,SAAQC,IAAI,EAAEC,IAAI,QAAO,cAAc;AACvC,SAASC,OAAO,EAAEC,IAAI,QAAQ,QAAQ;AAEtC,OAAOC,aAAa,MAAM,gBAAgB;AAC1C,SAASC,aAAa,QAAwB,iBAAiB;AAC/D,OAAOC,MAAM,MAAM,gEAAgE;AACnF,SAASC,oBAAoB,EAAEC,gBAAgB,QAAQ,sCAAsC;AAC7F,SAASC,QAAQ,QAAQ,mDAAmD;AAE5E,OAAO,MAAMC,aAAa,SAASF,gBAAgB,CAAgB;AAEnE,eAAe,MAAMG,QAAQ,SAASJ,oBAAoB,CAA+C;EACvGK,WAAW,CAACC,KAAoB,EAAE;IAChC,KAAK,CAACA,KAAK,EAAER,aAAa,EAAE,IAAID,aAAa,EAAE,CAAC;EAClD;EAEAU,QAAQ,CAACC,KAAU,EAAE;IACnB,IAAI,CAACA,KAAK,EAAE;MACV;IACF;IACA,IAAI,CAACC,QAAQ,CAACD,KAAK,CAAC;IACpB,IAAI,IAAI,CAACE,KAAK,CAACJ,KAAK,CAACK,SAAS,KAAK,YAAY,EAAE;MAC/C,MAAMC,YAAY,GAAGhB,IAAI,CAAC,IAAI,CAACc,KAAK,CAACG,SAAS,EAAGC,IAAI,IAAKnB,OAAO,CAACmB,IAAI,CAACC,GAAG,EAAEP,KAAK,CAAC,CAAC;MACnFA,KAAK,GAAGI,YAAY,IAAIA,YAAY,CAACI,UAAU;IACjD;IACA;IACA,IAAI,CAACC,WAAW,CAAC;MAACX,KAAK,EAAE;QAACY,SAAS,EAAEV;MAAK,CAAC;MAAEW,SAAS,EAAE;IAAK,CAAC,EAC5D,MAAM;MACN,IAAI,CAAC,IAAI,CAACb,KAAK,CAACc,WAAW,EAAE;QAC3B,IAAI,CAACC,mBAAmB,CAAC,UA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b,SAAS,GAAG,IAAI,CAACE,KAAK,CAACY,IAAI,CAAC,IAAI,EAAE,IAAI,EAAEtB,IAAI,CAAE;MACjF,MAAM,EAAE,CACN,IAAI,CAACuB,MAAM,CAACC,MAAM,EAClB,IAAI,CAACD,MAAM,CAACR,QAAQ,CAAC,EACrBK,UAAU,GAAG,IAAI,CAACG,MAAM,CAACE,cAAc,GAAG,IAAI,CAAE;MAChD,GAAG,EAAEzB,IAAI,CAACC;IAAI,GACf,IAAI,CAACL,KAAK,CAACJ,KAAK,CAACkC,SAAS,gBACtB,oBAAC,MAAM;MAAC,MAAM,EAAE,IAAI,CAACH,MAAM,CAACI,WAAY;MACjC,SAAS,EAAE3B,IAAI,CAAC4B,IAAK;MACrB,OAAO,EAAEX;IAAY,EAAU,gBACpC,oBAAC,IAAI,qBACJ,oBAAC,IAAI;MACH,KAAK,EAAE,CAAC,IAAI,CAACM,MAAM,CAACM,IAAI,EACtB;QAACC,KAAK,EAAEV,UAAU,GAAG,IAAI,CAACG,MAAM,CAACE,cAAc,CAACK,KAAK,GAAG,IAAI,CAACP,MAAM,CAACC,MAAM,CAACM;MAAM,CAAC;IAAE,GACrFb,WAAW,CACP,CACD,CACL;EAEf;EAEAc,YAAY,CAACvC,KAAoB,EAAE;IACjC,MAAMwC,KAAK,GAAG,IAAI,CAACpC,KAAK,CAACG,SAAS;IAClC,oBAAQ,oBAAC,IAAI;MAAC,KAAK,EAAE,IAAI,CAACwB,MAAM,CAACU;IAAK,GACnCD,KAAK,IAAIA,KAAK,CAAChB,MAAM,GACpBgB,KAAK,CAACE,GAAG,CAAC,CAAClC,IAAS,EAAEc,KAAU,KAAK,IAAI,CAACD,WAAW,CAACb,IAAI,EAAEc,KAAK,CAAC,CAAC,GAAE,IAAI,CACtE;EACT;AACF"}
1
+ {"version":3,"names":["React","Text","View","isEqual","find","WmSwitchProps","DEFAULT_CLASS","WmIcon","BaseDatasetComponent","BaseDatasetState","Tappable","WmSwitchState","WmSwitch","constructor","props","onChange","value","validate","state","datafield","selectedItem","dataItems","item","key","dataObject","updateState","datavalue","isDefault","invokeEvent","invokeEventCallback","undefined","proxy","onTap","event","getItemKey","renderChild","index","btnClass","length","displayText","displayexp","displayfield","isSelected","createElement","disabled","bind","styles","button","selectedButton","iconclass","loadingIcon","icon","caption","style","text","color","renderWidget","items","root","map"],"sources":["switch.component.tsx"],"sourcesContent":["import React from 'react';\nimport {Text, View} from \"react-native\";\nimport { isEqual, find } from 'lodash';\n\nimport WmSwitchProps from './switch.props';\nimport { DEFAULT_CLASS, WmSwitchStyles } from './switch.styles';\nimport WmIcon from '@wavemaker/app-rn-runtime/components/basic/icon/icon.component';\nimport { BaseDatasetComponent, BaseDatasetState } from '../basedataset/basedataset.component';\nimport { Tappable } from '@wavemaker/app-rn-runtime/core/tappable.component';\n\nexport class WmSwitchState extends BaseDatasetState<WmSwitchProps> {}\n\nexport default class WmSwitch extends BaseDatasetComponent<WmSwitchProps, WmSwitchState, WmSwitchStyles> {\n constructor(props: WmSwitchProps) {\n super(props, DEFAULT_CLASS, new WmSwitchProps());\n }\n\n onChange(value: any) {\n if (!value) {\n return;\n }\n this.validate(value);\n if (this.state.props.datafield === 'All Fields') {\n const selectedItem = find(this.state.dataItems, (item) => isEqual(item.key, value));\n value = selectedItem && selectedItem.dataObject;\n }\n // @ts-ignore\n this.updateState({props: {datavalue: value}, isDefault: false},\n () => {\n if (!this.props.invokeEvent) {\n this.invokeEventCallback('onChange', [undefined, this.proxy, value, this.state.props.datavalue])\n }\n });\n }\n\n onTap(event: any, item: any) {\n const value = this.state.props.datafield === 'All Fields' ? this.getItemKey(item.datafield) : item.datafield;\n this.onChange(value);\n this.invokeEventCallback('onTap', [ event, this.proxy ]);\n }\n\n renderChild(item: any, index: any) {\n let btnClass = 'button';\n const props = this.state.props;\n if(index === 0) {\n btnClass = 'firstButton';\n } else if (index+1 === this.state.dataItems.length) {\n btnClass = 'lastButton';\n }\n const displayText = item.displayexp || item.displayfield;\n const isSelected = this.state.props.datafield === 'All Fields' ? isEqual(props.datavalue, item.datafield) : this.state.props.datavalue === item.datafield;\n return (\n <Tappable \n onTap={this.state.props.disabled ? undefined : this.onTap.bind(this, null, item)}\n styles={[\n this.styles.button,\n this.styles[btnClass],\n isSelected ? this.styles.selectedButton : null]}\n key={item.key}>\n {this.state.props.iconclass ?\n (<WmIcon styles={this.styles.loadingIcon}\n iconclass={item.icon}\n caption={displayText}></WmIcon>)\n : (<View>\n <Text \n style={[this.styles.text, \n {color: isSelected ? this.styles.selectedButton.color : this.styles.button.color }]}>\n {displayText}\n </Text>\n </View>)}\n </Tappable>\n );\n };\n\n renderWidget(props: WmSwitchProps) {\n const items = this.state.dataItems;\n return (<View style={this.styles.root}>\n {items && items.length ?\n items.map((item: any, index: any) => this.renderChild(item, index)): null}\n </View>);\n }\n}\n"],"mappings":"AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,SAAQC,IAAI,EAAEC,IAAI,QAAO,cAAc;AACvC,SAASC,OAAO,EAAEC,IAAI,QAAQ,QAAQ;AAEtC,OAAOC,aAAa,MAAM,gBAAgB;AAC1C,SAASC,aAAa,QAAwB,iBAAiB;AAC/D,OAAOC,MAAM,MAAM,gEAAgE;AACnF,SAASC,oBAAoB,EAAEC,gBAAgB,QAAQ,sCAAsC;AAC7F,SAASC,QAAQ,QAAQ,mDAAmD;AAE5E,OAAO,MAAMC,aAAa,SAASF,gBAAgB,CAAgB;AAEnE,eAAe,MAAMG,QAAQ,SAASJ,oBAAoB,CAA+C;EACvGK,WAAWA,CAACC,KAAoB,EAAE;IAChC,KAAK,CAACA,KAAK,EAAER,aAAa,EAAE,IAAID,aAAa,CAAC,CAAC,CAAC;EAClD;EAEAU,QAAQA,CAACC,KAAU,EAAE;IACnB,IAAI,CAACA,KAAK,EAAE;MACV;IACF;IACA,IAAI,CAACC,QAAQ,CAACD,KAAK,CAAC;IACpB,IAAI,IAAI,CAACE,KAAK,CAACJ,KAAK,CAACK,SAAS,KAAK,YAAY,EAAE;M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AAM,CAAC;IAAE,GACrFhB,WACG,CACF,CACJ,CAAC;EAEf;EAEAiB,YAAYA,CAAC1C,KAAoB,EAAE;IACjC,MAAM2C,KAAK,GAAG,IAAI,CAACvC,KAAK,CAACG,SAAS;IAClC,oBAAQrB,KAAA,CAAA2C,aAAA,CAACzC,IAAI;MAACmD,KAAK,EAAE,IAAI,CAACP,MAAM,CAACY;IAAK,GACnCD,KAAK,IAAIA,KAAK,CAACnB,MAAM,GACpBmB,KAAK,CAACE,GAAG,CAAC,CAACrC,IAAS,EAAEc,KAAU,KAAK,IAAI,CAACD,WAAW,CAACb,IAAI,EAAEc,KAAK,CAAC,CAAC,GAAE,IACnE,CAAC;EACT;AACF"}
@@ -1 +1 @@
1
- {"version":3,"names":["BaseDatasetProps","WmSwitchProps"],"sources":["switch.props.ts"],"sourcesContent":["import { BaseProps } from '@wavemaker/app-rn-runtime/core/base.component';\nimport BaseDatasetProps from '../basedataset/basedataset.props';\n\nexport default class WmSwitchProps extends BaseDatasetProps {\n dataset: any = 'yes, no, maybe';\n dataItems: any;\n invokeEvent?: Function;\n}\n"],"mappings":";;;AACA,OAAOA,gBAAgB,MAAM,kCAAkC;AAE/D,eAAe,MAAMC,aAAa,SAASD,gBAAgB,CAAC;EAAA;IAAA;IAAA,iCAC3C,gBAAgB;IAAA;IAAA;EAAA;AAGjC"}
1
+ {"version":3,"names":["BaseDatasetProps","WmSwitchProps","constructor","arguments","_defineProperty"],"sources":["switch.props.ts"],"sourcesContent":["import { BaseProps } from '@wavemaker/app-rn-runtime/core/base.component';\nimport BaseDatasetProps from '../basedataset/basedataset.props';\n\nexport default class WmSwitchProps extends BaseDatasetProps {\n dataset: any = 'yes, no, maybe';\n dataItems: any;\n invokeEvent?: Function;\n}\n"],"mappings":";;;AACA,OAAOA,gBAAgB,MAAM,kCAAkC;AAE/D,eAAe,MAAMC,aAAa,SAASD,gBAAgB,CAAC;EAAAE,YAAA;IAAA,SAAAC,SAAA;IAAAC,eAAA,kBAC3C,gBAAgB;IAAAA,eAAA;IAAAA,eAAA;EAAA;AAGjC"}
@@ -1,5 +1,6 @@
1
1
  import BASE_THEME from '@wavemaker/app-rn-runtime/styles/theme';
2
2
  import { defineStyles } from '@wavemaker/app-rn-runtime/core/base.component';
3
+ import { Platform } from 'react-native';
3
4
  export const DEFAULT_CLASS = 'app-switch';
4
5
  BASE_THEME.registerStyle((themeVariables, addStyle) => {
5
6
  const defaultStyles = defineStyles({
@@ -59,6 +60,41 @@ BASE_THEME.registerStyle((themeVariables, addStyle) => {
59
60
  addStyle(DEFAULT_CLASS + '-disabled', '', {
60
61
  root: {}
61
62
  });
63
+ addStyle(DEFAULT_CLASS + '-rtl', '', Platform.OS == "web" ? {
64
+ firstButton: {
65
+ borderTopLeftRadius: 0,
66
+ borderBottomLeftRadius: 0,
67
+ borderTopRightRadius: 6,
68
+ borderBottomRightRadius: 6,
69
+ borderRightWidth: 1,
70
+ borderLeftWidth: 0
71
+ },
72
+ lastButton: {
73
+ borderTopLeftRadius: 6,
74
+ borderBottomLeftRadius: 6,
75
+ borderTopRightRadius: 0,
76
+ borderBottomRightRadius: 0,
77
+ borderRightWidth: 0
78
+ }
79
+ } : {});
80
+ addStyle(DEFAULT_CLASS + '1-rtl', '', Platform.OS == "web" ? {
81
+ firstButton: {
82
+ borderTopLeftRadius: 0,
83
+ borderBottomLeftRadius: 0,
84
+ borderTopRightRadius: 500,
85
+ borderBottomRightRadius: 500,
86
+ borderRightWidth: 0,
87
+ borderLeftWidth: 1
88
+ },
89
+ lastButton: {
90
+ flex: 1,
91
+ borderTopLeftRadius: 500,
92
+ borderBottomLeftRadius: 500,
93
+ borderTopRightRadius: 0,
94
+ borderBottomRightRadius: 0,
95
+ borderRightWidth: 1
96
+ }
97
+ } : {});
62
98
  addStyle(DEFAULT_CLASS + '1', '', {
63
99
  firstButton: {
64
100
  borderTopLeftRadius: 500,
@@ -1 +1 @@
1
- {"version":3,"names":["BASE_THEME","defineStyles","DEFAULT_CLASS","registerStyle","themeVariables","addStyle","defaultStyles","root","height","flexDirection","text","fontWeight","fontSize","textTransform","loadingIcon","flex","alignSelf","justifyContent","color","listSubTitleColor","button","backgroundColor","switchBgColor","switchTextColor","minWidth","borderRadius","borderColor","switchBorderColor","borderWidth","borderRightWidth","alignItems","selectedButton","switchActiveTextColor","switchActiveBgColor","firstButton","borderTopLeftRadius","borderBottomLeftRadius","borderTopRightRadius","borderBottomRightRadius","lastButton"],"sources":["switch.styles.ts"],"sourcesContent":["import 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 WmSwitchStyles = BaseStyles & {\n loadingIcon: WmIconStyles,\n button: AllStyle,\n selectedButton: AllStyle,\n firstButton: AllStyle,\n lastButton: AllStyle\n};\n\nexport const DEFAULT_CLASS = 'app-switch';\nBASE_THEME.registerStyle((themeVariables, addStyle) => {\n const defaultStyles: WmSwitchStyles = defineStyles<WmSwitchStyles>({\n root: {\n height: 38,\n flexDirection: 'row'\n },\n text: {\n fontWeight: '500',\n fontSize: 16,\n textTransform: 'capitalize'\n },\n loadingIcon: {\n root: {\n flex: 1,\n alignSelf: 'center',\n justifyContent: 'center',\n fontSize: 16\n },\n text: {\n color: themeVariables.listSubTitleColor\n }\n } as WmIconStyles,\n button: {\n backgroundColor: themeVariables.switchBgColor,\n color: themeVariables.switchTextColor,\n fontSize: 16,\n minWidth: 64,\n borderRadius: 0,\n borderColor: themeVariables.switchBorderColor,\n borderWidth: 1,\n borderRightWidth: 0,\n fontWeight: 'bold',\n justifyContent: 'center',\n alignItems: 'center'\n } as AllStyle,\n selectedButton: {\n color: themeVariables.switchActiveTextColor,\n backgroundColor: themeVariables.switchActiveBgColor,\n borderColor: themeVariables.switchActiveBgColor\n } as AllStyle,\n firstButton: {\n borderTopLeftRadius: 6,\n borderBottomLeftRadius: 6,\n borderTopRightRadius: 0,\n borderBottomRightRadius: 0\n } as AllStyle,\n lastButton: {\n borderTopLeftRadius: 0,\n borderBottomLeftRadius: 0,\n borderTopRightRadius: 6,\n borderBottomRightRadius: 6,\n borderRightWidth: 1\n } as AllStyle\n });\n\n addStyle(DEFAULT_CLASS, '', defaultStyles);\n addStyle(DEFAULT_CLASS + '-disabled', '', {\n root: {}\n });\n addStyle(DEFAULT_CLASS + '1', '', {\n firstButton: {\n borderTopLeftRadius: 500,\n borderBottomLeftRadius: 500,\n borderTopRightRadius: 0,\n borderBottomRightRadius: 0\n } as AllStyle,\n lastButton: {\n flex: 1,\n borderTopLeftRadius: 0,\n borderBottomLeftRadius: 0,\n borderTopRightRadius: 500,\n borderBottomRightRadius: 500\n } as AllStyle\n } as WmSwitchStyles);\n});"],"mappings":"AAAA,OAAOA,UAAU,MAAkB,wCAAwC;AAC3E,SAAqBC,YAAY,QAAQ,+CAA+C;AAWxF,OAAO,MAAMC,aAAa,GAAG,YAAY;AACzCF,UAAU,CAACG,aAAa,CAAC,CAACC,cAAc,EAAEC,QAAQ,KAAK;EACrD,MAAMC,aAA6B,GAAGL,YAAY,CAAiB;IAC/DM,IAAI,EAAE;MACJC,MAAM,EAAE,EAAE;MACVC,aAAa,EAAE;IACjB,CAAC;IACDC,IAAI,EAAE;MACJC,UAAU,EAAE,KAAK;MACjBC,QAAQ,EAAE,EAAE;MACZC,aAAa,EAAE;IACjB,CAAC;IACHC,WAAW,EAAE;MACXP,IAAI,EAAE;QACJQ,IAAI,EAAE,CAAC;QACPC,SAAS,EAAE,QAAQ;QACnBC,cAAc,EAAE,QAAQ;QACxBL,QAAQ,EAAE;MACZ,CAAC;MACDF,IAAI,EAAE;QACJQ,KAAK,EAAEd,cAAc,CAACe;MACxB;IACF,CAAiB;IACjBC,MAAM,EAAE;MACNC,eAAe,EAAEjB,cAAc,CAACkB,aAAa;MAC7CJ,KAAK,EAAEd,cAAc,CAACmB,eAAe;MACrCX,QAAQ,EAA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CAAC,CAAC"}
1
+ {"version":3,"names":["BASE_THEME","defineStyles","Platform","DEFAULT_CLASS","registerStyle","themeVariables","addStyle","defaultStyles","root","height","flexDirection","text","fontWeight","fontSize","textTransform","loadingIcon","flex","alignSelf","justifyContent","color","listSubTitleColor","button","backgroundColor","switchBgColor","switchTextColor","minWidth","borderRadius","borderColor","switchBorderColor","borderWidth","borderRightWidth","alignItems","selectedButton","switchActiveTextColor","switchActiveBgColor","firstButton","borderTopLeftRadius","borderBottomLeftRadius","borderTopRightRadius","borderBottomRightRadius","lastButton","OS","borderLeftWidth"],"sources":["switch.styles.ts"],"sourcesContent":["import 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 { Platform } from 'react-native';\n\nexport type WmSwitchStyles = BaseStyles & {\n loadingIcon: WmIconStyles,\n button: AllStyle,\n selectedButton: AllStyle,\n firstButton: AllStyle,\n lastButton: AllStyle\n};\n\nexport const DEFAULT_CLASS = 'app-switch';\nBASE_THEME.registerStyle((themeVariables, addStyle) => {\n const defaultStyles: WmSwitchStyles = defineStyles<WmSwitchStyles>({\n root: {\n height: 38,\n flexDirection: 'row'\n },\n text: {\n fontWeight: '500',\n fontSize: 16,\n textTransform: 'capitalize'\n },\n loadingIcon: {\n root: {\n flex: 1,\n alignSelf: 'center',\n justifyContent: 'center',\n fontSize: 16\n },\n text: {\n color: themeVariables.listSubTitleColor\n }\n } as WmIconStyles,\n button: {\n backgroundColor: themeVariables.switchBgColor,\n color: themeVariables.switchTextColor,\n fontSize: 16,\n minWidth: 64,\n borderRadius: 0,\n borderColor: themeVariables.switchBorderColor,\n borderWidth: 1,\n borderRightWidth: 0,\n fontWeight: 'bold',\n justifyContent: 'center',\n alignItems: 'center'\n } as AllStyle,\n selectedButton: {\n color: themeVariables.switchActiveTextColor,\n backgroundColor: themeVariables.switchActiveBgColor,\n borderColor: themeVariables.switchActiveBgColor\n } as AllStyle,\n firstButton: {\n borderTopLeftRadius: 6,\n borderBottomLeftRadius: 6,\n borderTopRightRadius: 0,\n borderBottomRightRadius: 0\n } as AllStyle,\n lastButton: {\n borderTopLeftRadius: 0,\n borderBottomLeftRadius: 0,\n borderTopRightRadius: 6,\n borderBottomRightRadius: 6,\n borderRightWidth: 1\n } as AllStyle\n });\n\n addStyle(DEFAULT_CLASS, '', defaultStyles);\n addStyle(DEFAULT_CLASS + '-disabled', '', {\n root: {}\n });\n addStyle(DEFAULT_CLASS + '-rtl', '', Platform.OS==\"web\"?{\n firstButton:{\n borderTopLeftRadius: 0,\n borderBottomLeftRadius: 0,\n borderTopRightRadius: 6,\n borderBottomRightRadius: 6,\n borderRightWidth: 1,\n borderLeftWidth: 0\n } ,\n lastButton:{\n borderTopLeftRadius: 6,\n borderBottomLeftRadius: 6,\n borderTopRightRadius: 0,\n borderBottomRightRadius: 0,\n borderRightWidth: 0\n }\n }:{});\n addStyle(DEFAULT_CLASS + '1-rtl', '', Platform.OS==\"web\"?{\n firstButton:{\n borderTopLeftRadius: 0,\n borderBottomLeftRadius: 0,\n borderTopRightRadius: 500,\n borderBottomRightRadius: 500,\n borderRightWidth: 0,\n borderLeftWidth: 1\n } ,\n lastButton:{\n flex: 1,\n borderTopLeftRadius: 500,\n borderBottomLeftRadius: 500,\n borderTopRightRadius: 0,\n borderBottomRightRadius: 0,\n borderRightWidth: 1\n }\n }:{});\n addStyle(DEFAULT_CLASS + '1', '', {\n firstButton: {\n borderTopLeftRadius: 500,\n borderBottomLeftRadius: 500,\n borderTopRightRadius: 0,\n borderBottomRightRadius: 0\n } as AllStyle,\n lastButton: {\n flex: 1,\n borderTopLeftRadius: 0,\n borderBottomLeftRadius: 0,\n borderTopRightRadius: 500,\n borderBottomRightRadius: 500\n } as AllStyle\n } as WmSwitchStyles);\n});"],"mappings":"AAAA,OAAOA,UAAU,MAAkB,wCAAwC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C;MACvBC,uBAAuB,EAAE,CAAC;MAC1BT,gBAAgB,EAAE;IACpB;EACF,CAAC,GAAC,CAAC,CAAC,CAAC;EACLxB,QAAQ,CAACH,aAAa,GAAG,GAAG,EAAE,EAAE,EAAE;IAChCgC,WAAW,EAAE;MACXC,mBAAmB,EAAE,GAAG;MACxBC,sBAAsB,EAAE,GAAG;MAC3BC,oBAAoB,EAAE,CAAC;MACvBC,uBAAuB,EAAE;IAC3B,CAAa;IACbC,UAAU,EAAE;MACVxB,IAAI,EAAE,CAAC;MACPoB,mBAAmB,EAAE,CAAC;MACtBC,sBAAsB,EAAE,CAAC;MACzBC,oBAAoB,EAAE,GAAG;MACzBC,uBAAuB,EAAE;IAC3B;EACF,CAAmB,CAAC;AACtB,CAAC,CAAC"}
@@ -1,8 +1,9 @@
1
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); }
2
2
  import React from 'react';
3
- import { Platform, TextInput } from 'react-native';
3
+ import { Platform } from 'react-native';
4
4
  import WmTextProps from './text.props';
5
5
  import { DEFAULT_CLASS } from './text.styles';
6
+ import { WMTextInput } from '@wavemaker/app-rn-runtime/core/components/textinput.component';
6
7
  import { BaseInputComponent, BaseInputState } from "@wavemaker/app-rn-runtime/components/input/baseinput/baseinput.component";
7
8
  import { isNull } from 'lodash';
8
9
  export class WmTextState extends BaseInputState {}
@@ -15,7 +16,7 @@ export default class WmText extends BaseInputComponent {
15
16
  let opts = {};
16
17
  const valueExpr = Platform.OS === 'web' ? 'value' : 'defaultValue';
17
18
  opts[valueExpr] = ((_this$state$textValue = this.state.textValue) === null || _this$state$textValue === void 0 ? void 0 : _this$state$textValue.toString()) || '';
18
- return /*#__PURE__*/React.createElement(TextInput, _extends({
19
+ return /*#__PURE__*/React.createElement(WMTextInput, _extends({
19
20
  ref: ref => {
20
21
  this.widgetRef = ref;
21
22
  // @ts-ignore
@@ -38,7 +39,8 @@ export default class WmText extends BaseInputComponent {
38
39
  onFocus: this.onFocus.bind(this),
39
40
  onKeyPress: this.onKeyPress.bind(this),
40
41
  onChangeText: this.onChangeText.bind(this),
41
- onChange: this.invokeChange.bind(this)
42
+ onChange: this.invokeChange.bind(this),
43
+ allowContentSelection: this.styles.text.userSelect === 'text'
42
44
  }));
43
45
  }
44
46
  }
@@ -1 +1 @@
1
- {"version":3,"names":["React","Platform","TextInput","WmTextProps","DEFAULT_CLASS","BaseInputComponent","BaseInputState","isNull","WmTextState","WmText","constructor","props","renderWidget","opts","valueExpr","OS","state","textValue","toString","ref","widgetRef","selectionStart","selectionEnd","cursor","styles","placeholderText","color","root","isValid","invalid","keyboardType","autocomplete","autofocus","disabled","readonly","type","maxchars","placeholder","onBlur","bind","onFocus","onKeyPress","onChangeText","invokeChange"],"sources":["text.component.tsx"],"sourcesContent":["import React from 'react';\nimport { Platform, TextInput } from 'react-native';\n\nimport WmTextProps from './text.props';\nimport { DEFAULT_CLASS, WmTextStyles } from './text.styles';\nimport { BaseInputComponent, BaseInputState } from \"@wavemaker/app-rn-runtime/components/input/baseinput/baseinput.component\";\nimport { isNull } from 'lodash';\nimport { createSkeleton } from '../../basic/skeleton/skeleton.component';\n\nexport class WmTextState extends BaseInputState<WmTextProps> {\n}\n\nexport default class WmText extends BaseInputComponent<WmTextProps, WmTextState, WmTextStyles> {\n\n constructor(props: WmTextProps) {\n super(props, DEFAULT_CLASS, new WmTextProps(), new WmTextState());\n }\n\n renderWidget(props: WmTextProps) {\n let opts: any = {};\n const valueExpr = Platform.OS === 'web' ? 'value' : 'defaultValue';\n opts[valueExpr] = this.state.textValue?.toString() || '';\n return (\n <TextInput\n ref={ref => {this.widgetRef = ref;\n // @ts-ignore\n if (ref && !isNull(ref.selectionStart) && !isNull(ref.selectionEnd)) {\n // @ts-ignore\n ref.selectionStart = ref.selectionEnd = this.cursor;\n }}}\n {...opts}\n placeholderTextColor={this.styles.placeholderText.color as any}\n style={[this.styles.root, this.state.isValid ? {} : this.styles.invalid]}\n keyboardType={this.state.keyboardType}\n autoComplete={props.autocomplete ? 'username' : 'off'}\n autoFocus={props.autofocus}\n editable={props.disabled || props.readonly ? false : true}\n secureTextEntry={props.type === 'password' ? true : false}\n maxLength={props.maxchars}\n placeholder={props.placeholder}\n onBlur={this.onBlur.bind(this)}\n onFocus={this.onFocus.bind(this)}\n onKeyPress={this.onKeyPress.bind(this)}\n onChangeText={this.onChangeText.bind(this)}\n onChange={this.invokeChange.bind(this)}\n />\n );\n }\n}\n"],"mappings":";AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,SAASC,QAAQ,EAAEC,SAAS,QAAQ,cAAc;AAElD,OAAOC,WAAW,MAAM,cAAc;AACtC,SAASC,aAAa,QAAsB,eAAe;AAC3D,SAASC,kBAAkB,EAAEC,cAAc,QAAQ,0EAA0E;AAC7H,SAASC,MAAM,QAAQ,QAAQ;AAG/B,OAAO,MAAMC,WAAW,SAASF,cAAc,CAAc;AAG7D,eAAe,MAAMG,MAAM,SAASJ,kBAAkB,CAAyC;EAE7FK,WAAW,CAACC,KAAkB,EAAE;IAC9B,KAAK,CAACA,KAAK,EAAEP,aAAa,EAAE,IAAID,WAAW,EAAE,EAAE,IAAIK,WAAW,EAAE,CAAC;EACnE;EAEAI,YAAY,CAACD,KAAkB,EAAE;IAAA;IAC/B,IAAIE,IAAS,GAAG,CAAC,CAAC;IAClB,MAAMC,SAAS,GAAGb,QAAQ,CAACc,EAAE,KAAK,KAAK,GAAG,OAAO,GAAG,cAAc;IAClEF,IAAI,CAACC,SAAS,CAAC,GAAG,8BAAI,CAACE,KAAK,CAACC,SAAS,0DAApB,sBAAsBC,QAAQ,EAAE,KAAI,EAAE;IACxD,oBACI,oBAAC,SAAS;MACR,GAAG,EAAEC,GAAG,IAAI;QAAC,IAAI,CAACC,SAAS,GAAGD,GAAG;QAC/B;QACF,IAAIA,GAAG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S","WMTextInput","BaseInputComponent","BaseInputState","isNull","WmTextState","WmText","constructor","props","renderWidget","_this$state$textValue","opts","valueExpr","OS","state","textValue","toString","createElement","_extends","ref","widgetRef","selectionStart","selectionEnd","cursor","placeholderTextColor","styles","placeholderText","color","style","root","isValid","invalid","keyboardType","autoComplete","autocomplete","autoFocus","autofocus","editable","disabled","readonly","secureTextEntry","type","maxLength","maxchars","placeholder","onBlur","bind","onFocus","onKeyPress","onChangeText","onChange","invokeChange","allowContentSelection","text","userSelect"],"sources":["text.component.tsx"],"sourcesContent":["import React from 'react';\nimport { Platform } from 'react-native';\n\nimport WmTextProps from './text.props';\nimport { DEFAULT_CLASS, WmTextStyles } from './text.styles';\nimport { WMTextInput } from '@wavemaker/app-rn-runtime/core/components/textinput.component';\nimport { BaseInputComponent, BaseInputState } from \"@wavemaker/app-rn-runtime/components/input/baseinput/baseinput.component\";\nimport { isNull } from 'lodash';\n\nexport class WmTextState extends BaseInputState<WmTextProps> {\n}\n\nexport default class WmText extends BaseInputComponent<WmTextProps, WmTextState, WmTextStyles> {\n\n constructor(props: WmTextProps) {\n super(props, DEFAULT_CLASS, new WmTextProps(), new WmTextState());\n }\n\n renderWidget(props: WmTextProps) {\n let opts: any = {};\n const valueExpr = Platform.OS === 'web' ? 'value' : 'defaultValue';\n opts[valueExpr] = this.state.textValue?.toString() || '';\n return (\n <WMTextInput\n ref={(ref: any) => {this.widgetRef = ref;\n // @ts-ignore\n if (ref && !isNull(ref.selectionStart) && !isNull(ref.selectionEnd)) {\n // @ts-ignore\n ref.selectionStart = ref.selectionEnd = this.cursor;\n }}}\n {...opts}\n placeholderTextColor={this.styles.placeholderText.color as any}\n style={[this.styles.root, this.state.isValid ? {} : this.styles.invalid]}\n keyboardType={this.state.keyboardType}\n autoComplete={props.autocomplete ? 'username' : 'off'}\n autoFocus={props.autofocus}\n editable={props.disabled || props.readonly ? false : true}\n secureTextEntry={props.type === 'password' ? true : false}\n maxLength={props.maxchars}\n placeholder={props.placeholder}\n onBlur={this.onBlur.bind(this)}\n onFocus={this.onFocus.bind(this)}\n onKeyPress={this.onKeyPress.bind(this)}\n onChangeText={this.onChangeText.bind(this)}\n onChange={this.invokeChange.bind(this)}\n allowContentSelection={this.styles.text.userSelect === 'text'}\n />\n );\n }\n}\n"],"mappings":";AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,SAASC,QAAQ,QAAQ,cAAc;AAEvC,OAAOC,WAAW,MAAM,cAAc;AACtC,SAASC,aAAa,QAAsB,eAAe;AAC3D,SAASC,WAAW,QAAQ,+DAA+D;AAC3F,SAASC,kBAAkB,EAAEC,cAAc,QAAQ,0EAA0E;AAC7H,SAASC,MAAM,QAAQ,QAAQ;AAE/B,OAAO,MAAMC,WAAW,SAASF,cAAc,CAAc;AAG7D,eAAe,MAAMG,MAAM,SAASJ,kBAAkB,CAAyC;EAE7FK,WAAWA,CAACC,KAAkB,EAAE;IAC9B,KAAK,CAACA,KAAK,EAAER,aAAa,EAAE,IAAID,WAAW,CAAC,CAAC,EAAE,IAAIM,WAAW,CAAC,CAAC,CAAC;EACnE;EAEAI,YAAYA,CAACD,KAAkB,EAAE;IAAA,IAAAE,qBAAA;IAC/B,IAAIC,IAAS,GAAG,CAAC,CAAC;IAClB,MAAMC,SAAS,GAAGd,QAAQ,CAACe,EAAE,KAAK,KAAK,GAAG,OAAO,GAAG,cAAc;IAClEF,IAAI,CAACC,SAAS,CAAC,GAAG,EAAAF,qBAAA,OAAI,CAACI,KAAK,CAACC,SAAS,cAAAL,qBAAA,uBAApBA,qBAAA,CAAsBM,QAAQ,CAAC,CAAC,KAAI,EAAE;IACxD,oBACInB,KAAA,CAAAoB,aAAA,CAAChB,WAAW,EAAAiB,QAAA;MACVC,GAAG,EAAGA,GAAQ,IAAK;QAAC,IAAI,CAACC,SAAS,GAAGD,GAAG;QACtC;QACF,IAAIA,GAAG,IAAI,CAACf,MAAM,CAACe,GAAG,CAACE,cAAc,CAAC,IAAI,CAACjB,MAAM,CAACe,GAA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 @@
1
- {"version":3,"names":["BaseInputProps","WmTextProps"],"sources":["text.props.ts"],"sourcesContent":["import BaseInputProps from \"@wavemaker/app-rn-runtime/components/input/baseinput/baseinput.props\";\n\nexport default class WmTextProps extends BaseInputProps {\n placeholder: string = 'Enter text';\n}\n"],"mappings":";;;AAAA,OAAOA,cAAc,MAAM,sEAAsE;AAEjG,eAAe,MAAMC,WAAW,SAASD,cAAc,CAAC;EAAA;IAAA;IAAA,qCAChC,YAAY;EAAA;AACpC"}
1
+ {"version":3,"names":["BaseInputProps","WmTextProps","constructor","arguments","_defineProperty"],"sources":["text.props.ts"],"sourcesContent":["import BaseInputProps from \"@wavemaker/app-rn-runtime/components/input/baseinput/baseinput.props\";\n\nexport default class WmTextProps extends BaseInputProps {\n placeholder: string = 'Enter text';\n}\n"],"mappings":";;;AAAA,OAAOA,cAAc,MAAM,sEAAsE;AAEjG,eAAe,MAAMC,WAAW,SAASD,cAAc,CAAC;EAAAE,YAAA;IAAA,SAAAC,SAAA;IAAAC,eAAA,sBAChC,YAAY;EAAA;AACpC"}
@@ -35,5 +35,10 @@ BASE_THEME.registerStyle((themeVariables, addStyle) => {
35
35
  backgroundColor: themeVariables.inputDisabledBgColor
36
36
  }
37
37
  });
38
+ addStyle(DEFAULT_CLASS + '-rtl', '', {
39
+ root: {
40
+ textAlign: 'right'
41
+ }
42
+ });
38
43
  });
39
44
  //# sourceMappingURL=text.styles.js.map
@@ -1 +1 @@
1
- {"version":3,"names":["BASE_THEME","defineStyles","DEFAULT_CLASS","registerStyle","themeVariables","addStyle","defaultStyles","root","padding","borderWidth","borderStyle","borderColor","inputBorderColor","backgroundColor","inputBackgroundColor","borderRadius","fontFamily","baseFont","text","fontSize","invalid","borderBottomColor","inputInvalidBorderColor","placeholderText","color","inputPlaceholderColor","skeleton","width","height","inputDisabledBgColor"],"sources":["text.styles.ts"],"sourcesContent":["import BASE_THEME, {AllStyle, Theme} from '@wavemaker/app-rn-runtime/styles/theme';\nimport { BaseStyles, defineStyles } from '@wavemaker/app-rn-runtime/core/base.component';\nimport {ColorValue} from \"react-native\";\nimport { WmSkeletonStyles } from '../../basic/skeleton/skeleton.styles';\n\nexport type WmTextStyles = BaseStyles & {\n invalid: AllStyle;\n placeholderText: AllStyle;\n skeleton: WmSkeletonStyles\n};\n\nexport const DEFAULT_CLASS = 'app-text';\nBASE_THEME.registerStyle((themeVariables, addStyle) => {\n const defaultStyles: WmTextStyles = defineStyles({\n root: {\n padding: 12,\n borderWidth: 1,\n borderStyle: 'solid',\n borderColor: themeVariables.inputBorderColor,\n backgroundColor: themeVariables.inputBackgroundColor,\n borderRadius: 6,\n fontFamily: themeVariables.baseFont\n },\n text: {\n fontSize: 16\n },\n invalid: {\n borderBottomColor: themeVariables.inputInvalidBorderColor\n },\n placeholderText: {\n color: themeVariables.inputPlaceholderColor\n },\n skeleton: {\n root: {\n width: '100%',\n height: 16,\n borderRadius: 4\n }\n } as WmSkeletonStyles\n });\n\n addStyle(DEFAULT_CLASS, '', defaultStyles);\n addStyle(DEFAULT_CLASS + '-disabled', '', {\n root : {\n backgroundColor: themeVariables.inputDisabledBgColor\n }\n });\n});"],"mappings":"AAAA,OAAOA,UAAU,MAAyB,wCAAwC;AAClF,SAAqBC,YAAY,QAAQ,+CAA+C;AAUxF,OAAO,MAAMC,aAAa,GAAG,UAAU;AACvCF,UAAU,CAACG,aAAa,CAAC,CAACC,cAAc,EAAEC,QAAQ,KAAK;EACrD,MAAMC,aAA2B,GAAGL,YAAY,CAAC;IAC7CM,IAAI,EAAE;MACJC,OAAO,EAAE,EAAE;MACXC,WAAW,EAAE,CAAC;MACdC,WAAW,EAAE,OAAO;MACpBC,WAAW,EAAEP,cAAc,CAACQ,gBAAgB;MAC5CC,eAAe,EAAET,cAAc,CAACU,oBAAoB;MACpDC,YAAY,EAAE,CAAC;MACfC,UAAU,EAAEZ,cAAc,CAACa;IAC7B,CAAC;IACDC,IAAI,EAAE;MACJC,QAAQ,EAAE;IACZ,CAAC;IACDC,OAAO,EAAE;MACPC,iBAAiB,EAAEjB,cAAc,CAACkB;IACpC,CAAC;IACDC,eAAe,EAAE;MACjBC,KAAK,EAAEpB,cAAc,CAACqB;IACtB,CAAC;IACDC,QAAQ,EAAE;MACRnB,IAAI,EAAE;QACJoB,KAAK,EAAE,MAAM;QACbC,MAAM,EAAE,EAAE;QACVb,YAAY,EAAE;MAChB;IACF;EACJ,CAAC,CAAC;EAEFV,QAAQ,CAACH,aAAa,EAAE,EAAE,EAAEI,aAAa,CAAC;EAC1CD,QAAQ,CAACH,aAAa,GAAG,WAAW,EAAE,EAAE,EAAE;IACtCK,IAAI,EAAG;MACLM,eAAe,EAAET,cAAc,CAACyB;IAClC;EACJ,CAAC,CAAC;AACJ,CAAC,CAAC"}
1
+ {"version":3,"names":["BASE_THEME","defineStyles","DEFAULT_CLASS","registerStyle","themeVariables","addStyle","defaultStyles","root","padding","borderWidth","borderStyle","borderColor","inputBorderColor","backgroundColor","inputBackgroundColor","borderRadius","fontFamily","baseFont","text","fontSize","invalid","borderBottomColor","inputInvalidBorderColor","placeholderText","color","inputPlaceholderColor","skeleton","width","height","inputDisabledBgColor","textAlign"],"sources":["text.styles.ts"],"sourcesContent":["import BASE_THEME, {AllStyle, Theme} from '@wavemaker/app-rn-runtime/styles/theme';\nimport { BaseStyles, defineStyles } from '@wavemaker/app-rn-runtime/core/base.component';\nimport {ColorValue} from \"react-native\";\nimport { WmSkeletonStyles } from '../../basic/skeleton/skeleton.styles';\n\nexport type WmTextStyles = BaseStyles & {\n invalid: AllStyle;\n placeholderText: AllStyle;\n skeleton: WmSkeletonStyles\n};\n\nexport const DEFAULT_CLASS = 'app-text';\nBASE_THEME.registerStyle((themeVariables, addStyle) => {\n const defaultStyles: WmTextStyles = defineStyles({\n root: {\n padding: 12,\n borderWidth: 1,\n borderStyle: 'solid',\n borderColor: themeVariables.inputBorderColor,\n backgroundColor: themeVariables.inputBackgroundColor,\n borderRadius: 6,\n fontFamily: themeVariables.baseFont\n },\n text: {\n fontSize: 16\n },\n invalid: {\n borderBottomColor: themeVariables.inputInvalidBorderColor\n },\n placeholderText: {\n color: themeVariables.inputPlaceholderColor\n },\n skeleton: {\n root: {\n width: '100%',\n height: 16,\n borderRadius: 4\n }\n } as any as WmSkeletonStyles\n });\n\n addStyle(DEFAULT_CLASS, '', defaultStyles);\n addStyle(DEFAULT_CLASS + '-disabled', '', {\n root : {\n backgroundColor: themeVariables.inputDisabledBgColor\n }\n });\n addStyle(DEFAULT_CLASS + '-rtl', '', {\n root:{\n textAlign: 'right'\n }\n })\n});"],"mappings":"AAAA,OAAOA,UAAU,MAAyB,wCAAwC;AAClF,SAAqBC,YAAY,QAAQ,+CAA+C;AAUxF,OAAO,MAAMC,aAAa,GAAG,UAAU;AACvCF,UAAU,CAACG,aAAa,CAAC,CAACC,cAAc,EAAEC,QAAQ,KAAK;EACrD,MAAMC,aAA2B,GAAGL,YAAY,CAAC;IAC7CM,IAAI,EAAE;MACJC,OAAO,EAAE,EAAE;MACXC,WAAW,EAAE,CAAC;MACdC,WAAW,EAAE,OAAO;MACpBC,WAAW,EAAEP,cAAc,CAACQ,gBAAgB;MAC5CC,eAAe,EAAET,cAAc,CAACU,oBAAoB;MACpDC,YAAY,EAAE,CAAC;MACfC,UAAU,EAAEZ,cAAc,CAACa;IAC7B,CAAC;IACDC,IAAI,EAAE;MACJC,QAAQ,EAAE;IACZ,CAAC;IACDC,OAAO,EAAE;MACPC,iBAAiB,EAAEjB,cAAc,CAACkB;IACpC,CAAC;IACDC,eAAe,EAAE;MACjBC,KAAK,EAAEpB,cAAc,CAACqB;IACtB,CAAC;IACDC,QAAQ,EAAE;MACRnB,IAAI,EAAE;QACJoB,KAAK,EAAE,MAAM;QACbC,MAAM,EAAE,EAAE;QACVb,YAAY,EAAE;MAChB;IACF;EACJ,CAAC,CAAC;EAEFV,QAAQ,CAACH,aAAa,EAAE,EAAE,EAAEI,aAAa,CAAC;EAC1CD,QAAQ,CAACH,aAAa,GAAG,WAAW,EAAE,EAAE,EAAE;IACtCK,IAAI,EAAG;MACLM,eAAe,EAAET,cAAc,CAACyB;IAClC;EACJ,CAAC,CAAC;EACFxB,QAAQ,CAACH,aAAa,GAAG,MAAM,EAAE,EAAE,EAAE;IACjCK,IAAI,EAAC;MACHuB,SAAS,EAAE;IACb;EACJ,CAAC,CAAC;AACJ,CAAC,CAAC"}
@@ -1,9 +1,10 @@
1
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); }
2
2
  import React from 'react';
3
- import { Platform, TextInput } from 'react-native';
3
+ import { Platform } from 'react-native';
4
4
  import WmTextareaProps from './textarea.props';
5
5
  import { DEFAULT_CLASS } from './textarea.styles';
6
6
  import { BaseInputComponent, BaseInputState } from '@wavemaker/app-rn-runtime/components/input/baseinput/baseinput.component';
7
+ import { WMTextInput } from '@wavemaker/app-rn-runtime/core/components/textinput.component';
7
8
  import { isNull } from 'lodash';
8
9
  export class WmTextareaState extends BaseInputState {}
9
10
  export default class WmTextarea extends BaseInputComponent {
@@ -15,7 +16,7 @@ export default class WmTextarea extends BaseInputComponent {
15
16
  let opts = {};
16
17
  const valueExpr = Platform.OS === 'web' ? 'value' : 'defaultValue';
17
18
  opts[valueExpr] = ((_this$state$textValue = this.state.textValue) === null || _this$state$textValue === void 0 ? void 0 : _this$state$textValue.toString()) || '';
18
- return /*#__PURE__*/React.createElement(TextInput, _extends({
19
+ return /*#__PURE__*/React.createElement(WMTextInput, _extends({
19
20
  ref: ref => {
20
21
  this.widgetRef = ref;
21
22
  // @ts-ignore
@@ -39,7 +40,8 @@ export default class WmTextarea extends BaseInputComponent {
39
40
  onFocus: this.onFocus.bind(this),
40
41
  onKeyPress: this.onKeyPress.bind(this),
41
42
  onChangeText: this.onChangeText.bind(this),
42
- onChange: this.invokeChange.bind(this)
43
+ onChange: this.invokeChange.bind(this),
44
+ allowContentSelection: this.styles.text.userSelect === 'text'
43
45
  }));
44
46
  }
45
47
  }
@@ -1 +1 @@
1
- {"version":3,"names":["React","Platform","TextInput","WmTextareaProps","DEFAULT_CLASS","BaseInputComponent","BaseInputState","isNull","WmTextareaState","WmTextarea","constructor","props","renderWidget","opts","valueExpr","OS","state","textValue","toString","ref","widgetRef","selectionStart","selectionEnd","cursor","styles","placeholderText","color","root","text","isValid","invalid","keyboardType","autocomplete","autofocus","disabled","readonly","maxchars","placeholder","onBlur","bind","onFocus","onKeyPress","onChangeText","invokeChange"],"sources":["textarea.component.tsx"],"sourcesContent":["import React from 'react';\nimport { Platform, TextInput } from 'react-native';\nimport WmTextareaProps from './textarea.props';\nimport { DEFAULT_CLASS, WmTextareaStyles } from './textarea.styles';\nimport {\n BaseInputComponent,\n BaseInputState\n} from '@wavemaker/app-rn-runtime/components/input/baseinput/baseinput.component';\nimport { isNull } from 'lodash';\nimport { createSkeleton } from '../../basic/skeleton/skeleton.component';\n\nexport class WmTextareaState extends BaseInputState<WmTextareaProps> {}\n\nexport default class WmTextarea extends BaseInputComponent<WmTextareaProps, WmTextareaState, WmTextareaStyles> {\n\n constructor(props: WmTextareaProps) {\n super(props, DEFAULT_CLASS, new WmTextareaProps(), new WmTextareaState());\n }\n\n renderWidget(props: WmTextareaProps) {\n let opts: any = {};\n const valueExpr = Platform.OS === 'web' ? 'value' : 'defaultValue';\n opts[valueExpr] = this.state.textValue?.toString() || '';\n return ( <TextInput\n ref={ref => {this.widgetRef = ref;\n // @ts-ignore\n if (ref && !isNull(ref.selectionStart) && !isNull(ref.selectionEnd)) {\n // @ts-ignore\n ref.selectionStart = ref.selectionEnd = this.cursor;\n }}}\n placeholderTextColor={this.styles.placeholderText.color as any}\n style={[this.styles.root, this.styles.text, this.state.isValid ? {} : this.styles.invalid]}\n multiline={true}\n numberOfLines={4}\n keyboardType={this.state.keyboardType}\n {...opts}\n autoComplete={props.autocomplete ? 'username' : 'off'}\n autoFocus={props.autofocus}\n editable={props.disabled || props.readonly ? false : true}\n maxLength={props.maxchars}\n placeholder={props.placeholder || 'Place your text'}\n onBlur={this.onBlur.bind(this)}\n onFocus={this.onFocus.bind(this)}\n onKeyPress={this.onKeyPress.bind(this)}\n onChangeText={this.onChangeText.bind(this)}\n onChange={this.invokeChange.bind(this)}\n />);\n }\n}\n"],"mappings":";AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,SAASC,QAAQ,EAAEC,SAAS,QAAQ,cAAc;AAClD,OAAOC,eAAe,MAAM,kBAAkB;AAC9C,SAASC,aAAa,QAA0B,mBAAmB;AACnE,SACEC,kBAAkB,EAClBC,cAAc,QACT,0EAA0E;AACjF,SAASC,MAAM,QAAQ,QAAQ;AAG/B,OAAO,MAAMC,eAAe,SAASF,cAAc,CAAkB;AAErE,eAAe,MAAMG,UAAU,SAASJ,kBAAkB,CAAqD;EAE7GK,WAAW,CAACC,KAAsB,EAAE;IAClC,KAAK,CAACA,KAAK,EAAEP,aAAa,EAAE,IAAID,eAAe,EAAE,EAAE,IAAIK,eAAe,EAAE,CAAC;EAC3E;EAEAI,YAAY,CAACD,KAAsB,EAAE;IAAA;IACnC,IAAIE,IAAS,GAAG,CAAC,CAAC;IAClB,MAAMC,SAAS,GAAGb,QAAQ,CAACc,EAAE,KAAK,KAAK,GAAG,OAAO,GAAG,cAAc;IAClEF,IAAI,CAACC,SAAS,CAAC,GAAG,8BAAI,CAACE,KAAK,CAACC,SAAS,0DAApB,sBAAsBC,QAAQ,EAAE,KAAI,EAAE;IACxD,oBAAS,oBAAC,SAAS;MACjB,GAAG,EAAEC,GAAG,IAAI;QAAC,IAAI,CAACC,SAAS,GAAGD,GAAG;QAC/B;QACA,IAAIA,GAAG,IAAI,CAACZ,MAAM,CAACY,GAAG,CAACE,cAAc,CAAC,IAAI,CAACd,MAAM,CAACY,GAAG,CAACG,YAAY,CAAC,EAAE;UACnE;UACAH,GAAG,CAACE,cAAc,GAAGF,GAAG,CAACG,YAAY,GAAG,IAAI,CAACC,MAAM;QACrD;MAAC,CAAE;MACL,oBAAoB,EAAE,IAAI,CAACC,MAAM,CAACC,eAAe,CAACC,KAAa;MAC/D,KAAK,EAAE,CAAC,IAAI,CAACF,MAAM,CAACG,IAAI,EAAE,IAAI,CAACH,MAAM,CAACI,IAAI,EAAE,IAAI,CAACZ,KAAK,CAACa,OAAO,GAAG,CAAC,CAAC,GAAG,IAAI,CAACL,MAAM,CAACM,OAAO,CAAE;MAC3F,SAAS,EAAE,IAAK;MAChB,aAAa,EAAE,CAAE;MACjB,YAAY,EAAE,IAAI,CAACd,KAAK,CAACe;IAAa,GAClClB,IAAI;MACR,YAAY,EAAEF,KAAK,CAACqB,YAAY,GAAG,UAAU,GAAG,KAAM;MACtD,SAAS,EAAErB,KAAK,CAACsB,SAAU;MAC3B,QAAQ,EAAEtB,KAAK,CAACuB,QAAQ,IAAIvB,KAAK,CAACwB,QAAQ,GAAG,KAAK,GAAG,IAAK;MAC1D,SAAS,EAAExB,KAAK,CAACyB,QAAS;MAC1B,WAAW,EAAEzB,KAAK,CAAC0B,WAAW,IAAI,iBAAkB;MACpD,MAAM,EAAE,IAAI,CAACC,MAAM,CAACC,IAAI,CAAC,IAAI,CAAE;MAC/B,OAAO,EAAE,IAAI,CAACC,OAAO,CAACD,IAAI,CAAC,IAAI,CAAE;MACjC,UAAU,EAAE,IAAI,CAACE,UAAU,CAACF,IAAI,CAAC,IAAI,CAAE;MACvC,YAAY,EAAE,IAAI,CAACG,YAAY,CAACH,IAAI,CAAC,IAAI,CAAE;MAC3C,QAAQ,EAAE,IAAI,CAACI,YAAY,CAACJ,IAAI,CAAC,IAAI;IAAE,GACvC;EACJ;AACF"}
1
+ {"version":3,"names":["React","Platform","WmTextareaProps","DEFAULT_CLASS","BaseInputComponent","BaseInputState","WMTextInput","isNull","WmTextareaState","WmTextarea","constructor","props","renderWidget","_this$state$textValue","opts","valueExpr","OS","state","textValue","toString","createElement","_extends","ref","widgetRef","selectionStart","selectionEnd","cursor","placeholderTextColor","styles","placeholderText","color","style","root","text","isValid","invalid","multiline","numberOfLines","keyboardType","autoComplete","autocomplete","autoFocus","autofocus","editable","disabled","readonly","maxLength","maxchars","placeholder","onBlur","bind","onFocus","onKeyPress","onChangeText","onChange","invokeChange","allowContentSelection","userSelect"],"sources":["textarea.component.tsx"],"sourcesContent":["import React from 'react';\nimport { Platform, TextInput, View } from 'react-native';\nimport WmTextareaProps from './textarea.props';\nimport { DEFAULT_CLASS, WmTextareaStyles } from './textarea.styles';\nimport {\n BaseInputComponent,\n BaseInputState\n} from '@wavemaker/app-rn-runtime/components/input/baseinput/baseinput.component';\nimport { WMTextInput } from '@wavemaker/app-rn-runtime/core/components/textinput.component';\nimport { isNull } from 'lodash';\n\nexport class WmTextareaState extends BaseInputState<WmTextareaProps> {}\n\nexport default class WmTextarea extends BaseInputComponent<WmTextareaProps, WmTextareaState, WmTextareaStyles> {\n\n constructor(props: WmTextareaProps) {\n super(props, DEFAULT_CLASS, new WmTextareaProps(), new WmTextareaState());\n }\n\n renderWidget(props: WmTextareaProps) {\n let opts: any = {};\n const valueExpr = Platform.OS === 'web' ? 'value' : 'defaultValue';\n opts[valueExpr] = this.state.textValue?.toString() || '';\n return ( <WMTextInput\n ref={(ref: any) => {this.widgetRef = ref;\n // @ts-ignore\n if (ref && !isNull(ref.selectionStart) && !isNull(ref.selectionEnd)) {\n // @ts-ignore\n ref.selectionStart = ref.selectionEnd = this.cursor;\n }}}\n placeholderTextColor={this.styles.placeholderText.color as any}\n style={[this.styles.root, this.styles.text, this.state.isValid ? {} : this.styles.invalid]}\n multiline={true}\n numberOfLines={4}\n keyboardType={this.state.keyboardType}\n {...opts}\n autoComplete={props.autocomplete ? 'username' : 'off'}\n autoFocus={props.autofocus}\n editable={props.disabled || props.readonly ? false : true}\n maxLength={props.maxchars}\n placeholder={props.placeholder || 'Place your text'}\n onBlur={this.onBlur.bind(this)}\n onFocus={this.onFocus.bind(this)}\n onKeyPress={this.onKeyPress.bind(this)}\n onChangeText={this.onChangeText.bind(this)}\n onChange={this.invokeChange.bind(this)}\n allowContentSelection={this.styles.text.userSelect === 'text'}\n />);\n }\n}\n"],"mappings":";AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,SAASC,QAAQ,QAAyB,cAAc;AACxD,OAAOC,eAAe,MAAM,kBAAkB;AAC9C,SAASC,aAAa,QAA0B,mBAAmB;AACnE,SACEC,kBAAkB,EAClBC,cAAc,QACT,0EAA0E;AACjF,SAASC,WAAW,QAAQ,+DAA+D;AAC3F,SAASC,MAAM,QAAQ,QAAQ;AAE/B,OAAO,MAAMC,eAAe,SAASH,cAAc,CAAkB;AAErE,eAAe,MAAMI,UAAU,SAASL,kBAAkB,CAAqD;EAE7GM,WAAWA,CAACC,KAAsB,EAAE;IAClC,KAAK,CAACA,KAAK,EAAER,aAAa,EAAE,IAAID,eAAe,CAAC,CAAC,EAAE,IAAIM,eAAe,CAAC,CAAC,CAAC;EAC3E;EAEAI,YAAYA,CAACD,KAAsB,EAAE;IAAA,IAAAE,qBAAA;IACnC,IAAIC,IAAS,GAAG,CAAC,CAAC;IAClB,MAAMC,SAAS,GAAGd,QAAQ,CAACe,EAAE,KAAK,KAAK,GAAG,OAAO,GAAG,cAAc;IAClEF,IAAI,CAACC,SAAS,CAAC,GAAG,EAAAF,qBAAA,OAAI,CAACI,KAAK,CAACC,SAAS,cAAAL,qBAAA,uBAApBA,qBAAA,CAAsBM,QAAQ,CAAC,CAAC,KAAI,EAAE;IACxD,oBAASnB,KAAA,CAAAoB,aAAA,CAACd,WAAW,EAAAe,QAAA;MACnBC,GAAG,EAAGA,GAAQ,IAAK;QAAC,IAAI,CAACC,SAAS,GAAGD,GAAG;QACtC;QACA,IAAIA,GAAG,IAAI,CAACf,MAAM,CAACe,GAAG,CAACE,cAAc,CAAC,IAAI,CAACjB,MAAM,CAACe,GAAG,CAACG,YAAY,CAAC,EAAE;UACnE;UACAH,GAAG,CAACE,cAAc,GAAGF,GA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"sources":["textarea.props.ts"],"sourcesContent":["import BaseInputProps from '@wavemaker/app-rn-runtime/components/input/baseinput/baseinput.props';\n\nexport default class WmTextareaProps extends BaseInputProps {\n placeholder: string = 'Place your text';\n}\n"],"mappings":";;;AAAA,OAAOA,cAAc,MAAM,sEAAsE;AAEjG,eAAe,MAAMC,eAAe,SAASD,cAAc,CAAC;EAAA;IAAA;IAAA,qCACpC,iBAAiB;EAAA;AACzC"}
1
+ {"version":3,"names":["BaseInputProps","WmTextareaProps","constructor","arguments","_defineProperty"],"sources":["textarea.props.ts"],"sourcesContent":["import BaseInputProps from '@wavemaker/app-rn-runtime/components/input/baseinput/baseinput.props';\n\nexport default class WmTextareaProps extends BaseInputProps {\n placeholder: string = 'Place your text';\n}\n"],"mappings":";;;AAAA,OAAOA,cAAc,MAAM,sEAAsE;AAEjG,eAAe,MAAMC,eAAe,SAASD,cAAc,CAAC;EAAAE,YAAA;IAAA,SAAAC,SAAA;IAAAC,eAAA,sBACpC,iBAAiB;EAAA;AACzC"}
@@ -37,5 +37,10 @@ BASE_THEME.registerStyle((themeVariables, addStyle) => {
37
37
  backgroundColor: themeVariables.inputDisabledBgColor
38
38
  }
39
39
  });
40
+ addStyle(DEFAULT_CLASS + '-rtl', '', {
41
+ root: {
42
+ textAlign: 'right'
43
+ }
44
+ });
40
45
  });
41
46
  //# sourceMappingURL=textarea.styles.js.map
@@ -1 +1 @@
1
- {"version":3,"names":["BASE_THEME","defineStyles","DEFAULT_CLASS","registerStyle","themeVariables","addStyle","defaultStyles","root","padding","borderWidth","borderStyle","borderColor","inputBorderColor","backgroundColor","inputBackgroundColor","borderRadius","fontFamily","baseFont","minHeight","text","fontSize","textAlignVertical","invalid","borderBottomColor","placeholderText","color","inputPlaceholderColor","skeleton","width","height","inputDisabledBgColor"],"sources":["textarea.styles.ts"],"sourcesContent":["import BASE_THEME, { AllStyle } from '@wavemaker/app-rn-runtime/styles/theme';\nimport { BaseStyles, defineStyles } from '@wavemaker/app-rn-runtime/core/base.component';\nimport { WmSkeletonStyles } from '@wavemaker/app-rn-runtime/components/basic/skeleton/skeleton.styles';\n\nexport type WmTextareaStyles = BaseStyles & {\n invalid: AllStyle;\n placeholderText: AllStyle;\n skeleton: WmSkeletonStyles;\n};\n\nexport const DEFAULT_CLASS = 'app-textarea';\nBASE_THEME.registerStyle((themeVariables, addStyle) => {\n const defaultStyles: WmTextareaStyles = defineStyles({\n root: {\n padding:12,\n borderWidth:1,\n borderStyle: 'solid',\n borderColor: themeVariables.inputBorderColor,\n backgroundColor: themeVariables.inputBackgroundColor,\n borderRadius: 6,\n fontFamily: themeVariables.baseFont,\n minHeight: 160,\n },\n text: {\n fontSize: 16,\n textAlignVertical: 'top'\n },\n invalid: {\n borderBottomColor: 'red'\n },\n placeholderText: {\n color: themeVariables.inputPlaceholderColor\n },\n skeleton: {\n root: {\n width: '100%',\n height: 84,\n borderRadius: 4\n }\n } as WmSkeletonStyles\n });\n\n addStyle(DEFAULT_CLASS, '', defaultStyles);\n addStyle(DEFAULT_CLASS + '-disabled', '', {\n root : {\n backgroundColor: themeVariables.inputDisabledBgColor\n }\n });\n});"],"mappings":"AAAA,OAAOA,UAAU,MAAoB,wCAAwC;AAC7E,SAAqBC,YAAY,QAAQ,+CAA+C;AASxF,OAAO,MAAMC,aAAa,GAAG,cAAc;AAC3CF,UAAU,CAACG,aAAa,CAAC,CAACC,cAAc,EAAEC,QAAQ,KAAK;EACrD,MAAMC,aAA+B,GAAGL,YAAY,CAAC;IACjDM,IAAI,EAAE;MACJC,OAAO,EAAC,EAAE;MACVC,WAAW,EAAC,CAAC;MACbC,WAAW,EAAE,OAAO;MACpBC,WAAW,EAAEP,cAAc,CAACQ,gBAAgB;MAC5CC,eAAe,EAAET,cAAc,CAACU,oBAAoB;MACpDC,YAAY,EAAE,CAAC;MACfC,UAAU,EAAEZ,cAAc,CAACa,QAAQ;MACnCC,SAAS,EAAE;IACb,CAAC;IACDC,IAAI,EAAE;MACJC,QAAQ,EAAE,EAAE;MACZC,iBAAiB,EAAE;IACrB,CAAC;IACDC,OAAO,EAAE;MACPC,iBAAiB,EAAE;IACrB,CAAC;IACDC,eAAe,EAAE;MACfC,KAAK,EAAErB,cAAc,CAACsB;IACxB,CAAC;IACDC,QAAQ,EAAE;MACRpB,IAAI,EAAE;QACJqB,KAAK,EAAE,MAAM;QACbC,MAAM,EAAE,EAAE;QACVd,YAAY,EAAE;MAChB;IACF;EACJ,CAAC,CAAC;EAEFV,QAAQ,CAACH,aAAa,EAAE,EAAE,EAAEI,aAAa,CAAC;EAC1CD,QAAQ,CAACH,aAAa,GAAG,WAAW,EAAE,EAAE,EAAE;IACtCK,IAAI,EAAG;MACLM,eAAe,EAAET,cAAc,CAAC0B;IAClC;EACJ,CAAC,CAAC;AACJ,CAAC,CAAC"}
1
+ {"version":3,"names":["BASE_THEME","defineStyles","DEFAULT_CLASS","registerStyle","themeVariables","addStyle","defaultStyles","root","padding","borderWidth","borderStyle","borderColor","inputBorderColor","backgroundColor","inputBackgroundColor","borderRadius","fontFamily","baseFont","minHeight","text","fontSize","textAlignVertical","invalid","borderBottomColor","placeholderText","color","inputPlaceholderColor","skeleton","width","height","inputDisabledBgColor","textAlign"],"sources":["textarea.styles.ts"],"sourcesContent":["import BASE_THEME, { AllStyle } from '@wavemaker/app-rn-runtime/styles/theme';\nimport { BaseStyles, defineStyles } from '@wavemaker/app-rn-runtime/core/base.component';\nimport { WmSkeletonStyles } from '@wavemaker/app-rn-runtime/components/basic/skeleton/skeleton.styles';\n\nexport type WmTextareaStyles = BaseStyles & {\n invalid: AllStyle;\n placeholderText: AllStyle;\n skeleton: WmSkeletonStyles;\n};\n\nexport const DEFAULT_CLASS = 'app-textarea';\nBASE_THEME.registerStyle((themeVariables, addStyle) => {\n const defaultStyles: WmTextareaStyles = defineStyles({\n root: {\n padding:12,\n borderWidth:1,\n borderStyle: 'solid',\n borderColor: themeVariables.inputBorderColor,\n backgroundColor: themeVariables.inputBackgroundColor,\n borderRadius: 6,\n fontFamily: themeVariables.baseFont,\n minHeight: 160,\n },\n text: {\n fontSize: 16,\n textAlignVertical: 'top'\n },\n invalid: {\n borderBottomColor: 'red'\n },\n placeholderText: {\n color: themeVariables.inputPlaceholderColor\n },\n skeleton: {\n root: {\n width: '100%',\n height: 84,\n borderRadius: 4\n }\n } as any as WmSkeletonStyles\n });\n\n addStyle(DEFAULT_CLASS, '', defaultStyles);\n addStyle(DEFAULT_CLASS + '-disabled', '', {\n root : {\n backgroundColor: themeVariables.inputDisabledBgColor\n }\n });\n addStyle(DEFAULT_CLASS + '-rtl', '', {\n root:{\n textAlign: 'right'\n }\n })\n});"],"mappings":"AAAA,OAAOA,UAAU,MAAoB,wCAAwC;AAC7E,SAAqBC,YAAY,QAAQ,+CAA+C;AASxF,OAAO,MAAMC,aAAa,GAAG,cAAc;AAC3CF,UAAU,CAACG,aAAa,CAAC,CAACC,cAAc,EAAEC,QAAQ,KAAK;EACrD,MAAMC,aAA+B,GAAGL,YAAY,CAAC;IACjDM,IAAI,EAAE;MACJC,OAAO,EAAC,EAAE;MACVC,WAAW,EAAC,CAAC;MACbC,WAAW,EAAE,OAAO;MACpBC,WAAW,EAAEP,cAAc,CAACQ,gBAAgB;MAC5CC,eAAe,EAAET,cAAc,CAACU,oBAAoB;MACpDC,YAAY,EAAE,CAAC;MACfC,UAAU,EAAEZ,cAAc,CAACa,QAAQ;MACnCC,SAAS,EAAE;IACb,CAAC;IACDC,IAAI,EAAE;MACJC,QAAQ,EAAE,EAAE;MACZC,iBAAiB,EAAE;IACrB,CAAC;IACDC,OAAO,EAAE;MACPC,iBAAiB,EAAE;IACrB,CAAC;IACDC,eAAe,EAAE;MACfC,KAAK,EAAErB,cAAc,CAACsB;IACxB,CAAC;IACDC,QAAQ,EAAE;MACRpB,IAAI,EAAE;QACJqB,KAAK,EAAE,MAAM;QACbC,MAAM,EAAE,EAAE;QACVd,YAAY,EAAE;MAChB;IACF;EACJ,CAAC,CAAC;EAEFV,QAAQ,CAACH,aAAa,EAAE,EAAE,EAAEI,aAAa,CAAC;EAC1CD,QAAQ,CAACH,aAAa,GAAG,WAAW,EAAE,EAAE,EAAE;IACtCK,IAAI,EAAG;MACLM,eAAe,EAAET,cAAc,CAAC0B;IAClC;EACJ,CAAC,CAAC;EACFzB,QAAQ,CAACH,aAAa,GAAG,MAAM,EAAE,EAAE,EAAE;IACnCK,IAAI,EAAC;MACHwB,SAAS,EAAE;IACb;EACF,CAAC,CAAC;AACJ,CAAC,CAAC"}
@@ -2,8 +2,8 @@ function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key i
2
2
  function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return typeof key === "symbol" ? key : String(key); }
3
3
  function _toPrimitive(input, hint) { if (typeof input !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (typeof res !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
4
4
  import React from 'react';
5
- import { View } from 'react-native';
6
- import { Switch } from 'react-native-paper';
5
+ import { View, TouchableOpacity } from 'react-native';
6
+ import { BackgroundComponent } from '@wavemaker/app-rn-runtime/styles/background.component';
7
7
  import { BaseComponent, BaseComponentState } from '@wavemaker/app-rn-runtime/core/base.component';
8
8
  import { unStringify, validateField } from '@wavemaker/app-rn-runtime/core/utils';
9
9
  import WmToggleProps from './toggle.props';
@@ -66,14 +66,13 @@ export default class WmToggle extends BaseComponent {
66
66
  });
67
67
  }
68
68
  renderWidget(props) {
69
- return /*#__PURE__*/React.createElement(View, {
70
- style: this.styles.root
71
- }, this._background, /*#__PURE__*/React.createElement(Switch, {
72
- value: this.state.isSwitchOn,
73
- color: this.styles.text.color,
74
- disabled: props.readonly || props.disabled,
75
- onValueChange: this.onToggleSwitch.bind(this),
76
- onTouchEndCapture: () => {
69
+ const styles = this.theme.mergeStyle(this.styles, this.theme.getStyle(this.state.isSwitchOn ? 'app-toggle-on' : 'app-toggle-off'));
70
+ return /*#__PURE__*/React.createElement(TouchableOpacity, {
71
+ style: styles.root,
72
+ onPress: () => {
73
+ if (this.props.disabled) {
74
+ return;
75
+ }
77
76
  // Added setTimeout to smooth animation
78
77
  setTimeout(() => {
79
78
  if (!props.readonly) {
@@ -81,8 +80,15 @@ export default class WmToggle extends BaseComponent {
81
80
  }
82
81
  this.invokeEventCallback('onTap', [null, this]);
83
82
  }, 500);
83
+ this.onToggleSwitch(!this.state.isSwitchOn);
84
84
  }
85
- }));
85
+ }, this._background, /*#__PURE__*/React.createElement(View, {
86
+ style: styles.handle
87
+ }, /*#__PURE__*/React.createElement(BackgroundComponent, {
88
+ size: styles.handle.backgroundSize,
89
+ position: styles.handle.backgroundPosition,
90
+ image: styles.handle.backgroundImage
91
+ })));
86
92
  }
87
93
  }
88
94
  //# sourceMappingURL=toggle.component.js.map
@@ -1 +1 @@
1
- {"version":3,"names":["React","View","Switch","BaseComponent","BaseComponentState","unStringify","validateField","WmToggleProps","DEFAULT_CLASS","WmToggleState","WmToggle","constructor","props","onPropertyChange","name","$new","$old","value","state","checkedvalue","updateState","isSwitchOn","updateDatavalue","datavalue","validate","validationObj","isValid","errorType","onToggleSwitch","oldValue","dataValue","uncheckedvalue","onFieldChange","invokeEventCallback","proxy","renderWidget","styles","root","_background","text","color","readonly","disabled","bind","setTimeout"],"sources":["toggle.component.tsx"],"sourcesContent":["import React from 'react';\nimport { View } from 'react-native';\nimport { Switch } from 'react-native-paper';\nimport { BaseComponent, BaseComponentState } from '@wavemaker/app-rn-runtime/core/base.component';\nimport {unStringify, validateField} from '@wavemaker/app-rn-runtime/core/utils';\n\nimport WmToggleProps from './toggle.props';\nimport { DEFAULT_CLASS, WmToggleStyles } from './toggle.styles';\n\nexport class WmToggleState extends BaseComponentState<WmToggleProps> {\n isSwitchOn: boolean = false;\n isValid: boolean = true;\n errorType = '';\n}\n\nexport default class WmToggle extends BaseComponent<WmToggleProps, WmToggleState, WmToggleStyles> {\n\n constructor(props: WmToggleProps) {\n super(props, DEFAULT_CLASS, new WmToggleProps(), new WmToggleState());\n }\n\n onPropertyChange(name: string, $new: any, $old: any) {\n switch (name) {\n case 'datavalue':\n let value =\n unStringify($new) ===\n unStringify(this.state.props.checkedvalue, true);\n this.updateState({ isSwitchOn: value } as WmToggleState);\n break;\n }\n }\n\n updateDatavalue(value: any) {\n this.updateState({ props: { datavalue: value }} as WmToggleState);\n }\n\n validate(value: any) {\n const validationObj = validateField(this.state.props, value);\n this.updateState({\n isValid: validationObj.isValid,\n errorType: validationObj.errorType\n } as WmToggleState);\n }\n\n onToggleSwitch(value: any) {\n const oldValue = this.state.props.datavalue;\n this.validate(value);\n this.updateState({ isSwitchOn: value } as WmToggleState);\n const dataValue = value === true ? this.state.props.checkedvalue : this.state.props.uncheckedvalue;\n // @ts-ignore\n this.updateState({ props: { datavalue: dataValue } },\n ()=> {\n if (!this.props.onFieldChange) {\n this.invokeEventCallback('onChange', [null, this.proxy, dataValue, oldValue]);\n } else {\n this.props.onFieldChange && this.props.onFieldChange('datavalue', dataValue, oldValue);\n }\n this.invokeEventCallback('onBlur', [ null, this.proxy ]);\n });\n }\n\n renderWidget(props: WmToggleProps) {\n return (\n <View style={this.styles.root}>\n {this._background}\n <Switch value={this.state.isSwitchOn}\n color={this.styles.text.color as string}\n disabled={props.readonly || props.disabled}\n onValueChange={this.onToggleSwitch.bind(this)}\n onTouchEndCapture={() => {\n // Added setTimeout to smooth animation\n setTimeout(() => {\n if (!props.readonly) {\n this.invokeEventCallback('onFocus', [null, this]);\n }\n this.invokeEventCallback('onTap', [null, this]);\n }, 500);\n }}/>\n </View>\n );\n }\n}\n"],"mappings":";;;AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,SAASC,IAAI,QAAQ,cAAc;AACnC,SAASC,MAAM,QAAQ,oBAAoB;AAC3C,SAASC,aAAa,EAAEC,kBAAkB,QAAQ,+CAA+C;AACjG,SAAQC,WAAW,EAAEC,aAAa,QAAO,sCAAsC;AAE/E,OAAOC,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AAE;YACnB,IAAI,CAACR,mBAAmB,CAAC,SAAS,EAAE,CAAC,IAAI,EAAE,IAAI,CAAC,CAAC;UACnD;UACA,IAAI,CAACA,mBAAmB,CAAC,OAAO,EAAE,CAAC,IAAI,EAAE,IAAI,CAAC,CAAC;QACjD,CAAC,EAAE,GAAG,CAAC;MACT;IAAE,EAAE,CACH;EAEX;AACF"}
1
+ {"version":3,"names":["React","View","TouchableOpacity","BackgroundComponent","BaseComponent","BaseComponentState","unStringify","validateField","WmToggleProps","DEFAULT_CLASS","WmToggleState","constructor","arguments","_defineProperty","WmToggle","props","onPropertyChange","name","$new","$old","value","state","checkedvalue","updateState","isSwitchOn","updateDatavalue","datavalue","validate","validationObj","isValid","errorType","onToggleSwitch","oldValue","dataValue","uncheckedvalue","onFieldChange","invokeEventCallback","proxy","renderWidget","styles","theme","mergeStyle","getStyle","createElement","style","root","onPress","disabled","setTimeout","readonly","_background","handle","size","backgroundSize","position","backgroundPosition","image","backgroundImage"],"sources":["toggle.component.tsx"],"sourcesContent":["import React from 'react';\nimport { View, TouchableOpacity } from 'react-native';\n\nimport { BackgroundComponent } from '@wavemaker/app-rn-runtime/styles/background.component';\nimport { BaseComponent, BaseComponentState } from '@wavemaker/app-rn-runtime/core/base.component';\nimport {unStringify, validateField} from '@wavemaker/app-rn-runtime/core/utils';\n\nimport WmToggleProps from './toggle.props';\nimport { DEFAULT_CLASS, WmToggleStyles } from './toggle.styles';\n\nexport class WmToggleState extends BaseComponentState<WmToggleProps> {\n isSwitchOn: boolean = false;\n isValid: boolean = true;\n errorType = '';\n}\n\nexport default class WmToggle extends BaseComponent<WmToggleProps, WmToggleState, WmToggleStyles> {\n\n constructor(props: WmToggleProps) {\n super(props, DEFAULT_CLASS, new WmToggleProps(), new WmToggleState());\n }\n\n onPropertyChange(name: string, $new: any, $old: any) {\n switch (name) {\n case 'datavalue':\n let value =\n unStringify($new) ===\n unStringify(this.state.props.checkedvalue, true);\n this.updateState({ isSwitchOn: value } as WmToggleState);\n break;\n }\n }\n\n updateDatavalue(value: any) {\n this.updateState({ props: { datavalue: value }} as WmToggleState);\n }\n\n validate(value: any) {\n const validationObj = validateField(this.state.props, value);\n this.updateState({\n isValid: validationObj.isValid,\n errorType: validationObj.errorType\n } as WmToggleState);\n }\n\n onToggleSwitch(value: any) {\n const oldValue = this.state.props.datavalue;\n this.validate(value);\n this.updateState({ isSwitchOn: value } as WmToggleState);\n const dataValue = value === true ? this.state.props.checkedvalue : this.state.props.uncheckedvalue;\n // @ts-ignore\n this.updateState({ props: { datavalue: dataValue } },\n ()=> {\n if (!this.props.onFieldChange) {\n this.invokeEventCallback('onChange', [null, this.proxy, dataValue, oldValue]);\n } else {\n this.props.onFieldChange && this.props.onFieldChange('datavalue', dataValue, oldValue);\n }\n this.invokeEventCallback('onBlur', [ null, this.proxy ]);\n });\n }\n\n renderWidget(props: WmToggleProps) {\n const styles = this.theme.mergeStyle(this.styles, \n this.theme.getStyle(this.state.isSwitchOn ? 'app-toggle-on' : 'app-toggle-off'));\n return (\n <TouchableOpacity style={styles.root} onPress={() => {\n if (this.props.disabled) {\n return;\n }\n // Added setTimeout to smooth animation\n setTimeout(() => {\n if (!props.readonly) {\n this.invokeEventCallback('onFocus', [null, this]);\n }\n this.invokeEventCallback('onTap', [null, this]);\n }, 500);\n this.onToggleSwitch(!this.state.isSwitchOn);\n }}>\n {this._background}\n <View style={styles.handle}>\n <BackgroundComponent\n size={styles.handle.backgroundSize}\n position={styles.handle.backgroundPosition}\n image={styles.handle.backgroundImage}> \n </BackgroundComponent>\n </View>\n </TouchableOpacity>\n );\n }\n}\n"],"mappings":";;;AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,SAASC,IAAI,EAAEC,gBAAgB,QAAQ,cAAc;AAErD,SAASC,mBAAmB,QAAQ,uDAAuD;AAC3F,SAASC,aAAa,EAAEC,kBAAkB,QAAQ,+CAA+C;AACjG,SAAQC,WAAW,EAAEC,aAAa,QAAO,sCAAsC;AAE/E,OAAOC,a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AAI,CAACjC,KAAK,CAACkC,QAAQ,EAAE;YACnB,IAAI,CAACb,mBAAmB,CAAC,SAAS,EAAE,CAAC,IAAI,EAAE,IAAI,CAAC,CAAC;UACnD;UACA,IAAI,CAACA,mBAAmB,CAAC,OAAO,EAAE,CAAC,IAAI,EAAE,IAAI,CAAC,CAAC;QACjD,CAAC,EAAE,GAAG,CAAC;QACP,IAAI,CAACL,cAAc,CAAC,CAAC,IAAI,CAACV,KAAK,CAACG,UAAU,CAAC;MAC7C;IAAE,GACC,IAAI,CAAC0B,WAAW,eACjBlD,KAAA,CAAA2C,aAAA,CAAC1C,IAAI;MAAC2C,KAAK,EAAEL,MAAM,CAACY;IAAO,gBACzBnD,KAAA,CAAA2C,aAAA,CAACxC,mBAAmB;MAClBiD,IAAI,EAAEb,MAAM,CAACY,MAAM,CAACE,cAAe;MACnCC,QAAQ,EAAEf,MAAM,CAACY,MAAM,CAACI,kBAAmB;MAC3CC,KAAK,EAAEjB,MAAM,CAACY,MAAM,CAACM;IAAgB,CAClB,CACjB,CACU,CAAC;EAEvB;AACF"}
@@ -1 +1 @@
1
- {"version":3,"names":["BaseProps","WmToggleProps"],"sources":["toggle.props.ts"],"sourcesContent":["import { BaseProps } from '@wavemaker/app-rn-runtime/core/base.component';\n\nexport default class WmToggleProps extends BaseProps {\n checkedvalue: any = true;\n uncheckedvalue: any = false;\n datavalue: any;\n readonly? = false;\n onFieldChange: any;\n invokeEvent?: Function;\n}\n"],"mappings":";;;AAAA,SAASA,SAAS,QAAQ,+CAA+C;AAEzE,eAAe,MAAMC,aAAa,SAASD,SAAS,CAAC;EAAA;IAAA;IAAA,sCAC/B,IAAI;IAAA,wCACF,KAAK;IAAA;IAAA,kCAEf,KAAK;IAAA;IAAA;EAAA;AAGnB"}
1
+ {"version":3,"names":["BaseProps","WmToggleProps","constructor","arguments","_defineProperty"],"sources":["toggle.props.ts"],"sourcesContent":["import { BaseProps } from '@wavemaker/app-rn-runtime/core/base.component';\n\nexport default class WmToggleProps extends BaseProps {\n checkedvalue: any = true;\n uncheckedvalue: any = false;\n datavalue: any;\n readonly? = false;\n onFieldChange: any;\n invokeEvent?: Function;\n}\n"],"mappings":";;;AAAA,SAASA,SAAS,QAAQ,+CAA+C;AAEzE,eAAe,MAAMC,aAAa,SAASD,SAAS,CAAC;EAAAE,YAAA;IAAA,SAAAC,SAAA;IAAAC,eAAA,uBAC/B,IAAI;IAAAA,eAAA,yBACF,KAAK;IAAAA,eAAA;IAAAA,eAAA,mBAEf,KAAK;IAAAA,eAAA;IAAAA,eAAA;EAAA;AAGnB"}
@@ -4,13 +4,38 @@ export const DEFAULT_CLASS = 'app-toggle';
4
4
  BASE_THEME.registerStyle((themeVariables, addStyle) => {
5
5
  const defaultStyles = defineStyles({
6
6
  root: {
7
- width: 36
7
+ width: 36,
8
+ flexDirection: 'row',
9
+ justifyContent: 'flex-start',
10
+ alignItems: 'center',
11
+ borderRadius: 18,
12
+ borderWidth: 1
8
13
  },
9
- text: {
10
- color: themeVariables.toggleColor
14
+ text: {},
15
+ handle: {
16
+ width: 18,
17
+ height: 18,
18
+ borderRadius: 18,
19
+ backgroundColor: themeVariables.toggleHandleColor,
20
+ backgroundSize: '100% 100%',
21
+ backgroundPosition: 'center'
11
22
  }
12
23
  });
13
24
  addStyle(DEFAULT_CLASS, '', defaultStyles);
25
+ addStyle(DEFAULT_CLASS + '-on', '', {
26
+ root: {
27
+ backgroundColor: themeVariables.toggleOnColor,
28
+ justifyContent: 'flex-end',
29
+ borderColor: themeVariables.toggleOnColor
30
+ }
31
+ });
32
+ addStyle(DEFAULT_CLASS + '-off', '', {
33
+ root: {
34
+ backgroundColor: themeVariables.toggleOffColor,
35
+ borderColor: themeVariables.toggleOffColor
36
+ }
37
+ });
38
+ addStyle(DEFAULT_CLASS + '-rtl', '', {});
14
39
  addStyle(DEFAULT_CLASS + '-disabled', '', {
15
40
  root: {}
16
41
  });