Skip to content

A fully open source & end-to-end encrypted note taking alternative to Evernote.

refactor selection system

ammarahm-ed6ca03ec6cd93
diff --git a/apps/mobile/src/components/SelectionHeader/index.js b/apps/mobile/src/components/SelectionHeader/index.js
index d6c5f139f..f8967fb5e 100644
--- a/apps/mobile/src/components/SelectionHeader/index.js
+++ b/apps/mobile/src/components/SelectionHeader/index.js
@@ -13,11 +13,11 @@ import {TEMPLATE_DELETE} from '../DialogManager/templates';
export const SelectionHeader = () => {
// State
const [state, dispatch] = useTracked();
- const {colors, selectionMode, selectedItemsList, currentScreen} = state;
+ const {colors, selectionMode, selectedItemsList, currentScreen,containerState} = state;
const [selectAll, setSelectAll] = useState(false);
- return (
+ return (containerState.noSelectionHeader ? null :
<Animatable.View
transition={['translateY']}
duration={300}
diff --git a/apps/mobile/src/components/SelectionWrapper/index.js b/apps/mobile/src/components/SelectionWrapper/index.js
index b6bd4868b..65bb33f47 100644
--- a/apps/mobile/src/components/SelectionWrapper/index.js
+++ b/apps/mobile/src/components/SelectionWrapper/index.js
@@ -48,7 +48,7 @@ const SelectionWrapper = ({
? 30
: 0,
backgroundColor:
- currentEditingNote === item.dateCreated
+ currentEditingNote === item.dateCreated || pinned
? colors.shade
: background
? background