Skip to content

Commit cf301aa

Browse files
committed
Make header sticky
1 parent 0e96941 commit cf301aa

File tree

1 file changed

+8
-4
lines changed

1 file changed

+8
-4
lines changed

extensions/ql-vscode/src/view/model-editor/ModelEditor.tsx

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -27,14 +27,18 @@ const LoadingContainer = styled.div`
2727
font-weight: 600;
2828
`;
2929

30-
const ModelEditorContainer = styled.div`
31-
margin-top: 1rem;
32-
`;
30+
const ModelEditorContainer = styled.div``;
3331

3432
const HeaderContainer = styled.div`
3533
display: flex;
3634
flex-direction: row;
3735
align-items: end;
36+
background-color: var(--vscode-editorGutter-background);
37+
position: sticky;
38+
z-index: 1;
39+
top: 0;
40+
padding-top: 1rem;
41+
padding-bottom: 1rem;
3842
`;
3943

4044
const HeaderColumn = styled.div`
@@ -67,7 +71,7 @@ const EditorContainer = styled.div`
6771
const ButtonsContainer = styled.div`
6872
display: flex;
6973
gap: 0.4em;
70-
margin-bottom: 1rem;
74+
margin-top: 1rem;
7175
`;
7276

7377
type Props = {

0 commit comments

Comments
 (0)