File tree Expand file tree Collapse file tree 1 file changed +16
-5
lines changed Expand file tree Collapse file tree 1 file changed +16
-5
lines changed Original file line number Diff line number Diff line change @@ -44,6 +44,8 @@ type MarkdownEditorState = {
44
44
45
45
const MarkdownEditorBlock = styled . div `
46
46
height: 100%;
47
+ display: flex;
48
+ flex-direction: column;
47
49
overflow-y: auto;
48
50
position: relative;
49
51
&::-webkit-scrollbar {
@@ -63,10 +65,13 @@ const MarkdownEditorBlock = styled.div`
63
65
64
66
& > .wrapper {
65
67
padding-top: 3rem;
66
- padding-bottom: 10rem;
68
+ padding-bottom: 4rem;
69
+ flex: 1;
70
+ display: flex;
71
+ flex-direction: column;
67
72
}
68
73
.CodeMirror {
69
- height: auto ;
74
+ flex: 1 ;
70
75
font-size: 1.125rem;
71
76
line-height: 1.5;
72
77
color: ${ palette . gray8 } ;
@@ -115,6 +120,12 @@ const PaddingWrapper = styled.div`
115
120
padding-right: 3rem;
116
121
` ;
117
122
123
+ const MarkdownWrapper = styled . div `
124
+ flex: 1;
125
+ display: flex;
126
+ flex-direction: column;
127
+ ` ;
128
+
118
129
const FooterWrapper = styled . div `
119
130
position: fixed;
120
131
bottom: 0;
@@ -193,7 +204,7 @@ export default class WriteMarkdownEditor extends React.Component<
193
204
mode : 'markdown' ,
194
205
theme : 'one-light' ,
195
206
placeholder : '당신의 이야기를 적어보세요...' ,
196
- viewportMargin : Infinity ,
207
+ // viewportMargin: Infinity,
197
208
lineWrapping : true ,
198
209
} ) ;
199
210
@@ -746,7 +757,7 @@ ${selected}
746
757
onConvert = { this . handleAskConvert }
747
758
innerRef = { this . toolbarElement }
748
759
/>
749
- < PaddingWrapper >
760
+ < MarkdownWrapper >
750
761
{ addLink . visible && (
751
762
< AddLink
752
763
defaultValue = ""
@@ -758,7 +769,7 @@ ${selected}
758
769
/>
759
770
) }
760
771
< textarea ref = { this . editorElement } style = { { display : 'none' } } />
761
- </ PaddingWrapper >
772
+ </ MarkdownWrapper >
762
773
</ div >
763
774
< AskChangeEditor
764
775
visible = { this . state . askChangeEditor }
You can’t perform that action at this time.
0 commit comments