@wavemaker/app-rn-runtime 11.6.1-rc.5513 → 11.6.1-rc.5518
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- app-rn-runtime/components/advanced/carousel/carousel.component.js +7 -9
- app-rn-runtime/components/advanced/carousel/carousel.component.js.map +1 -1
- app-rn-runtime/components/advanced/webview/webview.component.js +11 -27
- app-rn-runtime/components/advanced/webview/webview.component.js.map +1 -1
- app-rn-runtime/components/advanced/webview/webview.props.js +1 -0
- app-rn-runtime/components/advanced/webview/webview.props.js.map +1 -1
- app-rn-runtime/components/basic/anchor/anchor.component.js +1 -2
- app-rn-runtime/components/basic/anchor/anchor.component.js.map +1 -1
- app-rn-runtime/components/basic/anchor/anchor.props.js +0 -1
- app-rn-runtime/components/basic/anchor/anchor.props.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/buttongroup/buttongroup.styles.js +4 -9
- app-rn-runtime/components/basic/buttongroup/buttongroup.styles.js.map +1 -1
- app-rn-runtime/components/basic/label/label.component.js +29 -41
- app-rn-runtime/components/basic/label/label.component.js.map +1 -1
- app-rn-runtime/components/basic/label/label.styles.js +4 -1
- app-rn-runtime/components/basic/label/label.styles.js.map +1 -1
- app-rn-runtime/components/basic/search/search.component.js +2 -8
- app-rn-runtime/components/basic/search/search.component.js.map +1 -1
- app-rn-runtime/components/basic/search/search.props.js +0 -1
- app-rn-runtime/components/basic/search/search.props.js.map +1 -1
- app-rn-runtime/components/basic/skeleton/skeleton.component.js +0 -1
- app-rn-runtime/components/basic/skeleton/skeleton.component.js.map +1 -1
- app-rn-runtime/components/chart/area-chart/area-chart.component.js +8 -11
- app-rn-runtime/components/chart/area-chart/area-chart.component.js.map +1 -1
- app-rn-runtime/components/chart/bar-chart/bar-chart.component.js +0 -6
- app-rn-runtime/components/chart/bar-chart/bar-chart.component.js.map +1 -1
- app-rn-runtime/components/chart/bar-chart/bar-chart.props.js +2 -0
- app-rn-runtime/components/chart/bar-chart/bar-chart.props.js.map +1 -1
- app-rn-runtime/components/chart/basechart.component.js +6 -19
- app-rn-runtime/components/chart/basechart.component.js.map +1 -1
- app-rn-runtime/components/chart/basechart.props.js +2 -4
- app-rn-runtime/components/chart/basechart.props.js.map +1 -1
- app-rn-runtime/components/chart/basechart.styles.js +1 -7
- app-rn-runtime/components/chart/basechart.styles.js.map +1 -1
- app-rn-runtime/components/chart/line-chart/line-chart.component.js +3 -5
- app-rn-runtime/components/chart/line-chart/line-chart.component.js.map +1 -1
- app-rn-runtime/components/chart/stack-chart/stack-chart.component.js +16 -44
- app-rn-runtime/components/chart/stack-chart/stack-chart.component.js.map +1 -1
- app-rn-runtime/components/chart/stack-chart/stack-chart.props.js +0 -1
- app-rn-runtime/components/chart/stack-chart/stack-chart.props.js.map +1 -1
- app-rn-runtime/components/container/container.component.js +1 -10
- app-rn-runtime/components/container/container.component.js.map +1 -1
- app-rn-runtime/components/container/container.props.js +0 -1
- app-rn-runtime/components/container/container.props.js.map +1 -1
- app-rn-runtime/components/container/tabs/tabheader/tabheader.component.js +1 -1
- app-rn-runtime/components/container/tabs/tabheader/tabheader.component.js.map +1 -1
- app-rn-runtime/components/container/tabs/tabpane/tabpane.component.js +12 -2
- app-rn-runtime/components/container/tabs/tabpane/tabpane.component.js.map +1 -1
- app-rn-runtime/components/container/wizard/wizard.component.js +8 -13
- app-rn-runtime/components/container/wizard/wizard.component.js.map +1 -1
- app-rn-runtime/components/container/wizard/wizardstep/wizardstep.component.js +2 -24
- app-rn-runtime/components/container/wizard/wizardstep/wizardstep.component.js.map +1 -1
- app-rn-runtime/components/container/wizard/wizardstep/wizardstep.props.js +0 -6
- app-rn-runtime/components/container/wizard/wizardstep/wizardstep.props.js.map +1 -1
- app-rn-runtime/components/data/form/form-action/form-action.component.js +1 -0
- app-rn-runtime/components/data/form/form-action/form-action.component.js.map +1 -1
- app-rn-runtime/components/data/form/form-action/form-action.props.js +1 -0
- app-rn-runtime/components/data/form/form-action/form-action.props.js.map +1 -1
- app-rn-runtime/components/data/form/form-field/form-field.component.js +1 -5
- app-rn-runtime/components/data/form/form-field/form-field.component.js.map +1 -1
- app-rn-runtime/components/data/list/list.component.js +64 -8
- 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 +0 -3
- app-rn-runtime/components/data/list/list.styles.js.map +1 -1
- app-rn-runtime/components/input/baseinput/baseinput.component.js +2 -2
- app-rn-runtime/components/input/baseinput/baseinput.component.js.map +1 -1
- app-rn-runtime/components/input/basenumber/basenumber.component.js +5 -5
- app-rn-runtime/components/input/basenumber/basenumber.component.js.map +1 -1
- app-rn-runtime/components/input/checkbox/checkbox.component.js +5 -5
- app-rn-runtime/components/input/checkbox/checkbox.component.js.map +1 -1
- app-rn-runtime/components/input/checkbox/checkbox.styles.js +35 -5
- app-rn-runtime/components/input/checkbox/checkbox.styles.js.map +1 -1
- app-rn-runtime/components/input/checkboxset/checkboxset.component.js +9 -18
- app-rn-runtime/components/input/checkboxset/checkboxset.component.js.map +1 -1
- app-rn-runtime/components/input/checkboxset/checkboxset.props.js +0 -1
- app-rn-runtime/components/input/checkboxset/checkboxset.props.js.map +1 -1
- app-rn-runtime/components/input/checkboxset/checkboxset.styles.js +39 -10
- app-rn-runtime/components/input/checkboxset/checkboxset.styles.js.map +1 -1
- app-rn-runtime/components/input/composite/composite.component.js +1 -1
- app-rn-runtime/components/input/composite/composite.component.js.map +1 -1
- app-rn-runtime/components/input/composite/composite.props.js +1 -1
- app-rn-runtime/components/input/composite/composite.props.js.map +1 -1
- app-rn-runtime/components/input/currency/currency.component.js +17 -3
- app-rn-runtime/components/input/currency/currency.component.js.map +1 -1
- app-rn-runtime/components/input/currency/currency.props.js +1 -0
- app-rn-runtime/components/input/currency/currency.props.js.map +1 -1
- app-rn-runtime/components/input/currency/currency.styles.js +19 -1
- app-rn-runtime/components/input/currency/currency.styles.js.map +1 -1
- app-rn-runtime/components/input/epoch/base-datetime.component.js +68 -6
- app-rn-runtime/components/input/epoch/base-datetime.component.js.map +1 -1
- app-rn-runtime/components/input/epoch/date/date.component.js +8 -0
- app-rn-runtime/components/input/epoch/date/date.component.js.map +1 -1
- app-rn-runtime/components/input/epoch/date/date.styles.js +16 -0
- app-rn-runtime/components/input/epoch/date/date.styles.js.map +1 -1
- app-rn-runtime/components/input/epoch/datetime/datetime.component.js +8 -0
- app-rn-runtime/components/input/epoch/datetime/datetime.component.js.map +1 -1
- app-rn-runtime/components/input/epoch/datetime/datetime.props.js +1 -0
- app-rn-runtime/components/input/epoch/datetime/datetime.props.js.map +1 -1
- app-rn-runtime/components/input/epoch/datetime/datetime.styles.js +49 -1
- app-rn-runtime/components/input/epoch/datetime/datetime.styles.js.map +1 -1
- app-rn-runtime/components/input/epoch/time/time.component.js +8 -0
- app-rn-runtime/components/input/epoch/time/time.component.js.map +1 -1
- app-rn-runtime/components/input/epoch/time/time.styles.js +16 -0
- app-rn-runtime/components/input/epoch/time/time.styles.js.map +1 -1
- app-rn-runtime/components/input/number/number.component.js +11 -1
- app-rn-runtime/components/input/number/number.component.js.map +1 -1
- app-rn-runtime/components/input/number/number.props.js +1 -0
- app-rn-runtime/components/input/number/number.props.js.map +1 -1
- app-rn-runtime/components/input/number/number.styles.js +17 -0
- app-rn-runtime/components/input/number/number.styles.js.map +1 -1
- app-rn-runtime/components/input/radioset/radioset.component.js +2 -6
- app-rn-runtime/components/input/radioset/radioset.component.js.map +1 -1
- app-rn-runtime/components/input/slider/slider.component.js +3 -2
- app-rn-runtime/components/input/slider/slider.component.js.map +1 -1
- app-rn-runtime/components/input/text/text.component.js +11 -0
- app-rn-runtime/components/input/text/text.component.js.map +1 -1
- app-rn-runtime/components/input/text/text.props.js +1 -0
- app-rn-runtime/components/input/text/text.props.js.map +1 -1
- app-rn-runtime/components/input/text/text.styles.js +17 -0
- app-rn-runtime/components/input/text/text.styles.js.map +1 -1
- app-rn-runtime/components/input/textarea/textarea.component.js +11 -0
- app-rn-runtime/components/input/textarea/textarea.component.js.map +1 -1
- app-rn-runtime/components/input/textarea/textarea.props.js +1 -0
- app-rn-runtime/components/input/textarea/textarea.props.js.map +1 -1
- app-rn-runtime/components/input/textarea/textarea.styles.js +17 -0
- app-rn-runtime/components/input/textarea/textarea.styles.js.map +1 -1
- app-rn-runtime/components/input/toggle/toggle.component.js +3 -2
- app-rn-runtime/components/input/toggle/toggle.component.js.map +1 -1
- app-rn-runtime/components/navigation/appnavbar/appnavbar.component.js +1 -6
- app-rn-runtime/components/navigation/appnavbar/appnavbar.component.js.map +1 -1
- app-rn-runtime/components/navigation/appnavbar/appnavbar.props.js +0 -1
- app-rn-runtime/components/navigation/appnavbar/appnavbar.props.js.map +1 -1
- app-rn-runtime/components/navigation/appnavbar/appnavbar.styles.js +0 -6
- app-rn-runtime/components/navigation/appnavbar/appnavbar.styles.js.map +1 -1
- app-rn-runtime/components/navigation/navbar/navbar.props.js.map +1 -1
- app-rn-runtime/components/navigation/navitem/navitem.component.js.map +1 -1
- app-rn-runtime/components/navigation/navitem/navitem.props.js.map +1 -1
- app-rn-runtime/components/navigation/popover/popover.component.js.map +1 -1
- app-rn-runtime/components/page/page-content/page-content.component.js +2 -0
- app-rn-runtime/components/page/page-content/page-content.component.js.map +1 -1
- app-rn-runtime/components/page/tabbar/curve.js +84 -0
- app-rn-runtime/components/page/tabbar/curve.js.map +1 -0
- app-rn-runtime/components/page/tabbar/tabbar.component.js +43 -9
- app-rn-runtime/components/page/tabbar/tabbar.component.js.map +1 -1
- app-rn-runtime/components/page/tabbar/tabbar.styles.js +54 -1
- app-rn-runtime/components/page/tabbar/tabbar.styles.js.map +1 -1
- app-rn-runtime/core/base.component.js +17 -5
- app-rn-runtime/core/base.component.js.map +1 -1
- app-rn-runtime/core/components/floatinglabel.component.js +45 -0
- app-rn-runtime/core/components/floatinglabel.component.js.map +1 -0
- app-rn-runtime/core/components/textinput.component.js +9 -1
- app-rn-runtime/core/components/textinput.component.js.map +1 -1
- app-rn-runtime/core/formatters.js +1 -14
- app-rn-runtime/core/formatters.js.map +1 -1
- app-rn-runtime/core/tappable.component.js +36 -49
- app-rn-runtime/core/tappable.component.js.map +1 -1
- app-rn-runtime/gestures/swipe.animation.js +34 -1
- app-rn-runtime/gestures/swipe.animation.js.map +1 -1
- app-rn-runtime/package.json +5 -3
- app-rn-runtime/runtime/App.js +13 -7
- app-rn-runtime/runtime/App.js.map +1 -1
- app-rn-runtime/runtime/base-fragment.component.js +2 -1
- app-rn-runtime/runtime/base-fragment.component.js.map +1 -1
- app-rn-runtime/runtime/base-page.component.js +11 -3
- app-rn-runtime/runtime/base-page.component.js.map +1 -1
- app-rn-runtime/runtime/services/app-security.service.js +23 -8
- app-rn-runtime/runtime/services/app-security.service.js.map +1 -1
- app-rn-runtime/runtime/services/webprocess.service.js +1 -0
- app-rn-runtime/runtime/services/webprocess.service.js.map +1 -1
- app-rn-runtime/styles/background.component.js +12 -1
- app-rn-runtime/styles/background.component.js.map +1 -1
- app-rn-runtime/styles/theme.js +32 -12
- app-rn-runtime/styles/theme.js.map +1 -1
- app-rn-runtime/styles/theme.variables.js +7 -3
- app-rn-runtime/styles/theme.variables.js.map +1 -1
- app-rn-runtime/variables/device/device/network-info.operation.js +23 -3
- app-rn-runtime/variables/device/device/network-info.operation.js.map +1 -1
- app-rn-runtime/variables/device/operation.provider.js.map +1 -1
- app-rn-runtime/variables/device-variable.js +1 -1
- app-rn-runtime/variables/device-variable.js.map +1 -1
- app-rn-runtime/variables/model-variable.js +1 -2
- app-rn-runtime/variables/model-variable.js.map +1 -1
|
@@ -8,26 +8,56 @@ BASE_THEME.registerStyle((themeVariables, addStyle) => {
|
|
|
8
8
|
alignContent: 'center'
|
|
9
9
|
},
|
|
10
10
|
text: {
|
|
11
|
-
color: themeVariables.checkedColor
|
|
12
|
-
},
|
|
13
|
-
checkboxLabel: {
|
|
14
11
|
alignSelf: 'center',
|
|
15
12
|
fontFamily: themeVariables.baseFont,
|
|
16
13
|
fontSize: 16,
|
|
17
|
-
color: themeVariables.labelDefaultColor
|
|
14
|
+
color: themeVariables.labelDefaultColor,
|
|
15
|
+
marginLeft: 8
|
|
18
16
|
},
|
|
19
17
|
skeleton: {
|
|
20
18
|
root: {
|
|
21
19
|
width: '100%',
|
|
22
20
|
height: 16
|
|
23
21
|
}
|
|
22
|
+
},
|
|
23
|
+
checkicon: {
|
|
24
|
+
root: {
|
|
25
|
+
width: 20,
|
|
26
|
+
height: 20,
|
|
27
|
+
borderRadius: 4,
|
|
28
|
+
backgroundColor: themeVariables.primaryColor,
|
|
29
|
+
justifyContent: 'center',
|
|
30
|
+
alignItems: 'center',
|
|
31
|
+
borderColor: themeVariables.checkedBorderColor
|
|
32
|
+
},
|
|
33
|
+
text: {
|
|
34
|
+
fontSize: 18
|
|
35
|
+
},
|
|
36
|
+
icon: {
|
|
37
|
+
color: themeVariables.checkedIconColor,
|
|
38
|
+
padding: 0
|
|
39
|
+
}
|
|
40
|
+
},
|
|
41
|
+
uncheckicon: {
|
|
42
|
+
root: {
|
|
43
|
+
width: 20,
|
|
44
|
+
height: 20,
|
|
45
|
+
borderWidth: 2,
|
|
46
|
+
borderRadius: 4,
|
|
47
|
+
borderColor: themeVariables.uncheckedBorderColor,
|
|
48
|
+
backgroundColor: themeVariables.uncheckedBgColor
|
|
49
|
+
},
|
|
50
|
+
text: {},
|
|
51
|
+
icon: {
|
|
52
|
+
color: 'transparent'
|
|
53
|
+
}
|
|
24
54
|
}
|
|
25
55
|
});
|
|
26
56
|
addStyle(DEFAULT_CLASS + '-disabled', '', {
|
|
27
57
|
root: {
|
|
28
58
|
opacity: 0.8
|
|
29
59
|
},
|
|
30
|
-
|
|
60
|
+
text: {
|
|
31
61
|
color: themeVariables.checkedDisabledColor
|
|
32
62
|
}
|
|
33
63
|
});
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["BASE_THEME","defineStyles","DEFAULT_CLASS","registerStyle","themeVariables","addStyle","defaultStyles","root","flexDirection","alignContent","text","color","
|
|
1
|
+
{"version":3,"names":["BASE_THEME","defineStyles","DEFAULT_CLASS","registerStyle","themeVariables","addStyle","defaultStyles","root","flexDirection","alignContent","text","alignSelf","fontFamily","baseFont","fontSize","color","labelDefaultColor","marginLeft","skeleton","width","height","checkicon","borderRadius","backgroundColor","primaryColor","justifyContent","alignItems","borderColor","checkedBorderColor","icon","checkedIconColor","padding","uncheckicon","borderWidth","uncheckedBorderColor","uncheckedBgColor","opacity","checkedDisabledColor"],"sources":["checkbox.styles.ts"],"sourcesContent":["import BASE_THEME, { AllStyle } from '@wavemaker/app-rn-runtime/styles/theme';\nimport { BaseStyles, defineStyles } from '@wavemaker/app-rn-runtime/core/base.component';\nimport { WmSkeletonStyles } from '../../basic/skeleton/skeleton.styles';\nimport { WmIconStyles } from '../../basic/icon/icon.styles';\n\nexport type WmCheckboxStyles = BaseStyles & {\n skeleton: WmSkeletonStyles;\n checkicon: WmIconStyles;\n uncheckicon: WmIconStyles;\n};\n\nexport const DEFAULT_CLASS = 'app-checkbox';\nBASE_THEME.registerStyle((themeVariables, addStyle) => {\n const defaultStyles: WmCheckboxStyles = defineStyles({\n root: {\n flexDirection: 'row',\n alignContent: 'center',\n },\n text: {\n alignSelf: 'center',\n fontFamily: themeVariables.baseFont,\n fontSize: 16,\n color: themeVariables.labelDefaultColor,\n marginLeft: 8\n },\n skeleton: {\n root: {\n width: '100%',\n height: 16\n }\n } as any as WmSkeletonStyles,\n checkicon : {\n root: {\n width: 20,\n height: 20,\n borderRadius: 4,\n backgroundColor: themeVariables.primaryColor,\n justifyContent: 'center',\n alignItems: 'center',\n borderColor: themeVariables.checkedBorderColor,\n },\n text: {\n fontSize: 18,\n },\n icon : {\n color: themeVariables.checkedIconColor,\n padding: 0\n }\n } as WmIconStyles,\n uncheckicon : {\n root: {\n width: 20,\n height: 20,\n borderWidth: 2,\n borderRadius: 4,\n borderColor: themeVariables.uncheckedBorderColor,\n backgroundColor: themeVariables.uncheckedBgColor,\n },\n text: {},\n icon : {\n color: 'transparent',\n }\n } as WmIconStyles,\n });\n\n\n addStyle(DEFAULT_CLASS + '-disabled', '', {\n root : {\n opacity: 0.8\n },\n text : {\n color: themeVariables.checkedDisabledColor\n }\n });\n\n addStyle(DEFAULT_CLASS, '', defaultStyles);\n });\n"],"mappings":"AAAA,OAAOA,UAAU,MAAoB,wCAAwC;AAC7E,SAAqBC,YAAY,QAAQ,+CAA+C;AAUxF,OAAO,MAAMC,aAAa,GAAG,cAAc;AAC3CF,UAAU,CAACG,aAAa,CAAC,CAACC,cAAc,EAAEC,QAAQ,KAAK;EACnD,MAAMC,aAA+B,GAAGL,YAAY,CAAC;IACjDM,IAAI,EAAE;MACJC,aAAa,EAAE,KAAK;MACpBC,YAAY,EAAE;IAChB,CAAC;IACDC,IAAI,EAAE;MACJC,SAAS,EAAE,QAAQ;MACnBC,UAAU,EAAER,cAAc,CAACS,QAAQ;MACnCC,QAAQ,EAAE,EAAE;MACZC,KAAK,EAAEX,cAAc,CAACY,iBAAiB;MACvCC,UAAU,EAAE;IACd,CAAC;IACDC,QAAQ,EAAE;MACRX,IAAI,EAAE;QACJY,KAAK,EAAE,MAAM;QACbC,MAAM,EAAE;MACV;IACF,CAA4B;IAC5BC,SAAS,EAAG;MACVd,IAAI,EAAE;QACJY,KAAK,EAAE,EAAE;QACTC,MAAM,EAAE,EAAE;QACVE,YAAY,EAAE,CAAC;QACfC,eAAe,EAAEnB,cAAc,CAACoB,YAAY;QAC5CC,cAAc,EAAE,QAAQ;QACxBC,UAAU,EAAE,QAAQ;QACpBC,WAAW,EAAEvB,cAAc,CAACwB;MAC9B,CAAC;MACDlB,IAAI,EAAE;QACJI,QAAQ,EAAE;MACZ,CAAC;MACDe,IAAI,EAAG;QACLd,KAAK,EAAEX,cAAc,CAAC0B,gBAAgB;QACtCC,OAAO,EAAE;MACX;IACJ,CAAiB;IACfC,WAAW,EAAG;MACZzB,IAAI,EAAE;QACJY,KAAK,EAAE,EAAE;QACTC,MAAM,EAAE,EAAE;QACVa,WAAW,EAAE,CAAC;QACdX,YAAY,EAAE,CAAC;QACfK,WAAW,EAAEvB,cAAc,CAAC8B,oBAAoB;QAChDX,eAAe,EAAEnB,cAAc,CAAC+B;MAClC,CAAC;MACDzB,IAAI,EAAE,CAAC,CAAC;MACRmB,IAAI,EAAG;QACLd,KAAK,EAAE;MACT;IACJ;EACA,CAAC,CAAC;EAGJV,QAAQ,CAACH,aAAa,GAAG,WAAW,EAAE,EAAE,EAAE;IACxCK,IAAI,EAAG;MACL6B,OAAO,EAAE;IACX,CAAC;IACD1B,IAAI,EAAG;MACLK,KAAK,EAAEX,cAAc,CAACiC;IACxB;EACF,CAAC,CAAC;EAEFhC,QAAQ,CAACH,aAAa,EAAE,EAAE,EAAEI,aAAa,CAAC;AAC5C,CAAC,CAAC"}
|
|
@@ -4,17 +4,15 @@ function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return typ
|
|
|
4
4
|
function _toPrimitive(input, hint) { if (typeof input !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (typeof res !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
|
|
5
5
|
import React from 'react';
|
|
6
6
|
import { Text, View, TouchableOpacity } from 'react-native';
|
|
7
|
-
import { find, forEach, isEqual
|
|
8
|
-
import { Checkbox } from 'react-native-paper';
|
|
9
|
-
import { ScrollView } from 'react-native-gesture-handler';
|
|
7
|
+
import { find, forEach, isEqual } from 'lodash';
|
|
10
8
|
import WmCheckboxsetProps from './checkboxset.props';
|
|
11
9
|
import { DEFAULT_CLASS } from './checkboxset.styles';
|
|
12
10
|
import { BaseDatasetComponent, BaseDatasetState } from '@wavemaker/app-rn-runtime/components/input/basedataset/basedataset.component';
|
|
11
|
+
import WmIcon from '../../basic/icon/icon.component';
|
|
13
12
|
export class WmCheckboxsetState extends BaseDatasetState {
|
|
14
13
|
constructor() {
|
|
15
14
|
super(...arguments);
|
|
16
15
|
_defineProperty(this, "isValid", true);
|
|
17
|
-
_defineProperty(this, "template", "");
|
|
18
16
|
}
|
|
19
17
|
}
|
|
20
18
|
export default class WmCheckboxset extends BaseDatasetComponent {
|
|
@@ -50,14 +48,14 @@ export default class WmCheckboxset extends BaseDatasetComponent {
|
|
|
50
48
|
const props = this.state.props;
|
|
51
49
|
const displayText = item.displayexp || item.displayfield;
|
|
52
50
|
return /*#__PURE__*/React.createElement(TouchableOpacity, _extends({}, this.getTestPropsForAction(index + ''), {
|
|
53
|
-
style:
|
|
51
|
+
style: this.styles.item,
|
|
54
52
|
onPress: this.onPress.bind(this, item),
|
|
55
53
|
key: item.key
|
|
56
|
-
}), /*#__PURE__*/React.createElement(
|
|
57
|
-
|
|
58
|
-
|
|
54
|
+
}), /*#__PURE__*/React.createElement(WmIcon, {
|
|
55
|
+
iconclass: "wi wi-check",
|
|
56
|
+
styles: item.selected ? this.styles.checkicon : this.styles.uncheckicon,
|
|
59
57
|
disabled: props.readonly || props.disabled
|
|
60
|
-
}),
|
|
58
|
+
}), /*#__PURE__*/React.createElement(Text, _extends({}, this.getTestPropsForLabel(index + ''), {
|
|
61
59
|
style: this.styles.text
|
|
62
60
|
}), displayText));
|
|
63
61
|
}
|
|
@@ -76,11 +74,6 @@ export default class WmCheckboxset extends BaseDatasetComponent {
|
|
|
76
74
|
});
|
|
77
75
|
return Promise.resolve();
|
|
78
76
|
}
|
|
79
|
-
setTemplate(partialName) {
|
|
80
|
-
this.updateState({
|
|
81
|
-
template: partialName
|
|
82
|
-
});
|
|
83
|
-
}
|
|
84
77
|
renderGroupby() {
|
|
85
78
|
const groupedData = this.state.groupedData;
|
|
86
79
|
return /*#__PURE__*/React.createElement(View, null, groupedData && groupedData.length ? groupedData.map((groupObj, index) => {
|
|
@@ -97,11 +90,9 @@ export default class WmCheckboxset extends BaseDatasetComponent {
|
|
|
97
90
|
}
|
|
98
91
|
renderWidget(props) {
|
|
99
92
|
const items = this.state.dataItems;
|
|
100
|
-
return /*#__PURE__*/React.createElement(
|
|
93
|
+
return /*#__PURE__*/React.createElement(View, {
|
|
101
94
|
style: this.styles.root
|
|
102
|
-
},
|
|
103
|
-
horizontal: true
|
|
104
|
-
}, props.groupby && this.renderGroupby(), !props.groupby && this.renderCheckboxses(items)));
|
|
95
|
+
}, props.groupby && this.renderGroupby(), !props.groupby && this.renderCheckboxses(items));
|
|
105
96
|
}
|
|
106
97
|
}
|
|
107
98
|
//# sourceMappingURL=checkboxset.component.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["React","Text","View","TouchableOpacity","find","forEach","isEqual","
|
|
1
|
+
{"version":3,"names":["React","Text","View","TouchableOpacity","find","forEach","isEqual","WmCheckboxsetProps","DEFAULT_CLASS","BaseDatasetComponent","BaseDatasetState","WmIcon","WmCheckboxsetState","constructor","arguments","_defineProperty","WmCheckboxset","props","onPress","item","invokeEventCallback","proxy","state","disabled","readonly","selected","selectedValue","selectedItem","dataItems","d","key","oldValue","datavalue","push","datafield","validate","updateState","computeDisplayValue","undefined","renderChild","index","displayText","displayexp","displayfield","createElement","_extends","getTestPropsForAction","style","styles","bind","iconclass","checkicon","uncheckicon","getTestPropsForLabel","text","displayValue","filter","map","updateDatavalue","value","Promise","resolve","renderGroupby","groupedData","length","groupObj","groupHeaderTitle","renderCheckboxses","data","items","renderWidget","root","groupby"],"sources":["checkboxset.component.tsx"],"sourcesContent":["import React from 'react';\nimport { Text, View, TouchableOpacity } from 'react-native';\nimport { find, forEach, isEqual } from 'lodash';\nimport { Checkbox } from 'react-native-paper';\n\nimport WmCheckboxsetProps from './checkboxset.props';\nimport {\n DEFAULT_CLASS,\n \n WmCheckboxsetStyles,\n} from './checkboxset.styles';\nimport {\n BaseDatasetComponent,\n BaseDatasetState,\n} from '@wavemaker/app-rn-runtime/components/input/basedataset/basedataset.component';\nimport WmSkeleton, { createSkeleton } from '../../basic/skeleton/skeleton.component';\nimport WmIcon from '../../basic/icon/icon.component';\n\nexport class WmCheckboxsetState extends BaseDatasetState<WmCheckboxsetProps> {\n isValid: boolean = true;\n}\n\nexport default class WmCheckboxset extends BaseDatasetComponent<WmCheckboxsetProps, WmCheckboxsetState, WmCheckboxsetStyles> {\n constructor(props: WmCheckboxsetProps) {\n super(props, DEFAULT_CLASS, new WmCheckboxsetProps());\n }\n\n onPress(item: any) {\n this.invokeEventCallback('onTap', [null, this.proxy]);\n if (this.state.props.disabled || this.state.props.readonly) {\n return;\n }\n item.selected = !item.selected;\n const selectedValue: any = [];\n const selectedItem = find(this.state.dataItems, d => isEqual(d.key, item.key));\n const oldValue = this.state.props.datavalue;\n selectedItem.selected = item.selected;\n forEach(this.state.dataItems, (item) => {\n if (item.selected) {\n selectedValue.push(item.datafield);\n }\n });\n this.validate(selectedValue);\n this.updateState({ props: { datavalue: selectedValue }} as WmCheckboxsetState,\n () => {\n this.computeDisplayValue();\n this.invokeEventCallback('onChange', [ undefined, this.proxy, selectedValue, oldValue ]);\n });\n }\n\n renderChild(item: any, index: any) {\n const props = this.state.props;\n const displayText = item.displayexp || item.displayfield;\n return (\n <TouchableOpacity {...this.getTestPropsForAction(index + '')}\n style={this.styles.item}\n onPress={this.onPress.bind(this, item)} key={item.key}>\n <WmIcon iconclass=\"wi wi-check\" styles={item.selected? this.styles.checkicon : this.styles.uncheckicon} disabled={props.readonly || props.disabled}/>\n <Text {...this.getTestPropsForLabel(index + '')} style={this.styles.text}>{displayText}</Text>\n </TouchableOpacity>)\n }\n\n computeDisplayValue() {\n this.updateState({\n props: {\n displayValue: ((this.state.dataItems || [] as any)\n .filter((item: any) => item.selected)\n .map((item: any) => item.displayexp || item.displayfield)) || ''\n }\n } as WmCheckboxsetState);\n }\n\n updateDatavalue(value: any) {\n this.updateState({ props: { datavalue: value }} as WmCheckboxsetState);\n return Promise.resolve();\n }\n\n renderGroupby() {\n const groupedData = this.state.groupedData;\n return (\n <View>\n {groupedData && groupedData.length\n ? groupedData.map((groupObj: any, index: any) => {\n return(\n <View key={groupObj.key}>\n <Text style={this.styles.groupHeaderTitle}>{groupObj.key}</Text>\n {this.renderCheckboxses(groupObj.data)}\n </View>)\n })\n : null}\n </View>\n );\n }\n\n renderCheckboxses(items: any) {\n const props = this.state.props;\n return(<View>\n {items && items.length\n ? items.map((item: any, index: any) => this.renderChild(item, index))\n : null}\n </View>)\n }\n renderWidget(props: WmCheckboxsetProps) {\n const items = this.state.dataItems;\n return (\n <View style={this.styles.root}>\n {props.groupby && this.renderGroupby()}\n {!props.groupby && this.renderCheckboxses(items)}\n </View>\n );\n }\n}\n"],"mappings":";;;;AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,SAASC,IAAI,EAAEC,IAAI,EAAEC,gBAAgB,QAAQ,cAAc;AAC3D,SAASC,IAAI,EAAEC,OAAO,EAAEC,OAAO,QAAQ,QAAQ;AAG/C,OAAOC,kBAAkB,MAAM,qBAAqB;AACpD,SACEC,aAAa,QAGR,sBAAsB;AAC7B,SACEC,oBAAoB,EACpBC,gBAAgB,QACX,8EAA8E;AAErF,OAAOC,MAAM,MAAM,iCAAiC;AAEpD,OAAO,MAAMC,kBAAkB,SAASF,gBAAgB,CAAqB;EAAAG,YAAA;IAAA,SAAAC,SAAA;IAAAC,eAAA,kBACxD,IAAI;EAAA;AACzB;AAEA,eAAe,MAAMC,aAAa,SAASP,oBAAoB,CAA8D;EAC3HI,WAAWA,CAACI,KAAyB,EAAE;IACrC,KAAK,CAACA,KAAK,EAAET,aAAa,EAAE,IAAID,kBAAkB,CAAC,CAAC,CAAC;EACvD;EAEAW,OAAOA,CAACC,IAAS,EAAE;IACjB,IAAI,CAACC,mBAAmB,CAAC,OAAO,EAAE,CAAC,IAAI,EAAE,IAAI,CAACC,KAAK,CAAC,CAAC;IACrD,IAAI,IAAI,CAACC,KAAK,CAACL,KAAK,CAACM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7 +8,6 @@ export default class WmCheckboxsetProps extends BaseDatasetProps {
|
|
|
8
8
|
_defineProperty(this, "dataset", 'Option 1, Option 2, Option 3');
|
|
9
9
|
_defineProperty(this, "displayValue", '');
|
|
10
10
|
_defineProperty(this, "required", false);
|
|
11
|
-
_defineProperty(this, "renderitempartial", void 0);
|
|
12
11
|
}
|
|
13
12
|
}
|
|
14
13
|
//# sourceMappingURL=checkboxset.props.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["BaseDatasetProps","WmCheckboxsetProps","constructor","arguments","_defineProperty"],"sources":["checkboxset.props.ts"],"sourcesContent":["import BaseDatasetProps from '@wavemaker/app-rn-runtime/components/input/basedataset/basedataset.props';\n\nexport default class WmCheckboxsetProps extends BaseDatasetProps {\n dataset: any = 'Option 1, Option 2, Option 3';\n displayValue: any = '';\n required: boolean = false;\n
|
|
1
|
+
{"version":3,"names":["BaseDatasetProps","WmCheckboxsetProps","constructor","arguments","_defineProperty"],"sources":["checkboxset.props.ts"],"sourcesContent":["import BaseDatasetProps from '@wavemaker/app-rn-runtime/components/input/basedataset/basedataset.props';\n\nexport default class WmCheckboxsetProps extends BaseDatasetProps {\n dataset: any = 'Option 1, Option 2, Option 3';\n displayValue: any = '';\n required: boolean = false;\n}\n"],"mappings":";;;AAAA,OAAOA,gBAAgB,MAAM,0EAA0E;AAEvG,eAAe,MAAMC,kBAAkB,SAASD,gBAAgB,CAAC;EAAAE,YAAA;IAAA,SAAAC,SAAA;IAAAC,eAAA,kBAChD,8BAA8B;IAAAA,eAAA,uBACzB,EAAE;IAAAA,eAAA,mBACF,KAAK;EAAA;AAC3B"}
|
|
@@ -5,7 +5,11 @@ BASE_THEME.registerStyle((themeVariables, addStyle) => {
|
|
|
5
5
|
const defaultStyles = defineStyles({
|
|
6
6
|
root: {},
|
|
7
7
|
text: {
|
|
8
|
-
|
|
8
|
+
alignSelf: 'center',
|
|
9
|
+
fontFamily: themeVariables.baseFont,
|
|
10
|
+
fontSize: 16,
|
|
11
|
+
color: themeVariables.labelDefaultColor,
|
|
12
|
+
marginLeft: 8
|
|
9
13
|
},
|
|
10
14
|
groupHeaderTitle: {
|
|
11
15
|
backgroundColor: themeVariables.groupHeadingBgColor,
|
|
@@ -17,27 +21,52 @@ BASE_THEME.registerStyle((themeVariables, addStyle) => {
|
|
|
17
21
|
},
|
|
18
22
|
item: {
|
|
19
23
|
flexDirection: 'row',
|
|
20
|
-
alignContent: 'center'
|
|
21
|
-
|
|
22
|
-
checkedItem: {},
|
|
23
|
-
checkboxLabel: {
|
|
24
|
-
alignSelf: 'center',
|
|
25
|
-
fontFamily: themeVariables.baseFont,
|
|
26
|
-
fontSize: 16,
|
|
27
|
-
color: themeVariables.labelDefaultColor
|
|
24
|
+
alignContent: 'center',
|
|
25
|
+
marginTop: 8
|
|
28
26
|
},
|
|
29
27
|
skeleton: {
|
|
30
28
|
root: {
|
|
31
29
|
width: '100%',
|
|
32
30
|
height: 16
|
|
33
31
|
}
|
|
32
|
+
},
|
|
33
|
+
checkicon: {
|
|
34
|
+
root: {
|
|
35
|
+
width: 20,
|
|
36
|
+
height: 20,
|
|
37
|
+
borderRadius: 4,
|
|
38
|
+
backgroundColor: themeVariables.primaryColor,
|
|
39
|
+
justifyContent: 'center',
|
|
40
|
+
alignItems: 'center',
|
|
41
|
+
borderColor: themeVariables.checkedBorderColor
|
|
42
|
+
},
|
|
43
|
+
text: {
|
|
44
|
+
fontSize: 18
|
|
45
|
+
},
|
|
46
|
+
icon: {
|
|
47
|
+
color: themeVariables.checkedIconColor,
|
|
48
|
+
padding: 0
|
|
49
|
+
}
|
|
50
|
+
},
|
|
51
|
+
uncheckicon: {
|
|
52
|
+
root: {
|
|
53
|
+
width: 20,
|
|
54
|
+
height: 20,
|
|
55
|
+
borderWidth: 2,
|
|
56
|
+
borderRadius: 4,
|
|
57
|
+
borderColor: themeVariables.uncheckedBorderColor
|
|
58
|
+
},
|
|
59
|
+
text: {},
|
|
60
|
+
icon: {
|
|
61
|
+
color: 'transparent'
|
|
62
|
+
}
|
|
34
63
|
}
|
|
35
64
|
});
|
|
36
65
|
addStyle(DEFAULT_CLASS + '-disabled', '', {
|
|
37
66
|
root: {
|
|
38
67
|
opacity: 0.8
|
|
39
68
|
},
|
|
40
|
-
|
|
69
|
+
text: {
|
|
41
70
|
color: themeVariables.checkedDisabledColor
|
|
42
71
|
}
|
|
43
72
|
});
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["BASE_THEME","defineStyles","DEFAULT_CLASS","registerStyle","themeVariables","addStyle","defaultStyles","root","text","color","
|
|
1
|
+
{"version":3,"names":["BASE_THEME","defineStyles","DEFAULT_CLASS","registerStyle","themeVariables","addStyle","defaultStyles","root","text","alignSelf","fontFamily","baseFont","fontSize","color","labelDefaultColor","marginLeft","groupHeaderTitle","backgroundColor","groupHeadingBgColor","paddingLeft","paddingRight","lineHeight","item","flexDirection","alignContent","marginTop","skeleton","width","height","checkicon","borderRadius","primaryColor","justifyContent","alignItems","borderColor","checkedBorderColor","icon","checkedIconColor","padding","uncheckicon","borderWidth","uncheckedBorderColor","opacity","checkedDisabledColor"],"sources":["checkboxset.styles.ts"],"sourcesContent":["import BASE_THEME, { AllStyle } from '@wavemaker/app-rn-runtime/styles/theme';\nimport { BaseStyles, defineStyles } from '@wavemaker/app-rn-runtime/core/base.component';\nimport { WmSkeletonStyles } from '../../basic/skeleton/skeleton.styles';\nimport { WmIconStyles } from '../../basic/icon/icon.styles';\n\nexport type WmCheckboxsetStyles = BaseStyles & {\n groupHeaderTitle: AllStyle;\n item: AllStyle;\n skeleton: WmSkeletonStyles;\n checkicon: WmIconStyles;\n uncheckicon: WmIconStyles;\n};\n\nexport const DEFAULT_CLASS = 'app-checkboxset';\nBASE_THEME.registerStyle((themeVariables, addStyle) => {\n const defaultStyles: WmCheckboxsetStyles = defineStyles({\n root: {},\n text: {\n alignSelf: 'center',\n fontFamily: themeVariables.baseFont,\n fontSize: 16,\n color: themeVariables.labelDefaultColor,\n marginLeft: 8,\n },\n groupHeaderTitle: {\n backgroundColor: themeVariables.groupHeadingBgColor,\n fontSize: 16,\n paddingLeft: 8,\n paddingRight: 8,\n lineHeight: 40,\n fontFamily: themeVariables.baseFont\n } as AllStyle,\n item: {\n flexDirection: 'row',\n alignContent: 'center',\n marginTop: 8\n } as AllStyle,\n skeleton: {\n root: {\n width: '100%',\n height: 16\n }\n } as any as WmSkeletonStyles,\n checkicon : {\n root: {\n width: 20,\n height: 20,\n borderRadius: 4,\n backgroundColor: themeVariables.primaryColor,\n justifyContent: 'center',\n alignItems: 'center',\n borderColor: themeVariables.checkedBorderColor,\n },\n text: {\n fontSize: 18,\n },\n icon : {\n color: themeVariables.checkedIconColor,\n padding: 0\n }\n } as WmIconStyles,\n uncheckicon : {\n root: {\n width: 20,\n height: 20,\n borderWidth: 2,\n borderRadius: 4,\n borderColor: themeVariables.uncheckedBorderColor,\n },\n text: {},\n icon : {\n color: 'transparent',\n }\n } as WmIconStyles,\n });\n\n addStyle(DEFAULT_CLASS + '-disabled', '', {\n root: {\n opacity: 0.8\n },\n text : {\n color: themeVariables.checkedDisabledColor\n }\n });\n\n addStyle(DEFAULT_CLASS, '', defaultStyles);\n});\n"],"mappings":"AAAA,OAAOA,UAAU,MAAoB,wCAAwC;AAC7E,SAAqBC,YAAY,QAAQ,+CAA+C;AAYxF,OAAO,MAAMC,aAAa,GAAG,iBAAiB;AAC9CF,UAAU,CAACG,aAAa,CAAC,CAACC,cAAc,EAAEC,QAAQ,KAAK;EACrD,MAAMC,aAAkC,GAAGL,YAAY,CAAC;IACpDM,IAAI,EAAE,CAAC,CAAC;IACRC,IAAI,EAAE;MACJC,SAAS,EAAE,QAAQ;MACnBC,UAAU,EAAEN,cAAc,CAACO,QAAQ;MACnCC,QAAQ,EAAE,EAAE;MACZC,KAAK,EAAET,cAAc,CAACU,iBAAiB;MACvCC,UAAU,EAAE;IACd,CAAC;IACHC,gBAAgB,EAAE;MAChBC,eAAe,EAAEb,cAA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Q,CAACH,aAAa,EAAE,EAAE,EAAEI,aAAa,CAAC;AAC5C,CAAC,CAAC"}
|
|
@@ -15,7 +15,7 @@ export default class WmComposite extends BaseComponent {
|
|
|
15
15
|
super(props, DEFAULT_CLASS, new WmCompositeProps());
|
|
16
16
|
}
|
|
17
17
|
renderWidget(props) {
|
|
18
|
-
const styles = this.theme.mergeStyle({}, this.styles,
|
|
18
|
+
const styles = this.theme.mergeStyle({}, this.styles, this.theme.getStyle(POSITION_STYLES[props.captionposition]));
|
|
19
19
|
return /*#__PURE__*/React.createElement(View, {
|
|
20
20
|
style: styles.root
|
|
21
21
|
}, this._background, props.children);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["React","View","BaseComponent","BaseComponentState","WmCompositeProps","DEFAULT_CLASS","WmCompositeState","POSITION_STYLES","WmComposite","constructor","props","renderWidget","styles","theme","mergeStyle","
|
|
1
|
+
{"version":3,"names":["React","View","BaseComponent","BaseComponentState","WmCompositeProps","DEFAULT_CLASS","WmCompositeState","POSITION_STYLES","WmComposite","constructor","props","renderWidget","styles","theme","mergeStyle","getStyle","captionposition","createElement","style","root","_background","children"],"sources":["composite.component.tsx"],"sourcesContent":["import React from 'react';\nimport { View } from 'react-native';\nimport { BaseComponent, BaseComponentState } from '@wavemaker/app-rn-runtime/core/base.component';\n\nimport WmCompositeProps from './composite.props';\nimport { DEFAULT_CLASS, WmCompositeStyles } from './composite.styles';\n\nexport class WmCompositeState extends BaseComponentState<WmCompositeProps> {};\n\nconst POSITION_STYLES = {\n 'top': 'app-composite-top-caption',\n 'left': 'app-composite-left-caption',\n 'right': 'app-composite-right-caption'\n};\n\nexport default class WmComposite extends BaseComponent<WmCompositeProps, WmCompositeState, WmCompositeStyles> {\n\n constructor(props: WmCompositeProps) {\n super(props, DEFAULT_CLASS, new WmCompositeProps());\n }\n\n renderWidget(props: WmCompositeProps) {\n const styles = this.theme.mergeStyle({}, \n this.styles,\n this.theme.getStyle(POSITION_STYLES[props.captionposition]));\n return (<View style={styles.root}>{this._background}{props.children}</View>); \n }\n}\n"],"mappings":"AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,SAASC,IAAI,QAAQ,cAAc;AACnC,SAASC,aAAa,EAAEC,kBAAkB,QAAQ,+CAA+C;AAEjG,OAAOC,gBAAgB,MAAM,mBAAmB;AAChD,SAASC,aAAa,QAA2B,oBAAoB;AAErE,OAAO,MAAMC,gBAAgB,SAASH,kBAAkB,CAAmB;AAAE;AAE7E,MAAMI,eAAe,GAAG;EACtB,KAAK,EAAE,2BAA2B;EAClC,MAAM,EAAE,4BAA4B;EACpC,OAAO,EAAE;AACX,CAAC;AAED,eAAe,MAAMC,WAAW,SAASN,aAAa,CAAwD;EAE5GO,WAAWA,CAACC,KAAuB,EAAE;IACnC,KAAK,CAACA,KAAK,EAAEL,aAAa,EAAE,IAAID,gBAAgB,CAAC,CAAC,CAAC;EACrD;EAEAO,YAAYA,CAACD,KAAuB,EAAE;IACpC,MAAME,MAAM,GAAG,IAAI,CAACC,KAAK,CAACC,UAAU,CAAC,CAAC,CAAC,EACrC,IAAI,CAACF,MAAM,EACX,IAAI,CAACC,KAAK,CAACE,QAAQ,CAACR,eAAe,CAACG,KAAK,CAACM,eAAe,CAAC,CAAC,CAAC;IAC9D,oBAAQhB,KAAA,CAAAiB,aAAA,CAAChB,IAAI;MAACiB,KAAK,EAAEN,MAAM,CAACO;IAAK,GAAE,IAAI,CAACC,WAAW,EAAEV,KAAK,CAACW,QAAe,CAAC;EAC7E;AACF"}
|
|
@@ -6,7 +6,7 @@ export default class WmCompositeProps extends BaseProps {
|
|
|
6
6
|
constructor() {
|
|
7
7
|
super(...arguments);
|
|
8
8
|
_defineProperty(this, "children", void 0);
|
|
9
|
-
_defineProperty(this, "captionposition",
|
|
9
|
+
_defineProperty(this, "captionposition", 'left');
|
|
10
10
|
}
|
|
11
11
|
}
|
|
12
12
|
//# sourceMappingURL=composite.props.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["BaseProps","WmCompositeProps","constructor","arguments","_defineProperty"
|
|
1
|
+
{"version":3,"names":["BaseProps","WmCompositeProps","constructor","arguments","_defineProperty"],"sources":["composite.props.ts"],"sourcesContent":["import { BaseProps } from '@wavemaker/app-rn-runtime/core/base.component';\n\nexport default class WmCompositeProps extends BaseProps {\n children: any;\n captionposition: 'left' | 'right' | 'top' = 'left';\n}"],"mappings":";;;AAAA,SAASA,SAAS,QAAQ,+CAA+C;AAEzE,eAAe,MAAMC,gBAAgB,SAASD,SAAS,CAAC;EAAAE,YAAA;IAAA,SAAAC,SAAA;IAAAC,eAAA;IAAAA,eAAA,0BAER,MAAM;EAAA;AACtD"}
|
|
@@ -32,6 +32,14 @@ export default class WmCurrency extends BaseNumberComponent {
|
|
|
32
32
|
break;
|
|
33
33
|
}
|
|
34
34
|
}
|
|
35
|
+
getStyleClassName() {
|
|
36
|
+
const classes = [];
|
|
37
|
+
if (this.state.props.floatinglabel) {
|
|
38
|
+
classes.push('app-currency-with-label');
|
|
39
|
+
}
|
|
40
|
+
classes.push(super.getStyleClassName());
|
|
41
|
+
return classes.join(' ');
|
|
42
|
+
}
|
|
35
43
|
renderWidget(props) {
|
|
36
44
|
var _this$state$textValue;
|
|
37
45
|
let opts = {};
|
|
@@ -43,7 +51,11 @@ export default class WmCurrency extends BaseNumberComponent {
|
|
|
43
51
|
style: this.styles.labelWrapper
|
|
44
52
|
}, /*#__PURE__*/React.createElement(Text, {
|
|
45
53
|
style: this.styles.label
|
|
46
|
-
}, this.state.currencySymbol)), /*#__PURE__*/React.createElement(
|
|
54
|
+
}, this.state.currencySymbol)), /*#__PURE__*/React.createElement(View, {
|
|
55
|
+
style: {
|
|
56
|
+
flex: 1
|
|
57
|
+
}
|
|
58
|
+
}, /*#__PURE__*/React.createElement(WMTextInput, _extends({}, this.getTestPropsForInput(), {
|
|
47
59
|
ref: ref => {
|
|
48
60
|
this.widgetRef = ref;
|
|
49
61
|
// @ts-ignore
|
|
@@ -56,9 +68,11 @@ export default class WmCurrency extends BaseNumberComponent {
|
|
|
56
68
|
placeholderTextColor: this.styles.placeholderText.color,
|
|
57
69
|
style: [this.styles.input, this.styles.text, this.state.isValid ? {} : this.styles.invalid]
|
|
58
70
|
}, opts, {
|
|
71
|
+
floatingLabel: props.floatinglabel,
|
|
72
|
+
floatingLabelStyle: this.styles.floatingLabel,
|
|
73
|
+
activeFloatingLabelStyle: this.styles.activeFloatingLabel,
|
|
59
74
|
editable: props.disabled || props.readonly ? false : true,
|
|
60
75
|
placeholder: props.placeholder,
|
|
61
|
-
value: this.state.textValue,
|
|
62
76
|
onBlur: this.onBlur.bind(this),
|
|
63
77
|
onFocus: this.onFocus.bind(this),
|
|
64
78
|
onKeyPress: this.validateInputEntry.bind(this),
|
|
@@ -67,7 +81,7 @@ export default class WmCurrency extends BaseNumberComponent {
|
|
|
67
81
|
},
|
|
68
82
|
onChange: this.invokeChange.bind(this),
|
|
69
83
|
allowContentSelection: this.styles.text.userSelect === 'text'
|
|
70
|
-
})));
|
|
84
|
+
}))));
|
|
71
85
|
}
|
|
72
86
|
}
|
|
73
87
|
//# sourceMappingURL=currency.component.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["React","View","Text","Platform","WmCurrencyProps","CURRENCY_INFO","WMTextInput","DEFAULT_CLASS","BaseNumberComponent","BaseNumberState","isNull","WmCurrencyState","constructor","arguments","_defineProperty","WmCurrency","props","onPropertyChange","name","$new","$old","updateState","currencySymbol","symbol","renderWidget","_this$state$textValue","opts","valueExpr","OS","
|
|
1
|
+
{"version":3,"names":["React","View","Text","Platform","WmCurrencyProps","CURRENCY_INFO","WMTextInput","DEFAULT_CLASS","BaseNumberComponent","BaseNumberState","isNull","WmCurrencyState","constructor","arguments","_defineProperty","WmCurrency","props","onPropertyChange","name","$new","$old","updateState","currencySymbol","symbol","getStyleClassName","classes","state","floatinglabel","push","join","renderWidget","_this$state$textValue","opts","valueExpr","OS","textValue","toString","createElement","style","styles","root","labelWrapper","label","flex","_extends","getTestPropsForInput","ref","widgetRef","selectionStart","selectionEnd","cursor","keyboardType","placeholderTextColor","placeholderText","color","input","text","isValid","invalid","floatingLabel","floatingLabelStyle","activeFloatingLabelStyle","activeFloatingLabel","editable","disabled","readonly","placeholder","onBlur","bind","onFocus","onKeyPress","validateInputEntry","onChangeText","onChange","invokeChange","allowContentSelection","userSelect"],"sources":["currency.component.tsx"],"sourcesContent":["import React from 'react';\nimport { View, Text, Platform } from 'react-native';\n\nimport WmCurrencyProps from './currency.props';\nimport { CURRENCY_INFO } from '@wavemaker/app-rn-runtime/core/currency-constants';\nimport { WMTextInput } from '@wavemaker/app-rn-runtime/core/components/textinput.component';\nimport { DEFAULT_CLASS, WmCurrencyStyles } from './currency.styles';\nimport {\n BaseNumberComponent,\n BaseNumberState\n} from '@wavemaker/app-rn-runtime/components/input/basenumber/basenumber.component';\nimport { isNull } from \"lodash\";\nexport class WmCurrencyState extends BaseNumberState<WmCurrencyProps> {\n currencySymbol: any;\n}\n\nexport default class WmCurrency extends BaseNumberComponent<WmCurrencyProps, WmCurrencyState, WmCurrencyStyles> {\n\n constructor(props: WmCurrencyProps) {\n super(props, DEFAULT_CLASS, new WmCurrencyProps(), new WmCurrencyState());\n }\n\n onPropertyChange(name: string, $new: any, $old: any) {\n super.onPropertyChange(name, $new, $old);\n switch (name) {\n case 'currency':\n if ($new) {\n this.updateState({\n currencySymbol: CURRENCY_INFO[$new].symbol,\n } as WmCurrencyState);\n }\n break;\n\n }\n }\n\n public getStyleClassName(): string | undefined {\n const classes = [];\n if (this.state.props.floatinglabel) {\n classes.push('app-currency-with-label'); \n }\n classes.push(super.getStyleClassName());\n return classes.join(' ');\n }\n\n renderWidget(props: WmCurrencyProps) {\n let opts: any = {};\n const valueExpr = Platform.OS === 'web' ? 'value' : 'defaultValue';\n opts[valueExpr] = this.state.textValue?.toString() || '';\n return (<View style={this.styles.root}>\n <View style={this.styles.labelWrapper}>\n <Text style={this.styles.label}>{this.state.currencySymbol}</Text>\n </View>\n <View style={{flex: 1}}>\n <WMTextInput\n {...this.getTestPropsForInput()}\n ref={(ref: any) => {\n this.widgetRef = ref;\n // @ts-ignore\n if (ref && !isNull(ref.selectionStart) && !isNull(ref.selectionEnd)) {\n // @ts-ignore\n ref.selectionStart = ref.selectionEnd = this.cursor;\n }\n }}\n keyboardType=\"numeric\"\n placeholderTextColor={this.styles.placeholderText.color as any}\n style={[this.styles.input, this.styles.text, this.state.isValid ? {} : this.styles.invalid]}\n {...opts}\n floatingLabel={props.floatinglabel}\n floatingLabelStyle={this.styles.floatingLabel}\n activeFloatingLabelStyle={this.styles.activeFloatingLabel}\n editable={props.disabled || props.readonly ? false : true}\n placeholder={props.placeholder}\n onBlur={this.onBlur.bind(this)}\n onFocus={this.onFocus.bind(this)}\n onKeyPress={this.validateInputEntry.bind(this)}\n onChangeText={(text) => {\n this.onChangeText.bind(this)(text, 'currency');\n }}\n onChange={this.invokeChange.bind(this)}\n allowContentSelection={this.styles.text.userSelect === 'text'}\n />\n </View>\n </View>);\n }\n}\n"],"mappings":";;;;AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,SAASC,IAAI,EAAEC,IAAI,EAAEC,QAAQ,QAAQ,cAAc;AAEnD,OAAOC,eAAe,MAAM,kBAAkB;AAC9C,SAASC,aAAa,QAAQ,mDAAmD;AACjF,SAASC,WAAW,QAAQ,+DAA+D;AAC3F,SAASC,aAAa,QAA0B,mBAAmB;AACnE,SACEC,mBAAmB,EACnBC,eAAe,QACV,4EAA4E;AACnF,SAASC,MAAM,QAAQ,QAAQ;AAC/B,OAAO,MAAMC,eAAe,SAASF,eAAe,CAAkB;EAAAG,YAAA;IAAA,SAAAC,SAAA;IAAAC,eAAA;EAAA;AAEtE;AAEA,eAAe,MAAMC,UAAU,SAASP,mBAAmB,CAAqD;EAE9GI,WAAWA,CAACI,KAAsB,EAAE;IAClC,KAAK,CAACA,KAAK,EAAET,aAAa,EAAE,IAAIH,eAAe,CAAC,CAAC,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AAI,CAAE;MAC/BC,OAAO,EAAE,IAAI,CAACA,OAAO,CAACD,IAAI,CAAC,IAAI,CAAE;MACjCE,UAAU,EAAE,IAAI,CAACC,kBAAkB,CAACH,IAAI,CAAC,IAAI,CAAE;MAC/CI,YAAY,EAAGhB,IAAI,IAAK;QACtB,IAAI,CAACgB,YAAY,CAACJ,IAAI,CAAC,IAAI,CAAC,CAACZ,IAAI,EAAE,UAAU,CAAC;MAChD,CAAE;MACFiB,QAAQ,EAAE,IAAI,CAACC,YAAY,CAACN,IAAI,CAAC,IAAI,CAAE;MACvCO,qBAAqB,EAAE,IAAI,CAACpC,MAAM,CAACiB,IAAI,CAACoB,UAAU,KAAK;IAAO,EAC/D,CACK,CACF,CAAC;EACT;AACF"}
|
|
@@ -7,6 +7,7 @@ export default class WmCurrencyProps extends BaseNumberProps {
|
|
|
7
7
|
super(...arguments);
|
|
8
8
|
_defineProperty(this, "currency", void 0);
|
|
9
9
|
_defineProperty(this, "placeholder", '');
|
|
10
|
+
_defineProperty(this, "floatinglabel", void 0);
|
|
10
11
|
}
|
|
11
12
|
}
|
|
12
13
|
//# sourceMappingURL=currency.props.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["BaseNumberProps","WmCurrencyProps","constructor","arguments","_defineProperty"],"sources":["currency.props.ts"],"sourcesContent":["import BaseNumberProps from '@wavemaker/app-rn-runtime/components/input/basenumber/basenumber.props';\n\nexport default class WmCurrencyProps extends BaseNumberProps {\n currency: any;\n placeholder: string = '';\n}\n"],"mappings":";;;AAAA,OAAOA,eAAe,MAAM,wEAAwE;AAEpG,eAAe,MAAMC,eAAe,SAASD,eAAe,CAAC;EAAAE,YAAA;IAAA,SAAAC,SAAA;IAAAC,eAAA;IAAAA,eAAA,sBAErC,EAAE;EAAA;
|
|
1
|
+
{"version":3,"names":["BaseNumberProps","WmCurrencyProps","constructor","arguments","_defineProperty"],"sources":["currency.props.ts"],"sourcesContent":["import BaseNumberProps from '@wavemaker/app-rn-runtime/components/input/basenumber/basenumber.props';\n\nexport default class WmCurrencyProps extends BaseNumberProps {\n currency: any;\n placeholder: string = '';\n floatinglabel?: string;\n}\n"],"mappings":";;;AAAA,OAAOA,eAAe,MAAM,wEAAwE;AAEpG,eAAe,MAAMC,eAAe,SAASD,eAAe,CAAC;EAAAE,YAAA;IAAA,SAAAC,SAAA;IAAAC,eAAA;IAAAA,eAAA,sBAErC,EAAE;IAAAA,eAAA;EAAA;AAE1B"}
|
|
@@ -52,7 +52,9 @@ BASE_THEME.registerStyle((themeVariables, addStyle) => {
|
|
|
52
52
|
},
|
|
53
53
|
placeholderText: {
|
|
54
54
|
color: themeVariables.inputPlaceholderColor
|
|
55
|
-
}
|
|
55
|
+
},
|
|
56
|
+
floatingLabel: {},
|
|
57
|
+
activeFloatingLabel: {}
|
|
56
58
|
});
|
|
57
59
|
addStyle(DEFAULT_CLASS, '', defaultStyles);
|
|
58
60
|
addStyle(DEFAULT_CLASS + '-rtl', '', Platform.OS == "web" ? {
|
|
@@ -68,5 +70,21 @@ BASE_THEME.registerStyle((themeVariables, addStyle) => {
|
|
|
68
70
|
backgroundColor: themeVariables.inputDisabledBgColor
|
|
69
71
|
}
|
|
70
72
|
});
|
|
73
|
+
addStyle(DEFAULT_CLASS + '-with-label', '', {
|
|
74
|
+
root: {
|
|
75
|
+
minHeight: 48
|
|
76
|
+
},
|
|
77
|
+
floatingLabel: {
|
|
78
|
+
position: 'absolute',
|
|
79
|
+
top: 12,
|
|
80
|
+
left: 16,
|
|
81
|
+
fontSize: 14,
|
|
82
|
+
textAlign: 'left',
|
|
83
|
+
color: themeVariables.floatingLabelColor
|
|
84
|
+
},
|
|
85
|
+
activeFloatingLabel: {
|
|
86
|
+
color: themeVariables.activeFloatingLabelColor
|
|
87
|
+
}
|
|
88
|
+
});
|
|
71
89
|
});
|
|
72
90
|
//# sourceMappingURL=currency.styles.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["BASE_THEME","defineStyles","Platform","DEFAULT_CLASS","registerStyle","themeVariables","addStyle","defaultStyles","root","minHeight","borderWidth","borderStyle","borderColor","inputBorderColor","backgroundColor","inputBackgroundColor","borderRadius","flexDirection","text","fontSize","input","paddingTop","paddingBottom","paddingLeft","paddingRight","flex","transparent","labelWrapper","primaryColor","borderTopLeftRadius","borderBottomLeftRadius","width","label","marginVertical","color","primaryContrastColor","textAlignVertical","textAlign","fontWeight","fontFamily","baseFont","invalid","borderBottomColor","inputInvalidBorderColor","placeholderText","inputPlaceholderColor","OS","borderTopRightRadius","borderBottomRightRadius","inputDisabledBgColor"],"sources":["currency.styles.ts"],"sourcesContent":["import BASE_THEME, { AllStyle } from '@wavemaker/app-rn-runtime/styles/theme';\nimport { BaseStyles, defineStyles } from '@wavemaker/app-rn-runtime/core/base.component';\nimport { Platform } from 'react-native';\n\nexport type WmCurrencyStyles = BaseStyles & {\n label: AllStyle;\n invalid: AllStyle;\n placeholderText: AllStyle;\n};\n\nexport const DEFAULT_CLASS = 'app-currency';\nBASE_THEME.registerStyle((themeVariables, addStyle) => {\n const defaultStyles: WmCurrencyStyles = defineStyles({\n root: {\n minHeight: 42,\n borderWidth: 1,\n borderStyle: 'solid',\n borderColor: themeVariables.inputBorderColor,\n backgroundColor: themeVariables.inputBackgroundColor,\n borderRadius: 6,\n flexDirection: 'row'\n },\n text: {\n fontSize: 16\n },\n input : {\n minHeight: 42,\n paddingTop: 8,\n paddingBottom: 8,\n paddingLeft: 16,\n paddingRight: 16,\n flex: 1,\n borderWidth: 1,\n borderColor: themeVariables.transparent,\n borderStyle: 'solid'\n },\n labelWrapper: {\n minHeight: 42,\n backgroundColor: themeVariables.primaryColor,\n borderTopLeftRadius: 6,\n borderBottomLeftRadius: 6,\n width: 48,\n paddingTop: 8,\n paddingBottom: 8,\n paddingLeft: 16,\n paddingRight: 16\n },\n label: {\n marginVertical: 0.7,\n color: themeVariables.primaryContrastColor,\n textAlignVertical: 'center',\n textAlign: 'center',\n fontWeight: 'bold',\n fontFamily: themeVariables.baseFont,\n fontSize: 16\n },\n invalid: {\n borderBottomColor: themeVariables.inputInvalidBorderColor\n },\n placeholderText: {\n color: themeVariables.inputPlaceholderColor\n }\n });\n\n addStyle(DEFAULT_CLASS, '', defaultStyles);\n addStyle(DEFAULT_CLASS + '-rtl', '', Platform.OS==\"web\"?{\n labelWrapper:{\n borderTopLeftRadius: 0,\n borderBottomLeftRadius: 0,\n borderTopRightRadius: 6,\n borderBottomRightRadius: 6,\n }\n }:{});\n addStyle(DEFAULT_CLASS + '-disabled', '', {\n root : {\n backgroundColor: themeVariables.inputDisabledBgColor\n }\n });\n});"],"mappings":"AAAA,OAAOA,UAAU,MAAoB,wCAAwC;AAC7E,SAAqBC,YAAY,QAAQ,+CAA+C;AACxF,SAASC,QAAQ,QAAQ,cAAc;
|
|
1
|
+
{"version":3,"names":["BASE_THEME","defineStyles","Platform","DEFAULT_CLASS","registerStyle","themeVariables","addStyle","defaultStyles","root","minHeight","borderWidth","borderStyle","borderColor","inputBorderColor","backgroundColor","inputBackgroundColor","borderRadius","flexDirection","text","fontSize","input","paddingTop","paddingBottom","paddingLeft","paddingRight","flex","transparent","labelWrapper","primaryColor","borderTopLeftRadius","borderBottomLeftRadius","width","label","marginVertical","color","primaryContrastColor","textAlignVertical","textAlign","fontWeight","fontFamily","baseFont","invalid","borderBottomColor","inputInvalidBorderColor","placeholderText","inputPlaceholderColor","floatingLabel","activeFloatingLabel","OS","borderTopRightRadius","borderBottomRightRadius","inputDisabledBgColor","position","top","left","floatingLabelColor","activeFloatingLabelColor"],"sources":["currency.styles.ts"],"sourcesContent":["import BASE_THEME, { AllStyle } from '@wavemaker/app-rn-runtime/styles/theme';\nimport { BaseStyles, defineStyles } from '@wavemaker/app-rn-runtime/core/base.component';\nimport { Platform } from 'react-native';\n\nexport type WmCurrencyStyles = BaseStyles & {\n label: AllStyle;\n invalid: AllStyle;\n floatingLabel: AllStyle;\n activeFloatingLabel: AllStyle;\n placeholderText: AllStyle;\n};\n\nexport const DEFAULT_CLASS = 'app-currency';\nBASE_THEME.registerStyle((themeVariables, addStyle) => {\n const defaultStyles: WmCurrencyStyles = defineStyles({\n root: {\n minHeight: 42,\n borderWidth: 1,\n borderStyle: 'solid',\n borderColor: themeVariables.inputBorderColor,\n backgroundColor: themeVariables.inputBackgroundColor,\n borderRadius: 6,\n flexDirection: 'row'\n },\n text: {\n fontSize: 16\n },\n input : {\n minHeight: 42,\n paddingTop: 8,\n paddingBottom: 8,\n paddingLeft: 16,\n paddingRight: 16,\n flex: 1,\n borderWidth: 1,\n borderColor: themeVariables.transparent,\n borderStyle: 'solid'\n },\n labelWrapper: {\n minHeight: 42,\n backgroundColor: themeVariables.primaryColor,\n borderTopLeftRadius: 6,\n borderBottomLeftRadius: 6,\n width: 48,\n paddingTop: 8,\n paddingBottom: 8,\n paddingLeft: 16,\n paddingRight: 16\n },\n label: {\n marginVertical: 0.7,\n color: themeVariables.primaryContrastColor,\n textAlignVertical: 'center',\n textAlign: 'center',\n fontWeight: 'bold',\n fontFamily: themeVariables.baseFont,\n fontSize: 16\n },\n invalid: {\n borderBottomColor: themeVariables.inputInvalidBorderColor\n },\n placeholderText: {\n color: themeVariables.inputPlaceholderColor\n },\n floatingLabel: {},\n activeFloatingLabel: {}\n });\n\n addStyle(DEFAULT_CLASS, '', defaultStyles);\n addStyle(DEFAULT_CLASS + '-rtl', '', Platform.OS==\"web\"?{\n labelWrapper:{\n borderTopLeftRadius: 0,\n borderBottomLeftRadius: 0,\n borderTopRightRadius: 6,\n borderBottomRightRadius: 6,\n }\n }:{});\n addStyle(DEFAULT_CLASS + '-disabled', '', {\n root : {\n backgroundColor: themeVariables.inputDisabledBgColor\n }\n });\n addStyle(DEFAULT_CLASS + '-with-label', '', {\n root: {\n minHeight: 48\n },\n floatingLabel: {\n position: 'absolute',\n top: 12,\n left: 16,\n fontSize: 14,\n textAlign: 'left',\n color: themeVariables.floatingLabelColor\n },\n activeFloatingLabel: {\n color: themeVariables.activeFloatingL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