@wavemaker/app-rn-runtime 12.0.0-next.45752 → 12.0.0-next.46502
Sign up to get free protection for your applications and to get access to all the features.
- app-rn-runtime/components/advanced/carousel/carousel.component.js +14 -2
- app-rn-runtime/components/advanced/carousel/carousel.component.js.map +1 -1
- app-rn-runtime/components/advanced/carousel/carousel.props.js +1 -0
- app-rn-runtime/components/advanced/carousel/carousel.props.js.map +1 -1
- app-rn-runtime/components/advanced/carousel/carousel.styles.js +15 -0
- app-rn-runtime/components/advanced/carousel/carousel.styles.js.map +1 -1
- app-rn-runtime/components/basic/anchor/anchor.component.js +15 -5
- app-rn-runtime/components/basic/anchor/anchor.component.js.map +1 -1
- app-rn-runtime/components/basic/anchor/anchor.styles.js +3 -0
- app-rn-runtime/components/basic/anchor/anchor.styles.js.map +1 -1
- app-rn-runtime/components/basic/audio/audio.component.js +9 -2
- app-rn-runtime/components/basic/audio/audio.component.js.map +1 -1
- app-rn-runtime/components/basic/audio/audio.styles.js +7 -0
- app-rn-runtime/components/basic/audio/audio.styles.js.map +1 -1
- app-rn-runtime/components/basic/button/button.component.js +15 -2
- app-rn-runtime/components/basic/button/button.component.js.map +1 -1
- app-rn-runtime/components/basic/custom/custom.component.js +1 -1
- app-rn-runtime/components/basic/custom/custom.component.js.map +1 -1
- app-rn-runtime/components/basic/icon/icon.component.js +10 -2
- app-rn-runtime/components/basic/icon/icon.component.js.map +1 -1
- app-rn-runtime/components/basic/label/label.component.js +13 -3
- app-rn-runtime/components/basic/label/label.component.js.map +1 -1
- app-rn-runtime/components/basic/label/label.styles.js.map +1 -1
- app-rn-runtime/components/basic/lottie/lottie.component.js +3 -1
- app-rn-runtime/components/basic/lottie/lottie.component.js.map +1 -1
- app-rn-runtime/components/basic/search/search.component.js +10 -1
- app-rn-runtime/components/basic/search/search.component.js.map +1 -1
- app-rn-runtime/components/basic/search/search.props.js +3 -0
- app-rn-runtime/components/basic/search/search.props.js.map +1 -1
- app-rn-runtime/components/basic/search/search.styles.js +5 -0
- app-rn-runtime/components/basic/search/search.styles.js.map +1 -1
- app-rn-runtime/components/basic/skeleton/skeleton.component.js +6 -3
- app-rn-runtime/components/basic/skeleton/skeleton.component.js.map +1 -1
- app-rn-runtime/components/basic/skeleton/skeleton.props.js +9 -1
- app-rn-runtime/components/basic/skeleton/skeleton.props.js.map +1 -1
- app-rn-runtime/components/basic/video/video.component.js +6 -0
- app-rn-runtime/components/basic/video/video.component.js.map +1 -1
- app-rn-runtime/components/basic/video/video.styles.js +7 -1
- app-rn-runtime/components/basic/video/video.styles.js.map +1 -1
- app-rn-runtime/components/chart/area-chart/area-chart.component.js +2 -1
- app-rn-runtime/components/chart/area-chart/area-chart.component.js.map +1 -1
- app-rn-runtime/components/chart/area-chart/area-chart.styles.js +7 -1
- app-rn-runtime/components/chart/area-chart/area-chart.styles.js.map +1 -1
- app-rn-runtime/components/chart/bar-chart/bar-chart.styles.js +7 -1
- app-rn-runtime/components/chart/bar-chart/bar-chart.styles.js.map +1 -1
- app-rn-runtime/components/chart/basechart.component.js +23 -0
- app-rn-runtime/components/chart/basechart.component.js.map +1 -1
- app-rn-runtime/components/chart/basechart.props.js +2 -2
- app-rn-runtime/components/chart/basechart.props.js.map +1 -1
- app-rn-runtime/components/chart/basechart.styles.js.map +1 -1
- app-rn-runtime/components/chart/bubble-chart/bubble-chart.component.js +1 -1
- app-rn-runtime/components/chart/bubble-chart/bubble-chart.component.js.map +1 -1
- app-rn-runtime/components/chart/bubble-chart/bubble-chart.styles.js +7 -1
- app-rn-runtime/components/chart/bubble-chart/bubble-chart.styles.js.map +1 -1
- app-rn-runtime/components/chart/column-chart/column-chart.styles.js +7 -1
- app-rn-runtime/components/chart/column-chart/column-chart.styles.js.map +1 -1
- app-rn-runtime/components/chart/donut-chart/donut-chart.styles.js +7 -1
- app-rn-runtime/components/chart/donut-chart/donut-chart.styles.js.map +1 -1
- app-rn-runtime/components/chart/line-chart/line-chart.props.js +2 -0
- app-rn-runtime/components/chart/line-chart/line-chart.props.js.map +1 -1
- app-rn-runtime/components/chart/line-chart/line-chart.styles.js +7 -1
- app-rn-runtime/components/chart/line-chart/line-chart.styles.js.map +1 -1
- app-rn-runtime/components/chart/pie-chart/pie-chart.component.js +2 -1
- app-rn-runtime/components/chart/pie-chart/pie-chart.component.js.map +1 -1
- app-rn-runtime/components/chart/pie-chart/pie-chart.styles.js +7 -1
- app-rn-runtime/components/chart/pie-chart/pie-chart.styles.js.map +1 -1
- app-rn-runtime/components/container/accordion/accordion.component.js +58 -11
- app-rn-runtime/components/container/accordion/accordion.component.js.map +1 -1
- app-rn-runtime/components/container/accordion/accordion.props.js.map +1 -1
- app-rn-runtime/components/container/accordion/accordion.styles.js +4 -0
- app-rn-runtime/components/container/accordion/accordion.styles.js.map +1 -1
- app-rn-runtime/components/container/accordion/accordionpane/accordionpane.component.js +11 -1
- app-rn-runtime/components/container/accordion/accordionpane/accordionpane.component.js.map +1 -1
- app-rn-runtime/components/container/container.component.js +44 -3
- 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/container.styles.js +7 -0
- app-rn-runtime/components/container/container.styles.js.map +1 -1
- app-rn-runtime/components/container/layoutgrid/gridrow/gridrow.component.js +5 -1
- app-rn-runtime/components/container/layoutgrid/gridrow/gridrow.component.js.map +1 -1
- app-rn-runtime/components/container/layoutgrid/gridrow/gridrow.styles.js +6 -1
- app-rn-runtime/components/container/layoutgrid/gridrow/gridrow.styles.js.map +1 -1
- app-rn-runtime/components/container/layoutgrid/layoutgrid.component.js +28 -2
- 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 +4 -1
- app-rn-runtime/components/container/layoutgrid/layoutgrid.styles.js.map +1 -1
- app-rn-runtime/components/container/linearlayout/linearlayout.component.js +31 -5
- 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/linearlayout.styles.js +4 -1
- app-rn-runtime/components/container/linearlayout/linearlayout.styles.js.map +1 -1
- app-rn-runtime/components/container/panel/panel.component.js +43 -4
- 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 +3 -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 +2 -2
- app-rn-runtime/components/container/tabs/tabheader/tabheader.component.js.map +1 -1
- app-rn-runtime/components/container/tabs/tabpane/tabpane.component.js +11 -1
- app-rn-runtime/components/container/tabs/tabpane/tabpane.component.js.map +1 -1
- app-rn-runtime/components/container/tabs/tabpane/tabpane.props.js +1 -0
- app-rn-runtime/components/container/tabs/tabpane/tabpane.props.js.map +1 -1
- app-rn-runtime/components/container/tabs/tabs.component.js +41 -6
- app-rn-runtime/components/container/tabs/tabs.component.js.map +1 -1
- app-rn-runtime/components/container/tabs/tabs.styles.js +4 -1
- app-rn-runtime/components/container/tabs/tabs.styles.js.map +1 -1
- app-rn-runtime/components/container/tile/tile.component.js +28 -2
- 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 +6 -1
- app-rn-runtime/components/container/tile/tile.styles.js.map +1 -1
- app-rn-runtime/components/container/wizard/wizard.component.js +39 -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 +3 -0
- app-rn-runtime/components/container/wizard/wizard.styles.js.map +1 -1
- app-rn-runtime/components/container/wizard/wizardstep/wizardstep.component.js +8 -1
- app-rn-runtime/components/container/wizard/wizardstep/wizardstep.component.js.map +1 -1
- app-rn-runtime/components/data/card/card-content/card-content.component.js +6 -2
- 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.styles.js +4 -1
- app-rn-runtime/components/data/card/card-content/card-content.styles.js.map +1 -1
- app-rn-runtime/components/data/card/card.component.js +18 -0
- app-rn-runtime/components/data/card/card.component.js.map +1 -1
- app-rn-runtime/components/data/card/card.styles.js +3 -0
- app-rn-runtime/components/data/card/card.styles.js.map +1 -1
- app-rn-runtime/components/data/form/form-field/form-field.component.js +2 -1
- app-rn-runtime/components/data/form/form-field/form-field.component.js.map +1 -1
- app-rn-runtime/components/data/form/form.component.js +1 -1
- app-rn-runtime/components/data/form/form.component.js.map +1 -1
- app-rn-runtime/components/data/form/form.props.js +1 -0
- app-rn-runtime/components/data/form/form.props.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.props.js +1 -0
- 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 +11 -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 +32 -24
- app-rn-runtime/components/data/list/list.component.js.map +1 -1
- app-rn-runtime/components/data/list/list.props.js +1 -0
- app-rn-runtime/components/data/list/list.props.js.map +1 -1
- app-rn-runtime/components/data/list/list.styles.js +9 -0
- app-rn-runtime/components/data/list/list.styles.js.map +1 -1
- app-rn-runtime/components/dialogs/dialog/dialog.styles.js.map +1 -1
- app-rn-runtime/components/input/baseinput/baseinput.component.js +46 -10
- app-rn-runtime/components/input/baseinput/baseinput.component.js.map +1 -1
- app-rn-runtime/components/input/basenumber/basenumber.component.js +19 -6
- app-rn-runtime/components/input/basenumber/basenumber.component.js.map +1 -1
- app-rn-runtime/components/input/calendar/calendar.component.js +25 -0
- app-rn-runtime/components/input/calendar/calendar.component.js.map +1 -1
- app-rn-runtime/components/input/calendar/calendar.styles.js +19 -0
- app-rn-runtime/components/input/calendar/calendar.styles.js.map +1 -1
- app-rn-runtime/components/input/checkbox/checkbox.component.js +23 -3
- app-rn-runtime/components/input/checkbox/checkbox.component.js.map +1 -1
- app-rn-runtime/components/input/checkbox/checkbox.styles.js +19 -2
- app-rn-runtime/components/input/checkbox/checkbox.styles.js.map +1 -1
- app-rn-runtime/components/input/checkboxset/checkboxset.component.js +21 -1
- app-rn-runtime/components/input/checkboxset/checkboxset.component.js.map +1 -1
- app-rn-runtime/components/input/checkboxset/checkboxset.props.js +1 -0
- app-rn-runtime/components/input/checkboxset/checkboxset.props.js.map +1 -1
- app-rn-runtime/components/input/checkboxset/checkboxset.styles.js +1 -0
- app-rn-runtime/components/input/checkboxset/checkboxset.styles.js.map +1 -1
- app-rn-runtime/components/input/chips/chips.component.js +16 -2
- app-rn-runtime/components/input/chips/chips.component.js.map +1 -1
- app-rn-runtime/components/input/chips/chips.styles.js +8 -0
- app-rn-runtime/components/input/chips/chips.styles.js.map +1 -1
- app-rn-runtime/components/input/currency/currency.component.js +14 -4
- app-rn-runtime/components/input/currency/currency.component.js.map +1 -1
- app-rn-runtime/components/input/currency/currency.styles.js +43 -1
- app-rn-runtime/components/input/currency/currency.styles.js.map +1 -1
- app-rn-runtime/components/input/epoch/base-datetime.component.js +26 -5
- app-rn-runtime/components/input/epoch/base-datetime.component.js.map +1 -1
- app-rn-runtime/components/input/epoch/datetime/datetime.props.js +6 -0
- app-rn-runtime/components/input/epoch/datetime/datetime.props.js.map +1 -1
- app-rn-runtime/components/input/epoch/datetime/datetime.styles.js +13 -0
- app-rn-runtime/components/input/epoch/datetime/datetime.styles.js.map +1 -1
- app-rn-runtime/components/input/epoch/wheelpickermodal/date/date-picker-modal.component.js +7 -4
- app-rn-runtime/components/input/epoch/wheelpickermodal/date/date-picker-modal.component.js.map +1 -1
- app-rn-runtime/components/input/epoch/wheelpickermodal/date/date-picker-modal.props.js +3 -0
- app-rn-runtime/components/input/epoch/wheelpickermodal/date/date-picker-modal.props.js.map +1 -1
- app-rn-runtime/components/input/epoch/wheelpickermodal/time/time-picker-modal.component.js +7 -4
- app-rn-runtime/components/input/epoch/wheelpickermodal/time/time-picker-modal.component.js.map +1 -1
- app-rn-runtime/components/input/epoch/wheelpickermodal/time/time-picker-modal.props.js +3 -0
- app-rn-runtime/components/input/epoch/wheelpickermodal/time/time-picker-modal.props.js.map +1 -1
- app-rn-runtime/components/input/number/number.component.js +17 -3
- app-rn-runtime/components/input/number/number.component.js.map +1 -1
- app-rn-runtime/components/input/number/number.styles.js +24 -1
- app-rn-runtime/components/input/number/number.styles.js.map +1 -1
- app-rn-runtime/components/input/radioset/radioset.component.js +33 -8
- app-rn-runtime/components/input/radioset/radioset.component.js.map +1 -1
- app-rn-runtime/components/input/radioset/radioset.props.js +2 -0
- app-rn-runtime/components/input/radioset/radioset.props.js.map +1 -1
- app-rn-runtime/components/input/radioset/radioset.styles.js +7 -0
- app-rn-runtime/components/input/radioset/radioset.styles.js.map +1 -1
- app-rn-runtime/components/input/select/select.component.js +11 -3
- app-rn-runtime/components/input/select/select.component.js.map +1 -1
- app-rn-runtime/components/input/select/select.styles.js +24 -0
- app-rn-runtime/components/input/select/select.styles.js.map +1 -1
- app-rn-runtime/components/input/switch/switch.component.js +13 -3
- app-rn-runtime/components/input/switch/switch.component.js.map +1 -1
- app-rn-runtime/components/input/switch/switch.styles.js +15 -0
- app-rn-runtime/components/input/switch/switch.styles.js.map +1 -1
- app-rn-runtime/components/input/text/text.component.js +26 -2
- app-rn-runtime/components/input/text/text.component.js.map +1 -1
- app-rn-runtime/components/input/text/text.props.js +3 -0
- app-rn-runtime/components/input/text/text.props.js.map +1 -1
- app-rn-runtime/components/input/text/text.styles.js +3 -0
- app-rn-runtime/components/input/text/text.styles.js.map +1 -1
- app-rn-runtime/components/input/textarea/textarea.component.js +24 -1
- app-rn-runtime/components/input/textarea/textarea.component.js.map +1 -1
- app-rn-runtime/components/input/textarea/textarea.props.js +2 -0
- app-rn-runtime/components/input/textarea/textarea.props.js.map +1 -1
- app-rn-runtime/components/input/textarea/textarea.styles.js +3 -0
- app-rn-runtime/components/input/textarea/textarea.styles.js.map +1 -1
- app-rn-runtime/components/input/toggle/toggle.component.js +6 -0
- app-rn-runtime/components/input/toggle/toggle.component.js.map +1 -1
- app-rn-runtime/components/input/toggle/toggle.props.js +2 -0
- app-rn-runtime/components/input/toggle/toggle.props.js.map +1 -1
- app-rn-runtime/components/input/toggle/toggle.styles.js +7 -0
- app-rn-runtime/components/input/toggle/toggle.styles.js.map +1 -1
- app-rn-runtime/components/navigation/popover/popover.component.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 +4 -1
- app-rn-runtime/components/page/left-panel/left-panel.component.js.map +1 -1
- app-rn-runtime/components/page/page-content/page-content.component.js +70 -14
- 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 +2 -2
- app-rn-runtime/components/page/page-content/page-content.props.js.map +1 -1
- app-rn-runtime/components/page/page-content/page-content.styles.js +6 -1
- app-rn-runtime/components/page/page-content/page-content.styles.js.map +1 -1
- app-rn-runtime/components/page/page.component.js.map +1 -1
- app-rn-runtime/components/page/page.props.js.map +1 -1
- app-rn-runtime/components/page/page.styles.js +7 -1
- app-rn-runtime/components/page/page.styles.js.map +1 -1
- app-rn-runtime/components/page/partial/partial.component.js +27 -1
- app-rn-runtime/components/page/partial/partial.component.js.map +1 -1
- app-rn-runtime/components/page/partial/partial.props.js.map +1 -1
- app-rn-runtime/components/page/partial/partial.styles.js +6 -1
- app-rn-runtime/components/page/partial/partial.styles.js.map +1 -1
- app-rn-runtime/components/prefab/prefab-container.component.js +27 -1
- app-rn-runtime/components/prefab/prefab-container.component.js.map +1 -1
- app-rn-runtime/components/prefab/prefab-container.props.js.map +1 -1
- app-rn-runtime/components/prefab/prefab-container.styles.js +6 -1
- app-rn-runtime/components/prefab/prefab-container.styles.js.map +1 -1
- app-rn-runtime/core/AppConfig.js.map +1 -1
- app-rn-runtime/core/base.component.js +33 -6
- app-rn-runtime/core/base.component.js.map +1 -1
- app-rn-runtime/core/components/textinput.component.js +9 -7
- app-rn-runtime/core/components/textinput.component.js.map +1 -1
- app-rn-runtime/core/props.provider.js +0 -1
- app-rn-runtime/core/props.provider.js.map +1 -1
- app-rn-runtime/core/storage.service.js +15 -0
- app-rn-runtime/core/storage.service.js.map +1 -1
- app-rn-runtime/core/tappable.component.js +10 -4
- app-rn-runtime/core/tappable.component.js.map +1 -1
- app-rn-runtime/core/utils.js +5 -0
- app-rn-runtime/core/utils.js.map +1 -1
- app-rn-runtime/core/wm-component-tree.js +58 -0
- app-rn-runtime/core/wm-component-tree.js.map +1 -0
- app-rn-runtime/package.json +13 -6
- app-rn-runtime/runtime/App.js +23 -9
- app-rn-runtime/runtime/App.js.map +1 -1
- app-rn-runtime/runtime/App.navigator.js +1 -0
- app-rn-runtime/runtime/App.navigator.js.map +1 -1
- app-rn-runtime/runtime/base-fragment.component.js +46 -13
- app-rn-runtime/runtime/base-fragment.component.js.map +1 -1
- app-rn-runtime/runtime/base-page.component.js +38 -2
- app-rn-runtime/runtime/base-page.component.js.map +1 -1
- app-rn-runtime/runtime/base-partial.component.js +3 -0
- app-rn-runtime/runtime/base-partial.component.js.map +1 -1
- app-rn-runtime/runtime/base-prefab.component.js.map +1 -1
- app-rn-runtime/runtime/navigator/drawer.navigator.js +19 -10
- app-rn-runtime/runtime/navigator/drawer.navigator.js.map +1 -1
- app-rn-runtime/runtime/services/app-modal.service.js +4 -4
- app-rn-runtime/runtime/services/app-modal.service.js.map +1 -1
- app-rn-runtime/runtime/services/app-security.service.js +17 -1
- app-rn-runtime/runtime/services/app-security.service.js.map +1 -1
- app-rn-runtime/styles/theme.js +10 -0
- app-rn-runtime/styles/theme.js.map +1 -1
- app-rn-runtime/styles/theme.variables.js +2 -1
- app-rn-runtime/styles/theme.variables.js.map +1 -1
- app-rn-runtime/variables/http.service.js +5 -1
- app-rn-runtime/variables/http.service.js.map +1 -1
- app-rn-runtime/variables/live-variable.js +14 -0
- app-rn-runtime/variables/live-variable.js.map +1 -1
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"names":["React","ActivityIndicator","SectionList","Text","View","FlatList","isArray","isEmpty","isNil","isNumber","round","BaseComponent","BaseComponentState","getGroupedData","isDefined","Tappable","DefaultKeyExtractor","WmLabel","WmIcon","Swipeable","WmListProps","DEFAULT_CLASS","WmListState","constructor","args","_defineProperty","WmList","props","leftActionTemplate","createElement","Fragment","getTemplate","rightActionTemplate","updateState","maxRecordsToShow","state","pagesize","isSelected","$item","selectedItem","selecteditem","indexOf","onSelect","$index","$event","eventName","disableitem","multiselect","index","selectionlimit","length","push","invokeEventCallback","splice","proxy","selectedItemWidgets","itemWidgets","Promise","resolve","selectedindex","loadDataOnDemand","navigation","loadData","loadingData","dataset","setTimeout","$list","loadingdata","getNextPageData","currentPage","then","data","hasMoreData","catch","err","console","error","selectFirstItem","initialized","groupby","clear","groupedData","selectItem","item","getItem","deselect","selectedItemIndex","getWidgets","widgetname","map","filter","widget","undefined","deselectAll","setGroupData","items","dataItems","match","orderby","dateformat","_this$keyExtractor","keyExtractor","onPropertyChange","name","$new","$old","orderbyData","key","_this$keyExtractor2","direction","_this$keyExtractor3","selectfirstitem","pop","componentDidMount","_props$dataset","subscribe","event","scrollPosition","nativeEvent","contentOffset","y","layoutMeasurement","height","endThreshold","componentDidUpdate","prevProps","prevState","snapshot","getDefaultStyles","isHorizontal","theme","getStyle","defaultClass","getIndex","generateItemKey","itemkey","_showSkeleton","getKey","renderItem","cols","getNoOfColumns","renderLeftActions","renderRightActions","containerStyle","width","flex","style","styles","itemclass","_extends","getTestPropsForAction","onTap","onLongTap","onDoubleTap","display","flexDirection","paddingRight","marginRight","margin","id","getTestId","iconclass","selectedIcon","renderHeader","title","groupHeading","accessibilityRole","subheading","heading","listIcon","caption","accessibilityrole","renderEmptyMessage","emptyMessage","nodatamessage","renderLoadingIcon","loadingicon","loadingIcon","loadingdatamsg","color","text","itemsperrow","xs","onLayoutChange","e","l","layout","renderWithFlatList","root","onLayout","v","i","group","scrollEnabled","horizontal","ListEmptyComponent","itemInfo","numColumns","onDemandMessage","ondemandmessage","getSectionListData","renderWithSectionList","contentContainerStyle","sections","renderSectionHeader","section","renderSectionFooter","renderWidget","_background"],"sources":["list.component.tsx"],"sourcesContent":["import React from 'react';\nimport { ActivityIndicator, SectionList, Text, View, FlatList, LayoutChangeEvent, TouchableOpacity} from 'react-native';\nimport { isArray, isEmpty, isNil, isNumber, round } from 'lodash-es';\nimport { BaseComponent, BaseComponentState } from '@wavemaker/app-rn-runtime/core/base.component';\nimport {getGroupedData, isDefined} from \"@wavemaker/app-rn-runtime/core/utils\";\nimport { Tappable } from '@wavemaker/app-rn-runtime/core/tappable.component';\nimport { DefaultKeyExtractor } from '@wavemaker/app-rn-runtime/core/key.extractor';\nimport WmLabel from '@wavemaker/app-rn-runtime/components/basic/label/label.component';\nimport WmIcon from '@wavemaker/app-rn-runtime/components/basic/icon/icon.component';\nimport { Swipeable } from 'react-native-gesture-handler';\nimport WmListActionTemplate from './list-action-template/list-action-template.component';\n\nimport WmListProps from './list.props';\nimport { DEFAULT_CLASS, WmListStyles } from './list.styles';\n\n\nexport class WmListState extends BaseComponentState<WmListProps> {\n public selectedindex: any;\n groupedData: Array<any> = [];\n currentPage = 1;\n maxRecordsToShow = 20;\n}\n\nexport default class WmList extends BaseComponent<WmListProps, WmListState, WmListStyles> {\n\n private itemWidgets = [] as any[];\n private selectedItemWidgets = {} as any;\n private keyExtractor = new DefaultKeyExtractor();\n private endThreshold = -1;\n private loadingData = false;\n private hasMoreData = true;\n public leftActionTemplate?: WmListActionTemplate;\n public rightActionTemplate?: WmListActionTemplate;\n\n constructor(props: WmListProps) {\n super(props, DEFAULT_CLASS, new WmListProps(), new WmListState());\n this.updateState({\n maxRecordsToShow: this.state.props.pagesize\n } as WmListState);\n }\n\n private isSelected($item: any) {\n const selectedItem = this.state.props.selecteditem;\n if (isArray(selectedItem)) {\n return selectedItem.indexOf($item) >= 0;\n }\n return selectedItem === $item;\n }\n\n private async onSelect($item: any, $index: number | string, $event?: any) {\n const props = this.state.props;\n let selectedItem = null as any;\n let eventName = 'onSelect';\n if (props.disableitem !== true\n && (typeof props.disableitem !== 'function' || !props.disableitem($item, $index))) {\n if (props.multiselect) {\n selectedItem = [...(props.selecteditem || [])];\n const index = selectedItem.indexOf($item);\n if (index < 0) {\n if ((!props.selectionlimit)\n || props.selectionlimit < 0\n || selectedItem.length < props.selectionlimit) {\n selectedItem.push($item);\n } else {\n this.invokeEventCallback('onSelectionlimitexceed', [null, this]);\n }\n } else {\n selectedItem.splice(index, 1);\n eventName = 'onDeselect';\n }\n } else {\n this.state.props.selecteditem && this.invokeEventCallback('onDeselect', [this.proxy, this.state.props.selecteditem]);\n selectedItem = $item;\n }\n this.selectedItemWidgets = this.itemWidgets[$index as number];\n return new Promise(resolve => {\n this.updateState({\n props: { selecteditem: selectedItem },\n selectedindex: $index\n } as WmListState, () => {\n this.invokeEventCallback(eventName, [this.proxy, $item]);\n $event && this.invokeEventCallback('onTap', [$event, this.proxy]);\n resolve(null);\n });\n });\n } else {\n return Promise.resolve(null);\n }\n }\n\n private get loadDataOnDemand() {\n const navigation = this.state.props.navigation;\n return navigation === 'Scroll' || navigation === 'On-Demand';\n }\n\n renderLeftActions = () => {\n return this.leftActionTemplate ? (\n <>\n {this.leftActionTemplate.getTemplate()}\n </>\n ) : null;\n };\n\n renderRightActions = () => {\n return this.rightActionTemplate ? (\n <>\n {this.rightActionTemplate.getTemplate()}\n </>\n ) : null;\n };\n\n private loadData() {\n if (this.loadingData) {\n return;\n }\n if (isArray(this.state.props.dataset)\n && this.state.props.dataset.length > this.state.maxRecordsToShow) {\n this.loadingData = true;\n this.updateState({\n maxRecordsToShow: this.state.maxRecordsToShow + this.state.props.pagesize\n } as WmListState);\n setTimeout(() => {\n this.loadingData = false;\n }, 100);\n } else if (this.loadDataOnDemand) {\n const $list = this.proxy as any;\n $list.loadingdata = true;\n this.loadingData = true;\n this.props.getNextPageData && this.props.getNextPageData(null, this.proxy, this.state.currentPage + 1).then((data) => {\n if (isArray(data) && data.length > 0\n && isArray(this.state.props.dataset)) {\n $list.dataset = [...this.state.props.dataset, ...data];\n this.updateState({\n currentPage : this.state.currentPage + 1,\n maxRecordsToShow: this.state.maxRecordsToShow + this.state.props.pagesize\n } as WmListState);\n this.hasMoreData = true;\n } else {\n this.hasMoreData = false;\n }\n }).catch((err) => {\n console.error(err);\n }).then(() => {\n setTimeout(() => {\n $list.loadingdata = false;\n }, 1000);\n });\n }\n }\n\n private selectFirstItem() {\n const props = this.state.props;\n if (this.initialized\n && props.dataset\n && props.dataset.length) {\n const index = props.groupby ? '00': 0;\n this.onSelect(props.dataset[0], index);\n }\n }\n\n clear(){\n this.updateState({\n groupedData: {},\n } as WmListState);\n }\n\n selectItem(item: any){\n const dataset = this.state.props.dataset;\n if(isNumber(item)){\n this.onSelect(dataset[item], item);\n }\n else{\n let index = dataset.indexOf(item);\n this.onSelect(dataset[index], index);\n }\n }\n\n getItem(index: number){\n const props = this.state.props;\n return this.props.dataset[index]\n }\n\n deselect(item: any){\n const props = this.state.props;\n let selectedItem = null as any;\n let index = isNumber(item)?item:props.dataset.indexOf(item);\n if(props.multiselect && index >= 0){\n selectedItem = [...(props.selecteditem || [])];\n let selectedItemIndex = selectedItem.indexOf(props.dataset[index])\n if(selectedItemIndex >= 0){\n selectedItem.splice(selectedItemIndex, 1);\n }\n }\n else{\n if (props.selecteditem === props.dataset[index]) {\n selectedItem = null;\n }\n }\n this.updateState({\n props: { selecteditem: selectedItem },\n\n } as WmListState, () => {\n this.invokeEventCallback('onDeselect', [this.proxy, item]);\n });\n }\n\n getWidgets(widgetname: string, index: number){\n if(index >= 0 && index < this.itemWidgets.length){\n return this.itemWidgets[index][widgetname]\n }\n else{\n return this.itemWidgets.map(item => item[widgetname]).filter(widget => widget !== undefined);\n }\n }\n\n private deselectAll() {\n this.updateState({\n props: { selecteditem: null },\n selectedindex: -1\n } as WmListState);\n }\n\n setGroupData(items: any) {\n const dataItems = items;\n const props = this.state.props;\n if (props.groupby) {\n const groupedData = dataItems && getGroupedData(dataItems, props.groupby, props.match, props.orderby, props.dateformat, this);\n this.updateState({\n groupedData: groupedData\n } as WmListState, () => {\n this.keyExtractor?.clear();\n });\n }\n }\n\n public onPropertyChange(name: string, $new: any, $old: any) {\n super.onPropertyChange(name, $new, $old);\n const props = this.state.props;\n switch(name) {\n case 'selectfirstitem':\n if ($new) {\n this.selectFirstItem();\n }\n break;\n case 'dataset':\n if (this.state.props.groupby) {\n this.setGroupData($new);\n } else {\n if (!($old && $old.length)\n && $new && $new.length\n && this.loadDataOnDemand) {\n this.updateState({\n props: {\n dataset: [...$new]\n }\n } as WmListState);\n }\n const data = isArray($new) ? $new : (!isEmpty($new) && isDefined($new) ? [$new] : []);\n if(props.orderby) {\n const orderbyData = data && getGroupedData(data, props.groupby, props.match, props.orderby, props.dateformat, this);\n this.updateState({\n groupedData: (orderbyData[0] ? [{\n key: 'key',\n data: orderbyData[0].data\n }] : [])\n } as WmListState, () => {\n this.keyExtractor?.clear();\n });\n } else {\n this.updateState({\n groupedData: (data[0] || props.direction === 'horizontal' ? [{\n key: 'key',\n data: data\n }] : [])\n } as WmListState, () => {\n this.keyExtractor?.clear();\n });\n }\n }\n this.itemWidgets = [];\n if (props.selectfirstitem) {\n this.selectFirstItem();\n } else {\n this.deselectAll();\n }\n break;\n case 'groupby':\n case 'match':\n this.setGroupData(this.state.props.dataset);\n break;\n case 'multiselect':\n if ($new) {\n if (!isArray(this.state.props.selecteditem)) {\n this.state.props.selecteditem = this.state.props.selecteditem ?\n [this.state.props.selecteditem] : [];\n }\n } else if (isArray(this.state.props.selecteditem)) {\n this.state.props.selecteditem = this.state.props.selecteditem.pop();\n }\n break;\n case 'loadingdata':\n this.loadingData = $new && this.loadingData;\n break;\n case 'selecteditem':\n if($new != $old && isNumber($new)) {\n this.selectItem(this.state.props.dataset[$new])\n }\n break;\n }\n }\n\n componentDidMount() {\n const props = this.state.props;\n if (this.state.props.selectfirstitem && props.dataset?.length) {\n setTimeout(() => {\n this.onSelect(props.dataset[0], 0);\n });\n }\n this.subscribe('scroll', (event: any) => {\n const scrollPosition = event.nativeEvent.contentOffset.y + event.nativeEvent.layoutMeasurement.height;\n if (scrollPosition > this.endThreshold && this.state.props.direction === 'vertical') {\n this.loadData();\n }\n });\n super.componentDidMount();\n }\n\n componentDidUpdate(prevProps: WmListProps, prevState: WmListState, snapshot?: any) {\n super.componentDidUpdate && super.componentDidUpdate(prevProps, prevState, snapshot);\n this.invokeEventCallback('onRender', [this, this.state.props.dataset]);\n }\n\n getDefaultStyles() {\n const isHorizontal = this.state.props.direction === 'horizontal';\n return this.theme.getStyle(`${this.defaultClass} ${isHorizontal ? 'app-horizontal-list' : 'app-vertical-list'}`);\n }\n\n getIndex(item: any) {\n return this.state.props.dataset.indexOf(item);\n }\n\n private generateItemKey(item: any, index: number, props: WmListProps) {\n if (props.itemkey && item && !this._showSkeleton) {\n return props.itemkey(item, index);\n }\n return 'list_item_' + this.keyExtractor.getKey(item, true);\n }\n\n private renderItem(item: any, index: number, props: WmListProps) {\n const cols = this. getNoOfColumns();\n const isHorizontal = (props.direction === 'horizontal');\n return (index < this.state.maxRecordsToShow || isHorizontal) ? (\n <Swipeable\n renderLeftActions={() => this.renderLeftActions()}\n renderRightActions={() => this.renderRightActions()} containerStyle={ cols ? { width: round(100/cols) + \"%\" , flex: null } as any :{}}>\n <View style={[\n this.styles.item,\n props.itemclass ? this.theme.getStyle(props.itemclass(item, index)) : null,\n this.isSelected(item) ? this.styles.selectedItem : {}]}>\n <Tappable\n {...this.getTestPropsForAction(`item${index}`)}\n onTap={($event) => this.onSelect(item, index, $event)}\n onLongTap={() => this.invokeEventCallback('onLongtap', [null, this.proxy])}\n onDoubleTap={() => this.invokeEventCallback('onDoubletap', [null, this.proxy])}\n styles={\n [{display: 'flex', flexDirection : 'row'},\n cols ? {\n width: '100%'\n } : null,\n (cols && cols > 1) || isHorizontal ? {\n paddingRight: (isNil(this.styles.item.marginRight)\n ? this.styles.item.margin : this.styles.item.marginRight) || 4\n } : null\n ]\n }>\n {props.renderItem(item, index, this)}\n {this.isSelected(item) ? (\n <WmIcon id={this.getTestId('icon' + index)} iconclass='wi wi-check-circle' styles={this.styles.selectedIcon} />\n ) : null}\n </Tappable>\n </View>\n </Swipeable>\n ) : null;\n }\n\n private renderHeader(props: WmListProps, title: string) {\n return props.groupby ? (\n <Text style={this.styles.groupHeading} accessibilityRole='header'>{title}</Text>\n ) : (props.iconclass || props.title || props.subheading) ? (\n <View style={this.styles.heading}>\n <View style={{flex: 1, flexDirection: 'row'}}>\n <WmIcon id={this.getTestId('icon')} styles={this.styles.listIcon} iconclass={props.iconclass}></WmIcon>\n <View>\n <WmLabel id={this.getTestId('title')} styles={this.styles.title} caption={props.title} accessibilityrole='header'></WmLabel>\n <WmLabel id={this.getTestId('subheading')} styles={this.styles.subheading} caption={props.subheading}></WmLabel>\n </View>\n </View>\n </View>) : null;\n }\n\n private renderEmptyMessage(isHorizontal: boolean, item: any, index: any, props: WmListProps) {\n return (<WmLabel id={this.getTestId('emptymsg')} styles={this.styles.emptyMessage} caption={props.nodatamessage}></WmLabel>);\n }\n\n private renderLoadingIcon(props: WmListProps) {\n return props.loadingicon ? (<WmIcon\n id={this.getTestId('loadingicon')}\n styles={this.styles.loadingIcon}\n iconclass={props.loadingicon}\n caption={props.loadingdatamsg}></WmIcon>)\n : (\n <ActivityIndicator color={this.styles.loadingIcon.text.color}></ActivityIndicator>\n );\n }\n\n public getNoOfColumns() {\n const props = this.state.props;\n if(props.direction === 'vertical') {\n return props.itemsperrow.xs;\n }\n return 0;\n }\n\n private onLayoutChange(e: LayoutChangeEvent) {\n const l = e.nativeEvent.layout;\n this.endThreshold = l.height + l.y - 100;\n if (!this.endThreshold) {\n this.endThreshold = -1;\n }\n }\n\n private renderWithFlatList(props: WmListProps, isHorizontal = false) {\n return (\n <View style={this.styles.root} onLayout={e => this.onLayoutChange(e)}>\n {!isEmpty(this.state.groupedData) ? this.state.groupedData.map((v: any, i) => ((\n <View style={this.styles.group} key={v.key || this.keyExtractor.getKey(v, true)}>\n {this.renderHeader(props, v.key)}\n <FlatList\n key={props.name + '_' + (isHorizontal ? 'H' : 'V') + props.itemsperrow.xs}\n keyExtractor={(item, i) => this.generateItemKey(item, i, props)}\n scrollEnabled={isHorizontal}\n horizontal = {isHorizontal}\n data={isEmpty(v.data[0]) ? []: v.data}\n ListEmptyComponent = {(itemInfo) => this.renderEmptyMessage(isHorizontal, itemInfo.item, itemInfo.index, props)}\n renderItem={(itemInfo) => this.renderItem(itemInfo.item, itemInfo.index, props)}\n {...(isHorizontal ? {} : {numColumns : this.getNoOfColumns()})}>\n </FlatList>\n {this.loadDataOnDemand || (v.data.length > this.state.maxRecordsToShow) ?\n (this.loadingData ?\n this.renderLoadingIcon(props) :\n (<WmLabel id={this.getTestId('ondemandmessage')}\n styles={this.styles.onDemandMessage}\n caption={this.hasMoreData && !isHorizontal ? props.ondemandmessage : props.nodatamessage}\n onTap={() => this.loadData()}></WmLabel>))\n : null}\n </View>\n ))) : this.renderEmptyMessage(isHorizontal, null, null,props)\n }\n </View>);\n }\n\n private getSectionListData() {\n if (this._showSkeleton) {\n return [{\n key: '',\n data: [{}, {}, {}]\n }];\n } else if (this.state.groupedData\n && this.state.groupedData[0]\n && this.state.groupedData[0]['data'].length) {\n return this.state.groupedData;\n }\n return [];\n }\n\n private renderWithSectionList(props: WmListProps, isHorizontal = false) {\n return (\n <SectionList\n keyExtractor={(item, i) => this.generateItemKey(item, i, props)}\n horizontal = {isHorizontal}\n contentContainerStyle={this.styles.root}\n sections={this.getSectionListData()}\n renderSectionHeader={({ section: {key, data}}) => {\n return this.renderHeader(props, key);\n }}\n renderSectionFooter={() => props.loadingdata ? this.renderLoadingIcon(props) : null}\n ListEmptyComponent = {(itemInfo) => this.renderEmptyMessage(isHorizontal, itemInfo.item, itemInfo.index, props)}\n renderItem={(itemInfo) => this.renderItem(itemInfo.item, itemInfo.index, props)}>\n </SectionList>\n );\n }\n\n renderWidget(props: WmListProps) {\n this.invokeEventCallback('onBeforedatarender', [this, this.state.props.dataset]);\n const isHorizontal = (props.direction === 'horizontal');\n return (\n <View style={isHorizontal ? null : { width: '100%' }}>\n {this._background}\n {(isHorizontal || !props.groupby) ?\n this.renderWithFlatList(props, isHorizontal)\n : this.renderWithSectionList(props, isHorizontal)}\n </View>);\n }\n}\n"],"mappings":";;;;AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,SAASC,iBAAiB,EAAEC,WAAW,EAAEC,IAAI,EAAEC,IAAI,EAAEC,QAAQ,QAA4C,cAAc;AACvH,SAASC,OAAO,EAAEC,OAAO,EAAEC,KAAK,EAAEC,QAAQ,EAAEC,KAAK,QAAQ,WAAW;AACpE,SAASC,aAAa,EAAEC,kBAAkB,QAAQ,+CAA+C;AACjG,SAAQC,cAAc,EAAEC,SAAS,QAAO,sCAAsC;AAC9E,SAASC,QAAQ,QAAQ,mDAAmD;AAC5E,SAASC,mBAAmB,QAAQ,8CAA8C;AAClF,OAAOC,OAAO,MAAM,kEAAkE;AACtF,OAAOC,MAAM,MAAM,gEAAgE;AACnF,SAASC,SAAS,QAAQ,8BAA8B;AAGxD,OAAOC,WAAW,MAAM,cAAc;AACtC,SAASC,aAAa,QAAsB,eAAe;AAG3D,OAAO,MAAMC,WAAW,SAASV,kBAAkB,CAAc;EAAAW,YAAA,GAAAC,IAAA;IAAA,SAAAA,IAAA;IAAAC,eAAA;IAAAA,eAAA,sBAErC,EAAE;IAAAA,eAAA,sBACd,CAAC;IAAAA,eAAA,2BACI,EAAE;EAAA;AACvB;AAEA,eAAe,MAAM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CAAE;MAChH+G,UAAU,EAAG0D,QAAQ,IAAK,IAAI,CAAC1D,UAAU,CAAC0D,QAAQ,CAACjH,IAAI,EAAEiH,QAAQ,CAACpJ,KAAK,EAAErB,KAAK;IAAE,CACrE,CAAC;EAElB;EAEAoL,YAAYA,CAACpL,KAAkB,EAAE;IAC/B,IAAI,CAACyB,mBAAmB,CAAC,oBAAoB,EAAE,CAAC,IAAI,EAAE,IAAI,CAACjB,KAAK,CAACR,KAAK,CAACqC,OAAO,CAAC,CAAC;IAChF,MAAMiE,YAAY,GAAItG,KAAK,CAACkF,SAAS,KAAK,YAAa;IACvD,oBACI7G,KAAA,CAAA6B,aAAA,CAACzB,IAAI;MAAC8I,KAAK,EAAEjB,YAAY,GAAG,IAAI,GAAG;QAAEe,KAAK,EAAE;MAAO;IAAE,GAClD,IAAI,CAACgE,WAAW,EACf/E,YAAY,IAAI,CAACtG,KAAK,CAACoD,OAAO,GAC9B,IAAI,CAAC4G,kBAAkB,CAAChK,KAAK,EAAEsG,YAAY,CAAC,GAC5C,IAAI,CAACwE,qBAAqB,CAAC9K,KAAK,EAAEsG,YAAY,CAC9C,CAAC;EACX;AACF","ignoreList":[]}
|
1
|
+
{"version":3,"names":["React","ActivityIndicator","SectionList","Text","View","FlatList","isArray","isEmpty","isNil","isNumber","round","BaseComponent","BaseComponentState","getGroupedData","getNumberOfEmptyObjects","isDefined","Tappable","DefaultKeyExtractor","WmLabel","WmIcon","Swipeable","WmListProps","DEFAULT_CLASS","WmListState","constructor","args","_defineProperty","WmList","props","leftActionTemplate","createElement","Fragment","getTemplate","rightActionTemplate","updateState","maxRecordsToShow","state","pagesize","isSelected","$item","selectedItem","selecteditem","indexOf","onSelect","$index","$event","eventName","disableitem","multiselect","index","selectionlimit","length","push","invokeEventCallback","splice","proxy","selectedItemWidgets","itemWidgets","Promise","resolve","selectedindex","loadDataOnDemand","navigation","loadData","loadingData","dataset","setTimeout","$list","loadingdata","getNextPageData","currentPage","then","data","hasMoreData","catch","err","console","error","selectFirstItem","initialized","groupby","clear","groupedData","selectItem","item","getItem","deselect","selectedItemIndex","getWidgets","widgetname","map","filter","widget","undefined","deselectAll","setGroupData","items","dataItems","match","orderby","dateformat","_this$keyExtractor","keyExtractor","onPropertyChange","name","$new","$old","orderbyData","key","_this$keyExtractor2","direction","_this$keyExtractor3","selectfirstitem","pop","componentDidMount","_props$dataset","subscribe","event","scrollPosition","nativeEvent","contentOffset","y","layoutMeasurement","height","endThreshold","componentDidUpdate","prevProps","prevState","snapshot","getDefaultStyles","isHorizontal","theme","getStyle","defaultClass","getIndex","generateItemKey","itemkey","_showSkeleton","getKey","renderItem","cols","getNoOfColumns","styles","skeleton","root","renderLeftActions","renderRightActions","containerStyle","width","flex","style","itemclass","_extends","getTestPropsForAction","onTap","onLongTap","onDoubleTap","display","flexDirection","paddingRight","marginRight","margin","id","getTestId","iconclass","selectedIcon","renderHeader","title","groupHeading","accessibilityRole","subheading","heading","listIcon","caption","accessibilityrole","renderEmptyMessage","emptyMessage","nodatamessage","renderLoadingIcon","loadingicon","loadingIcon","loadingdatamsg","color","text","itemsperrow","xs","onLayoutChange","e","l","layout","renderWithFlatList","onLayout","v","i","_ref","group","scrollEnabled","horizontal","numberofskeletonitems","ListEmptyComponent","itemInfo","numColumns","onDemandMessage","ondemandmessage","getSectionListData","_ref2","renderWithSectionList","contentContainerStyle","sections","renderSectionHeader","section","renderSectionFooter","renderWidget","_background"],"sources":["list.component.tsx"],"sourcesContent":["import React from 'react';\nimport { ActivityIndicator, SectionList, Text, View, FlatList, LayoutChangeEvent, TouchableOpacity} from 'react-native';\nimport { isArray, isEmpty, isNil, isNumber, round } from 'lodash-es';\nimport { BaseComponent, BaseComponentState } from '@wavemaker/app-rn-runtime/core/base.component';\nimport {getGroupedData, getNumberOfEmptyObjects, isDefined} from \"@wavemaker/app-rn-runtime/core/utils\";\nimport { Tappable } from '@wavemaker/app-rn-runtime/core/tappable.component';\nimport { DefaultKeyExtractor } from '@wavemaker/app-rn-runtime/core/key.extractor';\nimport WmLabel from '@wavemaker/app-rn-runtime/components/basic/label/label.component';\nimport WmIcon from '@wavemaker/app-rn-runtime/components/basic/icon/icon.component';\nimport { Swipeable } from 'react-native-gesture-handler';\nimport WmListActionTemplate from './list-action-template/list-action-template.component';\n\nimport WmListProps from './list.props';\nimport { DEFAULT_CLASS, WmListStyles } from './list.styles';\n\n\nexport class WmListState extends BaseComponentState<WmListProps> {\n public selectedindex: any;\n groupedData: Array<any> = [];\n currentPage = 1;\n maxRecordsToShow = 20;\n}\n\nexport default class WmList extends BaseComponent<WmListProps, WmListState, WmListStyles> {\n\n private itemWidgets = [] as any[];\n private selectedItemWidgets = {} as any;\n private keyExtractor = new DefaultKeyExtractor();\n private endThreshold = -1;\n private loadingData = false;\n private hasMoreData = true;\n public leftActionTemplate?: WmListActionTemplate;\n public rightActionTemplate?: WmListActionTemplate;\n\n constructor(props: WmListProps) {\n super(props, DEFAULT_CLASS, new WmListProps(), new WmListState());\n this.updateState({\n maxRecordsToShow: this.state.props.pagesize\n } as WmListState);\n }\n\n private isSelected($item: any) {\n const selectedItem = this.state.props.selecteditem;\n if (isArray(selectedItem)) {\n return selectedItem.indexOf($item) >= 0;\n }\n return selectedItem === $item;\n }\n\n private async onSelect($item: any, $index: number | string, $event?: any) {\n const props = this.state.props;\n let selectedItem = null as any;\n let eventName = 'onSelect';\n if (props.disableitem !== true\n && (typeof props.disableitem !== 'function' || !props.disableitem($item, $index))) {\n if (props.multiselect) {\n selectedItem = [...(props.selecteditem || [])];\n const index = selectedItem.indexOf($item);\n if (index < 0) {\n if ((!props.selectionlimit)\n || props.selectionlimit < 0\n || selectedItem.length < props.selectionlimit) {\n selectedItem.push($item);\n } else {\n this.invokeEventCallback('onSelectionlimitexceed', [null, this]);\n }\n } else {\n selectedItem.splice(index, 1);\n eventName = 'onDeselect';\n }\n } else {\n this.state.props.selecteditem && this.invokeEventCallback('onDeselect', [this.proxy, this.state.props.selecteditem]);\n selectedItem = $item;\n }\n this.selectedItemWidgets = this.itemWidgets[$index as number];\n return new Promise(resolve => {\n this.updateState({\n props: { selecteditem: selectedItem },\n selectedindex: $index\n } as WmListState, () => {\n this.invokeEventCallback(eventName, [this.proxy, $item]);\n $event && this.invokeEventCallback('onTap', [$event, this.proxy]);\n resolve(null);\n });\n });\n } else {\n return Promise.resolve(null);\n }\n }\n\n private get loadDataOnDemand() {\n const navigation = this.state.props.navigation;\n return navigation === 'Scroll' || navigation === 'On-Demand';\n }\n\n renderLeftActions = () => {\n return this.leftActionTemplate ? (\n <>\n {this.leftActionTemplate.getTemplate()}\n </>\n ) : null;\n };\n\n renderRightActions = () => {\n return this.rightActionTemplate ? (\n <>\n {this.rightActionTemplate.getTemplate()}\n </>\n ) : null;\n };\n\n private loadData() {\n if (this.loadingData) {\n return;\n }\n if (isArray(this.state.props.dataset)\n && this.state.props.dataset.length > this.state.maxRecordsToShow) {\n this.loadingData = true;\n this.updateState({\n maxRecordsToShow: this.state.maxRecordsToShow + this.state.props.pagesize\n } as WmListState);\n setTimeout(() => {\n this.loadingData = false;\n }, 100);\n } else if (this.loadDataOnDemand) {\n const $list = this.proxy as any;\n $list.loadingdata = true;\n this.loadingData = true;\n this.props.getNextPageData && this.props.getNextPageData(null, this.proxy, this.state.currentPage + 1).then((data) => {\n if (isArray(data) && data.length > 0\n && isArray(this.state.props.dataset)) {\n $list.dataset = [...this.state.props.dataset, ...data];\n this.updateState({\n currentPage : this.state.currentPage + 1,\n maxRecordsToShow: this.state.maxRecordsToShow + this.state.props.pagesize\n } as WmListState);\n this.hasMoreData = true;\n } else {\n this.hasMoreData = false;\n }\n }).catch((err) => {\n console.error(err);\n }).then(() => {\n setTimeout(() => {\n $list.loadingdata = false;\n }, 1000);\n });\n }\n }\n\n private selectFirstItem() {\n const props = this.state.props;\n if (this.initialized\n && props.dataset\n && props.dataset.length) {\n const index = props.groupby ? '00': 0;\n this.onSelect(props.dataset[0], index);\n }\n }\n\n clear(){\n this.updateState({\n groupedData: {},\n } as WmListState);\n }\n\n selectItem(item: any){\n const dataset = this.state.props.dataset;\n if(isNumber(item)){\n this.onSelect(dataset[item], item);\n }\n else{\n let index = dataset.indexOf(item);\n this.onSelect(dataset[index], index);\n }\n }\n\n getItem(index: number){\n const props = this.state.props;\n return this.props.dataset[index]\n }\n\n deselect(item: any){\n const props = this.state.props;\n let selectedItem = null as any;\n let index = isNumber(item)?item:props.dataset.indexOf(item);\n if(props.multiselect && index >= 0){\n selectedItem = [...(props.selecteditem || [])];\n let selectedItemIndex = selectedItem.indexOf(props.dataset[index])\n if(selectedItemIndex >= 0){\n selectedItem.splice(selectedItemIndex, 1);\n }\n }\n else{\n if (props.selecteditem === props.dataset[index]) {\n selectedItem = null;\n }\n }\n this.updateState({\n props: { selecteditem: selectedItem },\n\n } as WmListState, () => {\n this.invokeEventCallback('onDeselect', [this.proxy, item]);\n });\n }\n\n getWidgets(widgetname: string, index: number){\n if(index >= 0 && index < this.itemWidgets.length){\n return this.itemWidgets[index][widgetname]\n }\n else{\n return this.itemWidgets.map(item => item[widgetname]).filter(widget => widget !== undefined);\n }\n }\n\n private deselectAll() {\n this.updateState({\n props: { selecteditem: null },\n selectedindex: -1\n } as WmListState);\n }\n\n setGroupData(items: any) {\n const dataItems = items;\n const props = this.state.props;\n if (props.groupby) {\n const groupedData = dataItems && getGroupedData(dataItems, props.groupby, props.match, props.orderby, props.dateformat, this);\n this.updateState({\n groupedData: groupedData\n } as WmListState, () => {\n this.keyExtractor?.clear();\n });\n }\n }\n\n public onPropertyChange(name: string, $new: any, $old: any) {\n super.onPropertyChange(name, $new, $old);\n const props = this.state.props;\n switch(name) {\n case 'selectfirstitem':\n if ($new) {\n this.selectFirstItem();\n }\n break;\n case 'dataset':\n if (this.state.props.groupby) {\n this.setGroupData($new);\n } else {\n if (!($old && $old.length)\n && $new && $new.length\n && this.loadDataOnDemand) {\n this.updateState({\n props: {\n dataset: [...$new]\n }\n } as WmListState);\n }\n const data = isArray($new) ? $new : (!isEmpty($new) && isDefined($new) ? [$new] : []);\n if(props.orderby) {\n const orderbyData = data && getGroupedData(data, props.groupby, props.match, props.orderby, props.dateformat, this);\n this.updateState({\n groupedData: (orderbyData[0] ? [{\n key: 'key',\n data: orderbyData[0].data\n }] : [])\n } as WmListState, () => {\n this.keyExtractor?.clear();\n });\n } else {\n this.updateState({\n groupedData: (data[0] || props.direction === 'horizontal' ? [{\n key: 'key',\n data: data\n }] : [])\n } as WmListState, () => {\n this.keyExtractor?.clear();\n });\n }\n }\n this.itemWidgets = [];\n if (props.selectfirstitem) {\n this.selectFirstItem();\n } else {\n this.deselectAll();\n }\n break;\n case 'groupby':\n case 'match':\n this.setGroupData(this.state.props.dataset);\n break;\n case 'multiselect':\n if ($new) {\n if (!isArray(this.state.props.selecteditem)) {\n this.state.props.selecteditem = this.state.props.selecteditem ?\n [this.state.props.selecteditem] : [];\n }\n } else if (isArray(this.state.props.selecteditem)) {\n this.state.props.selecteditem = this.state.props.selecteditem.pop();\n }\n break;\n case 'loadingdata':\n this.loadingData = $new && this.loadingData;\n break;\n case 'selecteditem':\n if($new != $old && isNumber($new)) {\n this.selectItem(this.state.props.dataset[$new])\n }\n break;\n }\n }\n\n componentDidMount() {\n const props = this.state.props;\n if (this.state.props.selectfirstitem && props.dataset?.length) {\n setTimeout(() => {\n this.onSelect(props.dataset[0], 0);\n });\n }\n this.subscribe('scroll', (event: any) => {\n const scrollPosition = event.nativeEvent.contentOffset.y + event.nativeEvent.layoutMeasurement.height;\n if (scrollPosition > this.endThreshold && this.state.props.direction === 'vertical') {\n this.loadData();\n }\n });\n super.componentDidMount();\n }\n\n componentDidUpdate(prevProps: WmListProps, prevState: WmListState, snapshot?: any) {\n super.componentDidUpdate && super.componentDidUpdate(prevProps, prevState, snapshot);\n this.invokeEventCallback('onRender', [this, this.state.props.dataset]);\n }\n\n getDefaultStyles() {\n const isHorizontal = this.state.props.direction === 'horizontal';\n return this.theme.getStyle(`${this.defaultClass} ${isHorizontal ? 'app-horizontal-list' : 'app-vertical-list'}`);\n }\n\n getIndex(item: any) {\n return this.state.props.dataset.indexOf(item);\n }\n\n private generateItemKey(item: any, index: number, props: WmListProps) {\n if (props.itemkey && item && !this._showSkeleton) {\n return props.itemkey(item, index);\n }\n return 'list_item_' + this.keyExtractor.getKey(item, true);\n }\n\n private renderItem(item: any, index: number, props: WmListProps) {\n const cols = this. getNoOfColumns();\n const isHorizontal = (props.direction === 'horizontal');\n \n const styles = this._showSkeleton ? {\n ...this.styles.item,\n ...this.styles.skeleton.root\n } : this.styles.item\n\n return (index < this.state.maxRecordsToShow || isHorizontal) ? (\n <Swipeable\n renderLeftActions={() => this.renderLeftActions()}\n renderRightActions={() => this.renderRightActions()} containerStyle={ cols ? { width: round(100/cols) + \"%\" , flex: null } as any :{}}>\n <View style={[\n styles,\n props.itemclass ? this.theme.getStyle(props.itemclass(item, index)) : null,\n this.isSelected(item) ? this.styles.selectedItem : {}]}>\n <Tappable\n {...this.getTestPropsForAction(`item${index}`)}\n onTap={($event) => this.onSelect(item, index, $event)}\n onLongTap={() => this.invokeEventCallback('onLongtap', [null, this.proxy])}\n onDoubleTap={() => this.invokeEventCallback('onDoubletap', [null, this.proxy])}\n styles={\n [{display: 'flex', flexDirection : 'row'},\n cols ? {\n width: '100%'\n } : null,\n (cols && cols > 1) || isHorizontal ? {\n paddingRight: (isNil(this.styles.item.marginRight)\n ? this.styles.item.margin : this.styles.item.marginRight) || 4\n } : null\n ]\n }>\n {props.renderItem(item, index, this)}\n {this.isSelected(item) ? (\n <WmIcon id={this.getTestId('icon' + index)} iconclass='wi wi-check-circle' styles={this.styles.selectedIcon} />\n ) : null}\n </Tappable>\n </View>\n </Swipeable>\n ) : null;\n }\n\n private renderHeader(props: WmListProps, title: string) {\n return props.groupby ? (\n <Text style={this.styles.groupHeading} accessibilityRole='header'>{title}</Text>\n ) : (props.iconclass || props.title || props.subheading) ? (\n <View style={this.styles.heading}>\n <View style={{flex: 1, flexDirection: 'row'}}>\n <WmIcon id={this.getTestId('icon')} styles={this.styles.listIcon} iconclass={props.iconclass}></WmIcon>\n <View>\n <WmLabel id={this.getTestId('title')} styles={this.styles.title} caption={props.title} accessibilityrole='header'></WmLabel>\n <WmLabel id={this.getTestId('subheading')} styles={this.styles.subheading} caption={props.subheading}></WmLabel>\n </View>\n </View>\n </View>) : null;\n }\n\n private renderEmptyMessage(isHorizontal: boolean, item: any, index: any, props: WmListProps) {\n return (<WmLabel id={this.getTestId('emptymsg')} styles={this.styles.emptyMessage} caption={props.nodatamessage}></WmLabel>);\n }\n\n private renderLoadingIcon(props: WmListProps) {\n return props.loadingicon ? (<WmIcon\n id={this.getTestId('loadingicon')}\n styles={this.styles.loadingIcon}\n iconclass={props.loadingicon}\n caption={props.loadingdatamsg}></WmIcon>)\n : (\n <ActivityIndicator color={this.styles.loadingIcon.text.color}></ActivityIndicator>\n );\n }\n\n public getNoOfColumns() {\n const props = this.state.props;\n if(props.direction === 'vertical') {\n return props.itemsperrow.xs;\n }\n return 0;\n }\n\n private onLayoutChange(e: LayoutChangeEvent) {\n const l = e.nativeEvent.layout;\n this.endThreshold = l.height + l.y - 100;\n if (!this.endThreshold) {\n this.endThreshold = -1;\n }\n }\n\n private renderWithFlatList(props: WmListProps, isHorizontal = false) {\n return (\n <View style={this.styles.root} onLayout={e => this.onLayoutChange(e)}>\n {!isEmpty(this.state.groupedData) ? this.state.groupedData.map((v: any, i) => ((\n <View style={this.styles.group} key={v.key || this.keyExtractor.getKey(v, true)}>\n {this.renderHeader(props, v.key)}\n <FlatList\n key={props.name + '_' + (isHorizontal ? 'H' : 'V') + props.itemsperrow.xs}\n keyExtractor={(item, i) => this.generateItemKey(item, i, props)}\n scrollEnabled={isHorizontal}\n horizontal = {isHorizontal}\n data={this._showSkeleton? [...getNumberOfEmptyObjects(this.props.numberofskeletonitems as number ?? 3)] : (isEmpty(v.data[0]) ? []: v.data)}\n ListEmptyComponent = {(itemInfo) => this.renderEmptyMessage(isHorizontal, itemInfo.item, itemInfo.index, props)}\n renderItem={(itemInfo) => this.renderItem(itemInfo.item, itemInfo.index, props)}\n {...(isHorizontal ? {} : {numColumns : this.getNoOfColumns()})}>\n </FlatList>\n {this.loadDataOnDemand || (v.data.length > this.state.maxRecordsToShow) ?\n (this.loadingData ?\n this.renderLoadingIcon(props) :\n (<WmLabel id={this.getTestId('ondemandmessage')}\n styles={this.styles.onDemandMessage}\n caption={this.hasMoreData && !isHorizontal ? props.ondemandmessage : props.nodatamessage}\n onTap={() => this.loadData()}></WmLabel>))\n : null}\n </View>\n ))) : this.renderEmptyMessage(isHorizontal, null, null,props)\n }\n </View>);\n }\n\n private getSectionListData(props: WmListProps) {\n if (this._showSkeleton) {\n return [{\n key: '',\n data: [...getNumberOfEmptyObjects(this.props.numberofskeletonitems as number ?? 3)]\n }];\n } else if (this.state.groupedData\n && this.state.groupedData[0]\n && this.state.groupedData[0]['data'].length) {\n return this.state.groupedData;\n }\n return [];\n }\n\n private renderWithSectionList(props: WmListProps, isHorizontal = false) {\n return (\n <SectionList\n keyExtractor={(item, i) => this.generateItemKey(item, i, props)}\n horizontal = {isHorizontal}\n contentContainerStyle={this.styles.root}\n sections={this.getSectionListData(props)}\n renderSectionHeader={({ section: {key, data}}) => {\n return this.renderHeader(props, key);\n }}\n renderSectionFooter={() => props.loadingdata ? this.renderLoadingIcon(props) : null}\n ListEmptyComponent = {(itemInfo) => this.renderEmptyMessage(isHorizontal, itemInfo.item, itemInfo.index, props)}\n renderItem={(itemInfo) => this.renderItem(itemInfo.item, itemInfo.index, props)}>\n </SectionList>\n );\n }\n\n renderWidget(props: WmListProps) {\n this.invokeEventCallback('onBeforedatarender', [this, this.state.props.dataset]);\n const isHorizontal = (props.direction === 'horizontal');\n return (\n <View style={isHorizontal ? null : { width: '100%' }}>\n {this._background}\n {(isHorizontal || !props.groupby) ?\n this.renderWithFlatList(props, isHorizontal)\n : this.renderWithSectionList(props, isHorizontal)}\n </View>);\n }\n}\n"],"mappings":";;;;AAAA,OAAOA,KAAK,MAAM,O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AAK,EAAErB,KAAK,CAAE;MAChH+G,UAAU,EAAG6D,QAAQ,IAAK,IAAI,CAAC7D,UAAU,CAAC6D,QAAQ,CAACpH,IAAI,EAAEoH,QAAQ,CAACvJ,KAAK,EAAErB,KAAK;IAAE,CACrE,CAAC;EAElB;EAEAwL,YAAYA,CAACxL,KAAkB,EAAE;IAC/B,IAAI,CAACyB,mBAAmB,CAAC,oBAAoB,EAAE,CAAC,IAAI,EAAE,IAAI,CAACjB,KAAK,CAACR,KAAK,CAACqC,OAAO,CAAC,CAAC;IAChF,MAAMiE,YAAY,GAAItG,KAAK,CAACkF,SAAS,KAAK,YAAa;IACvD,oBACI9G,KAAA,CAAA8B,aAAA,CAAC1B,IAAI;MAACkJ,KAAK,EAAEpB,YAAY,GAAG,IAAI,GAAG;QAAEkB,KAAK,EAAE;MAAO;IAAE,GAClD,IAAI,CAACiE,WAAW,EACfnF,YAAY,IAAI,CAACtG,KAAK,CAACoD,OAAO,GAC9B,IAAI,CAAC8G,kBAAkB,CAAClK,KAAK,EAAEsG,YAAY,CAAC,GAC5C,IAAI,CAAC4E,qBAAqB,CAAClL,KAAK,EAAEsG,YAAY,CAC9C,CAAC;EACX;AACF","ignoreList":[]}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"names":["React","BaseProps","View","WmListProps","constructor","args","_defineProperty","createElement","$item","$index","xs","sm","md","lg"],"sources":["list.props.tsx"],"sourcesContent":["import React from 'react';\nimport { BaseProps } from '@wavemaker/app-rn-runtime/core/base.component';\nimport { View } from 'react-native';\n\nexport default class WmListProps extends BaseProps {\n formRef: any;\n iconclass: string = null as any;\n deferload = false;\n ondemandmessage = 'Load More';\n title: string = null as any;\n subheading: string = null as any;\n dataset = [] as any;\n maxnumberofitems = 50;\n children? = null as any;\n renderItem: any = () => (<View/>);\n loadingicon: string = null as any;\n loadingdatamsg = 'Loading...';\n multiselect = false;\n nodatamessage = 'No data found';\n loadingdata = false;\n selectfirstitem = false;\n selectionlimit = -1;\n disableitem: Function | boolean = ($item: any, $index: any) => false;\n itemkey?: ($item: any, $index: any) => any = null as any;\n direction: 'horizontal' | 'vertical' = 'vertical';\n groupby: string = null as any;\n match: string = null as any;\n orderby: string = null as any;\n dateformat: string = null as any;\n selecteditem = null as any;\n navigation : 'Scroll' | 'On-Demand' | 'None' = 'None';\n itemclass: ($item: any, $index: any) => string = null as any;\n getNextPageData: ($event: any, $list: any, page: number) => Promise<any> = null as any;\n pagesize = 20;\n itemsperrow = {\n xs: 1,\n sm: 1,\n md: 1,\n lg: 1,\n }\n}\n"],"mappings":";;;AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,SAASC,SAAS,QAAQ,+CAA+C;AACzE,SAASC,IAAI,QAAQ,cAAc;AAEnC,eAAe,MAAMC,WAAW,SAASF,SAAS,CAAC;EAAAG,YAAA,GAAAC,IAAA;IAAA,SAAAA,IAAA;IAAAC,eAAA;IAAAA,eAAA,oBAE3B,IAAI;IAAAA,eAAA,oBACZ,KAAK;IAAAA,eAAA,0BACC,WAAW;IAAAA,eAAA,gBACb,IAAI;IAAAA,eAAA,qBACC,IAAI;IAAAA,eAAA,kBACf,EAAE;IAAAA,eAAA,2BACO,EAAE;IAAAA,eAAA,mBACT,IAAI;IAAAA,eAAA,qBACE,mBAAON,KAAA,CAAAO,aAAA,CAACL,IAAI,MAAC,CAAE;IAAAI,eAAA,sBACX,IAAI;IAAAA,eAAA,yBACT,YAAY;IAAAA,eAAA,sBACf,KAAK;IAAAA,eAAA,wBACH,eAAe;IAAAA,eAAA,sBACjB,KAAK;IAAAA,eAAA,0BACD,KAAK;IAAAA,eAAA,yBACN,CAAC,CAAC;IAAAA,eAAA,sBACe,CAACE,KAAU,EAAEC,MAAW,KAAK,KAAK;IAAAH,eAAA,kBACvB,IAAI;IAAAA,eAAA,oBACV,UAAU;IAAAA,eAAA,kBAC/B,IAAI;IAAAA,eAAA,gBACN,IAAI;IAAAA,eAAA,kBACF,IAAI;IAAAA,eAAA,qBACD,IAAI;IAAAA,eAAA,uBACV,IAAI;IAAAA,eAAA,qBAC4B,MAAM;IAAAA,eAAA,oBACJ,IAAI;IAAAA,eAAA,0BACsB,IAAI;IAAAA,eAAA,mBACpE,EAAE;IAAAA,eAAA,sBACE;MACZI,EAAE,EAAE,CAAC;MACLC,EAAE,EAAE,CAAC;MACLC,EAAE,EAAE,CAAC;MACLC,EAAE,EAAE;IACP,CAAC;EAAA;
|
1
|
+
{"version":3,"names":["React","BaseProps","View","WmListProps","constructor","args","_defineProperty","createElement","$item","$index","xs","sm","md","lg"],"sources":["list.props.tsx"],"sourcesContent":["import React from 'react';\nimport { BaseProps } from '@wavemaker/app-rn-runtime/core/base.component';\nimport { View } from 'react-native';\n\nexport default class WmListProps extends BaseProps {\n formRef: any;\n iconclass: string = null as any;\n deferload = false;\n ondemandmessage = 'Load More';\n title: string = null as any;\n subheading: string = null as any;\n dataset = [] as any;\n maxnumberofitems = 50;\n children? = null as any;\n renderItem: any = () => (<View/>);\n loadingicon: string = null as any;\n loadingdatamsg = 'Loading...';\n multiselect = false;\n nodatamessage = 'No data found';\n loadingdata = false;\n selectfirstitem = false;\n selectionlimit = -1;\n disableitem: Function | boolean = ($item: any, $index: any) => false;\n itemkey?: ($item: any, $index: any) => any = null as any;\n direction: 'horizontal' | 'vertical' = 'vertical';\n groupby: string = null as any;\n match: string = null as any;\n orderby: string = null as any;\n dateformat: string = null as any;\n selecteditem = null as any;\n navigation : 'Scroll' | 'On-Demand' | 'None' = 'None';\n itemclass: ($item: any, $index: any) => string = null as any;\n getNextPageData: ($event: any, $list: any, page: number) => Promise<any> = null as any;\n pagesize = 20;\n itemsperrow = {\n xs: 1,\n sm: 1,\n md: 1,\n lg: 1,\n };\n numberofskeletonitems?: number | string\n}\n"],"mappings":";;;AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,SAASC,SAAS,QAAQ,+CAA+C;AACzE,SAASC,IAAI,QAAQ,cAAc;AAEnC,eAAe,MAAMC,WAAW,SAASF,SAAS,CAAC;EAAAG,YAAA,GAAAC,IAAA;IAAA,SAAAA,IAAA;IAAAC,eAAA;IAAAA,eAAA,oBAE3B,IAAI;IAAAA,eAAA,oBACZ,KAAK;IAAAA,eAAA,0BACC,WAAW;IAAAA,eAAA,gBACb,IAAI;IAAAA,eAAA,qBACC,IAAI;IAAAA,eAAA,kBACf,EAAE;IAAAA,eAAA,2BACO,EAAE;IAAAA,eAAA,mBACT,IAAI;IAAAA,eAAA,qBACE,mBAAON,KAAA,CAAAO,aAAA,CAACL,IAAI,MAAC,CAAE;IAAAI,eAAA,sBACX,IAAI;IAAAA,eAAA,yBACT,YAAY;IAAAA,eAAA,sBACf,KAAK;IAAAA,eAAA,wBACH,eAAe;IAAAA,eAAA,sBACjB,KAAK;IAAAA,eAAA,0BACD,KAAK;IAAAA,eAAA,yBACN,CAAC,CAAC;IAAAA,eAAA,sBACe,CAACE,KAAU,EAAEC,MAAW,KAAK,KAAK;IAAAH,eAAA,kBACvB,IAAI;IAAAA,eAAA,oBACV,UAAU;IAAAA,eAAA,kBAC/B,IAAI;IAAAA,eAAA,gBACN,IAAI;IAAAA,eAAA,kBACF,IAAI;IAAAA,eAAA,qBACD,IAAI;IAAAA,eAAA,uBACV,IAAI;IAAAA,eAAA,qBAC4B,MAAM;IAAAA,eAAA,oBACJ,IAAI;IAAAA,eAAA,0BACsB,IAAI;IAAAA,eAAA,mBACpE,EAAE;IAAAA,eAAA,sBACE;MACZI,EAAE,EAAE,CAAC;MACLC,EAAE,EAAE,CAAC;MACLC,EAAE,EAAE,CAAC;MACLC,EAAE,EAAE;IACP,CAAC;IAAAP,eAAA;EAAA;AAEL","ignoreList":[]}
|
@@ -101,6 +101,15 @@ BASE_THEME.registerStyle((themeVariables, addStyle) => {
|
|
101
101
|
color: themeVariables.primaryColor,
|
102
102
|
fontSize: 16
|
103
103
|
}
|
104
|
+
},
|
105
|
+
skeleton: {
|
106
|
+
root: {
|
107
|
+
shadowColor: 'transparent',
|
108
|
+
paddingTop: 0,
|
109
|
+
paddingBottom: 0,
|
110
|
+
paddingLeft: 0,
|
111
|
+
paddingRight: 0
|
112
|
+
}
|
104
113
|
}
|
105
114
|
});
|
106
115
|
addStyle(DEFAULT_CLASS, '', defaultStyles);
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"names":["BASE_THEME","defineStyles","DEFAULT_CLASS","registerStyle","themeVariables","addStyle","defaultStyles","root","text","listIcon","marginTop","marginRight","groupHeading","backgroundColor","groupHeadingBgColor","fontSize","paddingLeft","paddingRight","lineHeight","fontFamily","baseFont","loadingIcon","flex","alignSelf","justifyContent","color","listSubTitleColor","heading","padding","marginBottom","listHeaderBgColor","title","listTitleColor","fontWeight","subheading","emptyMessage","onDemandMessage","paddingVertical","width","textAlign","group","item","getStyle","shadowColor","flexDirection","paddingTop","paddingBottom","minHeight","itemBgColor","borderColor","selectedItemBorderColor","borderRadius","borderStyle","selectedItem","selectedIcon","position","right","top","primaryColor","minWidth","borderBottomWidth","borderBottomColor","listDividerColor","borderRightWidth","borderRightColor"],"sources":["list.styles.ts"],"sourcesContent":["import { TextStyle, ViewStyle } from 'react-native';\nimport BASE_THEME, { AllStyle } from '@wavemaker/app-rn-runtime/styles/theme';\nimport { BaseStyles, defineStyles } from '@wavemaker/app-rn-runtime/core/base.component';\nimport { WmLabelStyles } from '@wavemaker/app-rn-runtime/components/basic/label/label.styles';\nimport { WmIconStyles } from '@wavemaker/app-rn-runtime/components/basic/icon/icon.styles';\n\nexport type WmListStyles = BaseStyles & {\n heading: AllStyle,\n groupHeading: TextStyle,\n listIcon: WmIconStyles,\n loadingIcon: WmIconStyles,\n title: WmLabelStyles,\n subheading: WmLabelStyles,\n emptyMessage: WmLabelStyles,\n onDemandMessage: WmLabelStyles,\n item: AllStyle,\n selectedItem: AllStyle,\n selectedIcon: WmIconStyles,\n group: AllStyle,\n};\n\nexport const DEFAULT_CLASS = 'app-list';\nBASE_THEME.registerStyle((themeVariables, addStyle) => {\n const defaultStyles: WmListStyles = defineStyles({\n root: {},\n text: {},\n listIcon: {\n root: {\n marginTop: 10,\n marginRight: 8\n }\n } as WmIconStyles,\n groupHeading: {\n backgroundColor: themeVariables.groupHeadingBgColor,\n fontSize: 16,\n paddingLeft: 8,\n paddingRight: 8,\n lineHeight: 40,\n fontFamily: themeVariables.baseFont\n },\n loadingIcon: {\n root: {\n flex: 1,\n alignSelf: 'center',\n justifyContent: 'center',\n fontSize: 16\n },\n text: {\n color: themeVariables.listSubTitleColor\n }\n } as WmIconStyles,\n heading : {\n padding: 8,\n marginBottom: 6,\n backgroundColor: themeVariables.listHeaderBgColor\n },\n title: {\n text: {\n color: themeVariables.listTitleColor,\n fontSize: 16,\n fontFamily: themeVariables.baseFont,\n lineHeight: 24,\n fontWeight: '400' \n }\n } as WmLabelStyles,\n subheading: {\n text: {\n fontSize: 14,\n lineHeight: 20,\n fontFamily: themeVariables.baseFont,\n fontWeight: '400',\n color: themeVariables.listSubTitleColor\n }\n } as WmLabelStyles,\n emptyMessage: {\n root: {\n flex: 1,\n alignSelf: 'center',\n fontSize: 16,\n lineHeight: 18,\n color: themeVariables.listSubTitleColor\n }\n } as WmLabelStyles,\n onDemandMessage: {\n root: {\n paddingVertical: 8,\n width: '100%'\n } as ViewStyle,\n text: {\n textAlign: 'center',\n color: themeVariables.listSubTitleColor\n }\n } as WmLabelStyles,\n group: {\n marginBottom: 16,\n },\n item: {\n ...BASE_THEME.getStyle('elevate1').root,\n shadowColor: 'rgba(0, 0, 0, 0.3)',\n paddingLeft: 4,\n paddingRight: 4,\n flex: 1,\n flexDirection: 'row',\n paddingTop: 4,\n paddingBottom: 4,\n minHeight: 56,\n backgroundColor: themeVariables.itemBgColor,\n borderColor: themeVariables.selectedItemBorderColor,\n borderRadius: 6,\n borderStyle: 'solid',\n },\n selectedItem : {} as AllStyle,\n selectedIcon : {\n root: {\n position: 'absolute',\n right: 0,\n top: 0\n },\n text: {\n color: themeVariables.primaryColor,\n fontSize: 16\n }\n } as WmIconStyles\n });\n\n addStyle(DEFAULT_CLASS, '', defaultStyles);\n\n addStyle('app-horizontal-list', '', {\n groupHeading: {\n minWidth: 120,\n backgroundColor: themeVariables.groupHeadingBgColor,\n },\n item: {\n marginRight: 6,\n borderColor: themeVariables.selectedItemBorderColor,\n }\n } as WmListStyles);\n\n addStyle('app-vertical-list', '', {\n item: {\n marginBottom: 6,\n width: '100%',\n borderBottomWidth: 0,\n borderBottomColor: themeVariables.listDividerColor,\n }\n } as any as WmListStyles);\n\n addStyle('app-horizontal-list-dense', '', {\n item: {\n marginRight: 0,\n borderRadius: 0,\n borderRightWidth: 1,\n borderRightColor: 'rgba(0,0,0,0.05)'\n } as ViewStyle\n } as WmListStyles);\n\n addStyle('app-list-dense', '', {\n item: {\n marginBottom: 0,\n borderRadius: 0,\n borderBottomWidth: 1,\n borderBottomColor: 'rgba(0,0,0,0.05)'\n } as ViewStyle\n } as WmListStyles);\n});\n"],"mappings":"AACA,OAAOA,UAAU,MAAoB,wCAAwC;AAC7E,SAAqBC,YAAY,QAAQ,+CAA+C;
|
1
|
+
{"version":3,"names":["BASE_THEME","defineStyles","DEFAULT_CLASS","registerStyle","themeVariables","addStyle","defaultStyles","root","text","listIcon","marginTop","marginRight","groupHeading","backgroundColor","groupHeadingBgColor","fontSize","paddingLeft","paddingRight","lineHeight","fontFamily","baseFont","loadingIcon","flex","alignSelf","justifyContent","color","listSubTitleColor","heading","padding","marginBottom","listHeaderBgColor","title","listTitleColor","fontWeight","subheading","emptyMessage","onDemandMessage","paddingVertical","width","textAlign","group","item","getStyle","shadowColor","flexDirection","paddingTop","paddingBottom","minHeight","itemBgColor","borderColor","selectedItemBorderColor","borderRadius","borderStyle","selectedItem","selectedIcon","position","right","top","primaryColor","skeleton","minWidth","borderBottomWidth","borderBottomColor","listDividerColor","borderRightWidth","borderRightColor"],"sources":["list.styles.ts"],"sourcesContent":["import { TextStyle, ViewStyle } from 'react-native';\nimport BASE_THEME, { AllStyle } from '@wavemaker/app-rn-runtime/styles/theme';\nimport { BaseStyles, defineStyles } from '@wavemaker/app-rn-runtime/core/base.component';\nimport { WmLabelStyles } from '@wavemaker/app-rn-runtime/components/basic/label/label.styles';\nimport { WmIconStyles } from '@wavemaker/app-rn-runtime/components/basic/icon/icon.styles';\nimport { WmSkeletonStyles } from '@wavemaker/app-rn-runtime/components/basic/skeleton/skeleton.styles';\n\nexport type WmListStyles = BaseStyles & {\n heading: AllStyle,\n groupHeading: TextStyle,\n listIcon: WmIconStyles,\n loadingIcon: WmIconStyles,\n title: WmLabelStyles,\n subheading: WmLabelStyles,\n emptyMessage: WmLabelStyles,\n onDemandMessage: WmLabelStyles,\n item: AllStyle,\n selectedItem: AllStyle,\n selectedIcon: WmIconStyles,\n group: AllStyle,\n skeleton: WmSkeletonStyles\n};\n\nexport const DEFAULT_CLASS = 'app-list';\nBASE_THEME.registerStyle((themeVariables, addStyle) => {\n const defaultStyles: WmListStyles = defineStyles({\n root: {},\n text: {},\n listIcon: {\n root: {\n marginTop: 10,\n marginRight: 8\n }\n } as WmIconStyles,\n groupHeading: {\n backgroundColor: themeVariables.groupHeadingBgColor,\n fontSize: 16,\n paddingLeft: 8,\n paddingRight: 8,\n lineHeight: 40,\n fontFamily: themeVariables.baseFont\n },\n loadingIcon: {\n root: {\n flex: 1,\n alignSelf: 'center',\n justifyContent: 'center',\n fontSize: 16\n },\n text: {\n color: themeVariables.listSubTitleColor\n }\n } as WmIconStyles,\n heading : {\n padding: 8,\n marginBottom: 6,\n backgroundColor: themeVariables.listHeaderBgColor\n },\n title: {\n text: {\n color: themeVariables.listTitleColor,\n fontSize: 16,\n fontFamily: themeVariables.baseFont,\n lineHeight: 24,\n fontWeight: '400' \n }\n } as WmLabelStyles,\n subheading: {\n text: {\n fontSize: 14,\n lineHeight: 20,\n fontFamily: themeVariables.baseFont,\n fontWeight: '400',\n color: themeVariables.listSubTitleColor\n }\n } as WmLabelStyles,\n emptyMessage: {\n root: {\n flex: 1,\n alignSelf: 'center',\n fontSize: 16,\n lineHeight: 18,\n color: themeVariables.listSubTitleColor\n }\n } as WmLabelStyles,\n onDemandMessage: {\n root: {\n paddingVertical: 8,\n width: '100%'\n } as ViewStyle,\n text: {\n textAlign: 'center',\n color: themeVariables.listSubTitleColor\n }\n } as WmLabelStyles,\n group: {\n marginBottom: 16,\n },\n item: {\n ...BASE_THEME.getStyle('elevate1').root,\n shadowColor: 'rgba(0, 0, 0, 0.3)',\n paddingLeft: 4,\n paddingRight: 4,\n flex: 1,\n flexDirection: 'row',\n paddingTop: 4,\n paddingBottom: 4,\n minHeight: 56,\n backgroundColor: themeVariables.itemBgColor,\n borderColor: themeVariables.selectedItemBorderColor,\n borderRadius: 6,\n borderStyle: 'solid',\n },\n selectedItem : {} as AllStyle,\n selectedIcon : {\n root: {\n position: 'absolute',\n right: 0,\n top: 0\n },\n text: {\n color: themeVariables.primaryColor,\n fontSize: 16\n }\n } as WmIconStyles,\n skeleton: {\n root: {\n shadowColor: 'transparent',\n paddingTop: 0,\n paddingBottom: 0, \n paddingLeft: 0,\n paddingRight: 0, \n }\n } as any as WmSkeletonStyles\n });\n\n addStyle(DEFAULT_CLASS, '', defaultStyles);\n\n addStyle('app-horizontal-list', '', {\n groupHeading: {\n minWidth: 120,\n backgroundColor: themeVariables.groupHeadingBgColor,\n },\n item: {\n marginRight: 6,\n borderColor: themeVariables.selectedItemBorderColor,\n }\n } as WmListStyles);\n\n addStyle('app-vertical-list', '', {\n item: {\n marginBottom: 6,\n width: '100%',\n borderBottomWidth: 0,\n borderBottomColor: themeVariables.listDividerColor,\n }\n } as any as WmListStyles);\n\n addStyle('app-horizontal-list-dense', '', {\n item: {\n marginRight: 0,\n borderRadius: 0,\n borderRightWidth: 1,\n borderRightColor: 'rgba(0,0,0,0.05)'\n } as ViewStyle\n } as WmListStyles);\n\n addStyle('app-list-dense', '', {\n item: {\n marginBottom: 0,\n borderRadius: 0,\n borderBottomWidth: 1,\n borderBottomColor: 'rgba(0,0,0,0.05)'\n } as ViewStyle\n } as WmListStyles);\n});\n"],"m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IAAI,EAAE;QACFoC,WAAW,EAAE,aAAa;QAC1BE,UAAU,EAAE,CAAC;QACbC,aAAa,EAAE,CAAC;QAChB9B,WAAW,EAAE,CAAC;QACdC,YAAY,EAAE;MAClB;IACJ;EACJ,CAAC,CAAC;EAEFZ,QAAQ,CAACH,aAAa,EAAE,EAAE,EAAEI,aAAa,CAAC;EAE1CD,QAAQ,CAAC,qBAAqB,EAAE,EAAE,EAAE;IAChCO,YAAY,EAAE;MACVgD,QAAQ,EAAE,GAAG;MACb/C,eAAe,EAAET,cAAc,CAACU;IACpC,CAAC;IACD2B,IAAI,EAAE;MACF9B,WAAW,EAAE,CAAC;MACdsC,WAAW,EAAE7C,cAAc,CAAC8C;IAChC;EACJ,CAAiB,CAAC;EAElB7C,QAAQ,CAAC,mBAAmB,EAAE,EAAE,EAAE;IAC9BoC,IAAI,EAAE;MACFZ,YAAY,EAAE,CAAC;MACfS,KAAK,EAAE,MAAM;MACbuB,iBAAiB,EAAE,CAAC;MACpBC,iBAAiB,EAAE1D,cAAc,CAAC2D;IACtC;EACJ,CAAwB,CAAC;EAEzB1D,QAAQ,CAAC,2BAA2B,EAAE,EAAE,EAAE;IACtCoC,IAAI,EAAE;MACF9B,WAAW,EAAE,CAAC;MACdwC,YAAY,EAAE,CAAC;MACfa,gBAAgB,EAAE,CAAC;MACnBC,gBAAgB,EAAE;IACtB;EACJ,CAAiB,CAAC;EAElB5D,QAAQ,CAAC,gBAAgB,EAAE,EAAE,EAAE;IAC3BoC,IAAI,EAAE;MACFZ,YAAY,EAAE,CAAC;MACfsB,YAAY,EAAE,CAAC;MACfU,iBAAiB,EAAE,CAAC;MACpBC,iBAAiB,EAAE;IACvB;EACJ,CAAiB,CAAC;AACtB,CAAC,CAAC","ignoreList":[]}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"names":["BASE_THEME","defineStyles","DEFAULT_CLASS","registerStyle","themeVariables","addStyle","defaultStyles","root","minWidth","paddingTop","paddingBottom","paddingLeft","paddingRight","elevation","width","maxHeight","maxModalHeight","backgroundColor","dialogBackgroundColor","borderRadius","text","modal","modalContent","undefined","icon","alignSelf","fontFamily","baseFont","fontSize","fontWeight","color","dialogLabelColor","dialogIconColor","header","flexDirection","borderStyle","borderColor","dialogBorderColor","headerLabel","flex","justifyContent","alignItems","closeBtn","minHeight","marginBottom","rippleColor","transparent","dialogCloseIconColor"],"sources":["dialog.styles.ts"],"sourcesContent":["import { ViewStyle } from 'react-native';\nimport BASE_THEME 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 { WmButtonStyles } from '
|
1
|
+
{"version":3,"names":["BASE_THEME","defineStyles","DEFAULT_CLASS","registerStyle","themeVariables","addStyle","defaultStyles","root","minWidth","paddingTop","paddingBottom","paddingLeft","paddingRight","elevation","width","maxHeight","maxModalHeight","backgroundColor","dialogBackgroundColor","borderRadius","text","modal","modalContent","undefined","icon","alignSelf","fontFamily","baseFont","fontSize","fontWeight","color","dialogLabelColor","dialogIconColor","header","flexDirection","borderStyle","borderColor","dialogBorderColor","headerLabel","flex","justifyContent","alignItems","closeBtn","minHeight","marginBottom","rippleColor","transparent","dialogCloseIconColor"],"sources":["dialog.styles.ts"],"sourcesContent":["import { ViewStyle } from 'react-native';\nimport BASE_THEME 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 { WmButtonStyles } from '@wavemaker/app-rn-runtime/components/basic/button/button.styles';\n\nexport type WmDialogStyles = BaseStyles & {\n modal: ViewStyle,\n modalContent: ViewStyle,\n icon: WmIconStyles,\n closeBtn: WmButtonStyles\n};\n\nexport const DEFAULT_CLASS = 'app-dialog';\nBASE_THEME.registerStyle((themeVariables, addStyle) => {\n const defaultStyles: WmDialogStyles = defineStyles<WmDialogStyles>({\n root: {\n minWidth: 320,\n paddingTop: 24,\n paddingBottom: 24,\n paddingLeft: 24,\n paddingRight: 24,\n elevation: 6,\n width: '90%',\n maxHeight: themeVariables.maxModalHeight,\n backgroundColor: themeVariables.dialogBackgroundColor,\n borderRadius: 28,\n },\n text: {},\n modal: {},\n modalContent: {\n width: undefined\n },\n icon: {\n root: {\n alignSelf: 'center',\n },\n text: {\n fontFamily: themeVariables.baseFont,\n fontSize: 24,\n fontWeight: '400',\n color : themeVariables.dialogLabelColor,\n },\n icon: {\n fontSize: 24,\n color: themeVariables.dialogIconColor\n }\n } as WmIconStyles,\n header: {\n flexDirection: 'row',\n borderStyle: 'solid',\n borderColor: themeVariables.dialogBorderColor\n },\n headerLabel: {\n flex: 1,\n flexDirection: 'row',\n justifyContent: 'flex-start',\n alignItems: 'center',\n paddingBottom: 16,\n },\n closeBtn: {\n root: {\n alignSelf: 'flex-end',\n backgroundColor: 'transparent',\n borderRadius: 8,\n paddingRight: 8,\n paddingTop: 8,\n paddingBottom: 8,\n paddingLeft: 8,\n minHeight: 0,\n marginBottom: 22,\n rippleColor: themeVariables.transparent\n },\n icon : {\n root: {\n alignItems: 'center',\n },\n icon: {\n paddingRight: 0\n },\n text: {\n color: themeVariables.dialogCloseIconColor,\n fontSize: 14\n }\n }\n } as WmButtonStyles\n });\n\n addStyle(DEFAULT_CLASS, '', defaultStyles);\n});"],"mappings":"AACA,OAAOA,UAAU,MAAM,wCAAwC;AAC/D,SAAqBC,YAAY,QAAQ,+CAA+C;AAWxF,OAAO,MAAMC,aAAa,GAAG,YAAY;AACzCF,UAAU,CAACG,aAAa,CAAC,CAACC,cAAc,EAAEC,QAAQ,KAAK;EACnD,MAAMC,aAA6B,GAAGL,YAAY,CAAiB;IAC/DM,IAAI,EAAE;MACFC,QAAQ,EAAE,GAAG;MACbC,UAAU,EAAE,EAAE;MACdC,aAAa,EAAE,EAAE;MACjBC,WAAW,EAAE,EAAE;M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ACFkC,UAAU,EAAE;QAChB,CAAC;QACDjB,IAAI,EAAE;UACFZ,YAAY,EAAE;QAClB,CAAC;QACDQ,IAAI,EAAE;UACFU,KAAK,EAAE1B,cAAc,CAAC2C,oBAAoB;UAC1CnB,QAAQ,EAAE;QACd;MACJ;IACJ;EACJ,CAAC,CAAC;EAEFvB,QAAQ,CAACH,aAAa,EAAE,EAAE,EAAEI,aAAa,CAAC;AAC9C,CAAC,CAAC","ignoreList":[]}
|
@@ -12,6 +12,7 @@ export class BaseInputState extends BaseComponentState {
|
|
12
12
|
super(...args);
|
13
13
|
_defineProperty(this, "keyboardType", 'default');
|
14
14
|
_defineProperty(this, "isValid", true);
|
15
|
+
_defineProperty(this, "isInputFocused", false);
|
15
16
|
_defineProperty(this, "textValue", '');
|
16
17
|
_defineProperty(this, "isDefault", false);
|
17
18
|
_defineProperty(this, "errorType", '');
|
@@ -24,6 +25,7 @@ export class BaseInputComponent extends BaseComponent {
|
|
24
25
|
_defineProperty(this, "widgetRef", null);
|
25
26
|
_defineProperty(this, "isTouched", false);
|
26
27
|
_defineProperty(this, "cursor", 0);
|
28
|
+
_defineProperty(this, "timer", null);
|
27
29
|
}
|
28
30
|
focus() {
|
29
31
|
var _this$widgetRef;
|
@@ -65,17 +67,40 @@ export class BaseInputComponent extends BaseComponent {
|
|
65
67
|
onChange(event) {
|
66
68
|
if (this.state.props.updateon === 'default') {
|
67
69
|
this.updateDatavalue(event.target.value, event);
|
70
|
+
} else if (this.state.props.updateon === 'lazy') {
|
71
|
+
if (this.timer !== null) {
|
72
|
+
clearTimeout(this.timer);
|
73
|
+
this.timer = null;
|
74
|
+
}
|
75
|
+
this.timer = setTimeout(() => {
|
76
|
+
this.updateDatavalue(event.target.value, event);
|
77
|
+
}, 300);
|
68
78
|
}
|
69
79
|
}
|
70
80
|
onChangeText(value) {
|
71
|
-
this.
|
72
|
-
|
73
|
-
|
74
|
-
|
75
|
-
this.validate(value);
|
76
|
-
this.updateDatavalue(value, null);
|
81
|
+
if (this.state.props.updateon === 'lazy') {
|
82
|
+
if (this.timer !== null) {
|
83
|
+
clearTimeout(this.timer);
|
84
|
+
this.timer = null;
|
77
85
|
}
|
78
|
-
|
86
|
+
this.timer = setTimeout(() => {
|
87
|
+
this.updateState({
|
88
|
+
textValue: value
|
89
|
+
}, () => {
|
90
|
+
this.validate(value);
|
91
|
+
this.updateDatavalue(value, null);
|
92
|
+
});
|
93
|
+
}, 300);
|
94
|
+
} else {
|
95
|
+
this.updateState({
|
96
|
+
textValue: value
|
97
|
+
}, () => {
|
98
|
+
if (this.state.props.updateon === 'default') {
|
99
|
+
this.validate(value);
|
100
|
+
this.updateDatavalue(value, null);
|
101
|
+
}
|
102
|
+
});
|
103
|
+
}
|
79
104
|
}
|
80
105
|
invokeChange(e) {
|
81
106
|
if (Platform.OS === 'web') {
|
@@ -99,6 +124,11 @@ export class BaseInputComponent extends BaseComponent {
|
|
99
124
|
new Promise(resolve => {
|
100
125
|
if (props.hastwowaybinding) {
|
101
126
|
this.setProp("datavalue", value);
|
127
|
+
this.updateState({
|
128
|
+
props: {
|
129
|
+
"datavalue": value
|
130
|
+
}
|
131
|
+
});
|
102
132
|
resolve(true);
|
103
133
|
} else {
|
104
134
|
this.updateState({
|
@@ -117,7 +147,7 @@ export class BaseInputComponent extends BaseComponent {
|
|
117
147
|
onBlur(event) {
|
118
148
|
Injector.FOCUSED_ELEMENT.remove();
|
119
149
|
this.isTouched = true;
|
120
|
-
let newVal = this.state.textValue;
|
150
|
+
let newVal = this.state.textValue || '';
|
121
151
|
let oldVal = this.state.props.datavalue || '';
|
122
152
|
this.validate(newVal);
|
123
153
|
if (newVal === '' || newVal == undefined) {
|
@@ -125,12 +155,15 @@ export class BaseInputComponent extends BaseComponent {
|
|
125
155
|
this.props.triggerValidation && this.props.triggerValidation();
|
126
156
|
}, 10);
|
127
157
|
}
|
128
|
-
if (this.state.props.updateon === 'blur') {
|
129
|
-
if (oldVal !== newVal) {
|
158
|
+
if (this.state.props.updateon === 'blur' || this.state.props.updateon === 'default') {
|
159
|
+
if (oldVal !== newVal && this.state.props.updateon === 'blur') {
|
130
160
|
this.updateDatavalue(newVal, event, 'blur');
|
131
161
|
} else {
|
132
162
|
this.invokeEventCallback('onBlur', [event, this.proxy]);
|
133
163
|
}
|
164
|
+
this.setState({
|
165
|
+
isInputFocused: false
|
166
|
+
});
|
134
167
|
}
|
135
168
|
}
|
136
169
|
validate(value) {
|
@@ -149,6 +182,9 @@ export class BaseInputComponent extends BaseComponent {
|
|
149
182
|
this.invokeEventCallback('onFocus', [event, this.proxy]);
|
150
183
|
(_this$closestTappable = this.closestTappable) === null || _this$closestTappable === void 0 || _this$closestTappable.triggerTap();
|
151
184
|
}, 250);
|
185
|
+
this.setState({
|
186
|
+
isInputFocused: true
|
187
|
+
});
|
152
188
|
}
|
153
189
|
onKeyPress(event) {
|
154
190
|
this.invokeEventCallback('onKeypress', [event, this.proxy]);
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"names":["DEFAULT_CLASS","BaseComponent","BaseComponentState","isString","Platform","validateField","Injector","BaseInputState","constructor","args","_defineProperty","BaseInputComponent","props","defaultClass","defaultProps","defaultState","focus","_this$widgetRef","widgetRef","blur","_this$widgetRef2","_this$widgetRef3","onPropertyChange","name","$new","$old","keyboardType","type","updateState","textValue","isDefault","state","onFieldChange","bind","onChange","event","updateon","updateDatavalue","target","value","onChangeText","validate","invokeChange","e","OS","cursor","selectionStart","setState","source","oldValue","datavalue","autotrim","trim","Promise","resolve","hastwowaybinding","setProp","then","invokeEventCallback","proxy","onBlur","FOCUSED_ELEMENT","remove","isTouched","newVal","oldVal","undefined","setTimeout","triggerValidation","validationObj","isValid","errorType","onFocus","_this$closestTappable","set","closestTappable","triggerTap","onKeyPress"],"sources":["baseinput.component.ts"],"sourcesContent":["import { DEFAULT_CLASS } from '@wavemaker/app-rn-runtime/components/navigation/basenav/basenav.styles';\nimport { BaseComponent, BaseComponentState } from '@wavemaker/app-rn-runtime/core/base.component';\nimport BaseInputProps from './baseinput.props';\nimport { isString } from 'lodash';\nimport { BaseInputStyles } from './baseinput.styles';\nimport { Platform, TextInput } from 'react-native';\nimport { validateField } from '@wavemaker/app-rn-runtime/core/utils';\nimport Injector from '@wavemaker/app-rn-runtime/core/injector';\n\nexport class BaseInputState <T extends BaseInputProps> extends BaseComponentState<T> {\n keyboardType: any = 'default';\n isValid: boolean = true;\n textValue: string = '';\n isDefault = false;\n errorType: string = '';\n}\nexport abstract class BaseInputComponent< T extends BaseInputProps, S extends BaseInputState<T>, L extends BaseInputStyles> extends BaseComponent<T, S, L> {\n public widgetRef: TextInput | null = null;\n isTouched: boolean = false;\n private cursor: any = 0;\n constructor(props: T, public defaultClass: string = DEFAULT_CLASS, defaultProps?: T, defaultState?: S) {\n super(props, defaultClass, defaultProps, defaultState);\n }\n\n focus() {\n this?.widgetRef?.focus();\n }\n\n blur() {\n this?.widgetRef?.blur && this?.widgetRef?.blur();\n }\n\n onPropertyChange(name: string, $new: any, $old: any) {\n switch (name) {\n case 'type':\n let keyboardType;\n if (this.props.type === 'number') {\n keyboardType = 'numeric';\n } else if (this.props.type === 'tel') {\n keyboardType = 'phone-pad';\n } else if (this.props.type === 'email') {\n keyboardType = 'email-address';\n }\n this.updateState({\n keyboardType: keyboardType,\n } as S);\n break;\n case 'datavalue':\n this.updateState({\n textValue: $new\n } as S\n );\n const isDefault = this.state.isDefault;\n if (isDefault) {\n this.updateState({ isDefault: false } as S, this.props.onFieldChange && this.props.onFieldChange.bind(this, 'datavalue', $new, $old, isDefault));\n } else {\n this.props.onFieldChange && this.props.onFieldChange('datavalue', $new, $old, isDefault);\n }\n }\n }\n\n onChange(event: any) {\n if (this.state.props.updateon === 'default') {\n this.updateDatavalue(event.target.value, event);\n }\n }\n\n onChangeText(value: any) {\n this.updateState({\n textValue: value\n } as S, () => {\n if (this.state.props.updateon === 'default') {\n this.validate(value);\n this.updateDatavalue(value, null);\n }\n }\n );\n }\n\n invokeChange(e: any) {\n if (Platform.OS === 'web') {\n this.cursor = e.target.selectionStart;\n this.setState({ textValue: e.target.value });\n }\n }\n\n updateDatavalue(value: any, event?: any, source?: any) {\n const props = this.state.props;\n const oldValue = props.datavalue;\n if (value === oldValue) {\n return;\n }\n\n // autotrim\n if (props.autotrim && props.datavalue && isString(props.datavalue)) {\n value = value.trim();\n }\n new Promise((resolve) => {\n if (props.hastwowaybinding) {\n this.setProp(\"datavalue\", value);\n resolve(true);\n } else {\n this.updateState({\n props: {\n datavalue: value\n }\n } as S, () => resolve(true));\n }\n }).then(() => {\n !this.props.onFieldChange && value !== oldValue && this.invokeEventCallback('onChange', [event, this.proxy, value, oldValue]);\n if (source === 'blur') {\n this.invokeEventCallback('onBlur', [ event, this.proxy]);\n }\n })\n }\n\n onBlur(event: any) {\n Injector.FOCUSED_ELEMENT.remove();\n this.isTouched = true;\n let newVal = this.state.textValue;\n let oldVal = this.state.props.datavalue || '';\n this.validate(newVal);\n if (newVal === '' || newVal == undefined) {\n setTimeout(() => {\n this.props.triggerValidation && this.props.triggerValidation();\n },10)\n }\n if (this.state.props.updateon === 'blur') {\n if (oldVal !== newVal) {\n this.updateDatavalue(newVal, event, 'blur');\n } else {\n this.invokeEventCallback('onBlur', [event, this.proxy]);\n }\n }\n }\n\n validate(value: any) {\n const validationObj = validateField(this.state.props, value);\n this.setState({\n isValid: validationObj.isValid,\n errorType: validationObj.errorType\n } as S);\n }\n\n onFocus(event: any) {\n // When input widgets are inside list widget and try to focus the field, list is selecting but unable to enter values in input fields\n // because on tap event of list is triggering after 200ms timeout So added 250ms timeout here\n setTimeout(() => {\n Injector.FOCUSED_ELEMENT.set(this);\n this.invokeEventCallback('onFocus', [ event, this.proxy]);\n this.closestTappable?.triggerTap();\n }, 250);\n\n }\n\n onKeyPress(event: any) {\n this.invokeEventCallback('onKeypress', [ event, this.proxy]);\n }\n}\n"],"mappings":";;;AAAA,SAASA,aAAa,QAAQ,wEAAwE;AACtG,SAASC,aAAa,EAAEC,kBAAkB,QAAQ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AAC;MACzD;IACF;EACF;EAEAlB,QAAQA,CAACF,KAAU,EAAE;IACnB,MAAM8B,aAAa,GAAGhE,aAAa,CAAC,IAAI,CAAC0B,KAAK,CAACnB,KAAK,EAAE2B,KAAK,CAAC;IAC5D,IAAI,CAACQ,QAAQ,CAAC;MACZuB,OAAO,EAAED,aAAa,CAACC,OAAO;MAC9BC,SAAS,EAAEF,aAAa,CAACE;IAC3B,CAAM,CAAC;EACT;EAEAC,OAAOA,CAACrC,KAAU,EAAE;IAClB;IACA;IACAgC,UAAU,CAAC,MAAM;MAAA,IAAAM,qBAAA;MACfnE,QAAQ,CAACuD,eAAe,CAACa,GAAG,CAAC,IAAI,CAAC;MAClC,IAAI,CAAChB,mBAAmB,CAAC,SAAS,EAAE,CAAEvB,KAAK,EAAE,IAAI,CAACwB,KAAK,CAAC,CAAC;MACzD,CAAAc,qBAAA,OAAI,CAACE,eAAe,cAAAF,qBAAA,eAApBA,qBAAA,CAAsBG,UAAU,CAAC,CAAC;IACpC,CAAC,EAAE,GAAG,CAAC;EAET;EAEAC,UAAUA,CAAC1C,KAAU,EAAE;IACrB,IAAI,CAACuB,mBAAmB,CAAC,YAAY,EAAE,CAAEvB,KAAK,EAAE,IAAI,CAACwB,KAAK,CAAC,CAAC;EAC9D;AACF","ignoreList":[]}
|
1
|
+
{"version":3,"names":["DEFAULT_CLASS","BaseComponent","BaseComponentState","isString","Platform","validateField","Injector","BaseInputState","constructor","args","_defineProperty","BaseInputComponent","props","defaultClass","defaultProps","defaultState","focus","_this$widgetRef","widgetRef","blur","_this$widgetRef2","_this$widgetRef3","onPropertyChange","name","$new","$old","keyboardType","type","updateState","textValue","isDefault","state","onFieldChange","bind","onChange","event","updateon","updateDatavalue","target","value","timer","clearTimeout","setTimeout","onChangeText","validate","invokeChange","e","OS","cursor","selectionStart","setState","source","oldValue","datavalue","autotrim","trim","Promise","resolve","hastwowaybinding","setProp","then","invokeEventCallback","proxy","onBlur","FOCUSED_ELEMENT","remove","isTouched","newVal","oldVal","undefined","triggerValidation","isInputFocused","validationObj","isValid","errorType","onFocus","_this$closestTappable","set","closestTappable","triggerTap","onKeyPress"],"sources":["baseinput.component.ts"],"sourcesContent":["import { DEFAULT_CLASS } from '@wavemaker/app-rn-runtime/components/navigation/basenav/basenav.styles';\nimport { BaseComponent, BaseComponentState } from '@wavemaker/app-rn-runtime/core/base.component';\nimport BaseInputProps from './baseinput.props';\nimport { isString } from 'lodash';\nimport { BaseInputStyles } from './baseinput.styles';\nimport { Platform, TextInput } from 'react-native';\nimport { validateField } from '@wavemaker/app-rn-runtime/core/utils';\nimport Injector from '@wavemaker/app-rn-runtime/core/injector';\n\nexport class BaseInputState <T extends BaseInputProps> extends BaseComponentState<T> {\n keyboardType: any = 'default';\n isValid: boolean = true;\n isInputFocused: boolean = false;\n textValue: string = '';\n isDefault = false;\n errorType: string = '';\n}\nexport abstract class BaseInputComponent< T extends BaseInputProps, S extends BaseInputState<T>, L extends BaseInputStyles> extends BaseComponent<T, S, L> {\n public widgetRef: TextInput | null = null;\n isTouched: boolean = false;\n private cursor: any = 0;\n private timer: ReturnType<typeof setTimeout> | null = null;\n constructor(props: T, public defaultClass: string = DEFAULT_CLASS, defaultProps?: T, defaultState?: S) {\n super(props, defaultClass, defaultProps, defaultState);\n }\n\n focus() {\n this?.widgetRef?.focus();\n }\n\n blur() {\n this?.widgetRef?.blur && this?.widgetRef?.blur();\n }\n\n onPropertyChange(name: string, $new: any, $old: any) {\n switch (name) {\n case 'type':\n let keyboardType;\n if (this.props.type === 'number') {\n keyboardType = 'numeric';\n } else if (this.props.type === 'tel') {\n keyboardType = 'phone-pad';\n } else if (this.props.type === 'email') {\n keyboardType = 'email-address';\n }\n this.updateState({\n keyboardType: keyboardType,\n } as S);\n break;\n case 'datavalue':\n this.updateState({\n textValue: $new\n } as S\n );\n const isDefault = this.state.isDefault;\n if (isDefault) {\n this.updateState({ isDefault: false } as S, this.props.onFieldChange && this.props.onFieldChange.bind(this, 'datavalue', $new, $old, isDefault));\n } else {\n this.props.onFieldChange && this.props.onFieldChange('datavalue', $new, $old, isDefault);\n }\n }\n }\n\n onChange(event: any) {\n if (this.state.props.updateon === 'default') {\n this.updateDatavalue(event.target.value, event);\n }else if(this.state.props.updateon === 'lazy') {\n if(this.timer !== null) {\n clearTimeout(this.timer);\n this.timer = null;\n }\n\n this.timer = setTimeout(() => {\n this.updateDatavalue(event.target.value, event);\n }, 300)\n }\n }\n\n onChangeText(value: any) {\n if(this.state.props.updateon === 'lazy') {\n if(this.timer !== null) {\n clearTimeout(this.timer);\n this.timer = null;\n }\n\n this.timer = setTimeout(() => {\n this.updateState({\n textValue: value\n } as S, () => {\n this.validate(value);\n this.updateDatavalue(value, null);\n }\n );\n }, 300)\n }\n else {\n this.updateState({\n textValue: value\n } as S, () => {\n if (this.state.props.updateon === 'default') {\n this.validate(value);\n this.updateDatavalue(value, null);\n }\n }\n );\n }\n }\n\n invokeChange(e: any) {\n if (Platform.OS === 'web') {\n this.cursor = e.target.selectionStart;\n this.setState({ textValue: e.target.value });\n }\n }\n\n updateDatavalue(value: any, event?: any, source?: any) {\n const props = this.state.props;\n const oldValue = props.datavalue;\n if (value === oldValue) {\n return;\n }\n\n // autotrim\n if (props.autotrim && props.datavalue && isString(props.datavalue)) {\n value = value.trim();\n }\n new Promise((resolve) => {\n if (props.hastwowaybinding) {\n this.setProp(\"datavalue\", value);\n this.updateState({props: { \"datavalue\": value }} as S);\n resolve(true);\n } else {\n this.updateState({\n props: {\n datavalue: value\n }\n } as S, () => resolve(true));\n }\n }).then(() => {\n !this.props.onFieldChange && value !== oldValue && this.invokeEventCallback('onChange', [event, this.proxy, value, oldValue]);\n if (source === 'blur') {\n this.invokeEventCallback('onBlur', [ event, this.proxy]);\n }\n })\n }\n\n onBlur(event: any) {\n Injector.FOCUSED_ELEMENT.remove();\n this.isTouched = true;\n let newVal = this.state.textValue || '';\n let oldVal = this.state.props.datavalue || '';\n this.validate(newVal);\n if (newVal === '' || newVal == undefined) {\n setTimeout(() => {\n this.props.triggerValidation && this.props.triggerValidation();\n },10)\n }\n if (this.state.props.updateon === 'blur' || this.state.props.updateon === 'default') {\n if (oldVal !== newVal && this.state.props.updateon === 'blur') {\n this.updateDatavalue(newVal, event, 'blur');\n } else {\n this.invokeEventCallback('onBlur', [event, this.proxy]);\n }\n this.setState({ isInputFocused: false })\n }\n }\n\n validate(value: any) {\n const validationObj = validateField(this.state.props, value);\n this.setState({\n isValid: validationObj.isValid,\n errorType: validationObj.errorType\n } as S);\n }\n\n onFocus(event: any) {\n // When input widgets are inside list widget and try to focus the field, list is selecting but unable to enter values in input fields\n // because on tap event of list is triggering after 200ms timeout So added 250ms timeout here\n setTimeout(() => {\n Injector.FOCUSED_ELEMENT.set(this);\n this.invokeEventCallback('onFocus', [ event, this.proxy]);\n this.closestTappable?.triggerTap();\n }, 250);\n this.setState({ isInputFocused: true })\n }\n\n onKeyPress(event: any) {\n this.invokeEventCallback('onKeypress', [ event, this.proxy]);\n }\n}\n"],"mappings":";;;AAAA,SAASA,aAAa,QAAQ,wEAAwE;AACtG,SAASC,aAAa,EAAEC,kBAAkB,QAAQ,+CAA+C;AAEjG,SAASC,QAAQ,QAAQ,QAAQ;AAEjC,SAASC,QAAQ,QAAmB,cAAc;AAClD,SAASC,aAAa,QAAQ,sCAAsC;AACpE,OAAOC,QAAQ,MAAM,yCAAyC;AAE9D,OAAO,MAAMC,cAAc,SAAoCL,kBAAkB,CAAI;EAAAM,YAAA,GAAAC,IAAA;IAAA,SAAAA,IAAA;IAAAC,eAAA,uBAC/D,SAAS;IAAAA,eAAA,kBACV,IAAI;IAAAA,eAAA,yBACG,KAAK;IAAAA,eAAA,oBACX,EAAE;IAAAA,eAAA,oBACV,KAAK;IAAAA,eAAA,oBACG,EAAE;EAAA;AACxB;AACA,OAAO,MAAeC,kBAAkB,SAA4FV,aAAa,CAAU;EAKzJO,WAAWA,CAACI,KAAQ,EAASC,YAAoB,GAAGb,aAAa,EAAEc,YAAgB,EAAEC,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B,KAAK,CAAC,CAAC;MACzD,CAAAc,qBAAA,OAAI,CAACE,eAAe,cAAAF,qBAAA,eAApBA,qBAAA,CAAsBG,UAAU,CAAC,CAAC;IACpC,CAAC,EAAE,GAAG,CAAC;IACP,IAAI,CAAC7B,QAAQ,CAAC;MAAEqB,cAAc,EAAE;IAAK,CAAC,CAAC;EACzC;EAEAS,UAAUA,CAAC7C,KAAU,EAAE;IACrB,IAAI,CAAC0B,mBAAmB,CAAC,YAAY,EAAE,CAAE1B,KAAK,EAAE,IAAI,CAAC2B,KAAK,CAAC,CAAC;EAC9D;AACF","ignoreList":[]}
|
@@ -10,6 +10,7 @@ export class BaseNumberState extends BaseComponentState {
|
|
10
10
|
constructor(...args) {
|
11
11
|
super(...args);
|
12
12
|
_defineProperty(this, "isValid", true);
|
13
|
+
_defineProperty(this, "isInputFocused", false);
|
13
14
|
_defineProperty(this, "textValue", '');
|
14
15
|
_defineProperty(this, "isDefault", false);
|
15
16
|
_defineProperty(this, "errorType", '');
|
@@ -151,7 +152,7 @@ export class BaseNumberComponent extends BaseComponent {
|
|
151
152
|
if (value === oldValue) {
|
152
153
|
return;
|
153
154
|
}
|
154
|
-
const validNumber = this.isValidNumber(model) || value
|
155
|
+
const validNumber = this.isValidNumber(model) || value === oldValue + '.';
|
155
156
|
if (!validNumber) {
|
156
157
|
this.invokeEventCallback('onError', [event, this.proxy, value, oldValue]);
|
157
158
|
return;
|
@@ -159,6 +160,11 @@ export class BaseNumberComponent extends BaseComponent {
|
|
159
160
|
new Promise(resolve => {
|
160
161
|
if (props.hastwowaybinding) {
|
161
162
|
this.setProp("datavalue", value);
|
163
|
+
setTimeout(() => this.updateState({
|
164
|
+
props: {
|
165
|
+
"datavalue": value
|
166
|
+
}
|
167
|
+
}), 0);
|
162
168
|
resolve(true);
|
163
169
|
} else {
|
164
170
|
this.updateState({
|
@@ -175,24 +181,31 @@ export class BaseNumberComponent extends BaseComponent {
|
|
175
181
|
});
|
176
182
|
}
|
177
183
|
onBlur(event, isDisplayValuePresent) {
|
178
|
-
|
184
|
+
const textVal = this.state.textValue || '';
|
185
|
+
let newVal = isDisplayValuePresent ? textVal : event.target.value || textVal;
|
179
186
|
this.validate(newVal);
|
180
187
|
if (newVal === '' || newVal == undefined) {
|
181
188
|
setTimeout(() => {
|
182
189
|
this.props.triggerValidation && this.props.triggerValidation();
|
183
190
|
}, 10);
|
184
191
|
}
|
185
|
-
if (this.state.props.updateon === 'blur') {
|
192
|
+
if (this.state.props.updateon === 'blur' || this.state.props.updateon === 'default') {
|
186
193
|
let oldVal = this.state.props.datavalue || '';
|
187
|
-
if (oldVal !== newVal) {
|
194
|
+
if (oldVal !== newVal && this.state.props.updateon === 'blur') {
|
188
195
|
this.updateDatavalue(newVal, event, 'blur');
|
189
196
|
} else {
|
190
197
|
this.invokeEventCallback('onBlur', [event, this.proxy]);
|
191
198
|
}
|
199
|
+
this.setState({
|
200
|
+
isInputFocused: false
|
201
|
+
});
|
192
202
|
}
|
193
203
|
}
|
194
204
|
onFocus(event) {
|
195
205
|
this.invokeEventCallback('onFocus', [event, this.proxy]);
|
206
|
+
this.setState({
|
207
|
+
isInputFocused: true
|
208
|
+
});
|
196
209
|
}
|
197
210
|
|
198
211
|
/**
|
@@ -245,13 +258,13 @@ export class BaseNumberComponent extends BaseComponent {
|
|
245
258
|
*/
|
246
259
|
getValueInRange(value) {
|
247
260
|
const props = this.state.props;
|
248
|
-
if (!isNil(value) && !isNaN(props.minvalue) && value < props.minvalue) {
|
261
|
+
if (props.minvalue && !isNil(value) && !isNaN(props.minvalue) && value < props.minvalue) {
|
249
262
|
this.updateState({
|
250
263
|
errorType: 'minvalue'
|
251
264
|
});
|
252
265
|
return props.minvalue;
|
253
266
|
}
|
254
|
-
if (!isNil(value) && !isNaN(props.maxvalue) && value > props.maxvalue) {
|
267
|
+
if (props.maxvalue && !isNil(value) && !isNaN(props.maxvalue) && value > props.maxvalue) {
|
255
268
|
this.updateState({
|
256
269
|
errorType: 'maxvalue'
|
257
270
|
});
|