feat(main: Added default block classes
This commit is contained in:
@@ -2,15 +2,16 @@
|
||||
{if $block.slider_mode == 'responsive'}
|
||||
{block name=slider_responsive}
|
||||
<div class="d-lg-none">
|
||||
<div id="customhtml-slider-{$block.id_ws_customhtml|intval}" class="swiper customhtml-slider" data-swiper="{$block.slider_config|escape:'html':'UTF-8'}">
|
||||
<div class="swiper customhtml-slider" data-swiper="{$block.slider_config|escape:'html':'UTF-8'}">
|
||||
<div class="swiper-wrapper">
|
||||
{foreach from=$block.slides item="slide" name="slides"}
|
||||
{assign var="count" value=$smarty.foreach.slides.iteration|string_format:"%02d"}
|
||||
<div class="swiper-slide">
|
||||
{assign var="customhtmlOverridePath" value="{$smarty.const._PS_THEME_DIR_}modules/ws_customhtml/views/templates/hook/{$hookName}/banner.tpl"}
|
||||
{if file_exists($customhtmlOverridePath)}
|
||||
{include file="module:ws_customhtml/views/templates/hook/`$hookName`/banner.tpl" block=$slide group=$group hookName=$hookName}
|
||||
{include file="module:ws_customhtml/views/templates/hook/`$hookName`/banner.tpl" block=$slide group=$group hookName=$hookName count=$count}
|
||||
{else}
|
||||
{include file="module:ws_customhtml/views/templates/hook/_banner.tpl" block=$slide}
|
||||
{include file="module:ws_customhtml/views/templates/hook/_banner.tpl" block=$slide count=$count}
|
||||
{/if}
|
||||
</div>
|
||||
{/foreach}
|
||||
@@ -19,12 +20,17 @@
|
||||
</div>
|
||||
<div class="row d-none d-lg-flex customhtml-slider-grid">
|
||||
{foreach from=$block.slides item="slide" name="slides"}
|
||||
{assign var="count" value=$smarty.foreach.slides.iteration|string_format:"%02d"}
|
||||
{if !empty($block.slider_desktop_column_width)}
|
||||
<div class="customhtml-slider-grid-item" style="flex: 0 0 {$block.slider_desktop_column_width|escape:'html':'UTF-8'}; max-width: {$block.slider_desktop_column_width|escape:'html':'UTF-8'};">
|
||||
{else}
|
||||
<div class="customhtml-slider-grid-item col">
|
||||
{/if}
|
||||
{assign var="customhtmlOverridePath" value="{$smarty.const._PS_THEME_DIR_}modules/ws_customhtml/views/templates/hook/{$hookName}/banner.tpl"}
|
||||
{if file_exists($customhtmlOverridePath)}
|
||||
{include file="module:ws_customhtml/views/templates/hook/`$hookName`/banner.tpl" block=$slide group=$group hookName=$hookName}
|
||||
{include file="module:ws_customhtml/views/templates/hook/`$hookName`/banner.tpl" block=$slide group=$group hookName=$hookName count=$count}
|
||||
{else}
|
||||
{include file="module:ws_customhtml/views/templates/hook/_banner.tpl" block=$slide}
|
||||
{include file="module:ws_customhtml/views/templates/hook/_banner.tpl" block=$slide count=$count}
|
||||
{/if}
|
||||
</div>
|
||||
{/foreach}
|
||||
@@ -33,15 +39,16 @@
|
||||
{/if}
|
||||
{if $block.slider_mode != 'responsive'}
|
||||
{block name=slider_always}
|
||||
<div id="customhtml-slider-{$block.id_ws_customhtml|intval}" class="swiper customhtml-slider" data-swiper="{$block.slider_config|escape:'html':'UTF-8'}">
|
||||
<div class="swiper customhtml-slider" data-swiper="{$block.slider_config|escape:'html':'UTF-8'}">
|
||||
<div class="swiper-wrapper">
|
||||
{foreach from=$block.slides item="slide" name="slides"}
|
||||
{assign var="count" value=$smarty.foreach.slides.iteration|string_format:"%02d"}
|
||||
<div class="swiper-slide">
|
||||
{assign var="customhtmlOverridePath" value="{$smarty.const._PS_THEME_DIR_}modules/ws_customhtml/views/templates/hook/{$hookName}/banner.tpl"}
|
||||
{if file_exists($customhtmlOverridePath)}
|
||||
{include file="module:ws_customhtml/views/templates/hook/`$hookName`/banner.tpl" block=$slide group=$group hookName=$hookName}
|
||||
{include file="module:ws_customhtml/views/templates/hook/`$hookName`/banner.tpl" block=$slide group=$group hookName=$hookName count=$count}
|
||||
{else}
|
||||
{include file="module:ws_customhtml/views/templates/hook/_banner.tpl" block=$slide}
|
||||
{include file="module:ws_customhtml/views/templates/hook/_banner.tpl" block=$slide count=$count}
|
||||
{/if}
|
||||
</div>
|
||||
{/foreach}
|
||||
@@ -50,5 +57,3 @@
|
||||
{/block}
|
||||
{/if}
|
||||
{/if}
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user