react-crud-mobile 1.0.826 → 1.0.828
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 +73 -62
- 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 +73 -62
- package/dist/react-crud-mobile.esm.js.map +1 -1
- package/package.json +2 -2
- package/src/elements/UIElement.tsx +78 -67
|
@@ -1713,6 +1713,75 @@ function UIElement(props) {
|
|
|
1713
1713
|
}
|
|
1714
1714
|
return /*#__PURE__*/jsxRuntime.jsx(jsxRuntime.Fragment, {});
|
|
1715
1715
|
};
|
|
1716
|
+
var Container = function Container() {
|
|
1717
|
+
return /*#__PURE__*/jsxRuntime.jsxs(jsxRuntime.Fragment, {
|
|
1718
|
+
children: [isShowLabel() && /*#__PURE__*/jsxRuntime.jsxs(reactNative.View, {
|
|
1719
|
+
style: getStyle('outerLabel', {
|
|
1720
|
+
alignSelf: 'flex-start',
|
|
1721
|
+
flexDirection: 'row',
|
|
1722
|
+
display: 'flex',
|
|
1723
|
+
justifyContent: 'space-between',
|
|
1724
|
+
alignItems: 'center',
|
|
1725
|
+
width: '100%'
|
|
1726
|
+
}),
|
|
1727
|
+
children: [/*#__PURE__*/jsxRuntime.jsx(reactNative.Text, {
|
|
1728
|
+
style: getStyle('label'),
|
|
1729
|
+
children: scope.getLabel()
|
|
1730
|
+
}), /*#__PURE__*/jsxRuntime.jsx(Include, {
|
|
1731
|
+
name: "actions",
|
|
1732
|
+
style: {
|
|
1733
|
+
width: 'auto'
|
|
1734
|
+
}
|
|
1735
|
+
})]
|
|
1736
|
+
}), isShowInner() && /*#__PURE__*/jsxRuntime.jsxs(jsxRuntime.Fragment, {
|
|
1737
|
+
children: [/*#__PURE__*/jsxRuntime.jsx(reactNative.View, {
|
|
1738
|
+
style: getStyle('inner'),
|
|
1739
|
+
children: /*#__PURE__*/jsxRuntime.jsx(Inner, {})
|
|
1740
|
+
}), error && /*#__PURE__*/jsxRuntime.jsx(reactNative.View, {
|
|
1741
|
+
style: getStyle('error'),
|
|
1742
|
+
children: error
|
|
1743
|
+
})]
|
|
1744
|
+
}), scope.isType('list', 'repeat') && /*#__PURE__*/jsxRuntime.jsx(UIList, _extends({}, props, {
|
|
1745
|
+
scope: scope,
|
|
1746
|
+
crud: crud
|
|
1747
|
+
})), scope.isType('dialog') && /*#__PURE__*/jsxRuntime.jsx(UIModal, _extends({}, props, {
|
|
1748
|
+
scope: scope,
|
|
1749
|
+
crud: crud
|
|
1750
|
+
})), scope.isType('chart') && /*#__PURE__*/jsxRuntime.jsx(ElChart, _extends({}, props, {
|
|
1751
|
+
scope: scope,
|
|
1752
|
+
crud: crud
|
|
1753
|
+
})), scope.isType('tabs') && /*#__PURE__*/jsxRuntime.jsx(ElTabs, _extends({}, props, {
|
|
1754
|
+
scope: scope,
|
|
1755
|
+
crud: crud
|
|
1756
|
+
})), scope.isType('view') && /*#__PURE__*/jsxRuntime.jsx(UIView, _extends({}, props, {
|
|
1757
|
+
scope: scope,
|
|
1758
|
+
crud: crud
|
|
1759
|
+
})), isShowChild() && /*#__PURE__*/jsxRuntime.jsx(UIChildren, _extends({}, props, {
|
|
1760
|
+
scope: scope,
|
|
1761
|
+
crud: crud,
|
|
1762
|
+
style: getStyle('inner')
|
|
1763
|
+
}))]
|
|
1764
|
+
});
|
|
1765
|
+
};
|
|
1766
|
+
var Card = function Card(props) {
|
|
1767
|
+
var isCard = scope.is('type|layout', 'card');
|
|
1768
|
+
if (isCard) {
|
|
1769
|
+
return /*#__PURE__*/jsxRuntime.jsx(reactNative.View, {
|
|
1770
|
+
style: getStyle('card', _extends({}, boxStyle.box, {
|
|
1771
|
+
alignSelf: 'stretch'
|
|
1772
|
+
})),
|
|
1773
|
+
children: /*#__PURE__*/jsxRuntime.jsx(reactNative.View, {
|
|
1774
|
+
style: getStyle('cardInner', {
|
|
1775
|
+
padding: 5
|
|
1776
|
+
}),
|
|
1777
|
+
children: props.children
|
|
1778
|
+
})
|
|
1779
|
+
});
|
|
1780
|
+
}
|
|
1781
|
+
return /*#__PURE__*/jsxRuntime.jsx(jsxRuntime.Fragment, {
|
|
1782
|
+
children: props.children
|
|
1783
|
+
});
|
|
1784
|
+
};
|
|
1716
1785
|
return /*#__PURE__*/jsxRuntime.jsx(CrudContext.Provider, {
|
|
1717
1786
|
value: {
|
|
1718
1787
|
crud: crud,
|
|
@@ -1722,70 +1791,23 @@ function UIElement(props) {
|
|
|
1722
1791
|
ref: ref,
|
|
1723
1792
|
style: getStyle()
|
|
1724
1793
|
}, custom, {
|
|
1725
|
-
children: /*#__PURE__*/jsxRuntime.
|
|
1726
|
-
children:
|
|
1727
|
-
style: getStyle('outerLabel', {
|
|
1728
|
-
alignSelf: 'flex-start',
|
|
1729
|
-
flexDirection: 'row',
|
|
1730
|
-
display: 'flex',
|
|
1731
|
-
justifyContent: 'space-between',
|
|
1732
|
-
alignItems: 'center',
|
|
1733
|
-
width: '100%'
|
|
1734
|
-
}),
|
|
1735
|
-
children: [/*#__PURE__*/jsxRuntime.jsx(reactNative.Text, {
|
|
1736
|
-
style: getStyle('label'),
|
|
1737
|
-
children: scope.getLabel()
|
|
1738
|
-
}), /*#__PURE__*/jsxRuntime.jsx(Include, {
|
|
1739
|
-
name: "actions",
|
|
1740
|
-
style: {
|
|
1741
|
-
width: 'auto'
|
|
1742
|
-
}
|
|
1743
|
-
})]
|
|
1744
|
-
}), isShowInner() && /*#__PURE__*/jsxRuntime.jsxs(jsxRuntime.Fragment, {
|
|
1745
|
-
children: [/*#__PURE__*/jsxRuntime.jsx(reactNative.View, {
|
|
1746
|
-
style: getStyle('inner'),
|
|
1747
|
-
children: /*#__PURE__*/jsxRuntime.jsx(Inner, {})
|
|
1748
|
-
}), error && /*#__PURE__*/jsxRuntime.jsx(reactNative.View, {
|
|
1749
|
-
style: getStyle('error'),
|
|
1750
|
-
children: error
|
|
1751
|
-
})]
|
|
1752
|
-
}), scope.isType('list', 'repeat') && /*#__PURE__*/jsxRuntime.jsx(UIList, _extends({}, props, {
|
|
1753
|
-
scope: scope,
|
|
1754
|
-
crud: crud
|
|
1755
|
-
})), scope.isType('dialog') && /*#__PURE__*/jsxRuntime.jsx(UIModal, _extends({}, props, {
|
|
1756
|
-
scope: scope,
|
|
1757
|
-
crud: crud
|
|
1758
|
-
})), scope.isType('chart') && /*#__PURE__*/jsxRuntime.jsx(ElChart, _extends({}, props, {
|
|
1759
|
-
scope: scope,
|
|
1760
|
-
crud: crud
|
|
1761
|
-
})), scope.isType('tabs') && /*#__PURE__*/jsxRuntime.jsx(ElTabs, _extends({}, props, {
|
|
1762
|
-
scope: scope,
|
|
1763
|
-
crud: crud
|
|
1764
|
-
})), scope.isType('view') && /*#__PURE__*/jsxRuntime.jsx(UIView, _extends({}, props, {
|
|
1765
|
-
scope: scope,
|
|
1766
|
-
crud: crud
|
|
1767
|
-
})), isShowChild() && /*#__PURE__*/jsxRuntime.jsx(UIChildren, _extends({}, props, {
|
|
1768
|
-
scope: scope,
|
|
1769
|
-
crud: crud,
|
|
1770
|
-
style: getStyle('inner')
|
|
1771
|
-
}))]
|
|
1794
|
+
children: /*#__PURE__*/jsxRuntime.jsx(Card, {
|
|
1795
|
+
children: /*#__PURE__*/jsxRuntime.jsx(Container, {})
|
|
1772
1796
|
})
|
|
1773
1797
|
}))
|
|
1774
1798
|
});
|
|
1775
1799
|
}
|
|
1776
|
-
var
|
|
1800
|
+
var boxStyle = /*#__PURE__*/reactNative.StyleSheet.create({
|
|
1777
1801
|
box: {
|
|
1778
1802
|
borderWidth: 1,
|
|
1779
1803
|
borderColor: '#dedede',
|
|
1780
1804
|
borderStyle: 'solid',
|
|
1781
1805
|
backgroundColor: 'white',
|
|
1782
|
-
paddingVertical: 10,
|
|
1783
|
-
paddingHorizontal: 15,
|
|
1784
1806
|
borderRadius: 10,
|
|
1785
1807
|
width: '100%'
|
|
1786
1808
|
}
|
|
1787
1809
|
});
|
|
1788
|
-
var box = /*#__PURE__*/_extends({},
|
|
1810
|
+
var box = /*#__PURE__*/_extends({}, boxStyle.box);
|
|
1789
1811
|
//v2
|
|
1790
1812
|
var elementStyle = {};
|
|
1791
1813
|
elementStyle.view = {
|
|
@@ -1807,17 +1829,6 @@ elementStyle.view = {
|
|
|
1807
1829
|
padding: 0
|
|
1808
1830
|
}
|
|
1809
1831
|
};
|
|
1810
|
-
elementStyle.card = /*#__PURE__*/reactNative.StyleSheet.create({
|
|
1811
|
-
root: /*#__PURE__*/_extends({}, box),
|
|
1812
|
-
inner: {
|
|
1813
|
-
flexDirection: 'row',
|
|
1814
|
-
flexWrap: 'wrap',
|
|
1815
|
-
paddingBottom: 10,
|
|
1816
|
-
paddingTop: 5,
|
|
1817
|
-
width: '100%',
|
|
1818
|
-
flex: 1
|
|
1819
|
-
}
|
|
1820
|
-
});
|
|
1821
1832
|
elementStyle.input = /*#__PURE__*/reactNative.StyleSheet.create({
|
|
1822
1833
|
label: {
|
|
1823
1834
|
paddingLeft: 0
|