From 2ed2992d0f220c513933a1f7c4f08b2f93c3a6fe Mon Sep 17 00:00:00 2001 From: Wassaf-Shahzad Date: Wed, 27 Oct 2021 16:17:41 +0500 Subject: [PATCH] fix(packge.json): add MITX info --- .env.development | 1 - package-lock.json | 2 +- package.json | 10 +- src/components/Footer.jsx | 38 ++-- .../__snapshots__/Footer.test.jsx.snap | 162 +++++++++++++++++- src/setupTest.js | 12 ++ 6 files changed, 195 insertions(+), 30 deletions(-) diff --git a/.env.development b/.env.development index 1d3121bf2..c80fc19e6 100644 --- a/.env.development +++ b/.env.development @@ -29,4 +29,3 @@ SITE_URL= LOGO_ALT_TEXT= SHOW_LOGO= SUPPORT_EMAIL= - diff --git a/package-lock.json b/package-lock.json index 296ed2f58..07670a4e7 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,5 +1,5 @@ { - "name": "@edx/frontend-component-footer", + "name": "frontend-component-footer-mitol", "version": "1.0.0-semantically-released", "lockfileVersion": 1, "requires": true, diff --git a/package.json b/package.json index 030c2f097..e1c0fabdd 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { - "name": "@edx/frontend-component-footer", + "name": "frontend-component-footer-mitol", "version": "1.0.0-semantically-released", - "description": "Footer component for use when building Open edX frontend applications", + "description": "Footer component for use when building Open edX frontend applications for MITX", "main": "dist/index.js", "publishConfig": { "access": "public" @@ -25,14 +25,14 @@ }, "repository": { "type": "git", - "url": "git+https://github.com/edx/frontend-component-footer.git" + "url": "git+https://github.com/mitodl/frontend-component-footer-mitol" }, "author": "edX", "license": "AGPL-3.0", "bugs": { - "url": "https://github.com/edx/frontend-component-footer/issues" + "url": "https://github.com/mitodl/frontend-component-footer-mitol/issues" }, - "homepage": "https://github.com/edx/frontend-component-footer#readme", + "homepage": "https://github.com/mitodl/frontend-component-footer-mitol#readme", "devDependencies": { "@commitlint/cli": "13.2.0", "@commitlint/config-angular": "13.2.0", diff --git a/src/components/Footer.jsx b/src/components/Footer.jsx index af242cfa4..7c70e8e15 100644 --- a/src/components/Footer.jsx +++ b/src/components/Footer.jsx @@ -40,8 +40,8 @@ class SiteFooter extends React.Component { sendTrackEvent(eventName, properties); } - renderLinkIfExists(value,text){ - return value &&
  • {text}
  • + renderLinkIfExists(value, text) { + return value &&
  • {text}
  • ; } render() { @@ -59,7 +59,8 @@ class SiteFooter extends React.Component { className="footer d-flex border-top py-3 px-4" >
    - { process.env.SHOW_LOGO && + { process.env.SHOW_LOGO + && ( - } -
    {showLanguageSelector && ( diff --git a/src/components/__snapshots__/Footer.test.jsx.snap b/src/components/__snapshots__/Footer.test.jsx.snap index 7f423261c..80070b0bf 100644 --- a/src/components/__snapshots__/Footer.test.jsx.snap +++ b/src/components/__snapshots__/Footer.test.jsx.snap @@ -11,10 +11,10 @@ exports[`