Created
July 29, 2015 13:48
-
-
Save amelekesov/8b479d3d2c657ae88dec to your computer and use it in GitHub Desktop.
Revisions
-
amelekesov created this gist
Jul 29, 2015 .There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,17 @@ diff --git a/design/themes/responsive/css/styles.less b/design/themes/responsive/css/styles.less index 3a0c6ba..beb6220 100644 --- a/design/themes/responsive/css/styles.less +++ b/design/themes/responsive/css/styles.less @@ -3223,8 +3223,12 @@ input.ty-search-block__input { /* * Template: templates/views/categories/view.tpl */ + .ty-subcategories-block { margin: 10px 0; + display: inline-block; + min-width: 350px; + vertical-align: top; } .ty-subcategories-block__item { padding-bottom: 10px; This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,29 @@ diff --git a/design/themes/responsive/css/tygh/responsive.less b/design/themes/responsive/css/tygh/responsive.less index 8defb07..1b0cf95 100644 --- a/design/themes/responsive/css/tygh/responsive.less +++ b/design/themes/responsive/css/tygh/responsive.less @@ -1307,6 +1307,12 @@ Responsive: Landscape phone to desktop/tablet margin-right: 4px; top: 0px; } + +/* Categories + ========================================================================== */ + .ty-subcategories { + text-align: center; + } } /* ========================================================================== @@ -1448,4 +1454,10 @@ Responsive: Phone .ty-filters-search__item { padding-right: 0; } + +/* Categories + ========================================================================== */ + .ty-subcategories-block { + min-width: 100%; + } } \ No newline at end of file This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,55 @@ diff --git a/design/themes/responsive/templates/views/categories/components/categories_multicolumns.tpl b/design/themes/responsive/templates/views/categories/components/categories_multicolumns.tpl index 5b3805a..1994653 100644 --- a/design/themes/responsive/templates/views/categories/components/categories_multicolumns.tpl +++ b/design/themes/responsive/templates/views/categories/components/categories_multicolumns.tpl @@ -1,27 +1,29 @@ {split data=$categories size=$columns|default:"3" assign="splitted_categories"} -<div class="ty-subcategories-block"> +<div class="ty-subcategories"> {strip} {foreach from=$splitted_categories item="scats"} - {foreach from=$scats item="category"} - {if $category} - <div class="ty-column{$columns} ty-subcategories-block__item"> - <a href="{"categories.view?category_id=`$category.category_id`"|fn_url}" class="ty-subcategories-block__a"> - {if $category.main_pair} - {include file="common/image.tpl" - show_detailed_link=false - images=$category.main_pair - no_ids=true - image_id="category_image" - image_width=$settings.Thumbnails.category_lists_thumbnail_width - image_height=$settings.Thumbnails.category_lists_thumbnail_height - class="ty-subcategories-img" - } - {/if} - {$category.category} - </a> - </div> - {/if} - {/foreach} + <div class="ty-subcategories-block"> + {foreach from=$scats item="category"} + {if $category} + <div class="ty-column{$columns} ty-subcategories-block__item"> + <a href="{"categories.view?category_id=`$category.category_id`"|fn_url}" class="ty-subcategories-block__a"> + {if $category.main_pair} + {include file="common/image.tpl" + show_detailed_link=false + images=$category.main_pair + no_ids=true + image_id="category_image" + image_width=$settings.Thumbnails.category_lists_thumbnail_width + image_height=$settings.Thumbnails.category_lists_thumbnail_height + class="ty-subcategories-img" + } + {/if} + {$category.category} + </a> + </div> + {/if} + {/foreach} + </div> {/foreach} {/strip} </div>