removed react-native-theming from all project

This commit is contained in:
ue 2018-09-30 02:57:38 +03:00
parent 323ba0cacf
commit c3dd62cbaf
7 changed files with 133 additions and 190 deletions

8
package-lock.json generated
View File

@ -8965,14 +8965,6 @@
"prop-types": "^15.5.10" "prop-types": "^15.5.10"
} }
}, },
"react-native-theming": {
"version": "1.0.16",
"resolved": "https://registry.npmjs.org/react-native-theming/-/react-native-theming-1.0.16.tgz",
"integrity": "sha512-f8P7F3yKW9i+PmsmZo98V933Ggsu6YpsBw8pvNEAOENnNqbFmeDL6K+89F0WmkpF6bSs/qqSbyGUWKvCgNhBkw==",
"requires": {
"prop-types": "^15.6.0"
}
},
"react-native-vector-icons": { "react-native-vector-icons": {
"version": "4.6.0", "version": "4.6.0",
"resolved": "https://registry.npmjs.org/react-native-vector-icons/-/react-native-vector-icons-4.6.0.tgz", "resolved": "https://registry.npmjs.org/react-native-vector-icons/-/react-native-vector-icons-4.6.0.tgz",

View File

@ -32,7 +32,6 @@
"react-native-navigation": "^2.0.2519", "react-native-navigation": "^2.0.2519",
"react-native-restart": "0.0.6", "react-native-restart": "0.0.6",
"react-native-slider": "^0.11.0", "react-native-slider": "^0.11.0",
"react-native-theming": "^1.0.16",
"react-native-vector-icons": "^4.6.0", "react-native-vector-icons": "^4.6.0",
"react-redux": "^5.0.7", "react-redux": "^5.0.7",
"realm": "^2.15.3", "realm": "^2.15.3",

View File

@ -1,36 +1,34 @@
import { createStyle } from "react-native-theming"; import EStyleSheet from "react-native-extended-stylesheet";
import { StatusBar, Dimensions } from "react-native"; import { StatusBar } from "react-native";
const styles = createStyle({ export default EStyleSheet.create({
container: { container: {
backgroundColor: "#F9F9F9", backgroundColor: "#F9F9F9",
flex: 1, flex: 1,
top: StatusBar.currentHeight, top: StatusBar.currentHeight,
}, },
placeholder: { placeholder: {
backgroundColor: "white", backgroundColor: "white",
padding: 20, padding: 20,
borderStyle: "solid", borderStyle: "solid",
borderWidth: 1, borderWidth: 1,
borderTopWidth: 1, borderTopWidth: 1,
borderColor: "#e2e5e8", borderColor: "#e2e5e8",
borderRadius: 5, borderRadius: 5,
marginRight: 0, marginRight: 0,
marginLeft: 0, marginLeft: 0,
marginTop: 10, marginTop: 10,
}, },
tabs: { tabs: {
position: "absolute", position: "absolute",
top: Dimensions.get("window").width / 30, top: "$deviceWidth / 30",
alignItems: "center", alignItems: "center",
}, },
flatlistFooter: { flatlistFooter: {
alignContent: "center", alignContent: "center",
alignItems: "center", alignItems: "center",
marginTop: 10, marginTop: 10,
marginBottom: 40, marginBottom: 40,
borderColor: "#CED0CE", borderColor: "#CED0CE",
}, },
}); });
export default styles;

View File

@ -1,18 +1,15 @@
import { createStyle } from "react-native-theming"; import EStyleSheet from "react-native-extended-stylesheet";
import { Dimensions } from "react-native";
const deviceWidth = Dimensions.get("window").width; export default EStyleSheet.create({
container: {
export default createStyle({ flex: 1,
container: { alignItems: "center",
flex: 1, justifyContent: "center",
alignItems: "center", },
justifyContent: "center", input: {
}, backgroundColor: "#f5f5f5",
input: { borderRadius: 5,
backgroundColor: "#f5f5f5", padding: 15,
borderRadius: 5, minWidth: "$deviceWidth / 2",
padding: 15, },
minWidth: deviceWidth / 2,
},
}); });

View File

@ -1,61 +1,58 @@
import { createStyle } from "react-native-theming"; import EStyleSheet from "react-native-extended-stylesheet";
import { StatusBar, Dimensions } from "react-native";
const styles = createStyle({ export default EStyleSheet.create({
container: { container: {
backgroundColor: "#F9F9F9", backgroundColor: "#F9F9F9",
flex: 1, flex: 1,
}, },
tabs: { tabs: {
flex: 1, flex: 1,
}, },
placeholder: { placeholder: {
backgroundColor: "white", backgroundColor: "white",
padding: 20, padding: 20,
borderStyle: "solid", borderStyle: "solid",
borderWidth: 1, borderWidth: 1,
borderTopWidth: 1, borderTopWidth: 1,
borderColor: "#e2e5e8", borderColor: "#e2e5e8",
borderRadius: 5, borderRadius: 5,
marginRight: 0, marginRight: 0,
marginLeft: 0, marginLeft: 0,
marginTop: 10, marginTop: 10,
}, },
header: { header: {
backgroundColor: "#284b78", backgroundColor: "#284b78",
borderBottomWidth: 0, borderBottomWidth: 0,
borderColor: "#284b78", borderColor: "#284b78",
}, },
avatar: { avatar: {
width: 30, width: 30,
height: 30, height: 30,
borderRadius: 15, borderRadius: 15,
borderWidth: 1, borderWidth: 1,
borderColor: "white", borderColor: "white",
}, },
searchButton: { searchButton: {
color: "white", color: "white",
fontWeight: "bold", fontWeight: "bold",
}, },
tabView: { tabView: {
alignSelf: "center", alignSelf: "center",
backgroundColor: "transparent", backgroundColor: "transparent",
}, },
tabbar: { tabbar: {
alignSelf: "center", alignSelf: "center",
height: 40, height: 40,
backgroundColor: "#284b78", backgroundColor: "#284b78",
}, },
tabbarItem: { tabbarItem: {
flex: 1, flex: 1,
paddingHorizontal: 7, paddingHorizontal: 7,
backgroundColor: "#f9f9f9", backgroundColor: "#f9f9f9",
minWidth: Dimensions.get("window").width, minWidth: "$deviceWidth",
}, },
loginButton: { loginButton: {
alignSelf: "center", alignSelf: "center",
marginTop: 100, marginTop: 100,
}, },
}); });
export default styles;

View File

@ -1,36 +1,33 @@
import { createStyle } from "react-native-theming"; import EStyleSheet from "react-native-extended-stylesheet";
import { StatusBar, Dimensions } from "react-native"; import { StatusBar } from "react-native";
export default EStyleSheet.create({
const styles = createStyle({ container: {
container: { backgroundColor: "#F9F9F9",
backgroundColor: "#F9F9F9", flex: 1,
flex: 1, top: StatusBar.currentHeight,
top: StatusBar.currentHeight, },
}, placeholder: {
placeholder: { backgroundColor: "white",
backgroundColor: "white", padding: 20,
padding: 20, borderStyle: "solid",
borderStyle: "solid", borderWidth: 1,
borderWidth: 1, borderTopWidth: 1,
borderTopWidth: 1, borderColor: "#e2e5e8",
borderColor: "#e2e5e8", borderRadius: 5,
borderRadius: 5, marginRight: 0,
marginRight: 0, marginLeft: 0,
marginLeft: 0, marginTop: 10,
marginTop: 10, },
}, tabs: {
tabs: { position: "absolute",
position: "absolute", top: "$deviceWidth / 30",
top: Dimensions.get("window").width / 30, alignItems: "center",
alignItems: "center", },
}, flatlistFooter: {
flatlistFooter: { alignContent: "center",
alignContent: "center", alignItems: "center",
alignItems: "center", marginTop: 10,
marginTop: 10, marginBottom: 40,
marginBottom: 40, borderColor: "#CED0CE",
borderColor: "#CED0CE", },
},
}); });
export default styles;

View File

@ -1,37 +0,0 @@
import { createTheme } from 'react-native-theming';
const fonts = {
FONT_SIZE_SMALL: '12',
FONT_SIZE_MEDIUM: '14',
FONT_SIZE_LARGE: '16',
FONT_WEIGHT_LIGHT: '200',
FONT_WEIGHT_MEDIUM: '600',
FONT_WEIGHT_HEAVY: '800',
};
const themes = [
createTheme(
{
backgroundColor: 'white',
textColor: 'black',
buttonColor: 'blue',
buttonText: 'white',
statusBar: 'dark-content',
fontSize: fonts.FONT_SIZE_MEDIUM,
fontWeight: fonts.FONT_WEIGHT_MEDIUM,
},
'Light'
),
createTheme(
{
backgroundColor: 'black',
textColor: 'white',
buttonColor: 'yellow',
buttonText: 'black',
statusBar: 'light-content',
fontSize: fonts.FONT_SIZE_MEDIUM,
fontWeight: fonts.FONT_WEIGHT_MEDIUM,
},
'Dark'
),
];