react-crud-mobile 1.3.147 → 1.3.149
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/react-crud-mobile.cjs.development.js +16 -8
- package/dist/react-crud-mobile.cjs.development.js.map +1 -1
- package/dist/react-crud-mobile.cjs.production.min.js +1 -1
- package/dist/react-crud-mobile.cjs.production.min.js.map +1 -1
- package/dist/react-crud-mobile.esm.js +16 -8
- package/dist/react-crud-mobile.esm.js.map +1 -1
- package/package.json +1 -1
- package/src/elements/core/UIModal.tsx +24 -12
package/package.json
CHANGED
|
@@ -34,7 +34,7 @@ export default function UIModal({
|
|
|
34
34
|
}: UIModalType) {
|
|
35
35
|
let [modalVisible, setModalVisible] = useState(open === true);
|
|
36
36
|
let [index, setIndex] = useState(0);
|
|
37
|
-
//
|
|
37
|
+
//v8
|
|
38
38
|
|
|
39
39
|
const label = scope.getLabel();
|
|
40
40
|
const theme = scope.getTheme();
|
|
@@ -76,6 +76,8 @@ export default function UIModal({
|
|
|
76
76
|
|
|
77
77
|
scope.put('scrollRef', scrollRef);
|
|
78
78
|
|
|
79
|
+
const original = scope.original;
|
|
80
|
+
|
|
79
81
|
ComponentUtils.setViewScope(scope);
|
|
80
82
|
|
|
81
83
|
let color = Utils.nvl(headerStyle.color, 'white');
|
|
@@ -124,8 +126,6 @@ export default function UIModal({
|
|
|
124
126
|
};
|
|
125
127
|
|
|
126
128
|
const ModalView = ({ children }) => {
|
|
127
|
-
const original = scope.original;
|
|
128
|
-
|
|
129
129
|
if (original.gesture) {
|
|
130
130
|
return (
|
|
131
131
|
<GestureHandlerRootView
|
|
@@ -139,15 +139,14 @@ export default function UIModal({
|
|
|
139
139
|
}
|
|
140
140
|
return <>{children}</>;
|
|
141
141
|
};
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
>
|
|
142
|
+
|
|
143
|
+
const ModalInner = () => {
|
|
144
|
+
if (original.transient) {
|
|
145
|
+
return <Content />;
|
|
146
|
+
}
|
|
147
|
+
|
|
148
|
+
return (
|
|
149
|
+
<>
|
|
151
150
|
<SafeAreaView style={style('modalTop')} />
|
|
152
151
|
<SafeAreaView style={style('modalSafe')}>
|
|
153
152
|
<View style={scope.getStyle('header', headerStyle)}>
|
|
@@ -185,6 +184,19 @@ export default function UIModal({
|
|
|
185
184
|
{bottom}
|
|
186
185
|
</SafeAreaView>
|
|
187
186
|
<UIToast />
|
|
187
|
+
</>
|
|
188
|
+
);
|
|
189
|
+
};
|
|
190
|
+
return (
|
|
191
|
+
<ModalView>
|
|
192
|
+
<Modal
|
|
193
|
+
key={key}
|
|
194
|
+
animationType="slide"
|
|
195
|
+
transparent={true}
|
|
196
|
+
visible={modalVisible}
|
|
197
|
+
onRequestClose={onClose}
|
|
198
|
+
>
|
|
199
|
+
<ModalInner />
|
|
188
200
|
</Modal>
|
|
189
201
|
</ModalView>
|
|
190
202
|
);
|