Skip to content

Commit

Permalink
feat: lang added to privacy policy link (#570)
Browse files Browse the repository at this point in the history
* feat: lang added to privacy policy link

* fix: data unused deleted

* fix: error php

* fix: error php
  • Loading branch information
ClaraLpresta authored Jan 17, 2025
1 parent e51c218 commit 6cd5ef2
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 2 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/php.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ jobs:
- run: composer install

- name: Run PHP-CS-Fixer
run: vendor/bin/php-cs-fixer fix --dry-run
uses: prestashopcorp/github-action-php-cs-fixer@master

phpstan:
name: PHPStan
Expand Down
12 changes: 11 additions & 1 deletion _dev/src/components/help/card-faq.vue
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,7 @@
<b-link
variant="link"
target="_blank"
href="https://prestashop.com/privacy-policy/"
:href="privacyPolicyLink()"
>
{{ $t("help.help.privacyPolicy") }}
</b-link>
Expand Down Expand Up @@ -184,6 +184,16 @@ export default defineComponent({
module: 'ps_facebook',
});
},
privacyPolicyLink() {
const urls = {
fr: 'https://prestashop.fr/politique-confidentialite/',
en: 'https://prestashop.com/privacy-policy/',
};

const currentLocale = this.$i18n.locale;

return urls[currentLocale] || urls.en;
},
},
});
</script>
Expand Down

0 comments on commit 6cd5ef2

Please sign in to comment.