[TWIG][CSS] Final fix for panels, resizing works as intended, content is wrapped when no space is available. Simpler rules throughout.
Signed-off-by: Eliseu Amaro <mail@eliseuama.ro>
This commit is contained in:
parent
ce06c1dfd2
commit
75bbf6c728
@ -188,20 +188,21 @@ html {
|
|||||||
/* CONTAINS ALL ELEMENTS BESIDES HEADER */
|
/* CONTAINS ALL ELEMENTS BESIDES HEADER */
|
||||||
.container {
|
.container {
|
||||||
display: flex;
|
display: flex;
|
||||||
justify-content: space-between;
|
flex-wrap: wrap;
|
||||||
|
justify-content: space-around;
|
||||||
margin-top: calc(3 * var(--small-size) + var(--main-size));
|
margin-top: calc(3 * var(--small-size) + var(--main-size));
|
||||||
}
|
}
|
||||||
|
|
||||||
/* THE FOCUSED (middle) DIV */
|
/* THE FOCUSED (middle) DIV */
|
||||||
.content {
|
.content {
|
||||||
margin: var(--main-size);
|
margin: var(--main-size);
|
||||||
box-sizing: border-box;
|
|
||||||
|
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
flex: 1;
|
flex: 1;
|
||||||
|
|
||||||
max-width: calc(3 * (100vw / 5));
|
width: 100%;
|
||||||
|
max-width: calc(3 * (100% / 5));
|
||||||
}
|
}
|
||||||
|
|
||||||
/* NOTES */
|
/* NOTES */
|
||||||
@ -258,10 +259,18 @@ html {
|
|||||||
}
|
}
|
||||||
|
|
||||||
.note-attachments > div figure {
|
.note-attachments > div figure {
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
margin: 0;
|
margin: 0;
|
||||||
padding: var(--small-size);
|
padding: var(--small-size);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.note-attachments > div figure img,
|
||||||
|
.note-attachments > div figure video {
|
||||||
|
width: 100%;
|
||||||
|
height: auto;
|
||||||
|
}
|
||||||
|
|
||||||
figcaption a:link {
|
figcaption a:link {
|
||||||
font-size: var(--small-size);
|
font-size: var(--small-size);
|
||||||
color: var(--white);
|
color: var(--white);
|
||||||
@ -269,14 +278,15 @@ figcaption a:link {
|
|||||||
|
|
||||||
/* SIDE PANELS */
|
/* SIDE PANELS */
|
||||||
.panel {
|
.panel {
|
||||||
|
width: 100%;
|
||||||
|
max-width: calc(100% / 5);
|
||||||
margin: var(--unit-size);
|
margin: var(--unit-size);
|
||||||
font-size: var(--main-size);
|
font-size: var(--main-size);
|
||||||
max-width: calc((100vw / 5));
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.panel aside {
|
.panel aside {
|
||||||
display: flex;
|
position: sticky;
|
||||||
flex-direction: column;
|
display: contents;
|
||||||
}
|
}
|
||||||
|
|
||||||
.icon-left,
|
.icon-left,
|
||||||
@ -284,46 +294,41 @@ figcaption a:link {
|
|||||||
display: none;
|
display: none;
|
||||||
}
|
}
|
||||||
|
|
||||||
@media (min-width: 1200px) {
|
|
||||||
.panel {
|
|
||||||
width: 100%;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
@media (max-width: 1200px) {
|
@media (max-width: 1200px) {
|
||||||
.icon-left,
|
.icon-left,
|
||||||
.icon-right {
|
.icon-right {
|
||||||
display: flex !important;
|
display: flex;
|
||||||
}
|
|
||||||
|
|
||||||
.panel {
|
|
||||||
max-width: 100vw !important;
|
|
||||||
}
|
|
||||||
|
|
||||||
.panel div ~ {
|
|
||||||
all: unset;
|
|
||||||
display: none;
|
|
||||||
}
|
|
||||||
|
|
||||||
.panel aside {
|
|
||||||
display: none !important;
|
|
||||||
}
|
|
||||||
|
|
||||||
.panel[open] {
|
|
||||||
display: block !important;
|
|
||||||
width: 100% !important; /* Full width */
|
|
||||||
height: 100% !important; /* Full height */
|
|
||||||
overflow: auto !important; /* Enable scroll if needed */
|
|
||||||
}
|
|
||||||
|
|
||||||
.panel[open] aside {
|
|
||||||
display: block !important;
|
|
||||||
animation: fadeIn 300ms cubic-bezier(0, 0.55, 0.45, 1);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.content {
|
.content {
|
||||||
max-width: 100vw;
|
order: 1;
|
||||||
|
max-width: 100% !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.panel {
|
||||||
|
all: unset;
|
||||||
|
width: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.panel aside {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
.panel[open] {
|
||||||
|
width: 100%;
|
||||||
|
font-size: var(--main-size);
|
||||||
|
margin: var(--unit-size);
|
||||||
|
}
|
||||||
|
|
||||||
|
.panel[open] {
|
||||||
|
width: 100%;
|
||||||
|
}
|
||||||
|
|
||||||
|
.panel[open] aside {
|
||||||
|
display: contents;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/* ANIMATIONS */
|
/* ANIMATIONS */
|
||||||
|
@ -1,3 +1,8 @@
|
|||||||
|
#left-container {
|
||||||
|
top: inherit;
|
||||||
|
left: 0;
|
||||||
|
}
|
||||||
|
|
||||||
.icon-left {
|
.icon-left {
|
||||||
position: fixed;
|
position: fixed;
|
||||||
top: 0;
|
top: 0;
|
||||||
@ -14,7 +19,6 @@
|
|||||||
|
|
||||||
/* PROFILE */
|
/* PROFILE */
|
||||||
.profile-nav {
|
.profile-nav {
|
||||||
width: inherit;
|
|
||||||
font-family: var(--display-font);
|
font-family: var(--display-font);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1,3 +1,8 @@
|
|||||||
|
#right-container {
|
||||||
|
top: inherit;
|
||||||
|
right: 0;
|
||||||
|
}
|
||||||
|
|
||||||
.icon-right {
|
.icon-right {
|
||||||
position: fixed;
|
position: fixed;
|
||||||
top: 0;
|
top: 0;
|
||||||
@ -13,19 +18,22 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
.create-notice {
|
.create-notice {
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
width: 100%;
|
||||||
|
|
||||||
background-image: radial-gradient(ellipse at 10% 10%, var(--bg3), var(--accent-blue)),
|
background-image: radial-gradient(ellipse at 10% 10%, var(--bg3), var(--accent-blue)),
|
||||||
url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgBAMAAACBVGfHAAAAElBMVEUAAACUkpSEhoSMioyMjoyEgoRr6djFAAAAAXRSTlMAQObYZgAAAAlwSFlzAAAOxAAADsQBlSsOGwAAAU1JREFUKJEVUcl1xTAIpAVLSgECXIAYUoCAX0Bi919LlCPLm5ValiOUUe2+ZRVFuYpKXFsUX9aIp0V6GtC8VRhNL0X2fikvswhKrNDhes7pbpPkufFAtI0B76LEjfc2bgdHDk6RX4A/sjt6LCylfoYpNYYJx/9COhIugsjluzN9VGZ/Hnl51jIH2ba+Ywsy2RJCFdoDe8Obw61TXGAv+ewExMRJs7gd7YcimPuk42uMqY2VJ1fK+bDL32rb7kwok/la/u7Mrz7Xf0DTssSP2Btp1ZS0zw35tM/SsJKgWNLcRh+/th1QqntwtM3Tx0LNosoBYbM3qjJFiMeLsMH2i5BcQdU3n9sJHOE1Hoqn1GA/bm4s0YkVB/y4r0PbltF32FpljXmdlOOwbDvFWkoDYLppSG4pnM6UxX3Src1lhXeU36FOu3o+R2vNaHME/wESUl9/3zMniwAAAABJRU5ErkJggg==);
|
url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgBAMAAACBVGfHAAAAElBMVEUAAACUkpSEhoSMioyMjoyEgoRr6djFAAAAAXRSTlMAQObYZgAAAAlwSFlzAAAOxAAADsQBlSsOGwAAAU1JREFUKJEVUcl1xTAIpAVLSgECXIAYUoCAX0Bi919LlCPLm5ValiOUUe2+ZRVFuYpKXFsUX9aIp0V6GtC8VRhNL0X2fikvswhKrNDhes7pbpPkufFAtI0B76LEjfc2bgdHDk6RX4A/sjt6LCylfoYpNYYJx/9COhIugsjluzN9VGZ/Hnl51jIH2ba+Ywsy2RJCFdoDe8Obw61TXGAv+ewExMRJs7gd7YcimPuk42uMqY2VJ1fK+bDL32rb7kwok/la/u7Mrz7Xf0DTssSP2Btp1ZS0zw35tM/SsJKgWNLcRh+/th1QqntwtM3Tx0LNosoBYbM3qjJFiMeLsMH2i5BcQdU3n9sJHOE1Hoqn1GA/bm4s0YkVB/y4r0PbltF32FpljXmdlOOwbDvFWkoDYLppSG4pnM6UxX3Src1lhXeU36FOu3o+R2vNaHME/wESUl9/3zMniwAAAABJRU5ErkJggg==);
|
||||||
background-blend-mode: multiply;
|
background-blend-mode: multiply;
|
||||||
border-radius: var(--unit-size);
|
border-radius: var(--unit-size);
|
||||||
}
|
}
|
||||||
|
|
||||||
.create-notice form fielset {
|
.create-notice textarea {
|
||||||
display: flex;
|
width: 100%;
|
||||||
flex-direction: column;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.section-title {
|
.section-title {
|
||||||
width: 100%;
|
flex: 1;
|
||||||
border-radius: var(--unit-size);
|
border-radius: var(--unit-size);
|
||||||
|
|
||||||
padding: var(--unit-size);
|
padding: var(--unit-size);
|
||||||
@ -35,9 +43,6 @@
|
|||||||
font-family: var(--display-font);
|
font-family: var(--display-font);
|
||||||
}
|
}
|
||||||
.section-content {
|
.section-content {
|
||||||
display: flex;
|
|
||||||
flex-wrap: wrap;
|
|
||||||
flex-direction: column;
|
|
||||||
margin: var(--unit-size);
|
margin: var(--unit-size);
|
||||||
}
|
}
|
||||||
.section-content hr {
|
.section-content hr {
|
||||||
@ -98,7 +103,7 @@
|
|||||||
border-radius: var(--unit-size);
|
border-radius: var(--unit-size);
|
||||||
background-color: var(--translucent);
|
background-color: var(--translucent);
|
||||||
|
|
||||||
width: 100%;
|
max-width: 100%;
|
||||||
margin-top: var(--unit-size);
|
margin-top: var(--unit-size);
|
||||||
padding: var(--unit-size);
|
padding: var(--unit-size);
|
||||||
resize: vertical;
|
resize: vertical;
|
||||||
|
@ -4,7 +4,6 @@
|
|||||||
|
|
||||||
<section class="create-notice">
|
<section class="create-notice">
|
||||||
{{ form_start(post_form) }}
|
{{ form_start(post_form) }}
|
||||||
<fieldset>
|
|
||||||
<legend class="section-title">Create a note</legend>
|
<legend class="section-title">Create a note</legend>
|
||||||
|
|
||||||
<div class="section-content">
|
<div class="section-content">
|
||||||
@ -46,7 +45,6 @@
|
|||||||
</div>
|
</div>
|
||||||
</span>
|
</span>
|
||||||
</div>
|
</div>
|
||||||
</fieldset>
|
|
||||||
{{ form_end(post_form) }}
|
{{ form_end(post_form) }}
|
||||||
|
|
||||||
<details>
|
<details>
|
||||||
|
Loading…
Reference in New Issue
Block a user