Skip to content

Commit

Permalink
feat: Add full width option to blog detail CMS element
Browse files Browse the repository at this point in the history
  • Loading branch information
7underlines committed Mar 1, 2025
1 parent bdb8da6 commit 6d80392
Show file tree
Hide file tree
Showing 8 changed files with 17 additions and 5 deletions.
3 changes: 3 additions & 0 deletions CHANGELOG_de-DE.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
# 4.2.1
- Option für volle Breite für Blog-Details CMS-Element hinzugefügt

# 4.2.0
- Tags hinzugefügt [5](https://github.com/Werkstattl/OpenBlogware/issues/5)

Expand Down
3 changes: 3 additions & 0 deletions CHANGELOG_en-GB.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
# 4.2.1
- Added full width option to blog detail cms element

# 4.2.0
- Added tags [5](https://github.com/Werkstattl/OpenBlogware/issues/5)

Expand Down
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "werkstattl/openblogware",
"description": "OpenBlogware: A Blog Module for Shopware 6.",
"version": "4.2.0",
"version": "4.2.1",
"type": "shopware-platform-plugin",
"keywords": ["blog", "news"],
"license":"MIT",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,5 +17,9 @@ Shopware.Service('cmsService').registerCmsElement({
source: 'static',
value: true,
},
fullWidth: {
source: 'static',
value: false,
},
},
});
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,8 @@
"showMeta": {
"label": "Detail Ansicht Meta Informationen",
"showAuthor": "Zeige Autor",
"showCategory": "Zeige Kategorie"
"showCategory": "Zeige Kategorie",
"fullWidth": "Volle Breite"
}
},
"component": {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,8 @@
"showMeta": {
"label": "Detail view meta information",
"showAuthor": "Show author",
"showCategory": "Show category"
"showCategory": "Show category",
"fullWidth": "Full width"
}
},
"component": {
Expand Down

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{% block block_werkl_blog_detail %}
{% set element = block.slots.getSlot('blogDetail') %}

<div class="{% if element.config.fullWidth %}col-md-12{% elseif section and section.sizingMode === 'boxed' %}col-md-8 offset-md-2{% endif %}" data-cms-element-id="{{ element.id }}">
<div class="{% if element.config.fullWidth %}col-12{% elseif section and section.sizingMode === 'boxed' %}col-md-8 offset-md-2{% endif %}" data-cms-element-id="{{ element.id }}">
{% sw_include "@Storefront/storefront/element/cms-element-" ~ element.type ~ ".html.twig" ignore missing %}
</div>

Expand Down

0 comments on commit 6d80392

Please sign in to comment.