@wavemaker/app-rn-runtime 11.4.0-next.28152 → 11.4.0-rc.121
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/base-action.js.map +1 -1
- app-rn-runtime/actions/login-action.js.map +1 -1
- app-rn-runtime/actions/logout-action.js.map +1 -1
- app-rn-runtime/actions/navigation-action.js +14 -2
- app-rn-runtime/actions/navigation-action.js.map +1 -1
- app-rn-runtime/actions/notification-action.js.map +1 -1
- app-rn-runtime/actions/timer-action.js.map +1 -1
- app-rn-runtime/components/advanced/carousel/carousel-content/carousel-content.component.js.map +1 -1
- app-rn-runtime/components/advanced/carousel/carousel-content/carousel-content.props.js.map +1 -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.props.js.map +1 -1
- app-rn-runtime/components/advanced/carousel/carousel.component.js +1 -1
- app-rn-runtime/components/advanced/carousel/carousel.component.js.map +1 -1
- app-rn-runtime/components/advanced/carousel/carousel.props.js.map +1 -1
- app-rn-runtime/components/advanced/carousel/carousel.styles.js +16 -0
- app-rn-runtime/components/advanced/carousel/carousel.styles.js.map +1 -1
- app-rn-runtime/components/advanced/login/login.component.js.map +1 -1
- app-rn-runtime/components/advanced/login/login.props.js.map +1 -1
- app-rn-runtime/components/advanced/network-info-toaster/network-info-toaster.component.js.map +1 -1
- app-rn-runtime/components/advanced/network-info-toaster/network-info-toaster.props.js.map +1 -1
- app-rn-runtime/components/advanced/webview/webview.component.js.map +1 -1
- app-rn-runtime/components/advanced/webview/webview.props.js.map +1 -1
- app-rn-runtime/components/basic/anchor/anchor.component.js +1 -0
- app-rn-runtime/components/basic/anchor/anchor.component.js.map +1 -1
- app-rn-runtime/components/basic/anchor/anchor.props.js.map +1 -1
- app-rn-runtime/components/basic/anchor/anchor.styles.js +5 -0
- app-rn-runtime/components/basic/anchor/anchor.styles.js.map +1 -1
- app-rn-runtime/components/basic/animatedview.component.js +1 -3
- app-rn-runtime/components/basic/animatedview.component.js.map +1 -1
- app-rn-runtime/components/basic/audio/audio.component.js +240 -0
- app-rn-runtime/components/basic/audio/audio.component.js.map +1 -0
- app-rn-runtime/components/basic/audio/audio.props.js +15 -0
- app-rn-runtime/components/basic/audio/audio.props.js.map +1 -0
- app-rn-runtime/components/basic/audio/audio.styles.js +61 -0
- app-rn-runtime/components/basic/audio/audio.styles.js.map +1 -0
- app-rn-runtime/components/basic/button/button.component.js.map +1 -1
- app-rn-runtime/components/basic/button/button.props.js.map +1 -1
- app-rn-runtime/components/basic/button/button.styles.js.map +1 -1
- app-rn-runtime/components/basic/buttongroup/buttongroup.component.js.map +1 -1
- app-rn-runtime/components/basic/buttongroup/buttongroup.props.js.map +1 -1
- app-rn-runtime/components/basic/buttongroup/buttongroup.styles.js.map +1 -1
- app-rn-runtime/components/basic/custom/custom.component.js.map +1 -1
- app-rn-runtime/components/basic/custom/custom.props.js.map +1 -1
- app-rn-runtime/components/basic/icon/icon.component.js.map +1 -1
- app-rn-runtime/components/basic/icon/icon.props.js.map +1 -1
- app-rn-runtime/components/basic/icon/icon.styles.js +5 -0
- app-rn-runtime/components/basic/icon/icon.styles.js.map +1 -1
- app-rn-runtime/components/basic/label/label.component.js +2 -1
- app-rn-runtime/components/basic/label/label.component.js.map +1 -1
- app-rn-runtime/components/basic/label/label.props.js.map +1 -1
- app-rn-runtime/components/basic/label/label.styles.js +8 -0
- app-rn-runtime/components/basic/label/label.styles.js.map +1 -1
- app-rn-runtime/components/basic/lottie/lottie.component.js.map +1 -1
- app-rn-runtime/components/basic/lottie/lottie.props.js.map +1 -1
- app-rn-runtime/components/basic/message/message.component.js.map +1 -1
- app-rn-runtime/components/basic/message/message.props.js.map +1 -1
- app-rn-runtime/components/basic/message/message.styles.js +22 -0
- app-rn-runtime/components/basic/message/message.styles.js.map +1 -1
- app-rn-runtime/components/basic/modal/modal.component.js.map +1 -1
- app-rn-runtime/components/basic/modal/modal.props.js.map +1 -1
- app-rn-runtime/components/basic/modal/modal.styles.js.map +1 -1
- app-rn-runtime/components/basic/picture/picture.component.js +7 -11
- app-rn-runtime/components/basic/picture/picture.component.js.map +1 -1
- app-rn-runtime/components/basic/picture/picture.props.js.map +1 -1
- app-rn-runtime/components/basic/picture/picture.styles.js.map +1 -1
- app-rn-runtime/components/basic/progress-bar/progress-bar.component.js.map +1 -1
- app-rn-runtime/components/basic/progress-bar/progress-bar.props.js.map +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.map +1 -1
- app-rn-runtime/components/basic/progress-circle/progress-circle.props.js.map +1 -1
- app-rn-runtime/components/basic/progress-circle/progress-circle.styles.js.map +1 -1
- app-rn-runtime/components/basic/search/local-data-provider.js.map +1 -1
- app-rn-runtime/components/basic/search/search.component.js +1 -1
- app-rn-runtime/components/basic/search/search.component.js.map +1 -1
- app-rn-runtime/components/basic/search/search.props.js +1 -0
- app-rn-runtime/components/basic/search/search.props.js.map +1 -1
- app-rn-runtime/components/basic/search/search.styles.js +47 -0
- app-rn-runtime/components/basic/search/search.styles.js.map +1 -1
- app-rn-runtime/components/basic/skeleton/skeleton.component.js.map +1 -1
- app-rn-runtime/components/basic/spinner/spinner.component.js +3 -1
- app-rn-runtime/components/basic/spinner/spinner.component.js.map +1 -1
- app-rn-runtime/components/basic/spinner/spinner.props.js.map +1 -1
- app-rn-runtime/components/basic/spinner/spinner.styles.js +8 -0
- app-rn-runtime/components/basic/spinner/spinner.styles.js.map +1 -1
- app-rn-runtime/components/basic/video/video.component.js +2 -2
- app-rn-runtime/components/basic/video/video.component.js.map +1 -1
- app-rn-runtime/components/basic/video/video.props.js.map +1 -1
- app-rn-runtime/components/chart/area-chart/area-chart.component.js.map +1 -1
- 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.map +1 -1
- app-rn-runtime/components/chart/basechart.component.js +6 -2
- app-rn-runtime/components/chart/basechart.component.js.map +1 -1
- app-rn-runtime/components/chart/basechart.props.js +1 -0
- app-rn-runtime/components/chart/basechart.props.js.map +1 -1
- app-rn-runtime/components/chart/basechart.styles.js +17 -0
- app-rn-runtime/components/chart/basechart.styles.js.map +1 -1
- app-rn-runtime/components/chart/bubble-chart/bubble-chart.component.js.map +1 -1
- app-rn-runtime/components/chart/column-chart/column-chart.component.js.map +1 -1
- app-rn-runtime/components/chart/donut-chart/donut-chart.component.js.map +1 -1
- app-rn-runtime/components/chart/donut-chart/donut-chart.props.js +0 -1
- app-rn-runtime/components/chart/donut-chart/donut-chart.props.js.map +1 -1
- app-rn-runtime/components/chart/legend/legend.component.js +36 -0
- app-rn-runtime/components/chart/legend/legend.component.js.map +1 -0
- 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.map +1 -1
- app-rn-runtime/components/chart/pie-chart/pie-chart.component.js +119 -40
- 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 -2
- app-rn-runtime/components/chart/pie-chart/pie-chart.props.js.map +1 -1
- app-rn-runtime/components/chart/theme/chart.theme.js.map +1 -1
- app-rn-runtime/components/container/accordion/accordion.component.js +75 -119
- app-rn-runtime/components/container/accordion/accordion.component.js.map +1 -1
- app-rn-runtime/components/container/accordion/accordion.props.js +1 -0
- app-rn-runtime/components/container/accordion/accordion.props.js.map +1 -1
- app-rn-runtime/components/container/accordion/accordion.styles.js +14 -4
- app-rn-runtime/components/container/accordion/accordion.styles.js.map +1 -1
- app-rn-runtime/components/container/accordion/accordionpane/accordionpane.component.js +48 -7
- app-rn-runtime/components/container/accordion/accordionpane/accordionpane.component.js.map +1 -1
- app-rn-runtime/components/container/accordion/accordionpane/accordionpane.props.js.map +1 -1
- app-rn-runtime/components/container/container.component.js.map +1 -1
- app-rn-runtime/components/container/container.props.js.map +1 -1
- app-rn-runtime/components/container/container.styles.js.map +1 -1
- app-rn-runtime/components/container/layoutgrid/gridcolumn/gridcolumn.component.js.map +1 -1
- app-rn-runtime/components/container/layoutgrid/gridcolumn/gridcolumn.props.js.map +1 -1
- app-rn-runtime/components/container/layoutgrid/gridrow/gridrow.component.js.map +1 -1
- app-rn-runtime/components/container/layoutgrid/gridrow/gridrow.props.js.map +1 -1
- app-rn-runtime/components/container/layoutgrid/layoutgrid.component.js.map +1 -1
- app-rn-runtime/components/container/layoutgrid/layoutgrid.props.js.map +1 -1
- app-rn-runtime/components/container/layoutgrid/layoutgrid.styles.js.map +1 -1
- app-rn-runtime/components/container/linearlayout/linearlayout.component.js +1 -0
- app-rn-runtime/components/container/linearlayout/linearlayout.component.js.map +1 -1
- app-rn-runtime/components/container/linearlayout/linearlayout.props.js.map +1 -1
- app-rn-runtime/components/container/linearlayout/linearlayoutitem/linearlayoutitem.component.js +2 -2
- app-rn-runtime/components/container/linearlayout/linearlayoutitem/linearlayoutitem.component.js.map +1 -1
- app-rn-runtime/components/container/linearlayout/linearlayoutitem/linearlayoutitem.props.js.map +1 -1
- app-rn-runtime/components/container/panel/panel-content/panel-content.component.js.map +1 -1
- app-rn-runtime/components/container/panel/panel-content/panel-content.props.js.map +1 -1
- app-rn-runtime/components/container/panel/panel-footer/panel-footer.component.js.map +1 -1
- app-rn-runtime/components/container/panel/panel-footer/panel-footer.props.js.map +1 -1
- app-rn-runtime/components/container/panel/panel.component.js.map +1 -1
- app-rn-runtime/components/container/panel/panel.props.js.map +1 -1
- app-rn-runtime/components/container/panel/panel.styles.js +9 -0
- app-rn-runtime/components/container/panel/panel.styles.js.map +1 -1
- app-rn-runtime/components/container/partial-host.component.js.map +1 -1
- app-rn-runtime/components/container/tabs/tabheader/tabheader.component.js +30 -5
- app-rn-runtime/components/container/tabs/tabheader/tabheader.component.js.map +1 -1
- app-rn-runtime/components/container/tabs/tabheader/tabheader.props.js.map +1 -1
- app-rn-runtime/components/container/tabs/tabheader/tabheader.styles.js +10 -1
- app-rn-runtime/components/container/tabs/tabheader/tabheader.styles.js.map +1 -1
- app-rn-runtime/components/container/tabs/tabpane/tabpane.component.js.map +1 -1
- app-rn-runtime/components/container/tabs/tabpane/tabpane.props.js.map +1 -1
- app-rn-runtime/components/container/tabs/tabs.component.js +5 -2
- app-rn-runtime/components/container/tabs/tabs.component.js.map +1 -1
- app-rn-runtime/components/container/tabs/tabs.props.js.map +1 -1
- app-rn-runtime/components/container/tabs/tabs.styles.js +39 -0
- app-rn-runtime/components/container/tabs/tabs.styles.js.map +1 -1
- app-rn-runtime/components/container/tile/tile.component.js.map +1 -1
- app-rn-runtime/components/container/tile/tile.props.js.map +1 -1
- app-rn-runtime/components/container/tile/tile.styles.js.map +1 -1
- app-rn-runtime/components/container/wizard/wizard.component.js +15 -6
- app-rn-runtime/components/container/wizard/wizard.component.js.map +1 -1
- app-rn-runtime/components/container/wizard/wizard.props.js.map +1 -1
- app-rn-runtime/components/container/wizard/wizard.styles.js +53 -1
- app-rn-runtime/components/container/wizard/wizard.styles.js.map +1 -1
- app-rn-runtime/components/container/wizard/wizardstep/wizardstep.component.js.map +1 -1
- 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.map +1 -1
- app-rn-runtime/components/data/card/card-content/card-content.props.js.map +1 -1
- app-rn-runtime/components/data/card/card-footer/card-footer.component.js.map +1 -1
- app-rn-runtime/components/data/card/card-footer/card-footer.props.js.map +1 -1
- app-rn-runtime/components/data/card/card.component.js.map +1 -1
- app-rn-runtime/components/data/card/card.props.js.map +1 -1
- app-rn-runtime/components/data/card/card.styles.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-action/form-action.props.js +3 -1
- app-rn-runtime/components/data/form/form-action/form-action.props.js.map +1 -1
- app-rn-runtime/components/data/form/form-action/form-action.styles.js.map +1 -1
- app-rn-runtime/components/data/form/form-body/form-body.component.js.map +1 -1
- app-rn-runtime/components/data/form/form-body/form-body.props.js.map +1 -1
- app-rn-runtime/components/data/form/form-field/form-field.component.js +23 -2
- app-rn-runtime/components/data/form/form-field/form-field.component.js.map +1 -1
- app-rn-runtime/components/data/form/form-field/form-field.props.js +8 -0
- app-rn-runtime/components/data/form/form-field/form-field.props.js.map +1 -1
- app-rn-runtime/components/data/form/form-field/form-field.styles.js.map +1 -1
- app-rn-runtime/components/data/form/form-footer/form-footer.component.js.map +1 -1
- app-rn-runtime/components/data/form/form-footer/form-footer.props.js.map +1 -1
- app-rn-runtime/components/data/form/form.component.js +94 -4
- app-rn-runtime/components/data/form/form.component.js.map +1 -1
- app-rn-runtime/components/data/form/form.props.js +2 -0
- app-rn-runtime/components/data/form/form.props.js.map +1 -1
- app-rn-runtime/components/data/form/form.styles.js +6 -0
- app-rn-runtime/components/data/form/form.styles.js.map +1 -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.props.js.map +1 -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 +77 -16
- app-rn-runtime/components/data/list/list.component.js.map +1 -1
- app-rn-runtime/components/data/list/list.props.js +2 -0
- app-rn-runtime/components/data/list/list.props.js.map +1 -1
- app-rn-runtime/components/data/list/list.styles.js.map +1 -1
- app-rn-runtime/components/data/liveform/liveform.component.js +102 -0
- app-rn-runtime/components/data/liveform/liveform.component.js.map +1 -0
- app-rn-runtime/components/device/barcodescanner/barcodescanner.component.js.map +1 -1
- app-rn-runtime/components/device/barcodescanner/barcodescanner.props.js.map +1 -1
- app-rn-runtime/components/device/camera/camera.component.js.map +1 -1
- app-rn-runtime/components/device/camera/camera.props.js.map +1 -1
- app-rn-runtime/components/dialogs/alertdialog/alertdialog.component.js.map +1 -1
- app-rn-runtime/components/dialogs/alertdialog/alertdialog.props.js.map +1 -1
- app-rn-runtime/components/dialogs/alertdialog/alertdialog.styles.js.map +1 -1
- app-rn-runtime/components/dialogs/confirmdialog/confirmdialog.component.js.map +1 -1
- app-rn-runtime/components/dialogs/confirmdialog/confirmdialog.props.js.map +1 -1
- app-rn-runtime/components/dialogs/confirmdialog/confirmdialog.styles.js +9 -0
- app-rn-runtime/components/dialogs/confirmdialog/confirmdialog.styles.js.map +1 -1
- app-rn-runtime/components/dialogs/dialog/dialog.component.js +5 -2
- app-rn-runtime/components/dialogs/dialog/dialog.component.js.map +1 -1
- app-rn-runtime/components/dialogs/dialog/dialog.props.js.map +1 -1
- app-rn-runtime/components/dialogs/dialogactions/dialogactions.component.js.map +1 -1
- app-rn-runtime/components/dialogs/dialogactions/dialogactions.props.js.map +1 -1
- app-rn-runtime/components/dialogs/dialogcontent/dialogcontent.component.js.map +1 -1
- app-rn-runtime/components/dialogs/dialogcontent/dialogcontent.props.js.map +1 -1
- app-rn-runtime/components/input/basedataset/basedataset.component.js.map +1 -1
- app-rn-runtime/components/input/basedataset/basedataset.props.js.map +1 -1
- app-rn-runtime/components/input/baseinput/baseinput.component.js +4 -4
- app-rn-runtime/components/input/baseinput/baseinput.component.js.map +1 -1
- app-rn-runtime/components/input/baseinput/baseinput.props.js.map +1 -1
- app-rn-runtime/components/input/basenumber/basenumber.component.js +1 -1
- app-rn-runtime/components/input/basenumber/basenumber.component.js.map +1 -1
- app-rn-runtime/components/input/basenumber/basenumber.props.js.map +1 -1
- app-rn-runtime/components/input/calendar/calendar.component.js.map +1 -1
- app-rn-runtime/components/input/calendar/calendar.props.js.map +1 -1
- app-rn-runtime/components/input/calendar/calendar.styles.js +22 -0
- app-rn-runtime/components/input/calendar/calendar.styles.js.map +1 -1
- app-rn-runtime/components/input/calendar/views/month-view.js +1 -0
- app-rn-runtime/components/input/calendar/views/month-view.js.map +1 -1
- app-rn-runtime/components/input/checkbox/checkbox.component.js.map +1 -1
- app-rn-runtime/components/input/checkbox/checkbox.props.js +1 -1
- app-rn-runtime/components/input/checkbox/checkbox.props.js.map +1 -1
- app-rn-runtime/components/input/checkbox/checkbox.styles.js.map +1 -1
- app-rn-runtime/components/input/checkboxset/checkboxset.component.js.map +1 -1
- app-rn-runtime/components/input/checkboxset/checkboxset.props.js.map +1 -1
- app-rn-runtime/components/input/checkboxset/checkboxset.styles.js.map +1 -1
- app-rn-runtime/components/input/chips/chips.component.js +1 -0
- app-rn-runtime/components/input/chips/chips.component.js.map +1 -1
- app-rn-runtime/components/input/chips/chips.props.js.map +1 -1
- app-rn-runtime/components/input/composite/composite.component.js.map +1 -1
- app-rn-runtime/components/input/composite/composite.props.js.map +1 -1
- app-rn-runtime/components/input/currency/currency.component.js +6 -4
- app-rn-runtime/components/input/currency/currency.component.js.map +1 -1
- app-rn-runtime/components/input/currency/currency.props.js +1 -1
- app-rn-runtime/components/input/currency/currency.props.js.map +1 -1
- app-rn-runtime/components/input/currency/currency.styles.js +9 -0
- app-rn-runtime/components/input/currency/currency.styles.js.map +1 -1
- app-rn-runtime/components/input/epoch/base-datetime.component.js +5 -2
- app-rn-runtime/components/input/epoch/base-datetime.component.js.map +1 -1
- app-rn-runtime/components/input/epoch/date/date.component.js.map +1 -1
- app-rn-runtime/components/input/epoch/date/date.props.js.map +1 -1
- app-rn-runtime/components/input/epoch/date/date.styles.js +9 -0
- app-rn-runtime/components/input/epoch/date/date.styles.js.map +1 -1
- app-rn-runtime/components/input/epoch/date-picker.component.js.map +1 -1
- app-rn-runtime/components/input/epoch/datetime/datetime.component.js.map +1 -1
- app-rn-runtime/components/input/epoch/datetime/datetime.props.js.map +1 -1
- app-rn-runtime/components/input/epoch/datetime/datetime.styles.js +9 -0
- app-rn-runtime/components/input/epoch/datetime/datetime.styles.js.map +1 -1
- app-rn-runtime/components/input/epoch/time/time.component.js.map +1 -1
- app-rn-runtime/components/input/epoch/time/time.props.js.map +1 -1
- app-rn-runtime/components/input/epoch/time/time.styles.js +9 -0
- app-rn-runtime/components/input/epoch/time/time.styles.js.map +1 -1
- app-rn-runtime/components/input/fileupload/fileupload.component.js.map +1 -1
- app-rn-runtime/components/input/fileupload/fileupload.props.js.map +1 -1
- app-rn-runtime/components/input/number/number.component.js +6 -4
- app-rn-runtime/components/input/number/number.component.js.map +1 -1
- app-rn-runtime/components/input/number/number.props.js +1 -1
- app-rn-runtime/components/input/number/number.props.js.map +1 -1
- app-rn-runtime/components/input/number/number.styles.js +5 -0
- app-rn-runtime/components/input/number/number.styles.js.map +1 -1
- app-rn-runtime/components/input/radioset/radioset.component.js +3 -1
- app-rn-runtime/components/input/radioset/radioset.component.js.map +1 -1
- app-rn-runtime/components/input/radioset/radioset.props.js.map +1 -1
- app-rn-runtime/components/input/radioset/radioset.styles.js +8 -0
- app-rn-runtime/components/input/radioset/radioset.styles.js.map +1 -1
- app-rn-runtime/components/input/rating/rating.component.js +1 -1
- app-rn-runtime/components/input/rating/rating.component.js.map +1 -1
- app-rn-runtime/components/input/rating/rating.props.js.map +1 -1
- app-rn-runtime/components/input/select/select.component.js +14 -2
- app-rn-runtime/components/input/select/select.component.js.map +1 -1
- app-rn-runtime/components/input/select/select.props.js.map +1 -1
- app-rn-runtime/components/input/select/select.styles.js +18 -1
- app-rn-runtime/components/input/select/select.styles.js.map +1 -1
- app-rn-runtime/components/input/slider/slider.component.js +2 -1
- app-rn-runtime/components/input/slider/slider.component.js.map +1 -1
- app-rn-runtime/components/input/slider/slider.props.js.map +1 -1
- app-rn-runtime/components/input/switch/switch.component.js.map +1 -1
- app-rn-runtime/components/input/switch/switch.props.js.map +1 -1
- app-rn-runtime/components/input/switch/switch.styles.js +36 -0
- app-rn-runtime/components/input/switch/switch.styles.js.map +1 -1
- app-rn-runtime/components/input/text/text.component.js +5 -3
- app-rn-runtime/components/input/text/text.component.js.map +1 -1
- app-rn-runtime/components/input/text/text.props.js.map +1 -1
- app-rn-runtime/components/input/text/text.styles.js +5 -0
- app-rn-runtime/components/input/text/text.styles.js.map +1 -1
- app-rn-runtime/components/input/textarea/textarea.component.js +5 -3
- app-rn-runtime/components/input/textarea/textarea.component.js.map +1 -1
- app-rn-runtime/components/input/textarea/textarea.props.js.map +1 -1
- app-rn-runtime/components/input/textarea/textarea.styles.js +5 -0
- app-rn-runtime/components/input/textarea/textarea.styles.js.map +1 -1
- app-rn-runtime/components/input/toggle/toggle.component.js +17 -11
- app-rn-runtime/components/input/toggle/toggle.component.js.map +1 -1
- app-rn-runtime/components/input/toggle/toggle.props.js.map +1 -1
- app-rn-runtime/components/input/toggle/toggle.styles.js +28 -3
- app-rn-runtime/components/input/toggle/toggle.styles.js.map +1 -1
- app-rn-runtime/components/navigation/appnavbar/appnavbar.component.js.map +1 -1
- app-rn-runtime/components/navigation/appnavbar/appnavbar.props.js.map +1 -1
- app-rn-runtime/components/navigation/appnavbar/appnavbar.styles.js.map +1 -1
- app-rn-runtime/components/navigation/basenav/basenav.component.js.map +1 -1
- app-rn-runtime/components/navigation/basenav/basenav.props.js.map +1 -1
- app-rn-runtime/components/navigation/menu/menu.component.js.map +1 -1
- app-rn-runtime/components/navigation/menu/menu.props.js.map +1 -1
- app-rn-runtime/components/navigation/menu/menu.styles.js +6 -0
- app-rn-runtime/components/navigation/menu/menu.styles.js.map +1 -1
- app-rn-runtime/components/navigation/navbar/navbar.component.js.map +1 -1
- app-rn-runtime/components/navigation/navbar/navbar.props.js.map +1 -1
- app-rn-runtime/components/navigation/navbar/navbar.styles.js.map +1 -1
- app-rn-runtime/components/navigation/navitem/navitem.component.js.map +1 -1
- app-rn-runtime/components/navigation/navitem/navitem.props.js.map +1 -1
- app-rn-runtime/components/navigation/navitem/navitem.styles.js.map +1 -1
- 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.map +1 -1
- app-rn-runtime/components/page/content/content.component.js.map +1 -1
- app-rn-runtime/components/page/left-panel/left-panel.component.js.map +1 -1
- app-rn-runtime/components/page/left-panel/left-panel.props.js.map +1 -1
- app-rn-runtime/components/page/page-content/page-content.component.js.map +1 -1
- app-rn-runtime/components/page/page-content/page-content.props.js.map +1 -1
- app-rn-runtime/components/page/page.component.js.map +1 -1
- app-rn-runtime/components/page/partial/partial.component.js.map +1 -1
- app-rn-runtime/components/page/partial-container/partial-container.component.js.map +1 -1
- app-rn-runtime/components/page/partial-container/partial-container.props.js.map +1 -1
- app-rn-runtime/components/page/tabbar/tabbar.component.js.map +1 -1
- app-rn-runtime/components/page/tabbar/tabbar.props.js.map +1 -1
- app-rn-runtime/components/prefab/prefab-container.component.js.map +1 -1
- app-rn-runtime/core/asset.provider.js.map +1 -1
- app-rn-runtime/core/base.component.js +29 -17
- app-rn-runtime/core/base.component.js.map +1 -1
- app-rn-runtime/core/components/textinput.component.js +37 -0
- app-rn-runtime/core/components/textinput.component.js.map +1 -0
- app-rn-runtime/core/device/camera-service.js.map +1 -1
- app-rn-runtime/core/device/scan-service.js.map +1 -1
- app-rn-runtime/core/display.manager.js.map +1 -1
- app-rn-runtime/core/event-notifier.js.map +1 -1
- app-rn-runtime/core/fixed-view.component.js.map +1 -1
- app-rn-runtime/core/formatters.js.map +1 -1
- app-rn-runtime/core/i18n.service.js +2 -0
- app-rn-runtime/core/i18n.service.js.map +1 -0
- app-rn-runtime/core/if.component.js +3 -3
- app-rn-runtime/core/if.component.js.map +1 -1
- app-rn-runtime/core/imageSizeEstimator.js.map +1 -1
- app-rn-runtime/core/injector.js +2 -1
- app-rn-runtime/core/injector.js.map +1 -1
- app-rn-runtime/core/logger.js +4 -1
- app-rn-runtime/core/logger.js.map +1 -1
- app-rn-runtime/core/modal.service.js.map +1 -1
- app-rn-runtime/core/navigation.service.js.map +1 -1
- app-rn-runtime/core/network.service.js +17 -15
- app-rn-runtime/core/network.service.js.map +1 -1
- app-rn-runtime/core/partial.service.js.map +1 -1
- app-rn-runtime/core/props.provider.js +1 -1
- app-rn-runtime/core/props.provider.js.map +1 -1
- app-rn-runtime/core/scroll-view.component.js.map +1 -1
- app-rn-runtime/core/security.service.js.map +1 -1
- app-rn-runtime/core/spinner.service.js.map +1 -1
- app-rn-runtime/core/storage.service.js.map +1 -1
- app-rn-runtime/core/tappable.component.js +11 -2
- app-rn-runtime/core/tappable.component.js.map +1 -1
- app-rn-runtime/core/toast.service.js.map +1 -1
- app-rn-runtime/core/utils.js +22 -0
- app-rn-runtime/core/utils.js.map +1 -1
- app-rn-runtime/core/viewport.js.map +1 -1
- app-rn-runtime/gestures/swipe.animation.js +9 -4
- app-rn-runtime/gestures/swipe.animation.js.map +1 -1
- app-rn-runtime/package.json +42 -42
- app-rn-runtime/runtime/App.js +14 -6
- app-rn-runtime/runtime/App.js.map +1 -1
- app-rn-runtime/runtime/App.navigator.js +11 -2
- app-rn-runtime/runtime/App.navigator.js.map +1 -1
- app-rn-runtime/runtime/base-fragment.component.js +20 -7
- app-rn-runtime/runtime/base-fragment.component.js.map +1 -1
- app-rn-runtime/runtime/base-page.component.js +2 -0
- app-rn-runtime/runtime/base-page.component.js.map +1 -1
- app-rn-runtime/runtime/base-partial.component.js.map +1 -1
- app-rn-runtime/runtime/base-prefab.component.js +5 -7
- app-rn-runtime/runtime/base-prefab.component.js.map +1 -1
- app-rn-runtime/runtime/lib-patch.js.map +1 -1
- app-rn-runtime/runtime/memo.component.js.map +1 -1
- app-rn-runtime/runtime/navigator/drawer.navigator.js.map +1 -1
- app-rn-runtime/runtime/navigator/stack.navigator.js.map +1 -1
- app-rn-runtime/runtime/services/app-display-manager.service.js.map +1 -1
- app-rn-runtime/runtime/services/app-i18n.service.js +26 -3
- app-rn-runtime/runtime/services/app-i18n.service.js.map +1 -1
- app-rn-runtime/runtime/services/app-modal.service.js.map +1 -1
- app-rn-runtime/runtime/services/app-security.service.js +7 -7
- app-rn-runtime/runtime/services/app-security.service.js.map +1 -1
- app-rn-runtime/runtime/services/app-spinner.service.js +3 -2
- app-rn-runtime/runtime/services/app-spinner.service.js.map +1 -1
- app-rn-runtime/runtime/services/app-toast.service.js.map +1 -1
- app-rn-runtime/runtime/services/device/calendar-service.js.map +1 -1
- app-rn-runtime/runtime/services/device/camera-service.js +2 -3
- app-rn-runtime/runtime/services/device/camera-service.js.map +1 -1
- app-rn-runtime/runtime/services/device/contacts-service.js.map +1 -1
- app-rn-runtime/runtime/services/device/location-service.js.map +1 -1
- app-rn-runtime/runtime/services/device/permissions.js.map +1 -1
- app-rn-runtime/runtime/services/device/scan-service.js.map +1 -1
- app-rn-runtime/runtime/services/partial.service.js.map +1 -1
- app-rn-runtime/runtime/services/webprocess.service.js.map +1 -1
- app-rn-runtime/runtime/watcher.js +3 -1
- app-rn-runtime/runtime/watcher.js.map +1 -1
- app-rn-runtime/styles/MediaQueryList.js.map +1 -1
- app-rn-runtime/styles/background.component.js +51 -12
- app-rn-runtime/styles/background.component.js.map +1 -1
- app-rn-runtime/styles/style-prop.validator.js +4 -0
- app-rn-runtime/styles/style-prop.validator.js.map +1 -1
- app-rn-runtime/styles/style-props.js.map +1 -1
- app-rn-runtime/styles/theme.js +12 -5
- app-rn-runtime/styles/theme.js.map +1 -1
- app-rn-runtime/styles/theme.variables.js +58 -2
- app-rn-runtime/styles/theme.variables.js.map +1 -1
- app-rn-runtime/variables/base-variable.js +3 -3
- app-rn-runtime/variables/base-variable.js.map +1 -1
- app-rn-runtime/variables/device/calendar/create-event.operation.js.map +1 -1
- app-rn-runtime/variables/device/calendar/delete-event.operation.js.map +1 -1
- app-rn-runtime/variables/device/calendar/get-events.operation.js.map +1 -1
- app-rn-runtime/variables/device/camera/capture-image.operation.js.map +1 -1
- app-rn-runtime/variables/device/camera/capture-video.operation.js.map +1 -1
- app-rn-runtime/variables/device/contacts/get-contacts.operation.js.map +1 -1
- app-rn-runtime/variables/device/device/app-info.operation.js.map +1 -1
- app-rn-runtime/variables/device/device/current-geo-position.operation.js.map +1 -1
- app-rn-runtime/variables/device/device/device-info.operation.js.map +1 -1
- app-rn-runtime/variables/device/device/network-info.operation.js.map +1 -1
- app-rn-runtime/variables/device/device/vibrate.operation.js.map +1 -1
- app-rn-runtime/variables/device/file/upload-file.operation.js.map +1 -1
- app-rn-runtime/variables/device/operation.provider.js.map +1 -1
- app-rn-runtime/variables/device/scan/scan.operation.js.map +1 -1
- app-rn-runtime/variables/device-variable.js.map +1 -1
- app-rn-runtime/variables/http.service.js +7 -3
- app-rn-runtime/variables/http.service.js.map +1 -1
- app-rn-runtime/variables/live-variable.js +115 -0
- app-rn-runtime/variables/live-variable.js.map +1 -0
- app-rn-runtime/variables/model-variable.js.map +1 -1
- app-rn-runtime/variables/service-variable.js +14 -4
- app-rn-runtime/variables/service-variable.js.map +1 -1
- app-rn-runtime/variables/utils/dataset-util.js.map +1 -1
- app-rn-runtime/variables/utils/inflight-queue.js.map +1 -1
- app-rn-runtime/variables/utils/variable.utils.js.map +1 -1
|
@@ -2,40 +2,48 @@ 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 { Badge
|
|
5
|
+
import { Text, TouchableOpacity, View } from 'react-native';
|
|
6
|
+
import { Badge } from 'react-native-paper';
|
|
7
7
|
import { isArray } from 'lodash';
|
|
8
8
|
import { BaseComponent, BaseComponentState } from '@wavemaker/app-rn-runtime/core/base.component';
|
|
9
|
-
import { isDefined } from '@wavemaker/app-rn-runtime/core/utils';
|
|
10
9
|
import WmAccordionProps from './accordion.props';
|
|
11
10
|
import { DEFAULT_CLASS } from './accordion.styles';
|
|
12
11
|
import WmIcon from '@wavemaker/app-rn-runtime/components/basic/icon/icon.component';
|
|
13
|
-
import {
|
|
14
|
-
import { createSkeleton } from '../../basic/skeleton/skeleton.component';
|
|
12
|
+
import { isDefined } from '@wavemaker/app-rn-runtime/core/utils';
|
|
15
13
|
export class WmAccordionState extends BaseComponentState {
|
|
16
14
|
constructor() {
|
|
17
15
|
super(...arguments);
|
|
18
|
-
_defineProperty(this, "
|
|
16
|
+
_defineProperty(this, "lastExpandedIndex", -1);
|
|
17
|
+
_defineProperty(this, "isExpanded", []);
|
|
19
18
|
}
|
|
20
19
|
}
|
|
21
20
|
export default class WmAccordion extends BaseComponent {
|
|
22
21
|
constructor(props) {
|
|
23
|
-
super(props, DEFAULT_CLASS, new WmAccordionProps());
|
|
24
|
-
_defineProperty(this, "animatedRef", void 0);
|
|
22
|
+
super(props, DEFAULT_CLASS, new WmAccordionProps(), new WmAccordionState());
|
|
25
23
|
_defineProperty(this, "accordionPanes", []);
|
|
26
24
|
_defineProperty(this, "newIndex", 0);
|
|
27
|
-
this.updateState({
|
|
28
|
-
expandedId: (this.state.props.defaultpaneindex || 0) + 1
|
|
29
|
-
});
|
|
30
25
|
}
|
|
31
26
|
addAccordionPane(accordionPane) {
|
|
32
|
-
this.accordionPanes
|
|
27
|
+
const i = this.accordionPanes.findIndex(t => t.props.name === accordionPane.props.name);
|
|
28
|
+
if (i >= 0) {
|
|
29
|
+
this.accordionPanes[i] = accordionPane;
|
|
30
|
+
} else {
|
|
31
|
+
this.accordionPanes[this.newIndex++] = accordionPane;
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
expand(accordionName) {
|
|
35
|
+
const i = this.accordionPanes.findIndex(t => t.props.name === accordionName);
|
|
36
|
+
this.toggle(i + 1, true);
|
|
37
|
+
}
|
|
38
|
+
collapse(accordionName) {
|
|
39
|
+
const i = this.accordionPanes.findIndex(t => t.props.name === accordionName);
|
|
40
|
+
this.toggle(i + 1, false);
|
|
33
41
|
}
|
|
34
|
-
expandCollapseIcon(
|
|
35
|
-
let showBadge = arguments.length >
|
|
36
|
-
let showIcon = arguments.length >
|
|
37
|
-
let useChevron = arguments.length >
|
|
38
|
-
let isExpanded = arguments.length >
|
|
42
|
+
expandCollapseIcon(item) {
|
|
43
|
+
let showBadge = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : true;
|
|
44
|
+
let showIcon = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : true;
|
|
45
|
+
let useChevron = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : true;
|
|
46
|
+
let isExpanded = arguments.length > 4 && arguments[4] !== undefined ? arguments[4] : false;
|
|
39
47
|
const widgetProps = item.props;
|
|
40
48
|
//@ts-ignore
|
|
41
49
|
const badge = showBadge && widgetProps.badgevalue != undefined ? /*#__PURE__*/React.createElement(Badge, {
|
|
@@ -58,125 +66,73 @@ export default class WmAccordion extends BaseComponent {
|
|
|
58
66
|
}) : null);
|
|
59
67
|
}
|
|
60
68
|
renderAccordionpane(item, index) {
|
|
61
|
-
let
|
|
62
|
-
let accordionpanes = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : [];
|
|
69
|
+
let accordionpanes = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : [];
|
|
63
70
|
const showIconOnLeft = this.styles.leftToggleIcon.root.width !== undefined;
|
|
71
|
+
const isExpanded = this.state.isExpanded[index];
|
|
64
72
|
return /*#__PURE__*/React.createElement(View, {
|
|
65
73
|
style: this.styles.pane,
|
|
66
74
|
key: item.props.name
|
|
67
|
-
}, /*#__PURE__*/React.createElement(
|
|
68
|
-
|
|
75
|
+
}, /*#__PURE__*/React.createElement(TouchableOpacity, {
|
|
76
|
+
key: 'accordionpane_' + (index + 1),
|
|
69
77
|
style: [this.styles.header, index === 0 ? this.styles.firstHeader : null, index === accordionpanes.length - 1 && !isExpanded ? this.styles.lastHeader : null, isExpanded ? this.styles.activeHeader : {}],
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
titleStyle: [this.styles.text, isExpanded ? this.styles.activeHeaderTitle : {}],
|
|
77
|
-
descriptionStyle: this.styles.subheading,
|
|
78
|
-
description: item.props.subheading,
|
|
79
|
-
id: index + 1,
|
|
80
|
-
key: 'accordionpane_' + index,
|
|
81
|
-
right: props => this.expandCollapseIcon(props, item, true, !showIconOnLeft, true, isExpanded),
|
|
82
|
-
left: props => /*#__PURE__*/React.createElement(React.Fragment, null, this.expandCollapseIcon(props, item, false, showIconOnLeft, true, isExpanded), item.props.iconclass ? /*#__PURE__*/React.createElement(WmIcon, {
|
|
83
|
-
styles: this.styles.icon,
|
|
84
|
-
name: item.props.name + '_icon',
|
|
85
|
-
iconclass: item.props.iconclass
|
|
86
|
-
}) : null)
|
|
87
|
-
}, /*#__PURE__*/React.createElement(Animatedview, {
|
|
78
|
+
onPress: this.toggle.bind(this, index + 1, !isExpanded)
|
|
79
|
+
}, this.expandCollapseIcon(item, false, showIconOnLeft, true, isExpanded), item.props.iconclass ? /*#__PURE__*/React.createElement(WmIcon, {
|
|
80
|
+
styles: this.styles.icon,
|
|
81
|
+
name: item.props.name + '_icon',
|
|
82
|
+
iconclass: item.props.iconclass
|
|
83
|
+
}) : null, /*#__PURE__*/React.createElement(View, {
|
|
88
84
|
style: {
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
},
|
|
85
|
+
flexDirection: 'column',
|
|
86
|
+
flex: 1,
|
|
87
|
+
justifyContent: 'center'
|
|
88
|
+
}
|
|
89
|
+
}, /*#__PURE__*/React.createElement(Text, {
|
|
90
|
+
style: [this.styles.text, this.styles.heading, isExpanded ? this.styles.activeHeaderTitle : {}]
|
|
91
|
+
}, isDefined(item.props.title) ? item.props.title : 'Title'), item.props.description ? /*#__PURE__*/React.createElement(Text, {
|
|
92
|
+
style: this.styles.subheading
|
|
93
|
+
}, item.props.description) : null), this.expandCollapseIcon(item, true, !showIconOnLeft, true, isExpanded)), item);
|
|
94
94
|
}
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
95
|
+
toggle(index) {
|
|
96
|
+
let expand = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : true;
|
|
97
|
+
let expandedId = expand ? index : -1;
|
|
98
|
+
let collapseId = expand ? -1 : index;
|
|
99
|
+
if (expand && this.state.isExpanded[expandedId - 1] || !expand && this.state.isExpanded[collapseId - 1] === false) {
|
|
100
|
+
return;
|
|
101
|
+
}
|
|
102
|
+
if (collapseId < 0 && this.state.props.closeothers) {
|
|
103
|
+
collapseId = this.state.lastExpandedIndex;
|
|
104
|
+
}
|
|
105
|
+
const collapsedPane = this.accordionPanes[collapseId - 1];
|
|
106
|
+
collapsedPane === null || collapsedPane === void 0 ? void 0 : collapsedPane.hide();
|
|
100
107
|
Promise.resolve().then(() => {
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
108
|
+
const expandedPane = expandedId ? this.accordionPanes[expandedId - 1] : null;
|
|
109
|
+
expandedPane === null || expandedPane === void 0 ? void 0 : expandedPane.show();
|
|
110
|
+
this.setState(state => {
|
|
111
|
+
if (collapseId > 0 && collapsedPane) {
|
|
112
|
+
state.isExpanded[collapseId - 1] = false;
|
|
113
|
+
}
|
|
114
|
+
if (expandedId > 0 && expandedPane) {
|
|
115
|
+
state.isExpanded[expandedId - 1] = true;
|
|
116
|
+
}
|
|
117
|
+
return {
|
|
118
|
+
lastExpandedIndex: expandedId,
|
|
119
|
+
isExpanded: [...state.isExpanded]
|
|
120
|
+
};
|
|
110
121
|
}, () => {
|
|
111
|
-
|
|
112
|
-
expandedPane === null || expandedPane === void 0 ? void 0 : expandedPane.onPaneExpand();
|
|
113
|
-
this.invokeEventCallback('onChange', [{}, this.proxy, expandedId - 1, oldIndex ? oldIndex - 1 : null, expandedPane && expandedPane.props.name, collapsedPane && collapsedPane.props.name]);
|
|
122
|
+
this.invokeEventCallback('onChange', [{}, this.proxy, expandedId - 1, collapseId ? collapseId - 1 : null, expandedPane && expandedPane.props.name, collapsedPane && collapsedPane.props.name]);
|
|
114
123
|
});
|
|
115
124
|
}, () => {});
|
|
116
125
|
}
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
const showIconOnLeft = this.styles.leftToggleIcon.root.width !== undefined;
|
|
121
|
-
return /*#__PURE__*/React.createElement(View, {
|
|
122
|
-
style: this.styles.pane,
|
|
123
|
-
key: item.props.name
|
|
124
|
-
}, /*#__PURE__*/React.createElement(List.Accordion, {
|
|
125
|
-
title: '',
|
|
126
|
-
style: [{}],
|
|
127
|
-
theme: {},
|
|
128
|
-
titleStyle: [{}],
|
|
129
|
-
descriptionStyle: this.styles.subheading,
|
|
130
|
-
description: item.props.subheading,
|
|
131
|
-
id: index + 1,
|
|
132
|
-
key: 'accordionpane_' + index,
|
|
133
|
-
right: props => this.expandCollapseIcon(props, item, true, !showIconOnLeft, true, isExpanded),
|
|
134
|
-
left: props => {
|
|
135
|
-
var _this$styles$root, _this$styles$root2, _this$styles$activeHe;
|
|
136
|
-
return /*#__PURE__*/React.createElement(React.Fragment, null, createSkeleton(this.theme, {
|
|
137
|
-
root: {
|
|
138
|
-
borderRadius: 4
|
|
139
|
-
}
|
|
140
|
-
}, {
|
|
141
|
-
...this.styles.root,
|
|
142
|
-
width: ((_this$styles$root = this.styles.root) === null || _this$styles$root === void 0 ? void 0 : _this$styles$root.width) || "100%",
|
|
143
|
-
height: ((_this$styles$root2 = this.styles.root) === null || _this$styles$root2 === void 0 ? void 0 : _this$styles$root2.height) || ((_this$styles$activeHe = this.styles.activeHeaderTitle) === null || _this$styles$activeHe === void 0 ? void 0 : _this$styles$activeHe.fontSize) || 16
|
|
144
|
-
}), this.expandCollapseIcon(props, item, false, showIconOnLeft, true, isExpanded), item.props.iconclass ? /*#__PURE__*/React.createElement(WmIcon, {
|
|
145
|
-
styles: this.styles.icon,
|
|
146
|
-
name: item.props.name + '_icon',
|
|
147
|
-
iconclass: item.props.iconclass
|
|
148
|
-
}) : null);
|
|
149
|
-
}
|
|
150
|
-
}, /*#__PURE__*/React.createElement(Animatedview, {
|
|
151
|
-
style: {
|
|
152
|
-
marginLeft: -64
|
|
153
|
-
},
|
|
154
|
-
ref: ref => this.animatedRef = ref,
|
|
155
|
-
entryanimation: this.state.props.animation
|
|
156
|
-
}, item)));
|
|
157
|
-
}
|
|
158
|
-
AccordionSkeleton() {
|
|
159
|
-
const accordionpanes = this.props.children;
|
|
160
|
-
const expandedId = this.state.expandedId || 0;
|
|
161
|
-
return /*#__PURE__*/React.createElement(View, {
|
|
162
|
-
style: this.styles.root
|
|
163
|
-
}, /*#__PURE__*/React.createElement(List.AccordionGroup, {
|
|
164
|
-
expandedId: expandedId,
|
|
165
|
-
onAccordionPress: this.onAccordionPress.bind(this)
|
|
166
|
-
}, accordionpanes ? isArray(accordionpanes) && accordionpanes.length ? accordionpanes.map((item, index) => this.renderSkeletonAccordionpane(item, index, false, accordionpanes)) : this.renderSkeletonAccordionpane(accordionpanes, 0) : null));
|
|
167
|
-
}
|
|
168
|
-
renderSkeleton(props) {
|
|
169
|
-
return this.AccordionSkeleton();
|
|
126
|
+
componentDidMount() {
|
|
127
|
+
super.componentDidMount();
|
|
128
|
+
this.toggle(this.state.props.defaultpaneindex + 1);
|
|
170
129
|
}
|
|
171
130
|
renderWidget(props) {
|
|
172
131
|
const accordionpanes = props.children;
|
|
173
|
-
const expandedId = this.state.
|
|
132
|
+
const expandedId = this.state.lastExpandedIndex || 0;
|
|
174
133
|
return /*#__PURE__*/React.createElement(View, {
|
|
175
134
|
style: this.styles.root
|
|
176
|
-
}, this._background,
|
|
177
|
-
expandedId: expandedId,
|
|
178
|
-
onAccordionPress: this.onAccordionPress.bind(this)
|
|
179
|
-
}, accordionpanes ? isArray(accordionpanes) && accordionpanes.length ? accordionpanes.map((item, index) => this.renderAccordionpane(item, index, expandedId === index + 1, accordionpanes)) : this.renderAccordionpane(accordionpanes, 0) : null));
|
|
135
|
+
}, this._background, accordionpanes ? isArray(accordionpanes) && accordionpanes.length ? accordionpanes.map((item, index) => this.renderAccordionpane(item, index, accordionpanes)) : this.renderAccordionpane(accordionpanes, 0) : null);
|
|
180
136
|
}
|
|
181
137
|
}
|
|
182
138
|
//# sourceMappingURL=accordion.component.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["React","View","Badge","List","isArray","BaseComponent","BaseComponentState","isDefined","WmAccordionProps","DEFAULT_CLASS","WmIcon","Animatedview","createSkeleton","WmAccordionState","WmAccordion","constructor","props","updateState","expandedId","state","defaultpaneindex","addAccordionPane","accordionPane","accordionPanes","newIndex","expandCollapseIcon","item","showBadge","showIcon","useChevron","isExpanded","widgetProps","badge","badgevalue","undefined","styles","activeBadge","badgetype","iconclass","flexDirection","theme","mergeStyle","icon","activeIcon","renderAccordionpane","index","accordionpanes","showIconOnLeft","leftToggleIcon","root","width","pane","name","title","header","firstHeader","length","lastHeader","activeHeader","colors","background","backgroundColor","primary","color","text","activeHeaderTitle","subheading","marginLeft","ref","animatedRef","animation","onAccordionPress","oldIndex","collapsedPane","onPaneCollapse","Promise","resolve","then","triggerExit","res","reject","expandedPane","onPaneExpand","invokeEventCallback","proxy","renderSkeletonAccordionpane","borderRadius","height","fontSize","AccordionSkeleton","children","bind","map","renderSkeleton","renderWidget","_background"],"sources":["accordion.component.tsx"],"sourcesContent":["import React, { useState } from 'react';\nimport { Text, View } from 'react-native';\nimport { Badge, List } from 'react-native-paper';\nimport { isArray } from 'lodash';\nimport { BaseComponent, BaseComponentState } from '@wavemaker/app-rn-runtime/core/base.component';\nimport { isDefined } from '@wavemaker/app-rn-runtime/core/utils';\n\nimport WmAccordionProps from './accordion.props';\nimport { DEFAULT_CLASS, WmAccordionStyles } from './accordion.styles';\nimport WmIcon from '@wavemaker/app-rn-runtime/components/basic/icon/icon.component';\nimport { Animatedview } from '@wavemaker/app-rn-runtime/components/basic/animatedview.component';\nimport WmAccordionpane from './accordionpane/accordionpane.component';\nimport WmSkeleton, { createSkeleton } from '../../basic/skeleton/skeleton.component';\nimport { WmSkeletonStyles } from '../../basic/skeleton/skeleton.styles';\n\nexport class WmAccordionState extends BaseComponentState<WmAccordionProps> {\n expandedId: any;\n}\n\nexport default class WmAccordion extends BaseComponent<WmAccordionProps, WmAccordionState, WmAccordionStyles> {\n private animatedRef: any;\n public accordionPanes = [] as WmAccordionpane[];\n private newIndex = 0;\n\n constructor(props: WmAccordionProps) {\n super(props, DEFAULT_CLASS, new WmAccordionProps());\n this.updateState({\n expandedId: (this.state.props.defaultpaneindex || 0) + 1\n } as WmAccordionState);\n }\n\n addAccordionPane(accordionPane: WmAccordionpane) {\n this.accordionPanes[(this.newIndex || this.state.expandedId) - 1] = accordionPane;\n }\n\n expandCollapseIcon(props: any, item: any, showBadge = true, showIcon = true, useChevron = true, isExpanded = false) {\n const widgetProps = item.props;\n //@ts-ignore\n const badge = showBadge && widgetProps.badgevalue != undefined ? (\n <Badge style={[\n this.styles.badge,\n isExpanded ? this.styles.activeBadge: null,\n this.styles[widgetProps.badgetype || 'default']]}>\n {widgetProps.badgevalue}\n </Badge>): null;\n let iconclass = null;\n if (useChevron) {\n iconclass = isExpanded ? 'wi wi-chevron-down' : 'wi wi-chevron-up';\n } else {\n iconclass = isExpanded ? 'wi wi-minus' : 'wi wi-plus';\n }\n return (<View style={{flexDirection: 'row'}}>\n {badge}\n {showIcon ? (\n <WmIcon\n styles={this.theme.mergeStyle({}, this.styles.icon, isExpanded ? this.styles.activeIcon : null)}\n name={'expand_collapse_icon'}\n iconclass={iconclass}></WmIcon>): null}\n </View>);\n }\n\n renderAccordionpane(item: any, index: any, isExpanded = true, accordionpanes: any[] = []) {\n const showIconOnLeft = this.styles.leftToggleIcon.root.width !== undefined;\n return (\n <View style={this.styles.pane} key={item.props.name}>\n <List.Accordion title={isDefined(item.props.title) ? item.props.title : 'Title'}\n style={[\n this.styles.header,\n index === 0 ? this.styles.firstHeader: null,\n index === accordionpanes.length - 1 && !isExpanded ? this.styles.lastHeader: null,\n isExpanded ? this.styles.activeHeader : {}]}\n theme={{\n colors: {\n background : this.styles.header.backgroundColor as string,\n primary: this.styles.activeHeader.color as string\n }\n }}\n titleStyle={[this.styles.text, isExpanded ? this.styles.activeHeaderTitle : {}]}\n descriptionStyle={this.styles.subheading}\n description={item.props.subheading}\n id={index + 1}\n key={'accordionpane_' + index}\n right={props => this.expandCollapseIcon(props, item, true, !showIconOnLeft, true, isExpanded)}\n left={props => (\n <>\n {this.expandCollapseIcon(props, item, false, showIconOnLeft, true, isExpanded)}\n {item.props.iconclass ? <WmIcon styles={this.styles.icon} name={item.props.name + '_icon'} iconclass={item.props.iconclass}></WmIcon>: null}\n </>)\n }>\n <Animatedview style={{marginLeft: -64}} ref={ref => this.animatedRef = ref} entryanimation={this.state.props.animation}>{item}</Animatedview>\n </List.Accordion>\n </View>\n );\n }\n\n onAccordionPress(expandedId: any) {\n const oldIndex = this.state.expandedId;\n this.newIndex = expandedId;\n const collapsedPane = oldIndex ? this.accordionPanes[oldIndex - 1]: null;\n collapsedPane?.onPaneCollapse();\n Promise.resolve().then(() => {\n if (this.state.expandedId >= 0) {\n return this.animatedRef.triggerExit().then((res: any) => !res && Promise.reject());\n }\n }).then(() => {\n if (this.state.expandedId === expandedId) {\n expandedId = -1;\n }\n this.updateState({\n expandedId: expandedId,\n } as WmAccordionState, () => {\n const expandedPane = expandedId ? this.accordionPanes[expandedId - 1]: null;\n expandedPane?.onPaneExpand();\n this.invokeEventCallback('onChange', [{},\n this.proxy,\n expandedId - 1,\n oldIndex ? oldIndex - 1 : null,\n expandedPane && expandedPane.props.name,\n collapsedPane && collapsedPane.props.name])\n });\n }, () => {});\n }\n\n\n renderSkeletonAccordionpane(item: any, index: any, isExpanded = true, accordionpanes: any[] = []) {\n const showIconOnLeft = this.styles.leftToggleIcon.root.width !== undefined;\n return (\n <View style={this.styles.pane} key={item.props.name}>\n <List.Accordion title={''}\n style={[{}]}\n theme={{}}\n titleStyle={[{}]}\n descriptionStyle={this.styles.subheading}\n description={item.props.subheading}\n id={index + 1}\n key={'accordionpane_' + index}\n right={props => this.expandCollapseIcon(props, item, true, !showIconOnLeft, true, isExpanded)}\n left={props => (\n <>\n {\n createSkeleton(this.theme, { root: { borderRadius: 4 }} as WmSkeletonStyles, {\n ...this.styles.root,\n width: this.styles.root?.width || \"100%\",\n height: this.styles.root?.height || this.styles.activeHeaderTitle?.fontSize || 16\n })\n }\n {this.expandCollapseIcon(props, item, false, showIconOnLeft, true, isExpanded)}\n {item.props.iconclass ? <WmIcon styles={this.styles.icon} name={item.props.name + '_icon'} iconclass={item.props.iconclass}></WmIcon>: null}\n </>)\n }>\n <Animatedview style={{marginLeft: -64}} ref={ref => this.animatedRef = ref} entryanimation={this.state.props.animation}>{item}</Animatedview>\n </List.Accordion>\n </View>\n );\n }\n public AccordionSkeleton() {\n const accordionpanes = this.props.children;\n const expandedId = this.state.expandedId || 0;\n return (\n <View style={this.styles.root}>\n <List.AccordionGroup expandedId={ expandedId } onAccordionPress={this.onAccordionPress.bind(this)} >\n {accordionpanes\n ? isArray(accordionpanes) && accordionpanes.length\n ? accordionpanes.map((item: any, index: any) => this.renderSkeletonAccordionpane(item, index, false, accordionpanes))\n : this.renderSkeletonAccordionpane(accordionpanes, 0)\n : null}\n </List.AccordionGroup>\n </View>\n )\n }\n\n public renderSkeleton(props: WmAccordionProps){\n return(this.AccordionSkeleton())\n }\n\n renderWidget(props: WmAccordionProps) {\n const accordionpanes = props.children;\n const expandedId = this.state.expandedId || 0;\n return (\n <View style={this.styles.root}>\n {this._background}\n <List.AccordionGroup expandedId={ expandedId } onAccordionPress={this.onAccordionPress.bind(this)} >\n {accordionpanes\n ? isArray(accordionpanes) && accordionpanes.length\n ? accordionpanes.map((item: any, index: any) => this.renderAccordionpane(item, index, expandedId === index + 1, accordionpanes))\n : this.renderAccordionpane(acc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E,GAC/F7C,cAAc,GACX1C,OAAO,CAAC0C,cAAc,CAAC,IAAIA,cAAc,CAACU,MAAM,GAC9CV,cAAc,CAAC8C,GAAG,CAAC,CAAClE,IAAS,EAAEmB,KAAU,KAAK,IAAI,CAACD,mBAAmB,CAAClB,IAAI,EAAEmB,KAAK,EAAE3B,UAAU,KAAK2B,KAAK,GAAG,CAAC,EAAEC,cAAc,CAAC,CAAC,GAC9H,IAAI,CAACF,mBAAmB,CAACE,cAAc,EAAE,CAAC,CAAC,GAC7C,IAAI,CACY,CACjB;EAEb;AACF"}
|
|
1
|
+
{"version":3,"names":["React","Text","TouchableOpacity","View","Badge","isArray","BaseComponent","BaseComponentState","WmAccordionProps","DEFAULT_CLASS","WmIcon","isDefined","WmAccordionState","constructor","arguments","_defineProperty","WmAccordion","props","addAccordionPane","accordionPane","i","accordionPanes","findIndex","t","name","newIndex","expand","accordionName","toggle","collapse","expandCollapseIcon","item","showBadge","length","undefined","showIcon","useChevron","isExpanded","widgetProps","badge","badgevalue","createElement","style","styles","activeBadge","badgetype","iconclass","flexDirection","theme","mergeStyle","icon","activeIcon","renderAccordionpane","index","accordionpanes","showIconOnLeft","leftToggleIcon","root","width","state","pane","key","header","firstHeader","lastHeader","activeHeader","onPress","bind","flex","justifyContent","text","heading","activeHeaderTitle","title","description","subheading","expandedId","collapseId","closeothers","lastExpandedIndex","collapsedPane","hide","Promise","resolve","then","expandedPane","show","setState","invokeEventCallback","proxy","componentDidMount","defaultpaneindex","renderWidget","children","_background","map"],"sources":["accordion.component.tsx"],"sourcesContent":["import React from 'react';\nimport { Text, TouchableOpacity, View } from 'react-native';\nimport { Badge } from 'react-native-paper';\nimport { isArray } from 'lodash';\n\nimport { BaseComponent, BaseComponentState } from '@wavemaker/app-rn-runtime/core/base.component';\nimport WmAccordionProps from './accordion.props';\nimport { DEFAULT_CLASS, WmAccordionStyles } from './accordion.styles';\nimport WmIcon from '@wavemaker/app-rn-runtime/components/basic/icon/icon.component';\nimport WmAccordionpane from './accordionpane/accordionpane.component';\nimport { isDefined } from '@wavemaker/app-rn-runtime/core/utils';\n\nexport class WmAccordionState extends BaseComponentState<WmAccordionProps> {\n lastExpandedIndex = -1;\n isExpanded = [] as boolean[];\n}\n\nexport default class WmAccordion extends BaseComponent<WmAccordionProps, WmAccordionState, WmAccordionStyles> {\n public accordionPanes = [] as WmAccordionpane[];\n private newIndex = 0;\n\n constructor(props: WmAccordionProps) {\n super(props, DEFAULT_CLASS, new WmAccordionProps(), new WmAccordionState());\n }\n\n addAccordionPane(accordionPane: WmAccordionpane) {\n const i = this.accordionPanes.findIndex(t => t.props.name === accordionPane.props.name);\n if (i >= 0) {\n this.accordionPanes[i] = accordionPane;\n } else {\n this.accordionPanes[this.newIndex++] = accordionPane;\n }\n }\n\n expand(accordionName: string) {\n const i = this.accordionPanes.findIndex(t => t.props.name === accordionName);\n this.toggle(i + 1, true);\n }\n\n collapse(accordionName: string) {\n const i = this.accordionPanes.findIndex(t => t.props.name === accordionName);\n this.toggle(i + 1, false);\n }\n\n expandCollapseIcon(item: any, showBadge = true, showIcon = true, useChevron = true, isExpanded = false) {\n const widgetProps = item.props;\n //@ts-ignore\n const badge = showBadge && widgetProps.badgevalue != undefined ? (\n <Badge style={[\n this.styles.badge,\n isExpanded ? this.styles.activeBadge: null,\n this.styles[widgetProps.badgetype || 'default']]}>\n {widgetProps.badgevalue}\n </Badge>): null;\n let iconclass = null;\n if (useChevron) {\n iconclass = isExpanded ? 'wi wi-chevron-down' : 'wi wi-chevron-up';\n } else {\n iconclass = isExpanded ? 'wi wi-minus' : 'wi wi-plus';\n }\n return (<View style={{flexDirection: 'row'}}>\n {badge}\n {showIcon ? (\n <WmIcon\n styles={this.theme.mergeStyle({}, this.styles.icon, isExpanded ? this.styles.activeIcon : null)}\n name={'expand_collapse_icon'}\n iconclass={iconclass}></WmIcon>): null}\n </View>);\n }\n\n renderAccordionpane(item: any, index: any, accordionpanes: any[] = []) {\n const showIconOnLeft = this.styles.leftToggleIcon.root.width !== undefined;\n const isExpanded = this.state.isExpanded[index];\n return (\n <View style={this.styles.pane} key={item.props.name}>\n <TouchableOpacity key={'accordionpane_' + (index + 1)}\n style={[this.styles.header,\n index === 0 ? this.styles.firstHeader: null,\n index === accordionpanes.length - 1 && !isExpanded ? this.styles.lastHeader: null,\n isExpanded ? this.styles.activeHeader : {}]}\n onPress={this.toggle.bind(this, index + 1, !isExpanded)}>\n {this.expandCollapseIcon(item, false, showIconOnLeft, true, isExpanded)}\n {item.props.iconclass ? <WmIcon styles={this.styles.icon} name={item.props.name + '_icon'} iconclass={item.props.iconclass}></WmIcon>: null}\n <View style={{flexDirection: 'column', flex: 1, justifyContent: 'center'}}>\n <Text style={[\n this.styles.text,\n this.styles.heading,\n isExpanded ? this.styles.activeHeaderTitle : {}]}>\n {isDefined(item.props.title) ? item.props.title : 'Title'}\n </Text>\n {item.props.description ? \n (<Text style={this.styles.subheading}>{item.props.description}</Text>) : null }\n </View>\n {this.expandCollapseIcon(item, true, !showIconOnLeft, true, isExpanded)}\n </TouchableOpacity>\n {item}\n </View>\n );\n }\n\n toggle(index: number, expand = true) {\n let expandedId = expand ? index : -1;\n let collapseId = expand ? -1 : index;\n if (expand && this.state.isExpanded[expandedId - 1]\n || !expand && this.state.isExpanded[collapseId - 1] === false) {\n return;\n }\n if (collapseId < 0 && this.state.props.closeothers) {\n collapseId = this.state.lastExpandedIndex;\n }\n const collapsedPane = this.accordionPanes[collapseId -1];\n collapsedPane?.hide();\n Promise.resolve().then(() => {\n const expandedPane = expandedId ? this.accordionPanes[expandedId - 1]: null;\n expandedPane?.show();\n this.setState((state) => {\n if (collapseId > 0 && collapsedPane) {\n state.isExpanded[collapseId - 1] = false;\n }\n if (expandedId > 0 && expandedPane) {\n state.isExpanded[expandedId - 1] = true;\n }\n return {\n lastExpandedIndex: expandedId,\n isExpanded: [...state.isExpanded]\n };\n }, () => {\n this.invokeEventCallback('onChange', [{},\n this.proxy,\n expandedId - 1,\n collapseId ? collapseId - 1 : null,\n expandedPane && expandedPane.props.name,\n collapsedPane && collapsedPane.props.name]);\n });\n }, () => {});\n }\n\n public componentDidMount(): void {\n super.componentDidMount();\n this.toggle(this.state.props.defaultpaneindex + 1);\n }\n\n renderWidget(props: WmAccordionProps) {\n const accordionpanes = props.children;\n const expandedId = this.state.lastExpandedIndex || 0;\n return (\n <View style={this.styles.root}>\n {this._background}\n {accordionpanes\n ? isArray(accordionpanes) && accordionpanes.length\n ? accordionpanes.map((item: any, index: any) => this.renderAccordionpane(item, index, accordionpanes))\n : this.renderAccordionpane(accordionpanes, 0)\n : null}\n </View>\n );\n }\n}\n"],"mappings":";;;AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,SAASC,IAAI,EAAEC,gBAAgB,EAAEC,IAAI,QAAQ,cAAc;AAC3D,SAASC,KAAK,QAAQ,oBAAoB;AAC1C,SAASC,OAAO,QAAQ,QAAQ;AAEhC,SAASC,aAAa,EAAEC,kBAAkB,QAAQ,+CAA+C;AACjG,OAAOC,gBAAgB,MAAM,mBAAmB;AAChD,SAASC,aAAa,QAA2B,oBAAoB;AACrE,OAAOC,MAAM,MAAM,gEAAgE;AAEnF,SAASC,SAAS,QAAQ,sCAAsC;AAEhE,OAAO,MAAMC,gBAAgB,SAASL,kBAAkB,CAAmB;EAAAM,YAAA;IAAA,SAAAC,SAAA;IAAAC,eAAA,4BACrD,CAAC,CAAC;IAAAA,eAAA,qBACT,EAAE;EAAA;AACjB;AAEA,eAAe,MAAMC,WAAW,SAASV,aAAa,CAAwD;EAI5GO,WAAWA,CAACI,KAAuB,EAAE;IACnC,KAAK,CAACA,KAAK,EAAER,aAAa,EAAE,IAAID,gBAAgB,CAAC,CAAC,EAAE,IAAII,gBAAgB,CAAC,CAAC,CAAC;IAACG,eAAA,yBAJtD,EAAE;IAAAA,eAAA,mBACP,CAAC;EAIpB;EAEAG,gBAAgBA,CAACC,aAA8B,EAAE;IAC/C,MAAMC,CAAC,GAAG,IAAI,CAACC,cAAc,CAACC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AC;MAC7C,CAAC,CAAC;IACN,CAAC,EAAE,MAAM,CAAC,CAAC,CAAC;EACd;EAEOkE,iBAAiBA,CAAA,EAAS;IAC7B,KAAK,CAACA,iBAAiB,CAAC,CAAC;IACzB,IAAI,CAAC9D,MAAM,CAAC,IAAI,CAAC+B,KAAK,CAAC1C,KAAK,CAAC0E,gBAAgB,GAAG,CAAC,CAAC;EACtD;EAEAC,YAAYA,CAAC3E,KAAuB,EAAE;IACpC,MAAMqC,cAAc,GAAGrC,KAAK,CAAC4E,QAAQ;IACrC,MAAMjB,UAAU,GAAG,IAAI,CAACjB,KAAK,CAACoB,iBAAiB,IAAI,CAAC;IACpD,oBACI/E,KAAA,CAAAyC,aAAA,CAACtC,IAAI;MAACuC,KAAK,EAAE,IAAI,CAACC,MAAM,CAACc;IAAK,GAC3B,IAAI,CAACqC,WAAW,EACdxC,cAAc,GACXjD,OAAO,CAACiD,cAAc,CAAC,IAAIA,cAAc,CAACrB,MAAM,GAC9CqB,cAAc,CAACyC,GAAG,CAAC,CAAChE,IAAS,EAAEsB,KAAU,KAAK,IAAI,CAACD,mBAAmB,CAACrB,IAAI,EAAEsB,KAAK,EAAEC,cAAc,CAAC,CAAC,GACpG,IAAI,CAACF,mBAAmB,CAACE,cAAc,EAAE,CAAC,CAAC,GAC7C,IACF,CAAC;EAEb;AACF"}
|
|
@@ -8,6 +8,7 @@ export default class WmAccordionProps extends BaseProps {
|
|
|
8
8
|
_defineProperty(this, "animation", 'fadeInDown');
|
|
9
9
|
_defineProperty(this, "children", void 0);
|
|
10
10
|
_defineProperty(this, "defaultpaneindex", 0);
|
|
11
|
+
_defineProperty(this, "closeothers", true);
|
|
11
12
|
}
|
|
12
13
|
}
|
|
13
14
|
//# sourceMappingURL=accordion.props.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["BaseProps","WmAccordionProps"],"sources":["accordion.props.ts"],"sourcesContent":["import { BaseProps } from '@wavemaker/app-rn-runtime/core/base.component';\n\nexport default class WmAccordionProps extends BaseProps {\n animation: string = 'fadeInDown';\n children: any;\n defaultpaneindex: number = 0;\n}\n"],"mappings":";;;AAAA,SAASA,SAAS,QAAQ,+CAA+C;AAEzE,eAAe,MAAMC,gBAAgB,SAASD,SAAS,CAAC;
|
|
1
|
+
{"version":3,"names":["BaseProps","WmAccordionProps","constructor","arguments","_defineProperty"],"sources":["accordion.props.ts"],"sourcesContent":["import { BaseProps } from '@wavemaker/app-rn-runtime/core/base.component';\n\nexport default class WmAccordionProps extends BaseProps {\n animation: string = 'fadeInDown';\n children: any;\n defaultpaneindex: number = 0;\n closeothers = true;\n}\n"],"mappings":";;;AAAA,SAASA,SAAS,QAAQ,+CAA+C;AAEzE,eAAe,MAAMC,gBAAgB,SAASD,SAAS,CAAC;EAAAE,YAAA;IAAA,SAAAC,SAAA;IAAAC,eAAA,oBAClC,YAAY;IAAAA,eAAA;IAAAA,eAAA,2BAEL,CAAC;IAAAA,eAAA,sBACd,IAAI;EAAA;AACpB"}
|
|
@@ -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-accordion';
|
|
4
5
|
BASE_THEME.registerStyle((themeVariables, addStyle) => {
|
|
5
6
|
const defaultStyles = defineStyles({
|
|
@@ -19,15 +20,15 @@ BASE_THEME.registerStyle((themeVariables, addStyle) => {
|
|
|
19
20
|
borderTopLeftRadius: 6,
|
|
20
21
|
borderTopRightRadius: 6
|
|
21
22
|
},
|
|
22
|
-
pane: {
|
|
23
|
-
marginBottom: 4
|
|
24
|
-
},
|
|
23
|
+
pane: {},
|
|
25
24
|
header: {
|
|
26
25
|
borderBottomWidth: 1,
|
|
27
26
|
borderStyle: 'solid',
|
|
28
27
|
borderColor: themeVariables.accordionBorderColor,
|
|
29
28
|
backgroundColor: themeVariables.accordionHeaderBgColor,
|
|
30
|
-
padding: 8
|
|
29
|
+
padding: 8,
|
|
30
|
+
flexDirection: 'row',
|
|
31
|
+
justifyContent: 'center'
|
|
31
32
|
},
|
|
32
33
|
lastHeader: {
|
|
33
34
|
borderBottomWidth: 0,
|
|
@@ -107,6 +108,15 @@ BASE_THEME.registerStyle((themeVariables, addStyle) => {
|
|
|
107
108
|
}
|
|
108
109
|
});
|
|
109
110
|
addStyle(DEFAULT_CLASS, '', defaultStyles);
|
|
111
|
+
addStyle(DEFAULT_CLASS + '-rtl', '', Platform.OS == "web" ? {
|
|
112
|
+
text: {
|
|
113
|
+
textAlign: 'right'
|
|
114
|
+
}
|
|
115
|
+
} : {
|
|
116
|
+
text: {
|
|
117
|
+
textAlign: 'left'
|
|
118
|
+
}
|
|
119
|
+
});
|
|
110
120
|
addStyle('app-accordion1', '', {
|
|
111
121
|
pane: {
|
|
112
122
|
marginBottom: 0
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["BASE_THEME","defineStyles","DEFAULT_CLASS","registerStyle","themeVariables","addStyle","defaultStyles","root","width","borderWidth","borderStyle","borderColor","accordionBorderColor","borderRadius","backgroundColor","transparent","text","color","accordionTitleColor","fontSize","firstHeader","borderTopLeftRadius","borderTopRightRadius","pane","
|
|
1
|
+
{"version":3,"names":["BASE_THEME","defineStyles","Platform","DEFAULT_CLASS","registerStyle","themeVariables","addStyle","defaultStyles","root","width","borderWidth","borderStyle","borderColor","accordionBorderColor","borderRadius","backgroundColor","transparent","text","color","accordionTitleColor","fontSize","firstHeader","borderTopLeftRadius","borderTopRightRadius","pane","header","borderBottomWidth","accordionHeaderBgColor","padding","flexDirection","justifyContent","lastHeader","borderBottomLeftRadius","borderBottomRightRadius","activeHeader","accordionActiveHeaderBgColor","activeHeaderTitle","accordionActiveHeaderTextColor","subheading","icon","alignSelf","height","accordionIconColor","fontWeight","leftToggleIcon","rightToggleIcon","activeIcon","activeBadge","badge","marginRight","alignContent","default","success","labelSuccessColor","danger","labelDangerColor","warning","labelWarningColor","info","labelInfoColor","primary","labelPrimaryColor","OS","textAlign","marginBottom"],"sources":["accordion.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 { TextStyle, ViewStyle, Platform } from 'react-native';\nimport Color from 'color';\n\nexport type WmAccordionStyles = BaseStyles & {\n icon: WmIconStyles,\n rightToggleIcon: WmIconStyles,\n leftToggleIcon: WmIconStyles,\n activeIcon: WmIconStyles,\n pane: AllStyle,\n badge: AllStyle,\n activeBadge: AllStyle,\n firstHeader: ViewStyle,\n lastHeader: ViewStyle,\n header: AllStyle,\n activeHeader: AllStyle,\n activeHeaderTitle: TextStyle,\n subheading: AllStyle\n};\n\nexport const DEFAULT_CLASS = 'app-accordion';\nBASE_THEME.registerStyle((themeVariables, addStyle) => {\n const defaultStyles: WmAccordionStyles = defineStyles({\n root: {\n width: '100%',\n borderWidth: 0,\n borderStyle: 'solid',\n borderColor: themeVariables.accordionBorderColor,\n borderRadius: 6,\n backgroundColor: themeVariables.transparent\n },\n text: {\n color: themeVariables.accordionTitleColor,\n fontSize: 18\n },\n firstHeader: {\n borderTopLeftRadius: 6,\n borderTopRightRadius: 6\n },\n pane : {},\n header: {\n borderBottomWidth: 1,\n borderStyle: 'solid',\n borderColor: themeVariables.accordionBorderColor,\n backgroundColor: themeVariables.accordionHeaderBgColor,\n padding: 8,\n flexDirection: 'row',\n justifyContent: 'center'\n },\n lastHeader: {\n borderBottomWidth: 0,\n borderBottomLeftRadius: 6,\n borderBottomRightRadius: 6\n },\n activeHeader: {\n borderColor: themeVariables.accordionActiveHeaderBgColor,\n backgroundColor: themeVariables.accordionActiveHeaderBgColor\n },\n activeHeaderTitle: {\n color: themeVariables.accordionActiveHeaderTextColor\n },\n subheading: {\n\n },\n icon: {\n root: {\n alignSelf: 'auto',\n width: 24,\n height: 24,\n borderRadius: 24,\n justifyContent: 'center'\n },\n icon: {\n color: themeVariables.accordionIconColor,\n alignSelf: 'center',\n justifyContent: 'center',\n fontSize: 16,\n fontWeight: 'bold'\n }\n } as WmIconStyles,\n leftToggleIcon: {\n root: {}\n } as WmIconStyles,\n rightToggleIcon: {\n root: {}\n } as WmIconStyles,\n activeIcon : {\n root: {\n borderColor: themeVariables.accordionActiveHeaderTextColor,\n },\n icon: {\n color: themeVariables.accordionActiveHeaderTextColor\n }\n } as WmIconStyles,\n activeBadge: {\n borderColor: themeVariables.accordionActiveHeaderTextColor,\n color: themeVariables.accordionActiveHeaderTextColor\n },\n badge: {\n color: themeVariables.accordionIconColor,\n fontSize: 14,\n marginRight: 4,\n width: 24,\n height: 24,\n borderRadius: 12,\n alignContent: 'center',\n borderStyle: 'solid',\n borderWidth: 2,\n borderColor: themeVariables.accordionIconColor,\n backgroundColor: themeVariables.transparent\n },\n default: {},\n success: {\n backgroundColor: themeVariables.labelSuccessColor\n },\n danger: {\n backgroundColor: themeVariables.labelDangerColor\n },\n warning: {\n backgroundColor: themeVariables.labelWarningColor\n },\n info: {\n backgroundColor: themeVariables.labelInfoColor\n },\n primary: {\n backgroundColor: themeVariables.labelPrimaryColor\n }\n });\n\n addStyle(DEFAULT_CLASS, '', defaultStyles);\n addStyle(DEFAULT_CLASS + '-rtl', '', Platform.OS==\"web\"?{\n text:{\n textAlign:'right',\n } \n }:{\n text:{\n textAlign:'left',\n } \n });\n addStyle('app-accordion1', '', {\n pane: {\n marginBottom: 0\n },\n leftToggleIcon: {\n root: {\n width: 1\n }\n },\n icon: {\n root: {\n backgroundColor: 'rgba(255, 255, 255, 0.1)'\n }\n }\n } as WmAccordionStyles);\n});\n"],"mappings":"AAAA,OAAOA,UAAU,MAAkB,wCAAwC;AAC3E,SAAqBC,YAAY,QAAQ,+CAA+C;AAExF,SAA+BC,QAAQ,QAAQ,cAAc;A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C;IACDC,OAAO,EAAE;MACP7C,eAAe,EAAEV,cAAc,CAACwD;IAClC;EACJ,CAAC,CAAC;EAEFvD,QAAQ,CAACH,aAAa,EAAE,EAAE,EAAEI,aAAa,CAAC;EAC1CD,QAAQ,CAACH,aAAa,GAAG,MAAM,EAAE,EAAE,EAAED,QAAQ,CAAC4D,EAAE,IAAE,KAAK,GAAC;IACtD7C,IAAI,EAAC;MACD8C,SAAS,EAAC;IACd;EACF,CAAC,GAAC;IACA9C,IAAI,EAAC;MACH8C,SAAS,EAAC;IACZ;EACF,CAAC,CAAC;EACFzD,QAAQ,CAAC,gBAAgB,EAAE,EAAE,EAAE;IAC7BkB,IAAI,EAAE;MACJwC,YAAY,EAAE;IAChB,CAAC;IACDpB,cAAc,EAAE;MACdpC,IAAI,EAAE;QACJC,KAAK,EAAE;MACT;IACF,CAAC;IACD8B,IAAI,EAAE;MACJ/B,IAAI,EAAE;QACJO,eAAe,EAAE;MACnB;IACF;EACF,CAAsB,CAAC;AACzB,CAAC,CAAC"}
|
|
@@ -1,27 +1,64 @@
|
|
|
1
1
|
function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
2
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
|
-
import React from 'react';
|
|
5
|
-
import { View } from 'react-native';
|
|
4
|
+
import React, { useState } from 'react';
|
|
6
5
|
import { BaseComponent, BaseComponentState } from '@wavemaker/app-rn-runtime/core/base.component';
|
|
7
6
|
import WmAccordionpaneProps from './accordionpane.props';
|
|
8
7
|
import { DEFAULT_CLASS } from './accordionpane.styles';
|
|
8
|
+
import { View } from 'react-native';
|
|
9
|
+
import { isWebPreviewMode } from '@wavemaker/app-rn-runtime/core/utils';
|
|
10
|
+
const Animated = isWebPreviewMode() ? {} : require('react-native-reanimated');
|
|
9
11
|
export class WmAccordionpaneState extends BaseComponentState {
|
|
10
12
|
constructor() {
|
|
11
13
|
super(...arguments);
|
|
12
14
|
_defineProperty(this, "isPartialLoaded", false);
|
|
15
|
+
_defineProperty(this, "collapsed", true);
|
|
13
16
|
}
|
|
14
17
|
}
|
|
18
|
+
const AnimatedView = props => {
|
|
19
|
+
const [height, setHeight] = useState(0);
|
|
20
|
+
const offset = Animated.useSharedValue(0);
|
|
21
|
+
offset.value = props.close ? 0 : 1;
|
|
22
|
+
const onLayoutChange = e => {
|
|
23
|
+
var _e$nativeEvent;
|
|
24
|
+
setHeight((((_e$nativeEvent = e.nativeEvent) === null || _e$nativeEvent === void 0 || (_e$nativeEvent = _e$nativeEvent.layout) === null || _e$nativeEvent === void 0 ? void 0 : _e$nativeEvent.height) || height || 100000000) + 1000);
|
|
25
|
+
};
|
|
26
|
+
const animatedStyles = Animated.useAnimatedStyle(() => {
|
|
27
|
+
return {
|
|
28
|
+
maxHeight: Animated.withTiming(offset.value * height)
|
|
29
|
+
};
|
|
30
|
+
});
|
|
31
|
+
return /*#__PURE__*/React.createElement(Animated.default.View, {
|
|
32
|
+
style: [animatedStyles]
|
|
33
|
+
}, /*#__PURE__*/React.createElement(View, {
|
|
34
|
+
onLayout: onLayoutChange
|
|
35
|
+
}, props.children));
|
|
36
|
+
};
|
|
15
37
|
export default class WmAccordionpane extends BaseComponent {
|
|
16
38
|
constructor(props) {
|
|
17
|
-
super(props, DEFAULT_CLASS, new WmAccordionpaneProps());
|
|
39
|
+
super(props, DEFAULT_CLASS, new WmAccordionpaneProps(), new WmAccordionpaneState());
|
|
40
|
+
}
|
|
41
|
+
isCollapsed() {
|
|
42
|
+
return this.state.collapsed;
|
|
18
43
|
}
|
|
19
|
-
|
|
44
|
+
show() {
|
|
45
|
+
this.updateState({
|
|
46
|
+
collapsed: false
|
|
47
|
+
});
|
|
20
48
|
this.invokeEventCallback('onExpand', [null, this.proxy]);
|
|
21
49
|
}
|
|
22
|
-
|
|
50
|
+
hide() {
|
|
51
|
+
this.updateState({
|
|
52
|
+
collapsed: true
|
|
53
|
+
});
|
|
23
54
|
this.invokeEventCallback('onCollapse', [null, this.proxy]);
|
|
24
55
|
}
|
|
56
|
+
expand() {
|
|
57
|
+
this.parent.expand(this.props.name || '');
|
|
58
|
+
}
|
|
59
|
+
collapse() {
|
|
60
|
+
this.parent.expand(this.props.name || '');
|
|
61
|
+
}
|
|
25
62
|
componentDidMount() {
|
|
26
63
|
const accordion = this.parent;
|
|
27
64
|
accordion.addAccordionPane(this);
|
|
@@ -44,8 +81,12 @@ export default class WmAccordionpane extends BaseComponent {
|
|
|
44
81
|
return props.children;
|
|
45
82
|
}
|
|
46
83
|
renderWidget(props) {
|
|
47
|
-
return /*#__PURE__*/React.createElement(View, {
|
|
48
|
-
style: this.
|
|
84
|
+
return isWebPreviewMode() ? /*#__PURE__*/React.createElement(View, {
|
|
85
|
+
style: this.state.collapsed ? {
|
|
86
|
+
maxHeight: 0
|
|
87
|
+
} : {}
|
|
88
|
+
}, this._background, this.renderContent(props)) : /*#__PURE__*/React.createElement(AnimatedView, {
|
|
89
|
+
close: this.state.collapsed
|
|
49
90
|
}, this._background, this.renderContent(props));
|
|
50
91
|
}
|
|
51
92
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["React","
|
|
1
|
+
{"version":3,"names":["React","useState","BaseComponent","BaseComponentState","WmAccordionpaneProps","DEFAULT_CLASS","View","isWebPreviewMode","Animated","require","WmAccordionpaneState","constructor","arguments","_defineProperty","AnimatedView","props","height","setHeight","offset","useSharedValue","value","close","onLayoutChange","e","_e$nativeEvent","nativeEvent","layout","animatedStyles","useAnimatedStyle","maxHeight","withTiming","createElement","default","style","onLayout","children","WmAccordionpane","isCollapsed","state","collapsed","show","updateState","invokeEventCallback","proxy","hide","expand","parent","name","collapse","componentDidMount","accordion","addAccordionPane","onPartialLoad","renderContent","renderPartial","isPartialLoaded","setTimeout","bind","renderWidget","_background"],"sources":["accordionpane.component.tsx"],"sourcesContent":["import React, { useCallback, useMemo, useState } from 'react';\nimport { BaseComponent, BaseComponentState } from '@wavemaker/app-rn-runtime/core/base.component';\n\nimport WmAccordionpaneProps from './accordionpane.props';\nimport { DEFAULT_CLASS, WmAccordionpaneStyles } from './accordionpane.styles';\nimport WmAccordion from '../accordion.component';\nimport { LayoutChangeEvent, View } from 'react-native';\nimport { isWebPreviewMode } from '@wavemaker/app-rn-runtime/core/utils';\n\nconst Animated: any = isWebPreviewMode() ? {} : require('react-native-reanimated');\n\nexport class WmAccordionpaneState extends BaseComponentState<WmAccordionpaneProps> {\n isPartialLoaded = false;\n collapsed = true;\n}\n\nconst AnimatedView = (props: {\n close: boolean,\n children: any\n}) => {\n const [height, setHeight] = useState(0);\n const offset = Animated.useSharedValue(0);\n offset.value = props.close ? 0 : 1;\n const onLayoutChange = (e: LayoutChangeEvent) => {\n setHeight((e.nativeEvent?.layout?.height || height || 100000000) + 1000);\n };\n const animatedStyles = Animated.useAnimatedStyle(() => {\n return {\n maxHeight: Animated.withTiming(offset.value * height)\n };\n });\n return (\n <Animated.default.View style={[animatedStyles]}>\n <View onLayout={onLayoutChange}>\n {props.children}\n </View>\n </Animated.default.View>\n );\n};\n\nexport default class WmAccordionpane extends BaseComponent<WmAccordionpaneProps, WmAccordionpaneState, WmAccordionpaneStyles> {\n\n constructor(props: WmAccordionpaneProps) {\n super(props, DEFAULT_CLASS, new WmAccordionpaneProps(), new WmAccordionpaneState());\n }\n\n isCollapsed() {\n return this.state.collapsed;\n }\n \n show() {\n this.updateState({\n collapsed: false\n } as WmAccordionpaneState);\n this.invokeEventCallback('onExpand', [null, this.proxy]);\n }\n\n hide() {\n this.updateState({\n collapsed: true\n } as WmAccordionpaneState);\n this.invokeEventCallback('onCollapse', [null, this.proxy]);\n }\n\n expand() {\n (this.parent as WmAccordion).expand(this.props.name || '');\n }\n\n collapse() {\n (this.parent as WmAccordion).expand(this.props.name || '');\n }\n\n componentDidMount() {\n const accordion = (this.parent) as WmAccordion;\n accordion.addAccordionPane(this);\n super.componentDidMount();\n }\n\n onPartialLoad() {\n this.invokeEventCallback('onLoad', [this]);\n }\n\n renderContent(props: WmAccordionpaneProps) {\n if (props.renderPartial) {\n if (!this.state.isPartialLoaded) {\n setTimeout(() => {\n this.updateState({\n isPartialLoaded: true\n } as WmAccordionpaneState);\n });\n }\n return props.renderPartial(this.onPartialLoad.bind(this));\n }\n return props.children;\n }\n renderWidget(props: WmAccordionpaneProps) {\n return isWebPreviewMode() ? \n (<View style={this.state.collapsed ? {maxHeight: 0} : {}}>\n {this._background}\n {this.renderContent(props)}\n </View>) :\n (<AnimatedView close={this.state.collapsed}>\n {this._background}\n {this.renderContent(props)}\n </AnimatedView>);\n }\n}\n"],"mappings":";;;AAAA,OAAOA,KAAK,IAA0BC,QAAQ,QAAQ,OAAO;AAC7D,SAASC,aAAa,EAAEC,kBAAkB,QAAQ,+CAA+C;AAEjG,OAAOC,oBAAoB,MAAM,uBAAuB;AACxD,SAASC,aAAa,QAA+B,wBAAwB;AAE7E,SAA4BC,IAAI,QAAQ,cAAc;AACtD,SAASC,gBAAgB,QAAQ,sCAAsC;AAEvE,MAAMC,QAAa,GAAGD,gBAAgB,CAAC,CAAC,GAAG,CAAC,CAAC,GAAGE,OAAO,CAAC,yBAAyB,CAAC;AAElF,OAAO,MAAMC,oBAAoB,SAASP,kBAAkB,CAAuB;EAAAQ,YAAA;IAAA,SAAAC,SAAA;IAAAC,eAAA,0BAC/D,KAAK;IAAAA,eAAA,oBACX,IAAI;EAAA;AAClB;AAEA,MAAMC,YAAY,GAAIC,KAGrB,IAAK;EACJ,MAAM,CAACC,MAAM,EAAEC,SAAS,CAAC,GAAGhB,QAAQ,C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xC,OAAOR,gBAAgB,CAAC,CAAC,gBACxBP,KAAA,CAAA+B,aAAA,CAACzB,IAAI;MAAC2B,KAAK,EAAE,IAAI,CAACK,KAAK,CAACC,SAAS,GAAG;QAACV,SAAS,EAAE;MAAC,CAAC,GAAG,CAAC;IAAE,GACtD,IAAI,CAAC8B,WAAW,EAChB,IAAI,CAACN,aAAa,CAACtC,KAAK,CACrB,CAAC,gBACNf,KAAA,CAAA+B,aAAA,CAACjB,YAAY;MAACO,KAAK,EAAE,IAAI,CAACiB,KAAK,CAACC;IAAU,GACxC,IAAI,CAACoB,WAAW,EAChB,IAAI,CAACN,aAAa,CAACtC,KAAK,CACb,CAAE;EAClB;AACF"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["BaseProps","WmAccordionpaneProps"],"sources":["accordionpane.props.ts"],"sourcesContent":["import { BaseProps } from '@wavemaker/app-rn-runtime/core/base.component';\n\nexport default class WmAccordionpaneProps extends BaseProps {\n children: any;\n iconclass: string = null as any;\n title: string = 'Title';\n renderPartial?: Function;\n subheading: string = null as any;\n badgevalue: string = null as any;\n badgetype: string = null as any;\n}\n"],"mappings":";;;AAAA,SAASA,SAAS,QAAQ,+CAA+C;AAEzE,eAAe,MAAMC,oBAAoB,SAASD,SAAS,CAAC;
|
|
1
|
+
{"version":3,"names":["BaseProps","WmAccordionpaneProps","constructor","arguments","_defineProperty"],"sources":["accordionpane.props.ts"],"sourcesContent":["import { BaseProps } from '@wavemaker/app-rn-runtime/core/base.component';\n\nexport default class WmAccordionpaneProps extends BaseProps {\n children: any;\n iconclass: string = null as any;\n title: string = 'Title';\n renderPartial?: Function;\n subheading: string = null as any;\n badgevalue: string = null as any;\n badgetype: string = null as any;\n}\n"],"mappings":";;;AAAA,SAASA,SAAS,QAAQ,+CAA+C;AAEzE,eAAe,MAAMC,oBAAoB,SAASD,SAAS,CAAC;EAAAE,YAAA;IAAA,SAAAC,SAAA;IAAAC,eAAA;IAAAA,eAAA,oBAEtC,IAAI;IAAAA,eAAA,gBACR,OAAO;IAAAA,eAAA;IAAAA,eAAA,qBAEF,IAAI;IAAAA,eAAA,qBACJ,IAAI;IAAAA,eAAA,oBACL,IAAI;EAAA;AAC1B"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["React","View","WmContainerProps","DEFAULT_CLASS","Tappable","Animatedview","PartialHost","PartialHostState","WmContainerState","
|
|
1
|
+
{"version":3,"names":["React","View","WmContainerProps","DEFAULT_CLASS","Tappable","Animatedview","PartialHost","PartialHostState","WmContainerState","constructor","arguments","_defineProperty","WmContainer","props","renderWidget","dimensions","width","styles","root","undefined","height","createElement","entryanimation","animation","style","_background","target","content","renderContent"],"sources":["container.component.tsx"],"sourcesContent":["import React from 'react';\nimport { View, ViewStyle } from 'react-native';\n\nimport WmContainerProps from './container.props';\nimport { DEFAULT_CLASS, WmContainerStyles } from './container.styles';\nimport { Tappable } from '@wavemaker/app-rn-runtime/core/tappable.component';\nimport { Animatedview } from '@wavemaker/app-rn-runtime/components/basic/animatedview.component';\nimport { PartialHost, PartialHostState } from './partial-host.component';\n\nexport class WmContainerState extends PartialHostState<WmContainerProps> {\n isPartialLoaded = false;\n}\n\nexport default class WmContainer extends PartialHost<WmContainerProps, WmContainerState, WmContainerStyles> {\n constructor(props: WmContainerProps) {\n super(props, DEFAULT_CLASS, new WmContainerProps());\n }\n\n renderWidget(props: WmContainerProps) {\n const dimensions = {\n width: this.styles.root.width ? '100%' : undefined,\n height: this.styles.root.height ? '100%' : undefined\n };\n return (\n <Animatedview entryanimation={props.animation} style={this.styles.root}>\n {this._background}\n <Tappable target={this} styles={dimensions}>\n <View style={[dimensions as ViewStyle, this.styles.content]}>{this.renderContent(props)}</View>\n </Tappable>\n </Animatedview>\n );\n }\n}\n"],"mappings":";;;AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,SAASC,IAAI,QAAmB,cAAc;AAE9C,OAAOC,gBAAgB,MAAM,mBAAmB;AAChD,SAASC,aAAa,QAA2B,oBAAoB;AACrE,SAASC,QAAQ,QAAQ,mDAAmD;AAC5E,SAASC,YAAY,QAAQ,mEAAmE;AAChG,SAASC,WAAW,EAAEC,gBAAgB,QAAQ,0BAA0B;AAExE,OAAO,MAAMC,gBAAgB,SAASD,gBAAgB,CAAmB;EAAAE,YAAA;IAAA,SAAAC,SAAA;IAAAC,eAAA,0BACrD,KAAK;EAAA;AACzB;AAEA,eAAe,MAAMC,WAAW,SAASN,WAAW,CAAwD;EAC1GG,WAAWA,CAACI,KAAuB,EAAE;IACnC,KAAK,CAACA,KAAK,EAAEV,aAAa,EAAE,IAAID,gBAAgB,CAAC,CAAC,CAAC;EACrD;EAEAY,YAAYA,CAACD,KAAuB,EAAE;IACpC,MAAME,UAAU,GAAG;MACjBC,KAAK,EAAE,IAAI,CAACC,MAAM,CAACC,IAAI,CAACF,KAAK,GAAG,MAAM,GAAGG,SAAS;MAClDC,MAAM,EAAE,IAAI,CAACH,MAAM,CAACC,IAAI,CAACE,MAAM,GAAG,MAAM,GAAGD;IAC7C,CAAC;IACD,oBACEnB,KAAA,CAAAqB,aAAA,CAAChB,YAAY;MAACiB,cAAc,EAAET,KAAK,CAACU,SAAU;MAACC,KAAK,EAAE,IAAI,CAACP,MAAM,CAACC;IAAK,GACpE,IAAI,CAACO,WAAW,eACjBzB,KAAA,CAAAqB,aAAA,CAACjB,QAAQ;MAACsB,MAAM,EAAE,IAAK;MAACT,MAAM,EAAEF;IAAW,gBACvCf,KAAA,CAAAqB,aAAA,CAACpB,IAAI;MAACuB,KAAK,EAAE,CAACT,UAAU,EAAgB,IAAI,CAACE,MAAM,CAACU,OAAO;IAAE,GAAE,IAAI,CAACC,aAAa,CAACf,KAAK,CAAQ,CACzF,CACE,CAAC;EAEnB;AACF"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["PartialHostProps","WmContainerProps"],"sources":["container.props.ts"],"sourcesContent":["import { PartialHostProps } from './partial-host.component';\n\nexport default class WmContainerProps extends PartialHostProps {\n animation?: string = null as any;\n onLoad?: Function;\n}\n"],"mappings":";;;AAAA,SAASA,gBAAgB,QAAQ,0BAA0B;AAE3D,eAAe,MAAMC,gBAAgB,SAASD,gBAAgB,CAAC;
|
|
1
|
+
{"version":3,"names":["PartialHostProps","WmContainerProps","constructor","arguments","_defineProperty"],"sources":["container.props.ts"],"sourcesContent":["import { PartialHostProps } from './partial-host.component';\n\nexport default class WmContainerProps extends PartialHostProps {\n animation?: string = null as any;\n onLoad?: Function;\n}\n"],"mappings":";;;AAAA,SAASA,gBAAgB,QAAQ,0BAA0B;AAE3D,eAAe,MAAMC,gBAAgB,SAASD,gBAAgB,CAAC;EAAAE,YAAA;IAAA,SAAAC,SAAA;IAAAC,eAAA,oBACxC,IAAI;IAAAA,eAAA;EAAA;AAE3B"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["BASE_THEME","defineStyles","DEFAULT_CLASS","registerStyle","themeVariables","addStyle","defaultStyles","root","text","content","flexDirection","flex","paddingLeft","paddingRight","justifyContent","shadowColor","shadowOffset","width","height","shadowRadius","borderRadius","borderWidth","borderColor","containerOutlineColor","borderStyle"],"sources":["container.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';\n\nexport type WmContainerStyles = BaseStyles & {\n content: AllStyle\n};\n\nexport const DEFAULT_CLASS = 'app-container';\nBASE_THEME.registerStyle((themeVariables, addStyle) => {\n const defaultStyles: WmContainerStyles = defineStyles({\n root: {},\n text: {},\n content: {\n flexDirection: 'column'\n }\n });\n\n addStyle(DEFAULT_CLASS, '', defaultStyles);\n addStyle('media-body', '', {\n root: {\n flex: 1,\n paddingLeft: 8,\n paddingRight: 8,\n justifyContent: 'center'\n }\n } as WmContainerStyles);\n addStyle('media-right', '', {\n root: {\n justifyContent: 'center'\n }\n } as WmContainerStyles);\n addStyle('app-elevated-container', '', {\n root: {\n shadowColor: 'rgba(0, 0, 0, 0.2)',\n shadowOffset: {\n width: 2,\n height: 2\n },\n shadowRadius: 2,\n borderRadius: 8\n }\n } as WmContainerStyles);\n addStyle('app-outlined-container', '', {\n root: {\n borderWidth: 1,\n borderColor: themeVariables.containerOutlineColor,\n borderStyle: 'solid'\n }\n } as WmContainerStyles);\n});"],"mappings":"AAAA,OAAOA,UAAU,MAAqB,wCAAwC;AAC9E,SAAqBC,YAAY,QAAQ,+CAA+C;AAMxF,OAAO,MAAMC,aAAa,GAAG,eAAe;AAC5CF,UAAU,CAACG,aAAa,CAAC,CAACC,cAAc,EAAEC,QAAQ,KAAK;EACnD,MAAMC,aAAgC,GAAGL,YAAY,CAAC;IAClDM,IAAI,EAAE,CAAC,CAAC;IACRC,IAAI,EAAE,CAAC,CAAC;IACRC,OAAO,EAAE;MACLC,aAAa,EAAE;IACnB;EACJ,CAAC,CAAC;EAEFL,QAAQ,CAACH,aAAa,EAAE,EAAE,EAAEI,aAAa,CAAC;EAC1CD,QAAQ,CAAC,YAAY,EAAE,EAAE,EAAE;IACvBE,IAAI,EAAE;MACFI,IAAI,EAAE,CAAC;MACPC,WAAW,EAAE,CAAC;MACdC,YAAY,EAAE,CAAC;MACfC,cAAc,EAAE;IACpB;EACJ,CAAC
|
|
1
|
+
{"version":3,"names":["BASE_THEME","defineStyles","DEFAULT_CLASS","registerStyle","themeVariables","addStyle","defaultStyles","root","text","content","flexDirection","flex","paddingLeft","paddingRight","justifyContent","shadowColor","shadowOffset","width","height","shadowRadius","borderRadius","borderWidth","borderColor","containerOutlineColor","borderStyle"],"sources":["container.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';\n\nexport type WmContainerStyles = BaseStyles & {\n content: AllStyle\n};\n\nexport const DEFAULT_CLASS = 'app-container';\nBASE_THEME.registerStyle((themeVariables, addStyle) => {\n const defaultStyles: WmContainerStyles = defineStyles({\n root: {},\n text: {},\n content: {\n flexDirection: 'column'\n }\n });\n\n addStyle(DEFAULT_CLASS, '', defaultStyles);\n addStyle('media-body', '', {\n root: {\n flex: 1,\n paddingLeft: 8,\n paddingRight: 8,\n justifyContent: 'center'\n }\n } as WmContainerStyles);\n addStyle('media-right', '', {\n root: {\n justifyContent: 'center'\n }\n } as WmContainerStyles);\n addStyle('app-elevated-container', '', {\n root: {\n shadowColor: 'rgba(0, 0, 0, 0.2)',\n shadowOffset: {\n width: 2,\n height: 2\n },\n shadowRadius: 2,\n borderRadius: 8\n }\n } as WmContainerStyles);\n addStyle('app-outlined-container', '', {\n root: {\n borderWidth: 1,\n borderColor: themeVariables.containerOutlineColor,\n borderStyle: 'solid'\n }\n } as WmContainerStyles);\n});"],"mappings":"AAAA,OAAOA,UAAU,MAAqB,wCAAwC;AAC9E,SAAqBC,YAAY,QAAQ,+CAA+C;AAMxF,OAAO,MAAMC,aAAa,GAAG,eAAe;AAC5CF,UAAU,CAACG,aAAa,CAAC,CAACC,cAAc,EAAEC,QAAQ,KAAK;EACnD,MAAMC,aAAgC,GAAGL,YAAY,CAAC;IAClDM,IAAI,EAAE,CAAC,CAAC;IACRC,IAAI,EAAE,CAAC,CAAC;IACRC,OAAO,EAAE;MACLC,aAAa,EAAE;IACnB;EACJ,CAAC,CAAC;EAEFL,QAAQ,CAACH,aAAa,EAAE,EAAE,EAAEI,aAAa,CAAC;EAC1CD,QAAQ,CAAC,YAAY,EAAE,EAAE,EAAE;IACvBE,IAAI,EAAE;MACFI,IAAI,EAAE,CAAC;MACPC,WAAW,EAAE,CAAC;MACdC,YAAY,EAAE,CAAC;MACfC,cAAc,EAAE;IACpB;EACJ,CAAsB,CAAC;EACvBT,QAAQ,CAAC,aAAa,EAAE,EAAE,EAAE;IACxBE,IAAI,EAAE;MACFO,cAAc,EAAE;IACpB;EACJ,CAAsB,CAAC;EACvBT,QAAQ,CAAC,wBAAwB,EAAE,EAAE,EAAE;IACnCE,IAAI,EAAE;MACFQ,WAAW,EAAE,oBAAoB;MACjCC,YAAY,EAAE;QACVC,KAAK,EAAE,CAAC;QACRC,MAAM,EAAE;MACZ,CAAC;MACDC,YAAY,EAAE,CAAC;MACfC,YAAY,EAAE;IAClB;EACJ,CAAsB,CAAC;EACvBf,QAAQ,CAAC,wBAAwB,EAAE,EAAE,EAAE;IACnCE,IAAI,EAAE;MACFc,WAAW,EAAE,CAAC;MACdC,WAAW,EAAElB,cAAc,CAACmB,qBAAqB;MACjDC,WAAW,EAAE;IACjB;EACJ,CAAsB,CAAC;AAC3B,CAAC,CAAC"}
|