@jescon-technologies/react-native-ui-kit 0.0.6 → 0.0.7
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.
- package/dist/Common/ErrorBoundary.d.ts +15 -0
- package/dist/Common/ErrorBoundary.d.ts.map +1 -0
- package/dist/Common/ErrorBoundary.js +64 -0
- package/dist/Common/ErrorBoundary.js.map +1 -0
- package/dist/index.d.ts +3 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +8 -0
- package/dist/index.js.map +1 -0
- package/dist/src/Common/ErrorBoundary.d.ts +15 -0
- package/dist/src/Common/ErrorBoundary.d.ts.map +1 -0
- package/dist/src/Common/ErrorBoundary.js +64 -0
- package/dist/src/Common/ErrorBoundary.js.map +1 -0
- package/package.json +17 -5
- package/.gitattributes +0 -2
- package/index.d.ts +0 -66
- package/index.js +0 -66
- package/src/Alerts/AAlert.js +0 -137
- package/src/Alerts/AAlertIOS.js +0 -97
- package/src/Alerts/ABlink.js +0 -40
- package/src/Common/ErrorBoundary.tsx +0 -73
- package/src/Common/Icons.js +0 -49
- package/src/Common/NetworkServiceCall.js +0 -265
- package/src/CommonStyle/CommonTheme.js +0 -11
- package/src/CommonStyle/ComponentFunctions.js +0 -632
- package/src/CommonStyle/PopupStyle.js +0 -146
- package/src/CommonStyle/commonStyle.js +0 -93
- package/src/CommonStyle/componentStyle.js +0 -545
- package/src/CommonStyle/optionListStyles.js +0 -175
- package/src/Components/ByProductPage.js +0 -200
- package/src/Components/CDropDownListNew.js +0 -153
- package/src/Components/CSupplierList.js +0 -88
- package/src/Components/CVerificationCard.js +0 -2822
- package/src/Components/CustomButton.js +0 -67
- package/src/Components/CustomCard.js +0 -127
- package/src/Components/CustomTextInput.js +0 -47
- package/src/Components/EquipmentPage.js +0 -313
- package/src/Components/FilterInput.Copy.js +0 -723
- package/src/Components/FilterInput.js +0 -569
- package/src/Components/HSubHeading.js +0 -68
- package/src/Components/HeaderCard.js +0 -40
- package/src/Components/MoreOptionsScreen.js +0 -251
- package/src/Components/NonSwipableProductCard.js +0 -226
- package/src/Components/NonSwipableSupplierCard.js +0 -348
- package/src/Components/ProductCard.js +0 -1336
- package/src/Components/QualityProductCard.js +0 -1059
- package/src/Components/RateProductCard.js +0 -1452
- package/src/Components/RawMaterial.js +0 -261
- package/src/Components/SDropDownEdited.js +0 -549
- package/src/Components/SDropDownNew.js +0 -529
- package/src/Components/SHelpDescription.js +0 -147
- package/src/Components/STextInputNew.js +0 -510
- package/src/Components/SearchProductCard.js +0 -470
- package/src/Components/StageByProduct.js +0 -199
- package/src/Components/SupplierCard.js +0 -243
- package/src/Components/SupplierInvoiceCard.js +0 -405
- package/src/Components/SwipableSupplierCard.js +0 -136
- package/src/Components/TagTemplate.js +0 -74
- package/src/Components/WrappedComponent.js +0 -25
- package/src/Custom/CBooking.js +0 -944
- package/src/Custom/CBookingPostpone.js +0 -1822
- package/src/Custom/CCalendar.js +0 -560
- package/src/Custom/CCard.js +0 -880
- package/src/Custom/CDetailCard.js +0 -205
- package/src/Custom/CHelpImage.js +0 -52
- package/src/Custom/CReport.js +0 -569
- package/src/Custom/CScrollView.js +0 -73
- package/src/Custom/CSignature.js +0 -112
- package/src/Custom/CSliderMenu.js +0 -339
- package/src/Custom/CSupplierCard.js +0 -99
- package/src/Custom/CTemplateCard.js +0 -438
- package/src/Custom/CTokenAllocation.js +0 -1402
- package/src/Custom/CTokenListOverlay.js +0 -122
- package/src/Custom/CWardStatus.js +0 -444
- package/src/Custom/Charts/CBarChart.js +0 -218
- package/src/Custom/Charts/CDashBoardList.js +0 -133
- package/src/Custom/Charts/CDashBoardTable.js +0 -172
- package/src/Custom/Charts/CLineChart.js +0 -193
- package/src/Custom/Charts/CPieChart.js +0 -186
- package/src/Custom/Loader.js +0 -182
- package/src/Custom/OUserView.js +0 -1121
- package/src/Custom/PreviewDosage.js +0 -115
- package/src/Custom/SearchLoader.js +0 -32
- package/src/Custom/TableComponent/CActivityTable.js +0 -707
- package/src/Custom/TableComponent/CMoreButtonTable.js +0 -197
- package/src/Custom/TableComponent/CTable.js +0 -185
- package/src/Custom/TableComponent/CTextBody.js +0 -40
- package/src/Custom/TableComponent/CTextHeader.js +0 -17
- package/src/Custom/TableComponent/PreviewPrescriptionNew.js +0 -1011
- package/src/Custom/TableComponent/SDropdownTable.js +0 -491
- package/src/Custom/TableComponent/TagTable.js +0 -1200
- package/src/CustomComponents/CAddColumn.js +0 -140
- package/src/CustomComponents/CAssessmentDelete.js +0 -307
- package/src/CustomComponents/CAwesomeButton.js +0 -83
- package/src/CustomComponents/CAwesomeMoreButton.js +0 -54
- package/src/CustomComponents/CBackHandler.js +0 -273
- package/src/CustomComponents/CCalendar.js +0 -243
- package/src/CustomComponents/CCommentOverlay.js +0 -202
- package/src/CustomComponents/CComments.js +0 -162
- package/src/CustomComponents/CContainerView.js +0 -24
- package/src/CustomComponents/CCustomTextInput.js +0 -336
- package/src/CustomComponents/CDetailView.js +0 -40
- package/src/CustomComponents/CDropDownList.js +0 -153
- package/src/CustomComponents/CDropdownSelect.js +0 -555
- package/src/CustomComponents/CFooterView.js +0 -42
- package/src/CustomComponents/CImagePickerSave.js +0 -316
- package/src/CustomComponents/CModalOverlay.js +0 -91
- package/src/CustomComponents/CNetworkStatus.js +0 -327
- package/src/CustomComponents/CNotesInstructions.js +0 -1000
- package/src/CustomComponents/COverlay.js +0 -81
- package/src/CustomComponents/CRemarks.js +0 -176
- package/src/CustomComponents/CRowAdd.js +0 -143
- package/src/CustomComponents/CSummaryDropDown.js +0 -327
- package/src/CustomComponents/CText.js +0 -9
- package/src/CustomComponents/CVectorIcon.js +0 -34
- package/src/CustomComponents/HtmlContentViewer.js +0 -65
- package/src/CustomComponents/PdfContentViewer.js +0 -90
- package/src/CustomComponents/SDropDownDosage.js +0 -1087
- package/src/CustomComponents/SwipableProductCard.js +0 -246
- package/src/CustomComponents/SwipableProductImageCard.js +0 -254
- package/src/CustomComponents/WorkOrderDetails.js +0 -1216
- package/src/CustomComponents/WorkOrderDetailsPage.js +0 -1213
- package/src/HOC/ConfirmOverlay.js +0 -192
- package/src/HOC/HHeading.js +0 -70
- package/src/HOC/HMoreButton.js +0 -88
- package/src/HOC/HNatureHeading.js +0 -402
- package/src/HOC/HOCIcons.js +0 -80
- package/src/HOC/HOverlayCentered.js +0 -140
- package/src/HOC/HShadowButton.js +0 -45
- package/src/HOC/HShadowCountButton.js +0 -82
- package/src/HOC/OptionOverlay.js +0 -48
- package/src/Json/Chart.json +0 -818
- package/src/Json/Consultation.json +0 -622
- package/src/Json/CreditBill.json +0 -490
- package/src/Json/Dropdown.json +0 -216
- package/src/Json/DropdownConsultation.json +0 -228
- package/src/Json/DynamicReports.json +0 -623
- package/src/Json/Footer.json +0 -79
- package/src/Media/AudioScreen.js +0 -342
- package/src/Media/BarcodeScan.js +0 -145
- package/src/Media/CAudioPlay.js +0 -228
- package/src/Media/CCaptureImageWithoutEdit.js +0 -330
- package/src/Media/CImageGallery.js +0 -289
- package/src/Media/CImageZoom.js +0 -82
- package/src/Media/CSingleImage.js +0 -391
- package/src/Media/CSketchCanvas.js +0 -76
- package/src/Media/CVideoPlay.js +0 -31
- package/src/Media/DocumentScreen.js +0 -362
- package/src/Media/DrawingScreen.js +0 -578
- package/src/Media/ImageScreen.js +0 -309
- package/src/Media/RecordAudio.js +0 -250
- package/src/Media/RecordVideo.js +0 -223
- package/src/Media/VideoScreen.js +0 -378
- package/src/Navigation/PageNavigation.js +0 -224
- package/src/Navigation/useFocusEffect.js +0 -2
- package/src/Navigation/useFocusEffect.native.js +0 -1
- package/src/Navigation/useFocusEffect.web.js +0 -1
- package/src/Navigation/useIsFocused.js +0 -1
- package/src/Navigation/useIsFocused.native.js +0 -1
- package/src/Navigation/useIsFocused.web.js +0 -1
- package/src/Navigation/useNavigation.js +0 -2
- package/src/Navigation/useNavigation.native.js +0 -1
- package/src/Navigation/useNavigation.web.js +0 -1
- package/src/Screens/CMedications.js +0 -528
- package/src/Screens/CWebViewGallery.js +0 -203
- package/src/Screens/ChartScan.js +0 -279
- package/src/Screens/ChartScreenNew.js +0 -1579
- package/src/Screens/Consultation.js +0 -1500
- package/src/Screens/Dashboard.js +0 -778
- package/src/Screens/FileExplorer.js +0 -288
- package/src/Screens/Footer.js +0 -340
- package/src/Screens/ForgotPassword.js +0 -288
- package/src/Screens/HeaderBlock.js +0 -353
- package/src/Screens/Login.js +0 -328
- package/src/Screens/Notification.js +0 -149
- package/src/Screens/OcrScreen.js +0 -20
- package/src/Screens/PdfPreview.js +0 -507
- package/src/Screens/RegistrationDetails.js +0 -467
- package/src/Screens/SearchScreen.js +0 -582
- package/src/Screens/Splash.js +0 -788
- package/src/Screens/SwipeLeftView.js +0 -1867
- package/src/StaticComponents/SAlphabet.js +0 -47
- package/src/StaticComponents/SCheckBox.js +0 -42
- package/src/StaticComponents/SDatePicker.js +0 -208
- package/src/StaticComponents/SDatePickerLabel.js +0 -253
- package/src/StaticComponents/SDatePickerNew.js +0 -258
- package/src/StaticComponents/SDateTimePickerNew.js +0 -381
- package/src/StaticComponents/SDropDownGenerate.js +0 -450
- package/src/StaticComponents/SDropDownHoc.js +0 -636
- package/src/StaticComponents/SDropDownIcon.js +0 -500
- package/src/StaticComponents/SMenuBox.js +0 -131
- package/src/StaticComponents/SOverlay.js +0 -177
- package/src/StaticComponents/SOverlayTextInput.js +0 -109
- package/src/StaticComponents/SSearch.js +0 -438
- package/src/StaticComponents/SSearchBar.js +0 -53
- package/src/StaticComponents/SSpeedDial.js +0 -303
- package/src/StaticComponents/STextInput.js +0 -289
- package/src/StaticComponents/STextInputProps.js +0 -36
- package/src/StaticComponents/STimePicker.js +0 -171
- package/src/StaticComponents/STimingDropDownNew.js +0 -1585
- package/src/StaticComponents/STimingSwitch.js +0 -34
- package/src/layout/CContainerView.js +0 -21
- package/src/layout/CDetailView.js +0 -81
- package/src/layout/HeaderBlock.js +0 -353
- package/src/layout/INVLoginLayout.js +0 -657
- package/src/layout/Loader.js +0 -176
|
@@ -1,402 +0,0 @@
|
|
|
1
|
-
import React, { memo, useState } from 'react';
|
|
2
|
-
import { View, TouchableOpacity, Text, FlatList, ScrollView } from 'react-native';
|
|
3
|
-
import FontAwesome5 from 'react-native-vector-icons/FontAwesome5';
|
|
4
|
-
import { normalize } from '../CommonStyle/componentStyle';
|
|
5
|
-
import CText from '../CustomComponents/CText';
|
|
6
|
-
import HOCIcons from './HOCIcons';
|
|
7
|
-
import { Global } from '../../../../../src/Common/Global';
|
|
8
|
-
import { CButtonShadow,isBNUL, isNU, isNUQ } from '../CommonStyle/ComponentFunctions';
|
|
9
|
-
import HShadowButton from './HShadowButton';
|
|
10
|
-
import HMoreButton from './HMoreButton';
|
|
11
|
-
|
|
12
|
-
function HNatureHeading(props) {
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
const deletebutton = 5;
|
|
16
|
-
const notebutton = 6;
|
|
17
|
-
const instructionbutton = 7;
|
|
18
|
-
const commentbutton = 8;
|
|
19
|
-
const commentbutton2 = 9;
|
|
20
|
-
|
|
21
|
-
const imagebutton = 3;
|
|
22
|
-
const videobutton = 3;
|
|
23
|
-
const audiobutton = 3;
|
|
24
|
-
const documentbutton = 3;
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
const [showButtons, setShowButtons] = useState({
|
|
28
|
-
'mediabuttons': false,
|
|
29
|
-
'detailbuttons': false,
|
|
30
|
-
});
|
|
31
|
-
|
|
32
|
-
const styles = props.styles != undefined ? props.styles : {
|
|
33
|
-
'iconname': 'file',
|
|
34
|
-
'bgcolor': '#f2efef',
|
|
35
|
-
'iconsize': 18,
|
|
36
|
-
'iconcolor': 'black',
|
|
37
|
-
'displaytext': 'Testing',
|
|
38
|
-
'textsize': 15,
|
|
39
|
-
'textcolor': 'darkblue',
|
|
40
|
-
};
|
|
41
|
-
|
|
42
|
-
function CheckDeleteButton(array) { //delete button
|
|
43
|
-
|
|
44
|
-
let prevcodearray = array.filter((i, k) => { return i.buttonflag == deletebutton ? { ...i } : undefined; });
|
|
45
|
-
let prevcode = isBNUL(prevcodearray) ? prevcodearray[0] : false;
|
|
46
|
-
return prevcode;
|
|
47
|
-
|
|
48
|
-
}
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
function groupMediaIcons(array) { // image video audio
|
|
52
|
-
|
|
53
|
-
let prevcodearray = array.filter((i, k) => { return (i.buttonflag == imagebutton || i.buttonflag == videobutton || i.buttonflag == audiobutton || i.buttonflag == documentbutton) ? { ...i } : undefined; });
|
|
54
|
-
let prevcode = isBNUL(prevcodearray) ? prevcodearray : [];
|
|
55
|
-
return prevcode;
|
|
56
|
-
|
|
57
|
-
}
|
|
58
|
-
|
|
59
|
-
function groupEntryIcons(array) { // notes instructions comments
|
|
60
|
-
|
|
61
|
-
let prevcodearray = array.filter((i, k) => { return (i.buttonflag == notebutton || i.buttonflag == instructionbutton || i.buttonflag == commentbutton || i.buttonflag == commentbutton2) ? { ...i } : undefined; });
|
|
62
|
-
let prevcode = isBNUL(prevcodearray) ? prevcodearray : [];
|
|
63
|
-
return prevcode;
|
|
64
|
-
|
|
65
|
-
}
|
|
66
|
-
|
|
67
|
-
function renderList(val) {
|
|
68
|
-
|
|
69
|
-
return (
|
|
70
|
-
<HShadowButton
|
|
71
|
-
useicon={true}
|
|
72
|
-
// usetext={true}
|
|
73
|
-
buttonstyle={{
|
|
74
|
-
margin: normalize(4),
|
|
75
|
-
borderLeftWidth: 0,
|
|
76
|
-
borderBottomWidth: 0,
|
|
77
|
-
borderRadius: 5,
|
|
78
|
-
borderWidth: 0,
|
|
79
|
-
borderColor: Global.AppTheme.primary_color,
|
|
80
|
-
justifyContent: 'center',
|
|
81
|
-
alignItems: 'center',
|
|
82
|
-
backgroundColor: 'white',
|
|
83
|
-
height: normalize(20),
|
|
84
|
-
width: normalize(20),
|
|
85
|
-
...CButtonShadow(),
|
|
86
|
-
}}
|
|
87
|
-
iconcolor={Global.AppTheme.primary_color}
|
|
88
|
-
iconname={isNU(val.iconname) ? val.iconname : 'file-alt'}
|
|
89
|
-
iconsize={normalize(15)}
|
|
90
|
-
iconstyle={{textAlign:'center'}}
|
|
91
|
-
displaytext={isNUQ(val.name) ? val.name : null}
|
|
92
|
-
buttonCallback={() => {
|
|
93
|
-
props.moreCallBack(val);
|
|
94
|
-
}}
|
|
95
|
-
textstyle={{
|
|
96
|
-
color: Global.AppTheme.primary_color,
|
|
97
|
-
fontSize: normalize(7),
|
|
98
|
-
textAlign: 'center',
|
|
99
|
-
}}
|
|
100
|
-
/>
|
|
101
|
-
);
|
|
102
|
-
|
|
103
|
-
}
|
|
104
|
-
|
|
105
|
-
return (
|
|
106
|
-
<View style={{
|
|
107
|
-
// backgroundColor: styles.bgcolor != undefined ? styles.bgcolor : '#f2efef',
|
|
108
|
-
}}>
|
|
109
|
-
<TouchableOpacity
|
|
110
|
-
onPress={() => props.callBack(true)}
|
|
111
|
-
style={{
|
|
112
|
-
// backgroundColor: styles.bgcolor != undefined ? styles.bgcolor : '#f2efef',
|
|
113
|
-
flexDirection: 'row',
|
|
114
|
-
alignItems: 'center',
|
|
115
|
-
// paddingVertical: normalize(3)
|
|
116
|
-
}}>
|
|
117
|
-
<TouchableOpacity
|
|
118
|
-
onPress={() => props.Expand != undefined ? props.Expand(1) : null}
|
|
119
|
-
disabled={props.Expand != undefined ? false : true}
|
|
120
|
-
style={{
|
|
121
|
-
width: normalize(30),
|
|
122
|
-
alignItems: 'center',
|
|
123
|
-
}}
|
|
124
|
-
>
|
|
125
|
-
<FontAwesome5 name={styles.iconname} color={styles.iconcolor}
|
|
126
|
-
size={normalize(styles.iconsize)} />
|
|
127
|
-
</TouchableOpacity>
|
|
128
|
-
<Text
|
|
129
|
-
numberOfLines={1}
|
|
130
|
-
adjustsFontSizeToFit={true}
|
|
131
|
-
style={{
|
|
132
|
-
flex: 1,
|
|
133
|
-
borderWidth: 0,
|
|
134
|
-
textShadowRadius: 2,
|
|
135
|
-
fontSize: normalize(styles.textsize),
|
|
136
|
-
fontWeight: 'bold',
|
|
137
|
-
color: styles.textcolor,
|
|
138
|
-
}}>
|
|
139
|
-
{styles.displaytext}
|
|
140
|
-
</Text>
|
|
141
|
-
{isBNUL(props.moreButtonArray) ?
|
|
142
|
-
<HMoreButton
|
|
143
|
-
styles={{
|
|
144
|
-
'iconname': 'dots-vertical',
|
|
145
|
-
'iconsize': 23,
|
|
146
|
-
'iconcolor': Global.AppTheme.primary_color,
|
|
147
|
-
'textsize': 9,
|
|
148
|
-
'textcolor': Global.AppTheme.primary_color,
|
|
149
|
-
}}
|
|
150
|
-
moreButtonArray={props.moreButtonArray}
|
|
151
|
-
// callBack={val => (val == undefined ? null : getHeaderMoreButtonPress(val, item))} />
|
|
152
|
-
callBack={val => (val == undefined ? null :
|
|
153
|
-
// getSelection(val, item, index)
|
|
154
|
-
props.moreCallBack(val)
|
|
155
|
-
)}
|
|
156
|
-
/>
|
|
157
|
-
: null}
|
|
158
|
-
{isBNUL(props.moreButtonArray) && CheckDeleteButton(props.moreButtonArray) ?
|
|
159
|
-
<View style={{ borderWidth: 0 }}>
|
|
160
|
-
<HShadowButton // DELETE BUTTON
|
|
161
|
-
useicon={true}
|
|
162
|
-
// usetext={true}
|
|
163
|
-
buttonstyle={{
|
|
164
|
-
margin: normalize(2),
|
|
165
|
-
padding: normalize(2),
|
|
166
|
-
borderLeftWidth: 0,
|
|
167
|
-
borderBottomWidth: 0,
|
|
168
|
-
borderRadius: 5,
|
|
169
|
-
borderWidth: 0,
|
|
170
|
-
borderColor: Global.AppTheme.primary_color,
|
|
171
|
-
justifyContent: 'center',
|
|
172
|
-
alignItems: 'center',
|
|
173
|
-
backgroundColor: 'white',
|
|
174
|
-
height: normalize(20),
|
|
175
|
-
width: normalize(20),
|
|
176
|
-
...CButtonShadow(),
|
|
177
|
-
}}
|
|
178
|
-
iconcolor={'#bb3030'}
|
|
179
|
-
iconname={isNU(CheckDeleteButton(props.moreButtonArray).iconname) ? CheckDeleteButton(props.moreButtonArray).iconname : 'file-alt'}
|
|
180
|
-
iconsize={normalize(15)}
|
|
181
|
-
textstyle={{
|
|
182
|
-
color: Global.AppTheme.primary_color,
|
|
183
|
-
fontSize: normalize(5),
|
|
184
|
-
textAlign: 'center',
|
|
185
|
-
}}
|
|
186
|
-
displaytext={isNUQ(CheckDeleteButton(props.moreButtonArray).name) ? CheckDeleteButton(props.moreButtonArray).name : null}
|
|
187
|
-
buttonCallback={() => {
|
|
188
|
-
props.moreCallBack(CheckDeleteButton(props.moreButtonArray));
|
|
189
|
-
}}
|
|
190
|
-
/>
|
|
191
|
-
</View>
|
|
192
|
-
: null}
|
|
193
|
-
|
|
194
|
-
</TouchableOpacity>
|
|
195
|
-
{isBNUL(props.moreButtonArray) ?
|
|
196
|
-
<ScrollView
|
|
197
|
-
showsHorizontalScrollIndicator={false}
|
|
198
|
-
showsVerticalScrollIndicator={false}
|
|
199
|
-
horizontal={true}
|
|
200
|
-
>
|
|
201
|
-
<View style={{ flexDirection: 'row', marginVertical: normalize(4) }}>
|
|
202
|
-
{props.moreButtonArray.map((val) => {
|
|
203
|
-
return val.buttonflag == deletebutton || // DELETE BUTTON
|
|
204
|
-
val.buttonflag == notebutton || // NOTES
|
|
205
|
-
val.buttonflag == instructionbutton || // INSTRUCTIONS
|
|
206
|
-
val.buttonflag == commentbutton || // COMMENTS
|
|
207
|
-
val.buttonflag == commentbutton2 || // COMMENTS 2
|
|
208
|
-
val.buttonflag == imagebutton || // IMAGE
|
|
209
|
-
val.buttonflag == videobutton || // VIDEO
|
|
210
|
-
val.buttonflag == audiobutton || // AUDIO
|
|
211
|
-
val.buttonflag == documentbutton // DOCUMENTS
|
|
212
|
-
? null : (
|
|
213
|
-
renderList(val)
|
|
214
|
-
);
|
|
215
|
-
})}
|
|
216
|
-
{isBNUL(groupMediaIcons(props.moreButtonArray)) ? // image,audio, video, document
|
|
217
|
-
|
|
218
|
-
<TouchableOpacity
|
|
219
|
-
onPress={() => {
|
|
220
|
-
setShowButtons(prevstate => {
|
|
221
|
-
return {
|
|
222
|
-
...prevstate,
|
|
223
|
-
mediabuttons: !prevstate.mediabuttons,
|
|
224
|
-
};
|
|
225
|
-
});
|
|
226
|
-
}}
|
|
227
|
-
style={{
|
|
228
|
-
borderWidth: 0,
|
|
229
|
-
flexDirection: 'row',
|
|
230
|
-
margin: normalize(4),
|
|
231
|
-
padding: normalize(4),
|
|
232
|
-
borderLeftWidth: 0,
|
|
233
|
-
borderBottomWidth: 0,
|
|
234
|
-
borderRadius: 5,
|
|
235
|
-
borderColor: Global.AppTheme.primary_color,
|
|
236
|
-
justifyContent: 'space-evenly',
|
|
237
|
-
alignItems: 'center',
|
|
238
|
-
backgroundColor: 'white',
|
|
239
|
-
...CButtonShadow(),
|
|
240
|
-
height: normalize(20),
|
|
241
|
-
width: normalize(40),
|
|
242
|
-
}}>
|
|
243
|
-
|
|
244
|
-
<HShadowButton
|
|
245
|
-
useicon={true}
|
|
246
|
-
// usetext={true}
|
|
247
|
-
buttonstyle={{
|
|
248
|
-
borderWidth: 0,
|
|
249
|
-
justifyContent: 'center',
|
|
250
|
-
alignItems: 'center',
|
|
251
|
-
}}
|
|
252
|
-
iconcolor={Global.AppTheme.primary_color}
|
|
253
|
-
icongroup={11}
|
|
254
|
-
iconname={'folder-images'}
|
|
255
|
-
iconsize={normalize(15)}
|
|
256
|
-
displaytext={'Media'}
|
|
257
|
-
buttonCallback={() => {
|
|
258
|
-
setShowButtons(prevstate => {
|
|
259
|
-
return {
|
|
260
|
-
...prevstate,
|
|
261
|
-
mediabuttons: !prevstate.mediabuttons,
|
|
262
|
-
};
|
|
263
|
-
});
|
|
264
|
-
}}
|
|
265
|
-
textstyle={{
|
|
266
|
-
color: Global.AppTheme.primary_color,
|
|
267
|
-
fontSize: normalize(7),
|
|
268
|
-
textAlign: 'center',
|
|
269
|
-
}}
|
|
270
|
-
/>
|
|
271
|
-
<HOCIcons.Icons
|
|
272
|
-
icongroup={5}
|
|
273
|
-
color={'black'}
|
|
274
|
-
name={showButtons.mediabuttons ? 'chevron-left' : 'chevron-right'}
|
|
275
|
-
size={normalize(10)}
|
|
276
|
-
style={{ marginHorizontal: normalize(5) }}
|
|
277
|
-
/>
|
|
278
|
-
</TouchableOpacity>
|
|
279
|
-
|
|
280
|
-
// <HShadowButton
|
|
281
|
-
// useicon={true}
|
|
282
|
-
// usetext={true}
|
|
283
|
-
// buttonstyle={{
|
|
284
|
-
// margin: normalize(4),
|
|
285
|
-
// padding: normalize(4),
|
|
286
|
-
// borderLeftWidth: 0,
|
|
287
|
-
// borderBottomWidth: 0,
|
|
288
|
-
// borderRadius: 5,
|
|
289
|
-
// borderWidth: 0,
|
|
290
|
-
// borderColor: Global.AppTheme.primary_color,
|
|
291
|
-
// justifyContent: 'center',
|
|
292
|
-
// alignItems: 'center',
|
|
293
|
-
// backgroundColor: 'white',
|
|
294
|
-
// height: normalize(30),
|
|
295
|
-
// width: normalize(40),
|
|
296
|
-
// }}
|
|
297
|
-
// iconcolor={Global.AppTheme.primary_color}
|
|
298
|
-
// icongroup={11}
|
|
299
|
-
// iconname={'folder-images'}
|
|
300
|
-
// iconsize={normalize(15)}
|
|
301
|
-
// displaytext={'Media'}
|
|
302
|
-
// buttonCallback={() => {
|
|
303
|
-
// setShowButtons(prevstate => {
|
|
304
|
-
// return {
|
|
305
|
-
// ...prevstate,
|
|
306
|
-
// mediabuttons: !prevstate.mediabuttons
|
|
307
|
-
// }
|
|
308
|
-
// })
|
|
309
|
-
// }}
|
|
310
|
-
// textstyle={{
|
|
311
|
-
// color: Global.AppTheme.primary_color,
|
|
312
|
-
// fontSize: normalize(7),
|
|
313
|
-
// textAlign: 'center'
|
|
314
|
-
// }}
|
|
315
|
-
// />
|
|
316
|
-
: null}
|
|
317
|
-
{isBNUL(groupMediaIcons(props.moreButtonArray)) && showButtons.mediabuttons ?
|
|
318
|
-
groupMediaIcons(props.moreButtonArray).map((val) => {
|
|
319
|
-
return (
|
|
320
|
-
renderList(val)
|
|
321
|
-
);
|
|
322
|
-
})
|
|
323
|
-
: null}
|
|
324
|
-
|
|
325
|
-
{isBNUL(groupEntryIcons(props.moreButtonArray)) ? // NOTES , INSTRUCTIONS , COMMENTS
|
|
326
|
-
<TouchableOpacity
|
|
327
|
-
onPress={() => {
|
|
328
|
-
setShowButtons(prevstate => {
|
|
329
|
-
return {
|
|
330
|
-
...prevstate,
|
|
331
|
-
detailbuttons: !prevstate.detailbuttons,
|
|
332
|
-
};
|
|
333
|
-
});
|
|
334
|
-
}}
|
|
335
|
-
style={{
|
|
336
|
-
borderWidth: 0,
|
|
337
|
-
flexDirection: 'row',
|
|
338
|
-
margin: normalize(4),
|
|
339
|
-
padding: normalize(4),
|
|
340
|
-
borderLeftWidth: 0,
|
|
341
|
-
borderBottomWidth: 0,
|
|
342
|
-
borderRadius: 5,
|
|
343
|
-
borderColor: Global.AppTheme.primary_color,
|
|
344
|
-
justifyContent: 'space-evenly',
|
|
345
|
-
alignItems: 'center',
|
|
346
|
-
backgroundColor: 'white',
|
|
347
|
-
...CButtonShadow(),
|
|
348
|
-
height: normalize(20),
|
|
349
|
-
width: normalize(40),
|
|
350
|
-
}}>
|
|
351
|
-
|
|
352
|
-
<HShadowButton
|
|
353
|
-
useicon={true}
|
|
354
|
-
// usetext={true}
|
|
355
|
-
buttonstyle={{
|
|
356
|
-
borderWidth: 0,
|
|
357
|
-
justifyContent: 'center',
|
|
358
|
-
alignItems: 'center',
|
|
359
|
-
}}
|
|
360
|
-
iconcolor={Global.AppTheme.primary_color}
|
|
361
|
-
icongroup={3}
|
|
362
|
-
iconname={'clipboard-text'}
|
|
363
|
-
iconsize={normalize(15)}
|
|
364
|
-
displaytext={'Remarks'}
|
|
365
|
-
buttonCallback={() => {
|
|
366
|
-
setShowButtons(prevstate => {
|
|
367
|
-
return {
|
|
368
|
-
...prevstate,
|
|
369
|
-
detailbuttons: !prevstate.detailbuttons,
|
|
370
|
-
};
|
|
371
|
-
});
|
|
372
|
-
}}
|
|
373
|
-
textstyle={{
|
|
374
|
-
color: Global.AppTheme.primary_color,
|
|
375
|
-
fontSize: normalize(7),
|
|
376
|
-
textAlign: 'center',
|
|
377
|
-
}}
|
|
378
|
-
/>
|
|
379
|
-
<HOCIcons.Icons
|
|
380
|
-
icongroup={5}
|
|
381
|
-
color={'black'}
|
|
382
|
-
name={showButtons.detailbuttons ? 'chevron-left' : 'chevron-right'}
|
|
383
|
-
size={normalize(10)}
|
|
384
|
-
style={{ marginHorizontal: normalize(5) }}
|
|
385
|
-
/>
|
|
386
|
-
</TouchableOpacity>
|
|
387
|
-
: null}
|
|
388
|
-
{isBNUL(groupEntryIcons(props.moreButtonArray)) && showButtons.detailbuttons ?
|
|
389
|
-
groupEntryIcons(props.moreButtonArray).map((val) => {
|
|
390
|
-
return (
|
|
391
|
-
renderList(val)
|
|
392
|
-
);
|
|
393
|
-
})
|
|
394
|
-
: null}
|
|
395
|
-
</View>
|
|
396
|
-
</ScrollView>
|
|
397
|
-
: null}
|
|
398
|
-
</View>
|
|
399
|
-
);
|
|
400
|
-
}
|
|
401
|
-
|
|
402
|
-
export default memo(HNatureHeading);
|
package/src/HOC/HOCIcons.js
DELETED
|
@@ -1,80 +0,0 @@
|
|
|
1
|
-
import React, { memo } from 'react';
|
|
2
|
-
import MaterialCommunityIcons from 'react-native-vector-icons/MaterialCommunityIcons';
|
|
3
|
-
import SimpleLineIcons from 'react-native-vector-icons/SimpleLineIcons';
|
|
4
|
-
import MaterialIcons from 'react-native-vector-icons/MaterialIcons';
|
|
5
|
-
import FontAwesome from 'react-native-vector-icons/FontAwesome';
|
|
6
|
-
import Foundation from 'react-native-vector-icons/Foundation';
|
|
7
|
-
import EvilIcons from 'react-native-vector-icons/EvilIcons';
|
|
8
|
-
import Octicons from 'react-native-vector-icons/Octicons';
|
|
9
|
-
import Ionicons from 'react-native-vector-icons/Ionicons';
|
|
10
|
-
import Feather from 'react-native-vector-icons/Feather';
|
|
11
|
-
import Fontisto from 'react-native-vector-icons/Fontisto';
|
|
12
|
-
import Entypo from 'react-native-vector-icons/Entypo';
|
|
13
|
-
import Zocial from 'react-native-vector-icons/Zocial';
|
|
14
|
-
import FontAwesome5 from 'react-native-vector-icons/FontAwesome5';
|
|
15
|
-
import AntDesign from 'react-native-vector-icons/AntDesign';
|
|
16
|
-
|
|
17
|
-
function Icons(props) {
|
|
18
|
-
|
|
19
|
-
const components = {
|
|
20
|
-
1: AntDesign,
|
|
21
|
-
2: MaterialIcons,
|
|
22
|
-
3: MaterialCommunityIcons,
|
|
23
|
-
4: FontAwesome,
|
|
24
|
-
5: FontAwesome5,
|
|
25
|
-
6: Foundation,
|
|
26
|
-
7: EvilIcons,
|
|
27
|
-
8: Ionicons,
|
|
28
|
-
9: Octicons,
|
|
29
|
-
10: Feather,
|
|
30
|
-
11: Entypo,
|
|
31
|
-
12: Zocial,
|
|
32
|
-
13: Fontisto,
|
|
33
|
-
14: SimpleLineIcons,
|
|
34
|
-
};
|
|
35
|
-
|
|
36
|
-
const HOCIconComponent = props.icongroup != null && props.icongroup != undefined &&
|
|
37
|
-
typeof props.icongroup !== 'boolean' && !isNaN(props.icongroup) && props.icongroup > 0 &&
|
|
38
|
-
props.icongroup < 15 ? components[props.icongroup] : components[5];
|
|
39
|
-
|
|
40
|
-
return (
|
|
41
|
-
<HOCIconComponent
|
|
42
|
-
{...props}
|
|
43
|
-
/>
|
|
44
|
-
);
|
|
45
|
-
}
|
|
46
|
-
/**
|
|
47
|
-
* to use HOC <HOCIcons.Icons
|
|
48
|
-
* Pass icongroup as an integer ex: icongroup={3}
|
|
49
|
-
* @param 1 AntDesign.
|
|
50
|
-
* @param 2 MaterialIcons.
|
|
51
|
-
* @param 3 MaterialCommunityIcons.
|
|
52
|
-
* @param 4 FontAwesome.
|
|
53
|
-
* @param 5 FontAwesome5.
|
|
54
|
-
* @param 6 Foundation.
|
|
55
|
-
* @param 7 EvilIcons.
|
|
56
|
-
* @param 8 Ionicons.
|
|
57
|
-
* @param 9 Octicons.
|
|
58
|
-
* @param 10 Feather.
|
|
59
|
-
* @param 11 Entypo.
|
|
60
|
-
* @param 12 Zocial.
|
|
61
|
-
* @param 13 Fontisto.
|
|
62
|
-
* @param 14 SimpleLineIcons.
|
|
63
|
-
*/
|
|
64
|
-
export default {
|
|
65
|
-
Icons,
|
|
66
|
-
MaterialCommunityIcons,
|
|
67
|
-
SimpleLineIcons,
|
|
68
|
-
MaterialIcons,
|
|
69
|
-
FontAwesome,
|
|
70
|
-
Foundation,
|
|
71
|
-
Fontisto,
|
|
72
|
-
EvilIcons,
|
|
73
|
-
Ionicons,
|
|
74
|
-
Octicons,
|
|
75
|
-
Feather,
|
|
76
|
-
Entypo,
|
|
77
|
-
Zocial,
|
|
78
|
-
FontAwesome5,
|
|
79
|
-
AntDesign,
|
|
80
|
-
};
|
|
@@ -1,140 +0,0 @@
|
|
|
1
|
-
import React, { useEffect } from 'react';
|
|
2
|
-
import { View, Dimensions,Text } from 'react-native';
|
|
3
|
-
import Overlay from 'react-native-modal-overlay';
|
|
4
|
-
import Icons from '../Common/Icons';
|
|
5
|
-
import { normalize } from '../CommonStyle/componentStyle';
|
|
6
|
-
|
|
7
|
-
const HOverlayCentered = (WrapComponent) => {
|
|
8
|
-
|
|
9
|
-
const { width, height } = Dimensions.get('window');
|
|
10
|
-
return function (props) {
|
|
11
|
-
useEffect(() => {
|
|
12
|
-
let isMounted = true;
|
|
13
|
-
});
|
|
14
|
-
|
|
15
|
-
function getPopupContainerStyle() {
|
|
16
|
-
return (
|
|
17
|
-
props.overlaystyle
|
|
18
|
-
);
|
|
19
|
-
}
|
|
20
|
-
|
|
21
|
-
return (
|
|
22
|
-
<Overlay
|
|
23
|
-
visible={true}
|
|
24
|
-
onClose={() => props.visibility != undefined ? props.visibility(false) : null}
|
|
25
|
-
closeOnTouchOutside={ props.disableOnTouch ? false : true}
|
|
26
|
-
animationType="fadeInUp"
|
|
27
|
-
// containerStyle={{ backgroundColor: 'rgba(0, 0, 0, 0.233)' }}
|
|
28
|
-
containerStyle={{ backgroundColor: 'rgba(0, 0, 0, 0.233)' }}
|
|
29
|
-
animationDuration={500}
|
|
30
|
-
childrenWrapperStyle={getPopupContainerStyle()}>
|
|
31
|
-
<View style={{ flex: 1 }} >
|
|
32
|
-
|
|
33
|
-
{props.position && props.position != null && props.position != undefined ?
|
|
34
|
-
null
|
|
35
|
-
:
|
|
36
|
-
<View
|
|
37
|
-
style={{
|
|
38
|
-
flexDirection: 'row',
|
|
39
|
-
justifyContent: 'space-between',
|
|
40
|
-
alignItems: 'center',
|
|
41
|
-
width: Dimensions.get('screen').width,
|
|
42
|
-
borderWidth: 0,
|
|
43
|
-
borderTopLeftRadius: 10,
|
|
44
|
-
paddingVertical: normalize(5),
|
|
45
|
-
borderTopRightRadius: 10,
|
|
46
|
-
}}>
|
|
47
|
-
|
|
48
|
-
<View style={{
|
|
49
|
-
width: '10%',
|
|
50
|
-
borderWidth: 0,
|
|
51
|
-
}}>
|
|
52
|
-
<Text>{''}</Text>
|
|
53
|
-
</View>
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
<View style={{
|
|
57
|
-
flex: 1,
|
|
58
|
-
width: '80%',
|
|
59
|
-
borderWidth: 0,
|
|
60
|
-
justifyContent: 'center',
|
|
61
|
-
alignItems: 'center',
|
|
62
|
-
}}>
|
|
63
|
-
<View style={{ flexDirection: 'row', alignItems: 'center', justifyContent: 'center' }}>
|
|
64
|
-
{props.overlayheading != null && props.overlayheading != undefined ?
|
|
65
|
-
<Icons.FontAwesome5
|
|
66
|
-
name={props.overlayicon != null && props.overlayicon != undefined ? props.overlayicon : 'file'}
|
|
67
|
-
color={'#000000'}
|
|
68
|
-
size={normalize(11)}
|
|
69
|
-
style={{ marginHorizontal: normalize(5) }}
|
|
70
|
-
/>
|
|
71
|
-
: null}
|
|
72
|
-
<Text style={{ color: '#000000', fontSize: normalize(11), fontWeight: 'bold', textAlign: 'center' }}>{props.overlayheading != null && props.overlayheading != undefined ? props.overlayheading : ''}</Text>
|
|
73
|
-
</View>
|
|
74
|
-
</View>
|
|
75
|
-
|
|
76
|
-
<View style={{
|
|
77
|
-
width: '10%',
|
|
78
|
-
borderWidth: 0,
|
|
79
|
-
}}>
|
|
80
|
-
<Text>{' '}</Text>
|
|
81
|
-
</View>
|
|
82
|
-
</View>
|
|
83
|
-
}
|
|
84
|
-
<WrapComponent
|
|
85
|
-
{...props}
|
|
86
|
-
/>
|
|
87
|
-
{props.position && props.position != null && props.position != undefined && props.position == true ?
|
|
88
|
-
<View
|
|
89
|
-
style={{
|
|
90
|
-
position: 'absolute',
|
|
91
|
-
flexDirection: 'row',
|
|
92
|
-
justifyContent: 'space-between',
|
|
93
|
-
alignItems: 'center',
|
|
94
|
-
width: Dimensions.get('screen').width,
|
|
95
|
-
borderWidth: 0,
|
|
96
|
-
borderTopLeftRadius: 10,
|
|
97
|
-
paddingVertical: normalize(5),
|
|
98
|
-
borderTopRightRadius: 10,
|
|
99
|
-
}}>
|
|
100
|
-
|
|
101
|
-
<View style={{
|
|
102
|
-
width: '10%',
|
|
103
|
-
borderWidth: 0,
|
|
104
|
-
}}>
|
|
105
|
-
<Text>{''}</Text>
|
|
106
|
-
</View>
|
|
107
|
-
<View style={{
|
|
108
|
-
flex: 1,
|
|
109
|
-
width: '80%',
|
|
110
|
-
borderWidth: 0,
|
|
111
|
-
justifyContent: 'center',
|
|
112
|
-
alignItems: 'center',
|
|
113
|
-
}}>
|
|
114
|
-
<View style={{ flexDirection: 'row', alignItems: 'center', justifyContent: 'center' }}>
|
|
115
|
-
{props.overlayheading != null && props.overlayheading != undefined ?
|
|
116
|
-
<Icons.FontAwesome5
|
|
117
|
-
name={props.overlayicon != null && props.overlayicon != undefined ? props.overlayicon : 'file'}
|
|
118
|
-
color={'#000000'}
|
|
119
|
-
size={normalize(11)}
|
|
120
|
-
style={{ marginHorizontal: normalize(5) }}
|
|
121
|
-
/>
|
|
122
|
-
: null}
|
|
123
|
-
<Text style={{ color: '#000000', fontSize: normalize(11), fontWeight: 'bold', textAlign: 'center' }}>{props.overlayheading != null && props.overlayheading != undefined ? props.overlayheading : ''}</Text>
|
|
124
|
-
</View>
|
|
125
|
-
</View>
|
|
126
|
-
<View style={{
|
|
127
|
-
width: '10%',
|
|
128
|
-
borderWidth: 0,
|
|
129
|
-
}}>
|
|
130
|
-
<Text>{' '}</Text>
|
|
131
|
-
</View>
|
|
132
|
-
</View>
|
|
133
|
-
: null}
|
|
134
|
-
</View>
|
|
135
|
-
</Overlay>
|
|
136
|
-
);
|
|
137
|
-
};
|
|
138
|
-
};
|
|
139
|
-
|
|
140
|
-
export default HOverlayCentered;
|
package/src/HOC/HShadowButton.js
DELETED
|
@@ -1,45 +0,0 @@
|
|
|
1
|
-
import { Text, TouchableOpacity } from 'react-native';
|
|
2
|
-
import { isBNU, isNU, isNUQ, normalize } from '../CommonStyle/ComponentFunctions';
|
|
3
|
-
import HOCIcons from './HOCIcons';
|
|
4
|
-
import { Global } from '../../../../../src/Common/Global';
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
export default function HShadowButton(props) {
|
|
8
|
-
|
|
9
|
-
return (
|
|
10
|
-
<TouchableOpacity
|
|
11
|
-
disabled={props.disabled ? true : false}
|
|
12
|
-
onPress={() => {
|
|
13
|
-
isNU(props.buttonCallback) ? props.buttonCallback(true) : null;
|
|
14
|
-
}}
|
|
15
|
-
style={isNU(props.buttonstyle) ? props.buttonstyle : {}}>
|
|
16
|
-
{props.useicon ?
|
|
17
|
-
<HOCIcons.Icons
|
|
18
|
-
icongroup={isNU(props.icongroup) ? props.icongroup : 5}
|
|
19
|
-
name={isBNU(props.iconname) ? props.iconname : 'file-alt'}
|
|
20
|
-
color={isNU(props.iconcolor) ? props.iconcolor : Global.AppTheme.primary_color}
|
|
21
|
-
size={isNU(props.iconsize) ? props.iconsize : normalize(15)}
|
|
22
|
-
style={props.iconstyle ? props.iconstyle : {}}
|
|
23
|
-
/>
|
|
24
|
-
: null}
|
|
25
|
-
{props.usetext ?
|
|
26
|
-
<Text
|
|
27
|
-
numberOfLines={1}
|
|
28
|
-
adjustsFontSizeToFit={true}
|
|
29
|
-
style={
|
|
30
|
-
props.textstyle ?
|
|
31
|
-
props.textstyle :
|
|
32
|
-
{
|
|
33
|
-
color: Global.AppTheme.primary_color,
|
|
34
|
-
fontSize: normalize(6),
|
|
35
|
-
textAlign: 'center',
|
|
36
|
-
}
|
|
37
|
-
}
|
|
38
|
-
>
|
|
39
|
-
{isNUQ(props.displaytext) ? props.displaytext : null}
|
|
40
|
-
</Text>
|
|
41
|
-
: null}
|
|
42
|
-
</TouchableOpacity>
|
|
43
|
-
);
|
|
44
|
-
|
|
45
|
-
}
|