refactor selection system

This commit is contained in:
ammarahm-ed
2020-05-10 22:19:10 +05:00
parent 9d2e1a1324
commit 6ca03ec6cd
2 changed files with 3 additions and 3 deletions

View File

@@ -13,11 +13,11 @@ import {TEMPLATE_DELETE} from '../DialogManager/templates';
export const SelectionHeader = () => { export const SelectionHeader = () => {
// State // State
const [state, dispatch] = useTracked(); const [state, dispatch] = useTracked();
const {colors, selectionMode, selectedItemsList, currentScreen} = state; const {colors, selectionMode, selectedItemsList, currentScreen,containerState} = state;
const [selectAll, setSelectAll] = useState(false); const [selectAll, setSelectAll] = useState(false);
return ( return (containerState.noSelectionHeader ? null :
<Animatable.View <Animatable.View
transition={['translateY']} transition={['translateY']}
duration={300} duration={300}

View File

@@ -48,7 +48,7 @@ const SelectionWrapper = ({
? 30 ? 30
: 0, : 0,
backgroundColor: backgroundColor:
currentEditingNote === item.dateCreated currentEditingNote === item.dateCreated || pinned
? colors.shade ? colors.shade
: background : background
? background ? background