|
@@ -85,7 +85,8 @@ if(false){var $grid=$('.grid',_$row).masonry({itemSelector:'.col',columnWidth:'.
|
|
|
$this.height(Math.min($this.attr('init-height'),_$row.height()));});};function checkGridBlockVisible(){var $r_h=_$row.height();var $this,pos;$('.grid .col',_$row).each(function(i,e){$this=$(this);pos=$this.position();if(pos.top+$this.height()<=$r_h){$this.removeClass('offfield');}else{$this.addClass('offfield');}});}
|
|
|
function initCollectionNav(){void 0;$('.field--name-field-notice, .index','.taxonomy-term.vocabulary-entrees.home_mobile').addClass('closed');$('.field--name-field-notice>.field__label','.taxonomy-term.vocabulary-entrees.home_mobile').on('click',onClickCollectionNotice);$('.index>.field__label','.taxonomy-term.vocabulary-entrees.home_mobile').on('click',onClickCollectionIndex);};function onClickCollectionNotice(e){toggleEntreeOpening($(this).parent(),'notice');};function onClickCollectionIndex(e){toggleEntreeOpening($(this).parent(),'index');};function toggleEntreeOpening($e,part){$e.toggleClass('closed').parents('.taxonomy-term.vocabulary-entrees.home_mobile').toggleClass(part+'-opened');}
|
|
|
function initSearch(){$('#edit-entries--wrapper legend','#edlp-search-form').on('click',function(){$(this).parent().toggleClass('opened');});};function initEnregistrementTranscript(){void 0;var $node=_$row.find('article.node--type-enregistrement.node--view-mode-transcript');var $nav=$('<nav>').prependTo($node);$node.find('.field--name-field-transcript-vo').addClass('visible').find('.field__label').clone().appendTo($nav).addClass('is-active').attr('field_target','.field--name-field-transcript-vo');$node.find('.field--name-field-transcript-trad').find('.field__label').clone().appendTo($nav).attr('field_target','.field--name-field-transcript-trad');$nav.find('.field__label').on('click',function(){var $this=$(this).addClass('is-active');$this.siblings('.is-active').removeClass('is-active');$this.parents('article.node').find('.field.visible').removeClass('visible');$this.parents('article.node').find($this.attr('field_target')).addClass('visible');});};function backToFrontPage(pop_state){void 0;closeAllModals();$('body').removeClass().addClass('path-frontpage');$('a[data-drupal-link-system-path="<front>"]').addClass('is-active');if(_corpus_ready){_$corpus_canvas.trigger({'type':'close-all-entree'});_$corpus_canvas.trigger({'type':'scramble-collection'});}
|
|
|
-if(typeof pop_state=="undefined"||!pop_state){void 0;history.pushState({home:true},null,_base_url+drupalSettings.path.currentLanguage);}}
|
|
|
+if(typeof pop_state=="undefined"||!pop_state){void 0;state={home:true,context:"home",caller:null}
|
|
|
+_states_history.unshift(state);history.pushState(state,null,_base_url+drupalSettings.path.currentLanguage);}}
|
|
|
function closeAllModals(){_$row.html('');_$ajaxLinks.removeClass('is-active');_$body.trigger({'type':'all-modal-closed'});checkVisibleCorpusMapSpace();};function checkRowEmpty(){void 0;if(!$('.col',_$row).length){if(!_$body.is('.entity-type-taxonomy_term.bundle-entrees')){if(!_$body.is('.entity-type-node.bundle-page')){if(_$body.is('.bundle-enregistrement.view-mode-article')&&$('a.articles-link').is('.is-active')){void 0;$('a.articles-link').removeClass('is-active').trigger('click');}else{backToFrontPage();}}else{if(_corpus_ready){_$corpus_canvas.trigger({'type':'scramble-collection'});}
|
|
|
$('a[data-drupal-link-system-path="productions"]','#block-mainnavigation').removeClass('is-active').trigger('click');}}else{$('.entree-content a.is-active').removeClass('is-active');}}};init();}
|
|
|
$(document).ready(function($){if(drupalSettings.path.isFront){var edlptheme=new EdlpTheme();}else{$('body').attr('booted','booted');}});})(jQuery,Drupal,drupalSettings);
|