Skip to content

Instantly share code, notes, and snippets.

View dimmech's full-sized avatar

David Cruz dimmech

View GitHub Profile
@dimmech
dimmech / store_menu.css
Created September 5, 2016 20:21
Drupal Isotope Hierarchical css
.isotope-container {
margin: 0 auto !important;
min-height: 500px;
}
.isotope-container a {
display: block;
}
.isotope-container ul,
.isotope-container li {
text-align: center;
@dimmech
dimmech / Import_View.txt
Created September 5, 2016 20:17
Drupal Isotope Hierarchical Filter View
$view = new view();
$view->name = 'Store_Filter';
$view->description = '';
$view->tag = 'default';
$view->base_table = 'taxonomy_term_data';
$view->human_name = 'Store Filter';
$view->core = 7;
$view->api_version = '3.0';
$view->disabled = FALSE; /* Edit this to true to make a default view disabled initially */
@dimmech
dimmech / store_menu.js
Created September 5, 2016 20:15
Drupal Isotope Hierarchical js
(function ($) {
$(document).ready(function() {
//$('li.first').hover(function(){ alert("Hello"); });
// Insert li classes based on span value from views output
$('ul.isotope-options > li.first > a').text('Product Catalog');
$('.level0').parent().parent().addClass('sub-parent');
$('.level1').parent().parent().addClass('sub-child');
$('.level2').parent().parent().addClass('sub-grandchild');