Commit 8bb5f4f5 authored by Simon Mitternacht's avatar Simon Mitternacht
Browse files

Change to child theme of healthSciences

parent e7211794
......@@ -7,7 +7,9 @@ class BoapFrontPageThemePlugin extends ThemePlugin {
* @return null
*/
public function init() {
$this->addStyle('stylesheet', 'dist/css/style.css');
// Use the parent theme's unique plugin slug
$this->setParent('healthsciencesthemeplugin');
$this->addStyle('child-stylesheet', 'styles/index.less');
}
/**
......@@ -23,6 +25,6 @@ class BoapFrontPageThemePlugin extends ThemePlugin {
* @return string
*/
function getDescription() {
return 'BOAP Front Page Theme Plugin.';
return 'BOAP Front Page Theme. Child of healthSciences.';
}
}
\ No newline at end of file
# BOAP-OJS-front-theme
Theme for BOAP front page
To build the theme type
~~~~
$ npm install
$ npm run build
~~~~
\ No newline at end of file
Theme for BOAP front page, child of healthSciences: https://github.com/pkp/healthSciences.
\ No newline at end of file
'use strict';
const gulp = require('gulp');
const sass = require('gulp-sass');
gulp.task('build', function () {
return gulp.src('./styles/style.scss')
.pipe(sass().on('error', sass.logError))
.pipe(gulp.dest('./dist/css'));
});
gulp.task('watch', function () {
gulp.watch('./styles/**/*.scss', ['build']);
});
{
"name": "boap-front",
"version": "1.0.0",
"description": "BOAP Front Page OJS Theme",
"scripts": {
"test": "echo \"Error: no test specified\" && exit 1",
"build": "gulp build"
},
"repository": {
"type": "git",
"url": "git+https://github.com/ubbdst/BOAP-OJS-front-theme.git"
},
"author": [ "Simon Mitternacht", "Christina Malitius" ],
"license": "ISC",
"bugs": {
"url": "https://github.com/ubbdst/BOAP-OJS-front-theme/issues"
},
"homepage": "https://github.com/ubbdst/BOAP-OJS-front-theme#readme",
"dependencies": {
"bootstrap": "^4.1.1",
"jquery": "^3.3.1",
"popper.js": "^1.14.3"
},
"devDependencies": {
"gulp-sass": "^4.0.1",
"gulp": "^3.9.1"
}
}
h1, h2, h3, h4, h5, h6, .h1, .h2, .h3, .h4, .h5, .h6,
.article-details-issue-identifier {font-family:'Fira Sans', sans-serif;}
.article-summary-title{font-family: 'Fira Sans', sans-serif;}
.page-content, .page-content p { font-size: 1.1rem; }
/* HEADER and NAV */
.main-header{ background-color: #fff; }
.main-header .container { max-width:2000px; width:100%; padding: 0 0 0 0; }
#userNav .nav-link,
.language-toggle .dropdown-toggle {font-size:15px;}
.navbar { background-color:#dedede; }
#primaryNav { padding: .1rem 0 .1rem 0; max-width:1140px;}
#primaryNav .dropdown-menu.show { padding: .1rem 0 .1rem 0; background-color: #363636; }
.navbar-logo { max-width:1140px; clear:both; }
.navbar-logo a { width:100%; }
.navbar-logo img { max-height:100px; height:auto; }
.navbar-light .navbar-nav .dropdown-item { color:#fff; }
#primaryNav .nav-link:hover,
#primaryNav .nav-link:focus { border:1px solid transparent; }
#primaryNav .dropdown-item,
#primaryNav .dropdown-item:hover { font-size:14px; border: 1px solid transparent; }
.article-summary {min-height:160px;}
.article-summary-pages { min-width:50px; }
.article-summary-galleys {}
/* FRONTPAGE STUFF */
.journal-description { max-width:900px; width:100%; margin:0px auto; padding-bottom:30px; }
.cmp_announcements { background-color: #dedede; max-width:940px; margin: 0 auto; padding: 0 20px 40px 20px; }
.cmp_announcements h2{ font-family:'Fira Sans', sans-serif; font-size:21px; text-transform:uppercase; letter-spacing:1px; color:#666; }
.announcement-summary h3 a{color:#1c1c1c;}
article.announcement-summary{margin-top: 30px; padding-top:20px; border-top:1px solid grey;}
/* Media Summary on Frontpage */
.article-summary-pic .cover.media-left {
float:left; width:25%; max-height:200px; overflow:hidden; margin-right:15px;
}
.article-summary-pic img{ width:100%;}
.issue-toc-section-title { font-size: 21px; font-weight:bold;}
/* CONTACT */
.contact-section { text-align:left; }
/* ARTICLE STUFF */
/* license under articles */
.article-summary { margin: 0 0 15px 0; padding: 15px 0 50px 0; border-bottom: 1px solid lightgrey; }
.article-details-block.article-details-license p { }
/*DIV*/
.alert-primary {border-color:transparent;}
.homepage-issue-cover { box-shadow: 0 0 0 #fff; }
.issue-toc{padding: 0 1% 0 1%;}
.issue-toc-section, .issue-toc-section + .issue-toc-section { border-top: none; }
.page-issue-description { text-align: left; }
.page-issue-description-wrapper,
.homepage-issue-description-wrapper { background-color: #dedede; }
/* FOOTER */
/*.site-footer-sidebar { display: none; }*/
.site-footer-sidebar {font-size:14px; }
.site-footer-sidebar .title { font-size:18px; }
/*BOAP-cred*/
.boap-cred{ width:100%; text-align:center; padding: 10px 0 10px 0; background-color: #666; }
.boap-cred a{ color: #fff; text-decoration:none;}
.boap-cred a:hover {color: #fff; text-decoration:underline;
}
@media screen and (max-width:1000px) {
.navbar-brand img {max-height:50px;}
}
@media screen and (max-width:750px) {
/* MEDIA SUMMARY */
.article-summary-pic{width:45%;}
.article-summary-pic .cover.media-left {
float:left;width:100%; margin-right:15px; margin-bottom:15px;
}
.article-summary-pic img{ width:100%;}
}
@media screen and (max-width:450px) {
/* MEDIA SUMMARY */
.article-summary-pic,
.article-summary-pic .cover.media-left {
float:left; clear:both; width:100%; margin-right:15px; margin-bottom:15px; max-height:320px;
}
.article-summary-pic img{ width:100%;}
}
$body-bg: green;
$body-color: white;
@import "node_modules/bootstrap/scss/bootstrap";
{**
* templates/frontend/components/footer.tpl
*
* Copyright (c) 2014-2017 Simon Fraser University Library
* Copyright (c) 2003-2017 John Willinsky
* Distributed under the GNU GPL v2. For full terms see the file docs/COPYING.
*
* @brief Common site frontend footer.
*
* @uses $isFullWidth bool Should this page be displayed without sidebars? This
* represents a page-level override, and doesn't indicate whether or not
* sidebars have been configured for thesite.
*}
</main>
{* Sidebars *}
{if empty($isFullWidth)}
{capture assign="sidebarCode"}{call_hook name="Templates::Common::Sidebar"}{/capture}
{if $sidebarCode}
<aside id="sidebar" class="pkp_structure_sidebar left col-xs-12 col-sm-2 col-md-4" role="complementary" aria-label="{translate|escape key="common.navigation.sidebar"}">
{$sidebarCode}
</aside><!-- pkp_sidebar.left -->
{/if}
{/if}
</div><!-- pkp_structure_content -->
<footer class="footer" role="contentinfo">
<div class="container">
<div class="row">
{if $pageFooter}
<div class="col-md-12">
{$pageFooter}
</div>
{/if}
<!--<div class="col-md-2" role="complementary" aria-label="{translate|escape key="about.aboutThisPublishingSystem"}">
<a href="{url page="about" op="aboutThisPublishingSystem"}">
<img alt="{translate key=$packageKey}" src="{$baseUrl}/{$brandImage}" width="70px">
</a>-->
<!--<a href="{$pkpLink}">
<img alt="{translate key="common.publicKnowledgeProject"}" src="{$baseUrl}/lib/pkp/templates/images/pkp_brand.png">
</a>
</div>-->
</div> <!-- .row -->
</div><!-- .container -->
</footer>
<div class="footer-extra"> <!-- line on bottom of page for collaboration content and contact -->
<p>Thin red line</p>
</div>
</div><!-- pkp_structure_page -->
{load_script context="frontend" scripts=$scripts}
{call_hook name="Templates::Common::Footer::PageFooter"}
</body>
</html>
{**
* lib/pkp/templates/frontend/components/header.tpl
*
* Copyright (c) 2014-2017 Simon Fraser University Library
* Copyright (c) 2003-2017 John Willinsky
* Distributed under the GNU GPL v2. For full terms see the file docs/COPYING.
*
* @brief Common frontend site header.
*
* @uses $isFullWidth bool Should this page be displayed without sidebars? This
* represents a page-level override, and doesn't indicate whether or not
* sidebars have been configured for thesite.
*}
{* Determine whether a logo or title string is being displayed *}
{assign var="showingLogo" value=true}
{if $displayPageHeaderTitle && !$displayPageHeaderLogo && is_string($displayPageHeaderTitle)}
{assign var="showingLogo" value=false}
{/if}
<!DOCTYPE html>
<html lang="{$currentLocale|replace:"_":"-"}" xml:lang="{$currentLocale|replace:"_":"-"}">
{if !$pageTitleTranslated}{capture assign="pageTitleTranslated"}{translate key=$pageTitle}{/capture}{/if}
{include file="core:frontend/components/headerHead.tpl"}
<body class="pkp_page_{$requestedPage|escape|default:"index"} pkp_op_{$requestedOp|escape|default:"index"}{if $showingLogo} has_site_logo{/if} container">
<div class="pkp_structure_page">
<nav id="accessibility-nav" class="sr-only navbar" role="navigation" aria-labelled-by="accessible-menu-label">
<div id="accessible-menu-label">
{translate|escape key="plugins.themes.bootstrap3.accessible_menu.label"}
</div>
<ul>
<li><a href="#main-navigation">{translate|escape key="plugins.themes.bootstrap3.accessible_menu.main_navigation"}</a></li>
<li><a href="#main-content">{translate|escape key="plugins.themes.bootstrap3.accessible_menu.main_content"}</a></li>
<li><a href="#sidebar">{translate|escape key="plugins.themes.bootstrap3.accessible_menu.sidebar"}</a></li>
</ul>
{* User profile, login, etc, navigation menu*}
<div class="container-fluid">
<div class="row navTop">
<ul id="navigationUser" class="nav nav-pills tab-list pull-right" role="navigation" aria-label="{translate|escape key="common.navigation.user"}">
{if $isUserLoggedIn}
<li>
<a class="dropdown-toggle" data-toggle="dropdown" role="button" aria-haspopup="true" aria-expanded="false" href="{url router=$smarty.const.ROUTE_PAGE page="submissions"}">
{$loggedInUsername|escape}
<span class="badge">
{$unreadNotificationCount}
</span>
</a>
<ul class="dropdown-menu dropdown-menu-right">
{if array_intersect(array(ROLE_ID_MANAGER, ROLE_ID_ASSISTANT, ROLE_ID_REVIEWER, ROLE_ID_AUTHOR), $userRoles)}
<li>
<a href="{url router=$smarty.const.ROUTE_PAGE page="submissions"}">
{translate key="navigation.dashboard"}
<span class="badge">
{$unreadNotificationCount}
</span>
</a>
</li>
{/if}
<li>
<a href="{url router=$smarty.const.ROUTE_PAGE page="user" op="profile"}">
{translate key="common.viewProfile"}
</a>
</li>
{if array_intersect(array(ROLE_ID_SITE_ADMIN), $userRoles)}
<li>
<a href="{if $multipleContexts}{url router=$smarty.const.ROUTE_PAGE context="index" page="admin" op="index"}{else}{url router=$smarty.const.ROUTE_PAGE page="admin" op="index"}{/if}">
{translate key="navigation.admin"}
</a>
</li>
{/if}
<li>
<a href="{url router=$smarty.const.ROUTE_PAGE page="login" op="signOut"}">
{translate key="user.logOut"}
</a>
</li>
{if $isUserLoggedInAs}
<li>
<a href="{url router=$smarty.const.ROUTE_PAGE page="login" op="signOutAsUser"}">
{translate key="user.logOutAs"} {$loggedInUsername|escape}
</a>
</li>
{/if}
</ul>
</li>
{else}
{if !$hideRegisterLink}
<li><a href="{url router=$smarty.const.ROUTE_PAGE page="user" op="register"}">{translate key="navigation.register"}</a></li>
{/if}
<li><a href="{url router=$smarty.const.ROUTE_PAGE page="login"}">{translate key="navigation.login"}</a></li>
{/if}
</ul>
</div><!-- .row -->
</div><!-- .container-fluid -->
<div class="container-fluid top-menu">
<div class="navbar-header">
{* Mobile hamburger menu *}
<button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target="#nav-menu" aria-expanded="false" aria-controls="navbar">
<span class="sr-only">Toggle navigation</span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button>
{* Logo or site title. Only use <h1> heading on the homepage.
Otherwise that should go to the page title. *}
{if $requestedOp == 'index'}
<h1 class="site-name navbar-brand">
{else}
<div class="site-name navbar-brand">
{/if}
{capture assign="homeUrl"}
{if $currentJournal && $multipleContexts}
{url page="index" router=$smarty.const.ROUTE_PAGE}
{else}
{url context="index" router=$smarty.const.ROUTE_PAGE}
{/if}
{/capture}
{if $displayPageHeaderLogo && is_array($displayPageHeaderLogo)}
<a href="{$homeUrl}" class="navbar-brand navbar-brand-logo">
<img src="{$publicFilesDir}/{$displayPageHeaderLogo.uploadName|escape:"url"}" {if $displayPageHeaderLogo.altText != ''}alt="{$displayPageHeaderLogo.altText|escape}"{else}alt="{translate key="common.pageHeaderLogo.altText"}"{/if}>
</a>
{elseif $displayPageHeaderTitle && !$displayPageHeaderLogo && is_string($displayPageHeaderTitle)}
<a href="{$homeUrl}" class="navbar-brand">{$displayPageHeaderTitle}</a>
{elseif $displayPageHeaderTitle && !$displayPageHeaderLogo && is_array($displayPageHeaderTitle)}
<a href="{$homeUrl}" class="navbar-brand navbar-brand-logo">
<img src="{$publicFilesDir}/{$displayPageHeaderTitle.uploadName|escape:"url"}" alt="{$displayPageHeaderTitle.altText|escape}">
</a>
{else}
<a href="{$homeUrl}" class="navbar-brand">
<img src="{$baseUrl}/templates/images/structure/logo.png" alt="{$applicationName|escape}" title="{$applicationName|escape}" />
</a>
{/if}
{if $requestedOp == 'index'}
</h1>
{else}
</div>
{/if}
</div>
{* Primary site navigation *}
{capture assign="primaryMenu"}
{load_menu name="primary" id="main-navigation" ulClass="nav navbar-nav"}
{/capture}
{if !empty(trim($primaryMenu)) || !$noContextsConfigured}
<nav id="nav-menu" class="navbar-collapse collapse" aria-label="{translate|escape key="common.navigation.site"}">
{* Primary navigation menu for current application *}
{$primaryMenu}
{* Search form *}
{if !$noContextsConfigured}
<div class="pull-md-right">
{include file="frontend/components/searchForm_simple.tpl"}
</div>
{/if}
</nav>
{/if}
</div><!-- .pkp_head_wrapper -->
</nav><!-- .pkp_structure_head -->
{* Wrapper for page content and sidebars *}
<div class="pkp_structure_content container">
<main class="pkp_structure_main col-xs-12 col-sm-10 col-md-8" role="main">
......@@ -10,73 +10,62 @@
*}
{include file="frontend/components/header.tpl"}
<div class="page_index_site">
{if $about}
<div class="about_site">
{$about|nl2br}
</div>
{/if}
<div class="journals">
<h2>
{translate key="journal.journals"}
</h2>
{if !count($journals)}
{translate key="site.noJournals"}
{else}
<ul>
{iterate from=journals item=journal}
{capture assign="url"}{url journal=$journal->getPath()}{/capture}
{assign var="thumb" value=$journal->getLocalizedSetting('journalThumbnail')}
{assign var="description" value=$journal->getLocalizedDescription()}
<li{if $thumb} class="has_thumb"{/if}>
{if $thumb}
{assign var="altText" value=$journal->getLocalizedSetting('journalThumbnailAltText')}
<div class="thumb">
<a href="{$url|escape}">
<img src="{$journalFilesPath}{$journal->getId()}/{$thumb.uploadName|escape:"url"}"{if $altText} alt="{$altText|escape}"{/if}>
</a>
<div class="container page-site">
<div class="row justify-content-md-center">
<div class="col-md-8">
<div class="page-content">
{if $about}
<div class="site-about">
{$about|nl2br}
</div>
{/if}
</div>
<div class="site-journals">
<h2 class="sr-only">{translate key="journal.journals"}</h2>
{if !count($journals)}
<p>{translate key="site.noJournals"}</p>
{else}
<div class="site-journals-list">
{iterate from=journals item=journal}
{capture assign="url"}{url journal=$journal->getPath()}{/capture}
{assign var="thumb" value=$journal->getLocalizedSetting('journalThumbnail')}
{assign var="description" value=$journal->getLocalizedDescription()}
<div class="site-journal">
{if $thumb}
<a class="site-journal-img" href="{$url|escape}">
<img src="{$journalFilesPath}{$journal->getId()}/{$thumb.uploadName|escape:"url"}"{if $altText} alt="{$altText|escape}"{/if}>
</a>
{/if}
<div class="site-journal-body">
<h3 class="site-journal-title">
<a href="{$url|escape}" rel="bookmark">
{$journal->getLocalizedName()}
</a>
</h3>
<div class="site-journal-description">{$description|nl2br}</div>
<p class="links">
<a class="btn" href="{$url|escape}">
{translate key="site.journalView"}
</a>
<a class="btn" href="{url|escape journal=$journal->getPath() page="issue" op="current"}">
{translate key="site.journalCurrent"}
</a>
</p>
</div>
</div>
{/if}
{/iterate}
</div>
<div class="body">
<h3>
<a href="{$url|escape}" rel="bookmark">
{$journal->getLocalizedName()}
</a>
</h3>
{if $description}
<div class="description">
{$description|nl2br}
</div>
{/if}
<ul class="links">
<li class="view">
<a href="{$url|escape}">
{translate key="site.journalView"}
</a>
</li>
<li class="current">
<a href="{url|escape journal=$journal->getPath() page="issue" op="current"}">
{translate key="site.journalCurrent"}
</a>
</li>
</ul>
{if $journals->getPageCount() > 0}
<div class="cmp_pagination">
{page_info iterator=$journals}
{page_links anchor="journals" name="journals" iterator=$journals}
</div>
</li>
{/iterate}
</ul>
{if $journals->getPageCount() > 0}
<div class="cmp_pagination">
{page_info iterator=$journals}
{page_links anchor="journals" name="journals" iterator=$journals}
</div>
{/if}
{/if}
{/if}
{/if}
</div>
</div>
</div>
</div><!-- .page -->
{include file="frontend/components/footer.tpl"}
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment