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

Fix : Add language-specific anchors to footer section links and the cookie banner #760

Conversation

muhammedBkf
Copy link

@muhammedBkf muhammedBkf commented Sep 29, 2024

Related issue #755.
Screenshot from 2024-09-29 09-33-16

Adding language-specific anchors to footer section links and the cookie banner so that it points to the correct language section in the docs.

NB:

  • Anchors must be removed from the config file:
    agreements: {
    terms: $TERMS_AND_CONDITIONS_LINK,
    privacy_policy: "https://doc.jonquetlab.lirmm.fr/share/e6158eda-c109-4385-852c-51a42de9a412/doc/terms-conditions-naDsDo2Zxq#h-privacy-policy",
    legal_notices: "https://doc.jonquetlab.lirmm.fr/share/e6158eda-c109-4385-852c-51a42de9a412/doc/terms-conditions-naDsDo2Zxq#h-legal-notice"
    },

@muhammedBkf muhammedBkf changed the title Fix/footer links language specific anchors Fix : Add language-specific anchors to footer section links and the cookie banner Sep 29, 2024
- section_links.each do |section , link|
%a{:href => link, :target => "_blank"}
- anchor_key = "layout.footer.#{section}_anchor"
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

it can be cleaner doing just this: - anchor = I18n.t("layout.footer.#{section}_anchor", default: ""), but it needs to be tested.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Indeed, it's cleaner that way. I tested it, works just fine

@syphax-bouazzouni
Copy link
Collaborator

Update also the sample config file to be as you pointed in your "NB"

@muhammedBkf muhammedBkf force-pushed the fix/footer_links_language-specific_anchors branch from 4a7bae6 to ba03b3c Compare September 29, 2024 18:22
Copy link
Collaborator

@syphax-bouazzouni syphax-bouazzouni left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good work

@jonquet
Copy link

jonquet commented Oct 29, 2024

Does not seems to work on StagePortal.

@syphax-bouazzouni
Copy link
Collaborator

Does not seems to work on StagePortal.

@Bilelkihal you will need to update the config file as described in the description (and remember to do it in production also)

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

Successfully merging this pull request may close these issues.

3 participants