mirror of
https://github.com/standardnotes/mobile.git
synced 2026-02-05 21:41:23 -05:00
fix: floating button position on iPad
This commit is contained in:
@@ -34,7 +34,13 @@ import { StyledIcon } from './Notes.styled';
|
||||
import { notePassesFilter, NoteSortKey } from './utils';
|
||||
|
||||
export const Notes = React.memo(
|
||||
({ shouldSplitLayout }: { shouldSplitLayout: boolean | undefined }) => {
|
||||
({
|
||||
shouldSplitLayout,
|
||||
keyboardHeight,
|
||||
}: {
|
||||
shouldSplitLayout: boolean | undefined;
|
||||
keyboardHeight: number | undefined;
|
||||
}) => {
|
||||
// Context
|
||||
const application = useContext(ApplicationContext);
|
||||
const theme = useContext(ThemeContext);
|
||||
@@ -477,7 +483,7 @@ export const Notes = React.memo(
|
||||
// @ts-ignore style prop does not exist in types
|
||||
style={
|
||||
application?.getAppState().isInTabletMode
|
||||
? { bottom: application?.getAppState().getKeyboardHeight() }
|
||||
? { bottom: keyboardHeight }
|
||||
: undefined
|
||||
}
|
||||
buttonColor={theme.stylekitInfoColor}
|
||||
|
||||
@@ -136,7 +136,10 @@ export const Root = (): JSX.Element | null => {
|
||||
notesListCollapsed={noteListCollapsed}
|
||||
shouldSplitLayout={shouldSplitLayout}
|
||||
>
|
||||
<Notes shouldSplitLayout={shouldSplitLayout} />
|
||||
<Notes
|
||||
keyboardHeight={keyboardHeight}
|
||||
shouldSplitLayout={shouldSplitLayout}
|
||||
/>
|
||||
</NotesContainer>
|
||||
{hasEditor && shouldSplitLayout && (
|
||||
<ComposeContainer>
|
||||
|
||||
Reference in New Issue
Block a user