Customize manuscript child theme

Dear @NateWr
I created this thread for putting together other customize issues on manuscript theme. I have got some such as:

This thread might be ‘double information’ but I think it is important to organize them

3 Likes

I have some questions about other customize. I am using ojs 3.1.1
First, is it possible to delete right sidebar information on article detail page but keep it in indexPage journal? It aims to make the article detail page as full page
Second, where is the header.tpl and footer.tpl file related to manuscript theme?

Thanks in advance

First, is it possible to delete right sidebar information on article detail page but keep it in indexPage journal? It aims to make the article detail page as full page

In the default template, you can prevent the sidebar from appearing on any page by passing a true $isFullWidth variable to the header template file.

To modify the article detail page, I’d add copy /templates/frontend/pages/article.tpl (here) to your child theme at the same location. Then I’d modify this line:

{include file="frontend/components/header.tpl" pageTitleTranslated=$article->getLocalizedTitle()|escape}

And add the isFullWidth variable:

{include file="frontend/components/header.tpl" isFullWidth=true pageTitleTranslated=$article->getLocalizedTitle()|escape}

That should do it.

(PS - I strongly encourage you to use a child theme, rather than modifying the manuscript theme directly. Any changes you make to the files in defaultManuscript will be overwritten with each update to the theme.)

Second, where is the header.tpl and footer.tpl file related to manuscript theme?

The default theme (and the manuscript theme, since it is a child theme) rely on the template files in the core application. You will find these in two places:

/templates/frontend/...
/lib/pkp/templates/frontend/...

You can find the templates you’re looking for in the /lib/pkp/frontend/components/ directory.

Thanks @NateWr
I am still learning how to make child theme. So, I just want to make a try first. In plugins/themes/defaultManuscript , I make folder templates/frontend/pages/article.tplthen modify

{include file="frontend/components/header.tpl" isFullWidth=true pageTitleTranslated=$article->getLocalizedTitle()|escape}

However, it does not change the article page to full width. Is it a correct way to do?
If it is, could I make other folders e.g. /templates/frontend/components or objects ?

That looks like the correct way. You may need to clear your template cache to see the change, which you can do in the Administration area.

If it is, could I make other folders e.g. /templates/frontend/components or objects ?

Yep. You can overwrite any core or parent theme template by dropping in a template file to a matching file path.

1 Like

Thanks a lot @NateWr

Is it possible to make three column footer by customizing footer.tpl in default manuscript?
In bootstrap, we can use container - row and grid system.

In Bootstrap, we can customize sidebar like this
image
but when the same html used in manuscript theme, they follow the theme sidebar layout.

Hi @NateWr
Is it possible to shorten the references, e.g using Read More feature?
http://ulumuna.or.id/index.php/ujis/article/view/5

Hi @NateWr,
I read, very interestingly, the difference is that I would like it to apply on the boostraps template. Is it possible? :thinking:

Yes, but you’d need to figure out your own implementation. I’m sure you can find a JS library that will do this for you if you google “jQuery read more” or something.

I’m sorry I don’t understand the question. Could you describe what you want to do in more detail?

I’m sorry I don’t understand the question. Could you describe what you want to do in more detail?

Yes @NateWr , sorry, so, as the user before wrote, I would like in the pages of the articles remove the right column, to be precise the default one, with the button MAKE A SUBMISSION etc. …, and replace it with the column of details of the article, such as the image, the section, the keywords, etc. …, but to apply on the boostraps template.

Hi @Tiziano,

That sounds a little more complicated, as you’ll need to change the HTML structure of the page. The templates you’ll need to modify are:

  • /templates/frontend/pages/article.tpl
  • /templates/frontend/objects/article_details.tpl

Hi @kawahyu

It seems that you would also need to add isFullWidth=true to this line: https://github.com/pkp/ojs/blob/master/templates/frontend/pages/article.tpl#L33.
i.e. to also have something like:
{include file="frontend/components/footer.tpl" isFullWidth=true}

Best,
Bozana

Hi @NateWr,
Would you please tell if the theme is compatible with 3.1.2? Many of our journals depend on it, so we cannot upgrade before it is available.
If not, when would you plan to make a new release? Thanks!

Hi @Ph_We,

Yes, it is! Since Manuscript only adds CSS code to the default theme, it is almost always compatible with a new upgrade. The only time this is not the case is:

  • If new content has been added to a release that is not styled yet. An example might be the Categories addition in 3.1.2 – but this shouldn’t impact existing journals because they can’t have used it before the upgrade.
  • If changes in the CSS code of the default theme haven’t been reflected in Manuscript. This is rare and usually will only lead to minor style degradation rather than significant bugs. The only changes I’m aware of will be adequately reflected in Manuscript’s styles, but let me know if you see anything off.
1 Like

Hi @NateWr,
the Manuscript (Default child theme), does not have the menu optimized for the mobile.

06

is it possible to add it? would be perfect.
Thanks

Bye
Tiziano

@Tiziano can you provide a link to the journal where you see this? I can’t reproduce it myself so there is probably a customization on the site that is causing this problem.

Hi @NateWr!
Yes, for exemple this:
http://beyond-rheumatology.org

is one of those to which I have applied the Manuscript theme.

Hi @Tiziano,

The custom CSS styles on that site are causing the issue. I tracked it down to this block of CSS code in custom_style.css:

.pkp_head_wrapper .pkp_search{
	position: absolute;
	top: 0.7em;
	right: 0;
	height: 40px;
	min-width: 100px;
	padding: 0;
	font-size: 14px;
	line-height: 20px;
	transition: min-width .4s;
	text-align: right;
	overflow-x: hidden
}

Selection_032

Hi @NateWr,
i tried to remove that css rule and in fact now the search form moves under the menu, but it would be nice if also in this Manuscript theme the menu would adapt to mobile as the bootstraps theme.
Like this:

32

Hi there, y’all.

I’m having a similar problem with the Mansucript theme (problem: menu not optimized for mobile). Here’s what I see when I visit the webpage:
Screenshot_20211102-104453_Chrome

And when I click the hamburger menu, I get this:

Screenshot_20211102-104457_Chrome

So, I don’t end up seeing anything on the menu when I click the hamburger when on a phone. I’ve tested on Android and Mac.

Any help? :slight_smile: