mirror of
https://github.com/AustinKelsay/plebdevs.git
synced 2025-05-17 19:55:50 +00:00
Line clamp on content thumbnails for description
This commit is contained in:
parent
03b771283a
commit
cae0396092
@ -96,9 +96,14 @@ export function CourseTemplate({ course }) {
|
|||||||
WebkitLineClamp: "2"
|
WebkitLineClamp: "2"
|
||||||
}}>
|
}}>
|
||||||
<div className="w-full flex flex-row justify-between items-start">
|
<div className="w-full flex flex-row justify-between items-start">
|
||||||
|
{/* <div className="flex flex-col max-h-[200px]">
|
||||||
{(course.summary || course.description)?.split('\n').map((line, index) => (
|
{(course.summary || course.description)?.split('\n').map((line, index) => (
|
||||||
<span key={index}>{line}</span>
|
<span className="line-clamp-2" key={index}>{line}</span>
|
||||||
))}
|
))}
|
||||||
|
</div> */}
|
||||||
|
<p className="line-clamp-2">{(course.summary || course.description)?.split('\n').map((line, index) => (
|
||||||
|
<span key={index}>{line}</span>
|
||||||
|
))}</p>
|
||||||
<div className="flex flex-col items-end">
|
<div className="flex flex-col items-end">
|
||||||
{
|
{
|
||||||
course?.price && course?.price > 0 ? (
|
course?.price && course?.price > 0 ? (
|
||||||
|
@ -85,9 +85,9 @@ export function DocumentTemplate({ document }) {
|
|||||||
WebkitLineClamp: "2"
|
WebkitLineClamp: "2"
|
||||||
}}>
|
}}>
|
||||||
<div className="w-full flex flex-row justify-between items-start">
|
<div className="w-full flex flex-row justify-between items-start">
|
||||||
{(document.summary || document.description)?.split('\n').map((line, index) => (
|
<p className="line-clamp-2">{(document.summary || document.description)?.split('\n').map((line, index) => (
|
||||||
<span key={index}>{line}</span>
|
<span key={index}>{line}</span>
|
||||||
))}
|
))}</p>
|
||||||
<div className="flex flex-col items-end">
|
<div className="flex flex-col items-end">
|
||||||
{
|
{
|
||||||
document?.price && document?.price > 0 ? (
|
document?.price && document?.price > 0 ? (
|
||||||
|
@ -87,9 +87,9 @@ export function VideoTemplate({ video }) {
|
|||||||
WebkitLineClamp: "2"
|
WebkitLineClamp: "2"
|
||||||
}}>
|
}}>
|
||||||
<div className="w-full flex flex-row justify-between items-start">
|
<div className="w-full flex flex-row justify-between items-start">
|
||||||
{(video.summary || video.description)?.split('\n').map((line, index) => (
|
<p className="line-clamp-2">{(video.summary || video.description)?.split('\n').map((line, index) => (
|
||||||
<span key={index}>{line}</span>
|
<span key={index}>{line}</span>
|
||||||
))}
|
))}</p>
|
||||||
<div className="flex flex-col items-end">
|
<div className="flex flex-col items-end">
|
||||||
{
|
{
|
||||||
video?.price && video?.price > 0 ? (
|
video?.price && video?.price > 0 ? (
|
||||||
|
Loading…
x
Reference in New Issue
Block a user