@wavemaker/app-rn-runtime 11.5.0-next.40301 → 11.5.0-next.NULL
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.
- app-rn-runtime/actions/login-action.js +4 -0
- app-rn-runtime/actions/login-action.js.map +1 -1
- app-rn-runtime/actions/logout-action.js +4 -0
- app-rn-runtime/actions/logout-action.js.map +1 -1
- app-rn-runtime/actions/notification-action.js.map +1 -1
- app-rn-runtime/components/advanced/carousel/carousel-template/carousel-template.component.js +4 -1
- app-rn-runtime/components/advanced/carousel/carousel-template/carousel-template.component.js.map +1 -1
- app-rn-runtime/components/advanced/carousel/carousel-template/carousel-template.styles.js +1 -2
- app-rn-runtime/components/advanced/carousel/carousel-template/carousel-template.styles.js.map +1 -1
- app-rn-runtime/components/advanced/carousel/carousel.component.js +214 -69
- app-rn-runtime/components/advanced/carousel/carousel.component.js.map +1 -1
- app-rn-runtime/components/advanced/carousel/carousel.props.js +3 -0
- app-rn-runtime/components/advanced/carousel/carousel.props.js.map +1 -1
- app-rn-runtime/components/advanced/carousel/carousel.styles.js +22 -10
- app-rn-runtime/components/advanced/carousel/carousel.styles.js.map +1 -1
- app-rn-runtime/components/advanced/login/login.component.js +3 -2
- app-rn-runtime/components/advanced/login/login.component.js.map +1 -1
- app-rn-runtime/components/advanced/network-info-toaster/network-info-toaster.component.js +17 -16
- app-rn-runtime/components/advanced/network-info-toaster/network-info-toaster.component.js.map +1 -1
- app-rn-runtime/components/advanced/webview/webview.component.js +28 -11
- app-rn-runtime/components/advanced/webview/webview.component.js.map +1 -1
- app-rn-runtime/components/advanced/webview/webview.props.js +0 -1
- app-rn-runtime/components/advanced/webview/webview.props.js.map +1 -1
- app-rn-runtime/components/basic/anchor/anchor.component.js +7 -5
- app-rn-runtime/components/basic/anchor/anchor.component.js.map +1 -1
- app-rn-runtime/components/basic/animatedview.component.js +50 -0
- app-rn-runtime/components/basic/animatedview.component.js.map +1 -1
- app-rn-runtime/components/basic/audio/audio.component.js +5 -0
- app-rn-runtime/components/basic/audio/audio.component.js.map +1 -1
- app-rn-runtime/components/basic/button/button.component.js +20 -7
- app-rn-runtime/components/basic/button/button.component.js.map +1 -1
- app-rn-runtime/components/basic/button/button.styles.js +15 -5
- app-rn-runtime/components/basic/button/button.styles.js.map +1 -1
- app-rn-runtime/components/basic/buttongroup/buttongroup.styles.js +11 -5
- app-rn-runtime/components/basic/buttongroup/buttongroup.styles.js.map +1 -1
- app-rn-runtime/components/basic/icon/icon.component.js +11 -5
- app-rn-runtime/components/basic/icon/icon.component.js.map +1 -1
- app-rn-runtime/components/basic/icon/icon.props.js +1 -0
- app-rn-runtime/components/basic/icon/icon.props.js.map +1 -1
- app-rn-runtime/components/basic/icon/icon.styles.js +2 -1
- app-rn-runtime/components/basic/icon/icon.styles.js.map +1 -1
- app-rn-runtime/components/basic/label/label.component.js +79 -11
- app-rn-runtime/components/basic/label/label.component.js.map +1 -1
- app-rn-runtime/components/basic/label/label.props.js +1 -0
- app-rn-runtime/components/basic/label/label.props.js.map +1 -1
- app-rn-runtime/components/basic/label/label.styles.js +5 -0
- app-rn-runtime/components/basic/label/label.styles.js.map +1 -1
- app-rn-runtime/components/basic/message/message.component.js +6 -3
- app-rn-runtime/components/basic/message/message.component.js.map +1 -1
- app-rn-runtime/components/basic/picture/picture.component.js +7 -5
- app-rn-runtime/components/basic/picture/picture.component.js.map +1 -1
- app-rn-runtime/components/basic/progress-bar/progress-bar.component.js +4 -3
- app-rn-runtime/components/basic/progress-bar/progress-bar.component.js.map +1 -1
- app-rn-runtime/components/basic/progress-bar/progress-bar.styles.js +1 -1
- app-rn-runtime/components/basic/progress-bar/progress-bar.styles.js.map +1 -1
- app-rn-runtime/components/basic/progress-circle/progress-circle.component.js +3 -2
- app-rn-runtime/components/basic/progress-circle/progress-circle.component.js.map +1 -1
- app-rn-runtime/components/basic/search/search.component.js +12 -6
- app-rn-runtime/components/basic/search/search.component.js.map +1 -1
- app-rn-runtime/components/basic/search/search.styles.js +11 -10
- app-rn-runtime/components/basic/search/search.styles.js.map +1 -1
- app-rn-runtime/components/basic/spinner/spinner.component.js +6 -2
- app-rn-runtime/components/basic/spinner/spinner.component.js.map +1 -1
- app-rn-runtime/components/basic/spinner/spinner.styles.js +3 -2
- app-rn-runtime/components/basic/spinner/spinner.styles.js.map +1 -1
- app-rn-runtime/components/basic/video/video.component.js +2 -1
- app-rn-runtime/components/basic/video/video.component.js.map +1 -1
- app-rn-runtime/components/chart/area-chart/area-chart.component.js +42 -14
- app-rn-runtime/components/chart/area-chart/area-chart.component.js.map +1 -1
- app-rn-runtime/components/chart/area-chart/area-chart.props.js +10 -1
- app-rn-runtime/components/chart/area-chart/area-chart.props.js.map +1 -1
- app-rn-runtime/components/chart/bar-chart/bar-chart.component.js +42 -4
- app-rn-runtime/components/chart/bar-chart/bar-chart.component.js.map +1 -1
- app-rn-runtime/components/chart/bar-chart/bar-chart.props.js +1 -2
- app-rn-runtime/components/chart/bar-chart/bar-chart.props.js.map +1 -1
- app-rn-runtime/components/chart/basechart.component.js +158 -46
- app-rn-runtime/components/chart/basechart.component.js.map +1 -1
- app-rn-runtime/components/chart/basechart.props.js +18 -4
- app-rn-runtime/components/chart/basechart.props.js.map +1 -1
- app-rn-runtime/components/chart/basechart.styles.js +44 -2
- app-rn-runtime/components/chart/basechart.styles.js.map +1 -1
- app-rn-runtime/components/chart/bubble-chart/bubble-chart.component.js +25 -3
- app-rn-runtime/components/chart/bubble-chart/bubble-chart.component.js.map +1 -1
- app-rn-runtime/components/chart/bubble-chart/bubble-chart.props.js +9 -1
- app-rn-runtime/components/chart/bubble-chart/bubble-chart.props.js.map +1 -1
- app-rn-runtime/components/chart/line-chart/line-chart.component.js +28 -6
- app-rn-runtime/components/chart/line-chart/line-chart.component.js.map +1 -1
- app-rn-runtime/components/chart/line-chart/line-chart.props.js +1 -0
- app-rn-runtime/components/chart/line-chart/line-chart.props.js.map +1 -1
- app-rn-runtime/components/chart/pie-chart/pie-chart.component.js +25 -3
- app-rn-runtime/components/chart/pie-chart/pie-chart.component.js.map +1 -1
- app-rn-runtime/components/chart/pie-chart/pie-chart.props.js +1 -0
- app-rn-runtime/components/chart/pie-chart/pie-chart.props.js.map +1 -1
- app-rn-runtime/components/chart/stack-chart/stack-chart.component.js +275 -0
- app-rn-runtime/components/chart/stack-chart/stack-chart.component.js.map +1 -0
- app-rn-runtime/components/chart/stack-chart/stack-chart.props.js +17 -0
- app-rn-runtime/components/chart/stack-chart/stack-chart.props.js.map +1 -0
- app-rn-runtime/components/chart/stack-chart/stack-chart.styles.js +7 -0
- app-rn-runtime/components/chart/stack-chart/stack-chart.styles.js.map +1 -0
- app-rn-runtime/components/container/accordion/accordion.component.js +22 -15
- app-rn-runtime/components/container/accordion/accordion.component.js.map +1 -1
- app-rn-runtime/components/container/accordion/accordionpane/accordionpane.component.js +6 -24
- app-rn-runtime/components/container/accordion/accordionpane/accordionpane.component.js.map +1 -1
- app-rn-runtime/components/container/container.component.js +14 -4
- app-rn-runtime/components/container/container.component.js.map +1 -1
- app-rn-runtime/components/container/container.props.js +1 -0
- app-rn-runtime/components/container/container.props.js.map +1 -1
- app-rn-runtime/components/container/panel/collapsible-pane.component.js +26 -0
- app-rn-runtime/components/container/panel/collapsible-pane.component.js.map +1 -0
- app-rn-runtime/components/container/panel/panel.component.js +44 -62
- app-rn-runtime/components/container/panel/panel.component.js.map +1 -1
- app-rn-runtime/components/container/panel/panel.styles.js +9 -2
- app-rn-runtime/components/container/panel/panel.styles.js.map +1 -1
- app-rn-runtime/components/container/partial-host.component.js +1 -1
- app-rn-runtime/components/container/partial-host.component.js.map +1 -1
- app-rn-runtime/components/container/tabs/tabheader/tabheader.component.js +29 -15
- app-rn-runtime/components/container/tabs/tabheader/tabheader.component.js.map +1 -1
- app-rn-runtime/components/container/tabs/tabheader/tabheader.styles.js +15 -10
- app-rn-runtime/components/container/tabs/tabheader/tabheader.styles.js.map +1 -1
- app-rn-runtime/components/container/tabs/tabpane/tabpane.component.js +1 -1
- app-rn-runtime/components/container/tabs/tabpane/tabpane.component.js.map +1 -1
- app-rn-runtime/components/container/tabs/tabs.component.js +18 -10
- app-rn-runtime/components/container/tabs/tabs.component.js.map +1 -1
- app-rn-runtime/components/container/tabs/tabs.styles.js +1 -0
- app-rn-runtime/components/container/tabs/tabs.styles.js.map +1 -1
- app-rn-runtime/components/container/tile/tile.component.js +3 -2
- app-rn-runtime/components/container/tile/tile.component.js.map +1 -1
- app-rn-runtime/components/container/wizard/wizard.component.js +139 -22
- app-rn-runtime/components/container/wizard/wizard.component.js.map +1 -1
- app-rn-runtime/components/container/wizard/wizard.props.js +4 -0
- app-rn-runtime/components/container/wizard/wizard.props.js.map +1 -1
- app-rn-runtime/components/container/wizard/wizard.styles.js +117 -6
- app-rn-runtime/components/container/wizard/wizard.styles.js.map +1 -1
- app-rn-runtime/components/container/wizard/wizardstep/wizardstep.component.js +22 -3
- app-rn-runtime/components/container/wizard/wizardstep/wizardstep.component.js.map +1 -1
- app-rn-runtime/components/container/wizard/wizardstep/wizardstep.props.js +4 -0
- app-rn-runtime/components/container/wizard/wizardstep/wizardstep.props.js.map +1 -1
- app-rn-runtime/components/data/card/card-content/card-content.component.js +1 -1
- app-rn-runtime/components/data/card/card-content/card-content.component.js.map +1 -1
- app-rn-runtime/components/data/card/card.component.js +3 -2
- app-rn-runtime/components/data/card/card.component.js.map +1 -1
- app-rn-runtime/components/data/form/form-action/form-action.component.js +1 -0
- app-rn-runtime/components/data/form/form-action/form-action.component.js.map +1 -1
- app-rn-runtime/components/data/form/form-field/form-field.component.js +9 -7
- app-rn-runtime/components/data/form/form-field/form-field.component.js.map +1 -1
- app-rn-runtime/components/data/form/form.component.js +12 -6
- app-rn-runtime/components/data/form/form.component.js.map +1 -1
- app-rn-runtime/components/data/list/list-template/list-template.component.js +15 -1
- app-rn-runtime/components/data/list/list-template/list-template.component.js.map +1 -1
- app-rn-runtime/components/data/list/list-template/list-template.styles.js +9 -1
- app-rn-runtime/components/data/list/list-template/list-template.styles.js.map +1 -1
- app-rn-runtime/components/data/list/list.component.js +93 -31
- app-rn-runtime/components/data/list/list.component.js.map +1 -1
- app-rn-runtime/components/data/list/list.props.js +7 -0
- app-rn-runtime/components/data/list/list.props.js.map +1 -1
- app-rn-runtime/components/data/list/list.styles.js +12 -5
- app-rn-runtime/components/data/list/list.styles.js.map +1 -1
- app-rn-runtime/components/device/barcodescanner/barcodescanner.component.js +1 -0
- app-rn-runtime/components/device/barcodescanner/barcodescanner.component.js.map +1 -1
- app-rn-runtime/components/device/barcodescanner/barcodescanner.styles.js +2 -1
- app-rn-runtime/components/device/barcodescanner/barcodescanner.styles.js.map +1 -1
- app-rn-runtime/components/device/camera/camera.component.js +1 -0
- app-rn-runtime/components/device/camera/camera.component.js.map +1 -1
- app-rn-runtime/components/device/camera/camera.styles.js +2 -1
- app-rn-runtime/components/device/camera/camera.styles.js.map +1 -1
- app-rn-runtime/components/dialogs/alertdialog/alertdialog.component.js +4 -1
- app-rn-runtime/components/dialogs/alertdialog/alertdialog.component.js.map +1 -1
- app-rn-runtime/components/dialogs/alertdialog/alertdialog.styles.js +9 -3
- app-rn-runtime/components/dialogs/alertdialog/alertdialog.styles.js.map +1 -1
- app-rn-runtime/components/dialogs/confirmdialog/confirmdialog.component.js +6 -2
- app-rn-runtime/components/dialogs/confirmdialog/confirmdialog.component.js.map +1 -1
- app-rn-runtime/components/dialogs/confirmdialog/confirmdialog.styles.js +10 -10
- app-rn-runtime/components/dialogs/confirmdialog/confirmdialog.styles.js.map +1 -1
- app-rn-runtime/components/dialogs/dialog/dialog.component.js +2 -0
- app-rn-runtime/components/dialogs/dialog/dialog.component.js.map +1 -1
- app-rn-runtime/components/dialogs/dialog/dialog.styles.js +25 -8
- app-rn-runtime/components/dialogs/dialog/dialog.styles.js.map +1 -1
- app-rn-runtime/components/dialogs/dialogcontent/dialogcontent.component.js +4 -2
- app-rn-runtime/components/dialogs/dialogcontent/dialogcontent.component.js.map +1 -1
- app-rn-runtime/components/dialogs/dialogcontent/dialogcontent.styles.js +2 -1
- app-rn-runtime/components/dialogs/dialogcontent/dialogcontent.styles.js.map +1 -1
- app-rn-runtime/components/input/baseinput/baseinput.component.js +6 -2
- app-rn-runtime/components/input/baseinput/baseinput.component.js.map +1 -1
- app-rn-runtime/components/input/basenumber/basenumber.component.js +45 -6
- app-rn-runtime/components/input/basenumber/basenumber.component.js.map +1 -1
- app-rn-runtime/components/input/basenumber/basenumber.props.js +1 -0
- app-rn-runtime/components/input/basenumber/basenumber.props.js.map +1 -1
- app-rn-runtime/components/input/calendar/calendar.component.js +4 -0
- app-rn-runtime/components/input/calendar/calendar.component.js.map +1 -1
- app-rn-runtime/components/input/calendar/calendar.styles.js +22 -11
- app-rn-runtime/components/input/calendar/calendar.styles.js.map +1 -1
- app-rn-runtime/components/input/calendar/views/month-view.js +4 -0
- app-rn-runtime/components/input/calendar/views/month-view.js.map +1 -1
- app-rn-runtime/components/input/checkbox/checkbox.component.js +6 -6
- app-rn-runtime/components/input/checkbox/checkbox.component.js.map +1 -1
- app-rn-runtime/components/input/checkboxset/checkboxset.component.js +14 -7
- app-rn-runtime/components/input/checkboxset/checkboxset.component.js.map +1 -1
- app-rn-runtime/components/input/checkboxset/checkboxset.styles.js +2 -1
- app-rn-runtime/components/input/checkboxset/checkboxset.styles.js.map +1 -1
- app-rn-runtime/components/input/chips/chips.component.js +15 -4
- app-rn-runtime/components/input/chips/chips.component.js.map +1 -1
- app-rn-runtime/components/input/chips/chips.styles.js +20 -12
- app-rn-runtime/components/input/chips/chips.styles.js.map +1 -1
- app-rn-runtime/components/input/composite/composite.component.js +8 -1
- app-rn-runtime/components/input/composite/composite.component.js.map +1 -1
- app-rn-runtime/components/input/composite/composite.props.js +1 -0
- app-rn-runtime/components/input/composite/composite.props.js.map +1 -1
- app-rn-runtime/components/input/composite/composite.styles.js +16 -1
- app-rn-runtime/components/input/composite/composite.styles.js.map +1 -1
- app-rn-runtime/components/input/currency/currency.component.js +21 -3
- app-rn-runtime/components/input/currency/currency.component.js.map +1 -1
- app-rn-runtime/components/input/currency/currency.props.js +1 -0
- app-rn-runtime/components/input/currency/currency.props.js.map +1 -1
- app-rn-runtime/components/input/currency/currency.styles.js +31 -5
- app-rn-runtime/components/input/currency/currency.styles.js.map +1 -1
- app-rn-runtime/components/input/epoch/base-datetime.component.js +32 -9
- app-rn-runtime/components/input/epoch/base-datetime.component.js.map +1 -1
- app-rn-runtime/components/input/epoch/date/date.component.js +8 -0
- app-rn-runtime/components/input/epoch/date/date.component.js.map +1 -1
- app-rn-runtime/components/input/epoch/date/date.styles.js +16 -0
- app-rn-runtime/components/input/epoch/date/date.styles.js.map +1 -1
- app-rn-runtime/components/input/epoch/datetime/datetime.component.js +8 -0
- app-rn-runtime/components/input/epoch/datetime/datetime.component.js.map +1 -1
- app-rn-runtime/components/input/epoch/datetime/datetime.props.js +1 -0
- app-rn-runtime/components/input/epoch/datetime/datetime.props.js.map +1 -1
- app-rn-runtime/components/input/epoch/datetime/datetime.styles.js +21 -1
- app-rn-runtime/components/input/epoch/datetime/datetime.styles.js.map +1 -1
- app-rn-runtime/components/input/epoch/time/time.component.js +8 -0
- app-rn-runtime/components/input/epoch/time/time.component.js.map +1 -1
- app-rn-runtime/components/input/epoch/time/time.styles.js +16 -0
- app-rn-runtime/components/input/epoch/time/time.styles.js.map +1 -1
- app-rn-runtime/components/input/fileupload/fileupload.component.js +1 -0
- app-rn-runtime/components/input/fileupload/fileupload.component.js.map +1 -1
- app-rn-runtime/components/input/number/number.component.js +16 -2
- app-rn-runtime/components/input/number/number.component.js.map +1 -1
- app-rn-runtime/components/input/number/number.props.js +1 -0
- app-rn-runtime/components/input/number/number.props.js.map +1 -1
- app-rn-runtime/components/input/number/number.styles.js +23 -2
- app-rn-runtime/components/input/number/number.styles.js.map +1 -1
- app-rn-runtime/components/input/radioset/radioset.component.js +13 -6
- app-rn-runtime/components/input/radioset/radioset.component.js.map +1 -1
- app-rn-runtime/components/input/radioset/radioset.props.js +6 -0
- app-rn-runtime/components/input/radioset/radioset.props.js.map +1 -1
- app-rn-runtime/components/input/radioset/radioset.styles.js +6 -9
- app-rn-runtime/components/input/radioset/radioset.styles.js.map +1 -1
- app-rn-runtime/components/input/rating/rating.component.js +2 -0
- app-rn-runtime/components/input/rating/rating.component.js.map +1 -1
- app-rn-runtime/components/input/select/select.component.js +17 -13
- app-rn-runtime/components/input/select/select.component.js.map +1 -1
- app-rn-runtime/components/input/select/select.styles.js +8 -4
- app-rn-runtime/components/input/select/select.styles.js.map +1 -1
- app-rn-runtime/components/input/slider/slider.component.js +99 -23
- app-rn-runtime/components/input/slider/slider.component.js.map +1 -1
- app-rn-runtime/components/input/slider/slider.styles.js +30 -3
- app-rn-runtime/components/input/slider/slider.styles.js.map +1 -1
- app-rn-runtime/components/input/switch/switch.component.js +11 -5
- app-rn-runtime/components/input/switch/switch.component.js.map +1 -1
- app-rn-runtime/components/input/switch/switch.styles.js +15 -9
- app-rn-runtime/components/input/switch/switch.styles.js.map +1 -1
- app-rn-runtime/components/input/text/text.component.js +12 -1
- app-rn-runtime/components/input/text/text.component.js.map +1 -1
- app-rn-runtime/components/input/text/text.props.js +1 -0
- app-rn-runtime/components/input/text/text.props.js.map +1 -1
- app-rn-runtime/components/input/text/text.styles.js +22 -1
- app-rn-runtime/components/input/text/text.styles.js.map +1 -1
- app-rn-runtime/components/input/textarea/textarea.component.js +12 -1
- app-rn-runtime/components/input/textarea/textarea.component.js.map +1 -1
- app-rn-runtime/components/input/textarea/textarea.props.js +1 -0
- app-rn-runtime/components/input/textarea/textarea.props.js.map +1 -1
- app-rn-runtime/components/input/textarea/textarea.styles.js +17 -0
- app-rn-runtime/components/input/textarea/textarea.styles.js.map +1 -1
- app-rn-runtime/components/input/toggle/toggle.component.js +44 -5
- app-rn-runtime/components/input/toggle/toggle.component.js.map +1 -1
- app-rn-runtime/components/input/toggle/toggle.styles.js +16 -11
- app-rn-runtime/components/input/toggle/toggle.styles.js.map +1 -1
- app-rn-runtime/components/navigation/appnavbar/appnavbar.component.js +16 -3
- app-rn-runtime/components/navigation/appnavbar/appnavbar.component.js.map +1 -1
- app-rn-runtime/components/navigation/appnavbar/appnavbar.styles.js +1 -1
- app-rn-runtime/components/navigation/appnavbar/appnavbar.styles.js.map +1 -1
- app-rn-runtime/components/navigation/basenav/basenav.component.js +2 -0
- app-rn-runtime/components/navigation/basenav/basenav.component.js.map +1 -1
- app-rn-runtime/components/navigation/menu/menu.component.js +5 -3
- app-rn-runtime/components/navigation/menu/menu.component.js.map +1 -1
- app-rn-runtime/components/navigation/menu/menu.styles.js +10 -6
- app-rn-runtime/components/navigation/menu/menu.styles.js.map +1 -1
- app-rn-runtime/components/navigation/navbar/navbar.component.js +7 -4
- app-rn-runtime/components/navigation/navbar/navbar.component.js.map +1 -1
- app-rn-runtime/components/navigation/navitem/navitem.component.js +6 -3
- app-rn-runtime/components/navigation/navitem/navitem.component.js.map +1 -1
- app-rn-runtime/components/navigation/navitem/navitem.styles.js +14 -10
- app-rn-runtime/components/navigation/navitem/navitem.styles.js.map +1 -1
- app-rn-runtime/components/navigation/popover/popover.component.js +10 -5
- app-rn-runtime/components/navigation/popover/popover.component.js.map +1 -1
- app-rn-runtime/components/navigation/popover/popover.props.js.map +1 -1
- app-rn-runtime/components/navigation/popover/popover.styles.js +8 -2
- app-rn-runtime/components/navigation/popover/popover.styles.js.map +1 -1
- app-rn-runtime/components/page/left-panel/left-panel.component.js +2 -2
- app-rn-runtime/components/page/left-panel/left-panel.component.js.map +1 -1
- app-rn-runtime/components/page/left-panel/left-panel.styles.js +6 -1
- app-rn-runtime/components/page/left-panel/left-panel.styles.js.map +1 -1
- app-rn-runtime/components/page/page-content/page-content.component.js +11 -3
- app-rn-runtime/components/page/page-content/page-content.component.js.map +1 -1
- app-rn-runtime/components/page/tabbar/curve.js +84 -0
- app-rn-runtime/components/page/tabbar/curve.js.map +1 -0
- app-rn-runtime/components/page/tabbar/tabbar.component.js +47 -12
- app-rn-runtime/components/page/tabbar/tabbar.component.js.map +1 -1
- app-rn-runtime/components/page/tabbar/tabbar.props.js +1 -0
- app-rn-runtime/components/page/tabbar/tabbar.props.js.map +1 -1
- app-rn-runtime/components/page/tabbar/tabbar.styles.js +76 -1
- app-rn-runtime/components/page/tabbar/tabbar.styles.js.map +1 -1
- app-rn-runtime/core/base.component.js +84 -37
- app-rn-runtime/core/base.component.js.map +1 -1
- app-rn-runtime/core/components/floatinglabel.component.js +45 -0
- app-rn-runtime/core/components/floatinglabel.component.js.map +1 -0
- app-rn-runtime/core/components/textinput.component.js +25 -2
- app-rn-runtime/core/components/textinput.component.js.map +1 -1
- app-rn-runtime/core/constant.service.js +22 -0
- app-rn-runtime/core/constant.service.js.map +1 -0
- app-rn-runtime/core/formatters.js +9 -2
- app-rn-runtime/core/formatters.js.map +1 -1
- app-rn-runtime/core/imageSizeEstimator.js +4 -0
- app-rn-runtime/core/imageSizeEstimator.js.map +1 -1
- app-rn-runtime/core/key.extractor.js +22 -0
- app-rn-runtime/core/key.extractor.js.map +1 -0
- app-rn-runtime/core/tappable.component.js +49 -12
- app-rn-runtime/core/tappable.component.js.map +1 -1
- app-rn-runtime/core/testid.provider.js +5 -0
- app-rn-runtime/core/testid.provider.js.map +1 -0
- app-rn-runtime/core/utils.js +16 -0
- app-rn-runtime/core/utils.js.map +1 -1
- app-rn-runtime/gestures/swipe.animation.js +90 -16
- app-rn-runtime/gestures/swipe.animation.js.map +1 -1
- app-rn-runtime/package.json +6 -3
- app-rn-runtime/runtime/App.js +55 -22
- app-rn-runtime/runtime/App.js.map +1 -1
- app-rn-runtime/runtime/base-fragment.component.js +27 -6
- app-rn-runtime/runtime/base-fragment.component.js.map +1 -1
- app-rn-runtime/runtime/base-page.component.js +25 -2
- app-rn-runtime/runtime/base-page.component.js.map +1 -1
- app-rn-runtime/runtime/services/app-i18n.service.js +7 -0
- app-rn-runtime/runtime/services/app-i18n.service.js.map +1 -1
- app-rn-runtime/runtime/services/app-modal.service.js +1 -1
- app-rn-runtime/runtime/services/app-modal.service.js.map +1 -1
- app-rn-runtime/runtime/services/app-security.service.js +14 -3
- app-rn-runtime/runtime/services/app-security.service.js.map +1 -1
- app-rn-runtime/runtime/services/device/camera-service.js +26 -9
- app-rn-runtime/runtime/services/device/camera-service.js.map +1 -1
- app-rn-runtime/runtime/services/device/scan-service.js +16 -2
- app-rn-runtime/runtime/services/device/scan-service.js.map +1 -1
- app-rn-runtime/runtime/services/webprocess.service.js +0 -1
- app-rn-runtime/runtime/services/webprocess.service.js.map +1 -1
- app-rn-runtime/styles/theme.js +66 -1
- app-rn-runtime/styles/theme.js.map +1 -1
- app-rn-runtime/styles/theme.variables.js +24 -3
- app-rn-runtime/styles/theme.variables.js.map +1 -1
- app-rn-runtime/variables/http.service.js +1 -1
- app-rn-runtime/variables/http.service.js.map +1 -1
- app-rn-runtime/variables/live-variable.js +1 -0
- app-rn-runtime/variables/live-variable.js.map +1 -1
- app-rn-runtime/variables/model-variable.js +13 -1
- app-rn-runtime/variables/model-variable.js.map +1 -1
- app-rn-runtime/variables/service-variable.js +1 -0
- app-rn-runtime/variables/service-variable.js.map +1 -1
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { BaseAction } from "./base-action";
|
|
2
|
+
import { VariableEvents } from '../variables/base-variable';
|
|
2
3
|
import { get } from 'lodash';
|
|
3
4
|
export class LoginAction extends BaseAction {
|
|
4
5
|
constructor(config) {
|
|
@@ -9,6 +10,7 @@ export class LoginAction extends BaseAction {
|
|
|
9
10
|
if (!get(options, 'formData')) {
|
|
10
11
|
params = this.config.paramProvider();
|
|
11
12
|
}
|
|
13
|
+
this.notify(VariableEvents.BEFORE_INVOKE, [this, params]);
|
|
12
14
|
return this.config.securityService().appLogin({
|
|
13
15
|
baseURL: this.config.baseURL,
|
|
14
16
|
formData: get(options, 'formData') || params,
|
|
@@ -16,12 +18,14 @@ export class LoginAction extends BaseAction {
|
|
|
16
18
|
}).then(data => {
|
|
17
19
|
this.config.onSuccess && this.config.onSuccess(this, get(data, 'userInfo'));
|
|
18
20
|
successcb && successcb(data);
|
|
21
|
+
this.notify(VariableEvents.AFTER_INVOKE, [this, data]);
|
|
19
22
|
if (this.config.useDefaultSuccessHandler) {
|
|
20
23
|
this.config.securityService().navigateToLandingPage(data);
|
|
21
24
|
}
|
|
22
25
|
}).catch(error => {
|
|
23
26
|
this.config.onError && this.config.onError(this, error);
|
|
24
27
|
errorcb && errorcb(error);
|
|
28
|
+
this.notify(VariableEvents.AFTER_INVOKE, [this, error]);
|
|
25
29
|
});
|
|
26
30
|
}
|
|
27
31
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["BaseAction","get","LoginAction","constructor","config","invoke","options","successcb","errorcb","params","paramProvider","securityService","appLogin","baseURL","formData","useDefaultSuccessHandler","then","data","onSuccess","navigateToLandingPage","catch","error","onError"],"sources":["login-action.ts"],"sourcesContent":["import { ActionConfig, BaseAction } from \"./base-action\";\nimport { SecurityService } from \"@wavemaker/app-rn-runtime/core/security.service\";\nimport { get } from 'lodash';\nexport interface LoginActionConfig extends ActionConfig {\n securityService: () => SecurityService;\n baseURL: String;\n useDefaultSuccessHandler: boolean;\n}\nexport class LoginAction extends BaseAction<LoginActionConfig> {\n constructor(config: LoginActionConfig) {\n super(config);\n }\n\n invoke(options: any, successcb?: Function, errorcb?: Function) {\n let params;\n if (!get(options, 'formData')) {\n params = this.config.paramProvider();\n }\n return this.config.securityService().appLogin(\n {\n baseURL: this.config.baseURL,\n formData: get(options, 'formData') || params,\n useDefaultSuccessHandler: this.config.useDefaultSuccessHandler\n })\n .then((data: any) => {\n this.config.onSuccess && this.config.onSuccess(this, get(data, 'userInfo'));\n successcb && successcb(data);\n if (this.config.useDefaultSuccessHandler) {\n this.config.securityService().navigateToLandingPage(data);\n }\n })\n .catch((error: any) => {\n this.config.onError && this.config.onError(this, error);\n errorcb && errorcb(error);\n });\n }\n}\n"],"mappings":"AAAA,SAAuBA,UAAU,QAAQ,eAAe;
|
|
1
|
+
{"version":3,"names":["BaseAction","VariableEvents","get","LoginAction","constructor","config","invoke","options","successcb","errorcb","params","paramProvider","notify","BEFORE_INVOKE","securityService","appLogin","baseURL","formData","useDefaultSuccessHandler","then","data","onSuccess","AFTER_INVOKE","navigateToLandingPage","catch","error","onError"],"sources":["login-action.ts"],"sourcesContent":["import { ActionConfig, BaseAction } from \"./base-action\";\nimport { VariableEvents } from '../variables/base-variable';\nimport { SecurityService } from \"@wavemaker/app-rn-runtime/core/security.service\";\nimport { get } from 'lodash';\nexport interface LoginActionConfig extends ActionConfig {\n securityService: () => SecurityService;\n baseURL: String;\n useDefaultSuccessHandler: boolean;\n}\nexport class LoginAction extends BaseAction<LoginActionConfig> {\n constructor(config: LoginActionConfig) {\n super(config);\n }\n\n invoke(options: any, successcb?: Function, errorcb?: Function) {\n let params;\n if (!get(options, 'formData')) {\n params = this.config.paramProvider();\n }\n this.notify(VariableEvents.BEFORE_INVOKE, [this, params]);\n return this.config.securityService().appLogin(\n {\n baseURL: this.config.baseURL,\n formData: get(options, 'formData') || params,\n useDefaultSuccessHandler: this.config.useDefaultSuccessHandler\n })\n .then((data: any) => {\n this.config.onSuccess && this.config.onSuccess(this, get(data, 'userInfo'));\n successcb && successcb(data);\n this.notify(VariableEvents.AFTER_INVOKE, [this, data]);\n if (this.config.useDefaultSuccessHandler) {\n this.config.securityService().navigateToLandingPage(data);\n }\n })\n .catch((error: any) => {\n this.config.onError && this.config.onError(this, error);\n errorcb && errorcb(error);\n this.notify(VariableEvents.AFTER_INVOKE, [this, error]);\n });\n }\n}\n"],"mappings":"AAAA,SAAuBA,UAAU,QAAQ,eAAe;AACxD,SAASC,cAAc,QAAQ,4BAA4B;AAE3D,SAASC,GAAG,QAAQ,QAAQ;AAM5B,OAAO,MAAMC,WAAW,SAASH,UAAU,CAAoB;EAC3DI,WAAWA,CAACC,MAAyB,EAAE;IACnC,KAAK,CAACA,MAAM,CAAC;EACjB;EAEAC,MAAMA,CAACC,OAAY,EAAEC,SAAoB,EAAEC,OAAkB,EAAE;IAC7D,IAAIC,MAAM;IACV,IAAI,CAACR,GAAG,CAACK,OAAO,EAAE,UAAU,CAAC,EAAE;MAC7BG,MAAM,GAAG,IAAI,CAACL,MAAM,CAACM,aAAa,CAAC,CAAC;IACtC;IACA,IAAI,CAACC,MAAM,CAACX,cAAc,CAACY,aAAa,EAAE,CAAC,IAAI,EAAEH,MAAM,CAAC,CAAC;IACzD,OAAO,IAAI,CAACL,MAAM,CAACS,eAAe,CAAC,CAAC,CAACC,QAAQ,CAC3C;MACEC,OAAO,EAAE,IAAI,CAACX,MAAM,CAACW,OAAO;MAC5BC,QAAQ,EAAEf,GAAG,CAACK,OAAO,EAAE,UAAU,CAAC,IAAIG,MAAM;MAC5CQ,wBAAwB,EAAE,IAAI,CAACb,MAAM,CAACa;IAC1C,CAAC,CAAC,CACCC,IAAI,CAAEC,IAAS,IAAK;MACjB,IAAI,CAACf,MAAM,CAACgB,SAAS,IAAI,IAAI,CAAChB,MAAM,CAACgB,SAAS,CAAC,IAAI,EAAEnB,GAAG,CAACkB,IAAI,EAAE,UAAU,CAAC,CAAC;MAC3EZ,SAAS,IAAIA,SAAS,CAACY,IAAI,CAAC;MAC5B,IAAI,CAACR,MAAM,CAACX,cAAc,CAACqB,YAAY,EAAE,CAAC,IAAI,EAAEF,IAAI,CAAC,CAAC;MACtD,IAAI,IAAI,CAACf,MAAM,CAACa,wBAAwB,EAAE;QACxC,IAAI,CAACb,MAAM,CAACS,eAAe,CAAC,CAAC,CAACS,qBAAqB,CAACH,IAAI,CAAC;MAC3D;IACJ,CAAC,CAAC,CACDI,KAAK,CAAEC,KAAU,IAAK;MACnB,IAAI,CAACpB,MAAM,CAACqB,OAAO,IAAI,IAAI,CAACrB,MAAM,CAACqB,OAAO,CAAC,IAAI,EAAED,KAAK,CAAC;MACvDhB,OAAO,IAAIA,OAAO,CAACgB,KAAK,CAAC;MACzB,IAAI,CAACb,MAAM,CAACX,cAAc,CAACqB,YAAY,EAAE,CAAC,IAAI,EAAEG,KAAK,CAAC,CAAC;IAC3D,CAAC,CAAC;EACN;AACJ"}
|
|
@@ -1,17 +1,21 @@
|
|
|
1
1
|
import { BaseAction } from "./base-action";
|
|
2
|
+
import { VariableEvents } from '../variables/base-variable';
|
|
2
3
|
export class LogoutAction extends BaseAction {
|
|
3
4
|
constructor(config) {
|
|
4
5
|
super(config);
|
|
5
6
|
}
|
|
6
7
|
invoke(options, successcb, errorcb) {
|
|
8
|
+
this.notify(VariableEvents.BEFORE_INVOKE, [this]);
|
|
7
9
|
return this.config.securityService().appLogout({
|
|
8
10
|
baseURL: this.config.baseURL
|
|
9
11
|
}).then(data => {
|
|
12
|
+
this.notify(VariableEvents.AFTER_INVOKE, [this, data]);
|
|
10
13
|
this.config.onSuccess && this.config.onSuccess(this, data);
|
|
11
14
|
successcb && successcb(data);
|
|
12
15
|
}).catch(error => {
|
|
13
16
|
this.config.onError && this.config.onError(this, error);
|
|
14
17
|
errorcb && errorcb(error);
|
|
18
|
+
this.notify(VariableEvents.AFTER_INVOKE, [this, error]);
|
|
15
19
|
});
|
|
16
20
|
}
|
|
17
21
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["BaseAction","LogoutAction","constructor","config","invoke","options","successcb","errorcb","securityService","appLogout","baseURL","then","data","onSuccess","catch","error","onError"],"sources":["logout-action.ts"],"sourcesContent":["import { ActionConfig, BaseAction } from \"./base-action\";\nimport { SecurityService } from \"@wavemaker/app-rn-runtime/core/security.service\";\nexport interface LogoutActionConfig extends ActionConfig {\n securityService: () => SecurityService;\n baseURL: String;\n}\nexport class LogoutAction extends BaseAction<LogoutActionConfig> {\n constructor(config: LogoutActionConfig) {\n super(config);\n }\n\n invoke(options: any, successcb?: Function, errorcb?: Function) {\n return this.config.securityService().appLogout({baseURL: this.config.baseURL})\n .then((data: any) => {\n this.config.onSuccess && this.config.onSuccess(this, data);\n successcb && successcb(data)
|
|
1
|
+
{"version":3,"names":["BaseAction","VariableEvents","LogoutAction","constructor","config","invoke","options","successcb","errorcb","notify","BEFORE_INVOKE","securityService","appLogout","baseURL","then","data","AFTER_INVOKE","onSuccess","catch","error","onError"],"sources":["logout-action.ts"],"sourcesContent":["import { ActionConfig, BaseAction } from \"./base-action\";\nimport { SecurityService } from \"@wavemaker/app-rn-runtime/core/security.service\";\nimport { VariableEvents } from '../variables/base-variable';\nexport interface LogoutActionConfig extends ActionConfig {\n securityService: () => SecurityService;\n baseURL: String;\n}\nexport class LogoutAction extends BaseAction<LogoutActionConfig> {\n constructor(config: LogoutActionConfig) {\n super(config);\n }\n\n invoke(options: any, successcb?: Function, errorcb?: Function) {\n this.notify(VariableEvents.BEFORE_INVOKE, [this]);\n return this.config.securityService().appLogout({baseURL: this.config.baseURL})\n .then((data: any) => {\n this.notify(VariableEvents.AFTER_INVOKE, [this, data]);\n this.config.onSuccess && this.config.onSuccess(this, data);\n successcb && successcb(data); \n })\n .catch((error: any) => {\n this.config.onError && this.config.onError(this, error);\n errorcb && errorcb(error);\n this.notify(VariableEvents.AFTER_INVOKE, [this, error]);\n });\n }\n}"],"mappings":"AAAA,SAAuBA,UAAU,QAAQ,eAAe;AAExD,SAASC,cAAc,QAAQ,4BAA4B;AAK3D,OAAO,MAAMC,YAAY,SAASF,UAAU,CAAqB;EAC7DG,WAAWA,CAACC,MAA0B,EAAE;IACpC,KAAK,CAACA,MAAM,CAAC;EACjB;EAEAC,MAAMA,CAACC,OAAY,EAAEC,SAAoB,EAAEC,OAAkB,EAAE;IAC3D,IAAI,CAACC,MAAM,CAACR,cAAc,CAACS,aAAa,EAAE,CAAC,IAAI,CAAC,CAAC;IACjD,OAAO,IAAI,CAACN,MAAM,CAACO,eAAe,CAAC,CAAC,CAACC,SAAS,CAAC;MAACC,OAAO,EAAE,IAAI,CAACT,MAAM,CAACS;IAAO,CAAC,CAAC,CAC7EC,IAAI,CAAEC,IAAS,IAAK;MACjB,IAAI,CAACN,MAAM,CAACR,cAAc,CAACe,YAAY,EAAE,CAAC,IAAI,EAAED,IAAI,CAAC,CAAC;MACtD,IAAI,CAACX,MAAM,CAACa,SAAS,IAAI,IAAI,CAACb,MAAM,CAACa,SAAS,CAAC,IAAI,EAAEF,IAAI,CAAC;MAC1DR,SAAS,IAAIA,SAAS,CAACQ,IAAI,CAAC;IAChC,CAAC,CAAC,CACDG,KAAK,CAAEC,KAAU,IAAK;MACnB,IAAI,CAACf,MAAM,CAACgB,OAAO,IAAI,IAAI,CAAChB,MAAM,CAACgB,OAAO,CAAC,IAAI,EAAED,KAAK,CAAC;MACvDX,OAAO,IAAIA,OAAO,CAACW,KAAK,CAAC;MACzB,IAAI,CAACV,MAAM,CAACR,cAAc,CAACe,YAAY,EAAE,CAAC,IAAI,EAAEG,KAAK,CAAC,CAAC;IAC3D,CAAC,CAAC;EACN;AACJ"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["BaseAction","DEFAULT_DURATION","NotificationAction","constructor","config","_defineProperty","showDialog","prepareToastOptions","_options$class","_params$class","options","arguments","length","undefined","params","paramProvider","o","text","message","type","class","toLowerCase","onClose","onClick","onOk","content","partialContent","hideOnClick","toasterPosition","position","placement","split","styles","top","bottom","duration","parseInt","name","getMessage","invoke","success","error","operation","toasterService","showToast","onCancel"],"sources":["notification-action.ts"],"sourcesContent":["import { ActionConfig, BaseAction } from \"./base-action\";\nimport { ToastOptions, ToastService } from '@wavemaker/app-rn-runtime/core/toast.service';\nimport React from 'react';\nexport interface NotificationActionConfig extends ActionConfig {\n showDialog: Function;\n onOk: any;\n onCancel: any;\n onClose: any;\n operation: string;\n partialContent: React.ReactNode;\n toasterService: () => ToastService;\n}\nconst DEFAULT_DURATION = 3000;\nexport class NotificationAction extends BaseAction<NotificationActionConfig> {\n showDialog: Function;\n constructor(config: NotificationActionConfig) {\n super(config);\n this.showDialog = config.showDialog;\n }\n\n prepareToastOptions(options: any = {}) {\n const params = this.config.paramProvider();\n const o = {} as ToastOptions;\n o.text = options.message || params.text;\n o.type = options.class?.toLowerCase() || params.class?.toLowerCase();\n o.onClose = () => {\n this.config.onClose && this.config.onClose(this);\n },\n o.onClick = () => {\n this.config.onOk && this.config.onOk(this);\n },\n o.content = this.config.partialContent;\n o.hideOnClick = options.hideOnClick || true;\n const toasterPosition = options.position || params.toasterPosition || 'bottom right';\n const placement = toasterPosition.split(' ')[0];\n switch(placement) {\n case 'top':\n o.styles = {top: 0};\n break;\n case 'bottom':\n o.styles = {bottom: 0};\n break;\n case 'center':\n o.styles = {top: '50%'};\n break;\n }\n if (this.config.partialContent) {\n if (!o.styles) {\n o.styles = {};\n }\n }\n if (!params.duration) {\n params.duration = (params.duration !== 0 && o.type === 'success') ? DEFAULT_DURATION : 0;\n }\n o.duration = parseInt(options.duration || params.duration);\n o.name = this.name;\n return o;\n }\n\n
|
|
1
|
+
{"version":3,"names":["BaseAction","DEFAULT_DURATION","NotificationAction","constructor","config","_defineProperty","showDialog","prepareToastOptions","_options$class","_params$class","options","arguments","length","undefined","params","paramProvider","o","text","message","type","class","toLowerCase","onClose","onClick","onOk","content","partialContent","hideOnClick","toasterPosition","position","placement","split","styles","top","bottom","duration","parseInt","name","getMessage","invoke","success","error","operation","toasterService","showToast","onCancel"],"sources":["notification-action.ts"],"sourcesContent":["import { ActionConfig, BaseAction } from \"./base-action\";\nimport { ToastOptions, ToastService } from '@wavemaker/app-rn-runtime/core/toast.service';\nimport React from 'react';\nexport interface NotificationActionConfig extends ActionConfig {\n showDialog: Function;\n onOk: any;\n onCancel: any;\n onClose: any;\n operation: string;\n partialContent: React.ReactNode;\n toasterService: () => ToastService;\n}\nconst DEFAULT_DURATION = 3000;\nexport class NotificationAction extends BaseAction<NotificationActionConfig> {\n showDialog: Function;\n constructor(config: NotificationActionConfig) {\n super(config);\n this.showDialog = config.showDialog;\n }\n\n prepareToastOptions(options: any = {}) {\n const params = this.config.paramProvider();\n const o = {} as ToastOptions;\n o.text = options.message || params.text;\n o.type = options.class?.toLowerCase() || params.class?.toLowerCase();\n o.onClose = () => {\n this.config.onClose && this.config.onClose(this);\n },\n o.onClick = () => {\n this.config.onOk && this.config.onOk(this);\n },\n o.content = this.config.partialContent;\n o.hideOnClick = options.hideOnClick || true;\n const toasterPosition = options.position || params.toasterPosition || 'bottom right';\n const placement = toasterPosition.split(' ')[0];\n switch(placement) {\n case 'top':\n o.styles = {top: 0};\n break;\n case 'bottom':\n o.styles = {bottom: 0};\n break;\n case 'center':\n o.styles = {top: '50%'};\n break;\n }\n if (this.config.partialContent) {\n if (!o.styles) {\n o.styles = {};\n }\n }\n if (!params.duration) {\n params.duration = (params.duration !== 0 && o.type === 'success') ? DEFAULT_DURATION : 0;\n }\n o.duration = parseInt(options.duration || params.duration);\n o.name = this.name;\n return o;\n }\n\n getMessage() {\n return this.config.paramProvider().text;\n }\n\n invoke(options: any, success: any, error: any) {\n super.invoke(options, success, error);\n if (this.config.operation === 'toast') {\n const toasterService = this.config.toasterService();\n return toasterService.showToast(this.prepareToastOptions(options));\n } else {\n return this.showDialog && this.showDialog({...this.params, onOk: this.config.onOk, onCancel: this.config.onCancel, onClose: this.config.onClose});\n }\n }\n}\n"],"mappings":";;;AAAA,SAAuBA,UAAU,QAAQ,eAAe;AAYxD,MAAMC,gBAAgB,GAAG,IAAI;AAC7B,OAAO,MAAMC,kBAAkB,SAASF,UAAU,CAA2B;EAEzEG,WAAWA,CAACC,MAAgC,EAAE;IAC1C,KAAK,CAACA,MAAM,CAAC;IAACC,eAAA;IACd,IAAI,CAACC,UAAU,GAAGF,MAAM,CAACE,UAAU;EACvC;EAEAC,mBAAmBA,CAAA,EAAoB;IAAA,IAAAC,cAAA,EAAAC,aAAA;IAAA,IAAnBC,OAAY,GAAAC,SAAA,CAAAC,MAAA,QAAAD,SAAA,QAAAE,SAAA,GAAAF,SAAA,MAAG,CAAC,CAAC;IACjC,MAAMG,MAAM,GAAG,IAAI,CAACV,MAAM,CAACW,aAAa,CAAC,CAAC;IAC1C,MAAMC,CAAC,GAAG,CAAC,CAAiB;IAC5BA,CAAC,CAACC,IAAI,GAAGP,OAAO,CAACQ,OAAO,IAAIJ,MAAM,CAACG,IAAI;IACvCD,CAAC,CAACG,IAAI,GAAG,EAAAX,cAAA,GAAAE,OAAO,CAACU,KAAK,cAAAZ,cAAA,uBAAbA,cAAA,CAAea,WAAW,CAAC,CAAC,OAAAZ,aAAA,GAAIK,MAAM,CAACM,KAAK,cAAAX,aAAA,uBAAZA,aAAA,CAAcY,WAAW,CAAC,CAAC;IACpEL,CAAC,CAACM,OAAO,GAAG,MAAM;MACd,IAAI,CAAClB,MAAM,CAACkB,OAAO,IAAI,IAAI,CAAClB,MAAM,CAACkB,OAAO,CAAC,IAAI,CAAC;IACpD,CAAC,EACDN,CAAC,CAACO,OAAO,GAAG,MAAM;MACd,IAAI,CAACnB,MAAM,CAACoB,IAAI,IAAI,IAAI,CAACpB,MAAM,CAACoB,IAAI,CAAC,IAAI,CAAC;IAC9C,CAAC,EACDR,CAAC,CAACS,OAAO,GAAG,IAAI,CAACrB,MAAM,CAACsB,cAAc;IACtCV,CAAC,CAACW,WAAW,GAAGjB,OAAO,CAACiB,WAAW,IAAI,IAAI;IAC3C,MAAMC,eAAe,GAAGlB,OAAO,CAACmB,QAAQ,IAAIf,MAAM,CAACc,eAAe,IAAI,cAAc;IACpF,MAAME,SAAS,GAAGF,eAAe,CAACG,KAAK,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC;IAC/C,QAAOD,SAAS;MACZ,KAAK,KAAK;QACNd,CAAC,CAACgB,MAAM,GAAG;UAACC,GAAG,EAAE;QAAC,CAAC;QACnB;MACJ,KAAK,QAAQ;QACTjB,CAAC,CAACgB,MAAM,GAAG;UAACE,MAAM,EAAE;QAAC,CAAC;QACtB;MACJ,KAAK,QAAQ;QACTlB,CAAC,CAACgB,MAAM,GAAG;UAACC,GAAG,EAAE;QAAK,CAAC;QACvB;IACR;IACA,IAAI,IAAI,CAAC7B,MAAM,CAACsB,cAAc,EAAE;MAC5B,IAAI,CAACV,CAAC,CAACgB,MAAM,EAAE;QACXhB,CAAC,CAACgB,MAAM,GAAG,CAAC,CAAC;MACjB;IACJ;IACA,IAAI,CAAClB,MAAM,CAACqB,QAAQ,EAAE;MACpBrB,MAAM,CAACqB,QAAQ,GAAIrB,MAAM,CAACqB,QAAQ,KAAK,CAAC,IAAInB,CAAC,CAACG,IAAI,KAAK,SAAS,GAAIlB,gBAAgB,GAAG,CAAC;IAC1F;IACAe,CAAC,CAACmB,QAAQ,GAAGC,QAAQ,CAAC1B,OAAO,CAACyB,QAAQ,IAAIrB,MAAM,CAACqB,QAAQ,CAAC;IAC1DnB,CAAC,CAACqB,IAAI,GAAG,IAAI,CAACA,IAAI;IAClB,OAAOrB,CAAC;EACV;EAEFsB,UAAUA,CAAA,EAAG;IACT,OAAO,IAAI,CAAClC,MAAM,CAACW,aAAa,CAAC,CAAC,CAACE,IAAI;EAC3C;EAEAsB,MAAMA,CAAC7B,OAAY,EAAE8B,OAAY,EAAEC,KAAU,EAAE;IAC3C,KAAK,CAACF,MAAM,CAAC7B,OAAO,EAAE8B,OAAO,EAAEC,KAAK,CAAC;IACrC,IAAI,IAAI,CAACrC,MAAM,CAACsC,SAAS,KAAK,OAAO,EAAE;MACnC,MAAMC,cAAc,GAAG,IAAI,CAACvC,MAAM,CAACuC,cAAc,CAAC,CAAC;MACnD,OAAOA,cAAc,CAACC,SAAS,CAAC,IAAI,CAACrC,mBAAmB,CAACG,OAAO,CAAC,CAAC;IACtE,CAAC,MAAM;MACH,OAAO,IAAI,CAACJ,UAAU,IAAI,IAAI,CAACA,UAAU,CAAC;QAAC,GAAG,IAAI,CAACQ,MAAM;QAAEU,IAAI,EAAE,IAAI,CAACpB,MAAM,CAACoB,IAAI;QAAEqB,QAAQ,EAAE,IAAI,CAACzC,MAAM,CAACyC,QAAQ;QAAEvB,OAAO,EAAE,IAAI,CAAClB,MAAM,CAACkB;MAAO,CAAC,CAAC;IACrJ;EACJ;AACJ"}
|
app-rn-runtime/components/advanced/carousel/carousel-template/carousel-template.component.js
CHANGED
|
@@ -9,8 +9,11 @@ export default class WmCarouselTemplate extends BaseComponent {
|
|
|
9
9
|
super(props, DEFAULT_CLASS, new WmCarouselTemplateProps());
|
|
10
10
|
}
|
|
11
11
|
renderWidget(props) {
|
|
12
|
+
var _this$parent;
|
|
12
13
|
return /*#__PURE__*/React.createElement(View, {
|
|
13
|
-
style: this.styles.root
|
|
14
|
+
style: [this.styles.root, {
|
|
15
|
+
height: this.styles.root.height || ((_this$parent = this.parent) === null || _this$parent === void 0 ? void 0 : _this$parent.styles.root.height) && '100%'
|
|
16
|
+
}]
|
|
14
17
|
}, this._background, props.children);
|
|
15
18
|
}
|
|
16
19
|
}
|
app-rn-runtime/components/advanced/carousel/carousel-template/carousel-template.component.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["React","View","BaseComponent","BaseComponentState","WmCarouselTemplateProps","DEFAULT_CLASS","WmCarouselTemplateState","WmCarouselTemplate","constructor","props","renderWidget","createElement","style","styles","root","_background","children"],"sources":["carousel-template.component.tsx"],"sourcesContent":["import React from 'react';\nimport { View } from 'react-native';\nimport { BaseComponent, BaseComponentState } from '@wavemaker/app-rn-runtime/core/base.component';\n\nimport WmCarouselTemplateProps from './carousel-template.props';\nimport { DEFAULT_CLASS, WmCarouselTemplateStyles } from './carousel-template.styles';\n\nexport class WmCarouselTemplateState extends BaseComponentState<WmCarouselTemplateProps> {}\n\nexport default class WmCarouselTemplate extends BaseComponent<WmCarouselTemplateProps, WmCarouselTemplateState, WmCarouselTemplateStyles> {\n\n constructor(props: WmCarouselTemplateProps) {\n super(props, DEFAULT_CLASS, new WmCarouselTemplateProps());\n }\n\n renderWidget(props: WmCarouselTemplateProps) {\n return (<View style={this.styles.root}>{this._background}{props.children}</View>); \n }\n}\n"],"mappings":"AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,SAASC,IAAI,QAAQ,cAAc;AACnC,SAASC,aAAa,EAAEC,kBAAkB,QAAQ,+CAA+C;AAEjG,OAAOC,uBAAuB,MAAM,2BAA2B;AAC/D,SAASC,aAAa,QAAkC,4BAA4B;AAEpF,OAAO,MAAMC,uBAAuB,SAASH,kBAAkB,CAA0B;AAEzF,eAAe,MAAMI,kBAAkB,SAASL,aAAa,CAA6E;EAExIM,WAAWA,CAACC,KAA8B,EAAE;IAC1C,KAAK,CAACA,KAAK,EAAEJ,aAAa,EAAE,IAAID,uBAAuB,CAAC,CAAC,CAAC;EAC5D;EAEAM,YAAYA,CAACD,KAA8B,EAAE;IAC3C,
|
|
1
|
+
{"version":3,"names":["React","View","BaseComponent","BaseComponentState","WmCarouselTemplateProps","DEFAULT_CLASS","WmCarouselTemplateState","WmCarouselTemplate","constructor","props","renderWidget","_this$parent","createElement","style","styles","root","height","parent","_background","children"],"sources":["carousel-template.component.tsx"],"sourcesContent":["import React from 'react';\nimport { View } from 'react-native';\nimport { BaseComponent, BaseComponentState } from '@wavemaker/app-rn-runtime/core/base.component';\n\nimport WmCarouselTemplateProps from './carousel-template.props';\nimport { DEFAULT_CLASS, WmCarouselTemplateStyles } from './carousel-template.styles';\n\nexport class WmCarouselTemplateState extends BaseComponentState<WmCarouselTemplateProps> {}\n\nexport default class WmCarouselTemplate extends BaseComponent<WmCarouselTemplateProps, WmCarouselTemplateState, WmCarouselTemplateStyles> {\n\n constructor(props: WmCarouselTemplateProps) {\n super(props, DEFAULT_CLASS, new WmCarouselTemplateProps());\n }\n\n renderWidget(props: WmCarouselTemplateProps) {\n return (<View style={[this.styles.root, {\n height: this.styles.root.height || (this.parent?.styles.root.height && '100%')\n }]}>{this._background}{props.children}</View>); \n }\n}\n"],"mappings":"AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,SAASC,IAAI,QAAQ,cAAc;AACnC,SAASC,aAAa,EAAEC,kBAAkB,QAAQ,+CAA+C;AAEjG,OAAOC,uBAAuB,MAAM,2BAA2B;AAC/D,SAASC,aAAa,QAAkC,4BAA4B;AAEpF,OAAO,MAAMC,uBAAuB,SAASH,kBAAkB,CAA0B;AAEzF,eAAe,MAAMI,kBAAkB,SAASL,aAAa,CAA6E;EAExIM,WAAWA,CAACC,KAA8B,EAAE;IAC1C,KAAK,CAACA,KAAK,EAAEJ,aAAa,EAAE,IAAID,uBAAuB,CAAC,CAAC,CAAC;EAC5D;EAEAM,YAAYA,CAACD,KAA8B,EAAE;IAAA,IAAAE,YAAA;IAC3C,oBAAQX,KAAA,CAAAY,aAAA,CAACX,IAAI;MAACY,KAAK,EAAE,CAAC,IAAI,CAACC,MAAM,CAACC,IAAI,EAAE;QACtCC,MAAM,EAAE,IAAI,CAACF,MAAM,CAACC,IAAI,CAACC,MAAM,IAAK,EAAAL,YAAA,OAAI,CAACM,MAAM,cAAAN,YAAA,uBAAXA,YAAA,CAAaG,MAAM,CAACC,IAAI,CAACC,MAAM,KAAI;MACzE,CAAC;IAAE,GAAE,IAAI,CAACE,WAAW,EAAET,KAAK,CAACU,QAAe,CAAC;EAC/C;AACF"}
|
app-rn-runtime/components/advanced/carousel/carousel-template/carousel-template.styles.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["BASE_THEME","defineStyles","DEFAULT_CLASS","registerStyle","themeVariables","addStyle","defaultStyles","root","flexDirection","justifyContent","alignItems","width","
|
|
1
|
+
{"version":3,"names":["BASE_THEME","defineStyles","DEFAULT_CLASS","registerStyle","themeVariables","addStyle","defaultStyles","root","flexDirection","justifyContent","alignItems","width","text"],"sources":["carousel-template.styles.ts"],"sourcesContent":["import BASE_THEME from '@wavemaker/app-rn-runtime/styles/theme';\nimport { BaseStyles, defineStyles } from '@wavemaker/app-rn-runtime/core/base.component';\n\nexport type WmCarouselTemplateStyles = BaseStyles & {};\n\nexport const DEFAULT_CLASS = 'app-carousel-template';\n\nBASE_THEME.registerStyle((themeVariables, addStyle) => {\n const defaultStyles: WmCarouselTemplateStyles = defineStyles({\n root: {\n flexDirection: 'column',\n justifyContent: 'center',\n alignItems: 'center',\n width: '100%'\n },\n text: {}\n });\n\n addStyle(DEFAULT_CLASS, '', defaultStyles);\n});"],"mappings":"AAAA,OAAOA,UAAU,MAAM,wCAAwC;AAC/D,SAAqBC,YAAY,QAAQ,+CAA+C;AAIxF,OAAO,MAAMC,aAAa,GAAG,uBAAuB;AAEpDF,UAAU,CAACG,aAAa,CAAC,CAACC,cAAc,EAAEC,QAAQ,KAAK;EACnD,MAAMC,aAAuC,GAAGL,YAAY,CAAC;IACzDM,IAAI,EAAE;MACFC,aAAa,EAAE,QAAQ;MACvBC,cAAc,EAAE,QAAQ;MACxBC,UAAU,EAAE,QAAQ;MACpBC,KAAK,EAAE;IACX,CAAC;IACDC,IAAI,EAAE,CAAC;EACX,CAAC,CAAC;EAEFP,QAAQ,CAACH,aAAa,EAAE,EAAE,EAAEI,aAAa,CAAC;AAC9C,CAAC,CAAC"}
|
|
@@ -2,87 +2,134 @@ 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 {
|
|
6
|
-
import
|
|
5
|
+
import { isArray, isUndefined } from 'lodash-es';
|
|
6
|
+
import { Animated, Easing, View } from 'react-native';
|
|
7
|
+
import { DefaultKeyExtractor } from '@wavemaker/app-rn-runtime/core/key.extractor';
|
|
7
8
|
import WmIcon from '@wavemaker/app-rn-runtime/components/basic/icon/icon.component';
|
|
8
9
|
import { BaseComponent, BaseComponentState } from '@wavemaker/app-rn-runtime/core/base.component';
|
|
10
|
+
import * as SwipeAnimation from '@wavemaker/app-rn-runtime/gestures/swipe.animation';
|
|
11
|
+
import { Tappable } from '@wavemaker/app-rn-runtime/core/tappable.component';
|
|
9
12
|
import WmCarouselProps from './carousel.props';
|
|
10
13
|
import { DEFAULT_CLASS } from './carousel.styles';
|
|
11
14
|
export class WmCarouselState extends BaseComponentState {
|
|
12
15
|
constructor() {
|
|
13
16
|
super(...arguments);
|
|
14
|
-
_defineProperty(this, "activeIndex",
|
|
15
|
-
_defineProperty(this, "sliderWidth", 0);
|
|
17
|
+
_defineProperty(this, "activeIndex", 1);
|
|
16
18
|
}
|
|
17
19
|
}
|
|
18
20
|
export default class WmCarousel extends BaseComponent {
|
|
19
21
|
constructor(_props) {
|
|
20
22
|
super(_props, DEFAULT_CLASS, new WmCarouselProps(), new WmCarouselState());
|
|
21
|
-
_defineProperty(this, "carouselRef", null);
|
|
22
23
|
_defineProperty(this, "noOfSlides", 0);
|
|
24
|
+
_defineProperty(this, "slidesLayout", []);
|
|
25
|
+
_defineProperty(this, "keyExtractor", new DefaultKeyExtractor());
|
|
23
26
|
_defineProperty(this, "stopPlay", null);
|
|
27
|
+
_defineProperty(this, "dotScale", new Animated.Value(0));
|
|
28
|
+
_defineProperty(this, "dotPosition", new Animated.Value(0));
|
|
29
|
+
_defineProperty(this, "animationView", null);
|
|
30
|
+
_defineProperty(this, "animationHandlers", {
|
|
31
|
+
bounds: e => {
|
|
32
|
+
var _this$slidesLayout, _this$slidesLayout$ac;
|
|
33
|
+
const activeTabIndex = this.state.activeIndex - 1;
|
|
34
|
+
let lower = 0;
|
|
35
|
+
if (activeTabIndex > 0) {
|
|
36
|
+
lower = this.slidesLayout.filter((l, i) => i < activeTabIndex - 1).reduce((s, l) => s + l.width, 0);
|
|
37
|
+
}
|
|
38
|
+
let center = lower + (((_this$slidesLayout = this.slidesLayout[activeTabIndex - 1]) === null || _this$slidesLayout === void 0 ? void 0 : _this$slidesLayout.width) || 0);
|
|
39
|
+
let upper = center + (((_this$slidesLayout$ac = this.slidesLayout[activeTabIndex]) === null || _this$slidesLayout$ac === void 0 ? void 0 : _this$slidesLayout$ac.width) || 0);
|
|
40
|
+
return {
|
|
41
|
+
lower: -1 * lower,
|
|
42
|
+
center: -1 * center,
|
|
43
|
+
upper: -1 * upper
|
|
44
|
+
};
|
|
45
|
+
},
|
|
46
|
+
computePhase: value => {
|
|
47
|
+
var _this$slidesLayout$ac2;
|
|
48
|
+
const activeTabIndex = this.state.activeIndex - 1;
|
|
49
|
+
const w = ((_this$slidesLayout$ac2 = this.slidesLayout[activeTabIndex]) === null || _this$slidesLayout$ac2 === void 0 ? void 0 : _this$slidesLayout$ac2.width) || 0;
|
|
50
|
+
return w && Math.abs(value / w);
|
|
51
|
+
},
|
|
52
|
+
onLower: e => {
|
|
53
|
+
this.onSlideChange(this.state.activeIndex - 1);
|
|
54
|
+
},
|
|
55
|
+
onUpper: e => {
|
|
56
|
+
this.onSlideChange(this.state.activeIndex + 1);
|
|
57
|
+
}
|
|
58
|
+
});
|
|
24
59
|
_defineProperty(this, "onSlideChange", index => {
|
|
25
60
|
const prevIndex = this.state.activeIndex;
|
|
26
61
|
this.updateState({
|
|
27
62
|
activeIndex: index
|
|
28
63
|
}, () => this.invokeEventCallback('onChange', [this, index, prevIndex]));
|
|
64
|
+
this.animatePagination(index);
|
|
29
65
|
});
|
|
30
|
-
_defineProperty(this, "renderItem",
|
|
66
|
+
_defineProperty(this, "renderItem", (item, index) => {
|
|
31
67
|
const props = this.state.props;
|
|
32
68
|
if (props.type === 'dynamic') {
|
|
33
|
-
return props.renderSlide ? props.renderSlide(
|
|
69
|
+
return props.renderSlide ? props.renderSlide(item, index, this) : null;
|
|
34
70
|
}
|
|
35
|
-
return props.children[
|
|
36
|
-
});
|
|
37
|
-
_defineProperty(this, "onLayoutChange", e => {
|
|
38
|
-
this.updateState({
|
|
39
|
-
sliderWidth: e.nativeEvent.layout.width
|
|
40
|
-
});
|
|
41
|
-
});
|
|
42
|
-
_defineProperty(this, "getDotElement", _ref => {
|
|
43
|
-
let {
|
|
44
|
-
active,
|
|
45
|
-
index
|
|
46
|
-
} = _ref;
|
|
47
|
-
return /*#__PURE__*/React.createElement(Text, {
|
|
48
|
-
style: active ? this.styles.activeDotStyle : this.styles.dotStyle
|
|
49
|
-
}, index);
|
|
71
|
+
return props.children[index];
|
|
50
72
|
});
|
|
51
73
|
_defineProperty(this, "next", () => {
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
74
|
+
const props = this.state.props;
|
|
75
|
+
const data = props.type === 'dynamic' ? props.dataset : props.children;
|
|
76
|
+
if (this.state.activeIndex >= (data === null || data === void 0 ? void 0 : data.length) || 0) {
|
|
77
|
+
var _this$animationView;
|
|
78
|
+
this.onSlideChange(1);
|
|
79
|
+
(_this$animationView = this.animationView) === null || _this$animationView === void 0 ? void 0 : _this$animationView.setPosition(0);
|
|
55
80
|
} else {
|
|
56
|
-
var _this$
|
|
57
|
-
(_this$
|
|
81
|
+
var _this$animationView2;
|
|
82
|
+
(_this$animationView2 = this.animationView) === null || _this$animationView2 === void 0 ? void 0 : _this$animationView2.goToUpper();
|
|
58
83
|
}
|
|
59
84
|
});
|
|
60
85
|
_defineProperty(this, "prev", () => {
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
(_this$carouselRef3 = this.carouselRef) === null || _this$carouselRef3 === void 0 ? void 0 : _this$carouselRef3.snapToPrev();
|
|
64
|
-
} else {
|
|
65
|
-
var _this$carouselRef4;
|
|
66
|
-
(_this$carouselRef4 = this.carouselRef) === null || _this$carouselRef4 === void 0 ? void 0 : _this$carouselRef4.snapToItem(this.noOfSlides - 1);
|
|
67
|
-
}
|
|
86
|
+
var _this$animationView3;
|
|
87
|
+
(_this$animationView3 = this.animationView) === null || _this$animationView3 === void 0 ? void 0 : _this$animationView3.goToLower();
|
|
68
88
|
});
|
|
69
89
|
this.cleanup.push(() => {
|
|
70
90
|
this.stopPlay && this.stopPlay();
|
|
71
91
|
});
|
|
72
92
|
}
|
|
93
|
+
addSlideLayout(index, nativeEvent) {
|
|
94
|
+
this.slidesLayout[index] = nativeEvent.nativeEvent.layout;
|
|
95
|
+
if (index === this.state.activeIndex) {
|
|
96
|
+
this.forceUpdate();
|
|
97
|
+
}
|
|
98
|
+
}
|
|
99
|
+
generateItemKey(item, index, props) {
|
|
100
|
+
if (props.itemkey && item && !this._showSkeleton) {
|
|
101
|
+
return props.itemkey(item, index);
|
|
102
|
+
}
|
|
103
|
+
return 'list_item_' + this.keyExtractor.getKey(item, true);
|
|
104
|
+
}
|
|
73
105
|
autoPlay() {
|
|
74
106
|
const props = this.state.props;
|
|
75
107
|
this.stopPlay && this.stopPlay();
|
|
76
|
-
if (props.animation && props.animationinterval) {
|
|
108
|
+
if (props.animation === 'auto' && props.animationinterval) {
|
|
77
109
|
const intervalId = setInterval(() => {
|
|
78
110
|
this.next();
|
|
79
111
|
}, props.animationinterval * 1000);
|
|
80
112
|
this.stopPlay = () => clearInterval(intervalId);
|
|
113
|
+
} else {
|
|
114
|
+
setTimeout(() => {
|
|
115
|
+
var _this$animationView4;
|
|
116
|
+
this.onSlideChange(1);
|
|
117
|
+
(_this$animationView4 = this.animationView) === null || _this$animationView4 === void 0 ? void 0 : _this$animationView4.setPosition(0);
|
|
118
|
+
}, 1000);
|
|
81
119
|
}
|
|
82
120
|
}
|
|
83
121
|
onPropertyChange(name, $new, $old) {
|
|
84
122
|
super.onPropertyChange(name, $new, $old);
|
|
85
123
|
switch (name) {
|
|
124
|
+
case 'dataset':
|
|
125
|
+
{
|
|
126
|
+
var _this$keyExtractor;
|
|
127
|
+
(_this$keyExtractor = this.keyExtractor) === null || _this$keyExtractor === void 0 ? void 0 : _this$keyExtractor.clear();
|
|
128
|
+
this.updateState({
|
|
129
|
+
activeIndex: Math.min(this.state.activeIndex, ($new === null || $new === void 0 ? void 0 : $new.length) || 1)
|
|
130
|
+
});
|
|
131
|
+
break;
|
|
132
|
+
}
|
|
86
133
|
case 'animation':
|
|
87
134
|
case 'animationinterval':
|
|
88
135
|
{
|
|
@@ -90,58 +137,156 @@ export default class WmCarousel extends BaseComponent {
|
|
|
90
137
|
}
|
|
91
138
|
}
|
|
92
139
|
}
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
140
|
+
animatePagination(index) {
|
|
141
|
+
var _this$styles$dotStyle, _this$styles$dotStyle2, _this$styles$dotStyle3;
|
|
142
|
+
const prevIndex = this.state.activeIndex;
|
|
143
|
+
const margin = (((_this$styles$dotStyle = this.styles.dotStyle) === null || _this$styles$dotStyle === void 0 ? void 0 : _this$styles$dotStyle.marginLeft) || 0) + (((_this$styles$dotStyle2 = this.styles.dotStyle) === null || _this$styles$dotStyle2 === void 0 ? void 0 : _this$styles$dotStyle2.marginRight) || 0);
|
|
144
|
+
const width = ((_this$styles$dotStyle3 = this.styles.dotStyle) === null || _this$styles$dotStyle3 === void 0 ? void 0 : _this$styles$dotStyle3.width) || 2;
|
|
145
|
+
const size = margin + width;
|
|
146
|
+
const position = Math.max(index - 1, 0) * size;
|
|
147
|
+
const scale = Math.abs(index - prevIndex) * size;
|
|
148
|
+
const options = {
|
|
149
|
+
useNativeDriver: true,
|
|
150
|
+
duration: 200,
|
|
151
|
+
easing: Easing.out(Easing.linear)
|
|
152
|
+
};
|
|
153
|
+
if (prevIndex < index) {
|
|
154
|
+
Animated.sequence([Animated.timing(this.dotScale, {
|
|
155
|
+
toValue: scale,
|
|
156
|
+
...options
|
|
157
|
+
}), Animated.parallel([Animated.timing(this.dotScale, {
|
|
158
|
+
toValue: 0,
|
|
159
|
+
...options
|
|
160
|
+
}), Animated.timing(this.dotPosition, {
|
|
161
|
+
toValue: (this.isRTL ? -1 : 1) * position,
|
|
162
|
+
...options
|
|
163
|
+
})])]).start();
|
|
164
|
+
} else if (prevIndex > index) {
|
|
165
|
+
Animated.sequence([Animated.parallel([Animated.timing(this.dotScale, {
|
|
166
|
+
toValue: scale,
|
|
167
|
+
...options
|
|
168
|
+
}), Animated.timing(this.dotPosition, {
|
|
169
|
+
toValue: (this.isRTL ? -1 : 1) * position,
|
|
170
|
+
...options
|
|
171
|
+
})]), Animated.timing(this.dotScale, {
|
|
172
|
+
toValue: 0,
|
|
173
|
+
...options
|
|
174
|
+
})]).start();
|
|
175
|
+
}
|
|
176
|
+
}
|
|
177
|
+
renderPagination(data) {
|
|
178
|
+
const maxNoOfDots = this.state.props.maxnoofdots;
|
|
179
|
+
let minIndex = Math.max(this.state.activeIndex - maxNoOfDots + 1, 0);
|
|
180
|
+
let maxIndex = Math.min(minIndex + maxNoOfDots - 1, data.length);
|
|
181
|
+
if (maxIndex === data.length) {
|
|
182
|
+
minIndex = maxIndex - maxNoOfDots;
|
|
183
|
+
}
|
|
184
|
+
return /*#__PURE__*/React.createElement(View, {
|
|
185
|
+
style: this.styles.dotsWrapperStyle
|
|
186
|
+
}, /*#__PURE__*/React.createElement(View, {
|
|
187
|
+
style: {
|
|
188
|
+
flexDirection: this.isRTL ? 'row-reverse' : 'row'
|
|
189
|
+
}
|
|
190
|
+
}, data.map((item, index) => {
|
|
191
|
+
return index >= minIndex && index <= maxIndex ? /*#__PURE__*/React.createElement(View, {
|
|
192
|
+
key: 'dots_' + this.generateItemKey(item, index, this.state.props),
|
|
193
|
+
style: [this.styles.dotStyle]
|
|
194
|
+
}) : null;
|
|
195
|
+
}), /*#__PURE__*/React.createElement(Animated.View, {
|
|
196
|
+
style: [this.styles.dotStyle, this.styles.activeDotStyle, {
|
|
197
|
+
width: undefined,
|
|
198
|
+
height: undefined,
|
|
199
|
+
transform: [{
|
|
200
|
+
translateX: this.dotPosition
|
|
201
|
+
}]
|
|
202
|
+
}, this.isRTL ? {
|
|
203
|
+
right: 0
|
|
204
|
+
} : {
|
|
205
|
+
left: 0
|
|
206
|
+
}]
|
|
207
|
+
}, /*#__PURE__*/React.createElement(Animated.View, {
|
|
208
|
+
style: [{
|
|
209
|
+
width: 1,
|
|
210
|
+
height: 1
|
|
211
|
+
}, {
|
|
212
|
+
// This is failing in Android
|
|
213
|
+
// minWidth: this.dotScale
|
|
214
|
+
}]
|
|
215
|
+
}))));
|
|
104
216
|
}
|
|
105
217
|
renderWidget(props) {
|
|
218
|
+
var _data, _this$styles$slide;
|
|
106
219
|
const hasNavs = props.controls === 'both' || props.controls === 'navs';
|
|
107
220
|
const hasDots = props.controls === 'both' || props.controls === 'indicators';
|
|
108
221
|
let styles = this.styles;
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
222
|
+
let data = props.type === 'dynamic' ? props.dataset : props.children;
|
|
223
|
+
data = isArray(data) ? data : [];
|
|
224
|
+
this.noOfSlides = ((_data = data) === null || _data === void 0 ? void 0 : _data.length) || 0;
|
|
225
|
+
let slideScale = undefined;
|
|
226
|
+
let slideTranslateX = undefined;
|
|
227
|
+
if (isArray((_this$styles$slide = this.styles.slide) === null || _this$styles$slide === void 0 ? void 0 : _this$styles$slide.transform)) {
|
|
228
|
+
var _this$styles$slide2, _this$styles$slide3;
|
|
229
|
+
slideScale = (_this$styles$slide2 = this.styles.slide) === null || _this$styles$slide2 === void 0 || (_this$styles$slide2 = _this$styles$slide2.transform) === null || _this$styles$slide2 === void 0 || (_this$styles$slide2 = _this$styles$slide2.find(o => !isUndefined(o.scale))) === null || _this$styles$slide2 === void 0 ? void 0 : _this$styles$slide2.scale;
|
|
230
|
+
slideTranslateX = (_this$styles$slide3 = this.styles.slide) === null || _this$styles$slide3 === void 0 || (_this$styles$slide3 = _this$styles$slide3.transform) === null || _this$styles$slide3 === void 0 || (_this$styles$slide3 = _this$styles$slide3.find(o => !isUndefined(o.translateX))) === null || _this$styles$slide3 === void 0 ? void 0 : _this$styles$slide3.translateX;
|
|
231
|
+
}
|
|
112
232
|
// TODO: loop prop on Carousel is not working Refer: https://github.com/meliorence/react-native-snap-carousel/issues/608
|
|
113
233
|
return /*#__PURE__*/React.createElement(View, {
|
|
114
|
-
style: styles.root
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
ref: ref => this.carouselRef = ref,
|
|
118
|
-
data: data || [],
|
|
119
|
-
firstItem: 0,
|
|
234
|
+
style: styles.root
|
|
235
|
+
}, this._background, /*#__PURE__*/React.createElement(SwipeAnimation.View, {
|
|
236
|
+
enableGestures: props.enablegestures,
|
|
120
237
|
style: {
|
|
121
|
-
|
|
122
|
-
|
|
238
|
+
height: props.type === 'dynamic' ? undefined : '100%'
|
|
239
|
+
},
|
|
240
|
+
direction: "horizontal",
|
|
241
|
+
ref: r => {
|
|
242
|
+
this.animationView = r;
|
|
123
243
|
},
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
244
|
+
handlers: this.animationHandlers,
|
|
245
|
+
slideMinWidth: this.styles.slide.width
|
|
246
|
+
}, data.map((item, index) => {
|
|
247
|
+
var _this$animationView5, _this$animationView6;
|
|
248
|
+
const isActive = index === this.state.activeIndex - 1;
|
|
249
|
+
let scale = (_this$animationView5 = this.animationView) === null || _this$animationView5 === void 0 ? void 0 : _this$animationView5.animationPhase.interpolate({
|
|
250
|
+
inputRange: [-2000, index - 1, index, index + 1, 2000],
|
|
251
|
+
outputRange: [slideScale, slideScale, 1, slideScale, slideScale]
|
|
252
|
+
});
|
|
253
|
+
let translateX = (_this$animationView6 = this.animationView) === null || _this$animationView6 === void 0 ? void 0 : _this$animationView6.animationPhase.interpolate({
|
|
254
|
+
inputRange: [-2000, index - 1, index, index + 1, 2000],
|
|
255
|
+
outputRange: [-56, -56, 0, 56, 56]
|
|
256
|
+
});
|
|
257
|
+
return /*#__PURE__*/React.createElement(Animated.View, {
|
|
258
|
+
key: this.generateItemKey(item, index, props),
|
|
259
|
+
onLayout: this.addSlideLayout.bind(this, index),
|
|
260
|
+
style: [{
|
|
261
|
+
height: props.type === 'dynamic' ? undefined : '100%'
|
|
262
|
+
}, this.styles.slide, index === 0 ? this.styles.firstSlide : null, index === data.length - 1 ? this.styles.lastSlide : null, isActive ? this.styles.activeSlide : null, translateX && scale ? {
|
|
263
|
+
transform: [{
|
|
264
|
+
translateX: !isUndefined(slideTranslateX) ? slideTranslateX : translateX
|
|
265
|
+
}, {
|
|
266
|
+
scale: scale
|
|
267
|
+
}]
|
|
268
|
+
} : null]
|
|
269
|
+
}, /*#__PURE__*/React.createElement(Tappable, {
|
|
270
|
+
onTap: () => {
|
|
271
|
+
var _this$animationView7;
|
|
272
|
+
this.onSlideChange(index + 1);
|
|
273
|
+
const position = this.slidesLayout.filter((l, i) => i < index).reduce((s, l) => s + l.width, 0);
|
|
274
|
+
(_this$animationView7 = this.animationView) === null || _this$animationView7 === void 0 ? void 0 : _this$animationView7.setPosition(-1 * position);
|
|
275
|
+
}
|
|
276
|
+
}, this.renderItem(item, index)));
|
|
277
|
+
})), hasNavs ? /*#__PURE__*/React.createElement(View, {
|
|
135
278
|
style: styles.btnPanel
|
|
136
279
|
}, /*#__PURE__*/React.createElement(WmIcon, {
|
|
280
|
+
id: this.getTestId('prev_icon'),
|
|
137
281
|
iconclass: "wi wi-chevron-left fa-2x",
|
|
138
282
|
styles: styles.prevBtn,
|
|
139
283
|
onTap: this.prev
|
|
140
284
|
}), /*#__PURE__*/React.createElement(WmIcon, {
|
|
285
|
+
id: this.getTestId('next_icon'),
|
|
141
286
|
iconclass: "wi wi-chevron-right fa-2x",
|
|
142
287
|
styles: styles.nextBtn,
|
|
143
288
|
onTap: this.next
|
|
144
|
-
})) : null,
|
|
289
|
+
})) : null, hasDots && data ? this.renderPagination(data) : null);
|
|
145
290
|
}
|
|
146
291
|
}
|
|
147
292
|
//# sourceMappingURL=carousel.component.js.map
|