2022-08-26 16:19:39 +05:00
|
|
|
import { View } from "react-native";
|
|
|
|
|
import { useThemeStore } from "../../stores/use-theme-store";
|
|
|
|
|
import { useSelectionStore } from "../../stores/use-selection-store";
|
2020-05-10 22:14:44 +05:00
|
|
|
|
2022-02-28 13:48:59 +05:00
|
|
|
export const ContainerHeader = ({ children }) => {
|
2022-08-26 16:19:39 +05:00
|
|
|
const colors = useThemeStore((state) => state.colors);
|
|
|
|
|
const selectionMode = useSelectionStore((state) => state.selectionMode);
|
2020-05-10 22:14:44 +05:00
|
|
|
|
2021-09-13 08:53:16 +05:00
|
|
|
return !selectionMode ? (
|
2021-02-15 10:53:55 +05:00
|
|
|
<View
|
2020-05-10 22:14:44 +05:00
|
|
|
style={{
|
|
|
|
|
backgroundColor: colors.bg,
|
2022-08-26 16:19:39 +05:00
|
|
|
width: "100%",
|
|
|
|
|
overflow: "hidden"
|
2022-01-22 12:57:05 +05:00
|
|
|
}}
|
|
|
|
|
>
|
2021-04-11 14:04:14 +05:00
|
|
|
{children}
|
2021-02-15 10:53:55 +05:00
|
|
|
</View>
|
2022-01-22 12:57:05 +05:00
|
|
|
) : null;
|
2020-05-10 22:14:44 +05:00
|
|
|
};
|