verstka
This commit is contained in:
@@ -3,13 +3,17 @@ import LoginScreen from "../LoginScreen/LoginScreen";
|
||||
import MainScreen from "../MainScreen/MainScreen";
|
||||
import SearchBar from "../../components/SearchBar/SearchBar";
|
||||
import React from "react";
|
||||
import {background} from "../../css/colors";
|
||||
import {useSelector} from "react-redux";
|
||||
import {RootState} from "../../redux/store";
|
||||
|
||||
function CommonPage() {
|
||||
|
||||
const dim = useSelector((state: RootState) => state.interface.dim);
|
||||
return (
|
||||
|
||||
<View style={styles.main}>
|
||||
<MainScreen/>
|
||||
<View style={[styles.overlay, {display: dim ? 'flex' : 'none'}]}/>
|
||||
</View>
|
||||
|
||||
)
|
||||
@@ -20,7 +24,13 @@ const styles = StyleSheet.create({
|
||||
display: "flex",
|
||||
flexDirection: "column",
|
||||
flexGrow: 1,
|
||||
flex: 1
|
||||
flex: 1,
|
||||
backgroundColor: background
|
||||
},
|
||||
overlay: {
|
||||
...StyleSheet.absoluteFillObject,
|
||||
backgroundColor: 'rgba(0, 0, 0, 0.5)',
|
||||
zIndex: 2,
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
Reference in New Issue
Block a user