Compare commits

...

45 Commits

Author SHA1 Message Date
renovate[bot]
ef8445a1b2 fix(deps): update dependency ts-jest to v29.2.3 2024-07-22 04:08:27 +00:00
renovate[bot]
5b34595520 fix(deps): update dependency ts-jest to v29.2.2 2024-07-15 09:54:25 +00:00
renovate[bot]
32ae2d8e7c chore(deps): update dependency @edx/frontend-platform to v8.1.0 2024-07-15 06:51:47 +00:00
renovate[bot]
abac1cd6d4 chore(deps): update dependency react-router-dom to v6.24.1 2024-07-08 08:29:05 +00:00
renovate[bot]
e0115e3d88 chore(deps): update dependency @openedx/frontend-plugin-framework to v1.2.2 2024-07-08 04:03:54 +00:00
renovate[bot]
ff18f3add9 fix(deps): update dependency ts-jest to v29.1.5 2024-07-01 12:24:59 +00:00
renovate[bot]
4926c3105b chore(deps): update dependency react-router-dom to v6.24.0 2024-07-01 06:05:04 +00:00
renovate[bot]
838a81a020 chore(deps): update dependency @openedx/paragon to v22.6.1 2024-07-01 04:23:27 +00:00
Adolfo R. Brandes
0ac6840cea Merge pull request #437 from arbrandes/update-codecov
build: Update codecov and use token
2024-06-27 09:23:31 -03:00
Adolfo R. Brandes
26a17bf2e4 build: Update codecov and use token
Update codecov to the latest version and start using the org-wide token for uploads.

