Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[OJS] | Frontend, article details page - Statistics graph without labels if Default theme is not enabled #11092

Open
1 task done
mpbraendle opened this issue Mar 14, 2025 · 0 comments
Assignees

Comments

@mpbraendle
Copy link
Contributor

mpbraendle commented Mar 14, 2025

Valid Title

  • I have updated the title to accurately reflect the bug description

Description

The usage statistics graph in the article detail page misses the labels if the Default theme is not enabled and another theme is used. This is due to using fixed translation key names in templates/frontend/objects/article_details.tpl, in https://github.com/pkp/ojs/blob/c2eef662bdbcdf6461cc1d21058235e1ba688de4/templates/frontend/objects/article_details.tpl#L197 and
https://github.com/pkp/ojs/blob/c2eef662bdbcdf6461cc1d21058235e1ba688de4/templates/frontend/objects/article_details.tpl#L202

Possible workarounds:

  • enable the Default theme in the plugins section, or
  • for a non-Default theme, copy templates/frontend/objects/article_details.tpl to the theme directory, replace the keys with theme-specific locales.

Correct solution:

  • translation keys in central templates should not be theme specific. Hence, replace them with keys/translations that are in the OJS central locale.

Steps to Reproduce

  1. In the backend, Website > Plugins, disable the Default theme for journal, use another theme instead, e.g. derived from the Default theme.
  2. In the backe, Website > Appearance, choose another theme than the Default theme.
  3. In the backend, enable display of usage statistics in Website > Appearance > Usage statistics display options (e.g. bar or line chart
  4. In the frontend, visit a article detail page

Expected Result

Display title label for Download graph and month labels for horizontal axis. See image 1 below.

Actual Result

Displays only the keys for the title of and month labels of the Download graph. See image 2 below.

Environment Details

No response

Application Version

OJS 3.4.0-x

Logs

No response

Additional Information

Image 1:
Image
Image 2:
Image

@kaitlinnewson kaitlinnewson self-assigned this Mar 20, 2025
@Tribunal33 Tribunal33 self-assigned this Mar 23, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants