DEV: implement composer peek mode directly in theme (#141)
This implements the [composer peek](https://github.com/discourse/composer-peek) component directly into the theme, and makes some minor adjustments to match theme styles: 
This commit is contained in:
@@ -0,0 +1,64 @@
|
||||
.peek-mode-toggle {
|
||||
display: none;
|
||||
}
|
||||
|
||||
@media screen and (min-width: 1300px) {
|
||||
html:not(.fullscreen-composer) {
|
||||
.peek-mode-toggle svg {
|
||||
transform: scaleX(-1);
|
||||
}
|
||||
|
||||
&.composer-open {
|
||||
.full-width-enabled .peek-mode-toggle {
|
||||
display: flex;
|
||||
}
|
||||
|
||||
.full-width-enabled.peek-mode-active {
|
||||
#reply-control.hide-preview {
|
||||
transition: none;
|
||||
box-shadow: none;
|
||||
border-radius: var(--d-border-radius-large);
|
||||
.grippie {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.reply-area {
|
||||
padding-inline: 0.67em;
|
||||
}
|
||||
}
|
||||
|
||||
#reply-control:not(.fullscreen).hide-preview {
|
||||
width: 100%;
|
||||
right: var(--d-border-radius-large);
|
||||
top: var(--header-offset);
|
||||
bottom: var(--d-border-radius-large);
|
||||
left: unset;
|
||||
height: unset;
|
||||
max-width: 32vw;
|
||||
}
|
||||
|
||||
&.has-sidebar-page {
|
||||
#main-outlet-wrapper {
|
||||
grid-template-columns:
|
||||
var(--d-sidebar-width) calc(100vw - 38vw - var(--d-sidebar-width))
|
||||
1fr;
|
||||
}
|
||||
}
|
||||
|
||||
&:not(.has-sidebar-page) {
|
||||
#main-outlet-wrapper {
|
||||
grid-template-columns: 0 calc(100vw - 52vw) 1fr;
|
||||
}
|
||||
|
||||
#reply-control:not(.fullscreen).hide-preview {
|
||||
max-width: 46vw;
|
||||
}
|
||||
}
|
||||
|
||||
.sidebar-wrapper .sidebar-container {
|
||||
height: unset;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user