Compare commits
51 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
cb738286ed | ||
|
|
cd24d0da8d | ||
|
|
2f9f573698 | ||
|
|
563cd4b8df | ||
|
|
25911bdfeb | ||
|
|
179fbaa452 | ||
|
|
73df912f29 | ||
|
|
d64e497407 | ||
|
|
3725a36b30 | ||
|
|
3cd6999886 | ||
|
|
3ff2a0a359 | ||
|
|
5b0f79f6f9 | ||
|
|
d3490985d2 | ||
|
|
82300bf99a | ||
|
|
c096bf3d28 | ||
|
|
ac885e49d7 | ||
|
|
c925666501 | ||
|
|
c3e30e8163 | ||
|
|
d5d2279797 | ||
|
|
8bb03e1404 | ||
|
|
d84ef68648 | ||
|
|
ba9cec39cf | ||
|
|
a13da63d25 | ||
|
|
22dd41f4ee | ||
|
|
f38a03b9ce | ||
|
|
04131d1636 | ||
|
|
2aab012b4d | ||
|
|
9f27335d2b | ||
|
|
cdac04a0d7 | ||
|
|
0b58870714 | ||
|
|
106cba1785 | ||
|
|
820768367f | ||
|
|
18df696902 | ||
|
|
f76383f034 | ||
|
|
f0ddf3bf09 | ||
|
|
11ac45f6b8 | ||
|
|
67c23630b9 | ||
|
|
0ef787b9ce | ||
|
|
c3e3024971 | ||
|
|
a95bf5006b | ||
|
|
517f3f57bf | ||
|
|
2e464498d8 | ||
|
|
3f519aa678 | ||
|
|
5b7a29422b | ||
|
|
f3d9f2ae06 | ||
|
|
b5607e9b83 | ||
|
|
fd9b393bc7 | ||
|
|
0fe5354047 | ||
|
|
71923503c4 | ||
|
|
f1a620a784 | ||
|
|
645f378600 |
5
.env
5
.env
@@ -16,6 +16,7 @@ SITE_NAME=null
|
||||
USER_INFO_COOKIE_NAME=null
|
||||
APPLE_APP_STORE_URL=null
|
||||
CONTACT_URL=null
|
||||
ENTERPRISE_LEARNER_PORTAL_HOSTNAME=null
|
||||
ENTERPRISE_MARKETING_FOOTER_UTM_MEDIUM=null
|
||||
ENTERPRISE_MARKETING_URL=null
|
||||
ENTERPRISE_MARKETING_UTM_CAMPAIGN=null
|
||||
@@ -30,3 +31,7 @@ SUPPORT_URL=null
|
||||
TERMS_OF_SERVICE_URL=null
|
||||
TWITTER_URL=null
|
||||
YOU_TUBE_URL=null
|
||||
LOGO_URL=''
|
||||
LOGO_TRADEMARK_URL=''
|
||||
LOGO_WHITE_URL=''
|
||||
FAVICON_URL=''
|
||||
|
||||
@@ -8,7 +8,7 @@ ECOMMERCE_BASE_URL='http://localhost:18130'
|
||||
LANGUAGE_PREFERENCE_COOKIE_NAME='openedx-language-preference'
|
||||
LMS_BASE_URL='http://localhost:18000'
|
||||
LOGIN_URL='http://localhost:18000/login'
|
||||
LOGOUT_URL='http://localhost:18000/login'
|
||||
LOGOUT_URL='http://localhost:18000/logout'
|
||||
MARKETING_SITE_BASE_URL='http://localhost:18000'
|
||||
ORDER_HISTORY_URL='localhost:1996/orders'
|
||||
REFRESH_ACCESS_TOKEN_ENDPOINT='http://localhost:18000/login_refresh'
|
||||
@@ -17,6 +17,7 @@ SITE_NAME='edX'
|
||||
USER_INFO_COOKIE_NAME='edx-user-info'
|
||||
APPLE_APP_STORE_URL='https://www.apple.com/ios/app-store/'
|
||||
CONTACT_URL='http://localhost:18000/contact'
|
||||
ENTERPRISE_LEARNER_PORTAL_HOSTNAME='http://localhost:8080'
|
||||
ENTERPRISE_MARKETING_FOOTER_UTM_MEDIUM='Footer'
|
||||
ENTERPRISE_MARKETING_URL='http://example.com'
|
||||
ENTERPRISE_MARKETING_UTM_CAMPAIGN='my_campaign'
|
||||
@@ -31,3 +32,7 @@ SUPPORT_URL='http://localhost:18000/support'
|
||||
TERMS_OF_SERVICE_URL='http://localhost:18000/terms-of-service'
|
||||
TWITTER_URL='https://twitter.com'
|
||||
YOU_TUBE_URL='https://www.youtube.com'
|
||||
LOGO_URL=https://edx-cdn.org/v3/default/logo.svg
|
||||
LOGO_TRADEMARK_URL=https://edx-cdn.org/v3/default/logo-trademark.svg
|
||||
LOGO_WHITE_URL=https://edx-cdn.org/v3/default/logo-white.svg
|
||||
FAVICON_URL=https://edx-cdn.org/v3/default/favicon.ico
|
||||
|
||||
@@ -6,10 +6,14 @@ ECOMMERCE_BASE_URL='http://localhost:18130'
|
||||
LANGUAGE_PREFERENCE_COOKIE_NAME='openedx-language-preference'
|
||||
LMS_BASE_URL='http://localhost:18000'
|
||||
LOGIN_URL='http://localhost:18000/login'
|
||||
LOGOUT_URL='http://localhost:18000/login'
|
||||
LOGOUT_URL='http://localhost:18000/logout'
|
||||
MARKETING_SITE_BASE_URL='http://localhost:18000'
|
||||
ORDER_HISTORY_URL='localhost:1996/orders'
|
||||
REFRESH_ACCESS_TOKEN_ENDPOINT='http://localhost:18000/login_refresh'
|
||||
SEGMENT_KEY=null
|
||||
SITE_NAME='edX'
|
||||
USER_INFO_COOKIE_NAME='edx-user-info'
|
||||
LOGO_URL=https://edx-cdn.org/v3/default/logo.svg
|
||||
LOGO_TRADEMARK_URL=https://edx-cdn.org/v3/default/logo-trademark.svg
|
||||
LOGO_WHITE_URL=https://edx-cdn.org/v3/default/logo-white.svg
|
||||
FAVICON_URL=https://edx-cdn.org/v3/default/favicon.ico
|
||||
|
||||
@@ -4,3 +4,4 @@
|
||||
nick: prof
|
||||
oeps: {}
|
||||
owner: edx/arch-team
|
||||
openedx-release: {ref: master}
|
||||
|
||||
14728
package-lock.json
generated
14728
package-lock.json
generated
File diff suppressed because it is too large
Load Diff
28
package.json
Executable file → Normal file
28
package.json
Executable file → Normal file
@@ -40,15 +40,15 @@
|
||||
"ie 11"
|
||||
],
|
||||
"dependencies": {
|
||||
"@edx/frontend-component-footer": "^10.0.0",
|
||||
"@edx/frontend-component-header": "^2.0.0",
|
||||
"@edx/frontend-platform": "^1.0.0",
|
||||
"@edx/frontend-component-footer": "10.1.1",
|
||||
"@edx/frontend-component-header": "2.2.1",
|
||||
"@edx/frontend-platform": "1.8.0",
|
||||
"@edx/paragon": "7.1.3",
|
||||
"@fortawesome/fontawesome-svg-core": "1.2.25",
|
||||
"@fortawesome/free-brands-svg-icons": "5.7.2",
|
||||
"@fortawesome/free-regular-svg-icons": "5.7.2",
|
||||
"@fortawesome/free-solid-svg-icons": "5.7.2",
|
||||
"@fortawesome/react-fontawesome": "0.1.7",
|
||||
"@fortawesome/react-fontawesome": "0.1.8",
|
||||
"babel-polyfill": "6.26.0",
|
||||
"classnames": "2.2.6",
|
||||
"email-prop-type": "1.1.7",
|
||||
@@ -65,10 +65,10 @@
|
||||
"react": "16.9.0",
|
||||
"react-dom": "16.9.0",
|
||||
"react-redux": "7.1.3",
|
||||
"react-router": "5.0.1",
|
||||
"react-router-dom": "5.0.1",
|
||||
"react-router": "5.1.2",
|
||||
"react-router-dom": "5.1.2",
|
||||
"react-transition-group": "4.3.0",
|
||||
"redux": "4.0.4",
|
||||
"redux": "4.0.5",
|
||||
"redux-devtools-extension": "2.13.8",
|
||||
"redux-logger": "3.0.6",
|
||||
"redux-saga": "1.0.5",
|
||||
@@ -79,18 +79,16 @@
|
||||
"devDependencies": {
|
||||
"@commitlint/cli": "8.2.0",
|
||||
"@commitlint/config-angular": "8.2.0",
|
||||
"@commitlint/prompt": "8.2.0",
|
||||
"@commitlint/prompt-cli": "8.2.0",
|
||||
"@edx/frontend-build": "2.0.2",
|
||||
"codecov": "3.1.0",
|
||||
"@edx/frontend-build": "5.3.2",
|
||||
"codecov": "3.7.2",
|
||||
"enzyme": "3.10.0",
|
||||
"enzyme-adapter-react-16": "1.14.0",
|
||||
"enzyme-adapter-react-16": "1.15.4",
|
||||
"es-check": "5.0.0",
|
||||
"glob": "7.1.3",
|
||||
"husky": "3.0.9",
|
||||
"glob": "7.1.6",
|
||||
"husky": "3.1.0",
|
||||
"purgecss-webpack-plugin": "1.6.0",
|
||||
"react-test-renderer": "16.9.0",
|
||||
"reactifex": "1.1.1",
|
||||
"redux-mock-store": "1.5.3"
|
||||
"redux-mock-store": "1.5.4"
|
||||
}
|
||||
}
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<link rel="preconnect" href="https://fonts.gstatic.com/" crossorigin>
|
||||
<link href="https://fonts.googleapis.com/css?family=Roboto:400,500,700" rel="stylesheet">
|
||||
<link rel="shortcut icon" href="/favicon.ico" type="image/x-icon" />
|
||||
<link rel="shortcut icon" href="<%=webpackConfig.output.publicPath%>favicon.ico" type="image/x-icon" />
|
||||
</head>
|
||||
<body>
|
||||
<div id="root"></div>
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { getConfig } from '@edx/frontend-platform/config';
|
||||
import { getConfig } from '@edx/frontend-platform';
|
||||
import { applyMiddleware, createStore, compose } from 'redux';
|
||||
import thunkMiddleware from 'redux-thunk';
|
||||
import { composeWithDevTools } from 'redux-devtools-extension';
|
||||
|
||||
@@ -1 +1,51 @@
|
||||
{}
|
||||
{
|
||||
"profile.age.headline": "Your profile cannot be shared.",
|
||||
"profile.age.details": "To share your profile with other edX learners, you must confirm that you are over the age of 13.",
|
||||
"profile.age.set.date": "Set your date of birth",
|
||||
"profile.datejoined.member.since": "Member since {year}",
|
||||
"profile.bio.empty": "Add a short bio",
|
||||
"profile.bio.about.me": "About Me",
|
||||
"profile.certificate.organization.label": "From",
|
||||
"profile.certificate.completion.date.label": "Completed on {date}",
|
||||
"profile.no.certificates": "You don't have any certificates yet.",
|
||||
"profile.certificates.my.certificates": "My Certificates",
|
||||
"profile.certificates.view.certificate": "View Certificate",
|
||||
"profile.certificates.types.verified": "Verified Certificate",
|
||||
"profile.certificates.types.professional": "Professional Certificate",
|
||||
"profile.certificates.types.unknown": "Certificate",
|
||||
"profile.country.label": "Location",
|
||||
"profile.country.empty": "Add location",
|
||||
"profile.education.empty": "Add education",
|
||||
"profile.education.education": "Education",
|
||||
"profile.education.levels.p": "Doctorate",
|
||||
"profile.education.levels.m": "Master's or professional degree",
|
||||
"profile.education.levels.b": "Bachelor's Degree",
|
||||
"profile.education.levels.a": "Associate's degree",
|
||||
"profile.education.levels.hs": "Secondary/high school",
|
||||
"profile.education.levels.jhs": "Junior secondary/junior high/middle school",
|
||||
"profile.education.levels.el": "Elementary/primary school",
|
||||
"profile.education.levels.none": "No formal education",
|
||||
"profile.education.levels.o": "Other education",
|
||||
"profile.editbutton.edit": "Edit",
|
||||
"profile.formcontrols.who.can.see": "Who can see this:",
|
||||
"profile.formcontrols.button.cancel": "Cancel",
|
||||
"profile.formcontrols.button.save": "Save",
|
||||
"profile.formcontrols.button.saving": "Saving",
|
||||
"profile.formcontrols.button.saved": "Saved",
|
||||
"profile.visibility.who.just.me": "Just me",
|
||||
"profile.visibility.who.everyone": "Everyone on edX",
|
||||
"profile.name.full.name": "Full Name",
|
||||
"profile.name.details": "This is the name that appears in your account and on your certificates.",
|
||||
"profile.name.empty": "Add name",
|
||||
"profile.preferredlanguage.empty": "Add language",
|
||||
"profile.preferredlanguage.label": "Primary Language Spoken",
|
||||
"profile.profileavatar.upload-button": "Upload Photo",
|
||||
"profile.profileavatar.remove.button": "Remove",
|
||||
"profile.image.alt.attribute": "profile avatar",
|
||||
"profile.profileavatar.change-button": "Change",
|
||||
"profile.sociallinks.add": "Add {network}",
|
||||
"profile.sociallinks.social.links": "Social Links",
|
||||
"profile.notfound.message": "The page you're looking for is unavailable or there's an error in the URL. Please check the URL and try again.",
|
||||
"profile.viewMyRecords": "View My Records",
|
||||
"profile.loading": "Profile loading..."
|
||||
}
|
||||
@@ -1 +1,51 @@
|
||||
{}
|
||||
{
|
||||
"profile.age.headline": "Tu perfil no puede ser compartido.",
|
||||
"profile.age.details": "Para compartir tu perfil con otros estudiantes de edX, debes confirmar que tienes más de 13 años.",
|
||||
"profile.age.set.date": "Establece tu fecha de nacimiento",
|
||||
"profile.datejoined.member.since": "Miembro desde {year}",
|
||||
"profile.bio.empty": "Añade una breve biografía",
|
||||
"profile.bio.about.me": "Sobre Mí",
|
||||
"profile.certificate.organization.label": "Desde",
|
||||
"profile.certificate.completion.date.label": "Completado el {date}",
|
||||
"profile.no.certificates": "Todavía no ha obtenido ningún certificado.",
|
||||
"profile.certificates.my.certificates": "Mis Certificados",
|
||||
"profile.certificates.view.certificate": "Ver Certificado",
|
||||
"profile.certificates.types.verified": "Certificado verificado",
|
||||
"profile.certificates.types.professional": "Certificado profesional",
|
||||
"profile.certificates.types.unknown": "Certificado",
|
||||
"profile.country.label": "Ubicación",
|
||||
"profile.country.empty": "Añade ubicación",
|
||||
"profile.education.empty": "Añade Educación",
|
||||
"profile.education.education": "Educación",
|
||||
"profile.education.levels.p": "Doctorado",
|
||||
"profile.education.levels.m": "Master o magíster",
|
||||
"profile.education.levels.b": "Pregrado o Licenciatura",
|
||||
"profile.education.levels.a": "Grado técnico - tecnológico",
|
||||
"profile.education.levels.hs": "Enseñanza secundaria",
|
||||
"profile.education.levels.jhs": "Formación media",
|
||||
"profile.education.levels.el": "Enseñanza primaria",
|
||||
"profile.education.levels.none": "Ninguna educación formal",
|
||||
"profile.education.levels.o": "Otra educación",
|
||||
"profile.editbutton.edit": "Editar",
|
||||
"profile.formcontrols.who.can.see": "Quién puede ver esto:",
|
||||
"profile.formcontrols.button.cancel": "Cancelar",
|
||||
"profile.formcontrols.button.save": "Guardar",
|
||||
"profile.formcontrols.button.saving": "Guardando",
|
||||
"profile.formcontrols.button.saved": "Guardado",
|
||||
"profile.visibility.who.just.me": "Solo yo",
|
||||
"profile.visibility.who.everyone": "Todos en edX",
|
||||
"profile.name.full.name": "Nombre completo",
|
||||
"profile.name.details": "Este es el nombre que aparecerá en tu cuenta y en tus certificados.",
|
||||
"profile.name.empty": "Añade nombre",
|
||||
"profile.preferredlanguage.empty": "Añadir idioma",
|
||||
"profile.preferredlanguage.label": "Idioma principal que hablas",
|
||||
"profile.profileavatar.upload-button": "Subir foto",
|
||||
"profile.profileavatar.remove.button": "Eliminar",
|
||||
"profile.image.alt.attribute": "avatar del perfil",
|
||||
"profile.profileavatar.change-button": "Cambiar",
|
||||
"profile.sociallinks.add": "Añade {network}",
|
||||
"profile.sociallinks.social.links": "Enlaces De Redes Sociales",
|
||||
"profile.notfound.message": "La página que estas buscando no está disponible o hay un error en la URL. Por favor, comprueba la URL y vuelve a intentarlo.",
|
||||
"profile.viewMyRecords": "Ver mis registros",
|
||||
"profile.loading": "Cargando perfil..."
|
||||
}
|
||||
@@ -1 +1,51 @@
|
||||
{}
|
||||
{
|
||||
"profile.age.headline": "Your profile cannot be shared.",
|
||||
"profile.age.details": "To share your profile with other edX learners, you must confirm that you are over the age of 13.",
|
||||
"profile.age.set.date": "Set your date of birth",
|
||||
"profile.datejoined.member.since": "Member since {year}",
|
||||
"profile.bio.empty": "Add a short bio",
|
||||
"profile.bio.about.me": "About Me",
|
||||
"profile.certificate.organization.label": "From",
|
||||
"profile.certificate.completion.date.label": "Completed on {date}",
|
||||
"profile.no.certificates": "You don't have any certificates yet.",
|
||||
"profile.certificates.my.certificates": "My Certificates",
|
||||
"profile.certificates.view.certificate": "View Certificate",
|
||||
"profile.certificates.types.verified": "Verified Certificate",
|
||||
"profile.certificates.types.professional": "Professional Certificate",
|
||||
"profile.certificates.types.unknown": "Certificate",
|
||||
"profile.country.label": "Location",
|
||||
"profile.country.empty": "Add location",
|
||||
"profile.education.empty": "Add education",
|
||||
"profile.education.education": "Education",
|
||||
"profile.education.levels.p": "Doctorate",
|
||||
"profile.education.levels.m": "Master's or professional degree",
|
||||
"profile.education.levels.b": "Bachelor's Degree",
|
||||
"profile.education.levels.a": "Associate's degree",
|
||||
"profile.education.levels.hs": "Secondary/high school",
|
||||
"profile.education.levels.jhs": "Junior secondary/junior high/middle school",
|
||||
"profile.education.levels.el": "Elementary/primary school",
|
||||
"profile.education.levels.none": "No formal education",
|
||||
"profile.education.levels.o": "Other education",
|
||||
"profile.editbutton.edit": "Edit",
|
||||
"profile.formcontrols.who.can.see": "Who can see this:",
|
||||
"profile.formcontrols.button.cancel": "Cancel",
|
||||
"profile.formcontrols.button.save": "Save",
|
||||
"profile.formcontrols.button.saving": "Saving",
|
||||
"profile.formcontrols.button.saved": "Saved",
|
||||
"profile.visibility.who.just.me": "Just me",
|
||||
"profile.visibility.who.everyone": "Everyone on edX",
|
||||
"profile.name.full.name": "Full Name",
|
||||
"profile.name.details": "This is the name that appears in your account and on your certificates.",
|
||||
"profile.name.empty": "Add name",
|
||||
"profile.preferredlanguage.empty": "Add language",
|
||||
"profile.preferredlanguage.label": "Primary Language Spoken",
|
||||
"profile.profileavatar.upload-button": "Upload Photo",
|
||||
"profile.profileavatar.remove.button": "Remove",
|
||||
"profile.image.alt.attribute": "profile avatar",
|
||||
"profile.profileavatar.change-button": "Change",
|
||||
"profile.sociallinks.add": "Add {network}",
|
||||
"profile.sociallinks.social.links": "Social Links",
|
||||
"profile.notfound.message": "The page you're looking for is unavailable or there's an error in the URL. Please check the URL and try again.",
|
||||
"profile.viewMyRecords": "View My Records",
|
||||
"profile.loading": "Profile loading..."
|
||||
}
|
||||
@@ -1 +1,51 @@
|
||||
{}
|
||||
{
|
||||
"profile.age.headline": "Your profile cannot be shared.",
|
||||
"profile.age.details": "To share your profile with other edX learners, you must confirm that you are over the age of 13.",
|
||||
"profile.age.set.date": "Set your date of birth",
|
||||
"profile.datejoined.member.since": "Member since {year}",
|
||||
"profile.bio.empty": "Add a short bio",
|
||||
"profile.bio.about.me": "About Me",
|
||||
"profile.certificate.organization.label": "From",
|
||||
"profile.certificate.completion.date.label": "Completed on {date}",
|
||||
"profile.no.certificates": "You don't have any certificates yet.",
|
||||
"profile.certificates.my.certificates": "My Certificates",
|
||||
"profile.certificates.view.certificate": "View Certificate",
|
||||
"profile.certificates.types.verified": "Verified Certificate",
|
||||
"profile.certificates.types.professional": "Professional Certificate",
|
||||
"profile.certificates.types.unknown": "Certificate",
|
||||
"profile.country.label": "Location",
|
||||
"profile.country.empty": "Add location",
|
||||
"profile.education.empty": "Add education",
|
||||
"profile.education.education": "Education",
|
||||
"profile.education.levels.p": "Doctorate",
|
||||
"profile.education.levels.m": "Master's or professional degree",
|
||||
"profile.education.levels.b": "Bachelor's Degree",
|
||||
"profile.education.levels.a": "Associate's degree",
|
||||
"profile.education.levels.hs": "Secondary/high school",
|
||||
"profile.education.levels.jhs": "Junior secondary/junior high/middle school",
|
||||
"profile.education.levels.el": "Elementary/primary school",
|
||||
"profile.education.levels.none": "No formal education",
|
||||
"profile.education.levels.o": "Other education",
|
||||
"profile.editbutton.edit": "Edit",
|
||||
"profile.formcontrols.who.can.see": "Who can see this:",
|
||||
"profile.formcontrols.button.cancel": "Cancel",
|
||||
"profile.formcontrols.button.save": "Save",
|
||||
"profile.formcontrols.button.saving": "Saving",
|
||||
"profile.formcontrols.button.saved": "Saved",
|
||||
"profile.visibility.who.just.me": "Just me",
|
||||
"profile.visibility.who.everyone": "Everyone on edX",
|
||||
"profile.name.full.name": "Full Name",
|
||||
"profile.name.details": "This is the name that appears in your account and on your certificates.",
|
||||
"profile.name.empty": "Add name",
|
||||
"profile.preferredlanguage.empty": "Add language",
|
||||
"profile.preferredlanguage.label": "Primary Language Spoken",
|
||||
"profile.profileavatar.upload-button": "Upload Photo",
|
||||
"profile.profileavatar.remove.button": "Remove",
|
||||
"profile.image.alt.attribute": "profile avatar",
|
||||
"profile.profileavatar.change-button": "Change",
|
||||
"profile.sociallinks.add": "Add {network}",
|
||||
"profile.sociallinks.social.links": "Social Links",
|
||||
"profile.notfound.message": "The page you're looking for is unavailable or there's an error in the URL. Please check the URL and try again.",
|
||||
"profile.viewMyRecords": "View My Records",
|
||||
"profile.loading": "Profile loading..."
|
||||
}
|
||||
@@ -1,8 +1,7 @@
|
||||
import 'babel-polyfill';
|
||||
|
||||
import { APP_INIT_ERROR, APP_READY, initialize, subscribe } from '@edx/frontend-platform';
|
||||
import { AppProvider, ErrorPage } from '@edx/frontend-platform/react';
|
||||
import { APP_INIT_ERROR, APP_READY, initialize } from '@edx/frontend-platform/init';
|
||||
import { subscribe } from '@edx/frontend-platform/pubSub';
|
||||
|
||||
import React from 'react';
|
||||
import ReactDOM from 'react-dom';
|
||||
|
||||
@@ -3,7 +3,7 @@ import PropTypes from 'prop-types';
|
||||
import { connect } from 'react-redux';
|
||||
|
||||
import { sendTrackingLogEvent } 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 { injectIntl, intlShape } from '@edx/frontend-platform/i18n';
|
||||
import { StatusAlert, Hyperlink } from '@edx/paragon';
|
||||
@@ -112,9 +112,11 @@ class ProfilePage extends React.Component {
|
||||
|
||||
return (
|
||||
<React.Fragment>
|
||||
<h1 className="h2 mb-0 font-weight-bold">{this.props.match.params.username}</h1>
|
||||
<DateJoined date={dateJoined} />
|
||||
<hr className="d-none d-md-block" />
|
||||
<span data-hj-suppress>
|
||||
<h1 className="h2 mb-0 font-weight-bold">{this.props.match.params.username}</h1>
|
||||
<DateJoined date={dateJoined} />
|
||||
<hr className="d-none d-md-block" />
|
||||
</span>
|
||||
</React.Fragment>
|
||||
);
|
||||
}
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
/* eslint-disable global-require */
|
||||
import { getConfig } from '@edx/frontend-platform';
|
||||
import * as analytics from '@edx/frontend-platform/analytics';
|
||||
import { AppContext } from '@edx/frontend-platform/react';
|
||||
import { getConfig } from '@edx/frontend-platform/config';
|
||||
import { configure as configureI18n, IntlProvider } from '@edx/frontend-platform/i18n';
|
||||
import { mount } from 'enzyme';
|
||||
import React from 'react';
|
||||
@@ -37,7 +37,7 @@ Object.defineProperty(global.document, 'cookie', {
|
||||
value: `${getConfig().LANGUAGE_PREFERENCE_COOKIE_NAME}=en`,
|
||||
});
|
||||
|
||||
jest.mock('@edx/frontend-platform/src/auth', () => ({
|
||||
jest.mock('@edx/frontend-platform/auth', () => ({
|
||||
configure: () => {},
|
||||
getAuthenticatedUser: () => null,
|
||||
fetchAuthenticatedUser: () => null,
|
||||
@@ -45,7 +45,7 @@ jest.mock('@edx/frontend-platform/src/auth', () => ({
|
||||
AUTHENTICATED_USER_CHANGED: 'user_changed',
|
||||
}));
|
||||
|
||||
jest.mock('@edx/frontend-platform/src/analytics', () => ({
|
||||
jest.mock('@edx/frontend-platform/analytics', () => ({
|
||||
configure: () => {},
|
||||
identifyAnonymousUser: jest.fn(),
|
||||
identifyAuthenticatedUser: jest.fn(),
|
||||
@@ -54,11 +54,9 @@ jest.mock('@edx/frontend-platform/src/analytics', () => ({
|
||||
|
||||
configureI18n({
|
||||
loggingService: { logError: jest.fn() },
|
||||
configService: {
|
||||
getConfig: () => ({
|
||||
ENVIRONMENT: 'production',
|
||||
LANGUAGE_PREFERENCE_COOKIE_NAME: 'yum',
|
||||
}),
|
||||
config: {
|
||||
ENVIRONMENT: 'production',
|
||||
LANGUAGE_PREFERENCE_COOKIE_NAME: 'yum',
|
||||
},
|
||||
messages,
|
||||
});
|
||||
|
||||
@@ -86,24 +86,28 @@ exports[`<ProfilePage /> Renders correctly in various states viewing other profi
|
||||
<div
|
||||
className="d-md-none"
|
||||
>
|
||||
<h1
|
||||
className="h2 mb-0 font-weight-bold"
|
||||
<span
|
||||
data-hj-suppress={true}
|
||||
>
|
||||
verified
|
||||
</h1>
|
||||
<p
|
||||
className="mb-0"
|
||||
>
|
||||
<span>
|
||||
Member since
|
||||
<h1
|
||||
className="h2 mb-0 font-weight-bold"
|
||||
>
|
||||
verified
|
||||
</h1>
|
||||
<p
|
||||
className="mb-0"
|
||||
>
|
||||
<span>
|
||||
2017
|
||||
Member since
|
||||
<span>
|
||||
2017
|
||||
</span>
|
||||
</span>
|
||||
</span>
|
||||
</p>
|
||||
<hr
|
||||
className="d-none d-md-block"
|
||||
/>
|
||||
</p>
|
||||
<hr
|
||||
className="d-none d-md-block"
|
||||
/>
|
||||
</span>
|
||||
</div>
|
||||
<div
|
||||
className="d-none d-md-block float-right"
|
||||
@@ -119,24 +123,28 @@ exports[`<ProfilePage /> Renders correctly in various states viewing other profi
|
||||
<div
|
||||
className="d-none d-md-block mb-4"
|
||||
>
|
||||
<h1
|
||||
className="h2 mb-0 font-weight-bold"
|
||||
<span
|
||||
data-hj-suppress={true}
|
||||
>
|
||||
verified
|
||||
</h1>
|
||||
<p
|
||||
className="mb-0"
|
||||
>
|
||||
<span>
|
||||
Member since
|
||||
<h1
|
||||
className="h2 mb-0 font-weight-bold"
|
||||
>
|
||||
verified
|
||||
</h1>
|
||||
<p
|
||||
className="mb-0"
|
||||
>
|
||||
<span>
|
||||
2017
|
||||
Member since
|
||||
<span>
|
||||
2017
|
||||
</span>
|
||||
</span>
|
||||
</span>
|
||||
</p>
|
||||
<hr
|
||||
className="d-none d-md-block"
|
||||
/>
|
||||
</p>
|
||||
<hr
|
||||
className="d-none d-md-block"
|
||||
/>
|
||||
</span>
|
||||
</div>
|
||||
<div
|
||||
className="d-md-none mb-4"
|
||||
@@ -277,6 +285,7 @@ exports[`<ProfilePage /> Renders correctly in various states viewing own profile
|
||||
<img
|
||||
alt="profile avatar"
|
||||
className="w-100 h-100 d-block rounded-circle overflow-hidden"
|
||||
data-hj-suppress={true}
|
||||
src="http://localhost:18000/media/profile-images/d2a9bdc2ba165dcefc73265c54bf9a20_500.jpg?v=1552495012"
|
||||
style={
|
||||
Object {
|
||||
@@ -307,24 +316,28 @@ exports[`<ProfilePage /> Renders correctly in various states viewing own profile
|
||||
<div
|
||||
className="d-md-none"
|
||||
>
|
||||
<h1
|
||||
className="h2 mb-0 font-weight-bold"
|
||||
<span
|
||||
data-hj-suppress={true}
|
||||
>
|
||||
staff
|
||||
</h1>
|
||||
<p
|
||||
className="mb-0"
|
||||
>
|
||||
<span>
|
||||
Member since
|
||||
<h1
|
||||
className="h2 mb-0 font-weight-bold"
|
||||
>
|
||||
staff
|
||||
</h1>
|
||||
<p
|
||||
className="mb-0"
|
||||
>
|
||||
<span>
|
||||
2017
|
||||
Member since
|
||||
<span>
|
||||
2017
|
||||
</span>
|
||||
</span>
|
||||
</span>
|
||||
</p>
|
||||
<hr
|
||||
className="d-none d-md-block"
|
||||
/>
|
||||
</p>
|
||||
<hr
|
||||
className="d-none d-md-block"
|
||||
/>
|
||||
</span>
|
||||
</div>
|
||||
<div
|
||||
className="d-none d-md-block float-right"
|
||||
@@ -359,24 +372,28 @@ exports[`<ProfilePage /> Renders correctly in various states viewing own profile
|
||||
<div
|
||||
className="d-none d-md-block mb-4"
|
||||
>
|
||||
<h1
|
||||
className="h2 mb-0 font-weight-bold"
|
||||
<span
|
||||
data-hj-suppress={true}
|
||||
>
|
||||
staff
|
||||
</h1>
|
||||
<p
|
||||
className="mb-0"
|
||||
>
|
||||
<span>
|
||||
Member since
|
||||
<h1
|
||||
className="h2 mb-0 font-weight-bold"
|
||||
>
|
||||
staff
|
||||
</h1>
|
||||
<p
|
||||
className="mb-0"
|
||||
>
|
||||
<span>
|
||||
2017
|
||||
Member since
|
||||
<span>
|
||||
2017
|
||||
</span>
|
||||
</span>
|
||||
</span>
|
||||
</p>
|
||||
<hr
|
||||
className="d-none d-md-block"
|
||||
/>
|
||||
</p>
|
||||
<hr
|
||||
className="d-none d-md-block"
|
||||
/>
|
||||
</span>
|
||||
</div>
|
||||
<div
|
||||
className="d-md-none mb-4"
|
||||
@@ -485,6 +502,7 @@ exports[`<ProfilePage /> Renders correctly in various states viewing own profile
|
||||
</div>
|
||||
<p
|
||||
className="h5"
|
||||
data-hj-suppress={true}
|
||||
>
|
||||
Lemon Seltzer
|
||||
</p>
|
||||
@@ -580,6 +598,7 @@ exports[`<ProfilePage /> Renders correctly in various states viewing own profile
|
||||
</div>
|
||||
<p
|
||||
className="h5"
|
||||
data-hj-suppress={true}
|
||||
>
|
||||
Montenegro
|
||||
</p>
|
||||
@@ -670,6 +689,7 @@ exports[`<ProfilePage /> Renders correctly in various states viewing own profile
|
||||
</div>
|
||||
<p
|
||||
className="h5"
|
||||
data-hj-suppress={true}
|
||||
>
|
||||
Yoruba
|
||||
</p>
|
||||
@@ -760,6 +780,7 @@ exports[`<ProfilePage /> Renders correctly in various states viewing own profile
|
||||
</div>
|
||||
<p
|
||||
className="h5"
|
||||
data-hj-suppress={true}
|
||||
>
|
||||
Elementary/primary school
|
||||
</p>
|
||||
@@ -1029,6 +1050,7 @@ exports[`<ProfilePage /> Renders correctly in various states viewing own profile
|
||||
</div>
|
||||
<p
|
||||
className="lead"
|
||||
data-hj-suppress={true}
|
||||
>
|
||||
This is my bio
|
||||
</p>
|
||||
@@ -1278,6 +1300,7 @@ exports[`<ProfilePage /> Renders correctly in various states while saving an edi
|
||||
<img
|
||||
alt="profile avatar"
|
||||
className="w-100 h-100 d-block rounded-circle overflow-hidden"
|
||||
data-hj-suppress={true}
|
||||
src="http://localhost:18000/media/profile-images/d2a9bdc2ba165dcefc73265c54bf9a20_500.jpg?v=1552495012"
|
||||
style={
|
||||
Object {
|
||||
@@ -1308,24 +1331,28 @@ exports[`<ProfilePage /> Renders correctly in various states while saving an edi
|
||||
<div
|
||||
className="d-md-none"
|
||||
>
|
||||
<h1
|
||||
className="h2 mb-0 font-weight-bold"
|
||||
<span
|
||||
data-hj-suppress={true}
|
||||
>
|
||||
staff
|
||||
</h1>
|
||||
<p
|
||||
className="mb-0"
|
||||
>
|
||||
<span>
|
||||
Member since
|
||||
<h1
|
||||
className="h2 mb-0 font-weight-bold"
|
||||
>
|
||||
staff
|
||||
</h1>
|
||||
<p
|
||||
className="mb-0"
|
||||
>
|
||||
<span>
|
||||
2017
|
||||
Member since
|
||||
<span>
|
||||
2017
|
||||
</span>
|
||||
</span>
|
||||
</span>
|
||||
</p>
|
||||
<hr
|
||||
className="d-none d-md-block"
|
||||
/>
|
||||
</p>
|
||||
<hr
|
||||
className="d-none d-md-block"
|
||||
/>
|
||||
</span>
|
||||
</div>
|
||||
<div
|
||||
className="d-none d-md-block float-right"
|
||||
@@ -1360,24 +1387,28 @@ exports[`<ProfilePage /> Renders correctly in various states while saving an edi
|
||||
<div
|
||||
className="d-none d-md-block mb-4"
|
||||
>
|
||||
<h1
|
||||
className="h2 mb-0 font-weight-bold"
|
||||
<span
|
||||
data-hj-suppress={true}
|
||||
>
|
||||
staff
|
||||
</h1>
|
||||
<p
|
||||
className="mb-0"
|
||||
>
|
||||
<span>
|
||||
Member since
|
||||
<h1
|
||||
className="h2 mb-0 font-weight-bold"
|
||||
>
|
||||
staff
|
||||
</h1>
|
||||
<p
|
||||
className="mb-0"
|
||||
>
|
||||
<span>
|
||||
2017
|
||||
Member since
|
||||
<span>
|
||||
2017
|
||||
</span>
|
||||
</span>
|
||||
</span>
|
||||
</p>
|
||||
<hr
|
||||
className="d-none d-md-block"
|
||||
/>
|
||||
</p>
|
||||
<hr
|
||||
className="d-none d-md-block"
|
||||
/>
|
||||
</span>
|
||||
</div>
|
||||
<div
|
||||
className="d-md-none mb-4"
|
||||
@@ -1486,6 +1517,7 @@ exports[`<ProfilePage /> Renders correctly in various states while saving an edi
|
||||
</div>
|
||||
<p
|
||||
className="h5"
|
||||
data-hj-suppress={true}
|
||||
>
|
||||
Lemon Seltzer
|
||||
</p>
|
||||
@@ -1581,6 +1613,7 @@ exports[`<ProfilePage /> Renders correctly in various states while saving an edi
|
||||
</div>
|
||||
<p
|
||||
className="h5"
|
||||
data-hj-suppress={true}
|
||||
>
|
||||
Montenegro
|
||||
</p>
|
||||
@@ -1671,6 +1704,7 @@ exports[`<ProfilePage /> Renders correctly in various states while saving an edi
|
||||
</div>
|
||||
<p
|
||||
className="h5"
|
||||
data-hj-suppress={true}
|
||||
>
|
||||
Yoruba
|
||||
</p>
|
||||
@@ -1761,6 +1795,7 @@ exports[`<ProfilePage /> Renders correctly in various states while saving an edi
|
||||
</div>
|
||||
<p
|
||||
className="h5"
|
||||
data-hj-suppress={true}
|
||||
>
|
||||
Elementary/primary school
|
||||
</p>
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { history } from '@edx/frontend-platform/init';
|
||||
import { history } from '@edx/frontend-platform';
|
||||
import { getAuthenticatedUser } from '@edx/frontend-platform/auth';
|
||||
import pick from 'lodash.pick';
|
||||
import { all, call, delay, put, select, takeEvery } from 'redux-saga/effects';
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
import { ensureConfig, getConfig } from '@edx/frontend-platform/config';
|
||||
|
||||
import { logError } from '@edx/frontend-platform/logging';
|
||||
import { ensureConfig, getConfig } from '@edx/frontend-platform';
|
||||
import { getAuthenticatedHttpClient as getHttpClient } from '@edx/frontend-platform/auth';
|
||||
import { logError } from '@edx/frontend-platform/logging';
|
||||
import { camelCaseObject, convertKeyNames, snakeCaseObject } from '../utils';
|
||||
|
||||
ensureConfig(['LMS_BASE_URL'], 'Profile API service');
|
||||
|
||||
@@ -91,7 +91,7 @@ class Bio extends React.Component {
|
||||
showVisibility={visibilityBio !== null}
|
||||
visibility={visibilityBio}
|
||||
/>
|
||||
<p className="lead">{bio}</p>
|
||||
<p data-hj-suppress className="lead">{bio}</p>
|
||||
</React.Fragment>
|
||||
),
|
||||
empty: (
|
||||
@@ -109,7 +109,7 @@ class Bio extends React.Component {
|
||||
static: (
|
||||
<React.Fragment>
|
||||
<EditableItemHeader content={intl.formatMessage(messages['profile.bio.about.me'])} />
|
||||
<p className="lead">{bio}</p>
|
||||
<p data-hj-suppress className="lead">{bio}</p>
|
||||
</React.Fragment>
|
||||
),
|
||||
}}
|
||||
|
||||
@@ -76,6 +76,7 @@ class Country extends React.Component {
|
||||
{intl.formatMessage(messages['profile.country.label'])}
|
||||
</label>
|
||||
<select
|
||||
data-hj-suppress
|
||||
className="form-control"
|
||||
type="select"
|
||||
id={formId}
|
||||
@@ -108,7 +109,7 @@ class Country extends React.Component {
|
||||
showVisibility={visibilityCountry !== null}
|
||||
visibility={visibilityCountry}
|
||||
/>
|
||||
<p className="h5">{countryMessages[country]}</p>
|
||||
<p data-hj-suppress className="h5">{countryMessages[country]}</p>
|
||||
</React.Fragment>
|
||||
),
|
||||
empty: (
|
||||
@@ -126,7 +127,7 @@ class Country extends React.Component {
|
||||
<EditableItemHeader
|
||||
content={intl.formatMessage(messages['profile.country.label'])}
|
||||
/>
|
||||
<p className="h5">{countryMessages[country]}</p>
|
||||
<p data-hj-suppress className="h5">{countryMessages[country]}</p>
|
||||
</React.Fragment>
|
||||
),
|
||||
}}
|
||||
|
||||
@@ -72,6 +72,7 @@ class Education extends React.Component {
|
||||
{intl.formatMessage(messages['profile.education.education'])}
|
||||
</label>
|
||||
<select
|
||||
data-hj-suppress
|
||||
className="form-control"
|
||||
id={formId}
|
||||
name={formId}
|
||||
@@ -109,7 +110,7 @@ class Education extends React.Component {
|
||||
showVisibility={visibilityLevelOfEducation !== null}
|
||||
visibility={visibilityLevelOfEducation}
|
||||
/>
|
||||
<p className="h5">
|
||||
<p data-hj-suppress className="h5">
|
||||
{intl.formatMessage(get(
|
||||
messages,
|
||||
`profile.education.levels.${levelOfEducation}`,
|
||||
@@ -133,7 +134,7 @@ class Education extends React.Component {
|
||||
static: (
|
||||
<React.Fragment>
|
||||
<EditableItemHeader content={intl.formatMessage(messages['profile.education.education'])} />
|
||||
<p className="h5">
|
||||
<p data-hj-suppress className="h5">
|
||||
{intl.formatMessage(get(
|
||||
messages,
|
||||
`profile.education.levels.${levelOfEducation}`,
|
||||
|
||||
@@ -68,7 +68,7 @@ class Name extends React.Component {
|
||||
Once we're super sure we don't want it back, you could delete the name props and
|
||||
such to fully get rid of it.
|
||||
*/}
|
||||
<p className="h5">{name}</p>
|
||||
<p data-hj-suppress className="h5">{name}</p>
|
||||
<small className="form-text text-muted" id={`${formId}-help-text`}>
|
||||
{intl.formatMessage(messages['profile.name.details'])}
|
||||
</small>
|
||||
@@ -92,7 +92,7 @@ class Name extends React.Component {
|
||||
showVisibility={visibilityName !== null}
|
||||
visibility={visibilityName}
|
||||
/>
|
||||
<p className="h5">{name}</p>
|
||||
<p data-hj-suppress className="h5">{name}</p>
|
||||
<small className="form-text text-muted">
|
||||
{intl.formatMessage(messages['profile.name.details'])}
|
||||
</small>
|
||||
@@ -112,7 +112,7 @@ class Name extends React.Component {
|
||||
static: (
|
||||
<React.Fragment>
|
||||
<EditableItemHeader content={intl.formatMessage(messages['profile.name.full.name'])} />
|
||||
<p className="h5">{name}</p>
|
||||
<p data-hj-suppress className="h5">{name}</p>
|
||||
</React.Fragment>
|
||||
),
|
||||
}}
|
||||
|
||||
@@ -86,6 +86,7 @@ class PreferredLanguage extends React.Component {
|
||||
{intl.formatMessage(messages['profile.preferredlanguage.label'])}
|
||||
</label>
|
||||
<select
|
||||
data-hj-suppress
|
||||
id={formId}
|
||||
name={formId}
|
||||
className="form-control"
|
||||
@@ -117,7 +118,7 @@ class PreferredLanguage extends React.Component {
|
||||
showVisibility={visibilityLanguageProficiencies !== null}
|
||||
visibility={visibilityLanguageProficiencies}
|
||||
/>
|
||||
<p className="h5">{languageMessages[value]}</p>
|
||||
<p data-hj-suppress className="h5">{languageMessages[value]}</p>
|
||||
</React.Fragment>
|
||||
),
|
||||
empty: (
|
||||
@@ -135,7 +136,7 @@ class PreferredLanguage extends React.Component {
|
||||
<EditableItemHeader
|
||||
content={intl.formatMessage(messages['profile.preferredlanguage.label'])}
|
||||
/>
|
||||
<p className="h5">{languageMessages[value]}</p>
|
||||
<p data-hj-suppress className="h5">{languageMessages[value]}</p>
|
||||
</React.Fragment>
|
||||
),
|
||||
}}
|
||||
|
||||
@@ -109,6 +109,7 @@ class ProfileAvatar extends React.Component {
|
||||
<DefaultAvatar className="text-muted" role="img" aria-hidden focusable="false" viewBox="0 0 24 24" />
|
||||
) : (
|
||||
<img
|
||||
data-hj-suppress
|
||||
className="w-100 h-100 d-block rounded-circle overflow-hidden"
|
||||
style={{ objectFit: 'cover' }}
|
||||
alt={intl.formatMessage(messages['profile.image.alt.attribute'])}
|
||||
|
||||
Reference in New Issue
Block a user