stacker.news/components/text.module.css

200 lines
2.9 KiB
CSS

.text {
font-size: 94%;
font-family: inherit;
word-break: break-word;
line-height: 140%;
overflow-y: hidden;
position: relative;
max-height: 200vh;
}
.textUncontained {
max-height: none;
}
.textContained::before {
content: "";
position: absolute;
bottom: 0;
left: 0;
width: 100%;
height: 50vh;
pointer-events: none;
z-index: 1;
background: linear-gradient(rgba(255, 255, 255, 0), var(--bs-body-bg) 200%);
}
.textShowFull {
position: absolute;
bottom: 0;
left: 0;
border-radius: 0;
z-index: 2;
}
@media screen and (min-width: 767px) {
.text {
line-height: 130%;
}
.text img {
min-width: 30% !important;
}
}
.heading {
position: relative;
margin-left: -22px;
padding-left: 22px;
display: block;
}
.headingLink {
display: none;
position: absolute;
left: 0px;
top: 0px;
height: 100%;
width: 44px;
}
.headingLink.copied {
display: flex;
}
.headingLink svg {
align-self: center;
}
.heading:hover>.headingLink {
display: flex;
}
.text hr {
border-top: 1px solid var(--theme-clickToContextColor);
}
.text .p {
display: block;
margin-bottom: .5rem;
white-space: pre-wrap;
word-break: break-word;
}
.text pre {
margin-bottom: .5rem;
}
.text pre>div {
margin: 0 !important;
}
.text>*:last-child {
margin-bottom: 0 !important;
}
.text blockquote:last-child {
margin-bottom: 0 !important;
}
.text blockquote:has(+ :not(blockquote)) {
margin-bottom: .5rem;
}
.text img {
display: block;
margin-top: .5rem;
margin-bottom: .5rem;
width: auto;
max-width: 100%;
cursor: zoom-in;
max-height: 25vh;
object-fit: contain;
object-position: left top;
min-width: 50%;
}
.text img.topLevel {
margin-top: .75rem;
margin-bottom: .75rem;
max-height: 35vh;
}
img.fullScreen {
cursor: zoom-out !important;
max-height: 100%;
max-width: 100vw;
min-width: 0;
min-height: 0;
align-self: center;
justify-self: center;
}
.fullScreenContainer {
--bs-columns: 1;
--bs-rows: 1;
display: grid;
width: 100%;
height: 100%;
align-content: center;
justify-content: center;
}
.text table {
width: auto;
}
.text blockquote {
border-left: 4px solid var(--theme-quoteBar);
padding-left: 1rem;
margin-left: 1.25rem;
margin-bottom: 0;
}
.text ul {
margin-bottom: 0;
}
.text li {
margin-top: .5rem;
margin-bottom: .5rem;
}
.text h1 {
font-size: 1.6rem;
}
.text h2 {
font-size: 1.45rem;
}
.text h3 {
font-size: 1.3rem;
}
.text h4 {
font-size: 1.15rem;
}
.text h5 {
font-size: 1rem;
}
.text h6 {
font-size: .85rem;
}
.youtubeContainer {
position: relative;
width: 100%;
height: 0;
padding-bottom: 56.25%;
overflow: hidden;
}
.youtubeContainer iframe {
width: 100%;
height: 100%;
position: absolute;
top: 0;
left: 0;
}