Skip to content

Commit 29a5db5

Browse files
author
Adolfo R. Brandes
authored
Merge pull request #178 from ayrtonlr/master
Change the logo to link to the LMS
2 parents dcc3617 + 7982251 commit 29a5db5

File tree

4 files changed

+10
-4
lines changed

4 files changed

+10
-4
lines changed

README.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@ Environment Variables
2121

2222
This component requires that the following environment variable be set by the consuming micro-frontend.
2323

24+
* ``LMS_BASE_URL`` - The URL of the LMS of your Open edX instance.
2425
* ``LOGO_TRADEMARK_URL`` - This is a URL to a logo for use in the footer. This is a different environment variable than ``LOGO_URL`` (used in frontend-component-header) to accommodate sites that would like to have additional trademark information on a logo in the footer, such as a (tm) or (r) symbol.
2526

2627
************

src/components/Footer.jsx

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ import messages from './Footer.messages';
99
import LanguageSelector from './LanguageSelector';
1010

1111
ensureConfig([
12+
'LMS_BASE_URL',
1213
'LOGO_TRADEMARK_URL',
1314
], 'Footer component');
1415

@@ -58,7 +59,7 @@ class SiteFooter extends React.Component {
5859
<div className="container-fluid d-flex">
5960
<a
6061
className="d-block"
61-
href="https://open.edx.org"
62+
href={config.LMS_BASE_URL}
6263
aria-label={intl.formatMessage(messages['footer.logo.ariaLabel'])}
6364
>
6465
<img

src/components/Footer.test.jsx

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@ describe('<Footer />', () => {
1717
authenticatedUser: null,
1818
config: {
1919
LOGO_TRADEMARK_URL: process.env.LOGO_TRADEMARK_URL,
20+
LMS_BASE_URL: process.env.LMS_BASE_URL,
2021
},
2122
}}
2223
>
@@ -36,6 +37,7 @@ describe('<Footer />', () => {
3637
authenticatedUser: null,
3738
config: {
3839
LOGO_TRADEMARK_URL: process.env.LOGO_TRADEMARK_URL,
40+
LMS_BASE_URL: process.env.LMS_BASE_URL,
3941
},
4042
}}
4143
>
@@ -55,6 +57,7 @@ describe('<Footer />', () => {
5557
authenticatedUser: null,
5658
config: {
5759
LOGO_TRADEMARK_URL: process.env.LOGO_TRADEMARK_URL,
60+
LMS_BASE_URL: process.env.LMS_BASE_URL,
5861
},
5962
}}
6063
>
@@ -83,6 +86,7 @@ describe('<Footer />', () => {
8386
authenticatedUser: null,
8487
config: {
8588
LOGO_TRADEMARK_URL: process.env.LOGO_TRADEMARK_URL,
89+
LMS_BASE_URL: process.env.LMS_BASE_URL,
8690
},
8791
}}
8892
>

src/components/__snapshots__/Footer.test.jsx.snap

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ exports[`<Footer /> renders correctly renders with a language selector 1`] = `
1111
<a
1212
aria-label="edX Home"
1313
className="d-block"
14-
href="https://open.edx.org"
14+
href="http://localhost:18000"
1515
>
1616
<img
1717
alt="Powered by Open edX"
@@ -83,7 +83,7 @@ exports[`<Footer /> renders correctly renders without a language selector 1`] =
8383
<a
8484
aria-label="edX Home"
8585
className="d-block"
86-
href="https://open.edx.org"
86+
href="http://localhost:18000"
8787
>
8888
<img
8989
alt="Powered by Open edX"
@@ -113,7 +113,7 @@ exports[`<Footer /> renders correctly renders without a language selector in es
113113
<a
114114
aria-label="edX Home"
115115
className="d-block"
116-
href="https://open.edx.org"
116+
href="http://localhost:18000"
117117
>
118118
<img
119119
alt="Powered by Open edX"

0 commit comments

Comments
 (0)