Skip to content

Commit

Permalink
chore(deps): update paragon and frontend-build to openedx scope
Browse files Browse the repository at this point in the history
  • Loading branch information
brian-smith-tcril authored and arbrandes committed Feb 28, 2024
1 parent 3a7b705 commit 1a2068d
Show file tree
Hide file tree
Showing 64 changed files with 6,026 additions and 8,839 deletions.
2 changes: 1 addition & 1 deletion .eslintrc.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
const { createConfig } = require('@edx/frontend-build');
const { createConfig } = require('@openedx/frontend-build');

module.exports = createConfig(
'eslint',
Expand Down
2 changes: 1 addition & 1 deletion jest.config.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
const { createConfig } = require('@edx/frontend-build');
const { createConfig } = require('@openedx/frontend-build');

module.exports = createConfig('jest', {
// setupFilesAfterEnv is used after the jest environment has been loaded. In general this is what you want.
Expand Down
14,588 changes: 5,886 additions & 8,702 deletions package-lock.json

Large diffs are not rendered by default.

11 changes: 6 additions & 5 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,11 +34,11 @@
},
"dependencies": {
"@edx/brand": "npm:@openedx/brand-openedx@^1.2.2",
"@edx/frontend-component-footer": "12.6.1",
"@edx/frontend-component-header": "4.10.1",
"@edx/frontend-platform": "5.6.1",
"@edx/frontend-component-footer": "^13.0.2",
"@edx/frontend-component-header": "^5.0.2",
"@edx/frontend-platform": "^7.1.0",
"@edx/openedx-atlas": "^0.6.0",
"@edx/paragon": "20.46.3",
"@openedx/paragon": "^22.1.1",
"@reduxjs/toolkit": "1.9.7",
"@tinymce/tinymce-react": "3.13.1",
"babel-polyfill": "6.26.0",
Expand All @@ -62,11 +62,12 @@
},
"devDependencies": {
"@edx/browserslist-config": "1.2.0",
"@edx/frontend-build": "13.0.14",
"@openedx/frontend-build": "^13.0.28",
"@edx/reactifex": "1.1.0",
"@testing-library/jest-dom": "5.17.0",
"@testing-library/react": "12.1.5",
"@testing-library/user-event": "13.5.0",
"axios": "^0.28.0",
"axios-mock-adapter": "1.22.0",
"babel-plugin-react-intl": "8.2.25",
"eslint-plugin-simple-import-sort": "7.0.0",
Expand Down
8 changes: 4 additions & 4 deletions src/components/FilterBar.jsx
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
import React, { useCallback, useMemo, useState } from 'react';
import PropTypes from 'prop-types';

import {
Collapsible, Form, Icon, Spinner,
} from '@openedx/paragon';
import { Tune } from '@openedx/paragon/icons';
import { capitalize, toString } from 'lodash';
import { useSelector } from 'react-redux';

import { injectIntl, intlShape } from '@edx/frontend-platform/i18n';
import {
Collapsible, Form, Icon, Spinner,
} from '@edx/paragon';
import { Tune } from '@edx/paragon/icons';

import {
PostsStatusFilter, RequestStatus,
Expand Down
3 changes: 1 addition & 2 deletions src/components/FormikErrorFeedback.jsx
Original file line number Diff line number Diff line change
@@ -1,10 +1,9 @@
import React from 'react';
import PropTypes from 'prop-types';

import { Form, TransitionReplace } from '@openedx/paragon';
import { getIn, useFormikContext } from 'formik';

import { Form, TransitionReplace } from '@edx/paragon';

const FormikErrorFeedback = ({ name }) => {
const { touched, errors } = useFormikContext();
const fieldTouched = getIn(touched, name);
Expand Down
2 changes: 1 addition & 1 deletion src/components/NavigationBar/navBar.scss
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
@import "~@edx/brand/paragon/fonts.scss";
@import "~@edx/brand/paragon/variables.scss";
@import "~@edx/paragon/scss/core/core.scss";
@import "~@openedx/paragon/scss/core/core.scss";
@import "~@edx/brand/paragon/overrides.scss";

$fa-font-path: "~font-awesome/fonts";
Expand Down
2 changes: 1 addition & 1 deletion src/components/NavigationBar/tabs/Tabs.jsx
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
import React, { useMemo } from 'react';
import PropTypes from 'prop-types';

import { Dropdown } from '@openedx/paragon';
import classNames from 'classnames';

import { FormattedMessage } from '@edx/frontend-platform/i18n';
import { Dropdown } from '@edx/paragon';

import useIndexOfLastVisibleChild from './useIndexOfLastVisibleChild';

Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { useLayoutEffect, useRef, useState } from 'react';

import { useWindowSize } from '@edx/paragon';
import { useWindowSize } from '@openedx/paragon';

const invisibleStyle = {
position: 'absolute',
Expand Down
5 changes: 3 additions & 2 deletions src/components/PostPreviewPanel.jsx
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
import React, { useState } from 'react';
import PropTypes from 'prop-types';

import { Button, Icon, IconButton } from '@openedx/paragon';
import { Close } from '@openedx/paragon/icons';

import { useIntl } from '@edx/frontend-platform/i18n';
import { Button, Icon, IconButton } from '@edx/paragon';
import { Close } from '@edx/paragon/icons';

import messages from '../discussions/posts/post-editor/messages';
import HTMLLoader from './HTMLLoader';
Expand Down
4 changes: 2 additions & 2 deletions src/components/Search.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,12 @@ import React, {
useCallback, useContext, useEffect, useRef, useState,
} from 'react';

import { Icon, SearchField } from '@openedx/paragon';
import { Search as SearchIcon } from '@openedx/paragon/icons';
import camelCase from 'lodash/camelCase';
import { useDispatch, useSelector } from 'react-redux';

import { useIntl } from '@edx/frontend-platform/i18n';
import { Icon, SearchField } from '@edx/paragon';
import { Search as SearchIcon } from '@edx/paragon/icons';

import DiscussionContext from '../discussions/common/context';
import { setUsernameSearch } from '../discussions/learners/data';
Expand Down
5 changes: 3 additions & 2 deletions src/components/SearchInfo.jsx
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
import React from 'react';
import PropTypes from 'prop-types';

import { Button, Icon } from '@openedx/paragon';
import { Search } from '@openedx/paragon/icons';

import { useIntl } from '@edx/frontend-platform/i18n';
import { Button, Icon } from '@edx/paragon';
import { Search } from '@edx/paragon/icons';

import { RequestStatus } from '../data/constants';
import messages from '../discussions/posts/post-actions-bar/messages';
Expand Down
2 changes: 1 addition & 1 deletion src/components/Spinner.jsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import React from 'react';

import { Spinner as ParagonSpinner } from '@edx/paragon';
import { Spinner as ParagonSpinner } from '@openedx/paragon';

const Spinner = () => (
<div className="spinner-container" data-testid="spinner">
Expand Down
2 changes: 1 addition & 1 deletion src/components/TinyMCEEditor.jsx
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
import React, { useCallback, useEffect, useState } from 'react';

import { ActionRow, AlertModal, Button } from '@openedx/paragon';
import { Editor } from '@tinymce/tinymce-react';
import { useLocation, useParams } from 'react-router-dom';
// TinyMCE so the global var exists
// eslint-disable-next-line no-unused-vars,import/no-extraneous-dependencies
import tinymce from 'tinymce/tinymce';

import { useIntl } from '@edx/frontend-platform/i18n';
import { ActionRow, AlertModal, Button } from '@edx/paragon';

import { MAX_UPLOAD_FILE_SIZE } from '../data/constants';
import messages from '../discussions/messages';
Expand Down
4 changes: 2 additions & 2 deletions src/components/TopicStats.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,11 @@
import React from 'react';
import PropTypes from 'prop-types';

import { Icon, OverlayTrigger, Tooltip } from '@openedx/paragon';
import { HelpOutline, PostOutline, Report } from '@openedx/paragon/icons';
import { useSelector } from 'react-redux';

import { useIntl } from '@edx/frontend-platform/i18n';
import { Icon, OverlayTrigger, Tooltip } from '@edx/paragon';
import { HelpOutline, PostOutline, Report } from '@edx/paragon/icons';

import {
selectUserHasModerationPrivileges,
Expand Down
8 changes: 4 additions & 4 deletions src/discussions/common/ActionsDropdown.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,14 @@ import React, {
} from 'react';
import PropTypes from 'prop-types';

import {
Button, Dropdown, Icon, IconButton, ModalPopup, useToggle,
} from '@openedx/paragon';
import { MoreHoriz } from '@openedx/paragon/icons';
import { useSelector } from 'react-redux';

import { useIntl } from '@edx/frontend-platform/i18n';
import { logError } from '@edx/frontend-platform/logging';
import {
Button, Dropdown, Icon, IconButton, ModalPopup, useToggle,
} from '@edx/paragon';
import { MoreHoriz } from '@edx/paragon/icons';

import { ContentActions } from '../../data/constants';
import { selectIsPostingEnabled } from '../data/selectors';
Expand Down
4 changes: 2 additions & 2 deletions src/discussions/common/AlertBanner.jsx
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
import React from 'react';
import PropTypes from 'prop-types';

import { Alert } from '@openedx/paragon';
import { Report } from '@openedx/paragon/icons';
import { useSelector } from 'react-redux';

import { getAuthenticatedUser } from '@edx/frontend-platform/auth';
import { useIntl } from '@edx/frontend-platform/i18n';
import { Alert } from '@edx/paragon';
import { Report } from '@edx/paragon/icons';

import { AvatarOutlineAndLabelColors } from '../../data/constants';
import {
Expand Down
3 changes: 2 additions & 1 deletion src/discussions/common/AlertBar.jsx
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
import React from 'react';
import PropTypes from 'prop-types';

import { Alert } from '@openedx/paragon';

import { useIntl } from '@edx/frontend-platform/i18n';
import { Alert } from '@edx/paragon';

import messages from '../post-comments/messages';
import AuthorLabel from './AuthorLabel';
Expand Down
2 changes: 1 addition & 1 deletion src/discussions/common/AuthorLabel.jsx
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
import React, { useContext, useMemo } from 'react';
import PropTypes from 'prop-types';

import { Icon, OverlayTrigger, Tooltip } from '@openedx/paragon';
import classNames from 'classnames';
import { generatePath, Link } from 'react-router-dom';
import * as timeago from 'timeago.js';

import { useIntl } from '@edx/frontend-platform/i18n';
import { Icon, OverlayTrigger, Tooltip } from '@edx/paragon';

import { Routes } from '../../data/constants';
import messages from '../messages';
Expand Down
3 changes: 2 additions & 1 deletion src/discussions/common/Confirmation.jsx
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
import React from 'react';
import PropTypes from 'prop-types';

import { ActionRow, Button, ModalDialog } from '@openedx/paragon';

import { useIntl } from '@edx/frontend-platform/i18n';
import { ActionRow, Button, ModalDialog } from '@edx/paragon';

import messages from '../messages';

Expand Down
4 changes: 2 additions & 2 deletions src/discussions/common/EndorsedAlertBanner.jsx
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
import React, { useContext } from 'react';
import PropTypes from 'prop-types';

import { Alert, Icon } from '@openedx/paragon';
import { CheckCircle, Verified } from '@openedx/paragon/icons';
import * as timeago from 'timeago.js';

import { useIntl } from '@edx/frontend-platform/i18n';
import { Alert, Icon } from '@edx/paragon';
import { CheckCircle, Verified } from '@edx/paragon/icons';

import { ThreadType } from '../../data/constants';
import messages from '../post-comments/messages';
Expand Down
10 changes: 5 additions & 5 deletions src/discussions/common/HoverCard.jsx
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
import React, { useContext } from 'react';
import PropTypes from 'prop-types';

import classNames from 'classnames';

import { useIntl } from '@edx/frontend-platform/i18n';
import {
Button, Icon, IconButton, OverlayTrigger, Tooltip,
} from '@edx/paragon';
} from '@openedx/paragon';
import {
StarFilled, StarOutline, ThumbUpFilled, ThumbUpOutline,
} from '@edx/paragon/icons';
} from '@openedx/paragon/icons';
import classNames from 'classnames';

import { useIntl } from '@edx/frontend-platform/i18n';

import { ThreadType } from '../../data/constants';
import { useUserPostingEnabled } from '../data/hooks';
Expand Down
2 changes: 1 addition & 1 deletion src/discussions/content-unavailable/ContentUnavailable.jsx
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
import React, { useCallback } from 'react';
import propTypes from 'prop-types';

import { Button } from '@openedx/paragon';
import classNames from 'classnames';
import { useSelector } from 'react-redux';

import { getConfig } from '@edx/frontend-platform';
import { useIntl } from '@edx/frontend-platform/i18n';
import { Button } from '@edx/paragon';

import ContentUnavailableIcon from '../../assets/ContentUnavailable';
import selectCourseTabs from '../../components/NavigationBar/data/selectors';
Expand Down
2 changes: 1 addition & 1 deletion src/discussions/data/hooks.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ import {
useContext, useEffect, useMemo, useRef, useState,
} from 'react';

import { breakpoints, useWindowSize } from '@openedx/paragon';
import { useDispatch, useSelector } from 'react-redux';
import {
matchPath, useLocation, useMatch, useNavigate,
Expand All @@ -11,7 +12,6 @@ import {
import { getAuthenticatedUser } from '@edx/frontend-platform/auth';
import { useIntl } from '@edx/frontend-platform/i18n';
import { AppContext } from '@edx/frontend-platform/react';
import { breakpoints, useWindowSize } from '@edx/paragon';

import fetchTab from '../../components/NavigationBar/data/thunks';
import { RequestStatus, Routes } from '../../data/constants';
Expand Down
3 changes: 1 addition & 2 deletions src/discussions/discussions-home/DiscussionSidebar.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,13 @@ import React, {
} from 'react';
import PropTypes from 'prop-types';

import { useWindowSize } from '@openedx/paragon';
import classNames from 'classnames';
import { useSelector } from 'react-redux';
import {
Navigate, Route, Routes,
} from 'react-router-dom';

import { useWindowSize } from '@edx/paragon';

import Spinner from '../../components/Spinner';
import { RequestStatus, Routes as ROUTES } from '../../data/constants';
import DiscussionContext from '../common/context';
Expand Down
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
import React, { useCallback, useState } from 'react';

import { PageBanner } from '@openedx/paragon';
import { useSelector } from 'react-redux';

import { useIntl } from '@edx/frontend-platform/i18n';
import { PageBanner } from '@edx/paragon';

import { RequestStatus } from '../../data/constants';
import { selectConfigLoadingStatus, selectIsPostingEnabled } from '../data/selectors';
Expand Down
3 changes: 1 addition & 2 deletions src/discussions/empty-posts/EmptyPage.jsx
Original file line number Diff line number Diff line change
@@ -1,10 +1,9 @@
import React from 'react';
import propTypes from 'prop-types';

import { Button } from '@openedx/paragon';
import classNames from 'classnames';

import { Button } from '@edx/paragon';

import EmptyIcon from '../../assets/Empty';

const EmptyPage = ({
Expand Down
2 changes: 1 addition & 1 deletion src/discussions/in-context-topics/TopicPostsView.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,11 @@ import React, {
useCallback, useContext, useEffect, useMemo,
} from 'react';

import { Spinner } from '@openedx/paragon';
import { useDispatch, useSelector } from 'react-redux';
import { useLocation } from 'react-router-dom';

import { useIntl } from '@edx/frontend-platform/i18n';
import { Spinner } from '@edx/paragon';

import { RequestStatus, Routes } from '../../data/constants';
import DiscussionContext from '../common/context';
Expand Down
3 changes: 1 addition & 2 deletions src/discussions/in-context-topics/TopicsView.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,11 @@ import React, {
useCallback, useContext, useEffect, useMemo,
} from 'react';

import { Spinner } from '@openedx/paragon';
import classNames from 'classnames';
import isEmpty from 'lodash/isEmpty';
import { useDispatch, useSelector } from 'react-redux';

import { Spinner } from '@edx/paragon';

import SearchInfo from '../../components/SearchInfo';
import { RequestStatus } from '../../data/constants';
import DiscussionContext from '../common/context';
Expand Down
12 changes: 7 additions & 5 deletions src/discussions/in-context-topics/TopicsView.test.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -151,12 +151,14 @@ describe('InContext Topics View', () => {
const sectionGroups = await screen.getAllByTestId('section-group');

coursewareTopics.forEach(async (topic, index) => {
const stats = await sectionGroups[index].querySelectorAll('.icon-size:not([data-testid="subsection-group"].icon-size)');
const subsectionGroups = await within(sectionGroups[index]).getAllByTestId('subsection-group');
await waitFor(async () => {
const stats = await sectionGroups[index].querySelectorAll('.icon-size:not([data-testid="subsection-group"].icon-size)');
const subsectionGroups = await within(sectionGroups[index]).getAllByTestId('subsection-group');

expect(within(sectionGroups[index]).queryByText(topic.displayName)).toBeInTheDocument();
expect(stats).toHaveLength(0);
expect(subsectionGroups).toHaveLength(2);
expect(within(sectionGroups[index]).queryByText(topic.displayName)).toBeInTheDocument();
expect(stats).toHaveLength(0);
expect(subsectionGroups).toHaveLength(2);
});
});
});

Expand Down
Loading

0 comments on commit 1a2068d

Please sign in to comment.