changes to try with chatgpt

This commit is contained in:
2024-12-12 22:02:21 +01:00
parent 869df50c01
commit 7133371206
6 changed files with 186 additions and 81 deletions

5
.chatgpt_config.yaml Normal file
View File

@@ -0,0 +1,5 @@
default_prompt_blocks:
- "basic-prompt"
- "typo3-development"
directories:
- "packages/base/ContentBlocks"

BIN
data/test.sql.gz Normal file

Binary file not shown.

View File

@@ -1,73 +1,155 @@
.frame-type-cloonar_hero { .frame-type-cloonar_hero {
position: relative; background: #f9f9f9;
padding: 1rem; /* Mobile-first padding */
}
/* Mobile-first: stacked layout */
.frame-type-cloonar_hero .hero {
display: flex; display: flex;
flex-direction: column; flex-direction: column;
padding-bottom: 3rem; /* Space for overlap */ align-items: flex-start;
background: #f9f9f9;
} }
.frame-type-cloonar_hero .hero-header { .frame-type-cloonar_hero .hero-subheader {
text-align: center; font-size: 1rem;
margin-bottom: 2rem; color: #3c6418;
font-size: 2.5rem; margin-bottom: 0.5rem;
color: #3c3c3c;
} }
.frame-type-cloonar_hero .hero-content { .frame-type-cloonar_hero .hero-title {
display: flex; font-size: 1.5rem;
flex-direction: row; font-weight: bold;
align-items: center; color: #3c6418;
justify-content: space-between; margin: 0 0 1rem 0;
gap: 2rem; line-height: 1.2;
text-transform: uppercase;
} }
.frame-type-cloonar_hero .hero-text { .frame-type-cloonar_hero .hero-text {
flex: 1; font-size: 0.9rem;
font-size: 1.2rem; color: #333;
color: #3c3c3c; line-height: 1.4;
line-height: 1.6; margin-bottom: 1rem;
} max-width: 45ch;
.frame-type-cloonar_hero .hero-image-wrapper {
position: relative;
flex: 1;
}
.frame-type-cloonar_hero .hero-image {
max-width: 100%;
height: auto;
border-radius: 8px;
} }
.frame-type-cloonar_hero .hero-social-icons { .frame-type-cloonar_hero .hero-social-icons {
position: absolute;
right: -10%;
top: 50%;
transform: translateY(-50%);
display: flex; display: flex;
flex-direction: column;
gap: 0.5rem; gap: 0.5rem;
margin-bottom: 1rem;
} }
.frame-type-cloonar_hero .social-icon { .frame-type-cloonar_hero .social-icon {
display: inline-block; display: inline-flex;
width: 40px; align-items: center;
height: 40px; justify-content: center;
background-color: #3c3c3c; background: #3c6418;
color: #fff; color: #fff;
text-align: center; font-size: 1rem;
line-height: 40px;
border-radius: 50%;
text-decoration: none; text-decoration: none;
font-size: 1.2rem; border-radius: 50%;
} width: 2rem;
.frame-type-cloonar_hero .next-section-overlap {
position: absolute;
bottom: 2rem;
width: 100%;
height: 2rem; height: 2rem;
background: #ffffff; transition: background 0.3s;
z-index: 10;
} }
.frame-type-cloonar_hero .social-icon:hover {
background: #1e3810;
}
.frame-type-cloonar_hero .hero-image-wrapper {
margin-top: 1rem;
}
.frame-type-cloonar_hero .hero-image {
max-width: 200px;
width: 100%;
height: auto;
border-radius: 0.5rem;
}
/* Medium devices (≥768px) - slightly larger text and icons */
@media (min-width: 768px) {
.frame-type-cloonar_hero .hero-subheader {
font-size: 1.2rem;
}
.frame-type-cloonar_hero .hero-title {
font-size: 2rem;
margin-bottom: 1.2rem;
}
.frame-type-cloonar_hero .hero-text {
font-size: 1rem;
}
.frame-type-cloonar_hero .social-icon {
width: 2.5rem;
height: 2.5rem;
font-size: 1.2rem;
}
.frame-type-cloonar_hero .hero-image {
max-width: 250px;
}
}
/* Large devices (≥992px): Switch to 3-column layout */
@media (min-width: 992px) {
.frame-type-cloonar_hero {
padding: 2rem;
}
/* Three-column grid: text (left), image (middle), icons (right) */
.frame-type-cloonar_hero .hero {
display: grid;
grid-template-columns: 1fr auto auto;
grid-template-areas:
"subheader image icons"
"title image icons"
"text image icons"
"social image icons";
align-items: start;
justify-items: start;
text-align: left;
}
.frame-type-cloonar_hero .hero-subheader {
grid-area: subheader;
font-size: 1.5rem;
margin-bottom: 0.5rem;
}
.frame-type-cloonar_hero .hero-title {
grid-area: title;
font-size: 3rem;
margin-bottom: 1.5rem;
}
.frame-type-cloonar_hero .hero-text {
grid-area: text;
font-size: 1rem;
max-width: 40ch;
margin-bottom: 1.5rem;
}
.frame-type-cloonar_hero .hero-social-icons {
grid-area: social;
flex-direction: column;
gap: 1rem;
margin-bottom: 0;
align-items: flex-start;
}
.frame-type-cloonar_hero .hero-image-wrapper {
grid-area: image;
margin-top: 0;
display: flex;
align-items: center;
justify-content: center;
}
.frame-type-cloonar_hero .hero-image {
max-width: 300px; /* Slightly larger on desktop, but not too big */
}
}

View File

@@ -1,15 +1,22 @@
<f:layout name="Default" /> <f:layout name="Default" />
<!-- No extra heading from the parent layout -->
<f:section name="Header" />
<f:section name="Main"> <f:section name="Main">
<f:asset.css identifier="CBHero" href="{cb:assetPath()}/frontend.css" /> <f:asset.css identifier="CBHero" href="{cb:assetPath()}/frontend.css" />
<div class="hero"> <div class="hero">
<header class="hero-header"> <div class="hero-subheader">{data.subheader}</div>
<h1>{data.header}</h1> <h2 class="hero-title">{data.header}</h2>
</header>
<div class="hero-content">
<div class="hero-text"> <div class="hero-text">
<f:format.html>{data.bodytext}</f:format.html> <f:format.html>{data.bodytext}</f:format.html>
</div> </div>
<div class="hero-social-icons">
<a href="#" class="social-icon">X</a>
<a href="#" class="social-icon">Instagram</a>
<a href="#" class="social-icon">TikTok</a>
</div>
<div class="hero-image-wrapper"> <div class="hero-image-wrapper">
<f:if condition="{data.image}"> <f:if condition="{data.image}">
<f:then> <f:then>
@@ -19,12 +26,6 @@
<p>No image available</p> <p>No image available</p>
</f:else> </f:else>
</f:if> </f:if>
<div class="hero-social-icons">
<a href="#" class="social-icon">X</a>
<a href="#" class="social-icon">Instagram</a>
<a href="#" class="social-icon">TikTok</a>
</div>
</div>
</div> </div>
<div class="next-section-overlap"></div> <div class="next-section-overlap"></div>
</div> </div>

View File

@@ -1,8 +1,13 @@
<div class="frame frame-type-{data.CType}"> <div class="frame frame-type-{data.CType}">
<div class="container"> <div class="container">
<div class="header"> <f:render section="Header" optional="true" />
<h2>{data.header}</h2>
</div>
<f:render section="Main" optional="true" /> <f:render section="Main" optional="true" />
</div> </div>
</div> </div>
<f:section name="Header">
<div class="header">
<h2>{data.header}</h2>
</div>
</f:section>

View File

@@ -9,3 +9,15 @@ $breakpoint-sm: 576px;
$breakpoint-md: 768px; $breakpoint-md: 768px;
$breakpoint-lg: 992px; $breakpoint-lg: 992px;
$breakpoint-xl: 1200px; $breakpoint-xl: 1200px;
// variables.scss
// Breakpoint Variables
:root {
--breakpoint-xs: 480px;
--breakpoint-sm: 576px;
--breakpoint-md: 768px;
--breakpoint-lg: 992px;
--breakpoint-xl: 1200px;
}
// Additional global variables can be added here