- local_url = current_page.metadata.page[:local_url] - url = local_url || current_page.url - title = current_page.metadata.page[:title] || locals[:title] # locals should be first but there's a bug - description = locals[:description] || current_page.metadata.page[:description] - standalone_url = !!extensions[:directory_indexes] ? url.sub(/\/$/, '/standalone') : url.sub(/\.html$/, '-standalone.html') - if resource_file(current_page).match(/-?standalone\/?$/) = html - else article.glypto-model header - if title h3._title - if local_url = link_to title, local_url - else = title - if description p._description = description ._standalone = link_to standalone_url, target: '_blank' do i.fa.fa-external-link title="Standalone version" section.glypto-model-stage - if current_page.metadata.page.iframe iframe src="#{standalone_url}" height="0" width="100%" frameborder="0" scrolling="no" onload='javascript:resizeIframe(this);' - else figure = html = partial 'glyptotheque/model-utils', locals: { html: html } - unless locals[:iframe] - stylesheets = current_page.metadata.page[:stylesheet] || current_page.metadata.page[:stylesheets] || current_page.data[:stylesheet] || current_page.data[:stylesheets] - javascripts = current_page.metadata.page[:javascript] || current_page.metadata.page[:javascripts] || current_page.data[:javascript] || current_page.data[:javascripts] - if stylesheets - content_for :stylesheets, include_stylesheets(stylesheets) - if javascripts - content_for :javascripts, include_javascripts(javascripts)