refactor(styles): extract shared ProseMirror styles to reduce
duplication
This commit is contained in:
parent
970f69be53
commit
590045405b
2 changed files with 27 additions and 62 deletions
|
@ -14,38 +14,4 @@
|
||||||
.ds4-biography {
|
.ds4-biography {
|
||||||
height: 100%;
|
height: 100%;
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
|
|
||||||
prose-mirror {
|
|
||||||
height: 100%;
|
|
||||||
display: flex;
|
|
||||||
flex-direction: column;
|
|
||||||
overflow: hidden;
|
|
||||||
|
|
||||||
// Edit mode with editor container
|
|
||||||
&.active {
|
|
||||||
.editor-container {
|
|
||||||
flex: 1;
|
|
||||||
display: flex;
|
|
||||||
flex-direction: column;
|
|
||||||
overflow: hidden;
|
|
||||||
|
|
||||||
.editor-content {
|
|
||||||
flex: 1;
|
|
||||||
overflow-y: auto;
|
|
||||||
min-height: 0;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// View mode - direct editor-content
|
|
||||||
&.inactive {
|
|
||||||
.editor-content {
|
|
||||||
position: relative;
|
|
||||||
flex: 1;
|
|
||||||
overflow-y: auto;
|
|
||||||
min-height: 0;
|
|
||||||
inset: auto;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -14,41 +14,40 @@
|
||||||
background: transparent;
|
background: transparent;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
prose-mirror {
|
// General ProseMirror editor styles
|
||||||
height: 100%;
|
prose-mirror {
|
||||||
|
height: 100%;
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
overflow: hidden;
|
||||||
|
|
||||||
|
// Edit mode with editor container
|
||||||
|
&.active {
|
||||||
|
.editor-container {
|
||||||
|
flex: 1;
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
|
|
||||||
// Edit mode with editor container
|
.editor-content {
|
||||||
&.active {
|
flex: 1;
|
||||||
.editor-container {
|
overflow-y: auto;
|
||||||
flex: 1;
|
min-height: 0;
|
||||||
display: flex;
|
|
||||||
flex-direction: column;
|
|
||||||
overflow: hidden;
|
|
||||||
|
|
||||||
.editor-content {
|
|
||||||
flex: 1;
|
|
||||||
overflow-y: auto;
|
|
||||||
min-height: 0;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// View mode - direct editor-content
|
|
||||||
&.inactive {
|
|
||||||
.editor-content {
|
|
||||||
position: relative;
|
|
||||||
flex: 1;
|
|
||||||
overflow-y: auto;
|
|
||||||
min-height: 0;
|
|
||||||
inset: auto;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// View mode - direct editor-content
|
||||||
|
&.inactive {
|
||||||
|
.editor-content {
|
||||||
|
position: relative;
|
||||||
|
flex: 1;
|
||||||
|
overflow-y: auto;
|
||||||
|
min-height: 0;
|
||||||
|
inset: auto;
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue