Obwohl das Spacing TOP in den Einstellungen (Zahnrad) auf 0 steht habe ich zwischen den oberen und unteren Bild einen grossen Abstand. Der sollte aber nur so gross sein wie zwischen den Bildern. Habe schon einiges versucht, leider ohne Erfolg. Vielleicht hast du eine Idee.
Code HTML:
Code: Alles auswählen
<section data-bs-version="5.1" class="features6" group="Features">
<mbr-parameters>
<header>Size</header>
<input type="checkbox" title="Full Width" name="fullWidth" checked>
<input type="range" inline title="Top" name="paddingTop" min="0" max="10" step="1" value="0">
<input type="range" inline title="Bottom" name="paddingBottom" min="0" max="10" step="1" value="0">
<select title="Columns" name="cardsWidth">
<option value="12">1</option>
<option value="6">2</option>
<option value="4">3</option>
<option value="3" selected>4</option>
</select>
<header>Show/Hide</header>
<input type="checkbox" name="showTitle" title="Title">
<input type="checkbox" name="showSubtitle" title="Subtitle">
<header>Cards</header>
<input type="checkbox" name="autoSize" title="Custom Height" checked>
<input type="range" name="imageHeight" title="Height" min="1" max="8" step="1" value="6" condition="autoSize && !(showButtons==false && showCardSubtitle==false && showCardTitle==false && showText==false)">
<input type="checkbox" title="Spacing" name="spacing" checked>
<input type="checkbox" name="showCardTitle" title="Title">
<input type="checkbox" name="showCardSubtitle" title="Subtitle">
<input type="checkbox" name="showText" title="Text">
<input type="checkbox" name="showButtons" title="Buttons">
<input type="color" name="cardsBg" title="BG" value="#ffffff">
<header>Background</header>
<fieldset type="background" name="bg" required>
<input type="image" title="Image" value="file:///C:/Users/pc/AppData/Local/Mobirise.com/Mobirise/projects/project-2022-01-24_131846/assets/images/background2.jpg">
<input type="color" title="Color" value="#ffffff" selected>
</fieldset>
<input type="checkbox" title="Overlay" name="overlay" condition="bg.type !== 'color'" checked>
<input type="color" title="Overlay Color" name="overlayColor" value="#fafafa" condition="overlay && bg.type == 'image'">
<input type="range" inline title="Opacity" name="overlayOpacity" min="0" max="1" step="0.1" value="0.1" condition="overlay && bg.type == 'image'">
</mbr-parameters>
<div class="mbr-overlay" mbr-if="overlay && bg.type !== 'color'"></div>
<div mbr-class="{'container': !fullWidth, 'container-fluid': fullWidth}">
<div class="mbr-section-head pb-4" mbr-if="showTitle || showSubtitle">
<h4 class="mbr-section-title mbr-fonts-style align-left mb-0" mbr-theme-style="display-2" mbr-if="showTitle" data-app-selector=".mbr-section-title"><b>Portfolio</b></h4>
<h5 class="mbr-section-subtitle mbr-fonts-style align-center mb-0 mt-2" mbr-theme-style="display-5" mbr-if="showSubtitle" data-app-selector=".mbr-section-subtitle">To add more cards, hover on a card and
click 'Add items'</h5>
</div>
<div class="row mt-4">
<div class="item features-image сol-12 col-md-6 col-lg-{{cardsWidth}}">
<div class="item-wrapper">
<div class="item-img abstand-bild-links">
<img src="file:///C:/Users/pc/AppData/Local/Mobirise.com/Mobirise/projects/project-2022-01-24_131846/assets/images/dummy500.jpg" alt>
</div>
<div class="item-content" mbr-if="showCardTitle || showCardSubtitle || showText || showButtons">
<h5 class="item-title mbr-fonts-style" mbr-theme-style="display-4" data-app-selector=".item-title" mbr-if="showCardTitle">Portfolio</h5>
<h6 class="item-subtitle mbr-fonts-style" mbr-theme-style="display-5" data-app-selector=".item-subtitle" mbr-if="showCardSubtitle"><b>VERKAUFSOFFENER SONNTAG</b></h6>
<p class="mbr-text mbr-fonts-style mt-3" mbr-if="showText" mbr-theme-style="display-7" data-app-selector=".mbr-text, .mbr-section-btn">03.04.2022 I 17 Uhr</p>
</div>
<div class="mbr-section-btn item-footer mt-2" mbr-if="showButtons" data-toolbar="-mbrBtnMove,-mbrBtnAdd" mbr-buttons mbr-theme-style="display-7"><a href class="btn btn-primary item-btn" target="_blank" data-app-placeholder="Type Text">Learn More
></a></div>
</div>
</div>
<div class="item features-image сol-12 col-md-6 col-lg-{{cardsWidth}}" mbr-if="cardsWidth < 7">
<div class="item-wrapper">
<div class="item-img">
<img src="file:///C:/Users/pc/AppData/Local/Mobirise.com/Mobirise/projects/project-2022-01-24_131846/assets/images/dummy500.jpg" alt>
</div>
<div class="item-content" mbr-if="showCardTitle || showCardSubtitle || showText || showButtons">
<h5 class="item-title mbr-fonts-style" mbr-theme-style="display-4" data-app-selector=".item-title" mbr-if="showCardTitle">Portfolio</h5>
<h6 class="item-subtitle mbr-fonts-style" mbr-theme-style="display-5" data-app-selector=".item-subtitle" mbr-if="showCardSubtitle"><b>ANTIK & TRÖDELMARKT</b></h6>
<p class="mbr-text mbr-fonts-style mt-3" mbr-if="showText" mbr-theme-style="display-7" data-app-selector=".mbr-text, .mbr-section-btn">01.05.2022 I 10-18 Uhr</p>
</div>
<div class="mbr-section-btn item-footer mt-2" mbr-if="showButtons" data-toolbar="-mbrBtnMove,-mbrBtnAdd" mbr-buttons mbr-theme-style="display-7"><a href class="btn btn-primary item-btn" target="_blank" data-app-placeholder="Type Text">Learn More
></a></div>
</div>
</div>
<div class="item features-image сol-12 col-md-6 col-lg-{{cardsWidth}}" mbr-if="cardsWidth < 4">
<div class="item-wrapper">
<div class="item-img">
<img src="file:///C:/Users/pc/AppData/Local/Mobirise.com/Mobirise/projects/project-2022-01-24_131846/assets/images/dummy500.jpg" alt>
</div>
<div class="item-content" mbr-if="showCardTitle || showCardSubtitle || showText || showButtons">
<h5 class="item-title mbr-fonts-style" mbr-theme-style="display-4" data-app-selector=".item-title" mbr-if="showCardTitle">Portfolio</h5>
<h6 class="item-subtitle mbr-fonts-style" mbr-theme-style="display-5" data-app-selector=".item-subtitle" mbr-if="showCardSubtitle">
Analysis
</h6>
<p class="mbr-text mbr-fonts-style mt-3" mbr-if="showText" mbr-theme-style="display-7" data-app-selector=".mbr-text, .mbr-section-btn">You don't have to code to create your own
site. Select one of available themes in the Mobirise Site Maker.</p>
</div>
<div class="mbr-section-btn item-footer mt-2" mbr-if="showButtons" data-toolbar="-mbrBtnMove,-mbrBtnAdd" mbr-buttons mbr-theme-style="display-7"><a href class="btn btn-primary item-btn" target="_blank" data-app-placeholder="Type Text">Learn More
></a></div>
</div>
</div>
<div class="item features-image сol-12 col-md-6 col-lg-{{cardsWidth}}" mbr-if="cardsWidth < 6">
<div class="item-wrapper">
<div class="item-img abstand-bild-rechts">
<img src="file:///C:/Users/pc/AppData/Local/Mobirise.com/Mobirise/projects/project-2022-01-24_131846/assets/images/dummy500.jpg" alt>
</div>
<div class="item-content" mbr-if="showCardTitle || showCardSubtitle || showText || showButtons">
<h5 class="item-title mbr-fonts-style" mbr-theme-style="display-4" data-app-selector=".item-title" mbr-if="showCardTitle">Portfolio</h5>
<h6 class="item-subtitle mbr-fonts-style" mbr-theme-style="display-5" data-app-selector=".item-subtitle" mbr-if="showCardSubtitle">
Analysis
</h6>
<p class="mbr-text mbr-fonts-style mt-3" mbr-if="showText" mbr-theme-style="display-7" data-app-selector=".mbr-text, .mbr-section-btn">You don't have to code to create your own
site. Select one of available themes in the Mobirise Site Maker.</p>
</div>
<div class="mbr-section-btn item-footer mt-2" mbr-if="showButtons" data-toolbar="-mbrBtnMove,-mbrBtnAdd" mbr-buttons mbr-theme-style="display-7"><a href class="btn btn-primary item-btn" target="_blank" data-app-placeholder="Type Text">Learn More
></a></div>
</div>
</div>
</div>
</div>
</section>
Code: Alles auswählen
padding-top: (@paddingTop * 1rem);
padding-bottom: (@paddingBottom * 0rem);
& when (@bg-type = "color") {
background-color: @bg-value;
}
& when (@bg-type = "image") {
background-image: url(@bg-value);
f & when (@overlay) {
.mbr-overlay {
background: @overlayColor;
opacity: @overlayOpacity;
}
}
}
.item-subtitle {
color: #3c3b3d;
a {
font-weight: 600;
}
}
.row {
justify-content: space-between;
}
.item {
cursor: pointer;
margin-bottom: 8px;
}
.item-img {
overflow: hidden;
margin-bottom: 0rem;
}
img, .item-img {
width: 100%;
& when (@autoSize) {
height: 100%;
object-fit: cover;
& when (@showCardTitle) {
height: (@imageHeight * 100px);
object-fit: cover;
}
& when (@showCardSubtitle) {
height: (@imageHeight * 100px);
object-fit: cover;
}
& when (@showText) {
height: (@imageHeight * 100px);
object-fit: cover;
}
& when (@showButtons) {
height: (@imageHeight * 100px);
object-fit: cover;
}
}
}
h5 {
margin: 0;
}
.item:focus, span:focus {
outline: none;
}
& when not (@spacing) {
.row {
margin-left: 0;
margin-right: 0;
}
.item {
padding: 0;
margin: 0;
}
}
.item-wrapper {
position: relative;
border-radius: 0px;
background: @cardsBg;
height: 100%;
display: flex;
flex-flow: column nowrap;
}
.item-content {
padding-top: 2rem;
}
.mbr-section-title {
color: #232323;
}
.item-title {
color: #666666;
}
.row > [class*=col] {
padding-left: 5px;
padding-right: 5px;
padding-top: 0px !important;
}
@media (min-width: 992px) {
.abstand-bild-links {
padding-left: 10px;
}
.abstand-bild-rechts {
padding-right: 10px;
}
}