Open Source Platform for DTC, B2B Commerce, Marketplaces & Omnichannel. REST APIs, TypeScript SDKs, and production-ready Next.js storefront. Self-host it. Own your data. No vendor lock-in. Zero platform fees.
Ruby b2b-commercee-commerceecommerceecommerce-apiecommerce-frameworkecommerce-platformheadlessheadless-commerceheadless-ecommercemarketplacemulti-tenantmulti-vendormulti-vendor-ecommerceopen-sourcespree-commerce
Fix displaying header and text in the Image With Text
Łukasz Adamczyk4ebdd2d6ef1b
diff --git a/storefront/app/views/themes/default/spree/page_sections/_image_with_text.html.erb b/storefront/app/views/themes/default/spree/page_sections/_image_with_text.html.erbindex faa15147bb..e34bf5c8fd 100644--- a/storefront/app/views/themes/default/spree/page_sections/_image_with_text.html.erb+++ b/storefront/app/views/themes/default/spree/page_sections/_image_with_text.html.erb@@ -32,17 +32,17 @@<% section.blocks.includes(:rich_text_text, :links).each do |block| %><% case block.type %><% when 'Spree::PageBlocks::Heading' %>- <%= page_builder_link_to(section.link, target: (section.link&.open_in_new_tab ? '_blank' : nil), class: "image-with-text--heading", style: block_background_color_style(block)) do %>- <h2 class="<%= block.preferred_size == 'small' ? 'text-lg' : (block.preferred_size == 'medium' ? 'text-xl' : 'text-2xl lg:text-3xl') %> font-medium" <%= block_attributes(block) %>>+ <h2 class="<%= block.preferred_size == 'small' ? 'text-lg' : (block.preferred_size == 'medium' ? 'text-xl' : 'text-2xl lg:text-3xl') %> font-medium" <%= block_attributes(block) %>>+ <%= page_builder_link_to(section.link, target: (section.link&.open_in_new_tab ? '_blank' : nil), class: "image-with-text--heading", style: block_background_color_style(block)) do %><%= block.text %>- </h2>- <% end %>+ <% end %>+ </h2><% when 'Spree::PageBlocks::Text' %>- <%= page_builder_link_to(section.link, target: (section.link&.open_in_new_tab ? '_blank' : nil), class: "image-with-text--text", style: block_background_color_style(block)) do %>- <div <%= block_attributes(block) %>>+ <div <%= block_attributes(block) %>>+ <%= page_builder_link_to(section.link, target: (section.link&.open_in_new_tab ? '_blank' : nil), class: "image-with-text--text", style: block_background_color_style(block)) do %><%= block.text %>- </div>- <% end %>+ <% end %>+ </div><% when 'Spree::PageBlocks::Buttons' %><div class="w-full image-with-text--buttons" <%= block_attributes(block) %>><div class="inline-block">