w/skins/MinervaNeue/resources/skins.minerva.scripts/references.js
/**
	 * Event handler to show reference when a reference link is clicked
	 * @ignore
	 * @param {jQuery.Event} ev Click event of the reference element
	 * @param {ReferencesDrawer} drawer to show the reference in
	 * @param {Page} page
	 */
Event handler to show reference when a reference link is clicked
@ignore
@param {jQuery.Event} ev Click event of the reference element
@param {ReferencesDrawer} drawer to show the reference in
@param {Page} page
Event handler to show reference when a reference link is clicked @ignore @param { jQuery . Event } ev Click event of the reference element @param { ReferencesDrawer } drawer to show the reference in @param { Page } page
function showReference( ev, drawer, page ) {
		var urlComponents, result,
			$dest = $( ev.currentTarget ),
			href = $dest.attr( 'href' );
		ev.preventDefault();
		urlComponents = href.split( '#' );
		if ( urlComponents.length > 1 ) {
			href = '#' + urlComponents[1];
		}
		result = drawer.showReference( href, page, $dest.text() );
		if ( result ) {
			result.then( util.noop, function ( err ) {
				if ( err === ReferencesGateway.ERROR_NOT_EXIST ) {
					router.navigate( href );
				}
			} );
		}
		if ( drawer.isVisible() ) {
			ev.stopPropagation();
		} else {
			drawer.render( {
				text: undefined
			} );
		}
	}
function showReference ( ev , drawer , page ) { var urlComponents , result , $dest = $ ( ev . currentTarget ) , href = $dest . attr ( 'href' ) ; ev . preventDefault ( ) ; urlComponents = href . split ( '#' ) ; if ( urlComponents . length > 1 ) { href = '#' + urlComponents [ 1 ] ; } result = drawer . showReference ( href , page , $dest . text ( ) ) ; if ( result ) { result . then ( util . noop , function ( err ) { if ( err === ReferencesGateway . ERROR_NOT_EXIST ) { router . navigate ( href ) ; } } ) ; } if ( drawer . isVisible ( ) ) { ev . stopPropagation ( ) ; } else { drawer . render ( { text : undefined } ) ; } }
Event handler to show reference when a reference link is clicked
 @ignore
 @param {jQuery.Event} ev Click event of the reference element
 @param {ReferencesDrawer} drawer to show the reference in
 @param {Page} page
Event handler to show reference when a reference link is clicked @ignore @param { jQuery . Event } ev Click event of the reference element @param { ReferencesDrawer } drawer to show the reference in @param { Page } page
// If necessary strip the URL portion of the href so we are left with the // fragment // Previously showReference method returns nothing so we check its truthy // Can be removed when I5a7b23f60722eb5017a85c68f38844dd460f8b63 is merged. // don't hide drawer (stop propagation of click) if it is already shown // (e.g. click another reference) // flush any existing reference information