mirror of
https://github.com/laurent22/joplin.git
synced 2024-11-27 08:21:03 +02:00
Chore: Regression: Revert changes made to the note list' height (#7823)
This commit is contained in:
parent
32bb256cca
commit
359448eb69
@ -17,12 +17,13 @@ interface Props {
|
||||
sortOrderField: string;
|
||||
sortOrderReverse: boolean;
|
||||
notesParentType: string;
|
||||
height: number;
|
||||
}
|
||||
|
||||
const StyledRoot = styled.div`
|
||||
box-sizing: border-box;
|
||||
height: ${(props: any) => props.height}px;
|
||||
display: flex;
|
||||
height: auto;
|
||||
flex-direction: column;
|
||||
padding: ${(props: any) => props.theme.mainPadding}px;
|
||||
background-color: ${(props: any) => props.theme.backgroundColor3};
|
||||
|
@ -1,3 +1,4 @@
|
||||
import { themeStyle } from '@joplin/lib/theme';
|
||||
import * as React from 'react';
|
||||
import { useMemo } from 'react';
|
||||
import NoteList from '../NoteList/NoteList';
|
||||
@ -20,16 +21,19 @@ const StyledRoot = styled.div`
|
||||
`;
|
||||
|
||||
export default function NoteListWrapper(props: Props) {
|
||||
const theme = themeStyle(props.themeId);
|
||||
const controlHeight = theme.topRowHeight;
|
||||
|
||||
const noteListSize = useMemo(() => {
|
||||
return {
|
||||
width: props.size.width,
|
||||
height: props.size.height,
|
||||
height: props.size.height - controlHeight,
|
||||
};
|
||||
}, [props.size]);
|
||||
}, [props.size, controlHeight]);
|
||||
|
||||
return (
|
||||
<StyledRoot>
|
||||
<NoteListControls />
|
||||
<NoteListControls height={controlHeight}/>
|
||||
<NoteList resizableLayoutEventEmitter={props.resizableLayoutEventEmitter} size={noteListSize} visible={props.visible}/>
|
||||
</StyledRoot>
|
||||
);
|
||||
|
@ -60,7 +60,7 @@ const globalStyle: any = {
|
||||
toolbarPadding: 6,
|
||||
appearance: 'light',
|
||||
mainPadding: 12,
|
||||
topRowHeight: 50,
|
||||
topRowHeight: 81,
|
||||
editorPaddingLeft: 8,
|
||||
};
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user