See https://github.com/openedx/wg-frontend/issues/179
2024-06-27 09:21:08 -03:00
renovate[bot]
17b9710810 chore(deps): update dependency @openedx/frontend-build to v14.0.10 2024-06-24 07:49:38 +00:00
renovate[bot]
df0129485e chore(deps): update dependency @openedx/frontend-build to v14.0.9 2024-06-17 07:25:48 +00:00
renovate[bot]
1c2f290faa chore(deps): update dependency @openedx/paragon to v22.6.0 2024-06-10 04:43:05 +00:00
renovate[bot]
9af9024bcc chore(deps): update dependency @openedx/frontend-plugin-framework to v1.2.1 2024-06-03 09:31:52 +00:00
renovate[bot]
0008bd485a chore(deps): update dependency @edx/frontend-platform to v8.0.4 2024-06-03 07:09:11 +00:00
renovate[bot]
181b9916a0 fix(deps): update dependency ts-jest to v29.1.4 2024-06-03 04:51:17 +00:00
renovate[bot]
22dbec317c fix(deps): update dependency ts-jest to v29.1.3 2024-05-27 11:12:12 +00:00
renovate[bot]
6f15e4dafa fix(deps): update dependency @fortawesome/react-fontawesome to v0.2.2 2024-05-27 07:24:23 +00:00
renovate[bot]
9f5aed3c76 fix(deps): update dependency @fortawesome/react-fontawesome to v0.2.1 2024-05-20 13:16:53 +00:00
renovate[bot]
54bc04b182 chore(deps): update dependency @edx/frontend-platform to v8.0.3 2024-05-20 04:41:57 +00:00
Brian Smith
ea2578fa15 fix!: remove FooterSlot component
BREAKING CHANGE: the `FooterSlot` component will now be provided by `frontend-slot-footer`.
2024-05-14 11:31:03 -03:00
renovate[bot]
5f7fab236d chore(deps): update dependency @openedx/paragon to v22.4.0 2024-05-13 09:24:28 +00:00
renovate[bot]
adf5f6c9a8 chore(deps): update dependency react-router-dom to v6.23.1 2024-05-13 06:20:49 +00:00
renovate[bot]
132b080195 chore(deps): update dependency @edx/frontend-platform to v8.0.2 2024-05-13 04:57:36 +00:00
Brian Smith
0d4ea96874 feat: provide FooterSlot
This allows consuming MFEs to utilize a standardized Frontend
Plugin Framework `PluginSlot` for replacing the footer.
2024-05-09 13:44:51 -03:00
renovate[bot]
8b9f5fa348 chore(deps): update dependency @openedx/paragon to v22.3.2 2024-05-06 06:47:39 +00:00
renovate[bot]
c014e30ca8 chore(deps): update dependency react-router-dom to v6.23.0 2024-04-29 09:52:14 +00:00
renovate[bot]
0e6ab3c358 chore(deps): update dependency @openedx/paragon to v22.3.1 2024-04-29 06:25:16 +00:00
renovate[bot]
7d0a126580 chore(deps): update dependency @edx/frontend-platform to v8.0.1 2024-04-29 04:40:18 +00:00
Bilal Qamar
c422ce40be feat: Updated frontend-build to bump jest version to v29 (#317)
* refactor: updated frontend-build to bump jest version to v29

* refactor: updated snapshots

* refactor: updated frontend-build & failing snapshots

* refactor: updated package-lock

* refactor: updated frontend-build to alpha, updated snapshots

* refactor: added overrides to resolve dependency issues

* refactor: updated frontend-build to the version which has eslint alpha synced with master

* feat: updated frontend-build and frontend-platform major versions

* refactor: updated peerDependency as per suggestion
2024-04-23 13:56:59 +05:00
renovate[bot]
7299d5367f chore(deps): update dependency @openedx/paragon to v22.2.2 2024-04-22 10:02:00 +00:00
renovate[bot]
38203b91ba chore(deps): update dependency @edx/frontend-platform to v7.1.4 2024-04-22 06:32:01 +00:00
renovate[bot]
83c340fe08 chore(deps): update dependency @openedx/paragon to v22.2.1 2024-04-15 13:02:17 +00:00
renovate[bot]
9eaebf4b11 chore(deps): update dependency @openedx/frontend-build to v13.1.4 2024-04-15 09:58:34 +00:00
renovate[bot]
2a883857cf chore(deps): update dependency @edx/brand to v1.2.3 2024-04-15 06:41:52 +00:00
renovate[bot]
5f26c1ae93 fix(deps): update font awesome to v6.5.2 2024-04-15 05:16:19 +00:00
Samir Sabri
89ad7234ac feat!: remove Transifex calls for OEP-58 (#355) 2024-03-25 11:23:10 -04:00
renovate[bot]
936915f81f chore(deps): update dependency @edx/frontend-platform to v7.1.3 2024-03-25 12:10:00 +00:00
Bilal Qamar
b993992987 chore(deps): update frontend-platform to v7 (#409) 2024-03-22 11:34:48 +05:00
Adolfo R. Brandes
64fc8adeed build: start releasing alpha packages 2024-03-20 13:09:22 -03:00
Braden MacDonald
a49b06349e fix: invalid frontend-platform import in Footer.jsx (#398) 2024-03-11 17:28:12 +05:00
Kristin Aoki
aa13b4946c Merge pull request #406 from openedx/KristinAoki/fix-accessibility-page-link-env-variable
fix: variable name for the accessibility link
2024-03-08 17:58:12 -05:00
KristinAoki
cff78e021c fix: variable name for the accessibility link 2024-03-08 09:32:55 -05:00
renovate[bot]
62bf038a06 chore(deps): update dependency react-router-dom to v6.21.3 2024-01-22 09:08:36 +00:00
Brian Smith
eed127969d fix: update paragon dep to support v22 (#400) 2024-01-19 11:30:50 -05:00
31 changed files with 6185 additions and 12410 deletions

View File

@@ -12,7 +12,7 @@ TERMS_OF_SERVICE_URL=null
PRIVACY_POLICY_URL=null
SUPPORT_EMAIL=null
STUDIO_BASE_URL=http://localhost:18010
SHOW_ACCESSIBILITY_PAGE=false
ENABLE_ACCESSIBILITY_PAGE=false
ORDER_HISTORY_URL=localhost:1996/orders
REFRESH_ACCESS_TOKEN_ENDPOINT=http://localhost:18000/login_refresh
SEGMENT_KEY=null

View File

@@ -33,4 +33,7 @@ jobs:
- name: i18n_extract
run: npm run i18n_extract
- name: Coverage
uses: codecov/codecov-action@v3
uses: codecov/codecov-action@v4
with:
token: ${{ secrets.CODECOV_TOKEN }}
fail_ci_if_error: true

View File

@@ -3,6 +3,7 @@ on:
push:
branches:
- master
- alpha
jobs:
release:
name: Release
@@ -29,7 +30,10 @@ jobs:
- name: i18n_extract
run: npm run i18n_extract
- name: Coverage
uses: codecov/codecov-action@v3
uses: codecov/codecov-action@v4
with:
token: ${{ secrets.CODECOV_TOKEN }}
fail_ci_if_error: false
- name: Build
run: npm run build
- name: Release

1
.gitignore vendored
View File

@@ -10,3 +10,4 @@ src/i18n/transifex_input.json
temp/babel-plugin-react-intl
/.vscode
module.config.js
src/i18n/messages

View File

@@ -1,5 +1,8 @@
{
"branch": "master",
"branches": [
"master",
{name: "alpha", prerelease: true}
],
"tagFormat": "v${version}",
"verifyConditions": [
"@semantic-release/npm",

View File

@@ -1,9 +0,0 @@
[main]
host = https://www.transifex.com
[o:open-edx:p:edx-platform:r:frontend-component-footer]
file_filter = src/i18n/messages/<lang>.json
source_file = src/i18n/transifex_input.json
source_lang = en
type = KEYVALUEJSON

View File

@@ -1,6 +1,3 @@
export TRANSIFEX_RESOURCE = frontend-component-footer
transifex_langs = "ar,fr,es_419,zh_CN,pt,it,de,uk,ru,hi,fr_CA,it_IT,pt_PT,de_DE"
transifex_utils = ./node_modules/.bin/transifex-utils.js
i18n = ./src/i18n
transifex_input = $(i18n)/transifex_input.json
@@ -35,20 +32,6 @@ detect_changed_source_translations:
# Checking for changed translations...
git diff --exit-code $(i18n)
# Pushes translations to Transifex. You must run make extract_translations first.
push_translations:
# Pushing strings to Transifex...
tx push -s
# Fetching hashes from Transifex...
./node_modules/@edx/reactifex/bash_scripts/get_hashed_strings_v3.sh
# Writing out comments to file...
$(transifex_utils) $(transifex_temp) --comments --v3-scripts-path
# Pushing comments to Transifex...
./node_modules/@edx/reactifex/bash_scripts/put_comments_v3.sh
# Pulls translations from Transifex.
pull_translations:
tx pull -t -f --mode reviewed --languages=$(transifex_langs)
# This target is used by Travis.
validate-no-uncommitted-package-lock-changes:

View File

@@ -93,6 +93,12 @@ This library has the following exports:
language from its dropdown.
* supportedLanguages: An array of objects representing available languages. See example below for object shape.
Plugin
======
The footer can be replaced using using `Frontend Plugin Framework <https://github.com/openedx/frontend-plugin-framework>`_.
Information on how to utilize the ``FooterSlot`` component to do so is available in the `frontend-slot-footer repository <https://github.com/openedx/frontend-slot-footer/>`_.
Examples
========
@@ -113,6 +119,8 @@ Component Usage Example::
* `An example of minimal component and messages usage. <https://github.com/openedx/frontend-template-application/blob/3355bb3a96232390e9056f35b06ffa8f105ed7ca/src/index.jsx#L23>`_
* `An example of SCSS file usage. <https://github.com/openedx/frontend-template-application/blob/3cd5485bf387b8c479baf6b02bf59e3061dc3465/src/index.scss#L9>`_
Development
===========

18443
package-lock.json generated

File diff suppressed because it is too large Load Diff

View File

@@ -13,7 +13,7 @@
"snapshot": "fedx-scripts jest --updateSnapshot",
"start": "fedx-scripts webpack-dev-server --progress",
"start:with-theme": "paragon install-theme && npm start && npm install",
"test": "fedx-scripts jest"
"test": "fedx-scripts jest --coverage"
},
"files": [
"/dist"
@@ -36,10 +36,11 @@
"devDependencies": {
"@edx/brand": "npm:@openedx/brand-openedx@^1.2.2",
"@edx/browserslist-config": "^1.1.1",
"@openedx/frontend-build": "^13.0.19",
"@openedx/paragon": "21.13.1",
"@edx/frontend-platform": "6.2.0",
"@edx/frontend-platform": "8.1.0",
"@edx/reactifex": "^2.1.1",
"@openedx/frontend-build": "14.0.10",
"@openedx/frontend-plugin-framework": "^1.1.2",
"@openedx/paragon": "22.6.1",
"@testing-library/jest-dom": "^5.16.4",
"@testing-library/react": "^12.1.1",
"husky": "8.0.3",
@@ -47,22 +48,24 @@
"react": "17.0.2",
"react-dom": "17.0.2",
"react-redux": "7.2.9",
"react-router-dom": "6.21.2",
"react-router-dom": "6.24.1",
"react-test-renderer": "17.0.2",
"redux": "4.2.1",
"semantic-release": "21.1.2"
},
"dependencies": {
"@fortawesome/fontawesome-svg-core": "6.5.1",
"@fortawesome/free-brands-svg-icons": "6.5.1",
"@fortawesome/free-regular-svg-icons": "6.5.1",
"@fortawesome/free-solid-svg-icons": "6.5.1",
"@fortawesome/react-fontawesome": "0.2.0",
"lodash": "^4.17.21"
"@fortawesome/fontawesome-svg-core": "6.5.2",
"@fortawesome/free-brands-svg-icons": "6.5.2",
"@fortawesome/free-regular-svg-icons": "6.5.2",
"@fortawesome/free-solid-svg-icons": "6.5.2",
"@fortawesome/react-fontawesome": "0.2.2",
"jest-environment-jsdom": "^29.7.0",
"lodash": "^4.17.21",
"ts-jest": "^29.1.2"
},
"peerDependencies": {
"@edx/frontend-platform": "^7.0.0",
"@openedx/paragon": ">= 21.11.3 < 22.0.0",
"@edx/frontend-platform": "^7.0.0 || ^8.0.0",
"@openedx/paragon": ">= 21.11.3 < 23.0.0",
"prop-types": "^15.5.10",
"react": "^16.9.0 || ^17.0.0",
"react-dom": "^16.9.0 || ^17.0.0"

View File

@@ -2,7 +2,7 @@ import React from 'react';
import PropTypes from 'prop-types';
import { injectIntl, intlShape } from '@edx/frontend-platform/i18n';
import { sendTrackEvent } from '@edx/frontend-platform/analytics';
import { ensureConfig } from '@edx/frontend-platform/config';
import { ensureConfig } from '@edx/frontend-platform';
import { AppContext } from '@edx/frontend-platform/react';
import messages from './Footer.messages';

View File

@@ -17,7 +17,7 @@ exports[`<Footer /> renders correctly renders with a language selector 1`] = `
alt="Powered by Open edX"
src="https://edx-cdn.org/v3/default/logo-trademark.svg"
style={
Object {
{
"maxHeight": 45,
}
}
@@ -86,7 +86,7 @@ exports[`<Footer /> renders correctly renders without a language selector 1`] =
alt="Powered by Open edX"
src="https://edx-cdn.org/v3/default/logo-trademark.svg"
style={
Object {
{
"maxHeight": 45,
}
}
@@ -116,7 +116,7 @@ exports[`<Footer /> renders correctly renders without a language selector in es
alt="Powered by Open edX"
src="https://edx-cdn.org/v3/default/logo-trademark.svg"
style={
Object {
{
"maxHeight": 45,
}
}

View File

@@ -22,7 +22,7 @@ ensureConfig([
'SUPPORT_EMAIL',
'SITE_NAME',
'STUDIO_BASE_URL',
'SHOW_ACCESSIBILITY_PAGE',
'ENABLE_ACCESSIBILITY_PAGE',
], 'Studio Footer component');
const StudioFooter = ({
@@ -105,7 +105,7 @@ const StudioFooter = ({
{intl.formatMessage(messages.privacyPolicyLinkLabel)}
</Hyperlink>
)}
{config.SHOW_ACCESSIBILITY_PAGE === 'true' && (
{config.ENABLE_ACCESSIBILITY_PAGE === 'true' && (
<Hyperlink
destination={`${config.STUDIO_BASE_URL}/accessibility`}
data-testid="accessibilityRequest"

View File

@@ -15,7 +15,7 @@ const config = {
SUPPORT_EMAIL: process.env.SUPPORT_EMAIL,
SITE_NAME: process.env.SITE_NAME,
STUDIO_BASE_URL: process.env.STUDIO_BASE_URL,
SHOW_ACCESSIBILITY_PAGE: process.env.SHOW_ACCESSIBILITY_PAGE,
ENABLE_ACCESSIBILITY_PAGE: process.env.ENABLE_ACCESSIBILITY_PAGE,
};
let currentConfig = config;
@@ -111,7 +111,7 @@ describe('Footer', () => {
expect(screen.queryByTestId('accessibilityRequest')).toBeNull();
});
it('should show accessibilty request link', () => {
render(<Component updateVariable={['SHOW_ACCESSIBILITY_PAGE', 'true']} />);
render(<Component updateVariable={['ENABLE_ACCESSIBILITY_PAGE', 'true']} />);
expect(screen.getByText('LMS')).toBeVisible();
expect(screen.queryByTestId('termsOfService')).toBeNull();
expect(screen.queryByTestId('privacyPolicy')).toBeNull();

View File

@@ -1,34 +1 @@
import arMessages from './messages/ar.json';
import frMessages from './messages/fr.json';
import es419Messages from './messages/es_419.json';
import zhcnMessages from './messages/zh_CN.json';
import ptMessages from './messages/pt.json';
import itMessages from './messages/it.json';
import ukMessages from './messages/uk.json';
import deMessages from './messages/de.json';
import ruMessages from './messages/ru.json';
import hiMessages from './messages/hi.json';
import frCAMessages from './messages/fr_CA.json';
import dedeCAMessages from './messages/de_DE.json';
import ititCAMessages from './messages/it_IT.json';
import ptptCAMessages from './messages/pt_PT.json';
// no need to import en messages-- they are in the defaultMessage field
const messages = {
ar: arMessages,
'es-419': es419Messages,
fr: frMessages,
'zh-cn': zhcnMessages,
pt: ptMessages,
it: itMessages,
de: deMessages,
hi: hiMessages,
'fr-ca': frCAMessages,
ru: ruMessages,
uk: ukMessages,
'de-de': dedeCAMessages,
'it-it': ititCAMessages,
'pt-pt': ptptCAMessages,
};
export default messages;
export default {};

View File

@@ -1 +0,0 @@
{}

View File

@@ -1 +0,0 @@
{}

View File

@@ -1 +0,0 @@
{}

View File

@@ -1 +0,0 @@
{}

View File

@@ -1 +0,0 @@
{}

View File

@@ -1 +0,0 @@
{}

View File

@@ -1 +0,0 @@
{}

View File

@@ -1 +0,0 @@
{}

View File

@@ -1 +0,0 @@
{}

View File

@@ -1 +0,0 @@
{}

View File

@@ -1 +0,0 @@
{}

View File

@@ -1 +0,0 @@
{}

View File

@@ -1 +0,0 @@
{}

View File

@@ -1 +0,0 @@
{}

View File

@@ -3,4 +3,6 @@ import messages from './i18n/index';
import StudioFooter from './components/studio-footer';
export default Footer;
export { messages, EVENT_NAMES, StudioFooter };
export {
messages, EVENT_NAMES, StudioFooter,
};

View File

@@ -19,3 +19,4 @@ process.env.LOGO_URL = 'https://edx-cdn.org/v3/default/logo.svg';
process.env.LOGO_TRADEMARK_URL = 'https://edx-cdn.org/v3/default/logo-trademark.svg';
process.env.LOGO_WHITE_URL = 'https://edx-cdn.org/v3/default/logo-white.svg';
process.env.FAVICON_URL = 'https://edx-cdn.org/v3/default/favicon.ico';
process.env.ENABLE_ACCESSIBILITY_PAGE = 'false';